Moving pers2.dat?

You are viewing a static copy of the old 2DBoy forum, which closed in 2010. It is preserved here for historical interest, but it is not possible to reply to topics. For more recent discussion about World of Goo, visit our new forum.
Moving pers2.dat?Indrek05/05/2009 - 19:54

Is there any way to move the profile file (pers2.dat) to a different location?

The reason I'm asking is that I have a dual-boot setup (Windows 7 and Ubuntu 9.04), and I'd like to play the game with the same profile under both systems. I read the included doc about Linux issues, but the suggestion of moving the profile file from Windows to Linux doesn't work, as I'm not moving from one OS to another, I'm switching between them all the time.

I have a separate partition for sharing data between the two OS's, and I could easily copy my pers2.dat file there, if only I could tell World of Goo to look for it there. Any suggestions?

Thanks in advance!

Re: Moving pers2.dat?TheHermit05/06/2009 - 08:07

Firstly, store your pers2.dat in your shared partition. Then set up scripts in windows and Linux that copies the pers2.dat from the shared partition to the relevant location, starts WoG, then once it is closed copies the pers2.dat back.

Re: Moving pers2.dat?Soultaker05/06/2009 - 10:18

Is your Windows partition mounted and writable under Linux? In that case, you should be able to symlink you Linux profile to your Windows profile.

Re: Moving pers2.dat?Indrek05/06/2009 - 17:24

[quote author=Soultaker link=topic=1825.msg12213#msg12213 date=1241623101]Is your Windows partition mounted and writable under Linux? In that case, you should be able to symlink you Linux profile to your Windows profile.

My Windows partition isn't mounted by default, to prevent anything in Linux (including myself) from messing with it by accident.

But your suggestion gave me the idea of creating symlinks in both Windows and Linux, which should accomplish exactly what I want.

So far I've moved pers2.dat to my shared partition, and created a symlink to it in Windows. World of Goo picks it up just fine. I've yet to boot into Ubuntu to test it.

In case anyone faces the same isse and finds this thread, here's how to create a symlink in Windows (Vista and higher):
- open an elevated command prompt: Start -> type cmd -> right-click on the first result (cmd.exe) and choose "Run as administrator". Provide permission if required.
- go to the pers2.dat location: type cd C:\Users\username\AppData\Local\2DBoy\WorldOfGoo (replacing "username" with your username, of course)
- back up the profile: type copy pers2.dat pers2.dat.bak
- move the profile to your shared partition: type move pers2.dat S:\WorldOfGoo\pers2.dat (replacing "S:\WorldOfGoo" with the path where you want to keep the shared profile)
- create the symlink: type mklink pers2.dat S:\WorldOfGoo\pers2.dat (more info about symlinks at Wikipedia)


(Writing from Ubuntu now)
Success! I set up a symlink from Ubuntu as well, and now I'm able to play the same WoG profile from same systems. Thanks for your suggestion, Soultaker!

For future reference, here's how to create a symlink in Linux:
- open Terminal (or other shell of choice; location depends on distro)
- check if World of Goo directory exists: type ls -ad .W* (you should see an entry called ".WorldOfGoo")
- if the directory doesn't exist, create it: type mkdir .WorldOfGoo
- change to the directory: type cd .WorldOfGoo
- create the symlink: type ln -s /share/WorldOfGoo/pers2.dat pers2.dat (replacing "/share/WorldOfGoo" with the path you mounted your share partition as)

And that's it!


Last modified Wed, 05/06/2009 - 17:47 by Indrek
Re: Moving pers2.dat?TheHermit05/07/2009 - 04:58

Yeah that'll work as well... :D

Re: Moving pers2.dat?spazturtle05/07/2009 - 06:22

im now trying this acrose computers, should be fun

Re: Moving pers2.dat?Soultaker05/07/2009 - 06:39

[quote author=Indrek link=topic=1825.msg12223#msg12223 date=1241648697]
In case anyone faces the same isse and finds this thread, here's how to create a symlink in Windows (Vista and higher):
[..]
- create the symlink: type mklink pers2.dat S:\WorldOfGoo\pers2.dat (more info about symlinks at Wikipedia)
Nice! In Windows 2000 and XP you can probably use a junction to achieve the same effect, but then you need to put the directory containing pers2.dat on your shared partition (since junctions can point to directories only).