SetEnchantment

From the Oblivion ConstructionSet Wiki
Revision as of 03:10, 30 September 2011 by imported>Lanceor (Updates based on new findings - see Talk Page.)
Jump to navigation Jump to search

A command for Oblivion Script Extender

Syntax:

(oldEnchantment:ref) reference.SetEnchantment nuEnchantment:ref objectID:ref

Sets the specific enchantment on the object and returns any previous enchantment.

Notes

  • For equipped armor and clothing, the new enchantment will only take affect after the actor unequips and re-equips the item.
  • Changes to weapon enchantments occur immediately. If the change occurs while the weapon is equipped however, the enchantment shader (e.g. the orange edge glow for fire damage) will not update until the actor unequips and re-equips the weapon.
  • Changes to enchantments are not saved. Any items modified with this function will revert to their default enchantment on loading a saved game.
  • Doesn't work on arrows.

See Also