29
Building a 20 Dexter Basics to ro 2/22/2016 a route for open 016 oute building in BVE nBVE

Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

  • Upload
    others

  • View
    31

  • Download
    2

Embed Size (px)

Citation preview

Page 1: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Building a route for openBVE

2016

Dexter

Basics to route building in BVE

2/22/2016

Building a route for openBVE

2016

Basics to route building in BVE

Building a route for openBVE

Page 2: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 2

CONTENTS

1. INTRODUCTION.......................................................................................................................................................... 3

2. FILE FORMATS ............................................................................................................................................................ 3

3. TO BE CONSIDERED ................................................................................................................................................... 3

4. ROUTE FILE SCHEME .................................................................................................................................................. 4

4.1 SYNTAX BASICS ...................................................................................................................................................... 4

4.2 KEY CHARACTERS IN SYNTAX ..................................................................................................................................... 4

4.3 BEGINNING THE CONSTRUCTION ............................................................................................................................... 4

4.4 ROUTE FILE SECTIONS (NAMESPACES) ........................................................................................................................ 5

5. BUILDING THE RAILS .................................................................................................................................................. 5

5.1 INSERTING STATIONS ............................................................................................................................................... 5

5.2 HEIGHT OF THE TRACK ............................................................................................................................................. 6

5.3 CURVES AND BANKINGS ........................................................................................................................................... 7

5.4 CHANGING RAIL TYPES ............................................................................................................................................. 8

5.5 ADDING MORE RAILS ............................................................................................................................................... 8

5.6 RAIL HEIGHT CHANGES .......................................................................................................................................... 10

5.7 ENDING A RAIL ..................................................................................................................................................... 10

5.8 APPLYING PITCH TO THE TRACKS .............................................................................................................................. 11

5.9 TRACK QUALITY & ADHESION.................................................................................................................................. 12

5.10 SETTING RAIL SOUNDS ........................................................................................................................................... 12

5.11 SWITCHES BUILDING .............................................................................................................................................. 15

6. LIGHTING AND ANNOUNCEMENTS ......................................................................................................................... 18

7.1 FOG ................................................................................................................................................................... 19

7.2 BRIGHTNESS ........................................................................................................................................................ 19

7.3 ANNOUNCEMENTS AND LOOPING SOUNDS ............................................................................................................... 20

8 DIKES, WALLS & CRACK ............................................................................................................................................ 21

7.1 DIKES AND WALLS ................................................................................................................................................ 21

7.2 CRACK COMMAND ................................................................................................................................................ 24

8 PLATFORMS & TRACTION MAINS ............................................................................................................................ 25

8.1 PLATFORMS......................................................................................................................................................... 25

8.2 TRACTION MAINS ................................................................................................................................................. 27

9 ADDITIONAL INFORMATION .................................................................................................................................... 29

10 ACNOWLEDGEMENT ................................................................................................................................................ 29

Page 3: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Introduction 3

1. INTRODUCTION Everyone, who has once driven a train in BVE or openBVE has surely thought about building his own

route. This guide will try to explain what is needed to achieve that. As the outcome, you should be able

to compose a route from pre-made objects.

Building a route for the BVE / openBVE simulator was unfortunately never the easiest thing on the

planet, because there has been no editor to help you out. This issue has been partly been tackled by

openBVE Script Editor created by Phil Eakins. I suggest downloading the tool here

http://brnobve.eu/?page_id=195, as it will help you with the commands and guide you through their

parameters. But let’s not skip forwards, we will get to that stage a little bit later. Many authors still use

NotePad or WordPad to write their routes, which, of course, requires a lot of knowledge (syntax,

commands). The old way of building a BVE / openBVE route could be compared to writing a HTML page,

which required knowing the HTML tags.

BVE was evolving quite quickly when in its beginnings and therefore there are a few versions of the

simulator and also corresponding versions of syntax. These syntax versions have their specific limitations,

since (as mentioned before) they were developed with a corresponding version of the simulator.

Before we start with the guide itself, it is important to have some basic knowledge – that means we need

to be able to download and install the simulator properly. In case you have any questions or doubts,

please ask for advice within the BVE WorldWide forum.

2. FILE FORMATS There is two file formats, but each of them has a couple of subtypes:

RW v.1 – syntax used for BVE 1.x

RW v.2 – syntax used for BVE 2.x

CSV v.1 – syntax for BVE 2.x

CSV v.2 – szntax for BVE 4.x

In the past, I have experienced some authors combining more types of syntax into one file along with

mixing up the sections of a route file. This usually leads to loading errors and the route being interpreted

incorrectly.

3. TO BE CONSIDERED BVE has been a simulator composed of static objects only, while in openBVE, animations can be used. In

BVE the route is rendering in segments. Each segment has 25 meters and the simulator can only load the

route up to 600 meter’s distance of your current location point. In praxis, once you pass the current 25

meter segment in BVE, it disappears, and a new one renders at the set distance ahead of you.

OpenBVE works differently – it can render longer distances of the route and there are no segments. From

my observation it renders the set distance (for example 1000m) backwards and forwards from your

current location. However, openBVE has much more efficient render and therefore it runs smoother

despite processing more graphical data.

Page 4: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Route file scheme 4

4. ROUTE FILE SCHEME The route file is composed of a few parts, where each of them has its characteristic commands. Basically

speaking, the route file can be divided into the train definition, objects definition and the route itself. By

a closer examination of the route file, we will be able to discover the following sections in the file - Train,

