comparison src/ai/api/ai_tile.cpp @ 16760:9e31dde37aed draft

(svn r21493) -Codechange: don't use the full 32 bits of the level land command to tell whether to raise, lower or keep the level of the first selected tile
author rubidium <rubidium@openttd.org>
date Mon, 13 Dec 2010 11:21:53 +0000
parents a864a5a396ed
children 47d33cf95c70
comparison
equal deleted inserted replaced
16759:aa34ba5a7da1 16760:9e31dde37aed
232 /* static */ bool AITile::LevelTiles(TileIndex start_tile, TileIndex end_tile) 232 /* static */ bool AITile::LevelTiles(TileIndex start_tile, TileIndex end_tile)
233 { 233 {
234 EnforcePrecondition(false, start_tile < ::MapSize()); 234 EnforcePrecondition(false, start_tile < ::MapSize());
235 EnforcePrecondition(false, end_tile < ::MapSize()); 235 EnforcePrecondition(false, end_tile < ::MapSize());
236 236
237 return AIObject::DoCommand(end_tile, start_tile, 0, CMD_LEVEL_LAND); 237 return AIObject::DoCommand(end_tile, start_tile, LM_LEVEL << 1, CMD_LEVEL_LAND);
238 } 238 }
239 239
240 /* static */ bool AITile::DemolishTile(TileIndex tile) 240 /* static */ bool AITile::DemolishTile(TileIndex tile)
241 { 241 {
242 EnforcePrecondition(false, ::IsValidTile(tile)); 242 EnforcePrecondition(false, ::IsValidTile(tile));