public override void OnResponse(NetState sender, RelayInfo info) { if (info.ButtonID != 1) { return; } var from = sender.Mobile; if (!m_Token.IsChildOf(from.Backpack)) { from.SendLocalizedMessage(1062334); // This item must be in your backpack to be used. } else { var i = m_Token.CreateItemFor(from); if (i != null) { from.BankBox.AddItem(i); TextDefinition.SendMessageTo(from, m_Token.ItemReceiveMessage); m_Token.Delete(); } } }
public override void OnResponse(NetState sender, RelayInfo info) { PlayerMobile pm = from as PlayerMobile; if (info.ButtonID == 1) { BankBox bank = from.BankBox; if (bank == null) { return; } Accounting.Account acct = from.Account as Accounting.Account; switch (token.Type) { case PromotionalType.SoulStone: { SoulStone ss = new SoulStone(acct.Username); bank.DropItem(ss); from.SendLocalizedMessage(1070743); // A Soulstone has been created in your bank box! break; } case PromotionalType.SoulStoneFragment: { int offset = Utility.Random(0, 8); SoulStoneFragment ssf = new SoulStoneFragment(0x2AA1 + offset, acct.Username); bank.DropItem(ssf); from.SendLocalizedMessage(1070976); // A soulstone fragment has been created in your bank box. break; } case PromotionalType.AdvancedCharacter: { pm.SendGump(new AdvancedCharacterChoiceGump()); pm.ACState = AdvancedCharacterState.InUse; break; } // TODO: character transfer, seventh anniversary } token.Delete(); } }
public override void OnResponse(GameClient sender, RelayInfo info) { PlayerMobile pm = from as PlayerMobile; if (info.ButtonID == 1) { BankBox bank = from.BankBox; if (bank == null) { return; } Accounting.Account acct = from.Account as Accounting.Account; switch (token.Type) { case PromotionalType.SoulStone: { SoulStone ss = new SoulStone(acct.Username); bank.DropItem(ss); from.SendLocalizedMessage(1070743); // A Soulstone has been created in your bank box! break; } case PromotionalType.BlueSoulstone: { SoulStone ss = new BlueSoulstone(acct.Username); bank.DropItem(ss); from.SendMessage("A Blue Soulstone has been created in your bank box!"); break; } case PromotionalType.SoulStoneFragment: { int offset = Utility.Random(0, 8); SoulStoneFragment ssf = new SoulStoneFragment(0x2AA1 + offset, acct.Username); bank.DropItem(ssf); from.SendLocalizedMessage(1070976); // A soulstone fragment has been created in your bank box. break; } case PromotionalType.AdvancedCharacter: { pm.SendGump(new AdvancedCharacterChoiceGump()); pm.ACState = AdvancedCharacterState.InUse; break; } case PromotionalType.SeventhAnniversary: { //Cerramos algún posible gump abierto (exploit arreglado) if (!pm.HasGump(typeof(SeventhAniversaryGump))) { pm.SendGump(new SeventhAniversaryGump(token)); } break; } case PromotionalType.EighthAnniversary: { //Cerramos algún posible gump abierto (exploit arreglado) if (!pm.HasGump(typeof(EighthAnniversaryGump))) { pm.SendGump(new EighthAnniversaryGump(token)); } break; } case PromotionalType.BrokenFurniture: { //Cerramos algún posible gump abierto (exploit arreglado) if (!pm.HasGump(typeof(BrokenFurnitureGump))) { pm.SendGump(new BrokenFurnitureConfirmGump(token)); } break; } case PromotionalType.HeritageItems: { //Cerramos algún posible gump abierto (exploit arreglado) if (!pm.HasGump(typeof(HeritageItemsGump))) { pm.SendGump(new HeritageItemsConfirmGump(token)); } break; } case PromotionalType.EvilHomeDecoration: { //Cerramos algún posible gump abierto (exploit arreglado) if (!pm.HasGump(typeof(EvilHomeDecorationGump))) { pm.SendGump(new EvilHomeDecorationConfirmGump(token)); } break; } // TODO: character transfer } if (token.Type != PromotionalType.SeventhAnniversary && token.Type != PromotionalType.EighthAnniversary) { token.Delete(); } } }