mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2026-08-28 23:58:07 +01:00
[MIRROR] Stops shields getting broken by pillows and disablers. [MDB IGNORE] (#21588)
* Stops shields getting broken by pillows and disablers. (#75759) ## About The Pull Request See the title. Doing so by adding a new arg for damage type to `check_shields()` and `hit_reaction()`. The other way would had involved a couple istype checks for item or projectile damage type, but this is a longer term solution and can tackle more than just that. ## Why It's Good For The Game Fixes #74876. ## Changelog 🆑 fix: Stops shields getting broken by pillows and disablers. /🆑 * Stops shields getting broken by pillows and disablers. --------- Co-authored-by: Ghom <42542238+Ghommie@users.noreply.github.com>
This commit is contained in:
@@ -704,7 +704,7 @@
|
||||
user.visible_message(span_danger("[user] strikes with the force of [ghost_counter] vengeful spirits!"))
|
||||
..()
|
||||
|
||||
/obj/item/melee/ghost_sword/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
|
||||
/obj/item/melee/ghost_sword/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK, damage_type = BRUTE)
|
||||
var/ghost_counter = ghost_check()
|
||||
final_block_chance += clamp((ghost_counter * 5), 0, 75)
|
||||
owner.visible_message(span_danger("[owner] is protected by a ring of [ghost_counter] ghosts!"))
|
||||
|
||||
@@ -738,7 +738,7 @@
|
||||
. = ..()
|
||||
end_berserk(user)
|
||||
|
||||
/obj/item/clothing/head/hooded/berserker/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
|
||||
/obj/item/clothing/head/hooded/berserker/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK, damage_type = BRUTE)
|
||||
if(berserk_active)
|
||||
return
|
||||
var/berserk_value = damage * DAMAGE_TO_CHARGE_SCALE
|
||||
@@ -993,7 +993,7 @@
|
||||
user.changeNext_move(CLICK_CD_RAPID)
|
||||
return ..()
|
||||
|
||||
/obj/item/cursed_katana/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
|
||||
/obj/item/cursed_katana/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK, damage_type = BRUTE)
|
||||
if(attack_type == PROJECTILE_ATTACK)
|
||||
final_block_chance = 0 //Don't bring a sword to a gunfight
|
||||
return ..()
|
||||
|
||||
Reference in New Issue
Block a user