Raised This Month: $51 Target: $400
 12% 

csgo musickit


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Ayman Khaled
Senior Member
Join Date: Mar 2017
Location: Palestine
Old 05-24-2017 , 13:43   csgo musickit
Reply With Quote #1

Hello guys.
i need someone rewrite this plugin with these sounds,
when you write kit1-kit5 ( 5 files, kit1 = folder 1 etc..) , play sounds automatic ( planting , win , lose sounds , etc.)

File is big, i can't upload it to forum , here is the download link : https://drive.google.com/open?id=0B2...XhjdWl6ZGhCc1k
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>

new const PLUGIN[] =  "CS:GO Music Kit for CS 1.6";
new const 
VERSION[] = "1.7.3";
new const 
AUTHOR[] = "hellmonja";

//These sounds are in arrays so we could match them with each other
new const MUSIC[][] =
{
    
"startround_01.mp3",    //0
    
"startround_02.mp3",    //1
    
"startround_03.mp3",    //2
    
"startaction_01.mp3",    //3
    
"startaction_02.mp3",    //4
    
"startaction_03.mp3",    //5
    
"deathcam.mp3",        //6
    
"bombplanted.mp3",            //7
    
"bombtenseccount.mp3",    //8
    
"roundtenseccount.mp3",    //9
    
"wonround.mp3",        //10
    
"lostround.mp3"        //11
}

// Setting task with their IDs so we can remove them later
enum (+= 100000)
{
    
TASKID_ROUND_TEN 100000// start with 100000
    
TASKID_BOMB_TEN
}

new 
player_cache[32], player_kit[32], player_folder[32][45];
new 
bool_firstround 1bool_endofroundbool_bomb_planted ;
new 
cvar_musickit_setcvar_round_timecvar_c4_timecvar_freeze_timecvar_musickit_howmany;
new 
variantclient_cmds[6];

public 
plugin_init() 
{
    
register_plugin(PLUGINVERSIONAUTHOR);
    
    
register_event("HLTV""Event_New_Round""a""1=0""2=0");
    
register_message(get_user_msgid("TextMsg"),    "Event_End_Round");
    
register_event("DeathMsg""Event_Death""a");
    
register_logevent("Event_Start_Round"2"1=Round_Start");
    
register_logevent("Event_Bomb_Planted"3"2=Planted_The_Bomb");
    
register_logevent("Event_Round_Draw" 4"1=Round_Draw");
    
register_logevent("Event_Bomb_Defused"3"2=Defused_The_Bomb");
    
register_logevent("Event_BombTarget_Saved"6"3=Target_Saved") ;
    
register_logevent("Remove_Tasks"2"1=Round_End");
    
    
// CVARS
    
cvar_round_time get_cvar_pointer("mp_roundtime");
    
cvar_c4_time get_cvar_pointer("mp_c4timer");
    
cvar_freeze_time get_cvar_pointer("mp_freezetime");
    
cvar_musickit_set register_cvar("musickit_set""1");
    
cvar_musickit_howmany register_cvar("musickit_howmany""5")
        
    for(new 
0<= get_pcvar_num(cvar_musickit_howmany); i++)
    {
        
formatex(client_cmdscharsmax(client_cmds), "kit%d"i);
        
register_concmd(client_cmds"ClientCommand_Select_Kit");
    }
        
    
register_concmd("debug""Debug");    
}

public 
Debug(id)
{
    new 
players[32], playername[32], num;
    new 
team get_user_team(id)
    
get_players(playersnum"a");
    for (new 
1num 1i++)
    {
        
get_user_name(iplayernamecharsmax(playername));
        
console_print(id"%s: %s | %d"playernameplayer_folder[i], player_cache[i]);
    }
    
client_print(1print_chat"TEAM: %d"team);
    
client_print(1print_chat"First Round: %d"bool_firstround);
    
console_print(id"==============================");
}

public 
ClientCommand_Select_Kit(id)
{
    static 
cmd[6];
    
read_argv(0cmd5);
    new 
num str_to_num(cmd[3]);
    
player_cache[id] = num;
    
    
client_print(idprint_chat"Music Kit changed to %d."num);
    
client_print(idprint_chat"Player: %d."id);
    
client_print(idprint_chat"Source Folder: %s."player_folder[id]);
    
client_print(idprint_center"Music Kit will change next round.");
}

