Update ZAS_Zones.dm

ZAS adjustments
This commit is contained in:
LBraindead
2014-01-18 00:14:01 +01:00
parent d1874bec2e
commit f58487a0e9

View File

@@ -152,6 +152,13 @@ var/list/CounterDoorDirections = list(SOUTH,EAST) //Which directions doors turfs
T.zone = src
///// Z-Level Stuff
// also add the tile below it if its open space
if(istype(T, /turf/simulated/floor/open))
var/turf/simulated/floor/open/T2 = T
src.AddTurf(T2.floorbelow)
///// Z-Level Stuff
else
if(!unsimulated_tiles)
unsimulated_tiles = list()
@@ -773,6 +780,32 @@ zone/proc/Rebuild()
if(adjacent_id && (!lowest_id || adjacent_id < lowest_id))
lowest_id = adjacent_id
/////// Z-Level stuff
var/turf/controlerlocation = locate(1, 1, current.z)
for(var/obj/effect/landmark/zcontroler/controler in controlerlocation)
// upwards
if(controler.up)
var/turf/simulated/adjacent = locate(current.x, current.y, controler.up_target)
if(adjacent in turfs && istype(adjacent, /turf/simulated/floor/open))
current_adjacents += adjacent
adjacent_id = turfs[adjacent]
if(adjacent_id && (!lowest_id || adjacent_id < lowest_id))
lowest_id = adjacent_id
// downwards
if(controler.down && istype(current, /turf/simulated/floor/open))
var/turf/simulated/adjacent = locate(current.x, current.y, controler.down_target)
if(adjacent in turfs)
current_adjacents += adjacent
adjacent_id = turfs[adjacent]
if(adjacent_id && (!lowest_id || adjacent_id < lowest_id))
lowest_id = adjacent_id
/////// Z-Level stuff
if(!lowest_id)
lowest_id = current_identifier++
identical_ids += lowest_id