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

Quest addon - Chest

mamon_2

Banned User
Joined
Jul 2, 2007
Messages
424
Reaction score
0
Hi people, someone knows how to make a script with an action.id that if you use it, it gives your for example a first nobleman addon?

I would really apreciate it, thanks.
 
PHP:
function onUse(cid, item, fromPosition, itemEx, toPosition)
    
    -- Your quest
    myQuest = 66666     -- Storage Value
    itemID  = 1337        -- Item ID
    if item.actionid == myQuest then
    queststatus = getPlayerStorageValue(cid,myQuest)
    if queststatus == -1 then
        doPlayerSendTextMessage(cid,22,"You have found an item.")
        doPlayerAddItem(cid,itemID,1)
        doSendMagicEffect(getCreaturePosition(cid), 13)
        doPlayerAddOutfit(cid, 251, 1) -- Norseman addon (male)
        doPlayerAddOutfit(cid, 252, 1) -- Norseman addon (female)
        setPlayerStorageValue(cid,myQuest,1)
    else
        doPlayerSendTextMessage(cid,22,"It is empty.")
    end
    end
end
This should do it, but remember you need to edit some minor things in the script, for example the storage value (unless you want that particilar value), the item id, the text message etc.

Good luck pal!
 
Back
Top