Fix mesh res enabled check

master
Ansariel 2025-05-20 18:33:14 +02:00
parent 29b31aa759
commit ca7b4058e7
2 changed files with 9 additions and 15 deletions

View File

@ -6210,13 +6210,15 @@ bool LLMeshRepository::meshRezEnabled()
// <FS:Beq> FIRE-35602 etc - Mesh not appearing after TP/login (opensim only)
// For OpenSim there is still an outside chance that mesh rezzing is disabled on the sim/region
// restore the old behaviour but keep the bias to mesh_enabled == true in the underlying checks.
#ifdef OPENSIM
LLViewerRegion *region = gAgent.getRegion();
if(mesh_enabled &&
region)
#ifdef OPENSIM
if (LLGridManager::instance().isInOpenSim())
{
return region->meshRezEnabled();
if (LLViewerRegion* region = gAgent.getRegion(); mesh_enabled && region)
{
return region->meshRezEnabled();
}
}
else
#endif // OPENSIM
// </FS:Beq>
return mesh_enabled;

View File

@ -3988,19 +3988,11 @@ bool LLViewerRegion::bakesOnMeshEnabled() const
#ifdef OPENSIM
bool LLViewerRegion::meshRezEnabled() const
{
if (LLGridManager::getInstance()->isInOpenSim())
{
if(!mSimulatorFeaturesReceived)
{
LL_DEBUGS("MeshRez") << "MeshRezEnabled: SimulatorFeatures not received yet. Defaulting to true" << LL_ENDL;
return true;
}
}
return (mSimulatorFeatures.has("MeshRezEnabled") &&
mSimulatorFeatures["MeshRezEnabled"].asBoolean());
return (mSimulatorFeatures.has("MeshRezEnabled") && mSimulatorFeatures["MeshRezEnabled"].asBoolean());
}
#endif
// </FS:Beq>
bool LLViewerRegion::dynamicPathfindingEnabled() const
{
return ( mSimulatorFeatures.has("DynamicPathfindingEnabled") &&