Block Buyzone for specific players while they are in a Buyzone
Hello everybody,
I want to block the possibility to buy weapons for specific players using this code by now: PHP Code:
Any solutions for that? |
Re: Block Buyzone for specific players while they are in a Buyzone
I remember somewhere seeing function fm_cs_set_user_nobuy. Basically its the same as this:
Code:
set_pdata_int(id, 235, get_pdata_int(id, 235) & ~(1<<0)); So you need to remove buyzone from player zone bitsum on infect. |
Re: Block Buyzone for specific players while they are in a Buyzone
Does not seem to work for me, they can still buy.
|
Re: Block Buyzone for specific players while they are in a Buyzone
Working for me
PHP Code:
|
Re: Block Buyzone for specific players while they are in a Buyzone
Quote:
|
Re: Block Buyzone for specific players while they are in a Buyzone
Said test while in buyzone and i was not able to buy, though the status icon of buyzone was still there
PHP Code:
|
Re: Block Buyzone for specific players while they are in a Buyzone
If you want to use the buyzone bitmask you should take a look at your zombie plugin. It probably provides a forward like "PlayerInfected" or something similar. You need to use that forward to also remove the buyzone bitflag if the player is already inside it.
The easiest way would be using CS_OnBuy from AMXX 1.8.3. Alternatively you can use the plugin and API made by ConnorMcLeod: https://forums.alliedmods.net/showthread.php?t=149380 |
Re: Block Buyzone for specific players while they are in a Buyzone
Found a way to remove buyzone icon from screen.. hope it helps you.
PHP Code:
PHP Code:
|
Re: Block Buyzone for specific players while they are in a Buyzone
When user gets infected, use this:
PHP Code:
2 native calls v/s a lot of message related natives, wonderful |
Re: Block Buyzone for specific players while they are in a Buyzone
Will update my plugin, thanks. :)
|
| All times are GMT -4. The time now is 21:09. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.