Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 8925 in orxonox.OLD for branches


Ignore:
Timestamp:
Jun 29, 2006, 10:50:30 PM (18 years ago)
Author:
patrick
Message:

all axis check and more debug out

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/single_player_map/src/lib/collision_reaction/cr_physics_ground_walk.cc

    r8924 r8925  
    7575  float height;
    7676  float front;
    77 
     77  float side;
     78
     79  PRINTF(0)("collision raction======================================\n");
    7880
    7981  const std::vector<CollisionEvent*>* collisionEvents = &(collision->getCollisionEvents());
     
    117119        height = collPos.y - box->halfLength[1];
    118120
     121        PRINTF(0)("height: %f\n", height);
     122        PRINTF(0)("in wall %i\n", ce->isInWall());
    119123
    120124        // object is beneath the plane (ground)
     
    133137        // collision in the z-axis
    134138      case COLLISION_TYPE_AXIS_Z:
     139
     140        side = collPos.z - box->halfLength[2];
     141
     142        PRINTF(0)("side: %f\n", side);
     143        PRINTF(0)("in wall %i\n", ce->isInWall());
     144
     145        // object is beneath the plane (ground)
     146        if( side <= 0.0f )
     147        {
     148//           entity->shiftCoor(Vector(front, 0.0f, 0.0f));
     149        }
     150        // object is already in the wall
     151        else if( ce->isInWall())
     152        {
     153//           entity->setAbsCoor(entity->getLastAbsCoor());
     154        }
    135155        break;
    136156    }
Note: See TracChangeset for help on using the changeset viewer.