mirror of
https://github.com/TES3MP/openmw-tes3mp.git
synced 2025-01-20 07:53:51 +00:00
fixed an unitialised variable
This commit is contained in:
parent
705e11becb
commit
4191bb32d1
2 changed files with 18 additions and 16 deletions
|
@ -15,16 +15,16 @@ namespace MWWorld
|
|||
{
|
||||
|
||||
PhysicsSystem::PhysicsSystem(OEngine::Render::OgreRenderer &_rend , OEngine::Physic::PhysicEngine* physEng) :
|
||||
mRender(_rend), mEngine(physEng)
|
||||
mRender(_rend), mEngine(physEng), mFreeFly (true)
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
PhysicsSystem::~PhysicsSystem()
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
std::vector< std::pair<std::string, Ogre::Vector3> > PhysicsSystem::doPhysics (float duration,
|
||||
const std::vector<std::pair<std::string, Ogre::Vector3> >& actors)
|
||||
{
|
||||
|
@ -76,7 +76,7 @@ namespace MWWorld
|
|||
{
|
||||
btVector3 newPos = it->second->getPosition();
|
||||
Ogre::Vector3 coord(newPos.x(), newPos.y(), newPos.z());
|
||||
|
||||
|
||||
response.push_back(std::pair<std::string, Ogre::Vector3>(it->first, coord));
|
||||
}
|
||||
return response;
|
||||
|
|
|
@ -13,31 +13,33 @@ namespace MWWorld
|
|||
public:
|
||||
PhysicsSystem (OEngine::Render::OgreRenderer &_rend , OEngine::Physic::PhysicEngine* physEng);
|
||||
~PhysicsSystem ();
|
||||
|
||||
|
||||
std::vector< std::pair<std::string, Ogre::Vector3> > doPhysics (float duration,
|
||||
const std::vector<std::pair<std::string, Ogre::Vector3> >& actors);
|
||||
|
||||
|
||||
void addObject (const std::string& handle, const std::string& mesh,
|
||||
const Ogre::Quaternion& rotation, float scale, const Ogre::Vector3& position);
|
||||
|
||||
|
||||
void addActor (const std::string& handle, const std::string& mesh,
|
||||
const Ogre::Vector3& position);
|
||||
|
||||
|
||||
void removeObject (const std::string& handle);
|
||||
|
||||
|
||||
void moveObject (const std::string& handle, const Ogre::Vector3& position, bool updatePhysics);
|
||||
|
||||
|
||||
void rotateObject (const std::string& handle, const Ogre::Quaternion& rotation);
|
||||
|
||||
|
||||
void scaleObject (const std::string& handle, float scale);
|
||||
|
||||
|
||||
bool toggleCollisionMode();
|
||||
|
||||
|
||||
private:
|
||||
OEngine::Render::OgreRenderer &mRender;
|
||||
OEngine::Physic::PhysicEngine* mEngine;
|
||||
bool mFreeFly;
|
||||
|
||||
|
||||
PhysicsSystem (const PhysicsSystem&);
|
||||
PhysicsSystem& operator= (const PhysicsSystem&);
|
||||
};
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue