nivs

@nivrig
992 Followers
317 Following
14.4K Posts
Real Programmer with screwdriver. Born to nerd. Respawned 80s game developer. Tech, games, cycling, sci-fi and old computers. Contents may unsettle.
Webhttps://nivrig.com
itch.iohttps://nivrig.itch.io
SmolWebgemini://s73.girv.in
Linkshttps://links.nivrig.com
All hands marketing update for an hour.

Here is the offender.

writename re-terminates the input string and leaves 2 bytes of whatever is in memory to be written to the file. The save CRC is calculated with these bytes.

readname ignores those 2 bytes and terminates the string with 0. The load CRC is calculated with 0s.

Spent all evening on a gnarly bug. Loaded levels would fail CRC after being saved once.

Eventually, with a hex editor, I figured out a string writer wasn’t writing the null terminator bytes the CRC was calculated with but whatever was in memory, and the string reader was ignoring those and always “reading” nulls. So the load CRC was seeing different data from the save CRC.

This just arrived, so I guess it’s going to be an #Amstrad April :)

#amstradcpc

Ireland weather being a bit weird this morning. I suppose snow in March or even April isn’t unheard of though.
I preferred macOS when it looked like this.
Progress…
Spotted at the council dump earlier.