Raised This Month: $ Target: $400
 0% 

fix Respawn Bug !


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
monster321
Member
Join Date: Apr 2012
Old 02-27-2015 , 12:10   Re: fix Respawn Bug !
Reply With Quote #1

Try it:

Code:
#include < amxmodx > #include < amxmisc > // Init public plugin_init() {     // Register     register_plugin( "Revive menu", "1.0", "MoNsTeR_KiLL!" )         // Cmds     register_clcmd( "say /revive", "cmd_revive" )     register_clcmd( "revive_menu", "cmd_revive" ) } // Dar freeday public fd_menu( id ) {     if( !is_user_admin( id ) )     {         client_print( id, print_chat, "[ AMXX ] You don't have access to this command." )         return PLUGIN_HANDLED;     }         new menu, name[ 32 ], temp[ 10 ];     menu = menu_create( "\yChoose player:\w", "revive_handler" )         for( new i; i <= 32; i++ )     {         if( is_user_alive( i ) || !is_user_connected( i ) )             continue;                 get_user_name( i, name, 31 )         num_to_str( i, temp, 9 )         menu_additem( menu, name, temp, 0 )     }         menu_display( id, menu, 0 )     return PLUGIN_HANDLED; } public revive_handler( id, menu, item ) {     if( item == MENU_EXIT )     {         menu_destroy( menu )         return PLUGIN_HANDLED;     }         new data[ 6 ], name[ 64 ], access, callback;     menu_item_getinfo( menu, item, access, data, 5, name, 63, callback )     new target = str_to_num( data )         if( !is_user_alive( target ) )     {                 ExecuteHamB( Ham_CS_RoundRespawn, target )         new admin_name[ 32 ], user_name[ 32 ];                 get_user_name( id, admin_name, 31 )         get_user_name( target, user_name, 31 )                 client_print( 0, print_chat, "ADMIN %s: revive %s", admin_name, user_name )     }     else client_print( id, print_chat, "[ AMXX ] You can't use this command in an alive player." )         return PLUGIN_HANDLED; }

Last edited by monster321; 02-28-2015 at 22:13. Reason: mistake
monster321 is offline
Send a message via MSN to monster321 Send a message via Skype™ to monster321
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 23:14.


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