hhyyrylainen / GodotPckTool

Standalone tool for extracting and creating Godot .pck files
MIT License
367 stars 32 forks source link

Unicode support #31

Open suphamster opened 1 year ago

suphamster commented 1 year ago

It seems that for now unicode file names is not supported since after unpacking .pck I got few files that can't be packed back properly, For example: original file name "魔王魂 アコースティック25.ogg-0683c3a09e15adb36630a670de69ac05.oggstr" (got it with Godot RE Tools), GodotPckTool generated file name "魔王魂 アコースティック25.ogg-0683c3a09e15adb36630a670de69ac05.oggstr" so at importing back I got such error:

terminate called after throwing an instance of 'std::filesystem::__cxx11::filesystem_error'
  what():  filesystem error: cannot get file size: No such file or directory [extracted\.import\├Р┬У├В┬й├Р┬Т├В┬н├Р┬Т├в┬А┬Э├Р┬У├В┬з├Р┬Т├Р┬Л├Р┬Т├в┬А┬╣├Р┬У├В┬й├Р┬Т├В┬н├Р┬Т├в┬А┬Ъ ├Р┬У├Р┬И├Р┬Т├в┬А┬Ъ├Р┬Т├С┬Ю├Р┬У├Р┬И├Р┬Т├в┬А┬Ъ├Р┬Т├С┬Ц├Р┬У├Р┬И├Р┬Т├С┬У├Р┬Т├С┬Ш├Р┬У├Р┬И├Р┬Т├в┬А┬Ъ├Р┬Т├в┬Д┬Ц├Р┬У├Р┬И├Р┬Т├С┬У├Р┬Т├в┬А┬а├Р┬У├Р┬И├Р┬Т├в┬А┬Ъ├Р┬Т├Р┬И├Р┬У├Р┬И├Р┬Т├С┬У├Р┬Т├С┬У├Р┬У├Р┬И├Р┬Т├в┬А┬Ъ├Р┬Т├Р┬З06.ogg-bcfff188be40b560c38e232ce419ff3c.oggstr]
hhyyrylainen commented 1 year ago

I hadn't tested with those kinds of paths, so it isn't exactly surprising that they don't work entirely correctly. Is that on Windows? Because I would guess that on Linux it should actually all just work correctly using utf-8, but on Windows utf-16 encoded text is likely problematic.

suphamster commented 1 year ago

Yes, on Windows 10.