GetLocalValue

From NPC for VCMP 0.4 Servers
Revision as of 18:18, 7 December 2022 by Habi (talk | contribs) (Created page with "{{Welcome|desc=Gets current field values of npc as a player.| params=<syntaxhighlight lang="lua">(field)</syntaxhighlight> <poem>::field : The field of npc's data to which...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search


Description:
Gets current field values of npc as a player.


Parameters:

(field)

field : The field of npc's data to which the value is to be get.


Return Values:

The value as integer or float.



Example The following code will fetch npc's current ammo.

local health = GetLocalValue(I_HEALTH );
if( health < 5 )
SendChat("Water. water please...");

relfuncs= *SetLocalValue