GetLastAttacker(object)
Determine who last attacked a creature, door or placeable object.
object GetLastAttacker( object oAttackee = OBJECT_SELF );
Parameters
oAttackee
Attacked object. (Default: OBJECT_SELF)
Description
Returns the last attacker of oAttackee. This should be used ONLY in the OnPhysicalAttacked events for creatures, placeables and doors.
Return OBJECT_INVALID on error.
Remarks
Remarks: I cannot for the life of me figure out why the description for this function says it should only be called from OnPhysicalAttacked. I’ve tried calling it from all sorts of events, even some not owned by the creature, and all of them work just fine, even a while after I’ve stopped attacking oAttackee.
Version
1.30
See Also
functions: | GetLastHostileActor | GetLastKiller | GetLastWeaponUsed | GetTotalDamageDealt |
categories: | Combat Information Functions | Get Data from Object Functions |
events: | OnPhysicalAttacked Event |
author: Jason Harris, editor: Lilac Soul, additional contributor(s): Lilac Soul