johnnovak / gridmonger

Your trusty old-school cRPG mapping companion
https://gridmonger.johnnovak.net/
Do What The F*ck You Want To Public License
61 stars 2 forks source link

The value of boolean 'lvl.cell.trail' must be either 0 or 1, actual value 10 #14

Closed tin-pham closed 4 months ago

tin-pham commented 4 months ago

image I can't open my map anymore, even the backup file. I can open example map.

I link the map file, since Github not support gmm upload: https://drive.google.com/file/d/1J0zOgRyQBjSNAC2AheFLakwcRyRXLZPw/view?usp=sharing

johnnovak commented 4 months ago

@tin-pham Thanks, I will look into it.

I've noticed a few such cases when you can end up with a corrupted map file. These will be all fixed in the next version. There's not much to do with the current version, unfortunately, other than trying to avoid the actions that result in a corrupted map (but you wouldn't know what those are...)

The changelog for the next release will give you some hints though what operations to avoid. But this specific problem you've run into could be something I haven't noticed yet with the trail markers stuff. I'll investigate.

https://github.com/johnnovak/gridmonger/blob/master/CHANGELOG.md

tin-pham commented 4 months ago

@tin-pham Thanks, I will look into it.

I've noticed a few such cases when you can end up with a corrupted map file. These will be all fixed in the next version. There's not much to do with the current version, unfortunately, other than trying to avoid the actions that result in a corrupted map (but you wouldn't know what those are...)

The changelog for the next release will give you some hints though what operations to avoid. But this specific problem you've run into could be something I haven't noticed yet with the trail markers stuff. I'll investigate.

https://github.com/johnnovak/gridmonger/blob/master/CHANGELOG.md

I looking forward to see what action occur that, now I gonna try to backup file as much as I can

johnnovak commented 4 months ago

Here's your fixed map @tin-pham.

It's almost impossible to say with certainty what corrupted it. Probably it was a memory corruption when you used the problematic operations listed in the changelog.

Ultima IV - Quest of the Avatar.gmm.zip

The new version will be more stable so have patience until it comes out (in 1-2 months, hopefully).

I will log the file position in the new version, so people could at least take a stab at correcting the map file themselves with a hex editor:

image

I really hope map file corruption will go away with the new version. But if I still receive reports about corrupted maps, I might add a "recover map" feature that will try to auto-fix them (but that would be a last resort; I'd much prefer to understand the problem and get 100% rid of the root cause).

johnnovak commented 4 months ago

Hopefully non-issue in v1.2.0, so closing.