diff options
author | chai <chaifix@163.com> | 2021-01-25 14:28:30 +0800 |
---|---|---|
committer | chai <chaifix@163.com> | 2021-01-25 14:28:30 +0800 |
commit | 6eb915c129fc90c6f4c82ae097dd6ffad5239efc (patch) | |
tree | 7dd2be50edf41f36b60fac84696e731c13afe617 /Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QuerySceneTime.cs |
+scripts
Diffstat (limited to 'Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QuerySceneTime.cs')
-rw-r--r-- | Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QuerySceneTime.cs | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QuerySceneTime.cs b/Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QuerySceneTime.cs new file mode 100644 index 00000000..56707392 --- /dev/null +++ b/Client/Assets/Scripts/XMainClient/PTC/Process/Process_RpcC2G_QuerySceneTime.cs @@ -0,0 +1,43 @@ +using System;
+using KKSG;
+using XUtliPoolLib;
+
+namespace XMainClient
+{
+ internal class Process_RpcC2G_QuerySceneTime
+ {
+ public static void OnReply(QuerySceneTimeArg oArg, QuerySceneTimeRes oRes)
+ {
+ bool flag = oRes.errorcode == ErrorCode.ERR_SUCCESS;
+ if (flag)
+ {
+ bool syncMode = XSingleton<XGame>.singleton.SyncMode;
+ if (syncMode)
+ {
+ bool flag2 = XSingleton<XScene>.singleton.SceneType != SceneType.SCENE_CASTLE_WAIT && XSingleton<XScene>.singleton.SceneType != SceneType.SCENE_CASTLE_FIGHT;
+ if (flag2)
+ {
+ XBattleDocument xbattleDoc = XSingleton<XGame>.singleton.Doc.XBattleDoc;
+ XSpectateSceneDocument xspectateSceneDoc = XSingleton<XGame>.singleton.Doc.XSpectateSceneDoc;
+ bool flag3 = oRes.time >= 0;
+ if (flag3)
+ {
+ xbattleDoc.ResetSceneTime(oRes.time);
+ xspectateSceneDoc.ResetSceneTime(oRes.time);
+ }
+ bool flag4 = XSingleton<XScene>.singleton.SceneType == SceneType.SCENE_RIFT;
+ if (flag4)
+ {
+ XRiftDocument specificDocument = XDocuments.GetSpecificDocument<XRiftDocument>(XRiftDocument.uuID);
+ specificDocument.ResSceneTime(oRes.time);
+ }
+ }
+ }
+ }
+ }
+
+ public static void OnTimeout(QuerySceneTimeArg oArg)
+ {
+ }
+ }
+}
|