Raised This Month: $ Target: $400
 0% 

Random_num in no specific index forward


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Craxor
Veteran Member
Join Date: Jan 2016
Location: Romania
Old 01-15-2017 , 12:34   Re: Random_num in no specific index forward
Reply With Quote #2

Test this one:

PHP Code:
#include <amxmodx>

public plugin_init( )
{
    
register_clcmd"say /test" "test" );
}

public 
testid )
{
    new 
szName[32];
    
get_user_nameRandomPlayer() , szNamecharsmaxszName ) );

    
client_printid print_chat"The name of a random players is %s" szName );
}

// Return the ID of a random ALIVE player
RandomPlayer()
{
    new 
Players[32] , Num;

    
get_playersPlayersNum"a" );

    return 
PlayersrandomNum ) ]; 

__________________
Project: Among Us

Last edited by Craxor; 01-15-2017 at 12:37.
Craxor is offline
Send a message via ICQ to Craxor
 



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 20:56.


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