GRF: Initial support for > 255 road stop specs per GRF
Add new variable for road stop info of nearby tiles Bump roadstops version
This commit is contained in:
@@ -43,7 +43,10 @@
|
||||
|
||||
<h3 id="roadstop_ids">Road Stop IDs</h3>
|
||||
<p>
|
||||
Road stop IDs are NewGRF-local and can therefore freely be chosen in the 0..255 range. A road stop is allocated by setting the 'class'-property, which should therefore be set first.
|
||||
A road stop is allocated by setting the 'class'-property, which should therefore be set first.<br />
|
||||
Road stop IDs are NewGRF-local and can be freely chosen in the 0..63999 range, as of version 7 of the <span class="code">road_stops</span> feature.<br />
|
||||
When loaded into a version of OpenTTD with versions 1 to 6 of the <span class="code">road_stops</span> feature, IDs are limited to the range: 0..254.
|
||||
Any road stops with IDs outside this range will be skipped.
|
||||
</p>
|
||||
|
||||
<h3 id="roadstop_properties">Road Stop Properties</h3>
|
||||
@@ -172,6 +175,7 @@
|
||||
<tr><td>nearby_tile_road_piece</td><td>x, y offset (-8..7)</td><td>0..18 | 0xFF</td><td>Present road piece and slope in <a href="https://newgrf-specs.tt-wiki.net/wiki/Action3/Roadtypes#Road_underlay_.2802.29">sprite order</a>, or 0xFF if none</td></tr>
|
||||
<tr><td>nearby_tile_tram_piece</td><td>x, y offset (-8..7)</td><td>0..18 | 0xFF</td><td>Present tram piece and slope in <a href="https://newgrf-specs.tt-wiki.net/wiki/Action3/Roadtypes#Road_underlay_.2802.29">sprite order</a>, or 0xFF if none</td></tr>
|
||||
<tr><td>nearby_tile_road_stop_info</td><td>x, y offset (-8..7)</td><td></td><td>Above nearby road tile variables in one variable (all of variable 0x6B)</td></tr>
|
||||
<tr><td>nearby_tile_road_stop_info_v2</td><td>x, y offset (-8..7)</td><td></td><td>Above nearby road tile variables in one variable (all of variable roadstop_road_stop_info_nearby_tiles_v2)</td></tr>
|
||||
</table>
|
||||
|
||||
<h3 id="roadstop_callbacks">Road Stop Callbacks</h3>
|
||||
|
@@ -323,7 +323,10 @@
|
||||
|
||||
<table>
|
||||
<tr><th>Bits</th><th>Meaning</th></tr>
|
||||
<tr><td>0 - 7</td><td>If the tile is defined in the current GRF, this is the setID used in the definition. Otherwise, the content is undefined. </td></tr>
|
||||
<tr><td>0 - 7</td><td>
|
||||
If the tile is defined in the current GRF, this is the lower 8 bits of the setID used in the definition. Otherwise, the content is undefined.<br />
|
||||
Note that if this GRF has any road stop setIDs greater than 255, bits 24 - 31 need to be used as well.
|
||||
</td></tr>
|
||||
<tr><td>8 - 9</td><td>
|
||||
0 - The tile uses original TTD graphics<br />
|
||||
1 - The tile is defined in the current GRF<br />
|
||||
@@ -344,6 +347,43 @@
|
||||
1 - North-bound only<br />
|
||||
2 - South-bound only<br />
|
||||
3 - No entry
|
||||
</td></tr>
|
||||
<tr><td>24 - 31</td><td>
|
||||
If the tile is defined in the current GRF, this is the upper 8 bits of the setID used in the definition. Otherwise, the content is undefined.<br />
|
||||
This can be ignored if this GRF does not have any road stop setIDs greater than 255 (does not define more than 256 road stop types).<br />
|
||||
This requires <font face="monospace">road_stops</font>, version 7.
|
||||
</td></tr>
|
||||
</table>
|
||||
<br />
|
||||
The remaining bits are reserved for future use and should be masked.
|
||||
</p>
|
||||
|
||||
<h4 id="roadstop_road_stop_info_nearby_tiles">Road stop of nearby tile v2 (mappable variable: roadstop_road_stop_info_nearby_tiles_v2)</h4>
|
||||
<p>This has a similar value to <a href="#roadstop_road_stop_info_nearby_tiles">68</a>/<a href="#roadstop_road_stop_info_nearby_tiles">roadstop_road_stop_info_nearby_tiles</a>, above.<br />
|
||||
|
||||
<table>
|
||||
<tr><th>Bits</th><th>Meaning</th></tr>
|
||||
<tr><td>0 - 15</td><td>If the tile is defined in the current GRF, this is the setID used in the definition. Otherwise, the content is undefined. </td></tr>
|
||||
<tr><td>16 - 17</td><td>
|
||||
0 - The tile uses original TTD graphics<br />
|
||||
1 - The tile is defined in the current GRF<br />
|
||||
2 - The tile is defined in another GRF
|
||||
</td></tr>
|
||||
<tr><td>18</td><td>Set if the selected tile belongs to the current station, clear otherwise</td></tr>
|
||||
<tr><td>19</td><td>Clear if the selected tile has the same view/rotation, set if a different view/rotation</td></tr>
|
||||
<tr><td>20 - 23</td><td>View/rotation of the selected tile</td></tr>
|
||||
<tr><td>24 - 27</td><td>
|
||||
0 - Passenger/bus stop<br />
|
||||
1 - Freight/lorry stop<br />
|
||||
2 - Road waypoint
|
||||
</td></tr>
|
||||
<tr><td>28</td><td>Set if the stop type (passenger/bus, freight/lorry or road waypoint) is the same as the current tile</td></tr>
|
||||
<tr><td>29 - 30</td><td>
|
||||
One-way road information of the selected tile:<br />
|
||||
0 - Two-way traffic<br />
|
||||
1 - North-bound only<br />
|
||||
2 - South-bound only<br />
|
||||
3 - No entry
|
||||
</table>
|
||||
<br />
|
||||
The remaining bits are reserved for future use and should be masked.
|
||||
@@ -415,6 +455,10 @@
|
||||
|
||||
<p>Road stops have the same Action 3 cargo-type values as feature 4 (station).</p>
|
||||
|
||||
<p>In feature name <font face="monospace">road_stops</font> version 7 and later, the Action 3 ID field is an extended byte; GRFs may define more than 255 road stop types.<br />
|
||||
In versions 1 to 6 (inclusive), only 255 road stop types may be defined per GRF, and the extended byte format may not be used.</p>
|
||||
<br />
|
||||
|
||||
<h3 id="erata">Erata</h3>
|
||||
|
||||
<p>In feature name <font face="monospace">road_stops</font> versions 1 to 5 (inclusive), mapped Action 0 properties which are unknown and should be ignored, instead generate an error on use.</p>
|
||||
|
Reference in New Issue
Block a user