상속: BaseCreature, IVendor
        public RefillGump(BaseVendor vendor, Mobile from, QuestReagentBag bag, List<RefillEntry> refillEntryList)
            : base(50, 50)
        {
            from.CloseGump(typeof(RefillGump));

            m_Vendor = vendor;
            m_Bag = bag;
            m_RefillEntryList = refillEntryList;

            this.Closable = true;
            this.Disposable = true;
            this.Dragable = true;
            this.Resizable = false;

            this.AddPage(0);

            this.AddBackground(0, 0, 453, 285, 2620);
            this.AddAlphaRegion(4, 7, 443, 271);
            this.AddLabel(bag.Type == QuestReagentBag.ReagentBagType.Mage ? 160 : 140, 13, 955, string.Format("Refill {0}", bag.Name));
            this.AddLabel(22, 45, 955, @"Reagents");
            this.AddLabel(106, 45, 955, @"Amount to refill");
            this.AddLabel(371, 45, 955, @"Total Cost");
            this.AddLabel(239, 45, 955, @"Cost per reagent");
            this.AddButton(410, 250, 4017, 4018, (int)Buttons.Cancel, GumpButtonType.Reply, 0);

            m_Price = ShowReagentCostList(refillEntryList);

            if (m_Price > 0)
            {
                this.AddLabel(100, 229, 955, string.Format("Do you want to refill your bag for {0} gp?", m_Price));
                this.AddButton(210, 250, 4023, 4024, (int)Buttons.OK, GumpButtonType.Reply, 0);
            }
        }
예제 #2
0
                public InternalBuyInfo(BaseVendor owner)
                {
                    Add(new GenericBuyInfo("Stasis Chamber Power Core", typeof(StasisChamberPowerCore), 101250, 500, 40155, 0));

                    Add(new GenericBuyInfo("1159014", typeof(CircuitTrapTrainingKit), 99375, 500, 41875, 0));
                    Add(new GenericBuyInfo("1159015", typeof(CylinderTrapTrainingKit), 99375, 500, 41875, 0));
                    Add(new GenericBuyInfo("1159016", typeof(SliderTrapTrainingKit), 99375, 500, 41875, 0));
                }
예제 #3
0
 public void OnSold(BaseVendor vendor, int amount)
 {
     if (EconomyItem)
     {
         foreach (var bii in vendor.GetBuyInfo().OfType <GenericBuyInfo>())
         {
             if (bii.Type == m_Type || (m_Type == typeof(UncutCloth) && bii.Type == typeof(Cloth)) || (m_Type == typeof(Cloth) && bii.Type == typeof(UncutCloth)))
             {
                 bii.TotalSold += amount;
             }
         }
     }
 }
예제 #4
0
        public void OnBought(Mobile buyer, BaseVendor vendor, IEntity entity, int amount)
        {
            if (EconomyItem)
            {
                foreach (var bii in vendor.GetBuyInfo().OfType <GenericBuyInfo>())
                {
                    if (bii.Type == m_Type || (m_Type == typeof(UncutCloth) && bii.Type == typeof(Cloth)) || (m_Type == typeof(Cloth) && bii.Type == typeof(UncutCloth)))
                    {
                        bii.TotalBought += amount;
                    }
                }
            }

            EventSink.InvokeValidVendorPurchase(new ValidVendorPurchaseEventArgs(buyer, vendor, entity, m_Price));
        }
        public static int GetPriceFromVendor(BaseVendor vendor, Type itemType)
        {
            IBuyItemInfo[] buyInfo = vendor.GetBuyInfo();

            for (int i = 0; i < buyInfo.Length; ++i)
            {
                IBuyItemInfo buyItem = (IBuyItemInfo)buyInfo[i];
                GenericBuyInfo gbi = (GenericBuyInfo)buyItem;

                if (gbi.Type == itemType)
                    return buyItem.Price;
            }

            return 0;
        }
예제 #6
0
        public ChangeHairHueGump(
            Mobile from, BaseVendor vendor, int price, bool hair, bool facialHair, ChangeHairHueEntry[] entries)
            : base(50, 50)
        {
            m_From       = from;
            m_Vendor     = vendor;
            m_Price      = price;
            m_Hair       = hair;
            m_FacialHair = facialHair;
            m_Entries    = entries;

            from.CloseGump(typeof(HairstylistBuyGump));
            from.CloseGump(typeof(ChangeHairHueGump));
            from.CloseGump(typeof(ChangeHairstyleGump));

            AddPage(0);

            AddBackground(100, 10, 350, 370, 2600);
            AddBackground(120, 54, 110, 270, 5100);

            AddHtmlLocalized(155, 25, 240, 30, 1011013, false, false);             // <center>Hair Color Selection Menu</center>

            AddHtmlLocalized(150, 330, 220, 35, 1011014, false, false);            // Dye my hair this color!
            AddButton(380, 330, 4005, 4007, 1, GumpButtonType.Reply, 0);

            for (int i = 0; i < entries.Length; ++i)
            {
                ChangeHairHueEntry entry = entries[i];

                AddLabel(130, 59 + (i * 22), entry.Hues[0] - 1, entry.Name);
                AddButton(207, 60 + (i * 22), 5224, 5224, 0, GumpButtonType.Page, 1 + i);
            }

            for (int i = 0; i < entries.Length; ++i)
            {
                ChangeHairHueEntry entry = entries[i];
                int[]  hues = entry.Hues;
                string name = entry.Name;

                AddPage(1 + i);

                for (int j = 0; j < hues.Length; ++j)
                {
                    AddLabel(278 + ((j / 16) * 80), 52 + ((j % 16) * 17), hues[j] - 1, name);
                    AddRadio(260 + ((j / 16) * 80), 52 + ((j % 16) * 17), 210, 211, false, (j * entries.Length) + i);
                }
            }
        }
예제 #7
0
        public HairstylistBuyGump(Mobile from, BaseVendor vendor, HairstylistBuyInfo[] sellList)
            : base(50, 50)
        {
            m_From     = from;
            m_Vendor   = vendor;
            m_SellList = sellList;

            from.CloseGump(typeof(HairstylistBuyGump));
            from.CloseGump(typeof(ChangeHairHueGump));
            from.CloseGump(typeof(ChangeHairstyleGump));

            bool isFemale = (from.Female || from.Body.IsFemale);

            int balance   = Banker.GetBalance(from, vendor.TypeOfCurrency);
            int canAfford = sellList.Count(t => balance >= t.Price && (!t.FacialHair || !isFemale));

            AddPage(0);

            AddBackground(50, 10, 450, 100 + (canAfford * 25), 2600);

            AddHtmlLocalized(100, 40, 350, 20, 1018356, false, false);             // Choose your hairstyle change:

            int index = 0;

            for (int i = 0; i < sellList.Length; ++i)
            {
                if (balance < sellList[i].Price || (sellList[i].FacialHair && isFemale))
                {
                    continue;
                }

                if (sellList[i].TitleString != null)
                {
                    AddHtml(140, 75 + (index * 25), 300, 20, sellList[i].TitleString, false, false);
                }
                else
                {
                    AddHtmlLocalized(140, 75 + (index * 25), 300, 20, sellList[i].Title, false, false);
                }

                AddButton(100, 75 + (index++ *25), 4005, 4007, 1 + i, GumpButtonType.Reply, 0);
            }
        }
예제 #8
0
        // Temporary
        public override void OnSpeech(SpeechEventArgs e)
        {
            base.OnSpeech(e);

            Mobile from = e.Mobile;

            BaseVendor vendor = m_Mobile as BaseVendor;

            if (m_Mobile is BaseVendor && from.InRange(m_Mobile, m_Mobile.EraAOS ? 1 : 4) && !e.Handled)
            {
                if (e.HasKeyword(0x14D))                     // *vendor sell*
                {
                    e.Handled = true;

                    vendor.VendorSell(from);
                    m_Mobile.FocusMob = from;
                }
                else if (e.HasKeyword(0x3C))
                {
                    e.Handled = true;

                    vendor.VendorBuy(from);
                    m_Mobile.FocusMob = from;
                }
                else if (WasNamed(e.Speech))
                {
                    e.Handled = true;

                    if (e.HasKeyword(0x177))                         // *sell*
                    {
                        vendor.VendorSell(from);
                    }
                    else if (e.HasKeyword(0x171))                         // *buy*
                    {
                        vendor.VendorBuy(from);
                    }

                    m_Mobile.FocusMob = from;
                }
            }
        }
        public static bool RefillBag(BaseVendor vendor, Mobile from, Item dropped)
        {
            if (dropped is QuestReagentBag)
            {
                QuestReagentBag regBag = (QuestReagentBag)dropped;
                List<RefillEntry> refillEntryList = ERefillUtility.Refill(regBag, regBag.ReagentTypes, vendor, from, false, regBag.BagRefillAmount);
                //int cost = 0;
                int amount = 0;

                foreach (RefillEntry entry in refillEntryList)
                    amount += entry.AmountToRefill;
                    //cost += entry.TotalCost;

                if (amount <= 0)
                    vendor.Say("That bag seems to be full.");
                else
                    from.SendGump(new RefillGump(vendor, from, (QuestReagentBag)dropped, refillEntryList));
                return true;
            }
            return false;
        }
예제 #10
0
        public GenericBuyInfo(string name, Type type, int price, int amount, int itemID, int hue, object[] args)
        {
            amount = 100;

            m_Type      = type;
            m_Price     = price;
            m_MaxAmount = m_Amount = amount;
            m_ItemID    = itemID;
            m_Hue       = hue;
            m_Args      = args;

            if (name == null)
            {
                m_Name = (1020000 + (itemID & 0x3FFF)).ToString();                     // TODO (SA): Extended Tiledata
            }
            else
            {
                m_Name = name;
            }

            BaseVendor.SetVendorPrice(m_Type, m_Price);
        }
예제 #11
0
 public InteractTimer(Mobile from, BaseVendor vendor)
     : base(TimeSpan.FromSeconds(60.0))
 {
     m_From   = from;
     m_Vendor = vendor;
 }
예제 #12
0
 public static void GetContextMenuEntries(Mobile from, BaseVendor vendor, List <ContextMenuEntry> list)
 {
     list.Add(new AProvisionerCancelMenu(from, vendor));                //HERE
 }
예제 #13
0
 public InteractTimer(Mobile from, BaseVendor vendor)
     : base(TimeSpan.FromSeconds(60.0))
 {
     m_From = from;
     m_Vendor = vendor;
 }
예제 #14
0
 public InternalSB(BaseVendor owner)
 {
     m_BuyInfo = new InternalBuyInfo(owner);
 }
예제 #15
0
		public virtual bool CheckVendorAccess( BaseVendor vendor, Mobile from )
		{
			return !from.Criminal || from.AccessLevel >= AccessLevel.GameMaster || IsDisabled();
		}
예제 #16
0
		public ChangeHairHueGump(
			Mobile from, BaseVendor vendor, int price, bool hair, bool facialHair, ChangeHairHueEntry[] entries)
			: base(50, 50)
		{
			m_From = from;
			m_Vendor = vendor;
			m_Price = price;
			m_Hair = hair;
			m_FacialHair = facialHair;
			m_Entries = entries;

			from.CloseGump(typeof(HairstylistBuyGump));
			from.CloseGump(typeof(ChangeHairHueGump));
			from.CloseGump(typeof(ChangeHairstyleGump));

			AddPage(0);

			AddBackground(100, 10, 350, 370, 2600);
			AddBackground(120, 54, 110, 270, 5100);

			AddHtmlLocalized(155, 25, 240, 30, 1011013, false, false); // <center>Hair Color Selection Menu</center>

			AddHtmlLocalized(150, 330, 220, 35, 1011014, false, false); // Dye my hair this color!
			AddButton(380, 330, 4005, 4007, 1, GumpButtonType.Reply, 0);

			for (int i = 0; i < entries.Length; ++i)
			{
				ChangeHairHueEntry entry = entries[i];

				AddLabel(130, 59 + (i * 22), entry.Hues[0] - 1, entry.Name);
				AddButton(207, 60 + (i * 22), 5224, 5224, 0, GumpButtonType.Page, 1 + i);
			}

			for (int i = 0; i < entries.Length; ++i)
			{
				ChangeHairHueEntry entry = entries[i];
				int[] hues = entry.Hues;
				string name = entry.Name;

				AddPage(1 + i);

				for (int j = 0; j < hues.Length; ++j)
				{
					AddLabel(278 + ((j / 16) * 80), 52 + ((j % 16) * 17), hues[j] - 1, name);
					AddRadio(260 + ((j / 16) * 80), 52 + ((j % 16) * 17), 210, 211, false, (j * entries.Length) + i);
				}
			}
		}
예제 #17
0
 public AAlchemistCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
 {
     m_Vendor = vendor as AAlchemist;                                        //HERE
     m_Mobile = from;
 }
예제 #18
0
            public InternalBuyInfo(BaseVendor owner)
            {
                Add(new GenericBuyInfo(typeof(Clock), 22, 20, 0x104B, 0));
                Add(new GenericBuyInfo(typeof(Nails), 3, 20, 0x102E, 0));
                Add(new GenericBuyInfo(typeof(ClockParts), 3, 20, 0x104F, 0, true));
                Add(new GenericBuyInfo(typeof(AxleGears), 3, 20, 0x1051, 0, true));
                Add(new GenericBuyInfo(typeof(Gears), 2, 20, 0x1053, 0, true));
                Add(new GenericBuyInfo(typeof(Hinge), 2, 20, 0x1055, 0, true));

                Add(new GenericBuyInfo(typeof(Sextant), 13, 20, 0x1057, 0));
                Add(new GenericBuyInfo(typeof(SextantParts), 5, 20, 0x1059, 0, true));
                Add(new GenericBuyInfo(typeof(Axle), 2, 20, 0x105B, 0, true));
                Add(new GenericBuyInfo(typeof(Springs), 3, 20, 0x105D, 0, true));

                Add(new GenericBuyInfo("1024111", typeof(Key), 8, 20, 0x100F, 0));
                Add(new GenericBuyInfo("1024112", typeof(Key), 8, 20, 0x1010, 0));
                Add(new GenericBuyInfo("1024115", typeof(Key), 8, 20, 0x1013, 0));
                Add(new GenericBuyInfo(typeof(KeyRing), 8, 20, 0x1010, 0));
                Add(new GenericBuyInfo(typeof(Lockpick), 12, 20, 0x14FC, 0, true));

                Add(new GenericBuyInfo(typeof(TinkersTools), 7, 20, 0x1EBC, 0));
                Add(new GenericBuyInfo(typeof(Board), 3, 20, 0x1BD7, 0, true));
                Add(new GenericBuyInfo(typeof(IronIngot), 5, 16, 0x1BF2, 0, true));
                Add(new GenericBuyInfo(typeof(SewingKit), 3, 20, 0xF9D, 0));

                Add(new GenericBuyInfo(typeof(DrawKnife), 10, 20, 0x10E4, 0));
                Add(new GenericBuyInfo(typeof(Froe), 10, 20, 0x10E5, 0));
                Add(new GenericBuyInfo(typeof(Scorp), 10, 20, 0x10E7, 0));
                Add(new GenericBuyInfo(typeof(Inshave), 10, 20, 0x10E6, 0));

                Add(new GenericBuyInfo(typeof(ButcherKnife), 13, 20, 0x13F6, 0));

                Add(new GenericBuyInfo(typeof(Scissors), 11, 20, 0xF9F, 0));

                Add(new GenericBuyInfo(typeof(Tongs), 13, 14, 0xFBB, 0));

                Add(new GenericBuyInfo(typeof(DovetailSaw), 12, 20, 0x1028, 0));
                Add(new GenericBuyInfo(typeof(Saw), 15, 20, 0x1034, 0));

                Add(new GenericBuyInfo(typeof(Hammer), 17, 20, 0x102A, 0));
                Add(new GenericBuyInfo(typeof(SmithHammer), 23, 20, 0x13E3, 0));
                // TODO: Sledgehammer

                Add(new GenericBuyInfo(typeof(Shovel), 12, 20, 0xF39, 0));

                Add(new GenericBuyInfo(typeof(MouldingPlane), 11, 20, 0x102C, 0));
                Add(new GenericBuyInfo(typeof(JointingPlane), 10, 20, 0x1030, 0));
                Add(new GenericBuyInfo(typeof(SmoothingPlane), 11, 20, 0x1032, 0));

                Add(new GenericBuyInfo(typeof(Pickaxe), 25, 20, 0xE86, 0));

                Add(new GenericBuyInfo(typeof(Drums), 21, 20, 0x0E9C, 0));
                Add(new GenericBuyInfo(typeof(Tambourine), 21, 20, 0x0E9E, 0));
                Add(new GenericBuyInfo(typeof(LapHarp), 21, 20, 0x0EB2, 0));
                Add(new GenericBuyInfo(typeof(Lute), 21, 20, 0x0EB3, 0));

                if (owner != null && owner.Race == Race.Gargoyle)
                {
                    Add(new GenericBuyInfo(typeof(AudChar), 33, 20, 0x403B, 0));
                    Add(new GenericBuyInfo("1080201", typeof(StatuetteEngravingTool), 1253, 20, 0x12B3, 0));
                    Add(new GenericBuyInfo(typeof(BasketWeavingBook), 10625, 20, 0xFBE, 0));
                }
            }
예제 #19
0
		public HairstylistBuyGump(Mobile from, BaseVendor vendor, HairstylistBuyInfo[] sellList)
			: base(50, 50)
		{
			m_From = from;
			m_Vendor = vendor;
			m_SellList = sellList;

			from.CloseGump(typeof(HairstylistBuyGump));
			from.CloseGump(typeof(ChangeHairHueGump));
			from.CloseGump(typeof(ChangeHairstyleGump));

			bool isFemale = (from.Female || from.Body.IsFemale);

			int balance = Banker.GetBalance(from, vendor.TypeOfCurrency);
			int canAfford = sellList.Count(t => balance >= t.Price && (!t.FacialHair || !isFemale));

			AddPage(0);

			AddBackground(50, 10, 450, 100 + (canAfford * 25), 2600);

			AddHtmlLocalized(100, 40, 350, 20, 1018356, false, false); // Choose your hairstyle change:

			int index = 0;

			for (int i = 0; i < sellList.Length; ++i)
			{
				if (balance < sellList[i].Price || (sellList[i].FacialHair && isFemale))
				{
					continue;
				}

				if (sellList[i].TitleString != null)
				{
					AddHtml(140, 75 + (index * 25), 300, 20, sellList[i].TitleString, false, false);
				}
				else
				{
					AddHtmlLocalized(140, 75 + (index * 25), 300, 20, sellList[i].Title, false, false);
				}

				AddButton(100, 75 + (index++ * 25), 4005, 4007, 1 + i, GumpButtonType.Reply, 0);
			}
		}
