1
0
mirror of https://gitlab.com/OpenMW/openmw.git synced 2025-01-11 09:36:37 +00:00
OpenMW/apps/openmw/mwworld/doingphysics.cpp
2011-01-29 16:57:33 +01:00

34 lines
548 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;
}
}