Page 12 of 14

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 20 Sep 2012 15:56
by FLHerne
FaantBoy501 wrote:Hello All, I also have been trying to apply this Signal in Tunnel patch, but with little succes. Am not an expert at this, sadly, but I managed to use TortoiseSVN 1.7.9 and OpenTTD Trunk R24534.
When I try to apply the patch itself, it gives me around 5 faulty messages. But I really don't have a clue how to solve this. Maybe someone can help me out with this. Thx in advance.
If you're using a version posted in this thread, you'll need to apply it to the appropriate OpenTTD version (r24031, unless I missed a more recent one). As far as I can tell, Streckenläufer hasn't posted his updated version here.

@Streckenläufer: Would you mind posting your version? It would save me some time duplicating it :P .

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 20 Sep 2012 16:48
by FaantBoy501
aa oke that would be great thx in advance.

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 25 Sep 2012 19:23
by Streckenläufer
Hello,

my last working version is trunk/r24551

Signals in tunnels, Traffic Light, Tunnel under water

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 25 Sep 2012 20:50
by FLHerne
I meant, could you post the patch file for that so that other people (like me) can use it? :wink:

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 25 Sep 2012 23:02
by Quast65
Signals in tunnels, Traffic Light, Tunnel under water
Exactly the three patches I would like to use combined in a game! :D
I meant, could you post the patch file for that so that other people (like me) can use it?
Indeed, pretty please with sugar on top! :bow:

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 21 Feb 2013 23:58
by pravdomil
Hi, I updated this nice patch to work with revision 25033.
What we shall do to have it in official release?

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 22 Feb 2013 16:16
by kyosuke1989
I believe that someone has "the less hacky way" of implementing this feature in works in some point of future. This current implementation does not allow you to implement signals same way as on track.

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 22 Feb 2013 17:28
by FLHerne
pravdomil wrote:What we shall do to have it in official release?
Even if this implementation was ever likely to reach trunk (it won't, due to being hacky and inflexible gameplay-wise), it still has several quite serious bugs that would prevent it from doing so:
- It just doesn't work at all with path signals (not only can you not put them in tunnels, placing path signals immediately before or after tunnels causes loads of bugs). With many/most players using path signals for almost everything, this is a big problem.
- The first train arriving at a newly-signalled tunnel often stops, despite it being clear, and has to be forced through.
- When stopping trains at the signals, it doesn't properly set the power/load/whatever - trains continue to produce smoke at the maximum rate, and are charged the same running costs as for accelerating. Similarly, they're shown as '0mph' rather than 'Waiting for path'.
- For some reason, it displays a signal facing in the wrong direction at the exit end of the bridge.
- Sometimes, for no apparent reason, trains just ignore the signals and crash into the ones in front. I couldn't see a pattern, but that might be because it only happens rarely.

Of course, as a constant user of this patch, I'd love it if anyone did fix any of the above. I suspect they'd be wasting their time though, as the devs would be unlikely to accept a patch based on this even without any bugs :( .

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 12 Jul 2013 18:05
by Ferrarius
Actually, the signal at the end of the tunnel/bridge is quite helpful if one wants to quickly see in what direction the tunnel signals have been built.

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 12 Jul 2013 18:16
by bcmpinc
Another reason why this patch would not be included in trunk is the following. Consider this piece of "src/tables/settings.ini", that is added by the patch:

Code: Select all

[SDTC_VAR]
var      = gui.simulated_wormhole_signals
type     = SLE_UINT8
flags    = SLF_NOT_IN_SAVE | SLF_NO_NETWORK_SYNC
def      = 2
min      = 1
max      = 16
str      = STR_CONFIG_SETTING_SIMULATE_SIGNALS
strval   = STR_CONFIG_SETTING_SIMULATE_SIGNALS_VALUE
proc     = RedrawScreen
There are two issues. One minor one, the setting does not belong to gui. And one major one, the client can use a different setting than the server. This will guarantee that a multi-player game will desync.

If I don't forget, I will put a version of this patch, that applies to current trunk and fixes this issue, here within a few days.

Oh and FLHerne, thanks for pointing out the other bugs. If I want to include this patch in my patch pack, I will have to fix some of those bugs as well.

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 12 Jul 2013 20:14
by pravdomil
Its time to create some Git or Hg repo for this patch, can somebody create it?

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 12 Jul 2013 22:02
by bcmpinc
I have created https://github.com/bcmpinc/openttd, which contains this patch, as well as various other patches.

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 13 Jul 2013 13:11
by bcmpinc
Updated to trunk and fixed desync bug.

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 12 Aug 2013 21:51
by Vaulter
is it only for me? I have red signals at fresh built bridge-signals : searching for the wrong code and cannot find any
:?:

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 15 Aug 2013 11:43
by bcmpinc
A yes, that is an eye-candy feature. It has absolutely no purpose other than showing that it is a bridge with signals. Trains ignore that signal completely. Note that on bridges you can only have one-way signals.

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 09 Sep 2013 03:00
by Redirect Left
bcmpinc wrote:A yes, that is an eye-candy feature. It has absolutely no purpose other than showing that it is a bridge with signals. Trains ignore that signal completely. Note that on bridges you can only have one-way signals.
That is a bit misleading to the actual player though. I'd suggest coming up with a seperate way of indicating it is a signalled bridge (other than i dunno...it having signals on it). I did read somewhere on these forums a while back that there are unused signal sprites, perhaps use one of them? Note that I have no idea if these sprites still exist, if they ever did, i'm sure a dev will know for sure, I also don't know what they look(ed) like, so I'm unsure of suitability, may be worth looking into though, as a red signal is a bit misleading, at least in my opinion ;)

On the plus side, it's a very interesting patch and works well enough for the job it does, I hope one day someone can patch it up enough to make it valid for inclusion by default, but I think it may be a terrible amount of work, sadly :(

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 27 Sep 2013 00:01
by Steijn
Hi, can someone update this fantastic patch to the current trunk? I tried the latest release but I get errors when I try to apply the patch. I tried solving it myself, but unfortunately I can't get it right (probably due my limited programming skills :oops: ). If it's not that much work, help would be appreciated very much. :bow:

This is the error report:
patching file src/rail_cmd.cpp
...
Hunk #2 FAILED at 1025.
...
1 out of 8 hunks FAILED -- saving rejects to file src/rail_cmd.cpp.rej

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 27 Sep 2013 07:46
by MasterMeNL
Did you use signaltunnel_V3.03.r25593 posted above or the one in the main post? Because I think that the first one still should apply cleanly to trunk.
If you not tell me and I'll update it.

Also, I think I found a bug in this.
When a path signal checks a bridge or tunnel with signals the game crashes over here, although this is with my own patch pack (it's in my signature) so the problem may lie with some other patches instead of this one but I doubt it.

Can anyone confirm this?

Regards,

Melvin.

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 27 Sep 2013 09:07
by Steijn
Hmmm, seems I used signaltunnel_V3.02_r25033.patch :oops: , now I tried to apply signaltunnel_V3.03.r25593.patch on trunk 25799 and I still get some, but different, errors.
[...]
patching file src/saveload/saveload.cpp
Hunk #1 FAILED at 251.
1 out of 1 hunk FAILED -- saving rejects to file src/saveload/saveload.cpp.rej
patching file src/saveload/saveload.h
Hunk #1 FAILED at 89.
1 out of 1 hunk FAILED -- saving rejects to file src/saveload/saveload.h.rej
[...]
Further I tried to verify your bugreport, but I can't replicate it. I used OpenTTD 1.3.2 stable release with signaltunnel_V3.02_r25033.patch and chunnelv20_r24097.patch applied to it. I made the following tracksetup (and sent a train over it):
noproblem.png
noproblem.png (15.53 KiB) Viewed 6694 times
Everything works fine here, perhaps you can provide a savegame with the tracksetup you used. :)

Re: Signals in tunnels and on bridges V3.02 r24031

Posted: 27 Sep 2013 14:48
by MasterMeNL
Thanks for verifying this.
I decided to test all of my builds to find the culprit and it is ATC Speed Control, turning it off fixing the problems even in the latest builds!

I'll try to fix this problem, but I may not be able to.
ATC Speed Control doesn't like checking those "weird" signals on "impossible" places I guess.

Regards,

Melvin.

P.S. Want to play co-op sometime?