Raised This Month: $ Target: $400
 0% 

[Request] AUTO restart round if player enter


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
DJEarthQuake
Veteran Member
Join Date: Jan 2014
Location: Astral planes
Old 02-24-2023 , 11:32   Re: [Request] AUTO restart round if player enter
Reply With Quote #3

Code:
/*CS/CZ restart round mono-to-duo, Idea by: MeliMeli*/ #include amxmodx #define  PLUGIN   "Restarting Round" #define  VERSION  "1.0.3" #define  AUTHOR   "SPiNX" #define MAX_PLAYERS 32 new g_zombies new bool:bRestarted, Xcvar_bot; new bool:bBot[MAX_PLAYERS +1]; new const SzCMD[]="sv_restartround 2" public plugin_init() {     register_plugin(PLUGIN, VERSION, AUTHOR)     Xcvar_bot=register_cvar("mp_two_bot", "1")     /*Zombie leave as 1 to fix round to include bots.*/ } public client_putinserver(id) {     bBot[id] = is_user_bot(id) ? true : false     if(bBot[id] && get_pcvar_num(Xcvar_bot) || !bBot[id] && !get_pcvar_num(Xcvar_bot))     {         g_zombies++         if(g_zombies  == 2 && !bRestarted)         {             bRestarted = true             console_cmd( 0, SzCMD )             console_cmd( 0, "say ^"%s, %s by %s.^"", PLUGIN, VERSION, AUTHOR )         }     } } public client_disconnected(id) {     if(bBot[id] && get_pcvar_num(Xcvar_bot) || !bBot[id] && !get_pcvar_num(Xcvar_bot))     {         g_zombies--         if(g_zombies < 2 && bRestarted)         bRestarted   = false     } }
__________________

Last edited by DJEarthQuake; 03-06-2023 at 07:18. Reason: remove command
DJEarthQuake is offline
 



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 10:14.


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