[patch] drive-through depots
Moderator: OpenTTD Developers
[patch] drive-through depots
Here's a patch that adds drive-through depots, that is, depots that you can enter from both sides and drive through if the vehicle's orders permit. It works for both trains and road vehicles. It seems pretty stable and I'm keen to hear your thoughts.
Links to the patch and some videos here:
Drive-Through depots
Links to the patch and some videos here:
Drive-Through depots
Last edited by racetrack on 19 Mar 2009 12:24, edited 3 times in total.
- JacobD88
- Chief Executive
- Posts: 708
- Joined: 16 Aug 2008 17:51
- Location: Long Eaton, Nottinghamshire. UK
- Contact:
Re: [patch] drive-through depots
Welcome to the forumsracetrack wrote:Here's a patch that adds drive-through depots, that is, depots that you can enter from both sides and drive through if the train's orders permit. There's still a few things to sort out but its working enough for you to play with if you like.

Huzah!

The thing i'm working on is more planned towards station like functionality and construction of depots, even using the station building interface, but if your up for it, it might be worth joining efforts?
The advantage of creating special "station" tiles to act as depots would also get around your bi-derectionality (drive-thru) question, and resolve any collisions between vehicles (if you construct the service-station correctly with signals et al)
I already have sprites too


above based on Snorbuckle's work 2005
Feel free to PM me if you like...
Have also added a link to your patch on my threads FP

screenshot mock-up of "servicing-stations" also includes ISR set
Last edited by JacobD88 on 12 Mar 2009 21:36, edited 5 times in total.
High-Functioning Autistic & Proud... National Autistic Society * Asperger Foundation
My (O)TTD Work...BIGGER DEPOTS (REL.) & SERVICING-STATIONS (WIP) * Advanced DEPOT DESIGNS * SCREENSHOTS

My personal website is occasionally here - sometimes it's just the family site - it's basically a lucky dip
My (O)TTD Work...BIGGER DEPOTS (REL.) & SERVICING-STATIONS (WIP) * Advanced DEPOT DESIGNS * SCREENSHOTS
My personal website is occasionally here - sometimes it's just the family site - it's basically a lucky dip
- CommanderZ
- Tycoon
- Posts: 1872
- Joined: 07 Apr 2008 18:29
- Location: Czech Republic
- Contact:
Re: [patch] drive-through depots
Looks good. Will the pathfinder allow the trains to use the depot as a piece of track (with severe penalty maybe)?racetrack wrote:Here's a patch that adds drive-through depots, that is, depots that you can enter from both sides and drive through if the train's orders permit. There's still a few things to sort out but its working enough for you to play with if you like.
Links to the patch and some videos here:
Drive-Through depots
--r.
BTW, Welcome to the tt-forums racetrack

Last edited by CommanderZ on 12 Mar 2009 21:44, edited 1 time in total.
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: [patch] drive-through depots
Looks promising
Hope you join forces with JacobD88.
Keep up the good work.
Regards HackaLittleBit
Hope you join forces with JacobD88.
Keep up the good work.
Regards HackaLittleBit
Re: [patch] drive-through depots
I'm not uninterested, but I think my simple hack and your goals are actually quite different. By the sounds of it you're really looking at making stations that can do something other than load/unload cargo. Stations and depots are handled quite differently by the code, and while you could argue that stations and depots should be treated the same its going to be a much bigger patch (and thus much harder to get accepted into trunk).JacobD88 wrote:Huzah!Just the thing I'm looking for to accompany the "bigger depots" GRF, would you be interested in joining me on the servicing-stations project?... http://www.tt-forums.net/viewtopic.php?f=36&t=40577
The thing i'm working on is more planned towards station like functionality and construction of depots, even using the station building interface, but if your up for it, it might be worth joining efforts?
The advantage of creating special "station" tiles to act as depots would also get around your bi-derectionality (drive-thru) question, and resolve any collisions between vehicles (if you construct the service-station correctly with signals et al)
I won't discuss it further here but I'll have a read through your thread and see if I can add anything. I'm certainly going to need something to do after finishing this patch; maybe that will be it

I haven't tested it extensively, but I think the pathfinder is currently treating the depot as a block signal. I suppose it should have a configurable penalty, but I really don't know what would be appropriate. If I decide to make it so that trains can drive straight through without stopping (though presumably at reduced speed), then that would affect the cost again. Any ideas?CommanderZ wrote:Will the pathfinder allow the trains to use the depot as a piece of track (with severe penalty maybe)?
- JacobD88
- Chief Executive
- Posts: 708
- Joined: 16 Aug 2008 17:51
- Location: Long Eaton, Nottinghamshire. UK
- Contact:
Re: [patch] drive-through depots
Thanks for taking a look, i agree, the end goals are much more code intensive, but at least with your existing patch, upon completion, will still mean that the "build depot" function will not be rendered obsolete and it already accompanies the "bigger depot" GRF well as i have said.racetrack wrote:I'm not uninterested, but I think my simple hack and your goals are actually quite different. By the sounds of it you're really looking at making stations that can do something other than load/unload cargo. Stations and depots are handled quite differently by the code, and while you could argue that stations and depots should be treated the same its going to be a much bigger patch (and thus much harder to get accepted into trunk).JacobD88 wrote:Huzah!Just the thing I'm looking for to accompany the "bigger depots" GRF, would you be interested in joining me on the servicing-stations project?... http://www.tt-forums.net/viewtopic.php?f=36&t=40577 ...
I won't discuss it further here but I'll have a read through your thread and see if I can add anything. I'm certainly going to need something to do after finishing this patch; maybe that will be it![]()
As to patching in "servicing stations", i'm still trying to work out if a code re-write or massive addition is necessary, as both the station code and depot code already allow for the functions i require, so i am pondering over if and how it is possible to code in "bridges" for the code as necessary, for example, code the depot sprites as station tiles, then either create a GRF action and/or (hopefully smaller) patch bridge to tell the game engine that if these tiles are present to behave as a piece of station tile, but with the properties of a depot as and where appropriate
I re-iterate, i am still trying to work out if this is possible, but once you have finished this patch i would appreciate any help as im also trying to learn how to code as part of my project so my ability to spot how these things can be done is somewhat limited and noobish

Many thanks
Jacob
High-Functioning Autistic & Proud... National Autistic Society * Asperger Foundation
My (O)TTD Work...BIGGER DEPOTS (REL.) & SERVICING-STATIONS (WIP) * Advanced DEPOT DESIGNS * SCREENSHOTS

My personal website is occasionally here - sometimes it's just the family site - it's basically a lucky dip
My (O)TTD Work...BIGGER DEPOTS (REL.) & SERVICING-STATIONS (WIP) * Advanced DEPOT DESIGNS * SCREENSHOTS
My personal website is occasionally here - sometimes it's just the family site - it's basically a lucky dip
Re: [patch] drive-through depots
That looks awesome!
IMO, there is no need for special code for servicing station. Just make the bigger depot also available as station and you can make your big Service Stations, with a drive-though depot in the middle.
Greets
Ammler
IMO, there is no need for special code for servicing station. Just make the bigger depot also available as station and you can make your big Service Stations, with a drive-though depot in the middle.

Greets
Ammler
Town Names:


Still work in progress: OpenGFX or/and OpenSFX - Please help!
- HackaLittleBit
- Director
- Posts: 550
- Joined: 10 Dec 2008 16:08
- Location: tile 0x0000
Re: [patch] drive-through depots
Agree with ammler.
Maybe restrict drive through depot to situation on photo (imagine depot in between the stations).
Why? The classic depot in ttd gave many many headaches to many many peoples.
Changing that could take away the charm of the game. be careful.
Although building a depot complex like JacobD88 is very nice.
So putting the drive though depot in between two stations plus a nice time penalty (CommanderZ) would be an option.
also you would avoid buttons and options etc because simply if the train enters the depot and sees next tile as station it automatically assumes drive trough depot.
Regards
Maybe restrict drive through depot to situation on photo (imagine depot in between the stations).
Why? The classic depot in ttd gave many many headaches to many many peoples.
Changing that could take away the charm of the game. be careful.
Although building a depot complex like JacobD88 is very nice.
So putting the drive though depot in between two stations plus a nice time penalty (CommanderZ) would be an option.
also you would avoid buttons and options etc because simply if the train enters the depot and sees next tile as station it automatically assumes drive trough depot.
Regards
- Attachments
-
- sds.png (19.58 KiB) Viewed 20359 times
- JacobD88
- Chief Executive
- Posts: 708
- Joined: 16 Aug 2008 17:51
- Location: Long Eaton, Nottinghamshire. UK
- Contact:
Re: [patch] drive-through depots
That's a good point, though it would require racetrack to make depots act as simply plain track tiles that trains could pass through without stopping and stop trains entering from both sides, otherwise you would end up with two trains entering one track of a "servicing station" and seemingly disappearing, something would have to be done to make racetracks depots aware of other trains on the track entering the depot.Ammler wrote:IMO, there is no need for special code for servicing station. Just make the bigger depot also available as station and you can make your big Service Stations, with a drive-though depot in the middle.![]()
This is probably the largest difference between what i envision with "servicing stations" and racetrack has already achieved in part, racetracks patch modifies the existing depots to be drive-thru, and maybe in future versions pass-thru, but with servicing stations i mostly want to achieve the ability to service engines at stations with these special tiles, not build them or remove them from the tracks at stations (and therefore render racetracks depot patch obsolete)...
In short "servicing stations" aims at allowing engines to have a "go to station xxx for servicing" command, upon which trains will simply move into a free station track, stop, and move off having been serviced, where-as racetracks work gives existing depots bi-directional entry and maybe pass-thru
Maybe one day servicing stations will also become suitable for building trains (as i mentioned this as a possibility on my thread sometime ago), but after some thought i would rather not render OTTD functions totally obsolete, dump all over racetracks patch, and force users to use "servicing stations" to build and service engines, one of the things i love about all TTO/TTD games is choice


High-Functioning Autistic & Proud... National Autistic Society * Asperger Foundation
My (O)TTD Work...BIGGER DEPOTS (REL.) & SERVICING-STATIONS (WIP) * Advanced DEPOT DESIGNS * SCREENSHOTS

My personal website is occasionally here - sometimes it's just the family site - it's basically a lucky dip
My (O)TTD Work...BIGGER DEPOTS (REL.) & SERVICING-STATIONS (WIP) * Advanced DEPOT DESIGNS * SCREENSHOTS
My personal website is occasionally here - sometimes it's just the family site - it's basically a lucky dip
Re: [patch] drive-through depots
I decree that this must be perfected.
Many have waited for a more realistic train depot, and now we have it. Not only have you got the thing to basic functionality, but you understand the problems that have to addressed. That's impressive. This is a fine example if an idea that was thought at one time, i'm sure, to never be implementable. Now someone has taken the time to study it, and code it. Excellent work!!
Ideally it would be great to have a realistic ONE-PIECE depot building (which jacob has created the sprite for), enter in one direction, and leave in this opposite side. Eventually i hope a train yard can serve as a depot, but that's for a future patch. Any train that enters the depot of course will be slowed considerably, and that can serve as the penalty for using a depot as a glorified waypoint.

Many have waited for a more realistic train depot, and now we have it. Not only have you got the thing to basic functionality, but you understand the problems that have to addressed. That's impressive. This is a fine example if an idea that was thought at one time, i'm sure, to never be implementable. Now someone has taken the time to study it, and code it. Excellent work!!

Ideally it would be great to have a realistic ONE-PIECE depot building (which jacob has created the sprite for), enter in one direction, and leave in this opposite side. Eventually i hope a train yard can serve as a depot, but that's for a future patch. Any train that enters the depot of course will be slowed considerably, and that can serve as the penalty for using a depot as a glorified waypoint.
Re: [patch] drive-through depots
I went through the patch and saw the videos - there doesn't seem to be included or mentioned in the wiki for that matter that if the depot is of same length as a train, train will enter it with higher speed than ordinary depots (measely 61km/h).
This higher entering speed would trully differentiate these long depots from the ordinary depots with the so-called realistic acceleration ON.
This higher entering speed would trully differentiate these long depots from the ordinary depots with the so-called realistic acceleration ON.
NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: [patch] drive-through depots
Yeah, you're right there, I don't think, in real life, an engine would ever enter a depot at anywhere NEAR 61km/h. The limit should be much LOWER.
He's like, some kind of OpenTTD developer.
Re: [patch] drive-through depots
This patch has nothing to do with long depots. Please study the above posts a little more closely; there's been some discussion about how the drive-through depot patch might be used with JacobD88's long depot/service station work, but thats not what this is.SirkoZ wrote:I went through the patch and saw the videos - there doesn't seem to be included or mentioned in the wiki for that matter that if the depot is of same length as a train, train will enter it with higher speed than ordinary depots (measely 61km/h).
Re: [patch] drive-through depots
Just uploaded an updated patch that adds drive-through depots for road vehicles, and a new video showing it off.
Re: [patch] drive-through depots
Hi racetrack
Congratsulations on your new patch, simply stunning. Bravo
Everyone will love this.
Methinks Depots need to have very low speed entry, eg 15mph; because it is a work area and safety would be paramount of course.
Ideal usage would be a dedicated side track with signals and one way traffic.
Congratsulations on your new patch, simply stunning. Bravo

Everyone will love this.

Methinks Depots need to have very low speed entry, eg 15mph; because it is a work area and safety would be paramount of course.
Ideal usage would be a dedicated side track with signals and one way traffic.

-
- Tycoon
- Posts: 1829
- Joined: 10 Jul 2006 00:43
- Location: Spain
Re: [patch] drive-through depots
I don't like this idea. It's more realistic, but It's too slow in the OpenTTD world.Rollo wrote:Hi racetrack
Congratsulations on your new patch, simply stunning. Bravo
Everyone will love this.![]()
Methinks Depots need to have very low speed entry, eg 15mph; because it is a work area and safety would be paramount of course.
Ideal usage would be a dedicated side track with signals and one way traffic.
Sorry if my english is too poor, I want learn it, but it isn't too easy.
- [list][*]Why use PNG screenshots in 8 bpp games.
[*]Caravan site New Industry. · Spain set. · Some spanish trains for locomotion[*]Favourites:GRVTS · ECS · FIRS
Re: [patch] drive-through depots
Don't worry, its nothing to do with this patch. If/when I implement non-stop for drive-through depots, it'll be at the depot speed limit. Any other change to depot limits will have to be done elsewhere, probably by someone else.maquinista wrote:I don't like this idea. It's more realistic, but It's too slow in the OpenTTD world.Rollo wrote:Methinks Depots need to have very low speed entry, eg 15mph; because it is a work area and safety would be paramount of course.
Ideal usage would be a dedicated side track with signals and one way traffic.
Re: [patch] drive-through depots
Get this through your head, Mr. Caps:peter1138 wrote:Yeah, you're right there, I don't think, in real life, an engine would ever enter a depot at anywhere NEAR 61km/h. The limit should be much LOWER.
How long does a day last in OpenTTD?
Now back to the topic.
Then it's back to good old single tile depots. Phew.racetrack wrote:Don't worry, its nothing to do with this patch. If/when I implement non-stop for drive-through depots, it'll be at the depot speed limit. Any other change to depot limits will have to be done elsewhere, probably by someone else.maquinista wrote:I don't like this idea. It's more realistic, but It's too slow in the OpenTTD world.Rollo wrote:Methinks Depots need to have very low speed entry, eg 15mph; because it is a work area and safety would be paramount of course.
Ideal usage would be a dedicated side track with signals and one way traffic.

NewGRF: Oil Wells in Temperate terrain now can Increase production, Better vehicle names, Use-able default aircraft, Oil Rig for Snowland and Desert, Speed for Suspension bridges.
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Patches (OpenTTD): Improved smooth_economy [in trunk], More (diesel) smoke [in trunk], Realistic_acceleration finetune.
Keep 'em rollin'!
Re: [patch] drive-through depots
2.2 seconds. It is not realistic. Therefore, changes from one arbitrary unrealistic speed to another arbitrary unrealistic speed, for the benefit of just one user, won't happen. Get that into your head.SirkoZ wrote:How long does a day last in OpenTTD?
How're the issues coming along, racetrack?
He's like, some kind of OpenTTD developer.
Re: [patch] drive-through depots
This would be an excellent feature for those of us who build depots that try to be at least the same length as the trains running the track. 
I noticed one slightly strange thing when doing a quick test now. (replicated without having any newgrf's loaded too).
When the train is coming back to the depots, it drives straight through depot 1 and instead enters depot 2. When coming out of depot 2 again towards the stations (through depot 1) it goes in to depot 1 and then exits it again before continuing.

I noticed one slightly strange thing when doing a quick test now. (replicated without having any newgrf's loaded too).
When the train is coming back to the depots, it drives straight through depot 1 and instead enters depot 2. When coming out of depot 2 again towards the stations (through depot 1) it goes in to depot 1 and then exits it again before continuing.
Who is online
Users browsing this forum: No registered users and 11 guests