Toimiva
authorekku
Thu, 20 Nov 2008 19:58:41 +0000
changeset 81 4a91cf6f5cc7
parent 80 c21641a487c5
child 82 8f60abd6a083
Toimiva
src/proto2/Physics.cc
--- a/src/proto2/Physics.cc	Thu Nov 20 19:52:38 2008 +0000
+++ b/src/proto2/Physics.cc	Thu Nov 20 19:58:41 2008 +0000
@@ -50,7 +50,7 @@
     //TODO Handle the object as a square or a polygon
     
 //    Engine::log(DEBUG, "physics.update_position") << "position=" << newPosition << ", velocity=" << velocity;
-
+  /*
     bool collided = false;
 
     //goes 1 unit forward every step and check if has hit anything
@@ -85,8 +85,8 @@
     }
     this->position = newPosition;
     
-/*
-    collided = false;
+*/
+    bool collided = false;
      
     if (newPosition.x < 0 || (newPosition.x > world.dimensions.x)) {
         // CRASH!
@@ -123,7 +123,7 @@
     
     if(!collided) {
         this->position = newPosition;
-    }*/
+    }
 }
 
 bool PhysicsWorld::collided (Vector oldPos, Vector newPos) {