MagicEffect Script

From Creation Kit
Jump to: navigation, search


Extends: Form Script (Papyrus)

Script for the manipulation of magic effect base objects.

Definition

ScriptName MagicEffect extends Form

Properties

None

Global Functions

None

Member Functions

String GetAssociatedSkill()
  • Obtains the skill that this magic effect is associated with.

SKSE Member Functions

SetAssociatedSkill(String skill)
  • Set the skill associated with the magic effect (eg. Destruction, Restoration, NONE. )
String GetResistance()
  • Returns the Resistance that this Magic Effect will be checked against when applied.
SetResistance(String skill)
  • Sets the Resistance that the magic effect will be checked against when applied (eg. MagicResist, PoisonResist or Resist Fire )
Bool IsEffectFlagSet(Int flag)
  • Checks to see if the specified flag is set (See Notes for list of flags)
SetEffectFlag(Int flag)
  • Sets the specified flag.
ClearEffectFlag(Int flag)
  • Clears the specified flag.
Float GetCastTime()
  • Returns the casting time of this magic effect.
SetCastTime(Float castTime)
  • Sets the casting time of this magic effect.
Int GetSkillLevel()
  • Returns the minimum skill level required to use this magic effect.
SetSkillLevel(Int level)
  • Sets the minimum skill level required to use this magic effect
Int GetArea()
  • Returns the area of this effect
SetArea(Int area)
  • Sets the area of this effect
Float GetSkillUsageMult()
  • Returns the skill usage multiplier which is used to calculate the amount of experience earned when using this spell.
SetSkillUsageMult(Float usageMult)
  • Sets the skill usage multiplier to the specified amount.
Float GetBaseCost()
  • Returns the base Magicka cost of the effect.
SetBaseCost(Float cost)
  • Sets the base Magicka cost of the effect.
Light GetLight()
  • Returns the light object used while casting the effect.
SetLight(Light obj)
  • Sets the light object used while casting the effect.
EffectShader GetHitShader()
  • Returns the EffectShader that is applied to an Actor when hit.
SetHitShader(EffectShader obj)
  • Sets the Effectshader used when an Actor is hit.
EffectShader GetEnchantShader()
  • Returns the EffectShader which is attached to the enchanted object (Only shown for Enchantments)
SetEnchantShader(EffectShader obj)
  • Sets the EffectShader which is attached to the enchanted object (Only shown for Enchantments)
Projectile GetProjectile()
SetProjectile(Projectile obj)
  • Get/Set the projectile which is fired by the effect
Explosion GetExplosion()
SetExplosion(Explosion obj)
  • Get/Set the explosion that is created when the projectile of the effect hits.
Art GetCastingArt()
  • Returns the art that is shown on hands while casting.
SetCastingArt(Art obj)
  • Sets the casting art.
Art GetHitEffectArt()
  • Returns the art object that is applied to the target of the effect on impact.
SetHitEffectArt(Art obj)
  • Sets the art object that is applied to the target.
Art GetEnchantArt()
  • Returns the art object that is attached to the enchanted object. (Only shown for enchantments)
SetEnchantArt(Art obj)
  • Sets the art object that is attached to the enchanted object.
ImpactDataSet GetImpactDataSet()
  • Returns the impact data set that is used by the effect to determine which (if any) decals should be applied.
SetImpactDataSet(ImpactDataSet obj)
  • Sets the impact data set for the effect.
Spell GetEquipAbility()
  • Returns the Ability-Type spell that is applied to the actor who equips a spell or enchanted item that uses this Magic Effect.
SetEquipAbility(Spell obj)
  • Sets the Equip Ability of this Magic Effect.
ImageSpaceModifier GetImageSpaceMod()
  • Returns the image space modifier that is used by the effect.
SetImageSpaceMod(ImageSpaceModifier obj)
  • Sets the image space modifier that is used by the Effect.
Perk GetPerk()
  • Returns the Perk that is applied to actors who are affected by this active effect. (Only works on the Player, Perks will not be applied to other NPCs).
SetPerk(Perk obj)
  • Sets the Perk to be applied to actors who are affected by this active effect.
int GetCastingType()
  • Constant Effect 0  ; Fire And Forget 1  ; Concentration 2
int GetDeliveryType()
  • Self 0; Contact 1; Aimed 2; Target Actor 3; Target Location 4

Events

None


Notes

  • The following is a list of all available flags for use with SetEffectFlag, ClearEffectFlag, IsEffectFlagSet functions:
Hostile	 		0x00000001
Recover  		0x00000002
Detrimental  		0x00000004
NoHitEvent  		0x00000010
DispelKeywords  	0x00000100
NoDuration  		0x00000200
NoMagnitude  		0x00000400
NoArea  		0x00000800
FXPersist  		0x00001000
GoryVisuals  		0x00004000
HideInUI  		0x00008000
NoRecast  		0x00020000
Magnitude  		0x00200000
Duration  		0x00400000
Painless  		0x04000000
NoHitEffect  		0x08000000
NoDeathDispel  		0x10000000