mirror of
https://github.com/OpenMW/openmw.git
synced 2025-01-20 22:23:52 +00:00
Player can't detect self
This commit is contained in:
parent
e1e23447f2
commit
a469444e53
1 changed files with 2 additions and 1 deletions
|
@ -724,7 +724,8 @@ namespace MWMechanics
|
|||
void Actors::updateSneak (const MWWorld::Ptr& ptr)
|
||||
{
|
||||
const MWWorld::Ptr player = MWBase::Environment::get().getWorld()->getPlayerPtr();
|
||||
if (player.getClass().getCreatureStats(player).getMovementFlag(MWMechanics::CreatureStats::Flag_Sneak))
|
||||
if ( player.getClass().getCreatureStats(player).getMovementFlag(MWMechanics::CreatureStats::Flag_Sneak)
|
||||
&& ptr != player)
|
||||
{
|
||||
const MWWorld::ESMStore& esmStore = MWBase::Environment::get().getWorld()->getStore();
|
||||
int radius = esmStore.get<ESM::GameSetting>().find("fSneakUseDist")->getInt();
|
||||
|
|
Loading…
Reference in a new issue