roriscrave
Advanced OT User
- Joined
- Dec 7, 2011
- Messages
- 1,188
- Solutions
- 34
- Reaction score
- 200
how can i use transform and set itemdecay?
im trying it, i want the new transformed item, have a decay, item(12569).
it transform correct, but get error in decay
im trying it, i want the new transformed item, have a decay, item(12569).
it transform correct, but get error in decay
Lua:
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
if item.itemid == 12568 then
item:transform(item.itemid + 1):decay()
end
return true
end
Code:
Lua Script Error: [Action Interface]
data/actions/scripts/test.lua:onUse
data/actions/scripts/test.lua:3: attempt to index a boolean value
stack traceback:
[C]: in function '__index'
data/actions/scripts/test.lua:3: in function <data/actions/scripts/test.lua:1>