1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-12-03 23:19:22 +02:00

Implement configurable object sounds: ambient, visit and removal

* If there more than one sound for visit or removal random is played
* At moment only the first ambient sound will be used
This commit is contained in:
Arseniy Shestakov
2017-09-13 03:35:58 +03:00
committed by DJWarmonger
parent e9bfbb70c1
commit f15cadc87b
22 changed files with 347 additions and 91 deletions

View File

@@ -908,6 +908,11 @@ bool CGameInfoCallback::isInTheMap(const int3 &pos) const
return gs->map->isInTheMap(pos);
}
void CGameInfoCallback::getVisibleTilesInRange(std::unordered_set<int3, ShashInt3> &tiles, int3 pos, int radious, int3::EDistanceFormula distanceFormula) const
{
gs->getTilesInRange(tiles, pos, radious, getLocalPlayer(), -1, distanceFormula);
}
const CArtifactInstance * CGameInfoCallback::getArtInstance( ArtifactInstanceID aid ) const
{
return gs->map->artInstances[aid.num];