Don't produce NaN's for 0-length controllers in NifOgre::DefaultFunction

deque
scrawl 10 years ago
parent fe0c9ec9b7
commit f3f869e99a

@ -89,6 +89,9 @@ namespace NifOgre
{
if(mDeltaInput)
{
if (mStopTime - mStartTime == 0.f)
return 0.f;
mDeltaCount += value*mFrequency;
if(mDeltaCount < mStartTime)
mDeltaCount = mStopTime - std::fmod(mStartTime - mDeltaCount,

Loading…
Cancel
Save