Changeset 8933 in orxonox.OLD for branches/single_player_map/src/lib/collision_reaction
- Timestamp:
- Jun 30, 2006, 1:12:57 AM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/single_player_map/src/lib/collision_reaction/cr_physics_ground_walk.cc
r8932 r8933 96 96 // collision in the x-axis 97 97 case COLLISION_TYPE_AXIS_X: 98 front = collPos.x - box->halfLength[ 0];98 front = collPos.x - box->halfLength[2]; // should be [0] 99 99 100 100 // object is beneath the plane (ground) … … 134 134 case COLLISION_TYPE_AXIS_Z: 135 135 136 side = collPos.z - box->halfLength[ 2];136 side = collPos.z - box->halfLength[0]; // should be [2] 137 137 138 138 // object is beneath the plane (ground) 139 139 if( side <= 0.0f ) 140 140 { 141 entity->shiftCoor(Vector(0.0f, 0.0f, side)); 141 Vector backoff = entity->getAbsDirX() * side; 142 entity->shiftCoor(backoff); 143 // entity->shiftCoor(Vector(0.0f, 0.0f, side)); 142 144 } 143 145 // object is already in the wall
Note: See TracChangeset
for help on using the changeset viewer.