예제 #20
0
 public BulkOrderInfoEntry(Mobile from, BaseVendor vendor)
     : base(6152)
 {
     m_From   = from;
     m_Vendor = vendor;
 }
예제 #21
0
		public ChangeHairstyleGump(Mobile from, BaseVendor vendor, int price, bool facialHair, ChangeHairstyleEntry[] entries)
			: base(50, 50)
		{
			m_From = from;
			m_Vendor = vendor;
			m_Price = price;
			m_FacialHair = facialHair;
			m_Entries = entries;

			from.CloseGump(typeof(HairstylistBuyGump));
			from.CloseGump(typeof(ChangeHairHueGump));
			from.CloseGump(typeof(ChangeHairstyleGump));

			int tableWidth = (m_FacialHair ? 2 : 3);
			int tableHeight = ((entries.Length + tableWidth - (m_FacialHair ? 1 : 2)) / tableWidth);
			int offsetWidth = 123;
			int offsetHeight = (m_FacialHair ? 70 : 65);

			AddPage(0);

			AddBackground(0, 0, 81 + (tableWidth * offsetWidth), 105 + (tableHeight * offsetHeight), 2600);

			AddButton(45, 45 + (tableHeight * offsetHeight), 4005, 4007, 1, GumpButtonType.Reply, 0);
			AddHtmlLocalized(77, 45 + (tableHeight * offsetHeight), 90, 35, 1006044, false, false); // Ok

			AddButton(
				81 + (tableWidth * offsetWidth) - 180, 45 + (tableHeight * offsetHeight), 4005, 4007, 0, GumpButtonType.Reply, 0);
			AddHtmlLocalized(
				81 + (tableWidth * offsetWidth) - 148, 45 + (tableHeight * offsetHeight), 90, 35, 1006045, false, false); // Cancel

			if (!facialHair)
			{
				AddHtmlLocalized(50, 15, 350, 20, 1018353, false, false); // <center>New Hairstyle</center>
			}
			else
			{
				AddHtmlLocalized(55, 15, 200, 20, 1018354, false, false); // <center>New Beard</center>
			}

			for (int i = 0; i < entries.Length; ++i)
			{
				int xTable = i % tableWidth;
				int yTable = i / tableWidth;

				if (entries[i].GumpID != 0)
				{
					AddRadio(40 + (xTable * offsetWidth), 70 + (yTable * offsetHeight), 208, 209, false, i);
					AddBackground(87 + (xTable * offsetWidth), 50 + (yTable * offsetHeight), 50, 50, 2620);
					AddImage(
						87 + (xTable * offsetWidth) + entries[i].X, 50 + (yTable * offsetHeight) + entries[i].Y, entries[i].GumpID);
				}
				else if (!facialHair)
				{
					AddRadio(40 + ((xTable + 1) * offsetWidth), 240, 208, 209, false, i);
					AddHtmlLocalized(60 + ((xTable + 1) * offsetWidth), 240, 85, 35, 1011064, false, false); // Bald
				}
				else
				{
					AddRadio(40 + (xTable * offsetWidth), 70 + (yTable * offsetHeight), 208, 209, false, i);
					AddHtmlLocalized(60 + (xTable * offsetWidth), 70 + (yTable * offsetHeight), 85, 35, 1011064, false, false); // Bald
				}
			}
		}
예제 #22
0
 public ATailorCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
 {
     m_Vendor = vendor as ATailor;                                        //HERE
     m_Mobile = from;
 }
        public static List<RefillEntry> Refill(Container cont, Type[] itemTypes, BaseVendor vendor, Mobile from, bool Refill, int amount)
        {
            List<RefillEntry> refillEntryList = new List<RefillEntry>();
            RefillEntry refillEntry;

            foreach (Type itemType in itemTypes)
            {
                bool foundReagentInBag = false;

                refillEntry = new RefillEntry();
                refillEntry.ItemType = itemType;

                for (int i = 0; i < cont.Items.Count; i++)
                {
                    Item item = (Item)cont.Items[i];
                    if (itemType == item.GetType())
                    {
                        // Add amount to refill to entry
                        int amountToRefill = amount - item.Amount;
                        refillEntry.AmountToRefill = amountToRefill;

                        // Add price on vendor to entry
                        int priceOnVendor = GetPriceFromVendor(vendor, itemType);
                        refillEntry.PriceOnVendor = priceOnVendor;

                        if (priceOnVendor > 0)
                        {
                            refillEntry.HasVendorGotItem = true;

                            if (Refill)
                                item.Amount += amountToRefill;
                        }
                        else
                        {
                            // Vendor does not have this item
                        }

                        foundReagentInBag = true;
                        break;
                    }
                }

                // We could not find the item in the players bag, create the item
                // and set the amount.
                if (!foundReagentInBag)
                {
                    // Add amount to refill to entry
                    refillEntry.AmountToRefill = amount;

                    // Add price on vendor to entry
                    int priceOnVendor = GetPriceFromVendor(vendor, itemType);
                    refillEntry.PriceOnVendor = priceOnVendor;

                    if (priceOnVendor > 0)
                    {
                        refillEntry.HasVendorGotItem = true;

                        if (Refill)
                            DirectRefillType(cont, itemType, amount);
                    }
                    else
                    {
                        // Vendor does not have this item
                    }
                }

                // Add the entry
                refillEntryList.Add(refillEntry);
            }

            return refillEntryList;
        }
예제 #24
0
			public ABlacksmithCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
			{
				m_Vendor = vendor as ABlacksmith;//HERE
				m_Mobile = from;
			}
예제 #25
0
 public RechargeEntry(Mobile from, BaseVendor vendor)
     : base(6271, 6)
 {
     m_From   = from;
     m_Vendor = vendor;
 }
예제 #26
0
			public ATailorCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
			{
				m_Vendor = vendor as ATailor;//HERE
				m_Mobile = from;
			}
