• Страница 1 из 1
  • 1
Делаем окно с информацией
Владислав
Дата: Вторник, 26.11.2013, 19:00 | Сообщение # 1
Главный
Сообщений:
527
Награды:
5
Offline
Код
void cheat_handle_hudinformacion ()               {        
         traceLastFunc( "cheat_handle_hudinformacion()" );        
         if ( KEY_PRESSED(set.key_hudinformacion) )        
         {        
         cheat_state->_generic.hudinformacion ^= 1;        
         }        
         if( cheat_state->_generic.hudinformacion == 1 )        
         {
uint32_t    samp_info = ( uint32_t ) g_SAMP;
uint32_t    func = g_dwSAMP_Addr + SAMP_FUNCUPDATESCOREBOARDDATA;
D3DCOLORcolor = D3DCOLOR_ARGB( 0xFF, 0xFF, 0x00, 0x00 );
floaty = 0.0f;
( y ) += 400.0f;
charbuf[512];
   
if ( cheat_state->state == CHEAT_STATE_VEHICLE )
{
intamount_players = getPlayerCount();
pD3DFontFixed->PrintShadow( 350.0f, y, color, "Informacion of Car" );
// Nick
color = D3DCOLOR_ARGB( 0xFF, 0x99, 0x99, 0x99 );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
sprintf( buf, "Nick: %s", getPlayerName(g_Players->sLocalPlayerID) );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// id
sprintf( buf, "ID: %u", g_Players->sLocalPlayerID );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Ping
sprintf( buf, "Ping: %u", g_Players->iLocalPlayerPing );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Level
sprintf( buf, "Level: %u", g_Players->iLocalPlayerScore );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Online Players
sprintf( buf, "Connected Players: %d", amount_players );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Position Cars
sprintf( buf, "Position Car: %0.2f %0.2f %0.2f",
g_Players->pLocalPlayer->inCarData.fPosition[0],
g_Players->pLocalPlayer->inCarData.fPosition[1],
g_Players->pLocalPlayer->inCarData.fPosition[2] );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Health Car
sprintf( buf, "Health Car: %0.2f",
g_Players->pLocalPlayer->inCarData.fVehicleHealth );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
}
else if ( cheat_state->state == CHEAT_STATE_ACTOR )
{
intamount_players = getPlayerCount();
pD3DFontFixed->PrintShadow( 350.0f, y, color, "Informacion of Player" );
// Nick
color = D3DCOLOR_ARGB( 0xFF, 0x99, 0x99, 0x99 );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
sprintf( buf, "Nick: %s", getPlayerName(g_Players->sLocalPlayerID) );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// id
sprintf( buf, "ID: %u", g_Players->sLocalPlayerID );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Ping
sprintf( buf, "Ping: %u", g_Players->iLocalPlayerPing );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Online Players
sprintf( buf, "Connected Players: %d", amount_players );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Level
sprintf( buf, "Level: %u", g_Players->iLocalPlayerScore );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Armor
sprintf( buf, "Armor: %u", g_Players->pLocalPlayer->onFootData.byteArmor );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Health
sprintf( buf, "Health: %u", g_Players->pLocalPlayer->onFootData.byteHealth );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
// Position
sprintf( buf, "Position: %0.2f %0.2f %0.2f",
g_Players->pLocalPlayer->onFootData.fPosition[0], g_Players->pLocalPlayer->onFootData.fPosition[1],
g_Players->pLocalPlayer->onFootData.fPosition[2] );
pD3DFontFixed->PrintShadow( 350.0f, y, color, buf );
( y ) += 1.0f + pD3DFontFixed->DrawHeight();
__asm mov ecx, samp_info
__asm call func
}
}
}
  • Страница 1 из 1
  • 1
Поиск: