Raised This Month: $90 Target: $400
 22% 

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 , 08: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 08:06.
tomax079 is offline
Send a message via Skype™ to tomax079
CrazY.
Veteran Member
Join Date: May 2015
Location: SP, Brazil
Old Yesterday , 17: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
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 20:20.


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