Signals in tunnels and on bridges V3.02 r24031
Moderator: OpenTTD Developers
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: signals in tunnels and on bridges V17 r16177
This is very close to definite patch.
I tested it in multiplayer and it worked fine.
It should however be tested much more.
Maybe openttdcoop is the place to do this?
I still have some doubt about reversing and I will not commit this patch until I am 100% sure.
EDIT Please go to first page to download patch http://www.tt-forums.net/viewtopic.php? ... 60&start=0
Regards HackaLittleBit
I tested it in multiplayer and it worked fine.
It should however be tested much more.
Maybe openttdcoop is the place to do this?
I still have some doubt about reversing and I will not commit this patch until I am 100% sure.
EDIT Please go to first page to download patch http://www.tt-forums.net/viewtopic.php? ... 60&start=0
Regards HackaLittleBit
Last edited by HackaLittleBit on 02 May 2009 16:37, edited 1 time in total.
-
- Tycoon
- Posts: 1534
- Joined: 14 Mar 2006 12:46
- Location: Netherlands
Re: signals in tunnels and on bridges V17 r16177
alright, looks very good, hope you can get a platform for it soon, id love to see this in stable, very very good patch
Re: signals in tunnels and on bridges V17 r16177
Here's another feedback from the latest version (v19).
Tried to play with train reversing. Found one situation, where the train gets stuck and doesn't want to turn back. It should be in the attachement.
The second problem I've experienced: sometimes, the train doesn't react to free track for a while (in some cases even few seconds). Bigger networks cause longer delays. Try to download for example this savegame. You'll most likely need their GRF pack (can be found here, it's version 7.3).
Now, try to replace part of mainline with signalled bridge and reverse one train on the bridge. The delay should be clearly visible.
I really don't know what could cause this. Maybe bad optimisation or huge CPU load, but I'm just guessing.
Thanks!
Edit: The idea with #openttdcoop is really great. They are now testing infrastructure sharing patch, so I guess they would be able to test this patch as well.
Tried to play with train reversing. Found one situation, where the train gets stuck and doesn't want to turn back. It should be in the attachement.
The second problem I've experienced: sometimes, the train doesn't react to free track for a while (in some cases even few seconds). Bigger networks cause longer delays. Try to download for example this savegame. You'll most likely need their GRF pack (can be found here, it's version 7.3).
Now, try to replace part of mainline with signalled bridge and reverse one train on the bridge. The delay should be clearly visible.
I really don't know what could cause this. Maybe bad optimisation or huge CPU load, but I'm just guessing.
Thanks!
Edit: The idea with #openttdcoop is really great. They are now testing infrastructure sharing patch, so I guess they would be able to test this patch as well.

- Attachments
-
- bridge3.sav
- (13.18 KiB) Downloaded 319 times
-
- bridge.png (45.35 KiB) Viewed 2514 times
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: signals in tunnels and on bridges V19 r16199
This is build in behavior.Vitus wrote:The second problem I've experienced: sometimes, the train doesn't react to free track for a while (in some cases even few seconds). Bigger networks cause longer delays
see line 292 in the patch
Code: Select all
v->load_unload_time_rem = 10;
The smaller the value, smaller waiting time but more times checking for distance between trains.
You can easily change this value to suit your needs.
I downloaded the game (2000 trains good for testing) thanks.
I am aware about this reversing problem. It is a very small problem.
Most of the reversing is done correct.
I am reluctant to change code for that issue at this moment.
I rather prefer some serious testing now.
Thanks
Re: signals in tunnels and on bridges V19 r16199
Ah, I see.hackalittlebit wrote:This is build in behavior.
I was just wondering, if you could include some kind of switch for this value (either in game options or the cfg file). However, as you don't want to make changes to the code, take this as idea for future versions.
Anyways, thanks for great patch!
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: signals in tunnels and on bridges V17 r16177
Fixed that one.Vitus wrote:train gets stuck
Fixed that one.Vitus wrote:the train doesn't react to free track for a while (in some cases even few seconds)
Code: Select all
v->load_unload_time_rem = 10;
Code: Select all
v->load_unload_time_rem = 4;
Regards
- Sensation Lover
- Transport Coordinator
- Posts: 338
- Joined: 26 Feb 2009 09:17
- Skype: Aron Bogdan Silviu
- Location: Torino, Italy
- Contact:
Re: signals in tunnels V4
how did you do thatDJ Nekkid wrote:or even worse, like in Norway:

- Attachments
-
- Dranhall Transport, 21st Mar 2000.png (45.38 KiB) Viewed 6433 times
I was in:
Austria,Belgium,Brazil,China,France,Germany,Hungary,Indonesia,Italy,Luxemburg,Malaysia,Mexico,Netherlands,Norway,Panamà,Poland,Romania,
Saudi Arabia,Singapore,Slovenia,Spain,Switzerland,Thailand,U.K.,Ukraine,U.S.A.
Austria,Belgium,Brazil,China,France,Germany,Hungary,Indonesia,Italy,Luxemburg,Malaysia,Mexico,Netherlands,Norway,Panamà,Poland,Romania,
Saudi Arabia,Singapore,Slovenia,Spain,Switzerland,Thailand,U.K.,Ukraine,U.S.A.
-
- Tycoon
- Posts: 1829
- Joined: 10 Jul 2006 00:43
- Location: Spain
Re: signals in tunnels V4
There is a example with a tunnel with curve.Sensation Lover wrote:how did you do thatDJ Nekkid wrote:or even worse, like in Norway:i want to know pleeeeease!
But... It was done with two tunnels. Tunnels with turns is not implemented yet. Watch under the save button. There is the exit of the tunnel.
Sorry if my english is too poor, I want learn it, but it isn't too easy.
- [list][*]Why use PNG screenshots in 8 bpp games.
[*]Caravan site New Industry. · Spain set. · Some spanish trains for locomotion[*]Favourites:GRVTS · ECS · FIRS
- Sensation Lover
- Transport Coordinator
- Posts: 338
- Joined: 26 Feb 2009 09:17
- Skype: Aron Bogdan Silviu
- Location: Torino, Italy
- Contact:
Re: signals in tunnels V4
you didn t answer my question... it was HOW DID YOU DO THAT?maquinista wrote: There is a example with a tunnel with curve.
But... It was done with two tunnels. Tunnels with turns is not implemented yet. Watch under the save button. There is the exit of the tunnel.
I was in:
Austria,Belgium,Brazil,China,France,Germany,Hungary,Indonesia,Italy,Luxemburg,Malaysia,Mexico,Netherlands,Norway,Panamà,Poland,Romania,
Saudi Arabia,Singapore,Slovenia,Spain,Switzerland,Thailand,U.K.,Ukraine,U.S.A.
Austria,Belgium,Brazil,China,France,Germany,Hungary,Indonesia,Italy,Luxemburg,Malaysia,Mexico,Netherlands,Norway,Panamà,Poland,Romania,
Saudi Arabia,Singapore,Slovenia,Spain,Switzerland,Thailand,U.K.,Ukraine,U.S.A.
-
- Tycoon
- Posts: 1829
- Joined: 10 Jul 2006 00:43
- Location: Spain
Re: signals in tunnels V4
Sensation Lover wrote:you didn t answer my question... it was HOW DID YOU DO THAT?maquinista wrote: There is a example with a tunnel with curve.
But... It was done with two tunnels. Tunnels with turns is not implemented yet. Watch under the save button. There is the exit of the tunnel.
- Attachments
-
- A tunnel with curves?
- Rutfinghill Transport, 12 Ago 1896.png (83.6 KiB) Viewed 6184 times
-
- No, There is two tunnels.
- Rutfinghill Transport, 8 Ago 1896.png (81.93 KiB) Viewed 6189 times
Sorry if my english is too poor, I want learn it, but it isn't too easy.
- [list][*]Why use PNG screenshots in 8 bpp games.
[*]Caravan site New Industry. · Spain set. · Some spanish trains for locomotion[*]Favourites:GRVTS · ECS · FIRS
Re: signals in tunnels and on bridges V19 r16399
I think, for a realistic solution, when using the teleporting tunnels, the game should offer the player an amount of tiles the train has to pass inside the tunnel. Minimal amount is calculated by the minimum length.Dunno about the speed. Maybe this can be calculated somehow, too.
I love the signals in tunnels and bridges! I hope it gets implemented.
I love the signals in tunnels and bridges! I hope it gets implemented.
- Sensation Lover
- Transport Coordinator
- Posts: 338
- Joined: 26 Feb 2009 09:17
- Skype: Aron Bogdan Silviu
- Location: Torino, Italy
- Contact:
Re: signals in tunnels and on bridges V19 r16399
Yeah, this patch is realy great! I can construct now metros in the cities, long bridges and tunnels, it's very usefull!!!
I was in:
Austria,Belgium,Brazil,China,France,Germany,Hungary,Indonesia,Italy,Luxemburg,Malaysia,Mexico,Netherlands,Norway,Panamà,Poland,Romania,
Saudi Arabia,Singapore,Slovenia,Spain,Switzerland,Thailand,U.K.,Ukraine,U.S.A.
Austria,Belgium,Brazil,China,France,Germany,Hungary,Indonesia,Italy,Luxemburg,Malaysia,Mexico,Netherlands,Norway,Panamà,Poland,Romania,
Saudi Arabia,Singapore,Slovenia,Spain,Switzerland,Thailand,U.K.,Ukraine,U.S.A.
Re: signals in tunnels and on bridges V19 r16399
I think i did something wrong... but I compiled the patch with latest trunk and it doesn't seem to work. I can click on the tunnel's entrance to see the trains inside of the tunnel, but no matter how I fiddle with the settings, I never get more than a single train in the tunnel (or bridge) at once.
Spanish translation of OpenTTD
Extended heightmaps
Have fun, don't quarrel too much and add as many advanced settings as you can.
Extended heightmaps
Have fun, don't quarrel too much and add as many advanced settings as you can.
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: signals in tunnels and on bridges V19 r16399
Fixed it see first post 
Now it looks for Front Engine and only shows if front engine is inside tunnel.
Changed:
Thanks Terkhen

Now it looks for Front Engine and only shows if front engine is inside tunnel.
Changed:
Code: Select all
proc ClickTile_TunnelBridge(TileIndex tile)
line if (v->type != VEH_TRAIN || !HasBit(v->subtype, 0)) continue;
into if (v->type != VEH_TRAIN || !IsFrontEngine(v)) continue;
Last edited by HackaLittleBit on 03 Jun 2009 10:36, edited 1 time in total.
Re: signals in tunnels and on bridges V20 r16507
Wow, that was fast. Thank you for your great work!
EDIT: I got the same problem again. I can see the train in the tunnel clicking on its entrance, but only one train enters into it... There's something else besides "Simulate signals in tunnels and bridges every N tiles" that I need to activate?
EDIT: I got the same problem again. I can see the train in the tunnel clicking on its entrance, but only one train enters into it... There's something else besides "Simulate signals in tunnels and bridges every N tiles" that I need to activate?
Spanish translation of OpenTTD
Extended heightmaps
Have fun, don't quarrel too much and add as many advanced settings as you can.
Extended heightmaps
Have fun, don't quarrel too much and add as many advanced settings as you can.
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: signals in tunnels and on bridges V20 r16507
Did you read this? Is it possible you did not activate the feature?Terkhen wrote:but only one train enters into it...
I checked it but everything working allright.
You have to be more specific please or send me save game by PM.
Regards
Re: signals in tunnels and on bridges V20 r16507
I was missing this:
I suppose that was added since I tried the patch the last time. Thanks, it is working now!Making it a tunnel / bridge with signals just build a signal on the entrance.
Spanish translation of OpenTTD
Extended heightmaps
Have fun, don't quarrel too much and add as many advanced settings as you can.
Extended heightmaps
Have fun, don't quarrel too much and add as many advanced settings as you can.
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: signals in tunnels and on bridges V21 r16573
Well I managed to plant a signal on the entrance of tunnel or bridge.
Placing it works the same as on normal rail.
The function of it is to indicate that a bridge/tunnel has signal simulation.
You can toggle the signals in order to make a one-way or a two-way tunnel/bridge.
I did not have much time to test it and I expect still some minor buggs.
Seefirst page for patch
Regards HackaLittleBit
Placing it works the same as on normal rail.
The function of it is to indicate that a bridge/tunnel has signal simulation.
You can toggle the signals in order to make a one-way or a two-way tunnel/bridge.
I did not have much time to test it and I expect still some minor buggs.
Seefirst page for patch
Regards HackaLittleBit
- Attachments
-
- with signal.png (21.96 KiB) Viewed 5274 times
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: signals in tunnels and on bridges V21 r16573
Ok some minor bug fixes.
Fixed transparecy problem on bridges with signal
Signal on bridge flips when train passes.
Code clean up.
Patch
Regards
Fixed transparecy problem on bridges with signal
Signal on bridge flips when train passes.
Code clean up.
Patch
Regards
Who is online
Users browsing this forum: No registered users and 19 guests