Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Plugin generated by AMXX-Studio */
- #include < amxmodx >
- #if AMXX_VERSION_NUM < 183
- #include < dhudmessage >
- #endif
- #pragma semicolon 1
- // --| Credite lui CryWolf pentru 'layout' !!
- // --| Credite lui Askhanar pentru baza plugin-ului 'DHUD Team Detalis' - extreamcs.com
- new const
- PLUGIN_NAME[ ] = "Score (XMAS)",
- PLUGIN_AUTHOR[ ] = "Askhanar + csfweed01",
- PLUGIN_VERSION[ ] = "0.1.7";
- #define iTerroRed 255
- #define iTerroGreen 0
- #define iTerroBlue 0
- #define iRoundsRed 255
- #define iRoundsGreen 255
- #define iRoundsBlue 255
- new const
- g_szCts[ ] = "SANTA [%02i] ",
- g_szTerrorists[ ] = " [%02i] GRINCH",
- g_szRounds[ ] = "vs^nRound %02i";
- enum _:iTeamWons
- {
- TERRO,
- CT
- }
- new g_iTeamWons[ iTeamWons ];
- new g_iRounds;
- public plugin_init( )
- {
- register_plugin( PLUGIN_NAME, PLUGIN_VERSION, PLUGIN_AUTHOR );
- register_event( "HLTV", "ev_NewRound", "a", "1=0", "2=0" );
- register_event( "TextMsg", "ev_RoundRestart", "a", "2&#Game_C", "2&#Game_w" );
- register_event( "SendAudio", "ev_TerroristWin", "a", "2&%!MRAD_terwin" );
- register_event( "SendAudio", "ev_CtWin", "a", "2&%!MRAD_ctwin" );
- g_iRounds = 0;
- g_iTeamWons[ TERRO ] = 0;
- g_iTeamWons[ CT ] = 0;
- set_task( 1.0, "task_DisplayHudScore", _, _, _, "b", 0 );
- // Add your code here...
- }
- public ev_NewRound( ) g_iRounds++;
- public ev_RoundRestart( )
- {
- g_iRounds = 0;
- g_iTeamWons[ TERRO ] = 0;
- g_iTeamWons[ CT ] = 0;
- }
- public ev_TerroristWin( )
- {
- g_iTeamWons[ TERRO ]++;
- }
- public ev_CtWin( )
- {
- g_iTeamWons[ CT ]++;
- }
- public task_DisplayHudScore( )
- {
- static iPlayers[ 32 ];
- static iPlayersNum;
- get_players( iPlayers, iPlayersNum, "ch" );
- if( !iPlayersNum )
- return;
- static szCrap[ 32 ];
- static iTerro, iCt;
- get_players( szCrap, iTerro, "aech", "TERRORIST" );
- get_players( szCrap, iCt, "aech", "CT" );
- static id, i;
- for( i = 0; i < iPlayersNum; i++ )
- {
- id = iPlayers[ i ];
- set_dhudmessage( 0, 70, 247, -1.0, is_user_alive( id ) ? 0.01 : 0.16 , 0, _, 2.0, 1.0, 1.0 );
- show_dhudmessage( id, g_szCts, g_iTeamWons[ CT ] );
- set_dhudmessage( iRoundsRed, iRoundsGreen, iRoundsBlue, -1.0, is_user_alive( id ) ? 0.01 : 0.16 , 0, _, 2.0, 1.0, 1.0 );
- show_dhudmessage( id, g_szRounds, g_iRounds);
- set_dhudmessage( iTerroRed, iTerroGreen, iTerroBlue, -1.0, is_user_alive( id ) ? 0.01 : 0.16 , 0, _, 2.0, 1.0, 1.0 );
- show_dhudmessage( id, g_szTerrorists, g_iTeamWons[ TERRO ] );
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement