• 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 This Item..

Teddy

SweStream.se
Joined
Oct 2, 2008
Messages
3,797
Reaction score
10
Location
Sweden 172
I have a new item here but it never go away ?
Code:
function onUse(cid, mount, namemount)

local storage = 61337

        if getPlayerStorageValue(cid,storage) == -1 then
                setPlayerStorageValue(cid,storage, 1)
                doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR,"Now you can use noob mount!!")
                doPlayerAddMount(cid, 4)
        else
                doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR,"You already have this mount!")
                end
        return TRUE
end
 
LUA:
local storage = 61337
function onUse(cid, item, mount, namemount)
if getPlayerStorageValue(cid,storage) == -1 then
   setPlayerStorageValue(cid,storage, 1)
   doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR,"Now you can use noob mount!!")
   doPlayerAddMount(cid, 4)
   doRemoveItem(item.uid, 1)
else
    doPlayerSendTextMessage(cid,MESSAGE_INFO_DESCR,"You already have this mount!")
end
return TRUE
end
 
Last edited:
[23:18:18.701] [Error - Action Interface]
[23:18:18.701] data/actions/scripts/mount.lua:onUse
[23:18:18.701] Description:
[23:18:18.701] data/actions/scripts/mount.lua:7: attempt to index global 'item'
(a nil value)
[23:18:18.701] stack traceback:
[23:18:18.701] data/actions/scripts/mount.lua:7: in function <data/actions/scri
pts/mount.lua:2>
Error
 
Back
Top