Raised This Month: $ Target: $400
 0% 

block "only 1 team change allowed"


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
n0br41ner
Senior Member
Join Date: May 2012
Location: Planet Earth
Old 12-09-2012 , 09:25   block "only 1 team change allowed"
Reply With Quote #1

Any easy way of allowing a user to change teams multiple time per round? It is very good for deathmatch servers.
__________________
n0br41ner is offline
jimaway
Heeeere's Jimmy!
Join Date: Jan 2009
Location: Estonia
Old 12-09-2012 , 10:09   Re: block "only 1 team change allowed"
Reply With Quote #2

Code:
set_pdata_int(id, 125, get_pdata_int(id, 125, 5) & ~(1<<8), 5)
set this after players changes team

Last edited by jimaway; 12-09-2012 at 10:10.
jimaway is offline
n0br41ner
Senior Member
Join Date: May 2012
Location: Planet Earth
Old 12-09-2012 , 11:50   Re: block "only 1 team change allowed"
Reply With Quote #3

Thank you, i will try and test this tomorrow when i get back home.
__________________
n0br41ner is offline
n0br41ner
Senior Member
Join Date: May 2012
Location: Planet Earth
Old 12-09-2012 , 12:37   Re: block "only 1 team change allowed"
Reply With Quote #4

Thank you very much, it seems to be working, i tested it with the following plugin. I switched teams twice but it did not let me, but when i type "test" in chat, i was able to change teams again.

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

public plugin_init( ) {
    
register_clcmd"say test""test" );
}

public 
testid ) {
    
set_pdata_int(id125get_pdata_int(id1255) & ~(1<<8), 5);

__________________

Last edited by n0br41ner; 12-09-2012 at 12:58.
n0br41ner is offline
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 06:37.


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