完善客户端功能并同步差距文档

This commit is contained in:
shenlei
2026-09-03 18:40:01 +09:00
parent f93a172296
commit 13ccb8d02d
135 changed files with 21881 additions and 1259 deletions
+13
View File
@@ -3,6 +3,7 @@
extends SceneTree
const PlayerView = preload("res://ui/player_view.gd")
const Audio = preload("res://audio.gd")
var _fail := 0
@@ -33,6 +34,17 @@ func _run() -> void:
_ck(pv.build(assets, 0), "warrior PlayerView builds")
if pv.anim == null:
return
await process_frame
var body_mesh := pv.model.get_node_or_null("MeshInstance3D") as MeshInstance3D
var body_layer := body_mesh.get_layer_mask() if body_mesh != null else 0
_ck(body_mesh != null and body_layer == 2,
"character mesh is assigned to the character light layer (got %d)" % body_layer)
var audio: Node = Audio.new()
get_root().add_child(audio)
audio.setup(assets)
pv.set_audio(audio)
pv.set_anim_state("run")
_ck(pv._sound_instances.size() == 3, "PlayerView run motion loads paired .mss instances")
_ck(pv.set_motion_id(305), "clap motion resolves")
_ck(String(pv.anim.get("anim_path")).ends_with("action/clap.msa"),
"clap -> action/clap.msa")
@@ -43,3 +55,4 @@ func _run() -> void:
_ck(String(pv.anim.get("anim_path")).ends_with("action/slap_hurt.msa"),
"slap hurt -> action/slap_hurt.msa")
pv.queue_free()
audio.queue_free()