Route, Structure, Texture, Cycle, Track. The order of these sections is not strictly given, since the whole

file is being read when the route is loaded anyway. It is, however, recommended to keep this order of

sections to make your code synoptic and easy to navigate through.

4.1 SYNTAX BASICS Before moving to the actual route construction, a few details need to be mentioned. BVE / openBVE is

not case sensitive, therefore you can use small letters, caps or whatever you like.

There is a full and abbreviated syntax in the simulator. The syntax can be abbreviated in a couple of

ways, but the one important for us involves using “With”. See the examples below:

Full Abbreviated

Section.Command With Section

.Command

Knowing the difference between the full and abbreviated version of the syntax, we can take a look at an

example. Let’s take the section “track” into consideration and let’s see how a couple of commands will

look like using the two types of syntax.

Full Abbreviated

Track.Rail,

Track.Pitch,

Track.Height,

With Track

.Rail

.Pitch

.Height

4.2 KEY CHARACTERS IN SYNTAX , (comma) – terminates the command section, allows proceeding to the next command or a note

; (semicolon) – separating the parameters in a single commands

$ (dollar) – introduces special command

. (dot) – used as the decimal separator

The route distance is defined in meters and has to be represented by integers. It is also possible to put

notes into your route file; in order to do this, you must write a complete command and put a semicolon

after it. The note after the semicolon is the omitted by the simulator when reading the route file.

4.3 BEGINNING THE CONSTRUCTION This is where we need to have the actual simulator and its tools (Route viewer) installed. If you need help

to install openBVE and Route Viewer, feel free to ask for support at BVE WorldWide. Also, it is

recommended to have some of the already existing routes and trains installed, as we will be using some

objects and a train for educational purposes.

Let’s begin the route construction with the simplest functioning route that can be built for the sim. Such

route has to contain a train definition, a rail object definition, a ground object definition, a background

Page 5: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 5

image and at least two stops with a defined place to stop so that we can run and play the route in the

actual simulator. Once we have these features defined, we can extend the route later.

There is, of course a program called Route Viewer that will enable you to check your progress easily.

After loading the route, simply use F5 to refresh and see any changes made to the route file. If you are

still using BVE 4.x, you can also go to Options -> User and tick the Developer field. That activates a new

menu item in the sim – Viewer Mode. This viewer mode has very intuitive controls and if you are an

experienced train driver (in BVE or openBVE, of course), you will not have any problems to navigate

through it.

4.4 ROUTE FILE SECTIONS (NAMESPACES) We will begin the actual route construction by creating a new simple text file in our Route folder. The file

can have a random name, so I will call it example.csv. In this file, we need to create the basic scheme of

structures, as we discussed it earlier. We will use the abbreviated version, utilizing „With“. The first

section defined will be Train, which along with the Folder command will define the actual vehicle we will

be using. We can select any train we have got installed, for now I will go with my 163-133-7. Next, we will

move to section Structure and we will define the commands Rail and Ground. These two commands

pretty much do what they say, they define the Rail and Ground objects to be used in the route. For both

of these structures, I will use the objects from my route – tr_straight.csv for the rail object, and

grassrise.csv for the ground object. It is very important to write the path to these files correctly. Last, but

not the least, we create the Texture section with its Background command. I will use the Bg1.jpg from

my route for the background. OpenBVE also allows you to define how many times (horizontally) the

texture will be displayed. If you choose quantity larger than one, you need to have a seamless texture.

Here is what we will end up with:

With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0) FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

Note: The number in brackets represents the object index.

5. BUILDING THE RAILS

5.1 INSERTING STATIONS Now that we have got the very basics written down, we can proceed to creating a route that is actually

runable in the simulator. If you remember the previous discussion, you should know, we are only missing

two stations to achieve that. To introduce the necessary command, we need to add the Track section

first, then we can use the commands Sta and Stop.

Of course, to use the commands properly, we need to know the syntax.

Track.Sta (Name; Time1; Time2; Blank; DOOR; Stop; Blank; Sound1; Halt; Jam; Sound2; TimetableIndex)

• Name: Station name

• Time1: Arrival time (HH.MMSS, or put “P” for the train to pass the station)

Page 6: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 6

• Time2: Departure time (HH.MMSS, or put “T” if this is the terminal station of your route)

• Blank: Not used in BVE4 and openBVE

• Door: (-1 to open left, 1 to open right)

• Stop: Station signal setting (1 shows red before the train stops, 0 shows green)

• Blank: Not used in BVE4 and openBVE

• Sound1: Sound played upon the train’s arrival

• Halt: Minimum station waiting time of the train in seconds

• Jam: Train occupancy in % (0 – 250)

• Sound2: Sound played upon the train’s departure

• TimetableIndex: Index of the train’s timetable

• We can leave some of the parameters blank if we don’t need to use them.

Track.Stop (MarkerDir; MarginBk, MarginFw)

• MarkerDir: The exact stopping point (-1 marker shown on left, 0 not shown, 1 shown on right)

• MarginBK: Stopping mistake toleration backwards in meters

• MarginFW: Stopping mistake toleration forwards in meters

And here is what we will end up with: And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0) FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

5,

.Stop 1

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Some of you might notice that even though we have defined a rail object in our short route file, we have

not used it anywhere. Yet the rail is still visible in the viewer. This is happening because the rail, which is

used by our train (uses index 0), is created automatically without questions asked. This, however, does

