Merge pull request #20962 from phil235/hit_message

No more message spam when you witness someone being attacked or shot
This commit is contained in:
oranges
2016-10-18 09:17:41 +13:00
committed by GitHub
54 changed files with 349 additions and 298 deletions
-6
View File
@@ -105,12 +105,6 @@
return attack_hand(user)
/obj/structure/alien/resin/attack_alien(mob/living/user)
user.changeNext_move(CLICK_CD_MELEE)
user.do_attack_animation(src)
user.visible_message("<span class='danger'>[user] claws at the resin!</span>")
take_damage(50)
/obj/structure/alien/resin/CanPass(atom/movable/mover, turf/target, height=0)
return !density
@@ -302,10 +302,6 @@
togglelock(user)
return
/obj/structure/closet/attack_alien(mob/living/user)
return attack_hand(user)
// tk grab then use on self
/obj/structure/closet/attack_self_tk(mob/user)
return attack_hand(user)
+2 -3
View File
@@ -185,9 +185,8 @@
//prevents remote "kicks" with TK
if (!Adjacent(user))
return
user.do_attack_animation(src)
user.visible_message("<span class='danger'>[user] kicks the display case.</span>", \
"<span class='notice'>You kick the display case.</span>")
user.visible_message("<span class='danger'>[user] kicks the display case.</span>", null, null, 2, user)
user.do_attack_animation(src, ATTACK_EFFECT_KICK)
take_damage(2)
+11 -7
View File
@@ -44,8 +44,7 @@
if(do_after(user, 60/I.toolspeed, target = src))
playsound(loc, 'sound/items/Deconstruct.ogg', 50, 1)
user << "<span class='notice'>You unsecure [name].</span>"
new /obj/item/wallframe/extinguisher_cabinet(loc)
qdel(src)
deconstruct(TRUE)
return
if(iscyborg(user) || isalien(user))
@@ -58,6 +57,7 @@
stored_extinguisher = I
update_icon()
user << "<span class='notice'>You place [I] in [src].</span>"
update_icon()
else
toggle_cabinet(user)
else if(user.a_intent != "harm")
@@ -73,8 +73,9 @@
user.put_in_hands(stored_extinguisher)
user << "<span class='notice'>You take [stored_extinguisher] from [src].</span>"
stored_extinguisher = null
opened = 1
playsound(loc, 'sound/machines/click.ogg', 15, 1, -3)
if(!opened)
opened = 1
playsound(loc, 'sound/machines/click.ogg', 15, 1, -3)
update_icon()
else
toggle_cabinet(user)
@@ -123,16 +124,19 @@
/obj/structure/extinguisher_cabinet/obj_break(damage_flag)
if(!broken && !(flags & NODECONSTRUCT))
broken = 1
opened = 0
update_icon()
opened = 1
if(stored_extinguisher)
stored_extinguisher.forceMove(loc)
stored_extinguisher = null
update_icon()
/obj/structure/extinguisher_cabinet/deconstruct(disassembled = TRUE)
if(!(flags & NODECONSTRUCT))
new /obj/item/stack/sheet/metal (loc, 2)
if(disassembled)
new /obj/item/wallframe/extinguisher_cabinet(loc)
else
new /obj/item/stack/sheet/metal (loc, 2)
if(stored_extinguisher)
stored_extinguisher.forceMove(loc)
stored_extinguisher = null
+3 -7
View File
@@ -42,19 +42,15 @@
/obj/structure/grille/attack_hand(mob/living/user)
user.changeNext_move(CLICK_CD_MELEE)
user.do_attack_animation(src)
user.visible_message("<span class='warning'>[user] hits [src].</span>", \
"<span class='danger'>You hit [src].</span>", \
"<span class='italics'>You hear twisting metal.</span>")
user.do_attack_animation(src, ATTACK_EFFECT_KICK)
user.visible_message("<span class='warning'>[user] hits [src].</span>", null, null, 2, user)
if(!shock(user, 70))
take_damage(rand(5,10), BRUTE, "melee", 1)
/obj/structure/grille/attack_alien(mob/living/user)
user.do_attack_animation(src)
user.changeNext_move(CLICK_CD_MELEE)
user.visible_message("<span class='warning'>[user] mangles [src].</span>", \
"<span class='danger'>You mangle [src].</span>", \
"<span class='italics'>You hear twisting metal.</span>")
user.visible_message("<span class='warning'>[user] mangles [src].</span>", null, null, 2, user)
if(!shock(user, 70))
take_damage(20, BRUTE, "melee", 1)
+1 -1
View File
@@ -23,7 +23,7 @@
return ..()
/obj/structure/holosign/attack_hand(mob/living/user)
user.do_attack_animation(src)
user.do_attack_animation(src, ATTACK_EFFECT_PUNCH)
user.changeNext_move(CLICK_CD_MELEE)
take_damage(5 , BRUTE, "melee", 1)
+2 -3
View File
@@ -437,9 +437,8 @@
/obj/structure/rack/attack_hand(mob/living/user)
user.changeNext_move(CLICK_CD_MELEE)
user.do_attack_animation(src)
user.visible_message("<span class='warning'>[user] kicks [src].</span>", \
"<span class='danger'>You kick [src].</span>")
user.do_attack_animation(src, ATTACK_EFFECT_KICK)
user.visible_message("<span class='danger'>[user] kicks [src].</span>", null, null, 2, user)
take_damage(rand(4,8), BRUTE, "melee", 1)
+1 -1
View File
@@ -101,7 +101,7 @@
/obj/structure/window/attack_hulk(mob/living/carbon/human/user, does_attack_animation = 0)
if(!can_be_reached(user))
return 1
..()
. = ..()
/obj/structure/window/attack_hand(mob/user)
if(!can_be_reached(user))