The International Simutrans Forum

Simutrans Extended => Simutrans-Extended development => Topic started by: Vladki on October 14, 2017, 12:09:06 PM

Title: Loading addons crashes the game
Post by: Vladki on October 14, 2017, 12:09:06 PM
Hello, I came upon this bug when debugging the smokes on industries.

If you put a factory in ~/simutrans/adddons/pakXY, that overwrites already existing factory, it will crash the game. If you move the pak file to the main pakXY directory, it will load OK.
However it does not crash if you override a station pak.
Title: Re: Loading addons crashes the game
Post by: jamespetts on October 14, 2017, 01:42:53 PM
Thank you for the report. I must confess that I have not used addons in many years. Does factory overriding like this work without problems in Standard, do you know? I have never really looked into the addons/overriding code.
Title: Re: Loading addons crashes the game
Post by: Vladki on October 14, 2017, 03:20:37 PM
I had never such a problem with standard. IIRC overriding factories worked just fine.
Title: Re: Loading addons crashes the game
Post by: Vladki on October 18, 2017, 07:00:49 PM
I have found out that it is not just addons. In pak128.CS we have some duplicates (two authors made the same vehicle), which were long unnoticed. At leas half a year ago they did not cause any problems in extended. Now I can't start simutrans with pak128.CS due to duplicates in mail pak directory. I do not even load any addons.


Reading object data from pak128.CS/...
Message: ground_desc_t::register_desc():        setting raster width to 128
Warning: vehicle_builder_t::register_desc():    Object CD_380_Messerschmitt was overlaid by addon!
Message: ground_desc_t::register_desc():        setting raster width to 128
Message: register_desc():       Notice: obj Outside already defined
Warning: vehicle_builder_t::register_desc():    Object Karosa_SL_11 was overlaid by addon!
Warning: vehicle_builder_t::register_desc():    Object Karosa_SD_11 was overlaid by addon!
Warning: vehicle_builder_t::register_desc():    Object Karosa_SM_11 was overlaid by addon!
Warning: vehicle_builder_t::register_desc():    Object Karosa_B_731 was overlaid by addon!
Neoprávněný přístup do paměti (SIGSEGV)
Title: Re: Loading addons crashes the game
Post by: jamespetts on October 19, 2017, 10:16:16 PM
Thank you for that. Are you able to upload a compiled pakset with a single override in which this problem can reliably be reproduced?