section one
This commit is contained in:
@@ -125,18 +125,45 @@
|
||||
dismantle_wall(1)
|
||||
return
|
||||
|
||||
/turf/closed/wall/attack_hulk(mob/user, does_attack_animation = 0)
|
||||
..(user, 1)
|
||||
/turf/closed/wall/attack_hulk(mob/living/carbon/user)
|
||||
..()
|
||||
var/obj/item/bodypart/arm = user.hand_bodyparts[user.active_hand_index]
|
||||
if(!arm)
|
||||
return
|
||||
if(arm.disabled)
|
||||
return
|
||||
if(prob(hardness))
|
||||
playsound(src, 'sound/effects/meteorimpact.ogg', 100, 1)
|
||||
playsound(src, 'sound/effects/meteorimpact.ogg', 100, TRUE)
|
||||
user.say(pick(";RAAAAAAAARGH!", ";HNNNNNNNNNGGGGGGH!", ";GWAAAAAAAARRRHHH!", "NNNNNNNNGGGGGGGGHH!", ";AAAAAAARRRGH!" ), forced = "hulk")
|
||||
hulk_recoil(arm, user)
|
||||
dismantle_wall(1)
|
||||
|
||||
else
|
||||
playsound(src, 'sound/effects/bang.ogg', 50, 1)
|
||||
playsound(src, 'sound/effects/bang.ogg', 50, TRUE)
|
||||
add_dent(WALL_DENT_HIT)
|
||||
to_chat(user, text("<span class='notice'>You punch the wall.</span>"))
|
||||
user.visible_message("<span class='danger'>[user] smashes \the [src]!</span>", \
|
||||
"<span class='danger'>You smash \the [src]!</span>", \
|
||||
"<span class='hear'>You hear a booming smash!</span>")
|
||||
return TRUE
|
||||
|
||||
/**
|
||||
*Deals damage back to the hulk's arm.
|
||||
*
|
||||
*When a hulk manages to break a wall using their hulk smash, this deals back damage to the arm used.
|
||||
*This is in its own proc just to be easily overridden by other wall types. Default allows for three
|
||||
*smashed walls per arm. Also, we use CANT_WOUND here because wounds are random. Wounds are applied
|
||||
*by hulk code based on arm damage and checked when we call break_an_arm().
|
||||
*Arguments:
|
||||
**arg1 is the arm to deal damage to.
|
||||
**arg2 is the hulk
|
||||
*/
|
||||
/turf/closed/wall/proc/hulk_recoil(obj/item/bodypart/arm, mob/living/carbon/human/hulkman, var/damage = 20)
|
||||
arm.receive_damage(brute = damage, blocked = 0, wound_bonus = CANT_WOUND)
|
||||
var/datum/mutation/human/hulk/smasher = locate(/datum/mutation/human/hulk) in hulkman.dna.mutations
|
||||
if(!smasher || !damage) //sanity check but also snow and wood walls deal no recoil damage, so no arm breaky
|
||||
return
|
||||
smasher.break_an_arm(arm)
|
||||
|
||||
/turf/closed/wall/attack_hand(mob/user, act_intent = user.a_intent, unarmed_attack_flags)
|
||||
. = ..()
|
||||
if(.)
|
||||
|
||||
Reference in New Issue
Block a user