Quote:
Originally Posted by Devil259
Example for terrorist :
Code:
new playersT[ 32 ] , num , i , tCount get_players( playersT , num , "ach" , "TERRORIST" ) for( i = 0; i < num; i++ ) { tCount++ } if( tCount == 1 ) { // do something }
That should works.
|
CAn i do it like
PHP Code:
/* Plugin generated by AMXX-Studio */
#include <amxmodx>
#include <amxmisc>
#include <cstrike>
#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
}
public Wow()
{
new playersT[ 32 ] , num , i , tCount
new name = get_user_name
get_players( playersT , num , "ach" , "TERRORIST" )
for( i = 0; i < num; i++ )
{
tCount++
}
if( tCount == 1 )
{
client_print(0, print_chat,"%s Is the last Vampire!",name)
}
}
public Woo()
{
new playersCT[ 32 ] , num , i ,ctCount
new namee = get_user_name
get_players(playersCT , num , "ach" , "COUNTER-TERRORST")
for(i = 0; i < num; i++ )
{
ctCount++
}
if(ctCount == 1 )
}
client_print(0, print_chat,"%s Is The last humen Eat HIM!",namee)
}