• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Lua TFS 1.0 script does absolutely nothing?

dominique120

Science & Reason
Senator
Premium User
Joined
Jun 16, 2013
Messages
3,881
Solutions
3
Reaction score
1,043
Location
Númenor
I have this script:
Code:
function onUse(cid, item, fromPosition, itemEx, toPosition)
local newposition = {x=847, y=1280, z=9}
    if(item.uid == 10200 and item.itemid == 1409) then
        doSendMagicEffect(fromPosition, 2)
        doTeleportThing(cid, newposition)
        doSendMagicEffect(newposition, 10)
    end
return true
end

Thats supposed to teleport a player when and item on the ground is used, but absolutely nothing happens. The player only gets the "you cant use this item" message and is not teleported.

The itemdID and uid is correct so I dont see how this is not working.
 
Code:
if(item.uid == 10200 and item.itemid == 1409) then
you don't need it, it's checked in actions.xml

if this script is moved from 0.4 replace in actions.xml:
Code:
event="script" value="
to:
Code:
script="
 
Back
Top