not happen for any other rail, we have to display any accompanying rails manually.

5.2 HEIGHT OF THE TRACK Another thing to be noticed is that the rail, which has been created automatically, is hidden in the

ground (or covered in grass, if you wish). This is because the implicit height of the track set by the

simulator is 0, which is often the height of the actual ground. Therefore, to make our rail visible, we need

to apply height command to it. The command will be right at the beginning of the route (distance 0

meters) to ensure the track starts at the correct height. We must not forget the decimal separator is a

dot. Also, the height command can only be put in distance, that is a multiple of 25 meters (+0).

Page 7: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 7

And here is what we will end up with: And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0) FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

5,

.Stop 1

.Height 0.4,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

5.3 CURVES AND BANKINGS Now that we have successfully created a segment of straight track, let us look at how to make curves. I

seriously doubt there is any route in the world that only contains straight tracks. In openBVE (BVE), the

track direction can be modified using the curve command.

Track.Curve (Radius; Cant)

• Radius: In meters, positive turns right, negative turns left

• Cant: In millimeters, positive only, creates banked curve

• Can only be placed in distance that is a multiple of 25 meters (+0).

• To end a curve, we need to use radius 0, analogically to end a banking, the cant has to be 0

And here is what we will end up with: And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0) FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

5,

.Stop 1

.Height 0.4,

25,

.Curve 500, 90,

125,

.Curve 0, 0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Page 8: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 8

5.4 CHANGING RAIL TYPES As you can see in the picture, the curve is currently composed of straight pieces of track, which does not

look good at all. Fixing this issue is not difficult at all, but we will need to define another rail object to

help us out, and another command to apply that object. In this case, we will be working with a right

curve with radius 550 meters. Again, I will be using the curved rail object and the path to it as it looks in

my route. The command to change the rail visual appearance is RailType.

Track.RailType (Index; StructureIndex)

• Index: Index of the affected rail

• StructureIndex: Object index of the rail

• Can only be placed in distance that is a multiple of 25 meters (+0).

And here is what we will end up with: And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Rail(1) FirstBrnoTrack\track\550R.csv

.Ground(0) FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

5,

.Stop 1

.Height 0.4,

25,

.Curve 500, 90,

.RailType,0,1

125,

.Curve 0, 0,

.RailType,0,0

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

5.5 ADDING MORE RAILS As you can see in the picture, the straight rail segments have been replaced by the curved object. It is

always a good idea to match the object radius with the radius you are setting in your route file. Also, it

needs to be pointed out that we have used the rail index 0 to change the appearance of our rail. This is

because as mentioned before, the rail our train is using in the sim is created automatically, and it always

has index 0. Therefore, any time you will need to change the rail your train is using to travel, you will

need to put 0 as the rail index. Enough talking about one rail, though, let’s add another. This is done by

the Rail command.

Track.Rail (Index; X; Y; StructureIndex)

• Index: Index of the rail (1-15)

Page 9: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 9

• X: Horizontal distance from our rail (- will be on the left, + will be on the right)

• Y: Vertical position of the rail relative to our rail

• StructureIndex: Object index of the rail

• Can only be placed in distance that is a multiple of 25 meters (+0).

The picture and syntax below shows an example of a new rail being created 3.8 meters to the right from

our rail (the one with index 0). Similarly as before, the new rail is composed of straight rail segments.

There are two ways to change that – we can either use the RailType command with the corresponding

rail index, which is faster, but the correct syntax in this case is to use the Rail command again. See the

syntax and pictures below. The sections train, Structure and Texture stay the same as in the previous

example, so I have removed them from the code below. However, they have to be included in the actual

route file. Please keep that in mind.

Firstly, defining the second rail: And here is how it will look like: With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Rail 1;3.8;0;0

5,

.Stop 1

.Height 0.4,

25,

.Curve 500, 90,

.RailType,0,1

125,

.Curve 0, 0,

.RailType,0,0

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

And secondly, changing the rail appearance: And here is how it will look like: With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Rail 1;3.8;0;0

5,

.Stop 1

.Height 0.4,

25,

.Curve 500, 90,

.RailType,0,1

.Rail 1;3.8;0;1

125,

.Curve 0, 0,

.RailType,0,0

.Rail 1;3.8;0;1

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Page 10: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 10

5.6 RAIL HEIGHT CHANGES Let us now move forwards past the curve, where we will practice changing the rail height. Analogically,

we can change the horizontal distance between the two rails.

Changing the height of rail 1: And here is how it will look like: With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Rail 1;3.8;0;0

5,

.Stop 1

.Height 0.4,

25,

.Curve 500, 90,

.RailType,0,1

.Rail 1;3.8;0;1

125,

.Curve 0, 0,

.RailType,0,0

.Rail 1;3.8;0;1

150,

.Rail 1;3.8;-0.5;0,

200,

.Rail 1;3.8;0;0,

225,

.Rail 1;3.8;0.5;0,

250,

.Rail 1;3.8;0;0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

5.7 ENDING A RAIL So, there we have adding a second rail, changing the railtype and changing the rail height sorted out. As

mentioned before, we can analogically change the horizontal distance of rail 1 from our rail. That would

involve changing the X parameter instead of the Y parameter on the rail command. I believe it is

understandable without any difficulties.

When building a route, you will sometimes get into a situation, when certain rails need to end. The

simulator does, of course, offer a command that enables you to do that. Let’s have a closer look at that.

To end a rail, you will need the command RailEnd.

Track.RailEnd (Index; X; Y; StructureIndex)

• Index: Index of the rail (1-15)

• X: Horizontal distance from our rail (- will be on the left, + will be on the right)

• Y: Vertical position of the rail relative to our rail

• Can only be placed in distance that is a multiple of 25 meters (+0).

See the practical use of the command below.

Page 11: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 11

Ending rail 1: And here is how it will look like: With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Rail 1;3.8;0;0

5,

.Stop 1

.Height 0.4,

25,

.Curve 500, 90,

.RailType,0,1

.Rail 1;3.8;0;1

125,

.Curve 0, 0,

.RailType,0,0

.Rail 1;3.8;0;1

250,

.RailEnd 1;3.8;0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

5.8 APPLYING PITCH TO THE TRACKS We have already seen how to change the height of the accompanying rail, but we are still missing the

information on how to do the same for the rail we are travelling on. This requires the Pitch command.

Please be aware that since this command is implicitly applied to rail 0, it automatically rises everything

else (other rails, objects, grounds etc.)

Track.Pitch (Rate)

• Rate: ‰ (positive values for rising, negative for descending)

• To restore a horizontal rail, another Pitch has to be put with “0” as a parameter

• Can only be placed in distance that is a multiple of 25 meters (+0).

The demanded pitch can be calculated easily, the basic formula is:

Track pitch = 1000 * elevation difference / distance for the difference

As an example, where we want to descend our route by 1 meter on a 170 meters distance:

Pitch = 1000 * 1 / 170 -> 1000 / 170 -> 5.88 let's not forget we are descending, therefore the resulting

value is - 5.88

Page 12: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 12

Applying pitch: And here is how it will look like: With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Rail 1;3.8;0;0

5,

.Stop 1

.Height 0.4,

25,

.Curve 500, 90,

.RailType,0,1

.Rail 1;3.8;0;1

125,

.Curve 0, 0,

.RailType,0,0

.Rail 1;3.8;0;1

225,

.Pitch 30,

250,

.RailEnd 1;3.8;0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

5.9 TRACK QUALITY & ADHESION In order to for the simulation to be as realistic as possible, we can set some interesting attributes of the

tracks. First of them is the actual track quality – which, in the simulator itself, will affect the train

behavior. The lower the track quality, the more the train will swerve at higher speed. It is the Accuracy

command that we will need to use here.

Track.Accuracy (Rank)

• Rank: 0 – 4, where 0 is the poor quality and 4 is high quality

• Can only be placed in distance that is a multiple of 25 meters (+0).

Another parameter that we can set does in fact simulate the route adhesion under different weather

conditions. As obvious from physics, the adhesion of two steel surfaces differs when the surfaces are dry,

wet, or for example covered covered in frost. The Adhesion command is the one that enables us to

simulate the effect of different weather conditions.

Track.Adhesion (Rate)

• Rate: adhesion coefficient in % (dry = 135, wet = 93, frost = 85, snow = 50)

• Can only be placed in distance that is a multiple of 25 meters (+0).

5.10 SETTING RAIL SOUNDS Until now, we haven’t really been working with any sounds in the route, yet if you tried to run it in the

simulator, you would still hear “some” sound. Here’s why. Every train can have up to 8 sound files, with

each of them representing a different type of track (bridges, tunnels, high quality track…). While in BVE

2.x these sounds had to be labeled Run0.wav – Run7.wav, this restriction has been removed in BVE4 and

Page 13: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 13

openBVE and the naming of these files is solely the author’s choice. That said, if there is no sound setting

within the train file, the sound assigned to index 0 is played the whole time.

It is always a good idea to check the actual train folder to see what sounds it contains and what you can

work with.

The sounds are a always dependent on the author of a train, but in order to keep cross compatibility of

different trains with different routes and also to ensure the correct sound is being played at the given

track type, the BVE Track Sound Standard (BVE TSS) has been introduced. Here is an overview of sound

indexes and their relations to the track type:

Sound Index Track type

0 Rails with dilatations, wooden sleepers

1 Rails with dilatations, concrete sleepers

2 Welded rails

3 Welded rails – tunnel, underpass, bridge

4 Welded rails – tunnel, underpass, bridge

5 Train passing – welded rails

6 Iron bridge

7 Train passing – rails with dilatations

Now that we know which sound index we should use for a given type of track, we can define the sounds

in the route file. This is done in the Train section.

Train.Run (StructureIndex) (value)

• Structure Index: index of the rail object

• Value: Index of the train run sound (0-7)

Here’s the code: With Train

.Folder 163-133-7v4

.Run (0) 0

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0) FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Stanice A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1;0;0,

1000,

.Sta Stanice B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Obviously there is nothing to be shown graphically, but what you can do is enter the sim with the setting as

it is written above, try it out, and then change the value for .Run (0) 1. If you then enter the simulator

again, you will notice a difference in the audio.

Page 14: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 14

It is also possible to define two or even more sounds for the same-looking rail (even for the same object),

for that, the same rail object needs to be defined under two different rail indexes.

Here’s the code: With Train

.Folder 163-133-7v4

.Run (0) 0

.Run (1) 2

.Run (2) 1

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Rail(1) FirstBrnoTrack\track\tr_straight.csv

.Rail(2) FirstBrnoTrack\track\550R.csv

.Ground(0) FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Stanice A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1;0;0,

1000,

.Sta Stanice B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

As you can see in the code above, I have also added the curved rail object in there. It can be using the

same, or a different sound index – on high quality routes you usually don’t notice any acoustic difference

between going on straight piece of track and going through a curve. However, if the train is going really

fast, or the track is not of the highest standard, you can often hear the wheels of the train squealing on the

rails. This can also be achieved in the simulator – using the Flange definition.

Train.Flange (StructureIndex) (value)

• Structure Index: index of the rail object

• Value: Index of the train run sound (0-7)

Definition: With Train

.Folder 163-133-7v4

.Run (0) 0

.Run (1) 2

.Run (2) 1

.Flange (2) 0

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Rail(1) FirstBrnoTrack\track\tr_straight.csv

.Rail(2) FirstBrnoTrack\track\550R.csv

.Ground(0) FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

Page 15: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 15

5.11 SWITCHES BUILDING There are two ways of creating a switch in the simulator, each of them having their special syntax and

properties. Let us now look at both of them; we will discuss the advantages and disadvantages as well.

Train.Turn (Slope)

• Slope: Rail diversion in meters (+ to the right, - to the left)

• Value: Index of the train run sound (0-7)

OR

Track.Curve (Radius; Cant)

• Radius: In meters, positive turns right, negative turns left

• Cant: In millimeters, positive only, creates banked curve

• Can only be placed in distance that is a multiple of 25 meters (+0).

We have, of course, already seen the curve command, but we have not used it for a track switch. If you

You are wondering what is difference between these two ways of writing a switch, let me explain that.

The main difference is the train behavior. If we put the curve command, the train moves smoothly along

an invisible circle. On the other hand, if we put the turn command, the simulator creates a diversion of

the rail at one exact point and from there, the rail continues straight on again in the set direction. It is

probably difficult to explain, so have a look at the example.

Using Turn command And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.Turn 1

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Right, so now we know what the turn command does, we can move on to actually building a switch. I am going to

use calculations based on my route First Brno Track, where the horizontal distance between two rails is 3.8

meters, but the formulae used are applicable for any value. It also needs to be said that the simulator is sort of

tied with by the object placement system, as we can only change the rail type every 25 meters. Therefore, the

switch might be a little bit sharper than in reality and we will just have to put up with that.

So, we have got the two parallel rails running 3.8 meters away from each other. The switch itself is 25 meters long

and the reverse switch (connection to the other rail) is another 25 meters, so that is 50 meters in total. The turn

command utilizes the horizontal rail distance per meter. Speaking about our example then, we need the rail

distance to be 1.9 meters after 25 meters of rail length. The calculation is simple: 1.9 / 25 = 0.076

Page 16: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 16

0.076 is the slope value we will use in the command. Remember that after 50 meters, when we are actually in a

position identical with the second rail, we need to perform the reverse turn with the same, but negative, value.

Using Turn command – positive and negative value And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.Turn 0.076

75,

.Turn -0.076

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

We have the base of the switch completed, but we obviously need to add the parallel rails. The only

thing we need to do is to calculate the horizontal distance correctly. We already know that each of the

rail pieces measures 25 meters. Therefore, at the beginning, the horizontal distance of the left rail is 0 at

the beginning of the switch, 1.9 in the middle and 3.8 at the end of the switch. The right rail obviously

goes vice-versa as we are basically going towards it. So we start at 3.8, go through 1.9 and end with 0.

Also, the right parallel rail will end at the point where we join it. See the example below.

Building the switch And here is how it will look like: With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.Turn 0.076

.RailType 0;1,

.Rail 1;0;0;1,

.Rail 2;4;0;0,

50

.Rail 1;-2;0;0,

.Rail 2;2;0;1,

75,

.Turn -0.076

.RailType 0;0,

.Rail 1;-4;0;0,

.Rail 2;0;0;0,

100,

.RailEnd 2;0;0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Page 17: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | 5. Building the rails 17

The switch is now completed, but it does not look very realistic. We need to fix that by replacing some

parts of the switch with realistic objects. These objects need to be loaded in the Structure section of the

route file. We will show that in the next example, we will be loading a switch and a reversed switch

object. To do that, we will need to use the FreeObject command.

Track.FreeObject (Index, StructureIndex, X-offset, Y-offset, Yaw, Pitch, Roll)

• Index: Rail index (-1 object freely on terrain, 0-15 object attached to the rail with that index)

• StructureIndex: Object index

• X-offset: X position

• Y-offset: Y position

• Yaw: X rotation

• Pitch: Y rotation

• Roll: Z rotation

But before that, we need to realize if we want to replace some of the already used rails, we need to

make those replaced rails invisible first. Since there is no way in the sim to end the rail 0 (our rail), we

will need to use a trick – we will set the railtype of our rail to an invisible object (empty object file).

Using Turn command – positive and negative value And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Rail(1) FirstBrnoTrack\track\null.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.FreeObj(0)\FirstBrnoTrack\track\tr_SwitchRight.csv

.FreeObj(1)\FirstBrnoTrack\track\tr_ConnectionLeft.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.FreeObj 1;0;0;0;0,

.Turn -0.076

.RailType 0;1,

.Rail 1;0;0;1,

.Rail 2;4;0;0,

50,

.Rail 1;-2;0;1,

.Rail 2;2;0;0,

75,

.FreeObj 2;1;0;0;0,

.Turn -0.076

.RailType 0;0,

.Rail 1;-4;0;0,

.Rail 2;0;0;0,

