and finally, the modules folder. Now I can publish and take a break
This commit is contained in:
17
code/modules/fields/gravity.dm
Normal file
17
code/modules/fields/gravity.dm
Normal file
@@ -0,0 +1,17 @@
|
||||
/datum/proximity_monitor/advanced/gravity
|
||||
name = "modified gravity zone"
|
||||
setup_field_turfs = TRUE
|
||||
var/gravity_value = 0
|
||||
var/list/grav_components = list()
|
||||
field_shape = FIELD_SHAPE_RADIUS_SQUARE
|
||||
|
||||
/datum/proximity_monitor/advanced/gravity/setup_field_turf(turf/T)
|
||||
. = ..()
|
||||
grav_components[T] = T.AddComponent(/datum/component/forced_gravity,gravity_value)
|
||||
|
||||
/datum/proximity_monitor/advanced/gravity/cleanup_field_turf(turf/T)
|
||||
. = ..()
|
||||
var/datum/component/forced_gravity/G = grav_components[T]
|
||||
grav_components -= T
|
||||
if(G)
|
||||
qdel(G)
|
||||
@@ -6,7 +6,7 @@
|
||||
icon_state = null
|
||||
alpha = 0
|
||||
invisibility = INVISIBILITY_ABSTRACT
|
||||
flags_1 = ABSTRACT_1|ON_BORDER_1
|
||||
flags_1 = ON_BORDER_1
|
||||
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
|
||||
var/datum/proximity_monitor/advanced/parent = null
|
||||
|
||||
|
||||
Reference in New Issue
Block a user