public InternalSellInfo() { Add(typeof(Lute), Lute.GetSBSellValue()); Add(typeof(Drums), Drums.GetSBSellValue()); Add(typeof(Harp), Harp.GetSBSellValue()); Add(typeof(Tambourine), Tambourine.GetSBSellValue()); }
public InternalBuyInfo() { Add(new GenericBuyInfo("Lute", typeof(Lute), Lute.GetSBPurchaseValue(), 50, 0x0EB3, 0)); Add(new GenericBuyInfo("Drums", typeof(Drums), Drums.GetSBPurchaseValue(), 50, 0x0E9C, 0)); Add(new GenericBuyInfo("Harp", typeof(Harp), Harp.GetSBPurchaseValue(), 50, 0x0EB1, 0)); Add(new GenericBuyInfo("Tambourine", typeof(Tambourine), Tambourine.GetSBPurchaseValue(), 50, 0x0E9E, 0)); }
public InternalBuyInfo() { Add(new GenericBuyInfo("Hatchet", typeof(Hatchet), Hatchet.GetSBPurchaseValue(), 50, 0xF43, 0)); Add(new GenericBuyInfo("Saw", typeof(Saw), Saw.GetSBPurchaseValue(), 50, 0x1034, 0)); Add(new GenericBuyInfo("Club", typeof(Club), Club.GetSBPurchaseValue(), 25, 0x13B4, 0)); Add(new GenericBuyInfo("Shepherd's Crook", typeof(ShepherdsCrook), ShepherdsCrook.GetSBPurchaseValue(), 25, 0xE81, 0)); Add(new GenericBuyInfo("Quarter Staff", typeof(QuarterStaff), QuarterStaff.GetSBPurchaseValue(), 25, 0xE89, 0)); Add(new GenericBuyInfo("Gnarled Staff", typeof(GnarledStaff), GnarledStaff.GetSBPurchaseValue(), 25, 0x13F8, 0)); Add(new GenericBuyInfo("Black Staff", typeof(BlackStaff), BlackStaff.GetSBPurchaseValue(), 25, 0xDF0, 0)); Add(new GenericBuyInfo("Wooden Shield", typeof(WoodenShield), WoodenShield.GetSBPurchaseValue(), 25, 7034, 0)); Add(new GenericBuyInfo("Wooden Kite Shield", typeof(WoodenKiteShield), WoodenKiteShield.GetSBPurchaseValue(), 25, 7033, 0)); Add(new GenericBuyInfo("Lute", typeof(Lute), Lute.GetSBPurchaseValue(), 50, 0x0EB3, 0)); Add(new GenericBuyInfo("Drums", typeof(Drums), Drums.GetSBPurchaseValue(), 50, 0x0E9C, 0)); Add(new GenericBuyInfo("Harp", typeof(Harp), Harp.GetSBPurchaseValue(), 50, 0x0EB1, 0)); Add(new GenericBuyInfo("Tambourine", typeof(Tambourine), Tambourine.GetSBPurchaseValue(), 50, 0x0E9E, 0)); Add(new GenericBuyInfo("Scorp", typeof(Scorp), Scorp.GetSBPurchaseValue(), 50, 0x10E7, 0)); Add(new GenericBuyInfo("Smoothing Plane", typeof(SmoothingPlane), SmoothingPlane.GetSBPurchaseValue(), 50, 0x1032, 0)); Add(new GenericBuyInfo("Drawing Knife", typeof(DrawKnife), DrawKnife.GetSBPurchaseValue(), 50, 0x10E4, 0)); Add(new GenericBuyInfo("Froe", typeof(Froe), Froe.GetSBPurchaseValue(), 50, 0x10E5, 0)); Add(new GenericBuyInfo("Hammer", typeof(Hammer), Hammer.GetSBPurchaseValue(), 50, 0x102A, 0)); Add(new GenericBuyInfo("Inshave", typeof(Inshave), Inshave.GetSBPurchaseValue(), 50, 0x10E6, 0)); Add(new GenericBuyInfo("Jointing Plane", typeof(JointingPlane), JointingPlane.GetSBPurchaseValue(), 50, 0x1030, 0)); Add(new GenericBuyInfo("Wooden Plane", typeof(WoodenPlane), WoodenPlane.GetSBPurchaseValue(), 50, 0x102C, 0)); Add(new GenericBuyInfo("Dovetail Saw", typeof(DovetailSaw), DovetailSaw.GetSBPurchaseValue(), 50, 0x1028, 0)); }
public InternalSellInfo() { Add(typeof(Hatchet), Hatchet.GetSBSellValue()); Add(typeof(Saw), Saw.GetSBSellValue()); Add(typeof(Scorp), Scorp.GetSBSellValue()); Add(typeof(SmoothingPlane), SmoothingPlane.GetSBSellValue()); Add(typeof(DrawKnife), DrawKnife.GetSBSellValue()); Add(typeof(Froe), Froe.GetSBSellValue()); Add(typeof(Hammer), Hammer.GetSBSellValue()); Add(typeof(Inshave), Inshave.GetSBSellValue()); Add(typeof(JointingPlane), JointingPlane.GetSBSellValue()); Add(typeof(WoodenPlane), WoodenPlane.GetSBSellValue()); Add(typeof(DovetailSaw), DovetailSaw.GetSBSellValue()); Add(typeof(Lute), Lute.GetSBSellValue()); Add(typeof(Drums), Drums.GetSBSellValue()); Add(typeof(Harp), Harp.GetSBSellValue()); Add(typeof(Tambourine), Tambourine.GetSBSellValue()); Add(typeof(Club), Club.GetSBSellValue()); Add(typeof(ShepherdsCrook), ShepherdsCrook.GetSBSellValue()); Add(typeof(QuarterStaff), QuarterStaff.GetSBSellValue()); Add(typeof(GnarledStaff), GnarledStaff.GetSBSellValue()); Add(typeof(BlackStaff), BlackStaff.GetSBSellValue()); Add(typeof(WoodenShield), WoodenShield.GetSBSellValue()); Add(typeof(WoodenKiteShield), WoodenKiteShield.GetSBSellValue()); /* * Add( typeof( WoodenBox ), 7 ); * Add( typeof( SmallCrate ), 5 ); * Add( typeof( MediumCrate ), 6 ); * Add( typeof( LargeCrate ), 7 ); * Add( typeof( WoodenChest ), 15 ); * * Add( typeof( LargeTable ), 10 ); * Add( typeof( Nightstand ), 7 ); * Add( typeof( YewWoodTable ), 10 ); * Add( typeof( WritingTable ), 9 ); * * Add( typeof( Throne ), 24 ); * Add( typeof( WoodenThrone ), 6 ); * Add( typeof( Stool ), 6 ); * Add( typeof( FootStool ), 6 ); * * Add( typeof( FancyWoodenChairCushion ), 12 ); * Add( typeof( CushionedWoodenChair ), 10 ); * Add( typeof( WoodenChair ), 8 ); * Add( typeof( BambooChair ), 6 ); * Add( typeof( WoodenBench ), 6 ); */ }
public static void PlayLuteMinor_OnCommand(CommandEventArgs e) { Lute inst1 = new Lute(); Lute inst2 = new Lute(); Lute inst3 = new Lute(); if (PlayChord(e.Mobile, e.Arguments, true, inst1, inst2, inst3)) { inst1.Delete(); inst2.Delete(); inst3.Delete(); } }
public static void MultiPlay_OnCommand(CommandEventArgs e) { Harp inst1 = new Harp(); Lute inst2 = new Lute(); LapHarp inst3 = new LapHarp(); if (PlayChord(e.Mobile, e.Arguments, false, inst1, inst2, inst3)) { inst1.Delete(); inst2.Delete(); inst3.Delete(); } }
public override void OnResponse(NetState sender, RelayInfo info) { Mobile from = sender.Mobile; from.CloseGump(typeof(SynthGump)); InstrumentType inst = InstrumentType.Harp; if (info.IsSwitched((int)Buttons.RB2_LapHarp)) { inst = InstrumentType.LapHarp; } if (info.IsSwitched((int)Buttons.RB3_Lute)) { inst = InstrumentType.Lute; } if (info.IsSwitched((int)Buttons.RB4_Drums)) { inst = InstrumentType.Drums; } try { m_Name = info.TextEntries[0].Text.Trim(); } catch { m_Name = "Untitled"; } if (info.ButtonID > 100) { m_Page = info.ButtonID - 100; from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); } else if (info.ButtonID >= (int)Buttons.Track1 && info.ButtonID <= (int)Buttons.Track8) { EditTrack(from); from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); } else if (info.ButtonID >= (int)Buttons.PlayTrack1 && info.ButtonID <= (int)Buttons.PlayTrack8) { int track = info.ButtonID - (int)Buttons.PlayTrack1 + 1; m_Mixer[track] = !m_Mixer[track]; from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); } else if (info.ButtonID == (int)Buttons.PlayTracks) { Container pack = m_From.Backpack; List <BaseInstrument> instruments = new List <BaseInstrument>(); List <XmlMusic> mxm = new List <XmlMusic>(); if (pack == null || pack.Deleted || pack.Items.Count == 0) { from.SendMessage("Your pack is missing or empty!"); } else { foreach (Item i in pack.Items) { if (i is BaseInstrument) { instruments.Add(i as BaseInstrument); } } if (instruments.Count > 0) { XmlMusic findxm = null; for (int x = 0; x < instruments.Count; x++) { if (!m_Mixer[x + 1]) { from.SendMessage("Skipping Track {0}", (int)(x + 1)); continue; } findxm = (XmlMusic)XmlAttach.FindAttachment(instruments[x], typeof(XmlMusic)); if (findxm != null) { try { mxm.Add(findxm); } catch { } } else { from.SendMessage("XmlMusic was null on the {0}", instruments[x].GetType().Name); } } } if (mxm.Count > 0) { Mix.PlayTracks(from, mxm); } else { from.SendMessage("xmx.Count was 0."); } } } else { switch (info.ButtonID) { case (int)Buttons.Quit: break; case (int)Buttons.ShowKeys: from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, !m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; case (int)Buttons.ShowMusic: from.SendGump(new SynthGump(m_From, m_Page, (int)inst, !m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; case (int)Buttons.ShowChords: { m_Chords = !m_Chords; from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; } case (int)Buttons.ShowMixer: { m_Mixer[0] = !m_Mixer[0]; from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; } case (int)Buttons.StartRecording: { if (m_Recording) { from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); } else { m_Song = new List <string>(); m_Song.Add("norm"); from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, true, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); } break; } case (int)Buttons.StopRecording: { if (!m_Recording) { from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); } else { List <string> tempSong = new List <string>(m_Song); string speed = tempSong[0]; tempSong.RemoveAt(0); string[] newSong = tempSong.ToArray(); Play.Play_OnCommand(new CommandEventArgs(from, "Play", speed, newSong)); from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, !m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); } break; } case (int)Buttons.FileOptions: from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, !m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; case (int)Buttons.Play: { List <string> tempSong = new List <string>(m_Song); string speed = tempSong[0]; tempSong.RemoveAt(0); string[] newSong = tempSong.ToArray(); Play.Play_OnCommand(new CommandEventArgs(from, "Play", speed, newSong)); from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; } case (int)Buttons.Save: { SaveSong(from, m_Name, m_Song); from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; } case (int)Buttons.Load: { m_Song = LoadSong(from, m_Name); from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; } case (int)Buttons.Fast: { if (m_Song.Count == 0) { m_Song.Add("fast"); } else if (m_Song[0] == "fast") { m_Song[0] = "veryfast"; } else if (m_Song[0] == "norm") { m_Song[0] = "fast"; } else if (m_Song[0] == "slow") { m_Song[0] = "norm"; } else if (m_Song[0] == "veryslow") { m_Song[0] = "slow"; } from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; } case (int)Buttons.Slow: { if (m_Song.Count == 0) { m_Song.Add("slow"); } else if (m_Song[0] == "slow") { m_Song[0] = "veryslow"; } else if (m_Song[0] == "norm") { m_Song[0] = "slow"; } else if (m_Song[0] == "fast") { m_Song[0] = "norm"; } else if (m_Song[0] == "veryfast") { m_Song[0] = "fast"; } from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; } default: { try { if (m_Song.Count == 0) { m_Song.Add("norm"); } if (m_Chords && info.ButtonID < (int)Buttons.n13_c) { switch ((InstrumentType)inst) { case InstrumentType.Harp: { Harp inst1 = new Harp(); Harp inst2 = new Harp(); Harp inst3 = new Harp(); if (Play.PlayChord(from, new string[] { GetNoteString((NoteValue)(info.ButtonID - 1)) }, true, inst1, inst2, inst3)) { inst1.Delete(); inst2.Delete(); inst3.Delete(); } break; } case InstrumentType.Lute: { Lute inst1 = new Lute(); Lute inst2 = new Lute(); Lute inst3 = new Lute(); if (Play.PlayChord(from, new string[] { GetNoteString((NoteValue)(info.ButtonID - 1)) }, true, inst1, inst2, inst3)) { inst1.Delete(); inst2.Delete(); inst3.Delete(); } break; } case InstrumentType.LapHarp: { LapHarp inst1 = new LapHarp(); LapHarp inst2 = new LapHarp(); LapHarp inst3 = new LapHarp(); if (Play.PlayChord(from, new string[] { GetNoteString((NoteValue)(info.ButtonID - 1)) }, true, inst1, inst2, inst3)) { inst1.Delete(); inst2.Delete(); inst3.Delete(); } break; } case InstrumentType.Drums: break; } } else { NoteValue nv = (NoteValue)(info.ButtonID - 1); Music.PlayNote(from, (int)nv, inst); if (m_Recording) { m_Song.Add(GetNoteString(nv)); //from.SendMessage("Note added to song: #: {0}, string: {1}", nv, GetNoteString(nv)); } } } catch { } from.SendGump(new SynthGump(m_From, m_Page, (int)inst, m_Music, m_Keys, m_Recording, m_FileOptions, m_Chords, m_Mixer, m_Song, m_Name, m_MusicTracks)); break; } } } }
private void Process(Mobile from) { Item rewardItem; switch (m_Skill.SkillID) { case 0: // alchemy rewardItem = new MortarPestle(); break; case 7: // Blacksmithy rewardItem = new GMSmithHammer(); break; case 8: // Bowcraft/fletching rewardItem = new Bow(); break; case 11: // Carpentry switch (m_Itemid) { case 4138: rewardItem = new Hammer(); break; case 4148: rewardItem = new Saw(); break; case 4146: rewardItem = new SmoothingPlane(); break; case 4325: rewardItem = new Froe(); break; case 4326: rewardItem = new Inshave(); break; case 4324: rewardItem = new DrawKnife(); break; default: return; } break; case 23: // Inscription rewardItem = new ScribesPen(); break; case 25: // Magery rewardItem = new Spellbook(); (rewardItem as Spellbook).Content = ulong.MaxValue; (rewardItem as Spellbook).LootType = LootType.Blessed; break; case 34: // Tailoring rewardItem = new RewardDyeTub(); break; case 35: // Animal Taming rewardItem = new ShepherdsCrook(); break; case 44: //Lumberjacking rewardItem = new Hatchet(); break; case 45: // Mining rewardItem = new Pickaxe(); break; //Bardic skills case 9: case 15: case 22: case 29: switch (m_Itemid) { case 3740: rewardItem = new Drums(); break; case 3761: rewardItem = new Harp(); break; case 3762: rewardItem = new LapHarp(); break; case 3763: rewardItem = new Lute(); break; case 3741: rewardItem = new Tambourine(); break; case 3742: rewardItem = new TambourineTassel(); break; default: return; } break; //"Thieving" skills case 21: case 28: case 33: case 47: rewardItem = new Cloak(); break; default: return; } rewardItem.Hue = m_CurrentHue; rewardItem.LootType = LootType.Blessed; if (m_Name != "") { rewardItem.Name = m_Name; } if (rewardItem is RewardDyeTub) { var tub = (RewardDyeTub)rewardItem; tub.DyedHue = rewardItem.Hue; tub.Redyable = false; tub.LootType = LootType.Blessed; tub.Owner = from; } else if (rewardItem is GMSmithHammer) { var hammer = (GMSmithHammer)rewardItem; hammer.Owner = from; } from.AddToBackpack(rewardItem); // Log RewardLogging.WriteLine(from, m_Skill, m_Name, m_CurrentHue); }