(svn r5794) Pass the TileIndex plus x and y coordinates into GetSlopeZ_* instead of a TileInfo

This commit is contained in:
tron
2006-08-06 16:32:49 +00:00
parent fb251d18e0
commit d8b8035f9f
14 changed files with 61 additions and 49 deletions

View File

@@ -323,9 +323,12 @@ static void DrawTile_Trees(TileInfo *ti)
}
static uint GetSlopeZ_Trees(const TileInfo* ti)
static uint GetSlopeZ_Trees(TileIndex tile, uint x, uint y)
{
return GetPartialZ(ti->x & 0xF, ti->y & 0xF, ti->tileh) + ti->z;
uint z;
uint tileh = GetTileSlope(tile, &z);
return z + GetPartialZ(x & 0xF, y & 0xF, tileh);
}
static Slope GetSlopeTileh_Trees(TileIndex tile, Slope tileh)