Esempio n. 1
0
 public void ReceiveBuyResult(SCarryShopBuy_SC sCarryShopBuy_SC)
 {
     if (sCarryShopBuy_SC.bySucess == 1)
     {
         int            index    = GetCarryShopData(sCarryShopBuy_SC.byIndex);
         DCarryShopUint shopUint = sCarryShopOpenUI_SC.shopUintMap[index];
         shopUint.byIsSale = 1;
         sCarryShopOpenUI_SC.shopUintMap.RemoveAt(index);
         sCarryShopOpenUI_SC.shopUintMap.Insert(index, shopUint);
     }
     UIEventManager.Instance.TriggerUIEvent(UIEventType.RcvCarryShopBuyEvent, sCarryShopBuy_SC.bySucess);
 }
Esempio n. 2
0
 //响应购买
 CommandCallbackType CarryShopBuyResponseHandle(byte[] dataBuffer, int sorketID)
 {
     CarryShopModel.Instance.ReceiveBuyResult(SCarryShopBuy_SC.ParsePackage(dataBuffer));
     return(CommandCallbackType.Continue);
 }
Esempio n. 3
0
    public byte bySucess;              //是否购买成功
    public static SCarryShopBuy_SC ParsePackage(byte[] dataBuffer)
    {
        SCarryShopBuy_SC sCarryShopBuy_SC = PackageHelper.BytesToStuct <SCarryShopBuy_SC>(dataBuffer);

        return(sCarryShopBuy_SC);
    }