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

Help / Support Buy Nemesis & Survivor for ZP 5.0.7


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
bnk
Junior Member
Join Date: Sep 2011
Location: Szazhalombatta, Hungary
Old 12-18-2011 , 10:52   Buy Nemesis & Survivor for ZP 5.0.7
Reply With Quote #1

Hello everybody!

I can't rewrite the zp_extra_nemesis and zp_extra_survivor plugin to zp 5.0.7.


Can anyone convert these plugins???:
zp_extra_nemesis.sma
zp_extra_survivor.sma
__________________
--- Sorry for My bad English! ---

--- My zombie server!: 91.82.84.253:27020 ---

Last edited by bnk; 12-18-2011 at 14:20.
bnk is offline
Snaker beatter
Veteran Member
Join Date: Sep 2011
Location: Manila, Philippines
Old 12-18-2011 , 21:05   Re: Buy Nemesis & Survivor for ZP 5.0.7
Reply With Quote #2

Try this UNTESTED

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)
    }

__________________

Last edited by Snaker beatter; 12-18-2011 at 21:06.
Snaker beatter is offline
GmodX8000
New Member
Join Date: Feb 2018
Location: Lupeni,Hunedoara,Romania
Old 02-18-2018 , 11:35   Re: Buy Nemesis & Survivor for ZP 5.0.7
Reply With Quote #3

Quote:
Originally Posted by Snaker beatter View Post
Try this UNTESTED

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)
    }

Hi . I'm new here . I want to say something . You must delete the "!" from "if (!zp_core_is_zombie(id) || zp_class_nemesis_get(id) || zp_class_survivor_get(id))" in order to show the items "Buy Surv" and "Buy Nem" in the ZP Extra Items menu . And also i have tested this plugin and works perfectly .

Last edited by GmodX8000; 02-18-2018 at 11:37. Reason: I forget to say something.
GmodX8000 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:54.


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