Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Changeset 3581 in orxonox.OLD


Ignore:
Timestamp:
Mar 16, 2005, 6:26:01 PM (19 years ago)
Author:
patrick
Message:

orxonox/trunk: character attributes defined

File:
1 edited

Legend:

Unmodified
Added
Removed
  • orxonox/trunk/src/world_entities/character_attributes.h

    r3580 r3581  
    2020  virtual ~CharacterAttributes();
    2121
     22  /* health */
     23  void setHealth(int health);
     24  void addHealth(int health);
     25  void substractHealth(int health);
     26  int getHealth();
     27
     28  void setHealthMax(int healthMax);
     29  int getHealthMax();
     30
     31
     32  /* armor/ shields */
     33  void setShieldStrength(int shieldStrength);
     34  void addShieldStrength(int shiledStrength);
     35  void substractShieldStrength(int shieldStrength);
     36  int getShieldStrength();
     37
     38
     39  /* damage */
     40  void setDamageToAirCraft(int damage);
     41  int getDamageToAirCraft();
     42
     43  void setDamageToGroundCraft(int damage);
     44  int getDamageToGroundCraft();
     45
     46  void setDamageLaserModifier(float modifier);
     47  float getDamageLaserModifier();
     48
     49  void setDamagePlasmaModifier(float modifier);
     50  float getDamagePlasmaModifier();
     51
     52  void setDamageExplosiveModifier(float modifier);
     53  float getDamageExplosiveModifier();
     54
     55
     56  /* energy */
     57  void setEnergy(int energy);
     58  int addEnergy(int addEnergy);
     59  void substractEnergy(int subEnergy);
     60  int getEnergy();
     61 
     62
     63 private:
     64  /* healt */
     65  int health;                        //<! the healt of a projectile
     66  int helathMax;                     //<! the max healt of a projectile, =0 if no limit
     67
     68  /* armor/ shields */
     69  int shieldStrength;                //<! the shiled strength of a character, =0 if no shields
     70
     71  /* damage */
     72  int damageToAirCraft;              //<! damage dealt to a air craft in case of a hit
     73  int damageToGroundCraft;           //<! damage dealt to a ground craft in case of a hit
     74
     75  float damageLaserModifier;         //<! [0..1] the damage from laser is multiplied with this modifier. there can be things in the world, that are immune to certain damage
     76  float damagePlasmaModifier;        //<! [0..1] the damage from plasma is multiplied with this modifier. there can be things in the world, that are immune to certain damage
     77  float damageExplosiveModifer;      //<! [0..1] the damage from exposives (rockets, tnt,...) is multiplied with this modifier. there can be things in the world, that are immune to certain damage
     78
     79  /* energy */
     80  int energyConsumption;             //<! if the character defines an action, it will consume energy
     81  int energyMax;                     //<! the maximal energy a character can handle
    2282};
    2383
Note: See TracChangeset for help on using the changeset viewer.