NPCClient math script: Difference between revisions
Jump to navigation
Jump to search
Created page with " == NPC Client == == NPC == {| HP The HP for the NPC | MaxHP | Mana | MaxMana |}" |
No edit summary |
||
Line 1: | Line 1: | ||
NPC Client Math scripts are used from [[Behavior Operations#Perception]] | |||
== NPC Client == | == NPC Client == | ||
The NPCClient has the following properties: | |||
{| | |||
|gameHour | |||
|The hour in game time | |||
|- | |||
|gameMinute | |||
|The minute in game time | |||
|- | |||
|gameMonth | |||
|The month in game time | |||
|- | |||
|gameYear | |||
|The year in game time | |||
|- | |||
|} | |||
Example DiurnalNight: | |||
if (NPCClient:gameHour > 22 | NPCClient:gameHour < 6) | |||
{ | |||
Result = 1.0; | |||
} else | |||
{ | |||
Result = 0.0; | |||
} | |||
== NPC == | == NPC == | ||
The NPC has the following properties: | |||
{| | {| | ||
HP | |HP | ||
The HP for the NPC | |The HP for the NPC | ||
| | |- | ||
MaxHP | |InsideTribeHome | ||
| | |Return 1.0 if inside tribe home, otherwise 0.0. | ||
Mana | |- | ||
| | |InsideRegion | ||
|Return 1.0 if inside region, otherwise 0.0. | |||
|- | |||
|Mana | |||
|The Mana for the NPC | |||
|- | |||
|MaxHP | |||
|The Max HP for the NPC | |||
|- | |||
|MaxMana | |||
|The Max Mana for the NPC | |||
|- | |||
|MaxMStamina | |||
|The Max Mental Stamina for the NPC | |||
|- | |||
|MaxPStamina | |||
|The Max Physical Stamina for the NPC | |||
|- | |||
|MStamina | |||
|The Mental Stamina for the NPC | |||
|- | |||
|PStamina | |||
|The Physical Stamina for the NPC | |||
|- | |||
|} | |} | ||
Example: | |||
Health = NPC:HP/NPC:MaxHP; |
Revision as of 16:06, 6 January 2013
NPC Client Math scripts are used from Behavior Operations#Perception
NPC Client
The NPCClient has the following properties:
gameHour | The hour in game time |
gameMinute | The minute in game time |
gameMonth | The month in game time |
gameYear | The year in game time |
Example DiurnalNight:
if (NPCClient:gameHour > 22 | NPCClient:gameHour < 6) { Result = 1.0; } else { Result = 0.0; }
NPC
The NPC has the following properties:
HP | The HP for the NPC |
InsideTribeHome | Return 1.0 if inside tribe home, otherwise 0.0. |
InsideRegion | Return 1.0 if inside region, otherwise 0.0. |
Mana | The Mana for the NPC |
MaxHP | The Max HP for the NPC |
MaxMana | The Max Mana for the NPC |
MaxMStamina | The Max Mental Stamina for the NPC |
MaxPStamina | The Max Physical Stamina for the NPC |
MStamina | The Mental Stamina for the NPC |
PStamina | The Physical Stamina for the NPC |
Example:
Health = NPC:HP/NPC:MaxHP;