public void Prospect(Mobile from, object toProspect) { if (!IsChildOf(from.Backpack) && Parent != from) { from.SendLocalizedMessage(1042001); // That must be in your pack for you to use it. return; } HarvestSystem system = Mining.System; int tileID; Map map; Point3D loc; if (!system.GetHarvestDetails(from, this, toProspect, out tileID, out map, out loc)) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestDefinition def = system.GetDefinition(tileID); if (def == null || def.Veins.Length <= 1) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestBank bank = def.GetBank(map, loc.X, loc.Y); if (bank == null) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestVein vein = bank.Vein, defaultVein = bank.DefaultVein; if (vein == null || defaultVein == null) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } else if (vein != defaultVein) { from.SendLocalizedMessage(1049049); // That ore looks to be prospected already. return; } int veinIndex = Array.IndexOf(def.Veins, vein); if (veinIndex < 0) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. } else if (veinIndex >= (def.Veins.Length - 1)) { from.SendLocalizedMessage(1049061); // You cannot improve valorite ore through prospecting. } else { bank.Vein = def.Veins[veinIndex + 1]; from.SendLocalizedMessage(1049050 + veinIndex); --UsesRemaining; if (UsesRemaining <= 0) { from.SendLocalizedMessage(1049062); // You have used up your prospector's tool. Delete(); } } }
public void Prospect(Mobile from, object toProspect) { if (!IsChildOf(from.Backpack) && Parent != from) { from.SendLocalizedMessage(1042001); // That must be in your pack for you to use it. return; } HarvestSystem system = Mining.System; int tileID; Map map; Point3D loc; if (!system.GetHarvestDetails(from, this, toProspect, out tileID, out map, out loc)) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestDefinition def = system.GetDefinition(tileID); if (def == null || def.Veins.Length <= 1) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestBank bank = def.GetBank(map, loc.X, loc.Y); if (bank == null) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestVein vein = bank.Vein, defaultVein = bank.DefaultVein; if (vein == null || defaultVein == null) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } else if (vein != defaultVein) { from.SendLocalizedMessage(1049049); // That ore looks to be prospected already. return; } int veinIndex = Array.IndexOf(def.Veins, vein); if (veinIndex < 0) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. } else if (veinIndex >= (def.Veins.Length - 1)) { //from.SendLocalizedMessage( 1049061 ); // You cannot improve valorite ore through prospecting. from.SendMessage("You cannot improve Sunstone ore through prospecting."); } else { bank.Vein = def.Veins[veinIndex + 1]; //from.SendLocalizedMessage( 1049050 + veinIndex ); switch (veinIndex) { case 0: from.SendLocalizedMessage(1049050); break; // dull copper case 1: from.SendLocalizedMessage(1049051); break; // shadow iron case 2: from.SendLocalizedMessage(1049052); break; // copper case 3: from.SendLocalizedMessage(1049053); break; // bronze case 4: from.SendLocalizedMessage(1049054); break; // gold case 5: from.SendLocalizedMessage(1049055); break; // agapite case 6: from.SendLocalizedMessage(1049056); break; // verite case 7: from.SendLocalizedMessage(1049057); break; // valorite //case 8: from.SendMessage ( "You sift through the ore and find platinum ore can be mined there!" ); break; //case 9: from.SendMessage ( "You sift through the ore and find that mythril ore can be mined there!" ); break; case 8: from.SendMessage("You sift through the ore and find silver ore can be mined there!"); break; //case 11: from.SendMessage ( "You sift through the ore and find that obsidian ore can be mined there!" ); break; case 9: from.SendMessage("You sift through the ore and find that jade ore can be mined there!"); break; case 10: from.SendMessage("You sift through the ore and find that moonstone ore can be mined there!"); break; case 11: from.SendMessage("You sift through the ore and find that sunstone ore can be mined there!"); break; //case 15: from.SendMessage ( "You sift through the ore and find that bloodstone ore can be mined there!" ); break; } --UsesRemaining; if (UsesRemaining <= 0) { from.SendLocalizedMessage(1049062); // You have used up your prospector's tool. Delete(); } } }
public void Prospect(Mobile from, object toProspect) { if (!IsChildOf(from.Backpack) && Parent != from) { from.SendLocalizedMessage(1042001); // That must be in your pack for you to use it. return; } HarvestSystem system = Lumberjacking.System; int tileID; Map map; Point3D loc; if (!system.GetHarvestDetails(from, this, toProspect, out tileID, out map, out loc)) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestDefinition def = system.GetDefinition(tileID); if (def == null || def.Veins.Length <= 1) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestBank bank = def.GetBank(map, loc.X, loc.Y); if (bank == null) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestVein vein = bank.Vein, defaultVein = bank.DefaultVein; if (vein == null || defaultVein == null) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } else if (vein != defaultVein) { from.SendLocalizedMessage(1049049); // That ore looks to be prospected already. return; } int veinIndex = Array.IndexOf(def.Veins, vein); if (veinIndex < 0) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. } else if (veinIndex >= (def.Veins.Length - 1)) { if (veinIndex >= (def.Veins.Length - 1)) { from.SendMessage("You cannot improve frostwood through prospecting."); } else { bank.Vein = def.Veins[veinIndex + 1]; switch (veinIndex) { case 0: from.SendMessage("You sift through the tree and find oak wood can be lumberjacked there"); break; //Pine case 1: from.SendMessage("You sift through the tree and find ash wood can be lumberjacked there"); break; //Ash case 2: from.SendMessage("You sift through the tree and find yew wood can be lumberjacked there"); break; //Mohogany case 3: from.SendMessage("You sift through the tree and find heartwood wood can be lumberjacked there"); break; //Yew case 4: from.SendMessage("You sift through the tree and find bloodwood can be lumberjacked there"); break; //Oak case 5: from.SendMessage("You sift through the tree and find frostwood wood can be lumberjacked there"); break; //Zircote } --UsesRemaining; if (UsesRemaining <= 0) { from.SendLocalizedMessage(1049062); // You have used up your prospector's tool. Delete(); } } } }
public void Prospect(Mobile from, object toProspect) { if (!this.IsChildOf(from.Backpack) && this.Parent != from) { from.SendLocalizedMessage(1042001); // That must be in your pack for you to use it. return; } HarvestSystem system = Mining.System; int tileID; Map map; Point3D loc; if (!system.GetHarvestDetails(from, this, toProspect, out tileID, out map, out loc)) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestDefinition def = system.GetDefinition(tileID); if (def == null || def.Veins.Length <= 1) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestBank bank = def.GetBank(map, loc.X, loc.Y); if (bank == null) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } HarvestVein vein = bank.Vein, defaultVein = bank.DefaultVein; if (vein == null || defaultVein == null) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. return; } //else if (vein != defaultVein) //daat99 OWLTR start - prospected sticks else if (vein != defaultVein || (OWLTROptionsManager.IsEnabled(OWLTROptionsManager.OPTIONS_ENUM.DAAT99_MINING) && (bank.Vein).IsProspected)) //daat99 OWLTR end - prospected sticks { from.SendLocalizedMessage(1049049); // That ore looks to be prospected already. return; } int veinIndex = Array.IndexOf(def.Veins, vein); if (veinIndex < 0) { from.SendLocalizedMessage(1049048); // You cannot use your prospector tool on that. } // else if (veinIndex >= (def.Veins.Length - 1)) // { // from.SendLocalizedMessage(1049061); // You cannot improve valorite ore through prospecting. // } //daat99 OWLTR start - prospecting else if (!OWLTROptionsManager.IsEnabled(OWLTROptionsManager.OPTIONS_ENUM.DAAT99_MINING)) { if (veinIndex >= (def.Veins.Length - 1)) { from.SendMessage("You cannot improve Platinum ore through prospecting."); // You cannot improve valorite ore through prospecting. } else { bank.Vein = def.Veins[veinIndex + 1]; //from.SendLocalizedMessage( 1049050 + veinIndex ); switch (veinIndex) { case 0: from.SendLocalizedMessage(1049050); break;//Dull Copper case 1: from.SendLocalizedMessage(1049051); break;//Shadow Iron case 2: from.SendLocalizedMessage(1049052); break;//Copper case 3: from.SendLocalizedMessage(1049053); break;//Bronze case 4: from.SendLocalizedMessage(1049054); break;//Gold case 5: from.SendLocalizedMessage(1049055); break;//Agapite case 6: from.SendLocalizedMessage(1049056); break;//Verite case 7: from.SendLocalizedMessage(1049057); break;//Valorite case 8: from.SendMessage("You sift through the ore and find blaze ore can be mined there"); break; case 9: from.SendMessage("You sift through the ore and find ice ore can be mined there"); break; case 10: from.SendMessage("You sift through the ore and find toxic ore can be mined there"); break; case 11: from.SendMessage("You sift through the ore and find electrum ore can be mined there"); break; case 12: from.SendMessage("You sift through the ore and find platinum ore can be mined there"); break; } --UsesRemaining; if (UsesRemaining <= 0) { from.SendLocalizedMessage(1049062); // You have used up your prospector's tool. Delete(); } } } else { (bank.Vein).IsProspected = true; from.SendMessage("You sift through the ore increasing your chances to find better ores"); //daat99 OWLTR end - prospecting // bank.Vein = def.Veins[veinIndex + 1]; // from.SendLocalizedMessage(1049050 + veinIndex); --this.UsesRemaining; if (this.UsesRemaining <= 0) { from.SendLocalizedMessage(1049062); // You have used up your prospector's tool. this.Delete(); } } }
public void Prospect(Mobile from, object toProspect) { if (!IsChildOf(from.Backpack) && Parent != from) { from.SendAsciiMessage("That must be in your pack for you to use it."); return; } HarvestSystem system = Mining.System; int tileID; Map map; Point3D loc; if (!system.GetHarvestDetails(from, this, toProspect, out tileID, out map, out loc)) { from.SendAsciiMessage("You cannot use your prospector tool on that."); // return; } HarvestDefinition def = system.GetDefinition(tileID); if (def == null || def.Veins.Length <= 1) { from.SendAsciiMessage("You cannot use your prospector tool on that."); // return; } HarvestBank bank = def.GetBank(map, loc.X, loc.Y); if (bank == null) { from.SendAsciiMessage("You cannot use your prospector tool on that."); // return; } HarvestVein vein = bank.Vein, defaultVein = bank.DefaultVein; if (vein == null || defaultVein == null) { from.SendAsciiMessage("You cannot use your prospector tool on that."); // return; } else if (vein != defaultVein) { from.SendAsciiMessage("That ore looks to be prospected already."); // return; } int veinIndex = Array.IndexOf(def.Veins, vein); if (veinIndex < 0) { from.SendAsciiMessage("You cannot use your prospector tool on that."); // } else if (veinIndex >= (def.Veins.Length - 1)) { from.SendAsciiMessage("You cannot improve valorite ore through prospecting."); // } else { bank.Vein = def.Veins[veinIndex + 1]; if (veinIndex == 0) { from.SendAsciiMessage("You sift through the ore and find dull copper can be mined there."); } else if (veinIndex == 1) { from.SendAsciiMessage("You sift through the ore and find shadow iron can be mined there."); } else if (veinIndex == 2) { from.SendAsciiMessage("You sift through the ore and find copper ore can be mined there."); } else if (veinIndex == 3) { from.SendAsciiMessage("You sift through the ore and find bronze can be mined there."); } else if (veinIndex == 4) { from.SendAsciiMessage("You sift through the ore and find gold ore can be mined there."); } else if (veinIndex == 5) { from.SendAsciiMessage("You sift through the ore and find agapite can be mined there."); } else if (veinIndex == 6) { from.SendAsciiMessage("You sift through the ore and find verite can be mined there."); } else if (veinIndex == 7) { from.SendAsciiMessage("You sift through the ore and find valorite can be mined there."); } else { from.SendAsciiMessage("bug"); } --UsesRemaining; if (UsesRemaining <= 0) { from.SendAsciiMessage("You have used up your prospector's tool."); // Delete(); } } }