Codechange: Use EnumBitSet for DoCommandFlags
This commit is contained in:
@@ -23,7 +23,7 @@
|
||||
|
||||
#include "safeguards.h"
|
||||
|
||||
static CommandCost ClearTile_Clear(TileIndex tile, DoCommandFlag flags)
|
||||
static CommandCost ClearTile_Clear(TileIndex tile, DoCommandFlags flags)
|
||||
{
|
||||
static const Price clear_price_table[] = {
|
||||
PR_CLEAR_GRASS,
|
||||
@@ -39,7 +39,7 @@ static CommandCost ClearTile_Clear(TileIndex tile, DoCommandFlag flags)
|
||||
price.AddCost(_price[clear_price_table[GetClearGround(tile)]]);
|
||||
}
|
||||
|
||||
if (flags & DC_EXEC) DoClearSquare(tile);
|
||||
if (flags.Test(DoCommandFlag::Execute)) DoClearSquare(tile);
|
||||
|
||||
return price;
|
||||
}
|
||||
@@ -352,7 +352,7 @@ static void ChangeTileOwner_Clear(TileIndex, Owner, Owner)
|
||||
return;
|
||||
}
|
||||
|
||||
static CommandCost TerraformTile_Clear(TileIndex tile, DoCommandFlag flags, int, Slope)
|
||||
static CommandCost TerraformTile_Clear(TileIndex tile, DoCommandFlags flags, int, Slope)
|
||||
{
|
||||
return Command<CMD_LANDSCAPE_CLEAR>::Do(flags, tile);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user