Merge pull request #869 from neuralroberts/master

Use correct direction multipliers during awareness check
openmw-38
scrawl 9 years ago
commit 5feab8c7d3

@ -1435,7 +1435,7 @@ namespace MWMechanics
osg::Vec3f observerDir = (observer.getRefData().getBaseNode()->getAttitude() * osg::Vec3f(0,1,0));
float angleRadians = std::acos(observerDir * vec / (observerDir.length() * vec.length()));
if (angleRadians < osg::DegreesToRadians(90.f))
if (angleRadians > osg::DegreesToRadians(90.f))
y = obsTerm * observerStats.getFatigueTerm() * fSneakNoViewMult;
else
y = obsTerm * observerStats.getFatigueTerm() * fSneakViewMult;

Loading…
Cancel
Save