mirror of
https://github.com/JezuzLizard/BO2-Reimagined.git
synced 2025-06-17 10:38:04 -05:00
Head Chopper changes
This commit is contained in:
@ -13,6 +13,18 @@
|
||||
#include maps\mp\animscripts\zm_run;
|
||||
#include maps\mp\zombies\_zm_audio;
|
||||
|
||||
#using_animtree("zombie_headchopper");
|
||||
|
||||
init_anim_slice_times()
|
||||
{
|
||||
level.headchopper_slice_times = [];
|
||||
slice_times = getnotetracktimes( %o_zmb_chopper_slice_slow, "slice" );
|
||||
animlength = getanimlength( %o_zmb_chopper_slice_slow );
|
||||
|
||||
foreach ( frac in slice_times )
|
||||
level.headchopper_slice_times[level.headchopper_slice_times.size] = animlength * frac;
|
||||
}
|
||||
|
||||
headchopperthink( weapon, electricradius, armed )
|
||||
{
|
||||
self endon( "death" );
|
||||
@ -60,7 +72,7 @@ headchopperthink( weapon, electricradius, armed )
|
||||
|
||||
while ( isdefined( is_slicing ) && is_slicing )
|
||||
{
|
||||
weapon notify( "chop", weapon.zombies_only );
|
||||
weapon notify( "chop", 1 );
|
||||
weapon.is_armed = 0;
|
||||
weapon.zombies_only = 1;
|
||||
|
||||
@ -117,17 +129,14 @@ headchopperattack( weapon, ent )
|
||||
|
||||
if ( isplayer( ent ) )
|
||||
{
|
||||
if ( isdefined( weapon.deployed_time ) && gettime() - weapon.deployed_time <= 2000 )
|
||||
return;
|
||||
|
||||
if ( isdefined( is_headchop ) && is_headchop && !ent hasperk( "specialty_armorvest" ) )
|
||||
ent dodamage( ent.health, weapon.origin );
|
||||
else if ( isdefined( is_torsochop ) && is_torsochop )
|
||||
ent dodamage( 50, weapon.origin );
|
||||
else if ( isdefined( is_footchop ) && is_footchop )
|
||||
ent dodamage( 25, weapon.origin );
|
||||
if ( isdefined( is_headchop ) && is_headchop )
|
||||
{
|
||||
radiusdamage( ent.origin + (0, 0, 5), 10, 50, 50, weapon, "MOD_MELEE" );
|
||||
}
|
||||
else
|
||||
ent dodamage( 10, weapon.origin );
|
||||
{
|
||||
radiusdamage( ent.origin + (0, 0, 5), 10, 25, 25, weapon, "MOD_MELEE" );
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -22,6 +22,7 @@ main()
|
||||
replaceFunc(maps\mp\zombies\_zm_equip_subwoofer::startsubwooferdecay, scripts\zm\replaced\_zm_equip_subwoofer::startsubwooferdecay);
|
||||
replaceFunc(maps\mp\zombies\_zm_equip_subwoofer::subwoofer_network_choke, scripts\zm\replaced\_zm_equip_subwoofer::subwoofer_network_choke);
|
||||
replaceFunc(maps\mp\zombies\_zm_equip_springpad::springpadthink, scripts\zm\replaced\_zm_equip_springpad::springpadthink);
|
||||
replaceFunc(maps\mp\zombies\_zm_equip_headchopper::init_anim_slice_times, scripts\zm\replaced\_zm_equip_headchopper::init_anim_slice_times);
|
||||
replaceFunc(maps\mp\zombies\_zm_equip_headchopper::headchopperthink, scripts\zm\replaced\_zm_equip_headchopper::headchopperthink);
|
||||
replaceFunc(maps\mp\zombies\_zm_weap_slowgun::init, scripts\zm\replaced\_zm_weap_slowgun::init);
|
||||
replaceFunc(maps\mp\zombies\_zm_weap_slowgun::zombie_paralyzed, scripts\zm\replaced\_zm_weap_slowgun::zombie_paralyzed);
|
||||
|
Reference in New Issue
Block a user