Raised This Month: $ Target: $400
 0% 

get_players work of both teams


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
kostov
Member
Join Date: Jan 2010
Location: Bulgaria, Sofia
Old 06-15-2010 , 14:23   get_players work of both teams
Reply With Quote #1

h1

What will be the function get_players work of both teams. I tried:

PHP Code:
get_players(iPlayersiNum"ache" "CT" "TERRORIST"
But not working. Tnx
kostov is offline
Old 06-15-2010, 14:31
NiHiLaNTh
This message has been deleted by NiHiLaNTh.
#8 SickneSS
BANNED
Join Date: Sep 2008
Location: Here
Old 06-15-2010 , 14:40   Re: get_players work of both teams
Reply With Quote #3

Why just don't use like that...

get_players( iPlayers , iNum , "ach" ) ?
#8 SickneSS is offline
Send a message via MSN to #8 SickneSS Send a message via Skype™ to #8 SickneSS
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 06-15-2010 , 14:43   Re: get_players work of both teams
Reply With Quote #4

PHP Code:
new players[32], pnum
new tcountctcount
get_players
(playerspnum"ach"// No team or something

//example to count ct's and t's
for(new 0pnumi++)
{
    new 
tempid players[i]

    if(
get_user_team(tempid) == 1)
        
tcount++

    if(
get_user_team(tempid) == 2)
        
ctcount++
}

client_print(0print_chat"there are %i Terrorists and %i ct's alive"tcountctcount
http://www.amxmodx.org/funcwiki.php?go=func&id=174
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
kostov
Member
Join Date: Jan 2010
Location: Bulgaria, Sofia
Old 06-15-2010 , 14:52   Re: get_players work of both teams
Reply With Quote #5

I want to work only between players from both teams and not between the two teams
kostov is offline
drekes
Veteran Member
Join Date: Jul 2009
Location: Vault 11
Old 06-15-2010 , 15:03   Re: get_players work of both teams
Reply With Quote #6

Quote:
Originally Posted by kostov View Post
I want to work only between players from both teams and not between the two teams
how do you mean?
The code i gave you check works with both teams, then checks the teams in the loop
__________________

Quote:
Originally Posted by nikhilgupta345 View Post
You're retarded.
drekes is offline
Send a message via MSN to drekes
kostov
Member
Join Date: Jan 2010
Location: Bulgaria, Sofia
Old 06-15-2010 , 15:07   Re: get_players work of both teams
Reply With Quote #7

This is SemiClip Deathrun Manager by Xpaw. I want to do only work between players in teams rather than between teams

PHP Code:
#include <amxmodx>
#include <fakemeta>

new g_iSemiClip[33]

public 
plugin_init()
{
    
register_plugin("""""")
    
    
register_forwardFM_StartFrame,    "FwdStartFrame");
    
register_forwardFM_AddToFullPack,    "FwdFullPack",   );
}

public 
FwdFullPackeseenthostflagsplayerpSet ) {
    if( 
player && g_iSemiClipent ] && g_iSemiCliphost ] ) {
        
set_esesES_SolidSOLID_NOT );
        
set_esesES_RenderModekRenderTransAlpha );
        
set_esesES_RenderAmt30 );}
    return 
FMRES_IGNORED;
}

public 
FwdStartFrame(id) {
    static 
iPlayers[32], iNumiPlayeriPlayer2ij;
    
get_players(iPlayersiNum"ache""CT")
    
arrayset(g_iSemiClip032);
    if(
iNum <= 1) return FMRES_IGNORED;
    for(
0iNumi++) {
        
iPlayer iPlayers];
        for(
0iNumj++) {
            
iPlayer2 iPlayers];
            if(
iPlayer == iPlayer2)
                continue;
            if(
g_iSemiClipiPlayer ] && g_iSemiClipiPlayer2 ] )
                continue;
            if(
fm_entity_rangeiPlayeriPlayer2 ) < 128) {
                
g_iSemiClipiPlayer ]    = true;
                
