nevix
Tunzodus.net
Hello, I present pretty usefull tool.
You can travel whatever you want
Creature scripts:
create folder "my scripts" and homeme.lua file
talkactions:
You can travel whatever you want
Creature scripts:
Code:
<event type="modalwindow" name="Destination" script="my scripts/homeme.lua"/>
create folder "my scripts" and homeme.lua file
Code:
function onModalWindow(cid, modalWindowId, buttonId, choiceId)
if modalWindowId == 2 then
local player = Player(cid)
local thais = {x = 32345, y = 32223, z = 7}
local carlin = {x = 32336, y = 31784, z = 7}
local edron = {x = 33172, y = 31766, z = 6}
local ab = {x = 32735, y = 31668, z = 6}
local venore = {x = 32952, y = 32024, z = 6}
local ah = {x = 33089, y = 32884, z = 6}
if buttonId == 2 then
return false
else
if choiceId == 1 then
player:teleportTo(thais)
return true
end
if choiceId == 2 then
player:teleportTo(carlin)
return true
end
if choiceId == 3 then
player:teleportTo(venore)
return true
end
if choiceId == 4 then
player:teleportTo(ab)
return true
end
if choiceId == 5 then
player:teleportTo(ah)
return true
end
if choiceId == 6 then
player:teleportTo(edron)
return true
end
end
end
end
Code:
player:registerEvent("Destination")
talkactions:
Code:
<talkaction words="/home" script="my scripts/homeme.lua" />
Code:
function onSay(cid, words, param)
local player = Player(cid)
local Destination = ModalWindow(2, "Destination", "Make your choice:")
Destination:addChoice(1, "1. Thais")
Destination:addChoice(2, "2. Carlin")
Destination:addChoice(3, "3. Venore")
Destination:addChoice(4, "4. Ab'dendriel")
Destination:addChoice(5, "5. Ankrahmun")
Destination:addChoice(6, "6. Edron")
Destination:addButton(1, 'Go')
Destination:addButton(2, 'Exit')
Destination:sendToPlayer(player)
return false
end