Resultados 1 a 1 de 1
  1. #1
    Developer C++ antoniofr's Avatar
    Data de Ingresso
    Feb 2015
    Posts
    28
    Thanks Thanks Given 
    16
    Thanks Thanks Received 
    16
    Thanked in
    1 Post
    Mencionado
    13 Post(s)
    MEU HUMOR
    Cold
    País
    Brazil

    Source comando /ping

    Código:
    void CMD::InitPing(DWORD aIndex)
        {    
            if(CMD_Config.Ping.Switch != 0)
            {
                DWORD Time = (GetTickCount() - Player[aIndex].PingDelay) / 1000;
    
                if(CMD_Config.Ping.Level > lpObj[aIndex].Level)
                {
                    MsgSystem::Leftblue(aIndex,SendMsg.Default3,lpObj[aIndex].Name);
                }
                else if(CMD_Config.Ping.Money > lpObj[aIndex].Money)
                {
                    MsgSystem::Leftblue(aIndex,SendMsg.Default4,lpObj[aIndex].Name);
                }
                else if(CMD_Config.Ping.Resets > Player[aIndex].Resets)
                {
                    MsgSystem::Leftblue(aIndex,SendMsg.Default6,lpObj[aIndex].Name);
                }
                else if(CMD_Config.Ping.Vip > Player[aIndex].VipIndex)
                {
                    MsgSystem::Leftblue(aIndex,SendMsg.Default5,lpObj[aIndex].Name);
                }
                else if(Time < CMD_Config.Ping.Delay)
                {
                    MsgSystem::Leftblue(aIndex,SendMsg.Default7,lpObj[aIndex].Name,CMD_Config.Ping.Delay);
                }
                else
                {
                    GCSendPing(aIndex);
                    Player[aIndex].PingDelay = GetTickCount();
                }
            }
            else
            {
                MsgSystem::Leftblue(aIndex,SendMsg.Default1,lpObj[aIndex].Name);
            }
        }
    Offset[97d]
    Código:
    Offsets.cpp
    pGCSendPing                            GCSendPing                                =        (pGCSendPing)0x00429EE0;
    
    Offsets.h
    typedef void (*pGCSendPing)(int aIndex);
        extern pGCSendPing GCSendPing;
    Protocol.cpp
    Código:
     case 0x71:
                 {
                     DWORD V2;
                     V2 = GetTickCount();
                     CMD_Config.Result = V2 - lpObj[aIndex].iPingTime;
                     MsgSystem::Leftblue(aIndex,"[%s]Seu ping é de %d ms",lpObj[aIndex].Name,CMD_Config.Result);
                 }
                 break;
    Créditos: antonio.fr
    Last edited by Mentor; 25/04/2015 at 07:31 PM.

Permissões de Postagem

  • Você não pode iniciar novos tópicos
  • You may not post Resposta(s)
  • Você não pode enviar anexos
  • Você não pode editar suas mensagens
  •  
Sobre nós
Somos uma comunidade em atividade a 8 anos que aborda assuntos relacionados a games em geral, principalmente games MMORPG. e que busca sempre ajudar os membros através de conteúdos, tutoriais e suporte...
Nossos anunciantes
Hinetworks
VelozHost
InovHost
Rede Sociais