GetRace - ActorBase

From Creation Kit
Jump to: navigation, search

Member of: ActorBase Script

Obtains this actor's Race.

Syntax

Race Function GetRace() native

Parameters

None.

Return Value

The Race the actor is.

Examples

; Get the race that the player is
ActorBase PlayerBase = Game.GetPlayer().GetBaseObject() as ActorBase
Race PlayerRace = PlayerBase.GetRace()

Notes

  • This will not work for a template NPC or LeveledActor as the actor references (ACHR) are dynamically created.

See Also