Difference between revisions of "SetEssential - Actor"

From the Fallout4 CreationKit Wiki
Jump to navigation Jump to search
imported>Plplecuyer
 
(→‎Notes: added detail about the effect calling this function has on Aliases)
 
Line 28: Line 28:


== Notes ==
== Notes ==
Once this function is called it overrides the actor base value. Changing the state on the actor base will no longer have any effect.
Once this function is called it overrides all other methods to make an actor essential. Changing the state on the actor base will no longer have any effect, nor will the essential flag on any alias filled by the actor.


== See Also ==
== See Also ==
*[[Actor Script]]
*[[Actor Script]]
*[[SetProtected - Actor]]
*[[SetProtected - Actor]]

Latest revision as of 06:38, 3 June 2023

Member of: Actor Script

Sets or clears this actor's essential flag. If the actor is protected and you set the essential flag, the protected flag will be removed. This works on an individual actor, not the Actor Base.

Syntax[edit | edit source]

Function SetEssential(bool abEssential) native

Parameters[edit | edit source]

  • abEssential: Whether to set or clear this actor's essential flag.

Return Value[edit | edit source]

None.

Examples[edit | edit source]

; Flag the Emperor as essential
EmperorBaseActorProperty.SetEssential()


; Flag RedShirt as non-essential
RedShirtBaseActorProperty.SetEssential(false)

Notes[edit | edit source]

Once this function is called it overrides all other methods to make an actor essential. Changing the state on the actor base will no longer have any effect, nor will the essential flag on any alias filled by the actor.

See Also[edit | edit source]