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

Trond
Tycoon
Tycoon
Posts: 973
Joined: 25 Jan 2008 07:32
Location: Gamle Ørnenuten

Re: Traffic lights (alpha 2; r12436)

Post by Trond »

As requested in the patchpack thread, here's a build with latest (r12436) version of trafficlight patch for win32. The trafficlight.grf is NOT inlcuded, so you need to grab that from 1st post in this thread. Enjoy.
..: Trond :.. because you deserve it! Image

The whole problem with the world is that fools and fanatics are always so certain of themselves,
and wiser people so full of doubts.
Bertrand Russell

MyGRFs: Norwegian Funny Town Names 4 | LOTR & WoW Town Names 2 | Islandic Town Names 1 | Random Norwegian Town Names
Favorites: GRFCrawler | ISR | WIKI | Now Playing: OpenTTD 1.3.2 w/YAPP 3.0-RC3.9ish
zypa
Transport Coordinator
Transport Coordinator
Posts: 329
Joined: 30 Mar 2006 12:05
Location: Germany
Contact:

Re: Traffic lights (alpha 2; r12436)

Post by zypa »

Thank you again Trond!
Roujin
Tycoon
Tycoon
Posts: 1884
Joined: 08 Apr 2007 04:07

Re: Traffic lights (v1; r12628)

Post by Roujin »

v1 released!

Check the first post for changelog and so on...

Have fun! :)
Attachments
trafficlights_v1_r12628.diff
trafficlights v1 for r12628
(35.89 KiB) Downloaded 257 times
* @Belugas wonders what is worst... a mom or a wife...
<Lakie> Well, they do the same thing but the code is different.

______________
My patches
check my wiki page (sticky button) for a complete list

ImageImage
ImageImageImageImageImageImageImage
Gekko
Engineer
Engineer
Posts: 8
Joined: 13 Apr 2008 10:30

Re: Traffic lights (v1; r12628)

Post by Gekko »

Can we get this patch updated to the latest trunk please?
Roujin
Tycoon
Tycoon
Posts: 1884
Joined: 08 Apr 2007 04:07

Re: Traffic lights (v1; r12628)

Post by Roujin »

Sure, here it is.
Attachments
trafficlights_v1_r12733.diff
traffic lights v1 for r12733
(35.95 KiB) Downloaded 283 times
* @Belugas wonders what is worst... a mom or a wife...
<Lakie> Well, they do the same thing but the code is different.

______________
My patches
check my wiki page (sticky button) for a complete list

ImageImage
ImageImageImageImageImageImageImage
Gekko
Engineer
Engineer
Posts: 8
Joined: 13 Apr 2008 10:30

Re: Traffic lights (v1; r12733)

Post by Gekko »

My thanks.
User avatar
Ammler
President
President
Posts: 953
Joined: 18 Jun 2006 18:18
Location: Switzerland
Contact:

Re: Traffic lights (v1; r12733)

Post by Ammler »

Roujin wrote:Traffic Lights v1 released! (r12628)

Changelog for v1:
Feature:
- Owner check. Now, you aren't allowed to build or remove traffic lights on opponents' or towns' roads any more.
Shouldn't it be possible to have that switchable like roadstops in town owned roads?

Edit: Maybe, you could use the same switch, so you don't spam the patch setting window. ;-)
(rename to something like "Allow company to build on town owned roads.")

Greets
Ammler
Last edited by Ammler on 18 Apr 2008 09:53, edited 3 times in total.
User avatar
Zephyris
Tycoon
Tycoon
Posts: 2890
Joined: 16 May 2007 16:59

Re: Traffic lights (v1; r12733)

Post by Zephyris »

Shouldn't it be possible to have that switchable like roadstops in town owned roads?
I was going to suggest that too...
User avatar
SirXavius
Transport Coordinator
Transport Coordinator
Posts: 302
Joined: 28 Jun 2006 18:25
Location: Florida

Re: Traffic lights (v1; r12733)

Post by SirXavius »

OK help me out. What do i do with the .diff file? I'd love to use working traffic signals as part of my setup...

I'm using OTTD under Win98 (emulation), if that matters..
Trond
Tycoon
Tycoon
Posts: 973
Joined: 25 Jan 2008 07:32
Location: Gamle Ørnenuten

Re: Traffic lights (v1; r12733)

Post by Trond »

Check the thread for BOTTD, i think that BOTTD works under win98 but I'm not certain... http://www.tt-forums.net/viewtopic.php?f=33&t=31823
..: Trond :.. because you deserve it! Image

