port for tfs 1.3 plz
Code:
local min, max = 15000000,15000000 --Ataque mínimo e ataque máximo
local w = {
[1] = {ef = 46, sh = 29, dmg = COMBAT_POISONDAMAGE},
}
function onUseWeapon(cid, var)
local effect = getPlayerStorageValue(cid, 4561)
local target = getCreatureTarget(cid)
if target ~= 0 then
local wx = w[effect] or w[math.random(#w)]
doSendDistanceShoot(getThingPos(cid), getThingPos(target), wx.sh)
addEvent(doAreaCombatHealth, 100, cid, wx.dmg, getThingPos(target), 0, -min, -max, wx.ef)
end
return true
end