summaryrefslogtreecommitdiff
path: root/Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QueryBoxs.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QueryBoxs.cs')
-rw-r--r--Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QueryBoxs.cs48
1 files changed, 48 insertions, 0 deletions
diff --git a/Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QueryBoxs.cs b/Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QueryBoxs.cs
new file mode 100644
index 00000000..f5307979
--- /dev/null
+++ b/Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QueryBoxs.cs
@@ -0,0 +1,48 @@
+using System;
+using System.Reflection;
+using KKSG;
+using XMainClient.UI;
+using XUtliPoolLib;
+
+namespace XMainClient
+{
+ internal class Process_RpcC2G_QueryBoxs
+ {
+ public static void OnReply(QueryBoxsArg oArg, QueryBoxsRes oRes)
+ {
+ bool flag = oRes.errorcode == ErrorCode.ERR_INVALID_REQUEST;
+ if (flag)
+ {
+ string fullName = MethodBase.GetCurrentMethod().ReflectedType.FullName;
+ XSingleton<UiUtility>.singleton.OnGetInvalidRequest(fullName);
+ }
+ else
+ {
+ XLevelRewardDocument specificDocument = XDocuments.GetSpecificDocument<XLevelRewardDocument>(XLevelRewardDocument.uuID);
+ ErrorCode errorcode = oRes.errorcode;
+ if (errorcode != ErrorCode.ERR_SUCCESS)
+ {
+ if (errorcode != ErrorCode.ERR_QUERYBOX_TIMELEFT)
+ {
+ if (errorcode != ErrorCode.ERR_INVALID_STATE)
+ {
+ XSingleton<UiUtility>.singleton.ShowSystemTip(oRes.errorcode, "fece00");
+ }
+ }
+ else
+ {
+ specificDocument.SetSelectBoxLeftTime(oRes.timeleft);
+ }
+ }
+ else
+ {
+ specificDocument.SetBoxsInfo(oRes.boxinfos);
+ }
+ }
+ }
+
+ public static void OnTimeout(QueryBoxsArg oArg)
+ {
+ }
+ }
+}