FL

[Resolvido] Como fazer o poke não "morrer" no sleep?

Por FlamesAdmin, 23 de out. de 2019 em Resolvidos

4
2.3k
23 de outubro de 2019 às 15:56

Como no título já diz, como fazer pro pokemon não "morrer" quando estiver com Sleep

KZoFzAR.gif

 

 

RESOLUÇÃO DO PROBLEMA LOGO ABAIXO NO TÓPICO

 

Editado Outubro 24 por FlamesAdmin

HyakiH
23 de outubro de 2019 às 16:46
Melhor resposta

Se o seu servidor for baseado no PDA, vai na pasta lib em "newStatusSyst.lua" e procura por "doSleep2":
A parte que muda a outfit é esta:

    if not isPlayer(cid) then
	   local dittoStg = getPlayerStorageValue(cid, 1010) 
       if getCreatureName(cid) == "Ditto" and isSummon(cid) and tostring(dittoStg) and dittoStg ~= "Ditto" then
	      doSetCreatureOutfit(cid, {lookType = getItemAttribute(getPlayerSlotItem(getCreatureMaster(cid), 8).uid, "transOutfit")}, -1)
       else
	      doRemoveCondition(cid, CONDITION_OUTFIT)
	   end
	   if getPlayerStorageValue(cid, 625877) ~= -1 then 
	      doSetCreatureOutfit(cid, {lookType = getPlayerStorageValue(cid, 625877)}, -1)   --alterado v1.6
       end 
    end

Faça um backup do seu arquivo antes de apagar alguma coisa.

24 de outubro de 2019 às 00:45

@HenriqueObrigado. Não era bem nessa parte que você colocou mas consegui resolver

No meu é assim:

if first then
        if getCreatureName(cid) == "Ursaring" and getCreatureCondition(cid, CONDITION_OUTFIT) == true then

        elseif not isPlayer(cid) then
          if isInArray({556, 557, 646, 647, 636, 637}, getCreatureOutfit(cid).lookType) then
            Info = 0                                                                            --alterado v1.6
          else
            Info = getMonsterInfo(getCreatureName(cid)).lookCorpse
          end
          local look = getCreatureOutfit(cid)
          ---------
          local dittoStg = getPlayerStorageValue(cid, 1010)
          if getCreatureName(cid) == "Ditto" and isSummon(cid) and tostring(dittoStg) and dittoStg ~= "Ditto" then
            local InfoDitto = getMonsterInfo(tostring(dittoStg)).lookCorpse
            if InfoDitto ~= 0 and look.lookType ~= 0 then
              doSetCreatureOutfit(cid, {lookType = 0, lookTypeEx = getMonsterInfo(tostring(dittoStg)).lookCorpse}, -1)
            end
          else
            if getCreatureName(cid) == "Shiny Golem" and getCreatureOutfit(cid).lookType == 292 then
              doRemoveCondition(cid, CONDITION_OUTFIT)
            elseif Info ~= 0 and look.lookType ~= 0 then
              doSetCreatureOutfit(cid, {lookType = 0, lookTypeEx = getMonsterInfo(getCreatureName(cid)).lookCorpse}, -1)
            end
          end
        end
      end

E para o pokemon não "morrer" no sleep basta comentar com ( -- ) sem os parenteses, no começo das linhas
 

--else
--Info = getMonsterInfo(getCreatureName(cid)).lookCorpse
--local InfoDitto = getMonsterInfo(tostring(dittoStg)).lookCorpse
--doSetCreatureOutfit(cid, {lookType = 0, lookTypeEx = getMonsterInfo(tostring(dittoStg)).lookCorpse}, -1)
--doSetCreatureOutfit(cid, {lookType = 0, lookTypeEx = getMonsterInfo(getCreatureName(cid)).lookCorpse}, -1)

 

Editado Outubro 24 por FlamesAdmin

1 mês depois...
MarkowiiczM
26 de novembro de 2019 às 15:34
A questão neste tópico de suporte foi respondida e/ou o autor do tópico resolveu o problema. Este tópico está fechado e foi movido para Suporte - Resolvidos. Se você tiver outras dúvidas, crie um novo tópico.