(svn r23885) -Codechange: Use the GRF sprite loader for then mapgen sprites as well.

This commit is contained in:
michi_cc
2012-02-04 13:28:56 +00:00
parent a02854d32f
commit 59d0702a6a
2 changed files with 31 additions and 51 deletions

View File

@@ -769,6 +769,7 @@ static void GenerateTerrain(int type, uint flag)
uint32 r = Random();
const Sprite *templ = GetSprite((((r >> 24) * _genterrain_tbl_1[type]) >> 8) + _genterrain_tbl_2[type] + 4845, ST_MAPGEN);
if (templ == NULL) usererror("Map generator sprites could not be loaded");
uint x = r & MapMaxX();
uint y = (r >> MapLogX()) & MapMaxY();