Expanded buildonslopes

Got an idea for a new feature in TTDPatch? Post it here.

Moderator: TTDPatch Moderators

User avatar
khamura
Traffic Manager
Traffic Manager
Posts: 218
Joined: 27 May 2005 21:50
Location: Tourian, Planet Zebes, Orion Arm, Milky Way
Contact:

Expanded buildonslopes

Post by khamura »

I've been wanting to ask whether it is possible for buildonslopes to be expanded, that is, for it to also make possible to building of track on steep diagonal tiles. Is that at all feasible in terms of patching?
Graduate of the LeRoy Funkified Badass School of Soul
User avatar
eis_os
TTDPatch Developer
TTDPatch Developer
Posts: 3603
Joined: 07 Mar 2003 13:10
Location: Germany
Contact:

Post by eis_os »

Try it out for rails :wink: It's not that nice, but I made it possible long time ago...
TTDPatch dev in retirement ... Search a grf, try Grf Crawler 0.9 - now with even faster details view and new features...
Image
User avatar
khamura
Traffic Manager
Traffic Manager
Posts: 218
Joined: 27 May 2005 21:50
Location: Tourian, Planet Zebes, Orion Arm, Milky Way
Contact:

Post by khamura »

Oh, I know that! It's one the things that make playing mountainous maps possible without full-scale environmental restructuring. ;)

But my drift was whether it could be expanded. Currently there are tiles that can't be build on even with buildonslopes active, such as the aforementioned steep diagonal slopes, and I was wondering if these could be included in the cases that buildonslopes covers.
Graduate of the LeRoy Funkified Badass School of Soul
User avatar
krtaylor
Tycoon
Tycoon
Posts: 11784
Joined: 07 Feb 2003 01:58
Location: Texas, USA
Contact:

Post by krtaylor »

I had an idea along these lines, but I don't know how you'd implement it GUI-wise. Right now, build-on-slopes puts the track out over the edge of the slope, with a retaining wall underneath the track to hold it up. But you also see cuttings, where the track is built on a flat spot cut into the side of the mountain, with a retaining wall above the track to hold the rest of the mountain up. If you had the ability to do either, and choose between them, then it would not only be possible to do double-track on the side of a mountain without heavy terraforming, but also to have a track climb a mountainside by degrees without moving dirt.
Development Projects Site:
http://www.as-st.com/ttd
Japan, American Transition, Planeset, and Project Generic Stations available there
User avatar
suttonc
Engineer
Engineer
Posts: 41
Joined: 30 May 2006 10:01
Location: Sydney, Australia

Post by suttonc »

the best way to do this from a graphical perspective is to have the track halfway up the slope, with a wall above and below the track
User avatar
Snail
Tycoon
Tycoon
Posts: 1283
Joined: 28 Apr 2003 18:52
Contact:

Post by Snail »

suttonc wrote:the best way to do this from a graphical perspective is to have the track halfway up the slope, with a wall above and below the track
Well, but like this, the track would be at "half height" between two tiles... I don't think it is possible...
Maybe we could get this effect with a double track, with one track cut into the mountain with the retaining wall holding the mountain up, and the other track over the edge, running over a wall, just like krtaylor said.

We could implement this in a GUI with a kind of toggle button: it could decide the build-on-slopes method, either above the slope with the wall underneath (an upwards-pointing arrow maybe?) or cut into the mountain (a downwards-pointing arrow)...
User avatar
VIPStephan
Engineer
Engineer
Posts: 58
Joined: 30 Dec 2005 20:27

Post by VIPStephan »

This idea was already suggested in this thread.
Whatever happens, don't click this link!!
User avatar
suttonc
Engineer
Engineer
Posts: 41
Joined: 30 May 2006 10:01
Location: Sydney, Australia

Post by suttonc »

Or, it could work like signals: click the part of the tile you want the track on.
michael blunck
Tycoon
Tycoon
Posts: 5950
Joined: 27 Apr 2005 07:09
Contact:

Post by michael blunck »

Maybe it would be easier to allow an "extended autoslope" feature on bare land tiles? Using simply the <STRG> key as its "GUI"? (I know it´s not that good for multiplayer but we already have it this way, e.g. for signal states).

I.e. clicking <arrow down> would lower the terrain as usual but <STRG><arrow down> would lower only the edge of that specific tile by trying to apply a retaining wall generated by "autoslope"?

This would indeed be very helpful for track laying in mountainous terrain.

Because we already have "autoslope" in connection with buildings I could imagine it wouldn´t be that hard to have it too for tiles without buildings?

Your comments, Oskar? 8)

regards
Michae
Attachments
cutting.png
cutting.png (43.65 KiB) Viewed 1752 times
Image
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

That would require to store the height of more than one corner. Currently only the height of the north corner is stored per tile.

For autoslope and buildonslopes this works because we know that what's built has to be flat (or perhaps sloped in a certain way for bridge heads), so the height of the other corners can be inferred.

If nothing is built on the tile, there's nothing to work with for the height of the other corners...
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
michael blunck
Tycoon
Tycoon
Posts: 5950
Joined: 27 Apr 2005 07:09
Contact:

Post by michael blunck »

How does industrial var60 determine slope data, then?

regards
Michael
Image
Patchman
Tycoon
Tycoon
Posts: 7575
Joined: 02 Oct 2002 18:57
Location: Ithaca, New York
Contact:

Post by Patchman »

From the heights of the north corners of the adjacent tiles.
Josef Drexler

TTDPatch main | alpha/beta | nightly | manual | FAQ | tracker
No private messages please, you'll only get the answering machine there. Send email instead.
User avatar
eis_os
TTDPatch Developer
TTDPatch Developer
Posts: 3603
Joined: 07 Mar 2003 13:10
Location: Germany
Contact:

Post by eis_os »

Autoslope knows exactly what is safe to do with a tile or atleast it should. This way it's possible to change the landscape under them. (still the problem remains that if a tile is visited two times it fails and can screw up the landscape. As the second visit doesn't know the change that the first visit allowed)

For bridges it's actually not very easy to determine the right allowed height /edge combination, thats why it's not possible to change the landscape under such structures.
TTDPatch dev in retirement ... Search a grf, try Grf Crawler 0.9 - now with even faster details view and new features...
Image
Ramshill
Engineer
Engineer
Posts: 92
Joined: 25 Jan 2006 16:06
Location: England UK
Contact:

Post by Ramshill »

A HORRIBLE question.
Would it be horrendusly difficult to include the height data for all four corners in the tile data? (note I admit to no knowledge on this and am just curious)
I maybe old but at least I'm not dead (yet).
OK! I admit it I AM dead (from the neck up)
User avatar
eis_os
TTDPatch Developer
TTDPatch Developer
Posts: 3603
Joined: 07 Mar 2003 13:10
Location: Germany
Contact:

Post by eis_os »

well, then you should ask Chris Sawyer for the locomotion engine, as there <insert high number> places in TTD that assumes that TTD works the way it works...
TTDPatch dev in retirement ... Search a grf, try Grf Crawler 0.9 - now with even faster details view and new features...
Image
michael blunck
Tycoon
Tycoon
Posts: 5950
Joined: 27 Apr 2005 07:09
Contact:

Post by michael blunck »

>> How does industrial var60 determine slope data, then?

> From the heights of the north corners of the adjacent tiles.

Yes, o/c.

My question was aimed towards a different issue. But in the light of your former answer, I deduce that the way in which industry var60 is used to determine and to draw appropriate slopes (I mean retaining walls here) wouldn´t be the way to go for the landcape tiles in general. These would have to be stored (e.g. into a savegame structure) and var 60 does this "on the fly".

Well, OK.

Nevertheless, I don´t see why from a topological reason, "cuttings" couldn´t be achieved even when keeping the actual method by storing only the height of a tiles´ northern corner.

O/c, the actual terrain shaping subroutines as well as the drawing routines would have to be changed.

[Disclaimer: I don´t know nothing about TTD´s terrain implementation.]

regards
Michael
Image
User avatar
eis_os
TTDPatch Developer
TTDPatch Developer
Posts: 3603
Joined: 07 Mar 2003 13:10
Location: Germany
Contact:

Post by eis_os »

Read Marcins "TTD savegame internals" again :wink: You would need to store the edges. All currently buildonslopes feature don't need extra bits because the slope status can be calculated on the fly.
Ramshill
Engineer
Engineer
Posts: 92
Joined: 25 Jan 2006 16:06
Location: England UK
Contact:

Post by Ramshill »

If I understand this correctly then to find the height of all four corners would need you to test the three adjacent tiles as shown in this diagram.
Too much trouble.
Attachments
example.PNG
example.PNG (15.23 KiB) Viewed 3407 times
I maybe old but at least I'm not dead (yet).
OK! I admit it I AM dead (from the neck up)
michael blunck
Tycoon
Tycoon
Posts: 5950
Joined: 27 Apr 2005 07:09
Contact:

Post by michael blunck »

Nevertheless, I don´t see why from a topological reason, "cuttings" couldn´t be achieved even when keeping the actual method by storing only the height of a tiles´ northern corner.

O/c, the actual terrain shaping subroutines as well as the drawing routines would have to be changed.
> Read Marcins "TTD savegame internals" again You would need to store the edges. [...]

To be sure, I did. But there´s no more information than Josef already gave here: the height of a tile is only given by storing its northern corner.
If I understand this correctly then to find the height of all four corners would need you to test the [height of the] three adjacent tiles as shown in this diagram.
Yes, that´s exactly what TTD´s drawing routine does. It then decides which kind of terrain tile has to be placed.

> Too much trouble.

Na. As I stated above, an implementation of "cuttings" should be straightforward and rely only on the current structure of the landscape array L4. No need to store all four corners.

I´ll come back to a proposal later.

regards
Michael
Image
User avatar
eis_os
TTDPatch Developer
TTDPatch Developer
Posts: 3603
Joined: 07 Mar 2003 13:10
Location: Germany
Contact:

Post by eis_os »

Not only the drawing, the z correction needs the 4 corners aswell, and you would allow trains to jump...

-edit- This would allow trains to start doing stuff it shouldn't do, a reason why certain station combinations aren't possible aswell...
Attachments
cutting_notallowed.png
cutting_notallowed.png (12.66 KiB) Viewed 3336 times
TTDPatch dev in retirement ... Search a grf, try Grf Crawler 0.9 - now with even faster details view and new features...
Image
Post Reply

Return to “Suggestions”

Who is online

Users browsing this forum: No registered users and 2 guests