public void JudgePay(string context = "") { string extraCommand = "/api/judge/pay"; AntiAddictionJudgePayInput judgePayInput = new AntiAddictionJudgePayInput(); judgePayInput.userId = userId; judgePayInput.id = configId; judgePayInput.context = context; AntiAddictionAuthInfo authInfo = new AntiAddictionAuthInfo(); authInfo.authUserId = userId; authInfo.authKey = ""; authInfo.authUserType = 1102; judgePayInput.authInfo = authInfo; string dataJson = Utils.DeJson.Serialize.From(judgePayInput); SendCommand(extraCommand, 3, dataJson); }
internal void JudgeLogin() { if (PlayerIdentityManager.Current.loginStatus != LoginStatus.LoggedIn) { Debug.LogError("用户尚未登录"); return; } string extraCommand = "/api/judge/login"; AntiAddictionJudgeLoginInput judgeLoginInput = new AntiAddictionJudgeLoginInput(); AntiAddictionAuthInfo authInfo = new AntiAddictionAuthInfo(); authInfo.authUserId = PlayerIdentityManager.Current.userInfo.userId; authInfo.authKey = ""; authInfo.authUserType = 1102; judgeLoginInput.authInfo = authInfo; judgeLoginInput.device = device; judgeLoginInput.id = configId; judgeLoginInput.context = ""; judgeLoginInput.userId = authInfo.authUserId; string dataJson = Utils.DeJson.Serialize.From(judgeLoginInput); SendCommand(extraCommand, 1, dataJson); }