Ir para conteúdo
  • 0

Ajuda Com Talkaction?


galaverna

Pergunta

ola eu tenho esta talkaction

function onSay(cid, words, param, var)
local pos = getPlayerPosition(cid)

if (getPlayerVocation(cid) == 1) and (getPlayerLevel(cid) >= 50) then
doPlayerSetVocation(cid, 2)
local outfit = {lookType = 30}


doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 50 then
               doPlayerSendCancel(cid, "Nao foi possivel!")
       elseif getPlayerVocation(cid) ==1 then
              doPlayerSendCancel(cid, "Nao foi possivel!")
else
if (getPlayerVocation(cid) == 2) and (getPlayerLevel(cid) >= 50) then
doPlayerSetVocation(cid, 3)
local outfit = {lookType = 37}
doSendMagicEffect(pos,18)
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 50 then
               doPlayerSendCancel(cid, "Nao foi possivel!")
       elseif getPlayerVocation(cid) ==1 then
              doPlayerSendCancel(cid, "Nao foi possivel!")
else
if (getPlayerVocation(cid) == 3) and (getPlayerLevel(cid) >= 100) then
doPlayerSetVocation(cid, 4)
local outfit = {lookType = 71}
doSendMagicEffect(pos,18)
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 100 then
               doPlayerSendCancel(cid, "Nao foi possivel")
       elseif getPlayerVocation(cid) ==3 then
              doPlayerSendCancel(cid, "Nao foi possivel!")                
else
if (getPlayerVocation(cid) == 4) and (getPlayerLevel(cid) >= 150) then
doPlayerSetVocation(cid, 5)
local outfit = {lookType = 70}
doSendMagicEffect(pos,18)
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 150 then
               doPlayerSendCancel(cid, "Nao foi possivel!")
       elseif getPlayerVocation(cid) ==4 then
              doPlayerSendCancel(cid, "Nao foi possivel!")
else
if (getPlayerVocation(cid) == 6) and (getPlayerLevel(cid) >= 30) then
doPlayerSetVocation(cid, 7) 
local outfit = {lookType = 205}
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 30 then
               doPlayerSendCancel(cid, "Nao foi possivel!")

else

if (getPlayerVocation(cid) == 7) and (getPlayerLevel(cid) >= 40) then
doPlayerSetVocation(cid, 8) 
local outfit = {lookType = 165}
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 40 then
               doPlayerSendCancel(cid, "Nao foi possivel!")

else
if (getPlayerVocation(cid) == 8) and (getPlayerLevel(cid) >= 50) then
doPlayerSetVocation(cid, 9) 
local outfit = {lookType = 166}
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 50 then
               doPlayerSendCancel(cid, "Nao foi possivel!")

else

if (getPlayerVocation(cid) == 9) and (getPlayerLevel(cid) >= 75) then
doPlayerSetVocation(cid, 10) 
local outfit = {lookType = 7}
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 75 then
               doPlayerSendCancel(cid, "Nao foi possivel!")

else                

if (getPlayerVocation(cid) == 10) and (getPlayerLevel(cid) >= 100) then
doPlayerSetVocation(cid, 11) 
local outfit = {lookType = 164}
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 100 then
               doPlayerSendCancel(cid, "Nao foi possivel!") 

else
if (getPlayerVocation(cid) == 11) and (getPlayerLevel(cid) >= 150) then
doPlayerSetVocation(cid, 12) 
local outfit = {lookType = 4}
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 150 then
               doPlayerSendCancel(cid, "Nao foi posivel!")                                 

else
if (getPlayerVocation(cid) == 12) and (getPlayerLevel(cid) >= 200) then
doPlayerSetVocation(cid, 13) 
local outfit = {lookType = 54}
doCreatureChangeOutfit(cid, outfit)
doPlayerSendCancel(cid, "Voce se Transformou!")
       elseif getPlayerLevel(cid) < 200 then
               doPlayerSendCancel(cid, "Nao foi possivel!") 

end
end
end
end
end
end
end  
end
end
end
end
end

ele funciona normal mais a transform de lv 30 , 40 , 50 , 75 , 100, 150 , 200

só funciona se voce tiver lv 200 como fazer para funcionar se vc tiver 30 ou 40??isso só acontece nas vocation 6 para a 7 em diante

Editado por galaverna
Link para o comentário
Compartilhar em outros sites

2 respostass a esta questão

Posts Recomendados

  • 0

tenta assim : Obs. Nem testei aqui. Se não funcionar me avisa.

 

function onSay(cid, words, param, var)

local pos = getPlayerPosition(cid)

 

if (getPlayerVocation(cid) == 1) and (getPlayerLevel(cid) >= 50) then

doPlayerSetVocation(cid, 2)

local outfit = {lookType = 30}

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 50 then

doPlayerSendCancel(cid, "Nao foi possivel!")

elseif getPlayerVocation(cid) == 1 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

if (getPlayerVocation(cid) == 2) and (getPlayerLevel(cid) >= 50) then

doPlayerSetVocation(cid, 3)

local outfit = {lookType = 37}

doSendMagicEffect(pos,18)

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 50 then

doPlayerSendCancel(cid, "Nao foi possivel!")

elseif getPlayerVocation(cid) ==1 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

if (getPlayerVocation(cid) == 3) and (getPlayerLevel(cid) >= 100) then

doPlayerSetVocation(cid, 4)

local outfit = {lookType = 71}

doSendMagicEffect(pos,18)

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 100 then

doPlayerSendCancel(cid, "Nao foi possivel")

elseif getPlayerVocation(cid) ==3 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

if (getPlayerVocation(cid) == 4) and (getPlayerLevel(cid) >= 150) then

doPlayerSetVocation(cid, 5)

local outfit = {lookType = 70}

doSendMagicEffect(pos,18)

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 150 then

doPlayerSendCancel(cid, "Nao foi possivel!")

elseif getPlayerVocation(cid) ==4 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

if (getPlayerVocation(cid) == 6) and (getPlayerLevel(cid) >= 30) then

doPlayerSetVocation(cid, 7)

local outfit = {lookType = 205}

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 30 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

if (getPlayerVocation(cid) == 7) and (getPlayerLevel(cid) >= 40) then

doPlayerSetVocation(cid, 8)

local outfit = {lookType = 165}

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 40 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

if (getPlayerVocation(cid) == 8) and (getPlayerLevel(cid) >= 50) then

doPlayerSetVocation(cid, 9)

local outfit = {lookType = 166}

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 50 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

 

if (getPlayerVocation(cid) == 9) and (getPlayerLevel(cid) >= 75) then

doPlayerSetVocation(cid, 10)

local outfit = {lookType = 7}

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 75 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

if (getPlayerVocation(cid) == 10) and (getPlayerLevel(cid) >= 100) then

doPlayerSetVocation(cid, 11)

local outfit = {lookType = 164}

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 100 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

 

if (getPlayerVocation(cid) == 11) and (getPlayerLevel(cid) >= 150) then

doPlayerSetVocation(cid, 12)

local outfit = {lookType = 4}

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 150 then

doPlayerSendCancel(cid, "Nao foi posivel!")

end

 

if (getPlayerVocation(cid) == 12) and (getPlayerLevel(cid) >= 200) then

doPlayerSetVocation(cid, 13)

local outfit = {lookType = 54}

doCreatureChangeOutfit(cid, outfit)

doPlayerSendCancel(cid, "Voce se Transformou!")

elseif getPlayerLevel(cid) < 200 then

doPlayerSendCancel(cid, "Nao foi possivel!")

end

Link para o comentário
Compartilhar em outros sites

  • Quem Está Navegando   0 membros estão online

    • Nenhum usuário registrado visualizando esta página.
×
×
  • Criar Novo...