Exemplo n.º 1
0
        public static void DrinkCure_OnCommand(CommandEventArgs e)
        {
            GreaterCurePotion m_GreaterCurePotion = (GreaterCurePotion)e.Mobile.Backpack.FindItemByType(typeof(GreaterCurePotion));
            CurePotion        m_CurePotion        = (CurePotion)e.Mobile.Backpack.FindItemByType(typeof(CurePotion));
            LesserCurePotion  m_LesserCurePotion  = (LesserCurePotion)e.Mobile.Backpack.FindItemByType(typeof(LesserCurePotion));
            int m_Exists   = e.Mobile.Backpack.GetAmount(typeof(GreaterCurePotion));
            int m_Existss  = e.Mobile.Backpack.GetAmount(typeof(CurePotion));
            int m_Existsss = e.Mobile.Backpack.GetAmount(typeof(LesserCurePotion));

            if (m_Exists != 0)
            {
                e.Mobile.SendMessage("Cure Potion found");

                m_GreaterCurePotion.OnDoubleClick(e.Mobile);
            }
            else if (m_Existss != 0)
            {
                e.Mobile.SendMessage("Cure Potion found");

                m_CurePotion.OnDoubleClick(e.Mobile);
            }
            else if (m_Existsss != 0)
            {
                e.Mobile.SendMessage("Cure Potion found");

                m_LesserCurePotion.OnDoubleClick(e.Mobile);
            }
            else
            {
                e.Mobile.SendMessage("Cannot find Cure Potion");
            }
        }
Exemplo n.º 2
0
            public InternalSellInfo()
            {
                Add(typeof(Bottle), Bottle.GetSBSellValue());
                Add(typeof(MortarPestle), MortarPestle.GetSBSellValue());

                Add(typeof(BlackPearl), BlackPearl.GetSBSellValue());
                Add(typeof(Bloodmoss), Bloodmoss.GetSBSellValue());
                Add(typeof(MandrakeRoot), MandrakeRoot.GetSBSellValue());
                Add(typeof(Garlic), Garlic.GetSBSellValue());
                Add(typeof(Ginseng), Ginseng.GetSBSellValue());
                Add(typeof(Nightshade), Nightshade.GetSBSellValue());
                Add(typeof(SpidersSilk), SpidersSilk.GetSBSellValue());
                Add(typeof(SulfurousAsh), SulfurousAsh.GetSBSellValue());

                Add(typeof(LesserMagicResistPotion), LesserMagicResistPotion.GetSBSellValue());
                Add(typeof(AgilityPotion), AgilityPotion.GetSBSellValue());
                Add(typeof(StrengthPotion), StrengthPotion.GetSBSellValue());
                Add(typeof(RefreshPotion), RefreshPotion.GetSBSellValue());
                Add(typeof(LesserCurePotion), LesserCurePotion.GetSBSellValue());
                Add(typeof(LesserHealPotion), LesserHealPotion.GetSBSellValue());
                Add(typeof(LesserPoisonPotion), LesserPoisonPotion.GetSBSellValue());
                Add(typeof(LesserExplosionPotion), LesserExplosionPotion.GetSBSellValue());

                Add(typeof(HairDye), HairDye.GetSBSellValue());
            }
Exemplo n.º 3
0
            public InternalSellInfo()
            {
                Add(typeof(Bandage), Bandage.GetSBSellValue());

                Add(typeof(LesserHealPotion), LesserHealPotion.GetSBSellValue());
                Add(typeof(LesserCurePotion), LesserCurePotion.GetSBSellValue());
                Add(typeof(RefreshPotion), RefreshPotion.GetSBSellValue());
            }
Exemplo n.º 4
0
        public static void DrinkCure_OnCommand(CommandEventArgs e)
        {
            // Added to fix the missing check to region. Ugly fix but this script is so ugly anyways. :p
            if (e.Mobile.Region != null && !e.Mobile.Region.OnDoubleClick(e.Mobile, new CurePotion()))
            {
                return;
            }

            LesserCurePotion  lc_potion = (LesserCurePotion)e.Mobile.Backpack.FindItemByType(typeof(LesserCurePotion));
            CurePotion        mc_potion = (CurePotion)e.Mobile.Backpack.FindItemByType(typeof(CurePotion));
            GreaterCurePotion gc_potion = (GreaterCurePotion)e.Mobile.Backpack.FindItemByType(typeof(GreaterCurePotion));

            int lcp = e.Mobile.Backpack.GetAmount(typeof(LesserCurePotion));

            if (lcp != 0)
            {
                Targeting.Target.Cancel(e.Mobile);
                e.Mobile.SendMessage("Lesser cure potion found");
                new InternalTimer(e.Mobile, lc_potion).Start();
            }
            else
            {
                int mcp = e.Mobile.Backpack.GetAmount(typeof(CurePotion));

                if (mcp != 0)
                {
                    Targeting.Target.Cancel(e.Mobile);
                    e.Mobile.SendMessage("Cure potion found");
                    new InternalTimer(e.Mobile, mc_potion).Start();
                }
                else
                {
                    int gcp = e.Mobile.Backpack.GetAmount(typeof(GreaterCurePotion));

                    if (gcp != 0)
                    {
                        Targeting.Target.Cancel(e.Mobile);
                        e.Mobile.SendMessage("Greater cure potion found");
                        new InternalTimer(e.Mobile, gc_potion).Start();
                    }
                    else
                    {
                        e.Mobile.SendMessage("Cure potion not found");
                    }
                }
            }
        }
Exemplo n.º 5
0
            public InternalBuyInfo()
            {
                Add(new GenericBuyInfo("Bottle", typeof(Bottle), Bottle.GetSBPurchaseValue(), 200, 0xF0E, 0));
                Add(new GenericBuyInfo("Mortar and Pestle", typeof(MortarPestle), MortarPestle.GetSBPurchaseValue(), 10, 0xE9B, 0));

                Add(new GenericBuyInfo("Black Pearl", typeof(BlackPearl), BlackPearl.GetSBPurchaseValue(), 500, 0xF7A, 0));
                Add(new GenericBuyInfo("Bloodmoss", typeof(Bloodmoss), Bloodmoss.GetSBPurchaseValue(), 500, 0xF7B, 0));
                Add(new GenericBuyInfo("Mandrake Root", typeof(MandrakeRoot), MandrakeRoot.GetSBPurchaseValue(), 500, 0xF86, 0));
                Add(new GenericBuyInfo("Garlic", typeof(Garlic), Garlic.GetSBPurchaseValue(), 500, 0xF84, 0));
                Add(new GenericBuyInfo("Ginseng", typeof(Ginseng), Ginseng.GetSBPurchaseValue(), 500, 0xF85, 0));
                Add(new GenericBuyInfo("Nightshade", typeof(Nightshade), Nightshade.GetSBPurchaseValue(), 500, 0xF88, 0));
                Add(new GenericBuyInfo("Spider Silk", typeof(SpidersSilk), SpidersSilk.GetSBPurchaseValue(), 500, 0xF8D, 0));
                Add(new GenericBuyInfo("Sulfurous Ash", typeof(SulfurousAsh), SulfurousAsh.GetSBPurchaseValue(), 500, 0xF8C, 0));

                Add(new GenericBuyInfo("Lesser Heal Potion", typeof(LesserHealPotion), LesserHealPotion.GetSBPurchaseValue(), 50, 0xF0C, 0));
                Add(new GenericBuyInfo("Lesser Cure Potion", typeof(LesserCurePotion), LesserCurePotion.GetSBPurchaseValue(), 50, 0xF07, 0));
                Add(new GenericBuyInfo("Refresh Potion", typeof(RefreshPotion), RefreshPotion.GetSBPurchaseValue(), 50, 0xF0B, 0));
                Add(new GenericBuyInfo("Agility Potion", typeof(AgilityPotion), AgilityPotion.GetSBPurchaseValue(), 50, 0xF08, 0));
                Add(new GenericBuyInfo("Strength Potion", typeof(StrengthPotion), StrengthPotion.GetSBPurchaseValue(), 50, 0xF09, 0));
                Add(new GenericBuyInfo("Lesser Magic Resist Potion", typeof(LesserMagicResistPotion), LesserMagicResistPotion.GetSBPurchaseValue(), 10, 0xF06, 0));
                Add(new GenericBuyInfo("Lesser Poison Potion", typeof(LesserPoisonPotion), LesserPoisonPotion.GetSBPurchaseValue(), 50, 0xF0A, 0));
                Add(new GenericBuyInfo("Lesser Explosion Potion", typeof(LesserExplosionPotion), LesserExplosionPotion.GetSBPurchaseValue(), 50, 0xF0D, 0));

                Add(new GenericBuyInfo("Hair Dye", typeof(HairDye), HairDye.GetSBPurchaseValue(), 10, 0xEFF, 0));
            }
Exemplo n.º 6
0
            public InternalBuyInfo()
            {
                Add(new GenericBuyInfo("Bandage", typeof(Bandage), Bandage.GetSBPurchaseValue(), 250, 0xE21, 0));

                Add(new GenericBuyInfo("Lesser Heal Potion", typeof(LesserHealPotion), LesserHealPotion.GetSBPurchaseValue(), 50, 0xF0C, 0));
                Add(new GenericBuyInfo("Lesser Cure Potion", typeof(LesserCurePotion), LesserCurePotion.GetSBPurchaseValue(), 50, 0xF07, 0));
                Add(new GenericBuyInfo("Refresh Potion", typeof(RefreshPotion), RefreshPotion.GetSBPurchaseValue(), 50, 0xF0B, 0));
            }