Route Building Tutorial 2: Stations, Stops and the Time

In this second tutorial, we will describe some of the commands used in the With Track section which we previously included in our route code. We will then add an additional station to the route and place a couple of free objects which will make driving the route easier.

No additional objects will be required for this part.

Time to open the route file and get coding…

The route file we created previously should look like this;

Having previously described the coding above the With Track part of the code, we now need to have a look at what follows this statement.

Looking at the code, all the lines start with a number. This represents the distance from the start of the route in metres and is followed immediately by a comma.

The majority of object types and commands should be positioned only at 25m increments, exception to this will be highlighted as needed.

At 0 metres, we find this code:

.Ground 1, sets the ground type to that indexed in the ‘with structure’ section of the route file, in our route, ground1.CSV is the object file indexed as ground 1 – more on this in future tutorials.

.back 0, sets the background bitmap to that indexed in the ‘with structure’ section of the route file, here background_1.bmp is the background image file. Changing the background images will be covered in a future tutorial.

.railtype 0;1, sets the rail type of rail 0 (which is always the running rail) to that indexed in the ‘with structure’ section of the route file, in our route, railtype 1 is a standard straight section of rail – more on this in the next tutorial.

All BVE routes MUST have two or more stations. In our route, these are at 0m and 2500m. At these distances, we find the station commands – these are the most complex commands used in BVE, but here goes with the explanation. Looking at the second station as an example;

The semicolons are used to separate the individual attributes of the command, these are in the order

Station name; – the name of the station (appears on the jump to station list)
;arrival time; – in hours.minutesseconds ** note the syntax used **
;departure time; – also in hours.minutes seconds
;pass alarm; – NOT used in BVE 4, leave blank
;door opening side; – use -1 for the left, 1 for the right.
;signal at station; – IF there is a signal immediately after the station, 1 shows red, 0 green
;safety system; – NOT used in BVE 4, leave blank
;sound; – filename of sound played on arrival at station
;dwell time; – the minimum station dwell time in seconds
;loading factor; – how full the train is (0-250), values >100 may cause door problems
;train departing sound; – filename of sound played when departing the station
;timetable index, – denotes the timetable to be displayed in the cab (on pressing F3)

Time to have a fiddle about and change some of these settings! (Resave the route to a different file if you wish after making any changes).

Renaming the stations – Now, think of names for the stations and change them like this from:

To:

Simliarly, change the second station, from:

To:

Now save the route and check the changes were successful by loading the route and using the right mouse button to view the jump to station list. It is useful when developing routes to use BVE in windowed mode as it remains possible to switch between Windows applications without problems.

Next, if we want to change the time at which the train is running (for example to 9.08), the following alterations would be needed;
From:

To:

Similiarly, the second station, should be changed from:

To:

Other changes you might like to experiment with include changing the passenger load factor (which will alter the train performance) –

From:

To:

The higher passenger load will result in a more sluggish train performance and possibly problems with the doors closing (as passengers become wedged in the doorway!!).

The other command required at stations where a train is to call is the stop command – this should be placed at the actual stopping position of the front of the train (and must be placed after the .sta command)

The x value refers to the maximum distance (in metres) before a station at which you may stop before being ‘called on’ by BVE and the y value the distance after which you will be called back. In our example, at the second station, we are allowed +- 30 metres (which is over two carriage lengths) of tolerance. This is perhaps unrealistically high as in real life, driver skill normally ensures stops are within 5-10 metres of the nominal stop point. So, to make our route driving experience more challenging (and accurate), change

To:

Notice again the syntax and the positioning of the , . and ; The free object is the marker which has been placed to show where to stop.

A default marker may also be displayed at the stop point by altering the first number after the stop command, by changing

which shows no BVE default stop position marker
To:

which will place the BVE default stop marker on the left hand side of the track whilst changing the code to

will place the BVE default sop marker on the right hand side of the track.

In real life, there are normally car stop signs on the platforms to show drivers where to stop – we will be creating these later. For now, I have shown the stopping point at the second station with the yellow ‘stop here sign’ which is easily visible from a distance (unlike the BVE default marker).

If you look in the ‘With structure’ part of the code you will see

Free object number 2 is the yellow ‘stop here’ sign which is generated by the object file stop_here.csv. This has been placed at the same distance as our stopping point using .freeobj 0;2, at 2600m, so in the absence of platforms, car stop signs and the like, we can clearly see where to stop. If you want to remove the yellow sign from the route, delete the code .freeobj 0;2,

(The .freeobj command will be looked at in more detail in a later tutorial.)

Having now examined the commands needed to make a station stop, lets add another station to our route at 5km. For this we need to add the station command a short distance before our desired stopping point, 4900m will be ideal, so add this code to the end of the route, giving the station a name of your choice;

Take extra care with the syntax of station commands, particularly the number of semi-colons.

** note the time – if you did not change the times as described in the previous part of this tutorial, you will need to use 12.3600;12.3700 **.

The arrival time has been estimated given the fact that we need to make a standing start, accelerate and brake to a stand at the stopping point. The station stop timings can be adjusted at a later date if we find early or late running is a persistent occurrence.

We also need to position our stopping point by adding this code to the end of the route file –

For this station, we are using the default BVE stop marker and no advanced warning of the stop, which for the second station is given by

Free object 1 being the yellow 500m warning sign object.

Now if we drive the route, we will find that the stopping point for the third station is very hard to see and has no advance warning.

In reality, local landmarks combined with route knowledge will give advance warning of a station stop and the stop point will be clearly marked (or at least evident by the presence of a platform!).

We can correct this by including our yellow signs on the approach to the third station by adding the free objects (being careful with the syntax),

Now if the route is driven, advanced warning of the stop will be visible and the stop point clearly marked.

We now have a 5km route with three ‘stations’, having learnt how to add station stops and show the stopping position by either using the default BVE marker or by using a free objects to not only show the stop point but also give advanced warning.

In the next tutorial, we will change the appearance of the rail, add some curves to our route, make it twin track and learn about run sounds.

Leave a Reply

Your email address will not be published. Required fields are marked *