landsandboat/scripts/items/koccos_earring.lua

20 lines
601 B
Lua

-----------------------------------
-- ID: 15998
-- Kocco's Earring
-- This earring functions in the same way as the spell Reraise II.
-----------------------------------
---@type TItem
local itemObject = {}
itemObject.onItemCheck = function(target, item, caster)
return 0
end
itemObject.onItemUse = function(target, user)
local duration = 7200
target:delStatusEffect(xi.effect.RERAISE)
target:addStatusEffect(xi.effect.RERAISE, { power = 2, duration = duration, origin = user })
target:messageBasic(xi.msg.basic.GAINS_EFFECT_OF_STATUS, xi.effect.RERAISE)
end
return itemObject