100,

.RailEnd 2;0;0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Page 18: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Lighting and announcements 18

If you go into the simulator and try to drive through the switch, you will find out the train does not

actually follow any curve at all, it does simply change the direction sharply exactly at where the turn

command is applied. This is not very realistic and precise, as you can see the train straying off the rails.

That is why the method with usage of curve command is better. To use the method correctly, we need

to know the correct radius of the curve, of course. For my track horizontal distance, 3.8 meters, the

correct curve radius will be around 165 meters.

We will now go ahead and replace the turn commands with curve commands. The first turn will be

replaced by a curve with positive radius and the other one with a negative radius. Also, we must not

forget to put the radius 0 at the end to make sure the route will continue straight.

Using Turn command – positive and negative value And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Rail(1) FirstBrnoTrack\track\null.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.FreeObj(0)\FirstBrnoTrack\track\tr_SwitchRight.csv

.FreeObj(1)\FirstBrnoTrack\track\tr_ConnectionLeft.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.FreeObj 1;0;0;0;0,

.RailType 0;1,

.Rail 1;0;0;1,

.Rail 2;4;0;0,

.Curve 165;0,

50,

.Rail 1;-2;0;1,

.Rail 2;2;0;0,

.Curve -165;0,

75,

.FreeObj 2;1;0;0;0,

.RailType 0;0,

.Rail 1;-4;0;0,

.Rail 2;0;0;0,

.Curve 0;0,

100,

.RailEnd 2;0;0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

If you now go ahead and run the route in the simulator, you will notice that the sound of your train

passing a switch is played even though you have not defined it anywhere. This sound is used

automatically once your rail (with index 0) intersects with any other rail. For this purpose, the sound

“point.wav” in your train folder is used.

6. LIGHTING AND ANNOUNCEMENTS Some of you might have noticed that there are night versions of some routes, that the cab does changes

lightness during the ride and that there sometimes are sounds played at different places of the route.

Let’s take a look at how it’s done.

Page 19: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Lighting and announcements 19

7.1 FOG The fog can serve two purposes in the simulator. The first purpose pretty much corresponds with the

name of the command, we can actually lower the visibility in the route. This comes in handy whenever

we want to make for example a mission in the rain. The other purpose is creating darkness for the night

time rides.

Track.Fog (Start, End, Red, Green, Blue)

• Start: 100% visibility in meters

• End: 0% visibility in meters

• Red: Red color component

• Green: Green color component

• Blue: Blue color component

• Can only be placed in distance that is a multiple of 25 meters (+0).

Fog usage And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.Fog 5;100;240;240;240,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Any fog color can be achieved by the correct combination of the components. In this example, the

visibility is good for the next 5 meters, while it goes gradually down to poor visibility in 100 meters.

7.2 BRIGHTNESS Whenever a train goes through a tunnel, under a bridge or simply any darker place, the lighting

conditions in the cab of the train should adjust accordingly. This can be achieved by using the brightness

command in our route. It is important to realize that this command always works with two values – the

first one as a default point, the second one as a target point. These points are not put into one

command, they are separated. See the example below (the train is from Uchibo line).

Track.Brightness (Value)

• Value: 0-255 (darkness -> lightness)

Page 20: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Lighting and announcements 20

Brightness usage And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.Brightness 255,

28,

.Brightness 20,

40,

.Brightness 20,

53,

.Brightness 255,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

7.3 ANNOUNCEMENTS AND LOOPING SOUNDS Herein, we will be looking at some supplemental working with sounds. There are two commands that we

can use for playing a sound while riding on a train (not speaking about the train sounds themselves,

rather about “external” sound sources). The Doppler command creates a looping sound to be played in

the route. For those of you, who know basic physics, the name Doppler will not be unknown; it is an

effect causing the frequency change of a sound source that we pass by. For example if we pass a

crossing, the beats coming from it will sound as if they have a lower frequency. This is exactly what the

command does in the sim; therefore it is a good idea to use it for the crossings as well.

Track.Doppler (FileName; X; Y)

• FileName: Sound file in WAV format.

• X: Horizontal position of the sound source

• Y: Vertical position of the sound source

The Announce command, on the other hand, only plays the sound file once. It is therefore good for

simulating a radio communication to the traindriver, playing ambient sounds etc.

Track.Announce (FileName)

• FileName: Sound file in WAV format.

Page 21: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Dikes, Walls & Crack 21

Brightness usage And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.Announce Radio.wav

200,

.Doppler Crossing.wav (2;2.3)

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

8 DIKES, WALLS & CRACK

7.1 DIKES AND WALLS At the start of this chapter, I would like to point out that Dike and Wall have pretty much the same

purpose. Having used them both myself, I can safely say it does not make any difference if you exchange

one for another. So, what do they do? Their purpose is basically to copy your track with a repeating

structure (the names „wall“ and „dike“ are a good example themselves). These commands have a

separate definition for those on the left of your rail and those on the right of your rail. Also, in the

simulator these commands are repeated automatically every 25 meters once you use them, so there is a

special command for the sim to terminate their usage.

Let’s have a look at the definition in the Structure section of your route file:

With Structure

.dikeL(0) FirstBrnoTrack\scenery\HillL1.csv

.dikeR(0) FirstBrnoTrack\scenery\HillR1.csv

.wallL(0) FirstBrnoTrack\scenery\StoneWallL.csv

.wallR(0) FirstBrnoTrack\scenery\StoneWallR.csv

