Ir para conteúdo
  • Cadastre-se

[Resolvido] Como adiciona mais uma vocação nos firstitens?


Posts Recomendados

Eu coloquei mais uma vocação no meu serv chamada Warlord , mais ela não esta vindo com itens ja tentei colocar no firstitens como esta ai abaixo mais não funfo so veio a backpack , como faço para ela tbm vim com itens de kina?

local commonItems = {

-- ITEMS ALL VOCS RECEIVE

{itemid=2120, count=1}, -- rope

{itemid=2789, count=100}, -- brown mushrooms

{itemid=2305, count=1}, -- fire bomb rune

{itemid=2261, count=1}, -- destroy field rune

}

local firstItems = {

{ -- SORC ITEMS

{itemid=2323, count=1}, -- hat of the mad

{itemid=8871, count=1}, -- focus cape

{itemid=7730, count=1}, -- blue legs

{itemid=2195, count=1}, -- boots of haste

{itemid=8902, count=1}, -- spellbook of mind control

{itemid=2187, count=1}, -- wand of inferno

{itemid=2268, count=1}, -- sd

{itemid=2273, count=1}, -- uh

{itemid=7590, count=1}, -- gmp

{itemid=2293, count=1}, -- mw

},

{ -- DRUID ITEMS

{itemid=2323, count=1}, -- hat of the mad

{itemid=8871, count=1}, -- focus cape

{itemid=7730, count=1}, -- blue legs

{itemid=2195, count=1}, -- boots of haste

{itemid=8902, count=1}, -- spellbook of mind control

{itemid=2183, count=1}, -- hailstorm rod

{itemid=2268, count=1}, -- sd

{itemid=2273, count=1}, -- uh

{itemid=7590, count=1}, -- gmp

{itemid=2293, count=1}, -- mw

{itemid=2269, count=1}, -- wg

{itemid=2278, count=1}, -- para

},

{ -- WARLORD ITEMS

{itemid=2493, count=1}, -- demon helmet

{itemid=2472, count=1}, -- magic plate armor

{itemid=2470, count=1}, -- golden legs

{itemid=2195, count=1}, -- boots of haste

{itemid=2514, count=1}, -- mastermind shield

{itemid=2400, count=1}, -- magic sword

{itemid=2431, count=1}, -- Stonecutter Axe

{itemid=7620, count=1}, -- mp

{itemid=8473, count=1}, -- uhp

{itemid=2313, count=1}, -- explosion

{itemid=2293, count=1}, -- mw

},

{ -- PALADIN ITEMS

{itemid=2493, count=1}, -- demon helmet

{itemid=8891, count=1}, -- paladin armor

{itemid=7730, count=1}, -- blue legs

{itemid=2195, count=1}, -- boots of haste

{itemid=2514, count=1}, -- mastermind shield

{itemid=7368, count=10}, -- assassin stars

{itemid=2268, count=1}, -- sd

{itemid=2273, count=1}, -- uh

{itemid=8472, count=1}, -- gsp

{itemid=7589, count=1}, -- smp

{itemid=7588, count=1}, -- shp

{itemid=2293, count=1}, -- mw

},

{ -- KNIGHT ITEMS

{itemid=2493, count=1}, -- demon helmet

{itemid=2472, count=1}, -- magic plate armor

{itemid=2470, count=1}, -- golden legs

{itemid=2195, count=1}, -- boots of haste

{itemid=2514, count=1}, -- mastermind shield

{itemid=2400, count=1}, -- magic sword

{itemid=2431, count=1}, -- Stonecutter Axe

{itemid=7620, count=1}, -- mp

{itemid=8473, count=1}, -- uhp

{itemid=2313, count=1}, -- explosion

{itemid=2293, count=1}, -- mw

}

}

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, 1988, 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, "You have recieved your equipment")

setPlayerStorageValue(cid, 67708, 1)

end

end

end

return TRUE

end

Link para o post
Compartilhar em outros sites


local commonItems = {

	 -- ITEMS ALL VOCS RECEIVE

			 {2120, 1}, -- rope

			 {2789, 100}, -- brown mushrooms

			 {2305, 1}, -- fire bomb rune

			 {2261, 1}, -- destroy field rune

}

