#include <amxmodx> #include <cstrike> new maxPlayers; new runda; new wygrane_ct; new wygrane_tt; new ilosc_reset; public plugin_init() { register_plugin("Zmiana", "1.0", "FD_GODPL"); register_event("HLTV", "NewRound", "a", "1=0", "2=0"); register_logevent("Restart", 2, "1=Game_Commencing"); register_event("SendAudio", "ct_win", "a", "2&%!MRAD_ctwin"); register_event("SendAudio", "t_win", "a", "2&%!MRAD_terwin"); register_logevent("ShowScore", 2, "1=Round_Start"); } public ct_win() wygrane_ct++; public t_win() wygrane_tt++; public plugin_cfg() maxPlayers = get_maxplayers(); public ShowScore() { if(runda == 14) info(); } public info() { for(new i=1;i<=maxPlayers;i++) { set_hudmessage(255, 255, 255, 0.57, 0.17, 2, 6.0, 5.0, 0.1, 0.2, -1) show_hudmessage(i, "Wyniki Po 12 Rundach Nastepujace: TT - %d, CT - %d", wygrane_tt, wygrane_ct); } wygrane_ct = 0; wygrane_tt = 0; } public NewRound() { runda++; switch(runda) { case 13: ChangeTeam(); case 26: ZmienMape(); } return PLUGIN_CONTINUE; } public ZmienMape() { new mapa[30]; get_cvar_string("amx_nextmap", mapa, charsmax(mapa)); server_cmd("changelevel %s", mapa); } public Restart() runda = 0; public ChangeTeam() { for(new i=1;i<=maxPlayers;i++) { if(!is_user_connected(i) || cs_get_user_team(i) == CS_TEAM_SPECTATOR || cs_get_user_team(i) == CS_TEAM_UNASSIGNED) continue; cs_set_user_team(i, cs_get_user_team(i) == CS_TEAM_T ? CS_TEAM_CT : CS_TEAM_T); cs_user_spawn(i); } set_task(1.0, "Resetuj", _, _, _, "b"); ilosc_reset = 4; return PLUGIN_CONTINUE } public Resetuj() { ilosc_reset--; set_cvar_num("sv_restartround", 1); if(ilosc_reset <= 0) { remove_task(0); set_cvar_num("sv_restartround", 0); client_print(0, print_chat, "[----GAME LIVE !----]"); runda = 13; return PLUGIN_CONTINUE } client_print(0, print_chat, "[----Gramy po %d resetach----]", ilosc_reset); return PLUGIN_CONTINUE }
Proszę zmienić rundy żeby było mr15, zmienic na 3restarty zamiast jednego, ma zostawiać wynik (czyli powiedzmy ze TT wygralo 13:2 w pierwszej polowce, po zmianie teamow CT wygrywa 13:2 czyli stare TT)
po wygranych 16 rundach zmiana mapy,proszę też dodać przy restartach żeby korzystało z esl.cfg
W pluginie chodzi o to że gra się 15 rund,przeżuca teamy,są 3 restarty gra się 16 wygranych rund i jest zmiana mapy.
Będę bardzo wdzięczny za pomoc.
Użytkownik Vixenek edytował ten post 29.04.2013 17:17