• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

KillQuest bug.

bybbzan

mapper
Joined
Aug 4, 2012
Messages
809
Solutions
2
Reaction score
136
Location
Sweden
Hello! I need quick help with this problem.
It doesnt matter who walks on the teleport, it still sais "You have already done this quest".
What do i need to change?

Code:
pos = {x=1468, y=853, z=7} --- Position monster summon
function onStepIn(cid, item, position, fromPosition)
    local newPosition = {x=1468, y=847, z=7} --- new position
    local noPosition = {x=1469, y=858, z=8} --- no position
        if(getGlobalStorageValue(7778) < 1) and (getPlayerStorageValue(cid, 7778) == EMPTY_STORAGE) then
              doTeleportThing(cid, newPosition, TRUE)
            doSummonCreature("Dragonator", getClosestFreeTile(cid, pos))
            doPlayerSendTextMessage(cid,18,'You need to kill the boss.')
            setGlobalStorageValue(7779, 1)

        else
            doTeleportThing(cid, noPosition, TRUE)
            doPlayerSendTextMessage(cid,18,'You have already done this quest.')
    end
return true
end

Thanks.
 
Code:
(getPlayerStorageValue(cid, 7778) == EMPTY_STORAGE)
EMPTY_STORAGE might be nil, check libs or try to put there -1.

Code:
setGlobalStorageValue(7779, 1)
You know that if you don't change it back to be lesser than 1, it will block boss for everyone, right?
 
Code:
(getPlayerStorageValue(cid, 7778) == EMPTY_STORAGE)
EMPTY_STORAGE might be nil, check libs or try to put there -1.

Code:
setGlobalStorageValue(7779, 1)
You know that if you don't change it back to be lesser than 1, it will block boss for everyone, right?

I dont know anything about scripting, so no, i did not now about that lesser than 1 thing.
Can you change what needs to be changed so i can test it? :)
 
i have a question!
did you want a reason to enter the teleport or anyone can enter ?
please explain

Well its a quest so everyone may enter. BUT just one player at the time. You may not be more than 1 player in the room.

Bump, please tell me how to do.
 
Last edited by a moderator:
Back
Top