Tiberian Technologies Scripts Reference Revision: 9000
Loading...
Searching...
No Matches
List of all members
JFW_Send_Custom_On_Damage Class Reference

Send a custom based on health values. More...

#include <jfwcust.h>

Detailed Description

Author
jonwil

Attach this to an object with health. When the script starts up, it sets a flag to "above". When the object is damaged, it checks the value of "current health" + "current shield strength" against the "Health" parameter. If "current health" + "current shield strength" is less than the "Health" parameter and the "above" flag is set, it clears the "above" flag and sends the custom specified by "Message1" to the object with "ID1". If "current health" + "current shield strength" is greater than the "Health" parameter and the "above" flag is not set, it sets the "above" flag and sends the custom specified by "Message2" to the object with "ID2".

Parameters
Message1Message to send when the objects health+shield goes below the set value
ID1ID of the object to send Message1 to
Message2Message to send when the objects health+shield goes above the set value
ID2ID of the object to send Message2 to
HealthHealth value to check against