Search the Community

Showing results for tags 'hp'.

  • Search By Tags

    Type tags separated by commas.
  • Search By Author



Filter by number of...

Found 1 result

  1. HP už KILL

      Gausite šiek tiek HP už kas antra kill   #include < amxmodx > #include < fakemeta > #pragma semicolon 1 #define PLUGIN_NAME   "Bonus Health for Kill" #define PLUGIN_VERSION   "v0.1" #define PLUGIN_AUTHOR   "XTCS.LT" // 0: plugin disable // 1: plugin enable #define BONUS_HEALTH   1 #if BONUS_HEALTH    new g_MessageColor[ 3 ] = { 255, 10, 5 };    new g_BonusHp[ 33 ] = 0;    new p_BonusHp;    new g_HudSyncObj; #endif public plugin_init( ) {    #if !BONUS_HEALTH       new nPluginName[ 32 ], pos = 0;       pos = format( nPluginName, charsmax( nPluginName ), PLUGIN_NAME );       pos += format( nPluginName[ pos ], charsmax( nPluginName ) - pos, " (OFF)" );       register_plugin( nPluginName, PLUGIN_VERSION, PLUGIN_AUTHOR );    #else       register_plugin( PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_AUTHOR );       register_event( "DeathMsg", "event_DeathMsg", "a" );       p_BonusHp = register_cvar( "amx_kill_bonus_hp", "20" );       g_HudSyncObj = CreateHudSyncObj( );    #endif } #if BONUS_HEALTH    public client_putinserver( id )    {       g_BonusHp[ id ] = 0;    }    public client_disconnect( id )    {       g_BonusHp[ id ] = 0;    }    public event_DeathMsg( )    {       new killer, victim;       killer = read_data( 1 );       victim = read_data( 2 );       if ( killer && ( killer != victim ) )       {          g_BonusHp[ killer ]++;          new nBonusHp;          nBonusHp = g_BonusHp[ killer ];          if ( ( nBonusHp > -1 ) && !( nBonusHp % 2 ) )          {             set_pev( killer, pev_health, pev( killer, pev_health ) + float( get_pcvar_num( p_BonusHp ) ) );             new r, g, b;             r = g_MessageColor[ 0 ];             g = g_MessageColor[ 1 ];             b = g_MessageColor[ 2 ];             set_hudmessage( r, g, b, 0.03, 0.27, 1, 0.3, 3.0, 0.3, 0.3, -1 );             ShowSyncHudMsg( killer, g_HudSyncObj, "Got one! +%dHP!", get_pcvar_num( p_BonusHp ) );          }       }    } #endif