Merge branch 'master' into upstream-merge-8298

This commit is contained in:
Novacat
2022-03-04 09:57:28 -05:00
committed by GitHub
825 changed files with 158690 additions and 79022 deletions
+8 -4
View File
@@ -10,7 +10,7 @@ SUBSYSTEM_DEF(ai)
var/list/currentrun = list()
var/slept_mobs = 0
var/list/process_z = list()
var/list/process_z = list()
/datum/controller/subsystem/ai/stat_entry(msg_prefix)
..("P: [processing.len] | S: [slept_mobs]")
@@ -32,10 +32,14 @@ SUBSYSTEM_DEF(ai)
while(currentrun.len)
var/datum/ai_holder/A = currentrun[currentrun.len]
--currentrun.len
if(!A || QDELETED(A) || !A.holder?.loc || A.busy) // Doesn't exist or won't exist soon or not doing it this tick
if(!A || QDELETED(A) || A.busy) // Doesn't exist or won't exist soon or not doing it this tick
continue
if(process_z[get_z(A.holder)])
var/mob/living/L = A.holder //VOREStation Edit Start
if(!L?.loc)
continue
if(process_z[get_z(L)] || !L.low_priority) //VOREStation Edit End
A.handle_strategicals()
else
slept_mobs++
+25 -1
View File
@@ -76,7 +76,9 @@ SUBSYSTEM_DEF(mapping)
// VOREStation Edit Start: Enable This
/datum/controller/subsystem/mapping/proc/loadLateMaps()
var/list/deffo_load = using_map.lateload_z_levels
var/list/maybe_load = using_map.lateload_single_pick
var/list/maybe_load = using_map.lateload_gateway
var/list/also_load = using_map.lateload_overmap
for(var/list/maplist in deffo_load)
if(!islist(maplist))
@@ -110,6 +112,28 @@ SUBSYSTEM_DEF(mapping)
error("Randompick Z level \"[map]\" is not a valid map!")
else
MT.load_new_z(centered = FALSE)
if(LAZYLEN(also_load)) //Just copied from gateway picking, this is so we can have a kind of OM map version of the same concept.
var/picklist = pick(also_load)
if(!picklist) //No lateload maps at all
return
if(!islist(picklist)) //So you can have a 'chain' of z-levels that make up one away mission
error("Randompick Z level [picklist] is not a list! Must be in a list!")
return
for(var/map in picklist)
if(islist(map))
// TRIPLE NEST. In this situation we pick one at random from the choices in the list.
//This allows a sort of a1,a2,a3,b1,b2,b3,c1,c2,c3 setup where it picks one 'a', one 'b', one 'c'
map = pick(map)
var/datum/map_template/MT = map_templates[map]
if(!istype(MT))
error("Randompick Z level \"[map]\" is not a valid map!")
else
MT.load_new_z(centered = FALSE)
/datum/controller/subsystem/mapping/proc/preloadShelterTemplates()
for(var/datum/map_template/shelter/shelter_type as anything in subtypesof(/datum/map_template/shelter))
+2 -11
View File
@@ -25,6 +25,7 @@ SUBSYSTEM_DEF(persist)
return
if(!resumed)
src.currentrun = human_mob_list.Copy()
src.currentrun += silicon_mob_list.Copy()
//cache for sanic speed (lists are references anyways)
var/list/currentrun = src.currentrun
@@ -41,9 +42,7 @@ SUBSYSTEM_DEF(persist)
return
continue
// Do not collect useless PTO
var/department_earning = J.pto_type
clear_unused_pto(M)
// Determine special PTO types and convert properly
if(department_earning == PTO_CYBORG)
@@ -103,12 +102,4 @@ SUBSYSTEM_DEF(persist)
// They have a custom title, aren't crew, or someone deleted their record, so we need a fallback method.
// Let's check the mind.
if(M.mind && M.mind.assigned_role)
. = job_master.GetJob(M.mind.assigned_role)
// This proc tries makes sure old Command PTO doesn't linger
/datum/controller/subsystem/persist/proc/clear_unused_pto(var/mob/M)
var/client/C = M.client
LAZYINITLIST(C.department_hours)
if(C.department_hours[DEPARTMENT_COMMAND])
C.department_hours[DEPARTMENT_COMMAND] = null
C.department_hours.Remove(DEPARTMENT_COMMAND)
. = job_master.GetJob(M.mind.assigned_role)
+1 -5
View File
@@ -4,7 +4,7 @@ SUBSYSTEM_DEF(persistence)
flags = SS_NO_FIRE
var/list/tracking_values = list()
var/list/persistence_datums = list()
/// Places our subsystem can spawn paintings (helps with art spawning differently across maps)
var/list/obj/structure/sign/painting/painting_frames = list()
var/list/all_paintings = list()
@@ -36,10 +36,6 @@ SUBSYSTEM_DEF(persistence)
if(!A || (A.flags & AREA_FLAG_IS_NOT_PERSISTENT))
return
// if((!T.z in GLOB.using_map.station_levels) || !initialized)
if(!(T.z in using_map.station_levels))
return
if(!(T.z in using_map.persist_levels))
return
+2
View File
@@ -56,6 +56,8 @@ SUBSYSTEM_DEF(supply)
return 1
if(istype(A,/obj/item/device/perfect_tele_beacon)) //VOREStation Addition: Translocator beacons
return 1 //VOREStation Addition: Translocator beacons
if(istype(A,/obj/machinery/power/quantumpad)) // //VOREStation Add: Quantum pads
return 1 //VOREStation Add: Quantum pads
for(var/atom/B in A.contents)
if(.(B))