RemoveSpell - Actor

From the CreationKit Wiki
Jump to navigation Jump to search

Member of: Actor Script

Removes the specified spell from this actor.

Syntax[edit | edit source]

bool Function RemoveSpell(Spell akSpell) native

Parameters[edit | edit source]

  • akSpell: The spell to remove from this actor.

Return Value[edit | edit source]

True on success.

Examples[edit | edit source]

; Removes the sheep spell from the player
if (Game.GetPlayer().RemoveSpell(SheepSpellProperty))
  Debug.Trace("Sheep spell removed from the player")
endIf

Note[edit | edit source]

This function will not succeed in removing spells that an actor has inherited from its ActorBase or Race. But it WILL still return true in such cases, even though the spell is not actually removed.

See Also[edit | edit source]