Changeset - r7727:2e9d27db05f9
[Not reviewed]
master
0 2 0
rubidium - 17 years ago 2007-10-14 20:12:51
rubidium@openttd.org
(svn r11262) -Fix [FS#1330]: do not check for vehicles that are not on the ground when removing owned land, furthermore do not check for shadows (of aircraft).
2 files changed with 3 insertions and 3 deletions:
0 comments (0 inline, 0 general)
src/clear_cmd.cpp
Show inline comments
 
@@ -480,7 +480,7 @@ CommandCost CmdSellLandArea(TileIndex ti
 
	if (!CheckTileOwnership(tile) && _current_player != OWNER_WATER) return CMD_ERROR;
 

	
 

	
 
	if (!EnsureNoVehicle(tile)) return CMD_ERROR;
 
	if (!EnsureNoVehicleOnGround(tile)) return CMD_ERROR;
 

	
 
	if (flags & DC_EXEC) DoClearSquare(tile);
 

	
src/vehicle.cpp
Show inline comments
 
@@ -119,7 +119,7 @@ StringID VehicleInTheWayErrMsg(const Veh
 

	
 
static void *EnsureNoVehicleProc(Vehicle *v, void *data)
 
{
 
	if (v->tile != *(const TileIndex*)data || v->type == VEH_DISASTER)
 
	if (v->tile != *(const TileIndex*)data || v->type == VEH_DISASTER || (v->type == VEH_AIRCRAFT && v->subtype == AIR_SHADOW))
 
		return NULL;
 

	
 
	_error_message = VehicleInTheWayErrMsg(v);
 
@@ -135,7 +135,7 @@ static void *EnsureNoVehicleProcZ(Vehicl
 
{
 
	const TileInfo *ti = (const TileInfo*)data;
 

	
 
	if (v->tile != ti->tile || v->type == VEH_DISASTER) return NULL;
 
	if (v->tile != ti->tile || v->type == VEH_DISASTER || (v->type == VEH_AIRCRAFT && v->subtype == AIR_SHADOW)) return NULL;
 
	if (v->z_pos > ti->z) return NULL;
 

	
 
	_error_message = VehicleInTheWayErrMsg(v);
0 comments (0 inline, 0 general)