feat(playable): 首个 Mac 联网内测版 STB-01 soak 工具与发布状态文档

- 新增 script/playable_soak.sh:先做 soak 配置/资源校验,无 --allow-gameplay
  只校验不启动客户端;N(>=10) 次独立正常退出运行 + 墙钟 soak,失败即停止后续
  运行并记 BLOCKED;写本批次 release-manifest.json 后聚合
- run_client_gate.sh:确认的故障代理对所有 suite 启动(共享场景的退出运行也经代理);
  soak 超时下限只约束 soak 客户端(validate_soak 增加 soak_client 参数)
- 新增本地 127.0.0.1 故障代理、RSS 采样/内存判定、窗口/指标/流程模块及其测试
- forest_mob_render_test 输出 PASS/FAIL 标记,供 rendering_batch_test.sh 识别
- 新增 docs/FIRST-MAC-PLAYABLE-STATUS.md:如实记录 PASS/BLOCKED、已知问题与环境需求
- .gitignore 排除本地场景配置、凭据文件与运行输出

离线回归:rendering_batch_test.sh failures=0,playable_gate_test.sh PASS,
node 夹具测试 PASS。未联网运行,未重建候选包。

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Ft3kXpNdLbKEfg5uDLfqVF
This commit is contained in:
shenlei
2026-09-11 22:06:48 +09:00
co-authored by Claude Opus 5
parent 374d4165d8
commit f39a55fdd5
66 changed files with 9189 additions and 951 deletions
+7
View File
@@ -29,6 +29,10 @@ var _light_states: Array[Dictionary] = []
var _bsphere_r := 0.0
var _playing := false
var _cleanup_remaining := -1.0
## MSE-defined playback length of the last play(); -1 while looping (owner-bound).
var defined_lifetime_ms := -1
## Why the node left the tree: "cleanup" when its own playback clock freed it.
var finish_reason := ""
static var _glow_tex: Texture2D
@@ -64,6 +68,7 @@ func _process(delta: float) -> void:
if _cleanup_remaining >= 0.0:
_cleanup_remaining -= maxf(delta, 0.0)
if _cleanup_remaining <= 0.0:
finish_reason = "cleanup"
queue_free()
func play(force_one_shot := false) -> void:
@@ -71,6 +76,7 @@ func play(force_one_shot := false) -> void:
# may start or delete an effect after stop/replay, or while it is paused.
_playing = true
_cleanup_remaining = maxf(_longest_life() + 0.5, 1.5) if (force_one_shot or one_shot) else -1.0
defined_lifetime_ms = roundi(_longest_life() * 1000.0) if (force_one_shot or one_shot) else -1
for state in _particle_states:
state["clock"] = 0.0
state["emission_stopped"] = false
@@ -97,6 +103,7 @@ func stop() -> void:
# Existing particles may finish their lifetime; mesh/light emission stops now.
_playing = false
_cleanup_remaining = -1.0
defined_lifetime_ms = -1
for e in _emitters:
e.emitting = false
for mesh in _mesh_nodes:
+24
View File
@@ -6,12 +6,21 @@
# var pv := fxr.spawn_at("hit_spark", world, global_pos)
extends RefCounted
## Lifecycle boundaries of every effect this registry creates. lifetime_ms is the
## MSE-defined length (-1 = looping, lives as long as its owner). fx_finished is
## emitted when the node actually leaves the tree; reason "cleanup" means its own
## playback clock freed it, "removed" means the owner/scene removed it earlier.
signal fx_spawned(effect: String, fx_id: int, lifetime_ms: int)
signal fx_finished(effect: String, fx_id: int, lifetime_ms: int, elapsed_ms: int, reason: String)
const Mse = preload("res://fx/mse.gd")
const EffectPlayer = preload("res://fx/effect_player.gd")
var assets_root := ""
var _path_cache := {} # name -> abs .mse path ("" = not found)
var _spec_cache := {} # abs path -> parsed spec
# Process-wide so ids stay unique when GameScene rebuilds its registry.
static var _next_fx_id := 0
func setup(assets: String) -> void:
assets_root = assets
@@ -89,8 +98,23 @@ func spawn(name: String, parent: Node3D, one_shot := true) -> Node3D:
fx.build(s, assets_root)
parent.add_child(fx)
fx.play(one_shot)
_track(fx, name)
return fx
func _track(fx: Node3D, name: String) -> void:
_next_fx_id += 1
var fx_id := _next_fx_id
var lifetime_ms: int = fx.defined_lifetime_ms
fx.tree_exiting.connect(_on_fx_exiting.bind(fx, name, fx_id, lifetime_ms, Time.get_ticks_msec()),
CONNECT_ONE_SHOT)
fx_spawned.emit(name, fx_id, lifetime_ms)
func _on_fx_exiting(fx: Node3D, name: String, fx_id: int, lifetime_ms: int, spawned_ms: int) -> void:
var reason := "removed"
if is_instance_valid(fx) and not String(fx.finish_reason).is_empty():
reason = fx.finish_reason
fx_finished.emit(name, fx_id, lifetime_ms, Time.get_ticks_msec() - spawned_ms, reason)
# 在世界某点播一次性
func spawn_at(name: String, world_parent: Node3D, global_pos: Vector3, one_shot := true) -> Node3D:
var fx := spawn(name, world_parent, one_shot)