Skip to content

Commit

Permalink
[Summon Creature] change creature:hasFlag to player:hasFlag (#628)
Browse files Browse the repository at this point in the history
The way it was the script was not working and presented error. Changing to player:hasFlag works correctly
  • Loading branch information
igorlabanca authored Nov 19, 2022
1 parent 6c924eb commit 0d6511c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions data-canary/scripts/spells/summon/summon_creature.lua
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ function spell.onCastSpell(player, variant)
return false
end

if not creature:hasFlag(PlayerFlag_CanSummonAll) then
if not player:hasFlag(PlayerFlag_CanSummonAll) then
if not monsterType:isSummonable() then
player:sendCancelMessage(RETURNVALUE_NOTPOSSIBLE)
position:sendMagicEffect(CONST_ME_POFF)
Expand Down Expand Up @@ -56,4 +56,4 @@ spell:cooldown(2 * 1000)
spell:groupCooldown(2 * 1000)
spell:needLearn(false)
spell:vocation("druid;true", "sorcerer;true", "elder druid;true", "master sorcerer;true")
spell:register()
spell:register()

0 comments on commit 0d6511c

Please sign in to comment.