Index: code/branches/physics/src/orxonox/objects/HelloBullet.cc
===================================================================
--- code/branches/physics/src/orxonox/objects/HelloBullet.cc	(revision 2122)
+++ code/branches/physics/src/orxonox/objects/HelloBullet.cc	(revision 2124)
@@ -40,5 +40,5 @@
 #include "core/ConfigValueIncludes.h"
 #include "core/XMLPort.h"
-#include "GraphicsEngine.h"
+#include "objects/Scene.h"
 
 #include "util/Sleep.h"
@@ -49,5 +49,6 @@
     CreateFactory(HelloBullet);
     
-    HelloBullet::HelloBullet()
+    HelloBullet::HelloBullet(BaseObject* creator)
+        : BaseObject(creator)
     {
  	   RegisterObject(HelloBullet);
@@ -94,5 +95,5 @@
 
 //load floor mash
-        Ogre::SceneManager* sceneMgr = GraphicsEngine::getInstance().getLevelSceneManager();
+        Ogre::SceneManager* sceneMgr = creator->getScene()->getSceneManager();
 
         int i = 0;
Index: code/branches/physics/src/orxonox/objects/HelloBullet.h
===================================================================
--- code/branches/physics/src/orxonox/objects/HelloBullet.h	(revision 2122)
+++ code/branches/physics/src/orxonox/objects/HelloBullet.h	(revision 2124)
@@ -42,5 +42,5 @@
     {
     public:
-        HelloBullet();
+        HelloBullet(BaseObject* creator);
         virtual ~HelloBullet();
         void setConfigValues();
Index: code/branches/physics/src/orxonox/objects/PhysicsTest.cc
===================================================================
--- code/branches/physics/src/orxonox/objects/PhysicsTest.cc	(revision 2122)
+++ code/branches/physics/src/orxonox/objects/PhysicsTest.cc	(revision 2124)
@@ -40,4 +40,5 @@
 #include "core/XMLPort.h"
 #include "GraphicsEngine.h"
+#include "Scene.h"
 
 namespace orxonox
@@ -45,6 +46,7 @@
     CreateFactory(PhysicsTest);
 
-    PhysicsTest::PhysicsTest()
-        : odeWorld_(0)
+    PhysicsTest::PhysicsTest(BaseObject* creator)
+        : BaseObject(creator)
+        , odeWorld_(0)
         , odeSpace_(0)
         , odeStepper_(0)
@@ -84,5 +86,5 @@
         SUPER(PhysicsTest, XMLPort, xmlelement, mode);
 
-        Ogre::SceneManager* sceneMgr = GraphicsEngine::getInstance().getLevelSceneManager();
+        Ogre::SceneManager* sceneMgr = this->getScene()->getSceneManager();
 
         // set up OgreOde
@@ -103,16 +105,15 @@
         const Ogre::Real time_scale = Ogre::Real(1.7);
         const Ogre::Real max_frame_time = Ogre::Real(1.0 / 4);
-        odeStepper_ = new OgreOde::StepHandler(odeWorld_, OgreOde::StepHandler::QuickStep,_time_step,
+        odeStepper_ = new OgreOde::StepHandler(odeWorld_, OgreOde::StepHandler::QuickStep, _time_step,
             max_frame_time, time_scale);
 
 
-        // Create a hanging crate
+        // create a plane in x-z dimensions.
 
         odeGround_ = new OgreOde::InfinitePlaneGeometry(Ogre::Plane(Ogre::Vector3(0,1,0),0),
             odeWorld_, odeWorld_->getDefaultSpace());
 
-	CollidingObject* collidingObject = new CollidingObject();
-       
-	odeGround_->setUserObject(static_cast<CollisionTestedObject*>(collidingObject));
+        CollidingObject* collidingObject = new CollidingObject();
+        odeGround_->setUserObject(static_cast<CollisionTestedObject*>(collidingObject));
 
         // Use a load of meshes to represent the floor
@@ -139,5 +140,5 @@
 
 
-        // create a plane in x-z dimensions.
+        // create a hanging crate
 
         entity_ = sceneMgr->createEntity("crate","crate.mesh");
@@ -147,5 +148,4 @@
         entity_->setNormaliseNormals(true);
         entity_->setCastShadows(true);
-
 
         odeBody_ = new OgreOde::Body(odeWorld_);
@@ -178,49 +178,49 @@
     }
 
-    bool PhysicsTest::collision(OgreOde::Contact *Contact)
-    {
-    	// Check for collisions between things that are connected and ignore them
-       	OgreOde::Geometry * const g1 = Contact->getFirstGeometry();
-       	OgreOde::Geometry * const g2 = Contact->getSecondGeometry();
-
-       	if (g1 && g2)
-       	{
-       		const OgreOde::Body * const b1 = g2->getBody();
-       		const OgreOde::Body * const  b2 = g1->getBody();
-       		if (b1 && b2 && OgreOde::Joint::areConnected(b1, b2)) 
-                  return false; 
-       	}
-       
-       	//set contact parameters:
-       	Contact->setBouncyness(1.0);
-       	Contact->setCoulombFriction(OgreOde::Utility::Infinity);
-       	Contact->setForceDependentSlip(1.0);
-       	Contact->setAdditionalFDS(1.0);
-       
-       	/*we have 2 collidable objects from our object system, if one of the Collide function returns false, e return false in this method, too, else we return true, so ode computes a normal collision.
-        true means ode will treat this like a normal collison => rigid body behavior
-        false means ode will not treat this collision at all => objects ignore each other*/
-        	
-        bool Return = true;
-        	
+    bool PhysicsTest::collision(OgreOde::Contact* contact)
+    {
+        // Check for collisions between things that are connected and ignore them
+        OgreOde::Geometry * const g1 = contact->getFirstGeometry();
+        OgreOde::Geometry * const g2 = contact->getSecondGeometry();
+
+        if (g1 && g2)
+        {
+            const OgreOde::Body * const b1 = g2->getBody();
+            const OgreOde::Body * const b2 = g1->getBody();
+            if (b1 && b2 && OgreOde::Joint::areConnected(b1, b2)) 
+                return false; 
+        }
+
+        //set contact parameters:
+        contact->setBouncyness(1.0);
+        contact->setCoulombFriction(OgreOde::Utility::Infinity);
+        contact->setForceDependentSlip(1.0);
+        contact->setAdditionalFDS(1.0);
+
+        // we have 2 collidable objects from our object system, if one of the Collide function returns false, e return false in this method, too, else we return true, so ode computes a normal collision.
+        // true means ode will treat this like a normal collison => rigid body behavior
+        // false means ode will not treat this collision at all => objects ignore each other
+
+        bool res = true;
+
         if (g1->getUserObject())
-        	if (!static_cast<CollisionTestedObject*>(g1->getUserObject())->Collide(true, Contact))
-        		Return = false;
-        
+            if (!static_cast<CollisionTestedObject*>(g1->getUserObject())->collide(true, contact))
+                res = false;
+
         if (g2->getUserObject())
-        	if (!static_cast<CollisionTestedObject*>(g2->getUserObject())->Collide(false, Contact))
-        		Return = false;
-        
-        return Return;
-    }
-
-        bool CollidingObject::Collide(bool MineIsFirst, OgreOde::Contact *Contact)
-        {
-        	Contact->setForceDependentSlip(Contact->getForceDependentSlip() * ForceDependentSlip);
-        	Contact->setAdditionalFDS(Contact->getForceDependentSlip2() * ForceDependentSlip);
-        	Contact->setCoulombFriction(Contact->getCoulombFrictionMu() * Friction);
-        	Contact->setBouncyness(Contact->getBouncyness() * Bouncyness, Contact->getBouncynessVelocity() * BounceVelocity);
-        	return true;
-        }
+            if (!static_cast<CollisionTestedObject*>(g2->getUserObject())->collide(false, contact))
+                res = false;
+
+        return res;
+    }
+
+    bool CollidingObject::Collide(bool MineIsFirst, OgreOde::Contact* contact)
+    {
+        contact->setForceDependentSlip(contact->getForceDependentSlip() * ForceDependentSlip);
+        contact->setAdditionalFDS(contact->getForceDependentSlip2() * ForceDependentSlip);
+        contact->setCoulombFriction(contact->getCoulombFrictionMu() * Friction);
+        contact->setBouncyness(contact->getBouncyness() * Bouncyness, contact->getBouncynessVelocity() * BounceVelocity);
+        return true;
+    }
 
 }
Index: code/branches/physics/src/orxonox/objects/PhysicsTest.h
===================================================================
--- code/branches/physics/src/orxonox/objects/PhysicsTest.h	(revision 2122)
+++ code/branches/physics/src/orxonox/objects/PhysicsTest.h	(revision 2124)
@@ -42,5 +42,5 @@
     {
     public:
-        PhysicsTest();
+        PhysicsTest(BaseObject* creator);
         virtual ~PhysicsTest();
         void setConfigValues();
@@ -66,44 +66,45 @@
 
 
-   class _OrxonoxExport CollisionTestedObject
-   {
-        public:
-        	CollisionTestedObject(void);
-        	virtual ~CollisionTestedObject(void);
-        	virtual bool Collide(bool MineIsFirst, OgreOde::Contact *Contact) = 0;
-   };
+    class _OrxonoxExport CollisionTestedObject
+    {
+    public:
+        CollisionTestedObject(void);
+        virtual ~CollisionTestedObject(void);
+        virtual bool Collide(bool bMineFirst, OgreOde::Contact* contact) = 0;
+    };
 
-   class _OrxonoxExport CollidingObject : public virtual CollisionTestedObject
-   {
-        protected:
-               float Friction;
-        	float Bouncyness;
-        	float BounceVelocity;
-        	float ForceDependentSlip;
-        
-        public:
-        	CollidingObject(void);
-        	virtual ~CollidingObject(void);
-        
-        //	bool virtual WriteToIni(IniFile& Ini)	const;
-        //	bool virtual LoadFromIni(const std::basic_string<wchar_t>& ObjectID, IniFile& Ini);
-        
-        	float GetFriction(void)			const	{return Friction;}
-        	float GetBouncyness(void)		const	{return Bouncyness;}
-        	float GetBounceVelocity(void)		const	{return BounceVelocity;}
-        	float GetFDS(void)			const	{return ForceDependentSlip;}
-        
-        	virtual bool Collide(bool MineIsFirst, OgreOde::Contact *Contact);
-        
-        private:
-        	static const wchar_t* KEY_FRICTION;
-        	static const float DEF_FRICTION;
-        	static const wchar_t* KEY_BOUNCYNESS;
-        	static const float DEF_BOUNCYNESS;
-        	static const wchar_t* KEY_FDS;
-        	static const float DEF_FDS;
-        	static const wchar_t* KEY_BOUNCE_VELO;
-        	static const float DEF_BOUNCE_VELO;
-   };
+    class _OrxonoxExport CollidingObject : virtual public CollisionTestedObject
+    {
+    protected:
+        float friction_;
+        float bouncyness_;
+        float bounceVelocity_;
+        float forceDependentSlip_;
+
+    public:
+        CollidingObject(void);
+        virtual ~CollidingObject(void);
+
+        //virtual bool writeToIni(IniFile& ini)	const;
+        //virtual bool loadFromIni(const std::basic_string<wchar_t>& objectID, IniFile& ini);
+
+        float getFriction(void)       const {return friction_;}
+        float getBouncyness(void)     const {return bouncyness_;}
+        float getBounceVelocity(void) const {return bounceVelocity_;}
+        float getFDS(void)            const {return forceDependentSlip_;}
+
+        virtual bool collide(bool bMineFirst, OgreOde::Contact *contact);
+
+    private:
+        //static const wchar_t* KEY_FRICTION;
+        //static const float DEF_FRICTION;
+        //static const wchar_t* KEY_BOUNCYNESS;
+        //static const float DEF_BOUNCYNESS;
+        //static const wchar_t* KEY_FDS;
+        //static const float DEF_FDS;
+        //static const wchar_t* KEY_BOUNCE_VELO;
+        //static const float DEF_BOUNCE_VELO;
+
+    };
 
 }
