Simonalina
Member
hello, im looking for an action Pick script for tfs 1.3 (10.98)
something like
when using pick ID: 2553
If floor is ID: xxx
and has AID: xxx
then transform to ID: xxx
i know there is scripts in my server, but i don't know how to fix it in action/Lib files...
like this code, it says if ground.actionid, <-- but where do i add Action.IDs this in script?
action/scripts/pick.xml
something like
when using pick ID: 2553
If floor is ID: xxx
and has AID: xxx
then transform to ID: xxx
i know there is scripts in my server, but i don't know how to fix it in action/Lib files...
like this code, it says if ground.actionid, <-- but where do i add Action.IDs this in script?
Lua:
if table.contains(groundIds, ground.itemid) and ground.actionid == actionIds.pickHole then
ground:transform(392)
ground:decay()
toPosition:sendMagicEffect(CONST_ME_POFF)
toPosition.z = toPosition.z + 1
tile:relocateTo(toPosition)
end
action/scripts/pick.xml
Code:
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
return onUsePick(player, item, fromPosition, target, toPosition, isHotkey)
end
Code:
<action itemid="2553" script="tools/pick.lua" />