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

Lua Help! doAddContainerItem

Status
Not open for further replies.

furstwin

New Member
Joined
Aug 9, 2007
Messages
486
Reaction score
1
Location
Sweden
PHP:
		elseif item.uid == 5004 then
			queststatus = getPlayerStorageValue(cid,30015)
			if queststatus == -1 then
				doPlayerSendTextMessage(cid,22,"You have found a present.")
				doPlayerAddItem(cid,1990,1)
				doAddContainerItem(uid, 2326, 1)
				setPlayerStorageValue(cid,30015,1)
			else
				doPlayerSendTextMessage(cid,22,"It is empty.")
			end

Heres the error.
PHP:
luaDoAddContainerItem<>. Container not found.

Sincerely,
Furstwin.
 
Alright, give me a couple of minutes and I'll have it done for ya.

EDIT: Didn't take as long as I thought it would, but still, here's the script for ya.

Code:
      elseif item.uid == 5004 then
            queststatus = getPlayerStorageValue(cid,30015)
            if queststatus == -1 then
                local container = doPlayerAddItem(1990,1)        
                doPlayerSendTextMessage(cid,22,"You have found a present.")
                doAddContainerItem(container, 2326, 1)
                setPlayerStorageValue(cid,30015,1)
            else
                doPlayerSendTextMessage(cid,22,"It is empty.")
            end
 
Last edited:
Try this:
Code:
      elseif item.uid == 5004 then
            queststatus = getPlayerStorageValue(cid,30015)
            if queststatus == -1 then
                local container = doPlayerAddItem(cid,1990,1)        
                doPlayerSendTextMessage(cid,22,"You have found a present.")
                doAddContainerItem(container,2326,1)
                setPlayerStorageValue(cid,30015,1)
            else
                doPlayerSendTextMessage(cid,22,"It is empty.")
            end
 
Status
Not open for further replies.
Back
Top