Please note you can define up to 256 types of Dike and the same amount of walls. As mentioned before,

they can substitute each other, so if you reach 256 types of one of these structures, feel free to use the

other one. We will now move on to see how to use these pre-defined structures in the actual route.

Track.DikeL (Index, Direction, Structure index)

Track.DikeR (Index, Direction, Structure index)

Track.WallL (Index, Direction, Structure index)

Track.WallR (Index, Direction, Structure index)

• Index: Rail index (0-15)

Page 22: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Dikes, Walls & Crack 22

• Direction: -1 for left, 0 for left & right, 1 for right

• Structure index: object index

• These commands repeat automatically every 25 meters unless terminated

• Can only be started / ended in distance that is a multiple of 25 meters (+0).

Once we use the above written commands, we also need to know how to stop the simulator applying

these structures once we don’t need them. Here’s the solution:

Track.DikeEnd (Index)

Track.WallEnd (Index)

• Index: rail index (0 ~ 15)

Dike usage And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.dikeL(0) FirstBrnoTrack\scenery\HillL1.csv

.dikeR(0) FirstBrnoTrack\scenery\HillR1.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

.Dike 0;0;0,

5,

.Stop 1

500,

.Dikeend 0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

The picture above shows displaying a very simple dike on both sides of your rail. It has already been

said that both dikes and walls basically copy the given track / rail, which is in this case the rail with

index 0. See below what I mean.

Page 23: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Dikes, Walls & Crack 23

Dike copying a rail And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.dikeL(0) FirstBrnoTrack\scenery\HillL1.csv

.dikeR(0) FirstBrnoTrack\scenery\HillR1.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

.Rail 1;7;2;0

.Dike 1;0;0,

5,

.Stop 1

50,

.Rail 1;7;1.5;0

125

.Rail 1;7;0;0

500,

.Dikeend 0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Wall usage And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.wallL(0) FirstBrnoTrack\scenery\StoneWallL.csv

.wallR(0) FirstBrnoTrack\scenery\StoneWallR.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

.Wall 0;0;0,

5,

.Stop 1

500,

.Wallend 0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Page 24: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Dikes, Walls & Crack 24

7.2 CRACK COMMAND This command serves for applying a filling in between two rails. Whenever two rails get a little bit further

from each other, there is always this smoother ballast as a filling in between them. This is what the crack

command attempts to achieve in the simulator.

The definition in the Structure namespace is very similar to the previous two commands.

With Structure

.CrackL(0) FirstBrnoTrack\track\CrackL.csv

.CrackR(0) FirstBrnoTrack\track\CrackR.csv

However, this command does not repeat automatically every 25 meters and the syntax is different:

Track.CrackL (Index1, Index2, Structure index)

Track.CrackR (Index1, Index2, Structure index)

• Index1: Rail index (0-15)

• Index2: Neighboring rail index (0-15)

• Structure index: object index

• Can only be placed in distance that is a multiple of 25 meters (+0).

Crack usage And here is how it will look like:

With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.CrackL(0) FirstBrnoTrack\track\CrackL.csv

.CrackR(0) FirstBrnoTrack\track\CrackR.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

.Rail 1;3.6;0;0,

5,

.Stop 1

25,

.Crack 0;1;0,

50,

.Rail 1;5.6;0;0,

.Crack 0;1;0,

75,

.Rail 1;7.6;0;0,

.Crack 0;1;0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

As you can see in the picture, the crack actually repeats in width between the two rails. The number of

repeats is dependent on the actual distance between the two rails. For this reason, I strongly suggest

using a seamless texture for the crack object.

Page 25: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Platforms & Traction mains 25

8 PLATFORMS & TRACTION MAINS We have gone through almost everything that you need to know to be able to build a very basic route for

the simulator. There is, however, a couple of things remaining, and those would be platforms and

traction mains.

8.1 PLATFORMS We need to provide space for our passengers to get on and off the train, so let’s see how it can be done.

One of the options would, of course, be using the FreeObject command. We have discussed that

command already, so I will now focus on the other approach. The simulator utilizes the form command

to create platforms, and the given command has its specifics. Firstly, it basically composes multiple

objects into one to create the platform, secondly, it is capable of creating both an island platform and a

lateral platform and thirdly, the command also enables you to create a roof (from a separate structure)

for the platform.

Here’s the definition for the structure namespace:

With Structure

.FormR(0) FirstBrnoTrack\Station\FormR.csv

.FormL(0) FirstBrnoTrack\Station\FormL.csv

.FormCR(0) FirstBrnoTrack\Station\FormCR.csv

.FormCL(0) FirstBrnoTrack\Station\FormCL.csv

.RoofR(0) FirstBrnoTrack\Station\RoofR.csv

.RoofL(0) FirstBrnoTrack\Station\RoofL.csv

.RoofCR(0) FirstBrnoTrack\Station\RoofCR.csv

.RoofCL(0) FirstBrnoTrack\Station\RoofCL.csv

As you can see, we need to define each of the object types separately. Here is a little catch – while for

the form command you can define indexes 0-255, for the roof you can only define indexes 1-255. This is

because index 0 for the roof is already pre-defined and if put in the command, it means you don’t want

any roof to your platform.

Lets’s see the actual command syntax in our track:

Track.Form (Index1, Index2, Roof Structure Index, Platform Structure index)

• Index1: Rail index (0-15)

• Index2: Neighboring rail index (0-15) or L for left sided platform / R for right sided platform

