How to get a 'train' moving on its own

HiBaller

19 Years of Trainz
I've been around Trainz now for around 10 years but I've never really done much more than build a load of routes and run trains manually. Now I've created a nice route that contains an industrial area where I've plopped down a bit of invisible track, some trackmarks, and a few industry stops. My 'train' is actually a tractor/trailer combination that I'd like to have running around the industrial park stopping and starting on its own. Hard to believe, but I've never created an AI train of my own before. In Driver, I can go to the unit and issue the "Drive" command and it dutifully runs around the route, which is cool, but, of course, it doesn't stop anywhere - it just "Drives". I can make it stop by adding commands to 'go here' and 'do that' (ending with a 'repeat' to make it endless), but doing that every time I start a session is counter-productive. I want it to start off by itself. The answer probably lies in setting up a schedule, but I haven't a clue how to do that.

I can create the 'consist', assign a driver and all that, but I'll be darned if I can figure out how to set up a way to automatically kick the consist into motion when I enter a session. In Surveyor, I've discovered that the plain "Drive" command isn't available. Instead, there is the Schedule thing. Is that what I would use? If so, then how is it set up?

EDIT: It's late here and I have to get up early so if I don't get back immediately, I will return in the morning.

Bill
 
Last edited:
You don't need to set a schedule. In Surveyor select "Edit Session" from the main drop down menu and select the Driver rule, the same place where you assign drivers to each loco. There you will see a driver command line for each assigned driver that is very similar to the one that appears at the bottom of the screen in Driver. Add your commands to the list just like you have been doing in Driver. When the session starts in Driver, the command sequence will be executed.
 
Ah, there's the rub. In Driver, there is the 'Drive' command, which I use to just let an AI train toodle down the tracks. This command doesn't exist in Surveyor, so there must be some other way to get the train moving.

Bill
 
Wonderful! Just wonderful! I've been working for over an hour on getting my session just right with "enable repeat" - "drive to trackmark xx" - "drive to trackmark yy" - "repeat". It worked just fine and then out of the clear blue the stupid program asked me (for some asinine reason) if I wanted to save the ROUTE. I haven't been editing the route, just the session (and saving it, going into Driver, running the session, and back to Surveyor). It tried to save and then told me the route was READ ONLY and trashed the whole ferschlugginer thing. I still haven't found out how to put a command string into a "library" for use by other drivers.

My entire hour's work was down the toilet AND I had to fall back on my previous save (which erased all the tracks in my industrial area). Basically, it put me back to where I was six hour ago. I really, really, really, really hate this program.

EDIT: Maybe some kind soul will also tell me why, when I edit a session, I keep having to go into the Driver Command setups andkeep checking the same commands over and over and over again. Doesn't this stupid game retain the checkmarks when you save a session?

Bill
 
Last edited:
Wonderful! Just wonderful! I've been working for over an hour on getting my session just right with "enable repeat" - "drive to trackmark xx" - "drive to trackmark yy" - "repeat". It worked just fine and then out of the clear blue the stupid program asked me (for some asinine reason) if I wanted to save the ROUTE. I haven't been editing the route, just the session (and saving it, going into Driver, running the session, and back to Surveyor). It tried to save and then told me the route was READ ONLY and trashed the whole ferschlugginer thing. I still haven't found out how to put a command string into a "library" for use by other drivers.

My entire hour's work was down the toilet AND I had to fall back on my previous save (which erased all the tracks in my industrial area). Basically, it put me back to where I was six hour ago. I really, really, really, really hate this program.

EDIT: Maybe some kind soul will also tell me why, when I edit a session, I keep having to go into the Driver Command setups andkeep checking the same commands over and over and over again. Doesn't this stupid game retain the checkmarks when you save a session?

Bill

It's the layers problem. I hate layers in Surveyor, and never use them.

To eliminate your problem, do this:

1. Open the session to edit.
2. As soon as it opens, MERGE the session into the ROUTE layer.
3. When you finish your editing save the route. If it says the route is READ ONLY, ignore that and immediately save it again. It'll save it.


Hope this works for you,

Dave
 
I've been aware of the layers and what problems they can cause, so every time I open a route/session to edit I make sure there are only 2 layers (Route and Session). In this case, no extra layers had shown up.

In this particular case of "read only' what happened was that the session appeared to save properly and then when I went to 'exit Surveyor' the message popped up asking me if I wanted to save the route also. I clicked 'yes' and then got the 'read only' message. The choices after that were 'save as...' and 'cancel'. I tried 'save as...' and ended up having my route clobbered even after I'd given it a one-up number to the name. AND the session I had just created was gone (because it was tied to the original name and not the updated name). Reloading the original-named route didn't produce the session either, so I figure that it just got dropped on the floor during the naming episode.

I certainly wish that N3V had spent the effort they did on T:ANE to actually study the errors and problems of TS2012 and FIX THEM before charging off in a new direction trying to mint more money. With the exception of Microsoft and Google, I've never seen a company with less regard for their customers than N3V.

Bill
 
I think one of your problems might be that you need to put things like track marks, industry settings and driver instructions only in the "edit session". They will not be saved if they are put in the "edit route" section. The "edit route" is only for track work and scenery changes. I learnt this the hard way as you have, with things disappearing on me all the time. Normally when you work in "edit route" mode it saves changes into the session as well, automatically.
Another thing I found is that it is best not to use the quick drive button to go to a session. Close Surveyor and go to "sessions", choose your session and click "Drive session".

Also if you check through your CM you may find your session still there. It may have changed the map it is tied to. You just need to go to "Edit in explorer" and change the map kuid if that has happened.
Cheers,
Mike
 
Thanks for the info, Mike, but I've checked to see if the session I want is still around. Not found. When the game tried to save, and told me it was 'read only', it must have decided to just trash the session as 'no longer needed' when I told it to "save as...". Just a long litany of stuff that really needs to be fixed by N3V with an eye towards finding out WHY it happens and preventing 'read only' errors.

I've pretty much always used the Edit Session to do things to test out a theory or try something without actually making it a part of the route. For some lstupid reason, things got out of hand in this case and dealt me a major blow by deleting the current veersion of the route, and both sessions I was working on. I had to fall back to a saved route 8 hours earlier.

EDIT: I suspect that in this case "read only" isn't from the OS, it is from the database because there is some sort of lock on a file that wasn't released when it should have been. Then the game obfuscates the error by calling it a 'read only' problem, when in fact it actually is an "I did it to myself, but i'm gonna blame you for it". There are loads of things like that in Trainz - like telling you that your network is at fault when their own servers are down.

Bill
 
Last edited:
I've had that happen also if I try to save too much at once, so I think this has something to what you're saying Bill. This is a data lock rather than an actual OS function.

John
 
Right, John. There have been innumerable threads complaining of a 'read only' error message and pretty much every time the person claims that they ARE the Administrator and there should be no permission issues like that. The error text is just plain wrong. I am sure it is a database locking error. One of the threads working the DB has gotten ahead of another one storing data and the lock is still active. The thread storing new data gets blocked and immediately screams murder that the 'file' is read only. Most DB creators/users call it a record, but the programmers translated that to file instead of record because most users wouldn't understand an error message that said "Cannot save the route because a record is locked". In fact, they'd go nuts trying to figure out what it did mean. Safer to just call it 'read only' and let the user sort it out. I also agree that trying to save a lot of data (like an hour's worth of intensive work - especially in one spot - will cause multiple threads to run and the possibility of collision is great.

Bill
 
Back
Top