public override void Invoke(ToolbarState state) { if (state == null) { return; } PlayerMobile user = state.User; if (user == null || user.Deleted || user.NetState == null) { return; } VitaNexCore.TryCatch( () => { if (!user.CanBeginAction(this)) { return; } switch (TextType) { case MessageType.Whisper: user.DoSpeech(FullValue, new int[0], TextType, user.WhisperHue); break; case MessageType.Yell: user.DoSpeech(FullValue, new int[0], TextType, user.YellHue); break; default: user.DoSpeech(FullValue, new int[0], TextType, user.SpeechHue); break; } user.BeginAction(this); Timer.DelayCall(SpamDelay, () => user.EndAction(this)); }, ex => { Console.WriteLine("{0} => {1} => ({2}) => {3}", user, GetType().Name, FullValue, ex); Toolbars.CMOptions.ToConsole(ex); }); }
public override void OnResponse(NetState state, RelayInfo info) { int[] numArray = new int[] { 0x23 }; int[] numArray2 = new int[] { 0x24 }; int[] numArray3 = new int[] { 0x25 }; int[] numArray4 = new int[] { 0x26 }; int[] numArray5 = new int[] { 0x34 }; int[] numArray6 = new int[] { 40 }; if (info.ButtonID == 1) { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*Select the items you wish to Lock Down*", numArray, 0, 20); pm.Say("i wish to lock this down"); } if (info.ButtonID == 2) { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*Select the items you wish to Release*", numArray2, 0, 20); pm.Say("i wish to release this"); } if (info.ButtonID == 3) { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*Select the items you wish to Secure*", numArray3, 0, 20); pm.Say("i wish to secure this"); } if (info.ButtonID == 4) { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*Select the items you wish to remove Security from*", numArray4, 0, 20); pm.Say("i wish to unsecure this"); } if (info.ButtonID == 5) { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*Select who you want to ban*", numArray5, 0, 20); pm.Say("i ban thee"); } if (info.ButtonID == 6) { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*Select the location for a Trash Barrel*", numArray6, 0, 20); pm.Say("i wish to place a trash barrel"); } if (info.ButtonID == 7) { pm.SendMessage("You close the Housing Command Bar."); } }
public override void OnResponse(NetState state, RelayInfo info) { int[] numArray = new int[] { 0x47 }; int[] numArray2 = new int[] { 0x45 }; int[] numArray3 = new int[] { 0x48 }; int[] numArray4 = new int[] { 0x66 }; int[] numArray5 = new int[] { 0x4f }; int[] numArray6 = new int[] { 0x65 }; int[] numArray7 = new int[] { 0x4d }; int[] numArray8 = new int[] { 70 }; int[] numArray9 = new int[] { 0x4e }; int[] numArray10 = new int[] { 0x6a }; int[] numArray11 = new int[] { 0x6b }; if (info.ButtonID == 1) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Move Left*", numArray, 0, 20); pm.Say("left"); } if (info.ButtonID == 2) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Move Forward*", numArray2, 0, 20); pm.Say("forward"); } if (info.ButtonID == 3) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Move Right*", numArray3, 0, 20); pm.Say("right"); } if (info.ButtonID == 4) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Turn Left*", numArray4, 0, 20); pm.Say("turn left"); } if (info.ButtonID == 5) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Stop*", numArray5, 0, 20); pm.Say("stop"); } if (info.ButtonID == 6) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Turn Right*", numArray6, 0, 20); pm.Say("turn right"); } if (info.ButtonID == 7) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Back Left*", numArray7, 0, 20); pm.Say("backward left"); } if (info.ButtonID == 8) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Go Backward*", numArray8, 0, 20); pm.Say("backward"); } if (info.ButtonID == 9) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Back Right*", numArray9, 0, 20); pm.Say("backward right"); } if (info.ButtonID == 10) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Drop Anchor*", numArray10, 0, 20); pm.Say("drop anchor"); } if (info.ButtonID == 11) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*Raise Anchor*", numArray11, 0, 20); pm.Say("raise anchor"); } if (info.ButtonID == 12) { pm.SendMessage("You close the Sailing Command Bar."); } }
public override void OnResponse(NetState state, RelayInfo info) { int[] numArray = new int[] { 0x47 }; int[] numArray2 = new int[] { 0x45 }; int[] numArray3 = new int[] { 0x48 }; int[] numArray4 = new int[] { 0x66 }; int[] numArray5 = new int[] { 0x4f }; int[] numArray6 = new int[] { 0x65 }; int[] numArray7 = new int[] { 0x4d }; int[] numArray8 = new int[] { 70 }; int[] numArray9 = new int[] { 0x4e }; int[] numArray10 = new int[] { 0x6a }; int[] numArray11 = new int[] { 0x6b }; if (info.ButtonID == 1) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*向左移動*", numArray, 0, 20); pm.Say("left"); } if (info.ButtonID == 2) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*向前移動*", numArray2, 0, 20); pm.Say("forward"); } if (info.ButtonID == 3) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*向右移動*", numArray3, 0, 20); pm.Say("right"); } if (info.ButtonID == 4) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*向左轉*", numArray4, 0, 20); pm.Say("turn left"); } if (info.ButtonID == 5) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*停船*", numArray5, 0, 20); pm.Say("stop"); } if (info.ButtonID == 6) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*向右轉*", numArray6, 0, 20); pm.Say("turn right"); } if (info.ButtonID == 7) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*左後方*", numArray7, 0, 20); pm.Say("backward left"); } if (info.ButtonID == 8) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*後退*", numArray8, 0, 20); pm.Say("backward"); } if (info.ButtonID == 9) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*右後方*", numArray9, 0, 20); pm.Say("backward right"); } if (info.ButtonID == 10) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*拋錨*", numArray10, 0, 20); pm.Say("drop anchor"); } if (info.ButtonID == 11) { pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolShip(pm)); pm.DoSpeech("*起錨*", numArray11, 0, 20); pm.Say("raise anchor"); } if (info.ButtonID == 12) { pm.SendMessage("你關閉了開船命令列表."); } }
public override void OnResponse(NetState state, RelayInfo info) { string str = CommandSystem.Prefix; int[] numArray = new int[1]; switch (info.ButtonID) { case 0: break; case 1: pm.CloseGump(typeof(ShowToolTwo)); pm.SendGump(new ShowTool(pm)); return; case 2: pm.CloseGump(typeof(ShowToolThree)); pm.SendGump(new ShowToolTwo(pm)); pm.SendGump(new ShowToolThree(pm)); return; case 3: pm.CloseGump(typeof(StatsGump)); pm.SendGump(new ShowToolTwo(pm)); CommandSystem.Handle(pm, string.Format("{0}mystats", str)); break; case 4: pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolTwo(pm)); pm.SendGump(new ShowToolHouse(pm)); return; case 5: pm.CloseGump(typeof(ShowToolShip)); pm.SendGump(new ShowToolTwo(pm)); pm.SendGump(new ShowToolShip(pm)); return; case 6: pm.CloseGump(typeof(NewsGump)); pm.SendGump(new ShowToolTwo(pm)); pm.DoSpeech("[motd", numArray, 0, 20); return; case 7: pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolTwo(pm)); pm.SendGump(new ShowToolAnimal(pm)); return; case 8: pm.CloseGump(typeof(ShowToolFour)); pm.SendGump(new ShowToolTwo(pm)); pm.SendGump(new ShowToolFour(pm)); return; default: return; } }
public override void OnResponse(NetState state, RelayInfo info) { int[] numArray1 = new int[] { 0x16b }; int[] numArray2 = new int[] { 0x16c }; int[] numArray3 = new int[] { 0x156 }; int[] numArray4 = new int[] { 360 }; int[] numArray5 = new int[] { 0x167 }; int[] numArray6 = new int[] { 0x170 }; int[] numArray7 = new int[] { 0x164 }; int[] numArray8 = new int[] { 8 }; int[] numArray9 = new int[] { 9 }; //int[] numarray = new int[] { 0x16b, 0x16c, 0x156, 360, 0x167, 0x170, 0x164, 8, 9, }; switch (info.ButtonID) { default: case 0: { break; } case 1: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*保护我,宝贝..*", numArray1, 0, 20); break; //pm.DoSpeech("*保护我,宝贝..*", new int [numarray[1]], 0, 20); //pm.Say("all guard me"); } case 2: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*跟我走,宝贝..*", numArray2, 0, 20); break; //pm.Say("all follow me"); } case 3: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*卸载..*", numArray3, 0, 20); pm.Say("all drop"); break; } case 4: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*上吧!..*", numArray4, 0, 20); break; //pm.Say("all kill"); } case 5: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*停止!!*", numArray5, 0, 20); break; //pm.Say("all stop"); } case 6: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*别动!*", numArray6, 0, 20); break; //pm.Say("all stay"); } case 7: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*过来,宝贝!*", numArray7, 0, 20); break; //pm.Say("all come"); } case 8: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*麻烦你 帮我好好照顾它.*", numArray8, 0, 20); pm.Say("stable"); break; } case 9: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); pm.DoSpeech("*取回我的宝贝!* ", numArray9, 0, 20); pm.Say("claim pet"); break; } case 0x16: { pm.CloseGump(typeof(ShowToolpet)); pm.SendGump(new ShowToolpet(pm)); break; //pm.SendMessage("*关闭宠物控制界面.*"); } case 0x17: { pm.SendMessage("*关闭宠物控制界面.*"); break; } } }
public override void OnResponse(NetState state, RelayInfo info) { int[] numArray = new int[] { 0x16b }; int[] numArray2 = new int[] { 0x16c }; int[] numArray3 = new int[] { 0x156 }; int[] numArray4 = new int[] { 360 }; int[] numArray5 = new int[] { 0x167 }; int[] numArray6 = new int[] { 0x170 }; int[] numArray7 = new int[] { 0x164 }; int[] numArray8 = new int[] { 9 }; int[] numArray9 = new int[1]; if (info.ButtonID == 1) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*Protect me, Baby..*", numArray, 0, 20); pm.Say("all guard me"); } if (info.ButtonID == 2) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*Follow me, Babe..*", numArray2, 0, 20); pm.Say("all follow me"); } if (info.ButtonID == 3) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*Go away..*", numArray3, 0, 20); pm.Say("all drop"); } if (info.ButtonID == 4) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*Yo! Go punch that..*", numArray4, 0, 20); pm.Say("all kill"); } if (info.ButtonID == 5) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*Stop, I say!!*", numArray5, 0, 20); pm.Say("all stop"); } if (info.ButtonID == 6) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*I said STAY!*", numArray6, 0, 20); pm.Say("all stay"); } if (info.ButtonID == 7) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*Come On Baby!*", numArray7, 0, 20); pm.Say("all come"); } if (info.ButtonID == 20) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*Take care of my pet.*", numArray9, 0, 20); pm.Say("stable"); } if (info.ButtonID == 0x15) { pm.CloseGump(typeof(ShowToolAnimal)); pm.SendGump(new ShowToolAnimal(pm)); pm.DoSpeech("*I want my pets!*", numArray8, 0, 20); pm.Say("claim all"); } if (info.ButtonID == 0x16) { pm.SendMessage("*You close the Pet Command Bar.*"); } }
public override void OnResponse(NetState state, RelayInfo info) { int[] numArray = new int[] { 0x23 }; int[] numArray2 = new int[] { 0x24 }; int[] numArray3 = new int[] { 0x25 }; int[] numArray4 = new int[] { 0x26 }; int[] numArray5 = new int[] { 0x34 }; int[] numArray6 = new int[] { 40 }; int[] numArray7 = new int[] { 1 }; int[] numArray8 = new int[] { 2 }; int[] numArray9 = new int[] { 0x00 }; switch (info.ButtonID) { default: case 0: { break; } case 1: pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*锁定哪个物件?*", numArray, 0, 20); pm.Say("i wish to lock this down"); break; case 2: { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*释放哪个?物件*", numArray2, 0, 20); pm.Say("i wish to release this"); break; } case 3: { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*保险哪个物件?*", numArray3, 0, 20); pm.Say("i wish to secure this"); break; } case 4: { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*不保险了?*", numArray4, 0, 20); pm.Say("i wish to unsecure this"); break; } case 5: { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*Select who you want to ban*", numArray5, 0, 20); pm.Say("i ban thee"); break; } case 6: { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("*把垃圾桶放在脚下。*", numArray6, 0, 20); pm.Say("i wish to place a trash barrel"); break; } //case 7: // { // pm.CloseGump(typeof(ShowToolHouse)); // pm.SendGump(new ShowToolHouse(pm)); // pm.DoSpeech(" ", numArray7, 0, 20); // // pm.Say("i wish to place a trash barrel"); // break; // } case 8: { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech(" ", numArray8, 0, 20); pm.Say(" open my bank"); break; } case 9: { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("withdraw 5000", numArray9, 0, 20); break; // pm.Say("withdraw"); } case 10: { pm.CloseGump(typeof(ShowToolHouse)); pm.SendGump(new ShowToolHouse(pm)); pm.DoSpeech("withdraw 20000", numArray9, 0, 20); break; // pm.Say(" withdraw"); } case 17: { pm.SendMessage("You close the Housing Command Bar."); break; } } }