Traffic lights (r17455)

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

Eddi
Tycoon
Tycoon
Posts: 8271
Joined: 17 Jan 2007 00:14

Re: Traffic lights (r17455)

Post by Eddi »

the typical process of "bumping" goes like this:
  1. pick the last known "good" revision
  2. compile, to check whether things work
  3. apply the patch to that revision
  4. compile, to check whether things work (possibly also run some functionality tests)
  5. pick a step size (100 revisions seems to be a good start)
  6. run an update for this step size
  7. check if there were merge errors
  8. compile, to check whether things work (possibly also run some functionality tests)
    1. if things worked, save your current progress in a new patch file, and go back to step 1, until you reached the current revision.
    2. in simple cases, you try to fix the errors directly by looking at the context, then proceed with step 7
    3. if nothing helps, go back to step 1, and choose a smaller step size in step 5, to isolate which revision failed, then check that revision for clues how to fix your errors (often it contains similar changes in other places)
knowledge in programming languages are necessary for step 9b/c

you should not try to bump two patches simultaneously. bump each patch individually and then merge them in the end.
User avatar
Streckenläufer
Engineer
Engineer
Posts: 57
Joined: 22 Jun 2012 14:45
Location: Berlin-Germany

Re: Traffic lights (r17455)

Post by Streckenläufer »

Hello,
the patch has so far worked out quite well, except for the 2 bugs that I've described here last post.
MfG Streckenläufer
OpenTTD V1.7.1, r27930 - Trafficlight - Bridge/tunnel Signals - Watertunnel - HousePlacing - SeaplaneAirport - Clipboard - Win7 64bit - MinGW/msys
!Sorry for my google English translator!
User avatar
Streckenläufer
Engineer
Engineer
Posts: 57
Joined: 22 Jun 2012 14:45
Location: Berlin-Germany

Re: Traffic lights (r17455)

Post by Streckenläufer »

Hello,

I trafficlights_r24349.diff "Apply SVN patch" to run properly.
If I start a new game I'm going to Advanced Settings> construction and I am now on the setting "Traffic Lights" is click the above is the error message:

Message: Assertion failed at line 59 of D :/ Spielen/OTTDSource/MinGW/msys/1.0/home/emily/svn.openttd.org/trunk/src/strings_func.h: size <= parent.num_param - parent.offset

OpenTTD hangs.
MfG Streckenläufer
OpenTTD V1.7.1, r27930 - Trafficlight - Bridge/tunnel Signals - Watertunnel - HousePlacing - SeaplaneAirport - Clipboard - Win7 64bit - MinGW/msys
!Sorry for my google English translator!
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2822
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Traffic lights (r17455)

Post by ChillCore »

Yes I have noticed that the patch crasches in this case (after you mentioning it).

There are some errors in the language files that I am trying to solve and should fix the issue.
Almost there. ;)


My understanding of the German language is not that good.
Can you please tell me about the second error that you mentioned?

Thank you for reporting.
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
User avatar
Streckenläufer
Engineer
Engineer
Posts: 57
Joined: 22 Jun 2012 14:45
Location: Berlin-Germany

Re: Traffic lights (r17455)

Post by Streckenläufer »

Hello chill core,
The second error was caused by me when I tried to translate to the language file englisch.txt ind german.txt, then came the error:

Warning: Param idx # 0 'STRING' does not match with template command 'String1'

Look here, the black DOS window.

The patch does not translate german.txt to Settings> Construction now when I click the option "traffic light" then click on the warning window appears and goes out with OpenTTD crash.log.
Attachments
compiler_fehler.jpg
compiler_fehler.jpg (281.02 KiB) Viewed 614 times
trafficlight_fehler.jpg
trafficlight_fehler.jpg (17.9 KiB) Viewed 614 times
crash.txt
(20.79 KiB) Downloaded 137 times
MfG Streckenläufer
OpenTTD V1.7.1, r27930 - Trafficlight - Bridge/tunnel Signals - Watertunnel - HousePlacing - SeaplaneAirport - Clipboard - Win7 64bit - MinGW/msys
!Sorry for my google English translator!
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2822
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Traffic lights (r17455)

Post by ChillCore »

The picture "compiler_fehler.jpg" suggest multiple things:
- you did not use "STRING1" in the german translation did you? STRINGx is reserved for the english strings ... other languages are supposed to use STRING here (I changed STRING1 to STRING2 for now in english.txt to avoid the crash).
- There is a line mentioning the use of the same string twice ... you did not apply the patch twice without reverting the new files to dummy files did you?
- You should upgrade your version of svn as it is outdated ;)

The assertion that happens in "trafficlight_fehler.jpg" is due to the errors that I have partially solved in the language files (I think).
The crash does no longer happen in the attached patch but there still is an error present; when you set "Advanced Settings -> Construction -> Trafficlights -> Maximum TL consist size" to zero then a date will appear.
The date appearing is the first error; being able to set it to "zero" is the second as the minimum is specified as 1 in table/settings.ini.
I absolutely have no clue yet why this happens.

The crash.txt you attached sais "Version: r (0)" ... how did you obtain the source of OpenTTD? Did you dowload the zip from openttd.org and patch that?
Better is to check out the source using your SVN client as instructed here http://wiki.openttd.org/Category:Compiling_OpenTTD ; that way your source is under version control and you will be able to update it to a different revision. ;)
Attachments
trafficlights_r24357.diff
(58.29 KiB) Downloaded 222 times
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
User avatar
Streckenläufer
Engineer
Engineer
Posts: 57
Joined: 22 Jun 2012 14:45
Location: Berlin-Germany

Re: Traffic lights (r17455)

Post by Streckenläufer »

Hello chill core,

I update my trunk after each revision, the revision number was from the beginning, since I use TortoiseSVN, not sent or registered. I have the latest version of TortoiseSVN v1.7.7 and still get the "Subversion 1.7 or greater" message. I already have about 10-15 Compiles and revisions can live with that without number.

Yes, I have the *. source.zip these patches from the trunk and is updated each version from the trunk.
I have now and get your trafficlights_r24349.diff the warning window patching.
Attachments
abgelehnt_1.jpg
abgelehnt_1.jpg (54.2 KiB) Viewed 614 times
abgelehnt_2.jpg
abgelehnt_2.jpg (39.95 KiB) Viewed 5262 times
neuer_fehler.jpg
neuer_fehler.jpg (209.73 KiB) Viewed 614 times
MfG Streckenläufer
OpenTTD V1.7.1, r27930 - Trafficlight - Bridge/tunnel Signals - Watertunnel - HousePlacing - SeaplaneAirport - Clipboard - Win7 64bit - MinGW/msys
!Sorry for my google English translator!
Eddi
Tycoon
Tycoon
Posts: 8271
Joined: 17 Jan 2007 00:14

Re: Traffic lights (r17455)

Post by Eddi »

you use tortoisesvn to check out openttd, but the build system tries to use the command line svn (to find out version, changes, etc.), which is somewhere in your path, but it is an older version, thus it cannot read the checkout you did with tortoisesvn. that is the error message you get.
User avatar
Streckenläufer
Engineer
Engineer
Posts: 57
Joined: 22 Jun 2012 14:45
Location: Berlin-Germany

Re: Traffic lights (r17455)

Post by Streckenläufer »

Hello Eddie,

my version of TortoiseSVN is the latest, which is the latest OpenTTD source, subversion is the latest.
The message is the same.

I remove old versions before installing new versions of its full length.
This is not the actual fault, which lies somewhere in the processing of the language file for patching.

I've already added several patches and received no error messages. The warning of an older Subversion I have often, but not intrusive and does not affect the compiler.
MfG Streckenläufer
OpenTTD V1.7.1, r27930 - Trafficlight - Bridge/tunnel Signals - Watertunnel - HousePlacing - SeaplaneAirport - Clipboard - Win7 64bit - MinGW/msys
!Sorry for my google English translator!
Eddi
Tycoon
Tycoon
Posts: 8271
Joined: 17 Jan 2007 00:14

Re: Traffic lights (r17455)

Post by Eddi »

read again. this is not about your version of TortoiseSVN, but your version of the command line svn (likely installed through cygwin or mingw). these are both svn clients, but they are different programs. like Firefox and Internet Explorer are both browsers, but each is a completely separate program, with different versions
User avatar
Streckenläufer
Engineer
Engineer
Posts: 57
Joined: 22 Jun 2012 14:45
Location: Berlin-Germany

Re: Traffic lights (r17455)

Post by Streckenläufer »

#Eddi,

It is about the subversion folder in the TortoiseSVN / bin / svn.exe and not the MinGW is the latest.
In the forum of TortoiseSVN described that can occur with a change in the language file from English to German this message if I keep the English language file I get no message bem compilation.

#ChillCore,

