标识符面:flag_*→seal_ 族(含 Godot 信号 flag_judged→seal_judged 与连接/回调同名、 FACTS 两键 flags_count→seals_count/dug_under_flag→dug_under_seal 全链、 .tres 键名与 schema .gd 同批同步);显式豁免零改动=size_flags_*(Godot 布局属性)+_fatal_flag。 中文面:金币→GP(金币袋→GP 袋)/插旗→封印/雷格→危险格/惩罚格→危险格/旗→封印·封印印记族, game/ 内 *.gd/.tres/.md/.json 四类禁用词与 flag 双双零命中(V1/V4)。 守卫字面量不动(被检查的禁字不是使用):smoke_all V21 零「雷/旗」检查面、 ui_font_asset_test 字形集攻/雷/旗/封 保持原断言逻辑。 代拍板:板面单字槽 glyph「旗」→「封」(禁字纪律+单字位宽,消费面四处同名随动)。 素材换代(2026-10-18 用户裁案甲):assets/art/board/flag_seal.png→seal_mark.png(素材不入 git, 盘上改名+导入重刷),代码两处 res:// 字符串+COL_FLAG/CURSOR_FLAG 常量同步, 闸件四处随批(run_all_gates.sh/render_gate.sh/golden_baseline_refresh.sh/path_check.py)。 anchor.json 键名手改,重锚与改前改后 diff 随本卡收口(同裁案甲)。 基线读数(改前,主区 ed2dfaf6):冒烟 1151 检查 0 失败/单元 34 套全绿/探针 --click 存量红仅 screen_flow_probe(user:// 断点污染在册已知项)。 改后同批读数(本 worktree):冒烟 1151 检查 0 失败/探针 --click 同一存量红、其余全绿。
37 lines
2.5 KiB
GDScript
37 lines
2.5 KiB
GDScript
## VERTICAL SLICE - NOT FOR PRODUCTION
|
||
## 行动经济表 schema:行动点预算旋钮单行全局类型化读取(垂直切片验证:完整战斗逐行归因)。
|
||
## validate() 违例加载期致命(fail-fast);表运行期只读,调参只走 data/tables 表值。
|
||
class_name ActionEconomyTable
|
||
extends Resource
|
||
|
||
@export var ap_per_round: int = 6 # [1,32] knob(默认值 = 现行表值基线,2026-09-16 AP 压速批 8→6 随动)
|
||
@export var dig_ap_cost: int = 1 # [1,8] knob(域下限 1 = 零预算系统失效拒绝)
|
||
@export var seal_place_ap_cost: int = 1 # [0,8] knob(seal_pull_ap_cost 随撤封印退役批 2026-09-19 删除)
|
||
@export var rap_refresh_cost: int = 6 # [1,64] knob(默认值随 AP 压速批 8→6 随动)
|
||
@export var refresh_cap_per_round: int = 2 # [1,8] knob(2026-09-12 轮内刷新批——每轮刷新兜底上限,Active/Waiting 合计)
|
||
@export var move_ap_cost: int = 0 # 冻结 0(P4 氛围承载)
|
||
@export var chain_ap_cost: int = 0 # 冻结 0(v2 定稿)
|
||
|
||
|
||
func validate() -> Array:
|
||
var errs: Array[Dictionary] = []
|
||
if ap_per_round < 1 or ap_per_round > 32:
|
||
errs.append({"category": "domain", "message": "ap_per_round 越域 [1,32]: %d" % ap_per_round})
|
||
if dig_ap_cost < 1 or dig_ap_cost > 8:
|
||
errs.append({"category": "domain", "message": "dig_ap_cost 越域 [1,8]: %d" % dig_ap_cost})
|
||
if seal_place_ap_cost < 0 or seal_place_ap_cost > 8:
|
||
errs.append({"category": "domain", "message": "seal_place_ap_cost 越域 [0,8]: %d" % seal_place_ap_cost})
|
||
if rap_refresh_cost < 1 or rap_refresh_cost > 64:
|
||
errs.append({"category": "domain", "message": "rap_refresh_cost 越域 [1,64]: %d" % rap_refresh_cost})
|
||
if refresh_cap_per_round < 1 or refresh_cap_per_round > 8:
|
||
errs.append({"category": "domain", "message": "refresh_cap_per_round 越域 [1,8]: %d" % refresh_cap_per_round})
|
||
if move_ap_cost != 0:
|
||
errs.append({"category": "frozen", "message": "move_ap_cost 结构冻结为 0: %d" % move_ap_cost})
|
||
if chain_ap_cost != 0:
|
||
errs.append({"category": "frozen", "message": "chain_ap_cost 结构冻结为 0: %d" % chain_ap_cost})
|
||
# 跨字段(行动经济 三轮评审增补):任一动作成本 ≤ ap_per_round,违规加载期致命
|
||
for pair in [["dig_ap_cost", dig_ap_cost], ["seal_place_ap_cost", seal_place_ap_cost]]:
|
||
if pair[1] > ap_per_round:
|
||
errs.append({"category": "cross_field", "message": "%s(%d) > ap_per_round(%d)——挖掘/封印动作永久不可用软锁" % [pair[0], pair[1], ap_per_round]})
|
||
return errs
|