AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Suggestions / Requests (https://forums.alliedmods.net/forumdisplay.php?f=12)
-   -   show all players in scoreboard of team terrorist (https://forums.alliedmods.net/showthread.php?t=322450)

666 03-27-2020 12:49

show all players in scoreboard of team terrorist
 
I tried with this code that I saw made of bugsy, it works well it shows all the CT players in the TERRORIST team on the scoreboard, but here comes the problem to the CT players it sets the TERRORIST model and it is what I don't want

PHP Code:

#include <amxmodx>

public plugin_init() 
{
    
register_messageget_user_msgid"TeamInfo" ) , "TeamInfo" );
}

public 
TeamInfo()
{
     
set_msg_arg_string"TERRORIST" );



Napoleon_be 03-27-2020 13:00

Re: show all players in scoreboard of team terrorist
 
Try this

PHP Code:

#include <amxmodx>
#include <cstrike>

public plugin_init() 
{
    
register_messageget_user_msgid"TeamInfo" ) , "TeamInfo" );
}

public 
TeamInfo()
{
    new 
iPlayers[32], iNum;
    
get_players(iPlayersiNum"ae""TERRORIST");
    
    
set_msg_arg_string"TERRORIST" );
    
    for(new 
iiNumi++)
    {
        
cs_reset_user_model(iPlayers[i]);
    }



666 03-27-2020 13:48

Re: show all players in scoreboard of team terrorist
 
Quote:

Originally Posted by Napoleon_be (Post 2688869)
Try this

PHP Code:

#include <amxmodx>
#include <cstrike>

public plugin_init() 
{
    
register_messageget_user_msgid"TeamInfo" ) , "TeamInfo" );
}

public 
TeamInfo()
{
    new 
iPlayers[32], iNum;
    
get_players(iPlayersiNum"ae""TERRORIST");
    
    
set_msg_arg_string"TERRORIST" );
    
    for(new 
iiNumi++)
    {
        
cs_reset_user_model(iPlayers[i]);
    }



it had no effect :/

666 03-29-2020 13:44

Re: show all players in scoreboard of team terrorist
 
I want to do it once they enter any team. I made this code. I do not know if it's ok.

PHP Code:

#include <amxmodx>

public plugin_init() 
{
    
register_plugin("1","2","3");
    
    
register_message(get_user_msgid("TeamInfo"),"TeamInfo");
}

public 
TeamInfo()
{
    new 
id get_msg_arg_int(1);
    
    if(!(
<= get_user_team(id) <= 2))
        return 
PLUGIN_HANDLED;
    
    
set_msg_arg_string(2,"TERRORIST");
    
    return 
PLUGIN_CONTINUE;




All times are GMT -4. The time now is 10:00.

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