[Bug1000351]Tap退出登录测试

main
yurui 2024-10-29 15:04:45 +08:00
parent 88762be3f2
commit f87d2b9c49
3 changed files with 10 additions and 3 deletions

View File

@ -21,9 +21,11 @@ namespace Gameplay.Net
public class LoginStatusTapTap : LoginStatus
{
public override LoginStatusID ID { get { return LoginStatusID.TapTap; } }
private bool isLogout;
public override void Start()
{
isLogout = false;
}
public override void End()
@ -107,12 +109,17 @@ namespace Gameplay.Net
{
case 500: // 登录成功
{
isLogout = false;
OnLoginSuccess();
}
break;
case 1000:// 用户登出
case 1001:// 切换账号
{
if (!isLogout)
return;
isLogout = true;
Logout();
if (GameStateManager.Instance.GetCurState() is not GameStateStart)
GameStateManager.Instance.ChangeState(new GameStateStart());

View File

@ -39,7 +39,7 @@ namespace PhxhSDK
public void AntiAddictionLeaveGame()
{
Debug.Log("taptap退出合规认证");
//TapTapCompliance.Exit();
TapTapCompliance.Exit();
}
public void LogOutAntiAddiction()

View File

@ -17,6 +17,7 @@ namespace PhxhSDK
return;
isInit = true;
Debug.Log("Tap注册合规认证回调");
TapTapCompliance.RegisterComplianceCallback(callback);
}
@ -37,11 +38,10 @@ namespace PhxhSDK
public void AntiAddictionLeaveGame()
{
Debug.Log("taptap离开游戏");
Debug.Log("taptap退出合规认证");
TapTapCompliance.Exit();
}
public void LogOutAntiAddiction()
{
Debug.Log("taptap退出登录");