burninrubber0 / Bundle-Manager

MIT License
9 stars 5 forks source link

Language: Empty strings are saved incorrectly #17

Closed burninrubber0 closed 11 months ago

burninrubber0 commented 2 years ago

Normally, empty strings are 4 null bytes plus a null terminator, making them 5 bytes long in total. In files saved with Bundle Manager, these same strings are a single byte with a null terminator (2 bytes).

While this does not impact the game, it results in files differing from the vanilla game even when no changes have been made, which is unwanted behaviour.

burninrubber0 commented 11 months ago

I was unable to find what I was talking about before. The vanilla file's empty strings are simply a null terminator. The "2 bytes" thing was probably me mistaking the null terminator of the previous string as part of the empty string.

It's possible I got the vanilla and edited files mixed up before, which would mean earlier versions of BM suffered from a bug that wrote empty strings as 4 null bytes.

Regardless of all this, the current version of BM accurately mimics the game, so any problem that may have existed is fixed. Closing.