mirror of
https://github.com/vcmi/vcmi.git
synced 2025-11-29 23:07:48 +02:00
Remove most of non-const access to VLC entities
This commit is contained in:
@@ -510,7 +510,7 @@ CDrawTerrainOperation::InvalidTiles CDrawTerrainOperation::getInvalidTiles(const
|
||||
{
|
||||
if(map->isInTheMap(pos))
|
||||
{
|
||||
auto * ptrConfig = VLC->terviewh;
|
||||
const auto & ptrConfig = VLC->terviewh;
|
||||
const auto * terType = map->getTile(pos).terType;
|
||||
auto valid = validateTerrainView(pos, ptrConfig->getTerrainTypePatternById("n1")).result;
|
||||
|
||||
|
||||
@@ -760,7 +760,7 @@ void CMapLoaderH3M::readAllowedArtifacts()
|
||||
// ban combo artifacts
|
||||
if(!features.levelSOD)
|
||||
{
|
||||
for(CArtifact * artifact : VLC->arth->objects)
|
||||
for(auto const & artifact : VLC->arth->objects)
|
||||
if(artifact->isCombined())
|
||||
map->allowedArtifact.erase(artifact->getId());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user