Changeset 7541 for code/trunk/src/modules/pickup/items/HealthPickup.h
- Timestamp:
- Oct 14, 2010, 12:55:59 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk/src/modules/pickup/items/HealthPickup.h
r7493 r7541 47 47 namespace orxonox { 48 48 49 //! Enum for the type of the HealthPickup 49 /** 50 @brief 51 Enum for the type of the @ref orxonox::HealthPickup "HealthPickup". 52 53 @ingroup PickupItems 54 */ 50 55 namespace pickupHealthType 51 56 { 52 57 enum Value 53 58 { 54 limited, 55 temporary, 56 permanent 59 limited, //!< Means that the @ref orxonox::HealthPickup "HealthPickup" only increases the users health to its maximum health. 60 temporary, //!< Means that the @ref orxonox::HealthPickup "HealthPickup" temporarily increases the users health even above its maximum health, but only as long as it is in use. 61 permanent //!< Means that the @ref orxonox::HealthPickup "HealthPickup" increases the users health even above its maximum health and increases the maximum health permanently such that it matches the new health. 57 62 }; 58 63 } … … 60 65 /** 61 66 @brief 62 A pickupthat can do (dependent upon the parameters) lots of different things to the health of a Pawn.67 The Health Pickup is a Pickupable that can do (dependent upon the parameters) lots of different things to the health of a Pawn. 63 68 There are 4 parameters that can be chosen: 64 - The @b health The amount of health that (in a way dependent on the other parameters) is transfered to the Pawn. 65 - The @b activation @b type It can be chosen to be either 'immediate' or 'onUse'. The activation type essentially (as indicated by the name) defines when the health is transfered, either immediately after being picked up or only after the player uses it. 66 - The @b duration @b type It can be chosen to be either 'once' or 'continuous'. For 'once' the specified health is transfered once to the Pawn, for 'continuous' the set health is transfered over a span of time at a rate defined by the health rate parameter. 67 - The @b health @b type The health type can be chosen to be 'limited', 'temporary' or 'permanent'. 'limited' means that the health is increased only to the maximum health of the Pawn. 'temporary' means that the maximum health is temporarily elevated but will be set back as soon as the pickup is no longer in use. 'permanent' means that the maximum health of the Pawn is increased such that the health provided by the pickup will fit in and the maximum health stays that way. 69 - The <b>health</b> The amount of health that (in a way dependent on the other parameters) is transferred to the Pawn. 70 - The <b>activation type</b> It can be chosen to be either <em>immediate</em> or <em>onUse</em>. The activation type essentially (as indicated by the name) defines when the health is transferred, either immediately after being picked up or only after the player uses it. 71 - The <b>duration type</b> It can be chosen to be either <em>once</em> or <em>continuous</em>. For <em>once</em> the specified health is transferred once to the Pawn, for <em>continuous</em> the set health is transferred over a span of time at a rate defined by the health rate parameter. 72 - The <b>health type</b> The health type can be chosen to be <em>limited</em>, <em>temporary</em> or <em>permanent</em>. <em>limited</em> means that the health is increased only to the maximum health of the Pawn. 'temporary' means that the maximum health is temporarily elevated but will be set back as soon as the pickup is no longer in use. <em>permanent</em> means that the maximum health of the Pawn is increased such that the health provided by the pickup will fit in and the maximum health stays that way. 73 74 An examle of a XML implementation of a HealthPickup would be: 75 @code 76 <HealthPickup 77 health = 33 78 healthType = "limited" 79 activationType = "immediate" 80 durationType = "once" 81 /> 82 @endcode 83 68 84 @author 69 85 Damian 'Mozork' Frick 86 87 @ingroup PickupItems 70 88 */ 71 89 class _PickupExport HealthPickup : public Pickup, public Tickable … … 83 101 84 102 /** 85 @brief Get the health that is transfer ed to the Pawn upon usage of this pickup.103 @brief Get the health that is transferred to the Pawn upon usage of this pickup. 86 104 @return Returns the health. 87 105 */
Note: See TracChangeset
for help on using the changeset viewer.