Codechange: Make SpriteType, CargoSortType, SourceType and ScriptType enum classes. (#10663)
This avoids a (soft) namespace conflict between the four ST_* enums.
This commit is contained in:
@@ -817,7 +817,7 @@ static void GenerateTerrain(int type, uint flag)
|
||||
uint32 r = Random();
|
||||
|
||||
/* Choose one of the templates from the graphics file. */
|
||||
const Sprite *templ = GetSprite((((r >> 24) * _genterrain_tbl_1[type]) >> 8) + _genterrain_tbl_2[type] + SPR_MAPGEN_BEGIN, ST_MAPGEN);
|
||||
const Sprite *templ = GetSprite((((r >> 24) * _genterrain_tbl_1[type]) >> 8) + _genterrain_tbl_2[type] + SPR_MAPGEN_BEGIN, SpriteType::MapGen);
|
||||
if (templ == nullptr) usererror("Map generator sprites could not be loaded");
|
||||
|
||||
/* Chose a random location to apply the template to. */
|
||||
|
Reference in New Issue
Block a user