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

Windows NEW Quest Help =/ (Rep++)

Teddy

SweStream.se
Joined
Oct 2, 2008
Messages
3,797
Reaction score
10
Location
Sweden 172
Woho Fixed it But 1 problem when i loot in a chest this come
13:56 You have found a chest.
But i get my item like fire sword , beholder shield and that , i also get a error in console every time i loot in a quest chest
Code:
[25/02/2009 13:56:52] Lua Script Error: [Action Interface] 
[25/02/2009 13:56:52] data/actions/scripts/quests/quests.lua:onUse

[25/02/2009 13:56:52] luaGetItemWeight(). Item not found
Here is mine action add for quests.lua
<action itemid="1740" script="quests/quests.lua"/>
<action fromid="1747" toid="1749" script="quests/quests.lua"/>
and here is the quests.lua file
Code:
local annihilatorReward = {1990, 2400, 2431, 2494}
function onUse(cid, item, fromPosition, itemEx, toPosition)
	if item.uid > 1000 and item.uid < 10000 then
		local itemWeight = getItemWeight(item.uid, 1, FALSE)
		local playerCap = getPlayerFreeCap(cid)
		if isInArray(annihilatorReward, item.uid) == TRUE then
			if getPlayerStorageValue(cid, 30015) == -1 then
				if playerCap >= itemWeight then
					if item.uid == 1990 then
						local container = doPlayerAddItem(cid, 1990, 1)
						doAddContainerItem(container, 2326, 1)
					else
						doPlayerAddItem(cid, item.uid, 1)
					end
					doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemName(item.uid) .. '.')
					setPlayerStorageValue(cid, 30015, 1)
				else
					doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemName(item.uid) .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
				end
			else
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "It is empty.")
			end
		elseif getPlayerStorageValue(cid, item.uid) == -1 then
			if playerCap >= itemWeight then
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemName(item.uid) .. '.')
				doPlayerAddItem(cid, item.uid, 1)
				setPlayerStorageValue(cid, item.uid, 1)
			else
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemName(item.uid) .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
			end
		else
			doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "It is empty.")
		end
	else
		return FALSE
	end
	return TRUE
end

IMAGE
[http://img90.imageshack.us/img90/3530/stormotland.jpg]

Same Problem Whit all my quest box...
stormotland.jpg
 
Last edited:
If you really want to use the old version (which in this case I guess you really do) simply go back into your old actions folder and take the quests.lua from the quests folder and put it in your new one. ;) After that they should all work again.
 
08:15 You see a chest (Vol:15).
ItemID: [1748].
ActionID: [2518].
UniqueID: [2518].

Position: [X: 112] [Y: 352] [Z: 7].
but when i open it is a beholder shield in it .. not like a quest
and i can move around the chest but i cant stand on it
 
Woho Fixed it But 1 problem when i loot in a chest this come
13:56 You have found a chest.
But i get my item like fire sword , beholder shield and that , i also get a error in console every time i loot in a quest chest
Code:
[25/02/2009 13:56:52] Lua Script Error: [Action Interface] 
[25/02/2009 13:56:52] data/actions/scripts/quests/quests.lua:onUse

[25/02/2009 13:56:52] luaGetItemWeight(). Item not found
Here is mine action add for quests.lua
<action itemid="1740" script="quests/quests.lua"/>
<action fromid="1747" toid="1749" script="quests/quests.lua"/>
and here is the quests.lua file
Code:
local annihilatorReward = {1990, 2400, 2431, 2494}
function onUse(cid, item, fromPosition, itemEx, toPosition)
	if item.uid > 1000 and item.uid < 10000 then
		local itemWeight = getItemWeight(item.uid, 1, FALSE)
		local playerCap = getPlayerFreeCap(cid)
		if isInArray(annihilatorReward, item.uid) == TRUE then
			if getPlayerStorageValue(cid, 30015) == -1 then
				if playerCap >= itemWeight then
					if item.uid == 1990 then
						local container = doPlayerAddItem(cid, 1990, 1)
						doAddContainerItem(container, 2326, 1)
					else
						doPlayerAddItem(cid, item.uid, 1)
					end
					doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemName(item.uid) .. '.')
					setPlayerStorageValue(cid, 30015, 1)
				else
					doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemName(item.uid) .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
				end
			else
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "It is empty.")
			end
		elseif getPlayerStorageValue(cid, item.uid) == -1 then
			if playerCap >= itemWeight then
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemName(item.uid) .. '.')
				doPlayerAddItem(cid, item.uid, 1)
				setPlayerStorageValue(cid, item.uid, 1)
			else
				doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, 'You have found a ' .. getItemName(item.uid) .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
			end
		else
			doPlayerSendTextMessage(cid, MESSAGE_INFO_DESCR, "It is empty.")
		end
	else
		return FALSE
	end
	return TRUE
end

IMAGE
[http://img90.imageshack.us/img90/3530/stormotland.jpg]

Same Problem Whit all my quest box...
stormotland.jpg
 
Last edited:
Back
Top