Lua Script Error: [Scripts Interface]next time use request please mate
local config = {
[ITEMID] = {id = OUTFITID},
[ITEMID] = {id = OUTFITID}
}
local addOutfit = Action()
function addOutfit.onUse(player, item, fromPosition, target, toPosition, isHotkey)
local outfita = config[item.itemid]
if outfita then
if player:hasOutfit(outfita.id) then
player:sendCancelMessage("You alredy have this outift.")
return true
end
player:addOutfitAddon(outfita.id, 3)
end
end
addOutfit:aid(5251)
addOutfit:register()
keep in mind u must regirst the item with actionId 5251
@moderator I canno't use the buttons for lua or anything else..
addongive.lua [error]
When i done that , nothings happens.Lua Script Error: [Scripts Interface]
/ots/data/scripts/addongive.lua
/ots/data/scripts/addongive.lua:3: table index is nil
stack traceback:
[C]: in function '__newindex'
ots/data/scripts/addongive.lua:3: in main chunk
ok i just have to put IDs, to work, but can i use it on any 'statue' for example? right now just putting actionID?
He wanted npc not an itemnext time use request please mate
local config = {
[ITEMID] = {id = OUTFITID},
[ITEMID] = {id = OUTFITID}
}
local addOutfit = Action()
function addOutfit.onUse(player, item, fromPosition, target, toPosition, isHotkey)
local outfita = config[item.itemid]
if outfita then
if player:hasOutfit(outfita.id) then
player:sendCancelMessage("You alredy have this outift.")
return true
end
player:addOutfitAddon(outfita.id, 3)
end
end
addOutfit:aid(5251)
addOutfit:register()
keep in mind u must regirst the item with actionId 5251
@moderator I canno't use the buttons for lua or anything else..
it could be an item, even better if it will be 'statue' I tried to put actionID 5251 on statue and scrit doesnt works,, (no error)He wanted npc not an item
ohhHe wanted npc not an item
np, but how can i use it by 'clicl on use' on statue for example, when i put actionid on statue it does nothinohh
my fault
right, the best if it will be as easy as this one up, give me items xxx(can u make more than 1 item, like 10items (same one, for example 10x token) recived addon xxx THANK YOU!so
you want to use a statue as example which has actionID = 200 and it should give you a addon?
any chance for ur help?so
you want to use a statue as example which has actionID = 200 and it should give you a addon?
1st, thanks for answers, 2nd, i want one statue that will can give lot of outfits, for example when we have 'apple' in backpack it will give me full citizen, if i will have 'banana' full hunter Or is it to hard to make?I would help you if you would be clear what you want.
you ask always different stuff
so as example
if statue gets actionID 2000 then he should receive citizien outfit
if statue gets actionID 2001 then he should receive hunter outfit
like this???