The whole problem with the world is that fools and fanatics are always so certain of themselves,
and wiser people so full of doubts.
Bertrand Russell

MyGRFs: Norwegian Funny Town Names 4 | LOTR & WoW Town Names 2 | Islandic Town Names 1 | Random Norwegian Town Names
Favorites: GRFCrawler | ISR | WIKI | Now Playing: OpenTTD 1.3.2 w/YAPP 3.0-RC3.9ish
User avatar
SirXavius
Transport Coordinator
Transport Coordinator
Posts: 302
Joined: 28 Jun 2006 18:25
Location: Florida

Re: Traffic lights (v1; r12733)

Post by SirXavius »

Are you crazy??!! :o I just looked at that thread, and at the very last post they're STILL having problems. THAT's something i don't wanna deal with.....
Trond
Tycoon
Tycoon
Posts: 973
Joined: 25 Jan 2008 07:32
Location: Gamle Ørnenuten

Re: Traffic lights (v1; r12733)

Post by Trond »

:lol: works fine for me. Set up BOTTD (check wiki) and load patch, compile, copy files and play... Works like a charm. On the last page it's probably not the same persons having problems as on page 1 :D
..: Trond :.. because you deserve it! Image

The whole problem with the world is that fools and fanatics are always so certain of themselves,
and wiser people so full of doubts.
Bertrand Russell

MyGRFs: Norwegian Funny Town Names 4 | LOTR & WoW Town Names 2 | Islandic Town Names 1 | Random Norwegian Town Names
Favorites: GRFCrawler | ISR | WIKI | Now Playing: OpenTTD 1.3.2 w/YAPP 3.0-RC3.9ish
User avatar
Ammler
President
President
Posts: 953
Joined: 18 Jun 2006 18:18
Location: Switzerland
Contact:

Re: Traffic lights (v1; r12733)

Post by Ammler »

SirXavius wrote: I'm using OTTD under Win98 (emulation),
SirXavius wrote:Are you crazy??!! :o
Who is crazy? :P

Greets
Ammler

P.S.: OTTD supports many platforms, you don't need a emulator or what OS do you natively use?
User avatar
SirXavius
Transport Coordinator
Transport Coordinator
Posts: 302
Joined: 28 Jun 2006 18:25
Location: Florida

Re: Traffic lights (v1; r12733)

Post by SirXavius »

I DESPISE Mac OSX to depths you can't imagine. It didnt take long after first using it, before i realized how un-Mac it is, but seriously don't get me started -- i'll have a coronary.

I use Mac OS 9.2.2 primarily. I access Windows 98SE via Virtual PC 3.0, and from there i have access to many great (and not so great) applications, including OTTD (i forgot how i found you guys). The only downside is that emulation saps 2/3 of my processor speed, which means i'm running Win98 at 133 mHz!
The reason, if you're wondering, why i don't just go get an old used Windows machine is that for music and art production, not even the newest Windows versions can match the simplicity, intuiveness, and professionability of the Mac apps for these kinds of work. And since i have a relatively stable setup with VPC 3.0 with Windows apps that don't need the latest DirectX (i think i can use up to DirectX 7), i'm happy this far behind the technology curve...

You know what they say: the less you want, the less you're disappointed...:wink:


BTW, as far as "compiling" the new .diff file, i'll wait til its in an official release. I do not want to get into dismantling and "remantling" the gamecode. I'll let you suckers -- uh, testers, work out the kinks and prepare it for one of the releases...
Roujin
Tycoon
Tycoon
Posts: 1884
Joined: 08 Apr 2007 04:07

Re: Traffic lights (v1; r12733)

Post by Roujin »

Ammler wrote:Shouldn't it be possible to have that switchable like roadstops in town owned roads?

Edit: Maybe, you could use the same switch, so you don't spam the patch setting window. ;-)
(rename to something like "Allow company to build on town owned roads.")

Greets
Ammler
I thought about that for some time and came to the conclusion that if it were allowed for everyone to remove town owned traffic lights, it wouldn't really make sense. Because they would just remove them if they were obstructed by them.
I'm thinking right now of an example multiplayer game, where player 1 funded road construction in order to obstruct player 2's bus lines (also with the traffic lights erected during road construction).

