Overhauls and 2/28 sync (#244)
* map tweaks/shuttle engines * helpers and defines * global/onclick * controllers and datums * mapping * game folder * some other stuff * some modules * modules that aren't mobs * some mob stuff * new player stuff * mob living * silicon stuff * simple animal things * carbon/ayylmao * update_icons * carbon/human * sounds and tools * icons and stuff * hippie grinder changes + tgui * kitchen.dmi * compile issues fixed * mapfix * Mapfixes 2.0 * mapedit2.0 * mapmerger pls * Revert "mapedit2.0" This reverts commit 74139a3cacea10df7aafca06c0a10bd3daf3a481. * clean up vore folder + 2 hotfixes * admin ticket refinement * Blob tweaks and LAZYADD * LAZYADD IS LAZY * Magic strings purged * DEFINES NEED HIGHER PRIORITIES * Only a sleepless idiot deals in absolute TRUE|FALSE * u h g * progress bar fix * reverts ticket logs * there's always that one guy * fixes and stuff * 2/27 fixes * game folder stuff * stats * some modules again * clothing stuff gets vg clothing out of the main files * everything not mobs again * mob stuff * maps, tgui, sql stuff * icons * additional fixes and compile errors * don't need this anymore * Oh right this isn't needed anymore * maint bar re-added * that doesn't need to be here * stupid events * wtfeven * probably makes Travis happy * don't care to fix the grinder atm * fixes vending sprites, changes turret * lethal, not lethals * overylays are finicky creatures * lazy fix for bleeding edgy (#252) * map tweaks/shuttle engines * helpers and defines * global/onclick * controllers and datums * mapping * game folder * some other stuff * some modules * modules that aren't mobs * some mob stuff * new player stuff * mob living * silicon stuff * simple animal things * carbon/ayylmao * update_icons * carbon/human * sounds and tools * icons and stuff * hippie grinder changes + tgui * kitchen.dmi * compile issues fixed * mapfix * Mapfixes 2.0 * mapedit2.0 * mapmerger pls * Revert "mapedit2.0" This reverts commit 74139a3cacea10df7aafca06c0a10bd3daf3a481. * clean up vore folder + 2 hotfixes * admin ticket refinement * Blob tweaks and LAZYADD * LAZYADD IS LAZY * Magic strings purged * DEFINES NEED HIGHER PRIORITIES * Only a sleepless idiot deals in absolute TRUE|FALSE * u h g * progress bar fix * reverts ticket logs * there's always that one guy * fixes and stuff * 2/27 fixes * game folder stuff * stats * some modules again * clothing stuff gets vg clothing out of the main files * everything not mobs again * mob stuff * maps, tgui, sql stuff * icons * additional fixes and compile errors * don't need this anymore * Oh right this isn't needed anymore * maint bar re-added * that doesn't need to be here * stupid events * wtfeven * probably makes Travis happy * don't care to fix the grinder atm * fixes vending sprites, changes turret * lethal, not lethals * overylays are finicky creatures
This commit is contained in:
@@ -2,13 +2,21 @@ var/datum/subsystem/mapping/SSmapping
|
||||
|
||||
/datum/subsystem/mapping
|
||||
name = "Mapping"
|
||||
init_order = 13
|
||||
init_order = 12
|
||||
flags = SS_NO_FIRE
|
||||
display_order = 50
|
||||
|
||||
var/list/nuke_tiles = list()
|
||||
var/list/nuke_threats = list()
|
||||
|
||||
var/list/map_templates = list()
|
||||
|
||||
var/list/ruins_templates = list()
|
||||
var/list/space_ruins_templates = list()
|
||||
var/list/lava_ruins_templates = list()
|
||||
|
||||
var/list/shuttle_templates = list()
|
||||
var/list/shelter_templates = list()
|
||||
|
||||
/datum/subsystem/mapping/New()
|
||||
NEW_SS_GLOBAL(SSmapping)
|
||||
@@ -25,8 +33,6 @@ var/datum/subsystem/mapping/SSmapping
|
||||
if (mining_type == "lavaland")
|
||||
seedRuins(list(5), config.lavaland_budget, /area/lavaland/surface/outdoors, lava_ruins_templates)
|
||||
spawn_rivers()
|
||||
else
|
||||
make_mining_asteroid_secrets()
|
||||
|
||||
// deep space ruins
|
||||
var/space_zlevels = list()
|
||||
@@ -68,3 +74,67 @@ var/datum/subsystem/mapping/SSmapping
|
||||
|
||||
/datum/subsystem/mapping/Recover()
|
||||
flags |= SS_NO_INIT
|
||||
map_templates = SSmapping.map_templates
|
||||
ruins_templates = SSmapping.ruins_templates
|
||||
space_ruins_templates = SSmapping.space_ruins_templates
|
||||
lava_ruins_templates = SSmapping.lava_ruins_templates
|
||||
shuttle_templates = SSmapping.shuttle_templates
|
||||
shelter_templates = SSmapping.shelter_templates
|
||||
|
||||
/datum/subsystem/mapping/proc/preloadTemplates(path = "_maps/templates/") //see master controller setup
|
||||
var/list/filelist = flist(path)
|
||||
for(var/map in filelist)
|
||||
var/datum/map_template/T = new(path = "[path][map]", rename = "[map]")
|
||||
map_templates[T.name] = T
|
||||
|
||||
preloadRuinTemplates()
|
||||
preloadShuttleTemplates()
|
||||
preloadShelterTemplates()
|
||||
|
||||
/datum/subsystem/mapping/proc/preloadRuinTemplates()
|
||||
// Still supporting bans by filename
|
||||
var/list/banned = generateMapList("config/lavaruinblacklist.txt")
|
||||
banned += generateMapList("config/spaceruinblacklist.txt")
|
||||
|
||||
for(var/item in subtypesof(/datum/map_template/ruin))
|
||||
var/datum/map_template/ruin/ruin_type = item
|
||||
// screen out the abstract subtypes
|
||||
if(!initial(ruin_type.id))
|
||||
continue
|
||||
var/datum/map_template/ruin/R = new ruin_type()
|
||||
|
||||
if(banned.Find(R.mappath))
|
||||
continue
|
||||
|
||||
map_templates[R.name] = R
|
||||
ruins_templates[R.name] = R
|
||||
|
||||
if(istype(R, /datum/map_template/ruin/lavaland))
|
||||
lava_ruins_templates[R.name] = R
|
||||
else if(istype(R, /datum/map_template/ruin/space))
|
||||
space_ruins_templates[R.name] = R
|
||||
|
||||
/datum/subsystem/mapping/proc/preloadShuttleTemplates()
|
||||
var/list/unbuyable = generateMapList("config/unbuyableshuttles.txt")
|
||||
|
||||
for(var/item in subtypesof(/datum/map_template/shuttle))
|
||||
var/datum/map_template/shuttle/shuttle_type = item
|
||||
if(!(initial(shuttle_type.suffix)))
|
||||
continue
|
||||
|
||||
var/datum/map_template/shuttle/S = new shuttle_type()
|
||||
if(unbuyable.Find(S.mappath))
|
||||
S.can_be_bought = FALSE
|
||||
|
||||
shuttle_templates[S.shuttle_id] = S
|
||||
map_templates[S.shuttle_id] = S
|
||||
|
||||
/datum/subsystem/mapping/proc/preloadShelterTemplates()
|
||||
for(var/item in subtypesof(/datum/map_template/shelter))
|
||||
var/datum/map_template/shelter/shelter_type = item
|
||||
if(!(initial(shelter_type.mappath)))
|
||||
continue
|
||||
var/datum/map_template/shelter/S = new shelter_type()
|
||||
|
||||
shelter_templates[S.shelter_id] = S
|
||||
map_templates[S.shelter_id] = S
|
||||
Reference in New Issue
Block a user