From b8ad11e7648ceaefb2b6859cfa6496cea969aa0a Mon Sep 17 00:00:00 2001 From: Doombringer-MarAlith Date: Wed, 29 Oct 2025 15:49:10 +0200 Subject: [PATCH 1/2] New method --- methods/TrinityCore/SpellMethods.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/methods/TrinityCore/SpellMethods.h b/methods/TrinityCore/SpellMethods.h index f868d88adb..9228998746 100644 --- a/methods/TrinityCore/SpellMethods.h +++ b/methods/TrinityCore/SpellMethods.h @@ -25,6 +25,17 @@ namespace LuaSpell return 1; } + /** + * Returns `true` if the [Spell] is passive, `false` otherwise. + * + * @return bool isPassive + */ + int IsPassive(Eluna* E, Spell* spell) + { + E->Push(spell->m_spellInfo->IsPassive()); + return 1; + } + /** * Returns the [Unit] that casted the [Spell]. * @@ -186,6 +197,7 @@ namespace LuaSpell // Boolean { "IsAutoRepeat", &LuaSpell::IsAutoRepeat }, + { "IsPassive", &LuaSpell::IsPassive }, // Other { "Cancel", &LuaSpell::Cancel }, From 2f1c696bc54954d147b9cf3a2ff2b9245c29b3bd Mon Sep 17 00:00:00 2001 From: Doombringer-MarAlith Date: Thu, 20 Nov 2025 15:57:48 +0200 Subject: [PATCH 2/2] one more method --- methods/TrinityCore/SpellMethods.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/methods/TrinityCore/SpellMethods.h b/methods/TrinityCore/SpellMethods.h index 9228998746..f57c361c19 100644 --- a/methods/TrinityCore/SpellMethods.h +++ b/methods/TrinityCore/SpellMethods.h @@ -36,6 +36,17 @@ namespace LuaSpell return 1; } + /** + * Returns `true` if the [Spell] is triggered, `false` otherwise. + * + * @return bool isTriggered + */ + int IsTriggered(Eluna* E, Spell* spell) + { + E->Push(spell->IsTriggered()); + return 1; + } + /** * Returns the [Unit] that casted the [Spell]. * @@ -198,6 +209,7 @@ namespace LuaSpell // Boolean { "IsAutoRepeat", &LuaSpell::IsAutoRepeat }, { "IsPassive", &LuaSpell::IsPassive }, + { "IsTriggered", &LuaSpell::IsTriggered }, // Other { "Cancel", &LuaSpell::Cancel },