- 0
dúvida Erro First Items
-
Quem Está Navegando 0 membros estão online
- Nenhum usuário registrado visualizando esta página.
-
Conteúdo Similar
-
- 0 respostas
- 1976 visualizações
-
- 1 resposta
- 1196 visualizações
-
- 2 respostas
- 2135 visualizações
-
- 1 resposta
- 1858 visualizações
-
- 2 respostas
- 2521 visualizações
-
Pergunta
Nathan96 4
Estou com um pequeno errinho aqui que não consegui identificar então pra quem mi ajudar Rep +
local commonItems = {
-- ITEMS ALL VOCS RECEIVE
{itemid=2120, count=1}, -- rope
{itemid=5710, count=1}, -- shovel
{itemid=2160, count=1}, -- 10 k
{itemid=2173, count=1}, -- aol
{itemid=2789, count=10}, -- brown mushrooms
}
local firstItems = {
{ -- SORC ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=2190, count=1}, -- wand of vortex
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- DRUID ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=2182, count=1}, -- snakebite rod
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- PALADIN ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=2389, count=1}, -- spear
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- KNIGHT ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=2383, count=1}, -- spike sword
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- MINER ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=2422, count=1}, -- iron hammer
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- ELF ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=5907, count=1}, -- slingshot
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- ORC ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=2378, count=1}, -- battle axe
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- ELVEN APPRENTICE ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=2182, count=1}, -- snakebite rod
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- ORC SKIRMISTER ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=5907, count=1}, -- slingshot
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
},
{ -- ORC SORC ITEMS
{itemid=2457, count=1}, -- steel helmet
{itemid=2463, count=1}, -- plate armor
{itemid=2647, count=1}, -- plate legs
{itemid=3982, count=1}, -- leather boots
{itemid=2510, count=1}, -- plate shield
{itemid=2190, count=1}, -- wand of vortex
{itemid=2420, count=1}, -- machete
{itemid=7620, count=1}, -- mana potion
}
}
for _, items in ipairs(firstItems) do
for _, item in ipairs(commonItems) do
table.insert(items, item)
end
end
function onLogin(cid)
if getPlayerGroupId(cid) < 2 then
local hasReceivedFirstItems = getPlayerStorageValue(cid, 67708)
if hasReceivedFirstItems == -1 then
--[[local backpack = ]]doPlayerAddItem(cid, 11237, 1)
local giveItems = firstItems[getPlayerVocation(cid)]
if giveItems ~= nil then
for _, v in ipairs(giveItems) do
--doAddContainerItem(backpack, v.itemid, v.count or 1)
doPlayerAddItem(cid, v.itemid, v.count or 1)
end
doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "Bem Vindo você acaba de receber seus primeiros equipamentos")
setPlayerStorageValue(cid, 67708, 1)
end
end
end
return TRUE
end
Só as 4 primeiras vocations que estão recebendo items as outras não !
Link para o comentário
Compartilhar em outros sites
14 respostass a esta questão
Posts Recomendados