Replace hardcoded z-level numbers with a trait system
This commit is contained in:
committed by
CitadelStationBot
parent
b2021912d7
commit
72319a9794
+29
-4
@@ -21,7 +21,7 @@ Last space-z level = empty
|
||||
#define CITY_OF_COGS "City of Cogs"
|
||||
#define EMPTY_AREA_1 "Empty Area 1"
|
||||
#define EMPTY_AREA_2 "Empty Area 2"
|
||||
#define MINING "Mining Asteroid"
|
||||
#define MINING_ASTEROID "Mining Asteroid"
|
||||
#define EMPTY_AREA_3 "Empty Area 3"
|
||||
#define EMPTY_AREA_4 "Empty Area 4"
|
||||
#define EMPTY_AREA_5 "Empty Area 5"
|
||||
@@ -36,11 +36,8 @@ Last space-z level = empty
|
||||
#define MAP_REMOVE_JOB(jobpath) /datum/job/##jobpath/map_check() { return (SSmapping.config.map_name != JOB_MODIFICATION_MAP_NAME) && ..() }
|
||||
|
||||
//zlevel defines, can be overridden for different maps in the appropriate _maps file.
|
||||
#define ZLEVEL_CENTCOM 1
|
||||
#define ZLEVEL_STATION_PRIMARY 2
|
||||
#define ZLEVEL_MINING 5
|
||||
#define ZLEVEL_LAVALAND 5
|
||||
#define ZLEVEL_CITYOFCOGS 6
|
||||
#define ZLEVEL_EMPTY_SPACE 12
|
||||
//Unless you modify it in map config should be equal to ZLEVEL_SPACEMAX
|
||||
#define ZLEVEL_TRANSIT 13
|
||||
@@ -49,3 +46,31 @@ Last space-z level = empty
|
||||
#define ZLEVEL_SPACEMAX 13
|
||||
|
||||
#define SPACERUIN_MAP_EDGE_PAD 15
|
||||
#define ZLEVEL_SPACE_RUIN_COUNT 5
|
||||
|
||||
// traits
|
||||
#define ZTRAIT_CENTCOM "CentCom"
|
||||
#define ZTRAIT_STATION "Station"
|
||||
#define ZTRAIT_MINING "Mining"
|
||||
#define ZTRAIT_REEBE "Reebe"
|
||||
#define ZTRAIT_TRANSIT "Transit"
|
||||
#define ZTRAIT_AWAY "Away Mission"
|
||||
#define ZTRAIT_SPACE_RUINS "Space Ruins"
|
||||
#define ZTRAIT_LAVA_RUINS "Lava Ruins"
|
||||
#define ZTRAIT_BOMBCAP_MULTIPLIER "Bombcap Multiplier"
|
||||
|
||||
// trait definitions
|
||||
#define DL_NAME "name"
|
||||
#define DL_LINKAGE "linkage"
|
||||
#define DL_TRAITS "traits"
|
||||
|
||||
#define DECLARE_LEVEL(NAME, LINKAGE, TRAITS) list(DL_NAME = NAME, DL_LINKAGE = LINKAGE, DL_TRAITS = TRAITS)
|
||||
// corresponds to basemap.dm
|
||||
#define DEFAULT_MAP_TRAITS list(\
|
||||
DECLARE_LEVEL("CentCom", SELFLOOPING, list(ZTRAIT_CENTCOM = TRUE)),\
|
||||
DECLARE_LEVEL("Main Station", CROSSLINKED, list(ZTRAIT_STATION = TRUE)),\
|
||||
DECLARE_LEVEL("Empty Area 1", CROSSLINKED, list(ZTRAIT_SPACE_RUINS = TRUE)),\
|
||||
DECLARE_LEVEL("Empty Area 2", CROSSLINKED, list(ZTRAIT_SPACE_RUINS = TRUE)),\
|
||||
DECLARE_LEVEL("Lavaland", UNAFFECTED, list(ZTRAIT_MINING = TRUE, ZTRAIT_LAVA_RUINS = TRUE, ZTRAIT_BOMBCAP_MULTIPLIER = 3)),\
|
||||
DECLARE_LEVEL("Reebe", UNAFFECTED, list(ZTRAIT_REEBE = TRUE, ZTRAIT_BOMBCAP_MULTIPLIER = 0.5)),\
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user