feat(mana): Core 编辑器加击杀回蓝(mana_leech)栏

This commit is contained in:
2026-07-21 15:19:42 +08:00
parent 37f4d45e9f
commit 301f731e6c
+5 -1
View File
@@ -18,6 +18,7 @@ var _cpu: SpinBox
var _interval: SpinBox var _interval: SpinBox
var _mana_max: SpinBox var _mana_max: SpinBox
var _mana_regen: SpinBox var _mana_regen: SpinBox
var _mana_leech: SpinBox
var _feat: OptionButton var _feat: OptionButton
var _rows: SpinBox var _rows: SpinBox
var _cols: SpinBox var _cols: SpinBox
@@ -43,6 +44,7 @@ func _ready() -> void:
_interval = _row("施法间隔(s)", UI.spin(0.05, 5, 0.05, 0.5)) _interval = _row("施法间隔(s)", UI.spin(0.05, 5, 0.05, 0.5))
_mana_max = _row("蓝上限(Mana Max)", UI.spin(0, 1000, 5, 100)) _mana_max = _row("蓝上限(Mana Max)", UI.spin(0, 1000, 5, 100))
_mana_regen = _row("回蓝/秒(Mana Regen)", UI.spin(0, 100, 0.5, 5)) _mana_regen = _row("回蓝/秒(Mana Regen)", UI.spin(0, 100, 0.5, 5))
_mana_leech = _row("击杀回蓝(Mana Leech)", UI.spin(0, 100, 0.5, 0))
_feat = _row("特性", UI.opt(FEAT, 0)) _feat = _row("特性", UI.opt(FEAT, 0))
_rows = _row("矩阵行(MATRIX)", UI.spin(1, 8, 1, 1)) _rows = _row("矩阵行(MATRIX)", UI.spin(1, 8, 1, 1))
_cols = _row("矩阵列(MATRIX)", UI.spin(1, 16, 1, 5)) _cols = _row("矩阵列(MATRIX)", UI.spin(1, 16, 1, 5))
@@ -87,6 +89,7 @@ func _on_select(idx: int) -> void:
_interval.value = float(d.get("cast_interval", 0.5)) _interval.value = float(d.get("cast_interval", 0.5))
_mana_max.value = float(d.get("mana_max", 100)) _mana_max.value = float(d.get("mana_max", 100))
_mana_regen.value = float(d.get("mana_regen", 5)) _mana_regen.value = float(d.get("mana_regen", 5))
_mana_leech.value = float(d.get("mana_leech", 0))
_feat.selected = int(d.get("feature_tags", 0)) _feat.selected = int(d.get("feature_tags", 0))
_rows.value = float(d.get("grid_rows", 1)) _rows.value = float(d.get("grid_rows", 1))
_cols.value = float(d.get("grid_cols", 5)) _cols.value = float(d.get("grid_cols", 5))
@@ -106,6 +109,7 @@ func _on_apply() -> void:
"topology": _topo.selected, "cpu_limit": int(_cpu.value), "topology": _topo.selected, "cpu_limit": int(_cpu.value),
"cast_interval": _interval.value, "feature_tags": _feat.selected, "cast_interval": _interval.value, "feature_tags": _feat.selected,
"mana_max": int(_mana_max.value), "mana_regen": _mana_regen.value, "mana_max": int(_mana_max.value), "mana_regen": _mana_regen.value,
"mana_leech": _mana_leech.value,
"grid_rows": int(_rows.value), "grid_cols": int(_cols.value), "edges": edges, "grid_rows": int(_rows.value), "grid_cols": int(_cols.value), "edges": edges,
} }
_cur = cid _cur = cid
@@ -118,7 +122,7 @@ func _on_new() -> void:
while _data.has(cid): cid = "new_core_%d" % i; i += 1 while _data.has(cid): cid = "new_core_%d" % i; i += 1
_data[cid] = {"display_name": cid, "slot_count": 5, "topology": 0, _data[cid] = {"display_name": cid, "slot_count": 5, "topology": 0,
"cpu_limit": 5, "cast_interval": 0.5, "feature_tags": 0, "cpu_limit": 5, "cast_interval": 0.5, "feature_tags": 0,
"mana_max": 100, "mana_regen": 5, "edges": []} "mana_max": 100, "mana_regen": 5, "mana_leech": 0, "edges": []}
_refresh() _refresh()
func _on_delete() -> void: func _on_delete() -> void: