forked from Aurorastation/Aurora.3
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added the z-level manager system from TG (Aurorastation#19532)
Added the z-level manager system from TG, mostly
- Loading branch information
1 parent
0a91768
commit 1345bea
Showing
90 changed files
with
614 additions
and
245 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
// Byond direction defines, because I want to put them somewhere. | ||
// #define NORTH 1 | ||
// #define SOUTH 2 | ||
// #define EAST 4 | ||
// #define WEST 8 | ||
|
||
/// North direction as a string "[1]" | ||
#define TEXT_NORTH "[NORTH]" | ||
/// South direction as a string "[2]" | ||
#define TEXT_SOUTH "[SOUTH]" | ||
/// East direction as a string "[4]" | ||
#define TEXT_EAST "[EAST]" | ||
/// West direction as a string "[8]" | ||
#define TEXT_WEST "[WEST]" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
// Defines for SSmapping's multiz_levels | ||
/// TRUE if we're ok with going up | ||
#define Z_LEVEL_UP 1 | ||
/// TRUE if we're ok with going down | ||
#define Z_LEVEL_DOWN 2 | ||
#define LARGEST_Z_LEVEL_INDEX Z_LEVEL_DOWN |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
// traits | ||
// boolean - marks a level as having that property if present | ||
#define ZTRAIT_CENTCOM "CentCom" | ||
#define ZTRAIT_STATION "Station" | ||
#define ZTRAIT_RESERVED "Transit/Reserved" | ||
#define ZTRAIT_AWAY "Away Mission" | ||
/* Aurora Snowflake */ | ||
#define ZTRAIT_OVERMAP "Overmap" | ||
#define ZTRAIT_EXPLANET "Exoplanet" | ||
|
||
|
||
// Whether this z level is linked up/down. Bool. | ||
#define ZTRAIT_UP "Up" | ||
#define ZTRAIT_DOWN "Down" | ||
|
||
// enum - how space transitions should affect this level | ||
#define ZTRAIT_LINKAGE "Linkage" | ||
// UNAFFECTED if absent - no space transitions | ||
#define UNAFFECTED null | ||
// SELFLOOPING - space transitions always self-loop | ||
#define SELFLOOPING "Self" | ||
// CROSSLINKED - mixed in with the cross-linked space pool | ||
#define CROSSLINKED "Cross" | ||
|
||
// default trait definitions, used by SSmapping | ||
///Z level traits for CentCom | ||
#define ZTRAITS_CENTCOM list(ZTRAIT_CENTCOM = TRUE, ZTRAIT_NOPHASE = TRUE) | ||
///Z level traits for Space Station 13 | ||
#define ZTRAITS_STATION list(ZTRAIT_LINKAGE = CROSSLINKED, ZTRAIT_STATION = TRUE) | ||
///Z level traits for Away Missions | ||
#define ZTRAITS_AWAY list(ZTRAIT_AWAY = TRUE) | ||
///Z level traits for Overmap | ||
#define ZTRAITS_OVERMAP list(ZTRAIT_OVERMAP = TRUE, ZTRAIT_LINKAGE = SELFLOOPING) | ||
///Z level traits for Exoplanets | ||
#define ZTRAITS_EXPLANET list(ZTRAIT_EXPLANET = TRUE, ZTRAIT_LINKAGE = SELFLOOPING) | ||
|
||
#define DL_NAME "name" | ||
#define DL_TRAITS "traits" | ||
#define DECLARE_LEVEL(NAME, TRAITS) list(DL_NAME = NAME, DL_TRAITS = TRAITS) | ||
|
||
// must correspond to _basemap.dm for things to work correctly | ||
#define DEFAULT_MAP_TRAITS list(\ | ||
DECLARE_LEVEL("CentCom", ZTRAITS_CENTCOM),\ | ||
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
/// Attempt to get the turf below the provided one according to Z traits | ||
#define GET_TURF_BELOW(turf) ( \ | ||
(turf.turf_flags & RESERVATION_TURF) ? SSmapping.get_reservation_from_turf(turf)?.get_turf_below(turf) : \ | ||
(!(turf) || !length(SSmapping.multiz_levels) || !SSmapping.multiz_levels[(turf).z][Z_LEVEL_DOWN]) ? null : get_step((turf), DOWN)) | ||
/// Attempt to get the turf above the provided one according to Z traits | ||
#define GET_TURF_ABOVE(turf) ( \ | ||
(turf.turf_flags & RESERVATION_TURF) ? SSmapping.get_reservation_from_turf(turf)?.get_turf_above(turf) : \ | ||
(!(turf) || !length(SSmapping.multiz_levels) || !SSmapping.multiz_levels[(turf).z][Z_LEVEL_UP]) ? null : get_step((turf), UP)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.