This package has been deprecated and may no longer be maintained. We recommend looking for an alternative.
Kopie Consumables Api thingy
Adds ability to easily add consumablesexample below
{
var piggyjar = ScriptableObject.CreateInstance<ConsumableItemData>();
piggyjar.description = "Using this will put a card in a jar for later use";
piggyjar.powerLevel = 2;
piggyjar.name= "Jar";
piggyjar.regionSpecific = false;
piggyjar.rulebookDescription = piggyjar.description;
piggyjar.rulebookCategory = AbilityMetaCategory.Part1Rulebook;
piggyjar.rulebookName = "Keepers Jar";
piggyjar.notRandomlyGiven = false;
byte[] imgBytes = File.ReadAllBytes(Path.Combine(this.Info.Location.Replace("consumablesapi.dll", ""), "Artwork/gloves.png"));
Texture2D tex = new Texture2D(2, 2);
tex.LoadImage(imgBytes);
piggyjar.rulebookSprite=Sprite.Create(tex, new Rect(0.0f, 0.0f, tex.width, tex.height), new Vector2(0.5f, 0.5f), 100.0f);
NewConsumable(piggyjar, typeof(KeeperJar), LoadMeshAndMaterial(staticpath.Replace("consumablesapi.dll", "")+"jar.obj", staticpath.Replace("consumablesapi.dll", "")+"jar.png"), new Vector3(0,1.1f,-1.2f), new Vector3(0.5f,0.5f,0.5f));
}
