fix more duplicate procs (#30232)

* fix more duplicate procs

* gah
This commit is contained in:
warriorstar-orion
2025-08-26 01:51:17 +00:00
committed by GitHub
parent cc9dfdc59c
commit e3c177e27b
12 changed files with 27 additions and 47 deletions
+7 -18
View File
@@ -457,7 +457,7 @@
else
underlays += emissive_appearance(icon, "[base_state]_lightmask")
/obj/machinery/light/fix(mob/user, obj/used_tool, emagged = FALSE)
/obj/machinery/light/proc/fix(mob/user, obj/used_tool, emagged = FALSE)
if(status != LIGHT_OK)
to_chat(user, "<span class='notice'>You replace the [fitting] with [used_tool].</span>")
status = LIGHT_OK
@@ -585,6 +585,12 @@
// attack with item - insert light (if right type), otherwise try to break the light
/obj/machinery/light/item_interaction(mob/living/user, obj/item/used, list/modifiers)
if(status == LIGHT_BROKEN || status == LIGHT_EMPTY)
if(on && (used.flags & CONDUCT))
if(prob(12))
electrocute_mob(user, get_area(src), src, 0.3, TRUE)
return ITEM_INTERACT_COMPLETE
var/obj/item/gripper/gripper = used
if(istype(gripper) && gripper.engineering_machine_interaction)
if(gripper.gripped_item)
@@ -715,15 +721,6 @@
transfer_fingerprints_to(newlight)
qdel(src)
/obj/machinery/light/item_interaction(mob/living/user, obj/item/used, list/modifiers)
if(status == LIGHT_BROKEN || status == LIGHT_EMPTY)
if(on && (used.flags & CONDUCT))
if(prob(12))
electrocute_mob(user, get_area(src), src, 0.3, TRUE)
return ITEM_INTERACT_COMPLETE
return ..()
/obj/machinery/light/take_damage(damage_amount, damage_type = BRUTE, damage_flag = 0, sound_effect = 1)
. = ..()
if(. && !QDELETED(src))
@@ -914,14 +911,6 @@
status = LIGHT_BROKEN
update()
/obj/machinery/light/proc/fix()
if(status == LIGHT_OK)
return
status = LIGHT_OK
extinguished = FALSE
on = TRUE
update(FALSE, TRUE, FALSE)
/obj/machinery/light/zap_act(power, zap_flags)
var/explosive = zap_flags & ZAP_MACHINE_EXPLOSIVE
zap_flags &= ~(ZAP_MACHINE_EXPLOSIVE | ZAP_OBJ_DAMAGE)