예제 #27
0
			public AAlchemistCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
			{
				m_Vendor = vendor as AAlchemist;//HERE
				m_Mobile = from;
			}
            protected override void OnTarget(Mobile from, object targeted)
            {
                if (targeted is PlayerMobile)
                {
                    PlayerMobile pm = targeted as PlayerMobile;

                    if (pm.Female == false)
                    {
                        m_Jeweler.SayTo(from, "You are a male, not an object. But you do seem like a tough fella.");
                    }
                    else if (pm.Female == true)
                    {
                        m_Jeweler.SayTo(from, "You are a female, not an object and not bad looking either.");
                    }
                    else
                    {
                        m_Jeweler.SayTo(from, "Yeah I'm not touching that with a 10 foot pole.");
                    }
                }

                if (targeted is BaseVendor)
                {
                    BaseVendor bv = targeted as BaseVendor;

                    if (bv.Female == false)
                    {
                        m_Jeweler.SayTo(from, "That person identifies as a male. Want me to pull down their pants?");
                    }
                    else if (bv.Female == true)
                    {
                        m_Jeweler.SayTo(from, "That person identifies as a female. Want me to lift up their shirt?");
                    }
                    else
                    {
                        m_Jeweler.SayTo(from, "They identify as none of your business.");
                    }
                }

                if (targeted is BaseCreature)
                {
                    BaseCreature c = targeted as BaseCreature;

                    if (c.Tamable)
                    {
                        m_Jeweler.SayTo(from, "That creature seems to know its identity already. It doesn't need my help.");
                    }
                    else
                    {
                        m_Jeweler.SayTo(from, "Get that frigging thing away from me before it causes trouble.");
                    }
                }

                if (targeted is BaseWeapon)
                {
                    BaseWeapon bw        = targeted as BaseWeapon;
                    Container  pack      = from.Backpack;
                    int        toConsume = 250;
                    toConsume = 250;

                    if (bw.Identified == true)
                    {
                        m_Jeweler.SayTo(from, "That weapon is already identified.");
                    }
                    else if ((bw.Identified == false) && (pack.ConsumeTotal(typeof(Gold), toConsume)))
                    {
                        Item a = from.Backpack.FindItemByType(typeof(Gold));
                        if (a != null)
                        {
                            a.Consume(toConsume);
                        }

                        bw.Identified = true;
                        m_Jeweler.SayTo(from, "Here is your weapon.");
                        from.SendMessage("You pay 500 gp.");
                        Effects.PlaySound(from.Location, from.Map, 0x2A);
                    }
                    else
                    {
                        m_Jeweler.SayTo(from, "It will cost you 500 gp to have your weapon identified.");
                        from.SendMessage("You do not have enough gold.");
                    }
                }

                else if (targeted is BaseArmor)
                {
                    BaseArmor ba        = targeted as BaseArmor;
                    Container pack      = from.Backpack;
                    int       toConsume = 200;
                    toConsume = 200;

                    if (ba.Identified == true)
                    {
                        m_Jeweler.SayTo(from, "That armor is already identified.");
                    }
                    else if ((ba.Identified == false) && (pack.ConsumeTotal(typeof(Gold), toConsume)))
                    {
                        Item a = from.Backpack.FindItemByType(typeof(Gold));
                        if (a != null)
                        {
                            a.Consume(toConsume);
                        }

                        ba.Identified = true;
                        m_Jeweler.SayTo(from, "Here is your armor.");
                        from.SendMessage("You pay 400 gp.");
                        Effects.PlaySound(from.Location, from.Map, 0x2A);
                    }
                    else
                    {
                        m_Jeweler.SayTo(from, "It will cost you 400 gp to have your armor identified.");
                        from.SendMessage("You do not have enough gold.");
                    }
                }

                else if (targeted is BaseClothing)
                {
                    BaseClothing bc        = targeted as BaseClothing;
                    Container    pack      = from.Backpack;
                    int          toConsume = 150;
                    toConsume = 150;

                    if (bc.Identified == true)
                    {
                        m_Jeweler.SayTo(from, "That clothing is already identified.");
                    }
                    else if ((bc.Identified == false) && (pack.ConsumeTotal(typeof(Gold), toConsume)))
                    {
                        Item a = from.Backpack.FindItemByType(typeof(Gold));
                        if (a != null)
                        {
                            a.Consume(toConsume);
                        }

                        bc.Identified = true;
                        m_Jeweler.SayTo(from, "Here is your clothing.");
                        from.SendMessage("You pay 300 gp.");
                        Effects.PlaySound(from.Location, from.Map, 0x2A);
                    }
                    else
                    {
                        m_Jeweler.SayTo(from, "It will cost you 300 gp to have your clothing identified.");
                        from.SendMessage("You do not have enough gold.");
                    }
                }

                else if (targeted is BaseJewel)
                {
                    BaseJewel bj        = targeted as BaseJewel;
                    Container pack      = from.Backpack;
                    int       toConsume = 100;
                    toConsume = 100;

                    if (bj.Identified == true)
                    {
                        m_Jeweler.SayTo(from, "That jewel is already identified.");
                    }
                    else if ((bj.Identified == false) && (pack.ConsumeTotal(typeof(Gold), toConsume)))
                    {
                        Item a = from.Backpack.FindItemByType(typeof(Gold));
                        if (a != null)
                        {
                            a.Consume(toConsume);
                        }

                        bj.Identified = true;
                        m_Jeweler.SayTo(from, "Here is your jewel.");
                        from.SendMessage("You pay 200 gp.");
                        Effects.PlaySound(from.Location, from.Map, 0x2A);
                    }
                    else
                    {
                        m_Jeweler.SayTo(from, "It will cost you 200 gp to have your jewel identified.");
                        from.SendMessage("You do not have enough gold.");
                    }
                }
                else
                {
                    m_Jeweler.SayTo(from, "That is not something I can identify.");
                }
            }
예제 #29
0
		public VendorBuyEntry(Mobile from, BaseVendor vendor)
			: base(6103, 8)
		{
			this.m_Vendor = vendor;
			this.Enabled = vendor.CheckVendorAccess(from);
		}
예제 #30
0
 public SBTinker(BaseVendor owner)
 {
     m_BuyInfo = new InternalBuyInfo(owner);
 }
예제 #31
0
 public InternalSellBagTarget(BaseVendor vendor)
     : base(1, false, TargetFlags.None)
 {
     m_Vendor = vendor;
 }
예제 #32
0
 public InternalBuyInfo(BaseVendor owner)
 {
     Add(new GenericBuyInfo("Stasis Chamber Power Core", typeof(StasisChamberPowerCore), 101250, 500, 40155, 0));                           // TODO: Get itemid
 }
예제 #33
0
		public VendorBuyEntry(Mobile from, BaseVendor vendor)
			: base(6103, 8)
		{
			m_Vendor = vendor;
		}
예제 #34
0
		public VendorSellEntry(Mobile from, BaseVendor vendor)
			: base(6104, 8)
		{
			m_Vendor = vendor;
		}
