As the title describes, if you create a map & save it to a mapid that isn't currently used you'll get the following error
System.Exception: Could not find a suitable Map.wz to place the new map into.
at HaCreator.Wz.MapSaver.InsertImage() in Harepacker-resurrected\HaCreator\Wz\MapSaver.cs:line 69
at HaCreator.Wz.MapSaver.SaveMapImage() in Harepacker-resurrected\HaCreator\Wz\MapSaver.cs:line 972
at HaCreator.GUI.Save.saveButton_Click(Object sender, EventArgs e) in Harepacker-resurrected\HaCreator\GUI\Save.cs:line 110
Messed up that while creating compatibility for later versions of MapleStory (post 64-bit) + Beta MapleStory.
Neglected testing on this aspect of the code.
Always hard to have one size that fits it all.
As the title describes, if you create a map & save it to a mapid that isn't currently used you'll get the following error
Line numbers are off? But debugging brings me to https://github.com/lastbattle/Harepacker-resurrected/blob/c28be2f92bd76ea1bf4aa1464d4fa42df0804c75/HaCreator/Wz/MapSaver.cs#L65-L75
https://github.com/lastbattle/Harepacker-resurrected/blob/c28be2f92bd76ea1bf4aa1464d4fa42df0804c75/HaSharedLibrary/Wz/WzInfoTools.cs#L257-L271 everything here seems fine except for
mapObject?[mapcat]?[mapIdNamePadded]
mapIdNamePadded
will not exist since its a new map, it'll return null, and the null check in MapSaver will now throw an exceptionMore notes, this is how it used to work before rewrites. Looks like restructuring didn't persist all functionality. https://github.com/lastbattle/Harepacker-resurrected/blob/6b636036816363e26c035877ca7a4c9a0b97c7ed/HaCreator/Wz/MapSaver.cs#L57-L71