1
0
Fork 1
mirror of https://github.com/TES3MP/openmw-tes3mp.git synced 2025-01-16 07:49:56 +00:00
openmw-tes3mp/apps/openmw/mwworld/doingphysics.cpp
2011-03-22 13:48:31 +01:00

33 lines
549 B
C++

#include "doingphysics.hpp"
namespace MWWorld
{
int DoingPhysics::sCounter = 0;
int DoingPhysics::sSuppress = 0;
DoingPhysics::DoingPhysics()
{
++sCounter;
}
DoingPhysics::~DoingPhysics()
{
--sCounter;
}
bool DoingPhysics::isDoingPhysics()
{
return sCounter>0 && sSuppress==0;
}
SuppressDoingPhysics::SuppressDoingPhysics()
{
++DoingPhysics::sSuppress;
}
SuppressDoingPhysics::~SuppressDoingPhysics()
{
--DoingPhysics::sSuppress;
}
}