Game just crashes on Win10
Version information: Windows 10, 22.03, 0b1c308
Describe the bug Launching the game allows you to specify the Locomotion original folder (which in my case is inside a subfolder of OpenLoco called original), then a bad allocation is raised.
Successive launches just causes "Chris Sawyer's Locomotion has stopped working" error.
To Reproduce
- Unzip OpenLoco binary downloaded from releases page
- Launch it
- Specify OpenLoco folder
- Wait for error
Console Log
OpenLoco, v22.03.1-58 (0b1c308)
Searching for Locomotion install path...
Unable to find install path for Locomotion.
You will need to manually provide it.
Creating directory: C:\Users\Jack\AppData\Roaming\OpenLoco\save\
Warning: file "C:\\Users\\Jack\\AppData\\Roaming\\OpenLoco\\scores.dat" could not be not found
Warning: file "C:\\Users\\Jack\\AppData\\Roaming\\OpenLoco\\scores.dat" could not be not found
bad allocation
I think we have breakpad already set up, does it produce a dump for you? Can you submit it?
No dump for me, is it possible this occurs before hooking breakpad? I could try to run it from sources but I need some time for this.
No, it's almost the first thing we do: https://github.com/OpenLoco/OpenLoco/blob/ccd0591c048ecdc0a96a5e419cdad80a8b01d0b6/src/OpenLoco/OpenLoco.cpp#L1231-L1243
I tried bisecting the issue, the first affected release is 433f3bd (22.03), earlier builds launch fine (0c4cc36 22.02 is working fine for example).
The version you report, v22.03, is outdated at this point. Could you try v22.04 as well?
It's not outdated, it's the latest 22.04 which is wrongfully reported as 22.03.1-58 (0b1c308) in console log. So the issue was already reported for latest build 👌
Does this still happen on the latest version?
Just tried on OpenLoco, v22.06.1 (adb6f6c on master) and yes, it still occurs.