about summary refs log tree commit diff
path: root/src/game/game.cpp
diff options
context:
space:
mode:
authorMagnus Auvinen <magnus.auvinen@gmail.com>2007-09-25 21:53:14 +0000
committerMagnus Auvinen <magnus.auvinen@gmail.com>2007-09-25 21:53:14 +0000
commitdbf425f1aa767de7f6415b45d1321d8dd6c05e97 (patch)
tree7ab92e9c5bae5f914e814746c203b4bdc4ef44bd /src/game/game.cpp
parenta554203943cde311a93090805b40f3d39ccc75d2 (diff)
downloadzcatch-dbf425f1aa767de7f6415b45d1321d8dd6c05e97.tar.gz
zcatch-dbf425f1aa767de7f6415b45d1321d8dd6c05e97.zip
updated ctf a bit
Diffstat (limited to 'src/game/game.cpp')
-rw-r--r--src/game/game.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/game/game.cpp b/src/game/game.cpp
index d5b74a92..c8c6acb3 100644
--- a/src/game/game.cpp
+++ b/src/game/game.cpp
@@ -79,13 +79,13 @@ void move_box(vec2 *inout_pos, vec2 *inout_vel, vec2 size, float elasticity)
 				if(test_box(vec2(pos.x, new_pos.y), size))
 				{
 					new_pos.y = pos.y;
-					vel.y = 0;
+					vel.y *= -elasticity;
 				}
 				
 				if(test_box(vec2(new_pos.x, pos.y), size))
 				{
 					new_pos.x = pos.x;
-					vel.x = 0;
+					vel.x *= -elasticity;
 				}
 			}