Can any fix this?
#include <amxmodx>
#include <amxmisc>
#include <dhudmessage>
#pragma semicolon 1
#define MAX_RESTART 3
#define MAX_SONGS 20
new const PLUGIN[ ] = "Live Plugin";
new const VERSION[ ] = "1";
new const AUTHOR[ ] = "Arshad Runjaun(Credit : glut , xxxperts)";
new gDir[MAX_SONGS][32];
new file[] = "addons/amxmodx/configs/loadmusic.ini";
new num;
public plugin_precache()
{
new len, arg[32], szDir[64];
for(new i; read_file(file, i, arg, charsmax(arg),len);i++)
{
remove_quotes(arg);
copy(gDir[i], charsmax(arg), arg);
formatex(szDir, charsmax(szDir), "sound/misc/%s", gDir[i]);
num++
precache_generic(szDir);
}
}
new iXYPos;
new const Float:HUD_XY_POS[ ][ ] =
{
{ -1.0, 0.90 },
{ -1.0, 0.80 },
{ -1.0, 0.70 },
{ -1.0, 0.60 },
{ -1.0, 0.50 },
{ -1.0, 0.40 },
{ -1.0, 0.30 },
{ -1.0, 0.20 },
{ -1.0, 0.10 }
};
new pCvar;
new iNumRounds, bool:GivenLive = false;
public plugin_init( )
{
register_plugin( PLUGIN, VERSION, AUTHOR );
register_event( "HLTV", "Event_NewRound", "a", "1=0", "2=0" );
register_logevent( "logevent_RoundStart", 2, "1=Round_Start" );
pCvar = register_cvar( "amx_auto_live", "0" );
register_clcmd( "say /live", "cmd_live", ADMIN_KICK );
register_clcmd( "say_team /live", "cmd_live", ADMIN_KICK );
register_clcmd( "say .live", "cmd_live", ADMIN_KICK );
register_clcmd( "say_team .live", "cmd_live", ADMIN_KICK );
}
public Event_NewRound( )
{
if( get_pcvar_num( pCvar ) && iNumRounds > 1 && !GivenLive ) {
set_task( 0.1, "NotifyGivingLive" );
set_task( 3.0, "GiveRestartRound", _, _, _, "a", MAX_RESTART );
set_task( 12.0, "ShowHUD_LiveLive" );
set_task( 19.0, "NotifyThat_LIVE" );
GivenLive = true;
}
}
public logevent_RoundStart( )
{
if( !GivenLive ) iNumRounds++;
}
public NotifyGivingLive( )
{
new rand = random(num);
client_cmd(0, "mp3 play sound/misc/%s", gDir[rand]);
set_dhudmessage( 0, 160, 0, -1.0, 0.44, 0, 1.0, 3.0, 0.2, 0.3, false );
show_dhudmessage( 0, "____________LIVE AFTER 3 RESTARTS____________" );
}
public NotifyThat_LIVE( )
{
set_dhudmessage( 0, 160, 0, -1.0, 0.44, 0, 1.0, 3.0, 0.2, 0.3, false );
show_dhudmessage( 0, "_____ G o o d L u c k a n d H a v e F u n !_____ " );
}
public GiveRestartRound( )
{
server_cmd( "sv_restartround ^"1^"" );
}
public ShowHUD_LiveLive( )
{
set_task( 0.2, "HUD_LiveLive", _, _, _, "a", sizeof( HUD_XY_POS ) * 3 );
}
public HUD_LiveLive( index )
{
if( iXYPos >= sizeof( HUD_XY_POS ) ) iXYPos = 0;
set_dhudmessage( random_num( 0, 255 ), random_num( 0, 255 ), random_num( 0, 255 ), HUD_XY_POS[ iXYPos ][ 0 ], HUD_XY_POS[ iXYPos ][ 1 ], 0, 50.0, 0.4, 0.2, 0.3, false );
show_dhudmessage( index, "[ L I V E ] [ L I V E ] [ L I V E ]" );
iXYPos++;
}
public cmd_live( index, level, cid )
{
if( !cmd_access( index, level, cid, 0 ) ) return PLUGIN_CONTINUE;
iXYPos = 0; GivenLive = true;
set_task( 0.1, "NotifyGivingLive" );
set_task( 3.0, "GiveRestartRound", _, _, _, "a", MAX_RESTART );
set_task( 12.0, "ShowHUD_LiveLive" );
set_task( 19.0, "NotifyThat_LIVE" );
GivenLive = true;
return PLUGIN_CONTINUE;
}
Customlive.sma(27) : error 001: expected token: ";", but found "-identifier-"
1 Error.
Could not locate output file Customlive.amx (compile failed).
Thanks in Advance