Saves and replays

Don't know how to use a machine? Looking for efficient setups? Stuck in a mission?
User avatar
Reygan
Fast Inserter
Fast Inserter
Posts: 177
Joined: Tue Jan 28, 2014 8:42 pm
Contact:

Saves and replays

Post by Reygan »

Does exist any way to extract map (blueprint.dat) from save? Or does exist any way to edit saves?
Does present in game replay recording/playing function?
Daniel V. Lenskiy

slpwnd
Factorio Staff
Factorio Staff
Posts: 1835
Joined: Sun Feb 03, 2013 2:51 pm
Contact:

Re: Saves and replays

Post by slpwnd »

Save can be migrated to "scenario" by running factorio from the commandline as follows (let's presume we have save foo.zip in the saves directory):

Code: Select all

./bin/prod/factorio --map2scenario foo
Factorio will start, load the save, store it as a blueprint (foo in the scenarios folder) and then quit. This is kind of a "development feature" so it is not really user friendly.

User avatar
Reygan
Fast Inserter
Fast Inserter
Posts: 177
Joined: Tue Jan 28, 2014 8:42 pm
Contact:

Re: Saves and replays

Post by Reygan »

slpwnd wrote:Save can be migrated to "scenario" by running factorio from the commandline as follows (let's presume we have save foo.zip in the saves directory):

Code: Select all

./bin/prod/factorio --map2scenario foo
Factorio will start, load the save, store it as a blueprint (foo in the scenarios folder) and then quit. This is kind of a "development feature" so it is not really user friendly.
Oh, thanks, its all that i need 8-)
And about second question?
Daniel V. Lenskiy

syneris
Fast Inserter
Fast Inserter
Posts: 141
Joined: Thu Feb 28, 2013 2:25 pm
Contact:

Re: Saves and replays

Post by syneris »

Replays are disabled at the moment. I believe I read it was sync issues and that we'll likely get it fixed as a work up to multiplayer.

slpwnd
Factorio Staff
Factorio Staff
Posts: 1835
Joined: Sun Feb 03, 2013 2:51 pm
Contact:

Re: Saves and replays

Post by slpwnd »

syneris wrote:Replays are disabled at the moment. I believe I read it was sync issues and that we'll likely get it fixed as a work up to multiplayer.
Exactly. They just don't work, I tried one recently, but soon I got a "out of sync checksum error".

User avatar
Reygan
Fast Inserter
Fast Inserter
Posts: 177
Joined: Tue Jan 28, 2014 8:42 pm
Contact:

Re: Saves and replays

Post by Reygan »

slpwnd wrote:
syneris wrote:Replays are disabled at the moment. I believe I read it was sync issues and that we'll likely get it fixed as a work up to multiplayer.
Exactly. They just don't work, I tried one recently, but soon I got a "out of sync checksum error".
Understood.

Does factorio have any else useful command line parameters? Or some like --h, to i look them myself?
Daniel V. Lenskiy

slpwnd
Factorio Staff
Factorio Staff
Posts: 1835
Joined: Sun Feb 03, 2013 2:51 pm
Contact:

Re: Saves and replays

Post by slpwnd »

There is --help but the map2scenario is probably the only one really useful.

User avatar
Reygan
Fast Inserter
Fast Inserter
Posts: 177
Joined: Tue Jan 28, 2014 8:42 pm
Contact:

Re: Saves and replays

Post by Reygan »

slpwnd wrote:There is --help but the map2scenario is probably the only one really useful.
Understood. Thank you.
Last edited by Reygan on Wed Mar 19, 2014 3:53 pm, edited 1 time in total.
Daniel V. Lenskiy

slpwnd
Factorio Staff
Factorio Staff
Posts: 1835
Joined: Sun Feb 03, 2013 2:51 pm
Contact:

Re: Saves and replays

Post by slpwnd »

Code: Select all

tomik ~/src/factorio(0.9.x) $  ./bin/prod/factorio --help
Options::
  --help                    display help
  --version                 show version information
  -s [ --map2scenario ] arg map 2 scenario conversion
  -c [ --convert ] arg      perform binary conversion
  --wiki                    create source files for wiki
  --autoupdate-stage2 arg   internal use only
  --autoupdate-finished     internal use only
  --apply-update arg        immediately apply update package

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Saves and replays

Post by ssilk »

I wondered that for a while: For me it ignores all params and starts the game... (MacOS)

Code: Select all

ssilk@ssilkpro [/Applications/factorio.app/Contents/MacOS] >  ./factorio --map2scenario /Users/ssilk/Library/Application\ Support/factorio/saves/Puzzle1.zip
... or any other option inclusive help.
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

slpwnd
Factorio Staff
Factorio Staff
Posts: 1835
Joined: Sun Feb 03, 2013 2:51 pm
Contact:

Re: Saves and replays

Post by slpwnd »

I see, that is probably some MacOS-package-thing. I am on MacOS as well but have a raw binary before being packaged, though it should be possible to use console params somehow even for packages ...

User avatar
ssilk
Global Moderator
Global Moderator
Posts: 12888
Joined: Tue Apr 16, 2013 10:35 pm
Contact:

Re: Saves and replays

Post by ssilk »

Any chance to get this working on Mac for v0.9.9 :?:

(I ask if I should create a windows vm for that)
Cool suggestion: Eatable MOUSE-pointers.
Have you used the Advanced Search today?
Need help, question? FAQ - Wiki - Forum help
I still like small signatures...

User avatar
CreeperDaReeper
Fast Inserter
Fast Inserter
Posts: 228
Joined: Fri May 23, 2014 8:59 pm
Contact:

Re: Saves and replays

Post by CreeperDaReeper »

Someone mind posting how this should look exactly for Windows? My attempts at trying to get the command line run the correct command all fail. (No idea what I'm doing really.)

User avatar
Reygan
Fast Inserter
Fast Inserter
Posts: 177
Joined: Tue Jan 28, 2014 8:42 pm
Contact:

Re: Saves and replays

Post by Reygan »

CreeperDaReeper wrote:Someone mind posting how this should look exactly for Windows? My attempts at trying to get the command line run the correct command all fail. (No idea what I'm doing really.)
Simple like tha daylight ;)
Right click on factorio.exe -> create shortcut -> right click shortcut -> properties ->
-> in "target" field append " --map2scenario YourSaveName"
Next time, if you want to convert other save you should open shortcut properties again and just change save name. Or create another shortcut.
Dont forget about space between factorio.exe and hyphens
Or you can use bat(cmd) file.
Daniel V. Lenskiy

User avatar
CreeperDaReeper
Fast Inserter
Fast Inserter
Posts: 228
Joined: Fri May 23, 2014 8:59 pm
Contact:

Re: Saves and replays

Post by CreeperDaReeper »

Reygan wrote:
CreeperDaReeper wrote:Someone mind posting how this should look exactly for Windows? My attempts at trying to get the command line run the correct command all fail. (No idea what I'm doing really.)
Simple like tha daylight ;)
Right click on factorio.exe -> create shortcut -> right click shortcut -> properties ->
-> in "target" field append " --map2scenario YourSaveName"
Next time, if you want to convert other save you should open shortcut properties again and just change save name. Or create another shortcut.
Dont forget about space between factorio.exe and hyphens
Or you can use bat(cmd) file.
Thanks for the help. Though I think I found a little quirk with this command, it doesn't like modded saves, sandbox (godmode), or both.
(I started a sandbox game and selected to research all technologies. I then saved, quit, and tried to convert the map. Right after Factorio finished loading up, but before the main menu, it would crash.)
Looks like I'll have to find another way to unlock all technologies in the map editor.

User avatar
Reygan
Fast Inserter
Fast Inserter
Posts: 177
Joined: Tue Jan 28, 2014 8:42 pm
Contact:

Re: Saves and replays

Post by Reygan »

CreeperDaReeper wrote: Thanks for the help. Though I think I found a little quirk with this command, it doesn't like modded saves, sandbox (godmode), or both.
(I started a sandbox game and selected to research all technologies. I then saved, quit, and tried to convert the map. Right after Factorio finished loading up, but before the main menu, it would crash.)
Looks like I'll have to find another way to unlock all technologies in the map editor.
Also you can turn all technologies researched by using console(~ key)

Code: Select all

game.player.force.researchalltechnologies()
Or some special technology, for example:

Code: Select all

game.player.force.technologies["toolbelt"].researched=true
There is no way to edit technologies in map editor. In factorio nearly all things edited by scripts directly in game. In editor you just painting the landscape and placing some entities/resources. If you want to edit map technologies you should create control.lua file in map folder and insert in there codes, that i writed higher.
Daniel V. Lenskiy

yogsog
Manual Inserter
Manual Inserter
Posts: 1
Joined: Wed Jun 10, 2015 9:43 pm
Contact:

Re: Saves and replays

Post by yogsog »

I am also unable to pass factorio any arguments from terminal on macos. It just runs without arguments. Anyone else managed to do map2scenario on a mac??

inventor1214
Manual Inserter
Manual Inserter
Posts: 3
Joined: Thu Jun 11, 2015 5:48 pm
Contact:

Re: Saves and replays

Post by inventor1214 »

How do you go to the commandline

fsjd
Burner Inserter
Burner Inserter
Posts: 5
Joined: Mon May 25, 2015 9:04 pm
Contact:

Re: Saves and replays

Post by fsjd »

inventor1214 wrote:How do you go to the commandline
tilde key. [`]

voidei
Manual Inserter
Manual Inserter
Posts: 2
Joined: Wed Jul 22, 2015 2:33 pm
Contact:

Re: Saves and replays

Post by voidei »

slpwnd wrote:Save can be migrated to "scenario" by running factorio from the commandline as follows (let's presume we have save foo.zip in the saves directory):

Code: Select all

./bin/prod/factorio --map2scenario foo
Factorio will start, load the save, store it as a blueprint (foo in the scenarios folder) and then quit. This is kind of a "development feature" so it is not really user friendly.
How would one do this on mac?

Post Reply

Return to “Gameplay Help”