Path control help..

Davie_UCF

Here since 2001, Trainz!!
I'm having issues with path control.

The tutorials on site help slightly but the path trigger one is confusing.


I want to be able to set schedules for my AI so they can travel fine and I can drive without facing locked points they have stolen.. will path control dothis?

Anyway if I set a path from a signal to a signal.. how do I get a train to drive it? Path trigger? I try to add a trigger yet no triggers are in the list, even though I have triggers all over the route.

And the timetable thing, does it have to be used with paths? I set it to a station, but the train just sat there going through the commands it had generated, opening doors but never actually going anywhere.. is there any better tutorials anywhere or some hlep please?

David
 
Path Control is very good, but it does take a bit of figuring out how all the bits fit together.

First set up routes wherever your trains have to cross junctions, this is exactly as the tutorial says. I assume you've got that.

Next, you have to get the train to "call" the route, that is to say, invoke the route ahead of it. If the train is starting from (say) a station, you can add the "PathControl" command to the driver's script. In this case you have two options, to wait for the path to become available, or to call the path then the script carries on to do other things. These are called "Wait" or "Queue" in the driver command menu. Either way, the path is invoked. If the tracks and junctions are clear, the points are called to the right direction and the signal clears. Now you want to tell the train to "Autodrive" to wherever it is to go. Autodrive is like the standard "Drive to" instructions except it doesn't do anything to points ahead - i.e. it just dumbly follows the route set.

If the tracks and points were not clear, then the path control will wait until they do become clear before enabling the path. Once enabled, the points are then locked to prevent any other path trying to use the same route, so preventing collisions. As the train passes it releases the points so other trans can go.

The final thing is Path Trigger. You set up your trigger ahead of a junction so that as the train approaches it calls (invokes) the path as it passes over the trigger. This is an alternative to using the Path Control in the driver script, but it means the train can set its route ahead of itself as it travels along. This is much easier with a moving train than trying to use Path Controls in the driver script.

Hope this helps

Chris
 
Thats a great reply, thankyou! it explains it a lot.

However the trigger part I still do not get... no trigger appear in my list even though I have them, do they have to be somewhere or what?

And.
Will this work like I have said? If i'm freely driving along myself with AI working.. or will my path have to be set too? I guess this works if going through passing loops? I can set the path to go through the loop so the AI doesn't lock the point infront of the loop even though its waiting for me to pass...?

Thanks for your help!
David
 
You need to name the triggers with a preface pattern to the name, eg. "TR-yourname". The path trigger rule has a place where you enter this pattern "TR-". This is to prevent every trigger used from showing up in the rule's menu.
Andyz
 
I downloaded the demo route but it had loads of dependencies i couldn't find even though they all claim to be on DLS.. but i'm using TC3 so i'm missing some builtin stuff too..

Also, issue.
Thanks Andy but I tried it out and got this when it crossed the trigger.


clipboard01jr8.jpg


If I click one of them I get a script error.. ?

Thanks for the help
David
 
Hi Davie,
That is the little screen that pops up whenever a "user driven train" is detected by the trigger. Judging by the options available in that screen , you have selected the trigger into the rule, but you don't have any paths entered for that trigger, only "default" and "ignore" are available.
With no paths connected to the trigger, any of these selections would result in a "null" error in the script. When setup correctly there should be path destinations available for selection. Also any AI trains must be driven using the "autodrive to" or "autodrive through" driver-command in order to be detected by the trigger. Maybe if you post a screeny of the actual setup page of the rule, I could help you more.

Andyz
 
Thanks once again Andy..

I did figure out how to get it showing the route.. but the main thing for me is the AI.. when AI drive past the trigger that pops up.. if i remember correctly...

So only AI under autopilot works?
How could UI use this in a timetable, would I have to set up the entire path across the route using lots more paths?> I was hoping to just use paths to help get through stations and passing loops?

Appreciate your help greatly! each step gets me closer to making my route work, after all these months of making it!
 
I tried to use PathControl in TC3 and it does absolutely nothing. I'm pretty sure I set it up correctly, so could it be that it just doesn't work in TC3?
Thanks,
Mick Berg.
EDIT...H'mmm, I see now that Davey UCF is using TC3. So that isn't the problem.
 
Last edited:
I tried to use PathControl in TC3 and it does absolutely nothing. I'm pretty sure I set it up correctly, so could it be that it just doesn't work in TC3?
Thanks,
Mick Berg.
EDIT...H'mmm, I see now that Davey UCF is using TC3. So that isn't the problem.

I guess its your settings, but i've not done a lot with it, parts of it seem to work, ive had a path set before.
 
Hi Davie,
I use path-control and triggers as follows:

1. I only use path control on complex station/yard sections.

2. Any departure from a station or yard does not need a trigger, just use the "setpath" command with the "wait for" option, then the "autodrive" command, to a trackmark placed (at least 30m) past the last set of points in the path, then continue with standard driver commands.

3. At least 30m before the path-trigger, place a trackmark "start-of-path etc", then use a "drive via trackmark" command followed by the "autodrive to (or through)" command.

4. When a path ends in a station where the train needs to load, place a trackmark just before the platform starts, use "autodrive through" this trackmark followed by the "drive to (station)" and "load" commands.

5. If required, the path-trigger can also set multiple consecutive paths, just keep adding them below each other to the same trigger.

6. the fact that only autodrive commands are detected, can be used in your favour. That is, you can send a train with "drive to" or "drive to trackmark" commands and not have the path set.

7. Experiment, experiment, experiment, ...........

I hope this was helpful.

Cheers
Andyz
 
Hi Davie,
I use path-control and triggers as follows:

1. I only use path control on complex station/yard sections.

2. Any departure from a station or yard does not need a trigger, just use the "setpath" command with the "wait for" option, then the "autodrive" command, to a trackmark placed (at least 30m) past the last set of points in the path, then continue with standard driver commands.

3. At least 30m before the path-trigger, place a trackmark "start-of-path etc", then use a "drive via trackmark" command followed by the "autodrive to (or through)" command.

4. When a path ends in a station where the train needs to load, place a trackmark just before the platform starts, use "autodrive through" this trackmark followed by the "drive to (station)" and "load" commands.

5. If required, the path-trigger can also set multiple consecutive paths, just keep adding them below each other to the same trigger.

6. the fact that only autodrive commands are detected, can be used in your favour. That is, you can send a train with "drive to" or "drive to trackmark" commands and not have the path set.

7. Experiment, experiment, experiment, ...........

I hope this was helpful.

Cheers
Andyz

Thanks Andy..
Are you using TC3?
When i've used Set path its just sat there, even once paths set?

Thanks
David
 
Hi David, I'm using trs2006.
When you say "its just sat there", do you mean the drivercommand icon?
I assume you are using the correct setpath command, the one called "pathcontrol_setpath" by brumfondel and not "Path Command" by mutton?
If you are using the correct rules, than a information/debug screen is available in driver mode, via the "k" key. There you can check which paths are currently running, and a heap of other information.
Another thing to check in the "path rule", is that the starting signal for the path has been set to other than red. By clicking on the signal icon you can cycle through the different signal aspect states.

In the path trigger rule the following data is mandatory:
1. (Obviously) a trigger name.
2. A minimum of 2 paths.
3. A destination trackmark name for each path. One of the paths may be set to be a default path. (ie. will be set if non of the trains "autodrive destinations" match), in which case no destination name is required for that path.

Finally there is one failing in the path-trigger rule, it does not work in "saved sessions", however the path rule can be used very well without the path trigger rule, I often do.

Cheers,
Andyz
 
I'm back after a trainz hiatus and I encounter this hell once more!

I can get it to set a path then use autopilot for it to run through the path.
The train has passed.. but the junctions are still locked.. is this normal? How do you get them released afterwards?
 
I sorted it out, it has to get to the end of the path, obvious really but I had two paths confused!

If anyones paying attention...
Does this work for human trains also? So I can drive around with the AI doing its paths.. would it not lock routes as it doesnt take my human train into acount?

Thanks
 
Hi again Davie,
'human' trains can set paths just like AI trains, just place a "set path" driver command in the command bar (your train must have a driver assigned to it for this to work).
Of course, your train has to stop first in order to set a path, unless a path trigger is used.
The paths are mutually exlusive, whether set by AI, or Human drivers, except where the paths only cross eachother (have no junctions in common). In that case the (M)utual e(X)clusive setting in the path control rule can be used.
This is where one path also locks a junction in another path and vica versa.
As far as I know, the 'path control' method is the only reliable way to mix 'Human' and AI drivers without fighting over junctions.

cheers Andyz
 
Hey again,

Thanks!
I've managed to get it working, the trigger system works for getting through passing loops and the driver commands work for AI in stations.

Just have to attempt to set it up for most of my route..

The only downside i've noticed is it doesn't like the semaphore signals in TC3, they change colour aspect to green but don't animate, what a pain, ruins a bit of the atmosphere!

David
 
Back
Top