• 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!
  • 2026 staff recruitment is open! Check it out and consider applying!

Quest chest not working

tnecniiv

scripter to be
Joined
Jan 6, 2012
Messages
298
Solutions
3
Reaction score
25
I made a quest chest with action id 2000 and uniqueid being the random number it makes the chest inmoveable but it does not give me the chest items help would be nice =)
 
Action id shouldnt be 2000 I believe. Leave it 0, or if you want a level requirement, make it "1050" - for level 50.

Code:
Level 100 - "1100"
Level 150 - "1150"

And so on
 
If this doesn't work, try using an action script for the chest. That kind of "reward chest" scripts are not hard to write. Try this one:

Code:
function onUse(cid, item, frompos, item2, topos)

local storageForQuest = 20000 -- enter an unused storage number here
local item1 = 1000 -- enter ID of reward #1 here
local item2 = 1000 -- enter ID of reward #2 here

        if getCreatureStorage(cid, storageForQuest) <= 0 then
            doPlayerAddItem(cid, item1)
            doPlayerAddItem(cid, item2)
            doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "You have obtained a reward from the chest.")
            doSendMagicEffect(getCreaturePosition(cid), 12)
            setPlayerStorageValue(cid, storageForQuest, 1)
        else
            doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "The chest is empty.")
            doSendMagicEffect(getCreaturePosition(cid), 2)
        end

end
 
The aid 2000 works only for 0.3/0.4. Limos made a script for 0.2.x but I dont remember where it is, you could probably use the one Zbizu made as well. They are here on OTLand.
 
uvIB6pn.jpg

i made this chest work way before before i stopped working on my server now that i am back it wont let me create other chest...
 
i replied in there
but i get this error
1/2014 10:00:33] Warning: [Event::checkScript] Can not load script. /scripts/quests/system.lua
[29/01/2014 10:00:33] data/actions/scripts/quests/system.lua:96: 'end' expected (to close 'function' at line 9) near '<eof>'
 
Back
Top