Advertisement
poxipox

Untitled

Dec 30th, 2023
1,069
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 0.62 KB | None | 0 0
  1.             door = function(cid, toPosition, creatPos)
  2.                     print'1'
  3.                     if toPosition.y-1 == creatPos.y then -- exit
  4.                         doTeleportThing(cid, {x=toPosition.x, y=toPosition.y+1, z=toPosition.z}, false)
  5.                         return true
  6.                     end
  7.                     print'2'
  8.                     if exhaustion.check(cid, 19000) then
  9.                         doSendMagicEffect(getPlayerPosition(cid), CONST_ME_POFF)
  10.                         doPlayerSendCancel(cid, "You are exhausted.")
  11.                         return true
  12.                     end  
  13.                     print'3'
  14.                     doTeleportThing(cid, {x=toPosition.x, y=toPosition.y-1, z=toPosition.z}, false)
  15.                     local time = 10
  16.                     exhaustion.set(cid, 19000, time)
  17.                 end
  18.                 },
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement