/// <summary> /// 获取抽奖记录 /// </summary> /// <param name="call"></param> public void SendGetPrizeRecord(CallBack <List <RecordInfo> > call) { NetProcess.SendRequest <int>(0, ProtoIdMap.CMD_sendGetPrizeRecord, (msg) => { GetDrawRecord data = msg.Read <GetDrawRecord>(); if (data.code == 1 && call != null) { call(data.data.recordInfo); } else { Global.Inst.GetController <CommonTipsController>().ShowTips(CodeErrorTips.GetTips(data.code, data.desc)); } }); }
/// <summary> /// 抽奖返回 /// </summary> /// <param name="call"></param> public void SendPrizeBack(CallBack <DrawBackData> call) { NetProcess.SendRequest <int>(0, ProtoIdMap.CMD_sendPrizeBack, (msg) => { DrawBack data = msg.Read <DrawBack>(); if (data.code == 1) { if (call != null) { call(data.data); } } else { Global.Inst.GetController <CommonTipsController>().ShowTips(CodeErrorTips.GetTips(data.code, data.desc)); } }); }
/// <summary> /// 显示错误提示 /// </summary> /// <param name="code"></param> public static void ShowErrorTips(int code) { Global.Inst.GetController <CommonTipsController>().ShowTips(CodeErrorTips.GetTips(code)); }