Difference between pages "Template:Ombox" and "Network Specs/IntersectionSolutions RUL"

From SC4D Encyclopaedia
(Difference between pages)
Jump to navigation Jump to search
sc4e>Freedo50
 
sc4e>CasperVg
m (addcat)
 
Line 1: Line 1:
<includeonly>{{#ifeq:{{{small|}}}|yes
+
{{NetSpecsNav}}
| {{ombox/core
+
{{Infobox TGI
  | small = yes
+
| name        = RUL Overrides
  | type  = {{{type|}}}
+
| format      = [[RUL File]]
  | image = {{#if:{{{smallimage|}}}| {{{smallimage}}} | {{{image|}}} }}
+
| type        = 0x0A5BCF4B
  | imageright = {{#if:{{{smallimageright|}}} | {{{smallimageright}}} | {{{imageright|}}} }}
+
| group      = 0xAA5BCF57
  | style = {{{style|}}}
+
| instance    = 0x10000001
  | textstyle = {{{textstyle|}}}
+
| comments    = {{also|RUL_0x10000001}}}}
  | text  = {{#if:{{{smalltext|}}}| {{{smalltext}}} | {{{text}}} }}
+
This is the file which dictates what happens when one network type is drawn over a different network (note the use of the word “different”; this is important). The network building engine calculates how network piece(s) are laid, as if no other networks are present. Then it looks to see if there are other network tiles of a different network in the way. If there are, it searches for a solution in this file and thus the intersecting piece(s)’ Rules are applied. If no Rules are found for the two different networks to intersect though, it results in an impossible network draw (red line). Format is as follows:
  }}
+
   
| {{ombox/core
 
  | type  = {{{type|}}}
 
  | image = {{{image|}}}
 
  | imageright = {{{imageright|}}}
 
  | style = {{{style|}}}
 
  | textstyle = {{{textstyle|}}}
 
  | text = {{{text}}}
 
  }}
 
}}</includeonly><noinclude>
 
  
{{pp-template}}
+
==Maxis' comments==
 +
<font color="green" face="Courier New">
 +
<nowiki>;</nowiki> format:<br>
 +
<nowiki>;</nowiki> name=roadMajorTypesFlag,streetMajorTypesFlag,textureId,rotation,flip<br>
 +
<nowiki>;</nowiki><br>
 +
<nowiki>;</nowiki> name is really not used and is just for our reference. <br>
 +
<nowiki>;</nowiki> the flag byte order is SENW (I think?)<br>
 +
<nowiki>;</nowiki><br>
 +
</font>
  
This is a template which defines a syle for Other message boxes, i.e. pages using the {{[[Templae:Mbox|Mbox}} tag which aren't article, category, talk, or image pages.
+
==Translation==
 +
The file is separated into sections by titles in [brackets]. The title has the following format:
 +
 +
<font color="green" face="Courier New">['''''Network1Network2'''''IntersectionSolutions]</font>
 +
 +
Network1 and Network2 are the two networks which are being overlapped. Valid network names are: DirtRoad, Street, Road, OneWayRoad, Avenue, GroundHighway, Highway, Rail, LightRail [aka EI-train], & MonoRail [& some others]. There must be no spaces or punctuation of any kind in the title.
  
<pre>{{ombox
+
*A note about Loading order; the IntersectionSolutions header for each intersection section needs to have its network names in a proper order, otherwise any rules created under that section may not work at all. For example; [OneWayRoadGroundHighwayIntersectionSolutions] header is valid, but the [GroundHighwayOneWayRoadIntersectionSolutions] header is not. So if a set of rules doesn’t seem to be working (& no other rules exist in the section), then this may be something to look closer at.
| type  = speedy / delete / content / style / notice / move / protection
+
 
| image = none / [[Image:Some image.svg|40px]]
+
Within each section, there are lines which describe the tile to place in the case where tiles of network1 and network2 are placed on top of each other, with the defined RUL edge values. The format of these lines is as follows:
| imageright = [[Image:Some image.svg|40px]]
+
 
| style = CSS values
+
<font color="green" face="Courier New">
| textstyle = CSS values
+
<nowiki>;</nowiki>straight road, diagonal rail<br>
| text  = The message body text.  
+
rot0flip0=0x02000200,0x00030100,0x03010200,0,0</font>
| small = {{{small|}}} / yes
+
 
| smallimage = none / [[Image:Some image.svg|30px]]
+
 
| smallimageright = none / [[Image:Some image.svg|30px]]
+
==Format==
| smalltext  = A shorter message body text.
+
<font color="green" face="Courier New">name=<font color="black">0x</font><font color="blue">N1s</font><font color="orange">N1e</font>N1n<font color="purple">N1e</font>,<font color="black">0x</font><font color="blue">N2s</font><font color="orange">N2e</font>N2n<font color="purple">N2e</font>,texture/path/ExemplarID,Rotation,Flip</font>
}}
+
 
</pre>
+
name = doesn't matter, generally anything is valid.<br>
==Example==
+
N1=Network1<br>
{{ombox|text= Lorem ipsum dolor si amet}}
+
N2=Network2<br>
</noinclude>
+
s,e,n,w = South, East, North, West<br>
 +
Each S/E/N/W holds the RUL edge values for each network, which are:<br>
 +
00 - no connection<br>
 +
01 - left at 45degree angle<br>
 +
02 - straight<br>
 +
03 - right at 45degree angle<br>
 +
04 – median
 +
Texture/PathID/ExemplarID = the InstanceID of the resulting transit tile put in this spot.
 +
Where an Exemplar file is referenced, this Exemplar file subsequently references an S3D (or Model) file.<br>
 +
'''Rotation = the rotation of the new transit tile 0-3'''<br>
 +
'''Flip = the flip of the new transit tile 0-1'''<br>
 +
 
 +
*Note; Some in-game network intersections rely on having various IntersectionSolution rules in place in order for them to work. Some intersections/junctions may need two different sets of intersectionsolution rules, that effectively work together for an intersection to work. Some intersections/junctions rely on the RuleOverrides rul in order to work effectively. Some examples of this can be seen in these files themselves.
 +
 
 +
==Allowed Overrides Section==
 +
<font color="green" face="Courier New">[AllowedOverrides]<br>
 +
1=Road,Street<br>
 +
2=Avenue,Road<br>
 +
3=Avenue,Street<br>
 +
4=Avenue,GroundHighway<br>
 +
5=Highway,GroundHighway<br>
 +
6=OneWayRoad,Road<br></font>
 +
 
 +
This controls what networks may be drawn on top of other networks. Unfortunately, the rules here in this last section are also read in reverse by the exe. And because of the hierarchy that exists with the networks, a lower hierarchical network can’t replace a higher hierarchical network when actively dragging one network over another (in a parallel overlapping fashion). So having X=Street,Road won’t force Street to replace Road as the Street tool is dragged over a stretch of road. Rather, X=Street,Road will effectively be read as X=Road,Street at run-time & thus allow Road to replace Street if the Road tool is dragged over a section of Street.
 +
{{NetSpecsNav}}
 +
 
 +
[[Category:Transit Modding]]

Revision as of 08:54, 15 July 2009

TGI Info
Name RUL Overrides
Format RUL File
Type

Group

Instance

0x0A5BCF4B

0xAA5BCF57

0x10000001

Comments
See also: RUL_0x10000001

This is the file which dictates what happens when one network type is drawn over a different network (note the use of the word “different”; this is important). The network building engine calculates how network piece(s) are laid, as if no other networks are present. Then it looks to see if there are other network tiles of a different network in the way. If there are, it searches for a solution in this file and thus the intersecting piece(s)’ Rules are applied. If no Rules are found for the two different networks to intersect though, it results in an impossible network draw (red line). Format is as follows:


Maxis' comments

; format:
; name=roadMajorTypesFlag,streetMajorTypesFlag,textureId,rotation,flip
;
; name is really not used and is just for our reference.
; the flag byte order is SENW (I think?)
;

Translation

The file is separated into sections by titles in [brackets]. The title has the following format:

[Network1Network2IntersectionSolutions]

Network1 and Network2 are the two networks which are being overlapped. Valid network names are: DirtRoad, Street, Road, OneWayRoad, Avenue, GroundHighway, Highway, Rail, LightRail [aka EI-train], & MonoRail [& some others]. There must be no spaces or punctuation of any kind in the title.

  • A note about Loading order; the IntersectionSolutions header for each intersection section needs to have its network names in a proper order, otherwise any rules created under that section may not work at all. For example; [OneWayRoadGroundHighwayIntersectionSolutions] header is valid, but the [GroundHighwayOneWayRoadIntersectionSolutions] header is not. So if a set of rules doesn’t seem to be working (& no other rules exist in the section), then this may be something to look closer at.

Within each section, there are lines which describe the tile to place in the case where tiles of network1 and network2 are placed on top of each other, with the defined RUL edge values. The format of these lines is as follows:

;straight road, diagonal rail
rot0flip0=0x02000200,0x00030100,0x03010200,0,0


Format

name=0xN1sN1eN1nN1e,0xN2sN2eN2nN2e,texture/path/ExemplarID,Rotation,Flip

name = doesn't matter, generally anything is valid.
N1=Network1
N2=Network2
s,e,n,w = South, East, North, West
Each S/E/N/W holds the RUL edge values for each network, which are:
00 - no connection
01 - left at 45degree angle
02 - straight
03 - right at 45degree angle
04 – median Texture/PathID/ExemplarID = the InstanceID of the resulting transit tile put in this spot. Where an Exemplar file is referenced, this Exemplar file subsequently references an S3D (or Model) file.
Rotation = the rotation of the new transit tile 0-3
Flip = the flip of the new transit tile 0-1

  • Note; Some in-game network intersections rely on having various IntersectionSolution rules in place in order for them to work. Some intersections/junctions may need two different sets of intersectionsolution rules, that effectively work together for an intersection to work. Some intersections/junctions rely on the RuleOverrides rul in order to work effectively. Some examples of this can be seen in these files themselves.

Allowed Overrides Section

[AllowedOverrides]
1=Road,Street
2=Avenue,Road
3=Avenue,Street
4=Avenue,GroundHighway
5=Highway,GroundHighway
6=OneWayRoad,Road

This controls what networks may be drawn on top of other networks. Unfortunately, the rules here in this last section are also read in reverse by the exe. And because of the hierarchy that exists with the networks, a lower hierarchical network can’t replace a higher hierarchical network when actively dragging one network over another (in a parallel overlapping fashion). So having X=Street,Road won’t force Street to replace Road as the Street tool is dragged over a stretch of road. Rather, X=Street,Road will effectively be read as X=Road,Street at run-time & thus allow Road to replace Street if the Road tool is dragged over a section of Street.