Example #1
0
        public static void Init()
        {
            string         itemName     = "Test Active Item";
            string         resourceName = "BunnyMod/Resources/speckofdust";
            GameObject     obj          = new GameObject(itemName);
            TestActiveItem testActive   = obj.AddComponent <TestActiveItem>();

            ItemBuilder.AddSpriteToObject(itemName, resourceName, obj);
            string shortDesc = "Used for testing";
            string longDesc  = "Test Active For Testing 'On Active' Items.";

            testActive.SetupItem(shortDesc, longDesc, "bny");
            testActive.SetCooldownType(ItemBuilder.CooldownType.Timed, 5f);
            testActive.consumable = false;
            testActive.quality    = PickupObject.ItemQuality.EXCLUDED;
        }