Closed ToolMan2k closed 2 months ago
Looking at the failed test, we'll need to compile liblcf using a modified fields_easyrpg file.
The build failures are normal when depending on lcf changes.
You added new easyrpg chunks here. Did you check how maniac patch stores it in the save file? If it isn't something annoying like storing it in some upper bits we usually try to be compatible to mp here.
You added new easyrpg chunks here. Did you check how maniac patch stores it in the save file? If it isn't something annoying like storing it in some upper bits we usually try to be compatible to mp here.
This is definitely something that needs more love. I did try to load saves between original RPG_RT and EasyRPG, it does prints about "unknown chunks" inside the save file. Inside my above test project, you can make an instant save file by pressing SHIFT.
Here's the log I've posted on the bug tracker post:
Skipped Chunk 86 (1 byte) in lcf at 1F9 (SaveSystem)
01
Skipped Chunk 87 (1 byte) in lcf at 1FD (SaveSystem)
04
Reading Primitive of incorrect size 4 (expected 1) at 29D
SavePicture: Corrupted Chunk 0x06 (size: 4, pos: 0x29d): fixed_to_map : Read 7 bytes! Reseting...
Reading Primitive of incorrect size 3 (expected 1) at 2AD
SavePicture: Corrupted Chunk 0x09 (size: 3, pos: 0x2ad): use_transparent_color : Read 5 bytes! Reseting...
Skipped Chunk 0A (8 byte) in lcf at 2B2 (SavePicture)
00 00 00 00 00 60 73 40
Skipped Chunk 24 (2 byte) in lcf at 2D0 (SavePicture)
82 36
Skipped Chunk 0A (8 byte) in lcf at 345 (SavePicture)
00 00 00 00 00 60 73 40
Skipped Chunk 1E (2 byte) in lcf at 362 (SavePicture)
82 20
Skipped Chunk 24 (2 byte) in lcf at 37E (SavePicture)
82 36
Debug: Loading Save Save01.lsd
Skipped Chunk 86 (1 byte) in lcf at 1F9 (SaveSystem)
01
Skipped Chunk 87 (1 byte) in lcf at 1FD (SaveSystem)
04
Reading Primitive of incorrect size 4 (expected 1) at 29D
SavePicture: Corrupted Chunk 0x06 (size: 4, pos: 0x29d): fixed_to_map : Read 7 bytes! Reseting...
Reading Primitive of incorrect size 3 (expected 1) at 2AD
SavePicture: Corrupted Chunk 0x09 (size: 3, pos: 0x2ad): use_transparent_color : Read 5 bytes! Reseting...
Skipped Chunk 0A (8 byte) in lcf at 2B2 (SavePicture)
00 00 00 00 00 60 73 40
Skipped Chunk 24 (2 byte) in lcf at 2D0 (SavePicture)
82 36
Skipped Chunk 0A (8 byte) in lcf at 345 (SavePicture)
00 00 00 00 00 60 73 40
Skipped Chunk 1E (2 byte) in lcf at 362 (SavePicture)
82 20
Skipped Chunk 24 (2 byte) in lcf at 37E (SavePicture)
82 36
Debug: Savegame version 0 (RPG_RT or EasyRPG Player Pre-0.6.0)
Debug: Loaded Map Map0001.lmu
Debug: Tree: MAP0001
While playing around, jumping between RPG_RT, saving, then reading the savefile using LCF2XML, I can determine the following things:
I'll recompile liblcf with the proper indexes, then I'll let you know. However, I have a quick question: is it safe to reuse a save chunk twice?
For instance, using the block 07 for both current_magnify and current_width_scale, since they're the same value internally. Or would we have to change the name for everything, even though width/height is only for Maniac?
I would certainly keep magnify as it is for compatibility reasons.
As per https://github.com/EasyRPG/liblcf/pull/473, I've updated the chunk pointers.
Now I can save and load between Maniacs and EasyRPG, and scaling is kept between the twos.
Jenkins: Test this please
This commit allows for the use of separate Width/Height parameters for rendering pictures. You can use this feature with ManiacPatch 211010 using the .scale2 parameter.
It also adds scaling support for "Maniac_ShowStringPic" and a quick fix for failed bitmap assertion.
https://github.com/EasyRPG/Player/assets/26819563/e8a6eb26-f7a9-4267-a4f1-e26e4c5e135c
Sister commit here: https://github.com/EasyRPG/liblcf/pull/473
Added:
Fixed: