NotRoadTypes

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

peter1138
OpenTTD Developer
OpenTTD Developer
Posts: 1728
Joined: 30 Mar 2005 09:43

Re: NotRoadTypes

Post by peter1138 »

Yeah, this was fixed in master 9 days ago.

In case it wasn't clear, the pr6811 build is now obsolete and should not be used. Use a nightly instead.
He's like, some kind of OpenTTD developer.
Diesel Power
Traffic Manager
Traffic Manager
Posts: 222
Joined: 18 Jun 2016 19:05

Re: NotRoadTypes

Post by Diesel Power »

Thank you.

***downloads***

Yup, problem solved!

**edit**
Just had a crash with the latest nightly. Now posting it on Github. Diffrent cause this time.
"Assertion failed at line 166 of D:\a\1\s\src\road_map.h:mayhaveroad(t)"
User avatar
Andrew350
Chairman
Chairman
Posts: 768
Joined: 19 Dec 2011 07:54
Location: Washington State, USA
Contact:

Re: NotRoadTypes

Post by Andrew350 »

Fun thing I just realized:

If you replace all of a town's roads with a roadtype which forbids house placement, that town will slowly shrink and die (unless it builds more house-friendly roads). I guess it makes sense now that I think about it, but all I can think of now is how I can (ab)use it :twisted: Looking at you Wasteland...
User avatar
kamnet
Moderator
Moderator
Posts: 8532
Joined: 28 Sep 2009 17:15
Location: Eastern KY
Contact:

Re: NotRoadTypes

Post by kamnet »

Andrew350 wrote:Fun thing I just realized:

If you replace all of a town's roads with a roadtype which forbids house placement, that town will slowly shrink and die (unless it builds more house-friendly roads). I guess it makes sense now that I think about it, but all I can think of now is how I can (ab)use it :twisted: Looking at you Wasteland...
Sounds like the perfect add-on for Wastelands, now you gotta fix their roads in order to encourage building!
Diesel Power
Traffic Manager
Traffic Manager
Posts: 222
Joined: 18 Jun 2016 19:05

Re: NotRoadTypes

Post by Diesel Power »

That's a great idea! Haven't played a wasteland game in a while, might start a new one...
User avatar
Andrew350
Chairman
Chairman
Posts: 768
Joined: 19 Dec 2011 07:54
Location: Washington State, USA
Contact:

Re: NotRoadTypes

Post by Andrew350 »

One small feature I think is missing in NRT is the ability to define a set of level crossing underlay (overlay?) sprites per each road/tram type.

I know railtypes are supposed to handle crossing graphics, and it's fine that they handle the track overlay and signage/crossing bars/etc., but they can't modify the underlying road tile (not in a reliable way, anyhow). I think it would be beneficial to add a level_crossing graphics callback to allow road/tramtype authors to supply at least a basic underlay sprite to help make crossings look more "natural".

Right now, as long as you use a good railtype NewGRF the effect isn't too bad. But especially when using the baseset rails the crossings look pretty terrible with the track overlay just haphazardly pasted over the road, and could use some custom road crossing sprites to help blend it in better :) Some pictures below to help explain:

This is what crossings currently look like (using baseset rails):
current_nrt_crossing.png
current_nrt_crossing.png (5.42 KiB) Viewed 12679 times
And here is an example of the effect I want to achieve (Using ARRS and baseset rails, ignore the crossing lights):
desired_nrt_crossing.png
desired_nrt_crossing.png (5.18 KiB) Viewed 12679 times
Obviously the effect won't be quite so seamless with NRT due to the way the track sprites are applied, but at least it could be significantly improved. While in combination with a railtype NewGRF, however, the effect could be nearly perfect :) I don't know if anyone else agrees or would use such a feature, but I know I certainly would!
Diesel Power wrote:That's a great idea! Haven't played a wasteland game in a while, might start a new one...
Yes, and I need to get back to working on it. One of these days :lol:
Kruemelchen
Transport Coordinator
Transport Coordinator
Posts: 287
Joined: 18 Feb 2017 17:47

Re: NotRoadTypes

Post by Kruemelchen »

I second Andrew350's suggestion

Also it would be great to be able to define graphics for drive-through road stops (at least overlay)

AND while we're at it, being able to define extra overlays for bridges would be nice as well :lol:
leifbk
Chairman
Chairman
Posts: 810
Joined: 23 Dec 2013 16:33
Location: Bærum, Norway

Re: NotRoadTypes

Post by leifbk »

It would be nice if bridges could display the same road type as the adjoining road. It looks weird with a 19th century dirt road connecting to a blacktop bridge.

Maybe with the exception of wooden bridges; those would look a lot more realistic with a board cover, regardless of the adjoining road type.
User avatar
Andrew350
Chairman
Chairman
Posts: 768
Joined: 19 Dec 2011 07:54
Location: Washington State, USA
Contact:

Re: NotRoadTypes

Post by Andrew350 »

leifbk wrote:It would be nice if bridges could display the same road type as the adjoining road. It looks weird with a 19th century dirt road connecting to a blacktop bridge.
That's already possible, but maybe some roadtypes just haven't defined those sprites yet (which they should).

I'd also like the ability to keep some bridges from displaying roadtypes/railtypes, but I think controlling that via bridge NewGRF would be best, perhaps by setting a flag to disable drawing of railtype/roadtype overlays on certain bridges. But that kind of feature is probably out-of-scope for NRT :)
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: NotRoadTypes

Post by wallyweb »

Andrew350 wrote:
leifbk wrote:It would be nice if bridges could display the same road type as the adjoining road. It looks weird with a 19th century dirt road connecting to a blacktop bridge.
That's already possible, but maybe some roadtypes just haven't defined those sprites yet (which they should).

I'd also like the ability to keep some bridges from displaying roadtypes/railtypes, but I think controlling that via bridge NewGRF would be best, perhaps by setting a flag to disable drawing of railtype/roadtype overlays on certain bridges. But that kind of feature is probably out-of-scope for NRT :)
This should be simple enough to do without additional grf settings.
A proper roadtype grf would have several road surface styles each including matching bridge overlays.
When laying out your road and find yourself in need of a different surface for a bridge deck, simply go to the appropriate roadtype style and build that bridge. Then you can return to your original roadtype and continue building your road.
That is the power of roadtypes. My only regret is that it is not extended to road/tram stop furniture ... or is it?
User avatar
Andrew350
Chairman
Chairman
Posts: 768
Joined: 19 Dec 2011 07:54
Location: Washington State, USA
Contact:

Re: NotRoadTypes

Post by Andrew350 »

Meh, that's just a workaround though, and it really limits your choices when building. Plus, you may not always have the perfect roadtype/bridge combination to make it look good. The simple fact is that some bridges will just look better using their own surface versus the generic type that gets applied by a road/tram/rail type. For example the wooden trestle from my American Bridge set or the short monorail bridges in TBRS, among others. It's a small thing but it can make a big difference :)
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: NotRoadTypes

Post by wallyweb »

Andrew350 wrote:Meh, that's just a workaround though, and it really limits your choices when building. Plus, you may not always have the perfect roadtype/bridge combination to make it look good. The simple fact is that some bridges will just look better using their own surface versus the generic type that gets applied by a road/tram/rail type. For example the wooden trestle from my American Bridge set or the short monorail bridges in TBRS, among others. It's a small thing but it can make a big difference :)
That's a function of the bridge set which overrides the default generic bridges. I would assume that if the roadtype set grf is loaded after the bridge set grf then the bridges would get the surfaces of the selected roadtype and then the player always has the option of getting the "default/bridge set" surfaces when selecting the "default" roadtype.
User avatar
Andrew350
Chairman
Chairman
Posts: 768
Joined: 19 Dec 2011 07:54
Location: Washington State, USA
Contact:

Re: NotRoadTypes

Post by Andrew350 »

wallyweb wrote:I would assume that if the roadtype set grf is loaded after the bridge set grf then the bridges would get the surfaces of the selected roadtype and then the player always has the option of getting the "default/bridge set" surfaces when selecting the "default" roadtype.
That only works if:

1. The roadtype GRF doesn't override the "default" roadtype (which I think most do, especially since towns are currently only able to build that type)

2. The roadtype you are building is compatible with the "default" roadtype

Also loading order of GRFs doesn't matter in this case; the roadtype overlay will always trump the bridge sprite as long as the roadtype GRF supplies them. Which is why it would be cool if bridges could set a flag to say "no thanks, no overlay needed here" :)
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: NotRoadTypes

Post by wallyweb »

Andrew350 wrote:
wallyweb wrote:I would assume that if the roadtype set grf is loaded after the bridge set grf then the bridges would get the surfaces of the selected roadtype and then the player always has the option of getting the "default/bridge set" surfaces when selecting the "default" roadtype.
That only works if:

1. The roadtype GRF doesn't override the "default" roadtype (which I think most do, especially since towns are currently only able to build that type)

2. The roadtype you are building is compatible with the "default" roadtype

Also loading order of GRFs doesn't matter in this case; the roadtype overlay will always trump the bridge sprite as long as the roadtype GRF supplies them. Which is why it would be cool if bridges could set a flag to say "no thanks, no overlay needed here" :)
I really got to get in and look at this NRT stuff, but I'm waiting for the definitive specifications. Seems like changes may have occurred since Frosch's pro-forma linked to in the first post.
peter1138
OpenTTD Developer
OpenTTD Developer
Posts: 1728
Joined: 30 Mar 2005 09:43

Re: NotRoadTypes

Post by peter1138 »

Towns currently choose the fastest available roadtype flagged as buildable, so if they become available over time you'll see towns use different roads.

The only changes are two new flags, and new default roadtypes were removed.
He's like, some kind of OpenTTD developer.
User avatar
Andrew350
Chairman
Chairman
Posts: 768
Joined: 19 Dec 2011 07:54
Location: Washington State, USA
Contact:

Re: NotRoadTypes

Post by Andrew350 »

peter1138 wrote:Towns currently choose the fastest available roadtype flagged as buildable, so if they become available over time you'll see towns use different roads.

The only changes are two new flags, and new default roadtypes were removed.
Interesting, can't wait to play around with these new mechanics :)
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: NotRoadTypes

Post by wallyweb »

peter1138 wrote:Towns currently choose the fastest available roadtype flagged as buildable, so if they become available over time you'll see towns use different roads.
Interesting. So if at some stage a roadtype grf defines a 120 km/h highway roadtype, the towns will all evolve to very high speeds in the thickest of urban areas (zone 5?) even though the grf also offers 50 km/h city streets as a roadtype? Or can the "highway" be flagged as "not buildable" by towns?
User avatar
jfs
Tycoon
Tycoon
Posts: 1743
Joined: 08 Jan 2003 23:09
Location: Denmark

Re: NotRoadTypes

Post by jfs »

wallyweb wrote:
peter1138 wrote:Towns currently choose the fastest available roadtype flagged as buildable, so if they become available over time you'll see towns use different roads.
Interesting. So if at some stage a roadtype grf defines a 120 km/h highway roadtype, the towns will all evolve to very high speeds in the thickest of urban areas (zone 5?) even though the grf also offers 50 km/h city streets as a roadtype? Or can the "highway" be flagged as "not buildable" by towns?
There's separate flags for "buildable by towns" and "houses can build out of this road".
I'm not sure if it's a good idea to let towns build road types that don't support houses, but you can make those.


Edit: There is also a "hidden" flag for road types. This flag makes the type not buildable by players, but does not prevent towns from building it. So you can make entirely separate road types for towns and for players.
User avatar
wallyweb
Tycoon
Tycoon
Posts: 6102
Joined: 27 Nov 2004 15:05
Location: Canada

Re: NotRoadTypes

Post by wallyweb »

peter1138 wrote:Towns currently choose the fastest available roadtype flagged as buildable, so if they become available over time you'll see towns use different roads.
I have another question along this theme.
Real life town population is usually distributed from the town center maximum out to the limits minimum. This is reflected in TTDP/OpenTTD with town zones. The real life town roads tend to evolve with population concentration with the outer limits being the last to evolve. This is reflected in TTDP/OpenTTD with road decorations and optionally by grf, surface treatments such as material and lines. If we have different roadtypes, each buildable by towns, each available at different years and each set at 50 km/h, which one gets the nod from the town?
User avatar
Emperor Jake
Tycoon
Tycoon
Posts: 3426
Joined: 24 Apr 2007 09:37
Skype: Discord: Emperor Jake #4106
Location: Not Actually Japan
Contact:

Re: NotRoadTypes

Post by Emperor Jake »

wallyweb wrote: 19 Aug 2018 16:42 !!!!!!! PROBLEM SOLVED !!!!!!!!
Bridges have two sprite types: Front&Top and Back&Floor. so why can't tram tracks? :idea:
So, I moved the back pylons over to the track sprite.

Good thinking, I did something similar in the vactrain set
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 4 guests