Raised This Month: $51 Target: $400
 12% 

Adding plugin in vip menu


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
shubhamgulati12
Senior Member
Join Date: Oct 2010
Location: Inida The Holy Place!!
Old 04-29-2012 , 02:51   Adding plugin in vip menu
Reply With Quote #1

PHP Code:
#include <amxmodx>
#include <zp50_core>
#include <zp50_items>
#include <zp50_class_nemesis>
#include <zp50_class_survivor>

new g_nemesisg_survivor

public plugin_init()
{
        
register_plugin("[ZP] Extra: Surv or Nem""1""snaker-beatter")
        
        
g_nemesis zp_items_register("Buy Nem"30)
        
g_survivor zp_items_register("Buy Surv"25)
}

public 
zp_fw_items_select_pre(iditemid)
{
    if (
itemid == g_nemesis)
    {
        if (!
zp_core_is_zombie(id) || zp_class_nemesis_get(id) || zp_class_survivor_get(id))
            return 
ZP_ITEM_DONT_SHOW;
            
        return 
ZP_ITEM_AVAILABLE;
    }
    if (
itemid == g_survivor)
    {
        if (
zp_core_is_zombie(id) || zp_class_survivor_get(id) || zp_class_nemesis_get(id))
            return 
ZP_ITEM_DONT_SHOW;
            
        return 
ZP_ITEM_AVAILABLE;
    }
    
    return 
ZP_ITEM_AVAILABLE;
}

public 
zp_fw_items_select_post(iditemid)
{
    if (
itemid == g_nemesis)
    {
        
zp_class_nemesis_set(id)
    }
    if (
itemid == g_survivor)
    {
        
zp_class_survivor_set(id)
    }

I tried this plugin to be added in vip but was unsuccessful..
can you please help me and teach it..
i saw this http://forums.alliedmods.net/showpos...6&postcount=99
and tried but on compiling message comes could not allocate zp_buy_addons.amx..

This is my scripting what i made for vip -

PHP Code:
#include <zmvip>
#include <amxmodx>
#include <zp50_core>
#include <zp50_items>
#include <zp50_class_nemesis>
#include <zp50_class_survivor>

new g_nemesisg_survivor

public plugin_init()
{
        
zv_register_extra_item("[ZP] Extra: Surv or Nem""1""snaker-beatter")
        
        
g_nemesis zp_items_register("Buy Nem"30)
        
g_survivor zp_items_register("Buy Surv"25)
}

public 
zp_fw_items_select_pre(iditemid)
{
    if (
itemid == g_nemesis)
    {
        if (!
zp_core_is_zombie(id) || zp_class_nemesis_get(id) || zp_class_survivor_get(id))
            return 
ZP_ITEM_DONT_SHOW;
            
        return 
ZP_ITEM_AVAILABLE;
    }
    if (
itemid == g_survivor)
    {
        if (
zp_core_is_zombie(id) || zp_class_survivor_get(id) || zp_class_nemesis_get(id))
            return 
ZP_ITEM_DONT_SHOW;
            
        return 
ZP_ITEM_AVAILABLE;
    }
    
    return 
ZP_ITEM_AVAILABLE;
}

public 
zv_extra_item_selected(iditemid)
{
    if (
itemid == g_nemesis)
    {
        
zp_class_nemesis_set(id)
    }
    if (
itemid == g_survivor)
    {
        
zp_class_survivor_set(id)
    }

__________________

Join Free File hosting - http://db.tt/VvebKSSW
[Free 2 GB cloud storage]

Last edited by shubhamgulati12; 04-29-2012 at 02:52.
shubhamgulati12 is offline
ownedin3d
Senior Member
Join Date: Jul 2011
Old 04-29-2012 , 07:16   Re: Adding plugin in vip menu
Reply With Quote #2

go in to the tutorial section, i made a tutorial try following that.
__________________
ownedin3d 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 04:45.


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