How to Use Session Editor

From TrainzOnline
(Difference between revisions)
Jump to: navigation, search
(Added links to examples of using the session editor)
(added section on copying between sessions)
Line 147: Line 147:
 
<tr valign="top">
 
<tr valign="top">
 
<td>[[file:Stop.PNG|link=]]</td>
 
<td>[[file:Stop.PNG|link=]]</td>
<td>The <span style="background-color: black; color: white; font-weight: 700;">&nbsp;Cut&nbsp;</span> and <span style="background-color: black; color: white; font-weight: 700;">&nbsp;Copy&nbsp;</span> operations will '''NOT''' copy ALL the settings in some rules, for example the '''Navigation Display Rule'''. It is a good idea to check the settings of each rule that you paste into the Session Editor</td>
+
<td>The <span style="background-color: black; color: white; font-weight: 700;">&nbsp;Cut&nbsp;</span>, <span style="background-color: black; color: white; font-weight: 700;">&nbsp;Copy&nbsp;</span> and <span style="background-color: black; color: white; font-weight: 700;">&nbsp;Paste&nbsp;</span> operations will '''NOT''' correctly copy ALL the settings in some rules, for example the '''Navigation Display Rule'''. It is a good idea to check the settings of each rule that you paste into the Session Editor</td>
 
</tr>
 
</tr>
 
</table>
 
</table>
Line 157: Line 157:
 
<tr valign="top">
 
<tr valign="top">
 
<td align="right">[[file:BackToTop.png|link=#top|alt=Top|Top]]</td>
 
<td align="right">[[file:BackToTop.png|link=#top|alt=Top|Top]]</td>
 +
</tr>
 +
</table>
 +
<br>
 +
='''Copying Rules Between Sessions'''=
 +
<table cellpadding="4" bgcolor=#c1e7e7>
 +
<tr valign="top">
 +
<td>[[file:DotPoint.JPG|link=]]</td>
 +
<td>'''Rules can be copied between Sessions'''</td>
 
</tr>
 
</tr>
 
</table>
 
</table>
  
 +
The '''Copy''' and '''Paste''' commands can be used to copy rules between different sessions. This can save you having to reenter complex sets of data, such as driver commands, in a new session.
 +
<table cellpadding="4" bgcolor=#ffffff>
 +
<tr>
 +
<td colspan="2">
 +
----</td>
 +
</tr>
 +
<tr valign="top">
 +
<td>[[file:Steps.PNG|link=]]</td>
 +
<td><span style="font-size: 17px; font-weight: 700;">Steps:'''</span><br>
 +
#in the Session Editor right mouse click on the Rule to be copied (more than one Rule can be highlighted)
 +
#select '''Copy''' from the popup menu
 +
#exit the session
 +
#load the second session (where the Rules are to be copied to) into Surveyor and open the Session Editor
 +
#right mouse click after the last rule entry and select '''Paste'''</td>
 +
</tr>
 +
<tr>
 +
<td colspan="2">
 +
----</td>
 +
</tr>
 +
</table>
 +
<br>
 +
If, for example, the '''Driver Setup Rule''' was copied by this method from one Session to another, then all the drivers with their assigned locos and driver commands will now be duplicated in the second Session.
 +
 +
If the second Session already has a Driver Setup Rule then there will now be two copies of that rule, the original and the imported copy. This will only be a problem if the imported copy '''uses the same locos or drivers''' as the original Rule. If this is the case then you will need to edit one of the Driver Setup Rules to remove or reassign the duplicates.
 +
 +
<table cellpadding="4" bgcolor=#fcbcbc>
 +
<tr valign="top">
 +
<td colspan=2><span style="font-size: 17px; font-weight: 700;">Warning:</span></td>
 +
</tr>
 +
<tr valign="top">
 +
<td>[[file:Stop.PNG|link=]]</td>
 +
<td>The '''Cut''', '''Copy''' and '''Paste''' operations will '''NOT''' correctly copy ALL the settings in some rules, for example the '''Navigation Display Rule'''. It is a good idea to check the settings of each rule that you paste into the Session Editor</td>
 +
</tr>
 +
</table>
 +
<br>
 
='''Examples of Using the Session Editor'''=
 
='''Examples of Using the Session Editor'''=
  
Line 212: Line 255:
 
</tr>
 
</tr>
 
</table>
 
</table>
 +
----
 +
This page was created by Trainz user '''<span class="plainlinks">[http://online.ts2009.com/mediaWiki/index.php/User:Pware pware]</span>''' in September 2019 and was last updated as shown below.
 +
----
 
[[Category:How-to guides]][[Category:Rules]]
 
[[Category:How-to guides]][[Category:Rules]]

Revision as of 08:57, 18 January 2020

The information in this Wiki Page applies to TANE, TRS19 and Trainz Plus.

Contents


What is the Session Editor

DotPoint.JPG The Session Editor allows you to add, delete and edit the Rules in a Session
DotPoint.JPG The Rules control the operation of the Session


NotePad.PNG Notes:

The Rules added and edited by the Session Editor control:-

  • behaviour of drivers (and their trains)
  • weather conditions
  • time of day
  • signals and switches
  • display of information and instructions to the player
  • train timetables
  • responses to events (time, triggers, load levels, other trains, etc)
  • decisions on what happens next

to name just a few.


In TANE and TRS19 the Session Editor is found in the Surveyor Main Menu. In TRS19 SP1 and Trainz Plus it has been moved to the Surveyor Edit Menu. In either case select Edit Session from the menu.

SessionEditMenuTANE.png SessionEditMenuSP1.png

When loaded, the Session Editor will show all the Rules that have been added to the Session. If you have just opened the Editor on a Route without a Session then it will show a very basic set of Rules. The Editor will allow you to add additional Rules, and delete or edit those shown. Links to extensive lists of Rules that are built into Trainz or available on the DLS can be found at the end of this document.

SessionEditRulesSP1.png
NotePad.PNG Notes:
  • the Name of the Session is the Username tag entry in the config.txt file
  • the Session Description of the Session is the Description tag entry in the config.txt file

Both entries can be edited in the Session Editor and the config.txt file for the Session asset will be updated when you save the Session and exit Surveyor.


DotPoint.JPG The order of the Rules in the Editor list is usually not important. All the rules shown will be executed simultaneously although some rules will take longer to complete than others


PencilTips.PNG If the order in which some of the Rules are executed is important, then group them together in a Ordered List Rule (examples are shown in the image) in the order you want them to be executed. Information on using Ordered Lists can be found at WikiLink.PNG Using Ordered Lists


Rules can be grouped together for convenience (e.g. all the Rules that set signals at the start of the Session) or because they depend on a particular event (e.g. a time, a train arriving at a set point, a wagon being loaded, etc). These form Nested Rules and are indicated by arrow heads as shown in the image. Click on an arrow head to open up its nested list of child Rules.

SessionEditOpenLayerSP1.png

Each of the Rules that have been nested under the Ordered List Rule in the image above have been indented one level to the right.

LinkWiki.PNG

More information on the various types of List Rules and how to create Nested Rules can be found on the Trainz Wiki Page at:-


Top

The "Button Bar"

At the bottom of the Session Editor is the "button Bar".

SessionEditButtonsSP1.png
  • the  Add  button will insert a new Rule below the selected (highlighted) Rule or at the end of the list if no Rule has been selected

To use the other buttons, select a Rule first by clicking on it

  • the  Edit  button will open the selected (highlighted) Rule for editing
  • the  Delete  button will delete the selected Rule
  • the  Indent/Outdent  buttons will move the selected Rule right or left
  • the  Up/Down  buttons will move the selected Rule Up or Down


Tick.PNG Click to Accept your edits and close the Session Editor    Cross.PNG Click to Cancel your edits and close the Session Editor


DotPoint.JPG The above operations, and more, can also be found by right mouse clicking on a Rule to open up a menu
SessionEditPopupMenu.png
  •  Edit rule  is the same as the  Edit  button
  •  Insert above  is the same as the  Add  button but inserts the new Rule above the selected Rule
  •  Insert below  is the same as the  Add  button (inserts the new rule below the selected Rule)
  •  Cut  Copy  Paste  will move/copy the rule (and its nested child rules if it has any) between the Session Editor and the Clipboard
  •  Delete  is the same as the  Delete  button
  •  Indent  is the same as the  Indent  button
  •  Outdent  is the same as the  Outdent  button
  •  Move up  is the same as the  Up  button
  •  Move down  is the same as the  Down  button


Warning:
Stop.PNG The  Cut ,  Copy  and  Paste  operations will NOT correctly copy ALL the settings in some rules, for example the Navigation Display Rule. It is a good idea to check the settings of each rule that you paste into the Session Editor


Top


Copying Rules Between Sessions

DotPoint.JPG Rules can be copied between Sessions

The Copy and Paste commands can be used to copy rules between different sessions. This can save you having to reenter complex sets of data, such as driver commands, in a new session.


Steps.PNG Steps:
  1. in the Session Editor right mouse click on the Rule to be copied (more than one Rule can be highlighted)
  2. select Copy from the popup menu
  3. exit the session
  4. load the second session (where the Rules are to be copied to) into Surveyor and open the Session Editor
  5. right mouse click after the last rule entry and select Paste


If, for example, the Driver Setup Rule was copied by this method from one Session to another, then all the drivers with their assigned locos and driver commands will now be duplicated in the second Session.

If the second Session already has a Driver Setup Rule then there will now be two copies of that rule, the original and the imported copy. This will only be a problem if the imported copy uses the same locos or drivers as the original Rule. If this is the case then you will need to edit one of the Driver Setup Rules to remove or reassign the duplicates.

Warning:
Stop.PNG The Cut, Copy and Paste operations will NOT correctly copy ALL the settings in some rules, for example the Navigation Display Rule. It is a good idea to check the settings of each rule that you paste into the Session Editor


Examples of Using the Session Editor

Wiki pages that show examples of using the Session Editor to solve particular problems or to carry out particular tasks can be found at the following links:-


Trainz (TRS19) "Plus"

The Plus version of TRS19 (also known as Trainz Plus) has the ability to edit saved Driver Games in Surveyor and allowing the edited game to be continued without having to restart the entire Session. This includes using the Session Editor on an active Driver Game Session where some of the Rules may have already been completed and others partially completed. To allow for these possibilities, additional features have been added to the Session Editor in the Plus version.

This version is currently undergoing beta testing.

Related Links

LinkWiki.PNG


Top


Trainz Wiki

TrainzWiki.png

More Tutorials and Guides to Using Trainz


This page was created by Trainz user pware in September 2019 and was last updated as shown below.


Personal tools