Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jun 16, 2006, 12:36:51 AM (19 years ago)
Author:
patrick
Message:

bsp: hit function reintroduced, now collision reaction should do better

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/bsp_model/src/world_entities/world_entity.cc

    r8507 r8511  
    727727}
    728728
     729
     730/**
     731 * hit the world entity with
     732 *  @param damage damage to be dealt
     733 */
     734void WorldEntity::hit(float damage)
     735{
     736  this->decreaseHealth(damage);
     737
     738  if( this->getHealth() > 0)
     739  {
     740    // any small explosion animaitions
     741  }
     742  else
     743  {
     744    this->destroy();
     745
     746//     if( State::getGameRules() != NULL)
     747//       State::getGameRules()->registerKill(Kill(NULL, this));
     748  }
     749}
     750
     751
    729752/**
    730753 * @brief updates the HealthWidget
Note: See TracChangeset for help on using the changeset viewer.