ModEnc is currently in Maintenance Mode: Changes could occur at any given moment, without advance warning.

Tubes

From ModEnc
Revision as of 10:11, 10 April 2008 by DCoder (talk | contribs) (Created)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
This page should correctly be named "[Tubes]"; it is wrong due to technical restrictions.



Tubes
Sidebar/Default

This section lists all the Tunnels in this map. Note that internally each Tunnel listed here is one cell wide and one way, meaning a typical three-cell wide two-way tunnel construct requires six entries in this section, three running one way and three going backwards. While you can give each one a different path, it is not recommended since it breaks the unit pathfinding.

(You need Terrain Expansion to make use of tunnels in YR.)


Section

TD/CO

Tunnels don't exist.

RA/CS/AM

Tunnels don't exist.

TS/FS/RA2/YR

The [Tubes] section takes the following format:

[Tubes]
Index=ENTER_X,ENTER_Y,FACING,EXIT_X,EXIT_Y,DIRECTIONS
Meanings of each string
String Meaning
Index This is an index into the list, not parsed, so any string without equals-signs will do. Note: The game was not designed to support more than 127 entries in this list (which is 127/6 = 21 typical tunnel constructs). Exceeding that limit will cause problems.
ENTER_X The X coordinate of the entrance cell. Each tunnel should have a different entrance cell.
ENTER_T The Y coordinate of the entrance cell.
FACING The numeric value of the facing the unit should assume before entering this tunnel. 0 - 7, with 0 standing for game North (NorthEast of the screen) and rotating clockwise.
EXIT_X The X coordinate of the exit cell.
EXIT_Y The Y coordinate of the exit cell.
DIRECTIONS A comma-separated list of directions the unit should follow as it moves through the tunnel. Up to 100 directions can be specified in one tunnel, list should end with -1.

Special care should be taken to ensure the entrance and exit cells are at the same height, or certain types of units will get stuck in them. Also, due to the fact that Tunnels were never a proper feature in RA2/YR, they don't cooperate well with new additions such as Battle Bunkers. It is advised to keep the edges of tunnel roofs unbuildable.