1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-06 00:55:50 +00:00

Merge pull request #2046 from akortunov/holstered_weapons

Fix visible sheaths for invisible actors
This commit is contained in:
Bret Curtis 2018-11-25 01:10:11 +01:00 committed by GitHub
commit 10a049b087
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -355,10 +355,6 @@ void ActorAnimation::updateQuiver()
addGlow(arrow, glowColor);
}
}
// recreate shaders for invisible actors, otherwise new nodes will be visible
if (mAlpha != 1.f)
mResourceSystem->getSceneManager()->recreateShaders(mObjectRoot);
}
void ActorAnimation::itemAdded(const MWWorld::ConstPtr& item, int /*count*/)

View File

@ -925,6 +925,10 @@ void NpcAnimation::showWeapons(bool showWeapon)
updateHolsteredWeapon(!mShowWeapons);
updateQuiver();
// Recreate shaders for invisible actors, otherwise sheath nodes will be visible
if (mAlpha != 1.f && mWeaponSheathing)
mResourceSystem->getSceneManager()->recreateShaders(mObjectRoot);
}
void NpcAnimation::showCarriedLeft(bool show)