vitals.inc Functions
 
 
Includes
The following inc files are included in vitals.inc
none
  

AP_GetVitalsCfgFile

Parameters
()
Explanation
Loads vitals.cfg
Return Values
Config file
 

AP_GetVitalCfgElem

Parameters
(vital_name, byref cfg_file:=0)
Name Type
vital_name Name of the vital to get the elem of.
cfg_file Optional parameter - reference to a config already read in.
Explanation
Retrieves a config elem for an vital in vitals.cfg
Return Values
Returns a config file elem.
 

AP_GetVitalNames

Parameters
()
Explanation
Retrieves a list of all vitals in vitals.cfg
Return Values
Returns an array of strings
 

AP_GetVital

Parameters
(mobile, vital_name)
Name Type
mobile Mobile reference to retrieve the points from.
vital_name Name of the vital to retrieve the points for.
Explanation
Retrieves the number of vital points a mobile has.
Return Values
Returns a double.
  

AP_GetVitalMaximumValue

Parameters
(mobile, vital_name)
Name Type
mobile Mobile reference to check.
vital_name Name of the vital to retrieve the max. points for.
Explanation
Retrieves the maximum number of vital points a mobile can have.
Return Values
Returns an integer.
 

AP_GetVitalRegenRate

Parameters
(mobile, vital_name)
Name Type
Mobile Mobile reference to check.
vital_name Name of the vital to retrieve the regen rate of.
Explanation
Retrieves the (base + mod) regen rate of a vital on a mobile.
Return Values
Returns an integer.
 

AP_SetVital

Parameters
(mobile, vital_name, amount)
Name Type
Mobile Mobile reference to set the vital on.
vital_name Name of the vital to set.
amount Number of points to set the vital to.
Explanation
Sets vital points on a mobile.
Return Values
Returns result of the SetVital() core function.
 

AP_ConsumeVital

Parameters
(mobile, vital_name, points)
Name Type
mobile Mobile reference to consume the vital on.
vital_name Name of the vital to consume.
points Number of points to attempt to consume.
Explanation
Attempts to remove points from a vital.
Return Values
Returns 1 on success
 

AP_RefreshVitals

Parameters
(mobile)
Name Type
mobile Mobile to refresh.
Explanation
Sets all vitals on a mobile to their maximum values.
Return Values
Returns 1