Raised This Month: $ Target: $400
 0% 

[REQ] Small plugin.


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
JoaoVieira
Senior Member
Join Date: May 2013
Location: Portugal
Old 02-01-2016 , 17:11   Re: [REQ] Small plugin.
Reply With Quote #3

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

#define PLUGIN "Give ammo packs"
#define VERSION "1.0.2"
#define AUTHOR "Fry!+sempz"

#if ADMIN_RESERVATION & ADMIN_MENU
#endif

new g_max_ammo_packs

public plugin_init() 
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
g_max_ammo_packs register_cvar("howmanyammopacksfriend""999999999")
    
    
register_forward(FM_PlayerPreThink"vip_admin_ammo_packs")
}

public 
vip_admin_ammo_packs(id)
{
    for (
id 1id <= 32id++)
    {
        new 
g_ammo_packs zp_get_user_ammo_packs(id)
    
        if (
g_ammo_packs == get_pcvar_num(g_max_ammo_packs))
        {
            
zp_set_user_ammo_packs(idg_ammo_packs 0)
        }        
    }


NOT TESTED
Attached Files
File Type: inc zombieplague.inc (11.2 KB, 104 views)

Last edited by JoaoVieira; 02-01-2016 at 17:15.
JoaoVieira is offline
 



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 23:17.


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