port 2D step 2: 40250 item_proto/mob_proto through CLZO and pack://locale/<lang>/

proto.cpp reads the 40250 MIPX/MMPT tables with the ported CLZO/TEA (156-byte
TItemTable, 255-byte SMobTable), replacing the m2dev XChaCha20 236/335 reader.
Names follow CItemData::GetName / GetMonsterName (szLocaleName, cp1252).
GDScript callers load AssetRoot.locale_file() = pack://locale/en/<name>, which
makes the EterPack chain runtime-reachable; port-map entries for the functions
a coverage run hit move to PORTED/ADAPTED.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
shenlei
2026-09-23 01:34:08 +09:00
co-authored by Claude Opus 5
parent 5a26e93f07
commit 232d0461be
28 changed files with 1367 additions and 332 deletions
+2 -2
View File
@@ -278,8 +278,8 @@ func _run() -> void:
if ClassDB.class_exists("Metin2Proto"):
var pr: Object = ClassDB.instantiate("Metin2Proto")
get_root().add_child(pr)
var ip := assets.path_join("locale/locale/en/item_proto")
if FileAccess.file_exists(ip) and pr.call("load_item_proto", ip):
var ip := AssetRoot.locale_file("item_proto")
if ip != "" and pr.call("load_item_proto", ip):
var em3: Node = EquipModel.new()
get_root().add_child(em3)
em3.setup(fc, il, func() -> Node: return model, assets)