Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 7960 in orxonox.OLD


Ignore:
Timestamp:
May 29, 2006, 5:57:39 PM (18 years ago)
Author:
patrick
Message:

cr: list handling fuck up. better stuff to come… but after a big chinese meal being coocked by the most wicked simon:D

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/cr/src/lib/collision_reaction/cr_engine.h

    r7958 r7960  
    5151
    5252  /** @returns an instance to a collision object. instead of creating new object this ones can be resycled */
    53   inline Collision* popCollisionObject() { if(!this->cachedCollisions.empty()) { return this->cachedCollisions.back(); this->cachedCollisions.pop_back();} else return NULL; }
     53  inline Collision* popCollisionObject() { if(!this->collisionsUnused.empty()) { return this->collisionsUnused.back(); this->collisionsUnused.pop_back();} else return NULL; }
    5454  /** @param collision: returns the Collision object back to the cache list */
    55   inline void pushCollisionObject(Collision* collision) { this->cachedCollisions.push_back(collision); }
     55  inline void pushCollisionObject(Collision* collision) { this->collisionsUsed.push_back(collision); }
    5656
    5757
     
    6666private:
    6767  std::vector<CollisionHandle*>       collisionHandles;         //!< list with the collision handles
    68   std::vector<Collision*>             cachedCollisions;         //!< a list of unused, cached collision events
     68
     69  std::vector<Collision*>             collisionsUsed;           //!< a list of used, cached collisions
     70  std::vector<Collision*>             collisionsUnused;         //!< a list of unused, cached collisions
     71
     72  std::vector<Collision*>             collisionEventsUsed;      //!< a list of used, cached collision events
     73  std::vector<Collision*>             collisionEventsUnused;    //!< a list of unused, cached collision events
    6974
    7075  static CREngine*                    singletonRef;             //!< the reference to the CREngine object (singleton)
Note: See TracChangeset for help on using the changeset viewer.