Ir para conteúdo

Featured Replies

Postado

Meu script é esse:

 

function onKill(cid, target, lastHit)

     if not isPlayer(target) or not isPlayer(cid) then
          return true
     end

     doBroadcastMessage(""..getCreatureName(target).." on level ["..getPlayerLevel(target).."] just got killed for "..getCreatureName(cid).." on level ["..getPlayerLevel(cid).."].", MESSAGE_STATUS_CONSOLE_BLUE)
    return true
end

 

A gambiarra que eu fiz para aparecer no death channel

 

if not isPlayer(target) or not isPlayer(cid) then
          return true
     end

     doPlayerSendChannelMessage(oid, "Death channel", ""..getCreatureName(target).." on level ["..getPlayerLevel(target).."] just got killed for "..getCreatureName(cid).." on level ["..getPlayerLevel(cid).."].", MESSAGE_STATUS_CONSOLE_BLUE)
    return true
end

 

E porque o chat não abre? Registrei isso depois do return true no login lua.

 

doPlayerOpenChannel(cid, 10)

 

E isso na lib constant

 

CHANNEL_DEATH = 10

E isso no xml

 

    <channel id="10" active="no" logged="yes" name="Death Channel"/>

 

 

 

(1º) | [8.60] - Galaxy Server - Download

(2º) | [8.60] - Glorious Server - Download

(3º) | [8.60] - Epic Server - Download

Resolvido por Dwarfer

Ir para solução
  • Respostas 6
  • Visualizações 1.3k
  • Created
  • Última resposta

Top Posters In This Topic

Most Popular Posts

  • @jNo   Em creaturescripts/scripts:   deathchannel.lua     Registre no login.lua: registerCreatureEvent(cid, "DeathChannel")   Adicione a tag no creatures

Postado

Traduzi a mensagem quando mata;

Quando você usa uma função tem que ver qual volores ela pede ( )


function onKill(cid, target, lastHit)
    if not isPlayer(target) or not isPlayer(cid) then
        return true
    end
    doPlayerSendChannelMessage(cid, "Death-Chat", "O Jogador "..getCreatureName(target).." no nivel ["..getPlayerLevel(target).."] foi morto pelo "..getCreatureName(cid).." que esta level ["..getPlayerLevel(cid).."].", TALKTYPE_CHANNEL_R1, CHANNEL_DEATH)
    print("oi")
return true
end

 

Te ajudei ?? Que tal fazer uma contribuição ?

Doar

Postado
  • Autor
54 minutos atrás, DboExplorer disse:

Traduzi a mensagem quando mata;

Quando você usa uma função tem que ver qual volores ela pede ( )

 


function onKill(cid, target, lastHit)
    if not isPlayer(target) or not isPlayer(cid) then
        return true
    end
    doPlayerSendChannelMessage(cid, "Death-Chat", "O Jogador "..getCreatureName(target).." no nivel ["..getPlayerLevel(target).."] foi morto pelo "..getCreatureName(cid).." que esta level ["..getPlayerLevel(cid).."].", TALKTYPE_CHANNEL_R1, CHANNEL_DEATH)
    print("oi")
return true
end

 

 

Funcionou, você consegue por para mostrar os bixos e outros players que ajudaram a matar?

(1º) | [8.60] - Galaxy Server - Download

(2º) | [8.60] - Glorious Server - Download

(3º) | [8.60] - Epic Server - Download

Postado
  • Autor
9 horas atrás, DboExplorer disse:

Ai vai precisar usar a função OnDeath mais tarde eu faço

 

No aguardo.

 

06:40 Death channel: Joaozinhosz was killed at level 103 by Suco De Uva, Sharingan.

(1º) | [8.60] - Galaxy Server - Download

(2º) | [8.60] - Glorious Server - Download

(3º) | [8.60] - Epic Server - Download

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

Quem Está Navegando 0

  • Nenhum usuário registrado visualizando esta página.

Estatísticas dos Fóruns

  • Tópicos 96.9k
  • Posts 519.6k

Informação Importante

Confirmação de Termo