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

API Scripting Help Plugin uses an unknown function (name "zv_register_zombie_class")


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
tomax079
Member
Join Date: Apr 2009
Location: Lithuania
Old 03-14-2019 , 09:02   Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #1

Hello everyone,

i wanted to use Bullet Proof Zombie class for my server, but when i'm want to use it i'm getting error
Code:
[AMXX] Plugin "zp_zclass_bullet_proof.amxx" failed to load: Plugin uses an unknown function (name "zv_register_zombie_class") - check your modules.ini.
What should i do to fix it? Can some one help me?
PHP Code:
#include <amxmodx>
#include <fakemeta>
#include <hamsandwich>
#include <zombieplague>
#include <zm_vip>
 
// Bullet Proof Zombie
new const zclass_name[] = { "Zombie Bullet Proof" }
new const 
zclass_info[] = { "Only hurts with secondary weapons" }
new const 
zclass_model[] = { "Bullet_Proof" }
new const 
zclass_clawmodel[] = { "v_bulletproof_claws.mdl" }
const 
zclass_health 1100
const zclass_speed 350
const Float:zclass_gravity 0.80
const Float:zclass_knockback 1.0
 
new gBulletProof
 
public plugin_init()
{  
    
register_plugin("[ZP] ZP Class: Bullet Proof""0.1""DJHD!")  
     
    
RegisterHam(Ham_TraceAttack"player""fw_Player_TraceAttack")
}
 
public 
plugin_precache()
    
gBulletProof zp_register_zombie_class(zclass_namezclass_infozclass_modelzclass_clawmodelzclass_healthzclass_speedzclass_gravityzclass_knockback)
 
public 
zp_user_infected_post(idinfector)
{
    if (
zp_get_user_zombie_class(id) == gBulletProof)
    {
        if(
zp_get_user_nemesis(id))
            return
         
        
print_chatColor(id"\g[ZP]\n Remember only you will hurt the secondary weapons.")  
    }
}
 
