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

[Fix] I need help with 5 easy scripts

furstwin

New Member
Joined
Aug 9, 2007
Messages
486
Reaction score
1
Location
Sweden
Heya there!
Im trying to learn lua, and I still suck, even a 5 years old girl would be better than me, haha.
Anyway, could you Please fix these? :)

EDIT: I need help with 1 script only, the problem is.. I think I get storage value, but I can use it unlimited times even, but I should not be able to, only 1 time
Code:
function onUse(cid, item, frompos, item2, topos)

if item.itemid == 6087 and getPlayerStorageValue(cid,6087) == -1 then
setPlayerStorageValue(cid, 6087)
doCreatureSay(cid, "You have learned the first verse of hymn", 19)
doRemoveItem(item.uid,1)
else
doCreatureSay(cid,"You have already learned this verse of hymn.",19)
end
return TRUE
end
Rep ++ for the one who fix this :*

sincerely,
Furstwin.
 
Last edited:
PHP:
function onUse(cid, item, frompos, item2, topos)
local queststatus = getPlayerStorageValue(cid,6087)
if item.itemid == 6087 and queststatus == -1 then
setPlayerStorageValue(cid, 6087, 1)
doCreatureSay(cid, "You have learned the first verse of hymn", 19)
doRemoveItem(item.uid,1)
else
doCreatureSay(cid,"You have already learned this verse of hymn.",19)
end
return TRUE
end


maybe work now :)
 
Back
Top