• 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!

[Movement] Teleport Tile Tfs 0.4.0

Knight God

Member
Joined
Oct 19, 2008
Messages
1,180
Reaction score
21
Hello, good afternoon I wonder if you might step on a floor that you ask for money to spend and also teleport you to another point, but if you do not have enough money you teleport to a different location, with a message .
 
local pos = {x=32861, y=32235, z=9} - Where player will be teleported if have money.
local leave = {x=32861, y=32235, z=9} - Where player will be teleported if do not have money.

LUA:
function onStepIn(cid, item, pos)

local pos = {x=32861, y=32235, z=9}
local leave = {x=32861, y=32235, z=9}

    if getPlayerMoney(cid) >= 1000 then
                        doTeleportThing(cid,pos)
doPlayerRemoveMoney(cid,1000)

else
			doPlayerSendCancel(cid, 'You need 1000gps to pass here.')
        end
end


rep++
 
Back
Top