i was getting a error:
[error - creature event : : configureevent] invalid type for creature event: voc ... failed to configure event
then i change all changehealth for healthchange and i think it worked, can someone help me?
now i'm having this issue when i atk with sd and others ways:
(
http://postimg.org/image/khpkvioc9/)
updating:
i descovery now that the problem r in here (mark with green)
if origin == ORIGIN_MELEE then --checks if damage is done by melee
primaryDamage = primaryDamage
* vocsmulti[attacking:getVocation()].melee
secondaryDamage = secondaryDamage
* vocsmulti[attacking:getVocation()].melee
elseif origin == ORIGIN_RANGED then --checks if damage is done by distance
primaryDamage = primaryDamage
* vocsmulti[attacking:getVocation()].distance
secondaryDamage = secondaryDamage
* vocsmulti[attacking:getVocation()].distance
elseif origin == ORIGIN_SPELL then --checks if damage/healing is done by a spell
if primaryType == COMBAT_HEALING then --checks if healing
primaryDamage = primaryDamage
* vocsmulti[attacking:getVocation()].healing
secondaryDamage = secondaryDamage
* vocsmulti[attacking:getVocation()].healing
else --rest is damage
primaryDamage = primaryDamage
* vocsmulti[attacking:getVocation()].magic
secondaryDamage = secondaryDamage
* vocsmulti[attacking:getVocation()].magic
end
end
seems like it's not getting the right value of:
local vocsmulti = {
[1] = {magic = 1.0 , healing = 1.0, melee = 1, distance = 1}, --sorcerer
[2] = {magic = 1.0 , healing = 1.0, melee = 1, distance = 1}, --druid
[3] = {magic = 1.0 , healing = 1.0, melee = 1, distance = 1}, --paladin
[4] = {magic = 1.0 , healing = 1.0, melee = 1, distance = 1}, --knight
[5] = {magic = 1.0 , healing = 1.0, melee = 1, distance = 1}, --master sorcerer
[6] = {magic = 1.0 , healing = 1.0, melee = 1, distance = 1}, --elder druid
[7] = {magic = 1.0 , healing = 1.0, melee = 1, distance = 1}, --royal paladin
[8] = {magic = 1.0 , healing = 1.0, melee = 1, distance = 1}, --elite knight