 |
|
Senior Member
Join Date: Nov 2013
Location: Vilnius, Lithuania
|

02-12-2017
, 11:18
Re: [REQ] Score advertiser
|
#9
|
Quote:
Originally Posted by Relaxing
***
|
Thank for your efforts.
Quote:
Originally Posted by Blizzard_87
This should only show the teamscore to each player separately instead of every player in server everytime someone spawns. plus resets the scores to 0 when new game starts.
PHP Code:
#include <amxmodx>
#include <hamsandwich>
new CTScore = 0;
new TScore = 0;
public plugin_init( )
{
register_event( "TextMsg", "GameWillRestart", "a", "2=#Game_will_restart_in" );
register_event( "SendAudio", "Hook_Terr_Win", "a", "2&%!MRAD_terwin" );
register_event( "SendAudio", "Hook_CT_Win", "a", "2&%!MRAD_ctwin" );
RegisterHam(Ham_Spawn, "player", "teamScore")
}
public GameWillRestart( )
{
TScore = 0;
CTSore = 0;
}
public Hook_CT_Win( ) CTScore++;
public Hook_Terr_Win( ) TScore++;
public teamScore( id ) client_print( id, print_chat, "[SERVER] Teams Scoreboard: Terrorists: %d | Counter-Terrorists: %d", TScore, CTScore );
|
This plugin works perfectly and I will use it. But one application. I need that spectators should see the teams scoreboard. Can you add it?
|
|
|
|