void Resend(ESlotType slotType, SlotList.ChangeEvent arg) { switch (arg.op) { case SlotList.ChangeEvent.Op.Set: changeEventor.Dispatch(new EventArg() { op = EventArg.Op.Put, itemObj = GetItem(slotType, arg.index) }); break; case SlotList.ChangeEvent.Op.Reset: changeEventor.Dispatch(new EventArg() { op = EventArg.Op.Reset, itemObj = GetItem(slotType, arg.index) }); break; case SlotList.ChangeEvent.Op.Update: changeEventor.Dispatch(new EventArg() { op = EventArg.Op.Update, itemObj = null }); break; case SlotList.ChangeEvent.Op.Clear: break; case SlotList.ChangeEvent.Op.Sort: break; default: break; } }
void ArmorSlotListMsgHandler(object sender, SlotList.ChangeEvent arg) { Resend(ESlotType.Armor, arg); }
void ResourceSlotListMsgHandler(object sender, SlotList.ChangeEvent arg) { Resend(ESlotType.Resource, arg); }
void EquipmentSlotListMsgHandler(object sender, SlotList.ChangeEvent arg) { Resend(ESlotType.Equipment, arg); }
void ItemSlotListMsgHandler(object sender, SlotList.ChangeEvent arg) { Resend(ESlotType.Item, arg); }