stars-4x / starsapi

Java-based API for manipulation of stars! related game files
5 stars 2 forks source link

HFileMerger/MFileMerger Exception #7

Closed runholen closed 4 years ago

runholen commented 7 years ago

So I and another player agreed to merge h-files in a game. But I get a java.lang.Exception: Unexpected player data size: => Block type: 6; size: 17 when it tries to parse the PlayerBlock. This is a full 16-player game btw. I have committed some code with the option of ignoring this error. This works well for my GalaxyViewer, which after all does not write files. But using the HFileMerger with this fix produces a non-complete merged file, which seems allright at first glance, but causes stars to forcefully crash when clicking on one of the other players starbase-designs. So I need the bug to be fixed. What is the cause for the Unexpected player data size?

runholen commented 7 years ago

Lol, I think I know what causes the bug. When i designed my race, I actually forgot to specify the "Plural Race Name" for my race, and that seems to screw up the parsing :-D I managed to recreate the error with parsing a new race-file with no plural race name.

raptor commented 4 years ago

Closing as likely fixed