fix(player): 补挂 CheckpointRespawnHandler——存活回检查点链路接通
PlacePlayer 脚手架新增 CheckpointRespawnHandler 并自动绑定 EVT_CheckpointRespawn/EVT_FadeOutRequest/EVT_FadeInRequest; Player.prefab 同步补挂修正。此前 LethalTrap 存活路径 Raise 的 EVT_CheckpointRespawn 无任何监听者,玩家不会被传送回检查点。 Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
@@ -232,6 +232,13 @@ namespace BaseGames.Editor
|
||||
if (inputReader != null)
|
||||
AssignReference(interactDetector, "_inputReader", inputReader, report);
|
||||
|
||||
// ── 检查点回溯(LethalTrap 存活路径:淡出 → 传送至最近检查点 → 淡入)──
|
||||
// 须与 Rigidbody2D 同节点(传送时直接写 rb.position)。
|
||||
CheckpointRespawnHandler checkpointRespawn = GetOrAddComponent<CheckpointRespawnHandler>(root);
|
||||
AssignAsset(checkpointRespawn, "_onCheckpointRespawn", report, false, "EVT_CheckpointRespawn");
|
||||
AssignAsset(checkpointRespawn, "_onFadeOutRequest", report, false, "EVT_FadeOutRequest");
|
||||
AssignAsset(checkpointRespawn, "_onFadeInRequest", report, false, "EVT_FadeInRequest");
|
||||
|
||||
if (animConfig == null) report.Add("★ 需创建并绑定:PlayerController._animConfig(PLY_PlayerAnimationConfig)");
|
||||
if (statsConfig == null) report.Add("★ 需创建并绑定:PlayerStats._config(PlayerStatsSO)");
|
||||
if (inputReader == null) report.Add("★ 需手动绑定:PlayerController._inputReader / FormController._input / SkillManager._input(InputReaderSO)");
|
||||
|
||||
Reference in New Issue
Block a user