public static void HandleShortcutBarRemove(ShortcutBarRemoveRequestMessage message, WorldClient client) { switch ((ShortcutBarEnum)message.barType) { case ShortcutBarEnum.GENERAL_SHORTCUT_BAR: GeneralShortcutRecord.RemoveShortcut(client.Character.Id, message.slot); break; case ShortcutBarEnum.SPELL_SHORTCUT_BAR: SpellShortcutRecord.RemoveShortcut(client.Character.Id, message.slot); break; } client.Send(new ShortcutBarRemovedMessage(message.barType, message.slot)); }
public void ShortcutBarRemoveRequestMessageFrame(WorldClient client, ShortcutBarRemoveRequestMessage shortcutBarRemoveRequestMessage) { var shortcutsBars = client.ActiveCharacter.CharacterShortcutBars; if (shortcutsBars == null) { return; } var shortcutBar = shortcutsBars.Find(x => x.BarType == (ShortcutBarEnum)shortcutBarRemoveRequestMessage.barType); CharacterShortcutRepository.Instance.RemoveShortcut(shortcutBar, (int)shortcutBarRemoveRequestMessage.slot); client.SendPacket(new ShortcutBarRemovedMessage(shortcutBarRemoveRequestMessage.barType, shortcutBarRemoveRequestMessage.slot)); }
public static void HandleShortcutBarRemove(ShortcutBarRemoveRequestMessage message, WorldClient client) { var bar = client.Character.GetShortcutBar((ShortcutBarEnum)message.barType); bar.RemoveShortcut(message.slot); }
public static void HandleShortcutBarRemoveRequestMessage(WorldClient client, ShortcutBarRemoveRequestMessage message) { client.Character.Shortcuts.RemoveShortcut((ShortcutBarEnum)message.barType, message.slot); }