Makes reactive teleport armor code better
Created by: unid15
because this is just awful:
if(wear_suit && istype(wear_suit, /obj/item/))
var/obj/item/I = wear_suit
if(I.IsShield() && (prob(35)))
visible_message("<span class='danger'>The reactive teleport system flings [src] clear of [attack_text]!</span>")
var/list/turfs = new/list()
for(var/turf/T in orange(6))
if(istype(T,/turf/space)) continue
if(T.density) continue
if(T.x>world.maxx-6 || T.x<6) continue
if(T.y>world.maxy-6 || T.y<6) continue
turfs += T
if(!turfs.len) turfs += pick(/turf in orange(6))
var/turf/picked = pick(turfs)
if(!isturf(picked)) return
src.loc = picked
In addition to isShield() proc for items, there's now "on_block(damage, attack_text)" proc that is called when an item can block a hit. If it returns 1, the hit is successfully blocked.
Also plays a sound when the reactive teleport armor activates
Also the washing machine's name is now lowercase