COnsole: peaceful_mode in 0.12.35?

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
Post Reply
Quax
Fast Inserter
Fast Inserter
Posts: 101
Joined: Mon Mar 14, 2016 7:57 am
Contact:

COnsole: peaceful_mode in 0.12.35?

Post by Quax »

Hi all,
since this is my first post here ... greetings to the community first :-)

Second, my question: I restarted a game where I had the "enemies never attack first" checkbox activated, but obviously that only counts for the first game, but isn't taken into account if you use the "restart" function from the game menu. So now I unexpectedly have been attacked and wanted to turn the peaceful mode on using the console command:

/c game.player.surface.peaceful_mode = true

However, the game returns the following line:

Cannot execute command. LuaSurface doesn't contain key peaceful_mode

is the console command for turning the peaceful mode on only available in version 0.13.x? I'm running the 0.12.35.

Since I'm just starting with the game, I want to concentrate on the basic building part without having to hassle with the beasts ...

Any help is appreciated!

Cheers, Peter

Nexela
Smart Inserter
Smart Inserter
Posts: 1828
Joined: Wed May 25, 2016 11:09 am
Contact:

Re: COnsole: peaceful_mode in 0.12.35?

Post by Nexela »

/c game.peaceful_mode = true

then you need to kill everything once with....

/c game.forces["enemy"].kill_all_units()


This should work in .12.35

Quax
Fast Inserter
Fast Inserter
Posts: 101
Joined: Mon Mar 14, 2016 7:57 am
Contact:

Re: COnsole: peaceful_mode in 0.12.35?

Post by Quax »

Thanks, will check it out in the evening :-)

Quax
Fast Inserter
Fast Inserter
Posts: 101
Joined: Mon Mar 14, 2016 7:57 am
Contact:

Re: COnsole: peaceful_mode in 0.12.35?

Post by Quax »

Thank you, worked out fine :-)

Post Reply

Return to “Gameplay Help”