Hello, i need help with this script, not work, 0 error in console ;c
the script is responsible for the outfit of a given vocation
Lua:
local outfits = {
[20] = {17},
}
function onLogin(player)
local voc = player:getVocation():getId()
if voc > 0 then
for key in pairs(outfits[voc]) do
player:addOutfit(outfits[voc + 1])
end
end
return true
end