Then again, there are players who want to play games for the sake of eyecandyness, and for them it would be nice to have full control. So I guess I'll make a patch option for it to make you happy ;) But It'll be a seperate one, because I can imagine someone wanting to allow bus stops on town roads but not allow messing with the towns' traffic lights.


SirXavius: Well it's fine if you don't want to compile something yourself and wait until this is in the official build (if it ever will be, that is), but please do not call others "suckers". Even if you meant it as a joke, it's still not nice ;)
* @Belugas wonders what is worst... a mom or a wife...
<Lakie> Well, they do the same thing but the code is different.

______________
My patches
check my wiki page (sticky button) for a complete list

ImageImage
ImageImageImageImageImageImageImage
User avatar
Gedemon
Traffic Manager
Traffic Manager
Posts: 150
Joined: 29 Apr 2004 21:53

Re: Traffic lights (v1; r12733)

Post by Gedemon »

Thanx for this nice patch Roujin, I really like it, nice to see those busy city center now :mrgreen:


May I suggest adding some pathfinding penalities for traffic lights ?
Roujin
Tycoon
Tycoon
Posts: 1884
Joined: 08 Apr 2007 04:07

Re: Traffic lights (v1; r12733)

Post by Roujin »

Gedemon wrote:Thanx for this nice patch Roujin, I really like it, nice to see those busy city center now :mrgreen:


May I suggest adding some pathfinding penalities for traffic lights ?

Hmm interesting request. I've thought about that long time ago but forgot about it. Maybe now it is the right time for me to dig a little deeper and try to do this.

I've now made the requested patch switch for building and removing TLs on town roads. But I'll look if I can do what Gedemon requested first before making a new release..


edit: by the way, nice to have some answers here from people who like this patch :) it's motivating me ;)

edit²: Gedemon, would you like the penalty to be additional to the crossing penalty, or independant from it? If it is independant, you could even set it lower than the crossing penalty to encourage roadvehicles to use traffic lighted crossings (despite that being not really useful). Or should I do it additional, meaning total penalty = crossing penalty + trafficlight penalty?
* @Belugas wonders what is worst... a mom or a wife...
<Lakie> Well, they do the same thing but the code is different.

______________
My patches
check my wiki page (sticky button) for a complete list

ImageImage
ImageImageImageImageImageImageImage
User avatar
Gedemon
Traffic Manager
Traffic Manager
Posts: 150
Joined: 29 Apr 2004 21:53

Re: Traffic lights (v1; r12733)

Post by Gedemon »

Roujin wrote:edit²: Gedemon, would you like the penalty to be additional to the crossing penalty, or independant from it? If it is independant, you could even set it lower than the crossing penalty to encourage roadvehicles to use traffic lighted crossings (despite that being not really useful). Or should I do it additional, meaning total penalty = crossing penalty + trafficlight penalty?
well, I don't know how the penalty system works :?

will it be a "hidden" value in openttd.cfg, or a patch gui option ? if you can use negative value, let's do it additional...

else made it independant, you'll never know, it may prove finaly usefull if... errr... someone implement road crash at junction for exemple :O

anyway, it's your patch, do it as you feel better :D
Roujin
Tycoon
Tycoon
Posts: 1884
Joined: 08 Apr 2007 04:07

Re: Traffic lights (v2; r12812)

Post by Roujin »

Okay, I've confused some stuff.. with crossing, they meant level crossing (as in road x rail). So there isn't any penalty for junctions. That means the traffic light penalty is extra, and since you can't make it negative, you cannot encourage vehicles to use them. But, meh. Who would want that, anyways? :P

Sooo I've made some awesome changes (shameless plug :P) and now present you v2.

Please be sure to check the changelog in the first post, to learn about the new features I added.
Attachments
trafficlights_v2_r12812.diff
traffic lights v2 for r12812
(43.31 KiB) Downloaded 239 times
* @Belugas wonders what is worst... a mom or a wife...
<Lakie> Well, they do the same thing but the code is different.

______________
My patches
check my wiki page (sticky button) for a complete list

ImageImage
ImageImageImageImageImageImageImage
Ar4i
Traffic Manager
Traffic Manager
Posts: 153
Joined: 24 Jul 2006 10:40

Re: Traffic lights (v1; r12733)

Post by Ar4i »

SirXavius wrote:...
BTW, as far as "compiling" the new .diff file, i'll wait til its in an official release. I do not want to get into dismantling and "remantling" the gamecode...
OR can try to read a bit more, especially the first post in that page where you can download already compiled executable including the patch.
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 14 guests