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

teleport storage

darkedo

New Member
Joined
Aug 6, 2022
Messages
14
Reaction score
3
hello
please if someone can i need script that if i have storage x i cant enter this teleport again, he can never enter this tp if he got x storage
 
please if someone can i need script that if i have storage x i cant enter this teleport again, he can never enter this tp if he got x storage
Type more details man, like TFS version and this stuffs. But here, for old TFS (0.X or OTX) u can use a movement like this:

LUA:
function onStepIn(cid, item, pos, fromPos)
  if not isPlayer(cid) then return doTeleportThing(cid, fromPos) end

  if getPlayerStorageValue(cid, VALUE) > 0 then
    doPlayerSendTextMessage(cid, MESSAGE_EVENT_DEFAULT, "You cannot jump in here!")
    doTeleportThing(cid, fromPos)
    return false
  end

  local position = {x = 343, y = 155, z = 7} -- position player teleported
  doTeleportThing(cid, position)
  doSendMagicEffect(position, CONST_ME_TELEPORT)
  doPlayerSendTextMessage(cid, MESSAGE_EVENT_DEFAULT,"Welcome to this area!")
  return true
end

Remember to change "VALUE" for your desired storage.
Post automatically merged:

Before i forgot, remember to put an actionid in this tp in map editor, and put on movements.xml

XML:
    <movevent event="StepIn" actionid="2424" script="script_name.lua"/>
 
Last edited:
Back
Top