get_players team
How can I get only terrorists or counter-terrorists in get_players()? with corresponding count.
For cstrike. |
Re: get_players team
new iPlayers[32]
new iNum get_players(iPlayers, iNum, "ch" /*Ingnores Bots and HLTV */, "TERRORIST" or "CT") |
Re: get_players team
get_players(players,num,"ceh","TERRORIST");
This returns CTs, too. Edit: This should select one player as a random T: PHP Code:
|
Re: get_players team
PHP Code:
|
Re: get_players team
Quote:
Does it have any return value or smth? Code:
if( !pnum ) |
Re: get_players team
Dude why do you even bother restoring a 10 years old thread? :O
Either way, if there are no players (!pnum) the function returns -1. |
Re: get_players team
Quote:
pnum is the number of players. If pnum is 0(!pnum is the same as pnum == 0) then there are no players so a random player cannot be retrieved. |
Re: get_players team
Yeah, I give him credit for searching first.
Upri98, to use that RandomPlayer function you would do something like: PHP Code:
|
| All times are GMT -4. The time now is 14:56. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.