mirror of
https://github.com/CHOMPStation2/CHOMPStation2.git
synced 2025-12-11 18:53:06 +00:00
Code cleanup.
This commit is contained in:
@@ -162,15 +162,9 @@
|
|||||||
if(istype(user, /mob/living/carbon/alien/humanoid) || istype(user, /mob/living/carbon/slime/adult))
|
if(istype(user, /mob/living/carbon/alien/humanoid) || istype(user, /mob/living/carbon/slime/adult))
|
||||||
if(src.operating)
|
if(src.operating)
|
||||||
return
|
return
|
||||||
src.health = max(0, src.health - 25)
|
|
||||||
playsound(src.loc, 'sound/effects/Glasshit.ogg', 75, 1)
|
playsound(src.loc, 'sound/effects/Glasshit.ogg', 75, 1)
|
||||||
visible_message("\red <B>[user] smashes against the [src.name].</B>", 1)
|
visible_message("\red <B>[user] smashes against the [src.name].</B>", 1)
|
||||||
if (src.health <= 0)
|
take_damage(25)
|
||||||
new /obj/item/weapon/shard(src.loc)
|
|
||||||
var/obj/item/weapon/cable_coil/CC = new /obj/item/weapon/cable_coil(src.loc)
|
|
||||||
CC.amount = 2
|
|
||||||
src.density = 0
|
|
||||||
del(src)
|
|
||||||
else
|
else
|
||||||
return src.attack_hand(user)
|
return src.attack_hand(user)
|
||||||
|
|
||||||
@@ -202,16 +196,10 @@
|
|||||||
//If it's a weapon, smash windoor. Unless it's an id card, agent card, ect.. then ignore it (Cards really shouldnt damage a door anyway)
|
//If it's a weapon, smash windoor. Unless it's an id card, agent card, ect.. then ignore it (Cards really shouldnt damage a door anyway)
|
||||||
if(src.density && istype(I, /obj/item/weapon) && !istype(I, /obj/item/weapon/card))
|
if(src.density && istype(I, /obj/item/weapon) && !istype(I, /obj/item/weapon/card))
|
||||||
var/aforce = I.force
|
var/aforce = I.force
|
||||||
if(I.damtype == BRUTE || I.damtype == BURN)
|
|
||||||
src.health = max(0, src.health - aforce)
|
|
||||||
playsound(src.loc, 'sound/effects/Glasshit.ogg', 75, 1)
|
playsound(src.loc, 'sound/effects/Glasshit.ogg', 75, 1)
|
||||||
visible_message("\red <B>[src] was hit by [I].</B>")
|
visible_message("\red <B>[src] was hit by [I].</B>")
|
||||||
if (src.health <= 0)
|
if(I.damtype == BRUTE || I.damtype == BURN)
|
||||||
new /obj/item/weapon/shard(src.loc)
|
take_damage(aforce)
|
||||||
var/obj/item/weapon/cable_coil/CC = new /obj/item/weapon/cable_coil(src.loc)
|
|
||||||
CC.amount = 2
|
|
||||||
src.density = 0
|
|
||||||
del(src)
|
|
||||||
return
|
return
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user