1
0
Fork 0

(svn r22658) -Feature: [NewGRF] Custom error messages for object callback 0x157.

release/1.2
michi_cc 2011-07-11 16:32:30 +00:00
parent 624aec0b19
commit e5dd6f9227
1 changed files with 2 additions and 1 deletions

View File

@ -240,7 +240,8 @@ CommandCost CmdBuildObject(TileIndex tile, DoCommandFlag flags, uint32 p1, uint3
if (callback == CALLBACK_FAILED) {
cost.AddCost(CheckBuildableTile(t, 0, allowed_z, false));
} else if (callback != 0) {
return_cmd_error(STR_ERROR_LAND_SLOPED_IN_WRONG_DIRECTION);
/* The meaning of bit 10 is inverted in the result of this callback. */
return GetErrorMessageFromLocationCallbackResult(ToggleBit(callback, 10), spec->grf_prop.grffile->grfid, STR_ERROR_LAND_SLOPED_IN_WRONG_DIRECTION);
}
}
}