landsandboat/scripts/items/samurai_die.lua
claywar 6e4fa2af25
[type] Add type annotations to Item scripts
rename to reflect type definition

Annotate xi.itemUtils.foodOnItemCheck

Make TItemFood functions optional, since the definition does not include types
2024-08-24 18:25:26 -04:00

17 lines
427 B
Lua

-----------------------------------
-- ID: 5488
-- Samurai Die
-- Teaches the job ability Samurai Roll
-----------------------------------
---@type TItem
local itemObject = {}
itemObject.onItemCheck = function(target, item, param, caster)
return target:canLearnAbility(xi.jobAbility.SAMURAI_ROLL)
end
itemObject.onItemUse = function(target)
target:addLearnedAbility(xi.jobAbility.SAMURAI_ROLL)
end
return itemObject