Transport Tycoon Forums

The place to talk about Transport Tycoon
It is currently Sat Feb 23, 2019 6:00 pm

All times are UTC




Post new topic  Reply to topic  [ 52 posts ]  Go to page 1 2 3 Next
Author Message
PostPosted: Fri Aug 26, 2011 2:40 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Thu Mar 19, 2009 7:25 pm
Posts: 2621
Location: Kent
I have had a rather lengthy idea which i will slowly develop over the next few days with added concept art and ideas.

Basically it would require two main changes that i can see:

1) A change to how the pathfinder treats multi-lane roads
2) A modification to the newgrf spec to add new road types

I understand that this is something people have spoke about for a while, but noone has ever really seemed willing to dive into it and actually give it some proper thought.

Now obviously by default, this wouldnt effect the game, the changes would only be implemented through NewGRFs (except that vehicles would use both lanes of one way roads correctly). The idea is that through a newgrf, you can specify several road types, and then by linking together half a tile of one road type and half a tile of another road type, you get a special transitional piece.

Like NuTracks, you would be able to specify speed, and additionally how many lanes the road has. A further development of this could be to eventually have special road tiles with things like roundabouts and junction turnoffs. I will create some concept art to demonstrate this soon.

_________________
Image


Last edited by Leanden on Fri Aug 26, 2011 7:43 pm, edited 1 time in total.

Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 3:01 pm 
Offline
Traffic Manager
Traffic Manager

Joined: Tue May 27, 2008 8:33 pm
Posts: 158
:bow:


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 3:20 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon May 21, 2007 11:47 am
Posts: 6559
Location: The Netherlands
oh, roadtypes was given a proper thought while petern developed railtypes. I'm pretty sure you still can find trace of that in the openttd wiki.

But yes, I think roadtypes is a good idea. It 'just' needs 'someone' to implement it :)

_________________
FooBar's Tram Tracks | TransRapid Track Set | Metro Track Set | OpenGFX base graphics set | FIRS Industry Replacement Set
Dutch Tram Set | Dutch Trainset 2 | Dutch Road Furniture


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 3:47 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon May 21, 2007 11:47 am
Posts: 6559
Location: The Netherlands
Oh, I looked it up for you now that I'm on my computer (easier with the copy/paste and such): http://wiki.openttd.org/Peter1138/Roadtypes

I think the best approach here is to design a NewGRF specification like railtypes but then for roadtypes. If that can be made solid, a developer or patchwright might get interested and actually implement this. And it really helps if you can provide a NewGRF that actually is coded according to that spec for testing purposes.


I'd leave your idea about the "halftile linking" out of the initial spec and just do it like railtypes: stop one type and continue with the other on the next. Overlapping could look better, but it's a bit of a bear trap to implement. First of all the original road and tram track set doesn't have these overlap graphics. Then when it comes to drawing the overlap, two different sets end up providing two different sprites: who should be drawn on top of who? And how would this work at junctions where a secondary road of one type is attached to a main road of the other type? Just drawing the border at the tile edge is much less complicated, which eventually gives this a higher chance to be implemented


If you want, I may be able to assist on writing this specification (of if you wait long enough I might write it myself at some point).

_________________
FooBar's Tram Tracks | TransRapid Track Set | Metro Track Set | OpenGFX base graphics set | FIRS Industry Replacement Set
Dutch Tram Set | Dutch Trainset 2 | Dutch Road Furniture


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 4:30 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Thu Mar 19, 2009 7:25 pm
Posts: 2621
Location: Kent
I thought about having the tile draw up to the edge, but think for example if you have a 3-lane motorway road then turn immediately into a 2-way road with no conversion graphics in between, It'd look pretty bad. There would have to be some way of having the roads change from one type to the other without them just being next to each other.

Also what about improving the pathfinder to allow for better lane utilisation? I hear this is buried deep in the code of Openttd so it'd be difficult to manipulate.

EDIT: Can't seem to find the railtype specification, just loads of information about labels, variables and callbacks.

_________________
Image


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 5:53 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon May 21, 2007 11:47 am
Posts: 6559
Location: The Netherlands
Ah, I didn't realise that you were also thinking three lane roads. Also that is something that you probably should forget, at least initially. It will need a tremendous amount of work to make three lane roads possible. Roadtypes is basically about changing the graphics and applying a speed limit; not really that much different to how the game works now. Three lane roads will apart from this also involve completely overhauling the pathfinder and road vehicle drawing code; a great deal of work which is unlikely to be accepted as a single patch (unless an OpenTTD Dev decides to make it).
So while I'm absolutely not against three lane roads, I think it's best for now to limit yourself to not wanting all at once :)


Improving the pathfinder to better work with one-way roads is certainly possible (I don't know how, but I believe I've seen an initial patch for that a while ago). Basically the only aspect needed here is to allow overtaking for articulated vehicles. There's not much advantage in making real two lane traffic, as you'll always end up with a huge bottleneck where both lanes need to merge into one. So overtaking for all road vehicles would be a big win here; two lane traffic will add very little benefit and most likely will only make it worse.


As for the railtype spec, it's a bit hidden on the Action3 page: http://newgrf-specs.tt-wiki.net/wiki/Action3#cargo-type, combined with the properties: http://newgrf-specs.tt-wiki.net/wiki/Action0/Railtypes, the sprite definition: http://newgrf-specs.tt-wiki.net/wiki/Action2/Single_Set the variables: http://newgrf-specs.tt-wiki.net/wiki/Va ... /Railtypes, a bit on random bits: http://newgrf-specs.tt-wiki.net/wiki/Ra ... Rail_types. There are no railtype callbacks. And don't forget the railtype translation table: http://newgrf-specs.tt-wiki.net/wiki/Ac ... e_.2812.29

Basically all these could be used as a basis for roadtypes. If you stay as close to the railtype specs, nothing can go wrong really. If you want to attempt something, I recommend you to include possibilities for diagonal roads and the possibility for custom catanery per roadtype. Also don't forget that tram tracks are a roadtype and that the specs need to account for these too (which will make it a bit more complicated than the railtype specs).

_________________
FooBar's Tram Tracks | TransRapid Track Set | Metro Track Set | OpenGFX base graphics set | FIRS Industry Replacement Set
Dutch Tram Set | Dutch Trainset 2 | Dutch Road Furniture


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 6:12 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Thu Mar 19, 2009 7:25 pm
Posts: 2621
Location: Kent
Ye because obviously you have to disable overtaking for tram track vehicles.

Is there a possibility as well to maybe make it so that certain road types dont cause collisions with other railtypes, this way you could perhaps implement subways as a road type which is almost invisible where the vehicles done collide with road vehicles?

_________________
Image


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 7:30 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon May 21, 2007 11:47 am
Posts: 6559
Location: The Netherlands
Leanden wrote:
Ye because obviously you have to disable overtaking for tram track vehicles.

Certainly. And it might be good to have this optional for other roadtypes as well. Think trolleybuses.

I think somehow a distinction must be made between basic roadtypes and overlay roadtypes. The basic roadtypes are like normal road and they can have no catanery. They cannot be built on top of each other. The overlay roadtypes are like tramways and can (but must not) have catanery. These overlay types can be built separately, on top of basic types but not on top of each other. However they can cross each other perpendicular (like how tramway crosses rail).


Leanden wrote:
Is there a possibility as well to maybe make it so that certain road types dont cause collisions with other railtypes, this way you could perhaps implement subways as a road type which is almost invisible where the vehicles done collide with road vehicles?

Well, in theory everything is possible. Not having collisions with rail vehicles would be easy (but weird). I might see a benefit in "vehicles of this roadtype also crash the train when both collide".
No collisions with road vehicles of a different roadtype when driving in the same direction would fall in the category of changing how road vehicles work. Possible, but not a lot will be interested in making this.

_________________
FooBar's Tram Tracks | TransRapid Track Set | Metro Track Set | OpenGFX base graphics set | FIRS Industry Replacement Set
Dutch Tram Set | Dutch Trainset 2 | Dutch Road Furniture


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 7:39 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Thu Mar 19, 2009 7:25 pm
Posts: 2621
Location: Kent
Well the only thing i was thinking of is that lots of people have requested subways, this might be one way of implementing it by having it as a underlay road type which doesnt interfere with road traffic.

This wouldnt neccesarily come as standard, but it would be in the newgrf spec so that people could code subways that way if they wanted too. Also think of suspended monorail ;)

_________________
Image


Top
   
PostPosted: Fri Aug 26, 2011 8:05 pm 
Offline
OpenTTD Developer
OpenTTD Developer

Joined: Thu Sep 11, 2008 7:32 am
Posts: 1034
Location: Spain
I think that it should be better to fix the overtaking mess before doing roadtypes.

_________________
Spanish translation of OpenTTD
Extended heightmaps

Have fun, don't quarrel too much and add as many advanced settings as you can.


Top
   
PostPosted: Fri Aug 26, 2011 8:35 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Thu Mar 19, 2009 7:25 pm
Posts: 2621
Location: Kent
But noone can ever be bothered with fixing the pathfinder, doing road types would be an incentive to get the pathfinder code fixed. With this and variable cargo aging, RVs are becoming feasible as transport once again.

_________________
Image


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 8:43 pm 
Offline
Director
Director
User avatar

Joined: Tue May 03, 2005 8:50 pm
Posts: 529
Location: Somewhere in a country called Argentina
Can I ask some off-topic-ish? Since diagonal roads are unlikely to be added, why not modify tracks to have a specific value that makes RVs running over them not slow down if they're going 'diagonally', that means they're turning left and right constantly, while only turning right or doing right-left-right slows them similarly to how trains are handled (the longer the curve, lesser the slowdown).

And more on topic, will newroads API support disabling town growth near tagged road types (like 'highways')?

_________________
Sorry for my english I am argentinian
TTO don't crashes in Windows XP; XP crashes TTO

Formerly known as UnderBuilder.

MyMiniCity


Top
   
PostPosted: Fri Aug 26, 2011 8:49 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Thu Mar 19, 2009 7:25 pm
Posts: 2621
Location: Kent
Diagonal roads is something we are thinking off. As for town growth, there is no reason this couldnt be some sort of flag that prevents town growth on that type of road. I believe that for example towns won't grow on tram tracks.

_________________
Image


Top
   
 Post subject: Re: NuRoads
PostPosted: Fri Aug 26, 2011 8:58 pm 
Offline
Tycoon
Tycoon

Joined: Sun Dec 16, 2007 10:24 pm
Posts: 1654
Location: Idaho, USA
Leanden wrote:
Well the only thing i was thinking of is that lots of people have requested subways, this might be one way of implementing it by having it as a underlay road type which doesnt interfere with road traffic.

This wouldnt neccesarily come as standard, but it would be in the newgrf spec so that people could code subways that way if they wanted too. Also think of suspended monorail ;)

That does sound pretty cool to me. The graphics for subway vehicles would be pretty simple too -- just a shadow or outline since it's all underground! :P

_________________
Eyecandy Road Vehicles | Fake Subways | Supercheese's NewObjects

"Fashions and cultures change, but steam trains shall always be majestic."
-Professor Hershel Layton


Top
   
PostPosted: Fri Aug 26, 2011 9:05 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon Feb 07, 2011 10:04 pm
Posts: 1183
Location: East Coast, United States
But if subways would be roadtypes, then that means that the land above the subways would need to be cleared anyway, defeating the objective.

The alternative is making a new type of tram tracks: with the same graphics as normal roads but vehicles underground. The drawback would be that subways could only be under streets.

_________________
Like my avatar? See my screenshot thread
Chill's Patchpack, an awesome collection of OTTD patches


Top
   
PostPosted: Fri Aug 26, 2011 9:07 pm 
Offline
Tycoon
Tycoon

Joined: Sun Dec 16, 2007 10:24 pm
Posts: 1654
Location: Idaho, USA
Level Crossing wrote:
The alternative is making a new type of tram tracks: with the same graphics as normal roads but vehicles underground. The drawback would be that subways could only be under streets.

That's what I meant...

_________________
Eyecandy Road Vehicles | Fake Subways | Supercheese's NewObjects

"Fashions and cultures change, but steam trains shall always be majestic."
-Professor Hershel Layton


Top
   
PostPosted: Fri Aug 26, 2011 9:35 pm 
Offline
Tycoon
Tycoon

Joined: Wed Jan 17, 2007 12:14 am
Posts: 7281
Level Crossing wrote:
subways could only be under streets.

that is what 90% of all subways do anyway.

the problem with that concept is connection with "over ground" (light-) rail, e.g. in the outskirts of a city, or elevated rails.

also might want to make sure that tunnels cannot cross a subway.

_________________
You might not exactly be interested in Ferion, but if you are, have fun :)


Top
   
PostPosted: Fri Aug 26, 2011 9:42 pm 
Offline
Tycoon
Tycoon

Joined: Sun Dec 16, 2007 10:24 pm
Posts: 1654
Location: Idaho, USA
Eddi wrote:
also might want to make sure that tunnels cannot cross a subway.

Eh, I think allowing tunnels to cross subways could be explained by asserting that "they build one tunnel above/below the other".

_________________
Eyecandy Road Vehicles | Fake Subways | Supercheese's NewObjects

"Fashions and cultures change, but steam trains shall always be majestic."
-Professor Hershel Layton


Top
   
PostPosted: Fri Aug 26, 2011 9:45 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon Feb 07, 2011 10:04 pm
Posts: 1183
Location: East Coast, United States
Supercheese wrote:
Eddi wrote:
also might want to make sure that tunnels cannot cross a subway.

Eh, I think allowing tunnels to cross subways could be explained by asserting that "they build one tunnel above/below the other".

But then that contradicts the fact that tunnels in general cannot be built one above/below the other.

_________________
Like my avatar? See my screenshot thread
Chill's Patchpack, an awesome collection of OTTD patches


Top
   
PostPosted: Fri Aug 26, 2011 9:47 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Thu Mar 19, 2009 7:25 pm
Posts: 2621
Location: Kent
But in the game, you can build one tunnel above another, so why would you not be able to build tunnels under subways?

_________________
Image


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 52 posts ]  Go to page 1 2 3 Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000-2019 phpBB Limited

Copyright © Owen Rudge/The Transport Tycoon Forums 2001-2019.
Hosted by Zernebok Hosting.