Raised This Month: $51 Target: $400
 12% 

How to trigger TeamInfo


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
KiLLeR.
Senior Member
Join Date: Jul 2014
Location: Bulgaria
Old 04-02-2020 , 09:28   How to trigger TeamInfo
Reply With Quote #1

At first i didn't found anything at the forum about this case.
Why cs_set_user_team doesn't trigger TeamInfo event and how to do it?
Yeah, I know jointeam cmd will trigger the TeamInfo, but that doesn't help me.

Last edited by KiLLeR.; 04-02-2020 at 09:30.
KiLLeR. is offline
Napoleon_be
Veteran Member
Join Date: Jul 2011
Location: Belgium
Old 04-02-2020 , 11:41   Re: How to trigger TeamInfo
Reply With Quote #2

Just call it when nessecary?

PHP Code:
register_event("TeamInfo""TeamInfo""a"); 
PHP Code:
public TeamInfo()
{
    new 
idszTeam[2];
    
    
id read_data(1);
    
read_data(2szTeamcharsmax(szTeam));
    
    switch(
szTeam[0])
    {
        case 
'T'CheckMode(id)
        case 
'C'CheckMode(id)
    }

__________________
Napoleon_be is offline
Send a message via Skype™ to Napoleon_be
KiLLeR.
Senior Member
Join Date: Jul 2014
Location: Bulgaria
Old 04-02-2020 , 13:06   Re: How to trigger TeamInfo
Reply With Quote #3

Bro I don't ask how to register the event or how to use it? My question is why when using cs_set_user_team, the TeamInfo event is never called...
KiLLeR. is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 04-02-2020 , 20:27   Re: How to trigger TeamInfo
Reply With Quote #4

Search bud

https://forums.alliedmods.net/showpo...59&postcount=4
__________________
Bugsy is offline
KiLLeR.
Senior Member
Join Date: Jul 2014
Location: Bulgaria
Old 04-03-2020 , 19:46   Re: How to trigger TeamInfo
Reply With Quote #5

Quote:
Originally Posted by Bugsy View Post
Thanks bro, I'm going to test that.
KiLLeR. is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 04-03-2020 , 20:00   Re: How to trigger TeamInfo
Reply With Quote #6

And bookmark this page, it contains the parameters of all events.

https://wiki.alliedmods.net/Half-life_1_game_events
__________________

Last edited by Bugsy; 04-03-2020 at 20:00.
Bugsy is offline
KiLLeR.
Senior Member
Join Date: Jul 2014
Location: Bulgaria
Old 04-05-2020 , 09:37   Re: How to trigger TeamInfo
Reply With Quote #7

Quote:
Originally Posted by Bugsy View Post
And bookmark this page, it contains the parameters of all events.

https://wiki.alliedmods.net/Half-life_1_game_events
Thanks, thats quite useful. I have tested the stock within the link you gave me, but found a little bug.
PHP Code:
static const szTeams[] = { "UNASSIGNED" "TERRORIST" "CT" "SPECTATOR" };
// >>>
static const szTeams[][] = { "UNASSIGNED" "TERRORIST" "CT" "SPECTATOR" }; 

Last edited by KiLLeR.; 04-05-2020 at 09:38.
KiLLeR. is offline
iceeedr
Veteran Member
Join Date: Apr 2017
Location: Brazil
Old 04-05-2020 , 09:54   Re: How to trigger TeamInfo
Reply With Quote #8

Quote:
Originally Posted by Bugsy View Post
Bugsy, still need on newest amxx dev?
__________________


Quote:
Originally Posted by fysiks View Post
Please stop trying to help. You appear to just be posting random stuff. Wait until you actually understand more about AMX Mod X and how the game works.
https://iceeedr.com.br/
iceeedr is offline
Send a message via Skype™ to iceeedr
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 04-05-2020 , 09:58   Re: How to trigger TeamInfo
Reply With Quote #9

Quote:
Originally Posted by iceeedr View Post
Bugsy, still need on newest amxx dev?
There's an additional "teaminfo" parameter in newer versions that is set to "true" by default:

Code:
native cs_set_user_team(index, any:team, any:model = CS_DONTCHANGE, bool:send_teaminfo = true);

So, no, it's not needed in AMXX > 1.8.2.
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
iceeedr
Veteran Member
Join Date: Apr 2017
Location: Brazil
Old 04-05-2020 , 10:06   Re: How to trigger TeamInfo
Reply With Quote #10

Quote:
Originally Posted by OciXCrom View Post
There's an additional "teaminfo" parameter in newer versions that is set to "true" by default:

Code:
native cs_set_user_team(index, any:team, any:model = CS_DONTCHANGE, bool:send_teaminfo = true);

So, no, it's not needed in AMXX > 1.8.2.
Correct, thanks for the information
__________________


Quote:
Originally Posted by fysiks View Post
Please stop trying to help. You appear to just be posting random stuff. Wait until you actually understand more about AMX Mod X and how the game works.
https://iceeedr.com.br/
iceeedr is offline
Send a message via Skype™ to iceeedr
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 20:02.


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