mirror of
https://github.com/araxiaonline/RandomScriptsforAzerothCore.git
synced 2026-06-13 02:22:19 -04:00
Add files via upload
This commit is contained in:
@@ -24,10 +24,10 @@ function OnSpellCast(event, caster, spell)
|
||||
end
|
||||
end
|
||||
|
||||
-- If the target is not a valid NPC
|
||||
if not isValidTarget then
|
||||
-- If the target is not a valid NPC or if the target's health is greater than 90%
|
||||
if not isValidTarget or target:GetHealthPct() > 90 then
|
||||
-- Send a broadcast message to the player
|
||||
caster:SendBroadcastMessage("Invalid target.")
|
||||
caster:SendBroadcastMessage("That defender is doing fine. Find one that needs more help!")
|
||||
-- Cancel the spell
|
||||
spell:Cancel()
|
||||
else
|
||||
|
||||
Reference in New Issue
Block a user