[1.10 Bug] Crash when saving ship design


#1

I created a new ship design and went to save it. Upon hitting Save Design, the following error came up (in the background – the main app became unresponsive):

Ship Design not found -> C:\Users\James\Documents/My Games/GratuitousSpaceBattles/ships/heavy weapons cruiser.txt:…\src\SIM_ShipDesign.cpp 529

I had initially named the ship “Heavy Weapons Cruiser” (note caps), but the file was being saved in all lower case. Could this be the problem?

The name it said was not found does exist (c:\users\james\documents\my games\GratuitousSpaceBattles\ships\heavy weapons cruiser.txt):

[config]
name = heavy weapons cruiser 
guiname = Heavy Weapons Cruiser 
hull = Federation Panther Cruiser hull 
cost = 2326 

[modules]
0 = cruiser tractor,
1 = cruiser_pointdefence,
2 = cruiser heavy plasma,
3 = cruiser_federation_beamlaser,
4 = cruiser powered armor,
5 = cruiser powered armor,
6 = cruiser heavy plasma,
7 = cruiser_federation_beamlaser,
8 = cruiser crew II,
9 = cruiser_engine II,
10 = cruiser_engine II,
11 = cruiser reinforced power II,
12 = cruiser reinforced power II,
13 = cruiser heavy plasma,
14 = cruiser_federation_beamlaser,

#2

I restarted the game and tried to load the saved design. It showed up in the list of design, but upon trying to load it, I got the same error as above. Perhaps the error isn’t in saving but in loading?


#3

There is a bug with the cruiser point defense modules. The regular “Cruiser Point Defense System” has the same “name” parameter in the data files as the “Hi-Speed Point Defense” module. If you create a ship with the regular module, the game will crash if you don’t have enough power or crew to have one of the Hi-Speed ones instead. You can work around the issue by opening up the file “\data\modules\cruiser_point_defense_II.txt” in the folder you installed GSB to and changing the line that says ‘name = “cruiser_pointdefense”’ to say ‘name = “cruiser_pointdefense_II”’ or something similar.