Postado Dezembro 31, 2016 8 anos Alguem poderia me ajudar a arrumar a script? quero que a transform level 600 precise de uma storage para ser usada algem pode ajudar?! ---if (voc[1]<600) and getPlayerStorageValue(cid,99023) >= 1 then // tentei usar esse mais nao deu certo. local config = { --[vocation id] = { level, nova voc, looktype, efeito} [675] = { 100, 676, 826, 121}, [676] = { 200, 677, 827, 121}, [678] = { 100, 679, 829, 121}, [679] = { 200, 680, 830, 121}, [680] = { 400, 681, 831, 121}, [681] = { 600, 682, 834, 121}, } function onSay(cid, words, param, channel) local voc = config[getPlayerVocation(cid)] if voc then ---if (voc[1]<600) and getPlayerStorageValue(cid,99023) >= 1 then if getPlayerLevel(cid) >= voc[1] then doPlayerSetVocation(cid, voc[2]) doCreatureSay(cid, "Sinta meu Poder, Evoluir!!!!", 19) local outfit = {lookType = voc[3]} doCreatureChangeOutfit(cid, outfit) doSendMagicEffect(getCreaturePosition(cid), voc[4]) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Voce precisa estar no level " .. voc[1] .. " para transformar.") end else doPlayerSendCancel(cid, "Voce ja esta na ultima transformação.") end return true end @Vodkart
Postado Janeiro 1, 2017 8 anos Solução local config = { --[vocation id] = { level, nova voc, looktype, efeito} [675] = {100, 676, 826, 121}, [676] = {200, 677, 827, 121}, [678] = {100, 679, 829, 121}, [679] = {200, 680, 830, 121}, [680] = {400, 681, 831, 121}, [681] = {600, 682, 834, 121} } function onSay(cid, words, param, channel) local voc = config[getPlayerVocation(cid)] if voc then if getPlayerLevel(cid) >= voc[1] then if voc[1] == 600 and getPlayerStorageValue(cid,99023) <= 0 then doPlayerSendCancel(cid, "desculpa mas precisa da storage.") return true end doPlayerSetVocation(cid, voc[2]) doCreatureSay(cid, "Sinta meu Poder, Evoluir!!!!", 19) local outfit = {lookType = voc[3]} doCreatureChangeOutfit(cid, outfit) doSendMagicEffect(getCreaturePosition(cid), voc[4]) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Voce precisa estar no level " .. voc[1] .. " para transformar.") end else doPlayerSendCancel(cid, "Voce ja esta na ultima transformação.") end return true end [*Ninguém será digno do sucesso se não usar suas derrotas para conquistá-lo.*] DISCORD: vodkart#6090
Postado Janeiro 1, 2017 8 anos Autor Em 01/01/2017 em 19:44, Vodkart disse: local config = { --[vocation id] = { level, nova voc, looktype, efeito} [675] = {100, 676, 826, 121}, [676] = {200, 677, 827, 121}, [678] = {100, 679, 829, 121}, [679] = {200, 680, 830, 121}, [680] = {400, 681, 831, 121}, [681] = {600, 682, 834, 121} } function onSay(cid, words, param, channel) local voc = config[getPlayerVocation(cid)] if voc then if getPlayerLevel(cid) >= voc[1] then if voc[1] == 600 and getPlayerStorageValue(cid,99023) <= 0 then doPlayerSendCancel(cid, "desculpa mas precisa da storage.") return true end doPlayerSetVocation(cid, voc[2]) doCreatureSay(cid, "Sinta meu Poder, Evoluir!!!!", 19) local outfit = {lookType = voc[3]} doCreatureChangeOutfit(cid, outfit) doSendMagicEffect(getCreaturePosition(cid), voc[4]) else doPlayerSendTextMessage(cid, MESSAGE_STATUS_WARNING, "Voce precisa estar no level " .. voc[1] .. " para transformar.") end else doPlayerSendCancel(cid, "Voce ja esta na ultima transformação.") end return true end Obrigado @Vodkart voce faz do tibiaking uma comunidade melhor.
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.