local firstItems = {

	 [1] = { -- [VOC 1] SORC ITEMS

			 {2323, 1}, -- hat of the mad

			 {8871, 1}, -- focus cape

			 {7730, 1}, -- blue legs

			 {2195, 1}, -- boots of haste

			 {8902, 1}, -- spellbook of mind control

			 {2187, 1}, -- wand of inferno

			 {2268, 1}, -- sd

			 {2273, 1}, -- uh

			 {7590, 1}, -- gmp

			 {2293, 1}, -- mw

	 },

	 [2] = { -- [VOC 2] DRUID ITEMS

			 {2323, 1}, -- hat of the mad

			 {8871, 1}, -- focus cape

			 {7730, 1}, -- blue legs

			 {2195, 1}, -- boots of haste

			 {8902, 1}, -- spellbook of mind control

			 {2183, 1}, -- hailstorm rod

			 {2268, 1}, -- sd

			 {2273, 1}, -- uh

			 {7590, 1}, -- gmp

			 {2293, 1}, -- mw

			 {2269, 1}, -- wg

			 {2278, 1}, -- para

	 },

	 [3] = { -- [VOC 3] WARLORD ITEMS

			 {2493, 1}, -- demon helmet

			 {2472, 1}, -- magic plate armor

			 {2470, 1}, -- golden legs

			 {2195, 1}, -- boots of haste

			 {2514, 1}, -- mastermind shield

			 {2400, 1}, -- magic sword

			 {2431, 1}, -- Stonecutter Axe

			 {7620, 1}, -- mp

			 {8473, 1}, -- uhp

			 {2313, 1}, -- explosion

			 {2293, 1}, -- mw

	 },

	 [4] = { -- [VOC 4] PALADIN ITEMS

			 {2493, 1}, -- demon helmet

			 {8891, 1}, -- paladin armor

			 {7730, 1}, -- blue legs

			 {2195, 1}, -- boots of haste

			 {2514, 1}, -- mastermind shield

			 {7368, 10}, -- assassin stars

			 {2268, 1}, -- sd

			 {2273, 1}, -- uh

			 {8472, 1}, -- gsp

			 {7589, 1}, -- smp

			 {7588, 1}, -- shp

			 {2293, 1}, -- mw

	 },

	 [5] = { -- [VOC 5] KNIGHT ITEMS

			 {2493, 1}, -- demon helmet

			 {2472, 1}, -- magic plate armor

			 {2470, 1}, -- golden legs

			 {2195, 1}, -- boots of haste

			 {2514, 1}, -- mastermind shield

			 {2400, 1}, -- magic sword

			 {2431, 1}, -- Stonecutter Axe

			 {7620, 1}, -- mp

			 {8473, 1}, -- uhp

			 {2313, 1}, -- explosion

			 {2293, 1}, -- mw

	 }

}

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

					 doPlayerAddItem(cid, 1988, 1)

					 local giveItems = firstItems[getPlayerVocation(cid)]

					 if giveItems then

							 for _, v in ipairs(giveItems) do

									 doPlayerAddItem(cid, v[1], v[2] or 1)

							 end

							 doPlayerSendTextMessage(cid, MESSAGE_STATUS_CONSOLE_ORANGE, "You have recieved your equipment")

							 setPlayerStorageValue(cid, 67708, 1)

					 end

			 end

	 end

	 return true

end

Bro, se liga;

[3] = { -- [VOC 3] WARLORD ITEMS

Só é mudar onde está em vermelho pro id da sua vocação.

-"Supra Omnes Lux Lucis"

- Acima de todos brilha a Luz -

5VGnDyBz.png

Link para o post
Compartilhar em outros sites

Participe da conversa

Você pode postar agora e se cadastrar mais tarde. Se você tem uma conta, faça o login para postar com sua conta.

Visitante
Responder

×   Você colou conteúdo com formatação.   Remover formatação

  Apenas 75 emojis são permitidos.

×   Seu link foi automaticamente incorporado.   Mostrar como link

×   Seu conteúdo anterior foi restaurado.   Limpar o editor

×   Não é possível colar imagens diretamente. Carregar ou inserir imagens do URL.

  • Quem Está Navegando   0 membros estão online

    Nenhum usuário registrado visualizando esta página.

×
×
  • Criar Novo...

Informação Importante

Confirmação de Termo