public 
Event_New_Round()
{
    
// Resetting some values for later
    
bool_endofround 0;
    
bool_bomb_planted 0;
    
    
client_print(1print_chat"End Round: %d."bool_endofround);
    
client_print(1print_chat"Bomb Planted: %d."bool_bomb_planted);

    new 
players[32], num;
    
get_players(playersnum"a");
    for (new 
1num 1i++)
    {
        if(
bool_firstround == 1)
        {
            
player_cache[i] = get_pcvar_num(cvar_musickit_set);
            
player_kit[i] = player_cache[i];
        }
        else
            
player_kit[i] = player_cache[i];
    }
    
    if(
get_pcvar_num(cvar_freeze_time) <= 2)
    {
        
variant random_num(0,2);
        return
    }

    
variant random_num(0,2);
    
Play_Music(variant00);
}

public 
Event_Start_Round()
{
    if(
bool_endofround == 1)
        return
        
    
Play_Music(variant00);
    
client_print(1print_center"Works up till this point.");
    new 
Float:SecUntilRoundEnd float((get_pcvar_num(cvar_round_time) * 60) - 10); // We calculate when there's only ten seconds left of round time
    
set_task(SecUntilRoundEnd"Round_Ten_Seconds_Left"TASKID_ROUND_TEN); // Setting task to play sound when only ten seconds of round time is left
}

public 
Round_Ten_Seconds_Left()
{
    if(
bool_endofround == 1)
        return

    
// If is already planted, function is ignored
    
if(bool_bomb_planted == 1)
        return

    
Play_Music(900);
}

public 
Event_Bomb_Planted()
{
    if(
bool_endofround == 1)
        return
    
    
bool_bomb_planted 1;
    
    
Play_Music(700);
    
    new 
Float:SecUntilExplosion float(get_pcvar_num(cvar_c4_time) - 10); // Calculating when ten seconds is left on the C4 timer
    
set_task(SecUntilExplosion"Bomb_Ten_Seconds_Left"TASKID_BOMB_TEN); // Sets tasks when ten seconds of C4 timer is left 
}

public 
Bomb_Ten_Seconds_Left()
{
    if(
bool_endofround == 1)
        return

    
Play_Music(800);
}

public 
Event_End_Round(id)
{
    
// We get what type of End Round we have...
    
static textmsg[22];
    
get_msg_arg_string(2textmsgcharsmax(textmsg));
    
    
//...and play the appropriate sound to each player according to their team
    
    
if(equali(textmsg"#Terrorists_Win")) //Terrorists Wins
        
Play_Music(1011);
    
    else if(
equali(textmsg"#CTs_Win")) //Counter-Terrorists Wins
        
Play_Music(1021);
    
    else if(
equali(textmsg"#Target_Bombed")) //C4 explodes, eliminates target
        
Play_Music(1011);
        
    else if(
equali(textmsg"#Hostages_Not_Rescued")) //Time ran out and hostages not rescued
        
Play_Music(1011);
    
    else if(
equali(textmsg"#VIP_Assassinated") || equali(textmsg"#VIP_Not_Escaped")) //VIP killed or time ran out and VIP has not escaped
        
Play_Music(1011);
    
    else if(
equali(textmsg"#VIP_Escaped")) //VIP escapes
        
Play_Music(1021);
}

// Plays victory sound for CT when C4 is defused
public Event_Bomb_Defused(id)
{
    if(
bool_endofround == 1)
        return
        
    
Play_Music(1021); 
}

// Plays victory sound for CT when target has not been bombed
public Event_BombTarget_Saved(id)
{
    
Play_Music(1021); 
}

public 
Event_Round_Draw()
{
    
Play_Music(1101);
}

public 
Event_Death()
{
    if(
bool_endofround == 1)
        return

    new 
id read_data(2// Getting index of player who just died
    
    
Format_Music_Folder(id);
    
client_cmd(id"mp3 play ^"%s%s^""player_folder[id], MUSIC[6]);
}

public 
Remove_Tasks()
{
    
//Removing set tasks
    
remove_task(TASKID_ROUND_TEN);
    
remove_task(TASKID_BOMB_TEN);

    
// Resetting values for next round
    
bool_endofround 1;
    
bool_bomb_planted 0;
}

public 
Play_Music(musicteamend)
{
    new 
players[32], num;
    
get_players(playersnum);
    for (new 
1num 1i++)
    {
        
Format_Music_Folder(i);
        if(
end == 1)
        {
            if(
team// If one team wins
            
{
                if(
get_user_team(i) == team)
                    
client_cmd(i"mp3 play ^"%s%s^""player_folder[i], MUSIC[10]);
                else
                    
client_cmd(i"mp3 play ^"%s%s^""player_folder[i], MUSIC[11]);
            }
            else 
// When no one wins, everybody loses
                
client_cmd(i"mp3 play ^"%s%s^""player_folder[i], MUSIC[11]);
            
            
// The 1st round is when players are still connecting and game has not commenced.
            // To prevent the sound from playing after that, we do this check
            
if(bool_firstround == 1)
            {
                
bool_firstround 0;
                return
            }
        }
        else
            
client_cmd(i"mp3 play ^"%s%s^""player_folder[i], MUSIC[music]);

    }
}

stock Format_Music_Folder(id)
{
    new 
iFolder[45];
    
    if(
player_kit[id] == 1)
    {
        if(
CsTeams:get_user_team(id) == CS_TEAM_T)
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/TER/");
        else if(
CsTeams:get_user_team(id) == CS_TEAM_CT)
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/CT/");
        else
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/CT/");
    }
    else if(
player_kit[id] >> 1)
        
formatex(iFoldercharsmax(iFolder), "media/musickits/%d/"player_kit[id]);
        
    
player_folder[id] = iFolder;

__________________

Last edited by Ayman Khaled; 05-24-2017 at 13:59.
Ayman Khaled is offline
tarsisd2
Veteran Member
Join Date: Feb 2016
Location: brazil
Old 05-24-2017 , 20:13   Re: csgo musickit
Reply With Quote #2

use updated version of the plugin

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <cstrike>

new const PLUGIN[] =  "CS:Go Music Kit for CS 1.6";
new const 
VERSION[] = "1.7.7";
new const 
AUTHOR[] = "hellmonja";

//These sounds are in arrays so we could match them with each other
new const MATCHPOINT[] = "media/musickits/cs_stinger.wav"
new const MUSIC[][] =
{
    
"startround_01.mp3",    //0
    
"startround_02.mp3",    //1
    
"startround_03.mp3",    //2
    
"startaction_01.mp3",    //3
    
"startaction_02.mp3",    //4
    
"startaction_03.mp3",    //5
    
"deathcam.mp3",        //6
    
"bombplanted.mp3",    //7
    
"bombtenseccount.mp3",    //8
    
"roundtenseccount.mp3",    //9
    
"wonround.mp3",        //10
    
"lostround.mp3"        //11
}

// Setting task with their IDs so we can remove them later
enum (+= 100000)
{
    
TASKID_ROUND_TEN 100000// start with 100000
    
TASKID_BOMB_TEN
}

new 
player_cache[32], player_kit[32], player_folder[32][45];
new 
bool_firstround 1bool_endofroundbool_bomb_planted ;
new 
cvar_round_timecvar_c4_timecvar_freeze_timecvar_windiffcvar_winlimit;
new 
cvar_musickit_setcvar_musickit_howmany;
new 
varianttscorectscoredefault_setclient_cmds[6];

public 
plugin_init() 
{
    
register_plugin(PLUGINVERSIONAUTHOR);
    
    
register_event("TextMsg""Game_Commencing""a""2=#Game_Commencing""2=#Game_will_restart_in")
    
register_event("HLTV""Event_New_Round""a""1=0""2=0");
    
register_message(get_user_msgid("TextMsg"),    "Event_End_Round");
    
register_event("DeathMsg""Event_Death""a");
    
register_logevent("Event_Start_Round"2"1=Round_Start");
    
register_logevent("Event_Bomb_Planted"3"2=Planted_The_Bomb");
    
register_logevent("Event_Round_Draw" 4"1=Round_Draw");
    
register_logevent("Event_Bomb_Defused"3"2=Defused_The_Bomb");
    
register_logevent("Event_BombTarget_Saved"6"3=Target_Saved") ;
    
register_logevent("Remove_Tasks"2"1=Round_End");
    
    
// CVARS
    
cvar_round_time get_cvar_pointer("mp_roundtime");
    
cvar_c4_time get_cvar_pointer("mp_c4timer");
    
cvar_freeze_time get_cvar_pointer("mp_freezetime");
    
cvar_windiff get_cvar_pointer("mp_windifference");
    
cvar_winlimit get_cvar_pointer("mp_winlimit");
    
cvar_musickit_set register_cvar("musickit_set""1");
    
cvar_musickit_howmany register_cvar("musickit_howmany""5")
        
    new 
szFilepath[64]
    
get_configsdir(szFilepathcharsmax(szFilepath))
    
add(szFilepathcharsmax(szFilepath), "/musickit.ini")
    
    if(!
file_exists(szFilepath))
    {
        
default_set get_pcvar_num(cvar_musickit_set);
        return
    }
    
    new 
fopen(szFilepath"rt"), szData[3];
    while(!
feof(f)) 
        
fgets(fszDatacharsmax(szData));

    
default_set str_to_num(szData);
    
fclose(f)
    
    if(!
|| default_set == 0)
        
default_set get_pcvar_num(cvar_musickit_set);
    
    
set_task(1.0"Register_ConCommands");
}

public 
Register_ConCommands()
{
    for(new 
0<= get_pcvar_num(cvar_musickit_howmany); i++)
    {
        
formatex(client_cmdscharsmax(client_cmds), "kit%d"i);
        
register_concmd(client_cmds"ClientCommand_Select_Kit");
    }
}

public 
Game_Commencing()
{
    
tscore 0;
    
ctscore 0;
}

public 
ClientCommand_Select_Kit(id)
{
    static 
cmd[6];
    
read_argv(0cmd5);
    new 
num str_to_num(cmd[3]);
    
    if(
num <= 0)
    {
        
player_kit[id] = 0;
        
player_cache[id] = 0;
        
client_cmd(id"mp3 stop");
        return
    } else 
player_cache[id] = num;
    
    
client_print(idprint_chat"Music Kit set to %d."num);
    
client_print(idprint_center"Music Kit will change next round.");
}

public 
Event_New_Round()
{
    
// Resetting some values for later
    
bool_endofround 0;
    
bool_bomb_planted 0;
    
Remove_Tasks();
    
    new 
players[32], num;
    
get_players(playersnum"c");
    for (new 
1num 1i++)
    {
        if(
bool_firstround == 1)
        {
            
player_cache[i] = default_set;
            
player_kit[i] = player_cache[i];
        }
        else
            
player_kit[i] = player_cache[i];
    }
    
    if(
get_pcvar_num(cvar_winlimit) >= 1)
        if(
tscore >= get_pcvar_num(cvar_winlimit) - || ctscore >= get_pcvar_num(cvar_winlimit) - 1)
            
Match_Point;
    
    if(
get_pcvar_num(cvar_freeze_time) <= 2)
    {
        
variant random_num(0,2);
        return
    }
    
    
variant random_num(0,2);
    
Play_Music(variant00);

}

public 
Event_Start_Round()
{
    if(
bool_endofround == 1)
        return
    
    
Play_Music(variant00);
    new 
Float:SecUntilRoundEnd float((get_pcvar_num(cvar_round_time) * 60) - 10); // We calculate when there's only ten seconds left of round time
    
set_task(SecUntilRoundEnd"Round_Ten_Seconds_Left"TASKID_ROUND_TEN); // Setting task to play sound when only ten seconds of round time is left
}

public 
Round_Ten_Seconds_Left()
{
    if(
bool_endofround == 1)
        return

    
// If is already planted, function is ignored
    
if(bool_bomb_planted == 1)
        return
    
    
Play_Music(900);
}

public 
Event_Bomb_Planted()
{
    if(
bool_endofround == 1)
        return
    
    
bool_bomb_planted 1;
    
remove_task(TASKID_ROUND_TEN);
    
    
Play_Music(700);
    
    new 
Float:SecUntilExplosion float(get_pcvar_num(cvar_c4_time) - 10); // Calculating when ten seconds is left on the C4 timer
    
set_task(SecUntilExplosion"Bomb_Ten_Seconds_Left"TASKID_BOMB_TEN); // Sets tasks when ten seconds of C4 timer is left 
}

public 
Bomb_Ten_Seconds_Left()
{
    if(
bool_endofround == 1)
        return

    
Play_Music(800);
}

public 
Event_End_Round(id)
{
    
// We get what type of End Round we have...
    
static textmsg[22];
    
get_msg_arg_string(2textmsgcharsmax(textmsg));
    
    
//...and play the appropriate sound to each player according to their team
    
    
if(equali(textmsg"#Terrorists_Win")) //Terrorists Wins
        
Play_Music(1011);
    
    else if(
equali(textmsg"#CTs_Win")) //Counter-Terrorists Wins
        
Play_Music(1021);
    
    else if(
equali(textmsg"#Target_Bombed")) //C4 explodes, eliminates target
        
Play_Music(1011);
        
    else if(
equali(textmsg"#Hostages_Not_Rescued")) //Time ran out and hostages not rescued
        
Play_Music(1011);
    
    else if(
equali(textmsg"#VIP_Assassinated") || equali(textmsg"#VIP_Not_Escaped")) //VIP killed or time ran out and VIP has not escaped
        
Play_Music(1011);
    
    else if(
equali(textmsg"#VIP_Escaped")) //VIP escapes
        
Play_Music(1021);
}

// Plays victory sound for CT when C4 is defused
public Event_Bomb_Defused(id)
{
    if(
bool_endofround == 1)
        return
        
    
Play_Music(1021); 
}

// Plays victory sound for CT when target has not been bombed
public Event_BombTarget_Saved(id)
{
    
Play_Music(1021); 
}

public 
Event_Round_Draw()
{
    
Play_Music(1101);
}

public 
Event_Death()
{
    if(
bool_endofround == 1)
        return

    new 
id read_data(2// Getting index of player who just died
    
    
Format_Music_Folder(id);
    
client_cmd(id"mp3 play ^"%s%s^""player_folder[id], MUSIC[6]);
}

public 
Remove_Tasks()
{
    
//Removing set tasks
    
remove_task(TASKID_ROUND_TEN);
    
remove_task(TASKID_BOMB_TEN);
}

public 
Play_Music(musicteamend)
{
    if(
end == 1)
    {
        if(
team == 1)
            
tscore tscore 1;
        else if(
team == 2)
            
ctscore ctscore 1;
    }

    new 
players[32], num;
    
get_players(playersnum"c");
    for (new 
1num 1i++)
    {
        
Format_Music_Folder(i);
        if(
end == 1)
        {
            if(
team// If one team wins
            
{
                if(
get_user_team(i) == team)
                    
client_cmd(i"mp3 play ^"%s%s^""player_folder[i], MUSIC[10]);
                else
                    
client_cmd(i"mp3 play ^"%s%s^""player_folder[i], MUSIC[11]);
            }
            else 
// When no one wins, everybody loses
                
client_cmd(i"mp3 play ^"%s%s^""player_folder[i], MUSIC[11]);
            
            
bool_endofround 1;
            
bool_bomb_planted 0;
            
Remove_Tasks();
            
            
// The 1st round is when players are still connecting and game has not commenced.
            // To prevent the sound from playing after that, we do this check
            
if(bool_firstround == 1)
            {
                
bool_firstround 0;
                return
            }
        }
        else
            
client_cmd(i"mp3 play ^"%s%s^""player_folder[i], MUSIC[music]);
    }
}

stock Format_Music_Folder(id)
{
    new 
iFolder[45];
    
    if(
player_kit[id] == 1)
    {
        if(
CsTeams:get_user_team(id) == CS_TEAM_T)
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/TER/");
        else if(
CsTeams:get_user_team(id) == CS_TEAM_CT)
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/CT/");
        else
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/CT/");
    }
    else if(
player_kit[id] >> 1)
        
formatex(iFoldercharsmax(iFolder), "media/musickits/%d/"player_kit[id]);
        
    
player_folder[id] = iFolder;
}

stock Match_Point()
{
    new 
windiffscore_dif tscore ctscore;
    
    if(
score_dif <= -1)
        
score_dif score_dif * -1;

    if(
get_pcvar_num(cvar_windiff) >= 2)
        
windiff get_pcvar_num(cvar_windiff) - 1;
    
    if(
score_dif >= windiff)
    {
        
client_cmd(0,"spk %s"MATCHPOINT);
        
set_task(0.5"MatchPoint_Txt");
    }
}

public 
MatchPoint_Txt()
{
    
set_hudmessage(255255255, -1.00.4003.03.51.52.04);
    
show_hudmessage(0"MATCH POINT");

get new sounds on gamebanana

edit: i tested this plugin on cs:cz and it loaded but didnt precache the sounds

Last edited by tarsisd2; 05-24-2017 at 21:44. Reason: error
tarsisd2 is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 05-25-2017 , 09:32   Re: csgo musickit
Reply With Quote #3

There's no precache in that code.
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Ayman Khaled
Senior Member
Join Date: Mar 2017
Location: Palestine
Old 05-25-2017 , 09:53   Re: csgo musickit
Reply With Quote #4

can you precache sounds in tarsisd2 one ?
__________________

Last edited by Ayman Khaled; 05-25-2017 at 09:54.
Ayman Khaled is offline
yas17sin
Veteran Member
Join Date: Oct 2016
Location: Morocco/Sale
Old 05-25-2017 , 12:52   Re: csgo musickit
Reply With Quote #5

just add this part to the current code :

PHP Code:
public plugin_precache()
{
    for( new 
i=0sizeof(MUSIC); i++)
    {
        
precache_sound(MUSIC[i]);
    }

__________________
FINISHED WORKING ON : Attack On Titan Mod (100% Done).

FB Acc : FaceBook Account.

pic: http://prntscr.com/fszkke not good quality

Last edited by yas17sin; 05-25-2017 at 12:52.
yas17sin is offline
Send a message via ICQ to yas17sin
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 05-25-2017 , 13:41   Re: csgo musickit
Reply With Quote #6

PHP Code:
Play_Music(variant00); 
You don't need the 0. Just do Play_Music(variant...)

PHP Code:
    for (new 1num 1i++) 
Different way to loop, but is really needed? Just do the basic way. That's only a point, maybe it's your style. Idk.

PHP Code:
client_cmd(i... 
Use 0 instead of i.

PHP Code:
    if(player_kit[id] == 1)
    {
        if(
CsTeams:get_user_team(id) == CS_TEAM_T)
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/TER/");
        else if(
CsTeams:get_user_team(id) == CS_TEAM_CT)
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/CT/");
        else
            
formatex(iFoldercharsmax(iFolder), "media/musickits/1/CT/");
    } 
Use switch() here.

PHP Code:
    if(equali(textmsg"#Terrorists_Win")) //Terrorists Wins
        
Play_Music(1011);
    
    else if(
equali(textmsg"#CTs_Win")) //Counter-Terrorists Wins
        
Play_Music(1021);
    
    else if(
equali(textmsg"#Target_Bombed")) //C4 explodes, eliminates target
        
Play_Music(1011);
        
    else if(
equali(textmsg"#Hostages_Not_Rescued")) //Time ran out and hostages not rescued
        
Play_Music(1011);
    
    else if(
equali(textmsg"#VIP_Assassinated") || equali(textmsg"#VIP_Not_Escaped")) //VIP killed or time ran out and VIP has not escaped
        
Play_Music(1011);
    
    else if(
equali(textmsg"#VIP_Escaped")) //VIP escapes
        
Play_Music(1021); 
Here too.
__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo
EFFx is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 05-25-2017 , 13:53   Re: csgo musickit
Reply With Quote #7

Quote:
Here too.
Switch string?
__________________

Last edited by OciXCrom; 05-25-2017 at 13:53.
OciXCrom is offline
Send a message via Skype™ to OciXCrom
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 05-25-2017 , 14:03   Re: csgo musickit
Reply With Quote #8

PHP Code:
switch(textmsg[1])
{
    case 
'C'//Counter-Terrorists Wins
    
{
        
Play_Music(1021);
    }
    case 
'H'//Time ran out and hostages not rescued
    
{
        
Play_Music(1011);
    }
    case 
'T':  //Terrorists Wins
    
{
        if(
textmsg[2] == 'e')
        {
            
Play_Music(1011);
        }
        else
        {
            
Play_Music(1011);
        }
    }
    case 
'V':
    {
        if((
textmsg[5] == 'N') || (textmsg[5] == 'A'))  //VIP killed or time ran out and VIP has not escaped
        
{
            
Play_Music(1011);
        }
        else 
//VIP escapes
        
{
            
Play_Music(1021);      
        }
    }

__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo
EFFx is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 05-25-2017 , 14:07   Re: csgo musickit
Reply With Quote #9

The messages aren't filtered, so basically every message in the game will call that event. In case 'C' it can be any message that starts with a C, etc...
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
EFFx
Veteran Member
Join Date: Feb 2016
Location: São Paulo, Brasil
Old 05-25-2017 , 15:11   Re: csgo musickit
Reply With Quote #10

Ah, that's right. My bad.
__________________
• Ranking System • AutoMix 5vs5 System
• Web Ban System • Plugins for free

____________________________________________
For private works:
• Discord: EFFEXo#8850 • Steam: EFFEXo
EFFx is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 11:31.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode