Changeset - r8955:31c083f63196
[Not reviewed]
master
0 3 0
peter1138 - 16 years ago 2008-04-17 06:52:56
peter1138@openttd.org
(svn r12746) -Codechange: Add map storage for station animation frame
3 files changed with 14 insertions and 1 deletions:
0 comments (0 inline, 0 general)
docs/landscape.html
Show inline comments
 
@@ -890,24 +890,25 @@
 
          <tr>
 
           <td><tt>05</tt>&nbsp; </td>
 
           <td align=left>Y direction water part</td>
 
          </tr>
 
         </table>
 
        </td>
 
       </tr>
 
      </table>
 
     </li>
 
     <li>m6 bits 5..3: the station type (rail, airport, truck, bus, oilrig, dock, buoy)</li>
 
     <li>m6 bit 2: 1 when a drive through road stop is built over a town owned road, otherwise 0</li>
 
     <li>m6 bits 1..0 : <a href="#tropic_zone">Tropic zone definition</a></li>
 
     <li>m7: animation frame</li>
 
    </ul>
 
   </td>
 
  </tr>
 

	
 
  <tr bgcolor="#CCCCCC">
 
   <td valign=top nowrap><strong><a name="Class6"><tt> 6 </tt></a></strong></td>
 
   <td><strong>Water</strong></td>
 
  </tr>
 
  <tr>
 
   <td valign=top nowrap>&nbsp;</td>
 
   <td>
 
    <ul>
docs/landscape_grid.html
Show inline comments
 
@@ -189,25 +189,25 @@ the array so you can quickly see what is
 
      <td class="bits"><span class="free">OOOO OOOO</span></td>
 
    </tr>
 
    <tr>
 
      <td rowspan=6>5</td>
 
      <td class="caption">rail station</td>
 
      <td class="bits">XXXX XXXX</td>
 
      <td class="bits"><span class="option">~~~</span>X XXXX</td>
 
      <td class="bits">XXXX XXXX XXXX XXXX</td>
 
      <td class="bits">XXXX <span class="option">~~</span>XX</td>
 
      <td class="bits">XXXX XXXX</td>
 
      <td class="bits">XXXX XXXX</td>
 
      <td class="bits"><span class="free">OO</span>XX X<span class="free">O</span>XX</td>
 
      <td class="bits"><span class="free">OOOO OOOO</span></td>
 
      <td class="bits">XXXX XXXX</td>
 
    </tr>
 
    <tr>
 
      <td class="caption">road stop</td>
 
      <td class="bits">-inherit-</td>
 
      <td class="bits">-inherit-</td>
 
      <td class="bits">-inherit-</td>
 
      <td class="bits"><span class="free">OOOO O</span>XXX</td>
 
      <td class="bits"><span class="option">~~~~ ~~~~</span></td>
 
      <td class="bits"><span class="option">~~~~ ~</span>XXX</td>
 
      <td class="bits"><span class="free">OO</span>XX XXXX</td>
 
      <td class="bits"><span class="free">OOOO OOOO</span></td>
 
    </tr>
src/station_map.h
Show inline comments
 
@@ -59,24 +59,36 @@ static inline RoadStopType GetRoadStopTy
 
static inline StationGfx GetStationGfx(TileIndex t)
 
{
 
	assert(IsTileType(t, MP_STATION));
 
	return _m[t].m5;
 
}
 

	
 
static inline void SetStationGfx(TileIndex t, StationGfx gfx)
 
{
 
	assert(IsTileType(t, MP_STATION));
 
	_m[t].m5 = gfx;
 
}
 

	
 
static inline uint8 GetStationAnimationFrame(TileIndex t)
 
{
 
	assert(IsTileType(t, MP_STATION));
 
	return _me[t].m7;
 
}
 

	
 
static inline void SetStationAnimationFrame(TileIndex t, uint8 frame)
 
{
 
	assert(IsTileType(t, MP_STATION));
 
	_me[t].m7 = frame;
 
}
 

	
 
static inline bool IsRailwayStation(TileIndex t)
 
{
 
	return GetStationType(t) == STATION_RAIL;
 
}
 

	
 
static inline bool IsRailwayStationTile(TileIndex t)
 
{
 
	return IsTileType(t, MP_STATION) && IsRailwayStation(t);
 
}
 

	
 
static inline bool IsAirport(TileIndex t)
 
{
0 comments (0 inline, 0 general)