Raised This Month: $ Target: $400
 0% 

Block Buyzone for specific players while they are in a Buyzone


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Kia
AlliedModders Donor
Join Date: Apr 2010
Location: In a world of madness
Old 06-20-2014 , 03:20   Block Buyzone for specific players while they are in a Buyzone
Reply With Quote #1

Hello everybody,

I want to block the possibility to buy weapons for specific players using this code by now:

PHP Code:
public Message_StatusIcon(iMsgIdiMsgDestid)  
{
    if(
g_bIsZombie[id])
    {
        static 
szIcon[8];  
        
get_msg_arg_string(2szIconcharsmax(szIcon));  
        if( 
equal(szIcon"buyzone") ) 
        {  
            if( 
get_msg_arg_int(1) )  
            {  
                
set_pdata_int(id235get_pdata_int(id235) & ~(1<<0)); 
                return 
PLUGIN_HANDLED;  
            }  
        }
    }
    
    return 
PLUGIN_CONTINUE;  

This works fine, but when a Player gets infected while he is in the buyzone, he can still open the buy menu.
Any solutions for that?
__________________
Kia is offline
 


Thread Tools
Display Modes

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 21:09.


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