Background for Skyrim SE
Member of the ActorBase script
voidfunctionSetProtected(boolabProtected=true)Native

Description

Wiki Description

Sets or clears this actor's protected flag. If you set the flag, and the actor is essential, the essential flag will be cleared.

Documentation Comment

Sets this actor as protected or not - if set as protected, will UNSET essential


Caveats

CK Wiki - Notes

  • This function is overridden by the flag on a quest alias.
  • When an actor is protected they can only be killed by the player.

Parameters

boolabProtected=true

CK Wiki Description

Whether to set or clear this actor's protected flag.

  • Default:True

Examples

; Flag the Emperor as protected
EmperorBaseActorProperty.SetProtected()
; Flag RedShirt as non-protected
RedShirtBaseActorProperty.SetProtected(false)

Auto-Generated Example

bool myBool__abProtected

myActorBase__toCallFunctionOn.SetProtected(myBool__abProtected)

Related Pages


Additional References

View this function’s page on the Skyrim Creation Kit Wiki

Some data provided by the Skyrim Creation Kit Wiki. Licensed under the Creative Commons Attribution-ShareAlike license.