Reaper7
dunno wat 2 rite here
- Joined
- Feb 18, 2011
- Messages
- 133
- Reaction score
- 1
Hello!
Today, I want to present you a short script, which teleports player, anywhere you like - position can always be changed, so if you want to play with my short code, I don't really mind, you're welcome to do it.
Ohh! I nearly forgott. I don't know who was first to write a script like that, surely it wasn't me, but I couldn't find any script like that here, so I've just added it. I know that it's easy to write it, but believe me that there are some people which don't know lua and to make something like that, might be for them a disaster.
data/talkactions/scripts/teleport.lua:
data/talkactions/talkactions.xml - Then of course, add this:
Regards,
Reaper7
Today, I want to present you a short script, which teleports player, anywhere you like - position can always be changed, so if you want to play with my short code, I don't really mind, you're welcome to do it.
Ohh! I nearly forgott. I don't know who was first to write a script like that, surely it wasn't me, but I couldn't find any script like that here, so I've just added it. I know that it's easy to write it, but believe me that there are some people which don't know lua and to make something like that, might be for them a disaster.

data/talkactions/scripts/teleport.lua:
Code:
--[[
Script by Reaper7/Elff/xElf
]]--
function onSay(cid, words, param)
if(isPlayerPzLocked(cid) == FALSE) then
doTeleportThing(cid, {x = teleport[param].x, y = teleport[param].y, z = teleport[param].z})
doSendMagicEffect(getCreaturePos(cid), 10)
end
end
data/talkactions/talkactions.xml - Then of course, add this:
Code:
<talkaction words="!teleport" script="teleport.lua"/>
Regards,
Reaper7