Skip to content

Metatable:Spell

Stefan A. Brannfjell edited this page Mar 15, 2020 · 2 revisions

The Spell metatable. Revscriptsys interface

local spell = Spell("incantation words")
local spell = Spell("spell name")

Available methods:

name
id
group
cooldown
groupCooldown
level
magicLevel
mana
manaPercent
health
healthPercent
soul
range
isPremium
isEnabled
needTarget
needWeapon
needLearn
isSelfTarget
isBlocking
isAggressive
vocation

only for InstantSpell:

words
needDirection
hasParams
hasPlayerNameParam
needCasterTargetOrDirection
isBlockingWalls

only for RuneSpells:

runeId
charges
allowFarUse
blockWalls
checkFloor


name([spell_name])

Description: Get or set the spell name
Parameters:

  • (optional) spell_name - No description
Returns: N/A
Example:
for _, spell in ipairs(player:getInstantSpells()) do
	print(spell:name())
end

Added in version: 1.0

Clone this wiki locally