jwthbb
New Member
- Joined
- Apr 22, 2013
- Messages
- 37
- Reaction score
- 0
i have searched everywhere on this forum for quests. but i cant fix it.
i know that action id need to be 2000.
unique id is? everyone says its 32000etc but when i type that. it just opens nothing more. it doesnt give me anything. when i look in script quest. it says this
local annihilatorReward = {1990, 2400, 2431, 2494}
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
if item.uid <= 1250 or item.uid >= 30000 then
return false
end
local itemType = ItemType(item.uid)
if itemType:getId() == 0 then
return false
end
local itemWeight = itemType:getWeight()
local playerCap = player:getFreeCapacity()
if isInArray(annihilatorReward, item.uid) then
if player:getStorageValue(30015) == -1 then
if playerCap >= itemWeight then
if item.uid == 1990 then
player:addItem(1990, 1):addItem(2326, 1)
else
player:addItem(item.uid, 1)
end
player:sendTextMessage(MESSAGE_INFO_DESCR, 'You have found a ' .. itemType:getName() .. '.')
player:setStorageValue(30015, 1)
else
player:sendTextMessage(MESSAGE_INFO_DESCR, 'You have found a ' .. itemType:getName() .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
end
else
player:sendTextMessage(MESSAGE_INFO_DESCR, "It is empty.")
end
elseif player:getStorageValue(item.uid) == -1 then
if playerCap >= itemWeight then
player:sendTextMessage(MESSAGE_INFO_DESCR, 'You have found a ' .. itemType:getName() .. '.')
player:addItem(item.uid, 1)
player:setStorageValue(item.uid, 1)
else
player:sendTextMessage(MESSAGE_INFO_DESCR, 'You have found a ' .. itemType:getName() .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
end
else
player:sendTextMessage(MESSAGE_INFO_DESCR, "It is empty.")
end
return true
end
please help me. cant figure this shit out
i know that action id need to be 2000.
unique id is? everyone says its 32000etc but when i type that. it just opens nothing more. it doesnt give me anything. when i look in script quest. it says this
local annihilatorReward = {1990, 2400, 2431, 2494}
function onUse(player, item, fromPosition, target, toPosition, isHotkey)
if item.uid <= 1250 or item.uid >= 30000 then
return false
end
local itemType = ItemType(item.uid)
if itemType:getId() == 0 then
return false
end
local itemWeight = itemType:getWeight()
local playerCap = player:getFreeCapacity()
if isInArray(annihilatorReward, item.uid) then
if player:getStorageValue(30015) == -1 then
if playerCap >= itemWeight then
if item.uid == 1990 then
player:addItem(1990, 1):addItem(2326, 1)
else
player:addItem(item.uid, 1)
end
player:sendTextMessage(MESSAGE_INFO_DESCR, 'You have found a ' .. itemType:getName() .. '.')
player:setStorageValue(30015, 1)
else
player:sendTextMessage(MESSAGE_INFO_DESCR, 'You have found a ' .. itemType:getName() .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
end
else
player:sendTextMessage(MESSAGE_INFO_DESCR, "It is empty.")
end
elseif player:getStorageValue(item.uid) == -1 then
if playerCap >= itemWeight then
player:sendTextMessage(MESSAGE_INFO_DESCR, 'You have found a ' .. itemType:getName() .. '.')
player:addItem(item.uid, 1)
player:setStorageValue(item.uid, 1)
else
player:sendTextMessage(MESSAGE_INFO_DESCR, 'You have found a ' .. itemType:getName() .. ' weighing ' .. itemWeight .. ' oz it\'s too heavy.')
end
else
player:sendTextMessage(MESSAGE_INFO_DESCR, "It is empty.")
end
return true
end
please help me. cant figure this shit out