예제 #35
0
            protected override void OnTarget(Mobile from, object targeted)
            {
                Container pack = from.Backpack;

                if (targeted is ScrollClue)
                {
                    ScrollClue scroll = (ScrollClue)targeted;

                    int nCost = scroll.ScrollLevel * 100;

                    if (BaseVendor.BeggingPose(from) > 0)                       // LET US SEE IF THEY ARE BEGGING - WIZARD
                    {
                        nCost = nCost - (int)((from.Skills[SkillName.Begging].Value * 0.005) * nCost);
                    }

                    int toConsume = nCost;

                    if (scroll.ScrollIntelligence > 0)
                    {
                        m_GypsyLady.SayTo(from, "That parchment hasn't been deciphered yet.");
                    }
                    else if (pack.ConsumeTotal(typeof(Gold), toConsume))
                    {
                        string WillSay = "";

                        switch (Utility.RandomMinMax(0, 3))
                        {
                        case 0: WillSay = "The spirits tell me that this parchment is"; break;

                        case 1: WillSay = "My mind is showing me that this parchment is"; break;

                        case 2: WillSay = "The voices all speak that this parchment is"; break;

                        case 3: WillSay = "I can see beyond that this parchment is"; break;
                        }

                        if (scroll.ScrollTrue == 1)
                        {
                            m_GypsyLady.SayTo(from, WillSay + " truthfully written.");
                        }
                        else
                        {
                            m_GypsyLady.SayTo(from, WillSay + " falsely written.");
                        }

                        from.SendMessage(String.Format("You pay {0} gold.", toConsume));
                    }
                    else
                    {
                        m_GypsyLady.SayTo(from, "I require {0} gold for my visions.", toConsume);
                    }
                }
                ///////////////////////////////////////////////////////////////////////////////////
                else if (targeted is SearchPage)
                {
                    SearchPage scroll = (SearchPage)targeted;

                    int nCost = (100 - scroll.LegendPercent) * 50;

                    if (BaseVendor.BeggingPose(from) > 0)                       // LET US SEE IF THEY ARE BEGGING - WIZARD
                    {
                        nCost = nCost - (int)((from.Skills[SkillName.Begging].Value * 0.005) * nCost);
                    }

                    int toConsume = nCost;

                    if (pack.ConsumeTotal(typeof(Gold), toConsume))
                    {
                        string WillSay = "";

                        switch (Utility.RandomMinMax(0, 3))
                        {
                        case 0: WillSay = "The spirits tell me that this legend "; break;

                        case 1: WillSay = "My mind is showing me that this legend "; break;

                        case 2: WillSay = "The voices all speak that this legend "; break;

                        case 3: WillSay = "I can see beyond that this legend "; break;
                        }

                        if (scroll.LegendReal == 1)
                        {
                            m_GypsyLady.SayTo(from, WillSay + " really happened.");
                        }
                        else
                        {
                            m_GypsyLady.SayTo(from, WillSay + " never happened.");
                        }

                        from.SendMessage(String.Format("You pay {0} gold.", toConsume));
                    }
                    else
                    {
                        m_GypsyLady.SayTo(from, "I require {0} gold for my visions.", toConsume);
                    }
                }
                ///////////////////////////////////////////////////////////////////////////////////
                else if (targeted is DynamicBook)
                {
                    DynamicBook scroll = (DynamicBook)targeted;

                    int nCost = (scroll.BookPower + 1) * 50;

                    if (BaseVendor.BeggingPose(from) > 0)                       // LET US SEE IF THEY ARE BEGGING - WIZARD
                    {
                        nCost = nCost - (int)((from.Skills[SkillName.Begging].Value * 0.005) * nCost);
                    }

                    int toConsume = nCost;

                    if (pack.ConsumeTotal(typeof(Gold), toConsume))
                    {
                        string WillSay = "";

                        switch (Utility.RandomMinMax(0, 3))
                        {
                        case 0: WillSay = "The spirits tell me that this book "; break;

                        case 1: WillSay = "My mind is showing me that this book "; break;

                        case 2: WillSay = "The voices all speak that this book "; break;

                        case 3: WillSay = "I can see beyond that this book "; break;
                        }

                        if (scroll.BookTrue > 0)
                        {
                            m_GypsyLady.SayTo(from, WillSay + " contains the truth.");
                        }
                        else
                        {
                            m_GypsyLady.SayTo(from, WillSay + " contains falsehoods.");
                        }

                        from.SendMessage(String.Format("You pay {0} gold.", toConsume));
                    }
                    else
                    {
                        m_GypsyLady.SayTo(from, "I require {0} gold for my visions.", toConsume);
                    }
                }
                ///////////////////////////////////////////////////////////////////////////////////
                else if (targeted is SomeRandomNote)
                {
                    SomeRandomNote scroll = (SomeRandomNote)targeted;

                    int nCost = 100;

                    if (BaseVendor.BeggingPose(from) > 0)                       // LET US SEE IF THEY ARE BEGGING - WIZARD
                    {
                        nCost = nCost - (int)((from.Skills[SkillName.Begging].Value * 0.005) * nCost);
                    }

                    int toConsume = nCost;

                    if (pack.ConsumeTotal(typeof(Gold), toConsume))
                    {
                        string WillSay = "";

                        switch (Utility.RandomMinMax(0, 3))
                        {
                        case 0: WillSay = "The spirits tell me that this parchment is"; break;

                        case 1: WillSay = "My mind is showing me that this parchment is"; break;

                        case 2: WillSay = "The voices all speak that this parchment is"; break;

                        case 3: WillSay = "I can see beyond that this parchment is"; break;
                        }

                        if (scroll.ScrollTrue == 1)
                        {
                            m_GypsyLady.SayTo(from, WillSay + " truthfully written.");
                        }
                        else
                        {
                            m_GypsyLady.SayTo(from, WillSay + " falsely written.");
                        }

                        from.SendMessage(String.Format("You pay {0} gold.", toConsume));
                    }
                    else
                    {
                        m_GypsyLady.SayTo(from, "I require {0} gold for my visions.", toConsume);
                    }
                }
                ///////////////////////////////////////////////////////////////////////////////////
                else if (targeted is DataPad)
                {
                    int nCost = 100;

                    if (BaseVendor.BeggingPose(from) > 0)                       // LET US SEE IF THEY ARE BEGGING - WIZARD
                    {
                        nCost = nCost - (int)((from.Skills[SkillName.Begging].Value * 0.005) * nCost);
                    }

                    int toConsume = nCost;

                    if (pack.ConsumeTotal(typeof(Gold), toConsume))
                    {
                        string WillSay = "";

                        switch (Utility.RandomMinMax(0, 3))
                        {
                        case 0: WillSay = "The spirits tell me that this glowing book is"; break;

                        case 1: WillSay = "My mind is showing me that this glowing book is"; break;

                        case 2: WillSay = "The voices all speak that this glowing book is"; break;

                        case 3: WillSay = "I can see beyond that this glowing book is"; break;
                        }

                        m_GypsyLady.SayTo(from, WillSay + " truthfully written.");

                        from.SendMessage(String.Format("You pay {0} gold.", toConsume));
                    }
                    else
                    {
                        m_GypsyLady.SayTo(from, "I require {0} gold for my visions.", toConsume);
                    }
                }
                ///////////////////////////////////////////////////////////////////////////////////
                else
                {
                    m_GypsyLady.SayTo(from, "That is not a parchment.");
                }
            }
예제 #36
0
        public ChangeHairstyleGump(Mobile from, BaseVendor vendor, int price, bool facialHair, ChangeHairstyleEntry[] entries)
            : base(50, 50)
        {
            m_From       = from;
            m_Vendor     = vendor;
            m_Price      = price;
            m_FacialHair = facialHair;
            m_Entries    = entries;

            from.CloseGump(typeof(HairstylistBuyGump));
            from.CloseGump(typeof(ChangeHairHueGump));
            from.CloseGump(typeof(ChangeHairstyleGump));

            int tableWidth   = (m_FacialHair ? 2 : 3);
            int tableHeight  = ((entries.Length + tableWidth - (m_FacialHair ? 1 : 2)) / tableWidth);
            int offsetWidth  = 123;
            int offsetHeight = (m_FacialHair ? 70 : 65);

            AddPage(0);

            AddBackground(0, 0, 81 + (tableWidth * offsetWidth), 105 + (tableHeight * offsetHeight), 2600);

            AddButton(45, 45 + (tableHeight * offsetHeight), 4005, 4007, 1, GumpButtonType.Reply, 0);
            AddHtmlLocalized(77, 45 + (tableHeight * offsetHeight), 90, 35, 1006044, false, false);             // Ok

            AddButton(
                81 + (tableWidth * offsetWidth) - 180, 45 + (tableHeight * offsetHeight), 4005, 4007, 0, GumpButtonType.Reply, 0);
            AddHtmlLocalized(
                81 + (tableWidth * offsetWidth) - 148, 45 + (tableHeight * offsetHeight), 90, 35, 1006045, false, false);                 // Cancel

            if (!facialHair)
            {
                AddHtmlLocalized(50, 15, 350, 20, 1018353, false, false);                 // <center>New Hairstyle</center>
            }
            else
            {
                AddHtmlLocalized(55, 15, 200, 20, 1018354, false, false);                 // <center>New Beard</center>
            }

            for (int i = 0; i < entries.Length; ++i)
            {
                int xTable = i % tableWidth;
                int yTable = i / tableWidth;

                if (entries[i].GumpID != 0)
                {
                    AddRadio(40 + (xTable * offsetWidth), 70 + (yTable * offsetHeight), 208, 209, false, i);
                    AddBackground(87 + (xTable * offsetWidth), 50 + (yTable * offsetHeight), 50, 50, 2620);
                    AddImage(
                        87 + (xTable * offsetWidth) + entries[i].X, 50 + (yTable * offsetHeight) + entries[i].Y, entries[i].GumpID);
                }
                else if (!facialHair)
                {
                    AddRadio(40 + ((xTable + 1) * offsetWidth), 240, 208, 209, false, i);
                    AddHtmlLocalized(60 + ((xTable + 1) * offsetWidth), 240, 85, 35, 1011064, false, false);                     // Bald
                }
                else
                {
                    AddRadio(40 + (xTable * offsetWidth), 70 + (yTable * offsetHeight), 208, 209, false, i);
                    AddHtmlLocalized(60 + (xTable * offsetWidth), 70 + (yTable * offsetHeight), 85, 35, 1011064, false, false);                     // Bald
                }
            }
        }
예제 #37
0
 public ABlacksmithCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
 {
     m_Vendor = vendor as ABlacksmith;                                        //HERE
     m_Mobile = from;
 }
예제 #38
0
 public static void GetContextMenuEntries(Mobile from, BaseVendor vendor, List <ContextMenuEntry> list)
 {
     list.Add(new AAlchemistCancelMenu(from, vendor));
 }
			public AAnimalTrainerCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
			{
				m_Vendor = vendor as AAnimalTrainer;//HERE
				m_Mobile = from;
			}
예제 #40
0
 public InternalBuyInfo(BaseVendor owner)
 {
     Add(new GenericBuyInfo("Unabridged Map of Eodon", typeof(UnabridgedAtlasOfEodon), 62500, 500, 7185, 0));
 }
예제 #41
0
		public VendorSellEntry( Mobile from, BaseVendor vendor )
			: base( 6104, 8 )
		{
			m_Vendor = vendor;
			Enabled = vendor.CheckVendorAccess( from );
		}
예제 #42
0
        public int GetSellPriceFor(Item item, BaseVendor vendor)
        {
            int price;

            m_Table.TryGetValue(item.GetType(), out price);

            if (vendor != null && BaseVendor.UseVendorEconomy)
            {
                IBuyItemInfo buyInfo = null;

                var infos = vendor.GetBuyInfo();

                for (var index = 0; index < infos.Length; index++)
                {
                    IBuyItemInfo info = infos[index];

                    if (info is GenericBuyInfo gbi && gbi.EconomyItem && gbi.Type == item.GetType())
                    {
                        buyInfo = gbi;
                        break;
                    }
                }

                if (buyInfo != null)
                {
                    int sold = buyInfo.TotalSold;

                    price = (int)(buyInfo.Price * .75);

                    return(Math.Max(1, price));
                }
            }

            if (item is BaseArmor armor)
            {
                if (armor.Quality == ItemQuality.Low)
                {
                    price = (int)(price * 0.60);
                }
                else if (armor.Quality == ItemQuality.Exceptional)
                {
                    price = (int)(price * 1.25);
                }

                price += 5 * armor.ArmorAttributes.DurabilityBonus;

                if (price < 1)
                {
                    price = 1;
                }
            }
            else if (item is BaseWeapon weapon)
            {
                if (weapon.Quality == ItemQuality.Low)
                {
                    price = (int)(price * 0.60);
                }
                else if (weapon.Quality == ItemQuality.Exceptional)
                {
                    price = (int)(price * 1.25);
                }

                price += 100 * weapon.WeaponAttributes.DurabilityBonus;

                price += 10 * weapon.Attributes.WeaponDamage;

                if (price < 1)
                {
                    price = 1;
                }
            }
            else if (item is BaseBeverage bev)
            {
                int price1 = price, price2 = price;

                if (bev is Pitcher)
                {
                    price1 = 3;
                    price2 = 5;
                }
                else if (bev is BeverageBottle)
                {
                    price1 = 3;
                    price2 = 3;
                }
                else if (bev is Jug)
                {
                    price1 = 6;
                    price2 = 6;
                }

                if (bev.IsEmpty || bev.Content == BeverageType.Milk)
                {
                    price = price1;
                }
                else
                {
                    price = price2;
                }
            }

            return(price);
        }
예제 #43
0
 public int GetBuyPriceFor(Item item, BaseVendor vendor)
 {
     return((int)(1.90 * GetSellPriceFor(item, vendor)));
 }
예제 #44
0
 public AProvisionerCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
 {
     m_Vendor = vendor as AProvisioner;                                        //HERE
     m_Mobile = from;
 }
        public virtual bool CheckVendorAccess( BaseVendor vendor, Mobile from )
        {
            if ( from.AccessLevel >= AccessLevel.GameMaster || IsDisabled() )
                return true;

            return ( from.Kills < 5 );
        }
예제 #46
0
			public RechargeEntry(Mobile from, BaseVendor vendor)
				: base(6271, 6)
			{
				m_From = from;
				m_Vendor = vendor;
			}
예제 #47
0
        public virtual bool CheckVendorAccess( BaseVendor vendor, Mobile from )
        {
            if ( from.AccessLevel >= AccessLevel.GameMaster || IsDisabled() )
                return true;

            return !IsConstantCandidate( from );
        }
예제 #48
0
			public BulkOrderInfoEntry( Mobile from, BaseVendor vendor )
				: base( 6152 )
			{
				m_From = from;
				m_Vendor = vendor;
			}
예제 #49
0
        public static bool DeliveryArrived(PlayerMobile player, BaseVendor vendor)
        {
            for (int i = 0; i < player.Quests.Count; i ++)
            {
                BaseQuest quest = player.Quests[i];
				
                for (int j = 0; j < quest.Objectives.Count; j ++)
                {
                    BaseObjective objective = quest.Objectives[j];
					
                    if (objective is DeliverObjective)
                    {
                        DeliverObjective deliver = (DeliverObjective)objective;
						
                        if (deliver.Update(vendor))
                        {
                            if (quest.Completed)
                            { 
                                player.SendLocalizedMessage(1046258, null, 0x23); // Your quest is complete.												
                                player.PlaySound(quest.CompleteSound);	
								
                                quest.OnCompleted();
								
                                if (vendor is MondainQuester)
                                    player.SendGump(new MondainQuestGump(player, quest, MondainQuestGump.Section.Complete, false, true, (MondainQuester)vendor));
                                else
                                    player.SendGump(new MondainQuestGump(quest, MondainQuestGump.Section.Complete, false, true));									
                            }
							
                            return true;
                        }
                    }
                }
            }
			
            return false;
        }
예제 #50
0
        public int GetSellPriceFor(Item item, BaseVendor vendor)
        {
            int price = 0;

            m_Table.TryGetValue(item.GetType(), out price);

            if (vendor != null && BaseVendor.UseVendorEconomy)
            {
                IBuyItemInfo buyInfo = vendor.GetBuyInfo().OfType <GenericBuyInfo>().FirstOrDefault(info => info.EconomyItem && info.Type == item.GetType());

                if (buyInfo != null)
                {
                    int sold = buyInfo.TotalSold;
                    price = (int)(buyInfo.Price * .75);

                    return(Math.Max(1, price));
                }
            }

            if (item is BaseArmor)
            {
                BaseArmor armor = (BaseArmor)item;

                if (armor.Quality == ItemQuality.Low)
                {
                    price = (int)(price * 0.60);
                }
                else if (armor.Quality == ItemQuality.Exceptional)
                {
                    price = (int)(price * 1.25);
                }

                price += 100 * (int)armor.Durability;

                price += 100 * (int)armor.ProtectionLevel;

                if (price < 1)
                {
                    price = 1;
                }
            }
            else if (item is BaseWeapon)
            {
                BaseWeapon weapon = (BaseWeapon)item;

                if (weapon.Quality == ItemQuality.Low)
                {
                    price = (int)(price * 0.60);
                }
                else if (weapon.Quality == ItemQuality.Exceptional)
                {
                    price = (int)(price * 1.25);
                }

                price += 100 * (int)weapon.DurabilityLevel;

                price += 100 * (int)weapon.DamageLevel;

                if (price < 1)
                {
                    price = 1;
                }
            }
            else if (item is BaseBeverage)
            {
                int price1 = price, price2 = price;

                if (item is Pitcher)
                {
                    price1 = 3;
                    price2 = 5;
                }
                else if (item is BeverageBottle)
                {
                    price1 = 3;
                    price2 = 3;
                }
                else if (item is Jug)
                {
                    price1 = 6;
                    price2 = 6;
                }

                BaseBeverage bev = (BaseBeverage)item;

                if (bev.IsEmpty || bev.Content == BeverageType.Milk)
                {
                    price = price1;
                }
                else
                {
                    price = price2;
                }
            }

            return(price);
        }
예제 #51
0
        public static void GetContextMenuEntries(Mobile from, BaseVendor vendor, List<ContextMenuEntry> list)
		{
			list.Add( new AProvisionerCancelMenu( from, vendor ) );//HERE
		}
예제 #52
0
			public AProvisionerCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
			{
				m_Vendor = vendor as AProvisioner;//HERE
				m_Mobile = from;
			}
예제 #53
0
 public AAnimalTrainerCancelMenu(Mobile from, BaseVendor vendor) : base(6129, 3) //Dismissal //HERE
 {
     m_Vendor = vendor as AAnimalTrainer;                                        //HERE
     m_Mobile = from;
 }