• 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!

MoveEvent Demon Helmet Quest

Kedor

New Member
Joined
Mar 3, 2008
Messages
263
Reaction score
0
Location
Poland, Gdynia
Code:
local oldPos = {x = xxx, y = yyy, z = zz} -- teleport position
local newPos = {x = xxx, y = yyy, z = zz} -- position where the player will be teleported

local itemPos = {x = xxx, y = yyy, z = zz, stackpos = STACKPOS_TOP_MOVEABLE_ITEM_OR_CREATURE} -- position where the item need to be
local itemId = xxxx -- item id (the item that need to disapear)

function onStepIn(cid, item, pos)

local getItem = getThingfromPos(itemPos)

    if isPlayer(cid) == TRUE then
        if getItem.itemid == itemId then
            doSendMagicEffect(oldPos, CONST_ME_POFF)
            doTeleportThing(cid, newPos, TRUE)
            doSendMagicEffect(newPos, CONST_ME_TELEPORT)
            doRemoveItem(getItem.uid)
        else
            doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "The teleport isn't activated.")
            doSendMagicEffect(oldPos, CONST_ME_POFF)
        end
    end
    return TRUE
end

Master-M: I moved this post to a new thread to help others ;)
 
Last edited by a moderator:
Kedor you, I was too lazy to make the demon helmet quest in a long time I tried, I used a very old script, I will test your script and give you notice a problem
 
Back
Top