Skip to content

Commit

Permalink
Merge pull request #20 from NSHoffman/dev
Browse files Browse the repository at this point in the history
release/2023-01-10/1.1.1
  • Loading branch information
NSHoffman committed Jan 10, 2023
2 parents 8629f97 + c7fe29e commit f386623
Showing 1 changed file with 24 additions and 51 deletions.
75 changes: 24 additions & 51 deletions Classes/N7_Boss.uc
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ simulated function CloakBoss()
return;
}

Visibility = 0;
Visibility = 1;
bCloaked = True;
if (Level.NetMode != NM_Client)
{
Expand Down Expand Up @@ -265,22 +265,6 @@ simulated function CloakBoss()
}
}

simulated function ZombieCrispDown()
{
bAshen = False;
bCrispified = False;

UnSetBurningBehavior();

if (Level.NetMode == NM_DedicatedServer)
{
return;
}

Skins[0] = default.Skins[0];
Skins[1] = default.Skins[1];
}

function RangedAttack(Actor A)
{
local float D;
Expand Down Expand Up @@ -403,7 +387,7 @@ function DoorAttack(Actor A)
function bool ShouldChargeFromDamage()
{
return !bChargingPlayer
&& (SyringeCount == 3 || Health >= HealingLevels[SyringeCount])
&& (SyringeCount == 3 || Health >= HealingLevels[SyringeCount])
&& DamageToCharge > DamageToChargeThreshold;
}

Expand All @@ -412,23 +396,23 @@ function bool ShouldChargeFromDamage()
* due to various bugs
*/
function TakeDamage(
int Damage,
Pawn InstigatedBy,
Vector Hitlocation,
Vector Momentum,
class<DamageType> DamageType,
int Damage,
Pawn InstigatedBy,
Vector Hitlocation,
Vector Momentum,
class<DamageType> DamageType,
optional int HitIndex)
{
local KFHumanPawn P;
local KFHumanPawn P;
local float DamagerDistSq, UsedPipeBombDamScale;
local int OldHealth, NumPlayersSurrounding;
local bool bDidRadialAttack;
local int OldHealth, NumPlayersSurrounding;
local bool bDidRadialAttack;

// Ignore damage instigated by other ZEDs
if (KFMonster(InstigatedBy) == None)
{
// Melee Exploiters check (from ZombieBoss::TakeDamage)
if (Level.TimeSeconds - LastMeleeExploitCheckTime > 1.0 &&
if (Level.TimeSeconds - LastMeleeExploitCheckTime > 1.0 &&
(class<DamTypeMelee>(DamageType) != None || class<KFProjectileWeaponDamageType>(DamageType) != None))
{
LastMeleeExploitCheckTime = Level.TimeSeconds;
Expand Down Expand Up @@ -484,10 +468,10 @@ function TakeDamage(
OldHealth = Health;
super(KFMonster).TakeDamage(Damage, InstigatedBy, Hitlocation, Momentum, DamageType);

if (Health <= 0 ||
IsInState('Escaping') && !IsInState('SneakAround') ||
IsInState('KnockDown') ||
IsInState('RadialAttack') ||
if (Health <= 0 ||
IsInState('Escaping') && !IsInState('SneakAround') ||
IsInState('KnockDown') ||
IsInState('RadialAttack') ||
bDidRadialAttack)
{
return;
Expand All @@ -502,7 +486,7 @@ function TakeDamage(
DamageToCharge += OldHealth - Health;
LastDamagedTime = Level.TimeSeconds;

if (InstigatedBy != None && ShouldChargeFromDamage())
if (InstigatedBy != None && ShouldChargeFromDamage())
{
DamagerDistSq = VSizeSquared(Location - InstigatedBy.Location);

Expand Down Expand Up @@ -715,12 +699,7 @@ simulated function PlayDying(class<DamageType> DamageType, Vector HitLoc)
*/
state Shield
{
ignores ZombieCrispUp, SetBurningBehavior, UnSetBurningBehavior, StartBurnFX, StopBurnFX;

function BeginState()
{
ZombieCrispDown();
}
ignores StartBurnFX, StopBurnFX;

function TakeDamage(
int Damage, Pawn InstigatedBy, Vector Hitlocation, Vector Momentum, class<DamageType> DamageType, optional int HitIndex)
Expand All @@ -742,12 +721,7 @@ Begin:
/** Teleport when patriarch is far enough from players */
state Teleport
{
ignores RangedAttack, ZombieCrispUp, SetBurningBehavior, UnSetBurningBehavior, StartBurnFX, StopBurnFX;

function BeginState()
{
ZombieCrispDown();
}
ignores RangedAttack, StartBurnFX, StopBurnFX;

function TeleportToPlayers()
{
Expand Down Expand Up @@ -795,16 +769,14 @@ Begin:
/** God mode + invisibility when escaping */
state Escaping
{
ignores RangedAttack, ZombieCrispUp, SetBurningBehavior, UnSetBurningBehavior, StartBurnFX, StopBurnFX;
ignores RangedAttack, StartBurnFX, StopBurnFX;

function BeginState()
{
super.BeginState();
bBlockActors = False;
bIgnoreEncroachers = True;
MotionDetectorThreat = 0;

ZombieCrispDown();
}

function EndState()
Expand All @@ -829,7 +801,7 @@ ignores RangedAttack, ZombieCrispUp, SetBurningBehavior, UnSetBurningBehavior, S
/** God mode + invisibility when healing */
state Healing
{
ignores RangedAttack, ZombieCrispUp, SetBurningBehavior, UnSetBurningBehavior, StartBurnFX, StopBurnFX;
ignores RangedAttack, StartBurnFX, StopBurnFX;

function BeginState()
{
Expand All @@ -838,8 +810,6 @@ ignores RangedAttack, ZombieCrispUp, SetBurningBehavior, UnSetBurningBehavior, S
bIgnoreEncroachers = True;
MotionDetectorThreat = 0;

ZombieCrispDown();

if (!bCloaked)
{
CloakBoss();
Expand Down Expand Up @@ -1054,7 +1024,7 @@ state FireMissile
Acceleration = vect(0, 0, 0);
SetAnimAction('FireEndMissile');
HandleWaitForAnim('FireEndMissile');

if (FRand() < 0.05 && Controller.Enemy != None && PlayerController(Controller.Enemy.Controller) != None)
{
PlayerController(Controller.Enemy.Controller).Speech('AUTO', 10, "");
Expand Down Expand Up @@ -1100,6 +1070,9 @@ function SetZapped(float ZapAmount, Pawn Instigator) {}
simulated function SetZappedBehavior() {}
simulated function UnSetZappedBehavior() {}

/** No crisping up */
simulated function ZombieCrispUp() {}

defaultproperties
{
MenuName="N7 Patriarch"
Expand Down

0 comments on commit f386623

Please sign in to comment.