Re: a script to trigger when a rune is cast
Posted: Thu Nov 13, 2014 4:29 pm
Created 4 versions of the spell and they all work great. Though i guess the way these are defined the spell will only work on the 1 tile and nowhere else since theyre reliant on the tiles ID ?
SpoilerShow
defineSpell{
name = "karinafire_spell",
uiName = "Dispell Fire Seal",
requirements = {"fire_magic", 5},
gesture = 521,
manaCost = 5,
icon = 0,
spellIcon = 0,
description = "A spell to open doors sealed with a Fire Element Seal",
onCast = function(champion, x, y, direction, elevation, skillLevel)
customSpellScript.script.karinaSpellCast1(champion, x, y, direction, elevation, skillLevel)
end,
}
defineSpell{
name = "karinaair_spell",
uiName = "Dispell Air Seal",
requirements = {"air_magic", 5},
gesture = 563,
manaCost = 5,
icon = 0,
spellIcon = 0,
description = "A spell to open doors sealed with an Air Element Seal",
onCast = function(champion, x, y, direction, elevation, skillLevel)
customSpellScript.script.karinaSpellCast2(champion, x, y, direction, elevation, skillLevel)
end,
}
defineSpell{
name = "karinas_spell",
uiName = "Dispell Water Seal",
requirements = {"water_magic", 5},
gesture = 589,
manaCost = 5,
icon = 0,
spellIcon = 0,
description = "A spell to open doors sealed with a Water Element Seal",
onCast = function(champion, x, y, direction, elevation, skillLevel)
customSpellScript.script.karinaSpellCast3(champion, x, y, direction, elevation, skillLevel)
end,
}
defineSpell{
name = "karinas_spell",
uiName = "Dispell Earth Seal",
requirements = {"earth_magic", 5},
gesture = 547,
manaCost = 5,
icon = 0,
spellIcon = 0,
description = "A spell to open doors sealed with an Earth Element Seal",
onCast = function(champion, x, y, direction, elevation, skillLevel)
customSpellScript.script.karinaSpellCast4(champion, x, y, direction, elevation, skillLevel)
end,
}
name = "karinafire_spell",
uiName = "Dispell Fire Seal",
requirements = {"fire_magic", 5},
gesture = 521,
manaCost = 5,
icon = 0,
spellIcon = 0,
description = "A spell to open doors sealed with a Fire Element Seal",
onCast = function(champion, x, y, direction, elevation, skillLevel)
customSpellScript.script.karinaSpellCast1(champion, x, y, direction, elevation, skillLevel)
end,
}
defineSpell{
name = "karinaair_spell",
uiName = "Dispell Air Seal",
requirements = {"air_magic", 5},
gesture = 563,
manaCost = 5,
icon = 0,
spellIcon = 0,
description = "A spell to open doors sealed with an Air Element Seal",
onCast = function(champion, x, y, direction, elevation, skillLevel)
customSpellScript.script.karinaSpellCast2(champion, x, y, direction, elevation, skillLevel)
end,
}
defineSpell{
name = "karinas_spell",
uiName = "Dispell Water Seal",
requirements = {"water_magic", 5},
gesture = 589,
manaCost = 5,
icon = 0,
spellIcon = 0,
description = "A spell to open doors sealed with a Water Element Seal",
onCast = function(champion, x, y, direction, elevation, skillLevel)
customSpellScript.script.karinaSpellCast3(champion, x, y, direction, elevation, skillLevel)
end,
}
defineSpell{
name = "karinas_spell",
uiName = "Dispell Earth Seal",
requirements = {"earth_magic", 5},
gesture = 547,
manaCost = 5,
icon = 0,
spellIcon = 0,
description = "A spell to open doors sealed with an Earth Element Seal",
onCast = function(champion, x, y, direction, elevation, skillLevel)
customSpellScript.script.karinaSpellCast4(champion, x, y, direction, elevation, skillLevel)
end,
}