Raised This Month: $153 Target: $400
 38% 

Biohazard v2.00 Beta 3b (Zombie Mod)


Post New Thread Reply   
 
Thread Tools Display Modes
Indigozm
Junior Member
Join Date: Nov 2017
Old 12-14-2018 , 00:49   Re: Biohazard v2.00 Beta 3b (Zombie Mod)
Reply With Quote #4071

Krtola, Looks great!
__________________
Indigozm is offline
Send a message via ICQ to Indigozm Send a message via Skype™ to Indigozm
Krtola
Veteran Member
Join Date: Oct 2013
Location: Serbia
Old 04-25-2019 , 07:30   Re: Biohazard v2.00 Beta 3b (Zombie Mod)
Reply With Quote #4072

https://forums.alliedmods.net/showthread.php?t=215468

Dasher zombie for biohazard mod.

I set that every zombie has this ability( because I do not use classes but zombie evolution).

If somebody needs for particular class,maybe we can adjust it.

PHP Code:
#include <amxmodx>
#include <engine>
#include <fakemeta_util>
#include <biohazard>

new bool:g_cooldown[33], g_rushing[33], cvar_rush

public plugin_precache()
{
    
register_plugin("[BIO] Class: Rusher Zombie""1.0""Catastrophe")
        
register_clcmd("drop","do_rush")
          
        
cvar_rush register_cvar("rush_cooldown","20.0")      
}

public 
do_rush(ent)
{
    if(!
is_user_alive(ent) || g_cooldown[ent] || !is_user_zombie(ent))
        return

        if(!(
pev(entpev_flags) & FL_ONGROUND))    
                return

        
g_cooldown[ent] = true
        g_rushing
[ent] = true

    set_task
(0.1"rush_now"ent)
        
        
set_task(get_pcvar_float(cvar_rush),"reset_cooldown",ent)
        
set_task(1.0,"resetmd",ent
}

public 
rush_now(ent)
{    
    if(!
is_user_alive(ent))
        return
    
    static 
Float:Origin[3]
    
get_position(ent1000.00.00.0Origin)
    
    
hook_ent2(entOrigin2000.0)
}

public 
reset_cooldown(id)
{
       
g_cooldown[id] = false
}

public 
resetmd(id)
{
       
g_rushing[id] = false      
}

stock get_position(entFloat:forwFloat:rightFloat:upFloat:vStart[])
{
    new 
Float:vOrigin[3], Float:vAngle[3], Float:vForward[3], Float:vRight[3], Float:vUp[3]
    
    
pev(entpev_originvOrigin)
    
pev(entpev_view_ofs,vUp//for player
    
xs_vec_add(vOrigin,vUp,vOrigin)
    
pev(entpev_v_anglevAngle// if normal entity ,use pev_angles
    
    
vAngle[0] = 0.0
    
    angle_vector
(vAngle,ANGLEVECTOR_FORWARD,vForward//or use EngFunc_AngleVectors
    
angle_vector(vAngle,ANGLEVECTOR_RIGHT,vRight)
    
angle_vector(vAngle,ANGLEVECTOR_UP,vUp)
    
    
vStart[0] = vOrigin[0] + vForward[0] * forw vRight[0] * right vUp[0] * up
    vStart
[1] = vOrigin[1] + vForward[1] * forw vRight[1] * right vUp[1] * up
    vStart
[2] = vOrigin[2] + vForward[2] * forw vRight[2] * right vUp[2] * up
}

stock hook_ent2(entFloat:VicOrigin[3], Float:speed)
{
    static 
Float:fl_Velocity[3]
    static 
Float:EntOrigin[3]
    
    
pev(entpev_originEntOrigin)
    
    static 
Float:distance_f
    distance_f 
get_distance_f(EntOriginVicOrigin)
    
    if (
distance_f 60.0)
    {
        new 
Float:fl_Time distance_f speed
        
        fl_Velocity
[0] = (VicOrigin[0] - EntOrigin[0]) / fl_Time
        fl_Velocity
[1] = (VicOrigin[1] - EntOrigin[1]) / fl_Time
        fl_Velocity
[2] = (VicOrigin[2] - EntOrigin[2]) / fl_Time
    
} else {
        
fl_Velocity[0] = 0.0
        fl_Velocity
[1] = 0.0
        fl_Velocity
[2] = 0.0
    
}

    
entity_set_vector(entEV_VEC_velocityfl_Velocity)

https://forums.alliedmods.net/showthread.php?t=150283

Houndeye Zombie for Biohazard mod.

I set that every zombie has this ability( because I do not use classes but zombie evolution).

If somebody needs for particular class,maybe we can adjust it.

PHP Code:
/*                Houndeye Zombie v0.4
                    By Morte
                    
    -. Description: Blast player and make it fly.
    
    -. Cvars: zp_houndeye_timeblast 2.5 (Time to Blast)
          zp_houndeye_radius 150.0 (Blast Radius)
          zp_houndeye_infect_blast 0 (Blast infect players)
          zp_houndeye_damage 0 (Blast Damage)
          zp_houndeye_damage_amount 25 (Blast Damage Amount)
          
          
    -. Changelog:
            # 0.1 - Plugin Release
            # 0.2 - Added 2 cvar's: 1) To activate the blast damage
                            2) To select the amount of the damage
            # 0.3 - Now you can't use blast hability if you are nemesis.
            # 0.4 - Fixed cvar "zp_houndeye_damage_amount".
    -. Credits:
            # shinoda - Help me with how to make players fly.
            # MeRcyLeZZ - For his Zombie Plague ^.^
            # frk_14 - For the model.

*/

#include <amxmodx>
#include <hamsandwich>
#include <fakemeta>
#include <xs>
#include <engine>
#include <biohazard>

/*================================================================================
 [Plugin Customization]
=================================================================================*/
new const beam_cylinder[] = "sprites/white.spr"

new const houndeye_attack[][] = { "houndeye/he_attack1.wav""houndeye/he_attack3.wav" }
new const 
houndeye_blast[][] = { "houndeye/he_blast1.wav""houndeye/he_blast3.wav" }

/*================================================================================
 [End Customization]
=================================================================================*/

#define is_player(%0)    (1 <= %0 <= giMaxplayers)
#define TASK_BARTIME 16000

// Zombie vars
new gMsgBarTimegMsgDeathMsggSprBeamgiMaxplayerscvar_timeblastcvar_radiuscvar_blast_infect,
cvar_damagecvar_damage_amount

public plugin_init()
{
    
register_plugin("Houndeye Zombie""0.4""Morte")
    
    
cvar_timeblast register_cvar("zp_houndeye_timeblast""2.5")
    
cvar_radius register_cvar("zp_houndeye_radius""150.0")
    
cvar_blast_infect register_cvar("zp_houndeye_infect""0")
    
cvar_damage register_cvar("zp_houndeye_damage""0")
    
cvar_damage_amount register_cvar("zp_houndeye_damage_amount""25")
    
    
register_forwardFM_CmdStart"CmdStart")
    
    
giMaxplayers get_maxplayers()
    
gMsgBarTime get_user_msgid("BarTime")
    
gMsgDeathMsg get_user_msgid("DeathMsg")
}

public 
plugin_precache()

    
gSprBeam precache_model(beam_cylinder)
    
    for (new 
0sizeof houndeye_attacki++)
        
engfunc(EngFunc_PrecacheSoundhoundeye_attack[i])
    for (new 
0sizeof houndeye_blasti++)
        
engfunc(EngFunc_PrecacheSoundhoundeye_blast[i])
}

public 
CmdStart(id)
{
    if(!
is_user_alive(id))
        return;
    
    static 
iButtoniButton pev(idpev_button)
    static 
iOldButtoniOldButton pev(idpev_oldbuttons)
    
    if(
is_user_zombie(id))
    {
        if( ( 
iButton IN_USE ) && !( iOldButton IN_USE ) )
        {
            if(!
is_user_alive(id))
                return;

            
message_begin(MSG_ONEgMsgBarTime_id)
            
write_byte(get_pcvar_num(cvar_timeblast))
            
write_byte(0)
            
message_end()
            
            
emit_sound(idCHAN_VOICEhoundeye_attack[random_num(0sizeof houndeye_attack 1)], 1.0ATTN_NORM0PITCH_NORM)
            
            
set_task(get_pcvar_float(cvar_timeblast), "blast_players"id+TASK_BARTIME)
        }
            
        if( 
iOldButton IN_USE && !( iButton IN_USE ) )
            
set_task(0.1"blast_stop"id)
    }
}

public 
blast_stop(id)
{
    
message_begin(MSG_ONEgMsgBarTime_id)
    
write_byte(0)
    
write_byte(0)
    
message_end()
    
    
remove_task(id+TASK_BARTIME)
}

public 
blast_players(id)
{
    
id -= TASK_BARTIME
    
    
new FloatiOrigin[3]
    
pev(idpev_originiOrigin)
    
    
emit_sound(idCHAN_VOICEhoundeye_blast[random_num(0sizeof houndeye_blast 1)], 1.0ATTN_NORM0PITCH_NORM)
    
    
engfunc(EngFunc_MessageBeginMSG_PVSSVC_TEMPENTITYiOrigin0)
    
write_byte(TE_BEAMCYLINDER)
    
engfunc(EngFunc_WriteCoordiOrigin[0])
    
engfunc(EngFunc_WriteCoordiOrigin[1])
    
engfunc(EngFunc_WriteCoordiOrigin[2])
    
engfunc(EngFunc_WriteCoordiOrigin[0])
    
engfunc(EngFunc_WriteCoordiOrigin[1])
    
engfunc(EngFunc_WriteCoordiOrigin[2]+385.0)
    
write_short(gSprBeam)
    
write_byte(0)
    
write_byte(0)
    
write_byte(4)
    
write_byte(60)
    
write_byte(0)
    
write_byte(255)
    
write_byte(255)
    
write_byte(255)
    
write_byte(200)
    
write_byte(0)
    
message_end()
    
    static 
EntFloatoriginF[3]
    
    while( (
Ent engfunc(EngFunc_FindEntityInSphereEntiOriginget_pcvar_float(cvar_radius))) )
    {
        if( 
is_player(Ent) && Ent != id )
        {
            if(
is_user_zombie(Ent))
                return 
PLUGIN_CONTINUE;
                
            if(
get_pcvar_num(cvar_blast_infect))
            {
                
infect_user(Ent1)
                
                
SendDeathMsg(idEnt)
            }
            
            if(
get_pcvar_num(cvar_damage))
            {    
                
fm_set_user_health(Entpev(Entpev_health) - get_pcvar_num(cvar_damage_amount))
            }
            
            
pev(Entpev_originoriginF)
            
            
originF[0] = (originF[0] - iOrigin[0]) * 10.0 
            originF
[1] = (originF[1] - iOrigin[1]) * 10.0 
            originF
[2] = (originF[2] - iOrigin[2]) + 500.0
            
            set_pev
(Entpev_velocityoriginF)
        }
    }
    
    return 
PLUGIN_HANDLED;
}

SendDeathMsg(attackervictim)
{
    
message_begin(MSG_BROADCASTgMsgDeathMsg)
    
write_byte(attacker)
    
write_byte(victim)
    
write_byte(1)
    
write_string("infection")
    
message_end()
}

/*================================================================================
 [Stocks]
=================================================================================*/

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

stock fm_set_user_health(idhealth)
{
    (
health 0) ? set_pev(idpev_healthfloat(health)) : dllfunc(DLLFunc_ClientKillid);

__________________
Check my new Zombie Mod (2019)
Look at the video below to see gameplay

https://www.youtube.com/watch?v=U4mf9obA6x0

Last edited by Krtola; 04-25-2019 at 07:42.
Krtola is offline
Send a message via Skype™ to Krtola
Krtola
Veteran Member
Join Date: Oct 2013
Location: Serbia
Old 05-15-2019 , 10:10   Re: Biohazard v2.00 Beta 3b (Zombie Mod)
Reply With Quote #4073

-Infection Effect for Biohazard Mod
- Download resources from there https://forums.alliedmods.net/showthread.php?t=182408
PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <fakemeta>
#include <hamsandwich>
#include <biohazard>
#include <xs>

#define PLUGIN "[ZP] Addon: Infect-Effect"
#define VERSION "1.0"
#define AUTHOR "Dias"

new g_effect_id[33], g_had_effect[33]
new const 
effect_model[] = "sprites/infect-effect.spr"

new cvar_scalecvar_showtimecvar_lightlevel

public plugin_init()
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
    
RegisterHam(Ham_Spawn"player""fw_spawn_post"1)
    
register_forward(FM_AddToFullPack"fw_WhatTheFuck_Post"1)
    
    
cvar_scale register_cvar("zp_in-ef_scale""0.035")
    
cvar_showtime register_cvar("zp_in-ef_showtime""2.0")
    
cvar_lightlevel register_cvar("zp_in-ef_lightlevel""100.0")
}

public 
plugin_precache()
{
    
precache_model(effect_model)
}

public 
fw_spawn_post(id)
{
    if(
g_had_effect[id])
        
remove_effect(id)
}

public 
event_infect(victimattacker)
{
    if(
is_user_alive(victim))
    {
        
show_effect(victim)
    }
}

public 
show_effect(id)
{
    
g_effect_id[id] = engfunc(EngFunc_CreateNamedEntityengfunc(EngFunc_AllocString"env_sprite"))
    
    if (!
pev_valid(g_effect_id[id]))
        return
    
    
g_had_effect[id] = 1
    
    set_pev
(g_effect_id[id], pev_solidSOLID_NOT)
    
set_pev(g_effect_id[id], pev_movetypeMOVETYPE_NONE)

    
engfunc(EngFunc_SetModelg_effect_id[id], effect_model)
    
    
set_pev(g_effect_id[id], pev_rendermodekRenderTransAlpha)
    
set_pev(g_effect_id[id], pev_renderamt0.0)
    
set_pev(g_effect_id[id], pev_ownerid)
    
set_pev(g_effect_id[id], pev_scaleget_pcvar_float(cvar_scale))
    
set_pev(g_effect_id[id], pev_light_levelget_pcvar_float(cvar_lightlevel))
    
    
set_task(get_pcvar_float(cvar_showtime), "remove_effect"g_effect_id[id])
}

public 
fw_WhatTheFuck_Post(eseenthosthost_flagsplayerp_set)
{
    if(!(
host 33))
        return 
FMRES_IGNORED
        
    
if(ent != g_effect_id[host] || !pev_valid(ent))
        return 
FMRES_IGNORED
        
    
if(pev(entpev_owner) != host)
        return 
FMRES_IGNORED
        
    
if(!is_user_alive(host))
        return 
FMRES_IGNORED
        
    
static Float:origin[3], Float:forvec[3], Float:voffsets[3], Float:Angles[3]
    
    
pev(hostpev_originorigin)
    
pev(hostpev_view_ofsvoffsets)
    
pev(hostpev_anglesAngles)
    
    
xs_vec_add(originvoffsetsorigin)
    
    
// Get a forward vector in the direction of player's aim
    
velocity_by_aim(host10forvec)
    
    
// Set the sprite on the new origin
    
xs_vec_add(originforvecorigin)
    
    
engfunc(EngFunc_SetOriginentorigin)
    
set_es(esES_Originorigin)
    
set_es(esES_AnglesAngles)
    
    
// Make the sprite visible
    
set_es(esES_RenderModekRenderTransAdd)
    
set_es(esES_RenderAmt200)
        
    return 
FMRES_HANDLED
}

public 
remove_effect(ent)
{
    
g_had_effect[pev(entpev_owner)] = 0
    
    
if(pev_valid(ent))
        
engfunc(EngFunc_RemoveEntityent)

__________________
Check my new Zombie Mod (2019)
Look at the video below to see gameplay

https://www.youtube.com/watch?v=U4mf9obA6x0
Krtola is offline
Send a message via Skype™ to Krtola
JorisCeoen
New Member
Join Date: Oct 2015
Old 12-01-2019 , 18:51   Re: Biohazard v2.00 Beta 3b (Zombie Mod)
Reply With Quote #4074

Was this truly the very first Zombie Escape or Zombie Mod-typish thing for CS1.6? I mean, didn't zombie escape exist before Source was even out yet? (before 2004)
__________________
Wall Worm Ambassador
JorisCeoen is offline
ZASTRELIS
Veteran Member
Join Date: Nov 2010
Location: dreams
Old Yesterday , 13:34   Re: Biohazard v2.00 Beta 3b (Zombie Mod)
Reply With Quote #4075

Is these addon working with zBot? Because I see incorrect things with players models and other bio*stuff
ZASTRELIS is offline
ZASTRELIS
Veteran Member
Join Date: Nov 2010
Location: dreams
Old Yesterday , 23:59   Re: Biohazard v2.00 Beta 3b (Zombie Mod)
Reply With Quote #4076

Quote:
I publish this fix for rehlds & zbots. Working for me correctly on cstrike mod (instead cz) with -bots

1. Go to the plugin_init func and find g_czero var, and change it mod[1] from 'z' char to 's'
Code:
g_czero = (mod[0] == 'c' && mod[1] == 's') ? true : false
2. Replace these two functions client_putinserver and task_botclient_pdata
click for expand to view code here..

4. Fix bacon_takedamage_player func, add (is_user_bot(victim) && g_zombie[victim]) to the HAM_IGNORED. Otherwise bots will not get any damage..
5. Then recompile the biohazard.sma script and restart the HLDS (make full restart, close and start hlds app manually)

click for expand to the view demo video


P.S. I never used CZ mod, so I can't understand why this previous logic was incorrect..

Last edited by ZASTRELIS; Today at 07:12.
ZASTRELIS 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 18:38.


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