Refactor Move() code

This commit is contained in:
Aronai Sieyes
2020-04-27 10:08:55 -04:00
parent ab179d74a2
commit bc1fa7bd05
42 changed files with 345 additions and 407 deletions

View File

@@ -19,19 +19,10 @@
icon_state = pick(event_icon_states)
GLOB.overmap_event_handler.update_hazards(loc)
/obj/effect/overmap/event/Move()
var/turf/old_loc = loc
/obj/effect/overmap/event/Moved(atom/old_loc, direction, forced = FALSE)
. = ..()
if(.)
GLOB.overmap_event_handler.update_hazards(old_loc)
GLOB.overmap_event_handler.update_hazards(loc)
/obj/effect/overmap/event/forceMove(atom/destination)
var/old_loc = loc
. = ..()
if(.)
GLOB.overmap_event_handler.update_hazards(old_loc)
GLOB.overmap_event_handler.update_hazards(loc)
GLOB.overmap_event_handler.update_hazards(old_loc)
GLOB.overmap_event_handler.update_hazards(loc)
/obj/effect/overmap/event/Destroy()//takes a look at this one as well, make sure everything is A-OK
var/turf/T = loc