public 
fw_Player_TraceAttack(iVictimiAttackerFloat:flDamageFloat:vecDirection[3], iTriDamageType)
{    
    if(!
is_user_alive(iVictim) || !is_user_alive(iAttacker))
    return 
HAM_IGNORED;
     
    if(
zp_get_user_nemesis(iVictim))
        return 
HAM_IGNORED;
         
    if(
zp_get_user_survivor(iAttacker))
        return 
HAM_IGNORED;
     
    if(
zp_get_user_zombie_class(iVictim) == gBulletProof)
    {                
        if (
get_user_weapon(iAttacker) == CSW_SCOUT || get_user_weapon(iAttacker) == CSW_XM1014
        
|| get_user_weapon(iAttacker) == CSW_MAC10|| get_user_weapon(iAttacker) == CSW_AUG
        
|| get_user_weapon(iAttacker) == CSW_UMP45 || get_user_weapon(iAttacker) == CSW_SG550
        
|| get_user_weapon(iAttacker) == CSW_GALI || get_user_weapon(iAttacker) == CSW_FAMAS
        
|| get_user_weapon(iAttacker) == CSW_AWP || get_user_weapon(iAttacker) == CSW_MP5NAVY
        
|| get_user_weapon(iAttacker) == CSW_M249 || get_user_weapon(iAttacker) == CSW_M3
        
|| get_user_weapon(iAttacker) == CSW_M4A1 || get_user_weapon(iAttacker) == CSW_TMP
        
|| get_user_weapon(iAttacker) == CSW_G3SG1 || get_user_weapon(iAttacker) == CSW_SG552
        
|| get_user_weapon(iAttacker) == CSW_AK47 || get_user_weapon(iAttacker) == CSW_P90)
        {            
            new 
Float:vecEndPos[3]
            
get_tr2(iTrTR_vecEndPosvecEndPos)
 
            
engfunc(EngFunc_MessageBeginMSG_PVSSVC_TEMPENTITYvecEndPos0)
            
write_byte(TE_SPARKS// TE iId
            
engfunc(EngFunc_WriteCoordvecEndPos[0]) // x
            
engfunc(EngFunc_WriteCoordvecEndPos[1]) // y
            
engfunc(EngFunc_WriteCoordvecEndPos[2]) // z
            
message_end()
                     
            return 
HAM_SUPERCEDE;
        }
         
    }
    return 
HAM_HANDLED
}
 
 
stock print_chatColor(const id, const input[], any:...)
{
    new 
msg[191], players[32], count 1;
    
vformat(msg,190,input,3);
    
replace_all(msg,190,"\g","^4");// green
    
replace_all(msg,190,"\n","^1");// normal
    
replace_all(msg,190,"\t","^3");// team
     
    
if (idplayers[0] = id; else get_players(players,count,"ch");
    for (new 
i=0;i<count;i++)
        if (
is_user_connected(players[i]))
    {
        
message_begin(MSG_ONE_UNRELIABLE,get_user_msgid("SayText"),_,players[i]);
        
write_byte(players[i]);
        
write_string(msg);
        
message_end();
    }
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang13322\\ f0\\ fs16 \n\\ par }
*/ 
Original plugin thread: https://forums.alliedmods.net/showthread.php?t=181260

Last edited by tomax079; 03-14-2019 at 09:06.
tomax079 is offline
Send a message via Skype™ to tomax079
CrazY.
Veteran Member
Join Date: May 2015
Location: SP, Brazil
Old 03-20-2019 , 18:42   Re: Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #2

zm_vip is not even being used so remove it.

Code:
#include <zm_vip>
__________________
Accepting private $$$ plugins requests.

@Steam: crazy770
@Discord: CrazY.#5317

Website | Channel

CrazY. is offline
tomax079
Member
Join Date: Apr 2009
Location: Lithuania
Old 03-25-2019 , 13:26   Re: Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #3

MAKE VIP EXTRA ITEMS / CLASSES:
To set item or class to work with this plugin, do steps:
Open your item or class .sma file.
At the top, where all #include are, add #include <zm_vip> as the last of all includes. Don't change anything more!
Compile plugin, add .amxx file to plugins folder.
Write plugin file name (with .amxx extension) in configs/plugins-zp_zm_vip.ini file at the end.
Save file. Restart server
Done!
tomax079 is offline
Send a message via Skype™ to tomax079
CrazY.
Veteran Member
Join Date: May 2015
Location: SP, Brazil
Old 03-25-2019 , 14:14   Re: Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #4

Are you sure you enabled the vip plugin?
__________________
Accepting private $$$ plugins requests.

@Steam: crazy770
@Discord: CrazY.#5317

Website | Channel

CrazY. is offline
HiDeath
Senior Member
Join Date: Aug 2018
Old 03-25-2019 , 23:01   Re: Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #5

if u are using the 1.7.2 version use this tutorial to add the items

https://forums.alliedmods.net/showpo...6&postcount=99

Note that you should have .inc file in include folder before compiling

Last edited by HiDeath; 03-25-2019 at 23:02.
HiDeath is offline
tomax079
Member
Join Date: Apr 2009
Location: Lithuania
Old 03-26-2019 , 10:24   Re: Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #6

Quote:
Originally Posted by CrazY. View Post
Are you sure you enabled the vip plugin?
Yes i'm sure i enabled vip plugin.
As i think the problem is that zombie class don't have?
Code:
zp_register_extra_item( g_item_name, g_item_cost, ZP_TEAM_HUMAN)
tomax079 is offline
Send a message via Skype™ to tomax079
HiDeath
Senior Member
Join Date: Aug 2018
Old 03-27-2019 , 12:30   Re: Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #7

Quote:
Originally Posted by tomax079 View Post
Yes i'm sure i enabled vip plugin.
As i think the problem is that zombie class don't have?
Code:
zp_register_extra_item( g_item_name, g_item_cost, ZP_TEAM_HUMAN)
Yeah classes don't have tho , try this one

http://zppv.boards.net/thread/1509/t...ra-items-class
HiDeath is offline
HiDeath
Senior Member
Join Date: Aug 2018
Old 03-27-2019 , 14:57   Re: Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #8

https://forums.alliedmods.net/showpo...&postcount=171

The original post
HiDeath is offline
tomax079
Member
Join Date: Apr 2009
Location: Lithuania
Old 03-29-2019 , 13:33   Re: Plugin uses an unknown function (name "zv_register_zombie_class")
Reply With Quote #9

Thanks guys!
tomax079 is offline
Send a message via Skype™ to tomax079
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 02:36.


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