完善客户端功能并同步差距文档
This commit is contained in:
+6
-5
@@ -62,8 +62,8 @@ func _init() -> void:
|
||||
v.add_child(title)
|
||||
|
||||
_host = _field(v, _loc.t("LOGIN_DEFAULT_SERVERADDR").split(",")[0], "192.168.21.203")
|
||||
_id = _field(v, _loc.t("LOGIN_ID"), "admin")
|
||||
_pw = _field(v, _loc.t("LOGIN_PASSWORD"), "123456789")
|
||||
_id = _field(v, _loc.t("LOGIN_ID"), OS.get_environment("MT_ACCOUNT"))
|
||||
_pw = _field(v, _loc.t("LOGIN_PASSWORD"), OS.get_environment("MT_PASSWORD"))
|
||||
_pw.secret = true
|
||||
|
||||
var btn := Button.new()
|
||||
@@ -143,9 +143,10 @@ func _on_entered_game() -> void:
|
||||
_msg("已进入游戏 —— 加载场景")
|
||||
if _layer:
|
||||
_layer.visible = false
|
||||
if _life: # 让 game_scene 自己的 AppLifecycle 接管
|
||||
_life.queue_free()
|
||||
_life = null
|
||||
# 兼容启动器没有 AppFlow,因此由这里创建的生命周期协调者贯穿
|
||||
# 登录→游戏;GameScene 不再创建第二个协调者,也不能在切屏时销毁它。
|
||||
if _life:
|
||||
_life.bind(_client, _audio)
|
||||
_game = GameScene.new()
|
||||
get_root().add_child(_game)
|
||||
_game.setup(_client, _assets)
|
||||
|
||||
Reference in New Issue
Block a user