FindActor
Usage:
FindActor(Name, [Type])
Description:
The FindActor command returns a handle to the first actor found matching the criteria specified. The Name is the name of the actor to find (in the case of NPCs, this is by default the same as the race). The Type specifies whether to look through NPCs, players, or both. A Type of 1 will search player characters only (whether in-game or not), a Type of 2 will search NPCs only, and a Type of 3 will search through all actors. If no Type value is specified, it will default to 3.
Example:
Function Main()
// Send a message to Fred
Player = FindActor("Fred", 1)
If (Player != 0)
Output(Player, "Hello Fred!")
EndIf
Return()
End Function
Comments (0)
You don't have permission to comment on this page.