really newbie question

Got a problem with OpenTTD? Find some help here.

Moderator: OpenTTD Developers

Post Reply
Chinbobble
Engineer
Engineer
Posts: 8
Joined: 02 Jan 2010 23:33

really newbie question

Post by Chinbobble »

hey all, new to this game tonight... i know.. staying in on a sat night, but who isnt skint after xmas ;) i remember playing the orginal TT, but having seen some of the stuff you guys are posting on here, im amazed at your skills! So i apologise if this question is really newby, but its killing me at the moment!

Basically i'm trying to figure out signals, junctions etc... and i'm getting there, but I can't get my trains to stop at a 'stop signal' for longer than x amount of time (default i presume), before they give up waiting and turn around. I then spend the next hour trying to get the train, plus all the other trains that get jammed up, back onto the right tracks lol. Not an efficient learning environment i can assure you ;) I read somewhere that there is an option to force your trains to stay at a stop signal until the signal turns green, but for the life of me I cant figure out where this option is.

Any advise will be warmly greeted, thanx all

- Chinbobble
User avatar
Chrill
Moderator
Moderator
Posts: 15980
Joined: 18 Dec 2004 17:35
Location: Stockholm, Sweden
Contact:

Re: really newbie question

Post by Chrill »

This should do it, assuming you play OpenTTD

My documents > OpenTTD > Open "openttd.cfg" in NotePad > scroll down to [pf] > change value of "wait_oneway_signal", "wait_twoway_signal" and "wait_for_pbs_path" (I believe 0 is infinite).

This means they'll never turn around on one way signals, never on two way signals and never at PBS signals (it could be another value than 0. If so, I apologise)
Image
My Scenarios:
Archipiélago Hermoso (Latest Release: Version 3.2)
Turnpike Falls (Latest Release: Version 0.91)
Chinbobble
Engineer
Engineer
Posts: 8
Joined: 02 Jan 2010 23:33

Re: really newbie question

Post by Chinbobble »

after changing those values to 0, my trains stop at signals for precisely zero seconds hehe. Guess zero isn't infinite, I'll try changing those value to a really large obscure number. Thank you for pointing me in the right direction
User avatar
Chrill
Moderator
Moderator
Posts: 15980
Joined: 18 Dec 2004 17:35
Location: Stockholm, Sweden
Contact:

Re: really newbie question

Post by Chrill »

Try 255 then :D
Image
My Scenarios:
Archipiélago Hermoso (Latest Release: Version 3.2)
Turnpike Falls (Latest Release: Version 0.91)
Chinbobble
Engineer
Engineer
Posts: 8
Joined: 02 Jan 2010 23:33

Re: really newbie question

Post by Chinbobble »

I just tried 999, worked a charm.... ish... it kinda messed up the pathfinding routine to be honest, if a signal is red when a train leaves the depot it'll keep trying to find another route rather than heading towards the stop signal. 999 works if you have a single line (i.e. for heading into a drop off point, or picking up from a station where you have ordered all the trains to wait until full load) but if a train has more than one route to choose it'll mess up the routine.

Saying that though, this is preferable to figuring out where the hell my train with 300 coal has bugg**ed off to :D, ty chrill
User avatar
Benny
Tycoon
Tycoon
Posts: 2185
Joined: 25 Aug 2007 17:03
Location: ~/

Re: really newbie question

Post by Benny »

999 is not a valid value.

255
means infinite.
Image
Chinbobble
Engineer
Engineer
Posts: 8
Joined: 02 Jan 2010 23:33

Re: really newbie question

Post by Chinbobble »

o lol, i though Chrill had just picked a random obscure number hehe, thank you, I'll change the value to 255 now and stop banging my head against the wall :D

- Chinbobble
Yexo
Tycoon
Tycoon
Posts: 3663
Joined: 20 Dec 2007 12:49

Re: really newbie question

Post by Yexo »

Chinbobble wrote:o lol, i though Chrill had just picked a random obscure number hehe, thank you, I'll change the value to 255 now and stop banging my head against the wall :D

- Chinbobble
Maximum value of an unsigned 8bit variable is 255, so it's not random. When OpenTTD loads the config file all values are checked and I think that invalid values are clamped to the correct range, so even if you enter 999 it'll assume 255. I'm not 100% sure on this, it might take the default instead.
Chinbobble
Engineer
Engineer
Posts: 8
Joined: 02 Jan 2010 23:33

Re: really newbie question

Post by Chinbobble »

no you are correct, the config reassigned 999 to 255, and also 0 to 2
User avatar
FHS
Director
Director
Posts: 577
Joined: 18 Apr 2009 17:17
Location: Basel, CH

Re: really newbie question

Post by FHS »

Chinbobble wrote:and also 0 to 2
That statement is wrong, a 8-bit variable can also contain 0 if none of the bits are 1.
Rubidium
OpenTTD Developer
OpenTTD Developer
Posts: 3815
Joined: 09 Feb 2006 19:15

Re: really newbie question

Post by Rubidium »

FHS wrote:
Chinbobble wrote:and also 0 to 2
That statement is wrong, a 8-bit variable can also contain 0 if none of the bits are 1.
A 8 bit variable might contain 0, but in this case the 0 being turned into a 2 is correct.
Post Reply

Return to “OpenTTD Problems”

Who is online

Users browsing this forum: No registered users and 27 guests