GetKiller - Actor

Revision as of 11:07, 2 September 2014 by imported>Terra Nova2 (Function returns the player if actors killed by followers.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

Member of: Actor Script

Obtains the actor that killed this one. If this actor isn't dead, returns None.

SyntaxEdit

Actor Function GetKiller() native

ParametersEdit

None.

Return ValueEdit

The actor that killed this one (if any). If actor is not dead, returns None.

ExamplesEdit

; Print a message if Bob is in combat with the player
if (Bob.GetKiller() == Game.GetPlayer())
  Debug.Trace("Bob was killed by the player!")
endIf

NotesEdit

  • This function will always return the player as the killer, if an actor is killed by a follower, and possibly summoned actors.

See AlsoEdit