Raised This Month: $178 Target: $400
 44% 

Block grenade with X numbers of online players


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
tarsisd2
Senior Member
Join Date: Feb 2016
Location: brazil
Old 06-10-2018 , 19:35   Block grenade with X numbers of online players
Reply With Quote #1

I have seen this plugin somewhere but i can't find it

only allow players to buy grenades, depending on how many players on server, with cvar
and print a msg
[amxx] you are not allowed to buy grenades with less then 10 players on the server

if anyone have it
tarsisd2 is online now
iceeedr
Senior Member
Join Date: Apr 2017
Location: Brazil
Old 06-10-2018 , 20:59   Re: Block grenade with X numbers of online players
Reply With Quote #2

Quote:
Originally Posted by tarsisd2 View Post
I have seen this plugin somewhere but i can't find it

only allow players to buy grenades, depending on how many players on server, with cvar
and print a msg
[amxx] you are not allowed to buy grenades with less then 10 players on the server

if anyone have it
Use this awsome plugin:

https://forums.alliedmods.net/showthread.php?t=149380

Then:

PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <cl_buy>

#define PLUGIN "New Plug-In"
#define VERSION "1.0"
#define AUTHOR "author"


public plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
}

public 
client_buy(idiItem)
{
    if(!
isBuyBlock(iItem))
        return 
PLUGIN_CONTINUE
        
    
if((get_playersnum() >= 9))
        return 
PLUGIN_CONTINUE

    client_print
(id,print_chat"The message you wanted")
    
client_cmd(id,"speak buttons/blip2")
    return 
PLUGIN_HANDLED
}

bool:isBuyBlock(iItem)
{
    switch(
iItem)
    {
        case 
CSW_HEGRENADECSW_FLASHBANGCSW_SMOKEGRENADE:    return true
    
}
    return 
false

iceeedr is offline
Send a message via Skype™ to iceeedr
Reply


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 04:30.


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