• Roof Structure index: Roof object index (0 for none)

• Platform Structure index: Platform object index

• Can only be placed in distance that is a multiple of 25 meters (+0).

Let me now show you a couple of examples – a left sided platform, and an island platform. Some of you

might notice that whenever building an island platform, the rails which run along the sides of the

platform are quite far away from each other. It is a good idea to use the already known command crack

to fill the gap between those rails.

Page 26: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Platforms & Traction mains 26

Left-sided platform And here is how it will look like: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.CrackL(0) FirstBrnoTrack\track\CrackL.csv

.CrackR(0) FirstBrnoTrack\track\CrackR.csv

.FormR(0) FirstBrnoTrack\Station\FormR.csv

.FormL(0) FirstBrnoTrack\Station\FormL.csv

.FormCR(0) FirstBrnoTrack\Station\FormCR.csv

.FormCL(0) FirstBrnoTrack\Station\FormCL.csv

.RoofR(0) FirstBrnoTrack\Station\RoofR.csv

.RoofL(0) FirstBrnoTrack\Station\RoofL.csv

.RoofCR(0) FirstBrnoTrack\Station\RoofCR.csv

.RoofCL(0) FirstBrnoTrack\Station\RoofCL.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.Form 0;L;1;0,

.Wall 0;-1;0,

50,

.Form 0;L;1;0,

75,

.Form 0;L;1;0,

100,

.WallEnd 0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

Left-sided platform And here is how it will look like:

[The definitions are the same as in previous example,

see above]

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

.Rail 1;11.4;0;0,

.Crack 0;1;0,

5,

.Stop 1

25,

.Form 0;L;1;0,

.Crack 0;1;0,

50,

.Form 0;L;1;0,

.Crack 0;1;0,

75,

.Form 0;L;1;0,

.Crack 0;1;0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Page 27: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Platforms & Traction mains 27

8.2 TRACTION MAINS Probably the last thing that needs to be discussed is the electrification of your route. For that, we will

obviously need some traction mains (both the holding poles and wires). While this thing can also be

taken care of using the FreeObject command, we will take a look a t a different option here.

The simulator offers a special command for electrification of your route – its name is Pole. This command

has certain limitations, though – the traction mains can only be placed each 25 or 50 meters. Also, when

using the pole command, you will need your rail object to also contain the power wires, which will result

into power wire breaks every 25 meters (on a curved track).

The pole definition involves the number of tracks covered by the pole – that means you can define a pole

for one rail, two rails, etc. The maximum value is 3, but it will cover 4 rails as the starting index for 1 rail is

0. Here’s the example definition for the structure namespace:

With Structure

.Pole(Tracks; StructureIndex)

The actual command syntax in our track:

Track.Pole (Index, Type, Location, Distance, Structure index)

• Index: Rail index (0-15)

• Type: Pole type (0 for 1 rail, 1 for 2 rails, 2 for 3 rails, 3 for 4 rails)

• Location: Valid for one rail only / -1 for left, 0 for both sides, 1 for right

• Distance: Route distance between two poles (25 or 50 meters)

• StructureIndex: (Object index)

• Can only be placed in distance that is a multiple of 25 meters (+0).

Using pole on a single track: And here is how it will look like:

With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.pole(0;0)

FirstBrnoTrack\track\TractionMains\Pole_one_railS.csv

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

5,

.Stop 1

25,

.Pole 0;0; -1;25,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Page 28: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Platforms & Traction mains 28

Using pole on multiple tracks: With Train

.Folder 163-133-7v4

With Structure

.Rail(0) FirstBrnoTrack\track\tr_straight.csv

.Ground(0)\FirstBrnoTrack\Scenery\GrassRise.csv

.pole(0;0) FirstBrnoTrack\track\TractionMains\Pole_one_railS.csv

.pole(0;0) FirstBrnoTrack\track\TractionMains\Pole_one_railS.csv

.Pole(1;0) FirstBrnoTrack\track\TractionMains\Pole_2_rails.animated

.Pole(2;0) FirstBrnoTrack\track\TractionMains\Pole_3_rails.animated

.Pole(3;0) FirstBrnoTrack\track\TractionMains\Pole_4_rails.animated

With Texture

.Background(0) FirstBrnoTrack\Bg1.jpg

With Track

0,

.Sta Station A;07.0040;07.0100; ;-1;0; ; ; ;50; ; ; ,

.Height 0.4,

.Rail 1;3.8;0;0,

5,

.Stop 1

25,

.Pole 0;1;0;25,

100,

.PoleEnd 0,

1000,

.Sta Station B;07.0245;T; ;-1;0; ; ; ;50; ; ; ,

1005,

.Stop 1;0;0,

Page 29: Building a route for BVEbrnobve.eu/Guides/Building a route for BVE.pdf · Basics to route building in BVE | 5. Building the rails 5 image and at least two stops with a defined place

Basics to route building in BVE | Additional information 29

9 ADDITIONAL INFORMATION The definitions, codes, pictures in this tutorial have informative character and are only an illustration to the

commands used. If you create and define your own objects, those will obviously be looking different when

you put them into a route file. The pictures used herein only show the principle of how the syntax works.

If you have any questions or you feel this tutorial should be enriched with some more information, please

use www.bveworldwide.unlimitedboard.com as a point of contact.

10 ACNOWLEDGEMENT This tutorial is a translation of an original text written in Czech by Gyzma.