Page 1 of 1

[16.39]Error loading scenario save after game update.

Posted: Tue May 01, 2018 10:07 am
by KrazyTygr
I have been playing a scenario over the past few days with no problem. After the latest update I can no longer load any of my saved games. I get this error message:
AppManagerStates.cpp:1304: Error while running on_configuration_changed: LuaGameScript doesn't contain key surface.
stack traceback: ...Data/Roaming/Factorio/temp/currently-playing/control.lua:59: in function <...Data/Roaming/Factorio/temp/currently-playing/control.lua:54>
The Scenario is called Frontier - Extended by MojoD. I also have a few mods installed. I have been able to save and load my game with no problem until I updated to the latest version. I have tried to sync the mods with the save as the scenario is shown as not being included in the save, but when I check the box and click confirm it has no effect.
Factorio Sync Mods Screen.png
Factorio Sync Mods Screen.png (360.76 KiB) Viewed 1797 times
I don't know if this is a bug or if I'm doing something wrong, but what do I need to do in order load my saves?
factorio-current.log
(9.05 KiB) Downloaded 87 times
_autosave2.zip
(4.85 MiB) Downloaded 79 times

Re: [16.39]Error loading scenario save after game update.

Posted: Tue May 01, 2018 4:54 pm
by orzelek
If I understand correctly it's a problem with the scenario you have.
Game update triggered the event since configuration changed and something in the scenario handler for this event is broken.

Re: [16.39]Error loading scenario save after game update.

Posted: Thu May 03, 2018 11:22 pm
by GotenXiao
We currently have a game up using the same scenario, and encountered the same problem. It's a bug (or an API change in Factorio) in the control.lua on line 59; change this:

Code: Select all

game.surface[1].peaceful_mode = false
to this:

Code: Select all

game.[b]surfaces[/b][1].peaceful_mode = false
This should get you going!

Re: [16.39]Error loading scenario save after game update.

Posted: Fri May 04, 2018 12:54 am
by KrazyTygr
GotenXiao wrote:We currently have a game up using the same scenario, and encountered the same problem. It's a bug (or an API change in Factorio) in the control.lua on line 59; change this:

Code: Select all

game.surface[1].peaceful_mode = false
to this:

Code: Select all

game.[b]surfaces[/b][1].peaceful_mode = false
This should get you going!
Hey, thank you very much. That really did the trick :) - well, at least it did after I realised that I needed to amend control.lua in the save file as well as the scenario itself.

Re: [16.39]Error loading scenario save after game update.

Posted: Thu Jun 07, 2018 11:29 pm
by hyspeed
I just had this happen with today's update. That's too frustrating to deal with.

Thanks for the info, at least I know the cause.