Anvil
Anvil.API.Events.SpellEvents.OnSpellCast Class Reference
+ Inheritance diagram for Anvil.API.Events.SpellEvents.OnSpellCast:
+ Collaboration diagram for Anvil.API.Events.SpellEvents.OnSpellCast:

Properties

NwGameObjectCaster = NWScript.OBJECT_SELF.ToNwObject<NwGameObject>() [get]
 Gets the caster of this spell. More...
 
bool Harmful = NWScript.GetLastSpellHarmful().ToBool() [get]
 Gets a value indicating whether this spell is considered harmful. More...
 
bool IsSpontaneousCast = NWScript.GetSpellCastSpontaneously().ToBool() [get]
 Gets if this spell was cast spontaneously. More...
 
NwItemItem = NWScript.GetSpellCastItem().ToNwObject<NwItem>() [get]
 Gets the item that was used to cast the spell. Returns null if no item was used to cast this spell. More...
 
MetaMagic MetaMagicFeat = (MetaMagic)NWScript.GetMetaMagicFeat() [get]
 Gets the type of metamagic used on the last spell. More...
 
int SaveDC = NWScript.GetSpellSaveDC() [get]
 Gets the saving throw DC required to save against the effects of this spell. More...
 
NwSpell Spell = NwSpell.FromSpellId(NWScript.GetSpellId())! [get]
 Gets the spell that was cast. More...
 
NwClassSpellCastClass = NwClass.FromClassId(NWScript.GetLastSpellCastClass()) [get]
 Gets the class that the caster cast the spell as. More...
 
int SpellLevel = NWScript.GetLastSpellLevel() [get]
 Gets the level of the spell that was cast. More...
 
LocationTargetLocation = NWScript.GetSpellTargetLocation() [get]
 Gets the targeted location of this spell. More...
 
NwGameObjectTargetObject = NWScript.GetSpellTargetObject().ToNwObject<NwGameObject>() [get]
 Gets the object being targeted by this spell, otherwise returns null if the caster targeted the ground. More...
 
- Properties inherited from Anvil.API.Events.IEvent
NwObjectContext [get]
 

Property Documentation

◆ Caster

NwGameObject? Anvil.API.Events.SpellEvents.OnSpellCast.Caster = NWScript.OBJECT_SELF.ToNwObject<NwGameObject>()
get

Gets the caster of this spell.

◆ Harmful

bool Anvil.API.Events.SpellEvents.OnSpellCast.Harmful = NWScript.GetLastSpellHarmful().ToBool()
get

Gets a value indicating whether this spell is considered harmful.

◆ IsSpontaneousCast

bool Anvil.API.Events.SpellEvents.OnSpellCast.IsSpontaneousCast = NWScript.GetSpellCastSpontaneously().ToBool()
get

Gets if this spell was cast spontaneously.

◆ Item

NwItem? Anvil.API.Events.SpellEvents.OnSpellCast.Item = NWScript.GetSpellCastItem().ToNwObject<NwItem>()
get

Gets the item that was used to cast the spell. Returns null if no item was used to cast this spell.

◆ MetaMagicFeat

MetaMagic Anvil.API.Events.SpellEvents.OnSpellCast.MetaMagicFeat = (MetaMagic)NWScript.GetMetaMagicFeat()
get

Gets the type of metamagic used on the last spell.

◆ SaveDC

int Anvil.API.Events.SpellEvents.OnSpellCast.SaveDC = NWScript.GetSpellSaveDC()
get

Gets the saving throw DC required to save against the effects of this spell.

◆ Spell

NwSpell Anvil.API.Events.SpellEvents.OnSpellCast.Spell = NwSpell.FromSpellId(NWScript.GetSpellId())!
get

Gets the spell that was cast.

◆ SpellCastClass

NwClass? Anvil.API.Events.SpellEvents.OnSpellCast.SpellCastClass = NwClass.FromClassId(NWScript.GetLastSpellCastClass())
get

Gets the class that the caster cast the spell as.

◆ SpellLevel

int Anvil.API.Events.SpellEvents.OnSpellCast.SpellLevel = NWScript.GetLastSpellLevel()
get

Gets the level of the spell that was cast.

◆ TargetLocation

Location? Anvil.API.Events.SpellEvents.OnSpellCast.TargetLocation = NWScript.GetSpellTargetLocation()
get

Gets the targeted location of this spell.

◆ TargetObject

NwGameObject? Anvil.API.Events.SpellEvents.OnSpellCast.TargetObject = NWScript.GetSpellTargetObject().ToNwObject<NwGameObject>()
get

Gets the object being targeted by this spell, otherwise returns null if the caster targeted the ground.


The documentation for this class was generated from the following file: