Continuing an observed online game offline?

OpenTTD is a fully open-sourced reimplementation of TTD, written in C++, boasting improved gameplay and many new features.

Moderator: OpenTTD Developers

Post Reply
.CHaSE.
Engineer
Engineer
Posts: 14
Joined: 03 Feb 2006 23:45

Continuing an observed online game offline?

Post by .CHaSE. »

Is it possible to continue an online game offline? I'm aware there's a save option when playing online, but it doesn't seem to do what I want.

Specifically, I'm observing a game right now, where one of the companies has some errors in its railroad network. And I'd like to save that game, load it offline and see if I'm able to fix them. However, when I do load the game, and select that company through the "Playing as Player X" cheat, I cannot build anything.
User avatar
Brianetta
Tycoon
Tycoon
Posts: 2567
Joined: 15 Oct 2003 22:00
Location: Jarrow, UK
Contact:

Post by Brianetta »

CHaSE: What I do is start a dedicated server on my machine with the saved game and then connect to it locally:

Code: Select all

./openttd -D -g <savegame.sav>
then run openttd (again), search for the game on the LAN, and then choose the company I want to control.

It takes twice the CPU because the game's running twice, but it does the trick.
PGP fingerprint: E66A 9D58 AA10 E967 41A6 474E E41D 10AE 082C F3ED
.CHaSE.
Engineer
Engineer
Posts: 14
Joined: 03 Feb 2006 23:45

Post by .CHaSE. »

Thanks! Good thing OTTD doesn't use much CPU, except when on fast forward :)
Moriarty
Tycoon
Tycoon
Posts: 1395
Joined: 12 Jun 2004 00:37
Location: United Kingdom of Great Britain and Northern Ireland
Contact:

Post by Moriarty »

But running it as a server will mean that if the company is passworded you won't be able to get into it.
It should work simply loading a multi-player save as a regular save. Then using the cheat choose you company. It has for me in the past.
peter1138
OpenTTD Developer
OpenTTD Developer
Posts: 1795
Joined: 30 Mar 2005 09:43

Post by peter1138 »

Company passwords aren't saved, so that's not an issue...
He's like, some kind of OpenTTD developer.
User avatar
Darkvater
Tycoon
Tycoon
Posts: 3053
Joined: 24 Feb 2003 18:45
Location: Hong Kong

Post by Darkvater »

He, there was a "-p" switch to force the game to play as another player but that was removed not so far ago :P

Why doesn't the cheat work? It should be.
TrueLight: "Did you bother to read any of the replies, or you just pressed 'Reply' and started typing?"
<@[R-Dk]FoRbiDDeN> "HELP, this litte arrow thing keeps following my mouse, and I can't make it go away."
.CHaSE.
Engineer
Engineer
Posts: 14
Joined: 03 Feb 2006 23:45

Post by .CHaSE. »

Darkvater
Here's exactly, step-by-step what I do: I join a game as a spectator, save the game, abandon the game, load that saved game, select one of the companies in the cheat menu. At that moment building tools are available, but don't actually build anything.

Perhaps I missed some important step or nuance?
.CHaSE.
Engineer
Engineer
Posts: 14
Joined: 03 Feb 2006 23:45

Post by .CHaSE. »

Oh my, silly me! I was trying to build in pause mode! *blushes*
User avatar
Darkvater
Tycoon
Tycoon
Posts: 3053
Joined: 24 Feb 2003 18:45
Location: Hong Kong

Post by Darkvater »

nice going chase :)
TrueLight: "Did you bother to read any of the replies, or you just pressed 'Reply' and started typing?"
<@[R-Dk]FoRbiDDeN> "HELP, this litte arrow thing keeps following my mouse, and I can't make it go away."
TrueBrain
OpenTTD Developer
OpenTTD Developer
Posts: 1370
Joined: 31 May 2004 09:21

Post by TrueBrain »

Darkvater wrote:He, there was a "-p" switch to force the game to play as another player but that was removed not so far ago :P

Why doesn't the cheat work? It should be.

Euh.... DV....
The -p switch was only for joining network clients, and it is merged with -n, to force this behavoir and not let people think that it has any effect in single player. With -n you can do: -n 127.0.0.1#4, which will join company 5 (0 .. 7).
User avatar
Brianetta
Tycoon
Tycoon
Posts: 2567
Joined: 15 Oct 2003 22:00
Location: Jarrow, UK
Contact:

Post by Brianetta »

TrueLight wrote:With -n you can do: -n 127.0.0.1#4, which will join company 5 (0 .. 7).
They're indexed from 1, TrueLight. I use this one extensively when visiting my servers. (:
PGP fingerprint: E66A 9D58 AA10 E967 41A6 474E E41D 10AE 082C F3ED
TrueBrain
OpenTTD Developer
OpenTTD Developer
Posts: 1370
Joined: 31 May 2004 09:21

Post by TrueBrain »

Brianetta wrote:
TrueLight wrote:With -n you can do: -n 127.0.0.1#4, which will join company 5 (0 .. 7).
They're indexed from 1, TrueLight. I use this one extensively when visiting my servers. (:
Then someone finally corrected that :) So, from 1 .. 8 :p
Moriarty
Tycoon
Tycoon
Posts: 1395
Joined: 12 Jun 2004 00:37
Location: United Kingdom of Great Britain and Northern Ireland
Contact:

Post by Moriarty »

LMAO.
The joys of (poor) documentation. We've got two devs who don't know what different commands do.

Anyone else find that ironic?
User avatar
Brianetta
Tycoon
Tycoon
Posts: 2567
Joined: 15 Oct 2003 22:00
Location: Jarrow, UK
Contact:

Post by Brianetta »

Not really. It's a big project, and people often don't have a complete picture with every detail. Given that the devs also have less time to actually play (as opposed to testing), it doesn't surprise me that some details, especially ones of little consequence, escape them.
PGP fingerprint: E66A 9D58 AA10 E967 41A6 474E E41D 10AE 082C F3ED
Moriarty
Tycoon
Tycoon
Posts: 1395
Joined: 12 Jun 2004 00:37
Location: United Kingdom of Great Britain and Northern Ireland
Contact:

Post by Moriarty »

I don't play the game I dev (PHP), but I know the ins and outs intimately. Many of the OTTD devs have been doing this for years now. I'd figured they had also gotton to know their code that well.
User avatar
Brianetta
Tycoon
Tycoon
Posts: 2567
Joined: 15 Oct 2003 22:00
Location: Jarrow, UK
Contact:

Post by Brianetta »

Moriarty wrote:I don't play the game I dev (PHP), but I know the ins and outs intimately. Many of the OTTD devs have been doing this for years now. I'd figured they had also gotton to know their code that well.
I know intimately how PPCIS works (see my web site). That said, when people ask me how to do something, I usually have to check, because I don't use the UI all that often myself - and I'm the only dev.
PGP fingerprint: E66A 9D58 AA10 E967 41A6 474E E41D 10AE 082C F3ED
Post Reply

Return to “General OpenTTD”

Who is online

Users browsing this forum: Bing [Bot], Semrush [Bot] and 16 guests