Difference between pages "RUL File" and "Network Specs/INI Network & Bridges"

From SC4D Encyclopaedia
(Difference between pages)
Jump to navigation Jump to search
sc4e>CasperVg
m (cat)
 
sc4e>CasperVg
m (addcat)
 
Line 1: Line 1:
'''RUL Files''' are internal game files which control the placement of [[Transit Network]] items in-game.  There are numerous RUL Files used by the game, each of which has its own particular function. There are three different types of RUL Files: [[Network-Specific|Network-Specific RUL Files]], Multi-Network, and [[Bridge RULs]].  In addition, the [[Network INI]] file effectively functions like a RUL File.
+
{{NetSpecsNav}}
 +
This file covers items related to the INI Network file & Bridge RUL files. Not all aspects of these files will be covered though.<br>
 +
INI Network file – 0x00000000/8A5971C5/8A5993B9<br>
 +
Bridge RULs – 0x0A5BCF4B/AA5BCF57/00001000 to 0x0A5BCF4B/AA5BCF57/000010##<br>
 +
* Note: The game originally only came with 5 Bridge RUL files. Other Bridge RULs other than the original 5 have been known to be valid though, hence where there is ‘##’ at the end.<br>
  
The [[Network Specs|Network Specs Folder]] written by many of the people who discovered the file formats is helpful for learning Transit [[Modding]] even if it is a few years old and a few things need to be updated
+
==Remapping==
 +
===Paths===
 +
<font face="Courier New">
 +
[UK path remapping]<br>
 +
<font color="green">
 +
<nowiki>;</nowiki> Format:<br>
 +
<nowiki>;</nowiki><br>
 +
<nowiki>;</nowiki>    <anything> = <match-id>, <match-mask>, <new-id>, <add-mask><br>
 +
</font>
 +
1      = 0x09201000,0xFFFFF000,0x09209000,0x00000FFF<br>
 +
<br>
 +
1      = 0x09209000,0xFFFFF000,0x09201000,0x00000FFF<br>
 +
</font>
  
The function of the RUL File is defined by its [[IID]].  It is not possible to add new RUL Files, though it is possible to define new Bridge RULs for networks that do not already have them.
 
  
== Network-Specific RUL Files ==
+
This section is mostly used in conjunction with the IntersectionOrdering RUL file. Basically, this section is used to replace particular path file or sets of path files at run-time for any given in-game tiles. Each line contains 2 main parts.<br>
''Main article'': [[Network Specific RUL]]
+
<font face="Courier New">
 +
1      = 0x09201000,0xFFFFF000,0x09209000,0x00000FFF<br>
 +
</font>
 +
This says; any Path files with IDs of 0x09201### be replaced with the Path files that exist in 0x09209###, for UK (or left hand side) driving orientated games. The “F”s denote masking of an ID. These, as too the IIDs, can be changed &/or shifted over, but in practise are not. The following would also be a valid & work (assuming the Path files are in place for these)<br><font face="Courier New">
 +
1    = 0x09210000,0xFFFF0000,0x0929000,0x0000FFFF<br>
 +
</font>
 +
===Textures===
 +
<font face="Courier New">[Texture remapping]<br></font>
 +
This particular section controls the texture remapping of an item when the network is being drawn. Or in other words; the '''Preview''' of an ordinary in-game tile of the network before you release the mouse button. This does not cover Bridges & interchange items.<br>
  
Each in-game network has two Network-Specific RUL Files, one Main RUL which defines the basic placement of the network, and one Supplemental RUL, which defines same-network overrides.  There are 18 total Network Specific RULs.
+
==Bridges==
 +
===Exemplar files===
 +
Bridges are a little different from other network items in the game. Unlike normal network aspects, Bridges are first called from the INI Network file.<br>
 +
<font color="green" face="Courier New">
 +
[RoadBridgeExemplars]<br>
 +
; 0x2821ED93<br>
 +
1 = 0x6534284a, 0xa82ca30f, 0x00000001, level road bridge<br>
 +
2 = 0x6534284a, 0xa82ca30f, 0x00000002, raised road bridge<br>
 +
3 = 0x6534284a, 0xa82ca30f, 0x00000003, undertruss road bridge<br>
 +
4 = 0x6534284a, 0xa82ca30f, 0x00000005, wooden covered road bridge<br>
 +
5 = 0x6534284a, 0xa82ca30f, 0x00000006, medium suspension road bridge<br>
 +
6 = 0x6534284a, 0xa82ca30f, 0x00000007, stone arch road bridge<br>
 +
7 = 0x6534284a, 0xa82ca30f, 0x00000008, small steel arch road bridge<br>
 +
8 = 0x6534284a, 0xa82ca30f, 0x00000009, cantilever truss road bridge<br>
 +
9 = 0x6534284a, 0xa82ca30f, 0x0000000a, overdeck truss road bridge<br>
 +
</font>
 +
This section here is the starting point for bridges. Each of the different networks that have bridges contains entries similar to this.<br>
 +
Format;<br>
 +
<font color="green" face="Courier New">[RoadBridgeExemplars]</font><br>
 +
This is the header for this section, & the network names are engine specific.<br>
 +
<font color="green" face="Courier New">1 = 0x6534284a, 0xa82ca30f, 0x00000001, level road
 +
bridge</font><br>
 +
Number = TypeID, GroupID, InstanceID, Name<br>
 +
<br>
 +
Number – These should be unique, as they can & are used as a point of reference in the Bridge RUL files.<br>
 +
Name - insignificant. Name can be anything.<br>
 +
Type/Group/InstanceID; this is an actual Bridge Parent-Exemplar file that this is pointing to. This referenced Bridge Parent-Exemplar file then follows on to reference Child-Exemplar files. These Child-Exemplar files not only fall under the GroupID specific format, but also a specific InstanceID format as well (which is believed to subsequently be controlled by the INI file itself, namely the section under Shadow Remappings).<br>
 +
If you have a look at the <font color="green">Level_Road_Bridge</font> Exemplar file (find the Exemplar file using the above referenced TGI ID, level road bridge), you’ll notice it contains many properties, among them the following properties;<br>
 +
0x482CB443<br>
 +
0x482CB445<br>
 +
0x482CB449<br>
 +
(not all of these three will be in every Bridge Exemplar)<br>
  
== Multi-Network RUL Files ==
 
There are three Multi-Network RUL Files, known by their IIDs: [[RUL 0x10000000]], [[RUL 0x10000001]] and [[RUL 0x10000002]].  These all handle situations that can handle multiple networks.  RUL 0x10000000 is a particularly special case, since it deals exclusively with [[Puzzle Pieces]], ploppable network pieces, as opposed to Draggable Network items, the only such RUL to do so.
 
  
== Bridge RULs ==
+
These properties contain the pointers, or InstanceIDs, of the Child-Exemplar files mentioned above. Essentially, the INI Network file & the referenced Bridge Parent-Exemplar file, controls the “ability” to actually build a bridge (Hint: A bridge can be built, carry commuters, & still not be visible. This would indicate a GroupID &/or InstanceID problem with the files involved, &/or possibly a S3D file problem). The Bridge RUL files are only supplementary after this; most of the bridges work this way.
''Main article'': [[Bridge RUL]]
 
  
Bridge RULs allow for more control over custom bridges.
 
  
== Network INI ==
+
===RUL files===
''Main article'': [[Network INI]]
+
Bridge RULs have a format all to themselves, & are very different from all the other RULs. The Bridge RULs have their format within them.
 +
{{NetSpecsNav}}
  
The Network INI file, while technically not a RUL file, combines many functions of the various RUL files.  It also controls bridge shadows, Left-Hand Drive path substitution, Powerlines, and various Bugfixes.
+
[[Category:Transit Modding]]
 
 
{{expand}}
 
[[category:File_Formats/SC4|RUL]]
 

Revision as of 08:54, 15 July 2009

This file covers items related to the INI Network file & Bridge RUL files. Not all aspects of these files will be covered though.
INI Network file – 0x00000000/8A5971C5/8A5993B9
Bridge RULs – 0x0A5BCF4B/AA5BCF57/00001000 to 0x0A5BCF4B/AA5BCF57/000010##

  • Note: The game originally only came with 5 Bridge RUL files. Other Bridge RULs other than the original 5 have been known to be valid though, hence where there is ‘##’ at the end.

Remapping

Paths

[UK path remapping]
; Format:
;
; <anything> = <match-id>, <match-mask>, <new-id>, <add-mask>
1 = 0x09201000,0xFFFFF000,0x09209000,0x00000FFF

1 = 0x09209000,0xFFFFF000,0x09201000,0x00000FFF


This section is mostly used in conjunction with the IntersectionOrdering RUL file. Basically, this section is used to replace particular path file or sets of path files at run-time for any given in-game tiles. Each line contains 2 main parts.
1 = 0x09201000,0xFFFFF000,0x09209000,0x00000FFF
This says; any Path files with IDs of 0x09201### be replaced with the Path files that exist in 0x09209###, for UK (or left hand side) driving orientated games. The “F”s denote masking of an ID. These, as too the IIDs, can be changed &/or shifted over, but in practise are not. The following would also be a valid & work (assuming the Path files are in place for these)
1 = 0x09210000,0xFFFF0000,0x0929000,0x0000FFFF

Textures

[Texture remapping]
This particular section controls the texture remapping of an item when the network is being drawn. Or in other words; the Preview of an ordinary in-game tile of the network before you release the mouse button. This does not cover Bridges & interchange items.

Bridges

Exemplar files

Bridges are a little different from other network items in the game. Unlike normal network aspects, Bridges are first called from the INI Network file.
[RoadBridgeExemplars]

0x2821ED93

1 = 0x6534284a, 0xa82ca30f, 0x00000001, level road bridge
2 = 0x6534284a, 0xa82ca30f, 0x00000002, raised road bridge
3 = 0x6534284a, 0xa82ca30f, 0x00000003, undertruss road bridge
4 = 0x6534284a, 0xa82ca30f, 0x00000005, wooden covered road bridge
5 = 0x6534284a, 0xa82ca30f, 0x00000006, medium suspension road bridge
6 = 0x6534284a, 0xa82ca30f, 0x00000007, stone arch road bridge
7 = 0x6534284a, 0xa82ca30f, 0x00000008, small steel arch road bridge
8 = 0x6534284a, 0xa82ca30f, 0x00000009, cantilever truss road bridge
9 = 0x6534284a, 0xa82ca30f, 0x0000000a, overdeck truss road bridge
This section here is the starting point for bridges. Each of the different networks that have bridges contains entries similar to this.
Format;
[RoadBridgeExemplars]
This is the header for this section, & the network names are engine specific.
1 = 0x6534284a, 0xa82ca30f, 0x00000001, level road bridge
Number = TypeID, GroupID, InstanceID, Name

Number – These should be unique, as they can & are used as a point of reference in the Bridge RUL files.
Name - insignificant. Name can be anything.
Type/Group/InstanceID; this is an actual Bridge Parent-Exemplar file that this is pointing to. This referenced Bridge Parent-Exemplar file then follows on to reference Child-Exemplar files. These Child-Exemplar files not only fall under the GroupID specific format, but also a specific InstanceID format as well (which is believed to subsequently be controlled by the INI file itself, namely the section under Shadow Remappings).
If you have a look at the Level_Road_Bridge Exemplar file (find the Exemplar file using the above referenced TGI ID, level road bridge), you’ll notice it contains many properties, among them the following properties;
0x482CB443
0x482CB445
0x482CB449
(not all of these three will be in every Bridge Exemplar)


These properties contain the pointers, or InstanceIDs, of the Child-Exemplar files mentioned above. Essentially, the INI Network file & the referenced Bridge Parent-Exemplar file, controls the “ability” to actually build a bridge (Hint: A bridge can be built, carry commuters, & still not be visible. This would indicate a GroupID &/or InstanceID problem with the files involved, &/or possibly a S3D file problem). The Bridge RUL files are only supplementary after this; most of the bridges work this way.


RUL files

Bridge RULs have a format all to themselves, & are very different from all the other RULs. The Bridge RULs have their format within them.