g_iSemiClipiPlayer2 ]    = true;}}}
    for(
0iNumi++) {
        
iPlayer iPlayers[i];
        
set_pev(iPlayerpev_solidg_iSemiClipiPlayer ] ? SOLID_NOT SOLID_SLIDEBOX);}
    return 
FMRES_IGNORED;
}

stock Float:fm_entity_range(ent1ent2){
    new 
Float:origin1[3], Float:origin2[3]
    
pev(ent1pev_originorigin1)
    
pev(ent2pev_originorigin2)
    return 
get_distance_f(origin1origin2)

kostov is offline
GXLZPGX
Veteran Member
Join Date: Sep 2009
Old 06-15-2010 , 18:39   Re: get_players work of both teams
Reply With Quote #8

Quote:
Originally Posted by kostov View Post
This is SemiClip Deathrun Manager by Xpaw. I want to do only work between players in teams rather than between teams

PHP Code:
#include <amxmodx>
#include <fakemeta>

new g_iSemiClip[33]

public 
plugin_init()
{
    
register_plugin("""""")
    
    
register_forwardFM_StartFrame,    "FwdStartFrame");
    
register_forwardFM_AddToFullPack,    "FwdFullPack",   );
}

public 
FwdFullPackeseenthostflagsplayerpSet ) {
    if( 
player && g_iSemiClipent ] && g_iSemiCliphost ] ) {
        
set_esesES_SolidSOLID_NOT );
        
set_esesES_RenderModekRenderTransAlpha );
        
set_esesES_RenderAmt30 );}
    return 
FMRES_IGNORED;
}

public 
FwdStartFrame(id) {
    static 
iPlayers[32], iNumiPlayeriPlayer2ij;
    
get_players(iPlayersiNum"ache""CT")
    
arrayset(g_iSemiClip032);
    if(
iNum <= 1) return FMRES_IGNORED;
    for(
0iNumi++) {
        
iPlayer iPlayers];
        for(
0iNumj++) {
            
iPlayer2 iPlayers];
            if(
iPlayer == iPlayer2)
                continue;
            if(
g_iSemiClipiPlayer ] && g_iSemiClipiPlayer2 ] )
                continue;
            if(
fm_entity_rangeiPlayeriPlayer2 ) < 128) {
                
g_iSemiClipiPlayer ]    = true;
                
g_iSemiClipiPlayer2 ]    = true;}}}
    for(
0iNumi++) {
        
iPlayer iPlayers[i];
        
set_pev(iPlayerpev_solidg_iSemiClipiPlayer ] ? SOLID_NOT SOLID_SLIDEBOX);}
    return 
FMRES_IGNORED;
}

stock Float:fm_entity_range(ent1ent2){
    new 
Float:origin1[3], Float:origin2[3]
    
pev(ent1pev_originorigin1)
    
pev(ent2pev_originorigin2)
    return 
get_distance_f(origin1origin2)

So your saying you don't want CT's to semiclip through T's?
__________________
Currently accepting payment US DOLLARS ONLY for custom plugins, contact me through PM.
GXLZPGX is offline
Alucard^
AMXX Moderator: Others
Join Date: Sep 2007
Location: Street
Old 06-15-2010 , 20:53   Re: get_players work of both teams
Reply With Quote #9

Look into team semiclips, like Jon's HnS plugin...
__________________
Approved Plugins - Steam Profile

Public non-terminated projects:
All Admins Menu, HLTV parameters, Subnick,
Second Password (cool style), InfoZone,
Binary C4 plant/defuse, and more...

Private projects:
NoSpec (+menu), NV Surf Management,
PM Adanved System, KZ longjump2, and more...
Alucard^ is offline
Send a message via Skype™ to Alucard^
K.K.Lv
Veteran Member
Join Date: Aug 2008
Location: GameFolder
Old 06-16-2010 , 03:21   Re: get_players work of both teams
Reply With Quote #10

e...
I still don't understand what did you say !
__________________
QQ:116268742
K.K.Lv is offline
Send a message via MSN to K.K.Lv
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 14:49.


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