Feat(LuaEngine/SpellInfo): Add SpellInfo class and methods #231
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request introduces SpellInfo API in mod-Eluna. With the addition of numerous new methods, this update provides developers with enhanced flexibility and control over spell-related interactions.
Key Highlights
Localization Support:
GetName
: Retrieve spell names in different locales, making localization more accessible.Attributes and Mechanics:
HasAttribute
: Check if a spell has a specific attribute.GetAttributes
: Retrieve all attributes of a spell.IsAffectingArea
: Determine if a spell affects an area (AoE).GetCategory
: Retrieve the spell’s category.IsPositive
/IsPositiveEffect
: Identify whether a spell or its effects are beneficial.Targeting Enhancements:
CheckTarget
andCheckExplicitTarget
: Validate if a target meets the requirements for a spell.NeedsExplicitUnitTarget
: Check if a spell requires a specific target.IsTargetingArea
: Verify if a spell targets an area.Aura and Effect Insights:
HasAura
/HasEffect
: Check for specific auras or effects.HasAreaAuraEffect
: Validate if a spell has an area-based aura.IsAuraExclusiveBySpecificWith
: Ensure exclusivity of an aura.Profession and Skill Integration:
IsProfession
,IsPrimaryProfession
, andIsAbilityLearnedWithProfession
enhance interactions with professions and skills.Miscellaneous Features:
IsPassive
: Determine if a spell is passive.IsChanneled
: Identify channeled spells.NeedsComboPoints
: Check if a spell requires combo points.IsSelfCast
: Validate self-casting spells.Advanced Mechanics:
CanPierceImmuneAura
andCanDispelAura
: Manage interactions with immune or dispellable auras.CheckLocation
: Verify if a spell can be used in a specific map, zone, or area.GetSchoolMask
: Retrieve the school of magic associated with a spell.