Hello.
I'm trying to create a complete working server with latest content possible. I'm total rookie in terms of coding, so I'm basically learning while working on this project. If you want to contribute PM me. I'm not making server for money, actually I'm not gonna set up server for players, just share it for free on github etc.
However, let's go to the topic.
I'm getting this error:
while trying to make movevent.
This is the script:
I know it's total disaster, but this should at least work properly. Basically, it's script for Dawnport vocation rooms. After you get level 8, you talk to Oressa and get your vocation, you can proceed to the one of the room depending on you voc (this is actually script for knight). So there is one tile that should tp you back if you don't meet the requirements: getting 8 lvl, talking to Oressa (storage 263267 should have 1 value then), and you can't go back once you went into the room (storage 263267 should have value 2 then).
Sorry for the mess, but I really count on you, if you can help me.
I will tell you anything you need to know.
Thanks.
Also if you know how to make it simplier (maybe using storages for it is not the best idea) share your proposition!
I'm trying to create a complete working server with latest content possible. I'm total rookie in terms of coding, so I'm basically learning while working on this project. If you want to contribute PM me. I'm not making server for money, actually I'm not gonna set up server for players, just share it for free on github etc.
However, let's go to the topic.
I'm getting this error:
Code:
Event onStepIn not found
This is the script:
Lua:
function onUse(cid, item, frompos, item2, topos)
local player = Player(cid)
local failPos = Position(32068, 31887, 6)
local failPos2 = Position(32068, 31884, 6)
if player:getLevel() < 8 then
player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "You need to reach at least 8 level to proceed.")
player:teleportTo(failPos)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
elseif player:getVocation():getId() ~= 4 then
player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "You need to be Knight to proceed.")
player:teleportTo(failPos)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
elseif player:getStorageValue(263267 == -1) then
player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "Talk to Oressa first.")
player:teleportTo(failPos)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
elseif player:getStorageValue(2632637 == 2) then
player:teleportTo(failPos2)
player:getPosition():sendMagicEffect(CONST_ME_TELEPORT)
player:sendTextMessage(MESSAGE_EVENT_ADVANCE, "You can't go back now.")
else
player:setStorageValue(263267, 2)
end
end
I know it's total disaster, but this should at least work properly. Basically, it's script for Dawnport vocation rooms. After you get level 8, you talk to Oressa and get your vocation, you can proceed to the one of the room depending on you voc (this is actually script for knight). So there is one tile that should tp you back if you don't meet the requirements: getting 8 lvl, talking to Oressa (storage 263267 should have 1 value then), and you can't go back once you went into the room (storage 263267 should have value 2 then).
Sorry for the mess, but I really count on you, if you can help me.
I will tell you anything you need to know.
Thanks.
Also if you know how to make it simplier (maybe using storages for it is not the best idea) share your proposition!