public static void GiveAntique(Museums antique, Mobile vendor, Mobile player) { string say = "Thank you!"; int cost = Museums.AntiqueTotalValue(antique.ThisValue, player, true); switch (Utility.RandomMinMax(0, 9)) { case 0: say = "I have been looking for something like this. Here is " + cost.ToString() + " gold for you."; break; case 1: say = "I have heard of this item before. Here is " + cost.ToString() + " gold for you."; break; case 2: say = "I never thought I would see one of these. Here is " + cost.ToString() + " gold for you."; break; case 3: say = "I have never seen one of these. Here is " + cost.ToString() + " gold for you."; break; case 4: say = "What a rare item. Here is " + cost.ToString() + " gold for you."; break; case 5: say = "This is quite rare. Here is " + cost.ToString() + " gold for you."; break; case 6: say = "This will go nicely in my museum. Here is " + cost.ToString() + " gold for you."; break; case 7: say = "I have only heard tales about such items. Here is " + cost.ToString() + " gold for you."; break; case 8: say = "How did you come across this? Here is " + cost.ToString() + " gold for you."; break; case 9: say = "Where did you find this? Here is " + cost.ToString() + " gold for you."; break; } player.SendSound(0x2E6); player.SendMessage("You receive " + cost + " gold."); player.AddToBackpack(new Gold(cost)); antique.Delete(); vendor.PrivateOverheadMessage(MessageType.Regular, 1153, false, say, player.NetState); }
public static bool FoundItem(Mobile player, int type) { Item item = player.Backpack.FindItemByType(typeof(MuseumBook)); MuseumBook book = (MuseumBook)item; if (type == book.RumorGoal && book.RumorDungeon == Server.Misc.Worlds.GetRegionName(player.Map, player.Location) && book.ArtOwner == player && GetNext(book) < 100) { if (Utility.RandomMinMax(1, 3) != 1) { int thing = GetNext(book); string say = AntiqueInfo(thing, 4, book); Museums relic = new Museums(); relic.ItemID = Int32.Parse(AntiqueInfo(thing, 1, book)); relic.Hue = Int32.Parse(AntiqueInfo(thing, 3, book)); if (relic.ItemID == 0x4FA4) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FC9) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x5328) { relic.Hue = Utility.RandomList(0, 0x4A7, 0x747, 0x96C, 0x7DA, 0x415, 0x908, 0x712, 0x1CD, 0x9C2, 0x843, 0x750, 0xA94, 0x973, 0xA3A); } else if (relic.ItemID == 0x4FA9) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FBD) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FBB) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FBE) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FA7) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FC2) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FC6) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x0FF5) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4B45) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FA6) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x4FAB) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x5327) { relic.Hue = Utility.RandomList(0, 0x4A7, 0x747, 0x96C, 0x7DA, 0x415, 0x908, 0x712, 0x1CD, 0x9C2, 0x843, 0x750, 0xA94, 0x973, 0xA3A); } else if (relic.ItemID == 0x47E6) { MaterialInfo.ColorMetal(relic, 0); } else if (relic.ItemID == 0x530A) { relic.Hue = Utility.RandomColor(0); } relic.Name = AntiqueInfo(thing, 4, book); relic.DiscoverName = player.Name; relic.DiscoverOwner = player; relic.ThisDescription = AntiqueInfo(thing, 5, book); relic.ThisValue = book.ItemValue; if (AntiqueInfo(thing, 6, book) == "1") { relic.Light = LightType.Circle150; } else if (AntiqueInfo(thing, 6, book) == "2") { relic.Light = LightType.Circle300; } player.AddToBackpack(relic); player.LocalOverheadMessage(MessageType.Emote, 1150, true, "You found the " + say + "."); player.SendSound(0x5B4); book.RumorWorld = ""; book.RumorDungeon = ""; book.RumorGoal = 0; book.RumorFrom = ""; book.ItemValue = 0; SetInventory(book, thing); return(true); } else { player.LocalOverheadMessage(MessageType.Emote, 1150, true, book.RumorFrom + " was either wrong or they lied."); player.SendSound(0x5B3); book.RumorWorld = ""; book.RumorDungeon = ""; book.RumorGoal = 0; book.RumorFrom = ""; book.ItemValue = 0; return(false); } } return(false); }
public override void OnDoubleClick(Mobile from) { if (IsChildOf(from.Backpack)) { int cost = Museums.AntiqueTotalValue(ThisValue, from, false); from.SendMessage("This antique is worth " + cost + " gold to an art collector."); } else { if (ItemID == 0x52FC) { ItemID = 0x0481; Light = LightType.Circle300; from.SendSound(0x4A); } else if (ItemID == 0x0481) { ItemID = 0x52FC; Light = LightType.Empty; from.SendSound(0x4A); } else if (ItemID == 0x5354) { ItemID = 0x5351; Light = LightType.Circle300; from.SendSound(0x47); } else if (ItemID == 0x5351) { ItemID = 0x5354; Light = LightType.Empty; from.SendSound(0x3be); } else if (ItemID == 0x5355) { ItemID = 0x5356; Light = LightType.Circle150; from.SendSound(0x47); } else if (ItemID == 0x5356) { ItemID = 0x5355; Light = LightType.Empty; from.SendSound(0x3be); } else if (ItemID == 0x535C) { ItemID = 0x535D; Light = LightType.Circle150; from.SendSound(0x47); } else if (ItemID == 0x535D) { ItemID = 0x535C; Light = LightType.Empty; from.SendSound(0x3be); } else if (ItemID == 0x5363) { ItemID = 0x5364; Light = LightType.Circle150; from.SendSound(0x47); } else if (ItemID == 0x5364) { ItemID = 0x5363; Light = LightType.Empty; from.SendSound(0x3be); } else if (ItemID == 0x5367) { ItemID = 0x5368; Light = LightType.Circle150; from.SendSound(0x47); } else if (ItemID == 0x5368) { ItemID = 0x5367; Light = LightType.Empty; from.SendSound(0x3be); } else if (ItemID == 0x5320) { ItemID = 0x5321; Light = LightType.Circle300; from.SendSound(0x208); } else if (ItemID == 0x5321) { ItemID = 0x5320; Light = LightType.Empty; from.SendSound(0x3be); } else if (ItemID == 0x539F) { ItemID = 0x53A0; Light = LightType.Circle300; from.SendSound(0x208); } else if (ItemID == 0x53A0) { ItemID = 0x539F; Light = LightType.Empty; from.SendSound(0x3be); } } }