public uint Execute(PacketDistributed ipacket) { CG_RESTAURANT_PREPAREFOOD packet = (CG_RESTAURANT_PREPAREFOOD )ipacket; if (null == packet) { return((uint)PACKET_EXE.PACKET_EXE_ERROR); } //enter your logic return((uint)PACKET_EXE.PACKET_EXE_CONTINUE); }
// 上菜操作 public void OnChooseFoodFinish(int foodID) { if (!m_bSelfData) { GUIData.AddNotifyData("#{2017}"); return; } if (m_FoodWindow != null) { m_FoodWindow.SetActive(false); } GameManager.gameManager.SoundManager.PlaySoundEffect(134); CG_RESTAURANT_PREPAREFOOD packet = (CG_RESTAURANT_PREPAREFOOD)PacketDistributed.CreatePacket(MessageID.PACKET_CG_RESTAURANT_PREPAREFOOD); if (null != m_curOperationDesk) { packet.SetDeskIndex(m_curOperationDesk.Index); m_curOperationDesk = null; } packet.SetFoodID(foodID); packet.SendPacket(); }