here is the code. i got alot of errors in my consol when i make a new character.. why ? :S What's wrong?
Code:
local firstItems = {
2457,
2463,
2525,
2647,
2643
}
local inBackpack = {
2409,
2120,
2429,
2190,
7378,
2394,
2182
}
function onLogin(cid)
if getPlayerStorageValue(cid, 30001) == -1 then
doPlayerAddItem(cid, 2152, 50)
local bag = doPlayerAddItem(cid, 1988, 1)
for i = 1, table.maxn(firstItems) do
doPlayerAddItem(cid, firstItems[i], 1)
end
for i = 1, table.maxn(inBackpack) do
doAddContainerItem(bag, inBackpack[i], 1)
end
setPlayerStorageValue(cid, 30001, 1)
end
return TRUE
end