Codechange: Don't use a global for the terrforming error tile.

This commit is contained in:
Michael Lutz
2021-12-01 00:44:57 +01:00
parent 2e39637db2
commit c521b965bd
7 changed files with 46 additions and 54 deletions

View File

@@ -44,13 +44,12 @@
#include "safeguards.h"
void CcTerraform(Commands cmd, const CommandCost &result, TileIndex tile)
void CcTerraform(Commands cmd, const CommandCost &result, Money, TileIndex tile)
{
if (result.Succeeded()) {
if (_settings_client.sound.confirm) SndPlayTileFx(SND_1F_CONSTRUCTION_OTHER, tile);
} else {
extern TileIndex _terraform_err_tile;
SetRedErrorSquare(_terraform_err_tile);
SetRedErrorSquare(tile);
}
}