コード例 #1
0
ファイル: FakePacketHelper.cs プロジェクト: slb1988/agame
        public static GetGachaDisplayRsp GetFakeGetGachaDisplayRsp()
        {
            GetGachaDisplayRsp rsp = new GetGachaDisplayRsp();

            rsp.set_retcode(0);
            rsp.set_hcoin_gacha_data(new HcoinGachaData());
            rsp.get_hcoin_gacha_data().set_common_data(new GachaDisplayCommonData());
            rsp.set_friends_point_gacha_data(new FriendsPointGachaData());
            rsp.get_friends_point_gacha_data().set_friends_point_cost(1);
            rsp.get_friends_point_gacha_data().set_common_data(new GachaDisplayCommonData());
            return(rsp);
        }
コード例 #2
0
ファイル: GachaModule.cs プロジェクト: slb1988/agame
 private bool OnGetGachaDisplayRsp(GetGachaDisplayRsp rsp)
 {
     if (rsp.get_retcode() == null)
     {
         if (this._gachaDisplayInfo == null)
         {
             this._gachaDisplayInfo = new GachaDisplayInfo();
         }
         this._gachaDisplayInfo.hcoinGachaData       = rsp.get_hcoin_gacha_data();
         this._gachaDisplayInfo.specialGachaData     = (rsp.get_special_hcoin_gacha_data_list().Count <= 0) ? null : rsp.get_special_hcoin_gacha_data_list()[0];
         this._gachaDisplayInfo.friendPointGachaData = rsp.get_friends_point_gacha_data();
         this._lastCheckGachaInfoTime = TimeUtil.Now;
     }
     return(false);
 }