mirror of
https://github.com/vcmi/vcmi.git
synced 2025-09-16 09:26:28 +02:00
Refactoring: random spells
This commit is contained in:
@@ -659,6 +659,17 @@ CTileInfo CMapGenerator::getTile(const int3& tile) const
|
||||
return tiles[tile.x][tile.y][tile.z];
|
||||
}
|
||||
|
||||
bool CMapGenerator::isAllowedSpell(SpellID sid) const
|
||||
{
|
||||
assert(sid >= 0);
|
||||
if (sid < map->allowedSpell.size())
|
||||
{
|
||||
return map->allowedSpell[sid];
|
||||
}
|
||||
else
|
||||
return false;
|
||||
}
|
||||
|
||||
void CMapGenerator::setNearestObjectDistance(int3 &tile, float value)
|
||||
{
|
||||
checkIsOnMap(tile);
|
||||
|
Reference in New Issue
Block a user