have now re-installed everything again, and the traffic light patch Compiles, now get the following error message.
It seems to affect only the English language file.
Attachments
language_error.jpg
language_error.jpg (8.66 KiB) Viewed 4737 times
MfG Streckenläufer
OpenTTD V1.7.1, r27930 - Trafficlight - Bridge/tunnel Signals - Watertunnel - HousePlacing - SeaplaneAirport - Clipboard - Win7 64bit - MinGW/msys
!Sorry for my google English translator!
User avatar
Streckenläufer
Engineer
Engineer
Posts: 57
Joined: 22 Jun 2012 14:45
Location: Berlin-Germany

Re: Traffic lights (r17455)

Post by Streckenläufer »

ok, it worked, it goes :)
MfG Streckenläufer
OpenTTD V1.7.1, r27930 - Trafficlight - Bridge/tunnel Signals - Watertunnel - HousePlacing - SeaplaneAirport - Clipboard - Win7 64bit - MinGW/msys
!Sorry for my google English translator!
User avatar
kyosuke1989
Transport Coordinator
Transport Coordinator
Posts: 273
Joined: 24 Mar 2008 13:04
Location: Finland

Re: Traffic lights (r17455)

Post by kyosuke1989 »

Is this feature mature enough for trunk if everything works as excepted? It could be nice in larger, and why not smaller cities. :)
User avatar
Raihan Yafie
Engineer
Engineer
Posts: 2
Joined: 13 May 2013 13:44
Location: Bekasi

Re: Traffic lights (r17455)

Post by Raihan Yafie »

can i installed to my openTTD?
User avatar
kamnet
Moderator
Moderator
Posts: 8587
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: Traffic lights (r17455)

Post by kamnet »

Raihan Yafie wrote:can i installed to my openTTD?
You have to download the source code for OpenTTD and then apply the Traffic Lights patch to the code. Then you must include the additional NewGRF for graphics with the binary.
emiel17
Engineer
Engineer
Posts: 2
Joined: 14 Jun 2013 18:00

Re: Traffic lights (r17455)

Post by emiel17 »

When i start openttd with traffic lights it says that there are no files for the game please help
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2822
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Traffic lights (r17455)

Post by ChillCore »

Welcome to the forums, emiel17

http://www.tt-forums.net/viewtopic.php? ... &start=147

At the bottom of the post are the correct sprites you need.
There should be a readme in the zip?

If you need more help then this do not hesitate to ask. ;)
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
emiel17
Engineer
Engineer
Posts: 2
Joined: 14 Jun 2013 18:00

Re: Traffic lights (r17455)

Post by emiel17 »

well my next question is does it work on the 1.3.1 version of openttd?
User avatar
ChillCore
Tycoon
Tycoon
Posts: 2822
Joined: 04 Oct 2008 23:05
Location: Lost in spaces

Re: Traffic lights (r17455)

Post by ChillCore »

It would if someone(TM) updated it.
But there is little point in doing that anyway, better is to keep patches against trunk itself when updating. ;)
-- .- -.-- / - .... . / ..-. --- .-. -.-. . / -... . / .-- .. - .... / -.-- --- ..- .-.-.-
--- .... / -.-- . .- .... --..-- / .- -. -.. / .--. .-. .- .. ... . / - .... . / .-.. --- .-. -.. / ..-. --- .-. / .... . / --. .- ...- . / ..- ... / -.-. .... --- --- -.-. .... --- --- ... .-.-.- / ---... .--.

Playing with my patchpack? Ask questions on usage and report bugs in the correct thread first, please.
All included patches have been modified and are no longer 100% original.
3298
Traffic Manager
Traffic Manager
Posts: 143
Joined: 02 Apr 2011 12:55

Re: Traffic lights (r17455)

Post by 3298 »

Patches are never made for any stable version of OpenTTD because modifying it means it isn't the same stable game anymore.
Also, the 1.3 series is roughly r25000 with a bunch of bugfixes backported from trunk. Current trunk is at roughly r25400. This patch is for r17455. That's quite a big difference, so it is almost certainly not compatible. I once updated a patch that was a bit more than 2000 revisions behind trunk. That was difficult enough. Now with almost 8000 revisions to go, you would spend several weeks with the update, coding. If you don't know C++, add some more weeks to learn it.
But I believe ChillCore has a heavily modified version of this patch in his patchpack based on r22555. You can play that one instead, even though it's still older than 1.2.

PS: Ninja'd by the one I'm talking about, why didn't you advertise your own patchpack?
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 21 guests