Hi! Any scripter around? I really need to learn how to handle the movements stuff, stepin function and things... But my problem right now are the teleports from inquisition quest.
I Was able to make the teleports that appears after the demon boss dies, however, I need some help with the teleports that go and come from the main room.
At first, the teleports at the main room cant work for the player, only after the person kills the demon boss and come back in the teleport after the respective demon boss, right?
So...
here is what I added in the movements.xml
The script in teleportsgo:
and finally the script for teleportsback:
Well... The server simply crashed ¬¬ when I tried to use one of these teleports. Plus, I couldnt find any tutorial about this one, of how to use setstorage in a teleport and things like that.
Can anyone help me out? I saw that other guy has the same problem, but I wanted to post my codes here, for you people can help me ^^
thx in advance
Neko
I Was able to make the teleports that appears after the demon boss dies, however, I need some help with the teleports that go and come from the main room.
At first, the teleports at the main room cant work for the player, only after the person kills the demon boss and come back in the teleport after the respective demon boss, right?
So...
here is what I added in the movements.xml
Code:
<movement type="StepIn" uniqueid="5210" event="script" value="teleportsback.lua"/>
<movement type="StepIn" uniqueid="5211" event="script" value="teleportsback.lua"/>
<movement type="StepIn" uniqueid="5212" event="script" value="teleportsback.lua"/>
<movement type="StepIn" uniqueid="5213" event="script" value="teleportsback.lua"/>
<movement type="StepIn" uniqueid="5214" event="script" value="teleportsback.lua"/>
<movement type="StepIn" uniqueid="5215" event="script" value="teleportsgo.lua"/>
<movement type="StepIn" uniqueid="5216" event="script" value="teleportsgo.lua"/>
<movement type="StepIn" uniqueid="5217" event="script" value="teleportsgo.lua"/>
<movement type="StepIn" uniqueid="5218" event="script" value="teleportsgo.lua"/>
<movement type="StepIn" uniqueid="5219" event="script" value="teleportsgo.lua"/>
The script in teleportsgo:
Code:
function onStepIn(cid, item, pos)
if item.uid == 5215 then
if getPlayerStorageValue(cid,5210) == 1 then
doTeleportThing(cid,{x=1176, y=1140, z=12})
else
doTeleportThing(cid,{x=1067, y=1081, z=14})
end
elseif item.uid == 5216 then
if getPlayerStorageValue(cid,5211) == 1 then
doTeleportThing(cid,{x=1128, y=1151, z=12})
else
doTeleportThing(cid,{x=1069, y=1083, z=14})
end
elseif item.uid == 5217 then
if getPlayerStorageValue(cid,5212) == 1 then
doTeleportThing(cid,{x=1069, y=1087, z=13})
else
doTeleportThing(cid,{x=1069, y=1087, z=14})
end
elseif item.uid == 5218 then
if getPlayerStorageValue(cid,5213) == 1 then
doTeleportThing(cid,{x=1152, y=1196, z=13})
else
doTeleportThing(cid,{x=1067, y=1089, z=14})
end
elseif item.uid == 5219 then
if getPlayerStorageValue(cid,5214) == 1 then
doTeleportThing(cid,{x=1244, y=1297, z=12})
else
doTeleportThing(cid,{x=1062, y=1089, z=14})
end
end
return 1
end
and finally the script for teleportsback:
Code:
function onStepIn(cid, item, pos)
if item.uid == 5210 then
setPlayerStorageValue(cid,5210,1)
doTeleportThing(cid,{x=1064, y=1085, z=14})
elseif item.uid == 5211 then
setPlayerStorageValue(cid,5211,1)
doTeleportThing(cid,{x=1064, y=1085, z=14})
elseif item.uid == 5212 then
setPlayerStorageValue(cid,5212,1)
doTeleportThing(cid,{x=1064, y=1085, z=14})
elseif item.uid == 5213 then
setPlayerStorageValue(cid,5213,1)
doTeleportThing(cid,{x=1064, y=1085, z=14})
elseif item.uid == 5214 then
setPlayerStorageValue(cid,5214,1)
doTeleportThing(cid,{x=1064, y=1085, z=14})
end
return 1
end
Well... The server simply crashed ¬¬ when I tried to use one of these teleports. Plus, I couldnt find any tutorial about this one, of how to use setstorage in a teleport and things like that.
Can anyone help me out? I saw that other guy has the same problem, but I wanted to post my codes here, for you people can help me ^^
thx in advance
Neko