[Patch] Departure boards, 24h clock + binary 25 (r27452)

Forum for technical discussions regarding development. If you have a general suggestion, problem or comment, please use one of the other forums.

Moderator: OpenTTD Developers

User avatar
Norfolkadam
Engineer
Engineer
Posts: 77
Joined: 11 Jun 2010 19:16
Location: Norfolk, UK
Contact:

Re: [Patch] Departure boards, 24h clock + binary

Post by Norfolkadam »

hthhs wrote:
Norfolkadam wrote:When you set a station to "no unloading" it doesn't show on the "Calling at:" section. Can you add an option so that it does?
Done.

I've also updated the patch to current trunk, and handled automatic orders as best I can.
Ah sweet thank you've made my day.
Helmland - The English and Danish island in the North Sea
User avatar
Norfolkadam
Engineer
Engineer
Posts: 77
Joined: 11 Jun 2010 19:16
Location: Norfolk, UK
Contact:

Re: [Patch] Departure boards, 24h clock + binary

Post by Norfolkadam »

So I'm new to all this patching malarkee. I've spent the best side of two hours compiling and typing lines of text and I finally get a compiled version of the latest build. I download the Tortoise patching programme and patch it using the latest diff you've put up. However it doesn't seem to have done anything, I have no departure boards yet when I was just using the old version that wasn't a patch it was fine.

Am I missing a step here (I'm sure I am). I've compiled OTTD. I've applied the patch. ...
Helmland - The English and Danish island in the North Sea
Yexo
Tycoon
Tycoon
Posts: 3663
Joined: 20 Dec 2007 12:49

Re: [Patch] Departure boards, 24h clock + binary

Post by Yexo »

You should patch the source code. If you've done that correctly you have to compile the code again. The resulting binary will have the patch you used.
User avatar
Norfolkadam
Engineer
Engineer
Posts: 77
Joined: 11 Jun 2010 19:16
Location: Norfolk, UK
Contact:

Re: [Patch] Departure boards, 24h clock + binary

Post by Norfolkadam »

Yexo wrote:You should patch the source code. If you've done that correctly you have to compile the code again. The resulting binary will have the patch you used.
I tried to compile it again (I figured that was probably the missing step) and I got an error a la:

Code: Select all

[SRC] Compiling ai/ai_core.cpp
In file included from c:/ottd/src/ai/..window_func.h:15:0,
from c:/ottd/src/ai/ai_core.cpp:18:
c:/ottd/src/ai/../window_type.h:115:2: error: redfinition of 'WC_DEPARTURES_BOARD'
c:ottd/src/ai/..window_type.h:114:2: error: 'WC_DEPARTURES BOARD' previously defined here
make [1]: *** [ai/ai_core.o] Error 1
make [1]: Leaving directory '/c/ottd/objs/release'
make: *** [all] Error 1
And I have no idea what any of that means.
Helmland - The English and Danish island in the North Sea
Yexo
Tycoon
Tycoon
Posts: 3663
Joined: 20 Dec 2007 12:49

Re: [Patch] Departure boards, 24h clock + binary

Post by Yexo »

Have you perhaps applied the patch twice? That could explain it. If so, revert the state (there should be a "revert" button in tortoisesvn) and after that apply the patch again, then compile again.

Other possible explanations why compiling could fail after applying a single patch:
-you applied the patch to another version of openttd than it was made for
-the patch is buggy.
Given the error message you posted neither of these is very likely.
Eddi
Tycoon
Tycoon
Posts: 8258
Joined: 17 Jan 2007 00:14

Re: [Patch] Departure boards, 24h clock + binary

Post by Eddi »

Yexo wrote:Have you perhaps applied the patch twice? That could explain it. If so, revert the state (there should be a "revert" button in tortoisesvn) and after that apply the patch again, then compile again.
this is missing a step: "reverting" the checkout only reverts files that are present in trunk. new files added to the repository by the patch must be deleted manually
User avatar
Norfolkadam
Engineer
Engineer
Posts: 77
Joined: 11 Jun 2010 19:16
Location: Norfolk, UK
Contact:

Re: [Patch] Departure boards, 24h clock + binary

Post by Norfolkadam »

Yexo wrote:Have you perhaps applied the patch twice? That could explain it. If so, revert the state (there should be a "revert" button in tortoisesvn) and after that apply the patch again, then compile again.

Other possible explanations why compiling could fail after applying a single patch:
-you applied the patch to another version of openttd than it was made for
-the patch is buggy.
Given the error message you posted neither of these is very likely.
If you were here right now I would kiss you. It's 3:40 and I think I've finally go this ok. It's compiling as we speak. I'll let you know if it works in about 20 minutes.
Helmland - The English and Danish island in the North Sea
User avatar
Norfolkadam
Engineer
Engineer
Posts: 77
Joined: 11 Jun 2010 19:16
Location: Norfolk, UK
Contact:

Re: [Patch] Departure boards, 24h clock + binary

Post by Norfolkadam »

Got as far as compiling departures.cpp and then this:
argh.PNG
(278.74 KiB) Downloaded 3 times
Helmland - The English and Danish island in the North Sea
Eddi
Tycoon
Tycoon
Posts: 8258
Joined: 17 Jan 2007 00:14

Re: [Patch] Departure boards, 24h clock + binary

Post by Eddi »

that's one of the newly added files i talked about. open it in an editor, and remove anything after the first duplicate line
User avatar
Norfolkadam
Engineer
Engineer
Posts: 77
Joined: 11 Jun 2010 19:16
Location: Norfolk, UK
Contact:

Re: [Patch] Departure boards, 24h clock + binary

Post by Norfolkadam »

Eddi wrote:that's one of the newly added files i talked about. open it in an editor, and remove anything after the first duplicate line
Ah okey doke. Well because that sounds like something I'd muck up I've re-downloaded my source, patched it (just the once this time :oops: ) and I'm re-compiling. I'll let you know how this goes.
Helmland - The English and Danish island in the North Sea
User avatar
Norfolkadam
Engineer
Engineer
Posts: 77
Joined: 11 Jun 2010 19:16
Location: Norfolk, UK
Contact:

Re: [Patch] Departure boards, 24h clock + binary

Post by Norfolkadam »

So I started doing this at about 11pm and it's now 4:36am and I've finally got it right.

Hooray. Thanks for all your help.
Helmland - The English and Danish island in the North Sea
Aylo
Traffic Manager
Traffic Manager
Posts: 198
Joined: 11 Apr 2007 16:47

Re: [Patch] Departure boards, 24h clock + binary

Post by Aylo »

You did it!

I started a game, built a small network with about 5 lines and SPENT ONE HOUR just watching this Depature board with all the delayed trains !!

GREAT JOB :bow:
User avatar
maselbe
Engineer
Engineer
Posts: 65
Joined: 13 May 2009 12:25

Re: [Patch] Departure boards, 24h clock + binary

Post by maselbe »

I downloaded the win32 binary and tested your patch and it worked like a charm.
But a few day's back I created a scenario and when I started playing it, the game frequently crashed.
Do you still bug fix this patch and if so do I post a savegame here along with my newgrf list?
hthhs
Engineer
Engineer
Posts: 107
Joined: 03 Sep 2010 12:58
Location: London, UK

Re: [Patch] Departure boards, 24h clock + binary

Post by hthhs »

maselbe wrote: Do you still bug fix this patch and if so do I post a savegame here along with my newgrf list?
Yes (assuming the crash is the fault of this patch) and yes.
User avatar
maselbe
Engineer
Engineer
Posts: 65
Joined: 13 May 2009 12:25

Re: [Patch] Departure boards, 24h clock + binary

Post by maselbe »

Well i'm assuming it has to be something with the patch, because it's the only thing different from my normal games. If not my apologies.
I'm also playing with the streettraffic AI.
Attachments
Error Message
Error Message
OpenTTDDepartBoardCrashErrMsg.jpg (13.78 KiB) Viewed 3976 times
NewGRF List
NewGRF List
OpenTTDDepartBoardCrashNewGRF.jpg (62.91 KiB) Viewed 3976 times
OpenTTDDepartBoardCrash.sav
Save Game
(116.82 KiB) Downloaded 133 times
oberhümer
Tycoon
Tycoon
Posts: 1283
Joined: 23 Oct 2009 19:35
Location: Here and there, sometime or another

Re: [Patch] Departure boards, 24h clock + binary

Post by oberhümer »

It doesn't look like it has anything to do with the patch, the game's apparently checking the position of a vehicle on a tile, which is something this should not affect. Try to recreate the same situation with unpatched OpenTTD.
--- Licenses: GNU LGPL, version 2 or newer, code and graphics. CC-By-SA, graphics, alternatively. If you're using any, I'd like to hear about it --- Call them "track types" ---
--- Mostly inactive developer for: NuTracks - Central European Train Set --- Running/compiling for: Linux (x86) - Android - Windows (32/64 bit) ---

--- Need a file packer? 7-Zip --- BOINC - use your computing power to benefit science --- Block trackers, not ads --- Unix in dispersible pellets, the formula for the future. ---
User avatar
maselbe
Engineer
Engineer
Posts: 65
Joined: 13 May 2009 12:25

Re: [Patch] Departure boards, 24h clock + binary

Post by maselbe »

oberhümer wrote:It doesn't look like it has anything to do with the patch, the game's apparently checking the position of a vehicle on a tile, which is something this should not affect. Try to recreate the same situation with unpatched OpenTTD.
Played the same scenario with the latest stable and same NewGRF files and that game doesn't crash.
I'll try loading the saved game I posted here into the stable and will check if the crash occurs.
hthhs
Engineer
Engineer
Posts: 107
Joined: 03 Sep 2010 12:58
Location: London, UK

Re: [Patch] Departure boards, 24h clock + binary

Post by hthhs »

It isn't a fair comparison unless you test it with unpatched r21920, as it may contain bugs that are not present in the latest stable.

The crash does occur with unpatched r21920, so it's not the fault of the patch.
User avatar
maselbe
Engineer
Engineer
Posts: 65
Joined: 13 May 2009 12:25

Re: [Patch] Departure boards, 24h clock + binary

Post by maselbe »

hthhs wrote:It isn't a fair comparison unless you test it with unpatched r21920, as it may contain bugs that are not present in the latest stable.

The crash does occur with unpatched r21920, so it's not the fault of the patch.
So if I understand correctly it is the r21920 release of openttd that causes the crash ?
Is it possible to change the offered win32 binary to a newer (more stable) version ?
hthhs
Engineer
Engineer
Posts: 107
Joined: 03 Sep 2010 12:58
Location: London, UK

Re: [Patch] Departure boards, 24h clock + binary

Post by hthhs »

Done.
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: Ahrefs [Bot], Semrush [Bot] and 7 guests