From e7d1c539e8812012b2cdef82ee442a9e7e084fcc Mon Sep 17 00:00:00 2001 From: Anton Tarasenko Date: Tue, 21 Apr 2020 13:52:35 +0700 Subject: [PATCH] Change Enforcer's skills for patch 0.2.70 --- sources/NiceGameType.uc | 54 +++++---- sources/NiceHumanPawn.uc | 112 +++++++++++------- sources/NicePack.uc | 4 +- .../Perks/Enforcer/NiceAvoidMarkerCarnage.uc | 17 +++ .../Enforcer/NiceEnforcerAbilitiesAdapter.uc | 93 +++++++++++++++ sources/Perks/Enforcer/NiceVetEnforcer.uc | 24 +++- .../Skills/NiceSkillEnforcerBrutalCarnageA.uc | 30 +++++ .../Skills/NiceSkillEnforcerCoating.uc | 9 ++ .../Skills/NiceSkillEnforcerDetermination.uc | 0 .../Skills/NiceSkillEnforcerStuporA.uc | 32 +++++ .../Skills/NiceSkillEnforcerUnshakable.uc | 0 .../Skills/NiceSkillEnforcerUnstoppable.uc | 0 .../Skills/NiceSkillEnforcerZEDBarrage.uc | 0 .../Skills/NiceSkillEnforcerZEDJuggernaut.uc | 0 .../Skills/NiceSkillHeavyCoating.uc | 0 .../Skills/NiceSkillHeavyOverclocking.uc | 0 .../Skills/NiceSkillHeavySafeguard.uc | 0 .../Skills/NiceSkillHeavyStablePosition.uc | 0 .../Skills/NiceSkillEnforcerFullCounter.uc | 43 ------- 19 files changed, 303 insertions(+), 115 deletions(-) create mode 100644 sources/Perks/Enforcer/NiceAvoidMarkerCarnage.uc create mode 100644 sources/Perks/Enforcer/NiceEnforcerAbilitiesAdapter.uc create mode 100644 sources/Perks/Enforcer/Skills/NiceSkillEnforcerBrutalCarnageA.uc create mode 100644 sources/Perks/Enforcer/Skills/NiceSkillEnforcerCoating.uc rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillEnforcerDetermination.uc (100%) create mode 100644 sources/Perks/Enforcer/Skills/NiceSkillEnforcerStuporA.uc rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillEnforcerUnshakable.uc (100%) rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillEnforcerUnstoppable.uc (100%) rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillEnforcerZEDBarrage.uc (100%) rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillEnforcerZEDJuggernaut.uc (100%) rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillHeavyCoating.uc (100%) rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillHeavyOverclocking.uc (100%) rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillHeavySafeguard.uc (100%) rename sources/Perks/{HeavyMachineGunner => Enforcer}/Skills/NiceSkillHeavyStablePosition.uc (100%) delete mode 100644 sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerFullCounter.uc diff --git a/sources/NiceGameType.uc b/sources/NiceGameType.uc index 86d14d3..358430f 100644 --- a/sources/NiceGameType.uc +++ b/sources/NiceGameType.uc @@ -102,31 +102,45 @@ event Tick(float DeltaTime){ } function Killed(Controller Killer, Controller Killed, Pawn KilledPawn, class dmgType){ local GameRules rules; + local NicePlayerController nicePlayer; + local NiceAvoidMarkerCarnage AvoidArea; local ScrnGameRules scrnRules; local KFSteamStatsAndAchievements StatsAndAchievements; Super.Killed(Killer, Killed, KilledPawn, dmgType); if(PlayerController(Killer) != none){ + nicePlayer = NicePlayerController(killer); if(NiceMonster(KilledPawn) != none && Killed != Killer){ - StatsAndAchievements = KFSteamStatsAndAchievements(PlayerController(Killer).SteamStatsAndAchievements); - if(StatsAndAchievements != none){ - if(KilledPawn.IsA('NiceZombieStalker') || KilledPawn.IsA('MeanZombieStalker')){ - if(class(dmgType) != none) - StatsAndAchievements.AddStalkerKillWithLAR(); - } - else if(KilledPawn.IsA('NiceZombieClot') || KilledPawn.IsA('MeanZombieClot')){ - if(class(dmgType) != none) - KFSteamStatsAndAchievements(PlayerController(Killer).SteamStatsAndAchievements).AddClotKillWithLAR(); - } - if(class(dmgType) != none){ - for(rules = Level.Game.GameRulesModifiers;rules != none;rules = rules.NextGameRules) - if(ScrnGameRules(rules) != none){ - scrnRules = ScrnGameRules(rules); - break; - } - if(scrnRules != none) - class(dmgType).Static.AwardNiceKill(StatsAndAchievements, KFPlayerController(Killer), KFMonster(KilledPawn), scrnRules.HardcoreLevel); - } - } + // Brutal carnage + if (nicePlayer != none && killer.pawn != none && nicePlayer.abilityManager != none && nicePlayer.abilityManager.IsAbilityActive("carnage")) + { + AvoidArea = Spawn(class'NiceAvoidMarkerCarnage', killer.pawn); + AvoidArea.SetLocation(KilledPawn.location); + AvoidArea.healthLevel = killedPawn.default.health; + AvoidArea.SetCollisionSize( class'NicePack.NiceSkillEnforcerBrutalCarnageA'.default.avoidRadius, + class'NicePack.NiceSkillEnforcerBrutalCarnageA'.default.avoidRadius); + AvoidArea.StartleBots(); + } + // Rest + StatsAndAchievements = KFSteamStatsAndAchievements(PlayerController(Killer).SteamStatsAndAchievements); + if(StatsAndAchievements != none){ + if(KilledPawn.IsA('NiceZombieStalker') || KilledPawn.IsA('MeanZombieStalker')){ + if(class(dmgType) != none) + StatsAndAchievements.AddStalkerKillWithLAR(); + } + else if(KilledPawn.IsA('NiceZombieClot') || KilledPawn.IsA('MeanZombieClot')){ + if(class(dmgType) != none) + KFSteamStatsAndAchievements(PlayerController(Killer).SteamStatsAndAchievements).AddClotKillWithLAR(); + } + if(class(dmgType) != none){ + for(rules = Level.Game.GameRulesModifiers;rules != none;rules = rules.NextGameRules) + if(ScrnGameRules(rules) != none){ + scrnRules = ScrnGameRules(rules); + break; + } + if(scrnRules != none) + class(dmgType).Static.AwardNiceKill(StatsAndAchievements, KFPlayerController(Killer), KFMonster(KilledPawn), scrnRules.HardcoreLevel); + } + } } } } diff --git a/sources/NiceHumanPawn.uc b/sources/NiceHumanPawn.uc index 8ec0c2b..9955ff9 100644 --- a/sources/NiceHumanPawn.uc +++ b/sources/NiceHumanPawn.uc @@ -44,6 +44,9 @@ struct InvincExtentions{ }; var array zedInvExtList; var int headshotStack; +var float remainingFCArmor; +var float remainingFCTime; +var float brutalCranageTimer; replication{ reliable if(Role == ROLE_Authority) headshotStack, hmgShieldLevel, forcedZedTimeCountDown, maniacTimeout, invincibilityTimer, safeMeleeMisses, ffScale, @@ -225,25 +228,50 @@ simulated function Tick(float deltaTime){ local NicePlayerController nicePlayer; nicePlayer = NicePlayerController(Controller); if(Role == Role_AUTHORITY){ - // Calibration - if( currentCalibrationState == CALSTATE_ACTIVE - && calibrationRemainingTime > 0.0){ - calibrationScore = CalculateCalibrationScore(); - calibrationRemainingTime -= deltaTime; - if(calibrationRemainingTime <= 0 || calibrationScore == 5){ - currentCalibrationState = CALSTATE_FINISHED; - calibrateUsedZeds.length = 0; - if(nicePlayer != none && nicePlayer.abilityManager != none) - nicePlayer.abilityManager.SetAbilityState(0, ASTATE_COOLDOWN); - } - } - // Gunslinger - if( gunslingerTimer > 0 - && nicePlayer != none && nicePlayer.abilityManager != none){ - gunslingerTimer -= deltaTime; - if(gunslingerTimer <= 0) - nicePlayer.abilityManager.SetAbilityState(1, ASTATE_COOLDOWN); - } + // Brutal carnage + if (brutalCranageTimer > 0) + { + brutalCranageTimer -= deltaTime; + if (brutalCranageTimer <= 0) + { + if(nicePlayer != none && nicePlayer.abilityManager != none) + { + nicePlayer.abilityManager.SetAbilityState(1, ASTATE_COOLDOWN); + } + } + } + // Full counter remainingFCTime + if (remainingFCTime > 0) + { + remainingFCTime -= deltaTime; + if (remainingFCTime <= 0) + { + remainingFCArmor = 0; + if(nicePlayer != none && nicePlayer.abilityManager != none) + { + nicePlayer.abilityManager.SetAbilityState(0, ASTATE_COOLDOWN); + } + } + } + // Calibration + if( currentCalibrationState == CALSTATE_ACTIVE + && calibrationRemainingTime > 0.0){ + calibrationScore = CalculateCalibrationScore(); + calibrationRemainingTime -= deltaTime; + if(calibrationRemainingTime <= 0 || calibrationScore == 5){ + currentCalibrationState = CALSTATE_FINISHED; + calibrateUsedZeds.length = 0; + if(nicePlayer != none && nicePlayer.abilityManager != none) + nicePlayer.abilityManager.SetAbilityState(0, ASTATE_COOLDOWN); + } + } + // Gunslinger + if( gunslingerTimer > 0 + && nicePlayer != none && nicePlayer.abilityManager != none){ + gunslingerTimer -= deltaTime; + if(gunslingerTimer <= 0) + nicePlayer.abilityManager.SetAbilityState(1, ASTATE_COOLDOWN); + } // Regen if(class'NiceVeterancyTypes'.static.hasSkill(NicePlayerController(Controller), class'NiceSkillMedicRegeneration')){ if(health < healthMax) @@ -663,10 +691,10 @@ simulated function ModifyVelocity(float DeltaTime, vector OldVelocity){ MovementMod *= TraderSpeedBoost; if(Health < HealthMax && medicAdrenaliteTime > 0){ // Calulate boos from adrenaline - adrSpeedBonus = Health * (1 - class'NiceSkillMedicAdrenalineShot'.default.speedBoost) + - (100 * class'NiceSkillMedicAdrenalineShot'.default.speedBoost - class'NiceSkillMedicAdrenalineShot'.default.minHealth); - adrSpeedBonus /= (100 - class'NiceSkillMedicAdrenalineShot'.default.minHealth); - adrSpeedBonus = FMin(adrSpeedBonus, class'NiceSkillMedicAdrenalineShot'.default.speedBoost); + adrSpeedBonus = Health * (1 - class'NiceSkillCommandoAdrenalineShot'.default.speedBoost) + + (100 * class'NiceSkillCommandoAdrenalineShot'.default.speedBoost - class'NiceSkillCommandoAdrenalineShot'.default.minHealth); + adrSpeedBonus /= (100 - class'NiceSkillCommandoAdrenalineShot'.default.minHealth); + adrSpeedBonus = FMin(adrSpeedBonus, class'NiceSkillCommandoAdrenalineShot'.default.speedBoost); adrSpeedBonus = FMax(adrSpeedBonus, 1.0); MovementMod *= adrSpeedBonus; } @@ -690,6 +718,7 @@ function getFreeJacket(){ } } simulated function TakeDamage(int Damage, Pawn InstigatedBy, Vector Hitlocation, Vector Momentum, class damageType, optional int HitIndex){ + local float FCArmorAbsorb; local int needArmor; local int healAmount; local float healPotency; @@ -708,35 +737,33 @@ simulated function TakeDamage(int Damage, Pawn InstigatedBy, Vector Hitlocation, } // Adrenaline damage decrease if(medicAdrenaliteTime > 0){ - adrResistance = Health * (1 - class'NiceSkillMedicAdrenalineShot'.default.resistBoost) + - (100 * class'NiceSkillMedicAdrenalineShot'.default.resistBoost - class'NiceSkillMedicAdrenalineShot'.default.minHealth); - adrResistance /= (100 - class'NiceSkillMedicAdrenalineShot'.default.minHealth); - adrResistance = FMin(adrResistance, class'NiceSkillMedicAdrenalineShot'.default.resistBoost); + adrResistance = Health * (1 - class'NiceSkillCommandoAdrenalineShot'.default.resistBoost) + + (100 * class'NiceSkillCommandoAdrenalineShot'.default.resistBoost - class'NiceSkillCommandoAdrenalineShot'.default.minHealth); + adrResistance /= (100 - class'NiceSkillCommandoAdrenalineShot'.default.minHealth); + adrResistance = FMin(adrResistance, class'NiceSkillCommandoAdrenalineShot'.default.resistBoost); adrResistance = FMax(adrResistance, 1.0); Damage *= adrResistance; } if(nicePlayer != none && nicePlayer.IsZedTimeActive() && class'NiceVeterancyTypes'.static.HasSkill(nicePlayer, class'NiceSkillZerkZEDUnbreakable')) return; - if(hmgShieldLevel > 0 && class'NiceVeterancyTypes'.static.HasSkill(nicePlayer, class'NiceSkillEnforcerFullCounter')){ - if(Damage < 20 && InstigatedBy.default.HealthMax < 1500){ - Damage *= class'NiceSkillEnforcerFullCounter'.default.damageReduction; - hmgShieldLevel --; - } - else{ - if(hmgShieldLevel == class'NiceSkillEnforcerFullCounter'.default.layersAmount) - Damage *= class'NiceSkillEnforcerFullCounter'.default.damageReduction * float(hmgShieldLevel) / - float(class'NiceSkillEnforcerFullCounter'.default.layersAmount); - hmgShieldLevel = 0; - } - } lastHMGShieldUpdateTime = Level.TimeSeconds; if(damageType != none && class(damageType) == none){ bOldArmorStops = damageType.default.bArmorStops; - if(class'NiceVeterancyTypes'.static.HasSkill(nicePlayer, class'NiceSkillHeavyCoating')) + if(class'NiceVeterancyTypes'.static.HasSkill(nicePlayer, class'NiceSkillEnforcerCoating')) damageType.default.bArmorStops = true; } lastExplosionDistance = 0.0; // hack, but scrn fucks with usotherwise + if (remainingFCArmor > 0 && remainingFCTime > 0) + { + FCArmorAbsorb = FMin(Damage, remainingFCArmor); + Damage -= FCArmorAbsorb; + remainingFCArmor -= FCArmorAbsorb; + if(remainingFCArmor <= 0 && nicePlayer != none && nicePlayer.abilityManager != none) + { + nicePlayer.abilityManager.SetAbilityState(0, ASTATE_COOLDOWN); + } + } super.TakeDamage(Damage, InstigatedBy, hitLocation, Momentum, damageType, HitIndex); // Commando's zed time if( forcedZedTimeCountDown <= 0.0 @@ -783,11 +810,6 @@ function Timer(){ } SetAmmoStatus(); ApplyWeaponFlashlight(true); - // Regenerate HMG's full counter shield - if(hmgShieldLevel < class'NiceSkillEnforcerFullCounter'.default.layersAmount && Level.TimeSeconds - lastHMGShieldUpdateTime > class'NiceSkillEnforcerFullCounter'.default.coolDown){ - lastHMGShieldUpdateTime = Level.TimeSeconds; - hmgShieldLevel ++; - } } simulated function Fire(optional float F){ local bool bRecManualReload; diff --git a/sources/NicePack.uc b/sources/NicePack.uc index 962ce79..ea2140b 100644 --- a/sources/NicePack.uc +++ b/sources/NicePack.uc @@ -186,6 +186,7 @@ simulated function PostBeginPlay(){ class'NicePack.NiceSCARMK17Pickup'.default.VariantClasses[class'NicePack.NiceSCARMK17Pickup'.default.VariantClasses.length] = class'NicePack.SkinCamoSCARMK17Pickup'; // Abilities class'NiceAbilityManager'.default.events.static.AddAdapter(class'NiceSharpshooterAbilitiesAdapter', level); + class'NiceAbilityManager'.default.events.static.AddAdapter(class'NiceEnforcerAbilitiesAdapter', level); SetTimer(0.25, true); if(Role < ROLE_Authority) return; @@ -761,9 +762,6 @@ function WaveStart(){ nicePawn.getFreeJacket(); nicePawn.bReactiveArmorUsed = false; } - // Update HMG's 'Full counter' level - if(nicePawn != none) - nicePawn.hmgShieldLevel = class'NiceSkillEnforcerFullCounter'.default.layersAmount; } } if(KFGameType(Level.Game).WaveNum == KFGameType(Level.Game).FinalWave && !bAppliedPlayersMult){ diff --git a/sources/Perks/Enforcer/NiceAvoidMarkerCarnage.uc b/sources/Perks/Enforcer/NiceAvoidMarkerCarnage.uc new file mode 100644 index 0000000..caa273b --- /dev/null +++ b/sources/Perks/Enforcer/NiceAvoidMarkerCarnage.uc @@ -0,0 +1,17 @@ +class NiceAvoidMarkerCarnage extends NiceAvoidMarker; + +var float healthLevel; + +function bool RelevantTo(Pawn P){ + local NiceMonster niceZed; + niceZed = NiceMonster(P); + if (niceZed != none && niceZed.default.health <= healthLevel) + { + return true; + } + return false; +} +defaultproperties +{ + lifespan = 2.5 +} \ No newline at end of file diff --git a/sources/Perks/Enforcer/NiceEnforcerAbilitiesAdapter.uc b/sources/Perks/Enforcer/NiceEnforcerAbilitiesAdapter.uc new file mode 100644 index 0000000..1d1214d --- /dev/null +++ b/sources/Perks/Enforcer/NiceEnforcerAbilitiesAdapter.uc @@ -0,0 +1,93 @@ +//============================================================================== +// NicePack / NiceSharpshooterAbilitiesAdapter +//============================================================================== +// Temporary stand-in for future functionality. +// Use this class to catch events from sharpshooter players' abilities. +//============================================================================== +// 'Nice pack' source +// Do whatever the fuck you want with it +// Author: dkanus +// E-mail: dkanus@gmail.com +//============================================================================== +class NiceEnforcerAbilitiesAdapter extends NiceAbilitiesAdapter; +static function AbilityActivated( string abilityID, + NicePlayerController relatedPlayer){ + local NiceHumanPawn nicePawn; + local NiceMonster victim; + if(relatedPlayer == none) return; + nicePawn = NiceHumanPawn(relatedPlayer.pawn); + if(nicePawn == none) + return; + if(abilityID == "fullcounter"){ + nicePawn.remainingFCArmor = 100.0; + nicePawn.remainingFCTime = 1.0; + } + if(abilityID == "carnage"){ + nicePawn.brutalCranageTimer = 10.0; + } + if(abilityID == class'NiceSkillEnforcerStuporA'.default.abilityID){ + relatedPlayer.abilityManager.SetAbilityState(1, ASTATE_COOLDOWN); + foreach relatedPlayer.CollidingActors(class'NiceMonster', victim, class'NicePack.NiceSkillEnforcerStuporA'.default.radius, relatedPlayer.pawn.location) + { + if (victim == none) continue; + victim.DoRightPainReaction(class'NicePack.NiceSkillEnforcerStuporA'.default.painScore, + relatedPlayer.pawn, victim.location, Vect(0,0,0), none, 0.0, + KFPlayerReplicationInfo(relatedPlayer.PlayerReplicationInfo)); + } + } +}/* +static function AbilityAdded( string abilityID, + NicePlayerController relatedPlayer){ + local NiceHumanPawn nicePawn; + if(relatedPlayer == none) return; + nicePawn = NiceHumanPawn(relatedPlayer.pawn); + if(nicePawn == none) + return; + if(abilityID == "Calibration"){ + nicePawn.currentCalibrationState = CALSTATE_FINISHED; + nicePawn.calibrationScore = 3; + } +} +static function AbilityRemoved( string abilityID, + NicePlayerController relatedPlayer){ + local NiceHumanPawn nicePawn; + if(relatedPlayer == none) return; + nicePawn = NiceHumanPawn(relatedPlayer.pawn); + if(nicePawn == none) + return; + if(abilityID == "Calibration") + nicePawn.currentCalibrationState = CALSTATE_NOABILITY; + if(abilityID == class'NiceSkillSharpshooterGunslingerA'.default.abilityID){ + nicePawn.gunslingerTimer = 0.0; + } +} +static function ModAbilityCooldown( string abilityID, + NicePlayerController relatedPlayer, + out float cooldown){ + local NiceHumanPawn nicePawn; + if(relatedPlayer == none) return; + nicePawn = NiceHumanPawn(relatedPlayer.pawn); + if( abilityID != class'NiceSkillSharpshooterGunslingerA'.default.abilityID + && abilityID != class'NiceSkillSharpshooterReaperA'.default.abilityID) + return; + switch(nicePawn.calibrationScore){ + case 2: + cooldown *= 0.85; + break; + case 3: + cooldown *= 0.7; + break; + case 4: + cooldown *= 0.5; + break; + case 5: + cooldown *= 0.25; + break; + } + // Reduce calibration score + if(nicePawn.calibrationScore > 3) + nicePawn.calibrationScore -= 1; +}*/ +defaultproperties +{ +} diff --git a/sources/Perks/Enforcer/NiceVetEnforcer.uc b/sources/Perks/Enforcer/NiceVetEnforcer.uc index 302ef3c..298e08f 100644 --- a/sources/Perks/Enforcer/NiceVetEnforcer.uc +++ b/sources/Perks/Enforcer/NiceVetEnforcer.uc @@ -46,7 +46,7 @@ static function float AddExtraAmmoFor(KFPlayerReplicationInfo KFPRI, Class 0){ + if(HasSkill(NicePlayerController(KFPRI.Owner), class'NiceSkillEnforcerCoating') && Injured.ShieldStrength > 0){ if( class(DmgType) != none && ((class(DmgType).default.bDealBurningDamage && KFMonster(Instigator) != none) || DmgType == class'NiceZombieTeslaHusk'.default.MyDamageType) ) - InDamage *= (1 - class'NiceSkillHeavyCoating'.default.huskResist); + InDamage *= (1 - class'NiceSkillEnforcerCoating'.default.huskResist); } return InDamage; } @@ -123,16 +123,32 @@ static function float SlowingModifier(KFPlayerReplicationInfo KFPRI){ static function string GetCustomLevelInfo(byte Level){ return default.CustomLevelInfo; } +static function SetupAbilities(KFPlayerReplicationInfo KFPRI){ + local NicePlayerController nicePlayer; + local NiceAbilityManager.NiceAbilityDescription fullcounter; + if(KFPRI != none) + nicePlayer = NicePlayerController(KFPRI.Owner); + if(nicePlayer == none || nicePlayer.abilityManager == none) + return; + fullcounter.ID = "fullcounter"; + fullcounter.icon = Texture'NicePackT.HudCounter.fullCounter'; + fullcounter.cooldownLength = 30.0; + fullcounter.canBeCancelled = false; + nicePlayer.abilityManager.AddAbility(fullcounter); +} + defaultproperties { bNewTypePerk=True SkillGroupA(0)=Class'NicePack.NiceSkillEnforcerUnstoppable' SkillGroupA(1)=Class'NicePack.NiceSkillEnforcerBombard' - SkillGroupA(2)=Class'NicePack.NiceSkillEnforcerFullCounter' + SkillGroupA(2)=Class'NicePack.NiceSkillEnforcerCoating' + SkillGroupA(3)=Class'NicePack.NiceSkillEnforcerStuporA' SkillGroupA(4)=Class'NicePack.NiceSkillEnforcerZEDBarrage' SkillGroupB(0)=Class'NicePack.NiceSkillEnforcerUnshakable' SkillGroupB(1)=Class'NicePack.NiceSkillEnforcerMultitasker' SkillGroupB(2)=Class'NicePack.NiceSkillEnforcerDetermination' + SkillGroupB(3)=Class'NicePack.NiceSkillEnforcerBrutalCarnageA' SkillGroupB(4)=Class'NicePack.NiceSkillEnforcerZEDJuggernaut' progressArray0(0)=100 progressArray0(1)=1000 diff --git a/sources/Perks/Enforcer/Skills/NiceSkillEnforcerBrutalCarnageA.uc b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerBrutalCarnageA.uc new file mode 100644 index 0000000..ea1b4df --- /dev/null +++ b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerBrutalCarnageA.uc @@ -0,0 +1,30 @@ +class NiceSkillEnforcerBrutalCarnageA extends NiceSkill + abstract; +var string abilityID; +var float coolDown; +var float avoidRadius; + +function static SkillSelected(NicePlayerController nicePlayer){ + local NiceAbilityManager.NiceAbilityDescription carnage; + if(nicePlayer == none) return; + if(nicePlayer.abilityManager == none) return; + carnage.ID = default.abilityID; + carnage.icon = Texture'NicePackT.HudCounter.demo'; + carnage.cooldownLength = default.cooldown; + carnage.canBeCancelled = false; + nicePlayer.abilityManager.AddAbility(carnage); +} +function static SkillDeSelected(NicePlayerController nicePlayer){ + if(nicePlayer == none) return; + if(nicePlayer.abilityManager == none) return; + nicePlayer.abilityManager.RemoveAbility(default.abilityID); +} + +defaultproperties +{ + abilityID="carnage" + cooldown=60.000000 + avoidRadius=600.0 + SkillName="Brutal carnage" + SkillEffects="Every zed killed withing next 10 seconds will cause other zeds to fear the killspot for 2.5 seconds." +} diff --git a/sources/Perks/Enforcer/Skills/NiceSkillEnforcerCoating.uc b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerCoating.uc new file mode 100644 index 0000000..acba8c7 --- /dev/null +++ b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerCoating.uc @@ -0,0 +1,9 @@ +class NiceSkillEnforcerCoating extends NiceSkill + abstract; +var float huskResist; +defaultproperties +{ + huskResist=1.000000 + SkillName="Coating" + SkillEffects="You get resistance against fire damage when you wear armor. Strength of resistance is proportional to the amount of armor, up to a full immunity." +} diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerDetermination.uc b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerDetermination.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerDetermination.uc rename to sources/Perks/Enforcer/Skills/NiceSkillEnforcerDetermination.uc diff --git a/sources/Perks/Enforcer/Skills/NiceSkillEnforcerStuporA.uc b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerStuporA.uc new file mode 100644 index 0000000..2b85f65 --- /dev/null +++ b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerStuporA.uc @@ -0,0 +1,32 @@ +class NiceSkillEnforcerStuporA extends NiceSkill + abstract; +var string abilityID; +var float coolDown; +var float radius; +var float painScore; + +function static SkillSelected(NicePlayerController nicePlayer){ + local NiceAbilityManager.NiceAbilityDescription stupor; + if(nicePlayer == none) return; + if(nicePlayer.abilityManager == none) return; + stupor.ID = default.abilityID; + stupor.icon = Texture'NicePackT.HudCounter.demo'; + stupor.cooldownLength = default.cooldown; + stupor.canBeCancelled = false; + nicePlayer.abilityManager.AddAbility(stupor); +} +function static SkillDeSelected(NicePlayerController nicePlayer){ + if(nicePlayer == none) return; + if(nicePlayer.abilityManager == none) return; + nicePlayer.abilityManager.RemoveAbility(default.abilityID); +} + +defaultproperties +{ + abilityID="stupor" + cooldown=30.000000 + radius=800.000000 // ~16 meters, I think + painScore=600.0 + SkillName="Stupor" + SkillEffects="Stun or flinch small zeds in 16 meter radius around you." +} diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerUnshakable.uc b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerUnshakable.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerUnshakable.uc rename to sources/Perks/Enforcer/Skills/NiceSkillEnforcerUnshakable.uc diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerUnstoppable.uc b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerUnstoppable.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerUnstoppable.uc rename to sources/Perks/Enforcer/Skills/NiceSkillEnforcerUnstoppable.uc diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerZEDBarrage.uc b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerZEDBarrage.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerZEDBarrage.uc rename to sources/Perks/Enforcer/Skills/NiceSkillEnforcerZEDBarrage.uc diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerZEDJuggernaut.uc b/sources/Perks/Enforcer/Skills/NiceSkillEnforcerZEDJuggernaut.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerZEDJuggernaut.uc rename to sources/Perks/Enforcer/Skills/NiceSkillEnforcerZEDJuggernaut.uc diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillHeavyCoating.uc b/sources/Perks/Enforcer/Skills/NiceSkillHeavyCoating.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillHeavyCoating.uc rename to sources/Perks/Enforcer/Skills/NiceSkillHeavyCoating.uc diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillHeavyOverclocking.uc b/sources/Perks/Enforcer/Skills/NiceSkillHeavyOverclocking.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillHeavyOverclocking.uc rename to sources/Perks/Enforcer/Skills/NiceSkillHeavyOverclocking.uc diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillHeavySafeguard.uc b/sources/Perks/Enforcer/Skills/NiceSkillHeavySafeguard.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillHeavySafeguard.uc rename to sources/Perks/Enforcer/Skills/NiceSkillHeavySafeguard.uc diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillHeavyStablePosition.uc b/sources/Perks/Enforcer/Skills/NiceSkillHeavyStablePosition.uc similarity index 100% rename from sources/Perks/HeavyMachineGunner/Skills/NiceSkillHeavyStablePosition.uc rename to sources/Perks/Enforcer/Skills/NiceSkillHeavyStablePosition.uc diff --git a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerFullCounter.uc b/sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerFullCounter.uc deleted file mode 100644 index f8f818b..0000000 --- a/sources/Perks/HeavyMachineGunner/Skills/NiceSkillEnforcerFullCounter.uc +++ /dev/null @@ -1,43 +0,0 @@ -class NiceSkillEnforcerFullCounter extends NiceSkill - abstract; -var int layersAmount; -var float coolDown; -var float damageReduction; -var float damageReductionWeak; -function static SkillSelected(NicePlayerController nicePlayer){ - local NicePack niceMutator; - local NiceHumanPawn nicePawn; - super.SkillSelected(nicePlayer); - niceMutator = class'NicePack'.static.Myself(nicePlayer.Level); - if(nicePlayer != none) - nicePawn = NiceHumanPawn(nicePlayer.pawn); - if(nicePawn != none) - nicePawn.hmgShieldLevel = default.layersAmount; - if(niceMutator == none || niceMutator.Role == Role_AUTHORITY) - return; - niceMutator.AddCounter("npHMGFullCounter", Texture'NicePackT.HudCounter.fullCounter', true, default.class); -} -function static SkillDeSelected(NicePlayerController nicePlayer){ - local NicePack niceMutator; - super.SkillDeSelected(nicePlayer); - niceMutator = class'NicePack'.static.Myself(nicePlayer.Level); - if(niceMutator == none || niceMutator.Role == Role_AUTHORITY) - return; - niceMutator.RemoveCounter("npHMGFullCounter"); -} -function static int UpdateCounterValue(string counterName, NicePlayerController nicePlayer){ - local NiceHumanPawn nicePawn; - if(nicePlayer == none || counterName != "npHMGFullCounter") - return 0; - nicePawn = NiceHumanPawn(nicePlayer.pawn); - if(nicePawn == none) - return 0; - return nicePawn.hmgShieldLevel; -} -defaultproperties -{ - layersAmount=5 - cooldown=15.000000 - SkillName="Full counter" - SkillEffects="Gives you 5 protection layers, each of which can block a weak hit. One layer restores 15 seconds after you've been hit. Can't withstand strong attacks or attacks of huge enough zeds." -}