Obsolete the PROXMOVE flag and uses

This commit is contained in:
Aronai Sieyes
2020-05-18 13:01:25 -04:00
parent 0adea12715
commit e3b5d24c8b
20 changed files with 125 additions and 78 deletions

View File

@@ -0,0 +1,33 @@
// Observer Pattern Implementation: Turf Entered/Exited
// Registration type: /turf
//
// Raised when: A /turf has a new item in contents, or an item has left it's contents
//
// Arguments that the called proc should expect:
// /turf: The turf that was entered/exited
// /atom/movable/moving_instance: The instance that entered/exited
// /atom/old_loc / /atom/new_loc: The previous/new loc of the mover
GLOBAL_DATUM_INIT(turf_entered_event, /decl/observ/turf_entered, new)
GLOBAL_DATUM_INIT(turf_exited_event, /decl/observ/turf_exited, new)
/decl/observ/turf_entered
name = "Turf Entered"
expected_type = /turf
/decl/observ/turf_exited
name = "Turf Exited"
expected_type = /turf
/********************
* Movement Handling *
********************/
/turf/Entered(var/atom/movable/am, var/atom/old_loc)
. = ..()
GLOB.turf_entered_event.raise_event(src, am, old_loc)
/turf/Exited(var/atom/movable/am, var/atom/new_loc)
. = ..()
GLOB.turf_exited_event.raise_event(src, am, new_loc)