Just remove on_loc_moved entirely

This commit is contained in:
Aronai Sieyes
2020-05-18 15:13:20 -04:00
parent ff1c571091
commit 8bf7178d61
5 changed files with 12 additions and 45 deletions

View File

@@ -97,17 +97,22 @@
var/high_color = "#0099FF" // Color the shield will be when at max health. A light blue.
var/low_color = "#FF0000" // Color the shield will drift towards as health is lowered. Deep red.
/obj/item/shield_projector/New()
/obj/item/shield_projector/Initialize()
START_PROCESSING(SSobj, src)
if(always_on)
create_shields()
GLOB.moved_event.register(src, src, .proc/moved_event)
..()
/obj/item/shield_projector/Destroy()
destroy_shields()
STOP_PROCESSING(SSobj, src)
GLOB.moved_event.unregister(src, src, .proc/moved_event)
return ..()
/obj/item/shield_projector/proc/moved_event()
update_shield_positions()
/obj/item/shield_projector/proc/create_shield(var/newloc, var/new_dir)
var/obj/effect/directional_shield/S = new(newloc, src)
S.dir = new_dir
@@ -210,14 +215,6 @@
/obj/item/shield_projector/emp_act(var/severity)
adjust_health(-max_shield_health / severity) // A strong EMP will kill the shield instantly, but weaker ones won't on the first hit.
/obj/item/shield_projector/Move(var/newloc, var/direct)
..(newloc, direct)
update_shield_positions()
/obj/item/shield_projector/on_loc_moved(atom/oldloc)
update_shield_positions()
// Subtypes
/obj/item/shield_projector/rectangle