Merge remote-tracking branch 'upstream/master' into universal-damage

This commit is contained in:
Fox McCloud
2019-09-17 11:24:58 -04:00
131 changed files with 1794 additions and 1012 deletions
+7 -8
View File
@@ -110,7 +110,8 @@
src.transfer_fingerprints_to(newlight)
qdel(src)
return
..()
else
return ..()
/obj/machinery/light_construct/small
name = "small light fixture frame"
@@ -299,17 +300,15 @@
// attack with item - insert light (if right type), otherwise try to break the light
/obj/machinery/light/attackby(obj/item/W, mob/living/user, params)
user.changeNext_move(CLICK_CD_MELEE) //does not call parent requires manual definition
//Light replacer code
if(istype(W, /obj/item/lightreplacer))
var/obj/item/lightreplacer/LR = W
LR.ReplaceLight(src, user)
// attempt to insert light
if(istype(W, /obj/item/light))
else if(istype(W, /obj/item/light))
if(status != LIGHT_EMPTY)
to_chat(user, "There is a [fitting] already inserted.")
return
else
src.add_fingerprint(user)
var/obj/item/light/L = W
@@ -388,6 +387,8 @@
do_sparks(3, 1, src)
if(prob(75))
electrocute_mob(user, get_area(src), src, rand(0.7, 1), TRUE)
else
return ..()
/obj/machinery/light/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1)
@@ -687,8 +688,7 @@
// attack bulb/tube with object
// if a syringe, can inject plasma to make it explode
/obj/item/light/attackby(var/obj/item/I, var/mob/user, params)
..()
/obj/item/light/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/reagent_containers/syringe))
var/obj/item/reagent_containers/syringe/S = I
@@ -703,8 +703,7 @@
S.reagents.clear_reagents()
else
..()
return
return ..()
// called after an attack with a light item
// shatter light, unless it was an attempt to put it in a light socket