Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Dec 4, 2006, 2:24:40 PM (17 years ago)
Author:
patrick
Message:

removed many very heavy segfaults

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/coll_rect/src/lib/collision_reaction/collision_event.h

    r9892 r10006  
    4949
    5050    /** @return CollisionEvent WorldEntity A */
    51     inline WorldEntity* getEntityA() const
    52     {
    53       return this->entityA;
    54     }
     51    inline const WorldEntity* getEntityA() const  { return this->entityA; }
    5552    /** @return CollisionEvent WorldEntity B */
    56     inline WorldEntity* getEntityB() const
    57     {
    58       return this->entityB;
    59     }
     53    inline const WorldEntity* getEntityB() const  { return this->entityB; }
    6054    /** @return Bounding Volume from EntityA */
    61     inline BoundingVolume* getBVA() const
    62     {
    63       return this->bvA;
    64     }
     55    inline const BoundingVolume* getBVA() const { return this->bvA; }
    6556    /** @return Bounding Volume from EntityB */
    66     inline BoundingVolume* getBVB() const
    67     {
    68       return this->bvB;
    69     }
     57    inline const BoundingVolume* getBVB() const {  return this->bvB;  }
    7058
    7159    /** @return ground plane if collided with bsp model */
    72     inline Vector getGroundNormal()
    73     {
    74       return this->groundNormal;
    75     }
     60    inline const Vector& getGroundNormal() const  { return this->groundNormal; }
    7661
    7762    /** @return position of the position, only accurate if this is a collision with the ground!!! */
    78     inline Vector getCollisionPosition()
    79     {
    80       return this->position;
    81     }
     63    inline const Vector& getCollisionPosition() const  {  return this->position;  }
    8264
    8365    /** @return the type of the collision */
    84     inline int getType()
    85     {
    86       return this->collisionType;
    87     }
     66    inline int getType() const  {  return this->collisionType;  }
    8867
    8968    /** @return true if the entity is in the wall */
    90     inline bool isInWall()
    91     {
    92       return this->bInWall;
    93     }
     69    inline bool isInWall() const  {  return this->bInWall;  }
    9470
    9571
Note: See TracChangeset for help on using the changeset viewer.