fix: 装备属性面板避让逻辑 + 多项功能更新
- item_tooltip_view.gd: 新增 avoid_rect 属性,tooltip 与装备窗口重叠时自动推到左侧 - inventory_ui.gd: 悬停装备时传入窗口矩形作为避让区域 - 包含其他累积的功能开发和测试文件
This commit is contained in:
@@ -94,7 +94,9 @@ func _run() -> void:
|
||||
_ck(name_edit != null, "create dialog has Name field")
|
||||
var job_opt := _find(s, "OptionButton", func(n): return n.name == "Job") as OptionButton
|
||||
_ck(job_opt != null and job_opt.get_selected_id() == 1, "job defaults to slot index (assassin)")
|
||||
name_edit.text = "Newbie"
|
||||
# 40250 的角色名字段是 24 个 GB2312 wire 字节。这个名称占 27 个
|
||||
# UTF-8 字节,但只占 18 个 GB2312 字节,UI 不应在转码前误拒绝它。
|
||||
name_edit.text = "龙驹简体中文免费版"
|
||||
var ok := _btn(s, "创建")
|
||||
_ck(ok != null, "create dialog has 创建 button")
|
||||
ok.pressed.emit()
|
||||
@@ -102,7 +104,8 @@ func _run() -> void:
|
||||
_ck(fc.creates.size() == 1, "create_character called once")
|
||||
if fc.creates.size() == 1:
|
||||
var c: Dictionary = fc.creates[0]
|
||||
_ck(c["slot"] == 1 and c["name"] == "Newbie" and c["job"] == 1, "create args: slot/name/job")
|
||||
_ck(c["slot"] == 1 and c["name"] == "龙驹简体中文免费版" and c["job"] == 1,
|
||||
"create args preserve a GB2312-fitting Chinese name")
|
||||
# assassin 基础四维 con3 int3 str4 dex6
|
||||
_ck(c["con"] == 3 and c["int"] == 3 and c["str"] == 4 and c["dex"] == 6,
|
||||
"create sends assassin base stats (got %s)" % c)
|
||||
|
||||
Reference in New Issue
Block a user