Ok im back again lol umm here is my script i got ive just made a new quest and at the end is 6 new weapon items BUT i only want a person to get 1 reward not the whole 6 ok so here is my script i done it work but the player can get all 6 rewards and not 1 so here it is
data\actions\scripts\quests
and in data\actions
actions.xml
can any1 help me please ????? or wat have i done wrong?
oh with my quest if it helps lol i got a gate of expertise of lvl 250 uid == 1250 if that helps at all hehe.
Im not getting any errors at all i just want the players to get 1 reward per character ...
data\actions\scripts\quests
Lua:
-- hells weapons -- Made By Wishy
function onUse(cid, item, frompos, item2, topos)
if item.uid == 2211 then
queststatus = getPlayerStorageValue(cid,2211)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a hells rod.")
doPlayerAddItem(cid,7735,1)
setPlayerStorageValue(cid,2211,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
end
if item.uid == 2222 then
queststatus = getPlayerStorageValue(cid,2222)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a hells wand.")
doPlayerAddItem(cid,7735,1)
setPlayerStorageValue(cid,2222,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
end
if item.uid == 2233 then
queststatus = getPlayerStorageValue(cid,2233)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a hells club.")
doPlayerAddItem(cid,7735,1)
setPlayerStorageValue(cid,2233,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
end
if item.uid == 2244 then
queststatus = getPlayerStorageValue(cid,2244)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a hells axe.")
doPlayerAddItem(cid,7735,1)
setPlayerStorageValue(cid,2244,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
end
if item.uid == 2255 then
queststatus = getPlayerStorageValue(cid,2255)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a hells sword.")
doPlayerAddItem(cid,7735,1)
setPlayerStorageValue(cid,2255,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
end
if item.uid == 2266 then
queststatus = getPlayerStorageValue(cid,2266)
if queststatus == -1 then
doPlayerSendTextMessage(cid,22,"You have found a hells slingshot.")
doPlayerAddItem(cid,7735,1)
setPlayerStorageValue(cid,2266,1)
else
doPlayerSendTextMessage(cid,22,"It is empty.")
end
else
return 0
end
return 1
end
and in data\actions
actions.xml
Lua:
<action uniqueid="2211" event="script" value="quests/hells weapons.lua"/>
<action uniqueid="2222" event="script" value="quests/hells weapons.lua"/>
<action uniqueid="2233" event="script" value="quests/hells weapons.lua"/>
<action uniqueid="2244" event="script" value="quests/hells weapons.lua"/>
<action uniqueid="2255" event="script" value="quests/hells weapons.lua"/>
<action uniqueid="2266" event="script" value="quests/hells weapons.lua"/>
can any1 help me please ????? or wat have i done wrong?
oh with my quest if it helps lol i got a gate of expertise of lvl 250 uid == 1250 if that helps at all hehe.
Im not getting any errors at all i just want the players to get 1 reward per character ...
Last edited by a moderator: