From 02987715b09b8b6bbe17c9ccfb6c1dd684dc51bc Mon Sep 17 00:00:00 2001
From: Joan Lung <3886584+ChangelingRain@users.noreply.github.com>
Date: Sat, 30 Sep 2017 22:38:36 -0400
Subject: [PATCH 1/2] Fixes Vanguard never stunning for more than 2 seconds
---
code/datums/status_effects/buffs.dm | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/code/datums/status_effects/buffs.dm b/code/datums/status_effects/buffs.dm
index 69749475cd..25b04b4312 100644
--- a/code/datums/status_effects/buffs.dm
+++ b/code/datums/status_effects/buffs.dm
@@ -71,7 +71,7 @@
/datum/status_effect/vanguard_shield/on_apply()
owner.log_message("gained Vanguard stun immunity", INDIVIDUAL_ATTACK_LOG)
- owner.add_stun_absorption("vanguard", 200, 1, "'s yellow aura momentarily intensifies!", "Your ward absorbs the stun!", " radiating with a soft yellow light!")
+ owner.add_stun_absorption("vanguard", INFINITY, 1, "'s yellow aura momentarily intensifies!", "Your ward absorbs the stun!", " radiating with a soft yellow light!")
owner.visible_message("[owner] begins to faintly glow!", "You will absorb all stuns for the next twenty seconds.")
owner.SetStun(0, FALSE)
owner.SetKnockdown(0)
@@ -87,7 +87,8 @@
var/vanguard = owner.stun_absorption["vanguard"]
var/stuns_blocked = 0
if(vanguard)
- stuns_blocked = round(min(vanguard["stuns_absorbed"] * 0.25, 20))
+ stuns_blocked = Floor(min(vanguard["stuns_absorbed"] * 0.25, 400))
+ vanguard["end_time"] = 0 //so it doesn't absorb the stuns we're about to apply
if(owner.stat != DEAD)
var/message_to_owner = "You feel your Vanguard quietly fade..."
var/otheractiveabsorptions = FALSE
@@ -95,7 +96,6 @@
if(owner.stun_absorption[i]["end_time"] > world.time && owner.stun_absorption[i]["priority"] > vanguard["priority"])
otheractiveabsorptions = TRUE
if(!GLOB.ratvar_awakens && stuns_blocked && !otheractiveabsorptions)
- vanguard["end_time"] = 0 //so it doesn't absorb the stuns we're about to apply
owner.Knockdown(stuns_blocked)
message_to_owner = "The weight of the Vanguard's protection crashes down upon you!"
if(stuns_blocked >= 300)