| | |
| | | #这里只做初始化逻辑
|
| | | #在玩家切换场景的时候, 不会调用到这里
|
| | | curPlayer = GameWorld.GetPlayerManager().GetPlayerByIndex(index)
|
| | | InitLoginPlayer(curPlayer, tick)
|
| | | DoPlayerLogin(curPlayer, tick)
|
| | | try:
|
| | | InitLoginPlayer(curPlayer, tick)
|
| | | DoPlayerLogin(curPlayer, tick)
|
| | | |
| | | #锁住玩家, 等到读取地图成功, 再解锁
|
| | | curPlayer.SetCanMove(False)
|
| | | |
| | | #登陆发图形验证码
|
| | | PlayerAutoCheckOnline.PlayerLoginCaptcha(curPlayer, tick)
|
| | | except:
|
| | | curPlayer.Kick(IPY_GameWorld.disWaitForPlayerLoinError)
|
| | | import traceback
|
| | | GameWorld.ErrLog("玩家上线逻辑错误~~~~~\r\n%s" % traceback.format_exc())
|
| | | if GameWorld.GetGameWorld().GetDebugLevel():
|
| | | raise Exception("玩家上线逻辑错误~~~~\r\n%s" % traceback.format_exc())
|
| | | return
|
| | |
|
| | | #锁住玩家, 等到读取地图成功, 再解锁
|
| | | curPlayer.SetCanMove(False)
|
| | | |
| | | #登陆发图形验证码
|
| | | PlayerAutoCheckOnline.PlayerLoginCaptcha(curPlayer, tick)
|
| | |
|
| | | #---------------------------------------------------------------------
|
| | | ##C++封包触发, 玩家切换地图的时候, 在本地图登录
|
| | |
| | | import traceback
|
| | | GameWorld.ErrLog("玩家下线逻辑错误~~~~~\r\n%s" % traceback.format_exc())
|
| | | if GameWorld.GetGameWorld().GetDebugLevel():
|
| | | raise Exception("玩家下线~~~~~\r\n%s" % traceback.format_exc())
|
| | | raise Exception("玩家下线逻辑错误~~~~~\r\n%s" % traceback.format_exc())
|
| | |
|
| | | #调用底层使玩家下线
|
| | | curPlayer.DoDisconnect(tick)
|