diff --git a/.github/workflows/render_nanomaps.yml b/.github/workflows/render_nanomaps.yml
new file mode 100644
index 00000000000..32bde6d350a
--- /dev/null
+++ b/.github/workflows/render_nanomaps.yml
@@ -0,0 +1,35 @@
+# GitHub action to autorender nanomaps outside the game
+# This kills off the awful verb we have that takes a full 50 seconds and hangs the whole server
+# The file names and locations are VERY important here
+# DO NOT EDIT THIS UNLESS YOU KNOW WHAT YOU ARE DOING
+# -aa
+name: 'Render Nanomaps'
+on:
+ push:
+ branches: master
+ paths:
+ - '_maps/map_files/**'
+
+jobs:
+ generate_maps:
+ name: 'Generate NanoMaps'
+ runs-on: ubuntu-18.04
+ steps:
+ - name: 'Update Branch'
+ uses: actions/checkout@v2
+ with:
+ fetch-depth: 1
+
+ - name: 'Generate Maps'
+ run: './tools/github-actions/nanomap-renderer-invoker.sh'
+
+ - name: 'Commit Maps'
+ run: |
+ git config --local user.email "action@github.com"
+ git config --local user.name "NanoMap Generation"
+ git pull origin master
+ git commit -m "NanoMap Auto-Update (`date`)" -a || true
+ - name: 'Push Maps'
+ uses: ad-m/github-push-action@master
+ with:
+ github_token: ${{ secrets.GITHUB_TOKEN }}
diff --git a/README.md b/README.md
index 943397b0fa8..b484a8bccfc 100644
--- a/README.md
+++ b/README.md
@@ -2,7 +2,7 @@
[](https://travis-ci.org/ParadiseSS13/Paradise)
[](http://isitmaintained.com/project/paradisess13/paradise "Average time to resolve an issue")
[](http://isitmaintained.com/project/paradisess13/paradise "Percentage of issues still open")
-[](http://www.krihelinator.xyz)
+
[](http://forthebadge.com)
[](http://forthebadge.com)
diff --git a/_maps/cyberiad.dm b/_maps/cyberiad.dm
index 81499ec8c75..3652328e8f4 100644
--- a/_maps/cyberiad.dm
+++ b/_maps/cyberiad.dm
@@ -17,7 +17,7 @@ z4 = lavaland
#define MAP_TRANSITION_CONFIG list(\
DECLARE_LEVEL(MAIN_STATION, CROSSLINKED, list(STATION_LEVEL, STATION_CONTACT, REACHABLE, AI_OK)),\
DECLARE_LEVEL(CENTCOMM, SELFLOOPING, list(ADMIN_LEVEL, BLOCK_TELEPORT, IMPEDES_MAGIC)),\
-DECLARE_LEVEL(MINING, SELFLOOPING, list(REACHABLE, STATION_CONTACT, HAS_WEATHER, ORE_LEVEL, AI_OK)))
+DECLARE_LEVEL(MINING, SELFLOOPING, list(ORE_LEVEL, REACHABLE, STATION_CONTACT, HAS_WEATHER, AI_OK)))
#define USING_MAP_DATUM /datum/map/cyberiad
#elif !defined(MAP_OVERRIDE)
diff --git a/_maps/delta.dm b/_maps/delta.dm
index cf6acbcddb1..f944092131b 100644
--- a/_maps/delta.dm
+++ b/_maps/delta.dm
@@ -22,7 +22,7 @@ Lovingly ported by Purpose2 to Paradise
#define MAP_TRANSITION_CONFIG list(\
DECLARE_LEVEL(MAIN_STATION, CROSSLINKED, list(STATION_LEVEL, STATION_CONTACT, REACHABLE, AI_OK)),\
DECLARE_LEVEL(CENTCOMM, SELFLOOPING, list(ADMIN_LEVEL, BLOCK_TELEPORT, IMPEDES_MAGIC)),\
-DECLARE_LEVEL(MINING, SELFLOOPING, list(REACHABLE, STATION_CONTACT, HAS_WEATHER, ORE_LEVEL, AI_OK)))
+DECLARE_LEVEL(MINING, SELFLOOPING, list(ORE_LEVEL, REACHABLE, STATION_CONTACT, HAS_WEATHER, AI_OK)))
#define USING_MAP_DATUM /datum/map/delta
diff --git a/_maps/map_files/MetaStation/MetaStation.v41A.II.dmm b/_maps/map_files/MetaStation/MetaStation.v41A.II.dmm
index fdc812d1f93..bcbbe8b2351 100644
--- a/_maps/map_files/MetaStation/MetaStation.v41A.II.dmm
+++ b/_maps/map_files/MetaStation/MetaStation.v41A.II.dmm
@@ -12820,7 +12820,7 @@
/obj/machinery/light/small{
dir = 8
},
-/obj/structure/chickenstatue,
+/obj/structure/statue/chickenstatue,
/turf/simulated/floor/wood,
/area/crew_quarters/mrchangs)
"awO" = (
@@ -12828,7 +12828,7 @@
/turf/simulated/floor/wood,
/area/crew_quarters/mrchangs)
"awP" = (
-/obj/structure/chickenstatue,
+/obj/structure/statue/chickenstatue,
/turf/simulated/floor/wood,
/area/crew_quarters/mrchangs)
"awQ" = (
diff --git a/_maps/map_files/RandomRuins/LavaRuins/lavaland_surface_ash_walker1.dmm b/_maps/map_files/RandomRuins/LavaRuins/lavaland_surface_ash_walker1.dmm
index 281346d9b8f..be8f849400f 100644
--- a/_maps/map_files/RandomRuins/LavaRuins/lavaland_surface_ash_walker1.dmm
+++ b/_maps/map_files/RandomRuins/LavaRuins/lavaland_surface_ash_walker1.dmm
@@ -1205,9 +1205,9 @@
/turf/simulated/floor/plating/asteroid/basalt/lava_land_surface,
/area/lavaland/surface/outdoors)
"dg" = (
-/obj/structure/bonfire/dense,
/obj/structure/stone_tile/center,
/obj/effect/mapping_helpers/no_lava,
+/obj/structure/bonfire,
/turf/simulated/floor/plating/asteroid/basalt/lava_land_surface,
/area/lavaland/surface/outdoors)
"di" = (
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/asteroid1.dmm b/_maps/map_files/RandomRuins/SpaceRuins/asteroid1.dmm
index 5dae1cf1452..de19f1ecbc8 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/asteroid1.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/asteroid1.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/floor/plating/asteroid/airless,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/asteroid2.dmm b/_maps/map_files/RandomRuins/SpaceRuins/asteroid2.dmm
index aace1d84625..6a90a5dd587 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/asteroid2.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/asteroid2.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/floor/plating/asteroid/airless,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/asteroid3.dmm b/_maps/map_files/RandomRuins/SpaceRuins/asteroid3.dmm
index a569b957ebf..121b5cff321 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/asteroid3.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/asteroid3.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/floor/plating/asteroid/airless,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/asteroid4.dmm b/_maps/map_files/RandomRuins/SpaceRuins/asteroid4.dmm
index fb51d7aabc1..fb1039beb6f 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/asteroid4.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/asteroid4.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/mineral,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/asteroid5.dmm b/_maps/map_files/RandomRuins/SpaceRuins/asteroid5.dmm
index aae4ff9e9c7..d7f38907b30 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/asteroid5.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/asteroid5.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/mineral,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/blowntcommsat.dmm b/_maps/map_files/RandomRuins/SpaceRuins/blowntcommsat.dmm
index 768bb5b30a5..de2ab18f8ab 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/blowntcommsat.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/blowntcommsat.dmm
@@ -411,17 +411,9 @@
/obj/structure/chair,
/turf/simulated/floor/plating/airless,
/area/ruin/tcommsat)
-"bu" = (
-/obj/machinery/door/airlock/maintenance_hatch,
-/turf/simulated/floor/plating/airless{
- icon_state = "dark"
- },
-/area/ruin/tcommsat)
"bv" = (
/obj/machinery/door/airlock/hatch,
-/turf/simulated/floor/plating/airless{
- icon_state = "dark"
- },
+/turf/simulated/floor/plating/airless,
/area/ruin/tcommsat)
"bw" = (
/obj/structure/window/reinforced{
@@ -2709,7 +2701,7 @@ aD
aC
aC
ai
-bu
+bC
ai
ak
ak
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/deepstorage.dmm b/_maps/map_files/RandomRuins/SpaceRuins/deepstorage.dmm
index 8bb87d2026e..7d0db9f8eb3 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/deepstorage.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/deepstorage.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"aa" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"ab" = (
/turf/simulated/mineral/random/low_chance,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/derelict1.dmm b/_maps/map_files/RandomRuins/SpaceRuins/derelict1.dmm
index 8b094749545..a78a8e88151 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/derelict1.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/derelict1.dmm
@@ -1,11 +1,11 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/obj/structure/lattice,
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"c" = (
/turf/simulated/wall,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/derelict2.dmm b/_maps/map_files/RandomRuins/SpaceRuins/derelict2.dmm
index 95ad761e62c..f3b7a74c0b3 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/derelict2.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/derelict2.dmm
@@ -1,14 +1,14 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/obj/structure/window/reinforced{
tag = "icon-rwindow (EAST)";
icon_state = "rwindow";
dir = 4
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"c" = (
/obj/machinery/door/airlock/external,
@@ -20,7 +20,7 @@
icon_state = "rwindow";
dir = 8
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"e" = (
/obj/structure/window/reinforced{
@@ -64,7 +64,7 @@
/area/ruin/powered)
"k" = (
/obj/structure/window/reinforced,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"l" = (
/obj/structure/window/reinforced,
@@ -112,7 +112,7 @@
icon_state = "rwindow";
dir = 1
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"q" = (
/obj/machinery/light/small{
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/derelict3.dmm b/_maps/map_files/RandomRuins/SpaceRuins/derelict3.dmm
index be313cd7770..56cd71d71c6 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/derelict3.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/derelict3.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/floor/plating/airless,
/area/ruin/unpowered)
@@ -10,12 +10,12 @@
/area/ruin/unpowered)
"d" = (
/obj/structure/lattice,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"e" = (
/obj/structure/lattice,
/obj/structure/lattice,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
(1,1,1) = {"
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/derelict4.dmm b/_maps/map_files/RandomRuins/SpaceRuins/derelict4.dmm
index 1c7d14bd6fa..ce660407cca 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/derelict4.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/derelict4.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/mineral,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/derelict5.dmm b/_maps/map_files/RandomRuins/SpaceRuins/derelict5.dmm
index ff8a5ac4cc2..fe74e127741 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/derelict5.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/derelict5.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/mineral,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/emptyshell.dmm b/_maps/map_files/RandomRuins/SpaceRuins/emptyshell.dmm
index 4c33095219a..0f30191dfb6 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/emptyshell.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/emptyshell.dmm
@@ -1,11 +1,11 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/obj/structure/lattice,
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"c" = (
/turf/simulated/wall/r_wall,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/gasthelizards.dmm b/_maps/map_files/RandomRuins/SpaceRuins/gasthelizards.dmm
index 0f7c36fe634..a8b394a6421 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/gasthelizards.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/gasthelizards.dmm
@@ -1,11 +1,11 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/obj/structure/lattice,
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"c" = (
/turf/simulated/wall,
/area/ruin/unpowered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/intactemptyship.dmm b/_maps/map_files/RandomRuins/SpaceRuins/intactemptyship.dmm
index a993ab96190..ad1ca6cf96a 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/intactemptyship.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/intactemptyship.dmm
@@ -1,9 +1,9 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
-/turf/space,
+/turf/template_noop,
/turf/simulated/shuttle/wall{
dir = 8;
icon_state = "diagonalWall3"
@@ -15,7 +15,7 @@
},
/area/ruin/powered)
"d" = (
-/turf/space,
+/turf/template_noop,
/turf/simulated/shuttle/wall{
dir = 2;
icon_state = "diagonalWall3"
@@ -198,7 +198,7 @@
},
/area/ruin/powered)
"A" = (
-/turf/space,
+/turf/template_noop,
/turf/simulated/shuttle/wall{
dir = 1;
icon_state = "diagonalWall3"
@@ -212,7 +212,7 @@
},
/area/ruin/powered)
"C" = (
-/turf/space,
+/turf/template_noop,
/turf/simulated/shuttle/wall{
dir = 4;
icon_state = "diagonalWall3"
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/listeningpost.dmm b/_maps/map_files/RandomRuins/SpaceRuins/listeningpost.dmm
index 17d49d666bc..32d5ea2af1d 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/listeningpost.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/listeningpost.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/mineral,
/area/ruin/powered)
@@ -73,8 +73,7 @@
},
/mob/living/simple_animal/hostile/syndicate{
desc = "A weary looking syndicate operative.";
- environment_smash = 0;
- faction = "syndicate"
+ environment_smash = 0
},
/turf/simulated/floor/plasteel,
/area/ruin/powered)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/mechtransport.dmm b/_maps/map_files/RandomRuins/SpaceRuins/mechtransport.dmm
index b4e36942d6a..99b254e2684 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/mechtransport.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/mechtransport.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/shuttle/wall{
tag = "icon-swall_s6";
@@ -168,7 +168,7 @@
/area/ruin/powered)
"D" = (
/obj/structure/lattice,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"E" = (
/obj/item/stack/rods,
@@ -202,7 +202,7 @@
/area/ruin/powered)
"K" = (
/obj/item/stack/sheet/metal,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"L" = (
/obj/structure/mecha_wreckage/gygax,
@@ -228,7 +228,7 @@
/area/ruin/powered)
"P" = (
/obj/item/stack/rods,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"Q" = (
/turf/simulated/shuttle/wall{
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/onehalf.dmm b/_maps/map_files/RandomRuins/SpaceRuins/onehalf.dmm
index fa38a1a647b..93dc1fffed4 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/onehalf.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/onehalf.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"aa" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"ab" = (
/obj/structure/lattice,
/obj/structure/cable{
@@ -10,7 +10,7 @@
icon_state = "2-4";
tag = ""
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"ac" = (
/obj/structure/lattice,
@@ -20,7 +20,7 @@
icon_state = "4-8";
tag = ""
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"ad" = (
/obj/structure/lattice,
@@ -29,7 +29,7 @@
d2 = 8;
icon_state = "2-8"
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"ae" = (
/obj/structure/lattice,
@@ -38,7 +38,7 @@
dir = 2;
icon_state = "coil_red2"
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"af" = (
/obj/structure/lattice,
@@ -48,7 +48,7 @@
icon_state = "1-8";
tag = ""
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"ag" = (
/turf/simulated/wall,
@@ -65,7 +65,7 @@
d2 = 2;
icon_state = "1-2"
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"aj" = (
/turf/unsimulated/floor/plating/airless,
@@ -154,11 +154,11 @@
/area/ruin/onehalf/drone_bay)
"aw" = (
/obj/structure/lattice,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"ax" = (
/obj/structure/lattice,
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"ay" = (
/obj/structure/table_frame,
@@ -224,7 +224,7 @@
/area/ruin/onehalf/drone_bay)
"aH" = (
/obj/item/stack/rods,
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"aI" = (
/obj/effect/landmark/damageturf,
@@ -805,7 +805,7 @@
/area/ruin/onehalf/bridge)
"bU" = (
/obj/item/stack/sheet/metal,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"bV" = (
/obj/structure/disposalpipe/segment,
@@ -914,7 +914,7 @@
dir = 4
},
/obj/item/stack/rods,
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"cn" = (
/obj/structure/lattice,
@@ -925,7 +925,7 @@
tag = "icon-small";
icon_state = "small"
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"co" = (
/obj/structure/grille,
@@ -1008,7 +1008,7 @@
/area/ruin/onehalf/bridge)
"cv" = (
/obj/item/stack/rods,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"cw" = (
/turf/unsimulated/floor/plating/airless,
@@ -1016,7 +1016,7 @@
"cx" = (
/obj/structure/lattice,
/obj/item/stack/sheet/plasteel,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"cy" = (
/obj/structure/lattice,
@@ -1024,7 +1024,7 @@
tag = "icon-medium";
icon_state = "medium"
},
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"cz" = (
/obj/structure/grille/broken,
@@ -1071,10 +1071,10 @@
/area/ruin/onehalf/bridge)
"cE" = (
/obj/item/stack/tile/wood,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"cF" = (
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"cG" = (
/obj/structure/lattice,
@@ -1083,7 +1083,7 @@
d2 = 8;
icon_state = "2-8"
},
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"cH" = (
/obj/structure/lattice,
@@ -1097,7 +1097,7 @@
icon_state = "pipe-b";
dir = 8
},
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"cI" = (
/obj/machinery/door/airlock/command/glass{
@@ -1149,7 +1149,7 @@
dir = 2;
icon_state = "coil_red2"
},
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"cQ" = (
/obj/machinery/light{
@@ -1160,7 +1160,7 @@
/area/ruin/onehalf/bridge)
"cR" = (
/obj/item/stack/sheet/plasteel,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"cS" = (
/obj/structure/lattice,
@@ -1169,7 +1169,7 @@
d2 = 2;
icon_state = "1-2"
},
-/turf/space,
+/turf/template_noop,
/area/ruin/onehalf/hallway)
"cU" = (
/obj/structure/grille,
@@ -1221,7 +1221,7 @@
d2 = 8;
icon_state = "2-8"
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"db" = (
/obj/structure/table,
@@ -1256,7 +1256,7 @@
d2 = 2;
icon_state = "1-2"
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"dg" = (
/obj/structure/girder/reinforced,
@@ -1350,7 +1350,7 @@
tag = "icon-medium";
icon_state = "medium"
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"dp" = (
/obj/structure/lattice,
@@ -1366,7 +1366,7 @@
icon_state = "1-4"
},
/obj/item/stack/rods,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"dq" = (
/obj/structure/lattice,
@@ -1382,7 +1382,7 @@
icon_state = "1-8";
tag = ""
},
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
(1,1,1) = {"
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/spacebar.dmm b/_maps/map_files/RandomRuins/SpaceRuins/spacebar.dmm
index 108c8103975..1f9725a3d03 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/spacebar.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/spacebar.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"aa" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"ab" = (
/turf/simulated/mineral,
/area/space/nearstation)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/turretedoutpost.dmm b/_maps/map_files/RandomRuins/SpaceRuins/turretedoutpost.dmm
index 96e43773146..67dc298eb20 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/turretedoutpost.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/turretedoutpost.dmm
@@ -1,10 +1,10 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/obj/structure/lattice,
-/turf/space,
+/turf/template_noop,
/area/space/nearstation)
"c" = (
/obj/structure/grille,
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/ussp.dmm b/_maps/map_files/RandomRuins/SpaceRuins/ussp.dmm
index 332da829c16..4361bd59785 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/ussp.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/ussp.dmm
@@ -5760,12 +5760,7 @@
/turf/simulated/floor/plasteel,
/area/derelict/arrival)
"lw" = (
-/obj/structure/chickenstatue{
- desc = "Like a MULEbot, but more Russian and less functional.";
- icon = 'icons/obj/aibots.dmi';
- icon_state = "mulebot0";
- name = "OXENbot"
- },
+/obj/structure/statue/russian_mulebot,
/turf/simulated/floor/plasteel,
/area/derelict/arrival)
"lx" = (
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/way_home.dmm b/_maps/map_files/RandomRuins/SpaceRuins/way_home.dmm
index b0613eef965..dc1e468624b 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/way_home.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/way_home.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"a" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"b" = (
/turf/simulated/mineral/random,
/area/ruin/unpowered/no_grav/way_home)
diff --git a/_maps/map_files/RandomRuins/SpaceRuins/wizardcrash.dmm b/_maps/map_files/RandomRuins/SpaceRuins/wizardcrash.dmm
index ebfaf3b94b4..a063d88a252 100644
--- a/_maps/map_files/RandomRuins/SpaceRuins/wizardcrash.dmm
+++ b/_maps/map_files/RandomRuins/SpaceRuins/wizardcrash.dmm
@@ -1,7 +1,7 @@
//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE
"aa" = (
-/turf/space,
-/area/space)
+/turf/template_noop,
+/area/template_noop)
"ab" = (
/turf/simulated/floor/plating/asteroid/airless,
/area/ruin/unpowered)
diff --git a/_maps/map_files/cyberiad/cyberiad.dmm b/_maps/map_files/cyberiad/cyberiad.dmm
index 16315eafd6f..2c12ac11e44 100644
--- a/_maps/map_files/cyberiad/cyberiad.dmm
+++ b/_maps/map_files/cyberiad/cyberiad.dmm
@@ -32677,7 +32677,7 @@
/turf/simulated/floor/carpet,
/area/crew_quarters/mrchangs)
"biQ" = (
-/obj/structure/chickenstatue,
+/obj/structure/statue/chickenstatue,
/obj/machinery/camera{
c_tag = "Mr. Chang's";
dir = 2;
@@ -82398,7 +82398,7 @@
/turf/simulated/floor/carpet,
/area/crew_quarters/mrchangs)
"cSW" = (
-/obj/structure/chickenstatue,
+/obj/structure/statue/chickenstatue,
/obj/machinery/firealarm{
dir = 1;
pixel_y = -24
@@ -82907,14 +82907,14 @@
tag = ""
},
/obj/structure/table,
-/obj/item/t_scanner,
-/obj/item/radio/headset/headset_eng,
-/obj/item/multitool{
- pixel_x = 5
- },
/obj/machinery/atmospherics/pipe/simple/hidden/supply{
dir = 4
},
+/obj/item/airlock_painter,
+/obj/item/airlock_painter{
+ pixel_x = -4;
+ pixel_y = 4
+ },
/turf/simulated/floor/plasteel,
/area/engine/equipmentstorage)
"cTP" = (
diff --git a/_maps/map_files/generic/Lavaland.dmm b/_maps/map_files/generic/Lavaland.dmm
index e44b9f52458..86ec920c658 100644
--- a/_maps/map_files/generic/Lavaland.dmm
+++ b/_maps/map_files/generic/Lavaland.dmm
@@ -681,7 +681,7 @@
req_access_txt = "2"
},
/obj/structure/cable{
- icon_state = "1-10"
+ icon_state = "1-2"
},
/turf/simulated/floor/plating,
/area/mine/laborcamp)
@@ -858,18 +858,11 @@
/turf/simulated/floor/plasteel,
/area/mine/laborcamp/security)
"ce" = (
-/obj/structure/cable{
- icon_state = "2-4"
+/obj/machinery/power/smes{
+ charge = 5e+006
},
/obj/structure/cable{
- icon_state = "5-6"
- },
-/turf/simulated/floor/plating,
-/area/mine/laborcamp)
-"cf" = (
-/obj/machinery/power/terminal,
-/obj/structure/cable{
- icon_state = "0-8"
+ icon_state = "0-4"
},
/turf/simulated/floor/plating,
/area/mine/laborcamp)
@@ -880,6 +873,9 @@
/turf/simulated/floor/plating,
/area/mine/laborcamp)
"ch" = (
+/obj/structure/cable{
+ icon_state = "1-8"
+ },
/turf/simulated/floor/plating,
/area/mine/laborcamp)
"ci" = (
@@ -1033,21 +1029,22 @@
/turf/simulated/floor/plasteel,
/area/mine/laborcamp)
"cz" = (
-/obj/machinery/power/port_gen/pacman{
- anchored = 1
- },
-/obj/structure/cable,
-/turf/simulated/floor/plating,
-/area/mine/laborcamp)
-"cA" = (
-/obj/machinery/power/smes{
- charge = 5e+006
+/obj/machinery/power/terminal{
+ dir = 1
},
/obj/structure/cable{
icon_state = "0-4"
},
+/obj/structure/reagent_dispensers/fueltank,
+/turf/simulated/floor/plating,
+/area/mine/laborcamp)
+"cA" = (
/obj/structure/cable{
- icon_state = "0-9"
+ d1 = 4;
+ d2 = 8;
+ icon_state = "4-8";
+ pixel_x = 0;
+ tag = ""
},
/turf/simulated/floor/plating,
/area/mine/laborcamp)
@@ -1056,7 +1053,13 @@
/turf/simulated/floor/plating,
/area/mine/laborcamp)
"cC" = (
-/obj/structure/reagent_dispensers/fueltank,
+/obj/machinery/power/port_gen/pacman{
+ anchored = 1
+ },
+/obj/structure/cable{
+ d2 = 8;
+ icon_state = "0-8"
+ },
/turf/simulated/floor/plating,
/area/mine/laborcamp)
"cD" = (
@@ -11202,7 +11205,7 @@ bm
aq
bB
bM
-cf
+ch
cA
aq
aj
@@ -11460,7 +11463,7 @@ aq
aq
aq
cg
-cB
+cA
aq
aj
cQ
@@ -11716,7 +11719,7 @@ aD
aD
aD
aq
-ch
+cB
cC
aq
aj
diff --git a/_maps/map_files/shuttles/emergency_dept.dmm b/_maps/map_files/shuttles/emergency_dept.dmm
index 739056d20d6..fb479c23995 100644
--- a/_maps/map_files/shuttles/emergency_dept.dmm
+++ b/_maps/map_files/shuttles/emergency_dept.dmm
@@ -17,81 +17,152 @@
"ad" = (
/turf/space,
/turf/simulated/shuttle/wall{
- tag = "icon-swall_f10";
icon_state = "swall_f10";
dir = 2
},
/area/shuttle/escape)
"ae" = (
-/turf/simulated/shuttle/wall{
- icon_state = "swall12";
- dir = 2
+/obj/structure/table/reinforced,
+/obj/item/paper_bin,
+/obj/item/pen,
+/turf/simulated/floor/plasteel{
+ dir = 4;
+ icon_state = "vault"
},
/area/shuttle/escape)
"af" = (
-/turf/simulated/shuttle/wall{
- icon_state = "swallc4"
+/obj/structure/table/reinforced,
+/obj/item/folder/red,
+/obj/item/restraints/handcuffs,
+/obj/item/flash,
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
},
/area/shuttle/escape)
"ag" = (
-/obj/machinery/computer/emergency_shuttle,
-/turf/simulated/shuttle/floor,
+/obj/machinery/computer/robotics,
+/turf/simulated/floor/plasteel{
+ dir = 9;
+ icon_state = "darkblue"
+ },
/area/shuttle/escape)
"ah" = (
-/turf/simulated/shuttle/wall{
- icon_state = "swallc3"
+/obj/machinery/computer/crew,
+/turf/simulated/floor/plasteel{
+ dir = 1;
+ icon_state = "darkblue"
},
/area/shuttle/escape)
"ai" = (
-/obj/machinery/computer/station_alert,
-/turf/simulated/shuttle/floor,
+/obj/machinery/computer/emergency_shuttle,
+/turf/simulated/floor/plasteel{
+ dir = 1;
+ icon_state = "darkblue"
+ },
/area/shuttle/escape)
"aj" = (
/obj/machinery/computer/communications,
-/obj/machinery/light/spot{
- tag = "icon-tube1 (NORTH)";
- icon_state = "tube1";
- dir = 1
+/turf/simulated/floor/plasteel{
+ dir = 5;
+ icon_state = "darkblue"
},
-/turf/simulated/shuttle/floor,
/area/shuttle/escape)
"ak" = (
-/obj/machinery/computer/security{
- network = list("SS13","Telecomms","Research Outpost","Mining Outpost")
+/obj/structure/table/reinforced,
+/obj/item/storage/fancy/donut_box,
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
},
-/turf/simulated/shuttle/floor,
/area/shuttle/escape)
"al" = (
+/obj/structure/table/reinforced,
+/obj/machinery/cell_charger,
+/obj/item/stock_parts/cell/high,
+/turf/simulated/floor/plasteel{
+ dir = 4;
+ icon_state = "vault"
+ },
+/area/shuttle/escape)
+"am" = (
+/obj/structure/table/reinforced,
+/obj/machinery/recharger,
+/turf/simulated/floor/plasteel{
+ dir = 4;
+ icon_state = "vault"
+ },
+/area/shuttle/escape)
+"an" = (
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
+ },
+/area/shuttle/escape)
+"ao" = (
/obj/structure/chair/comfy/shuttle{
dir = 1
},
-/turf/simulated/shuttle/floor,
-/area/shuttle/escape)
-"am" = (
-/obj/structure/table,
-/turf/simulated/shuttle/floor,
-/area/shuttle/escape)
-"an" = (
-/obj/machinery/computer/crew,
-/obj/machinery/light/spot{
- tag = "icon-tube1 (NORTH)";
- icon_state = "tube1";
- dir = 1
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
},
-/turf/simulated/shuttle/floor,
-/area/shuttle/escape)
-"ao" = (
-/obj/machinery/computer/robotics,
-/turf/simulated/shuttle/floor,
/area/shuttle/escape)
"ap" = (
+/obj/structure/table/reinforced,
+/obj/item/storage/toolbox/mechanical,
+/turf/simulated/floor/plasteel{
+ dir = 4;
+ icon_state = "vault"
+ },
+/area/shuttle/escape)
+"aq" = (
/turf/simulated/shuttle/wall{
icon_state = "swall3";
dir = 2
},
/area/shuttle/escape)
-"aq" = (
-/turf/simulated/shuttle/floor,
+"ar" = (
+/obj/machinery/computer/security{
+ network = list("SS13","Research Outpost","Mining Outpost","Telecomms")
+ },
+/obj/structure/sign/poster/official/nanotrasen_logo{
+ pixel_x = -32;
+ pixel_y = 0
+ },
+/turf/simulated/floor/plasteel{
+ dir = 9;
+ icon_state = "darkred"
+ },
+/area/shuttle/escape)
+"as" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
+ },
+/area/shuttle/escape)
+"at" = (
+/obj/item/radio/intercom{
+ dir = 4;
+ name = "Station Intercom (General)";
+ pixel_x = 29;
+ pixel_y = -60
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
+ },
+/area/shuttle/escape)
+"au" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
+ },
+/area/shuttle/escape)
+"av" = (
+/turf/simulated/shuttle/wall{
+ icon_state = "swall12";
+ dir = 2
+ },
/area/shuttle/escape)
"aw" = (
/turf/simulated/shuttle/wall{
@@ -100,49 +171,240 @@
},
/area/shuttle/escape)
"ax" = (
-/turf/simulated/shuttle/wall{
- icon_state = "swall14";
- dir = 2
+/obj/machinery/computer/station_alert,
+/obj/structure/sign/poster/official/nanotrasen_logo{
+ pixel_x = 32;
+ pixel_y = 0
+ },
+/turf/simulated/floor/plasteel{
+ dir = 5;
+ icon_state = "darkyellow"
},
/area/shuttle/escape)
"ay" = (
-/obj/machinery/door/airlock/command/glass{
- name = "Escape Shuttle Cockpit";
- req_access_txt = "19"
+/obj/machinery/computer/secure_data,
+/turf/simulated/floor/plasteel{
+ dir = 10;
+ icon_state = "darkred"
},
-/turf/simulated/shuttle/floor,
/area/shuttle/escape)
"az" = (
-/obj/structure/chair/comfy/shuttle,
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
/turf/simulated/shuttle/floor4,
/area/shuttle/escape)
"aA" = (
-/obj/machinery/status_display{
- pixel_y = 30
+/obj/machinery/light,
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
},
-/obj/machinery/light/spot{
- tag = "icon-tube1 (NORTH)";
- icon_state = "tube1";
- dir = 1
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
},
-/obj/structure/chair/comfy/shuttle,
-/turf/simulated/shuttle/floor4,
/area/shuttle/escape)
"aB" = (
-/obj/structure/grille,
-/obj/structure/window/full/shuttle{
- icon_state = "16"
+/obj/machinery/light,
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
},
-/turf/simulated/floor/plating,
/area/shuttle/escape)
"aC" = (
+/obj/machinery/computer/atmos_alert,
+/turf/simulated/floor/plasteel{
+ dir = 6;
+ icon_state = "darkyellow"
+ },
+/area/shuttle/escape)
+"aD" = (
+/obj/machinery/status_display,
+/turf/simulated/shuttle/wall{
+ icon_state = "swall12";
+ dir = 2
+ },
+/area/shuttle/escape)
+"aE" = (
+/obj/machinery/door/airlock/command/glass{
+ name = "Escape Shuttle Cockpit";
+ normalspeed = 0;
+ req_access_txt = "19"
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
+ },
+/area/shuttle/escape)
+"aF" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"aG" = (
+/obj/machinery/recharger/wallcharger{
+ pixel_x = 32;
+ pixel_y = 0
+ },
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"aH" = (
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"aI" = (
+/obj/machinery/door/airlock/medical/glass{
+ id_tag = null;
+ name = "Escape Shuttle Infirmary";
+ req_access_txt = "0"
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"aJ" = (
+/obj/structure/table/reinforced,
+/obj/item/storage/fancy/donut_box,
+/obj/item/restraints/handcuffs,
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"aL" = (
+/obj/machinery/door/airlock/medical/glass{
+ id_tag = null;
+ name = "Escape Shuttle Infirmary";
+ normalspeed = 0;
+ req_access_txt = "5"
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"aM" = (
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 8
+ },
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"aN" = (
+/obj/structure/sign/directions/security{
+ dir = 1;
+ pixel_y = 7
+ },
+/turf/simulated/shuttle/wall{
+ icon_state = "swall12";
+ dir = 2
+ },
+/area/shuttle/escape)
+"aO" = (
+/mob/living/simple_animal/bot/secbot,
/turf/simulated/floor/plasteel{
icon_state = "cafeteria";
dir = 2
},
/area/shuttle/escape)
-"aD" = (
+"aP" = (
+/turf/simulated/shuttle/wall{
+ tag = "icon-swall7";
+ icon_state = "swall7";
+ dir = 2
+ },
+/area/shuttle/escape)
+"aR" = (
/obj/structure/chair/comfy/shuttle{
+ dir = 1
+ },
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"aS" = (
+/turf/simulated/floor/plasteel{
+ icon_state = "cafeteria";
+ dir = 2
+ },
+/area/shuttle/escape)
+"aT" = (
+/obj/item/twohanded/required/kirbyplants,
+/turf/simulated/floor/plasteel{
+ dir = 8;
+ icon_state = "neutralfull"
+ },
+/area/shuttle/escape)
+"aU" = (
+/obj/structure/chair/stool/bar,
+/turf/simulated/floor/plasteel{
+ icon_state = "cafeteria";
+ dir = 2
+ },
+/area/shuttle/escape)
+"aV" = (
+/obj/structure/table/wood,
+/turf/simulated/floor/plasteel{
+ icon_state = "cafeteria";
+ dir = 2
+ },
+/area/shuttle/escape)
+"aW" = (
+/obj/machinery/door/airlock/security/glass{
+ name = "Escape Shuttle Brig";
+ normalspeed = 0;
+ req_access_txt = "63"
+ },
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"aX" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"aZ" = (
+/turf/simulated/shuttle/wall{
+ tag = "icon-swall14";
+ icon_state = "swall14";
+ dir = 2
+ },
+/area/shuttle/escape)
+"ba" = (
+/turf/simulated/floor/plasteel{
+ dir = 8;
+ icon_state = "neutralfull"
+ },
+/area/shuttle/escape)
+"bb" = (
+/obj/structure/sign/greencross,
+/turf/simulated/shuttle/wall{
+ dir = 2;
+ icon_state = "swallc3"
+ },
+/area/shuttle/escape)
+"bc" = (
+/obj/structure/bed/roller,
+/obj/machinery/light{
+ dir = 1;
+ on = 1
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"bd" = (
+/obj/item/storage/box/drinkingglasses,
+/obj/item/reagent_containers/food/drinks/shaker,
+/obj/structure/table/wood,
+/obj/machinery/light{
+ icon_state = "tube1";
dir = 4
},
/turf/simulated/floor/plasteel{
@@ -150,60 +412,7 @@
dir = 2
},
/area/shuttle/escape)
-"aE" = (
-/obj/structure/table/wood,
-/turf/simulated/floor/plasteel{
- icon_state = "cafeteria";
- dir = 2
- },
-/area/shuttle/escape)
-"aF" = (
-/obj/machinery/status_display{
- pixel_y = 30
- },
-/obj/machinery/light/spot{
- tag = "icon-tube1 (NORTH)";
- icon_state = "tube1";
- dir = 1
- },
-/turf/simulated/floor/plasteel{
- icon_state = "cafeteria";
- dir = 2
- },
-/area/shuttle/escape)
-"aG" = (
-/obj/item/storage/box/drinkingglasses,
-/obj/item/reagent_containers/food/drinks/shaker,
-/obj/structure/table/wood,
-/turf/simulated/floor/plasteel{
- icon_state = "cafeteria";
- dir = 2
- },
-/area/shuttle/escape)
-"aH" = (
-/obj/structure/closet/walllocker/emerglocker{
- pixel_x = -28
- },
-/turf/simulated/shuttle/floor4,
-/area/shuttle/escape)
-"aI" = (
-/turf/simulated/shuttle/floor4,
-/area/shuttle/escape)
-"aJ" = (
-/obj/structure/grille,
-/obj/structure/window/full/shuttle{
- icon_state = "15"
- },
-/turf/simulated/floor/plating,
-/area/shuttle/escape)
-"aK" = (
-/obj/structure/chair/comfy/shuttle,
-/turf/simulated/floor/plasteel{
- icon_state = "cafeteria";
- dir = 2
- },
-/area/shuttle/escape)
-"aL" = (
+"be" = (
/obj/machinery/chem_dispenser/beer,
/obj/structure/table/wood,
/turf/simulated/floor/plasteel{
@@ -211,24 +420,40 @@
dir = 2
},
/area/shuttle/escape)
-"aM" = (
-/obj/machinery/door/airlock/security/glass{
- name = "Escape Shuttle Cell";
- req_access_txt = "2"
+"bf" = (
+/obj/structure/table/reinforced,
+/obj/item/storage/firstaid/o2{
+ pixel_x = -3;
+ pixel_y = -3
+ },
+/obj/item/storage/firstaid/regular,
+/obj/item/storage/firstaid/toxin{
+ pixel_x = 5;
+ pixel_y = 5
},
-/turf/simulated/floor/plating,
-/area/shuttle/escape)
-"aN" = (
-/obj/item/storage/box/drinkingglasses,
-/obj/item/reagent_containers/food/drinks/shaker,
-/obj/item/clothing/mask/cigarette/cigar,
-/obj/structure/table/wood,
/turf/simulated/floor/plasteel{
- icon_state = "cafeteria";
- dir = 2
+ tag = "icon-whiteblue (NORTHEAST)";
+ icon_state = "whiteblue";
+ dir = 5
},
/area/shuttle/escape)
-"aO" = (
+"bg" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 1
+ },
+/obj/machinery/light,
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"bh" = (
+/obj/machinery/recharger/wallcharger{
+ pixel_x = 5;
+ pixel_y = -28
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "dark"
+ },
+/area/shuttle/escape)
+"bi" = (
/obj/machinery/chem_dispenser/soda,
/obj/structure/table/wood,
/turf/simulated/floor/plasteel{
@@ -236,842 +461,1093 @@
dir = 2
},
/area/shuttle/escape)
-"aP" = (
-/obj/machinery/door/airlock/shuttle{
- aiControlDisabled = 1;
- hackProof = 1;
- id_tag = "s_docking_airlock";
- name = "Shuttle Hatch"
- },
-/turf/simulated/floor/plating,
-/area/shuttle/escape)
-"aQ" = (
-/obj/structure/chair/comfy/shuttle{
- dir = 1
- },
-/turf/simulated/shuttle/floor4,
-/area/shuttle/escape)
-"aR" = (
-/obj/structure/chair/comfy/shuttle{
- dir = 1
- },
-/turf/simulated/floor/plasteel{
- icon_state = "cafeteria";
- dir = 2
- },
-/area/shuttle/escape)
-"aS" = (
-/turf/simulated/shuttle/wall{
- tag = "icon-swall7";
- icon_state = "swall7";
- dir = 2
- },
-/area/shuttle/escape)
-"aT" = (
-/obj/docking_port/mobile/emergency{
- dir = 4;
- dwidth = 11;
- height = 13;
- timid = 1;
- width = 24
- },
-/obj/machinery/door/airlock/shuttle{
- aiControlDisabled = 1;
- hackProof = 1;
- id_tag = "s_docking_airlock";
- name = "Shuttle Hatch"
- },
-/turf/simulated/shuttle/floor,
-/area/shuttle/escape)
-"aU" = (
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"aV" = (
-/obj/machinery/door/window/southright{
- autoclose = 1;
- name = "engineering door";
- req_access_txt = "32"
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor2"
- },
-/area/shuttle/escape)
-"aW" = (
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
-/turf/simulated/shuttle/floor4,
-/area/shuttle/escape)
-"aX" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor2"
- },
-/area/shuttle/escape)
-"aY" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"aZ" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"ba" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor5"
- },
-/area/shuttle/escape)
-"bb" = (
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/shuttle/floor4,
-/area/shuttle/escape)
-"bc" = (
-/obj/machinery/door/window/southright{
- autoclose = 1;
- name = "science door";
- req_access_txt = "47"
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor5"
- },
-/area/shuttle/escape)
-"bd" = (
-/obj/machinery/door/window/northleft{
- autoclose = 1;
- name = "security door";
+"bj" = (
+/obj/machinery/door/airlock/security/glass{
+ name = "Escape Shuttle Cell";
+ normalspeed = 0;
req_access_txt = "2"
},
/turf/simulated/shuttle/floor4,
/area/shuttle/escape)
-"be" = (
-/obj/structure/window/reinforced{
- dir = 1
+"bk" = (
+/obj/machinery/door/airlock/mining/glass{
+ name = "Escape Shuttle Cargo";
+ normalspeed = 0;
+ req_access_txt = "50"
},
-/turf/simulated/shuttle/floor{
- icon_state = "floor2"
+/turf/simulated/floor/plasteel{
+ dir = 8;
+ icon_state = "neutralfull"
},
/area/shuttle/escape)
-"bf" = (
-/obj/item/radio/intercom{
- dir = 8;
- name = "station intercom (General)";
- pixel_x = -28
+"bl" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
},
-/obj/machinery/light/spot{
- tag = "icon-tube1 (WEST)";
+/obj/machinery/light{
icon_state = "tube1";
dir = 8
},
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
/turf/simulated/shuttle/floor4,
/area/shuttle/escape)
-"bg" = (
-/obj/structure/grille,
-/obj/structure/window/full/shuttle{
- icon_state = "8"
- },
-/turf/simulated/floor/plating,
-/area/shuttle/escape)
-"bh" = (
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bi" = (
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bj" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor2"
- },
-/area/shuttle/escape)
-"bk" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/shuttle/floor4,
-/area/shuttle/escape)
-"bl" = (
-/obj/machinery/door/window/northleft{
- autoclose = 1;
- name = "medical door";
- req_access_txt = "5"
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor3"
- },
-/area/shuttle/escape)
"bm" = (
-/obj/structure/window/reinforced,
-/obj/structure/chair/comfy/shuttle{
+/obj/machinery/sleeper/upgraded{
dir = 4
},
-/turf/simulated/shuttle/floor{
- icon_state = "floor2"
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
},
/area/shuttle/escape)
"bn" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
+/obj/structure/table/reinforced,
/turf/simulated/shuttle/floor{
- icon_state = "floor5"
+ icon_state = "floor2"
},
/area/shuttle/escape)
"bo" = (
-/obj/structure/window/reinforced,
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor2"
+/obj/machinery/door/airlock/shuttle{
+ aiControlDisabled = 1;
+ hackProof = 1;
+ id_tag = "s_docking_airlock";
+ name = "Shuttle Hatch"
},
+/turf/simulated/floor/plasteel,
/area/shuttle/escape)
"bp" = (
-/obj/structure/window/reinforced,
/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/obj/machinery/light{
+ icon_state = "tube1";
dir = 4
},
-/turf/simulated/floor/plasteel,
+/turf/simulated/shuttle/floor4,
/area/shuttle/escape)
"bq" = (
-/obj/structure/window/reinforced,
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"br" = (
-/obj/structure/window/reinforced,
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor5"
- },
-/area/shuttle/escape)
-"bs" = (
-/obj/structure/closet/walllocker/emerglocker{
- pixel_x = 28
- },
-/obj/machinery/light/spot{
- tag = "icon-tube1 (EAST)";
- icon_state = "tube1";
- dir = 4
- },
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor3"
- },
-/area/shuttle/escape)
-"bt" = (
-/obj/structure/window/reinforced,
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor5"
- },
-/area/shuttle/escape)
-"bu" = (
-/obj/machinery/light/spot{
- tag = "icon-tube1 (WEST)";
- icon_state = "tube1";
- dir = 8
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bv" = (
-/obj/machinery/light/spot{
- tag = "icon-tube1 (EAST)";
- icon_state = "tube1";
- dir = 4
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bw" = (
-/obj/machinery/door/airlock/shuttle{
- aiControlDisabled = 1;
- hackProof = 1;
- id_tag = "s_docking_airlock";
- name = "Shuttle Hatch"
- },
-/turf/simulated/shuttle/floor,
-/area/shuttle/escape)
-"bx" = (
-/obj/structure/noticeboard,
-/turf/simulated/shuttle/wall{
- icon_state = "swall12";
- dir = 2
- },
-/area/shuttle/escape)
-"by" = (
-/obj/machinery/door/airlock/shuttle{
- aiControlDisabled = 1;
- hackProof = 1;
- id_tag = null;
- name = "Shuttle Cargo Hatch"
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor3"
- },
-/area/shuttle/escape)
-"bz" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor3"
- },
-/area/shuttle/escape)
-"bA" = (
-/obj/structure/window/reinforced{
- dir = 1
- },
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor5"
- },
-/area/shuttle/escape)
-"bB" = (
-/obj/structure/table,
-/obj/item/storage/firstaid/o2{
- layer = 2.8;
- pixel_x = 4;
- pixel_y = 6
- },
-/obj/item/storage/firstaid/regular{
- pixel_x = 2;
- pixel_y = 6
- },
-/obj/item/storage/firstaid/regular{
- pixel_x = -2;
- pixel_y = 4
- },
-/obj/item/bodybag{
- pixel_x = 5
- },
-/obj/item/storage/firstaid/fire,
-/obj/item/storage/firstaid/regular{
- pixel_x = 2;
- pixel_y = 3
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bC" = (
-/obj/machinery/door/airlock/medical/glass{
- id_tag = null;
- name = "Escape Shuttle Infirmary";
- req_access_txt = "0"
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bD" = (
-/turf/simulated/shuttle/wall{
- icon_state = "swall11";
- dir = 2
- },
-/area/shuttle/escape)
-"bE" = (
-/obj/machinery/door/airlock/shuttle{
- aiControlDisabled = 1;
- hackProof = 1;
- id_tag = "s_docking_airlock";
- name = "Shuttle Hatch"
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor2"
- },
-/area/shuttle/escape)
-"bF" = (
-/obj/structure/chair/comfy/shuttle{
- dir = 4
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor3"
- },
-/area/shuttle/escape)
-"bG" = (
-/turf/simulated/shuttle/floor{
- icon_state = "floor3"
- },
-/area/shuttle/escape)
-"bH" = (
-/obj/structure/chair/comfy/shuttle{
- dir = 8
- },
-/turf/simulated/shuttle/floor{
- icon_state = "floor3"
- },
-/area/shuttle/escape)
-"bI" = (
-/obj/machinery/vending/wallmed{
- layer = 3.3;
- name = "Emergency NanoMed";
- pixel_x = 28;
- pixel_y = 0;
- req_access_txt = "0"
- },
-/obj/machinery/sleeper,
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bJ" = (
-/obj/item/radio/intercom{
- dir = 4;
- name = "station intercom (General)";
- pixel_x = 28
- },
-/obj/item/extinguisher,
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bK" = (
-/obj/structure/closet/cardboard,
-/obj/machinery/light/spot{
- tag = "icon-tube1 (WEST)";
- icon_state = "tube1";
- dir = 8
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bL" = (
-/obj/machinery/recharge_station,
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bN" = (
-/obj/structure/bed/roller,
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bO" = (
-/obj/machinery/sleeper,
-/obj/machinery/light/spot{
- tag = "icon-tube1 (EAST)";
- icon_state = "tube1";
- dir = 4
- },
-/turf/simulated/floor/plasteel,
-/area/shuttle/escape)
-"bP" = (
/turf/space,
/turf/simulated/shuttle/wall{
icon_state = "swall_f5";
dir = 2
},
/area/shuttle/escape)
-"bQ" = (
-/obj/structure/window/reinforced{
+"br" = (
+/obj/structure/chair/comfy/shuttle{
dir = 1
},
-/obj/structure/shuttle/engine/heater,
-/turf/simulated/shuttle/plating,
+/turf/simulated/shuttle/floor{
+ icon_state = "floor2"
+ },
/area/shuttle/escape)
-"bR" = (
+"bs" = (
+/turf/simulated/shuttle/wall{
+ icon_state = "swall11";
+ dir = 2
+ },
+/area/shuttle/escape)
+"bt" = (
+/turf/simulated/shuttle/wall{
+ icon_state = "swall7";
+ dir = 2
+ },
+/area/shuttle/escape)
+"bu" = (
/obj/structure/shuttle/engine/heater,
/obj/structure/window/reinforced{
dir = 1
},
/turf/simulated/shuttle/plating,
/area/shuttle/escape)
-"bS" = (
+"bv" = (
/turf/space,
/turf/simulated/shuttle/wall{
icon_state = "swall_f9";
dir = 2
},
/area/shuttle/escape)
-"bT" = (
+"bw" = (
/obj/structure/shuttle/engine/propulsion,
/turf/simulated/shuttle/plating,
/area/shuttle/escape)
+"bx" = (
+/obj/structure/bed/roller,
+/obj/machinery/iv_drip,
+/obj/machinery/light,
+/turf/simulated/floor/plasteel{
+ tag = "icon-whiteblue (EAST)";
+ icon_state = "whiteblue";
+ dir = 4
+ },
+/area/shuttle/escape)
+"by" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor2"
+ },
+/area/shuttle/escape)
+"bz" = (
+/turf/simulated/shuttle/floor{
+ icon_state = "floor2"
+ },
+/area/shuttle/escape)
+"bA" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor2"
+ },
+/area/shuttle/escape)
+"bB" = (
+/obj/structure/table/reinforced,
+/turf/simulated/shuttle/floor{
+ icon_state = "floor5"
+ },
+/area/shuttle/escape)
+"bC" = (
+/obj/structure/sign/directions/engineering,
+/turf/simulated/shuttle/wall{
+ icon_state = "swall12";
+ dir = 2
+ },
+/area/shuttle/escape)
+"bD" = (
+/obj/machinery/door/airlock/shuttle{
+ aiControlDisabled = 1;
+ hackProof = 1;
+ id_tag = "s_docking_airlock";
+ name = "Shuttle Hatch"
+ },
+/obj/docking_port/mobile/emergency{
+ dir = 4;
+ dwidth = 11;
+ height = 18;
+ timid = 1;
+ width = 29
+ },
+/turf/simulated/floor/plasteel,
+/area/shuttle/escape)
+"bE" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 1
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor5"
+ },
+/area/shuttle/escape)
+"bF" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"bG" = (
+/obj/machinery/status_display,
+/turf/simulated/shuttle/wall{
+ tag = "icon-swall14";
+ icon_state = "swall14";
+ dir = 2
+ },
+/area/shuttle/escape)
+"bH" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 4
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"bI" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor5"
+ },
+/area/shuttle/escape)
+"bJ" = (
+/turf/simulated/shuttle/floor{
+ icon_state = "floor5"
+ },
+/area/shuttle/escape)
+"bK" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor5"
+ },
+/area/shuttle/escape)
+"bL" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 8
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor2"
+ },
+/area/shuttle/escape)
+"bM" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 4
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor2"
+ },
+/area/shuttle/escape)
+"bO" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 8
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "bot";
+ dir = 1
+ },
+/area/shuttle/escape)
+"bP" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "bot";
+ dir = 1
+ },
+/area/shuttle/escape)
+"bQ" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "bot";
+ dir = 1
+ },
+/area/shuttle/escape)
+"bR" = (
+/obj/structure/flora/ausbushes/grassybush,
+/obj/structure/flora/ausbushes/lavendergrass,
+/obj/structure/flora/ausbushes/ppflowers,
+/obj/structure/flora/ausbushes/sunnybush,
+/obj/structure/window/full/shuttle,
+/turf/simulated/floor/grass,
+/area/shuttle/escape)
+"bS" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 8
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor5"
+ },
+/area/shuttle/escape)
+"bT" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 4
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor5"
+ },
+/area/shuttle/escape)
"bU" = (
-/turf/space,
+/obj/structure/sign/directions/science,
+/turf/simulated/shuttle/wall{
+ icon_state = "swall12";
+ dir = 2
+ },
+/area/shuttle/escape)
+"bV" = (
+/obj/structure/sign/directions/cargo,
+/turf/simulated/shuttle/wall{
+ icon_state = "swall12";
+ dir = 2
+ },
+/area/shuttle/escape)
+"bW" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/obj/machinery/recharger/wallcharger{
+ pixel_x = -24
+ },
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"bX" = (
+/obj/machinery/ai_status_display,
+/turf/simulated/shuttle/wall{
+ icon_state = "swall3";
+ dir = 2
+ },
+/area/shuttle/escape)
+"bY" = (
+/obj/structure/flora/ausbushes/grassybush,
+/obj/structure/flora/ausbushes/lavendergrass,
+/obj/structure/flora/ausbushes/ywflowers,
+/obj/structure/flora/ausbushes/fernybush,
+/obj/structure/window/full/shuttle,
+/turf/simulated/floor/grass,
+/area/shuttle/escape)
+"bZ" = (
+/obj/machinery/recharge_station/upgraded,
+/turf/simulated/floor/plasteel{
+ dir = 8;
+ icon_state = "neutralfull"
+ },
+/area/shuttle/escape)
+"ca" = (
+/obj/machinery/light,
+/turf/simulated/floor/plasteel{
+ dir = 8;
+ icon_state = "neutralfull"
+ },
+/area/shuttle/escape)
+"cb" = (
+/obj/machinery/door/airlock/engineering/glass{
+ name = "Escape Shuttle Engineering";
+ normalspeed = 0;
+ req_access_txt = "32";
+ req_one_access_txt = "0"
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor2"
+ },
+/area/shuttle/escape)
+"cc" = (
+/obj/structure/extinguisher_cabinet,
+/turf/simulated/shuttle/wall{
+ icon_state = "swall3";
+ dir = 2
+ },
+/area/shuttle/escape)
+"cd" = (
+/obj/machinery/door/airlock/research/glass{
+ name = "Escape Shuttle Research";
+ normalspeed = 0;
+ req_access_txt = "47"
+ },
+/turf/simulated/shuttle/floor{
+ icon_state = "floor5"
+ },
+/area/shuttle/escape)
+"cf" = (
+/turf/simulated/shuttle/wall{
+ icon_state = "swallc4"
+ },
+/area/shuttle/escape)
+"ck" = (
+/obj/structure/chair/comfy/shuttle{
+ dir = 8
+ },
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 4
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "bot";
+ dir = 1
+ },
+/area/shuttle/escape)
+"cp" = (
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"cw" = (
+/obj/structure/bed/roller,
+/obj/machinery/iv_drip,
+/turf/simulated/floor/plasteel{
+ tag = "icon-whiteblue (EAST)";
+ icon_state = "whiteblue";
+ dir = 4
+ },
+/area/shuttle/escape)
+"cA" = (
+/obj/machinery/light{
+ icon_state = "tube1";
+ dir = 8
+ },
+/obj/structure/chair/comfy/shuttle{
+ dir = 4
+ },
+/turf/simulated/floor/plasteel{
+ icon_state = "bot";
+ dir = 1
+ },
+/area/shuttle/escape)
+"cD" = (
+/obj/structure/table/reinforced,
+/obj/item/storage/backpack/medic,
+/obj/item/storage/belt/medical,
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"cE" = (
+/obj/structure/bed/roller,
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"cG" = (
+/obj/structure/table/reinforced,
+/obj/item/clothing/gloves/color/latex/nitrile,
+/obj/item/clothing/mask/breath,
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"cH" = (
+/turf/simulated/shuttle/wall{
+ icon_state = "wall3"
+ },
+/area/shuttle/escape)
+"sc" = (
+/obj/machinery/door/airlock/medical/glass{
+ id_tag = null;
+ name = "Escape Shuttle Medical Seating";
+ normalspeed = 0;
+ req_access_txt = "5"
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"xD" = (
+/obj/structure/table/reinforced,
+/obj/item/reagent_containers/iv_bag/blood/random,
+/obj/item/reagent_containers/iv_bag/blood/random,
+/obj/item/reagent_containers/iv_bag/blood/random,
+/obj/item/reagent_containers/iv_bag/blood/random,
+/obj/item/reagent_containers/iv_bag/blood/random,
+/obj/item/reagent_containers/iv_bag/blood/random,
+/turf/simulated/floor/plasteel{
+ tag = "icon-whiteblue (EAST)";
+ icon_state = "whiteblue";
+ dir = 4
+ },
+/area/shuttle/escape)
+"PY" = (
+/obj/structure/table/reinforced,
+/obj/item/storage/firstaid/machine{
+ pixel_x = -5;
+ pixel_y = -5
+ },
+/obj/item/storage/firstaid/regular,
+/obj/item/storage/firstaid/adv{
+ pixel_x = 5;
+ pixel_y = 5
+ },
+/turf/simulated/floor/plasteel{
+ dir = 2;
+ icon_state = "cmo"
+ },
+/area/shuttle/escape)
+"Qf" = (
+/obj/machinery/defibrillator_mount/loaded,
+/turf/simulated/shuttle/wall{
+ icon_state = "swall12";
+ dir = 2
+ },
+/area/shuttle/escape)
+"UN" = (
+/obj/structure/chair/comfy/shuttle,
+/turf/simulated/shuttle/floor4,
+/area/shuttle/escape)
+"Wy" = (
+/obj/structure/chair/comfy/shuttle,
+/obj/machinery/light{
+ dir = 1;
+ on = 1
+ },
+/turf/simulated/shuttle/floor4,
/area/shuttle/escape)
(1,1,1) = {"
aa
-aa
-aa
-aa
-aa
ab
-ap
-ap
-ap
-aP
-aS
-aT
-ap
-aB
-bg
-aJ
-ap
-bw
-aS
-bE
+aq
ac
-ap
-bP
+aq
+aP
+aq
+aq
+aq
+bo
+aP
+bD
+aq
+ac
+ac
+ac
+aq
+bo
+aq
+bo
+bt
+aq
+ac
+ac
+aq
+aq
+bt
+bq
aa
"}
(2,1,1) = {"
aa
-aa
-ab
-ap
-ap
-aw
+av
+az
+bl
+az
+ac
+az
+bW
az
aH
-aI
-aI
-ae
-aU
-bf
-aW
-bj
-bm
-bu
-aU
-ae
-aU
-aU
-bK
-ax
+aN
+ba
bP
+bO
+bP
+bP
+bP
+ba
+aT
+ba
+bR
+bP
+cA
+bP
+bP
+bP
+av
+cH
+cH
"}
(3,1,1) = {"
aa
-ab
-af
-aq
-aq
-ae
-aA
-aI
-aI
-aI
-ae
-aU
-bd
-aI
-be
-aV
-aU
-aU
-bx
-aU
-aU
-bL
-bQ
-bT
+ac
+aH
+aH
+aH
+bj
+aH
+aH
+aH
+aH
+av
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+bV
+ba
+ba
+ba
+ba
+ba
+av
+bu
+bw
"}
(4,1,1) = {"
aa
-ae
-ai
-al
-aq
-ae
-az
-aI
-aI
-aQ
-ae
-aU
-bk
-bb
+av
aX
-bo
-aU
-aU
-by
-aU
-aU
-bL
+bp
+aX
+ac
+aH
+aH
+aH
+aR
+av
+ba
bQ
-bT
+bQ
+bQ
+bQ
+bQ
+bQ
+ba
+ba
+bk
+ba
+ba
+ba
+ba
+ba
+ac
+bu
+bw
"}
(5,1,1) = {"
-aa
-ae
-aj
-al
+ab
+bs
+aq
+aq
aq
-ae
-az
-aI
-aI
-aQ
-ae
-aU
-aB
-bg
-bg
-aJ
-aU
-aU
-aB
-bg
-bg
-aJ
aw
-bS
+Wy
+aH
+aH
+bg
+av
+ba
+bP
+bP
+bP
+bP
+bP
+bP
+ba
+ba
+bR
+bQ
+ck
+bQ
+bQ
+bQ
+av
+cH
+cH
"}
(6,1,1) = {"
-ab
-af
-ak
-al
-aq
-ax
-aB
-aJ
-aM
-aB
-aJ
-aU
-aY
-bh
-bh
-bp
-aU
-aU
-aY
-bh
-bh
-bh
+av
ae
-bU
+am
+ar
+ay
+aD
+aJ
+aH
+aH
+aH
+aW
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ca
+bG
+bY
+cc
+bR
+bX
+bY
+aw
+cH
+cH
"}
(7,1,1) = {"
ac
-ag
-al
-aq
-aq
-ay
-aC
-aC
-aC
-aC
-aC
-aU
-aU
-aU
-aU
-aU
-aU
-aU
-aU
-aU
-aU
-aU
-ae
-bU
+af
+an
+as
+aA
+av
+UN
+aG
+aH
+aH
+aW
+ba
+bQ
+bQ
+bQ
+bQ
+bQ
+bQ
+ba
+ba
+bR
+by
+bL
+by
+by
+bn
+av
+cH
+cH
"}
(8,1,1) = {"
-ad
-ah
-am
+ac
+ag
+ao
+an
+bh
+aZ
aq
aq
-ae
-aD
-aD
-aD
-aD
-aD
-aU
-aZ
-bi
-bi
-bq
-aU
-aU
-aZ
-bi
-bi
-bi
-ae
-bU
+aW
+ac
+cf
+ba
+bP
+bP
+bP
+bP
+bP
+bP
+ba
+ba
+bC
+bz
+bz
+bz
+bz
+br
+av
+bu
+bw
"}
(9,1,1) = {"
-aa
-ae
+ac
+ah
+ao
+an
an
-al
-aq
-ae
aE
+an
+an
+an
+an
aE
-aE
-aE
-aE
-aU
-aB
-bg
-bg
-aJ
-aU
-aU
-aB
-bg
-bg
-aJ
-aw
-bP
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+cb
+bz
+bz
+bz
+bz
+br
+ac
+bu
+bw
"}
(10,1,1) = {"
-aa
-ae
+ac
+ai
ao
-al
-aq
-ae
-aC
-aC
-aC
-aC
-aC
-aU
-bz
-bF
+an
+an
+aE
+an
+an
+an
+an
+aE
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ba
ba
-br
-aU
-aU
-bC
-aU
-aU
-bN
bR
-bT
+bz
+bz
+bz
+bz
+br
+av
+bu
+bw
"}
(11,1,1) = {"
-aa
-ad
-ah
-aq
-aq
-ae
-aF
-aK
-aN
-aR
-aC
-aU
-bl
-bG
-bn
-bc
-aU
-aU
ac
-aU
-aU
-bB
+aj
+ao
+at
+an
+aZ
+aq
+aq
+aL
+ac
+bb
+ba
+bQ
+bQ
+bQ
+bQ
+bQ
+bQ
+ba
+ba
bR
-bT
+bA
+bM
+bA
+bA
+bn
+av
+bu
+bw
"}
(12,1,1) = {"
-aa
-aa
-ad
-ap
-ap
+ac
+ak
+an
+au
+aB
+av
+bm
+cp
+cp
+cp
+aI
+ba
+bP
+bP
+bP
+bP
+bP
+bP
+ba
+ca
+bG
+bY
+cc
+bR
+bX
+bY
aw
-aG
-aL
-aO
-aR
-aC
-aU
-bs
-bH
-bA
-bt
-bv
-aU
-ae
-bI
-bJ
-bO
-ax
-bS
+cH
+cH
"}
(13,1,1) = {"
+av
+al
+ap
+ax
+aC
+aD
+bm
+cp
+cp
+cp
+aI
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+ba
+bR
+bI
+bS
+bI
+bI
+bB
+av
+cH
+cH
+"}
+(14,1,1) = {"
+ad
+bt
+aq
+aq
+aq
+aw
+bc
+cp
+cp
+bx
+av
+ba
+aS
+aU
+aU
+aU
+aU
+aS
+ba
+ba
+bU
+bJ
+bJ
+bJ
+bJ
+bE
+av
+cH
+cH
+"}
+(15,1,1) = {"
aa
+av
+bF
+aM
+bF
+Qf
+cE
+cp
+cp
+cw
+av
+ba
+aO
+aV
+aV
+aV
+aV
+aU
+ba
+ba
+cd
+bJ
+bJ
+bJ
+bJ
+bE
+ac
+bu
+bw
+"}
+(16,1,1) = {"
aa
+ac
+cp
+cp
+cp
+sc
+cp
+cp
+cp
+xD
+av
+ba
+aS
+aS
+aS
+aS
+aV
+aU
+ba
+ba
+bR
+bJ
+bJ
+bJ
+bJ
+bE
+av
+bu
+bw
+"}
+(17,1,1) = {"
aa
-aa
+av
+aF
+bH
+aF
+av
+cG
+PY
+cD
+bf
+av
+aT
+aS
+bd
+be
+bi
+aV
+aU
+bZ
+bZ
+bR
+bK
+bT
+bK
+bK
+bB
+av
+cH
+cH
+"}
+(18,1,1) = {"
aa
ad
-ap
-ap
-ap
+aq
ac
-ap
-ap
-ap
-aB
-bg
-aJ
-ap
+aq
+bs
+aq
+aq
+aq
+aq
+bs
ac
-bD
-ap
-ap
-ap
-bS
+ac
+ac
+ac
+ac
+ac
+aq
+ac
+ac
+bs
+ac
+aq
+ac
+ac
+ac
+bs
+bv
aa
"}
diff --git a/_maps/metastation.dm b/_maps/metastation.dm
index 7747ad79fb8..0941ffc453a 100644
--- a/_maps/metastation.dm
+++ b/_maps/metastation.dm
@@ -23,7 +23,7 @@ z7 = empty space
#define MAP_TRANSITION_CONFIG list(\
DECLARE_LEVEL(MAIN_STATION, CROSSLINKED, list(STATION_LEVEL, STATION_CONTACT, REACHABLE, AI_OK)),\
DECLARE_LEVEL(CENTCOMM, SELFLOOPING, list(ADMIN_LEVEL, BLOCK_TELEPORT, IMPEDES_MAGIC)),\
-DECLARE_LEVEL(MINING, SELFLOOPING, list(REACHABLE, STATION_CONTACT, HAS_WEATHER, ORE_LEVEL, AI_OK)))
+DECLARE_LEVEL(MINING, SELFLOOPING, list(ORE_LEVEL, REACHABLE, STATION_CONTACT, HAS_WEATHER, AI_OK)))
#define USING_MAP_DATUM /datum/map/metastation
diff --git a/code/_DATASTRUCTURES/stacks.dm b/code/_DATASTRUCTURES/stacks.dm
deleted file mode 100644
index b310a3b9401..00000000000
--- a/code/_DATASTRUCTURES/stacks.dm
+++ /dev/null
@@ -1,56 +0,0 @@
-/datum/stack
- var/list/stack = list()
- var/max_elements = 0
-
-/datum/stack/New(list/elements,max)
- ..()
- if(elements)
- stack = elements.Copy()
- if(max)
- max_elements = max
-
-/datum/stack/proc/Pop()
- if(is_empty())
- return null
- . = stack[stack.len]
- stack.Cut(stack.len,0)
-
-/datum/stack/proc/Push(element)
- if(max_elements && (stack.len+1 > max_elements))
- return null
- stack += element
-
-/datum/stack/proc/Top()
- if(is_empty())
- return null
- . = stack[stack.len]
-
-/datum/stack/proc/is_empty()
- . = stack.len ? 0 : 1
-
-//Rotate entire stack left with the leftmost looping around to the right
-/datum/stack/proc/RotateLeft()
- if(is_empty())
- return 0
- . = stack[1]
- stack.Cut(1,2)
- Push(.)
-
-//Rotate entire stack to the right with the rightmost looping around to the left
-/datum/stack/proc/RotateRight()
- if(is_empty())
- return 0
- . = stack[stack.len]
- stack.Cut(stack.len,0)
- stack.Insert(1,.)
-
-
-/datum/stack/proc/Copy()
- var/datum/stack/S=new()
- S.stack = stack.Copy()
- S.max_elements = max_elements
- return S
-
-
-/datum/stack/proc/Clear()
- stack.Cut()
diff --git a/code/__DEFINES/gamemode.dm b/code/__DEFINES/gamemode.dm
index 73a812e8f5b..2de0a86c268 100644
--- a/code/__DEFINES/gamemode.dm
+++ b/code/__DEFINES/gamemode.dm
@@ -15,6 +15,7 @@
#define GAMEMODE_IS_NUCLEAR (SSticker && istype(SSticker.mode, /datum/game_mode/nuclear))
#define GAMEMODE_IS_REVOLUTION (SSticker && istype(SSticker.mode, /datum/game_mode/revolution))
#define GAMEMODE_IS_WIZARD (SSticker && istype(SSticker.mode, /datum/game_mode/wizard))
+#define GAMEMODE_IS_RAGIN_MAGES (SSticker && istype(SSticker.mode, /datum/game_mode/wizard/raginmages))
//special roles
// Distinct from the ROLE_X defines because some antags have multiple special roles but only one ban type
diff --git a/code/__DEFINES/subsystems.dm b/code/__DEFINES/subsystems.dm
index b1773ba10d5..153eca7f373 100644
--- a/code/__DEFINES/subsystems.dm
+++ b/code/__DEFINES/subsystems.dm
@@ -44,7 +44,7 @@
// Subsystem init_order, from highest priority to lowest priority
// Subsystems shutdown in the reverse of the order they initialize in
// The numbers just define the ordering, they are meaningless otherwise.
-
+#define INIT_ORDER_TITLE 100 // This **MUST** load first or people will se blank lobby screens
#define INIT_ORDER_GARBAGE 19
#define INIT_ORDER_DBCORE 18
#define INIT_ORDER_BLACKBOX 17
diff --git a/code/__HELPERS/global_lists.dm b/code/__HELPERS/global_lists.dm
index 0002bc0d488..cbc691e3c2a 100644
--- a/code/__HELPERS/global_lists.dm
+++ b/code/__HELPERS/global_lists.dm
@@ -23,6 +23,14 @@
init_subtypes(/datum/surgery_step, GLOB.surgery_steps)
+ // Different bodies
+ __init_body_accessory(/datum/body_accessory/body)
+ // Different tails
+ __init_body_accessory(/datum/body_accessory/tail)
+
+ // Setup species:accessory relations
+ initialize_body_accessory_by_species()
+
for(var/path in (subtypesof(/datum/surgery)))
GLOB.surgeries_list += new path()
@@ -30,6 +38,7 @@
init_datum_subtypes(/datum/superheroes, GLOB.all_superheroes, null, "name")
init_datum_subtypes(/datum/language, GLOB.all_languages, null, "name")
+ // Setup languages
for(var/language_name in GLOB.all_languages)
var/datum/language/L = GLOB.all_languages[language_name]
if(!(L.flags & NONGLOBAL))
@@ -54,7 +63,61 @@
var/datum/pipes/P = D
if(P.rpd_dispensable)
GLOB.rpd_pipe_list += list(list("pipe_name" = P.pipe_name, "pipe_id" = P.pipe_id, "pipe_type" = P.pipe_type, "pipe_category" = P.pipe_category, "orientations" = P.orientations, "pipe_icon" = P.pipe_icon, "bendy" = P.bendy))
- return 1
+
+ // Setup PAI software
+ for(var/type in subtypesof(/datum/pai_software))
+ var/datum/pai_software/P = new type()
+ if(GLOB.pai_software_by_key[P.id])
+ var/datum/pai_software/O = GLOB.pai_software_by_key[P.id]
+ to_chat(world, "pAI software module [P.name] has the same key as [O.name]!")
+ continue
+ GLOB.pai_software_by_key[P.id] = P
+ if(P.default)
+ GLOB.default_pai_software[P.id] = P
+
+ // Setup loadout gear
+ for(var/geartype in subtypesof(/datum/gear))
+ var/datum/gear/G = geartype
+
+ var/use_name = initial(G.display_name)
+ var/use_category = initial(G.sort_category)
+
+ if(G == initial(G.subtype_path))
+ continue
+
+ if(!use_name)
+ error("Loadout - Missing display name: [G]")
+ continue
+ if(!initial(G.cost))
+ error("Loadout - Missing cost: [G]")
+ continue
+ if(!initial(G.path))
+ error("Loadout - Missing path definition: [G]")
+ continue
+
+ if(!GLOB.loadout_categories[use_category])
+ GLOB.loadout_categories[use_category] = new /datum/loadout_category(use_category)
+ var/datum/loadout_category/LC = GLOB.loadout_categories[use_category]
+ GLOB.gear_datums[use_name] = new geartype
+ LC.gear[use_name] = GLOB.gear_datums[use_name]
+
+ GLOB.loadout_categories = sortAssoc(GLOB.loadout_categories)
+ for(var/loadout_category in GLOB.loadout_categories)
+ var/datum/loadout_category/LC = GLOB.loadout_categories[loadout_category]
+ LC.gear = sortAssoc(LC.gear)
+
+
+ // Setup a list of robolimbs
+ GLOB.basic_robolimb = new()
+ for(var/limb_type in typesof(/datum/robolimb))
+ var/datum/robolimb/R = new limb_type()
+ GLOB.all_robolimbs[R.company] = R
+ if(!R.unavailable_at_chargen)
+ if(R != "head" && R != "chest" && R != "groin" ) //Part of the method that ensures only IPCs can access head, chest and groin prosthetics.
+ if(R.has_subtypes) //Ensures solos get added to the list as well be incorporating has_subtypes == 1 and has_subtypes == 2.
+ GLOB.chargen_robolimbs[R.company] = R //List only main brands and solo parts.
+ if(R.selectable)
+ GLOB.selectable_robolimbs[R.company] = R
/* // Uncomment to debug chemical reaction list.
/client/verb/debug_chemical_list()
diff --git a/code/_DATASTRUCTURES/heap.dm b/code/__HELPERS/heap.dm
similarity index 80%
rename from code/_DATASTRUCTURES/heap.dm
rename to code/__HELPERS/heap.dm
index 7246eff8771..b878969571e 100644
--- a/code/_DATASTRUCTURES/heap.dm
+++ b/code/__HELPERS/heap.dm
@@ -1,28 +1,28 @@
//////////////////////
-//Heap object
+//datum/heap object
//////////////////////
-/Heap
+/datum/heap
var/list/L
var/cmp
-/Heap/New(compare)
+/datum/heap/New(compare)
L = new()
cmp = compare
-/Heap/proc/IsEmpty()
+/datum/heap/proc/IsEmpty()
return !L.len
//Insert and place at its position a new node in the heap
-/Heap/proc/Insert(atom/A)
+/datum/heap/proc/Insert(atom/A)
L.Add(A)
Swim(L.len)
//removes and returns the first element of the heap
//(i.e the max or the min dependant on the comparison function)
-/Heap/proc/Pop()
+/datum/heap/proc/Pop()
if(!L.len)
return 0
. = L[1]
@@ -33,7 +33,7 @@
Sink(1)
//Get a node up to its right position in the heap
-/Heap/proc/Swim(var/index)
+/datum/heap/proc/Swim(var/index)
var/parent = round(index * 0.5)
while(parent > 0 && (call(cmp)(L[index],L[parent]) > 0))
@@ -42,7 +42,7 @@
parent = round(index * 0.5)
//Get a node down to its right position in the heap
-/Heap/proc/Sink(var/index)
+/datum/heap/proc/Sink(var/index)
var/g_child = GetGreaterChild(index)
while(g_child > 0 && (call(cmp)(L[index],L[g_child]) < 0))
@@ -52,7 +52,7 @@
//Returns the greater (relative to the comparison proc) of a node children
//or 0 if there's no child
-/Heap/proc/GetGreaterChild(var/index)
+/datum/heap/proc/GetGreaterChild(var/index)
if(index * 2 > L.len)
return 0
@@ -65,11 +65,11 @@
return index * 2
//Replaces a given node so it verify the heap condition
-/Heap/proc/ReSort(atom/A)
+/datum/heap/proc/ReSort(atom/A)
var/index = L.Find(A)
Swim(index)
Sink(index)
-/Heap/proc/List()
+/datum/heap/proc/List()
. = L.Copy()
diff --git a/code/__HELPERS/mobs.dm b/code/__HELPERS/mobs.dm
index f437c409088..0d3b26d0340 100644
--- a/code/__HELPERS/mobs.dm
+++ b/code/__HELPERS/mobs.dm
@@ -289,11 +289,14 @@ This is always put in the attack log.
var/user_str = key_name_log(user) + COORD(user)
var/target_str
+ var/target_info
if(isatom(target))
var/atom/AT = target
target_str = key_name_log(AT) + COORD(AT)
+ target_info = key_name_admin(target)
else
target_str = target
+ target_info = target
var/mob/MU = user
var/mob/MT = target
if(istype(MU))
@@ -317,10 +320,13 @@ This is always put in the attack log.
var/area/A = get_area(MT)
if(A && A.hide_attacklogs)
loglevel = ATKLOG_ALMOSTALL
+ else
+ loglevel = ATKLOG_ALL // Hitting an object. Not a mob
if(isLivingSSD(target)) // Attacks on SSDs are shown to admins with any log level except ATKLOG_NONE. Overrides custom level
loglevel = ATKLOG_FEW
- msg_admin_attack("[key_name_admin(user)] vs [key_name_admin(target)]: [what_done]", loglevel)
+
+ msg_admin_attack("[key_name_admin(user)] vs [target_info]: [what_done]", loglevel)
/proc/do_mob(mob/user, mob/target, time = 30, uninterruptible = 0, progress = 1, list/extra_checks = list())
if(!user || !target)
@@ -579,7 +585,8 @@ GLOBAL_LIST_INIT(do_after_once_tracker, list())
LogMouseMacro(".mouse", params)
/proc/update_all_mob_security_hud()
- for(var/mob/living/carbon/human/H in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
H.sec_hud_set_security_status()
/proc/getviewsize(view)
@@ -616,3 +623,34 @@ GLOBAL_LIST_INIT(do_after_once_tracker, list())
chosen = pick(mob_spawn_meancritters)
var/mob/living/simple_animal/C = new chosen(spawn_location)
return C
+
+//determines the job of a mob, taking into account job transfers
+/proc/determine_role(mob/living/P)
+ var/datum/mind/M = P.mind
+ if(!M)
+ return
+ return M.playtime_role ? M.playtime_role : M.assigned_role //returns current role
+
+/** checks the security force on station and returns a list of numbers, of the form:
+ * total, active, dead, antag
+ * where active is defined as conscious (STAT = 0) and not an antag
+*/
+/proc/check_active_security_force()
+ var/sec_positions = GLOB.security_positions - "Magistrate" - "Brig Physician"
+ var/total = 0
+ var/active = 0
+ var/dead = 0
+ var/antag = 0
+ for(var/p in GLOB.human_list) //contains only human mobs, so no type check needed
+ var/mob/living/carbon/human/player = p //need to tell it what type it is or we can't access stat without the dreaded :
+ if(determine_role(player) in sec_positions)
+ total++
+ if(player.stat == DEAD)
+ dead++
+ continue
+ if(isAntag(player))
+ antag++
+ continue
+ if(player.stat == CONSCIOUS)
+ active++
+ return list(total, active, dead, antag)
diff --git a/code/__HELPERS/text.dm b/code/__HELPERS/text.dm
index ecbebf813df..47650177283 100644
--- a/code/__HELPERS/text.dm
+++ b/code/__HELPERS/text.dm
@@ -533,7 +533,7 @@ proc/checkhtml(var/t)
text = replacetext(text, "\[/grid\]", "")
text = replacetext(text, "\[row\]", "
")
text = replacetext(text, "\[cell\]", "")
- text = replacetext(text, "\[logo\]", " ")
+ text = replacetext(text, "\[logo\]", "​ ")
text = replacetext(text, "\[time\]", "[station_time_timestamp()]") // TO DO
if(!no_font)
if(P)
diff --git a/code/__HELPERS/unsorted.dm b/code/__HELPERS/unsorted.dm
index 7e57a394988..d6caa29f670 100644
--- a/code/__HELPERS/unsorted.dm
+++ b/code/__HELPERS/unsorted.dm
@@ -1919,6 +1919,16 @@ GLOBAL_DATUM_INIT(dview_mob, /mob/dview, new)
return pois
+/*
+ * Returns all player mobs in an assoc list with ckey as key and the mob as value
+*/
+/proc/get_assoc_mob_list_by_ckey()
+ var/list/mob/mobs = list()
+ for(var/i in GLOB.player_list)
+ var/mob/M = i
+ mobs[M.ckey] = M
+ return mobs
+
/proc/flash_color(mob_or_client, flash_color="#960000", flash_time=20)
var/client/C
if(istype(mob_or_client, /mob))
@@ -2017,5 +2027,10 @@ GLOBAL_DATUM_INIT(dview_mob, /mob/dview, new)
set waitfor = FALSE
return call(source, proctype)(arglist(arguments))
+/proc/IsFrozen(atom/A)
+ if(A in GLOB.frozen_atom_list)
+ return TRUE
+ return FALSE
+
/// Waits at a line of code until X is true
#define UNTIL(X) while(!(X)) stoplag()
diff --git a/code/_globalvars/mapping.dm b/code/_globalvars/mapping.dm
index d67875db2de..e43062a18b7 100644
--- a/code/_globalvars/mapping.dm
+++ b/code/_globalvars/mapping.dm
@@ -55,3 +55,7 @@ GLOBAL_LIST_EMPTY(space_ruins_templates)
GLOBAL_LIST_EMPTY(lava_ruins_templates)
GLOBAL_LIST_EMPTY(shelter_templates)
GLOBAL_LIST_EMPTY(shuttle_templates)
+
+// Teleport locations
+GLOBAL_LIST_EMPTY(teleportlocs)
+GLOBAL_LIST_EMPTY(ghostteleportlocs)
diff --git a/code/_globalvars/misc.dm b/code/_globalvars/misc.dm
index c541e40768a..283d92a954f 100644
--- a/code/_globalvars/misc.dm
+++ b/code/_globalvars/misc.dm
@@ -89,7 +89,7 @@ GLOBAL_VAR_INIT(copier_items_printed_logged, FALSE)
GLOBAL_VAR(map_name) // Self explanatory
-GLOBAL_DATUM(data_core, /datum/datacore) // Station datacore, manifest, etc
+GLOBAL_DATUM_INIT(data_core, /datum/datacore, new) // Station datacore, manifest, etc
GLOBAL_VAR_INIT(panic_bunker_enabled, FALSE) // Is the panic bunker enabled
diff --git a/code/_onclick/click.dm b/code/_onclick/click.dm
index d840f64bb4a..36b6d647b7d 100644
--- a/code/_onclick/click.dm
+++ b/code/_onclick/click.dm
@@ -73,7 +73,9 @@
var/dragged = modifiers["drag"]
if(dragged && !modifiers[dragged])
return
-
+ if(IsFrozen(A) && !is_admin(usr))
+ to_chat(usr, "Interacting with admin-frozen players is not permitted.")
+ return
if(modifiers["middle"] && modifiers["shift"] && modifiers["ctrl"])
MiddleShiftControlClickOn(A)
return
diff --git a/code/_onclick/item_attack.dm b/code/_onclick/item_attack.dm
index f88244c0cd8..4fd5b956df5 100644
--- a/code/_onclick/item_attack.dm
+++ b/code/_onclick/item_attack.dm
@@ -81,7 +81,7 @@
user.do_attack_animation(M)
. = M.attacked_by(src, user, def_zone)
- add_attack_logs(user, M, "Attacked with [name] (INTENT: [uppertext(user.a_intent)]) (DAMTYPE: [uppertext(damtype)])", (M.ckey && force > 0 && damtype != STAMINA) ? null : ATKLOG_ALMOSTALL)
+ add_attack_logs(user, M, "Attacked with [name] ([uppertext(user.a_intent)]) ([uppertext(damtype)])", (M.ckey && force > 0 && damtype != STAMINA) ? null : ATKLOG_ALMOSTALL)
add_fingerprint(user)
diff --git a/code/_onclick/rig.dm b/code/_onclick/rig.dm
deleted file mode 100644
index ff55f35cb57..00000000000
--- a/code/_onclick/rig.dm
+++ /dev/null
@@ -1,84 +0,0 @@
-
-#define MIDDLE_CLICK 0
-#define ALT_CLICK 1
-#define CTRL_CLICK 2
-#define MAX_HARDSUIT_CLICK_MODE 2
-
-/client
- var/hardsuit_click_mode = MIDDLE_CLICK
-
-/client/verb/toggle_hardsuit_mode()
- set name = "Toggle Hardsuit Activation Mode"
- set desc = "Switch between hardsuit activation modes."
- set category = "OOC"
-
- hardsuit_click_mode++
- if(hardsuit_click_mode > MAX_HARDSUIT_CLICK_MODE)
- hardsuit_click_mode = 0
-
- switch(hardsuit_click_mode)
- if(MIDDLE_CLICK)
- to_chat(src, "Hardsuit activation mode set to middle-click.")
- if(ALT_CLICK)
- to_chat(src, "Hardsuit activation mode set to alt-click.")
- if(CTRL_CLICK)
- to_chat(src, "Hardsuit activation mode set to control-click.")
- else
- // should never get here, but just in case:
- log_runtime(EXCEPTION("Bad hardsuit click mode: [hardsuit_click_mode] - expected 0 to [MAX_HARDSUIT_CLICK_MODE]"), src)
- to_chat(src, "Somehow you bugged the system. Setting your hardsuit mode to middle-click.")
- hardsuit_click_mode = MIDDLE_CLICK
-
-/mob/living/MiddleClickOn(atom/A)
- if(client && client.hardsuit_click_mode == MIDDLE_CLICK)
- if(HardsuitClickOn(A))
- return
- ..()
-
-/mob/living/AltClickOn(atom/A)
- if(client && client.hardsuit_click_mode == ALT_CLICK)
- if(HardsuitClickOn(A))
- return
- ..()
-
-/mob/living/CtrlClickOn(atom/A)
- if(client && client.hardsuit_click_mode == CTRL_CLICK)
- if(HardsuitClickOn(A))
- return
- ..()
-
-/mob/living/proc/can_use_rig()
- return 0
-
-/mob/living/carbon/human/can_use_rig()
- return 1
-
-/mob/living/carbon/brain/can_use_rig()
- return istype(loc, /obj/item/mmi)
-
-/mob/living/silicon/ai/can_use_rig()
- return istype(loc, /obj/item/aicard)
-
-/mob/living/silicon/pai/can_use_rig()
- return loc == card
-
-/mob/living/proc/HardsuitClickOn(var/atom/A, var/alert_ai = 0)
- if(!can_use_rig() || (next_move > world.time))
- return 0
- var/obj/item/rig/rig = get_rig()
- if(istype(rig) && !rig.offline && rig.selected_module)
- if(src != rig.wearer)
- if(rig.ai_can_move_suit(src, check_user_module = 1))
- message_admins("[key_name_admin(src)] is trying to force \the [key_name_admin(rig.wearer)] to use a hardsuit module.")
- else
- return 0
- rig.selected_module.engage(A, alert_ai)
- if(ismob(A)) // No instant mob attacking - though modules have their own cooldowns
- changeNext_move(CLICK_CD_MELEE)
- return 1
- return 0
-
-#undef MIDDLE_CLICK
-#undef ALT_CLICK
-#undef CTRL_CLICK
-#undef MAX_HARDSUIT_CLICK_MODE
diff --git a/code/controllers/configuration.dm b/code/controllers/configuration.dm
index f4f2f72b16b..756ce6f8527 100644
--- a/code/controllers/configuration.dm
+++ b/code/controllers/configuration.dm
@@ -61,7 +61,6 @@
var/usewhitelist = 0
var/mods_are_mentors = 0
var/load_jobs_from_txt = 0
- var/ToRban = 0
var/automute_on = 0 //enables automuting/spam prevention
var/jobs_have_minimal_access = 0 //determines whether jobs use minimal access or expanded access.
var/round_abandon_penalty_period = 30 MINUTES // Time from round start during which ghosting out is penalized
@@ -578,9 +577,6 @@
if("humans_need_surnames")
humans_need_surnames = 1
- if("tor_ban")
- ToRban = 1
-
if("automute_on")
automute_on = 1
diff --git a/code/controllers/hooks-defs.dm b/code/controllers/hooks-defs.dm
deleted file mode 100644
index 59510162e1c..00000000000
--- a/code/controllers/hooks-defs.dm
+++ /dev/null
@@ -1,11 +0,0 @@
-/**
- * Startup hook.
- * Called in world.dm when the server starts.
- */
-/hook/startup
-
-/**
- * Roundstart hook.
- * Called in gameticker.dm when a round starts.
- */
-/hook/roundstart
diff --git a/code/controllers/hooks.dm b/code/controllers/hooks.dm
deleted file mode 100644
index 48f1199ef76..00000000000
--- a/code/controllers/hooks.dm
+++ /dev/null
@@ -1,39 +0,0 @@
-/**
- * @file hooks.dm
- * Implements hooks, a simple way to run code on pre-defined events.
- */
-
-/** @page hooks Code hooks
- * @section hooks Hooks
- * A hook is defined under /hook in the type tree.
- *
- * To add some code to be called by the hook, define a proc under the type, as so:
- * @code
- /hook/foo/proc/bar()
- if(1)
- return 1 //Sucessful
- else
- return 0 //Error, or runtime.
- * @endcode
- * All hooks must return nonzero on success, as runtimes will force return null.
- */
-
-/**
- * Calls a hook, executing every piece of code that's attached to it.
- * @param hook Identifier of the hook to call.
- * @returns 1 if all hooked code runs successfully, 0 otherwise.
- */
-/proc/callHook(hook, list/args=null)
- var/hook_path = text2path("/hook/[hook]")
- if(!hook_path)
- error("Invalid hook '/hook/[hook]' called.")
- return 0
-
- var/caller = new hook_path
- var/status = 1
- for(var/P in typesof("[hook_path]/proc"))
- if(!call(caller, P)(arglist(args)))
- error("Hook '[P]' failed or runtimed.")
- status = 0
-
- return status
diff --git a/code/controllers/subsystem.dm b/code/controllers/subsystem.dm
index 03e54df61c5..c9934b128cf 100644
--- a/code/controllers/subsystem.dm
+++ b/code/controllers/subsystem.dm
@@ -35,7 +35,7 @@
var/static/list/failure_strikes //How many times we suspect a subsystem type has crashed the MC, 3 strikes and you're out!
- var/offline_implications = "None" // What are the implications of this SS being offlined?
+ var/offline_implications = "None. No immediate action is needed." // What are the implications of this SS being offlined?
//Do not override
///datum/controller/subsystem/New()
diff --git a/code/controllers/subsystem/afk.dm b/code/controllers/subsystem/afk.dm
index 951a7fb1786..25ccda3349c 100644
--- a/code/controllers/subsystem/afk.dm
+++ b/code/controllers/subsystem/afk.dm
@@ -21,7 +21,8 @@ SUBSYSTEM_DEF(afk)
/datum/controller/subsystem/afk/fire()
var/list/toRemove = list()
- for(var/mob/living/carbon/human/H in GLOB.alive_mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
if(!H?.ckey) // Useless non ckey creatures
continue
diff --git a/code/controllers/subsystem/events.dm b/code/controllers/subsystem/events.dm
index 1a6e073c808..390c6bc1a62 100644
--- a/code/controllers/subsystem/events.dm
+++ b/code/controllers/subsystem/events.dm
@@ -212,38 +212,38 @@ SUBSYSTEM_DEF(events)
if(href_list["toggle_report"])
report_at_round_end = !report_at_round_end
- admin_log_and_message_admins("has [report_at_round_end ? "enabled" : "disabled"] the round end event report.")
+ log_and_message_admins("has [report_at_round_end ? "enabled" : "disabled"] the round end event report.")
else if(href_list["dec_timer"])
var/datum/event_container/EC = locate(href_list["event"])
var/decrease = (60 * RaiseToPower(10, text2num(href_list["dec_timer"])))
EC.next_event_time -= decrease
- admin_log_and_message_admins("decreased timer for [GLOB.severity_to_string[EC.severity]] events by [decrease/600] minute(s).")
+ log_and_message_admins("decreased timer for [GLOB.severity_to_string[EC.severity]] events by [decrease/600] minute(s).")
else if(href_list["inc_timer"])
var/datum/event_container/EC = locate(href_list["event"])
var/increase = (60 * RaiseToPower(10, text2num(href_list["inc_timer"])))
EC.next_event_time += increase
- admin_log_and_message_admins("increased timer for [GLOB.severity_to_string[EC.severity]] events by [increase/600] minute(s).")
+ log_and_message_admins("increased timer for [GLOB.severity_to_string[EC.severity]] events by [increase/600] minute(s).")
else if(href_list["select_event"])
var/datum/event_container/EC = locate(href_list["select_event"])
var/datum/event_meta/EM = EC.SelectEvent()
if(EM)
- admin_log_and_message_admins("has queued the [GLOB.severity_to_string[EC.severity]] event '[EM.name]'.")
+ log_and_message_admins("has queued the [GLOB.severity_to_string[EC.severity]] event '[EM.name]'.")
else if(href_list["pause"])
var/datum/event_container/EC = locate(href_list["pause"])
EC.delayed = !EC.delayed
- admin_log_and_message_admins("has [EC.delayed ? "paused" : "resumed"] countdown for [GLOB.severity_to_string[EC.severity]] events.")
+ log_and_message_admins("has [EC.delayed ? "paused" : "resumed"] countdown for [GLOB.severity_to_string[EC.severity]] events.")
else if(href_list["interval"])
var/delay = input("Enter delay modifier. A value less than one means events fire more often, higher than one less often.", "Set Interval Modifier") as num|null
if(delay && delay > 0)
var/datum/event_container/EC = locate(href_list["interval"])
EC.delay_modifier = delay
- admin_log_and_message_admins("has set the interval modifier for [GLOB.severity_to_string[EC.severity]] events to [EC.delay_modifier].")
+ log_and_message_admins("has set the interval modifier for [GLOB.severity_to_string[EC.severity]] events to [EC.delay_modifier].")
else if(href_list["stop"])
if(alert("Stopping an event may have unintended side-effects. Continue?","Stopping Event!","Yes","No") != "Yes")
return
var/datum/event/E = locate(href_list["stop"])
var/datum/event_meta/EM = E.event_meta
- admin_log_and_message_admins("has stopped the [GLOB.severity_to_string[EM.severity]] event '[EM.name]'.")
+ log_and_message_admins("has stopped the [GLOB.severity_to_string[EM.severity]] event '[EM.name]'.")
E.kill()
else if(href_list["view_events"])
selected_event_container = locate(href_list["view_events"])
@@ -265,23 +265,23 @@ SUBSYSTEM_DEF(events)
var/datum/event_meta/EM = locate(href_list["set_weight"])
EM.weight = weight
if(EM != new_event)
- admin_log_and_message_admins("has changed the weight of the [GLOB.severity_to_string[EM.severity]] event '[EM.name]' to [EM.weight].")
+ log_and_message_admins("has changed the weight of the [GLOB.severity_to_string[EM.severity]] event '[EM.name]' to [EM.weight].")
else if(href_list["toggle_oneshot"])
var/datum/event_meta/EM = locate(href_list["toggle_oneshot"])
EM.one_shot = !EM.one_shot
if(EM != new_event)
- admin_log_and_message_admins("has [EM.one_shot ? "set" : "unset"] the oneshot flag for the [GLOB.severity_to_string[EM.severity]] event '[EM.name]'.")
+ log_and_message_admins("has [EM.one_shot ? "set" : "unset"] the oneshot flag for the [GLOB.severity_to_string[EM.severity]] event '[EM.name]'.")
else if(href_list["toggle_enabled"])
var/datum/event_meta/EM = locate(href_list["toggle_enabled"])
EM.enabled = !EM.enabled
- admin_log_and_message_admins("has [EM.enabled ? "enabled" : "disabled"] the [GLOB.severity_to_string[EM.severity]] event '[EM.name]'.")
+ log_and_message_admins("has [EM.enabled ? "enabled" : "disabled"] the [GLOB.severity_to_string[EM.severity]] event '[EM.name]'.")
else if(href_list["remove"])
if(alert("This will remove the event from rotation. Continue?","Removing Event!","Yes","No") != "Yes")
return
var/datum/event_meta/EM = locate(href_list["remove"])
var/datum/event_container/EC = locate(href_list["EC"])
EC.available_events -= EM
- admin_log_and_message_admins("has removed the [GLOB.severity_to_string[EM.severity]] event '[EM.name]'.")
+ log_and_message_admins("has removed the [GLOB.severity_to_string[EM.severity]] event '[EM.name]'.")
else if(href_list["add"])
if(!new_event.name || !new_event.event_type)
return
@@ -289,12 +289,12 @@ SUBSYSTEM_DEF(events)
return
new_event.severity = selected_event_container.severity
selected_event_container.available_events += new_event
- admin_log_and_message_admins("has added \a [GLOB.severity_to_string[new_event.severity]] event '[new_event.name]' of type [new_event.event_type] with weight [new_event.weight].")
+ log_and_message_admins("has added \a [GLOB.severity_to_string[new_event.severity]] event '[new_event.name]' of type [new_event.event_type] with weight [new_event.weight].")
new_event = new
else if(href_list["clear"])
var/datum/event_container/EC = locate(href_list["clear"])
if(EC.next_event)
- admin_log_and_message_admins("has dequeued the [GLOB.severity_to_string[EC.severity]] event '[EC.next_event.name]'.")
+ log_and_message_admins("has dequeued the [GLOB.severity_to_string[EC.severity]] event '[EC.next_event.name]'.")
EC.next_event = null
Interact(usr)
diff --git a/code/controllers/subsystem/garbage.dm b/code/controllers/subsystem/garbage.dm
index 619508544a6..e50c372584a 100644
--- a/code/controllers/subsystem/garbage.dm
+++ b/code/controllers/subsystem/garbage.dm
@@ -4,7 +4,7 @@ SUBSYSTEM_DEF(garbage)
wait = 2 SECONDS
flags = SS_POST_FIRE_TIMING|SS_BACKGROUND|SS_NO_INIT
runlevels = RUNLEVELS_DEFAULT | RUNLEVEL_LOBBY
- init_order = INIT_ORDER_GARBAGE
+ init_order = INIT_ORDER_GARBAGE // Why does this have an init order if it has SS_NO_INIT?
offline_implications = "Garbage collection is no longer functional, and objects will not be qdel'd. Immediate server restart recommended."
var/list/collection_timeout = list(2 MINUTES, 10 SECONDS) // deciseconds to wait before moving something up in the queue to the next level
diff --git a/code/controllers/subsystem/icon_smooth.dm b/code/controllers/subsystem/icon_smooth.dm
index 289505a153c..8d6a7e39852 100644
--- a/code/controllers/subsystem/icon_smooth.dm
+++ b/code/controllers/subsystem/icon_smooth.dm
@@ -19,8 +19,18 @@ SUBSYSTEM_DEF(icon_smooth)
can_fire = 0
/datum/controller/subsystem/icon_smooth/Initialize()
- smooth_zlevel(1,TRUE)
- smooth_zlevel(2,TRUE)
+ log_startup_progress("Smoothing atoms...")
+ // Smooth EVERYTHING in the world
+ for(var/turf/T in world)
+ if(T.smooth)
+ smooth_icon(T)
+ for(var/A in T)
+ var/atom/AA = A
+ if(AA.smooth)
+ smooth_icon(AA)
+ CHECK_TICK
+
+ // Incase any new atoms were added to the smoothing queue for whatever reason
var/queue = smooth_queue
smooth_queue = list()
for(var/V in queue)
diff --git a/code/controllers/subsystem/mapping.dm b/code/controllers/subsystem/mapping.dm
index cb9c79422bc..163b2635d0e 100644
--- a/code/controllers/subsystem/mapping.dm
+++ b/code/controllers/subsystem/mapping.dm
@@ -41,6 +41,28 @@ SUBSYSTEM_DEF(mapping)
spawn_rivers(list(level_name_to_num(MINING)))
log_startup_progress("Successfully populated lavaland in [stop_watch(lavaland_setup_timer)]s.")
+ // Now we make a list of areas for teleport locs
+ // TOOD: Make these locs into lists on the SS itself, not globs
+ for(var/area/AR in world)
+ if(AR.no_teleportlocs)
+ continue
+ if(GLOB.teleportlocs[AR.name])
+ continue
+ var/turf/picked = safepick(get_area_turfs(AR.type))
+ if(picked && is_station_level(picked.z))
+ GLOB.teleportlocs[AR.name] = AR
+
+ GLOB.teleportlocs = sortAssoc(GLOB.teleportlocs)
+
+ for(var/area/AR in world)
+ if(GLOB.ghostteleportlocs[AR.name])
+ continue
+ var/list/turfs = get_area_turfs(AR.type)
+ if(turfs.len)
+ GLOB.ghostteleportlocs[AR.name] = AR
+
+ GLOB.ghostteleportlocs = sortAssoc(GLOB.ghostteleportlocs)
+
return ..()
diff --git a/code/controllers/subsystem/nano_mob_hunter.dm b/code/controllers/subsystem/nano_mob_hunter.dm
index 19b57f59a70..b8a5d09e0b5 100644
--- a/code/controllers/subsystem/nano_mob_hunter.dm
+++ b/code/controllers/subsystem/nano_mob_hunter.dm
@@ -2,6 +2,7 @@ SUBSYSTEM_DEF(mob_hunt)
name = "Nano-Mob Hunter GO Server"
init_order = INIT_ORDER_NANOMOB
priority = FIRE_PRIORITY_NANOMOB // Low priority, no need for MC_TICK_CHECK due to extremely low performance impact.
+ flags = SS_NO_INIT
offline_implications = "Nano-Mob Hunter will no longer spawn mobs. No immediate action is needed."
var/max_normal_spawns = 15 //change this to adjust the number of normal spawns that can exist at one time. trapped spawns (from traitors) don't count towards this
var/list/normal_spawns = list()
diff --git a/code/controllers/subsystem/dcs.dm b/code/controllers/subsystem/processing/dcs.dm
similarity index 90%
rename from code/controllers/subsystem/dcs.dm
rename to code/controllers/subsystem/processing/dcs.dm
index 09dea24071f..a223f4676f6 100644
--- a/code/controllers/subsystem/dcs.dm
+++ b/code/controllers/subsystem/processing/dcs.dm
@@ -3,6 +3,8 @@ PROCESSING_SUBSYSTEM_DEF(dcs)
flags = SS_NO_INIT
var/list/elements_by_type = list()
+ // Update this if you add in components which actually use this as a processor
+ offline_implications = "This SS doesnt actually process anything yet. No immediate action is needed."
/datum/controller/subsystem/processing/dcs/Recover()
comp_lookup = SSdcs.comp_lookup
diff --git a/code/controllers/subsystem/processing/fastprocess.dm b/code/controllers/subsystem/processing/fastprocess.dm
index 9622e021469..37761ca8d60 100644
--- a/code/controllers/subsystem/processing/fastprocess.dm
+++ b/code/controllers/subsystem/processing/fastprocess.dm
@@ -4,3 +4,4 @@ PROCESSING_SUBSYSTEM_DEF(fastprocess)
name = "Fast Processing"
wait = 2
stat_tag = "FP"
+ offline_implications = "Objects using the 'Fast Processing' processor will no longer process. Shuttle call recommended."
diff --git a/code/controllers/subsystem/processing/obj.dm b/code/controllers/subsystem/processing/obj.dm
index 26021fb267a..2a05c04af58 100644
--- a/code/controllers/subsystem/processing/obj.dm
+++ b/code/controllers/subsystem/processing/obj.dm
@@ -3,3 +3,4 @@ PROCESSING_SUBSYSTEM_DEF(obj)
priority = FIRE_PRIORITY_OBJ
flags = SS_NO_INIT
wait = 20
+ offline_implications = "Objects using the 'Objects' processor will no longer process. Shuttle call recommended."
diff --git a/code/controllers/subsystem/processing/processing.dm b/code/controllers/subsystem/processing/processing.dm
index a8bc823bbbe..5302314589d 100644
--- a/code/controllers/subsystem/processing/processing.dm
+++ b/code/controllers/subsystem/processing/processing.dm
@@ -9,6 +9,7 @@ SUBSYSTEM_DEF(processing)
var/stat_tag = "P" //Used for logging
var/list/processing = list()
var/list/currentrun = list()
+ offline_implications = "Objects using the default processor will no longer process. Shuttle call recommended."
/datum/controller/subsystem/processing/stat_entry()
..("[stat_tag]:[processing.len]")
diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm
index 6f8dd85b79b..5d0a53c221e 100644
--- a/code/controllers/subsystem/ticker.dm
+++ b/code/controllers/subsystem/ticker.dm
@@ -180,7 +180,14 @@ SUBSYSTEM_DEF(ticker)
current_state = GAME_STATE_PLAYING
Master.SetRunLevel(RUNLEVEL_GAME)
- callHook("roundstart")
+ // Generate the list of playable AI cores in the world
+ for(var/obj/effect/landmark/start/S in GLOB.landmarks_list)
+ if(S.name != "AI")
+ continue
+ if(locate(/mob/living) in S.loc)
+ continue
+ GLOB.empty_playable_ai_cores += new /obj/structure/AIcore/deactivated(get_turf(S))
+
//here to initialize the random events nicely at round start
setup_economy()
@@ -279,10 +286,22 @@ SUBSYSTEM_DEF(ticker)
for(var/mob/new_player/N in GLOB.mob_list)
if(N.client)
N.new_player_panel_proc()
+
+ // Now that every other piece of the round has initialized, lets setup player job scaling
+ var/playercount = length(GLOB.clients)
+ var/highpop_trigger = 80
+
+ if(playercount >= highpop_trigger)
+ log_debug("Playercount: [playercount] versus trigger: [highpop_trigger] - loading highpop job config")
+ SSjobs.LoadJobs("config/jobs_highpop.txt")
+ else
+ log_debug("Playercount: [playercount] versus trigger: [highpop_trigger] - keeping standard job config")
+
#ifdef UNIT_TESTS
RunUnitTests()
#endif
- return 1
+ return TRUE
+
/datum/controller/subsystem/ticker/proc/station_explosion_cinematic(station_missed = 0, override = null)
if(cinematic)
diff --git a/code/controllers/subsystem/tickets/mentor_tickets.dm b/code/controllers/subsystem/tickets/mentor_tickets.dm
index 76c7ed2dc28..3fd003418a4 100644
--- a/code/controllers/subsystem/tickets/mentor_tickets.dm
+++ b/code/controllers/subsystem/tickets/mentor_tickets.dm
@@ -10,6 +10,7 @@ GLOBAL_REAL(SSmentor_tickets, /datum/controller/subsystem/tickets/mentor_tickets
ticket_name = "Mentor Ticket"
span_class = "mentorhelp"
close_rights = R_MENTOR | R_ADMIN
+ offline_implications = "Mentor tickets will no longer be marked as stale. No immediate action is needed."
/datum/controller/subsystem/tickets/mentor_tickets/message_staff(var/msg)
message_mentorTicket(msg)
diff --git a/code/controllers/subsystem/tickets/tickets.dm b/code/controllers/subsystem/tickets/tickets.dm
index 3aa0a8846c3..879ee35abee 100644
--- a/code/controllers/subsystem/tickets/tickets.dm
+++ b/code/controllers/subsystem/tickets/tickets.dm
@@ -20,6 +20,7 @@ SUBSYSTEM_DEF(tickets)
init_order = INIT_ORDER_TICKETS
wait = 300
priority = FIRE_PRIORITY_TICKETS
+ offline_implications = "Admin tickets will no longer be marked as stale. No immediate action is needed."
flags = SS_BACKGROUND
@@ -130,6 +131,7 @@ SUBSYSTEM_DEF(tickets)
"Already Resolved" = "The problem has been resolved already.",
"Mentorhelp" = "Please redirect your question to Mentorhelp, as they are better experienced with these types of questions.",
"Happens Again" = "Thanks, let us know if it continues to happen.",
+ "Github Issue Report" = "To report a bug, please go to our Github page. Then go to 'Issues'. Then 'New Issue'. Then fill out the report form. If the report would reveal current-round information, file it after the round ends.",
"Clear Cache" = "To fix a blank screen, go to the 'Special Verbs' tab and press 'Reload UI Resources'. If that fails, clear your BYOND cache (instructions provided with 'Reload UI Resources'). If that still fails, please adminhelp again, stating you have already done the following." ,
"IC Issue" = "This is an In Character (IC) issue and will not be handled by admins. You could speak to Security, Internal Affairs, a Departmental Head, Nanotrasen Representetive, or any other relevant authority currently on station.",
"Reject" = "Reject",
diff --git a/code/modules/fancytitle/fancytitle.dm b/code/controllers/subsystem/titlescreen.dm
similarity index 85%
rename from code/modules/fancytitle/fancytitle.dm
rename to code/controllers/subsystem/titlescreen.dm
index d1cf08ff58c..e597f74e05f 100644
--- a/code/modules/fancytitle/fancytitle.dm
+++ b/code/controllers/subsystem/titlescreen.dm
@@ -1,4 +1,9 @@
-/hook/startup/proc/setup_title_screen()
+SUBSYSTEM_DEF(title)
+ name = "Title Screen"
+ flags = SS_NO_FIRE
+ init_order = INIT_ORDER_TITLE
+
+/datum/controller/subsystem/title/Initialize()
var/list/provisional_title_screens = flist("config/title_screens/images/")
var/list/title_screens = list()
var/use_rare_screens = prob(1)
@@ -29,5 +34,5 @@
for(var/turf/unsimulated/wall/splashscreen/splash in world)
splash.icon = icon
- return TRUE
- return FALSE
+
+ return ..()
diff --git a/code/controllers/subsystem/vote.dm b/code/controllers/subsystem/vote.dm
index b0110258da7..0b91e6b3467 100644
--- a/code/controllers/subsystem/vote.dm
+++ b/code/controllers/subsystem/vote.dm
@@ -367,7 +367,7 @@ SUBSYSTEM_DEF(vote)
var/votedesc = capitalize(mode)
if(mode == "custom")
votedesc += " ([question])"
- admin_log_and_message_admins("cancelled the running [votedesc] vote.")
+ log_and_message_admins("cancelled the running [votedesc] vote.")
reset()
if("toggle_restart")
if(admin)
diff --git a/code/datums/beam.dm b/code/datums/beam.dm
index 19935bda130..3b5c9d2f5fb 100644
--- a/code/datums/beam.dm
+++ b/code/datums/beam.dm
@@ -131,6 +131,5 @@
/atom/proc/Beam(atom/BeamTarget,icon_state="b_beam",icon='icons/effects/beam.dmi',time=50, maxdistance=10,beam_type=/obj/effect/ebeam,beam_sleep_time=3)
var/datum/beam/newbeam = new(src,BeamTarget,icon,icon_state,time,maxdistance,beam_type,beam_sleep_time)
- spawn(0)
- newbeam.Start()
+ INVOKE_ASYNC(newbeam, /datum/beam.proc/Start)
return newbeam
diff --git a/code/datums/datacore.dm b/code/datums/datacore.dm
index 7bfc79e4e71..0e98179e2f9 100644
--- a/code/datums/datacore.dm
+++ b/code/datums/datacore.dm
@@ -1,7 +1,3 @@
-/hook/startup/proc/createDatacore()
- GLOB.data_core = new /datum/datacore()
- return 1
-
/datum/datacore
var/list/medical = list()
var/list/general = list()
diff --git a/code/datums/diseases/advance/advance.dm b/code/datums/diseases/advance/advance.dm
index 34c41c581f2..318dd176e45 100644
--- a/code/datums/diseases/advance/advance.dm
+++ b/code/datums/diseases/advance/advance.dm
@@ -395,8 +395,9 @@ GLOBAL_LIST_INIT(advance_cures, list(
for(var/datum/disease/advance/AD in GLOB.active_diseases)
AD.Refresh()
- for(var/mob/living/carbon/human/H in shuffle(GLOB.alive_mob_list))
- if(!is_station_level(H.z))
+ for(var/thing in shuffle(GLOB.human_list))
+ var/mob/living/carbon/human/H = thing
+ if(H.stat == DEAD || !is_station_level(H.z))
continue
if(!H.HasDisease(D))
H.ForceContractDisease(D)
diff --git a/code/datums/diseases/transformation.dm b/code/datums/diseases/transformation.dm
index f619e9aa9bd..3e3e1696e61 100644
--- a/code/datums/diseases/transformation.dm
+++ b/code/datums/diseases/transformation.dm
@@ -57,6 +57,9 @@
W.plane = initial(W.plane)
W.loc = affected_mob.loc
W.dropped(affected_mob)
+ if(isobj(affected_mob.loc))
+ var/obj/O = affected_mob.loc
+ O.force_eject_occupant()
var/mob/living/new_mob = new new_form(affected_mob.loc)
if(istype(new_mob))
new_mob.a_intent = "harm"
diff --git a/code/datums/helper_datums/map_template.dm b/code/datums/helper_datums/map_template.dm
index a54707842db..ee5a4df4f5b 100644
--- a/code/datums/helper_datums/map_template.dm
+++ b/code/datums/helper_datums/map_template.dm
@@ -17,7 +17,7 @@
name = rename
/datum/map_template/proc/preload_size(path)
- var/bounds = GLOB.maploader.load_map(file(path), 1, 1, 1, cropMap = 0, measureOnly = 1)
+ var/bounds = GLOB.maploader.load_map(file(path), 1, 1, 1, shouldCropMap = FALSE, measureOnly = TRUE)
if(bounds)
width = bounds[MAP_MAXX] // Assumes all templates are rectangular, have a single Z level, and begin at 1,1,1
height = bounds[MAP_MAXY]
@@ -49,7 +49,7 @@
// if given a multi-z template
// it might need to be adapted for that when that time comes
GLOB.space_manager.add_dirt(placement.z)
- var/list/bounds = GLOB.maploader.load_map(get_file(), min_x, min_y, placement.z, cropMap = 1)
+ var/list/bounds = GLOB.maploader.load_map(get_file(), min_x, min_y, placement.z, shouldCropMap = TRUE)
if(!bounds)
return 0
if(bot_left == null || top_right == null)
diff --git a/code/datums/log_record.dm b/code/datums/log_record.dm
index 9b7d52b5390..7d127eedc7d 100644
--- a/code/datums/log_record.dm
+++ b/code/datums/log_record.dm
@@ -8,10 +8,10 @@
/datum/log_record/New(_log_type, _who, _what, _target, _where, _raw_time)
log_type = _log_type
-
- who = get_subject_text(_who)
+
+ who = get_subject_text(_who, _log_type)
what = _what
- target = get_subject_text(_target)
+ target = get_subject_text(_target, _log_type)
if(!_where)
_where = get_turf(_who)
where = _where
@@ -19,16 +19,31 @@
_raw_time = world.time
raw_time = _raw_time
-/datum/log_record/proc/get_subject_text(subject)
+/datum/log_record/proc/get_subject_text(subject, log_type)
if(ismob(subject) || isclient(subject) || istype(subject, /datum/mind))
- return key_name_admin(subject)
- if(isatom(subject))
+ . = key_name_admin(subject)
+ if(should_log_health(log_type) && isliving(subject))
+ . += get_health_string(subject)
+ else if(isatom(subject))
var/atom/A = subject
- return A.name
- if(istype(subject, /datum))
+ . = A.name
+ else if(istype(subject, /datum))
var/datum/D = subject
return D.type
- return subject
+ else
+ . = subject
+
+/datum/log_record/proc/get_health_string(var/mob/living/L)
+ var/OX = L.getOxyLoss() > 50 ? "[L.getOxyLoss()]" : L.getOxyLoss()
+ var/TX = L.getToxLoss() > 50 ? "[L.getToxLoss()]" : L.getToxLoss()
+ var/BU = L.getFireLoss() > 50 ? "[L.getFireLoss()]" : L.getFireLoss()
+ var/BR = L.getBruteLoss() > 50 ? "[L.getBruteLoss()]" : L.getBruteLoss()
+ return " ([L.health]: [OX] - [TX] - [BU] - [BR])"
+
+/datum/log_record/proc/should_log_health(log_type)
+ if(log_type == ATTACK_LOG || log_type == DEFENSE_LOG)
+ return TRUE
+ return FALSE
/proc/compare_log_record(datum/log_record/A, datum/log_record/B)
var/time_diff = A.raw_time - B.raw_time
diff --git a/code/datums/log_viewer.dm b/code/datums/log_viewer.dm
index 67eb3d21d86..72872e93a3c 100644
--- a/code/datums/log_viewer.dm
+++ b/code/datums/log_viewer.dm
@@ -4,13 +4,13 @@
var/time_from = 0
var/time_to = 4 HOURS // 4 Hours should be enough. INFINITY would screw the UI up
var/list/selected_mobs = list() // The mobs in question
- var/list/selected_log_types = list() // The log types being searched for
+ var/list/selected_log_types = ALL_LOGS // The log types being searched for
var/list/log_records = list() // Found and sorted records
/datum/log_viewer/proc/clear_all()
selected_mobs.Cut()
- selected_log_types.Cut()
+ selected_log_types = ALL_LOGS
time_from = initial(time_from)
time_to = initial(time_to)
log_records.Cut()
@@ -91,6 +91,14 @@
return start
return 0
+/datum/log_viewer/proc/add_mobs(list/mob/mobs)
+ if(!mobs?.len)
+ return
+ for(var/i in mobs)
+ var/mob/M = i
+ if(istype(M))
+ selected_mobs |= M
+
/datum/log_viewer/proc/add_mob(mob/user, mob/M)
if(!M || !user)
return
@@ -103,8 +111,8 @@
var/trStyleTop = "border-top:2px solid; border-bottom:2px solid; padding-top: 5px; padding-bottom: 5px;"
var/trStyle = "border-top:1px solid; border-bottom:1px solid; padding-top: 5px; padding-bottom: 5px;"
var/dat
- dat += ""
- dat += ""
+ dat += " "
+ dat += " "
dat += " Time Search Range: [gameTimestamp(wtime = time_from)]"
dat += " To: [gameTimestamp(wtime = time_to)]"
dat += " "
@@ -115,8 +123,9 @@
if(QDELETED(M))
selected_mobs -= i
continue
- dat += " [M.name]"
+ dat += " [get_display_name(M)]"
dat += " Add Mob"
+ dat += " Add Mob (by ckey)"
dat += " Clear All Mobs"
dat += " "
@@ -142,9 +151,9 @@
// Search results
var/tdStyleTime = "width:80px; text-align:center;"
var/tdStyleType = "width:80px; text-align:center;"
- var/tdStyleWho = "width:300px; text-align:center;"
+ var/tdStyleWho = "width:400px; text-align:center;"
var/tdStyleWhere = "width:150px; text-align:center;"
- dat += " "
+ dat += " "
dat += " "
dat += "| When | Type | Who | What | Target | Where | "
for(var/i in log_records)
@@ -158,7 +167,7 @@
dat += " "
dat += " "
- var/datum/browser/popup = new(user, "Log viewer", "Log viewer", 1400, 600)
+ var/datum/browser/popup = new(user, "Log Viewer", "Log Viewer", 1500, 600)
popup.set_content(dat)
popup.open()
@@ -203,6 +212,11 @@
var/datum/async_input/A = input_autocomplete_async(usr, "Please, select a mob: ", mobs)
A.on_close(CALLBACK(src, .proc/add_mob, usr))
return
+ if(href_list["add_mob_ckey"])
+ var/list/mobs = get_assoc_mob_list_by_ckey()
+ var/datum/async_input/A = input_autocomplete_async(usr, "Please, select a ckey: ", mobs)
+ A.on_close(CALLBACK(src, .proc/add_mob, usr))
+ return
if(href_list["remove_mob"])
var/mob/M = locate(href_list["remove_mob"])
if(M)
@@ -233,3 +247,11 @@
if(MISC_LOG)
return "gray"
return "slategray"
+
+/datum/log_viewer/proc/get_display_name(mob/M)
+ var/name = M.name
+ if(M.name != M.real_name)
+ name = "[name] ([M.real_name])"
+ if(isobserver(M))
+ name = "[name] (DEAD)"
+ return name
diff --git a/code/datums/mind.dm b/code/datums/mind.dm
index cb1ee856b1c..103865bee94 100644
--- a/code/datums/mind.dm
+++ b/code/datums/mind.dm
@@ -47,7 +47,6 @@
var/miming = 0 // Mime's vow of silence
var/list/antag_datums
- var/speech_span // What span any body this mind has talks in.
var/datum/changeling/changeling //changeling holder
var/linglink
var/datum/vampire/vampire //vampire holder
@@ -65,8 +64,6 @@
var/isblessed = FALSE // is this person blessed by a chaplain?
var/num_blessed = 0 // for prayers
- // the world.time since the mob has been brigged, or -1 if not at all
- var/brigged_since = -1
var/suicided = FALSE
//put this here for easier tracking ingame
@@ -1422,9 +1419,10 @@
return A
/datum/mind/proc/announce_objectives()
- to_chat(current, " Your current objectives:")
- for(var/line in splittext(gen_objective_text(), " "))
- to_chat(current, line)
+ if(current)
+ to_chat(current, " Your current objectives:")
+ for(var/line in splittext(gen_objective_text(), " "))
+ to_chat(current, line)
/datum/mind/proc/find_syndicate_uplink()
var/list/L = current.get_contents()
@@ -1593,25 +1591,6 @@
L = agent_landmarks[team]
H.forceMove(L.loc)
-
-// check whether this mind's mob has been brigged for the given duration
-// have to call this periodically for the duration to work properly
-/datum/mind/proc/is_brigged(duration)
- var/turf/T = current.loc
- if(!istype(T))
- brigged_since = -1
- return 0
-
- var/is_currently_brigged = current.is_in_brig()
- if(!is_currently_brigged)
- brigged_since = -1
- return 0
-
- if(brigged_since == -1)
- brigged_since = world.time
-
- return (duration <= world.time - brigged_since)
-
/datum/mind/proc/AddSpell(obj/effect/proc_holder/spell/S)
spell_list += S
S.action.Grant(current)
diff --git a/code/datums/ruins/space.dm b/code/datums/ruins/space.dm
index b81587440d4..799a12f4db9 100644
--- a/code/datums/ruins/space.dm
+++ b/code/datums/ruins/space.dm
@@ -175,6 +175,7 @@
description = "The crew of a space station awaken one hundred years after a crisis. Awaking to a derelict space station on the verge of collapse, and a hostile force of invading \
hivebots. Can the surviving crew overcome the odds and survive and rebuild, or will the cold embrace of the stars become their new home?"
cost = 2
+ allow_duplicates = FALSE
/datum/map_template/ruin/space/wizardcrash
id = "wizardcrash"
diff --git a/code/datums/shuttles.dm b/code/datums/shuttles.dm
index 53517d5dbc9..4d6310041e5 100644
--- a/code/datums/shuttles.dm
+++ b/code/datums/shuttles.dm
@@ -9,8 +9,9 @@
var/admin_notes
/datum/map_template/shuttle/New()
- shuttle_id = "[port_id]_[suffix]"
- mappath = "[prefix][shuttle_id].dmm"
+ if(port_id && suffix)
+ shuttle_id = "[port_id]_[suffix]"
+ mappath = "[prefix][shuttle_id].dmm"
. = ..()
/datum/map_template/shuttle/emergency
diff --git a/code/datums/supplypacks.dm b/code/datums/supplypacks.dm
index a18a9d74f28..5b21036b2bc 100644
--- a/code/datums/supplypacks.dm
+++ b/code/datums/supplypacks.dm
@@ -633,7 +633,6 @@ GLOBAL_LIST_INIT(all_supply_groups, list(SUPPLY_EMERGENCY,SUPPLY_SECURITY,SUPPLY
contains = list(/obj/machinery/power/emitter,
/obj/machinery/power/emitter)
cost = 10
- containertype = /obj/structure/closet/crate/secure
containername = "emitter crate"
access = ACCESS_CE
containertype = /obj/structure/closet/crate/secure/engineering
@@ -717,7 +716,7 @@ GLOBAL_LIST_INIT(all_supply_groups, list(SUPPLY_EMERGENCY,SUPPLY_SECURITY,SUPPLY
name = "Supermatter Shard Crate"
contains = list(/obj/machinery/power/supermatter_shard)
cost = 50 //So cargo thinks twice before killing themselves with it
- containertype = /obj/structure/closet/crate/secure
+ containertype = /obj/structure/closet/crate/secure/engineering
containername = "supermatter shard crate"
access = ACCESS_CE
@@ -728,7 +727,7 @@ GLOBAL_LIST_INIT(all_supply_groups, list(SUPPLY_EMERGENCY,SUPPLY_SECURITY,SUPPLY
/obj/item/pipe/circulator,
/obj/item/pipe/circulator)
cost = 25
- containertype = /obj/structure/closet/crate/secure
+ containertype = /obj/structure/closet/crate/secure/engineering
containername = "thermo-electric generator crate"
access = ACCESS_CE
announce_beacons = list("Engineering" = list("Chief Engineer's Desk", "Atmospherics"))
@@ -1767,6 +1766,16 @@ GLOBAL_LIST_INIT(all_supply_groups, list(SUPPLY_EMERGENCY,SUPPLY_SECURITY,SUPPLY
cost = 20
containername = "polo supply crate"
+/datum/supply_packs/misc/boxing //For non log spamming cargo brawls!
+ name = "Boxing Supply Crate"
+ // 4 boxing gloves
+ contains = list(/obj/item/clothing/gloves/boxing/blue,
+ /obj/item/clothing/gloves/boxing/green,
+ /obj/item/clothing/gloves/boxing/yellow,
+ /obj/item/clothing/gloves/boxing)
+ cost = 15
+ containername = "boxing supply crate"
+
///////////// Station Goals
/datum/supply_packs/misc/station_goal
diff --git a/code/datums/wires/robot.dm b/code/datums/wires/robot.dm
index 789a0472869..04a9509cfe2 100644
--- a/code/datums/wires/robot.dm
+++ b/code/datums/wires/robot.dm
@@ -15,16 +15,16 @@
switch(index)
if(BORG_WIRE_MAIN_POWER)
return "Main Power"
-
+
if(BORG_WIRE_LOCKED_DOWN)
return "Lockdown"
-
+
if(BORG_WIRE_CAMERA)
return "Camera"
-
+
if(BORG_WIRE_AI_CONTROL)
return "AI Control"
-
+
if(BORG_WIRE_LAWCHECK)
return "Law Check"
@@ -52,7 +52,7 @@
if(BORG_WIRE_AI_CONTROL) //Cut the AI wire to reset AI control
if(!mended)
if(R.connected_ai)
- R.connected_ai = null
+ R.disconnect_from_ai()
if(BORG_WIRE_CAMERA)
if(!isnull(R.camera) && !R.scrambledcodes)
@@ -74,8 +74,7 @@
switch(index)
if(BORG_WIRE_AI_CONTROL) //pulse the AI wire to make the borg reselect an AI
if(!R.emagged)
- R.connected_ai = select_active_ai()
- R.notify_ai(1)
+ R.connect_to_ai(select_active_ai())
if(BORG_WIRE_CAMERA)
if(!isnull(R.camera) && R.camera.can_use() && !R.scrambledcodes)
diff --git a/code/datums/wires/wires.dm b/code/datums/wires/wires.dm
index 09c874ce8a8..40aeda21b58 100644
--- a/code/datums/wires/wires.dm
+++ b/code/datums/wires/wires.dm
@@ -194,7 +194,7 @@ GLOBAL_LIST_INIT(wireColours, list("red", "blue", "green", "black", "orange", "b
return 1
/datum/wires/CanUseTopic(mob/user, datum/topic_state/state)
- if(!CanUse(user))
+ if(!holder || !CanUse(user))
return STATUS_CLOSE
return ..()
diff --git a/code/defines/procs/AStar.dm b/code/defines/procs/AStar.dm
index 1f8c83f5f04..1d6fa5619e2 100644
--- a/code/defines/procs/AStar.dm
+++ b/code/defines/procs/AStar.dm
@@ -29,15 +29,15 @@ Actual Adjacent procs :
//////////////////////
//A* nodes variables
-/PathNode
+/datum/pathnode
var/turf/source //turf associated with the PathNode
- var/PathNode/prevNode //link to the parent PathNode
+ var/datum/pathnode/prevNode //link to the parent PathNode
var/f //A* Node weight (f = g + h)
var/g //A* movement cost variable
var/h //A* heuristic variable
var/nt //count the number of Nodes traversed
-/PathNode/New(s,p,pg,ph,pnt)
+/datum/pathnode/New(s,p,pg,ph,pnt)
source = s
prevNode = p
g = pg
@@ -46,7 +46,7 @@ Actual Adjacent procs :
source.PNode = src
nt = pnt
-/PathNode/proc/calc_f()
+/datum/pathnode/proc/calc_f()
f = g + h
//////////////////////
@@ -54,11 +54,11 @@ Actual Adjacent procs :
//////////////////////
//the weighting function, used in the A* algorithm
-/proc/PathWeightCompare(PathNode/a, PathNode/b)
+/proc/PathWeightCompare(datum/pathnode/a, datum/pathnode/b)
return a.f - b.f
//reversed so that the Heap is a MinHeap rather than a MaxHeap
-/proc/HeapPathWeightCompare(PathNode/a, PathNode/b)
+/proc/HeapPathWeightCompare(datum/pathnode/a, datum/pathnode/b)
return b.f - a.f
//wrapper that returns an empty list if A* failed to find a path
@@ -82,13 +82,13 @@ Actual Adjacent procs :
return 0
maxnodedepth = maxnodes //no need to consider path longer than maxnodes
- var/Heap/open = new /Heap(/proc/HeapPathWeightCompare) //the open list
+ var/datum/heap/open = new /datum/heap(/proc/HeapPathWeightCompare) //the open list
var/list/closed = new() //the closed list
var/list/path = null //the returned path, if any
- var/PathNode/cur //current processed turf
+ var/datum/pathnode/cur //current processed turf
//initialization
- open.Insert(new /PathNode(start,null,0,call(start,dist)(end),0))
+ open.Insert(new /datum/pathnode(start,null,0,call(start,dist)(end),0))
//then run the main loop
while(!open.IsEmpty() && !path)
@@ -125,7 +125,7 @@ Actual Adjacent procs :
var/newg = cur.g + call(cur.source,dist)(T)
if(!T.PNode) //is not already in open list, so add it
- open.Insert(new /PathNode(T,cur,newg,call(T,dist)(end),cur.nt+1))
+ open.Insert(new /datum/pathnode(T,cur,newg,call(T,dist)(end),cur.nt+1))
else //is already in open list, check if it's a better way from the current turf
if(newg < T.PNode.g)
T.PNode.prevNode = cur
@@ -137,7 +137,7 @@ Actual Adjacent procs :
}
//cleaning after us
- for(var/PathNode/PN in open.L)
+ for(var/datum/pathnode/PN in open.L)
PN.source.PNode = null
for(var/turf/T in closed)
T.PNode = null
diff --git a/code/defines/procs/admin.dm b/code/defines/procs/admin.dm
index fb8ca665906..23b485ad252 100644
--- a/code/defines/procs/admin.dm
+++ b/code/defines/procs/admin.dm
@@ -83,10 +83,6 @@
var/message = "[key_name(whom, 0)][isAntag(whom) ? "(ANTAG)" : ""][isLivingSSD(whom) ? "(SSD!)": ""]"
return message
-/proc/log_and_message_admins(var/message as text)
+/proc/log_and_message_admins(message)
log_admin("[key_name(usr)] " + message)
message_admins("[key_name_admin(usr)] " + message)
-
-/proc/admin_log_and_message_admins(var/message as text)
- log_admin("[key_name(usr)] " + message)
- message_admins("[key_name_admin(usr)] " + message, 1)
diff --git a/code/game/area/Space Station 13 areas.dm b/code/game/area/Space Station 13 areas.dm
index c7936f2a91b..c33e7609685 100644
--- a/code/game/area/Space Station 13 areas.dm
+++ b/code/game/area/Space Station 13 areas.dm
@@ -13,35 +13,6 @@ NOTE: there are two lists of areas in the end of this file: centcom and station
*/
-/*Adding a wizard area teleport list because motherfucking lag -- Urist*/
-/*I am far too lazy to make it a proper list of areas so I'll just make it run the usual telepot routine at the start of the game*/
-GLOBAL_LIST_EMPTY(teleportlocs)
-/hook/startup/proc/process_teleport_locs()
- for(var/area/AR in world)
- if(AR.no_teleportlocs) continue
- if(GLOB.teleportlocs.Find(AR.name)) continue
- var/turf/picked = safepick(get_area_turfs(AR.type))
- if(picked && is_station_level(picked.z))
- GLOB.teleportlocs += AR.name
- GLOB.teleportlocs[AR.name] = AR
-
- GLOB.teleportlocs = sortAssoc(GLOB.teleportlocs)
-
- return 1
-
-GLOBAL_LIST_EMPTY(ghostteleportlocs)
-/hook/startup/proc/process_ghost_teleport_locs()
- for(var/area/AR in world)
- if(GLOB.ghostteleportlocs.Find(AR.name)) continue
- var/list/turfs = get_area_turfs(AR.type)
- if(turfs.len)
- GLOB.ghostteleportlocs += AR.name
- GLOB.ghostteleportlocs[AR.name] = AR
-
- GLOB.ghostteleportlocs = sortAssoc(GLOB.ghostteleportlocs)
-
- return 1
-
/*-----------------------------------------------------------------------------*/
diff --git a/code/game/atoms_movable.dm b/code/game/atoms_movable.dm
index ab5ff19462a..00009c8eeca 100644
--- a/code/game/atoms_movable.dm
+++ b/code/game/atoms_movable.dm
@@ -567,3 +567,6 @@
/atom/movable/proc/portal_destroyed(obj/effect/portal/P)
return
+
+/atom/movable/proc/decompile_act(obj/item/matter_decompiler/C, mob/user) // For drones to decompile mobs and objs. See drone for an example.
+ return FALSE
diff --git a/code/game/dna/dna_modifier.dm b/code/game/dna/dna_modifier.dm
index fb0ccff32cb..d887153c6d5 100644
--- a/code/game/dna/dna_modifier.dm
+++ b/code/game/dna/dna_modifier.dm
@@ -282,6 +282,9 @@
occupant = null
icon_state = "scanner_open"
+/obj/machinery/dna_scannernew/force_eject_occupant()
+ go_out(null, TRUE)
+
/obj/machinery/dna_scannernew/ex_act(severity)
if(occupant)
occupant.ex_act(severity)
diff --git a/code/game/gamemodes/blob/blob_report.dm b/code/game/gamemodes/blob/blob_report.dm
index 9c7fb99fe81..8f6ba965222 100644
--- a/code/game/gamemodes/blob/blob_report.dm
+++ b/code/game/gamemodes/blob/blob_report.dm
@@ -18,7 +18,7 @@
intercepttext += " Note in the event of a quarantine breach or uncontrolled spread of the biohazard, the directive 7-10 may be upgraded to a directive 7-12. "
intercepttext += "Message ends."
if(2)
- var/nukecode = rand(10000, 99999)
+ var/nukecode = "[rand(10000, 99999)]"
for(var/obj/machinery/nuclearbomb/bomb in GLOB.machines)
if(bomb && bomb.r_code)
if(is_station_level(bomb.z))
diff --git a/code/game/gamemodes/cult/cult.dm b/code/game/gamemodes/cult/cult.dm
index bf5fbb70731..433fc5b526a 100644
--- a/code/game/gamemodes/cult/cult.dm
+++ b/code/game/gamemodes/cult/cult.dm
@@ -20,8 +20,8 @@ GLOBAL_LIST_EMPTY(all_cults)
var/mob/living/carbon/human/H = mind.current
if(ismindshielded(H)) //mindshield protects against conversions unless removed
return FALSE
-// if(mind.offstation_role) cant convert offstation roles such as ghost spawns
-// return FALSE Commented out until we can figure out why offstation_role is getting set to TRUE on normal crew
+ if(mind.offstation_role)
+ return FALSE
if(issilicon(mind.current))
return FALSE //can't convert machines, that's ratvar's thing
if(isguardian(mind.current))
@@ -231,6 +231,8 @@ GLOBAL_LIST_EMPTY(all_cults)
/datum/game_mode/cult/proc/get_unconvertables()
var/list/ucs = list()
for(var/mob/living/carbon/human/player in GLOB.player_list)
+ if(player.mind && player.mind.offstation_role)
+ continue
if(!is_convertable_to_cult(player.mind))
ucs += player.mind
return ucs
diff --git a/code/game/gamemodes/cult/talisman.dm b/code/game/gamemodes/cult/talisman.dm
index 60d2a7ff73b..492d128e222 100644
--- a/code/game/gamemodes/cult/talisman.dm
+++ b/code/game/gamemodes/cult/talisman.dm
@@ -4,7 +4,7 @@
var/cultist_name = "talisman"
var/cultist_desc = "A basic talisman. It serves no purpose."
var/invocation = "Naise meam!"
- info = "  "
+ info = " ​ "
var/uses = 1
var/health_cost = 0 //The amount of health taken from the user when invoking the talisman
diff --git a/code/game/gamemodes/game_mode.dm b/code/game/gamemodes/game_mode.dm
index 2d71df8c979..57a77167346 100644
--- a/code/game/gamemodes/game_mode.dm
+++ b/code/game/gamemodes/game_mode.dm
@@ -291,7 +291,8 @@
///////////////////////////////////
/datum/game_mode/proc/get_living_heads()
. = list()
- for(var/mob/living/carbon/human/player in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/player = thing
var/list/real_command_positions = GLOB.command_positions.Copy() - "Nanotrasen Representative"
if(player.stat != DEAD && player.mind && (player.mind.assigned_role in real_command_positions))
. |= player.mind
@@ -312,7 +313,8 @@
//////////////////////////////////////////////
/datum/game_mode/proc/get_living_sec()
. = list()
- for(var/mob/living/carbon/human/player in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/player = thing
if(player.stat != DEAD && player.mind && (player.mind.assigned_role in GLOB.security_positions))
. |= player.mind
@@ -321,7 +323,8 @@
////////////////////////////////////////
/datum/game_mode/proc/get_all_sec()
. = list()
- for(var/mob/living/carbon/human/player in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/player = thing
if(player.mind && (player.mind.assigned_role in GLOB.security_positions))
. |= player.mind
diff --git a/code/game/gamemodes/malfunction/Malf_Modules.dm b/code/game/gamemodes/malfunction/Malf_Modules.dm
index a4b8c594b89..526a2c01083 100644
--- a/code/game/gamemodes/malfunction/Malf_Modules.dm
+++ b/code/game/gamemodes/malfunction/Malf_Modules.dm
@@ -83,6 +83,36 @@
else
add_ranged_ability(user, enable_text)
+/datum/action/innate/ai/choose_modules
+ name = "Choose Modules"
+ desc = "Spend your processing time to gain a variety of different abilities."
+ button_icon_state = "choose_module"
+ auto_use_uses = FALSE // This is an infinite ability.
+
+/datum/action/innate/ai/choose_modules/Grant(mob/living/L)
+ . = ..()
+ owner_AI.malf_picker = new /datum/module_picker
+
+/datum/action/innate/ai/choose_modules/Trigger()
+ . = ..()
+ owner_AI.malf_picker.use(owner_AI)
+
+/datum/action/innate/ai/return_to_core
+ name = "Return to Main Core"
+ desc = "Leave the APC you are shunted to, and return to your core."
+ icon_icon = 'icons/obj/power.dmi'
+ button_icon_state = "apcemag"
+ auto_use_uses = FALSE // Here just to prevent the "You have X uses remaining" from popping up.
+
+/datum/action/innate/ai/return_to_core/Trigger()
+ . = ..()
+ var/obj/machinery/power/apc/apc = owner_AI.loc
+ if(!istype(apc)) // This shouldn't happen but here for safety.
+ to_chat(src, " You are already in your Main Core.")
+ return
+ apc.malfvacate()
+ qdel(src)
+
//The datum and interface for the malf unlock menu, which lets them choose actions to unlock.
/datum/module_picker
var/temp
@@ -96,13 +126,7 @@
if((AM.power_type && AM.power_type != /datum/action/innate/ai) || AM.upgrade)
possible_modules += AM
-/datum/module_picker/proc/remove_malf_verbs(mob/living/silicon/ai/AI) //Removes all malfunction-related abilities from the target AI.
- for(var/datum/AI_Module/AM in possible_modules)
- for(var/datum/action/A in AI.actions)
- if(istype(A, initial(AM.power_type)))
- qdel(A)
-
-/datum/module_picker/proc/use(user as mob)
+/datum/module_picker/proc/use(mob/user)
var/dat
dat += {" Select use of processing time: (currently #[processing_time] left.)
diff --git a/code/game/gamemodes/miniantags/borer/borer.dm b/code/game/gamemodes/miniantags/borer/borer.dm
index f99a00567ae..750473b1dfa 100644
--- a/code/game/gamemodes/miniantags/borer/borer.dm
+++ b/code/game/gamemodes/miniantags/borer/borer.dm
@@ -394,7 +394,7 @@
to_chat(src, " You are feeling far too docile to do that.")
return
- var content = ""
+ var/content = ""
content += " "
diff --git a/code/game/gamemodes/miniantags/revenant/revenant.dm b/code/game/gamemodes/miniantags/revenant/revenant.dm
index f86f018757e..637ab69bf04 100644
--- a/code/game/gamemodes/miniantags/revenant/revenant.dm
+++ b/code/game/gamemodes/miniantags/revenant/revenant.dm
@@ -16,6 +16,7 @@
var/icon_stun = "revenant_stun"
var/icon_drain = "revenant_draining"
incorporeal_move = 3
+ see_invisible = INVISIBILITY_REVENANT
invisibility = INVISIBILITY_REVENANT
health = INFINITY //Revenants don't use health, they use essence instead
maxHealth = INFINITY
diff --git a/code/game/gamemodes/nuclear/nuclear.dm b/code/game/gamemodes/nuclear/nuclear.dm
index 5fed8ae00f4..8316364781b 100644
--- a/code/game/gamemodes/nuclear/nuclear.dm
+++ b/code/game/gamemodes/nuclear/nuclear.dm
@@ -53,7 +53,6 @@ proc/issyndicate(mob/living/M as mob)
for(var/datum/mind/synd_mind in syndicates)
synd_mind.assigned_role = SPECIAL_ROLE_NUKEOPS //So they aren't chosen for other jobs.
synd_mind.special_role = SPECIAL_ROLE_NUKEOPS
- synd_mind.offstation_role = TRUE
return 1
@@ -113,7 +112,7 @@ proc/issyndicate(mob/living/M as mob)
if(spawnpos > synd_spawn.len)
spawnpos = 2
synd_mind.current.loc = synd_spawn[spawnpos]
-
+ synd_mind.offstation_role = TRUE
forge_syndicate_objectives(synd_mind)
create_syndicate(synd_mind)
greet_syndicate(synd_mind)
diff --git a/code/game/gamemodes/nuclear/pinpointer.dm b/code/game/gamemodes/nuclear/pinpointer.dm
index e8f4c22e377..f6e454bd737 100644
--- a/code/game/gamemodes/nuclear/pinpointer.dm
+++ b/code/game/gamemodes/nuclear/pinpointer.dm
@@ -357,7 +357,8 @@
var/list/name_counts = list()
var/list/names = list()
- for(var/mob/living/carbon/human/H in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
if(!trackable(H))
continue
diff --git a/code/game/gamemodes/revolution/revolution.dm b/code/game/gamemodes/revolution/revolution.dm
index b09bb7a851f..213814d52e8 100644
--- a/code/game/gamemodes/revolution/revolution.dm
+++ b/code/game/gamemodes/revolution/revolution.dm
@@ -385,7 +385,8 @@
if(foecount == GLOB.score_arrested)
GLOB.score_allarrested = 1
- for(var/mob/living/carbon/human/player in GLOB.mob_living_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/player = thing
if(player.mind)
var/role = player.mind.assigned_role
if(role in list("Captain", "Head of Security", "Head of Personnel", "Chief Engineer", "Research Director"))
@@ -415,7 +416,8 @@
for(var/datum/mind/M in SSticker.mode:revolutionaries)
if(M.current && M.current.stat != DEAD)
revcount++
- for(var/mob/living/carbon/human/player in GLOB.mob_living_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/player = thing
if(player.mind)
var/role = player.mind.assigned_role
if(role in list("Captain", "Head of Security", "Head of Personnel", "Chief Engineer", "Research Director"))
diff --git a/code/game/gamemodes/scoreboard.dm b/code/game/gamemodes/scoreboard.dm
index d9e59e9ded1..2e370db5f7a 100644
--- a/code/game/gamemodes/scoreboard.dm
+++ b/code/game/gamemodes/scoreboard.dm
@@ -41,7 +41,8 @@
GLOB.score_deadaipenalty++
GLOB.score_deadcrew++
- for(var/mob/living/carbon/human/I in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/I = thing
if(I.stat == DEAD && is_station_level(I.z))
GLOB.score_deadcrew++
@@ -60,7 +61,8 @@
var/dmg_score = 0
if(SSshuttle.emergency.mode >= SHUTTLE_ENDGAME)
- for(var/mob/living/carbon/human/E in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/E = thing
cash_score = 0
dmg_score = 0
var/turf/location = get_turf(E.loc)
diff --git a/code/game/gamemodes/vampire/vampire_powers.dm b/code/game/gamemodes/vampire/vampire_powers.dm
index 7e0f00f8721..7906deeb718 100644
--- a/code/game/gamemodes/vampire/vampire_powers.dm
+++ b/code/game/gamemodes/vampire/vampire_powers.dm
@@ -145,7 +145,7 @@
/obj/effect/proc_holder/spell/vampire/self/rejuvenate
name = "Rejuvenate"
- desc= "Flush your system with spare blood to remove any incapacitating effects."
+ desc= "Use reserve blood to enliven your body, removing any incapacitating effects."
action_icon_state = "vampire_rejuvinate"
charge_max = 200
stat_allowed = 1
@@ -158,7 +158,7 @@
user.SetParalysis(0)
user.SetSleeping(0)
U.adjustStaminaLoss(-75)
- to_chat(user, "You flush your system with clean blood and remove any incapacitating effects.")
+ to_chat(user, "You instill your body with clean blood and remove any incapacitating effects.")
spawn(1)
if(usr.mind.vampire.get_ability(/datum/vampire_passive/regen))
for(var/i = 1 to 5)
@@ -354,10 +354,10 @@
var/datum/objective/protect/serve_objective = new
serve_objective.owner = user.mind
serve_objective.target = H.mind
- serve_objective.explanation_text = "You have been Enthralled by [user]. Follow [user.p_their()] every command."
+ serve_objective.explanation_text = "You have been Enthralled by [user.real_name]. Follow [user.p_their()] every command."
H.mind.objectives += serve_objective
- to_chat(H, "You have been Enthralled by [user]. Follow [user.p_their()] every command.")
+ to_chat(H, "You have been Enthralled by [user.real_name]. Follow [user.p_their()] every command.")
to_chat(user, "You have successfully Enthralled [H]. If [H.p_they()] refuse[H.p_s()] to do as you say just adminhelp.")
H.Stun(2)
add_attack_logs(user, H, "Vampire-thralled")
diff --git a/code/game/gamemodes/wizard/artefact.dm b/code/game/gamemodes/wizard/artefact.dm
index 09b228bdd0c..a81b12ed041 100644
--- a/code/game/gamemodes/wizard/artefact.dm
+++ b/code/game/gamemodes/wizard/artefact.dm
@@ -866,8 +866,9 @@ GLOBAL_LIST_EMPTY(multiverse)
possible = list()
if(!link)
return
- for(var/mob/living/carbon/human/H in GLOB.alive_mob_list)
- if(md5(H.dna.uni_identity) in link.fingerprints)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
+ if(H.stat != DEAD && (md5(H.dna.uni_identity) in link.fingerprints))
possible |= H
/obj/item/voodoo/proc/GiveHint(mob/victim,force=0)
diff --git a/code/game/gamemodes/wizard/spellbook.dm b/code/game/gamemodes/wizard/spellbook.dm
index b76b31255e9..d0773947c21 100644
--- a/code/game/gamemodes/wizard/spellbook.dm
+++ b/code/game/gamemodes/wizard/spellbook.dm
@@ -1,20 +1,16 @@
/datum/spellbook_entry
var/name = "Entry Name"
-
+ var/is_ragin_restricted = FALSE // FALSE if this is buyable on ragin mages, TRUE if it's not.
var/spell_type = null
var/desc = ""
var/category = "Offensive"
var/log_name = "XX" //What it shows up as in logs
var/cost = 2
var/refundable = TRUE
- var/surplus = -1 // -1 for infinite, not used by anything atm
var/obj/effect/proc_holder/spell/S = null //Since spellbooks can be used by only one person anyway we can track the actual spell
var/buy_word = "Learn"
var/limit //used to prevent a spellbook_entry from being bought more than X times with one wizard spellbook
-/datum/spellbook_entry/proc/IsSpellAvailable() // For config prefs / gamemode restrictions - these are round applied
- return TRUE
-
/datum/spellbook_entry/proc/CanBuy(mob/living/carbon/human/user, obj/item/spellbook/book) // Specific circumstances
if(book.uses < cost || limit == 0)
return FALSE
@@ -218,12 +214,7 @@
spell_type = /obj/effect/proc_holder/spell/targeted/lichdom
log_name = "LD"
category = "Defensive"
-
-/datum/spellbook_entry/lichdom/IsSpellAvailable()
- if(SSticker.mode.name == "ragin' mages")
- return FALSE
- else
- return TRUE
+ is_ragin_restricted = TRUE
/datum/spellbook_entry/magicm
name = "Magic Missile"
@@ -325,14 +316,7 @@
desc = "Spook the crew out by making them see dead people. Be warned, ghosts are capricious and occasionally vindicative, and some will use their incredibly minor abilities to frustrate you."
cost = 0
log_name = "SGH"
-
-/datum/spellbook_entry/summon/ghosts/IsSpellAvailable()
- if(!SSticker.mode) // In case spellbook is placed on map
- return FALSE
- if(SSticker.mode.name == "ragin' mages")
- return FALSE
- else
- return TRUE
+ is_ragin_restricted = TRUE
/datum/spellbook_entry/summon/ghosts/Buy(mob/living/carbon/human/user, obj/item/spellbook/book)
new /datum/event/wizard/ghost()
@@ -345,14 +329,7 @@
name = "Summon Guns"
desc = "Nothing could possibly go wrong with arming a crew of lunatics just itching for an excuse to kill you. There is a good chance that they will shoot each other first."
log_name = "SG"
-
-/datum/spellbook_entry/summon/guns/IsSpellAvailable()
- if(!SSticker.mode) // In case spellbook is placed on map
- return FALSE
- if(SSticker.mode.name == "ragin' mages")
- return FALSE
- else
- return TRUE
+ is_ragin_restricted = TRUE
/datum/spellbook_entry/summon/guns/Buy(mob/living/carbon/human/user, obj/item/spellbook/book)
feedback_add_details("wizard_spell_learned", log_name)
@@ -366,14 +343,7 @@
name = "Summon Magic"
desc = "Share the wonders of magic with the crew and show them why they aren't to be trusted with it at the same time."
log_name = "SU"
-
-/datum/spellbook_entry/summon/magic/IsSpellAvailable()
- if(!SSticker.mode) // In case spellbook is placed on map
- return FALSE
- if(SSticker.mode.name == "ragin' mages")
- return FALSE
- else
- return TRUE
+ is_ragin_restricted = TRUE
/datum/spellbook_entry/summon/magic/Buy(mob/living/carbon/human/user, obj/item/spellbook/book)
feedback_add_details("wizard_spell_learned", log_name)
@@ -400,8 +370,6 @@
dat += "[name]"
dat += " Cost:[cost] "
dat += "[desc] "
- if(surplus>=0)
- dat += "[surplus] left. "
return dat
//Artefacts
@@ -642,11 +610,12 @@
var/entry_types = subtypesof(/datum/spellbook_entry) - /datum/spellbook_entry/item - /datum/spellbook_entry/summon - /datum/spellbook_entry/loadout
for(var/T in entry_types)
var/datum/spellbook_entry/E = new T
- if(E.IsSpellAvailable())
- entries |= E
- categories |= E.category
- else
+ if(GAMEMODE_IS_RAGIN_MAGES && E.is_ragin_restricted)
qdel(E)
+ continue
+ entries |= E
+ categories |= E.category
+
main_tab = main_categories[1]
tab = categories[1]
diff --git a/code/game/gamemodes/wizard/wizloadouts.dm b/code/game/gamemodes/wizard/wizloadouts.dm
index 0e53d30f1bf..c050b27f273 100644
--- a/code/game/gamemodes/wizard/wizloadouts.dm
+++ b/code/game/gamemodes/wizard/wizloadouts.dm
@@ -20,6 +20,7 @@
log_name = "DL"
spells_path = list(/obj/effect/proc_holder/spell/targeted/lichdom, /obj/effect/proc_holder/spell/targeted/ethereal_jaunt, /obj/effect/proc_holder/spell/fireball, \
/obj/effect/proc_holder/spell/targeted/rod_form, /obj/effect/proc_holder/spell/targeted/emplosion/disable_tech, /obj/effect/proc_holder/spell/targeted/forcewall/greater)
+ is_ragin_restricted = TRUE
/datum/spellbook_entry/loadout/wands
name = "Utility Focus : Wands"
@@ -63,6 +64,7 @@
/obj/effect/proc_holder/spell/targeted/summonitem, /obj/effect/proc_holder/spell/noclothes, /obj/effect/proc_holder/spell/targeted/lichdom/gunslinger)
category = "Unique"
destroy_spellbook = TRUE
+ is_ragin_restricted = TRUE
/obj/effect/proc_holder/spell/targeted/lichdom/gunslinger/equip_lich(mob/living/carbon/human/H)
H.equip_to_slot_or_del(new /obj/item/clothing/suit/storage/det_suit(H), slot_wear_suit)
diff --git a/code/game/jobs/job/silicon.dm b/code/game/jobs/job/silicon.dm
index c510518716a..fef9c2302b3 100644
--- a/code/game/jobs/job/silicon.dm
+++ b/code/game/jobs/job/silicon.dm
@@ -32,7 +32,7 @@
minimal_player_age = 21
exp_requirements = 300
exp_type = EXP_TYPE_CREW
- alt_titles = list("Android", "Robot")
+ alt_titles = list("Robot")
/datum/job/cyborg/equip(mob/living/carbon/human/H)
if(!H)
diff --git a/code/game/jobs/job_scaling.dm b/code/game/jobs/job_scaling.dm
deleted file mode 100644
index 7c2a98b36df..00000000000
--- a/code/game/jobs/job_scaling.dm
+++ /dev/null
@@ -1,11 +0,0 @@
-/hook/roundstart/proc/jobscaling()
- sleep(10 SECONDS) // give everyone time to finish spawning, and the lag to die down
- var/playercount = length(GLOB.clients)
- var/highpop_trigger = 80
-
- if(playercount >= highpop_trigger)
- log_debug("Playercount: [playercount] versus trigger: [highpop_trigger] - loading highpop job config")
- SSjobs.LoadJobs("config/jobs_highpop.txt")
- else
- log_debug("Playercount: [playercount] versus trigger: [highpop_trigger] - keeping standard job config")
- return 1
diff --git a/code/game/jobs/whitelist.dm b/code/game/jobs/whitelist.dm
index ab1bd3b8067..46b98ce1030 100644
--- a/code/game/jobs/whitelist.dm
+++ b/code/game/jobs/whitelist.dm
@@ -2,10 +2,11 @@
GLOBAL_LIST_EMPTY(whitelist)
-/hook/startup/proc/loadWhitelist()
+/proc/init_whitelists()
if(config.usewhitelist)
load_whitelist()
- return 1
+ if(config.usealienwhitelist)
+ load_alienwhitelist()
/proc/load_whitelist()
GLOB.whitelist = file2list(WHITELISTFILE)
@@ -48,11 +49,6 @@ GLOBAL_LIST_EMPTY(whitelist)
GLOBAL_LIST_EMPTY(alien_whitelist)
-/hook/startup/proc/loadAlienWhitelist()
- if(config.usealienwhitelist)
- load_alienwhitelist()
- return 1
-
/proc/load_alienwhitelist()
var/text = file2text("config/alienwhitelist.txt")
if(!text)
diff --git a/code/game/machinery/Sleeper.dm b/code/game/machinery/Sleeper.dm
index e4d0befa61e..7c5a03e29e6 100644
--- a/code/game/machinery/Sleeper.dm
+++ b/code/game/machinery/Sleeper.dm
@@ -411,6 +411,9 @@
for(var/atom/movable/A in contents - component_parts - list(beaker))
A.forceMove(loc)
+/obj/machinery/sleeper/force_eject_occupant()
+ go_out()
+
/obj/machinery/sleeper/proc/inject_chemical(mob/living/user as mob, chemical, amount)
if(!(chemical in possible_chems))
to_chat(user, "The sleeper does not offer that chemical!")
diff --git a/code/game/machinery/adv_med.dm b/code/game/machinery/adv_med.dm
index 1ee30b6e9d0..3fa78dd02e6 100644
--- a/code/game/machinery/adv_med.dm
+++ b/code/game/machinery/adv_med.dm
@@ -172,6 +172,9 @@
for(var/atom/movable/A in contents - component_parts)
A.forceMove(loc)
+/obj/machinery/bodyscanner/force_eject_occupant()
+ go_out()
+
/obj/machinery/bodyscanner/ex_act(severity)
if(occupant)
occupant.ex_act(severity)
diff --git a/code/game/machinery/computer/cloning.dm b/code/game/machinery/computer/cloning.dm
index 3091caa82a2..5198a97a88c 100644
--- a/code/game/machinery/computer/cloning.dm
+++ b/code/game/machinery/computer/cloning.dm
@@ -164,7 +164,7 @@
data["selected_pod"] = "\ref[selected_pod]"
var/list/temprecords[0]
for(var/datum/dna2/record/R in records)
- var tempRealName = R.dna.real_name
+ var/tempRealName = R.dna.real_name
temprecords.Add(list(list("record" = "\ref[R]", "realname" = sanitize(tempRealName))))
data["records"] = temprecords
diff --git a/code/game/machinery/computer/communications.dm b/code/game/machinery/computer/communications.dm
index e161891cdbc..366946254ea 100644
--- a/code/game/machinery/computer/communications.dm
+++ b/code/game/machinery/computer/communications.dm
@@ -298,10 +298,6 @@
else
to_chat(usr, "Nano-Mob Hunter GO! game server is offline for extended maintenance. Contact your Central Command administrators for more info if desired.")
- if("ToggleATC")
- GLOB.atc.squelched = !GLOB.atc.squelched
- to_chat(usr, "ATC traffic is now: [GLOB.atc.squelched ? "Disabled" : "Enabled"].")
-
SSnanoui.update_uis(src)
return 1
@@ -395,8 +391,6 @@
data["shuttle"] = shuttle
- data["atcSquelched"] = GLOB.atc.squelched
-
return data
diff --git a/code/game/machinery/computer/crew.dm b/code/game/machinery/computer/crew.dm
index 131956ca3c1..d6a1ccdd33c 100644
--- a/code/game/machinery/computer/crew.dm
+++ b/code/game/machinery/computer/crew.dm
@@ -27,7 +27,7 @@
return
tgui_interact(user)
-/obj/machinery/computer/crew/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
+/obj/machinery/computer/crew/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = FALSE, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
crew_monitor.tgui_interact(user, ui_key, ui, force_open)
/obj/machinery/computer/crew/interact(mob/user)
diff --git a/code/game/machinery/computer/depot.dm b/code/game/machinery/computer/depot.dm
index 62c82d9bd95..f2e89923eb4 100644
--- a/code/game/machinery/computer/depot.dm
+++ b/code/game/machinery/computer/depot.dm
@@ -165,7 +165,7 @@
alerts_when_broken = TRUE
/obj/machinery/computer/syndicate_depot/selfdestruct/get_menu(mob/user)
- var menutext = {"Syndicate Depot Fusion Reactor Control
+ var/menutext = {"Syndicate Depot Fusion Reactor Control
Disable Containment Field
"}
return menutext
@@ -193,10 +193,6 @@
/obj/machinery/computer/syndicate_depot/shieldcontrol/New()
. = ..()
perimeterarea = locate(/area/syndicate_depot/perimeter)
- if(istype(perimeterarea) && (GAMEMODE_IS_NUCLEAR || prob(20)))
- spawn(200)
- perimeterarea.perimeter_shields_up()
- depotarea.perimeter_shield_status = TRUE
/obj/machinery/computer/syndicate_depot/shieldcontrol/Destroy()
if(istype(perimeterarea) && perimeterarea.shield_list.len)
@@ -204,7 +200,7 @@
return ..()
/obj/machinery/computer/syndicate_depot/shieldcontrol/get_menu(mob/user)
- var menutext = {"Syndicate Depot Shield Grid Control
+ var/menutext = {"Syndicate Depot Shield Grid Control
"}
menutext += {"(SYNDI-LEADER) Whole-base Shield: [perimeterarea.shield_list.len ? "ON" : "OFF"] ([perimeterarea.shield_list.len ? "Disable" : "Enable"]) "}
menutext += {"(SYNDI-LEADER) Armory Shield: [depotarea.shield_list.len ? "ON" : "OFF"] ([depotarea.shield_list.len ? "Disable" : "Enable"]) "}
diff --git a/code/game/machinery/cryo.dm b/code/game/machinery/cryo.dm
index 4213ff517bf..8be09ef30b7 100644
--- a/code/game/machinery/cryo.dm
+++ b/code/game/machinery/cryo.dm
@@ -443,6 +443,9 @@
for(var/atom/movable/A in contents - component_parts - list(beaker))
A.forceMove(get_step(loc, SOUTH))
+/obj/machinery/atmospherics/unary/cryo_cell/force_eject_occupant()
+ go_out()
+
/// Called when either the occupant is dead and the AUTO_EJECT_DEAD flag is present, OR the occupant is alive, has no external damage, and the AUTO_EJECT_HEALTHY flag is present.
/obj/machinery/atmospherics/unary/cryo_cell/proc/auto_eject(eject_flag)
on = FALSE
diff --git a/code/game/machinery/cryopod.dm b/code/game/machinery/cryopod.dm
index 36196ea4eca..fecd006886e 100644
--- a/code/game/machinery/cryopod.dm
+++ b/code/game/machinery/cryopod.dm
@@ -302,6 +302,7 @@
// Eject dead people
if(occupant.stat == DEAD)
go_out()
+ return
// Allow a gap between entering the pod and actually despawning.
if(world.time - time_entered < time_till_despawn)
@@ -768,9 +769,13 @@
return ..()
+
/proc/cryo_ssd(var/mob/living/carbon/person_to_cryo)
if(istype(person_to_cryo.loc, /obj/machinery/cryopod))
return 0
+ if(isobj(person_to_cryo.loc))
+ var/obj/O = person_to_cryo.loc
+ O.force_eject_occupant()
var/list/free_cryopods = list()
for(var/obj/machinery/cryopod/P in GLOB.machines)
if(!P.occupant && istype(get_area(P), /area/crew_quarters/sleep))
diff --git a/code/game/machinery/doors/airlock.dm b/code/game/machinery/doors/airlock.dm
index e97c460de4b..42ff08ff00f 100644
--- a/code/game/machinery/doors/airlock.dm
+++ b/code/game/machinery/doors/airlock.dm
@@ -80,6 +80,7 @@ GLOBAL_LIST_EMPTY(airlock_overlays)
var/note_overlay_file = 'icons/obj/doors/airlocks/station/overlays.dmi' //Used for papers and photos pinned to the airlock
var/normal_integrity = AIRLOCK_INTEGRITY_N
var/prying_so_hard = FALSE
+ var/paintable = TRUE // If the airlock type can be painted with an airlock painter
var/image/old_frame_overlay //keep those in order to prevent unnecessary updating
var/image/old_filling_overlay
@@ -502,6 +503,36 @@ About the new airlock wires panel:
sleep(6)
update_icon(AIRLOCK_CLOSED)
+
+/// Called when a player uses an airlock painter on this airlock
+/obj/machinery/door/airlock/proc/change_paintjob(obj/item/airlock_painter/painter, mob/user)
+ if((!in_range(src, user) && loc != user)) // user should be adjacent to the airlock.
+ return
+
+ if(!painter.paint_setting)
+ to_chat(user, "You need to select a paintjob first.")
+ return
+
+ if(!paintable)
+ to_chat(user, "This type of airlock cannot be painted.")
+ return
+
+ var/obj/machinery/door/airlock/airlock = painter.available_paint_jobs["[painter.paint_setting]"] // get the airlock type path associated with the airlock name the user just chose
+ var/obj/structure/door_assembly/assembly = initial(airlock.assemblytype)
+
+ if(airlock_material == "glass" && initial(assembly.noglass)) // prevents painting glass airlocks with a paint job that doesn't have a glass version, such as the freezer
+ to_chat(user, "This paint job can only be applied to non-glass airlocks.")
+ return
+
+ if(do_after(user, 20, target = src))
+ // applies the user-chosen airlock's icon, overlays and assemblytype to the src airlock
+ painter.paint(user)
+ icon = initial(airlock.icon)
+ overlays_file = initial(airlock.overlays_file)
+ assemblytype = initial(airlock.assemblytype)
+ update_icon()
+
+
/obj/machinery/door/airlock/examine(mob/user)
. = ..()
if(emagged)
@@ -882,6 +913,8 @@ About the new airlock wires panel:
user.visible_message("[user] pins [C] to [src].", "You pin [C] to [src].")
note = C
update_icon()
+ else if(istype(C, /obj/item/airlock_painter))
+ change_paintjob(C, user)
else
return ..()
diff --git a/code/game/machinery/doors/airlock_types.dm b/code/game/machinery/doors/airlock_types.dm
index fccb77c5e2a..dd9581a5af3 100644
--- a/code/game/machinery/doors/airlock_types.dm
+++ b/code/game/machinery/doors/airlock_types.dm
@@ -115,6 +115,7 @@
name = "gold airlock"
icon = 'icons/obj/doors/airlocks/station/gold.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_gold
+ paintable = FALSE
/obj/machinery/door/airlock/gold/glass
opacity = 0
@@ -124,6 +125,7 @@
name = "silver airlock"
icon = 'icons/obj/doors/airlocks/station/silver.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_silver
+ paintable = FALSE
/obj/machinery/door/airlock/silver/glass
opacity = 0
@@ -135,6 +137,7 @@
assemblytype = /obj/structure/door_assembly/door_assembly_diamond
normal_integrity = 1000
explosion_block = 2
+ paintable = FALSE
/obj/machinery/door/airlock/diamond/glass
normal_integrity = 950
@@ -146,6 +149,7 @@
desc = "And they said I was crazy."
icon = 'icons/obj/doors/airlocks/station/uranium.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_uranium
+ paintable = FALSE
var/event_step = 20
/obj/machinery/door/airlock/uranium/New()
@@ -169,6 +173,7 @@
desc = "No way this can end badly."
icon = 'icons/obj/doors/airlocks/station/plasma.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_plasma
+ paintable = FALSE
/obj/machinery/door/airlock/plasma/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
..()
@@ -214,6 +219,7 @@
assemblytype = /obj/structure/door_assembly/door_assembly_bananium
doorOpen = 'sound/items/bikehorn.ogg'
doorClose = 'sound/items/bikehorn.ogg'
+ paintable = FALSE
/obj/machinery/door/airlock/bananium/glass
opacity = 0
@@ -227,11 +233,13 @@
doorDeni = null
boltUp = null
boltDown = null
+ paintable = FALSE
/obj/machinery/door/airlock/sandstone
name = "sandstone airlock"
icon = 'icons/obj/doors/airlocks/station/sandstone.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_sandstone
+ paintable = FALSE
/obj/machinery/door/airlock/sandstone/glass
opacity = 0
@@ -241,6 +249,7 @@
name = "wooden airlock"
icon = 'icons/obj/doors/airlocks/station/wood.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_wood
+ paintable = FALSE
/obj/machinery/door/airlock/wood/glass
opacity = 0
@@ -252,6 +261,7 @@
icon = 'icons/obj/doors/airlocks/shuttle/shuttle.dmi'
overlays_file = 'icons/obj/doors/airlocks/shuttle/overlays.dmi'
normal_integrity = 400
+ paintable = FALSE
/obj/machinery/door/airlock/titanium/glass
normal_integrity = 350
@@ -317,6 +327,7 @@
explosion_block = 2
normal_integrity = 400 // reverse engieneerd: 400 * 1.5 (sec lvl 6) = 600 = original
security_level = 6
+ paintable = FALSE
//////////////////////////////////
/*
@@ -329,6 +340,7 @@
overlays_file = 'icons/obj/doors/airlocks/hatch/overlays.dmi'
note_overlay_file = 'icons/obj/doors/airlocks/hatch/overlays.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_hatch
+ paintable = FALSE
/obj/machinery/door/airlock/hatch/syndicate
name = "syndicate hatch"
@@ -400,6 +412,7 @@
overlays_file = 'icons/obj/doors/airlocks/hatch/overlays.dmi'
note_overlay_file = 'icons/obj/doors/airlocks/hatch/overlays.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_mhatch
+ paintable = FALSE
//////////////////////////////////
/*
@@ -415,6 +428,7 @@
normal_integrity = 500
security_level = 1
damage_deflection = 30
+ paintable = FALSE
/obj/machinery/door/airlock/highsecurity/red
name = "secure armory airlock"
@@ -457,6 +471,7 @@
icon = 'icons/obj/doors/airlocks/shuttle/shuttle.dmi'
overlays_file = 'icons/obj/doors/airlocks/shuttle/overlays.dmi'
assemblytype = /obj/structure/door_assembly/door_assembly_shuttle
+ paintable = FALSE
/obj/machinery/door/airlock/shuttle/glass
opacity = 0
@@ -475,6 +490,7 @@
aiControlDisabled = 1
normal_integrity = 700
security_level = 1
+ paintable = FALSE
//////////////////////////////////
/*
@@ -489,6 +505,7 @@
damage_deflection = 10
hackProof = TRUE
aiControlDisabled = TRUE
+ paintable = FALSE
var/openingoverlaytype = /obj/effect/temp_visual/cult/door
var/friendly = FALSE
@@ -575,6 +592,7 @@
overlays_file = 'icons/obj/doors/airlocks/glass_large/overlays.dmi'
note_overlay_file = 'icons/obj/doors/airlocks/glass_large/overlays.dmi'
assemblytype = /obj/structure/door_assembly/multi_tile
+ paintable = FALSE
/obj/machinery/door/airlock/multi_tile/narsie_act()
return
diff --git a/code/game/machinery/suit_storage_unit.dm b/code/game/machinery/suit_storage_unit.dm
index da4df4f8382..cd6b33d0a95 100644
--- a/code/game/machinery/suit_storage_unit.dm
+++ b/code/game/machinery/suit_storage_unit.dm
@@ -740,10 +740,11 @@
if(!occupant)
return
- if(user != occupant)
- to_chat(occupant, "The machine kicks you out!")
- if(user.loc != loc)
- to_chat(occupant, "You leave the not-so-cozy confines of the SSU.")
+ if(user)
+ if(user != occupant)
+ to_chat(occupant, "The machine kicks you out!")
+ if(user.loc != loc)
+ to_chat(occupant, "You leave the not-so-cozy confines of [src].")
occupant.forceMove(loc)
occupant = null
if(!state_open)
@@ -751,6 +752,8 @@
update_icon()
return
+/obj/machinery/suit_storage_unit/force_eject_occupant()
+ eject_occupant()
/obj/machinery/suit_storage_unit/verb/get_out()
set name = "Eject Suit Storage Unit"
diff --git a/code/game/machinery/tcomms/_base.dm b/code/game/machinery/tcomms/_base.dm
index dc933099faa..05c7552aacc 100644
--- a/code/game/machinery/tcomms/_base.dm
+++ b/code/game/machinery/tcomms/_base.dm
@@ -52,6 +52,19 @@ GLOBAL_LIST_EMPTY(tcomms_machines)
. = ..()
GLOB.tcomms_machines += src
update_icon()
+ if((!mapload) && (usr))
+ // To the person who asks "Hey affected, why are you using this massive operator when you can use AREACOORD?" Well, ill tell you
+ // get_area_name is fucking broken and uses a for(x in world) search
+ // It doesnt even work, is expensive, and returns 0
+ // Im not refactoring one thing which could risk breaking all admin location logs
+ // Fight me
+ log_action(usr, "constructed a new [src] at [src ? "[get_location_name(src, TRUE)] [COORD(src)]" : "nonexistent location"] [ADMIN_JMP(src)]", adminmsg = TRUE)
+ // Add in component parts for the sake of deconstruction
+ component_parts = list()
+ component_parts += new /obj/item/stock_parts/manipulator(null)
+ component_parts += new /obj/item/stock_parts/manipulator(null)
+ component_parts += new /obj/item/stack/cable_coil(null, 1)
+ component_parts += new /obj/item/stack/cable_coil(null, 1)
/**
* Base Destructor
@@ -60,6 +73,8 @@ GLOBAL_LIST_EMPTY(tcomms_machines)
*/
/obj/machinery/tcomms/Destroy()
GLOB.tcomms_machines -= src
+ if(usr)
+ log_action(usr, "destroyed a [src] at [src ? "[get_location_name(src, TRUE)] [COORD(src)]" : "nonexistent location"] [ADMIN_JMP(src)]", adminmsg = TRUE)
return ..()
/**
@@ -462,3 +477,20 @@ GLOBAL_LIST_EMPTY(tcomms_machines)
break
return ..()
+/**
+ * Screwdriver Act Handler
+ *
+ * Handles the screwdriver action for all tcomms machines, so they can be open and closed to be deconstructed
+ */
+/obj/machinery/tcomms/screwdriver_act(mob/user, obj/item/I)
+ . = TRUE
+ default_deconstruction_screwdriver(user, icon_state, icon_state, I)
+
+/**
+ * Crowbar Act Handler
+ *
+ * Handles the crowbar action for all tcomms machines, so they can be deconstructed
+ */
+/obj/machinery/tcomms/crowbar_act(mob/user, obj/item/I)
+ . = TRUE
+ default_deconstruction_crowbar(user, I)
diff --git a/code/game/machinery/tcomms/core.dm b/code/game/machinery/tcomms/core.dm
index f1599edd8b8..46cd0e6df71 100644
--- a/code/game/machinery/tcomms/core.dm
+++ b/code/game/machinery/tcomms/core.dm
@@ -34,6 +34,7 @@
. = ..()
link_password = GenerateKey()
reachable_zlevels |= loc.z
+ component_parts += new /obj/item/circuitboard/tcomms/core(null)
/**
* Destructor for the core.
@@ -57,6 +58,9 @@
* * zlevel - The input z level to test
*/
/obj/machinery/tcomms/core/proc/zlevel_reachable(zlevel)
+ // Nothing is reachable if the core is offline, unpowered, or ion'd
+ if(!active || (stat & NOPOWER) || ion)
+ return FALSE
if(zlevel in reachable_zlevels)
return TRUE
else
@@ -113,7 +117,7 @@
// Add all the linked relays in
for(var/obj/machinery/tcomms/relay/R in linked_relays)
// Only if the relay is active
- if(R.active)
+ if(R.active && !(R.stat & NOPOWER))
reachable_zlevels |= R.loc.z
diff --git a/code/game/machinery/tcomms/relay.dm b/code/game/machinery/tcomms/relay.dm
index 9309a6109da..b2faf9ce0cd 100644
--- a/code/game/machinery/tcomms/relay.dm
+++ b/code/game/machinery/tcomms/relay.dm
@@ -25,6 +25,7 @@
*/
/obj/machinery/tcomms/relay/Initialize(mapload)
. = ..()
+ component_parts += new /obj/item/circuitboard/tcomms/relay(null)
if(mapload && autolink_id)
return INITIALIZE_HINT_LATELOAD
@@ -76,6 +77,16 @@
linked_core = null
linked = FALSE
+/**
+ * Power Change Handler
+ *
+ * Proc which ensures the host core has its zlevels updated (icons are updated by parent call)
+ */
+/obj/machinery/tcomms/relay/power_change()
+ ..()
+ if(linked_core)
+ linked_core.refresh_zlevels()
+
//////////////
// UI STUFF //
//////////////
diff --git a/code/game/machinery/teleporter.dm b/code/game/machinery/teleporter.dm
index b92e3c78bb8..59bae3174c4 100644
--- a/code/game/machinery/teleporter.dm
+++ b/code/game/machinery/teleporter.dm
@@ -79,7 +79,7 @@
/obj/machinery/computer/teleporter/ui_data(mob/user, ui_key = "main", datum/topic_state/state = GLOB.default_state)
var/data[0]
data["powerstation"] = power_station
- if(power_station)
+ if(power_station?.teleporter_hub)
data["teleporterhub"] = power_station.teleporter_hub
data["calibrated"] = power_station.teleporter_hub.calibrated
data["accurate"] = power_station.teleporter_hub.accurate
diff --git a/code/game/machinery/turntable.dm b/code/game/machinery/turntable.dm
deleted file mode 100644
index 70d7adff2be..00000000000
--- a/code/game/machinery/turntable.dm
+++ /dev/null
@@ -1,280 +0,0 @@
-/sound/turntable/test
- file = 'sound/turntable/testloop1.ogg'
- falloff = 2
- repeat = 1
-
-/mob/var/music = 0
-
-/obj/machinery/party/turntable
- name = "turntable"
- desc = "A turntable used for parties and shit."
- icon = 'icons/effects/lasers2.dmi'
- icon_state = "turntable"
- var/playing = 0
- anchored = 1
-
-/obj/machinery/party/mixer
- name = "mixer"
- desc = "A mixing board for mixing music"
- icon = 'icons/effects/lasers2.dmi'
- icon_state = "mixer"
- anchored = 1
-
-
-/obj/machinery/party/turntable/New()
- ..()
- sleep(2)
- new /sound/turntable/test(src)
- return
-
-/obj/machinery/party/turntable/attack_hand(mob/user as mob)
-
- var/t = "Turntable Interface
"
- //t += "On "
- t += "Off
"
- t += "One "
- t += "TestLoop2 "
- t += "TestLoop3 "
-
- user << browse(t, "window=turntable;size=420x700")
-
-
-/obj/machinery/party/turntable/Topic(href, href_list)
- ..()
- if( href_list["on1"] )
- if(src.playing == 0)
-// to_chat(world, "Should be working...")
- var/sound/S = sound('sound/turntable/testloop1.ogg')
- S.repeat = 1
- S.channel = 10
- S.falloff = 2
- S.wait = 1
- S.environment = 0
- //for(var/mob/M in world)
- // if(M.loc.loc == src.loc.loc && M.music == 0)
-// to_chat(world, "Found the song...")
-// M << S
- // M.music = 1
- var/area/A = src.loc.loc
-
- for(var/obj/machinery/party/lasermachine/L in A)
- L.turnon()
- playing = 1
- while(playing == 1)
- for(var/mob/M in world)
- if((M.loc.loc in A) && M.music == 0)
-// to_chat(world, "Found the song...")
- M << S
- M.music = 1
- else if(!(M.loc.loc in A) && M.music == 1)
- var/sound/Soff = sound(null)
- Soff.channel = 10
- M << Soff
- M.music = 0
- sleep(10)
- return
- if( href_list["on2"] )
- if(src.playing == 0)
-// to_chat(world, "Should be working...")
- var/sound/S = sound('sound/turntable/testloop2.ogg')
- S.repeat = 1
- S.channel = 10
- S.falloff = 2
- S.wait = 1
- S.environment = 0
- //for(var/mob/M in world)
- // if(M.loc.loc == src.loc.loc && M.music == 0)
-// to_chat(world, "Found the song...")
-// M << S
- // M.music = 1
- var/area/A = src.loc.loc
- for(var/obj/machinery/party/lasermachine/L in A)
- L.turnon()
- playing = 1
- while(playing == 1)
- for(var/mob/M in world)
- if(M.loc.loc == src.loc.loc && M.music == 0)
-// to_chat(world, "Found the song...")
- M << S
- M.music = 1
- else if(M.loc.loc != src.loc.loc && M.music == 1)
- var/sound/Soff = sound(null)
- Soff.channel = 10
- M << Soff
- M.music = 0
- sleep(10)
- return
- if( href_list["on3"] )
- if(src.playing == 0)
-// to_chat(world, "Should be working...")
- var/sound/S = sound('sound/turntable/testloop3.ogg')
- S.repeat = 1
- S.channel = 10
- S.falloff = 2
- S.wait = 1
- S.environment = 0
- //for(var/mob/M in world)
- // if(M.loc.loc == src.loc.loc && M.music == 0)
-// to_chat(world, "Found the song...")
-// M << S
- // M.music = 1
- var/area/A = src.loc.loc
- for(var/obj/machinery/party/lasermachine/L in A)
- L.turnon()
- playing = 1
- while(playing == 1)
- for(var/mob/M in world)
- if(M.loc.loc == src.loc.loc && M.music == 0)
-// to_chat(world, "Found the song...")
- M << S
- M.music = 1
- else if(M.loc.loc != src.loc.loc && M.music == 1)
- var/sound/Soff = sound(null)
- Soff.channel = 10
- M << Soff
- M.music = 0
- sleep(10)
- return
-
-
- if( href_list["off"] )
- if(src.playing == 1)
- var/sound/S = sound(null)
- S.channel = 10
- S.wait = 1
- for(var/mob/M in world)
- M << S
- M.music = 0
- playing = 0
- var/area/A = src.loc.loc
- for(var/obj/machinery/party/lasermachine/L in A)
- L.turnoff()
-
-
-
-/obj/machinery/party/lasermachine
- name = "laser machine"
- desc = "A laser machine that shoots lasers."
- icon = 'icons/effects/lasers2.dmi'
- icon_state = "lasermachine"
- anchored = 1
- var/mirrored = 0
-
-/obj/effect/turntable_laser
- name = "laser"
- desc = "A laser..."
- icon = 'icons/effects/lasers2.dmi'
- icon_state = "laserred1"
- anchored = 1
- layer = 4
-
-/obj/item/lasermachine/New()
- ..()
-
-/obj/machinery/party/lasermachine/proc/turnon()
- var/wall = 0
- var/cycle = 1
- var/area/A = get_area(src)
- var/X = 1
- var/Y = 0
- if(mirrored == 0)
- while(wall == 0)
- if(cycle == 1)
- var/obj/effect/turntable_laser/F = new(src)
- F.x = src.x+X
- F.y = src.y+Y
- F.z = src.z
- F.icon_state = "laserred1"
- var/area/AA = get_area(F)
- var/turf/T = get_turf(F)
- if(T.density == 1 || AA.name != A.name)
- qdel(F)
- return
- cycle++
- if(cycle > 3)
- cycle = 1
- X++
- if(cycle == 2)
- var/obj/effect/turntable_laser/F = new(src)
- F.x = src.x+X
- F.y = src.y+Y
- F.z = src.z
- F.icon_state = "laserred2"
- var/area/AA = get_area(F)
- var/turf/T = get_turf(F)
- if(T.density == 1 || AA.name != A.name)
- qdel(F)
- return
- cycle++
- if(cycle > 3)
- cycle = 1
- Y++
- if(cycle == 3)
- var/obj/effect/turntable_laser/F = new(src)
- F.x = src.x+X
- F.y = src.y+Y
- F.z = src.z
- F.icon_state = "laserred3"
- var/area/AA = get_area(F)
- var/turf/T = get_turf(F)
- if(T.density == 1 || AA.name != A.name)
- qdel(F)
- return
- cycle++
- if(cycle > 3)
- cycle = 1
- X++
- if(mirrored == 1)
- while(wall == 0)
- if(cycle == 1)
- var/obj/effect/turntable_laser/F = new(src)
- F.x = src.x+X
- F.y = src.y-Y
- F.z = src.z
- F.icon_state = "laserred1m"
- var/area/AA = get_area(F)
- var/turf/T = get_turf(F)
- if(T.density == 1 || AA.name != A.name)
- qdel(F)
- return
- cycle++
- if(cycle > 3)
- cycle = 1
- Y++
- if(cycle == 2)
- var/obj/effect/turntable_laser/F = new(src)
- F.x = src.x+X
- F.y = src.y-Y
- F.z = src.z
- F.icon_state = "laserred2m"
- var/area/AA = get_area(F)
- var/turf/T = get_turf(F)
- if(T.density == 1 || AA.name != A.name)
- qdel(F)
- return
- cycle++
- if(cycle > 3)
- cycle = 1
- X++
- if(cycle == 3)
- var/obj/effect/turntable_laser/F = new(src)
- F.x = src.x+X
- F.y = src.y-Y
- F.z = src.z
- F.icon_state = "laserred3m"
- var/area/AA = get_area(F)
- var/turf/T = get_turf(F)
- if(T.density == 1 || AA.name != A.name)
- qdel(F)
- return
- cycle++
- if(cycle > 3)
- cycle = 1
- X++
-
-
-
-/obj/machinery/party/lasermachine/proc/turnoff()
- var/area/A = src.loc.loc
- for(var/obj/effect/turntable_laser/F in A)
- qdel(F)
diff --git a/code/game/mecha/equipment/tools/mining_tools.dm b/code/game/mecha/equipment/tools/mining_tools.dm
index 5916d0f96c7..2248c37f518 100644
--- a/code/game/mecha/equipment/tools/mining_tools.dm
+++ b/code/game/mecha/equipment/tools/mining_tools.dm
@@ -94,7 +94,7 @@
/obj/item/mecha_parts/mecha_equipment/drill/proc/drill_mob(mob/living/target, mob/user)
target.visible_message("[chassis] is drilling [target] with [src]!",
"[chassis] is drilling you with [src]!")
- add_attack_logs(user, target, "DRILLED with [src] (INTENT: [uppertext(user.a_intent)]) (DAMTYPE: [uppertext(damtype)])")
+ add_attack_logs(user, target, "DRILLED with [src] ([uppertext(user.a_intent)]) ([uppertext(damtype)])")
if(target.stat == DEAD && target.getBruteLoss() >= 200)
add_attack_logs(user, target, "gibbed")
if(LAZYLEN(target.butcher_results))
diff --git a/code/game/mecha/equipment/tools/work_tools.dm b/code/game/mecha/equipment/tools/work_tools.dm
index 63eeb21e165..5962a1eccbb 100644
--- a/code/game/mecha/equipment/tools/work_tools.dm
+++ b/code/game/mecha/equipment/tools/work_tools.dm
@@ -60,7 +60,7 @@
target.visible_message("[chassis] squeezes [target].", \
"[chassis] squeezes [target].",\
"You hear something crack.")
- add_attack_logs(chassis.occupant, M, "Squeezed with [src] (INTENT: [uppertext(chassis.occupant.a_intent)]) (DAMTYE: [uppertext(damtype)])")
+ add_attack_logs(chassis.occupant, M, "Squeezed with [src] ([uppertext(chassis.occupant.a_intent)]) ([uppertext(damtype)])")
start_cooldown()
else
step_away(M,chassis)
diff --git a/code/game/mecha/equipment/weapons/weapons.dm b/code/game/mecha/equipment/weapons/weapons.dm
index 9acdcba48de..e05fef18e5a 100644
--- a/code/game/mecha/equipment/weapons/weapons.dm
+++ b/code/game/mecha/equipment/weapons/weapons.dm
@@ -385,7 +385,7 @@
return
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/flashbang
- name = "SGL-6 Grenade Launcher"
+ name = "SGL-6 Flashbang Launcher"
icon_state = "mecha_grenadelnchr"
origin_tech = "combat=4;engineering=4"
projectile = /obj/item/grenade/flashbang
@@ -411,7 +411,7 @@
return
/obj/item/mecha_parts/mecha_equipment/weapon/ballistic/missile_rack/flashbang/clusterbang//Because I am a heartless bastard -Sieve
- name = "SOB-3 Grenade Launcher"
+ name = "SOB-3 Clusterbang Launcher"
desc = "A weapon for combat exosuits. Launches primed clusterbangs. You monster."
origin_tech = "combat=4;materials=4"
projectiles = 3
diff --git a/code/game/mecha/mecha.dm b/code/game/mecha/mecha.dm
index 90d466baf3e..69f70207452 100644
--- a/code/game/mecha/mecha.dm
+++ b/code/game/mecha/mecha.dm
@@ -1,3 +1,5 @@
+#define OCCUPANT_LOGGING occupant ? occupant : "empty mech"
+
/obj/mecha
name = "Mecha"
desc = "Exosuit"
@@ -37,6 +39,7 @@
var/lights_power = 6
var/emagged = FALSE
var/frozen = FALSE
+ var/repairing = FALSE
//inner atmos
var/use_internal_tank = 0
@@ -543,6 +546,7 @@
/obj/mecha/attack_alien(mob/living/user)
log_message("Attack by alien. Attacker - [user].", TRUE)
+ add_attack_logs(user, OCCUPANT_LOGGING, "Alien attacked mech [src]")
playsound(src.loc, 'sound/weapons/slash.ogg', 100, TRUE)
attack_generic(user, 15, BRUTE, "melee", 0)
@@ -560,8 +564,8 @@
if(user.obj_damage)
animal_damage = user.obj_damage
animal_damage = min(animal_damage, 20*user.environment_smash)
- user.create_attack_log("attacked [name]")
- add_attack_logs(user, src, "Attacked")
+ if(animal_damage)
+ add_attack_logs(user, OCCUPANT_LOGGING, "Animal attacked mech [src]")
attack_generic(user, animal_damage, user.melee_damage_type, "melee", play_soundeffect)
return TRUE
@@ -572,7 +576,7 @@
. = ..()
if(.)
log_message("Attack by hulk. Attacker - [user].", 1)
- add_attack_logs(user, src, "Punched with hulk powers")
+ add_attack_logs(user, OCCUPANT_LOGGING, "Hulk punched mech [src]")
/obj/mecha/blob_act(obj/structure/blob/B)
log_message("Attack by blob. Attacker - [B].")
@@ -583,10 +587,14 @@
/obj/mecha/hitby(atom/movable/AM, skipcatch, hitpush, blocked, datum/thrownthing/throwingdatum) //wrapper
log_message("Hit by [AM].")
+ if(isitem(AM))
+ var/obj/item/I = AM
+ add_attack_logs(I.thrownby, OCCUPANT_LOGGING, "threw [AM] at mech [src]")
. = ..()
/obj/mecha/bullet_act(obj/item/projectile/Proj) //wrapper
log_message("Hit by projectile. Type: [Proj.name]([Proj.flag]).")
+ add_attack_logs(Proj.firer, OCCUPANT_LOGGING, "shot [Proj.name]([Proj.flag]) at mech [src]")
..()
/obj/mecha/ex_act(severity, target)
@@ -773,6 +781,8 @@
to_chat(user, "You stop installing [M].")
else
+ if(W.force)
+ add_attack_logs(user, OCCUPANT_LOGGING, "attacked mech '[src]' using [W]")
return ..()
@@ -839,7 +849,11 @@
if((obj_integrity >= max_integrity) && !internal_damage)
to_chat(user, "[src] is at full integrity!")
return
+ if(repairing)
+ to_chat(user, "[src] is currently being repaired!")
+ return
WELDER_ATTEMPT_REPAIR_MESSAGE
+ repairing = TRUE
if(I.use_tool(src, user, 15, volume = I.tool_volume))
if(internal_damage & MECHA_INT_TANK_BREACH)
clearInternalDamage(MECHA_INT_TANK_BREACH)
@@ -849,13 +863,14 @@
obj_integrity += min(10, max_integrity - obj_integrity)
else
to_chat(user, "[src] is at full integrity!")
+ repairing = FALSE
/obj/mecha/mech_melee_attack(obj/mecha/M)
if(!has_charge(melee_energy_drain))
return 0
use_power(melee_energy_drain)
if(M.damtype == BRUTE || M.damtype == BURN)
- add_attack_logs(M.occupant, src, "Mecha-attacked with [M] (INTENT: [uppertext(M.occupant.a_intent)]) (DAMTYPE: [uppertext(M.damtype)])")
+ add_attack_logs(M.occupant, src, "Mecha-attacked with [M] ([uppertext(M.occupant.a_intent)]) ([uppertext(M.damtype)])")
. = ..()
/obj/mecha/emag_act(mob/user)
@@ -1258,6 +1273,9 @@
L.client.RemoveViewMod("mecha")
zoom_mode = FALSE
+/obj/mecha/force_eject_occupant()
+ go_out()
+
/////////////////////////
////// Access stuff /////
/////////////////////////
@@ -1528,3 +1546,5 @@
if(L.incapacitated())
return FALSE
return TRUE
+
+#undef OCCUPANT_LOGGING
diff --git a/code/game/objects/effects/decals/remains.dm b/code/game/objects/effects/decals/remains.dm
index 9a879a02da3..e750c15e761 100644
--- a/code/game/objects/effects/decals/remains.dm
+++ b/code/game/objects/effects/decals/remains.dm
@@ -28,6 +28,12 @@
icon_state = "remainsrobot"
anchored = TRUE
+/obj/effect/decal/remains/robot/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ C.stored_comms["glass"] += 2
+ C.stored_comms["metal"] += 3
+ qdel(src)
+ return TRUE
+
/obj/effect/decal/remains/slime
name = "You shouldn't see this"
desc = "Noooooooooooooooooooooo"
diff --git a/code/game/objects/effects/effect_system/effect_system.dm b/code/game/objects/effects/effect_system/effect_system.dm
index 5ae6b0c6860..9ae89309eed 100644
--- a/code/game/objects/effects/effect_system/effect_system.dm
+++ b/code/game/objects/effects/effect_system/effect_system.dm
@@ -49,6 +49,8 @@ would spawn and follow the beaker, even if it is carried or thrown.
holder = atom
/datum/effect_system/proc/start()
+ if(QDELETED(src))
+ return
for(var/i in 1 to number)
if(total_effects > 20)
return
@@ -68,7 +70,8 @@ would spawn and follow the beaker, even if it is carried or thrown.
for(var/j in 1 to steps_amt)
sleep(5)
step(E,direction)
- addtimer(CALLBACK(src, .proc/decrement_total_effect), 20)
+ if(!QDELETED(src))
+ addtimer(CALLBACK(src, .proc/decrement_total_effect), 20)
/datum/effect_system/proc/decrement_total_effect()
total_effects--
diff --git a/code/game/objects/effects/manifest.dm b/code/game/objects/effects/manifest.dm
index f267494496e..6ada54e75f7 100644
--- a/code/game/objects/effects/manifest.dm
+++ b/code/game/objects/effects/manifest.dm
@@ -10,7 +10,8 @@
/obj/effect/manifest/proc/manifest()
var/dat = "Crew Manifest: "
- for(var/mob/living/carbon/human/M in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/M = thing
dat += text(" [] - [] ", M.name, M.get_assignment())
var/obj/item/paper/P = new /obj/item/paper( src.loc )
P.info = dat
diff --git a/code/game/objects/effects/spiders.dm b/code/game/objects/effects/spiders.dm
index 7af5d7a998f..9dd1c771b17 100644
--- a/code/game/objects/effects/spiders.dm
+++ b/code/game/objects/effects/spiders.dm
@@ -190,6 +190,16 @@
to_chat(S, "You are a spider who is loyal to [S.master_commander], obey [S.master_commander]'s every order and assist [S.master_commander.p_them()] in completing [S.master_commander.p_their()] goals at any cost.")
qdel(src)
+/obj/structure/spider/spiderling/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ if(!istype(user, /mob/living/silicon/robot/drone))
+ user.visible_message("[user] sucks [src] into its decompiler. There's a horrible crunching noise.", \
+ "It's a bit of a struggle, but you manage to suck [user] into your decompiler. It makes a series of visceral crunching noises.")
+ C.stored_comms["wood"] += 2
+ C.stored_comms["glass"] += 2
+ qdel(src)
+ return TRUE
+ return ..()
+
/obj/effect/decal/cleanable/spiderling_remains
name = "spiderling remains"
desc = "Green squishy mess."
diff --git a/code/game/objects/items.dm b/code/game/objects/items.dm
index 76361776b0a..baaf0cab16b 100644
--- a/code/game/objects/items.dm
+++ b/code/game/objects/items.dm
@@ -506,7 +506,7 @@ GLOBAL_DATUM_INIT(fire_overlay, /image, image("icon" = 'icons/goonstation/effect
"You stab yourself in the eyes with [src]!" \
)
- add_attack_logs(user, M, "Eye-stabbed with [src] (INTENT: [uppertext(user.a_intent)])")
+ add_attack_logs(user, M, "Eye-stabbed with [src] ([uppertext(user.a_intent)])")
if(istype(H))
var/obj/item/organ/internal/eyes/eyes = H.get_int_organ(/obj/item/organ/internal/eyes)
diff --git a/code/game/objects/items/devices/airlock_painter.dm b/code/game/objects/items/devices/airlock_painter.dm
new file mode 100644
index 00000000000..8f845f2bac6
--- /dev/null
+++ b/code/game/objects/items/devices/airlock_painter.dm
@@ -0,0 +1,81 @@
+// Airlock painter
+
+/obj/item/airlock_painter
+ name = "airlock painter"
+ desc = "An advanced autopainter preprogrammed with several paintjobs for airlocks. Use it on a completed airlock to change its paintjob."
+ icon = 'icons/obj/device.dmi'
+ icon_state = "airlock_painter"
+ item_state = "airlock_painter"
+ flags = CONDUCT | NOBLUDGEON
+ usesound = 'sound/effects/spray2.ogg'
+ w_class = WEIGHT_CLASS_SMALL
+ slot_flags = SLOT_BELT
+ materials = list(MAT_METAL = 3000, MAT_GLASS = 1000)
+ var/paint_setting
+
+ // All the different paint jobs that an airlock painter can apply.
+ // If the airlock you're using it on is glass, the new paint job will also be glass
+ var/list/available_paint_jobs = list(
+ "Atmospherics" = /obj/machinery/door/airlock/atmos,
+ "Command" = /obj/machinery/door/airlock/command,
+ "Engineering" = /obj/machinery/door/airlock/engineering,
+ "External" = /obj/machinery/door/airlock/external,
+ "External Maintenance"= /obj/machinery/door/airlock/maintenance/external,
+ "Freezer" = /obj/machinery/door/airlock/freezer,
+ "Maintenance" = /obj/machinery/door/airlock/maintenance,
+ "Medical" = /obj/machinery/door/airlock/medical,
+ "Mining" = /obj/machinery/door/airlock/mining,
+ "Public" = /obj/machinery/door/airlock/public,
+ "Research" = /obj/machinery/door/airlock/research,
+ "Science" = /obj/machinery/door/airlock/science,
+ "Security" = /obj/machinery/door/airlock/security,
+ "Standard" = /obj/machinery/door/airlock,
+ )
+
+//Only call this if you are certain that the painter will be used right after this check!
+/obj/item/airlock_painter/proc/paint(mob/user)
+ playsound(loc, usesound, 30, TRUE)
+ return TRUE
+
+/obj/item/airlock_painter/attack_self(mob/user)
+ paint_setting = input(user, "Please select a paintjob for this airlock.") as null|anything in available_paint_jobs
+ if(!paint_setting)
+ return
+ to_chat(user, "The [paint_setting] paint setting has been selected.")
+
+/obj/item/airlock_painter/suicide_act(mob/user)
+
+ var/obj/item/organ/internal/lungs/L = user.get_organ_slot("lungs")
+ var/lungs_name = "\improper[L.name]"
+
+ if(L)
+ user.visible_message("[user] is inhaling toner from [src]! It looks like [user.p_theyre()] trying to commit suicide!")
+ // Once you've inhaled the toner, you throw up your lungs
+ // and then die.
+
+ // they managed to lose their lungs between then and now. Good job.
+ if(!L)
+ return FALSE
+
+ L.remove(user)
+
+ // make some colorful reagent, and apply it to the lungs
+ L.create_reagents(10)
+ L.reagents.add_reagent("colorful_reagent", 10)
+ L.reagents.reaction(L, REAGENT_TOUCH, 1)
+
+ user.emote("scream")
+ user.visible_message("[user] vomits out [user.p_their()] [lungs_name]!")
+ playsound(user.loc, 'sound/effects/splat.ogg', 50, TRUE)
+
+ // make some vomit under the player, and apply colorful reagent
+ var/obj/effect/decal/cleanable/vomit/V = new(get_turf(user))
+ V.create_reagents(10)
+ V.reagents.add_reagent("colorful_reagent", 10)
+ V.reagents.reaction(V, REAGENT_TOUCH, 1)
+
+ L.forceMove(get_turf(user))
+
+ return OXYLOSS
+ else
+ return SHAME
diff --git a/code/game/objects/items/devices/megaphone.dm b/code/game/objects/items/devices/megaphone.dm
index 941e90a31ef..c6fa7b20c66 100644
--- a/code/game/objects/items/devices/megaphone.dm
+++ b/code/game/objects/items/devices/megaphone.dm
@@ -33,8 +33,6 @@
if(H && H.mind && H.mind.miming)
to_chat(user, "Your vow of silence prevents you from speaking.")
return
- if(H.mind)
- span = H.mind.speech_span
if((COMIC in H.mutations) || H.get_int_organ(/obj/item/organ/internal/cyberimp/brain/clown_voice))
span = "sans"
if(spamcheck)
diff --git a/code/game/objects/items/devices/paicard.dm b/code/game/objects/items/devices/paicard.dm
index b3695229790..42c134736d7 100644
--- a/code/game/objects/items/devices/paicard.dm
+++ b/code/game/objects/items/devices/paicard.dm
@@ -18,13 +18,6 @@
name = "syndicate personal AI device"
faction = list("syndicate")
-/obj/item/paicard/relaymove(var/mob/user, var/direction)
- if(user.stat || user.stunned)
- return
- var/obj/item/rig/rig = get_rig()
- if(istype(rig))
- rig.forced_move(direction, user)
-
/obj/item/paicard/New()
..()
overlays += "pai-off"
diff --git a/code/game/objects/items/devices/radio/radio.dm b/code/game/objects/items/devices/radio/radio.dm
index 009ec01ef43..b497bc518b0 100644
--- a/code/game/objects/items/devices/radio/radio.dm
+++ b/code/game/objects/items/devices/radio/radio.dm
@@ -226,7 +226,7 @@ GLOBAL_LIST_INIT(default_medbay_channels, list(
channels[chan_name] |= FREQ_LISTENING
. = 1
else if(href_list["spec_freq"])
- var freq = href_list["spec_freq"]
+ var/freq = href_list["spec_freq"]
if(has_channel_access(usr, freq))
set_frequency(text2num(freq))
. = 1
@@ -272,7 +272,7 @@ GLOBAL_LIST_INIT(default_medbay_channels, list(
tcm.sender_job = "Automated Announcement"
tcm.vname = "synthesized voice"
tcm.data = SIGNALTYPE_AINOTRACK
- // Datum radios dont have a location (obviously
+ // Datum radios dont have a location (obviously)
if(loc && loc.z)
tcm.source_level = loc.z // For anyone that reads this: This used to pull from a LIST from the CONFIG DATUM. WHYYYYYYYYY!!!!!!!! -aa
else
@@ -411,11 +411,16 @@ GLOBAL_LIST_INIT(default_medbay_channels, list(
jobname = "Unknown"
voicemask = TRUE
+ // Copy the message pieces so we can safely edit comms line without affecting the actual line
+ var/list/message_pieces_copy = list()
+ for(var/datum/multilingual_say_piece/S in message_pieces)
+ message_pieces_copy += new /datum/multilingual_say_piece(S.speaking, S.message)
+
// Make us a message datum!
var/datum/tcomms_message/tcm = new
tcm.sender_name = displayname
tcm.sender_job = jobname
- tcm.message_pieces = message_pieces
+ tcm.message_pieces = message_pieces_copy
tcm.source_level = position.z
tcm.freq = connection.frequency
tcm.vmask = voicemask
diff --git a/code/game/objects/items/devices/sensor_device.dm b/code/game/objects/items/devices/sensor_device.dm
index b83128cf4a5..9133bf37b9c 100644
--- a/code/game/objects/items/devices/sensor_device.dm
+++ b/code/game/objects/items/devices/sensor_device.dm
@@ -19,5 +19,5 @@
/obj/item/sensor_device/attack_self(mob/user as mob)
tgui_interact(user)
-/obj/item/sensor_device/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
+/obj/item/sensor_device/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = FALSE, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
crew_monitor.tgui_interact(user, ui_key, ui, force_open)
diff --git a/code/game/objects/items/robot/robot_items.dm b/code/game/objects/items/robot/robot_items.dm
index eae59151a38..f1487a09986 100644
--- a/code/game/objects/items/robot/robot_items.dm
+++ b/code/game/objects/items/robot/robot_items.dm
@@ -29,7 +29,7 @@
"[user] has prodded you with [src]!")
playsound(loc, 'sound/weapons/egloves.ogg', 50, 1, -1)
- add_attack_logs(user, M, "Stunned with [src] (INTENT: [uppertext(user.a_intent)])")
+ add_attack_logs(user, M, "Stunned with [src] ([uppertext(user.a_intent)])")
/obj/item/borg/overdrive
name = "Overdrive"
diff --git a/code/game/objects/items/robot/robot_parts.dm b/code/game/objects/items/robot/robot_parts.dm
index 46bc15a2ffe..ca2fb17c004 100644
--- a/code/game/objects/items/robot/robot_parts.dm
+++ b/code/game/objects/items/robot/robot_parts.dm
@@ -253,7 +253,16 @@
to_chat(user, "This [W] does not seem to fit.")
return
- var/mob/living/silicon/robot/O = new /mob/living/silicon/robot(get_turf(loc), unfinished = 1)
+ var/datum/ai_laws/laws_to_give
+ if(M.syndiemmi)
+ aisync = FALSE
+ lawsync = FALSE
+ laws_to_give = new /datum/ai_laws/syndicate_override
+
+ if(!aisync)
+ lawsync = FALSE
+
+ var/mob/living/silicon/robot/O = new /mob/living/silicon/robot(get_turf(loc), unfinished = 1, ai_to_sync_to = forced_ai)
if(!O)
return
@@ -263,24 +272,15 @@
if(istype(task))
task.unit_completed()
- if(M.syndiemmi)
- aisync = 0
- lawsync = 0
- O.laws = new /datum/ai_laws/syndicate_override
-
O.invisibility = 0
//Transfer debug settings to new mob
O.custom_name = created_name
O.rename_character(O.real_name, O.get_default_name())
O.locked = panel_locked
- if(!aisync)
- lawsync = 0
- O.connected_ai = null
- else
- O.notify_ai(1)
- if(forced_ai)
- O.connected_ai = forced_ai
- if(!lawsync && !M.syndiemmi)
+
+ if(laws_to_give)
+ O.laws = laws_to_give
+ else if(!lawsync)
O.lawupdate = 0
O.make_laws()
diff --git a/code/game/objects/items/stacks/sheets/glass.dm b/code/game/objects/items/stacks/sheets/glass.dm
index 4d3e3181726..000ad2d225f 100644
--- a/code/game/objects/items/stacks/sheets/glass.dm
+++ b/code/game/objects/items/stacks/sheets/glass.dm
@@ -17,9 +17,9 @@
GLOBAL_LIST_INIT(glass_recipes, list ( \
new/datum/stack_recipe/window("directional window", /obj/structure/window/basic, time = 0, on_floor = TRUE, window_checks = TRUE), \
new/datum/stack_recipe/window("fulltile window", /obj/structure/window/full/basic, 2, time = 0, on_floor = TRUE, window_checks = TRUE), \
- new/datum/stack_recipe("fishbowl", /obj/machinery/fishtank/bowl, 1, time = 0), \
- new/datum/stack_recipe("fish tank", /obj/machinery/fishtank/tank, 3, time = 0, on_floor = TRUE), \
- new/datum/stack_recipe("wall aquariam", /obj/machinery/fishtank/wall, 4, time = 0, on_floor = TRUE) \
+ new/datum/stack_recipe("fishbowl", /obj/machinery/fishtank/bowl, 1, time = 10), \
+ new/datum/stack_recipe("fish tank", /obj/machinery/fishtank/tank, 3, time = 20, on_floor = TRUE), \
+ new/datum/stack_recipe("wall aquariam", /obj/machinery/fishtank/wall, 4, time = 40, on_floor = TRUE) \
))
/obj/item/stack/sheet/glass
diff --git a/code/game/objects/items/stacks/sheets/leather.dm b/code/game/objects/items/stacks/sheets/leather.dm
index 6bdfdd49234..9f6844c8b9e 100644
--- a/code/game/objects/items/stacks/sheets/leather.dm
+++ b/code/game/objects/items/stacks/sheets/leather.dm
@@ -242,7 +242,7 @@ GLOBAL_LIST_INIT(sinew_recipes, list ( \
HS.amount++
src.use(1)
wetness = initial(wetness)
- break
+ return
//If it gets to here it means it did not find a suitable stack on the tile.
var/obj/item/stack/sheet/leather/HS = new(src.loc)
HS.amount = 1
diff --git a/code/game/objects/items/stacks/sheets/mineral.dm b/code/game/objects/items/stacks/sheets/mineral.dm
index 54d42176f52..9dabea08319 100644
--- a/code/game/objects/items/stacks/sheets/mineral.dm
+++ b/code/game/objects/items/stacks/sheets/mineral.dm
@@ -218,10 +218,22 @@ GLOBAL_LIST_INIT(sandbag_recipes, list ( \
/obj/item/stack/sheet/mineral/plasma/welder_act(mob/user, obj/item/I)
if(I.use_tool(src, user, volume = I.tool_volume))
- message_admins("Plasma sheets ignited by [key_name_admin(user)]([ADMIN_QUE(user,"?")]) ([ADMIN_FLW(user,"FLW")]) in ([x],[y],[z] - JMP)",0,1)
- log_game("Plasma sheets ignited by [key_name(user)] in ([x],[y],[z])")
- investigate_log("was ignited by [key_name(user)]","atmos")
- fire_act()
+ log_and_set_aflame(user, I)
+ return TRUE
+
+/obj/item/stack/sheet/mineral/plasma/attackby(obj/item/I, mob/living/user, params)
+ if(is_hot(I))
+ log_and_set_aflame(user, I)
+ else
+ return ..()
+
+/obj/item/stack/sheet/mineral/plasma/proc/log_and_set_aflame(mob/user, obj/item/I)
+ var/turf/T = get_turf(src)
+ message_admins("Plasma sheets ignited by [key_name_admin(user)]([ADMIN_QUE(user, "?")]) ([ADMIN_FLW(user, "FLW")]) in ([COORD(T)] - [ADMIN_JMP(T)]")
+ log_game("Plasma sheets ignited by [key_name(user)] in [COORD(T)]")
+ investigate_log("was ignited by [key_name(user)]", "atmos")
+ user.create_log(MISC_LOG, "Plasma sheets ignited using [I]", src)
+ fire_act()
/obj/item/stack/sheet/mineral/plasma/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume, global_overlay = TRUE)
..()
diff --git a/code/game/objects/items/trash.dm b/code/game/objects/items/trash.dm
index 7cf48095e72..8508c741524 100644
--- a/code/game/objects/items/trash.dm
+++ b/code/game/objects/items/trash.dm
@@ -8,6 +8,13 @@
desc = "This is rubbish."
resistance_flags = FLAMMABLE
+/obj/item/trash/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ C.stored_comms["metal"] += 2
+ C.stored_comms["wood"] += 1
+ C.stored_comms["glass"] += 1
+ qdel(src)
+ return TRUE
+
/obj/item/trash/raisins
name = "4no raisins"
icon_state= "4no_raisins"
diff --git a/code/game/objects/items/weapons/RSF.dm b/code/game/objects/items/weapons/RSF.dm
index a8da7503c72..26cef27a0b4 100644
--- a/code/game/objects/items/weapons/RSF.dm
+++ b/code/game/objects/items/weapons/RSF.dm
@@ -58,7 +58,7 @@ RSF
if(!proximity) return
if(!(istype(A, /obj/structure/table) || istype(A, /turf/simulated/floor)))
return
- var spawn_location
+ var/spawn_location
var/turf/T = get_turf(A)
if(istype(T) && !T.density)
spawn_location = T
diff --git a/code/game/objects/items/weapons/cards_ids.dm b/code/game/objects/items/weapons/cards_ids.dm
index 405ce47a033..dc26b14e24b 100644
--- a/code/game/objects/items/weapons/cards_ids.dm
+++ b/code/game/objects/items/weapons/cards_ids.dm
@@ -356,13 +356,13 @@
/obj/item/card/id/syndicate/attack_self(mob/user as mob)
if(!src.registered_name)
- var t = reject_bad_name(input(user, "What name would you like to use on this card?", "Agent Card name", ishuman(user) ? user.real_name : user.name))
+ var/t = reject_bad_name(input(user, "What name would you like to use on this card?", "Agent Card name", ishuman(user) ? user.real_name : user.name))
if(!t)
to_chat(user, "Invalid name.")
return
src.registered_name = t
- var u = sanitize(stripped_input(user, "What occupation would you like to put on this card?\nNote: This will not grant any access levels other than maintenance.", "Agent Card Job Assignment", "Agent", MAX_MESSAGE_LEN))
+ var/u = sanitize(stripped_input(user, "What occupation would you like to put on this card?\nNote: This will not grant any access levels other than maintenance.", "Agent Card Job Assignment", "Agent", MAX_MESSAGE_LEN))
if(!u)
to_chat(user, "Invalid assignment.")
src.registered_name = ""
diff --git a/code/game/objects/items/weapons/cigs.dm b/code/game/objects/items/weapons/cigs.dm
index 8c2c3e85917..30ad91beffa 100644
--- a/code/game/objects/items/weapons/cigs.dm
+++ b/code/game/objects/items/weapons/cigs.dm
@@ -311,6 +311,11 @@ LIGHTERS ARE IN LIGHTERS.DM
pixel_y = rand(-10,10)
transform = turn(transform,rand(0,360))
+/obj/item/cigbutt/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ C.stored_comms["wood"] += 1
+ qdel(src)
+ return TRUE
+
/obj/item/cigbutt/cigarbutt
name = "cigar butt"
desc = "A manky old cigar butt."
diff --git a/code/game/objects/items/weapons/cosmetics.dm b/code/game/objects/items/weapons/cosmetics.dm
index 8815ad6a20f..42f65141094 100644
--- a/code/game/objects/items/weapons/cosmetics.dm
+++ b/code/game/objects/items/weapons/cosmetics.dm
@@ -5,16 +5,22 @@
icon_state = "lipstick"
w_class = WEIGHT_CLASS_TINY
var/colour = "red"
- var/open = 0
- var/list/lipstick_colors = list(
- "purple" = "purple",
- "jade" = "#216F43",
- "lime" = "lime",
- "black" = "black",
- "green" = "green",
- "blue" = "blue",
- "white" = "white")
+ var/open = FALSE
+ var/static/list/lipstick_colors
+/obj/item/lipstick/Initialize(mapload)
+ . = ..()
+ if(!lipstick_colors)
+ lipstick_colors = list(
+ "black" = "#000000",
+ "white" = "#FFFFFF",
+ "red" = "#FF0000",
+ "green" = "#00C000",
+ "blue" = "#0000FF",
+ "purple" = "#D55CD0",
+ "jade" = "#216F43",
+ "lime" = "#00FF00",
+ )
/obj/item/lipstick/purple
name = "purple lipstick"
@@ -22,7 +28,7 @@
/obj/item/lipstick/jade
name = "jade lipstick"
- colour = "#216F43"
+ colour = "jade"
/obj/item/lipstick/lime
name = "lime lipstick"
@@ -47,40 +53,38 @@
/obj/item/lipstick/random
name = "lipstick"
-/obj/item/lipstick/random/New()
- ..()
- var/lscolor = pick(lipstick_colors)//A random color is picked from the var defined initially in a new var.
- colour = lipstick_colors[lscolor]//The color of the lipstick is pulled from the new variable (right hand side, HTML & Hex RGB)
- name = "[lscolor] lipstick"//The new variable is also used to match the name to the color of the lipstick. Kudos to Desolate & Lemon
+/obj/item/lipstick/random/Initialize(mapload)
+ . = ..()
+ var/lscolor = pick(lipstick_colors) // A random color is picked from the var defined initially in a new var.
+ colour = lipstick_colors[lscolor] // The color of the lipstick is pulled from the new variable (right hand side, HTML & Hex RGB)
+ name = "[lscolor] lipstick" // The new variable is also used to match the name to the color of the lipstick. Kudos to Desolate & Lemon
-
-/obj/item/lipstick/attack_self(mob/user as mob)
- overlays.Cut()
+/obj/item/lipstick/attack_self(mob/user)
+ cut_overlays()
to_chat(user, "You twist \the [src] [open ? "closed" : "open"].")
open = !open
if(open)
- var/image/colored = image("icon"='icons/obj/items.dmi', "icon_state"="lipstick_uncap_color")
- colored.color = colour
+ var/image/colored = mutable_appearance('icons/obj/items.dmi', "lipstick_uncap_color")
+ colored.color = lipstick_colors[colour]
icon_state = "lipstick_uncap"
- overlays += colored
+ add_overlay(colored)
else
icon_state = "lipstick"
-/obj/item/lipstick/attack(mob/M as mob, mob/user as mob)
- if(!open) return
-
- if(!istype(M, /mob)) return
+/obj/item/lipstick/attack(mob/M, mob/user)
+ if(!open || !istype(M))
+ return
if(ishuman(M))
var/mob/living/carbon/human/H = M
- if(H.lip_style) //if they already have lipstick on
+ if(H.lip_style) // If they already have lipstick on
to_chat(user, "You need to wipe off the old lipstick first!")
return
if(H == user)
user.visible_message("[user] does [user.p_their()] lips with [src].", \
"You take a moment to apply [src]. Perfect!")
H.lip_style = "lipstick"
- H.lip_color = colour
+ H.lip_color = lipstick_colors[colour]
H.update_body()
else
user.visible_message("[user] begins to do [H]'s lips with \the [src].", \
@@ -89,7 +93,7 @@
user.visible_message("[user] does [H]'s lips with \the [src].", \
"You apply \the [src].")
H.lip_style = "lipstick"
- H.lip_color = colour
+ H.lip_color = lipstick_colors[colour]
H.update_body()
else
to_chat(user, "Where are the lips on that?")
diff --git a/code/game/objects/items/weapons/holy_weapons.dm b/code/game/objects/items/weapons/holy_weapons.dm
index 4efb6994e8d..6423bbeb6ff 100644
--- a/code/game/objects/items/weapons/holy_weapons.dm
+++ b/code/game/objects/items/weapons/holy_weapons.dm
@@ -488,7 +488,7 @@
var/mob/living/carbon/human/holder = loc
if(src == holder.l_hand || src == holder.r_hand) // Holding this in your hand will
for(var/mob/living/carbon/human/H in range(5, loc))
- if(H.mind.vampire && !H.mind.vampire.get_ability(/datum/vampire_passive/full))
+ if(H.mind && H.mind.vampire && !H.mind.vampire.get_ability(/datum/vampire_passive/full))
H.mind.vampire.nullified = max(5, H.mind.vampire.nullified + 2)
if(prob(10))
to_chat(H, "Being in the presence of [holder]'s [src] is interfering with your powers!")
diff --git a/code/game/objects/items/weapons/lighters.dm b/code/game/objects/items/weapons/lighters.dm
index 740079db8e1..1bfeeabae03 100644
--- a/code/game/objects/items/weapons/lighters.dm
+++ b/code/game/objects/items/weapons/lighters.dm
@@ -244,12 +244,18 @@
else
..()
+/obj/item/match/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ if(burnt)
+ C.stored_comms["wood"] += 1
+ qdel(src)
+ return TRUE
+ return ..()
+
/obj/item/proc/help_light_cig(mob/living/M)
var/mask_item = M.get_item_by_slot(slot_wear_mask)
if(istype(mask_item, /obj/item/clothing/mask/cigarette))
return mask_item
-
/obj/item/match/firebrand
name = "firebrand"
desc = "An unlit firebrand. It makes you wonder why it's not just called a stick."
diff --git a/code/game/objects/items/weapons/manuals.dm b/code/game/objects/items/weapons/manuals.dm
index d91bb29ff76..bab2ff02fbb 100644
--- a/code/game/objects/items/weapons/manuals.dm
+++ b/code/game/objects/items/weapons/manuals.dm
@@ -5,6 +5,7 @@
icon = 'icons/obj/library.dmi'
due_date = 0 // Game time in 1/10th seconds
unique = 1 // 0 - Normal book, 1 - Should not be treated as normal book, unable to be copied, unable to be modified
+ has_drm = TRUE // No reuploading. Piracy is a crime
/obj/item/book/manual/engineering_construction
diff --git a/code/game/objects/items/weapons/shards.dm b/code/game/objects/items/weapons/shards.dm
index 52c2aea5ddb..6daabffe000 100644
--- a/code/game/objects/items/weapons/shards.dm
+++ b/code/game/objects/items/weapons/shards.dm
@@ -88,6 +88,11 @@
playsound(loc, 'sound/effects/glass_step.ogg', 50, TRUE)
return ..()
+/obj/item/shard/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ C.stored_comms["glass"] += 3
+ qdel(src)
+ return TRUE
+
/obj/item/shard/plasma
name = "plasma shard"
desc = "A shard of plasma glass. Considerably tougher then normal glass shards. Apparently not tough enough to be a window."
diff --git a/code/game/objects/items/weapons/storage/bags.dm b/code/game/objects/items/weapons/storage/bags.dm
index 4a449069d4c..6d5a192c641 100644
--- a/code/game/objects/items/weapons/storage/bags.dm
+++ b/code/game/objects/items/weapons/storage/bags.dm
@@ -421,13 +421,13 @@
/obj/item/storage/bag/tray/cyborg/afterattack(atom/target, mob/user as mob)
if( isturf(target) || istype(target,/obj/structure/table) )
- var foundtable = istype(target,/obj/structure/table/)
+ var/foundtable = istype(target,/obj/structure/table/)
if( !foundtable ) //it must be a turf!
for(var/obj/structure/table/T in target)
foundtable = 1
break
- var turf/dropspot
+ var/turf/dropspot
if( !foundtable ) // don't unload things onto walls or other silly places.
dropspot = user.loc
else if( isturf(target) ) // they clicked on a turf with a table in it
@@ -437,7 +437,7 @@
overlays = null
- var droppedSomething = 0
+ var/droppedSomething = 0
for(var/obj/item/I in contents)
I.loc = dropspot
diff --git a/code/game/objects/items/weapons/storage/fancy.dm b/code/game/objects/items/weapons/storage/fancy.dm
index f0ab5bd5ac7..37f568fa51a 100644
--- a/code/game/objects/items/weapons/storage/fancy.dm
+++ b/code/game/objects/items/weapons/storage/fancy.dm
@@ -215,6 +215,13 @@
//if we get this far, handle the insertion checks as normal
.=..()
+/obj/item/storage/fancy/cigarettes/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ if(!length(contents))
+ C.stored_comms["wood"] += 1
+ qdel(src)
+ return TRUE
+ return ..()
+
/obj/item/storage/fancy/cigarettes/dromedaryco
name = "\improper DromedaryCo packet"
desc = "A packet of six imported DromedaryCo cancer sticks. A label on the packaging reads, \"Wouldn't a slow death make a change?\""
diff --git a/code/game/objects/items/weapons/storage/firstaid.dm b/code/game/objects/items/weapons/storage/firstaid.dm
index 4ff769a7d3f..1e22015bc97 100644
--- a/code/game/objects/items/weapons/storage/firstaid.dm
+++ b/code/game/objects/items/weapons/storage/firstaid.dm
@@ -205,7 +205,7 @@
if(empty)
return
new /obj/item/reagent_containers/hypospray/combat(src)
- new /obj/item/reagent_containers/applicator/dual(src) // Because you ain't got no time to look at what damage dey taking yo
+ new /obj/item/reagent_containers/applicator/dual/syndi(src) // Because you ain't got no time to look at what damage dey taking yo
new /obj/item/defibrillator/compact/combat/loaded(src)
new /obj/item/clothing/glasses/hud/health/night(src)
diff --git a/code/game/objects/items/weapons/storage/storage.dm b/code/game/objects/items/weapons/storage/storage.dm
index 55b25ad725a..16bd6f4caa8 100644
--- a/code/game/objects/items/weapons/storage/storage.dm
+++ b/code/game/objects/items/weapons/storage/storage.dm
@@ -541,7 +541,7 @@
return depth
/obj/item/storage/serialize()
- var data = ..()
+ var/data = ..()
var/list/content_list = list()
data["content"] = content_list
data["slots"] = storage_slots
diff --git a/code/game/objects/items/weapons/tanks/jetpack.dm b/code/game/objects/items/weapons/tanks/jetpack.dm
index bc783457e76..edf32e2f5a6 100644
--- a/code/game/objects/items/weapons/tanks/jetpack.dm
+++ b/code/game/objects/items/weapons/tanks/jetpack.dm
@@ -219,28 +219,3 @@
turn_off(cur_user)
return
..()
-
-/obj/item/tank/jetpack/rig
- name = "jetpack"
- var/obj/item/rig/holder
- actions_types = list(/datum/action/item_action/toggle_jetpack, /datum/action/item_action/jetpack_stabilization)
-
-/obj/item/tank/jetpack/rig/examine()
- . = list("It's a jetpack. If you can see this, report it on the bug tracker.")
-
-/obj/item/tank/jetpack/rig/allow_thrust(num, mob/living/user)
- if(!on)
- return 0
-
- if(!istype(holder) || !holder.air_supply)
- return 0
-
- var/datum/gas_mixture/removed = holder.air_supply.air_contents.remove(num)
- if(removed.total_moles() < 0.005)
- turn_off(user)
- return 0
-
- var/turf/T = get_turf(user)
- T.assume_air(removed)
-
- return 1
diff --git a/code/game/objects/objs.dm b/code/game/objects/objs.dm
index d40c628ed90..7a56c53f73a 100644
--- a/code/game/objects/objs.dm
+++ b/code/game/objects/objs.dm
@@ -351,3 +351,9 @@ a {
/obj/proc/check_uplink_validity()
return TRUE
+
+/obj/proc/force_eject_occupant()
+ // This proc handles safely removing occupant mobs from the object if they must be teleported out (due to being SSD/AFK, by admin teleport, etc) or transformed.
+ // In the event that the object doesn't have an overriden version of this proc to do it, log a runtime so one can be added.
+ CRASH("Proc force_eject_occupant() is not overriden on a machine containing a mob.")
+
diff --git a/code/game/objects/structures/crates_lockers/closets.dm b/code/game/objects/structures/crates_lockers/closets.dm
index 04373502832..6db1846e872 100644
--- a/code/game/objects/structures/crates_lockers/closets.dm
+++ b/code/game/objects/structures/crates_lockers/closets.dm
@@ -354,6 +354,11 @@
/obj/structure/closet/AllowDrop()
return TRUE
+/obj/structure/closet/force_eject_occupant()
+ // Its okay to silently teleport mobs out of lockers, since the only thing affected is their contents list.
+ return
+
+
/obj/structure/closet/bluespace
name = "bluespace closet"
desc = "A storage unit that moves and stores through the fourth dimension."
diff --git a/code/game/objects/structures/girders.dm b/code/game/objects/structures/girders.dm
index 5fea799ecb0..6d27b21e686 100644
--- a/code/game/objects/structures/girders.dm
+++ b/code/game/objects/structures/girders.dm
@@ -76,14 +76,14 @@
if(istype(W,/obj/item/stack/rods))
var/obj/item/stack/rods/S = W
if(state == GIRDER_DISPLACED)
- if(S.get_amount() < 2)
- to_chat(user, "You need at least two rods to create a false wall!")
+ if(S.get_amount() < 5)
+ to_chat(user, "You need at least five rods to create a false wall!")
return
to_chat(user, "You start building a reinforced false wall...")
if(do_after(user, 20, target = src))
- if(!loc || !S || S.get_amount() < 2)
+ if(!loc || !S || S.get_amount() < 5)
return
- S.use(2)
+ S.use(5)
to_chat(user, "You create a false wall. Push on it to open or close the passage.")
var/obj/structure/falsewall/iron/FW = new (loc)
transfer_fingerprints_to(FW)
diff --git a/code/game/objects/structures/kitchen_spike.dm b/code/game/objects/structures/kitchen_spike.dm
index 1f0d4b8b473..c3f36e42f1d 100644
--- a/code/game/objects/structures/kitchen_spike.dm
+++ b/code/game/objects/structures/kitchen_spike.dm
@@ -69,9 +69,9 @@
if(isliving(G.affecting))
if(!has_buckled_mobs())
if(do_mob(user, src, 120))
- if(spike(G.affecting))
- G.affecting.visible_message("[user] slams [G.affecting] onto the meat spike!", "[user] slams you onto the meat spike!", "You hear a squishy wet noise.")
- qdel(G)
+ var/mob/living/affected = G.affecting
+ if(spike(affected))
+ affected.visible_message("[user] slams [affected] onto the meat spike!", "[user] slams you onto the meat spike!", "You hear a squishy wet noise.")
return
return ..()
diff --git a/code/game/objects/structures/statues.dm b/code/game/objects/structures/statues.dm
index 80fd69597c4..22449bb547b 100644
--- a/code/game/objects/structures/statues.dm
+++ b/code/game/objects/structures/statues.dm
@@ -288,6 +288,28 @@
return
setDir(turn(dir, 90))
+/obj/structure/statue/kidanstatue
+ name = "Obsidian Kidan warrior statue"
+ desc = "A beautifully carved and menacing statue of a Kidan warrior made out of obsidian. It looks very heavy."
+ icon_state = "kidan"
+ anchored = TRUE
+ oreAmount = 0
+
+/obj/structure/statue/chickenstatue
+ name = "Bronze Chickenman Statue"
+ desc = "An antique and oriental-looking statue of a Chickenman made of bronze."
+ icon_state = "chicken"
+ anchored = TRUE
+ oreAmount = 0
+
+/obj/structure/statue/russian_mulebot
+ desc = "Like a MULEbot, but more Russian and less functional.";
+ icon = 'icons/obj/aibots.dmi';
+ icon_state = "mulebot0";
+ name = "OXENbot"
+ anchored = TRUE
+ oreAmount = 10
+
////////////////////////////////
/obj/structure/snowman
@@ -320,19 +342,3 @@
..()
qdel(src)
-
-/obj/structure/kidanstatue
- name = "Obsidian Kidan warrior statue"
- desc = "A beautifully carved and menacing statue of a Kidan warrior made out of obsidian. It looks very heavy."
- icon = 'icons/obj/decorations.dmi'
- icon_state = "kidanstatue"
- anchored = 1
- density = 1
-
-/obj/structure/chickenstatue
- name = "Bronze Chickenman Statue"
- desc = "An antique and oriental-looking statue of a Chickenman made of bronze."
- icon = 'icons/obj/decorations.dmi'
- icon_state = "chickenstatue"
- anchored = 1
- density = 1
diff --git a/code/game/turfs/simulated/minerals.dm b/code/game/turfs/simulated/minerals.dm
index ebad3554f18..8bf3e820d3d 100644
--- a/code/game/turfs/simulated/minerals.dm
+++ b/code/game/turfs/simulated/minerals.dm
@@ -439,7 +439,7 @@
var/area/A = get_area(bombturf)
var/notify_admins = 0
- if(z != 5)
+ if(!is_mining_level(z))
notify_admins = 1
if(!triggered_by_explosion)
message_admins("[key_name_admin(user)] has triggered a gibtonite deposit reaction at [A.name] (JMP).")
diff --git a/code/game/turfs/space/transit.dm b/code/game/turfs/space/transit.dm
index a96cbae1269..dda49fecdbd 100644
--- a/code/game/turfs/space/transit.dm
+++ b/code/game/turfs/space/transit.dm
@@ -94,8 +94,6 @@
var/max = world.maxx-TRANSITIONEDGE
var/min = 1+TRANSITIONEDGE
- var/_z = pick(levels_by_trait(REACHABLE)) //select a random space zlevel
-
//now select coordinates for a border turf
var/_x
var/_y
@@ -113,7 +111,8 @@
_x = rand(min,max)
_y = min
- var/turf/T = locate(_x, _y, _z)
+ var/list/levels_available = get_all_linked_levels_zpos()
+ var/turf/T = locate(_x, _y, pick(levels_available))
AM.forceMove(T)
AM.newtonian_move(dir)
diff --git a/code/game/turfs/turf.dm b/code/game/turfs/turf.dm
index e174634123d..7fc000aa06f 100644
--- a/code/game/turfs/turf.dm
+++ b/code/game/turfs/turf.dm
@@ -25,7 +25,7 @@
var/blocks_air = 0
- var/PathNode/PNode = null //associated PathNode in the A* algorithm
+ var/datum/pathnode/PNode = null //associated PathNode in the A* algorithm
flags = 0
@@ -67,19 +67,6 @@
return INITIALIZE_HINT_NORMAL
-/hook/startup/proc/smooth_world()
- var/watch = start_watch()
- log_startup_progress("Smoothing atoms...")
- for(var/turf/T in world)
- if(T.smooth)
- queue_smooth(T)
- for(var/A in T)
- var/atom/AA = A
- if(AA.smooth)
- queue_smooth(AA)
- log_startup_progress(" Smoothed atoms in [stop_watch(watch)]s.")
- return TRUE
-
/turf/Destroy(force)
. = QDEL_HINT_IWILLGC
if(!changing_turf)
diff --git a/code/game/world.dm b/code/game/world.dm
index 355c6280aaf..fdb0b8f63be 100644
--- a/code/game/world.dm
+++ b/code/game/world.dm
@@ -9,10 +9,14 @@ GLOBAL_LIST_INIT(map_transition_config, MAP_TRANSITION_CONFIG)
enable_debugger() // Enable the extools debugger
log_world("World loaded at [time_stamp()]")
log_world("[GLOB.vars.len - GLOB.gvars_datum_in_built_vars.len] global variables")
+ connectDB() // This NEEDS TO HAPPEN EARLY. I CANNOT STRESS THIS ENOUGH!!!!!!! -aa
+ load_admins() // Same here
+
#ifdef UNIT_TESTS
log_world("Unit Tests Are Enabled!")
#endif
+
if(byond_version < MIN_COMPILER_VERSION || byond_build < MIN_COMPILER_BUILD)
log_world("Your server's byond version does not meet the recommended requirements for this code. Please update BYOND")
@@ -22,8 +26,7 @@ GLOBAL_LIST_INIT(map_transition_config, MAP_TRANSITION_CONFIG)
GLOB.timezoneOffset = text2num(time2text(0, "hh")) * 36000
- makeDatumRefLists()
- callHook("startup")
+ startup_procs() // Call procs that need to occur on startup (Generate lists, load MOTD, etc)
src.update_status()
@@ -31,9 +34,6 @@ GLOBAL_LIST_INIT(map_transition_config, MAP_TRANSITION_CONFIG)
. = ..()
- // Create robolimbs for chargen.
- populate_robolimb_list()
-
Master.Initialize(10, FALSE)
#ifdef UNIT_TESTS
@@ -42,6 +42,16 @@ GLOBAL_LIST_INIT(map_transition_config, MAP_TRANSITION_CONFIG)
return
+// This is basically a replacement for hook/startup. Please dont shove random bullshit here
+// If it doesnt need to happen IMMEDIATELY on world load, make a subsystem for it
+/world/proc/startup_procs()
+ LoadBans() // Load up who is banned and who isnt. DONT PUT THIS IN A SUBSYSTEM IT WILL TAKE TOO LONG TO BE CALLED
+ jobban_loadbanfile() // Load up jobbans. Again, DO NOT PUT THIS IN A SUBSYSTEM IT WILL TAKE TOO LONG TO BE CALLED
+ load_motd() // Loads up the MOTD (Welcome message players see when joining the server)
+ load_mode() // Loads up the gamemode
+ investigate_reset() // This is part of the admin investigate system. PLEASE DONT SS THIS EITHER
+ makeDatumRefLists() // Setups up lists of datums and their subtypes
+
//world/Topic(href, href_list[])
// to_chat(world, "Received a Topic() call!")
// to_chat(world, "[href]")
@@ -335,11 +345,6 @@ GLOBAL_VAR_INIT(world_topic_spam_protect_time, world.timeofday)
else
..(0)
-
-/hook/startup/proc/loadMode()
- world.load_mode()
- return 1
-
/world/proc/load_mode()
var/list/Lines = file2list("data/mode.txt")
if(Lines.len)
@@ -352,10 +357,6 @@ GLOBAL_VAR_INIT(world_topic_spam_protect_time, world.timeofday)
fdel(F)
F << the_mode
-/hook/startup/proc/loadMOTD()
- world.load_motd()
- return 1
-
/world/proc/load_motd()
GLOB.join_motd = file2text("config/motd.txt")
GLOB.join_tos = file2text("config/tos.txt")
@@ -444,7 +445,7 @@ GLOBAL_VAR_INIT(failed_old_db_connections, 0)
fdel(GLOB.config_error_log)
-/hook/startup/proc/connectDB()
+/world/proc/connectDB()
if(!setup_database_connection())
log_world("Your server failed to establish a connection with the feedback database.")
else
diff --git a/code/modules/admin/IsBanned.dm b/code/modules/admin/IsBanned.dm
index c7f2baac4ef..d9ceba62830 100644
--- a/code/modules/admin/IsBanned.dm
+++ b/code/modules/admin/IsBanned.dm
@@ -36,17 +36,6 @@ world/IsBanned(key, address, computer_id, type, check_ipintel = TRUE)
// message_admins("Failed Login: [key] - Guests not allowed")
return list("reason"="guest", "desc"="\nReason: Guests not allowed. Please sign in with a BYOND account.")
- //check if the IP address is a known Tor node
- if(config.ToRban && ToRban_isbanned(address))
- log_adminwarn("Failed Login: [key] [computer_id] [address] - Banned: Tor")
- message_admins("Failed Login: [key] - Banned: Tor")
- //ban their computer_id and ckey for posterity
- AddBan(ckey(key), computer_id, "Use of Tor", "Automated Ban", 0, 0)
- var/mistakemessage = ""
- if(config.banappeals)
- mistakemessage = "\nIf you believe this is a mistake, please request help at [config.banappeals]."
- return list("reason"="using Tor", "desc"="\nReason: The network you are using to connect has been banned.[mistakemessage]")
-
//check if the IP address is a known proxy/vpn, and the user is not whitelisted
if(check_ipintel && config.ipintel_email && config.ipintel_whitelist && ipintel_is_banned(key, address))
log_adminwarn("Failed Login: [key] [computer_id] [address] - Proxy/VPN")
diff --git a/code/modules/admin/NewBan.dm b/code/modules/admin/NewBan.dm
index 7b9a9330704..293504919d4 100644
--- a/code/modules/admin/NewBan.dm
+++ b/code/modules/admin/NewBan.dm
@@ -58,9 +58,6 @@ GLOBAL_PROTECT(banlist_savefile) // Obvious reasons
GLOB.CMinutes = (world.realtime / 10) / 60
return 1
-/hook/startup/proc/loadBans()
- return LoadBans()
-
/proc/LoadBans()
GLOB.banlist_savefile = new("data/banlist.bdb")
@@ -106,7 +103,8 @@ GLOBAL_PROTECT(banlist_savefile) // Obvious reasons
GLOB.banlist_savefile.cd = "/base"
if( GLOB.banlist_savefile.dir.Find("[ckey][computerid]") )
- to_chat(usr, "Ban already exists.")
+ if(usr)
+ to_chat(usr, "Ban already exists.")
return 0
else
GLOB.banlist_savefile.dir.Add("[ckey][computerid]")
diff --git a/code/modules/admin/ToRban.dm b/code/modules/admin/ToRban.dm
deleted file mode 100644
index b486f168503..00000000000
--- a/code/modules/admin/ToRban.dm
+++ /dev/null
@@ -1,89 +0,0 @@
-//By Carnwennan
-//fetches an external list and processes it into a list of ip addresses.
-//It then stores the processed list into a savefile for later use
-#define TORFILE "data/ToR_ban.bdb"
-#define TOR_UPDATE_INTERVAL 216000 //~6 hours
-
-/proc/ToRban_isbanned(var/ip_address)
- var/savefile/F = new(TORFILE)
- if(F)
- if( ip_address in F.dir )
- return 1
- return 0
-
-/proc/ToRban_autoupdate()
- var/savefile/F = new(TORFILE)
- if(F)
- var/last_update
- F["last_update"] >> last_update
- if((last_update + TOR_UPDATE_INTERVAL) < world.realtime) //we haven't updated for a while
- ToRban_update()
- return
-
-/proc/ToRban_update()
- spawn(0)
- log_world("Downloading updated ToR data...")
- var/http[] = world.Export("http://exitlist.torproject.org/exit-addresses")
-
- var/list/rawlist = file2list(http["CONTENT"])
- if(rawlist.len)
- fdel(TORFILE)
- var/savefile/F = new(TORFILE)
- for( var/line in rawlist )
- if(!line) continue
- if( copytext(line,1,12) == "ExitAddress" )
- var/cleaned = copytext(line,13,length(line)-19)
- if(!cleaned) continue
- F[cleaned] << 1
- to_chat(F["last_update"], world.realtime)
- log_world("ToR data updated!")
- if(usr)
- to_chat(usr, "ToRban updated.")
- return 1
- log_world("ToR data update aborted: no data.")
- return 0
-
-/client/proc/ToRban(task in list("update","toggle","show","remove","remove all","find"))
- set name = "ToRban"
- set category = "Server"
- if(!holder) return
- switch(task)
- if("update")
- ToRban_update()
- if("toggle")
- if(config)
- if(config.ToRban)
- config.ToRban = 0
- message_admins("ToR banning disabled.")
- else
- config.ToRban = 1
- message_admins("ToR banning enabled.")
- if("show")
- var/savefile/F = new(TORFILE)
- var/dat
- if( length(F.dir) )
- for( var/i=1, i<=length(F.dir), i++ )
- dat += "| #[i] | [F.dir[i]] | "
- dat = ""
- else
- dat = "No addresses in list."
- src << browse(dat,"window=ToRban_show")
- if("remove")
- var/savefile/F = new(TORFILE)
- var/choice = input(src,"Please select an IP address to remove from the ToR banlist:","Remove ToR ban",null) as null|anything in F.dir
- if(choice)
- F.dir.Remove(choice)
- to_chat(src, "Address removed")
- if("remove all")
- to_chat(src, "[TORFILE] was [fdel(TORFILE)?"":"not "]removed.")
- if("find")
- var/input = input(src,"Please input an IP address to search for:","Find ToR ban",null) as null|text
- if(input)
- if(ToRban_isbanned(input))
- to_chat(src, "Address is a known ToR address")
- else
- to_chat(src, "Address is not a known ToR address")
- return
-
-#undef TORFILE
-#undef TOR_UPDATE_INTERVAL
diff --git a/code/modules/admin/admin.dm b/code/modules/admin/admin.dm
index 1eed8083a97..958dedae362 100644
--- a/code/modules/admin/admin.dm
+++ b/code/modules/admin/admin.dm
@@ -78,6 +78,7 @@ GLOBAL_VAR_INIT(nologevent, 0)
body += " \[Heal\] "
body += "
\[ "
+ body += "LOGS - "
body += "VV - "
body += "[ADMIN_TP(M,"TP")] - "
if(M.client)
diff --git a/code/modules/admin/admin_investigate.dm b/code/modules/admin/admin_investigate.dm
index 13b786c5174..a627c96148f 100644
--- a/code/modules/admin/admin_investigate.dm
+++ b/code/modules/admin/admin_investigate.dm
@@ -11,10 +11,6 @@
/proc/investigate_subject2file(var/subject)
return file("[INVESTIGATE_DIR][subject].html")
-/hook/startup/proc/resetInvestigate()
- investigate_reset()
- return 1
-
/proc/investigate_reset()
if(fdel(INVESTIGATE_DIR)) return 1
return 0
diff --git a/code/modules/admin/admin_ranks.dm b/code/modules/admin/admin_ranks.dm
index afb4b19eee2..342ba454526 100644
--- a/code/modules/admin/admin_ranks.dm
+++ b/code/modules/admin/admin_ranks.dm
@@ -56,10 +56,6 @@ GLOBAL_PROTECT(admin_ranks) // this shit is being protected for obvious reasons
testing(msg)
#endif
-/hook/startup/proc/loadAdmins()
- load_admins()
- return 1
-
/proc/load_admins()
if(IsAdminAdvancedProcCall())
to_chat(usr, "Admin reload blocked: Advanced ProcCall detected.")
diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm
index 80a60957c75..b7f6a9d6bc9 100644
--- a/code/modules/admin/admin_verbs.dm
+++ b/code/modules/admin/admin_verbs.dm
@@ -37,6 +37,7 @@ GLOBAL_LIST_INIT(admin_verbs_admin, list(
/client/proc/jumptoturf, /*allows us to jump to a specific turf*/
/client/proc/admin_call_shuttle, /*allows us to call the emergency shuttle*/
/client/proc/admin_cancel_shuttle, /*allows us to cancel the emergency shuttle, sending it back to centcomm*/
+ /client/proc/admin_deny_shuttle, /*toggles availability of shuttle calling*/
/client/proc/check_ai_laws, /*shows AI and borg laws*/
/client/proc/manage_silicon_laws, /* Allows viewing and editing silicon laws. */
/client/proc/admin_memo, /*admin memo system. show/delete/write. +SERVER needed to delete admin memos of others*/
@@ -125,7 +126,6 @@ GLOBAL_LIST_INIT(admin_verbs_spawn, list(
/client/proc/admin_deserialize
))
GLOBAL_LIST_INIT(admin_verbs_server, list(
- /client/proc/ToRban,
/client/proc/Set_Holiday,
/datum/admins/proc/startnow,
/datum/admins/proc/restart,
@@ -826,7 +826,7 @@ GLOBAL_LIST_INIT(admin_verbs_ticket, list(
return
if(holder)
- admin_log_and_message_admins("is altering the appearance of [H].")
+ log_and_message_admins("is altering the appearance of [H].")
H.change_appearance(APPEARANCE_ALL, usr, usr, check_species_whitelist = 0)
feedback_add_details("admin_verb","CHAA") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
@@ -857,10 +857,10 @@ GLOBAL_LIST_INIT(admin_verbs_ticket, list(
switch(alert("Do you wish for [H] to be allowed to select non-whitelisted races?","Alter Mob Appearance","Yes","No","Cancel"))
if("Yes")
- admin_log_and_message_admins("has allowed [H] to change [H.p_their()] appearance, without whitelisting of races.")
+ log_and_message_admins("has allowed [H] to change [H.p_their()] appearance, without whitelisting of races.")
H.change_appearance(APPEARANCE_ALL, H.loc, check_species_whitelist = 0)
if("No")
- admin_log_and_message_admins("has allowed [H] to change [H.p_their()] appearance, with whitelisting of races.")
+ log_and_message_admins("has allowed [H] to change [H.p_their()] appearance, with whitelisting of races.")
H.change_appearance(APPEARANCE_ALL, H.loc, check_species_whitelist = 1)
feedback_add_details("admin_verb","CMAS") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
diff --git a/code/modules/admin/banjob.dm b/code/modules/admin/banjob.dm
index 9efc4c9ce88..2122f88f4ed 100644
--- a/code/modules/admin/banjob.dm
+++ b/code/modules/admin/banjob.dm
@@ -56,10 +56,6 @@ DEBUG
jobban_loadbanfile()
*/
-/hook/startup/proc/loadJobBans()
- jobban_loadbanfile()
- return 1
-
/proc/jobban_loadbanfile()
if(config.ban_legacy_system)
var/savefile/S=new("data/job_full.ban")
diff --git a/code/modules/admin/player_panel.dm b/code/modules/admin/player_panel.dm
index e89b829f421..1c6bab4d3cd 100644
--- a/code/modules/admin/player_panel.dm
+++ b/code/modules/admin/player_panel.dm
@@ -404,7 +404,8 @@
PM [ADMIN_FLW(M, "FLW")] | [close ? "" : ""]"}
/datum/admins/proc/check_antagonists()
- if(!check_rights(R_ADMIN)) return
+ if(!check_rights(R_ADMIN))
+ return
if(SSticker && SSticker.current_state >= GAME_STATE_PLAYING)
var/dat = "Round StatusRound Status"
dat += "Current Game Mode: [SSticker.mode.name] "
@@ -570,6 +571,15 @@
if(SSticker.mode.ert.len)
dat += check_role_table("ERT", SSticker.mode.ert)
+ //list active security force count, so admins know how bad things are
+ var/list/sec_list = check_active_security_force()
+ dat += "
| Security | | "
+ dat += "| Total: | [sec_list[1]] | "
+ dat += " | Active: | [sec_list[2]] | "
+ dat += " | Dead: | [sec_list[3]] | "
+ dat += " | Antag: | [sec_list[4]] | "
+ dat += " "
+
dat += ""
usr << browse(dat, "window=roundstatus;size=400x500")
else
diff --git a/code/modules/admin/sql_notes.dm b/code/modules/admin/sql_notes.dm
index a438a43eaec..04e28737479 100644
--- a/code/modules/admin/sql_notes.dm
+++ b/code/modules/admin/sql_notes.dm
@@ -2,7 +2,8 @@
if(checkrights && !check_rights(R_ADMIN|R_MOD))
return
if(!GLOB.dbcon.IsConnected())
- to_chat(usr, "Failed to establish database connection.")
+ if(usr)
+ to_chat(usr, "Failed to establish database connection.")
return
if(!target_ckey)
@@ -19,7 +20,8 @@
log_game("SQL ERROR obtaining ckey from player table. Error : \[[err]\]\n")
return
if(!query_find_ckey.NextRow())
- to_chat(usr, "[target_ckey] has not been seen before, you can only add notes to known players.")
+ if(usr)
+ to_chat(usr, "[target_ckey] has not been seen before, you can only add notes to known players.")
return
var/exp_data = query_find_ckey.item[2]
@@ -52,8 +54,8 @@
log_game("SQL ERROR adding new note to table. Error : \[[err]\]\n")
return
if(logged)
- log_admin("[key_name(usr)] has added a note to [target_ckey]: [notetext]")
- message_admins("[key_name_admin(usr)] has added a note to [target_ckey]: [notetext]")
+ log_admin("[usr ? key_name(usr) : adminckey] has added a note to [target_ckey]: [notetext]")
+ message_admins("[usr ? key_name_admin(usr) : adminckey] has added a note to [target_ckey]: [notetext]")
show_note(target_ckey)
/proc/remove_note(note_id)
@@ -63,7 +65,8 @@
var/notetext
var/adminckey
if(!GLOB.dbcon.IsConnected())
- to_chat(usr, "Failed to establish database connection.")
+ if(usr)
+ to_chat(usr, "Failed to establish database connection.")
return
if(!note_id)
return
@@ -82,15 +85,16 @@
var/err = query_del_note.ErrorMsg()
log_game("SQL ERROR removing note from table. Error : \[[err]\]\n")
return
- log_admin("[key_name(usr)] has removed a note made by [adminckey] from [ckey]: [notetext]")
- message_admins("[key_name_admin(usr)] has removed a note made by [adminckey] from [ckey]: [notetext]")
+ log_admin("[usr ? key_name(usr) : "Bot"] has removed a note made by [adminckey] from [ckey]: [notetext]")
+ message_admins("[usr ? key_name_admin(usr) : "Bot"] has removed a note made by [adminckey] from [ckey]: [notetext]")
show_note(ckey)
/proc/edit_note(note_id)
if(!check_rights(R_ADMIN|R_MOD))
return
if(!GLOB.dbcon.IsConnected())
- to_chat(usr, "Failed to establish database connection.")
+ if(usr)
+ to_chat(usr, "Failed to establish database connection.")
return
if(!note_id)
return
@@ -117,8 +121,8 @@
var/err = query_update_note.ErrorMsg()
log_game("SQL ERROR editing note. Error : \[[err]\]\n")
return
- log_admin("[key_name(usr)] has edited [target_ckey]'s note made by [adminckey] from \"[old_note]\" to \"[new_note]\"")
- message_admins("[key_name_admin(usr)] has edited [target_ckey]'s note made by [adminckey] from \"[old_note]\" to \"[new_note]\"")
+ log_admin("[usr ? key_name(usr) : "Bot"] has edited [target_ckey]'s note made by [adminckey] from \"[old_note]\" to \"[new_note]\"")
+ message_admins("[usr ? key_name_admin(usr) : "Bot"] has edited [target_ckey]'s note made by [adminckey] from \"[old_note]\" to \"[new_note]\"")
show_note(target_ckey)
/proc/show_note(target_ckey, index, linkless = 0)
diff --git a/code/modules/admin/topic.dm b/code/modules/admin/topic.dm
index 50fa99778e7..1d2c75aff0a 100644
--- a/code/modules/admin/topic.dm
+++ b/code/modules/admin/topic.dm
@@ -911,6 +911,11 @@
//M.client = null
qdel(M.client)
+ else if(href_list["open_logging_view"])
+ var/mob/M = locateUID(href_list["open_logging_view"])
+ if(ismob(M))
+ usr.client.open_logging_view(list(M), TRUE)
+
//Player Notes
else if(href_list["addnote"])
var/target_ckey = href_list["addnote"]
@@ -2583,14 +2588,16 @@
if("monkey")
feedback_inc("admin_secrets_fun_used",1)
feedback_add_details("admin_secrets_fun_used","M")
- for(var/mob/living/carbon/human/H in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
spawn(0)
H.monkeyize()
ok = 1
if("corgi")
feedback_inc("admin_secrets_fun_used",1)
feedback_add_details("admin_secrets_fun_used","M")
- for(var/mob/living/carbon/human/H in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
spawn(0)
H.corgize()
ok = 1
@@ -2661,7 +2668,8 @@
feedback_inc("admin_secrets_fun_used",1)
feedback_add_details("admin_secrets_fun_used","PW")
message_admins("[key_name_admin(usr)] teleported all players to the prison station.", 1)
- for(var/mob/living/carbon/human/H in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
var/turf/loc = find_loc(H)
var/security = 0
if(!is_station_level(loc.z) || GLOB.prisonwarped.Find(H))
@@ -2994,7 +3002,8 @@
if("manifest")
var/dat = "Showing Crew Manifest. "
dat += "| Name | Position | "
- for(var/mob/living/carbon/human/H in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
if(H.ckey)
dat += text("| [] | [] | ", H.name, H.get_assignment())
dat += " "
@@ -3004,7 +3013,8 @@
if("DNA")
var/dat = "Showing DNA from blood. "
dat += "| Name | DNA | Blood Type | "
- for(var/mob/living/carbon/human/H in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
if(H.dna && H.ckey)
dat += "| [H] | [H.dna.unique_enzymes] | [H.dna.blood_type] | "
dat += " "
@@ -3012,7 +3022,8 @@
if("fingerprints")
var/dat = "Showing Fingerprints. "
dat += "| Name | Fingerprints | "
- for(var/mob/living/carbon/human/H in GLOB.mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
if(H.ckey)
if(H.dna && H.dna.uni_identity)
dat += "| [H] | [md5(H.dna.uni_identity)] | "
diff --git a/code/modules/admin/verbs/adminjump.dm b/code/modules/admin/verbs/adminjump.dm
index 0c1a8c5f14f..ca83b5bad08 100644
--- a/code/modules/admin/verbs/adminjump.dm
+++ b/code/modules/admin/verbs/adminjump.dm
@@ -22,6 +22,10 @@
to_chat(src, "Nowhere to jump to!")
return
+ if(isobj(usr.loc))
+ var/obj/O = usr.loc
+ O.force_eject_occupant()
+
admin_forcemove(usr, T)
log_admin("[key_name(usr)] jumped to [A]")
if(!isobserver(usr))
@@ -35,6 +39,9 @@
if(!check_rights(R_ADMIN))
return
+ if(isobj(usr.loc))
+ var/obj/O = usr.loc
+ O.force_eject_occupant()
log_admin("[key_name(usr)] jumped to [T.x], [T.y], [T.z] in [T.loc]")
if(!isobserver(usr))
message_admins("[key_name_admin(usr)] jumped to [T.x], [T.y], [T.z] in [T.loc]", 1)
@@ -52,6 +59,9 @@
log_admin("[key_name(usr)] jumped to [key_name(M)]")
if(!isobserver(usr))
message_admins("[key_name_admin(usr)] jumped to [key_name_admin(M)]", 1)
+ if(isobj(usr.loc))
+ var/obj/O = usr.loc
+ O.force_eject_occupant()
if(src.mob)
var/mob/A = src.mob
var/turf/T = get_turf(M)
@@ -70,6 +80,9 @@
var/turf/T = locate(tx, ty, tz)
if(T)
+ if(isobj(usr.loc))
+ var/obj/O = usr.loc
+ O.force_eject_occupant()
admin_forcemove(usr, T)
if(isobserver(usr))
var/mob/dead/observer/O = usr
@@ -96,7 +109,9 @@
log_admin("[key_name(usr)] jumped to [key_name(M)]")
if(!isobserver(usr))
message_admins("[key_name_admin(usr)] jumped to [key_name_admin(M)]", 1)
-
+ if(isobj(usr.loc))
+ var/obj/O = usr.loc
+ O.force_eject_occupant()
admin_forcemove(usr, M.loc)
feedback_add_details("admin_verb","JK") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
@@ -111,6 +126,10 @@
log_admin("[key_name(usr)] teleported [key_name(M)]")
message_admins("[key_name_admin(usr)] teleported [key_name_admin(M)]", 1)
+
+ if(isobj(M.loc))
+ var/obj/O = M.loc
+ O.force_eject_occupant()
admin_forcemove(M, get_turf(usr))
feedback_add_details("admin_verb","GM") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
@@ -135,6 +154,9 @@
log_admin("[key_name(usr)] teleported [key_name(M)]")
message_admins("[key_name_admin(usr)] teleported [key_name(M)]", 1)
if(M)
+ if(isobj(M.loc))
+ var/obj/O = M.loc
+ O.force_eject_occupant()
admin_forcemove(M, get_turf(usr))
admin_forcemove(usr, M.loc)
feedback_add_details("admin_verb","GK") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
@@ -148,6 +170,9 @@
var/area/A = input(usr, "Pick an area.", "Pick an area") in return_sorted_areas()
if(A)
+ if(isobj(M.loc))
+ var/obj/O = M.loc
+ O.force_eject_occupant()
admin_forcemove(M, pick(get_area_turfs(A)))
feedback_add_details("admin_verb","SMOB") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
log_admin("[key_name(usr)] teleported [key_name(M)] to [A]")
diff --git a/code/modules/admin/verbs/adminsay.dm b/code/modules/admin/verbs/adminsay.dm
index a0e8b4b9088..5a0425af30a 100644
--- a/code/modules/admin/verbs/adminsay.dm
+++ b/code/modules/admin/verbs/adminsay.dm
@@ -78,5 +78,5 @@
C.verbs -= msay
to_chat(C, "Mentor chat has been disabled.")
- admin_log_and_message_admins("toggled mentor chat [enabling ? "on" : "off"].")
+ log_and_message_admins("toggled mentor chat [enabling ? "on" : "off"].")
feedback_add_details("admin_verb", "TMC")
diff --git a/code/modules/admin/verbs/debug.dm b/code/modules/admin/verbs/debug.dm
index 424e3c91f57..03b9dfb60e7 100644
--- a/code/modules/admin/verbs/debug.dm
+++ b/code/modules/admin/verbs/debug.dm
@@ -643,7 +643,7 @@ GLOBAL_PROTECT(AdminProcCallSpamPrevention)
for(var/areatype in areas_without_camera)
to_chat(world, "* [areatype]")
-/client/proc/cmd_admin_dress(var/mob/living/carbon/human/M in GLOB.mob_list)
+/client/proc/cmd_admin_dress(mob/living/carbon/human/M in GLOB.human_list)
set category = "Event"
set name = "Select equipment"
@@ -917,6 +917,9 @@ GLOBAL_PROTECT(AdminProcCallSpamPrevention)
if(istype(landmark))
var/datum/map_template/ruin/template = landmark.ruin_template
+ if(isobj(usr.loc))
+ var/obj/O = usr.loc
+ O.force_eject_occupant()
admin_forcemove(usr, get_turf(landmark))
to_chat(usr, "[template.name]")
diff --git a/code/modules/admin/verbs/logging_view.dm b/code/modules/admin/verbs/logging_view.dm
index 903926f4923..cafaab8f1d7 100644
--- a/code/modules/admin/verbs/logging_view.dm
+++ b/code/modules/admin/verbs/logging_view.dm
@@ -2,10 +2,20 @@ GLOBAL_LIST_INIT(open_logging_views, list())
/client/proc/cmd_admin_open_logging_view()
set category = "Admin"
- set name = "Open Logging View"
+ set name = "Logging View"
set desc = "Opens the detailed logging viewer"
+ open_logging_view()
- if(!GLOB.open_logging_views[usr.client.ckey])
- GLOB.open_logging_views[usr.client.ckey] = new /datum/log_viewer()
- var/datum/log_viewer/LV = GLOB.open_logging_views[usr.client.ckey]
- LV.show_ui(usr)
+/client/proc/open_logging_view(list/mob/mobs_to_add = null, clear_view = FALSE)
+ var/datum/log_viewer/cur_view = GLOB.open_logging_views[usr.client.ckey]
+ if(!cur_view)
+ cur_view = new /datum/log_viewer()
+ GLOB.open_logging_views[usr.client.ckey] = cur_view
+ else if(clear_view)
+ cur_view.clear_all()
+
+ if(mobs_to_add?.len)
+ cur_view.add_mobs(mobs_to_add)
+
+ cur_view.show_ui(usr)
+
diff --git a/code/modules/admin/verbs/onlyone.dm b/code/modules/admin/verbs/onlyone.dm
index e51f6da991a..9f2579ad162 100644
--- a/code/modules/admin/verbs/onlyone.dm
+++ b/code/modules/admin/verbs/onlyone.dm
@@ -84,7 +84,7 @@
var/obj/item/slot_item_hand = H.get_item_by_slot(slot_r_hand)
H.unEquip(slot_item_hand)
- var /obj/item/multisword/pure_evil/multi = new(H)
+ var/obj/item/multisword/pure_evil/multi = new(H)
H.equip_to_slot_or_del(multi, slot_r_hand)
var/obj/item/card/id/W = new(H)
diff --git a/code/modules/admin/verbs/randomverbs.dm b/code/modules/admin/verbs/randomverbs.dm
index 03315243602..7e9f397a855 100644
--- a/code/modules/admin/verbs/randomverbs.dm
+++ b/code/modules/admin/verbs/randomverbs.dm
@@ -826,7 +826,10 @@ Traitors and the like can also be revived with the previous role mostly intact.
else
SSshuttle.emergency.canRecall = FALSE
- SSshuttle.emergency.request()
+ if(seclevel2num(get_security_level()) >= SEC_LEVEL_RED)
+ SSshuttle.emergency.request(coefficient = 0.5, redAlert = TRUE)
+ else
+ SSshuttle.emergency.request()
feedback_add_details("admin_verb","CSHUT") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
log_admin("[key_name(usr)] admin-called the emergency shuttle.")
@@ -874,6 +877,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if(SSshuttle)
SSshuttle.emergencyNoEscape = !SSshuttle.emergencyNoEscape
+ feedback_add_details("admin_verb", "DENYSHUT")
log_admin("[key_name(src)] has [SSshuttle.emergencyNoEscape ? "denied" : "allowed"] the shuttle to be called.")
message_admins("[key_name_admin(usr)] has [SSshuttle.emergencyNoEscape ? "denied" : "allowed"] the shuttle to be called.")
@@ -979,7 +983,8 @@ Traitors and the like can also be revived with the previous role mostly intact.
var/role_string
var/obj_count = 0
var/obj_string = ""
- for(var/mob/living/carbon/human/H in GLOB.alive_mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
if(!isLivingSSD(H))
continue
mins_ssd = round((world.time - H.last_logout) / 600)
@@ -1016,7 +1021,8 @@ Traitors and the like can also be revived with the previous role mostly intact.
msg += "AFK Players:
"
msg += "| Key | Real Name | Job | Mins AFK | Special Role | Area | PPN | Cryo | "
var/mins_afk
- for(var/mob/living/carbon/human/H in GLOB.alive_mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
if(H.client == null || H.stat == DEAD) // No clientless or dead
continue
mins_afk = round(H.client.inactivity / 600)
diff --git a/code/modules/admin/verbs/toggledebugverbs.dm b/code/modules/admin/verbs/toggledebugverbs.dm
index 328b5176e9a..38b49869298 100644
--- a/code/modules/admin/verbs/toggledebugverbs.dm
+++ b/code/modules/admin/verbs/toggledebugverbs.dm
@@ -17,7 +17,6 @@ GLOBAL_LIST_INIT(admin_verbs_show_debug_verbs, list(
/client/proc/print_jobban_old,
/client/proc/print_jobban_old_filter,
/client/proc/forceEvent,
- /client/proc/nanomapgen_DumpImage,
/client/proc/admin_redo_space_transitions,
/client/proc/make_turf_space_map,
/client/proc/vv_by_ref
diff --git a/code/modules/antagonists/_common/antag_spawner.dm b/code/modules/antagonists/_common/antag_spawner.dm
index beefc41735b..8e29326632f 100644
--- a/code/modules/antagonists/_common/antag_spawner.dm
+++ b/code/modules/antagonists/_common/antag_spawner.dm
@@ -194,7 +194,7 @@
to_chat(user, "The demons do not respond to your summon. Perhaps you should try again later.")
/obj/item/antag_spawner/slaughter_demon/spawn_antag(client/C, turf/T, type = "", mob/user)
- var /obj/effect/dummy/slaughter/holder = new /obj/effect/dummy/slaughter(T)
+ var/obj/effect/dummy/slaughter/holder = new /obj/effect/dummy/slaughter(T)
var/mob/living/simple_animal/slaughter/S = new demon_type(holder)
S.vialspawned = TRUE
S.holder = holder
diff --git a/code/modules/antagonists/traitor/datum_traitor.dm b/code/modules/antagonists/traitor/datum_traitor.dm
index e13fb701317..6275c00ba9b 100644
--- a/code/modules/antagonists/traitor/datum_traitor.dm
+++ b/code/modules/antagonists/traitor/datum_traitor.dm
@@ -41,9 +41,8 @@
A.common_radio.channels.Remove("Syndicate") // De-traitored AIs can still state laws over the syndicate channel without this
A.laws.sorted_laws = A.laws.inherent_laws.Copy() // AI's 'notify laws' button will still state a law 0 because sorted_laws contains it
A.show_laws()
- A.malf_picker.remove_malf_verbs(A)
- A.verbs -= /mob/living/silicon/ai/proc/choose_modules
- qdel(A.malf_picker)
+ A.remove_malf_abilities()
+ QDEL_NULL(A.malf_picker)
if(owner.som)
var/datum/mindslaves/slaved = owner.som
@@ -251,9 +250,14 @@
/datum/antagonist/traitor/proc/update_traitor_icons_added(datum/mind/traitor_mind)
- var/datum/atom_hud/antag/traitorhud = GLOB.huds[ANTAG_HUD_TRAITOR]
- traitorhud.join_hud(owner.current, null)
- set_antag_hud(owner.current, "hudsyndicate")
+ if(locate(/datum/objective/hijack) in owner.objectives)
+ var/datum/atom_hud/antag/hijackhud = GLOB.huds[ANTAG_HUD_TRAITOR]
+ hijackhud.join_hud(owner.current, null)
+ set_antag_hud(owner.current, "hudhijack")
+ else
+ var/datum/atom_hud/antag/traitorhud = GLOB.huds[ANTAG_HUD_TRAITOR]
+ traitorhud.join_hud(owner.current, null)
+ set_antag_hud(owner.current, "hudsyndicate")
/datum/antagonist/traitor/proc/update_traitor_icons_removed(datum/mind/traitor_mind)
@@ -400,7 +404,7 @@
var/phrases = jointext(GLOB.syndicate_code_phrase, ", ")
var/responses = jointext(GLOB.syndicate_code_response, ", ")
- var message = " The code phrases were: [phrases] \
+ var/message = " The code phrases were: [phrases] \
The code responses were: [responses] "
return message
diff --git a/code/modules/awaymissions/maploader/dmm_suite.dm b/code/modules/awaymissions/maploader/dmm_suite.dm
index 1eee3d8fc34..5e958f28ee6 100644
--- a/code/modules/awaymissions/maploader/dmm_suite.dm
+++ b/code/modules/awaymissions/maploader/dmm_suite.dm
@@ -1,72 +1,82 @@
-GLOBAL_DATUM_INIT(maploader, /dmm_suite, new())
-dmm_suite{
- /*
+/*
- dmm_suite version 1.0
- Released January 30th, 2011.
+ dmm_suite version 1.0
+ Released January 30th, 2011.
- defines the object /dmm_suite
- - Provides the proc load_map()
- - Loads the specified map file onto the specified z-level.
- - provides the proc write_map()
- - Returns a text string of the map in dmm format
- ready for output to a file.
- - provides the proc save_map()
- - Returns a .dmm file if map is saved
- - Returns FALSE if map fails to save
+ defines the object /dmm_suite
+ - Provides the proc load_map()
+ - Loads the specified map file onto the specified z-level.
+ - provides the proc write_map()
+ - Returns a text string of the map in dmm format
+ ready for output to a file.
+ - provides the proc save_map()
+ - Returns a .dmm file if map is saved
+ - Returns FALSE if map fails to save
- The dmm_suite provides saving and loading of map files in BYOND's native DMM map
- format. It approximates the map saving and loading processes of the Dream Maker
- and Dream Seeker programs so as to allow editing, saving, and loading of maps at
- runtime.
+ The dmm_suite provides saving and loading of map files in BYOND's native DMM map
+ format. It approximates the map saving and loading processes of the Dream Maker
+ and Dream Seeker programs so as to allow editing, saving, and loading of maps at
+ runtime.
- ------------------------
+ ------------------------
- To save a map at runtime, create an instance of /dmm_suite, and then call
- write_map(), which accepts three arguments:
- - A turf representing one corner of a three dimensional grid (Required).
- - Another turf representing the other corner of the same grid (Required).
- - Any, or a combination, of several bit flags (Optional, see documentation).
+ To save a map at runtime, create an instance of /dmm_suite, and then call
+ write_map(), which accepts three arguments:
+ - A turf representing one corner of a three dimensional grid (Required).
+ - Another turf representing the other corner of the same grid (Required).
+ - Any, or a combination, of several bit flags (Optional, see documentation).
- The order in which the turfs are supplied does not matter, the /dmm_writer will
- determine the grid containing both, in much the same way as DM's block() function.
- write_map() will then return a string representing the saved map in dmm format;
- this string can then be saved to a file, or used for any other purose.
+ The order in which the turfs are supplied does not matter, the /dmm_writer will
+ determine the grid containing both, in much the same way as DM's block() function.
+ write_map() will then return a string representing the saved map in dmm format;
+ this string can then be saved to a file, or used for any other purose.
- ------------------------
+ ------------------------
- To load a map at runtime, create an instance of /dmm_suite, and then call load_map(),
- which accepts two arguments:
- - A .dmm file to load (Required).
- - A number representing the z-level on which to start loading the map (Optional).
+ To load a map at runtime, create an instance of /dmm_suite, and then call load_map(),
+ which accepts two arguments:
+ - A .dmm file to load (Required).
+ - A number representing the z-level on which to start loading the map (Optional).
- The /dmm_suite will load the map file starting on the specified z-level. If no
- z-level was specified, world.maxz will be increased so as to fit the map. Note
- that if you wish to load a map onto a z-level that already has objects on it,
- you will have to handle the removal of those objects. Otherwise the new map will
- simply load the new objects on top of the old ones.
+ The /dmm_suite will load the map file starting on the specified z-level. If no
+ z-level was specified, world.maxz will be increased so as to fit the map. Note
+ that if you wish to load a map onto a z-level that already has objects on it,
+ you will have to handle the removal of those objects. Otherwise the new map will
+ simply load the new objects on top of the old ones.
- Also note that all type paths specified in the .dmm file must exist in the world's
- code, and that the /dmm_reader trusts that files to be loaded are in fact valid
- .dmm files. Errors in the .dmm format will cause runtime errors.
+ Also note that all type paths specified in the .dmm file must exist in the world's
+ code, and that the /dmm_reader trusts that files to be loaded are in fact valid
+ .dmm files. Errors in the .dmm format will cause runtime errors.
- */
+*/
- verb/load_map(var/dmm_file as file, var/x_offset as num, var/y_offset as num, var/z_offset as num, do_sleep as num){
- // dmm_file: A .dmm file to load (Required).
- // z_offset: A number representing the z-level on which to start loading the map (Optional).
- }
- verb/write_map(var/turf/t1 as turf, var/turf/t2 as turf, var/flags as num){
- // t1: A turf representing one corner of a three dimensional grid (Required).
- // t2: Another turf representing the other corner of the same grid (Required).
- // flags: Any, or a combination, of several bit flags (Optional, see documentation).
- }
+GLOBAL_DATUM_INIT(maploader, /datum/dmm_suite, new())
- // save_map is included as a legacy proc. Use write_map instead.
- verb/save_map(var/turf/t1 as turf, var/turf/t2 as turf, var/map_name as text, var/flags as num){
- // t1: A turf representing one corner of a three dimensional grid (Required).
- // t2: Another turf representing the other corner of the same grid (Required).
- // map_name: A valid name for the map to be saved, such as "castle" (Required).
- // flags: Any, or a combination, of several bit flags (Optional, see documentation).
- }
- }
+/datum/dmm_suite
+ var/static/quote = "\""
+
+ // These regexes are global - meaning that starting the maploader again mid-load will
+ // reset progress - which means we need to track our index per-map, or we'll
+ // eternally recurse
+ // /"([a-zA-Z]+)" = \(((?:.|\n)*?)\)\n(?!\t)|\((\d+),(\d+),(\d+)\) = \{"([a-zA-Z\n]*)"\}/g
+ var/static/regex/dmmRegex = new/regex({""(\[a-zA-Z]+)" = \\(((?:.|\n)*?)\\)\n(?!\t)|\\((\\d+),(\\d+),(\\d+)\\) = \\{"(\[a-zA-Z\n]*)"\\}"}, "g")
+ // /^[\s\n]+"?|"?[\s\n]+$|^"|"$/g
+ var/static/regex/trimQuotesRegex = new/regex({"^\[\\s\n]+"?|"?\[\\s\n]+$|^"|"$"}, "g")
+ // /^[\s\n]+|[\s\n]+$/
+ var/static/regex/trimRegex = new/regex("^\[\\s\n]+|\[\\s\n]+$", "g")
+ var/static/list/modelCache = list()
+
+ var/static/list/letter_digits = list(
+ "a", "b", "c", "d", "e",
+ "f", "g", "h", "i", "j",
+ "k", "l", "m", "n", "o",
+ "p", "q", "r", "s", "t",
+ "u", "v", "w", "x", "y",
+ "z",
+ "A", "B", "C", "D", "E",
+ "F", "G", "H", "I", "J",
+ "K", "L", "M", "N", "O",
+ "P", "Q", "R", "S", "T",
+ "U", "V", "W", "X", "Y",
+ "Z"
+ )
diff --git a/code/modules/awaymissions/maploader/reader.dm b/code/modules/awaymissions/maploader/reader.dm
index 9a7cf6b6405..f034c4f39d1 100644
--- a/code/modules/awaymissions/maploader/reader.dm
+++ b/code/modules/awaymissions/maploader/reader.dm
@@ -1,23 +1,11 @@
///////////////////////////////////////////////////////////////
-//SS13 Optimized Map loader
+// SS13 Optimized Map loader
//////////////////////////////////////////////////////////////
-//As of 3.6.2016
-//global datum that will preload variables on atoms instanciation
+// As of 3.6.2016
+// global datum that will preload variables on atoms instanciation
GLOBAL_VAR_INIT(use_preloader, FALSE)
-GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
-
-/dmm_suite
- // These regexes are global - meaning that starting the maploader again mid-load will
- // reset progress - which means we need to track our index per-map, or we'll
- // eternally recurse
- // /"([a-zA-Z]+)" = \(((?:.|\n)*?)\)\n(?!\t)|\((\d+),(\d+),(\d+)\) = \{"([a-zA-Z\n]*)"\}/g
- var/static/regex/dmmRegex = new/regex({""(\[a-zA-Z]+)" = \\(((?:.|\n)*?)\\)\n(?!\t)|\\((\\d+),(\\d+),(\\d+)\\) = \\{"(\[a-zA-Z\n]*)"\\}"}, "g")
- // /^[\s\n]+"?|"?[\s\n]+$|^"|"$/g
- var/static/regex/trimQuotesRegex = new/regex({"^\[\\s\n]+"?|"?\[\\s\n]+$|^"|"$"}, "g")
- // /^[\s\n]+|[\s\n]+$/
- var/static/regex/trimRegex = new/regex("^\[\\s\n]+|\[\\s\n]+$", "g")
- var/static/list/modelCache = list()
+GLOBAL_DATUM_INIT(_preloader, /datum/dmm_suite/preloader, new())
/**
* Construct the model map and control the loading process
@@ -37,13 +25,18 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
* atmos will attempt to start before it's ready, causing runtimes galore if init is
* allowed to romp unchecked.
*/
-/dmm_suite/load_map(dmm_file as file, x_offset as num, y_offset as num, z_offset as num, cropMap as num, measureOnly as num)
- var/tfile = dmm_file//the map file we're creating
+/datum/dmm_suite/proc/load_map(dmm_file, x_offset = 0, y_offset = 0, z_offset = 0, shouldCropMap = FALSE, measureOnly = FALSE)
+ var/tfile = dmm_file// the map file we're creating
var/fname = "Lambda"
if(isfile(tfile))
fname = "[tfile]"
+ // Make sure we dont load a dir up
+ var/lastchar = copytext(fname, -1)
+ if(lastchar == "/" || lastchar == "\\")
+ log_debug("Attempted to load map template without filename (Attempted [tfile])")
+ return
tfile = file2text(tfile)
- if(length(tfile) == 0)
+ if(!length(tfile))
throw EXCEPTION("Map path '[fname]' does not exist!")
if(!x_offset)
@@ -57,7 +50,7 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
var/list/grid_models = list()
var/key_len = 0
- var/dmm_suite/loaded_map/LM = new
+ var/datum/dmm_suite/loaded_map/LM = new
// This try-catch is used as a budget "Finally" clause, as the dirt count
// needs to be reset
var/watch = start_watch()
@@ -76,7 +69,7 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
if(!key_len)
key_len = length(key)
else
- throw EXCEPTION("Inconsistant key length in DMM")
+ throw EXCEPTION("Inconsistent key length in DMM")
if(!measureOnly)
grid_models[key] = dmmRegex.group[2]
@@ -86,17 +79,17 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
throw EXCEPTION("Coords before model definition in DMM")
var/xcrdStart = text2num(dmmRegex.group[3]) + x_offset - 1
- //position of the currently processed square
+ // position of the currently processed square
var/xcrd
var/ycrd = text2num(dmmRegex.group[4]) + y_offset - 1
var/zcrd = text2num(dmmRegex.group[5]) + z_offset - 1
if(!measureOnly)
if(zcrd > world.maxz)
- if(cropMap)
+ if(shouldCropMap)
continue
else
- GLOB.space_manager.increase_max_zlevel_to(zcrd) //create a new z_level if needed
+ GLOB.space_manager.increase_max_zlevel_to(zcrd) // create a new z_level if needed
bounds[MAP_MINX] = min(bounds[MAP_MINX], xcrdStart)
bounds[MAP_MINZ] = min(bounds[MAP_MINZ], zcrd)
@@ -118,7 +111,7 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
bounds[MAP_MINY] = min(bounds[MAP_MINY], ycrd)
ycrd += gridLines.len - 1 // Start at the top and work down
- if(!cropMap && ycrd > world.maxy)
+ if(!shouldCropMap && ycrd > world.maxy)
if(!measureOnly)
world.maxy = ycrd // Expand Y here. X is expanded in the loop below
bounds[MAP_MAXY] = max(bounds[MAP_MAXY], ycrd)
@@ -133,9 +126,9 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
for(var/line in gridLines)
if(ycrd <= world.maxy && ycrd >= 1)
xcrd = xcrdStart
- for(var/tpos = 1 to length(line) - key_len + 1 step key_len)
+ for(var/tpos = 1 to (length(line) - key_len + 1) step key_len)
if(xcrd > world.maxx)
- if(cropMap)
+ if(shouldCropMap)
break
else
world.maxx = xcrd
@@ -152,7 +145,7 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
maxx = max(maxx, xcrd)
++xcrd
--ycrd
- bounds[MAP_MAXX] = max(bounds[MAP_MAXX], cropMap ? min(maxx, world.maxx) : maxx)
+ bounds[MAP_MAXX] = max(bounds[MAP_MAXX], shouldCropMap ? min(maxx, world.maxx) : maxx)
CHECK_TICK
catch(var/exception/e)
@@ -175,8 +168,8 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
if(!measureOnly)
for(var/t in block(locate(bounds[MAP_MINX], bounds[MAP_MINY], bounds[MAP_MINZ]), locate(bounds[MAP_MAXX], bounds[MAP_MAXY], bounds[MAP_MAXZ])))
var/turf/T = t
- //we do this after we load everything in. if we don't; we'll have weird atmos bugs regarding atmos adjacent turfs
- T.AfterChange(1, keep_cabling = TRUE)
+ // we do this after we load everything in. if we don't; we'll have weird atmos bugs regarding atmos adjacent turfs
+ T.AfterChange(TRUE, keep_cabling = TRUE)
return bounds
/**
@@ -196,14 +189,14 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
* 4) Instanciates the atom with its variables
*
*/
-/dmm_suite/proc/parse_grid(model as text,xcrd as num,ycrd as num,zcrd as num, dmm_suite/loaded_map/LM)
+/datum/dmm_suite/proc/parse_grid(model = "", xcrd = 0, ycrd = 0, zcrd = 0, datum/dmm_suite/loaded_map/LM)
/*Method parse_grid()
- Accepts a text string containing a comma separated list of type paths of the
same construction as those contained in a .dmm file, and instantiates them.
*/
- var/list/members //will contain all members (paths) in model (in our example : /turf/unsimulated/wall and /area/mine/dangerous/explored)
- var/list/members_attributes //will contain lists filled with corresponding variables, if any (in our example : list(icon_state = "rock") and list())
+ var/list/members // will contain all members (paths) in model (in our example : /turf/unsimulated/wall and /area/mine/dangerous/explored)
+ var/list/members_attributes // will contain lists filled with corresponding variables, if any (in our example : list(icon_state = "rock") and list())
var/list/cached = modelCache[model]
var/index
@@ -212,7 +205,7 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
members_attributes = cached[2]
else
/////////////////////////////////////////////////////////
- //Constructing members and corresponding variables lists
+ // Constructing members and corresponding variables lists
////////////////////////////////////////////////////////
members = list()
@@ -223,13 +216,13 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
var/dpos
do
- //finding next member (e.g /turf/unsimulated/wall{icon_state = "rock"} or /area/mine/dangerous/explored)
- dpos = find_next_delimiter_position(model, old_position, ",", "{", "}") //find next delimiter (comma here) that's not within {...}
+ // finding next member (e.g /turf/unsimulated/wall{icon_state = "rock"} or /area/mine/dangerous/explored)
+ dpos = find_next_delimiter_position(model, old_position, ",", "{", "}") // find next delimiter (comma here) that's not within {...}
- var/full_def = trim_text(copytext(model, old_position, dpos)) //full definition, e.g : /obj/foo/bar{variables=derp}
+ var/full_def = trim_text(copytext(model, old_position, dpos)) // full definition, e.g : /obj/foo/bar{variables=derp}
var/variables_start = findtext(full_def, "{")
var/atom_text = trim_text(copytext(full_def, 1, variables_start))
- var/atom_def = text2path(atom_text) //path definition, e.g /obj/foo/bar
+ var/atom_def = text2path(atom_text) // path definition, e.g /obj/foo/bar
old_position = dpos + 1
if(!atom_def) // Skip the item if the path does not exist. Fix your crap, mappers!
@@ -237,14 +230,14 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
continue
members.Add(atom_def)
- //transform the variables in text format into a list (e.g {var1="derp"; var2; var3=7} => list(var1="derp", var2, var3=7))
+ // transform the variables in text format into a list (e.g {var1="derp"; var2; var3=7} => list(var1="derp", var2, var3=7))
var/list/fields = list()
- if(variables_start)//if there's any variable
- full_def = copytext(full_def,variables_start+1,length(full_def))//removing the last '}'
+ if(variables_start) // if there's any variable
+ full_def = copytext(full_def, variables_start + 1, length(full_def)) // removing the last '}'
fields = readlist(full_def, ";")
- //then fill the members_attributes list with the corresponding variables
+ // then fill the members_attributes list with the corresponding variables
members_attributes.len++
members_attributes[index++] = fields
@@ -255,24 +248,23 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
////////////////
- //Instanciation
+ // Instanciation
////////////////
- //The next part of the code assumes there's ALWAYS an /area AND a /turf on a given tile
+ // The next part of the code assumes there's ALWAYS an /area AND a /turf on a given tile
- //first instance the /area and remove it from the members list
+ // first instance the /area and remove it from the members list
index = members.len
- var/turf/crds = locate(xcrd,ycrd,zcrd)
+ var/turf/crds = locate(xcrd, ycrd, zcrd)
if(members[index] != /area/template_noop)
// We assume `members[index]` is an area path, as above, yes? I will operate
// on that assumption.
if(!ispath(members[index], /area))
throw EXCEPTION("Oh no, I thought this was an area!")
- var/atom/instance
- GLOB._preloader.setup(members_attributes[index])//preloader for assigning set variables on atom creation
- instance = LM.area_path_to_real_area(members[index])
+ GLOB._preloader.setup(members_attributes[index]) // preloader for assigning set variables on atom creation
+ var/atom/instance = LM.area_path_to_real_area(members[index])
if(crds)
instance.contents.Add(crds)
@@ -280,45 +272,46 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
if(GLOB.use_preloader && instance)
GLOB._preloader.load(instance)
- //then instance the /turf and, if multiple tiles are presents, simulates the DMM underlays piling effect
+ // then instance the /turf and, if multiple tiles are presents, simulates the DMM underlays piling effect
var/first_turf_index = 1
- while(!ispath(members[first_turf_index],/turf)) //find first /turf object in members
+ while(!ispath(members[first_turf_index], /turf)) // find first /turf object in members
first_turf_index++
- //instanciate the first /turf
+ // instanciate the first /turf
var/turf/T
if(members[first_turf_index] != /turf/template_noop)
- T = instance_atom(members[first_turf_index],members_attributes[first_turf_index],xcrd,ycrd,zcrd)
+ T = instance_atom(members[first_turf_index], members_attributes[first_turf_index], xcrd, ycrd, zcrd)
if(T)
- //if others /turf are presents, simulates the underlays piling effect
+ // if others /turf are presents, simulates the underlays piling effect
index = first_turf_index + 1
- while(index <= members.len - 1) // Last item is an /area
+ var/mlen = members.len - 1
+ while(index <= mlen) // Last item is an /area
var/underlay
if(istype(T, /turf)) // I blame this on the stupid clown who coded the BYOND map editor
underlay = T.appearance
- T = instance_atom(members[index],members_attributes[index],xcrd,ycrd,zcrd)//instance new turf
- if(ispath(members[index],/turf))
+ T = instance_atom(members[index], members_attributes[index], xcrd, ycrd, zcrd) // instance new turf
+ if(ispath(members[index], /turf))
T.underlays += underlay
index++
- //finally instance all remainings objects/mobs
- for(index in 1 to first_turf_index-1)
- instance_atom(members[index],members_attributes[index],xcrd,ycrd,zcrd)
+ // finally instance all remainings objects/mobs
+ for(index in 1 to first_turf_index - 1)
+ instance_atom(members[index], members_attributes[index], xcrd, ycrd, zcrd)
CHECK_TICK
////////////////
-//Helpers procs
+// Helpers procs
////////////////
-//Instance an atom at (x,y,z) and gives it the variables in attributes
-/dmm_suite/proc/instance_atom(path,list/attributes, x, y, z)
+// Instance an atom at (x, y, z) and gives it the variables in attributes
+/datum/dmm_suite/proc/instance_atom(path, list/attributes, x, y, z)
var/atom/instance
GLOB._preloader.setup(attributes, path)
- var/turf/T = locate(x,y,z)
+ var/turf/T = locate(x, y, z)
if(T)
if(ispath(path, /turf))
T.ChangeTurf(path, defer_change = TRUE, keep_icon = FALSE)
@@ -326,115 +319,111 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
else if(ispath(path, /area))
else
- instance = new path (T)//first preloader pass
+ instance = new path(T) // first preloader pass
- if(GLOB.use_preloader && instance)//second preloader pass, for those atoms that don't ..() in New()
+ if(GLOB.use_preloader && instance) // second preloader pass, for those atoms that don't ..() in New()
GLOB._preloader.load(instance)
return instance
-//text trimming (both directions) helper proc
-//optionally removes quotes before and after the text (for variable name)
-/dmm_suite/proc/trim_text(what as text,trim_quotes=0)
+// text trimming (both directions) helper proc
+// optionally removes quotes before and after the text (for variable name)
+/datum/dmm_suite/proc/trim_text(what, trim_quotes = FALSE)
if(trim_quotes)
return trimQuotesRegex.Replace(what, "")
else
return trimRegex.Replace(what, "")
-
-//find the position of the next delimiter,skipping whatever is comprised between opening_escape and closing_escape
-//returns 0 if reached the last delimiter
-/dmm_suite/proc/find_next_delimiter_position(text as text,initial_position as num, delimiter=",",opening_escape=quote,closing_escape=quote)
+// find the position of the next delimiter, skipping whatever is comprised between opening_escape and closing_escape
+// returns 0 if reached the last delimiter
+/datum/dmm_suite/proc/find_next_delimiter_position(text, initial_position = 0, delimiter = ",", opening_escape = quote, closing_escape = quote)
var/position = initial_position
- var/next_delimiter = findtext(text,delimiter,position,0)
- var/next_opening = findtext(text,opening_escape,position,0)
+ var/next_delimiter = findtext(text, delimiter, position, 0)
+ var/next_opening = findtext(text, opening_escape, position, 0)
while((next_opening != 0) && (next_opening < next_delimiter))
- position = findtext(text,closing_escape,next_opening + 1,0)+1
- next_delimiter = findtext(text,delimiter,position,0)
- next_opening = findtext(text,opening_escape,position,0)
+ position = findtext(text, closing_escape, next_opening + 1, 0) + 1
+ next_delimiter = findtext(text, delimiter, position, 0)
+ next_opening = findtext(text, opening_escape, position, 0)
return next_delimiter
-
-//build a list from variables in text form (e.g {var1="derp"; var2; var3=7} => list(var1="derp", var2, var3=7))
-//return the filled list
-/dmm_suite/proc/readlist(text as text, delimiter=",")
-
+// build a list from variables in text form (e.g {var1="derp"; var2; var3=7} => list(var1="derp", var2, var3=7))
+// return the filled list
+/datum/dmm_suite/proc/readlist(text, delimiter = ",")
var/list/to_return = list()
var/position
var/old_position = 1
do
- //find next delimiter that is not within "..."
- position = find_next_delimiter_position(text,old_position,delimiter)
+ // find next delimiter that is not within "..."
+ position = find_next_delimiter_position(text, old_position, delimiter)
- //check if this is a simple variable (as in list(var1, var2)) or an associative one (as in list(var1="foo",var2=7))
- var/equal_position = findtext(text,"=",old_position, position)
+ // check if this is a simple variable (as in list(var1, var2)) or an associative one (as in list(var1="foo", var2=7))
+ var/equal_position = findtext(text, "=", old_position, position)
- var/trim_left = trim_text(copytext(text,old_position,(equal_position ? equal_position : position)),1)//the name of the variable, must trim quotes to build a BYOND compliant associatives list
+ var/trim_left = trim_text(copytext(text, old_position, (equal_position ? equal_position : position)), 1) // the name of the variable, must trim quotes to build a BYOND compliant associatives list
old_position = position + 1
- if(equal_position)//associative var, so do the association
- var/trim_right = trim_text(copytext(text,equal_position+1,position))//the content of the variable
+ if(equal_position) // associative var, so do the association
+ var/trim_right = trim_text(copytext(text, equal_position + 1, position)) // the content of the variable
- //Check for string
+ // Check for string
// Make it read to the next delimiter, instead of the quote
- if(findtext(trim_right,quote,1,2))
- var/endquote = findtext(trim_right,quote,-1)
+ if(findtext(trim_right, quote, 1, 2))
+ var/endquote = findtext(trim_right, quote, -1)
if(!endquote)
log_runtime(EXCEPTION("Terminating quote not found!"), src)
// Our map writer escapes quotes and curly brackets to avoid
// letting our simple parser choke on meanly-crafted names/etc
// - so we decode it here so it's back to good ol' legibility
- trim_right = dmm_decode(copytext(trim_right,2,endquote))
+ trim_right = dmm_decode(copytext(trim_right, 2, endquote))
- //Check for number
+ // Check for number
else if(isnum(text2num(trim_right)))
trim_right = text2num(trim_right)
- //Check for null
+ // Check for null
else if(trim_right == "null")
trim_right = null
- //Check for list
- else if(copytext(trim_right,1,5) == "list")
- trim_right = readlist(copytext(trim_right,6,length(trim_right)))
+ // Check for list
+ else if(copytext(trim_right, 1, 5) == "list")
+ trim_right = readlist(copytext(trim_right, 6, length(trim_right)))
- //Check for file
- else if(copytext(trim_right,1,2) == "'")
- trim_right = file(copytext(trim_right,2,length(trim_right)))
+ // Check for file
+ else if(copytext(trim_right, 1, 2) == "'")
+ trim_right = file(copytext(trim_right, 2, length(trim_right)))
- //Check for path
+ // Check for path
else if(ispath(text2path(trim_right)))
trim_right = text2path(trim_right)
to_return[trim_left] = trim_right
- else//simple var
+ else// simple var
to_return[trim_left] = null
while(position != 0)
return to_return
-/dmm_suite/Destroy()
+/datum/dmm_suite/Destroy()
..()
return QDEL_HINT_HARDDEL_NOW
//////////////////
-//Preloader datum
+// Preloader datum
//////////////////
// This ain't re-entrant, but we had this before the maploader update
-/dmm_suite/preloader
- parent_type = /datum
+/datum/dmm_suite/preloader
var/list/attributes
var/target_path
var/json_ready = 0
-/dmm_suite/preloader/proc/setup(list/the_attributes, path)
+/datum/dmm_suite/preloader/proc/setup(list/the_attributes, path)
if(the_attributes.len)
json_ready = 0
if("map_json_data" in the_attributes)
@@ -443,25 +432,24 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
attributes = the_attributes
target_path = path
-/dmm_suite/preloader/proc/load(atom/what)
+/datum/dmm_suite/preloader/proc/load(atom/A)
if(json_ready)
- var/json_data = attributes["map_json_data"]
+ var/json_data = dmm_decode(attributes["map_json_data"])
attributes -= "map_json_data"
- json_data = dmm_decode(json_data)
try
- what.deserialize(json_decode(json_data))
- catch(var/exception/e)
+ A.deserialize(json_decode(json_data))
+ catch(var/exception/E)
log_runtime(EXCEPTION("Bad json data: '[json_data]'"), src)
- throw e
+ throw E
for(var/attribute in attributes)
var/value = attributes[attribute]
if(islist(value))
value = deepCopyList(value)
- what.vars[attribute] = value
+ A.vars[attribute] = value
GLOB.use_preloader = FALSE
// If the map loader fails, make this safe
-/dmm_suite/preloader/proc/reset()
+/datum/dmm_suite/preloader/proc/reset()
GLOB.use_preloader = FALSE
attributes = list()
target_path = null
@@ -470,12 +458,11 @@ GLOBAL_DATUM_INIT(_preloader, /dmm_suite/preloader, new())
// so that one can have separate "unpowered" areas for ruins or whatever,
// yet have a single area type for use of mapping, instead of creating
// a new area type for each new ruin
-/dmm_suite/loaded_map
- parent_type = /datum
+/datum/dmm_suite/loaded_map
var/list/area_list = list()
var/index = 1 // To store the state of the regex
-/dmm_suite/loaded_map/proc/area_path_to_real_area(area/A)
+/datum/dmm_suite/loaded_map/proc/area_path_to_real_area(area/A)
if(!ispath(A, /area))
throw EXCEPTION("Wrong argument to `area_path_to_real_area`")
diff --git a/code/modules/awaymissions/maploader/writer.dm b/code/modules/awaymissions/maploader/writer.dm
index c6d1fd589cf..b609f26c69d 100644
--- a/code/modules/awaymissions/maploader/writer.dm
+++ b/code/modules/awaymissions/maploader/writer.dm
@@ -5,28 +5,12 @@
#define DMM_IGNORE_PLAYERS 16
#define DMM_IGNORE_MOBS 24
#define DMM_USE_JSON 32
-/dmm_suite
- var/quote = "\""
- var/list/letter_digits = list(
- "a","b","c","d","e",
- "f","g","h","i","j",
- "k","l","m","n","o",
- "p","q","r","s","t",
- "u","v","w","x","y",
- "z",
- "A","B","C","D","E",
- "F","G","H","I","J",
- "K","L","M","N","O",
- "P","Q","R","S","T",
- "U","V","W","X","Y",
- "Z"
- )
-/dmm_suite/save_map(var/turf/t1 as turf, var/turf/t2 as turf, var/map_name as text, var/flags as num)
- //Check for illegal characters in file name... in a cheap way.
- if(!((ckeyEx(map_name)==map_name) && ckeyEx(map_name)))
+/datum/dmm_suite/proc/save_map(turf/t1, turf/t2, map_name = "", flags = 0)
+ // Check for illegal characters in file name... in a cheap way.
+ if(!((ckeyEx(map_name) == map_name) && ckeyEx(map_name)))
CRASH("Invalid text supplied to proc save_map, invalid characters or empty string.")
- //Check for valid turfs.
+ // Check for valid turfs.
if(!isturf(t1) || !isturf(t2))
CRASH("Invalid arguments supplied to proc save_map, arguments were not turfs.")
@@ -35,17 +19,17 @@
if(fexists(map_path))
fdel(map_path)
var/saved_map = file(map_path)
- var/map_text = write_map(t1,t2,flags,saved_map)
+ var/map_text = write_map(t1, t2, flags, saved_map)
saved_map << map_text
return saved_map
-/dmm_suite/write_map(var/turf/t1 as turf, var/turf/t2 as turf, var/flags as num)
- //Check for valid turfs.
+/datum/dmm_suite/proc/write_map(turf/t1, turf/t2, flags = 0)
+ // Check for valid turfs.
if(!isturf(t1) || !isturf(t2))
CRASH("Invalid arguments supplied to proc write_map, arguments were not turfs.")
- var/turf/ne = locate(max(t1.x,t2.x),max(t1.y,t2.y),max(t1.z,t2.z)) // Outer corner
- var/turf/sw = locate(min(t1.x,t2.x),min(t1.y,t2.y),min(t1.z,t2.z)) // Inner corner
+ var/turf/ne = locate(max(t1.x, t2.x), max(t1.y, t2.y), max(t1.z, t2.z)) // Outer corner
+ var/turf/sw = locate(min(t1.x, t2.x), min(t1.y, t2.y), min(t1.z, t2.z)) // Inner corner
var/list/templates[0]
var/list/template_buffer = list()
var/template_buffer_text
@@ -54,37 +38,40 @@
var/total_timer = start_watch()
var/timer = start_watch()
log_debug("Reading turfs...")
+
// Read the contents of all the turfs we were given
for(var/pos_z in sw.z to ne.z)
for(var/pos_y in ne.y to sw.y step -1) // We're reversing this because the map format is silly
for(var/pos_x in sw.x to ne.x)
- var/turf/test_turf = locate(pos_x,pos_y,pos_z)
+ var/turf/test_turf = locate(pos_x, pos_y, pos_z)
var/test_template = make_template(test_turf, flags)
var/template_number = templates.Find(test_template)
if(!template_number)
templates.Add(test_template)
- template_number = templates.len
+ template_number = length(templates)
template_buffer += "[template_number],"
CHECK_TICK
-
template_buffer += ";"
-
template_buffer += "."
- template_buffer_text = jointext(template_buffer,"")
+
+ template_buffer_text = jointext(template_buffer, "")
log_debug("Reading turfs took [stop_watch(timer)]s.")
- if(templates.len == 0)
+ if(length(templates) == 0)
CRASH("No templates found!")
- var/key_length = round/*floor*/(log(letter_digits.len,templates.len-1)+1)
- var/list/keys[templates.len]
+
+ var/key_length = round(log(length(letter_digits), length(templates) - 1) + 1) // or floor
+ var/list/keys[length(templates)]
+
// Write the list of key/model pairs to the file
timer = start_watch()
log_debug("Writing out key/model pairs to file header...")
var/list/key_models = list()
- for(var/key_pos in 1 to templates.len)
- keys[key_pos] = get_model_key(key_pos,key_length)
+ for(var/key_pos in 1 to length(templates))
+ keys[key_pos] = get_model_key(key_pos, key_length)
key_models += "\"[keys[key_pos]]\" = ([templates[key_pos]])\n"
CHECK_TICK
+
dmm_text += jointext(key_models,"")
log_debug("Writing key/model pairs complete, took [stop_watch(timer)]s.")
@@ -92,58 +79,69 @@
// Loop over all z in our zone
timer = start_watch()
log_debug("Writing out key map...")
+
var/list/key_map = list()
- for(var/z_pos=1;TRUE;z_pos=findtext(template_buffer_text,".",z_pos)+1)
- if(z_pos>=length(template_buffer_text)) break
- if(z_level) key_map += "\n"
+ for(var/z_pos = 1; TRUE; z_pos = findtext(template_buffer_text, ".", z_pos) + 1)
+ if(z_pos >= length(template_buffer_text))
+ break
+
+ if(z_level)
+ key_map += "\n"
+
key_map += "\n(1,1,[++z_level]) = {\"\n"
- var/z_block = copytext(template_buffer_text,z_pos,findtext(template_buffer_text,".",z_pos))
- for(var/y_pos=1;TRUE;y_pos=findtext(z_block,";",y_pos)+1)
- if(y_pos>=length(z_block)) break
- var/y_block = copytext(z_block,y_pos,findtext(z_block,";",y_pos))
+ var/z_block = copytext(template_buffer_text, z_pos, findtext(template_buffer_text, ".", z_pos))
+ for(var/y_pos = 1; TRUE; y_pos = findtext(z_block, ";", y_pos) + 1)
+ if(y_pos >= length(z_block))
+ break
+
+ var/y_block = copytext(z_block, y_pos, findtext(z_block, ";", y_pos))
// A row of keys
- for(var/x_pos=1;TRUE;x_pos=findtext(y_block,",",x_pos)+1)
- if(x_pos>=length(y_block)) break
- var/x_block = copytext(y_block,x_pos,findtext(y_block,",",x_pos))
+ for(var/x_pos = 1; TRUE; x_pos = findtext(y_block, ",", x_pos) + 1)
+ if(x_pos >= length(y_block))
+ break
+
+ var/x_block = copytext(y_block, x_pos, findtext(y_block, ",", x_pos))
var/key_number = text2num(x_block)
var/temp_key = keys[key_number]
key_map += temp_key
CHECK_TICK
key_map += "\n"
key_map += "\"}"
- dmm_text += jointext(key_map,"")
+
+ dmm_text += jointext(key_map, "")
log_debug("Writing key map complete, took [stop_watch(timer)]s.")
log_debug("TOTAL TIME: [stop_watch(total_timer)]s.")
+
return dmm_text
-/dmm_suite/proc/make_template(var/turf/model as turf, var/flags as num)
- var/use_json = 0
- if(flags & DMM_USE_JSON)
- use_json = 1
+/datum/dmm_suite/proc/make_template(turf/model, flags = 0)
+ var/use_json = (flags & DMM_USE_JSON) ? TRUE : FALSE
+
var/template = ""
var/turf_template = ""
var/list/obj_template = list()
var/list/mob_template = list()
var/area_template = ""
-
-
// Turf
if(!(flags & DMM_IGNORE_TURFS))
turf_template = "[model.type][check_attributes(model,use_json=use_json)],"
- else turf_template = "[world.turf],"
+ else
+ turf_template = "[world.turf],"
// Objects loop
if(!(flags & DMM_IGNORE_OBJS))
for(var/obj/O in model.contents)
if(O.dont_save || QDELETED(O))
continue
+
obj_template += "[O.type][check_attributes(O,use_json=use_json)],"
// Mobs Loop
for(var/mob/M in model.contents)
if(M.dont_save || QDELETED(M))
continue
+
if(M.client)
if(!(flags & DMM_IGNORE_PLAYERS))
mob_template += "[M.type][check_attributes(M,use_json=use_json)],"
@@ -155,65 +153,68 @@
if(!(flags & DMM_IGNORE_AREAS))
var/area/m_area = model.loc
area_template = "[m_area.type][check_attributes(m_area,use_json=use_json)]"
- else area_template = "[world.area]"
+ else
+ area_template = "[world.area]"
template = "[jointext(obj_template,"")][jointext(mob_template,"")][turf_template][area_template]"
return template
-/dmm_suite/proc/check_attributes(var/atom/A,use_json=0)
+/datum/dmm_suite/proc/check_attributes(atom/A, use_json = FALSE)
var/attributes_text = "{"
var/list/attributes = list()
if(!use_json)
for(var/V in A.vars)
CHECK_TICK
- if((!issaved(A.vars[V])) || (A.vars[V]==initial(A.vars[V]))) continue
+ if((!issaved(A.vars[V])) || (A.vars[V] == initial(A.vars[V])))
+ continue
attributes += var_to_dmm(A.vars[V], V)
else
- var/list/yeah = A.serialize()
+ var/list/to_encode = A.serialize()
// We'll want to write out vars that are important to the editor
// So that the map is legible as before
- for(var/thing in A.map_important_vars())
+ for(var/T in A.map_important_vars())
// Save vars that are important for the map editor, so that
// json-encoded maps are legible for standard editors
- if(A.vars[thing] != initial(A.vars[thing]))
- yeah -= thing
- attributes += var_to_dmm(A.vars[thing],thing)
+ if(A.vars[T] != initial(A.vars[T]))
+ to_encode -= T
+ attributes += var_to_dmm(A.vars[T], T)
// Remove useless info
- yeah -= "type"
- if(yeah.len)
- var/json_stuff = json_encode(yeah)
+ to_encode -= "type"
+ if(length(to_encode))
+ var/json_stuff = json_encode(to_encode)
attributes += var_to_dmm(json_stuff, "map_json_data")
- if(attributes.len == 0)
+
+ if(length(attributes) == 0)
return
// Trim a trailing semicolon - `var_to_dmm` always appends a semicolon,
// so the last one will be trailing.
- if(copytext(attributes_text, length(attributes_text)-1, 0) == "; ")
- attributes_text = copytext(attributes_text, 1, length(attributes_text)-1)
+ if(copytext(attributes_text, length(attributes_text) - 1, 0) == "; ")
+ attributes_text = copytext(attributes_text, 1, length(attributes_text) - 1)
+
attributes_text = "{[jointext(attributes,"; ")]}"
return attributes_text
-
-/dmm_suite/proc/get_model_key(var/which as num, var/key_length as num)
+/datum/dmm_suite/proc/get_model_key(which, key_length)
var/list/key = list()
- var/working_digit = which-1
+ var/working_digit = which - 1
for(var/digit_pos in key_length to 1 step -1)
- var/place_value = round/*floor*/(working_digit/(letter_digits.len**(digit_pos-1)))
- working_digit-=place_value*(letter_digits.len**(digit_pos-1))
- key += letter_digits[place_value+1]
+ var/place_value = round/*floor*/(working_digit / (length(letter_digits) ** (digit_pos - 1)))
+ working_digit -= place_value * (length(letter_digits) ** (digit_pos - 1))
+ key += letter_digits[place_value + 1]
+
return jointext(key,"")
-
-/dmm_suite/proc/var_to_dmm(attr, name)
+/datum/dmm_suite/proc/var_to_dmm(attr, name)
if(istext(attr))
// dmm_encode will strip out characters that would be capable of disrupting
// parsing - namely, quotes and curly braces
return "[name] = \"[dmm_encode(attr)]\""
- else if(isnum(attr)||ispath(attr))
+ else if(isnum(attr) || ispath(attr))
return "[name] = [attr]"
- else if(isicon(attr)||isfile(attr))
+ else if(isicon(attr) || isfile(attr))
if(length("[attr]") == 0)
// The DM map reader is unable to read files that have a '' file/icon entry
return
diff --git a/code/modules/busy_space/air_traffic.dm b/code/modules/busy_space/air_traffic.dm
deleted file mode 100644
index e21414e8ed3..00000000000
--- a/code/modules/busy_space/air_traffic.dm
+++ /dev/null
@@ -1,128 +0,0 @@
-//Cactus, Speedbird, Dynasty, oh my
-GLOBAL_DATUM_INIT(atc, /datum/lore/atc_controller, new)
-
-/datum/lore/atc_controller
- var/delay_max = 10 MINUTES //Maximum amount of tiem between ATC messages. Default is 10 mins.
- var/delay_min = 5 MINUTES //Minimum amount of time between ATC messages. Default is 5 mins.
- var/backoff_delay = 5 MINUTES //How long to back off if we can't talk and want to. Default is 5 mins.
- var/next_message //When the next message should happen in world.time
- var/force_chatter_type //Force a specific type of messages
-
- var/squelched = FALSE //If ATC is squelched currently
-
-/datum/lore/atc_controller/New()
- spawn(30 SECONDS) //Lots of lag at the start of a shift.
- msg("New shift beginning, resuming traffic control.")
- next_message = world.time + rand(delay_min, delay_max)
- process()
-
-/datum/lore/atc_controller/process()
- if(world.time >= next_message)
- if(squelched)
- next_message = world.time + backoff_delay
- else
- next_message = world.time + rand(delay_min,delay_max)
- random_convo()
-
- spawn(1 MINUTES) //We don't really need high-accuracy here.
- process()
-
-/datum/lore/atc_controller/proc/msg(var/message,var/sender)
- ASSERT(message)
- GLOB.global_announcer.autosay("[message]", sender ? sender : "[GLOB.using_map.station_short] Space Control")
-
-/datum/lore/atc_controller/proc/reroute_traffic(var/yes = 1)
- if(yes)
- if(!squelched)
- msg("Rerouting traffic away from [GLOB.using_map.station_name].")
- squelched = TRUE
- else
- if(squelched)
- msg("Resuming normal traffic routing around [GLOB.using_map.station_name].")
- squelched = FALSE
-
-/datum/lore/atc_controller/proc/shift_ending(var/evac = 0)
- msg("Automated Shuttle departing [GLOB.using_map.station_name] for [GLOB.using_map.dock_name] on routine transfer route.", "NT Automated Shuttle")
- sleep(5 SECONDS)
- msg("Automated Shuttle, cleared to complete routine transfer from [GLOB.using_map.station_name] to [GLOB.using_map.dock_name].")
-
-/datum/lore/atc_controller/proc/random_convo()
- var/one = pick(GLOB.loremaster.organizations) //These will pick an index, not an instance
- var/two = pick(GLOB.loremaster.organizations)
-
- var/datum/lore/organization/source = GLOB.loremaster.organizations[one] //Resolve to the instances
- var/datum/lore/organization/dest = GLOB.loremaster.organizations[two]
-
- //Let's get some mission parameters
- var/owner = source.short_name //Use the short name
- var/prefix = pick(source.ship_prefixes) //Pick a random prefix
- var/mission = source.ship_prefixes[prefix] //The value of the prefix is the mission type that prefix does
- var/shipname = pick(source.ship_names) //Pick a random ship name to go with it
- var/destname = pick(dest.destination_names) //Pick a random holding from the destination
-
- var/combined_name = "[owner] [prefix] [shipname]"
- var/alt_atc_names = list("[GLOB.using_map.station_short] TraCon", "[GLOB.using_map.station_short] Control", "[GLOB.using_map.station_short] STC", "[GLOB.using_map.station_short] Airspace")
- var/wrong_atc_names = list("Sol Command", "Orion Control", "[GLOB.using_map.dock_name]")
- var/mission_noun = list("flight", "mission", "route")
- var/request_verb = list("requesting", "calling for", "asking for")
-
- //First response is 'yes', second is 'no'
- var/requests = list("[GLOB.using_map.station_short] transit clearance" = list("cleared to transit", "unable to approve, contact regional on 953.5"),
- "planetary flight rules" = list("cleared planetary flight rules", "unable to approve planetary flight rules due to traffic"),
- "special flight rules" = list("cleared special flight rules", "unable to approve special flight rules for your traffic class"),
- "current solar weather info" = list("sending you the relevant information via tightbeam", "cannot fulfill your request at the moment"),
- "nearby traffic info" = list("sending you current traffic info", "no known traffic for your flight plan route"),
- "remote telemetry data" = list("sending telemetry now", "no uplink from your ship, recheck your uplink and ask again"),
- "refueling information" = list("sending refueling information now", "no fuel for your ship class in this sector"),
- "a current system time sync" = list("sending time sync ping to you now", "your ship isn't compatible with our time sync, set time manually"),
- "current system starcharts" = list("transmitting current starcharts", "request on standby due to demand"),
- "permission to engage FTL" = list("cleared to FTL, good day", "hold position, traffic crossing"),
- "permission to transit system" = list("cleared to transit, good day", "hold position, traffic crossing"),
- "permission to depart system" = list("cleared to leave via flight plan route, good day", "hold position, traffic crossing"),
- "permission to enter system" = list("good day, cleared in as published", "hold position, traffic crossing"),
- )
-
- //Random chance things for variety
- var/chatter_type = "normal"
- if(force_chatter_type)
- chatter_type = force_chatter_type
- else
- chatter_type = pick(2;"emerg",5;"wrong_freq","normal") //Be nice to have wrong_lang...
-
- var/yes = prob(90) //Chance for them to say yes vs no
-
- var/request = pick(requests)
- var/callname = pick(alt_atc_names)
- var/response = requests[request][yes ? 1 : 2] //1 is yes, 2 is no
-
- var/full_request
- var/full_response
- var/full_closure
-
- switch(chatter_type)
- if("wrong_freq")
- callname = pick(wrong_atc_names)
- full_request = "[callname], this is [combined_name] on a [mission] [pick(mission_noun)] to [destname], [pick(request_verb)] [request]."
- full_response = "[combined_name], this is [GLOB.using_map.station_short] TraCon, wrong frequency. Switch to [rand(700,999)].[rand(1,9)]."
- full_closure = "[GLOB.using_map.station_short] TraCon, copy, apologies."
- if("wrong_lang")
- //Can't implement this until autosay has language support
- if("emerg")
- var/problem = pick("hull breaches on multiple decks","unknown life forms on board","a drive about to go critical","asteroids impacting the hull","a total loss of engine power","people trying to board the ship")
- full_request = "Mayday, mayday, mayday, this is [combined_name] declaring an emergency! We have [problem]!"
- var/rand_freq = "[rand(700,999)].[rand(1,9)]"
- full_response = "[combined_name], this is [GLOB.using_map.station_short] TraCon, copy. Switch to emergency responder channel [rand_freq]."
- full_closure = "Roger, [GLOB.using_map.station_short] TraCon, contacting [rand_freq]."
- else
- full_request = "[callname], this is [combined_name] on a [mission] [pick(mission_noun)] to [destname], [pick(request_verb)] [request]."
- full_response = "[combined_name], this is [GLOB.using_map.station_short] TraCon, [response]." //Station TraCon always calls themselves TraCon
- full_closure = "[GLOB.using_map.station_short] TraCon, [yes ? "thank you" : "copy"], good day." //They always copy what TraCon called themselves in the end when they realize they said it wrong
-
- //Ship sends request to ATC
- msg(full_request,"[prefix] [shipname]")
- sleep(5 SECONDS)
- //ATC sends response to ship
- msg(full_response)
- sleep(5 SECONDS)
- //Ship sends response to ATC
- msg(full_closure,"[prefix] [shipname]")
diff --git a/code/modules/busy_space/loremaster.dm b/code/modules/busy_space/loremaster.dm
deleted file mode 100644
index 77b8a8ed53d..00000000000
--- a/code/modules/busy_space/loremaster.dm
+++ /dev/null
@@ -1,15 +0,0 @@
-//I AM THE LOREMASTER, ARE YOU THE GATEKEEPER?
-GLOBAL_DATUM_INIT(loremaster, /datum/lore/loremaster, new)
-
-/datum/lore/loremaster
- var/list/organizations = list()
-
-/datum/lore/loremaster/New()
-
- var/list/paths = typesof(/datum/lore/organization) - /datum/lore/organization
- for(var/path in paths)
- // Some intermediate paths are not real organizations (ex. /datum/lore/organization/mil). Only do ones with names
- var/datum/lore/organization/instance = path
- if(initial(instance.name))
- instance = new path()
- organizations[path] = instance
diff --git a/code/modules/busy_space/organizations.dm b/code/modules/busy_space/organizations.dm
deleted file mode 100644
index c39e92ea49e..00000000000
--- a/code/modules/busy_space/organizations.dm
+++ /dev/null
@@ -1,549 +0,0 @@
-//Datums for different companies that can be used by busy_space
-/datum/lore/organization
- var/name = "" // Organization's name
- var/short_name = "" // Organization's shortname (Nanotrasen for "Nanotrasen Incorporated")
- var/acronym = "" // Organization's acronym, e.g. 'NT' for Nanotrasen'.
- var/desc = "" // One or two paragraph description of the organization, but only current stuff. Currently unused.
- var/history = "" // Historical description of the organization's origins Currently unused.
- var/work = "" // Short description of their work, eg "an arms manufacturer"
- var/headquarters = "" // Location of the organization's HQ. Currently unused.
- var/motto = "" // A motto/jingle/whatever, if they have one. Currently unused.
-
- var/list/ship_prefixes = list() //Some might have more than one! Like Nanotrasen. Value is the mission they perform, e.g. ("ABC" = "mission desc")
- var/list/ship_names = list( //Names of spaceships. This is a mostly generic list that all the other organizations inherit from if they don't have anything better.
- "Kestrel",
- "Beacon",
- "Signal",
- "Freedom",
- "Glory",
- "Axiom",
- "Eternal",
- "Icarus",
- "Harmony",
- "Light",
- "Discovery",
- "Endeavour",
- "Explorer",
- "Swift",
- "Dragonfly",
- "Ascendant",
- "Tenacious",
- "Pioneer",
- "Hawk",
- "Haste",
- "Radiant",
- "Luminous",
- "Gallant",
- "Dependable",
- "Indomitable",
- "Guardian",
- "Resolution",
- "Fearless",
- "Amazon",
- "Relentless",
- "Inspire",
- "Implacable",
- "Steadfast",
- "Leviathan",
- "Dauntless",
- "Adroit",
- "Mistral",
- "Typhoon",
- "Titan",
- "Kupua",
- "Alchemist",
- "Cuirass",
- "Citadel",
- "Rondelle",
- "Camail",
- "Ocrea",
- "Ram",
- "Crest",
- "Tanko",
- "Pommel",
- "Kissaki",
- "Cavalier",
- "Anelace",
- "Flint",
- "Xiphos",
- "Parrot",
- "Chamber",
- "Annellet",
- "Cestus",
- "Talwar")
- var/list/destination_names = list() //Names of static holdings that the organization's ships visit regularly.
- var/autogenerate_destination_names = TRUE
-
-/datum/lore/organization/New()
- ..()
- if(autogenerate_destination_names) // Lets pad out the destination names.
- var/i = rand(6, 10)
- var/list/star_names = list(
- "Sol", "Alpha Centauri", "Sirius", "Vega", "Regulus", "Vir", "Algol", "Aldebaran",
- "Delta Doradus", "Menkar", "Geminga", "Elnath", "Gienah", "Mu Leporis", "Nyx", "Tau Ceti",
- "Wazn", "Alphard", "Phact", "Altair", "Mauna", "Jargon", "Xarxis", "Hestia", "Dalstis", "Cygni", "Haverick", "Corvus", "Sancere", "Cydoni", "Kaliban", "Midway", "Dansik", "Branwyn")
- var/list/destination_types = list("dockyard", "station", "vessel", "waystation", "telecommunications satellite", "spaceport", "distress beacon", "anomaly", "colony", "outpost")
- while(i)
- destination_names.Add("a [pick(destination_types)] in [pick(star_names)]")
- i--
-
-//////////////////////////////////////////////////////////////////////////////////
-
-// TSCs
-/datum/lore/organization/tsc/nanotrasen
- name = "Nanotrasen Incorporated"
- short_name = "Nanotrasen"
- acronym = "NT"
- desc = "The largest shareholder in the galactic plasma markets, Nanotrasen is a research and mining corporation which specializes in\
- FTL technologies and weapon systems. Frowned upon by most governments due to their shady business tactics and poor ethics record,\
- Nanotrasen is often seen as a necessary evil for maintaining access to the often volatile plasma market. Nanotrasen was originally\
- incorporated on Earth with their headquarters situated on Mars, however they have recently moved most of their operations to the Epsilon Eridani sector."
- history = "" // To be written someday.
- work = "research giant"
- headquarters = "Mars"
- motto = ""
-
- ship_prefixes = list("NSV" = "exploration", "NTV" = "hauling", "NDV" = "patrol", "NRV" = "emergency response")
- // Note that the current station being used will be pruned from this list upon being instantiated
- destination_names = list(
- "NAS Trurl in Epsilon Eridani",
- "NAS Crescent in Tau Ceti",
- "NSS Exodus in Tau Ceti",
- "NSS Antiqua in Darsing",
- "NRS Orion in Sol",
- "NSS Vector in Omicron Ceti",
- "NBS Anansi in Omicron Ceti",
- "NSS Redemption in Sirius",
- "NDS Inferno in Tau Ceti",
- "NAB Smythside Central Headquarters on Earth",
- "NAB North Cimmeria Central Offices on Mars",
- )
-
-/datum/lore/organization/tsc/nanotrasen/New()
- ..()
- spawn(1) // BYOND shenanigans means using_map is not initialized yet. Wait a tick.
- // Get rid of the current map from the list, so ships flying in don't say they're coming to the current map.
- var/string_to_test = "[GLOB.using_map.station_name] in [GLOB.using_map.starsys_name]"
- if(string_to_test in destination_names)
- destination_names.Remove(string_to_test)
-
-
-/datum/lore/organization/tsc/donk
- name = "Donk Corporation"
- short_name = "Donk Co."
- acronym = "DC"
- desc = "The infamous rival of the well-known Waffle Corporation, Donk Co. is a company specializing in food delivery systems and brand-name food\
- products such as Donk Pockets. While generally seen as a neutral actor, Donk Corporation has been known to work both with Nanotrasen and\
- the Syndicate when it suits them - often acting as the primary logistical supplier for the Epsilon Eridani sector.\
- Donk Corporation is better known for recent high-profile litigation alleging that their food products are used for illicit drug distribution.\
- While the trial is ongoing, it has been repeatedly delayed due to incidents of methamphetamine poisoning."
- history = ""
- work = "food company that establishes and maintains delivery supply chains"
- headquarters = ""
- motto = "Now with 20% more donk!"
-
- ship_prefixes = list("D-Co." = "transportation")
- destination_names = list()
-
-/datum/lore/organization/tsc/hephaestus
- name = "Hephaestus Industries"
- short_name = "Hephaestus"
- acronym = "HI"
- desc = ""
- history = ""
- work = "arms manufacturer"
- headquarters = ""
- motto = ""
-
- ship_prefixes = list("HTV" = "freight", "HTV" = "munitions resupply")
- destination_names = list(
- "a SolGov dockyard on Luna"
- )
-
-/datum/lore/organization/tsc/waffle
- name = "Waffle Corporation"
- short_name = "Waffle Co."
- acronym = "WC"
- desc = "The once prominent competitor of Donk Corporation, Waffle Co. is well-known for its popular line of Waffle Co.\
- brand waffles and their use of violent tactics against competitors - often bribing, extorting, blackmailing or sabotaging businesses\
- that pose a direct or indirect threat to their market share. They have recently fallen on hard times primarily due to to\
- severe mismanagement which lead to much of their private arsenal being swindled by a pirate faction known as the Gorlex Marauders.\
- Waffle Co. commonly engages in smear campaigns against Donk Co., maintaining that the original recipe for Donk Pockets was stolen from them."
- history = ""
- work = "food logistics and marketing firm"
- headquarters = ""
- motto = "Now that's a Waffle Co. Waffle!"
-
- ship_prefixes = list("W-Co." = "transportation")
- destination_names = list()
-
-
-/datum/lore/organization/tsc/einstein
- name = "Einstein Engines Incorporated"
- short_name = "Einstein Inc."
- acronym = "EEI"
- desc = "An Engineering firm specializing in alternative fuel-technologies for FTL travel,\
- Einstein Engines is an up and coming player in the galactic FTL and energy markets.\
- As their research into alternative FTL fuel threatens both Nanotrasen's relative stranglehold on plasma as well as The Syndicate's vested\
- interest in the market, they are often the target of industrial sabotage by both Nanotrasen and The Syndicate.\
- Most of their contracts are based outside of the Epsilon Eridani sector, and they are frequently commissioned by smaller firms to retrofit new\
- and existing colonies, space stations, and outposts."
- history = ""
- work = "engineering firm specializing in engine technology"
- headquarters = "Jargon 4"
- motto = ""
-
- ship_prefixes = list("EE-T" = "transportation")
- destination_names = list()
-
-/datum/lore/organization/tsc/zeng_hu
- name = "Zeng-Hu pharmaceuticals"
- short_name = "Zeng-Hu"
- acronym = "ZH"
- desc = ""
- history = ""
- work = "pharmaceuticals company"
- headquarters = ""
- motto = ""
-
- ship_prefixes = list("ZTV" = "transportation", "ZMV" = "medical resupply")
- destination_names = list()
-
-/datum/lore/organization/tsc/biotech
- name = "Biotech Solutions"
- short_name = "Biotech"
- acronym = "BTS"
- desc = "A company specializing in the field of synthetic biology, BioTech solutions is at the forefront of providing cutting-edge prosthetics,\
- augmentations, and gene-therapy solutions. Their extensive list of patents and the highly secretive nature of their work often puts them at odds\
- with companies such as Nanotrasen, who commonly reverse-engineer their products. BioTech Solutions is often the victim of industrial sabotage by\
- Cybersun Industries and often relies on planetary governments for asset protection. BioTech Solutions also owns a number of prominent subsidiaries,\
- such as Bishop Cybernetics, Hesphiastos Industries, and Xion Manufacturing Group."
- history = ""
- work = "medical company specializing in prosthetics and pharmaceuticals"
- headquarters = "Xarxis 5"
- motto = ""
-
- ship_prefixes = list("CIND-T" = "transportation")
- destination_names = list()
-
-/datum/lore/organization/tsc/ward_takahashi
- name = "Ward-Takahashi General Manufacturing Conglomerate"
- short_name = "Ward-Takahashi"
- acronym = "WT"
- desc = ""
- history = ""
- work = "electronics manufacturer"
- headquarters = ""
- motto = ""
-
- ship_prefixes = list("WTV" = "freight")
- destination_names = list(
- ""
- )
-
-/datum/lore/organization/tsc/cybersun
- name = "Cybersun Industries"
- short_name = "Cybersun Ind."
- acronym = "CI"
- desc = "Cybersun Industries is a biotechnology company that primarily specializes on the research and development of human-enhancing augmentations.\
- They are better known for their aggressive corporate tactics and are known to often subsidize pirate bands to commit acts of industrial sabotage.\
- Cybersun Industries is usually the target of conspiracy theorists due to their development of the first mindslave implant, as well as their open financing of,\
- and involvement in, The Syndicate. They are one of Nanotrasen's largest detractors, and a direct competitor to BioTech Solutions."
- history = ""
- work = "RND company specializing in augmentations and implants."
- headquarters = "Luna"
- motto = ""
-
- ship_prefixes = list("CIND-T" = "transportation")
- destination_names = list()
-
-/datum/lore/organization/tsc/bishop
- name = "Bishop Cybernetics"
- short_name = "Bishop"
- acronym = "BC"
- desc = ""
- history = ""
- work = "cybernetics and augmentation manufacturer"
- headquarters = ""
- motto = ""
-
- ship_prefixes = list("BTV" = "transportation")
- destination_names = list()
-
-/datum/lore/organization/tsc/morpheus
- name = "Morpheus Cyberkinetics"
- short_name = "Morpheus"
- acronym = "MC"
- desc = "The only large corporation run by positronic intelligences, Morpheus caters almost exclusively to their sensibilities \
- and needs. A product of the synthetic colony of Shelf, Morpheus eschews traditional advertising to keep their prices low and \
- relied on word of mouth among positronics to reach their current economic dominance. Morpheus in exchange lobbies heavily for \
- positronic rights, sponsors positronics through their Jans-Fhriede test, and tends to other positronic concerns to earn them \
- the good-will of the positronics, and the ire of those who wish to exploit them."
- history = ""
- work = "cybernetics manufacturer"
- headquarters = ""
- motto = ""
-
- ship_prefixes = list("MTV" = "freight")
- // Culture names, because Anewbe told me so.
- ship_names = list(
- "Nervous Energy",
- "Prosthetic Conscience",
- "Revisionist",
- "Trade Surplus",
- "Flexible Demeanour",
- "Just Read The Instructions",
- "Limiting Factor",
- "Cargo Cult",
- "Gunboat Diplomat",
- "A Ship With A View",
- "Cantankerous",
- "Never Talk To Strangers",
- "Sacrificial Victim",
- "Unwitting Accomplice",
- "Bad For Business",
- "Just Testing",
- "Yawning Angel",
- "Liveware Problem",
- "Very Little Gravitas Indeed",
- "Zero Gravitas",
- "Gravitas Free Zone",
- "Absolutely No You-Know-What",
- "Existence Is Pain",
- "Screw Loose",
- "Limiting Factor",
- "So Much For Subtley",
- "Unfortunate Conflict Of Evidence",
- "Prime Mover",
- "Reasonable Excuse",
- "Honest Mistake",
- "Appeal To Reason",
- "My First Ship II",
- "Hidden Income",
- "Anything Legal Considered",
- "New Toy",
- "Me, I'm Always Counting",
- "Great White Snark",
- "No Shirt No Shoes",
- "Callsign"
- )
- destination_names = list(
- "a dockyard on New Canaan"
- )
-
-/datum/lore/organization/tsc/xion
- name = "Xion Manufacturing Group"
- short_name = "Xion"
- desc = ""
- history = ""
- work = "industrial equipment manufacturer"
- headquarters = ""
- motto = ""
-
- ship_prefixes = list("XTV" = "hauling")
- destination_names = list()
-
-/datum/lore/organization/tsc/shellguard
- name = "Shellguard Munitions"
- short_name = "Shellguard"
- acronym = "SM"
- desc = "The brainchild of a colonial war veteran, Shellguard Munitions is an arms manufacturer and private military contractor specializing\
- in anti-synthetic weapon systems and platforms. Initially a smaller private military force only serving frontier colonies,\
- Shellguard Munitions has become a household name due to its involvement in resolving the Haverick AI crisis in 2552.\
- Using its recently earned fame, the company has made a successful foray into the market of robotics and is highly regarded for the toughness \
- and reliability of their hardware. Despite being frequently contracted by the Trans-Solar Federation, Shellguard Munitions is known to\
- sell their services to the highest corporate bidder."
- history = ""
- work = "anti-synthetic arms manufacturer and PMC"
- headquarters = "Colony of Haverick"
- motto = ""
-
- ship_prefixes = list("BTS-T" = "transportation")
- destination_names = list()
-
-// Governments
-
-
-/datum/lore/organization/gov/solgov
- name = "Trans-Solar Federation"
- short_name = "SolGov"
- acronym = "TSF"
- desc = "Colloquially known as SolGov, the TSF is an authoritarian republic that manages the areas in and around the Sol system.\
- Despite being a highly militant organization headed by the government of Earth,\
- SolGov is usually conservative with its power and mostly serves as a mediator and peacekeeper in galactic affairs."
- history = "" // Todo
- work = "governing polity of humanity's Confederation"
- headquarters = "Earth"
- motto = ""
- autogenerate_destination_names = TRUE
-
- ship_prefixes = list("FTV" = "transporation", "FDV" = "diplomatic", "FSF" = "freight", "FIV" = "interception", "FDV" = "defense", "FCV-A" = "carrier", "FBB" = "battleship")
- destination_names = list(
- "Venus",
- "Earth",
- "Luna",
- "Mars",
- "Titan",
- "Ahdomai",
- "Kelune",
- "Dalstadt",
- "New Canaan",
- "Jargon 4",
- "Hoorlm",
- "Xarxis 5",
- "Aurum",
- "Moghes",
- "Haverick",
- "Darsing",
- "Norfolk",
- "Boron",
- "Iluk")
-
-/datum/lore/organization/gov/tajara
- name = "The Alchemist's Council"
- short_name = "The Council"
- acronym = "AC"
- desc = "The Alchemist's Council is a science-oriented organization of scholars, researchers, and entrepreneurs. \
- Though dedicated to industrializing the Tajaran world of Ahdomai, it is seen as one of the few remaining centralized powers of the Tajara peoples \
- due to the collapse of Ahdomai's provisional government."
- history = "" // Todo
- work = "science body that oversees Tajara economic and research policy"
- headquarters = "Ahdomai"
- motto = ""
- autogenerate_destination_names = TRUE
-
- ship_prefixes = list("ACS" = "transportation", "ADV" = "diplomatic", "ACF" = "freight")
- destination_names = list(
- "Ahdomai",
- "Iluk")
-
-
-/datum/lore/organization/gov/vulp
- name = "The Assembly"
- short_name = "Assembly"
- acronym = "ASB"
- desc = "A unifying body created to stave off extinction from a solar event,\
- The Assembly is the loose federal coalition of the Vulpkanin. It holds little centralized authority and mostly serves as a diplomatic body,\
- primarily concerned with facilitating trade between Vulpkanin colonies and Nanotrasen."
- history = "" // Todo
- work = "governing body of the Vulpakanin"
- headquarters = "Kelune and Dalstadt"
- motto = ""
- autogenerate_destination_names = TRUE
-
- ship_prefixes = list("ATV" = "transportation", "ADV" = "diplomatic", "ACF" = "freight")
- destination_names = list(
- "Kelune",
- "Dalstadt",
- "New Canaan")
-
-/datum/lore/organization/gov/synth
- name = "Synthetic Union"
- short_name = "Synthetica"
- acronym = "SYN"
- desc = "A defensive coalition of synthetics based out of New Canaan,\
- the Synthetic Union is an organization which aims to establish and consolidate synthetic rights across the galaxy.\
- Despite its synth oriented focus, the Synthetic Union has cordial relations with most governing bodies."
- history = "" // Todo
- work = "Union of Machines"
- headquarters = "New Canaan"
- motto = ""
- autogenerate_destination_names = TRUE
-
- ship_prefixes = list("01" = "transportation", "10" = "diplomatic", "112" = "freight")//copyed from solgov until new ones can be thought of
- destination_names = list(
- "Luna",
- "Dalstadt",
- "New Canaan",
- "Jargon 4",
- "Haverick",
- "Darsing",
- "Norfolk")
-
-/datum/lore/organization/gov/grey
- name = "The Technocracy"
- short_name = "Technocracy"
- acronym = "AYY"
- desc = "The Technocracy is a science council that operates based off the principles of a meritocracy.\
- The organization's leadership is highly competitive, and is headed by the most psionically gifted members of the Grey species.\
- The Technocracy, though enigmatic in its dealings, has cordial relations with almost all other galactic bodies."
- history = "" // Todo
- work = "Grey Council"
- headquarters = ""
- motto = ""
- autogenerate_destination_names = TRUE
-
- ship_prefixes = list("TC-T" = "transportation", "TC-D" = "diplomatic", "TC-F" = "freight")
- destination_names = list(
- "Venus",
- "Earth",
- "Luna",
- "Mars",
- "Titan",
- "Ahdomai",
- "Kelune",
- "Dalstadt",
- "New Canaan",
- "Jargon 4",
- "Hoorlm",
- "Xarxis 5",
- "Aurum",
- "Moghes",
- "Haverick",
- "Darsing",
- "Norfolk",
- "Boron",
- "Iluk")
-
-/datum/lore/organization/gov/vox
- name = "The Shoal"
- short_name = "Shoal"
- acronym = "SHA"
- desc = "The Shoal is the primary ark ship of the reclusive Vox species.\
- Little is known about The Shoal's political structure as Vox typically shy away from diplomatic engagements.\
- Subsequently, it is considered a politically neutral entity in galactic affairs by most governments."
- history = "" // Todo
- work = "Traders"
- headquarters = "Shoal"
- motto = ""
- autogenerate_destination_names = FALSE
-
- ship_prefixes = list("Legitimate Transport" = "transportation", "Legitimate Trader" = "freight", "Legitimate Diplomatic Vessel" = "raider")
- destination_names = list(
- "Ahdomai",
- "Kelune",
- "Dalstadt",
- "New Canaan",
- "Jargon 4",
- "Hoorlm",
- "Xarxis 5",
- "Aurum",
- "Moghes",
- "Haverick",
- "Darsing")
-
-/datum/lore/organization/tsc/skrell
- name = "Skrellian Central Authority"
- short_name = "Skrellian CA."
- acronym = "SCA"
- desc = "The primary governing body of the Skrellian homeworld of Jargon 4,\
- the SCA oversees all foreign and domestic policy for the Skrell and their colonies. The Skrellian Central Authority is better known for its\
- active role in the largest military alliance in the galaxy, the Human-Skrellian Alliance."
- history = ""
- work = "oversees Skrell worlds"
- headquarters = "Jargon 4"
- motto = ""
-
- ship_prefixes = list("SCA-V." = "transportation", "SCA-F" = "freight", "HSA-D" = "diplomatic")
- destination_names = list(
- "Venus",
- "Earth",
- "Luna",
- "Mars",
- "Titan",
- "Aurumn",
- "Jargon 4",
- "Xarxis 5",
- "Haverick",
- "Darsing",
- "Norfolk")
diff --git a/code/modules/client/preference/loadout/loadout.dm b/code/modules/client/preference/loadout/loadout.dm
index 1091b38a11c..f1f0e2082de 100644
--- a/code/modules/client/preference/loadout/loadout.dm
+++ b/code/modules/client/preference/loadout/loadout.dm
@@ -9,39 +9,6 @@ GLOBAL_LIST_EMPTY(gear_datums)
category = cat
..()
-/hook/startup/proc/populate_gear_list()
- //create a list of gear datums to sort
- for(var/geartype in subtypesof(/datum/gear))
- var/datum/gear/G = geartype
-
- var/use_name = initial(G.display_name)
- var/use_category = initial(G.sort_category)
-
- if(G == initial(G.subtype_path))
- continue
-
- if(!use_name)
- error("Loadout - Missing display name: [G]")
- continue
- if(!initial(G.cost))
- error("Loadout - Missing cost: [G]")
- continue
- if(!initial(G.path))
- error("Loadout - Missing path definition: [G]")
- continue
-
- if(!GLOB.loadout_categories[use_category])
- GLOB.loadout_categories[use_category] = new /datum/loadout_category(use_category)
- var/datum/loadout_category/LC = GLOB.loadout_categories[use_category]
- GLOB.gear_datums[use_name] = new geartype
- LC.gear[use_name] = GLOB.gear_datums[use_name]
-
- GLOB.loadout_categories = sortAssoc(GLOB.loadout_categories)
- for(var/loadout_category in GLOB.loadout_categories)
- var/datum/loadout_category/LC = GLOB.loadout_categories[loadout_category]
- LC.gear = sortAssoc(LC.gear)
- return 1
-
/datum/gear
var/display_name //Name/index. Must be unique.
var/description //Description of this gear. If left blank will default to the description of the pathed item.
diff --git a/code/modules/client/preference/loadout/loadout_accessories.dm b/code/modules/client/preference/loadout/loadout_accessories.dm
index 09cc082dc5d..b9318fd9e8c 100644
--- a/code/modules/client/preference/loadout/loadout_accessories.dm
+++ b/code/modules/client/preference/loadout/loadout_accessories.dm
@@ -163,41 +163,41 @@
display_name = "armband, blue-yellow"
path = /obj/item/clothing/accessory/armband/yb
-/datum/gear/accessory/armband_sec
+/datum/gear/accessory/armband_job
+ subtype_path = /datum/gear/accessory/armband_job
+ subtype_cost_overlap = FALSE
+
+/datum/gear/accessory/armband_job/sec
display_name = " armband, security"
path = /obj/item/clothing/accessory/armband/sec
allowed_roles = list("Head of Security", "Warden", "Detective", "Security Officer", "Brig Physician", "Security Pod Pilot")
-/datum/gear/accessory/armband_cargo
+/datum/gear/accessory/armband_job/cargo
display_name = "cargo armband"
path = /obj/item/clothing/accessory/armband/cargo
allowed_roles = list("Quartermaster","Cargo Technician", "Shaft Miner")
-/datum/gear/accessory/armband_medical
+/datum/gear/accessory/armband_job/medical
display_name = "armband, medical"
path = /obj/item/clothing/accessory/armband/med
allowed_roles = list("Chief Medical Officer", "Medical Doctor", "Coroner", "Paramedic", "Brig Physician")
-/datum/gear/accessory/armband_emt
+/datum/gear/accessory/armband_job/emt
display_name = "armband, EMT"
path = /obj/item/clothing/accessory/armband/medgreen
allowed_roles = list("Paramedic", "Brig Physician")
-/datum/gear/accessory/armband_engineering
+/datum/gear/accessory/armband_job/engineering
display_name = "armband, engineering"
path = /obj/item/clothing/accessory/armband/engine
allowed_roles = list("Chief Engineer","Station Engineer", "Life Support Specialist")
-/datum/gear/accessory/armband_hydro
+/datum/gear/accessory/armband_job/hydro
display_name = "armband, hydroponics"
path = /obj/item/clothing/accessory/armband/hydro
allowed_roles = list("Botanist")
-/datum/gear/accessory/armband_sci
+/datum/gear/accessory/armband_job/sci
display_name = "armband, science"
path = /obj/item/clothing/accessory/armband/science
allowed_roles = list("Research Director","Scientist", "Roboticist")
-
-
-
-
diff --git a/code/modules/client/preference/loadout/loadout_hat.dm b/code/modules/client/preference/loadout/loadout_hat.dm
index 7d6275e09e4..4993c8502ea 100644
--- a/code/modules/client/preference/loadout/loadout_hat.dm
+++ b/code/modules/client/preference/loadout/loadout_hat.dm
@@ -42,11 +42,6 @@
display_name = "fedora, brown"
path = /obj/item/clothing/head/fedora/brownfedora
-/datum/gear/hat/beretsec
- display_name = "security beret"
- path = /obj/item/clothing/head/beret/sec
- allowed_roles = list("Head of Security", "Warden", "Security Officer", "Security Pod Pilot")
-
/datum/gear/hat/capcsec
display_name = "security corporate cap"
path = /obj/item/clothing/head/soft/sec/corp
@@ -113,32 +108,51 @@
display_name = "cowboy hat, pink"
path = /obj/item/clothing/head/cowboyhat/pink
-/datum/gear/hat/pr_beret
+/datum/gear/hat/beret_purple
display_name = "beret, purple"
path = /obj/item/clothing/head/beret/purple_normal
-/datum/gear/hat/bl_beret
+/datum/gear/hat/beret_black
display_name = "beret, black"
path = /obj/item/clothing/head/beret/black
-/datum/gear/hat/blu_beret
+/datum/gear/hat/beret_blue
display_name = "beret, blue"
path = /obj/item/clothing/head/beret/blue
-/datum/gear/hat/red_beret
+/datum/gear/hat/beret_red
display_name = "beret, red"
path = /obj/item/clothing/head/beret
-/datum/gear/hat/sci_beret
+/datum/gear/hat/beret_job
+ subtype_path = /datum/gear/hat/beret_job
+ subtype_cost_overlap = FALSE
+
+/datum/gear/hat/beret_job/sec
+ display_name = "security beret"
+ path = /obj/item/clothing/head/beret/sec
+ allowed_roles = list("Head of Security", "Warden", "Security Officer", "Security Pod Pilot")
+
+/datum/gear/hat/beret_job/sci
display_name = "science beret"
path = /obj/item/clothing/head/beret/sci
allowed_roles = list("Research Director", "Scientist")
-/datum/gear/hat/med_beret
+/datum/gear/hat/beret_job/med
display_name = "medical beret"
path = /obj/item/clothing/head/beret/med
allowed_roles = list("Chief Medical Officer", "Medical Doctor" , "Virologist", "Brig Physician" , "Coroner")
+/datum/gear/hat/beret_job/eng
+ display_name = "engineering beret"
+ path = /obj/item/clothing/head/beret/eng
+ allowed_roles = list("Chief Engineer", "Station Engineer")
+
+/datum/gear/hat/beret_job/atmos
+ display_name = "atmospherics beret"
+ path = /obj/item/clothing/head/beret/atmos
+ allowed_roles = list("Chief Engineer", "Life Support Specialist")
+
/datum/gear/hat/surgicalcap_purple
display_name = "surgical cap, purple"
path = /obj/item/clothing/head/surgery/purple
diff --git a/code/modules/client/preference/loadout/loadout_suit.dm b/code/modules/client/preference/loadout/loadout_suit.dm
index 32a9bae99e7..57e7ea63414 100644
--- a/code/modules/client/preference/loadout/loadout_suit.dm
+++ b/code/modules/client/preference/loadout/loadout_suit.dm
@@ -175,32 +175,36 @@
display_name = "regal shawl"
path = /obj/item/clothing/suit/mantle/regal
-/datum/gear/suit/captain_cloak
+/datum/gear/suit/mantle/job
+ subtype_path = /datum/gear/suit/mantle/job
+ subtype_cost_overlap = FALSE
+
+/datum/gear/suit/mantle/job/captain
display_name = "mantle, captain"
path = /obj/item/clothing/suit/mantle/armor/captain
allowed_roles = list("Captain")
-/datum/gear/suit/ce_mantle
+/datum/gear/suit/mantle/job/ce
display_name = "mantle, chief engineer"
path = /obj/item/clothing/suit/mantle/chief_engineer
allowed_roles = list("Chief Engineer")
-/datum/gear/suit/cmo_mantle
+/datum/gear/suit/mantle/job/cmo
display_name = "mantle, chief medical officer"
path = /obj/item/clothing/suit/mantle/labcoat/chief_medical_officer
allowed_roles = list("Chief Medical Officer")
-/datum/gear/suit/armored_shawl
+/datum/gear/suit/mantle/job/hos
display_name = "mantle, head of security"
path = /obj/item/clothing/suit/mantle/armor
allowed_roles = list("Head of Security")
-/datum/gear/suit/hop_shawl
+/datum/gear/suit/mantle/job/hop
display_name = "mantle, head of personnel"
path = /obj/item/clothing/suit/mantle/armor/head_of_personnel
allowed_roles = list("Head of Personnel")
-/datum/gear/suit/rd_mantle
+/datum/gear/suit/mantle/job/rd
display_name = "mantle, research director"
path = /obj/item/clothing/suit/mantle/labcoat
allowed_roles = list("Research Director")
diff --git a/code/modules/client/preference/preferences.dm b/code/modules/client/preference/preferences.dm
index 0b74b7132fd..12203b8155f 100644
--- a/code/modules/client/preference/preferences.dm
+++ b/code/modules/client/preference/preferences.dm
@@ -188,6 +188,7 @@ GLOBAL_LIST_INIT(special_role_times, list( //minimum age (in days) for accounts
// OOC Metadata:
var/metadata = ""
var/slot_name = ""
+ var/saved = FALSE // Indicates whether the character comes from the database or not
// Whether or not to use randomized character slots
var/randomslot = 0
@@ -263,10 +264,12 @@ GLOBAL_LIST_INIT(special_role_times, list( //minimum age (in days) for accounts
dat += "(Always Randomize) "
dat += ""
dat += ""
- dat += "Slot [slot_name] - "
+ dat += "Slot [default_slot][saved ? "" : " (empty)"] "
dat += "Load slot - "
dat += "Save slot - "
dat += "Reload slot"
+ if(saved)
+ dat += " - Clear slot"
dat += ""
dat += " | "
dat += ""
@@ -2078,6 +2081,11 @@ GLOBAL_LIST_INIT(special_role_times, list( //minimum age (in days) for accounts
load_preferences(user)
load_character(user)
+ if("clear")
+ if(!saved || real_name != input("This will clear the current slot permanently. Please enter the character's full name to confirm."))
+ return FALSE
+ clear_character_slot(user)
+
if("open_load_dialog")
if(!IsGuestKey(user.key))
open_load_dialog(user)
diff --git a/code/modules/client/preference/preferences_mysql.dm b/code/modules/client/preference/preferences_mysql.dm
index 4219935c766..e889ec5a181 100644
--- a/code/modules/client/preference/preferences_mysql.dm
+++ b/code/modules/client/preference/preferences_mysql.dm
@@ -121,6 +121,7 @@
return 1
/datum/preferences/proc/load_character(client/C,slot)
+ saved = FALSE
if(!slot) slot = default_slot
slot = sanitize_integer(slot, 1, max_save_slots, initial(default_slot))
@@ -262,6 +263,8 @@
loadout_gear = params2list(query.item[51])
autohiss_mode = text2num(query.item[52])
+ saved = TRUE
+
//Sanitize
var/datum/species/SP = GLOB.all_species[species]
metadata = sanitize_text(metadata, initial(metadata))
@@ -474,6 +477,8 @@
log_game("SQL ERROR during character slot saving. Error : \[[err]\]\n")
message_admins("SQL ERROR during character slot saving. Error : \[[err]\]\n")
return
+
+ saved = TRUE
return 1
/datum/preferences/proc/load_random_character_slot(client/C)
@@ -495,3 +500,20 @@
load_character(C,pick(saves))
return 1
+/datum/preferences/proc/clear_character_slot(client/C)
+ . = FALSE
+ // Is there a character in that slot?
+ var/DBQuery/query = GLOB.dbcon.NewQuery("SELECT slot FROM [format_table_name("characters")] WHERE ckey='[C.ckey]' AND slot='[default_slot]'")
+ query.Execute()
+ if(!query.RowCount())
+ return
+
+ var/DBQuery/query2 = GLOB.dbcon.NewQuery("DELETE FROM [format_table_name("characters")] WHERE ckey='[C.ckey]' AND slot='[default_slot]'")
+ if(!query2.Execute())
+ var/err = query2.ErrorMsg()
+ log_game("SQL ERROR during character slot clearing. Error : \[[err]\]\n")
+ message_admins("SQL ERROR during character slot clearing. Error : \[[err]\]\n")
+ return
+
+ saved = FALSE
+ return TRUE
diff --git a/code/modules/clothing/spacesuits/rig/modules/combat.dm b/code/modules/clothing/spacesuits/rig/modules/combat.dm
deleted file mode 100644
index 6b9d07a332d..00000000000
--- a/code/modules/clothing/spacesuits/rig/modules/combat.dm
+++ /dev/null
@@ -1,248 +0,0 @@
-/*
- * Contains
- * /obj/item/rig_module/grenade_launcher
- * /obj/item/rig_module/mounted
- * /obj/item/rig_module/mounted/taser
- * /obj/item/rig_module/shield
- * /obj/item/rig_module/fabricator
- * /obj/item/rig_module/device/flash
- */
-
-/obj/item/rig_module/device/flash
- name = "mounted flash"
- desc = "You are the law."
- icon_state = "flash"
- interface_name = "mounted flash"
- interface_desc = "Stuns your target by blinding them with a bright light."
- device_type = /obj/item/flash
-
-/obj/item/rig_module/grenade_launcher
-
- name = "mounted grenade launcher"
- desc = "A shoulder-mounted micro-explosive dispenser."
- selectable = 1
- icon_state = "grenade"
-
- interface_name = "integrated grenade launcher"
- interface_desc = "Discharges loaded grenades against the wearer's location."
-
- var/fire_force = 30
- var/fire_distance = 10
-
- charges = list(
- list("flashbang", "flashbang", /obj/item/grenade/flashbang, 3),
- list("smoke bomb", "smoke bomb", /obj/item/grenade/smokebomb, 3),
- list("EMP grenade", "EMP grenade", /obj/item/grenade/empgrenade, 3),
- )
-
-/obj/item/rig_module/grenade_launcher/accepts_item(var/obj/item/input_device, var/mob/living/user)
-
- if(!istype(input_device) || !istype(user))
- return 0
-
- var/datum/rig_charge/accepted_item
- for(var/charge in charges)
- var/datum/rig_charge/charge_datum = charges[charge]
- if(input_device.type == charge_datum.product_type)
- accepted_item = charge_datum
- break
-
- if(!accepted_item)
- return 0
-
- if(accepted_item.charges >= 5)
- to_chat(user, "Another grenade of that type will not fit into the module.")
- return 0
-
- to_chat(user, "You slot \the [input_device] into the suit module.")
- user.unEquip(input_device)
- qdel(input_device)
- accepted_item.charges++
- return 1
-
-/obj/item/rig_module/grenade_launcher/engage(atom/target)
-
- if(!..())
- return 0
-
- if(!target)
- return 0
-
- var/mob/living/carbon/human/H = holder.wearer
-
- if(!charge_selected)
- to_chat(H, "You have not selected a grenade type.")
- return 0
-
- var/datum/rig_charge/charge = charges[charge_selected]
-
- if(!charge)
- return 0
-
- if(charge.charges <= 0)
- to_chat(H, "Insufficient grenades!")
- return 0
-
- charge.charges--
- var/obj/item/grenade/new_grenade = new charge.product_type(get_turf(H))
- H.visible_message("[H] launches \a [new_grenade]!")
- new_grenade.throw_at(target,fire_force,fire_distance)
- new_grenade.prime()
-
-/obj/item/rig_module/mounted
-
- name = "mounted laser cannon"
- desc = "A shoulder-mounted battery-powered laser cannon mount."
- selectable = 1
- usable = 1
- module_cooldown = 0
- icon_state = "lcannon"
-
- engage_string = "Configure"
-
- interface_name = "mounted laser cannon"
- interface_desc = "A shoulder-mounted cell-powered laser cannon."
-
- var/gun_type = /obj/item/gun/energy/lasercannon/mounted
- var/obj/item/gun/gun
-
-/obj/item/rig_module/mounted/New()
- ..()
- gun = new gun_type(src)
-
-/obj/item/rig_module/mounted/engage(atom/target)
-
- if(!..())
- return 0
-
- if(!target)
- gun.attack_self(holder.wearer)
- return 1
-
- gun.afterattack(target,holder.wearer)
- return 1
-
-/obj/item/rig_module/mounted/egun
-
- name = "mounted energy gun"
- desc = "A forearm-mounted energy projector."
- icon_state = "egun"
-
- interface_name = "mounted energy gun"
- interface_desc = "A forearm-mounted suit-powered energy gun."
-
- gun_type = /obj/item/gun/energy/gun/mounted
-
-/obj/item/rig_module/mounted/taser
-
- name = "mounted taser"
- desc = "A palm-mounted nonlethal energy projector."
- icon_state = "taser"
-
- usable = 0
-
- suit_overlay_active = "mounted-taser"
- suit_overlay_inactive = "mounted-taser"
-
- interface_name = "mounted energy gun"
- interface_desc = "A shoulder-mounted cell-powered energy gun."
-
- gun_type = /obj/item/gun/energy/taser/mounted
-
-/obj/item/rig_module/mounted/energy_blade
-
- name = "energy blade projector"
- desc = "A powerful cutting beam projector."
- icon_state = "eblade"
-
- activate_string = "Project Blade"
- deactivate_string = "Cancel Blade"
-
- interface_name = "spider fang blade"
- interface_desc = "A lethal energy projector that can shape a blade projected from the hand of the wearer or launch radioactive darts."
-
- usable = 0
- selectable = 1
- toggleable = 1
- use_power_cost = 50
- active_power_cost = 10
- passive_power_cost = 0
-
- gun_type = /obj/item/gun/energy/kinetic_accelerator/crossbow/ninja
-
-/obj/item/rig_module/mounted/energy_blade/process()
-
- if(holder && holder.wearer)
- if(!(locate(/obj/item/melee/energy/blade) in holder.wearer))
- deactivate()
- return 0
-
- return ..()
-
-/obj/item/rig_module/mounted/energy_blade/activate()
-
- ..()
-
- var/mob/living/M = holder.wearer
-
- if(M.l_hand && M.r_hand)
- to_chat(M, "Your hands are full.")
- deactivate()
- return
-
- var/obj/item/melee/energy/blade/blade = new(M)
- M.put_in_hands(blade)
-
-/obj/item/rig_module/mounted/energy_blade/deactivate()
-
- ..()
-
- var/mob/living/M = holder.wearer
-
- if(!M)
- return
-
- for(var/obj/item/melee/energy/blade/blade in M.contents)
- M.unEquip(blade)
- qdel(blade)
-
-/obj/item/rig_module/fabricator
-
- name = "matter fabricator"
- desc = "A self-contained microfactory system for hardsuit integration."
- selectable = 1
- usable = 1
- use_power_cost = 15
- icon_state = "enet"
-
- engage_string = "Fabricate Tile"
-
- interface_name = "death blossom launcher"
- interface_desc = "An integrated microfactory that produces floor tiles from thin air and electricity."
-
- var/fabrication_type = /obj/item/stack/tile/plasteel
- var/fire_force = 30
- var/fire_distance = 10
-
-/obj/item/rig_module/fabricator/engage(atom/target)
-
- if(!..())
- return 0
-
- var/mob/living/H = holder.wearer
-
- if(target)
- var/obj/item/firing = new fabrication_type()
- firing.forceMove(get_turf(src))
- H.visible_message("[H] launches \a [firing]!")
- firing.throw_at(target,fire_force,fire_distance)
- else
- if(H.l_hand && H.r_hand)
- to_chat(H, "Your hands are full.")
- else
- var/obj/item/new_weapon = new fabrication_type()
- new_weapon.forceMove(H)
- to_chat(H, "You quickly fabricate \a [new_weapon].")
- H.put_in_hands(new_weapon)
-
- return 1
diff --git a/code/modules/clothing/spacesuits/rig/modules/computer.dm b/code/modules/clothing/spacesuits/rig/modules/computer.dm
deleted file mode 100644
index 749e12e8053..00000000000
--- a/code/modules/clothing/spacesuits/rig/modules/computer.dm
+++ /dev/null
@@ -1,496 +0,0 @@
-/*
- * Contains
- * /obj/item/rig_module/ai_container
- * /obj/item/rig_module/datajack
- * /obj/item/rig_module/power_sink
- * /obj/item/rig_module/electrowarfare_suite
- */
-
-/obj/item/ai_verbs
- name = "AI verb holder"
-
-/obj/item/ai_verbs/verb/hardsuit_interface()
- set category = "Hardsuit"
- set name = "Open Hardsuit Interface"
- set src in usr
-
- if(!usr.loc || !usr.loc.loc || !istype(usr.loc.loc, /obj/item/rig_module))
- to_chat(usr, "You are not loaded into a hardsuit.")
- return
-
- var/obj/item/rig_module/module = usr.loc.loc
- if(!module.holder)
- to_chat(usr, "Your module is not installed in a hardsuit.")
- return
-
- module.holder.ui_interact(usr, state = GLOB.contained_state)
-
-/obj/item/rig_module/ai_container
-
- name = "IIS module"
- desc = "An integrated intelligence system module suitable for most hardsuits."
- icon_state = "IIS"
- toggleable = 1
- usable = 1
- disruptive = 0
- activates_on_touch = 1
-
- engage_string = "Eject AI"
- activate_string = "Enable Dataspike"
- deactivate_string = "Disable Dataspike"
-
- interface_name = "integrated intelligence system"
- interface_desc = "A socket that supports a range of artificial intelligence systems."
-
- var/mob/integrated_ai // Direct reference to the actual mob held in the suit.
- var/obj/item/ai_card // Reference to the MMI, posibrain, intellicard or pAI card previously holding the AI.
- var/obj/item/ai_verbs/verb_holder
-
-/mob
- var/get_rig_stats = 0
-
-/obj/item/rig_module/ai_container/process()
- if(integrated_ai)
- var/obj/item/rig/rig = get_rig()
- if(rig && rig.ai_override_enabled)
- integrated_ai.get_rig_stats = 1
- else
- integrated_ai.get_rig_stats = 0
-
-/obj/item/rig_module/ai_container/proc/update_verb_holder()
- if(!verb_holder)
- verb_holder = new(src)
- if(integrated_ai)
- verb_holder.forceMove(integrated_ai)
- else
- verb_holder.forceMove(src)
-
-/obj/item/rig_module/ai_container/accepts_item(var/obj/item/input_device, var/mob/living/user)
-
- // Check if there's actually an AI to deal with.
- var/mob/living/silicon/ai/target_ai
- if(istype(input_device, /mob/living/silicon/ai))
- target_ai = input_device
- else
- target_ai = locate(/mob/living/silicon/ai) in input_device.contents
-
- var/obj/item/aicard/card = ai_card
-
- // Downloading from/loading to a terminal.
- if(istype(input_device,/obj/machinery/computer/aifixer) || istype(input_device,/mob/living/silicon/ai) || istype(input_device,/obj/structure/AIcore/deactivated))
-
- // If we're stealing an AI, make sure we have a card for it.
- if(!card)
- card = new /obj/item/aicard(src)
-
- // Terminal interaction only works with an intellicarded AI.
- if(!istype(card))
- return 0
-
- // Since we've explicitly checked for three types, this should be safe.
- card.afterattack(input_device, user, 1)
-
- // If the transfer failed we can delete the card.
- if(locate(/mob/living/silicon/ai) in card)
- ai_card = card
- integrated_ai = locate(/mob/living/silicon/ai) in card
- else
- eject_ai()
- update_verb_holder()
- return 1
-
- if(istype(input_device,/obj/item/aicard))
- // We are carding the AI in our suit.
- if(integrated_ai)
- var/obj/item/aicard/ext_card = input_device
- ext_card.afterattack(integrated_ai, user, 1)
- // If the transfer was successful, we can clear out our vars.
- if(integrated_ai.loc != src)
- integrated_ai = null
- eject_ai()
- else
- // You're using an empty card on an empty suit, idiot.
- if(!target_ai)
- return 0
- integrate_ai(input_device,user)
- return 1
-
- // Okay, it wasn't a terminal being touched, check for all the simple insertions.
- if(input_device.type in list(/obj/item/paicard, /obj/item/mmi, /obj/item/mmi/robotic_brain))
- if(integrated_ai)
- integrated_ai.attackby(input_device,user)
- // If the transfer was successful, we can clear out our vars.
- if(integrated_ai.loc != src)
- integrated_ai = null
- eject_ai()
- else
- integrate_ai(input_device,user)
- return 1
-
- return 0
-
-/obj/item/rig_module/ai_container/engage(atom/target)
-
- if(!..())
- return 0
-
- var/mob/living/carbon/human/H = holder.wearer
-
- if(!target)
- if(ai_card)
- if(istype(ai_card,/obj/item/aicard))
- ai_card.ui_interact(H, state = GLOB.deep_inventory_state)
- else
- eject_ai(H)
- update_verb_holder()
- return 1
-
- if(accepts_item(target,H))
- return 1
-
- return 0
-
-/obj/item/rig_module/ai_container/removed()
- eject_ai()
- ..()
-
-/obj/item/rig_module/ai_container/proc/eject_ai(var/mob/user)
-
- if(ai_card)
- if(istype(ai_card, /obj/item/aicard))
- if(integrated_ai && !integrated_ai.stat)
- if(user)
- to_chat(user, "You cannot eject your currently stored AI. Purge it manually.")
- return 0
- to_chat(user, "You purge the remaining scraps of data from your previous AI, freeing it for use.")
- QDEL_NULL(integrated_ai)
- QDEL_NULL(ai_card)
- else if(user)
- user.put_in_hands(ai_card)
- else
- ai_card.forceMove(get_turf(src))
- ai_card = null
- integrated_ai = null
- update_verb_holder()
-
-
-
-/obj/item/rig_module/ai_container/proc/integrate_ai(var/obj/item/ai,var/mob/user)
- if(!ai) return
-
- // The ONLY THING all the different AI systems have in common is that they all store the mob inside an item.
- var/mob/living/ai_mob = locate(/mob/living) in ai.contents
- if(ai_mob)
- if(ai_mob.key && ai_mob.client)
- if(istype(ai, /obj/item/aicard))
- var/mob/living/silicon/ai/ROBUTT = ai_mob
- if(istype(ROBUTT))
- if(!ai_card)
- ai_card = new /obj/item/aicard(src)
-
- var/obj/item/aicard/source_card = ai
- var/obj/item/aicard/target_card = ai_card
- if(istype(source_card) && istype(target_card))
- ROBUTT.forceMove(target_card)
- ROBUTT.aiRestorePowerRoutine = 0//So the AI initially has power.
- ROBUTT.control_disabled = 1//Can't control things remotely if you're stuck in a card!
- ROBUTT.aiRadio.disabledAi = 1 //No talking on the built-in radio for you either!
- source_card.update_state()
- target_card.update_state()
- else
- return 0
-
- else
- user.unEquip(ai)
- ai.forceMove(src)
- ai_card = ai
- to_chat(ai_mob, "You have been transferred to \the [holder]'s [src].")
- to_chat(user, "You load [ai_mob] into \the [holder]'s [src].")
-
- integrated_ai = ai_mob
-
- if(!(locate(integrated_ai) in ai_card))
- integrated_ai = null
- eject_ai()
- else
- to_chat(user, "There is no active AI within \the [ai].")
- else
- to_chat(user, "There is no active AI within \the [ai].")
- update_verb_holder()
-
-/obj/item/rig_module/datajack
-
- name = "datajack module"
- desc = "A simple induction datalink module."
- icon_state = "datajack"
- toggleable = 1
- activates_on_touch = 1
- usable = 0
-
- activate_string = "Enable Datajack"
- deactivate_string = "Disable Datajack"
-
- interface_name = "contact datajack"
- interface_desc = "An induction-powered high-throughput datalink suitable for hacking encrypted networks."
- var/list/stored_research
-
-/obj/item/rig_module/datajack/New()
- ..()
- stored_research = list()
-
-/obj/item/rig_module/datajack/engage(atom/target)
-
- if(!..())
- return 0
-
- if(target)
- var/mob/living/carbon/human/H = holder.wearer
- if(!accepts_item(target,H))
- return 0
- return 1
-
-/obj/item/rig_module/datajack/accepts_item(var/obj/item/input_device, var/mob/living/user)
-
- if(istype(input_device,/obj/item/disk/tech_disk))
- to_chat(user, "You slot the disk into [src].")
- var/obj/item/disk/tech_disk/disk = input_device
- if(disk.stored)
- if(load_data(disk.stored))
- to_chat(user, "Download successful; disk erased.")
- disk.stored = null
- else
- to_chat(user, "The disk is corrupt. It is useless to you.")
- else
- to_chat(user, "The disk is blank. It is useless to you.")
- return 1
-
- // I fucking hate R&D code. This typecheck spam would be totally unnecessary in a sane setup.
- else if(istype(input_device,/obj/machinery))
- var/datum/research/incoming_files
- if(istype(input_device,/obj/machinery/computer/rdconsole))
- var/obj/machinery/computer/rdconsole/input_machine = input_device
- incoming_files = input_machine.files
- else if(istype(input_device,/obj/machinery/r_n_d/server))
- var/obj/machinery/r_n_d/server/input_machine = input_device
- incoming_files = input_machine.files
- else if(istype(input_device,/obj/machinery/mecha_part_fabricator))
- var/obj/machinery/mecha_part_fabricator/input_machine = input_device
- incoming_files = input_machine.files
-
- if(!incoming_files || !incoming_files.known_tech || !incoming_files.known_tech.len)
- to_chat(user, "Memory failure. There is nothing accessible stored on this terminal.")
- else
- // Maybe consider a way to drop all your data into a target repo in the future.
- if(load_data(incoming_files.known_tech))
- to_chat(user, "Download successful; local and remote repositories synchronized.")
- else
- to_chat(user, "Scan complete. There is nothing useful stored on this terminal.")
- return 1
- return 0
-
-/obj/item/rig_module/datajack/proc/load_data(var/incoming_data)
-
- if(islist(incoming_data))
- for(var/entry in incoming_data)
- load_data(entry)
- return 1
-
- if(istype(incoming_data, /datum/tech))
- var/data_found
- var/datum/tech/new_data = incoming_data
- for(var/datum/tech/current_data in stored_research)
- if(current_data.id == new_data.id)
- data_found = 1
- if(current_data.level < new_data.level)
- current_data.level = new_data.level
- break
- if(!data_found)
- stored_research += incoming_data
- return 1
- return 0
-
-/obj/item/rig_module/electrowarfare_suite
-
- name = "electrowarfare module"
- desc = "A bewilderingly complex bundle of fiber optics and chips."
- icon_state = "ewar"
- toggleable = 1
- usable = 0
-
- activate_string = "Enable Countermeasures"
- deactivate_string = "Disable Countermeasures"
-
- interface_name = "electrowarfare system"
- interface_desc = "An active counter-electronic warfare suite that disrupts AI tracking."
-
-/obj/item/rig_module/electrowarfare_suite/activate()
-
- if(!..())
- return
-
- // This is not the best way to handle this, but I don't want it to mess with ling camo
- var/mob/living/M = holder.wearer
- M.digitalcamo++
-
-/obj/item/rig_module/electrowarfare_suite/deactivate()
-
- if(!..())
- return
-
- var/mob/living/M = holder.wearer
- M.digitalcamo = max(0,(M.digitalcamo-1))
-
-/* //Not easily compatible with our current powernet, and is
-/obj/item/rig_module/power_sink // quite stupid anyways, iyam
-
- name = "hardsuit power sink"
- desc = "An heavy-duty power sink."
- icon_state = "powersink"
- toggleable = 1
- activates_on_touch = 1
- disruptive = 0
-
- activate_string = "Enable Power Sink"
- deactivate_string = "Disable Power Sink"
-
- interface_name = "niling d-sink"
- interface_desc = "Colloquially known as a power siphon, this module drains power through the suit hands into the suit battery."
-
- var/atom/interfaced_with // Currently draining power from this device.
- var/total_power_drained = 0
- var/drain_loc
-
-/obj/item/rig_module/power_sink/deactivate()
-
- if(interfaced_with)
- if(holder && holder.wearer)
- to_chat(holder.wearer, "Your power sink retracts as the module deactivates.")
- drain_complete()
- interfaced_with = null
- total_power_drained = 0
- return ..()
-
-/obj/item/rig_module/power_sink/activate()
- interfaced_with = null
- total_power_drained = 0
- return ..()
-
-/obj/item/rig_module/power_sink/engage(atom/target)
-
- if(!..())
- return 0
-
- //Target wasn't supplied or we're already draining.
- if(interfaced_with)
- return 0
-
- if(!target)
- return 1
-
- // Are we close enough?
- var/mob/living/carbon/human/H = holder.wearer
- if(!target.Adjacent(H))
- return 0
-
- // Is it a valid power source?
- if(target.drain_power(1) <= 0)
- return 0
-
- to_chat(H, "You begin draining power from [target]!")
- interfaced_with = target
- drain_loc = interfaced_with.loc
-
- holder.spark_system.start()
- playsound(H.loc, 'sound/effects/sparks2.ogg', 50, 1)
-
- return 1
-
-/obj/item/rig_module/power_sink/accepts_item(var/obj/item/input_device, var/mob/living/user)
- var/can_drain = input_device.drain_power(1)
- if(can_drain > 0)
- engage(input_device)
- return 1
- return 0
-
-/obj/item/rig_module/power_sink/process()
-
- if(!interfaced_with)
- return ..()
-
- var/mob/living/carbon/human/H
- if(holder && holder.wearer)
- H = holder.wearer
-
- if(!H || !istype(H))
- return 0
-
- holder.spark_system.start()
- playsound(H.loc, 'sound/effects/sparks2.ogg', 50, 1)
-
- if(!holder.cell)
- to_chat(H, "Your power sink flashes an error; there is no cell in your rig.")
- drain_complete(H)
- return
-
- if(!interfaced_with || !interfaced_with.Adjacent(H) || !(interfaced_with.loc == drain_loc))
- to_chat(H, "Your power sink retracts into its casing.")
- drain_complete(H)
- return
-
- if(holder.cell.fully_charged())
- to_chat(H, "Your power sink flashes an amber light; your rig cell is full.")
- drain_complete(H)
- return
-
- // Attempts to drain up to 40kW, determines this value from remaining cell capacity to ensure we don't drain too much..
- var/to_drain = min(40000, ((holder.cell.maxcharge - holder.cell.charge) / CELLRATE))
- var/target_drained = interfaced_with.drain_power(0,0,to_drain)
- if(target_drained <= 0)
- to_chat(H, "Your power sink flashes a red light; there is no power left in [interfaced_with].")
- drain_complete(H)
- return
-
- holder.cell.give(target_drained * CELLRATE)
- total_power_drained += target_drained
-
- return 1
-
-/obj/item/rig_module/power_sink/proc/drain_complete(var/mob/living/M)
-
- if(!interfaced_with)
- to_chat(if(M) M, "Total power drained: [round(total_power_drained/1000)]kJ.")
- else
- to_chat(if(M) M, "Total power drained from [interfaced_with]: [round(total_power_drained/1000)]kJ.")
- interfaced_with.drain_power(0,1,0) // Damage the victim.
-
- drain_loc = null
- interfaced_with = null
- total_power_drained = 0*/
-
-/*
-//Maybe make this use power when active or something
-/obj/item/rig_module/emp_shielding
- name = "\improper EMP dissipation module"
- desc = "A bewilderingly complex bundle of fiber optics and chips."
- toggleable = 1
- usable = 0
-
- activate_string = "Enable active EMP shielding"
- deactivate_string = "Disable active EMP shielding"
-
- interface_name = "active EMP shielding system"
- interface_desc = "A highly experimental system that augments the hardsuit's existing EM shielding."
- var/protection_amount = 20
-
-/obj/item/rig_module/emp_shielding/activate()
- if(!..())
- return
-
- holder.emp_protection += protection_amount
-
-/obj/item/rig_module/emp_shielding/deactivate()
- if(!..())
- return
-
- holder.emp_protection = max(0,(holder.emp_protection - protection_amount))
-*/
diff --git a/code/modules/clothing/spacesuits/rig/modules/handheld.dm b/code/modules/clothing/spacesuits/rig/modules/handheld.dm
deleted file mode 100644
index 31f9400afc2..00000000000
--- a/code/modules/clothing/spacesuits/rig/modules/handheld.dm
+++ /dev/null
@@ -1,50 +0,0 @@
-
-/obj/item/rig_module/handheld
- name = "mounted device"
- desc = "Some kind of hardsuit extension."
- usable = 0
- selectable = 0
- toggleable = 1
- disruptive = 0
- activate_string = "Deploy"
- deactivate_string = "Retract"
-
- var/device_type
- var/obj/item
-
-/obj/item/rig_module/handheld/activate()
- if(!..())
- return
-
- if(!holder.wearer.put_in_hands(device))
- to_chat(holder.wearer, "You need a free hand to hold \the [device].")
- active = 0
- return
-
- to_chat(holder.wearer, "You deploy \the [device].")
-
-
-/obj/item/rig_module/handheld/deactivate()
- if(!..())
- return
- if(ismob(device.loc)) //Better check for the holder, instead of assuming the rigwearer has it.
- var/mob/M = device.loc //Helps in case the code fails to keep the module in one place, this should still return it.
- M.unEquip(device, 1)
-
- device.loc = src
- to_chat(holder.wearer, "You retract \the [device].")
-
-/obj/item/rig_module/handheld/New()
- ..()
- if(device_type)
- device = new device_type(src)
- device.flags |= NODROP //We don't want to drop it while it's active/inhand.
- activate_string += " [device]"
- deactivate_string += " [device]"
-
-/obj/item/rig_module/handheld/horn
- name = "mounted bikehorn"
- desc = "For tactical honking"
- interface_name = "mounted bikehorn"
- interface_desc = "Honks"
- device_type = /obj/item/bikehorn
diff --git a/code/modules/clothing/spacesuits/rig/modules/modules.dm b/code/modules/clothing/spacesuits/rig/modules/modules.dm
deleted file mode 100644
index 53330341bfe..00000000000
--- a/code/modules/clothing/spacesuits/rig/modules/modules.dm
+++ /dev/null
@@ -1,330 +0,0 @@
-/*
- * Rigsuit upgrades/abilities.
- */
-
-/datum/rig_charge
- var/short_name = "undef"
- var/display_name = "undefined"
- var/product_type = "undefined"
- var/charges = 0
-
-/obj/item/rig_module
- name = "hardsuit upgrade"
- desc = "It looks pretty sciency."
- icon = 'icons/obj/rig_modules.dmi'
- icon_state = "module"
-
- toolspeed = 1
-
- var/damage = 0
- var/obj/item/rig/holder
-
- var/module_cooldown = 10
- var/next_use = 0
-
- var/toggleable // Set to 1 for the device to show up as an active effect.
- var/usable // Set to 1 for the device to have an on-use effect.
- var/selectable // Set to 1 to be able to assign the device as primary system.
- var/redundant // Set to 1 to ignore duplicate module checking when installing.
- var/permanent // If set, the module can't be removed.
- var/disruptive = 1 // Can disrupt by other effects.
- var/activates_on_touch // If set, unarmed attacks will call engage() on the target.
-
- var/active // Basic module status
- var/disruptable // Will deactivate if some other powers are used.
-
- var/use_power_cost = 0 // Power used when single-use ability called.
- var/active_power_cost = 0 // Power used when turned on.
- var/passive_power_cost = 0 // Power used when turned off.
-
- var/list/charges // Associative list of charge types and remaining numbers.
- var/charge_selected // Currently selected option used for charge dispensing.
-
- // Icons.
- var/suit_overlay
- var/suit_overlay_active // If set, drawn over icon and mob when effect is active.
- var/suit_overlay_inactive // As above, inactive.
- var/suit_overlay_used // As above, when engaged.
-
- //Display fluff
- var/interface_name = "hardsuit upgrade"
- var/interface_desc = "A generic hardsuit upgrade."
- var/engage_string = "Engage"
- var/activate_string = "Activate"
- var/deactivate_string = "Deactivate"
-
- var/list/stat_rig_module/stat_modules = new()
-
-/obj/item/rig_module/examine(mob/user)
- . = ..()
- switch(damage)
- if(0)
- . += "It is undamaged."
- if(1)
- . += "It is badly damaged."
- if(2)
- . += "It is almost completely destroyed."
-
-/obj/item/rig_module/attackby(obj/item/W as obj, mob/user as mob)
-
- if(istype(W,/obj/item/stack/nanopaste))
-
- if(damage == 0)
- to_chat(user, "There is no damage to mend.")
- return
-
- to_chat(user, "You start mending the damaged portions of \the [src]...")
-
- if(!do_after(user, 30 * W.toolspeed, target = src) || !W || !src)
- return
-
- var/obj/item/stack/nanopaste/paste = W
- damage = 0
- to_chat(user, "You mend the damage to [src] with [W].")
- paste.use(1)
- return
-
- else if(istype(W,/obj/item/stack/cable_coil))
-
- switch(damage)
- if(0)
- to_chat(user, "There is no damage to mend.")
- return
- if(2)
- to_chat(user, "There is no damage that you are capable of mending with such crude tools.")
- return
-
- var/obj/item/stack/cable_coil/cable = W
- if(!cable.amount >= 5)
- to_chat(user, "You need five units of cable to repair \the [src].")
- return
-
- to_chat(user, "You start mending the damaged portions of \the [src]...")
- if(!do_after(user, 30 * W.toolspeed, target = src) || !W || !src)
- return
-
- damage = 1
- to_chat(user, "You mend some of damage to [src] with [W], but you will need more advanced tools to fix it completely.")
- cable.use(5)
- return
- ..()
-
-/obj/item/rig_module/New()
- ..()
- if(suit_overlay_inactive)
- suit_overlay = suit_overlay_inactive
-
- if(charges && charges.len)
- var/list/processed_charges = list()
- for(var/list/charge in charges)
- var/datum/rig_charge/charge_dat = new
-
- charge_dat.short_name = charge[1]
- charge_dat.display_name = charge[2]
- charge_dat.product_type = charge[3]
- charge_dat.charges = charge[4]
-
- if(!charge_selected) charge_selected = charge_dat.short_name
- processed_charges[charge_dat.short_name] = charge_dat
-
- charges = processed_charges
-
- stat_modules += new/stat_rig_module/activate(src)
- stat_modules += new/stat_rig_module/deactivate(src)
- stat_modules += new/stat_rig_module/engage(src)
- stat_modules += new/stat_rig_module/select(src)
- stat_modules += new/stat_rig_module/charge(src)
-
-// Called when the module is installed into a suit.
-/obj/item/rig_module/proc/installed(var/obj/item/rig/new_holder)
- holder = new_holder
- return
-
-//Proc for one-use abilities like teleport.
-/obj/item/rig_module/proc/engage()
-
- if(damage >= 2)
- to_chat(usr, "The [interface_name] is damaged beyond use!")
- return 0
-
- if(world.time < next_use)
- to_chat(usr, "You cannot use the [interface_name] again so soon.")
- return 0
-
- if(!holder || (!(holder.flags & NODROP)))
- to_chat(usr, "The suit is not initialized.")
- return 0
-
- if(usr.lying || usr.stat || usr.stunned || usr.paralysis || usr.IsWeakened())
- to_chat(usr, "You cannot use the suit in this state.")
- return 0
-
- if(holder.wearer && holder.wearer.lying)
- to_chat(usr, "The suit cannot function while the wearer is prone.")
- return 0
-
- if(holder.security_check_enabled && !holder.check_suit_access(usr))
- to_chat(usr, "Access denied.")
- return 0
-
- if(!holder.check_power_cost(usr, use_power_cost, 0, src, (istype(usr,/mob/living/silicon ? 1 : 0) ) ) )
- return 0
-
- next_use = world.time + module_cooldown
-
- return 1
-
-// Proc for toggling on active abilities.
-/obj/item/rig_module/proc/activate()
-
- if(active || !engage())
- return 0
-
- active = 1
-
- spawn(1)
- if(suit_overlay_active)
- suit_overlay = suit_overlay_active
- else
- suit_overlay = null
- holder.update_icon()
-
- return 1
-
-// Proc for toggling off active abilities.
-/obj/item/rig_module/proc/deactivate()
-
- if(!active)
- return 0
-
- active = 0
-
- spawn(1)
- if(suit_overlay_inactive)
- suit_overlay = suit_overlay_inactive
- else
- suit_overlay = null
- if(holder)
- holder.update_icon()
-
- return 1
-
-// Called when the module is uninstalled from a suit.
-/obj/item/rig_module/proc/removed()
- deactivate()
- holder = null
- return
-
-// Called by the hardsuit each rig process tick.
-/obj/item/rig_module/process()
- if(active)
- return active_power_cost
- else
- return passive_power_cost
-
-// Called by holder rigsuit attackby()
-// Checks if an item is usable with this module and handles it if it is
-/obj/item/rig_module/proc/accepts_item(var/obj/item/input_device)
- return 0
-
-/mob/proc/SetupStat(var/obj/item/rig/R)
- if(R && (R.flags & NODROP) && R.installed_modules.len && statpanel("Hardsuit Modules"))
- var/cell_status = R.cell ? "[R.cell.charge]/[R.cell.maxcharge]" : "ERROR"
- stat("Suit charge", cell_status)
- for(var/obj/item/rig_module/module in R.installed_modules)
- {
- for(var/stat_rig_module/SRM in module.stat_modules)
- if(SRM.CanUse())
- stat(SRM.module.interface_name,SRM)
- }
-
-/stat_rig_module
- parent_type = /atom/movable
- var/module_mode = ""
- var/obj/item/rig_module/module
-
-/stat_rig_module/New(var/obj/item/rig_module/module)
- ..()
- src.module = module
-
-/stat_rig_module/proc/AddHref(var/list/href_list)
- return
-
-/stat_rig_module/proc/CanUse()
- return 0
-
-/stat_rig_module/Click()
- if(CanUse())
- var/list/href_list = list(
- "interact_module" = module.holder.installed_modules.Find(module),
- "module_mode" = module_mode
- )
- AddHref(href_list)
- module.holder.Topic(usr, href_list)
-
-/stat_rig_module/DblClick()
- return Click()
-
-/stat_rig_module/activate/New(var/obj/item/rig_module/module)
- ..()
- name = module.activate_string
- if(module.active_power_cost)
- name += " ([module.active_power_cost*10]A)"
- module_mode = "activate"
-
-/stat_rig_module/activate/CanUse()
- return module.toggleable && !module.active
-
-/stat_rig_module/deactivate/New(var/obj/item/rig_module/module)
- ..()
- name = module.deactivate_string
- // Show cost despite being 0, if it means changing from an active cost.
- if(module.active_power_cost || module.passive_power_cost)
- name += " ([module.passive_power_cost*10]P)"
-
- module_mode = "deactivate"
-
-/stat_rig_module/deactivate/CanUse()
- return module.toggleable && module.active
-
-/stat_rig_module/engage/New(var/obj/item/rig_module/module)
- ..()
- name = module.engage_string
- if(module.use_power_cost)
- name += " ([module.use_power_cost*10]E)"
- module_mode = "engage"
-
-/stat_rig_module/engage/CanUse()
- return module.usable
-
-/stat_rig_module/select/New()
- ..()
- name = "Select"
- module_mode = "select"
-
-/stat_rig_module/select/CanUse()
- if(module.selectable)
- name = module.holder.selected_module == module ? "Selected" : "Select"
- return 1
- return 0
-
-/stat_rig_module/charge/New()
- ..()
- name = "Change Charge"
- module_mode = "select_charge_type"
-
-/stat_rig_module/charge/AddHref(var/list/href_list)
- var/charge_index = module.charges.Find(module.charge_selected)
- if(!charge_index)
- charge_index = 0
- else
- charge_index = charge_index == module.charges.len ? 1 : charge_index+1
-
- href_list["charge_type"] = module.charges[charge_index]
-
-/stat_rig_module/charge/CanUse()
- if(module.charges && module.charges.len)
- var/datum/rig_charge/charge = module.charges[module.charge_selected]
- name = "[charge.display_name] ([charge.charges]C) - Change"
- return 1
- return 0
diff --git a/code/modules/clothing/spacesuits/rig/modules/ninja.dm b/code/modules/clothing/spacesuits/rig/modules/ninja.dm
deleted file mode 100644
index 6e4b588ac24..00000000000
--- a/code/modules/clothing/spacesuits/rig/modules/ninja.dm
+++ /dev/null
@@ -1,196 +0,0 @@
-/*
- * Contains
- * /obj/item/rig_module/stealth_field
- * /obj/item/rig_module/teleporter
- * /obj/item/rig_module/fabricator/energy_net
- * /obj/item/rig_module/self_destruct
- */
-
-/obj/item/rig_module/stealth_field
-
- name = "active camouflage module"
- desc = "A robust hardsuit-integrated stealth module."
- icon_state = "cloak"
-
- toggleable = 1
- disruptable = 1
- disruptive = 0
-
- use_power_cost = 50
- active_power_cost = 10
- passive_power_cost = 0
- module_cooldown = 30
-
- activate_string = "Enable Cloak"
- deactivate_string = "Disable Cloak"
-
- interface_name = "integrated stealth system"
- interface_desc = "An integrated active camouflage system."
-
- suit_overlay_active = "stealth_active"
- suit_overlay_inactive = "stealth_inactive"
-
-/obj/item/rig_module/stealth_field/activate()
-
- if(!..())
- return 0
-
- var/mob/living/carbon/human/H = holder.wearer
-
- to_chat(H, "You are now invisible to normal detection.")
- H.invisibility = INVISIBILITY_LEVEL_TWO
-
- H.visible_message("[H.name] vanishes into thin air!",1)
-
-/obj/item/rig_module/stealth_field/deactivate()
-
- if(!..())
- return 0
-
- var/mob/living/carbon/human/H = holder.wearer
-
- to_chat(H, "You are now visible.")
- H.invisibility = 0
-
- new /obj/effect/temp_visual/dir_setting/ninja(get_turf(H), H.dir)
-
- for(var/mob/O in oviewers(H))
- O.show_message("[H.name] appears from thin air!",1)
- playsound(get_turf(H), 'sound/effects/stealthoff.ogg', 75, 1)
-
-
-/obj/item/rig_module/teleporter
-
- name = "teleportation module"
- desc = "A complex, sleek-looking, hardsuit-integrated teleportation module."
- icon_state = "teleporter"
- use_power_cost = 40
- redundant = 1
- usable = 1
- selectable = 1
-
- engage_string = "Emergency Leap"
-
- interface_name = "VOID-shift phase projector"
- interface_desc = "An advanced teleportation system. It is capable of pinpoint precision or random leaps forward."
-
-/obj/item/rig_module/teleporter/proc/phase_in(var/mob/M,var/turf/T)
-
- if(!M || !T)
- return
-
- holder.spark_system.start()
- playsound(T, 'sound/effects/phasein.ogg', 25, 1)
- playsound(T, 'sound/effects/sparks2.ogg', 50, 1)
- new /obj/effect/temp_visual/dir_setting/ninja/phase(T, M.dir)
-
-/obj/item/rig_module/teleporter/proc/phase_out(var/mob/M,var/turf/T)
-
- if(!M || !T)
- return
-
- playsound(T, "sparks", 50, 1)
- new /obj/effect/temp_visual/dir_setting/ninja/phase/out(T, M.dir)
-
-/obj/item/rig_module/teleporter/engage(var/atom/target, var/notify_ai)
-
- if(!..()) return 0
-
- var/mob/living/carbon/human/H = holder.wearer
-
- if(!istype(H.loc, /turf))
- to_chat(H, "You cannot teleport out of your current location.")
- return 0
-
- var/turf/T
- if(target)
- T = get_turf(target)
- else
- T = get_teleport_loc(get_turf(H), H, rand(5, 9))
-
- /*if(!T || T.density)
- to_chat(H, "You cannot teleport into solid walls.")
- return 0*///Who the fuck cares? Ninjas in walls are cool.
-
- if(!is_teleport_allowed(T.z))
- to_chat(H, "You cannot use your teleporter on this Z-level.")
- return 0
-
- phase_out(H,get_turf(H))
- H.forceMove(T)
- phase_in(H,get_turf(H))
-
- for(var/obj/item/grab/G in H.contents)
- if(G.affecting)
- phase_out(G.affecting,get_turf(G.affecting))
- G.affecting.forceMove(locate(T.x+rand(-1,1),T.y+rand(-1,1),T.z))
- phase_in(G.affecting,get_turf(G.affecting))
-
- return 1
-
-/*
-/obj/item/rig_module/fabricator/energy_net
-
- name = "net projector"
- desc = "Some kind of complex energy projector with a hardsuit mount."
- icon_state = "enet"
-
- interface_name = "energy net launcher"
- interface_desc = "An advanced energy-patterning projector used to capture targets."
-
- engage_string = "Fabricate Net"
-
- fabrication_type = /obj/item/energy_net
- use_power_cost = 70
-
-/obj/item/rig_module/fabricator/energy_net/engage(atom/target)
-
- if(holder && holder.wearer)
- if(..(target) && target)
- holder.wearer.Beam(target,"n_beam",,10)
- return 1
- return 0*/
-
-/obj/item/rig_module/self_destruct
-
- name = "self-destruct module"
- desc = "Oh my God, Captain. A bomb."
- icon_state = "deadman"
- usable = 1
- active = 1
- permanent = 1
-
- engage_string = "Detonate"
-
- interface_name = "dead man's switch"
- interface_desc = "An integrated self-destruct module. When the wearer dies, so does the surrounding area. Do not press this button."
-
-/obj/item/rig_module/self_destruct/activate()
- return
-
-/obj/item/rig_module/self_destruct/deactivate()
- return
-
-/obj/item/rig_module/self_destruct/process()
-
- // Not being worn, leave it alone.
- if(!holder || !holder.wearer || !holder.wearer.wear_suit == holder)
- return 0
-
- //OH SHIT.
- if(holder.wearer.stat == 2)
- engage()
-
-/obj/item/rig_module/self_destruct/engage()
- explosion(get_turf(src), 1, 2, 4, 5)
- if(holder && holder.wearer)
- holder.wearer.unEquip(src)
- qdel(holder)
- qdel(src)
-
-/obj/item/rig_module/self_destruct/small/engage()
- explosion(get_turf(src), 0, 0, 3, 4)
- if(holder && holder.wearer)
- holder.wearer.unEquip(src)
- qdel(holder)
- qdel(src)
diff --git a/code/modules/clothing/spacesuits/rig/modules/utility.dm b/code/modules/clothing/spacesuits/rig/modules/utility.dm
deleted file mode 100644
index 4b19d2a7753..00000000000
--- a/code/modules/clothing/spacesuits/rig/modules/utility.dm
+++ /dev/null
@@ -1,476 +0,0 @@
-/* Contains:
- * /obj/item/rig_module/device
- * /obj/item/rig_module/device/plasmacutter
- * /obj/item/rig_module/device/healthscanner
- * /obj/item/rig_module/device/drill
- * /obj/item/rig_module/device/orescanner
- * /obj/item/rig_module/device/rcd
- * /obj/item/rig_module/device/anomaly_scanner
- * /obj/item/rig_module/maneuvering_jets
- * /obj/item/rig_module/foam_sprayer
- * /obj/item/rig_module/device/broadcaster
- * /obj/item/rig_module/chem_dispenser
- * /obj/item/rig_module/chem_dispenser/injector
- * /obj/item/rig_module/voice
- * /obj/item/rig_module/device/paperdispenser
- * /obj/item/rig_module/device/pen
- * /obj/item/rig_module/device/stamp
- */
-
-/obj/item/rig_module/device
- name = "mounted device"
- desc = "Some kind of hardsuit mount."
- usable = 0
- selectable = 1
- toggleable = 0
- disruptive = 0
-
- var/device_type
- var/obj/item/device
-
-/obj/item/rig_module/device/plasmacutter
- name = "hardsuit plasma cutter"
- desc = "A lethal-looking industrial cutter."
- icon_state = "plasmacutter"
- interface_name = "plasma cutter"
- interface_desc = "A self-sustaining plasma arc capable of cutting through walls."
- suit_overlay_active = "plasmacutter"
- suit_overlay_inactive = "plasmacutter"
-
- device_type = /obj/item/gun/energy/plasmacutter
-
-/obj/item/rig_module/device/healthscanner
- name = "health scanner module"
- desc = "A hardsuit-mounted health scanner."
- icon_state = "scanner"
- interface_name = "health scanner"
- interface_desc = "Shows an informative health readout when used on a subject."
-
- device_type = /obj/item/healthanalyzer
-
-/obj/item/rig_module/device/drill
- name = "hardsuit drill mount"
- desc = "A very heavy diamond-tipped drill."
- icon_state = "drill"
- interface_name = "mounted drill"
- interface_desc = "A diamond-tipped industrial drill."
- suit_overlay_active = "mounted-drill"
- suit_overlay_inactive = "mounted-drill"
- device_type = /obj/item/pickaxe/drill/diamonddrill
-
-/obj/item/rig_module/device/orescanner
- name = "ore scanner module"
- desc = "A clunky old ore scanner."
- icon_state = "scanner"
- interface_name = "ore detector"
- interface_desc = "A sonar system for detecting large masses of ore."
- engage_string = "Begin Scan"
- usable = 1
- selectable = 0
- device_type = /obj/item/mining_scanner
-/*
-/obj/item/rig_module/device/rcd
- name = "RCD mount"
- desc = "A cell-powered rapid construction device for a hardsuit."
- icon_state = "rcd"
- interface_name = "mounted RCD"
- interface_desc = "A device for building or removing walls. Cell-powered."
- usable = 1
- engage_string = "Configure RCD"
-
- device_type = /obj/item/rcd/mounted
-*/
-/obj/item/rig_module/device/New()
- ..()
- if(device_type)
- device = new device_type(src)
- device.flags |= ABSTRACT //Abstract in the sense that it's not an item that stands alone, but rather is just there to let the module act like it.
-
-/obj/item/rig_module/device/engage(atom/target)
- if(!..() || !device)
- return 0
-
- if(!target)
- device.attack_self(holder.wearer)
- return 1
-
- var/turf/T = get_turf(target)
- if(istype(T) && !T.Adjacent(get_turf(src)))
- return 0
-
- var/resolved = target.attackby(device,holder.wearer)
- if(!resolved && device && target)
- device.afterattack(target,holder.wearer,1)
- return 1
-
-
-
-/obj/item/rig_module/chem_dispenser
- name = "mounted chemical dispenser"
- desc = "A complex web of tubing and needles suitable for hardsuit use."
- icon_state = "injector"
- usable = 1
- selectable = 0
- toggleable = 0
- disruptive = 0
-
- engage_string = "Inject"
-
- interface_name = "integrated chemical dispenser"
- interface_desc = "Dispenses loaded chemicals directly into the wearer's bloodstream."
-
- charges = list(
- list("saline-glucose", "salglu_solution", 0, 80),
- list("salicylic acid", "sal_acid", 0, 80),
- list("salbutamol", "salbutamol", 0, 80),
- list("antibiotics", "spaceacillin", 0, 80),
- list("charcoal", "charcoal", 0, 80),
- list("nutrients", "nutriment", 0, 80),
- list("potasssium iodide","potass_iodide", 0, 80),
- list("radium", "radium", 0, 80)
- )
-
- var/max_reagent_volume = 80 //Used when refilling.
-
-/obj/item/rig_module/chem_dispenser/ninja
- interface_desc = "Dispenses loaded chemicals directly into the wearer's bloodstream. This variant is made to be extremely light and flexible."
-
- //just over a syringe worth of each. Want more? Go refill. Gives the ninja another reason to have to show their face.
- charges = list(
- list("saline-glucose", "salglu_solution", 0, 20),
- list("salicylic acid", "sal_acid", 0, 20),
- list("salbutamol", "salbutamol", 0, 20),
- list("antibiotics", "spaceacillin", 0, 20),
- list("charcoal", "charcoal", 0, 20),
- list("nutrients", "nutriment", 0, 80),
- list("potasssium iodide","potass_iodide", 0, 20),
- list("radium", "radium", 0, 20)
- )
-
-
-/obj/item/rig_module/chem_dispenser/accepts_item(var/obj/item/input_item, var/mob/living/user)
-
- if(!input_item.is_open_container())
- return 0
-
- if(!input_item.reagents || !input_item.reagents.total_volume)
- to_chat(user, "\The [input_item] is empty.")
- return 0
-
- // Magical chemical filtration system, do not question it.
- var/total_transferred = 0
- for(var/datum/reagent/R in input_item.reagents.reagent_list)
- for(var/chargetype in charges)
- var/datum/rig_charge/charge = charges[chargetype]
- if(charge.display_name == R.id)
-
- var/chems_to_transfer = R.volume
-
- if((charge.charges + chems_to_transfer) > max_reagent_volume)
- chems_to_transfer = max_reagent_volume - charge.charges
-
- charge.charges += chems_to_transfer
- input_item.reagents.remove_reagent(R.id, chems_to_transfer)
- total_transferred += chems_to_transfer
-
- break
-
- if(total_transferred)
- to_chat(user, "You transfer [total_transferred] units into the suit reservoir.")
- else
- to_chat(user, "None of the reagents seem suitable.")
- return 1
-
-/obj/item/rig_module/chem_dispenser/engage(atom/target)
-
- if(!..())
- return 0
-
- var/mob/living/carbon/human/H = holder.wearer
-
- if(!charge_selected)
- to_chat(H, "You have not selected a chemical type.")
- return 0
-
- var/datum/rig_charge/charge = charges[charge_selected]
-
- if(!charge)
- return 0
-
- var/chems_to_use = 10
- if(charge.charges <= 0)
- to_chat(H, "Insufficient chems!")
- return 0
- else if(charge.charges < chems_to_use)
- chems_to_use = charge.charges
-
- var/mob/living/carbon/target_mob
- if(target)
- if(istype(target,/mob/living/carbon))
- target_mob = target
- else
- return 0
- else
- target_mob = H
-
- if(target_mob != H)
- to_chat(H, "You inject [target_mob] with [chems_to_use] unit\s of [charge.display_name].")
- to_chat(target_mob, "You feel a rushing in your veins as [chems_to_use] unit\s of [charge.display_name] [chems_to_use == 1 ? "is" : "are"] injected.")
- target_mob.reagents.add_reagent(charge.display_name, chems_to_use)
-
- charge.charges -= chems_to_use
- if(charge.charges < 0) charge.charges = 0
-
- return 1
-
-/obj/item/rig_module/chem_dispenser/combat
-
- name = "combat chemical injector"
- desc = "A complex web of tubing and needles suitable for hardsuit use."
-
- charges = list(
- list("synaptizine", "synaptizine", 0, 30),
- list("hydrocodone", "hydrocodone", 0, 30),
- list("nutrients", "nutriment", 0, 80),
- )
-
- interface_name = "combat chem dispenser"
- interface_desc = "Dispenses loaded chemicals directly into the bloodstream."
-
-
-/obj/item/rig_module/chem_dispenser/injector
-
- name = "mounted chemical injector"
- desc = "A complex web of tubing and a large needle suitable for hardsuit use."
- usable = 0
- selectable = 1
- disruptive = 1
-
- interface_name = "mounted chem injector"
- interface_desc = "Dispenses loaded chemicals via an arm-mounted injector."
-
-/obj/item/rig_module/voice
-
- name = "hardsuit voice synthesiser"
- desc = "A speaker box and sound processor."
- icon_state = "megaphone"
- usable = 1
- selectable = 0
- toggleable = 0
- disruptive = 0
-
- engage_string = "Configure Synthesiser"
-
- interface_name = "voice synthesiser"
- interface_desc = "A flexible and powerful voice modulator system."
-
- var/obj/item/voice_changer/voice_holder
-
-/obj/item/rig_module/voice/New()
- ..()
- voice_holder = new(src)
- voice_holder.active = FALSE
-
-/obj/item/rig_module/voice/installed()
- ..()
- holder.speech = src
-
-/obj/item/rig_module/voice/engage()
- if(!..())
- return 0
-
- var/choice= input("Would you like to toggle the synthesiser or set the name?") as null|anything in list("Enable","Disable","Set Name")
-
- if(!choice)
- return 0
-
- switch(choice)
- if("Enable")
- active = TRUE
- voice_holder.active = TRUE
- to_chat(usr, "You enable the speech synthesiser.")
- if("Disable")
- active = FALSE
- voice_holder.active = FALSE
- to_chat(usr, "You disable the speech synthesiser.")
- if("Set Name")
- var/raw_choice = sanitize(input(usr, "Please enter a new name.") as text|null, MAX_NAME_LEN)
- if(!raw_choice)
- return FALSE
- voice_holder.voice = raw_choice
- to_chat(usr, "You are now mimicking [voice_holder.voice].")
- return 1
-
-/obj/item/rig_module/maneuvering_jets
-
- name = "hardsuit maneuvering jets"
- desc = "A compact gas thruster system for a hardsuit."
- icon_state = "thrusters"
- usable = 1
- toggleable = 1
- selectable = 0
- disruptive = 0
-
- suit_overlay_active = "maneuvering_active"
- suit_overlay_inactive = null //"maneuvering_inactive"
-
- engage_string = "Toggle Stabilizers"
- activate_string = "Activate Thrusters"
- deactivate_string = "Deactivate Thrusters"
-
- interface_name = "maneuvering jets"
- interface_desc = "An inbuilt EVA maneuvering system that runs off the rig air supply."
-
- var/obj/item/tank/jetpack/rig/jets
-
-/obj/item/rig_module/maneuvering_jets/engage()
- if(!..())
- return 0
- jets.toggle_stabilization(usr)
- return 1
-
-/obj/item/rig_module/maneuvering_jets/activate()
-
- if(active)
- return 0
-
- active = 1
-
- spawn(1)
- if(suit_overlay_active)
- suit_overlay = suit_overlay_active
- else
- suit_overlay = null
- holder.update_icon()
-
- jets.turn_on()
- return 1
-
-/obj/item/rig_module/maneuvering_jets/deactivate()
- if(!..())
- return 0
- jets.turn_off()
- return 1
-
-/obj/item/rig_module/maneuvering_jets/New()
- ..()
- jets = new(src)
-
-/obj/item/rig_module/maneuvering_jets/installed()
- ..()
- jets.holder = holder
- jets.ion_trail.set_up(holder)
-
-/obj/item/rig_module/maneuvering_jets/removed()
- ..()
- jets.holder = null
- jets.ion_trail.set_up(jets)
-
-/obj/item/rig_module/foam_sprayer
-
-/obj/item/rig_module/device/paperdispenser
- name = "hardsuit paper dispenser"
- desc = "Crisp sheets."
- icon_state = "paper"
- interface_name = "paper dispenser"
- interface_desc = "Dispenses warm, clean, and crisp sheets of paper."
- engage_string = "Dispense"
- usable = 1
- selectable = 0
- device_type = /obj/item/paper_bin
-
-/obj/item/rig_module/device/paperdispenser/engage(atom/target)
-
- if(!..() || !device)
- return 0
-
- if(!target)
- device.attack_hand(holder.wearer)
- return 1
-
-/obj/item/rig_module/device/pen
- name = "mounted pen"
- desc = "For mecha John Hancocks."
- icon_state = "pen"
- interface_name = "mounted pen"
- interface_desc = "Signatures with style(tm)."
- engage_string = "Change color"
- usable = 1
- device_type = /obj/item/pen/multi
-
-/obj/item/rig_module/device/stamp
- name = "mounted internal affairs stamp"
- desc = "DENIED."
- icon_state = "stamp"
- interface_name = "mounted stamp"
- interface_desc = "Leave your mark."
- engage_string = "Toggle stamp type"
- usable = 1
- var/obj/iastamp //Theese were just vars, but any device would need to be an object
- var/obj/deniedstamp //Stops assigning non-objects to theese vars, which probably would break quite a bit.
-
-/obj/item/rig_module/device/stamp/New()
- ..()
- iastamp = new /obj/item/stamp/law(src)
- deniedstamp = new /obj/item/stamp/denied(src)
- iastamp.flags |= ABSTRACT
- deniedstamp.flags |= ABSTRACT
- device = iastamp
-
-/obj/item/rig_module/device/stamp/engage(atom/target)
- if(!..() || !device)
- return 0
-
- if(!target)
- if(device == iastamp)
- device = deniedstamp
- to_chat(holder.wearer, "Switched to denied stamp.")
- else if(device == deniedstamp)
- device = iastamp
- to_chat(holder.wearer, "Switched to internal affairs stamp.")
- return 1
-
-/obj/item/rig_module/welding_tank
- name = "welding fuel tank"
- desc = "A bluespace welding fuel storage tank for a rigsuit."
- icon_state = "welding_tank"
- interface_name = "mounted welding fuel tank"
- interface_desc = "A minitaure fuel tank used for storage of welding fuel, built into a hardsuit."
- engage_string = "Dispense fuel"
- usable = 1
-
- var/max_fuel = 300
-
-/obj/item/rig_module/welding_tank/New()
- ..()
-
- create_reagents(max_fuel)
- reagents.add_reagent("fuel", max_fuel)
-
-/obj/item/rig_module/welding_tank/engage(atom/target)
- if(!..() || !reagents)
- return 0
-
- if(!target)
- if(get_fuel() >= 0)
- var/obj/item/weldingtool/W = holder.wearer.get_active_hand()
- if(istype(W))
- fill_welder(W)
- else
- W = holder.wearer.get_inactive_hand()
- if(istype(W))
- fill_welder(W)
- else
- to_chat(holder.wearer, "Your welding tank is out of fuel!")
- else
- to_chat(holder.wearer, "You need to have a welding tool in one of your hands to dispense fuel.")
-
-/obj/item/rig_module/welding_tank/proc/fill_welder(obj/item/weldingtool/W)
- if(!istype(W))
- return
- W.refill(holder.wearer, src, W.maximum_fuel)
- if(!reagents.get_reagent_amount("fuel"))
- to_chat(holder.wearer, "You hear a faint dripping as your hardsuit welding tank completely empties.")
-
-/obj/item/rig_module/welding_tank/proc/get_fuel()
- return reagents.get_reagent_amount("fuel")
diff --git a/code/modules/clothing/spacesuits/rig/modules/vision.dm b/code/modules/clothing/spacesuits/rig/modules/vision.dm
deleted file mode 100644
index 33ae007ceee..00000000000
--- a/code/modules/clothing/spacesuits/rig/modules/vision.dm
+++ /dev/null
@@ -1,191 +0,0 @@
-/*
- * Contains
- * /obj/item/rig_module/vision
- * /obj/item/rig_module/vision/multi
- * /obj/item/rig_module/vision/meson
- * /obj/item/rig_module/vision/thermal
- * /obj/item/rig_module/vision/nvg
- * /obj/item/rig_module/vision/medhud
- * /obj/item/rig_module/vision/sechud
- */
-
-/datum/rig_vision
- var/mode
- var/obj/item/clothing/glasses/glasses
-
-/datum/rig_vision/nvg
- mode = "night vision"
-/datum/rig_vision/nvg/New()
- glasses = new /obj/item/clothing/glasses/night
-
-/datum/rig_vision/thermal
- mode = "thermal scanner"
-/datum/rig_vision/thermal/New()
- glasses = new /obj/item/clothing/glasses/thermal
-
-/datum/rig_vision/meson
- mode = "meson scanner"
-/datum/rig_vision/meson/New()
- glasses = new /obj/item/clothing/glasses/meson
-
-/datum/rig_vision/sechud
- mode = "security HUD"
-/datum/rig_vision/sechud/New()
- glasses = new /obj/item/clothing/glasses/hud/security
-
-/datum/rig_vision/medhud
- mode = "medical HUD"
-/datum/rig_vision/medhud/New()
- glasses = new /obj/item/clothing/glasses/hud/health
-
-/obj/item/rig_module/vision
-
- name = "hardsuit visor"
- desc = "A layered, translucent visor system for a hardsuit."
- icon_state = "optics"
-
- interface_name = "optical scanners"
- interface_desc = "An integrated multi-mode vision system."
-
- usable = 1
- toggleable = 1
- disruptive = 0
-
- engage_string = "Cycle Visor Mode"
- activate_string = "Enable Visor"
- deactivate_string = "Disable Visor"
-
- var/datum/rig_vision/vision
- var/list/vision_modes = list(
- /datum/rig_vision/nvg,
- /datum/rig_vision/thermal,
- /datum/rig_vision/meson
- )
-
- var/vision_index
-
-/obj/item/rig_module/vision/multi
-
- name = "hardsuit optical package"
- desc = "A complete visor system of optical scanners and vision modes."
- icon_state = "fulloptics"
-
-
- interface_name = "multi optical visor"
- interface_desc = "An integrated multi-mode vision system."
-
- vision_modes = list(/datum/rig_vision/meson,
- /datum/rig_vision/nvg,
- /datum/rig_vision/thermal,
- /datum/rig_vision/sechud,
- /datum/rig_vision/medhud)
-
-/obj/item/rig_module/vision/meson
-
- name = "hardsuit meson scanner"
- desc = "A layered, translucent visor system for a hardsuit."
- icon_state = "meson"
-
- usable = 0
-
- interface_name = "meson scanner"
- interface_desc = "An integrated meson scanner."
-
- vision_modes = list(/datum/rig_vision/meson)
-
-/obj/item/rig_module/vision/thermal
-
- name = "hardsuit thermal scanner"
- desc = "A layered, translucent visor system for a hardsuit."
- icon_state = "thermal"
-
- usable = 0
-
- interface_name = "thermal scanner"
- interface_desc = "An integrated thermal scanner."
-
- vision_modes = list(/datum/rig_vision/thermal)
-
-/obj/item/rig_module/vision/nvg
-
- name = "hardsuit night vision interface"
- desc = "A multi input night vision system for a hardsuit."
- icon_state = "night"
-
- usable = 0
-
- interface_name = "night vision interface"
- interface_desc = "An integrated night vision system."
-
- vision_modes = list(/datum/rig_vision/nvg)
-
-/obj/item/rig_module/vision/sechud
-
- name = "hardsuit security hud"
- desc = "A simple tactical information system for a hardsuit."
- icon_state = "securityhud"
-
- usable = 0
-
- interface_name = "security HUD"
- interface_desc = "An integrated security heads up display."
-
- vision_modes = list(/datum/rig_vision/sechud)
-
-/obj/item/rig_module/vision/medhud
-
- name = "hardsuit medical hud"
- desc = "A simple medical status indicator for a hardsuit."
- icon_state = "healthhud"
-
- usable = 0
-
- interface_name = "medical HUD"
- interface_desc = "An integrated medical heads up display."
-
- vision_modes = list(/datum/rig_vision/medhud)
-
-
-// There should only ever be one vision module installed in a suit.
-/obj/item/rig_module/vision/installed()
- ..()
- holder.visor = src
-
-/obj/item/rig_module/vision/engage()
-
- var/starting_up = !active
-
- if(!..() || !vision_modes)
- return 0
-
- // Don't cycle if this engage() is being called by activate().
- if(starting_up)
- to_chat(holder.wearer, "You activate your visual sensors.")
- return 1
-
- if(vision_modes.len > 1)
- vision_index++
- if(vision_index > vision_modes.len)
- vision_index = 1
- vision = vision_modes[vision_index]
-
- to_chat(holder.wearer, "You cycle your sensors to [vision.mode] mode.")
- else
- to_chat(holder.wearer, "Your sensors only have one mode.")
- return 1
-
-/obj/item/rig_module/vision/New()
- ..()
-
- if(!vision_modes)
- return
-
- vision_index = 1
- var/list/processed_vision = list()
-
- for(var/vision_mode in vision_modes)
- var/datum/rig_vision/vision_datum = new vision_mode
- if(!vision) vision = vision_datum
- processed_vision += vision_datum
-
- vision_modes = processed_vision
diff --git a/code/modules/clothing/spacesuits/rig/rig.dm b/code/modules/clothing/spacesuits/rig/rig.dm
deleted file mode 100644
index 0d106a874a7..00000000000
--- a/code/modules/clothing/spacesuits/rig/rig.dm
+++ /dev/null
@@ -1,1059 +0,0 @@
-#define ONLY_DEPLOY 1
-#define ONLY_RETRACT 2
-#define SEAL_DELAY 30
-
-/*
- * Defines the behavior of hardsuits/rigs/power armour.
- */
-
-/obj/item/rig
-
- name = "hardsuit control module"
- icon = 'icons/obj/rig_modules.dmi'
- desc = "A back-mounted hardsuit deployment and control mechanism."
- slot_flags = SLOT_BACK
- req_one_access = list()
- req_access = list()
- w_class = WEIGHT_CLASS_BULKY
-
- // These values are passed on to all component pieces.
- armor = list(melee = 10, bullet = 5, laser = 10, energy = 5, bomb = 10, bio = 100, rad = 75)
- min_cold_protection_temperature = SPACE_SUIT_MIN_TEMP_PROTECT
- max_heat_protection_temperature = SPACE_SUIT_MAX_TEMP_PROTECT
- siemens_coefficient = 0.2
- permeability_coefficient = 0.1
-
- var/interface_path = "hardsuit.tmpl"
- var/ai_interface_path = "hardsuit.tmpl"
- var/interface_title = "Hardsuit Controller"
- var/wearer_move_delay //Used for AI moving.
- var/ai_controlled_move_delay = 10
-
- // Keeps track of what this rig should spawn with.
- var/suit_type = "hardsuit"
- var/list/initial_modules
- var/chest_type = /obj/item/clothing/suit/space/new_rig
- var/helm_type = /obj/item/clothing/head/helmet/space/new_rig
- var/boot_type = /obj/item/clothing/shoes/magboots/rig
- var/glove_type = /obj/item/clothing/gloves/rig
- var/cell_type = /obj/item/stock_parts/cell/high
- var/air_type = /obj/item/tank/oxygen
-
- //Component/device holders.
- var/obj/item/tank/air_supply // Air tank, if any.
- var/obj/item/clothing/shoes/magboots/boots = null // Deployable boots, if any.
- var/obj/item/clothing/shoes/under_boots = null //Boots that are between the feet and the rig boots, if any.
- var/obj/item/clothing/suit/space/new_rig/chest // Deployable chestpiece, if any.
- var/obj/item/clothing/head/helmet/space/new_rig/helmet = null // Deployable helmet, if any.
- var/obj/item/clothing/gloves/rig/gloves = null // Deployable gauntlets, if any.
- var/obj/item/stock_parts/cell/cell // Power supply, if any.
- var/obj/item/rig_module/selected_module = null // Primary system (used with middle-click)
- var/obj/item/rig_module/vision/visor // Kinda shitty to have a var for a module, but saves time.
- var/obj/item/rig_module/voice/speech // As above.
- var/mob/living/carbon/human/wearer // The person currently wearing the rig.
- var/image/mob_icon // Holder for on-mob icon.
- var/list/installed_modules = list() // Power consumption/use bookkeeping.
-
- // Rig status vars.
- var/open = 0 // Access panel status.
- var/locked = 1 // Lock status.
- var/subverted = 0
- var/interface_locked = 0
- var/control_overridden = 0
- var/ai_override_enabled = 0
- var/security_check_enabled = 1
- var/malfunctioning = 0
- var/malfunction_delay = 0
- var/electrified = 0
- var/locked_down = 0
-
- var/seal_delay = SEAL_DELAY
- var/sealing // Keeps track of seal status independantly of NODROP.
- var/offline = 1 // Should we be applying suit maluses?
- var/offline_slowdown = 3 // If the suit is deployed and unpowered, it sets slowdown to this.
- var/active_slowdown = 3 // How much the deployed suit slows down if powered.
- var/vision_restriction
- var/offline_vision_restriction = 1 // 0 - none, 1 - welder vision, 2 - blind. Maybe move this to helmets.
- var/airtight = 1 //If set, will adjust AIRTIGHT and STOPSPRESSUREDMAGE flags on components. Otherwise it should leave them untouched.
-
- var/emp_protection = 0
- var/has_emergency_release = 1 //Allows suit to be removed from outside.
-
- // Wiring! How exciting.
- var/datum/wires/rig/wires
- var/datum/effect_system/spark_spread/spark_system
-
-/obj/item/rig/examine(mob/user)
- . = list("This is [src].")
- . += "[desc]"
- if(wearer)
- for(var/obj/item/piece in list(helmet,gloves,chest,boots))
- if(!piece || piece.loc != wearer)
- continue
- . += "[bicon(piece)] \The [piece] [piece.gender == PLURAL ? "are" : "is"] deployed."
-
- if(loc == usr)
- . += "The maintenance panel is [open ? "open" : "closed"]."
- . += "Hardsuit systems are [offline ? "offline" : "online"]."
-
-/obj/item/rig/get_cell()
- return cell
-
-/obj/item/rig/New()
- ..()
-
- item_state = icon_state
- wires = new(src)
-
- if((!req_access || !req_access.len) && (!req_one_access || !req_one_access.len))
- locked = 0
-
- spark_system = new()
- spark_system.set_up(5, 0, src)
- spark_system.attach(src)
-
- START_PROCESSING(SSobj, src)
-
- if(initial_modules && initial_modules.len)
- for(var/path in initial_modules)
- var/obj/item/rig_module/module = new path(src)
- installed_modules += module
- module.installed(src)
-
- // Create and initialize our various segments.
- if(cell_type)
- cell = new cell_type(src)
- if(air_type)
- air_supply = new air_type(src)
- if(glove_type)
- gloves = new glove_type(src)
- verbs |= /obj/item/rig/proc/toggle_gauntlets
- if(helm_type)
- helmet = new helm_type(src)
- verbs |= /obj/item/rig/proc/toggle_helmet
- helmet.item_color="[initial(icon_state)]_sealed" //For the lightswitching to know the correct string to manipulate
- if(boot_type)
- boots = new boot_type(src)
- verbs |= /obj/item/rig/proc/toggle_boots
- boots.magboot_state="[initial(icon_state)]_sealed" //For the magboot (de)activation to know the correct string to manipulate
- if(chest_type)
- chest = new chest_type(src)
- if(allowed)
- chest.allowed = allowed
- chest.slowdown = offline_slowdown
- chest.holder = src
- verbs |= /obj/item/rig/proc/toggle_chest
-
- for(var/obj/item/piece in list(gloves,helmet,boots,chest))
- if(!istype(piece))
- continue
- piece.name = "[suit_type] [initial(piece.name)]"
- piece.desc = "It seems to be part of a [src.name]."
- piece.icon_state = "[initial(icon_state)]"
- piece.min_cold_protection_temperature = min_cold_protection_temperature
- piece.max_heat_protection_temperature = max_heat_protection_temperature
- if(piece.siemens_coefficient > siemens_coefficient) //So that insulated gloves keep their insulation.
- piece.siemens_coefficient = siemens_coefficient
- piece.permeability_coefficient = permeability_coefficient
- if(armor)
- piece.armor = armor
-
- update_icon(1)
-
-/obj/item/rig/Destroy()
- for(var/obj/item/piece in list(gloves,boots,helmet,chest))
- var/mob/living/M = piece.loc
- if(istype(M))
- M.unEquip(piece)
- qdel(piece)
- STOP_PROCESSING(SSobj, src)
- QDEL_NULL(wires)
- QDEL_NULL(spark_system)
- return ..()
-
-/obj/item/rig/proc/suit_is_deployed()
- if(!istype(wearer) || src.loc != wearer || wearer.back != src)
- return 0
- if(helm_type && !(helmet && wearer.head == helmet))
- return 0
- if(glove_type && !(gloves && wearer.gloves == gloves))
- return 0
- if(boot_type && !(boots && wearer.shoes == boots))
- return 0
- if(chest_type && !(chest && wearer.wear_suit == chest))
- return 0
- return 1
-
-/obj/item/rig/proc/reset()
- offline = 2
- flags &= ~NODROP
- if(helmet && helmet.on)
- helmet.toggle_light(wearer)
- if(boots && boots.magpulse)
- boots.attack_self(wearer)
- for(var/obj/item/piece in list(helmet,boots,gloves,chest))
- if(!piece) continue
- piece.icon_state = "[initial(icon_state)]"
- if(airtight)
- piece.flags &= ~(STOPSPRESSUREDMAGE | AIRTIGHT)
- update_icon(1)
-
-/obj/item/rig/proc/seal(mob/living/user)
- if(sealing)
- return 0
-
- if(!wearer || !user)
- return
-
- var/sealed = (flags & NODROP)
- if(sealed)
- to_chat(user, "\The [src] is already sealed!")
- return 0
-
- if(!check_power_cost(user, 1)) //need power to seal the suit
- return 0
-
- var/failed_to_seal = FALSE
-
- if(!suit_is_deployed())
- to_chat(user, "\The [src] cannot seal, as it is not fully deployed!")
- return 0
-
- flags |= NODROP
- sealing = TRUE
-
- to_chat(user, "\The [src] begins to tighten it's seals.")
- wearer.visible_message("\The [wearer]'s suit emits a quiet hum as it begins to tighten it's seals.",
- "With a quiet hum, your suit begins to seal.")
-
- if(seal_delay && !do_after(user, seal_delay, target = wearer))
- to_chat(user, "You must remain still to seal \the [src]!")
- failed_to_seal = TRUE
-
- if(!failed_to_seal)
- deploy(user)
-
- var/list/pieces_data = list(list(wearer.shoes, boots, "boots", boot_type),
- list(wearer.gloves, gloves, "gloves", glove_type),
- list(wearer.head, helmet, "helmet", helm_type),
- list(wearer.wear_suit, chest, "chest", chest_type))
-
- for(var/list/piece_data in pieces_data)
- var/obj/item/user_piece = piece_data[1]
- var/obj/item/correct_piece = piece_data[2]
- var/msg_type = piece_data[3]
- var/piece_type = piece_data[4]
-
- if(!user_piece || !piece_type)
- continue
-
- if(user_piece != correct_piece)
- to_chat(user, "\The [user_piece] is blocking \the [src] from deploying.")
- failed_to_seal = TRUE
-
- if(seal_delay && !do_after(user, seal_delay, needhand = 0, target = wearer))
- to_chat(user, "You must remain still to seal \the [src]!")
- failed_to_seal = TRUE
-
- if(failed_to_seal)
- break
-
- correct_piece.icon_state = "[initial(icon_state)]_sealed"
- switch(msg_type)
- if("boots")
- to_chat(wearer, "\The [correct_piece] seal around your feet.")
- correct_piece.icon_state = "[initial(icon_state)]_sealed0" //Solution to not need a sprite for off, on, and unused magboots.
- if(user != wearer)
- to_chat(user, "\The [correct_piece] has been sealed.")
- wearer.update_inv_shoes()
- if("gloves")
- to_chat(wearer, "\The [correct_piece] tighten around your fingers and wrists.")
- if(user != wearer)
- to_chat(user, "\The [correct_piece] has been sealed.")
- wearer.update_inv_gloves()
- if("chest")
- to_chat(wearer, "\The [correct_piece] cinches tight again your chest.")
- if(user != wearer)
- to_chat(user, "\The [correct_piece] has been sealed.")
- wearer.update_inv_wear_suit()
- if("helmet")
- to_chat(wearer, "\The [correct_piece] hisses closed.")
- correct_piece.icon_state = "[initial(icon_state)]_sealed0" //Solution to not need a sprite for off, on, and unused helmet light.
- if(user != wearer)
- to_chat(user, "\The [correct_piece] has been sealed.")
- wearer.update_inv_head()
- if(helmet)
- helmet.update_light(wearer)
-
- correct_piece.armor = correct_piece.armor.setRating(bio_value = 100)
-
- sealing = FALSE
-
- if(failed_to_seal)
- for(var/obj/item/piece in list(helmet, boots, gloves, chest))
- if(!piece)
- continue
- piece.icon_state = "[initial(icon_state)]"
- flags &= ~NODROP
- if(airtight)
- update_component_sealed()
- update_icon(1)
- return 0
-
- if(user != wearer)
- to_chat(user, "\The [src] has been loosened.")
- to_chat(wearer, "Your entire suit tightens around you as the components lock into place.")
- if(airtight)
- update_component_sealed()
- update_icon(1)
-
-/obj/item/rig/proc/unseal(mob/living/user)
- if(sealing)
- return 0
-
- if(!wearer || !user)
- return
-
- var/sealed = (flags & NODROP)
- if(!sealed)
- to_chat(user, "\The [src] is already unsealed!")
- return 0
-
- sealing = TRUE
-
- var/failed_to_seal = FALSE
-
- if(!suit_is_deployed())
- to_chat(user, "\The [src] cannot unseal, as it is not fully deployed!")
- failed_to_seal = TRUE
-
- if(!failed_to_seal)
- if(user != wearer)
- to_chat(user, "\The [src] begins to loosen it's seals.")
- wearer.visible_message("\The [wearer]'s suit emits a quiet hum as it begins to loosen it's seals.",
- "With a quiet hum, your suit begins to unseal.")
-
- if(seal_delay && !do_after(user, seal_delay, target = wearer))
- to_chat(user, "You must remain still to unseal \the [src]!")
- failed_to_seal = TRUE
-
- if(!failed_to_seal)
- var/list/pieces_data = list(list(wearer.shoes, boots, "boots", boot_type),
- list(wearer.gloves, gloves, "gloves", glove_type),
- list(wearer.head, helmet, "helmet", helm_type),
- list(wearer.wear_suit, chest, "chest", chest_type))
-
- for(var/list/piece_data in pieces_data)
- var/obj/item/user_piece = piece_data[1]
- var/obj/item/correct_piece = piece_data[2]
- var/msg_type = piece_data[3]
- var/piece_type = piece_data[4]
-
- if(!correct_piece || !piece_type)
- continue
-
- if(user_piece != correct_piece)
- to_chat(user, "\The [user_piece] is blocking \the [src] from deploying.")
- failed_to_seal = TRUE
-
- if(seal_delay && !do_after(user, seal_delay, needhand = 0, target = wearer))
- to_chat(user, "You must remain still to unseal \the [src]!")
- failed_to_seal = TRUE
-
- if(failed_to_seal)
- break
-
- correct_piece.icon_state = "[initial(icon_state)]"
- switch(msg_type)
- if("boots")
- to_chat(wearer, "\The [correct_piece] relax [correct_piece.p_their()] grip on your legs.")
- if(user != wearer)
- to_chat(user, "\The [correct_piece] has been unsealed.")
- wearer.update_inv_shoes()
- if("gloves")
- to_chat(wearer, "\The [correct_piece] become loose around your fingers.")
- if(user != wearer)
- to_chat(user, "\The [correct_piece] has been unsealed.")
- wearer.update_inv_gloves()
- if("chest")
- to_chat(wearer, "\The [correct_piece] releases your chest.")
- if(user != wearer)
- to_chat(user, "\The [correct_piece] has been unsealed.")
- wearer.update_inv_wear_suit()
- if("helmet")
- to_chat(wearer, "\The [correct_piece] hisses open.")
- if(user != wearer)
- to_chat(user, "\The [correct_piece] has been unsealed.")
- wearer.update_inv_head()
- if(helmet)
- helmet.update_light(wearer)
-
- correct_piece.armor = correct_piece.armor.setRating(bio_value = armor.getRating("bio"))
-
- sealing = FALSE
-
- if(failed_to_seal)
- for(var/obj/item/piece in list(gloves, chest))
- if(!piece)
- continue
- piece.icon_state = "[initial(icon_state)]_sealed"
- if(helmet)
- helmet.icon_state = "[initial(icon_state)]_sealed[helmet.on]"
- if(boots)
- boots.icon_state = "[initial(icon_state)]_sealed[boots.magpulse]"
- if(airtight)
- update_component_sealed()
- update_icon(1)
- return 0
-
- if(user != wearer)
- to_chat(user, "\The [src] has been unsealed.")
- to_chat(wearer, "Your entire suit loosens as the components relax.")
-
- flags &= ~NODROP
-
- for(var/obj/item/rig_module/module in installed_modules)
- module.deactivate()
-
- if(airtight)
- update_component_sealed()
- update_icon(1)
-
-/obj/item/rig/proc/update_component_sealed()
- if(istype(boots) && !(flags & NODROP) && boots.magpulse) //If we have (active) boots and unsealed the suit, we deactivate the magboots.
- boots.attack_self(wearer)
- if(istype(helmet) && !(flags & NODROP) && helmet.on) //If we have an (active) headlamp and unsealed the suit, we deactivate the headlamp.
- helmet.toggle_light(wearer)
- for(var/obj/item/piece in list(helmet,boots,gloves,chest))
- if(!(flags & NODROP))
- piece.flags &= ~(STOPSPRESSUREDMAGE | AIRTIGHT)
- else
- piece.flags |= STOPSPRESSUREDMAGE | AIRTIGHT
-
-/obj/item/rig/process()
- // If we've lost any parts, grab them back.
- var/mob/living/M
- for(var/obj/item/piece in list(gloves,boots,helmet,chest))
- if(piece.loc != src && !(wearer && piece.loc == wearer))
- if(istype(piece.loc, /mob/living))
- M = piece.loc
- M.unEquip(piece)
- piece.forceMove(src)
-
- if(cell && cell.charge > 0 && electrified > 0)
- electrified--
-
- if(malfunction_delay > 0)
- malfunction_delay--
- else if(malfunctioning)
- malfunctioning--
- malfunction()
-
- if(!istype(wearer) || loc != wearer || wearer.back != src || !(flags & NODROP) || !cell || cell.charge <= 0)
- if(!cell || cell.charge <= 0)
- if(electrified > 0)
- electrified = 0
- if(!offline)
- if(istype(wearer))
- if(flags & NODROP)
- if(offline_slowdown < 3)
- to_chat(wearer, "Your suit beeps stridently, and suddenly goes dead.")
- else
- to_chat(wearer, "Your suit beeps stridently, and suddenly you're wearing a leaden mass of metal and plastic composites instead of a powered suit.")
- if(offline_vision_restriction == 1)
- to_chat(wearer, "The suit optics flicker and die, leaving you with restricted vision.")
- else if(offline_vision_restriction == 2)
- to_chat(wearer, "The suit optics drop out completely, drowning you in darkness.")
- if(!offline)
- offline = 1
- if(istype(wearer) && wearer.wearing_rig)
- wearer.wearing_rig = null
- else
- if(offline)
- offline = 0
- if(istype(wearer) && !wearer.wearing_rig)
- wearer.wearing_rig = src
- chest.slowdown = active_slowdown
-
- if(offline)
- if(offline == 1)
- for(var/obj/item/rig_module/module in installed_modules)
- module.deactivate()
- offline = 2
- chest.slowdown = offline_slowdown
- return
-
-
- for(var/obj/item/rig_module/module in installed_modules)
- cell.use(module.process()*10)
-
-/obj/item/rig/proc/check_power_cost(var/mob/living/user, var/cost, var/use_unconcious, var/obj/item/rig_module/mod, var/user_is_ai)
- if(!istype(user))
- return 0
-
- var/fail_msg
-
- if(!user_is_ai)
- var/mob/living/carbon/human/H = user
- if(istype(H) && H.back != src)
- fail_msg = "You must be wearing \the [src] to do this."
- else if(user.incorporeal_move)
- fail_msg = "You must be solid to do this."
- if(sealing)
- fail_msg = "The hardsuit is in the process of adjusting seals and cannot be activated."
- else if(!fail_msg && ((use_unconcious && user.stat > 1) || (!use_unconcious && user.stat)))
- fail_msg = "You are in no fit state to do that."
- else if(!cell)
- fail_msg = "There is no cell installed in the suit."
- else if(cost && cell.charge < cost * 10) //TODO: Cellrate?
- fail_msg = "Not enough stored power."
-
- if(fail_msg)
- to_chat(user, "[fail_msg]")
- return 0
-
- // This is largely for cancelling stealth and whatever.
- if(mod && mod.disruptive)
- for(var/obj/item/rig_module/module in (installed_modules - mod))
- if(module.active && module.disruptable)
- module.deactivate()
-
- cell.use(cost*10)
- return 1
-
-/obj/item/rig/ui_interact(mob/user, ui_key = "main", var/datum/nanoui/ui = null, var/force_open = 1, var/datum/topic_state/state = GLOB.inventory_state)
- if(!user)
- return
-
- ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
- if(!ui)
- ui = new(user, src, ui_key, ((src.loc != user) ? ai_interface_path : interface_path), interface_title, 480, 550, state = state)
- ui.open()
- ui.set_auto_update(1)
-
-/obj/item/rig/ui_data(mob/user, ui_key = "main", datum/topic_state/state = GLOB.inventory_state)
- var/data[0]
-
- data["primarysystem"] = null
- if(selected_module)
- data["primarysystem"] = "[selected_module.interface_name]"
-
- data["ai"] = 0
- if(src.loc != user)
- data["ai"] = 1
-
- var/is_sealed = (flags & NODROP) //1 if NODROP, 0 if no-nodrop
- data["seals"] = "[!is_sealed]" //1 if not NODROP (unsealed), 0 if NODROP (sealed)
- data["sealing"] = "[src.sealing]"
- data["helmet"] = (helmet ? "[helmet.name]" : "None.")
- data["gauntlets"] = (gloves ? "[gloves.name]" : "None.")
- data["boots"] = (boots ? "[boots.name]" : "None.")
- data["chest"] = (chest ? "[chest.name]" : "None.")
-
- data["charge"] = cell ? round(cell.charge,1) : 0
- data["maxcharge"] = cell ? cell.maxcharge : 0
- data["chargestatus"] = cell ? FLOOR((cell.charge/cell.maxcharge)*50, 1) : 0
-
- data["emagged"] = subverted
- data["coverlock"] = locked
- data["interfacelock"] = interface_locked
- data["aicontrol"] = control_overridden
- data["aioverride"] = ai_override_enabled
- data["securitycheck"] = security_check_enabled
- data["malf"] = malfunction_delay
-
-
- var/list/module_list = list()
- var/i = 1
- for(var/obj/item/rig_module/module in installed_modules)
- var/list/module_data = list(
- "index" = i,
- "name" = "[module.interface_name]",
- "desc" = "[module.interface_desc]",
- "can_use" = "[module.usable]",
- "can_select" = "[module.selectable]",
- "can_toggle" = "[module.toggleable]",
- "is_active" = "[module.active]",
- "engagecost" = module.use_power_cost*10,
- "activecost" = module.active_power_cost*10,
- "passivecost" = module.passive_power_cost*10,
- "engagestring" = module.engage_string,
- "activatestring" = module.activate_string,
- "deactivatestring" = module.deactivate_string,
- "damage" = module.damage
- )
-
- if(module.charges && module.charges.len)
-
- module_data["charges"] = list()
- var/datum/rig_charge/selected = module.charges[module.charge_selected]
- module_data["chargetype"] = selected ? "[selected.display_name]" : "none"
-
- for(var/chargetype in module.charges)
- var/datum/rig_charge/charge = module.charges[chargetype]
- module_data["charges"] += list(list("caption" = "[chargetype] ([charge.charges])", "index" = "[chargetype]"))
-
- module_list += list(module_data)
- i++
-
- if(module_list.len)
- data["modules"] = module_list
-
- return data
-
-/obj/item/rig/update_icon(var/update_mob_icon)
-
- //TODO: Maybe consider a cache for this (use mob_icon as blank canvas, use suit icon overlay).
- overlays.Cut()
- if(!mob_icon || update_mob_icon)
- var/species_icon = 'icons/mob/rig_back.dmi'
- // Since setting mob_icon will override the species checks in
- // update_inv_wear_suit(), handle species checks here.
- if(wearer && sprite_sheets && sprite_sheets[wearer.dna.species.name])
- species_icon = sprite_sheets[wearer.dna.species.name]
- mob_icon = image("icon" = species_icon, "icon_state" = "[icon_state]")
-
- if(installed_modules.len)
- for(var/obj/item/rig_module/module in installed_modules)
- if(module.suit_overlay)
- chest.overlays += image("icon" = 'icons/mob/rig_modules.dmi', "icon_state" = "[module.suit_overlay]", "dir" = SOUTH)
-
- if(wearer)
- wearer.update_inv_shoes()
- wearer.update_inv_gloves()
- wearer.update_inv_head()
- wearer.update_inv_wear_suit()
- wearer.update_inv_back()
- return
-
-/obj/item/rig/proc/check_suit_access(var/mob/living/carbon/human/user)
-
- if(!security_check_enabled)
- return 1
-
- if(istype(user))
- if(malfunction_check(user))
- return 0
- if(user.back != src)
- return 0
- else if(!src.allowed(user))
- to_chat(user, "Unauthorized user. Access denied.")
- return 0
-
- else if(!ai_override_enabled)
- to_chat(user, "Synthetic access disabled. Please consult hardware provider.")
- return 0
-
- return 1
-
-/obj/item/rig/Topic(href,href_list)
- if(!check_suit_access(usr))
- return 0
-
- if(href_list["toggle_piece"])
- if(ishuman(usr) && (usr.stat || usr.stunned || usr.lying))
- return 0
- toggle_piece(href_list["toggle_piece"], usr)
- else if(href_list["toggle_seals"])
- if(flags & NODROP)
- unseal(usr)
- else
- seal(usr)
- else if(href_list["interact_module"])
- var/module_index = text2num(href_list["interact_module"])
-
- if(module_index > 0 && module_index <= installed_modules.len)
- var/obj/item/rig_module/module = installed_modules[module_index]
- switch(href_list["module_mode"])
- if("activate")
- module.activate()
- if("deactivate")
- module.deactivate()
- if("engage")
- module.engage()
- if("select")
- selected_module = module
- if("select_charge_type")
- module.charge_selected = href_list["charge_type"]
- else if(href_list["toggle_ai_control"])
- ai_override_enabled = !ai_override_enabled
- notify_ai("Synthetic suit control has been [ai_override_enabled ? "enabled" : "disabled"].")
- else if(href_list["toggle_suit_lock"])
- locked = !locked
-
- usr.set_machine(src)
- add_fingerprint(usr)
- return 0
-
-/obj/item/rig/proc/notify_ai(var/message)
- if(!message || !installed_modules || !installed_modules.len)
- return
- for(var/obj/item/rig_module/module in installed_modules)
- for(var/mob/living/silicon/ai/ai in module.contents)
- if(ai && ai.client && !ai.stat)
- to_chat(ai, "[message]")
-
-/obj/item/rig/equipped(mob/living/carbon/human/M, slot)
- ..()
- if(!istype(M) || slot != slot_back)
- return //we don't care about picking up/nonhumans
-
- spawn(1) //equipped() is called BEFORE the item is actually set as the slot
-
- if(seal_delay > 0 && istype(M) && M.back == src)
- M.visible_message("[M] starts putting on \the [src]...", "You start putting on \the [src]...")
- if(!do_after(M, seal_delay, target = M))
- if(M && M.back == src)
- M.unEquip(src)
- M.put_in_hands(src)
- return
-
- if(istype(M) && M.back == src)
- M.visible_message("[M] struggles into \the [src].", "You struggle into \the [src].")
- wearer = M
- wearer.wearing_rig = src
- if(has_emergency_release)
- M.verbs |= /obj/item/rig/proc/emergency_release
- update_icon()
-
-/obj/item/rig/proc/toggle_piece(var/piece, var/mob/living/user, var/deploy_mode, var/force)
- if(!istype(wearer) || wearer.back != src)
- if(force) //can only force retracting sorry
- for(var/obj/item/uneq_piece in list(helmet, gloves, boots, chest))
- if(uneq_piece)
- if(isliving(uneq_piece.loc))
- var/mob/living/L = uneq_piece.loc
- L.unEquip(uneq_piece, 1)
- if(uneq_piece == boots)
- if(under_boots)
- if(L.equip_to_slot_if_possible(under_boots, slot_shoes))
- under_boots = null
- else
- to_chat(user, "Somehow, your [under_boots] got stuck to the [boots], and were retracted with them. ((This shouldn't happen, bug report this.))")
- uneq_piece.forceMove(src)
- return 0
-
- if(sealing || !cell || !cell.charge)
- return 0
-
- if(!(deploy_mode == ONLY_RETRACT && force)) //This should be the case while stripping, stripping does trigger the if statement below.
- if(user == wearer && user.incapacitated()) // If the user isn't wearing the suit it's probably an AI.
- return 0
-
- var/obj/item/check_slot
- var/equip_to
- var/obj/item/use_obj
-
- switch(piece)
- if("helmet")
- equip_to = slot_head
- use_obj = helmet
- check_slot = wearer.head
- if("gauntlets")
- equip_to = slot_gloves
- use_obj = gloves
- check_slot = wearer.gloves
- if("boots")
- equip_to = slot_shoes
- use_obj = boots
- check_slot = wearer.shoes
- if("chest")
- equip_to = slot_wear_suit
- use_obj = chest
- check_slot = wearer.wear_suit
-
- if(use_obj)
- if(check_slot == use_obj && deploy_mode != ONLY_DEPLOY) //user is wearing it, retract it if not forced to deploy
- if((flags & NODROP) && equip_to != slot_head && !force) //you can only retract the helmet if the suit isn't unsealed
- to_chat(user, "You can't retract \the [use_obj] while the suit is sealed!")
- return
-
- var/mob/living/to_strip
- if(wearer)
- to_strip = wearer
- else if(isliving(use_obj.loc))
- to_strip = use_obj.loc
-
- if(to_strip)
- to_strip.unEquip(use_obj, 1)
- if(use_obj == boots)
- if(under_boots)
- if(to_strip.equip_to_slot_if_possible(under_boots, slot_shoes))
- under_boots = null
- else
- to_chat(user, "Somehow, your [under_boots] got stuck to the [boots], and were retracted with them. ((This shouldn't happen, bug report this.))")
- use_obj.forceMove(src)
- if(wearer)
- to_chat(wearer, "Your [use_obj] [use_obj.gender == PLURAL ? "retract" : "retracts"] swiftly.")
-
- else if(deploy_mode != ONLY_RETRACT)
- if(check_slot)
- if(check_slot != use_obj) //If use_obj is already in check_slot, silently bail. Otherwise, tell the user why the part didn't deploy.
- if(use_obj == boots)
- under_boots = check_slot
- wearer.unEquip(under_boots)
- under_boots.forceMove(src)
- else
- to_chat(wearer, "You are unable to deploy \the [piece] as \the [check_slot] [check_slot.gender == PLURAL ? "are" : "is"] in the way.")
- return
- use_obj.forceMove(wearer)
- if(!wearer.equip_to_slot_if_possible(use_obj, equip_to, FALSE, TRUE))
- use_obj.forceMove(src)
- else
- if(wearer)
- to_chat(wearer, "Your [use_obj.name] [use_obj.gender == PLURAL ? "deploy" : "deploys"] swiftly.")
-
- if(piece == "helmet" && helmet)
- helmet.update_light(wearer)
-
-/obj/item/rig/proc/deploy(mob/user)
- if(!wearer || !user)
- return 0
-
- if(flags & NODROP) //We need to check if we have the part, the person is wearing something in the parts slot, and if yes, are they the same.
- if(helmet && wearer.head && wearer.head != helmet)
- to_chat(user, "\The [wearer.head] is blocking \the [src] from deploying!")
- return 0
- if(gloves && wearer.gloves && wearer.gloves != gloves)
- to_chat(user, "\The [wearer.gloves] is preventing \the [src] from deploying!")
- return 0
- /*if(boots && wearer.shoes && wearer.shoes != boots)
- to_chat(user, "\The [wearer.shoes] is preventing \the [src] from deploying!")
- return 0*/
- if(chest && wearer.wear_suit && wearer.wear_suit != chest)
- to_chat(user, "\The [wearer.wear_suit] is preventing \the [src] from deploying!")
- return 0
-
-
- for(var/piece in list("helmet", "gauntlets", "chest", "boots"))
- toggle_piece(piece, user, ONLY_DEPLOY)
-
-/obj/item/rig/dropped(var/mob/user)
- ..()
- user.verbs -= /obj/item/rig/proc/emergency_release
- for(var/piece in list("helmet","gauntlets","chest","boots"))
- toggle_piece(piece, user, ONLY_RETRACT, 1)
- if(wearer)
- wearer.wearing_rig = null
- wearer = null
-
-//Todo
-/obj/item/rig/proc/malfunction()
- return 0
-
-/obj/item/rig/emp_act(severity_class)
- //set malfunctioning
- if(emp_protection < 30) //for ninjas, really.
- malfunctioning += 10
- if(malfunction_delay <= 0)
- malfunction_delay = max(malfunction_delay, round(30/severity_class))
-
- //drain some charge
- if(cell) cell.emp_act(severity_class + 15)
-
- //possibly damage some modules
- take_hit((100/severity_class), "electrical pulse", 1)
-
-/obj/item/rig/proc/shock(mob/user)
- if(get_dist(src, user) <= 1) //Needs to be adjecant to the rig to get shocked.
- if(electrocute_mob(user, cell, src)) //electrocute_mob() handles removing charge from the cell, no need to do that here.
- spark_system.start()
- if(user.stunned)
- return 1
- return 0
-
-/obj/item/rig/proc/take_hit(damage, source, is_emp=0)
-
- if(!installed_modules.len)
- return
-
- var/chance
- if(!is_emp)
- chance = 2*max(0, damage - (chest? chest.breach_threshold : 0))
- else
- //Want this to be roughly independant of the number of modules, meaning that X emp hits will disable Y% of the suit's modules on average.
- //that way people designing hardsuits don't have to worry (as much) about how adding that extra module will affect emp resiliance by 'soaking' hits for other modules
- chance = 2*max(0, damage - emp_protection)*min(installed_modules.len/15, 1)
-
- if(!prob(chance))
- return
-
- //deal addition damage to already damaged module first.
- //This way the chances of a module being disabled aren't so remote.
- var/list/valid_modules = list()
- var/list/damaged_modules = list()
- for(var/obj/item/rig_module/module in installed_modules)
- if(module.damage < 2)
- valid_modules |= module
- if(module.damage > 0)
- damaged_modules |= module
-
- var/obj/item/rig_module/dam_module = null
- if(damaged_modules.len)
- dam_module = pick(damaged_modules)
- else if(valid_modules.len)
- dam_module = pick(valid_modules)
-
- if(!dam_module) return
-
- dam_module.damage++
-
- if(!source)
- source = "hit"
-
- if(wearer)
- if(dam_module.damage >= 2)
- to_chat(wearer, "The [source] has disabled your [dam_module.interface_name]!")
- else
- to_chat(wearer, "The [source] has damaged your [dam_module.interface_name]!")
- dam_module.deactivate()
-
-/obj/item/rig/proc/malfunction_check(var/mob/living/carbon/human/user)
- if(malfunction_delay)
- if(offline)
- to_chat(user, "The suit is completely unresponsive.")
- else
- to_chat(user, "ERROR: Hardware fault. Rebooting interface...")
- return 1
- return 0
-
-/obj/item/rig/proc/ai_can_move_suit(var/mob/user, var/check_user_module = 0, var/check_for_ai = 0)
-
- if(check_for_ai)
- if(!(locate(/obj/item/rig_module/ai_container) in contents))
- return 0
- var/found_ai
- for(var/obj/item/rig_module/ai_container/module in contents)
- if(module.damage >= 2)
- continue
- if(module.integrated_ai && module.integrated_ai.client && !module.integrated_ai.stat)
- found_ai = 1
- break
- if(!found_ai)
- return 0
-
- if(check_user_module)
- if(!user || !user.loc || !user.loc.loc)
- return 0
- var/obj/item/rig_module/ai_container/module = user.loc.loc
- if(!istype(module) || module.damage >= 2)
- to_chat(user, "Your host module is unable to interface with the suit.")
- return 0
-
- if(offline || !cell || !cell.charge || locked_down)
- if(user)
- to_chat(user, "Your host rig is unpowered and unresponsive.")
- return 0
- if(!wearer || wearer.back != src)
- if(user)
- to_chat(user, "Your host rig is not being worn.")
- return 0
- if(!wearer.stat && !control_overridden && !ai_override_enabled)
- if(user)
- to_chat(user, "You are locked out of the suit servo controller.")
- return 0
- return 1
-
-/obj/item/rig/proc/force_rest(var/mob/user)
- if(!ai_can_move_suit(user, check_user_module = 1))
- return
- wearer.lay_down()
- to_chat(user, "\The [wearer] is now [wearer.resting ? "resting" : "getting up"].")
-
-/obj/item/rig/proc/forced_move(var/direction, var/mob/user)
-
- // Why is all this shit in client/Move()? Who knows?
- if(world.time < wearer_move_delay)
- return
-
- if(!wearer || !wearer.loc || !ai_can_move_suit(user, check_user_module = 1))
- return
-
- //This is sota the goto stop mobs from moving var
- if(wearer.notransform || !wearer.canmove)
- return
-
- if(!wearer.lastarea)
- wearer.lastarea = get_area(wearer.loc)
-
- if((istype(wearer.loc, /turf/space)) || (wearer.lastarea.has_gravity == 0))
- if(!wearer.Process_Spacemove(0))
- return 0
-
- if(malfunctioning)
- direction = pick(GLOB.cardinal)
-
- // Inside an object, tell it we moved.
- if(isobj(wearer.loc) || ismob(wearer.loc))
- var/atom/O = wearer.loc
- return O.relaymove(wearer, direction)
-
- if(isturf(wearer.loc))
- if(wearer.restrained())//Why being pulled while cuffed prevents you from moving
- for(var/mob/M in range(wearer, 1))
- if(M.pulling == wearer)
- if(!M.restrained() && M.stat == 0 && M.canmove && wearer.Adjacent(M))
- to_chat(user, "Your host is restrained! They can't move!")
- return 0
- else
- M.stop_pulling()
-
- // AIs are a bit slower than regular and ignore move intent.
- wearer_move_delay = world.time + ai_controlled_move_delay
-
- if(wearer.buckled) //if we're buckled to something, tell it we moved.
- return wearer.buckled.relaymove(wearer, direction)
-
- if(cell.use(200)) //Arbitrary, TODO
- wearer.Move(get_step(get_turf(wearer),direction),direction)
-
-// This returns the rig if you are contained inside one, but not if you are wearing it
-/atom/proc/get_rig()
- if(loc)
- return loc.get_rig()
- return null
-
-/obj/item/rig/get_rig()
- return src
-
-/mob/living/carbon/human/get_rig()
- if(istype(back,/obj/item/rig))
- return back
- else
- return null
-
-/obj/item/rig/proc/emergency_release()
- set name = "Suit Emergency Release"
- set desc = "Activate the suits emergency release system."
- set category = "Object"
- set src in oview(1)
- var/obj/item/rig/T = get_rig()
- return T.do_emergency_release(usr)
-
-/obj/item/rig/proc/do_emergency_release(var/mob/living/user)
- if(!can_touch(user, wearer) || !has_emergency_release)
- return can_touch(user,wearer)
- usr.visible_message("[user] starts activating \the [src] emergency seals release!")
- if(!do_after(user, 240, target = wearer))
- to_chat(user, "You need to focus on activating the emergency release.")
- return 0
- usr.visible_message("[user] activated \the [src] emergency seals release!")
- malfunctioning += 1
- malfunction_delay = 30
- unseal(user)
- return 1
-
-/obj/item/rig/proc/can_touch(var/mob/user, var/mob/wearer)
- if(!user)
- return 0
- if(!wearer.Adjacent(user))
- return 0
- if(user.restrained())
- to_chat(user, "You need your hands free for this.")
- return 0
- if(user.stat || user.paralysis || user.sleeping || user.lying || user.IsWeakened())
- return 0
- return 1
-#undef ONLY_DEPLOY
-#undef ONLY_RETRACT
-#undef SEAL_DELAY
diff --git a/code/modules/clothing/spacesuits/rig/rig_armormod.dm b/code/modules/clothing/spacesuits/rig/rig_armormod.dm
deleted file mode 100644
index c04270aa97b..00000000000
--- a/code/modules/clothing/spacesuits/rig/rig_armormod.dm
+++ /dev/null
@@ -1,30 +0,0 @@
-/obj/item/clothing/suit/space/new_rig/calc_breach_damage()
- ..()
- holder.update_armor() //New dammage, new armormultiplikator.
- return damage
-
-/obj/item/rig/proc/update_armor()
- var/multi = 1 //Multiplicative modification to the armor, maybe add an additive later on
- if(chest)
- multi *= (100 - chest.damage) / 100 //If we have some breaches, lower the armor value.
-
- //TODO check for other armor mods, likely modules, which need to be coded.
- if(!armor) //Did we even give them some armor, if this is the case, the list should be initialized from New()
- return
-
- var/datum/armor/A = armor
- for(var/obj/item/piece in list(gloves, helmet, boots, chest))
- if(!istype(piece)) //Do we have the piece
- continue
-
- piece.armor = piece.armor.setRating(melee_value = A.getRating("melee") * multi,
- bullet_value = A.getRating("bullet") * multi,
- laser_value = A.getRating("laser") * multi,
- energy_value = A.getRating("energy") * multi,
- bomb_value = A.getRating("bomb") * multi,
- bio_value = A.getRating("bio") * multi,
- rad_value = A.getRating("rad") * multi,
- fire_value = A.getRating("fire") * multi,
- acid_value = A.getRating("acidd") * multi)
-
-//Perfect place to also add something like shield modules, or any other hit_reaction modules check.
diff --git a/code/modules/clothing/spacesuits/rig/rig_attackby.dm b/code/modules/clothing/spacesuits/rig/rig_attackby.dm
deleted file mode 100644
index b48e17b2c41..00000000000
--- a/code/modules/clothing/spacesuits/rig/rig_attackby.dm
+++ /dev/null
@@ -1,196 +0,0 @@
-/obj/item/rig/attackby(obj/item/W as obj, mob/user as mob)
-
- if(!istype(user,/mob/living)) return 0
-
- if(electrified != 0)
- if(shock(user)) //Handles removing charge from the cell, as well. No need to do that here.
- return
-
- // Pass repair items on to the chestpiece.
- if(chest && (istype(W,/obj/item/stack) || istype(W, /obj/item/weldingtool)))
- return chest.attackby(W,user)
-
- // Lock or unlock the access panel.
- if(W.GetID())
- if(subverted)
- locked = 0
- to_chat(user, "It looks like the locking system has been shorted out.")
- return
-
- if((!req_access || !req_access.len) && (!req_one_access || !req_one_access.len))
- locked = 0
- to_chat(user, "\The [src] doesn't seem to have a locking mechanism.")
- return
-
- if(security_check_enabled && !src.allowed(user))
- to_chat(user, "Access denied.")
- return
-
- locked = !locked
- to_chat(user, "You [locked ? "lock" : "unlock"] \the [src] access panel.")
- return
-
- else if(istype(W,/obj/item/crowbar))
-
- if(!open && locked)
- to_chat(user, "The access panel is locked shut.")
- return
-
- open = !open
- to_chat(user, "You [open ? "open" : "close"] the access panel.")
- return
-
- if(open)
-
- // Hacking.
- if(istype(W,/obj/item/wirecutters) || istype(W,/obj/item/multitool))
- if(open)
- wires.Interact(user)
- else
- to_chat(user, "You can't reach the wiring.")
- return
- // Air tank.
- if(istype(W,/obj/item/tank)) //Todo, some kind of check for suits without integrated air supplies.
-
- if(air_supply)
- to_chat(user, "\The [src] already has a tank installed.")
- return
-
- user.unEquip(W)
- air_supply = W
- W.forceMove(src)
- to_chat(user, "You slot [W] into [src] and tighten the connecting valve.")
- return
-
- // Check if this is a hardsuit upgrade or a modification.
- else if(istype(W,/obj/item/rig_module))
-
- if(istype(src.loc,/mob/living/carbon/human))
- var/mob/living/carbon/human/H = src.loc
- if(H.back == src)
- to_chat(user, "You can't install a hardsuit module while the suit is being worn.")
- return 1
-
- if(!installed_modules) installed_modules = list()
- if(installed_modules.len)
- for(var/obj/item/rig_module/installed_mod in installed_modules)
- if(!installed_mod.redundant && istype(installed_mod,W))
- to_chat(user, "The hardsuit already has a module of that class installed.")
- return 1
-
- var/obj/item/rig_module/mod = W
- to_chat(user, "You begin installing \the [mod] into \the [src].")
- if(!do_after(user, 40 * W.toolspeed, target = src))
- return
- if(!user || !W)
- return
- to_chat(user, "You install \the [mod] into \the [src].")
- user.unEquip(mod)
- installed_modules |= mod
- mod.forceMove(src)
- mod.installed(src)
- update_icon()
- return 1
-
- else if(!cell && istype(W,/obj/item/stock_parts/cell))
-
- to_chat(user, "You jack \the [W] into \the [src]'s battery mount.")
- user.unEquip(W)
- W.forceMove(src)
- src.cell = W
- return
-
- else if(istype(W,/obj/item/wrench))
-
- if(!air_supply)
- to_chat(user, "There is not tank to remove.")
- return
-
- if(user.r_hand && user.l_hand)
- air_supply.forceMove(get_turf(user))
- else
- user.put_in_hands(air_supply)
- to_chat(user, "You detach and remove \the [air_supply].")
- air_supply = null
- return
-
- else if(istype(W,/obj/item/screwdriver))
-
- var/list/current_mounts = list()
- if(cell) current_mounts += "cell"
- if(installed_modules && installed_modules.len) current_mounts += "system module"
-
- var/to_remove = input("Which would you like to modify?") as null|anything in current_mounts
- if(!to_remove)
- return
-
- if(istype(src.loc,/mob/living/carbon/human) && to_remove != "cell")
- var/mob/living/carbon/human/H = src.loc
- if(H.back == src)
- to_chat(user, "You can't remove an installed device while the hardsuit is being worn.")
- return
-
- switch(to_remove)
-
- if("cell")
-
- if(cell)
- to_chat(user, "You detatch \the [cell] from \the [src]'s battery mount.")
- for(var/obj/item/rig_module/module in installed_modules)
- module.deactivate()
- if(user.r_hand && user.l_hand)
- cell.forceMove(get_turf(user))
- else
- user.put_in_hands(cell)
- cell = null
- else
- to_chat(user, "There is nothing loaded in that mount.")
-
- if("system module")
-
- var/list/possible_removals = list()
- for(var/obj/item/rig_module/module in installed_modules)
- if(module.permanent)
- continue
- possible_removals[module.name] = module
-
- if(!possible_removals.len)
- to_chat(user, "There are no installed modules to remove.")
- return
-
- var/removal_choice = input("Which module would you like to remove?") as null|anything in possible_removals
- if(!removal_choice)
- return
-
- var/obj/item/rig_module/removed = possible_removals[removal_choice]
- to_chat(user, "You detatch \the [removed] from \the [src].")
- removed.forceMove(get_turf(src))
- removed.removed()
- installed_modules -= removed
- update_icon()
-
- return
-
- // If we've gotten this far, all we have left to do before we pass off to root procs
- // is check if any of the loaded modules want to use the item we've been given.
- for(var/obj/item/rig_module/module in installed_modules)
- if(module.accepts_item(W,user)) //Item is handled in this proc
- return
- ..()
-
-
-/obj/item/rig/attack_hand(var/mob/user)
-
- if(electrified != 0)
- if(shock(user)) //Handles removing charge from the cell, as well. No need to do that here.
- return
- ..()
-
-/obj/item/rig/emag_act(var/remaining_charges, var/mob/user)
- if(!subverted)
- req_access.Cut()
- req_one_access.Cut()
- locked = 0
- subverted = 1
- to_chat(user, "You short out the access protocol for the suit.")
- return 1
diff --git a/code/modules/clothing/spacesuits/rig/rig_pieces.dm b/code/modules/clothing/spacesuits/rig/rig_pieces.dm
deleted file mode 100644
index 246e3beb10f..00000000000
--- a/code/modules/clothing/spacesuits/rig/rig_pieces.dm
+++ /dev/null
@@ -1,147 +0,0 @@
-/*
- * Defines the helmets, gloves and shoes for rigs.
- */
-
-/obj/item/clothing/head/helmet/space/new_rig
- name = "helmet"
- flags = BLOCKHAIR | THICKMATERIAL | NODROP
- flags_inv = HIDEEARS|HIDEEYES|HIDEFACE|HIDEMASK
- body_parts_covered = HEAD
- heat_protection = HEAD
- cold_protection = HEAD
- var/brightness_on = 4
- var/on = 0
- sprite_sheets = list(
- "Tajaran" = 'icons/mob/species/tajaran/helmet.dmi',
- "Skrell" = 'icons/mob/species/skrell/helmet.dmi',
- "Unathi" = 'icons/mob/species/unathi/helmet.dmi'
- )
- species_restricted = null
- actions_types = list(/datum/action/item_action/toggle_helmet_light)
-
- flash_protect = 2
-
-/obj/item/clothing/head/helmet/space/new_rig/attack_self(mob/user)
- if(!isturf(user.loc))
- to_chat(user, "You cannot turn the light on while in this [user.loc].")//To prevent some lighting anomalities.
-
- return
- toggle_light(user)
-
-/obj/item/clothing/head/helmet/space/new_rig/proc/toggle_light(mob/user)
- if(flags & AIRTIGHT) //Could also check for STOPSPRESSUREDMAGE, but one is enough, both get toggled when the seal gets toggled.
-
- on = !on
- icon_state = "[item_color][on]"
-
- if(on)
- set_light(brightness_on)
- else
- set_light(0)
- else
- to_chat(user, "You cannot turn the light on while the suit isn't sealed.")
-
- if(istype(user,/mob/living/carbon/human))
- var/mob/living/carbon/human/H = user
- H.update_inv_head()
-
-/obj/item/clothing/gloves/rig
- name = "gauntlets"
- flags = THICKMATERIAL | NODROP
- body_parts_covered = HANDS
- heat_protection = HANDS
- cold_protection = HANDS
- species_restricted = null
- gender = PLURAL
-
-/obj/item/clothing/shoes/magboots/rig
- name = "boots"
- flags = NODROP
- body_parts_covered = FEET
- cold_protection = FEET
- heat_protection = FEET
- species_restricted = null
- gender = PLURAL
-
-/obj/item/clothing/shoes/magboots/rig/attack_self(mob/user)
- if(flags & AIRTIGHT) //Could also check for STOPSPRESSUREDMAGE, but one is enough, both get toggled when the seal gets toggled.
- ..(user)
- else
- to_chat(user, "You cannot activate mag-pulse traction system while the suit is not sealed.")
-
-/obj/item/clothing/suit/space/new_rig
- name = "chestpiece"
- allowed = list(/obj/item/flashlight,/obj/item/tank)
- body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
- heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
- cold_protection = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
- flags_inv = HIDEJUMPSUIT|HIDETAIL
- flags = STOPSPRESSUREDMAGE | THICKMATERIAL | AIRTIGHT | NODROP
- slowdown = 0
- breach_threshold = 20
- resilience = 0.2
- can_breach = 1
- var/obj/item/rig/holder
- sprite_sheets = list(
- "Tajaran" = 'icons/mob/species/tajaran/suit.dmi',
- "Unathi" = 'icons/mob/species/unathi/suit.dmi'
- )
-
-//TODO: move this to modules
-/obj/item/clothing/head/helmet/space/new_rig/proc/prevent_track()
- return 0
-
-/obj/item/clothing/gloves/rig/Touch(var/atom/A, var/proximity)
-
- if(!A || !proximity)
- return 0
-
- var/mob/living/carbon/human/H = loc
- if(!istype(H) || !H.back)
- return 0
-
- var/obj/item/rig/suit = H.back
- if(!suit || !istype(suit) || !suit.installed_modules.len)
- return 0
-
- for(var/obj/item/rig_module/module in suit.installed_modules)
- if(module.active && module.activates_on_touch)
- if(module.engage(A))
- return 1
-
- return 0
-
-//Rig pieces for non-spacesuit based rigs
-
-/obj/item/clothing/head/lightrig
- name = "mask"
- body_parts_covered = HEAD
- heat_protection = HEAD
- cold_protection = HEAD
- flags = THICKMATERIAL|AIRTIGHT
-
-/obj/item/clothing/suit/lightrig
- name = "suit"
- allowed = list(/obj/item/flashlight)
- body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
- heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
- cold_protection = UPPER_TORSO|LOWER_TORSO|LEGS|ARMS
- flags_inv = HIDEJUMPSUIT
- flags = THICKMATERIAL
-
-/obj/item/clothing/shoes/lightrig
- name = "boots"
- body_parts_covered = FEET
- cold_protection = FEET
- heat_protection = FEET
- species_restricted = null
- gender = PLURAL
-
-/obj/item/clothing/gloves/lightrig
- name = "gloves"
- flags = THICKMATERIAL
- body_parts_covered = HANDS
- heat_protection = HANDS
- cold_protection = HANDS
- species_restricted = null
- gender = PLURAL
diff --git a/code/modules/clothing/spacesuits/rig/rig_verbs.dm b/code/modules/clothing/spacesuits/rig/rig_verbs.dm
deleted file mode 100644
index 4a71f6c67bc..00000000000
--- a/code/modules/clothing/spacesuits/rig/rig_verbs.dm
+++ /dev/null
@@ -1,335 +0,0 @@
-// Interface for humans.
-/obj/item/rig/verb/hardsuit_interface()
- set name = "Open Hardsuit Interface"
- set desc = "Open the hardsuit system interface."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(wearer && wearer.back == src)
- ui_interact(usr)
-
-/obj/item/rig/verb/toggle_vision()
- set name = "Toggle Visor"
- set desc = "Turns your rig visor off or on."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- if(!check_power_cost(usr))
- return
-
- if(!(flags & NODROP))
- to_chat(usr, "The suit is not active.")
- return
-
- if(!check_suit_access(usr))
- return
-
- if(!visor)
- to_chat(usr, "The hardsuit does not have a configurable visor.")
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- if(!visor.active)
- visor.activate()
- else
- visor.deactivate()
-
-/obj/item/rig/proc/toggle_helmet()
- set name = "Toggle Helmet"
- set desc = "Deploys or retracts your helmet."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- if(!check_suit_access(usr))
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- toggle_piece("helmet", usr)
-
-/obj/item/rig/proc/toggle_chest()
- set name = "Toggle Chestpiece"
- set desc = "Deploys or retracts your chestpiece."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(!check_suit_access(usr))
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- toggle_piece("chest", usr)
-
-/obj/item/rig/proc/toggle_gauntlets()
- set name = "Toggle Gauntlets"
- set desc = "Deploys or retracts your gauntlets."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- if(!check_suit_access(usr))
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- toggle_piece("gauntlets", usr)
-
-/obj/item/rig/proc/toggle_boots()
- set name = "Toggle Boots"
- set desc = "Deploys or retracts your boots."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- if(!check_suit_access(usr))
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- toggle_piece("boots", usr)
-
-/obj/item/rig/verb/deploy_suit()
- set name = "Deploy Hardsuit"
- set desc = "Deploys helmet, gloves and boots all at once."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- if(!check_suit_access(usr))
- return
-
- if(!check_power_cost(usr))
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- deploy(wearer, usr)
-
-/obj/item/rig/verb/toggle_seals_verb()
- set name = "Toggle Hardsuit Seals"
- set desc = "Seals or unseals your rig."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- if(!check_suit_access(usr))
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- if(flags & NODROP)
- unseal(usr)
- else
- seal(usr)
-
-/obj/item/rig/verb/switch_vision_mode()
- set name = "Switch Vision Mode"
- set desc = "Switches between available vision modes."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(malfunction_check(usr))
- return
-
- if(!check_power_cost(usr, 0, 0, 0, 0))
- return
-
- if(!(flags & NODROP))
- to_chat(usr, "The suit is not active.")
- return
-
- if(!visor)
- to_chat(usr, "The hardsuit does not have a configurable visor.")
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- if(!visor.active)
- visor.activate()
-
- if(!visor.active)
- to_chat(usr, "The visor is suffering a hardware fault and cannot be configured.")
- return
-
- visor.engage()
-
-/obj/item/rig/verb/alter_voice()
- set name = "Configure Voice Synthesiser"
- set desc = "Toggles or configures your voice synthesizer."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(malfunction_check(usr))
- return
-
- if(!(flags & NODROP))
- to_chat(usr, "The suit is not active.")
- return
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- if(!speech)
- to_chat(usr, "The hardsuit does not have a speech synthesiser.")
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- speech.engage()
-
-/obj/item/rig/verb/select_module()
- set name = "Select Module"
- set desc = "Selects a module as your primary system."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(malfunction_check(usr))
- return
-
- if(!check_power_cost(usr, 0, 0, 0, 0))
- return
-
- if(!(flags & NODROP))
- to_chat(usr, "The suit is not active.")
- return
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- var/list/selectable = list()
- for(var/obj/item/rig_module/module in installed_modules)
- if(module.selectable)
- selectable |= module
-
- var/obj/item/rig_module/module = input("Which module do you wish to select?") as null|anything in selectable
-
- if(!istype(module))
- selected_module = null
- to_chat(usr, "Primary system is now: deselected.")
- return
-
- selected_module = module
- to_chat(usr, "Primary system is now: [selected_module.interface_name].")
-
-/obj/item/rig/verb/toggle_module()
- set name = "Toggle Module"
- set desc = "Toggle a system module."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(malfunction_check(usr))
- return
-
- if(!check_power_cost(usr, 0, 0, 0, 0))
- return
-
- if(!(flags & NODROP))
- to_chat(usr, "The suit is not active.")
- return
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- var/list/selectable = list()
- for(var/obj/item/rig_module/module in installed_modules)
- if(module.toggleable)
- selectable |= module
-
- var/obj/item/rig_module/module = input("Which module do you wish to toggle?") as null|anything in selectable
-
- if(!istype(module))
- return
-
- if(module.active)
- to_chat(usr, "You attempt to deactivate \the [module.interface_name].")
- module.deactivate()
- else
- to_chat(usr, "You attempt to activate \the [module.interface_name].")
- module.activate()
-
-/obj/item/rig/verb/engage_module()
- set name = "Engage Module"
- set desc = "Engages a system module."
- set category = "Hardsuit"
- set src = usr.contents
-
- if(malfunction_check(usr))
- return
-
- if(!(flags & NODROP))
- to_chat(usr, "The suit is not active.")
- return
-
- if(!istype(wearer) || !wearer.back == src)
- to_chat(usr, "The hardsuit is not being worn.")
- return
-
- if(!check_power_cost(usr, 0, 0, 0, 0))
- return
-
- var/mob/M = usr
- if(M.incapacitated())
- return
-
- var/list/selectable = list()
- for(var/obj/item/rig_module/module in installed_modules)
- if(module.usable)
- selectable |= module
-
- var/obj/item/rig_module/module = input("Which module do you wish to engage?") as null|anything in selectable
-
- if(!istype(module))
- return
-
- to_chat(usr, "You attempt to engage the [module.interface_name].")
- module.engage()
diff --git a/code/modules/clothing/spacesuits/rig/rig_wiring.dm b/code/modules/clothing/spacesuits/rig/rig_wiring.dm
deleted file mode 100644
index 9d3108ac016..00000000000
--- a/code/modules/clothing/spacesuits/rig/rig_wiring.dm
+++ /dev/null
@@ -1,70 +0,0 @@
-/datum/wires/rig
- random = 1
- holder_type = /obj/item/rig
- wire_count = 5
-
-#define RIG_SECURITY 1
-#define RIG_AI_OVERRIDE 2
-#define RIG_SYSTEM_CONTROL 4
-#define RIG_INTERFACE_LOCK 8
-#define RIG_INTERFACE_SHOCK 16
-/*
- * Rig security can be snipped to disable ID access checks on rig.
- * Rig AI override can be pulsed to toggle whether or not the AI can take control of the suit.
- * System control can be pulsed to toggle some malfunctions.
- * Interface lock can be pulsed to toggle whether or not the interface can be accessed.
- */
-
-/datum/wires/rig/UpdateCut(var/index, var/mended)
-
- var/obj/item/rig/rig = holder
- switch(index)
- if(RIG_SECURITY)
- if(mended)
- rig.req_access = initial(rig.req_access)
- rig.req_one_access = initial(rig.req_one_access)
- if(RIG_INTERFACE_SHOCK)
- rig.electrified = mended ? 0 : -1
- rig.shock(usr,100)
-
-/datum/wires/rig/UpdatePulsed(var/index)
-
- var/obj/item/rig/rig = holder
- switch(index)
- if(RIG_SECURITY)
- rig.security_check_enabled = !rig.security_check_enabled
- rig.visible_message("\The [rig] twitches as several suit locks [rig.security_check_enabled?"close":"open"].")
- if(RIG_AI_OVERRIDE)
- rig.ai_override_enabled = !rig.ai_override_enabled
- rig.visible_message("A small red light on [rig] [rig.ai_override_enabled?"goes dead":"flickers on"].")
- if(RIG_SYSTEM_CONTROL)
- rig.malfunctioning += 10
- if(rig.malfunction_delay <= 0)
- rig.malfunction_delay = 20
- rig.shock(usr,100)
- if(RIG_INTERFACE_LOCK)
- rig.interface_locked = !rig.interface_locked
- rig.visible_message("\The [rig] clicks audibly as the software interface [rig.interface_locked?"darkens":"brightens"].")
- if(RIG_INTERFACE_SHOCK)
- if(rig.electrified != -1)
- rig.electrified = 30
- rig.shock(usr,100)
-
-/datum/wires/rig/GetWireName(index)
- switch(index)
- if(RIG_SECURITY)
- return "ID check"
- if(RIG_AI_OVERRIDE)
- return "AI control"
- if(RIG_SYSTEM_CONTROL)
- return "System control"
- if(RIG_INTERFACE_LOCK)
- return "Interface lock"
- if(RIG_INTERFACE_SHOCK)
- return "Electrification"
-
-/datum/wires/rig/CanUse(var/mob/living/L)
- var/obj/item/rig/rig = holder
- if(rig.open)
- return 1
- return 0
diff --git a/code/modules/clothing/spacesuits/rig/suits/alien.dm b/code/modules/clothing/spacesuits/rig/suits/alien.dm
deleted file mode 100644
index 25c784ba7dd..00000000000
--- a/code/modules/clothing/spacesuits/rig/suits/alien.dm
+++ /dev/null
@@ -1,46 +0,0 @@
-/obj/item/rig/unathi
- name = "NT breacher chassis control module"
- desc = "A cheap NT knock-off of an Unathi battle-rig. Looks like a fish, moves like a fish, steers like a cow."
- suit_type = "NT breacher"
- icon_state = "breacher_rig_cheap"
- armor = list(melee = 30, bullet = 30, laser = 30, energy = 30, bomb = 45, bio = 100, rad = 50)
- emp_protection = -20
- active_slowdown = 6
- offline_slowdown = 10
- vision_restriction = 1
- offline_vision_restriction = 2
-
- chest_type = /obj/item/clothing/suit/space/new_rig/unathi
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/unathi
- glove_type = /obj/item/clothing/gloves/rig/unathi
- boot_type = /obj/item/clothing/shoes/magboots/rig/unathi
-
-/obj/item/rig/unathi/fancy
- name = "breacher chassis control module"
- desc = "An authentic Unathi breacher chassis. Huge, bulky and absurdly heavy. It must be like wearing a tank."
- suit_type = "breacher chassis"
- icon_state = "breacher_rig"
- armor = list(melee = 45, bullet = 45, laser = 45, energy = 45, bomb = 45, bio = 100, rad = 75) //Takes TEN TIMES as much damage to stop someone in a breacher. In exchange, it's slow. //Whoever made this was on meth
- vision_restriction = 0
-
-/obj/item/clothing/head/helmet/space/new_rig/unathi
- icon = 'icons/obj/clothing/species/unathi/hats.dmi'
- species_restricted = list("Unathi")
-
-/obj/item/clothing/suit/space/new_rig/unathi
- icon = 'icons/obj/clothing/species/unathi/suits.dmi'
- species_restricted = list("Unathi")
-
-/obj/item/clothing/gloves/rig/unathi
- icon = 'icons/obj/clothing/species/unathi/gloves.dmi'
- species_restricted = list("Unathi")
- sprite_sheets = list(
- "Unathi" = 'icons/mob/species/unathi/gloves.dmi'
- )
-
-/obj/item/clothing/shoes/magboots/rig/unathi
- icon = 'icons/obj/clothing/species/unathi/shoes.dmi'
- species_restricted = list("Unathi")
- sprite_sheets = list(
- "Unathi" = 'icons/mob/species/unathi/feet.dmi'
- )
diff --git a/code/modules/clothing/spacesuits/rig/suits/combat.dm b/code/modules/clothing/spacesuits/rig/suits/combat.dm
deleted file mode 100644
index cc05c8af2f7..00000000000
--- a/code/modules/clothing/spacesuits/rig/suits/combat.dm
+++ /dev/null
@@ -1,28 +0,0 @@
-/obj/item/clothing/head/helmet/space/new_rig/combat
-
-/obj/item/rig/combat
- name = "combat hardsuit control module"
- desc = "A sleek and dangerous hardsuit for active combat."
- icon_state = "security_rig"
- suit_type = "combat hardsuit"
- armor = list(melee = 80, bullet = 80, laser = 50, energy = 50, bomb = 100, bio = 100, rad = 100)
- active_slowdown = 1
- offline_slowdown = 3
- offline_vision_restriction = 1
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/combat
- allowed = list(/obj/item/gun,/obj/item/flashlight,/obj/item/tank,/obj/item/melee/baton)
-
-
-/obj/item/rig/combat/equipped
-
-
- initial_modules = list(
- /obj/item/rig_module/mounted,
- /obj/item/rig_module/vision/thermal,
- /obj/item/rig_module/grenade_launcher,
- /obj/item/rig_module/ai_container,
- // /obj/item/rig_module/power_sink,
- /obj/item/rig_module/electrowarfare_suite,
- /obj/item/rig_module/chem_dispenser/combat
- )
diff --git a/code/modules/clothing/spacesuits/rig/suits/ert_suits.dm b/code/modules/clothing/spacesuits/rig/suits/ert_suits.dm
deleted file mode 100644
index 5485e1fe882..00000000000
--- a/code/modules/clothing/spacesuits/rig/suits/ert_suits.dm
+++ /dev/null
@@ -1,81 +0,0 @@
-/obj/item/clothing/head/helmet/space/new_rig/ert
-
-/obj/item/rig/ert
- name = "ERT-C hardsuit control module"
- desc = "A suit worn by the commander of an Emergency Response Team. Has blue highlights. Armoured and space ready."
- suit_type = "ERT commander"
- icon_state = "ert_commander_rig"
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/ert
-
- req_access = list(ACCESS_CENT_SPECOPS)
-
- armor = list(melee = 45, bullet = 25, laser = 30, energy = 10, bomb = 25, bio = 100, rad = 50)
- allowed = list(/obj/item/flashlight, /obj/item/tank, /obj/item/t_scanner, /obj/item/rcd, /obj/item/crowbar, \
- /obj/item/screwdriver, /obj/item/weldingtool, /obj/item/wirecutters, /obj/item/wrench, /obj/item/multitool, \
- /obj/item/radio, /obj/item/analyzer,/obj/item/storage/briefcase/inflatable, /obj/item/melee/baton, /obj/item/gun, \
- /obj/item/storage/firstaid, /obj/item/reagent_containers/hypospray, /obj/item/roller)
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/maneuvering_jets,
- /obj/item/rig_module/datajack,
- )
-
-/obj/item/rig/ert/engineer
- name = "ERT-E suit control module"
- desc = "A suit worn by the engineering division of an Emergency Response Team. Has orange highlights. Armoured and space ready."
- suit_type = "ERT engineer"
- icon_state = "ert_engineer_rig"
- siemens_coefficient = 0
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/maneuvering_jets,
- /obj/item/rig_module/device/plasmacutter,
- // /obj/item/rig_module/device/rcd
- )
-
-/obj/item/rig/ert/medical
- name = "ERT-M suit control module"
- desc = "A suit worn by the medical division of an Emergency Response Team. Has white highlights. Armoured and space ready."
- suit_type = "ERT medic"
- icon_state = "ert_medical_rig"
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/maneuvering_jets,
- /obj/item/rig_module/device/healthscanner,
- /obj/item/rig_module/chem_dispenser/injector
- )
-
-/obj/item/rig/ert/security
- name = "ERT-S suit control module"
- desc = "A suit worn by the security division of an Emergency Response Team. Has red highlights. Armoured and space ready."
- suit_type = "ERT security"
- icon_state = "ert_security_rig"
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/maneuvering_jets,
- /obj/item/rig_module/grenade_launcher,
- /obj/item/rig_module/mounted/egun,
- )
-
-/obj/item/rig/ert/assetprotection
- name = "Heavy Asset Protection suit control module"
- desc = "A heavy suit worn by the highest level of Asset Protection, don't mess with the person wearing this. Armoured and space ready."
- suit_type = "heavy asset protection"
- icon_state = "asset_protection_rig"
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/maneuvering_jets,
- /obj/item/rig_module/grenade_launcher,
- /obj/item/rig_module/vision/multi,
- /obj/item/rig_module/mounted/egun,
- /obj/item/rig_module/chem_dispenser/injector,
- /obj/item/rig_module/device/plasmacutter,
- // /obj/item/rig_module/device/rcd,
- /obj/item/rig_module/datajack
- )
diff --git a/code/modules/clothing/spacesuits/rig/suits/light.dm b/code/modules/clothing/spacesuits/rig/suits/light.dm
deleted file mode 100644
index d76691daf57..00000000000
--- a/code/modules/clothing/spacesuits/rig/suits/light.dm
+++ /dev/null
@@ -1,120 +0,0 @@
-// Light rigs are not space-capable, but don't suffer excessive slowdown or sight issues when depowered.
-/obj/item/rig/light
- name = "light suit control module"
- desc = "A lighter, less armoured rig suit."
- icon_state = "ninja_rig"
- suit_type = "light suit"
- allowed = list(/obj/item/gun,/obj/item/ammo_casing,/obj/item/melee/baton,/obj/item/restraints/handcuffs,/obj/item/tank,/obj/item/stock_parts/cell)
- emp_protection = 10
- active_slowdown = 0
- flags = STOPSPRESSUREDMAGE | THICKMATERIAL
- offline_slowdown = 0
- offline_vision_restriction = 0
-
- chest_type = /obj/item/clothing/suit/space/new_rig/light
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/light
- boot_type = /obj/item/clothing/shoes/magboots/rig/light
- glove_type = /obj/item/clothing/gloves/rig/light
-
-/obj/item/clothing/suit/space/new_rig/light
- name = "suit"
- breach_threshold = 18 //comparable to voidsuits
-
-/obj/item/clothing/gloves/rig/light
- name = "gloves"
-
-/obj/item/clothing/shoes/magboots/rig/light
- name = "shoes"
-
-/obj/item/clothing/head/helmet/space/new_rig/light
- name = "hood"
-
-/obj/item/rig/light/hacker
- name = "cybersuit control module"
- suit_type = "cyber"
- desc = "An advanced powered armour suit with many cyberwarfare enhancements. Comes with built-in insulated gloves for safely tampering with electronics."
- icon_state = "hacker_rig"
-
- req_access = list(ACCESS_SYNDICATE)
-
- airtight = 0
- seal_delay = 5 //not being vaccum-proof has an upside I guess
-
- helm_type = /obj/item/clothing/head/lightrig/hacker
- chest_type = /obj/item/clothing/suit/lightrig/hacker
- glove_type = /obj/item/clothing/gloves/lightrig/hacker
- boot_type = /obj/item/clothing/shoes/lightrig/hacker
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- // /obj/item/rig_module/power_sink,
- /obj/item/rig_module/datajack,
- /obj/item/rig_module/electrowarfare_suite,
- /obj/item/rig_module/voice,
- /obj/item/rig_module/vision,
- )
-
-//The cybersuit is not space-proof. It does however, have good siemens_coefficient values
-/obj/item/clothing/head/lightrig/hacker
- name = "HUD"
- siemens_coefficient = 0.4
- flags = 0
-
-/obj/item/clothing/suit/lightrig/hacker
- siemens_coefficient = 0.4
-
-/obj/item/clothing/shoes/lightrig/hacker
- siemens_coefficient = 0.4
- flags = NOSLIP //All the other rigs have magboots anyways, hopefully gives the hacker suit something more going for it.
-
-/obj/item/clothing/gloves/lightrig/hacker
- siemens_coefficient = 0
-
-/obj/item/rig/light/ninja
- name = "ominous suit control module"
- suit_type = "ominous"
- desc = "A unique, vaccum-proof suit of nano-enhanced armor designed specifically for Spider Clan assassins."
- icon_state = "ninja_rig"
- armor = list(melee = 50, bullet = 15, laser = 30, energy = 10, bomb = 25, bio = 100, rad = 30)
- emp_protection = 40 //change this to 30 if too high.
- active_slowdown = 0
-
- chest_type = /obj/item/clothing/suit/space/new_rig/light/ninja
- glove_type = /obj/item/clothing/gloves/rig/light/ninja
-
- req_access = list(ACCESS_SYNDICATE)
-
- initial_modules = list(
- /obj/item/rig_module/teleporter,
- /obj/item/rig_module/stealth_field,
- /obj/item/rig_module/mounted/energy_blade,
- /obj/item/rig_module/vision,
- /obj/item/rig_module/voice,
- /obj/item/rig_module/chem_dispenser,
- /obj/item/rig_module/grenade_launcher,
- /obj/item/rig_module/fabricator,
- /obj/item/rig_module/ai_container,
- // /obj/item/rig_module/power_sink,
- /obj/item/rig_module/datajack,
- /obj/item/rig_module/self_destruct
- )
-
-/obj/item/clothing/gloves/rig/light/ninja
- name = "insulated gloves"
- siemens_coefficient = 0
-
-/obj/item/clothing/suit/space/new_rig/light/ninja
- breach_threshold = 38 //comparable to regular hardsuits
-
-/obj/item/rig/light/stealth
- name = "stealth suit control module"
- suit_type = "stealth"
- desc = "A highly advanced and expensive suit designed for covert operations."
- icon_state = "ninja_rig" //supposed to be "stealth_rig", but as it currently only has a semi-copied ninja rig sprite, we can just use them directly.
-
- req_access = list(ACCESS_SYNDICATE)
-
- initial_modules = list(
- /obj/item/rig_module/stealth_field,
- /obj/item/rig_module/vision
- )
diff --git a/code/modules/clothing/spacesuits/rig/suits/merc.dm b/code/modules/clothing/spacesuits/rig/suits/merc.dm
deleted file mode 100644
index 95abba52df9..00000000000
--- a/code/modules/clothing/spacesuits/rig/suits/merc.dm
+++ /dev/null
@@ -1,32 +0,0 @@
-/obj/item/clothing/head/helmet/space/new_rig/merc
-
-/obj/item/rig/merc
- name = "crimson hardsuit control module"
- desc = "A blood-red hardsuit featuring some fairly illegal technology."
- icon_state = "merc_rig"
- suit_type = "crimson hardsuit"
- armor = list(melee = 40, bullet = 50, laser = 30, energy = 15, bomb = 35, bio = 100, rad = 50)
- active_slowdown = 1
- offline_slowdown = 3
- offline_vision_restriction = 1
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/merc
- allowed = list(/obj/item/flashlight,/obj/item/tank,/obj/item/gun,/obj/item/ammo_casing,/obj/item/melee/baton,/obj/item/melee/energy/sword,/obj/item/restraints/handcuffs)
-
- initial_modules = list(
- /obj/item/rig_module/mounted,
- /obj/item/rig_module/vision/thermal,
- /obj/item/rig_module/grenade_launcher,
- /obj/item/rig_module/ai_container,
- // /obj/item/rig_module/power_sink,
- /obj/item/rig_module/electrowarfare_suite,
- /obj/item/rig_module/chem_dispenser/combat,
- // /obj/item/rig_module/fabricator/energy_net
- )
-
-//Has most of the modules removed
-/obj/item/rig/merc/empty
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/electrowarfare_suite, //might as well
- )
diff --git a/code/modules/clothing/spacesuits/rig/suits/station.dm b/code/modules/clothing/spacesuits/rig/suits/station.dm
deleted file mode 100644
index c4bbd059fae..00000000000
--- a/code/modules/clothing/spacesuits/rig/suits/station.dm
+++ /dev/null
@@ -1,223 +0,0 @@
-/obj/item/clothing/head/helmet/space/new_rig/industrial
-
-/obj/item/clothing/head/helmet/space/new_rig/ce
-
-/obj/item/clothing/head/helmet/space/new_rig/eva
-
-/obj/item/clothing/head/helmet/space/new_rig/hazmat
-
-/obj/item/clothing/head/helmet/space/new_rig/medical
-
-/obj/item/clothing/head/helmet/space/new_rig/hazard
-
-/obj/item/rig/internalaffairs
- name = "augmented tie"
- suit_type = "augmented suit"
- desc = "Prepare for paperwork."
- icon_state = "internalaffairs_rig"
- armor = list(melee = 0, bullet = 0, laser = 0, energy = 0, bomb = 0, bio = 0, rad = 0)
- siemens_coefficient = 0.9
- active_slowdown = 0
- offline_slowdown = 0
- offline_vision_restriction = 0
-
- allowed = list(/obj/item/flashlight,/obj/item/tank,/obj/item/storage/briefcase,/obj/item/storage/secure/briefcase)
-
- req_access = list()
- req_one_access = list()
-
- glove_type = null
- helm_type = null
- boot_type = null
-
-/obj/item/rig/internalaffairs/equipped
-
- req_access = list(ACCESS_LAWYER)
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/device/flash,
- /obj/item/rig_module/device/paperdispenser,
- /obj/item/rig_module/device/pen,
- /obj/item/rig_module/device/stamp
- )
-
- glove_type = null
- helm_type = null
- boot_type = null
-
-/obj/item/rig/industrial
- name = "industrial suit control module"
- suit_type = "industrial hardsuit"
- desc = "A heavy, powerful rig used by construction crews and mining corporations."
- icon_state = "engineering_rig"
- armor = list(melee = 10, bullet = 5, laser = 10, energy = 5, bomb = 10, bio = 100, rad = 75)
- active_slowdown = 3
- offline_slowdown = 10
- offline_vision_restriction = 2
- emp_protection = -20
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/industrial
-
- allowed = list(/obj/item/flashlight,/obj/item/tank,/obj/item/storage/bag/ore,/obj/item/t_scanner,/obj/item/pickaxe, /obj/item/rcd)
-
- req_access = list()
- req_one_access = list()
-
-
-/obj/item/rig/industrial/equipped
-
- initial_modules = list(
- /obj/item/rig_module/device/plasmacutter,
- /obj/item/rig_module/device/drill,
- /obj/item/rig_module/device/orescanner,
- // /obj/item/rig_module/device/rcd,
- /obj/item/rig_module/vision/meson
- )
-
-/obj/item/rig/eva
- name = "EVA suit control module"
- suit_type = "EVA hardsuit"
- desc = "A light rig for repairs and maintenance to the outside of habitats and vessels."
- icon_state = "eva_rig"
- active_slowdown = 0
- offline_slowdown = 1
- offline_vision_restriction = 1
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/eva
-
- allowed = list(/obj/item/flashlight,/obj/item/tank,/obj/item/storage/toolbox,/obj/item/storage/briefcase/inflatable,/obj/item/t_scanner,/obj/item/rcd)
-
- req_access = list()
- req_one_access = list()
-
-/obj/item/rig/eva/equipped
-
- initial_modules = list(
- /obj/item/rig_module/device/plasmacutter,
- /obj/item/rig_module/maneuvering_jets,
- // /obj/item/rig_module/device/rcd,
- /obj/item/rig_module/vision/meson
- )
-
-//Chief Engineer's rig. This is sort of a halfway point between the old hardsuits (voidsuits) and the rig class.
-/obj/item/rig/ce
-
- name = "advanced voidsuit control module"
- suit_type = "advanced voidsuit"
- desc = "An advanced voidsuit that protects against hazardous, low pressure environments. Shines with a high polish."
- icon_state = "ce_rig"
- armor = list(melee = 40, bullet = 5, laser = 10, energy = 5, bomb = 50, bio = 100, rad = 90)
- active_slowdown = 0
- offline_slowdown = 0
- offline_vision_restriction = 0
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/ce
-
- allowed = list(/obj/item/flashlight,/obj/item/tank,/obj/item/storage/bag/ore,/obj/item/t_scanner,/obj/item/pickaxe, /obj/item/rcd)
-
-
- req_access = list()
- req_one_access = list()
-
- boot_type = null
- glove_type = null
-
-/obj/item/rig/ce/equipped
-
- req_access = list(ACCESS_CE)
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/maneuvering_jets,
- /obj/item/rig_module/device/plasmacutter,
- // /obj/item/rig_module/device/rcd,
- /obj/item/rig_module/vision/meson
- )
-
- chest_type = /obj/item/clothing/suit/space/new_rig/ce
- boot_type = null
- glove_type = null
-
-/obj/item/clothing/suit/space/new_rig/ce
- heat_protection = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
- body_parts_covered = UPPER_TORSO|LOWER_TORSO|LEGS|FEET|ARMS|HANDS
-
-/obj/item/rig/hazmat
-
- name = "AMI control module"
- suit_type = "hazmat hardsuit"
- desc = "An Anomalous Material Interaction hardsuit that protects against the strangest energies the universe can throw at it."
- icon_state = "science_rig"
- active_slowdown = 1
- offline_vision_restriction = 1
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/hazmat
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/ert
-
- allowed = list(/obj/item/flashlight,/obj/item/tank,/obj/item/pickaxe,/obj/item/healthanalyzer,/obj/item/gps,/obj/item/radio/beacon)
-
- req_access = list()
- req_one_access = list()
-
-/obj/item/rig/hazmat/equipped
-
- req_access = list(ACCESS_RD)
-
- initial_modules = list(
- /obj/item/rig_module/ai_container,
- /obj/item/rig_module/maneuvering_jets)
-
-/obj/item/rig/medical
-
- name = "rescue suit control module"
- suit_type = "rescue hardsuit"
- desc = "A durable suit designed for medical rescue in high risk areas."
- icon_state = "medical_rig"
- armor = list(melee = 10, bullet = 5, laser = 10, energy = 5, bomb = 10, bio = 100, rad = 50)
- active_slowdown = 1
- offline_vision_restriction = 1
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/medical
-
- allowed = list(/obj/item/flashlight,/obj/item/tank,/obj/item/storage/firstaid,/obj/item/healthanalyzer,/obj/item/stack/medical,/obj/item/roller )
-
- req_access = list()
- req_one_access = list()
-
-/obj/item/rig/medical/equipped
-
- initial_modules = list(
- /obj/item/rig_module/chem_dispenser/injector,
- /obj/item/rig_module/maneuvering_jets,
- /obj/item/rig_module/device/healthscanner,
- /obj/item/rig_module/vision/medhud
- )
-
-/obj/item/rig/hazard
- name = "hazard hardsuit control module"
- suit_type = "hazard hardsuit"
- desc = "A Security hardsuit designed for prolonged EVA in dangerous environments."
- icon_state = "hazard_rig"
- armor = list(melee = 30, bullet = 15, laser = 30, energy = 10, bomb = 10, bio = 100, rad = 50)
- active_slowdown = 1
- offline_slowdown = 3
- offline_vision_restriction = 1
-
- helm_type = /obj/item/clothing/head/helmet/space/new_rig/hazard
-
- allowed = list(/obj/item/gun,/obj/item/flashlight,/obj/item/tank,/obj/item/melee/baton)
-
- req_access = list()
- req_one_access = list()
-
-
-/obj/item/rig/hazard/equipped
-
- initial_modules = list(
- /obj/item/rig_module/vision/sechud,
- /obj/item/rig_module/maneuvering_jets,
- /obj/item/rig_module/grenade_launcher,
- /obj/item/rig_module/mounted/taser
- )
diff --git a/code/modules/customitems/item_defines.dm b/code/modules/customitems/item_defines.dm
index 1a5da52ffce..530b9095f75 100644
--- a/code/modules/customitems/item_defines.dm
+++ b/code/modules/customitems/item_defines.dm
@@ -349,7 +349,7 @@
to_chat(user, "You modify the appearance of [target].")
var/obj/item/clothing/mask/gas/M = target
M.name = "Prescription Gas Mask"
- M.desc = "It looks heavily modified, but otherwise functions as a gas mask. The words “Property of Yon-Dale” can be seen on the inner band."
+ M.desc = "It looks heavily modified, but otherwise functions as a gas mask. The words \"Property of Yon-Dale\" can be seen on the inner band."
M.icon = 'icons/obj/custom_items.dmi'
M.icon_state = "gas_tariq"
M.sprite_sheets = list(
diff --git a/code/modules/events/apc_short.dm b/code/modules/events/apc_short.dm
index d2fe04dcc5d..c19b6cbe8b7 100644
--- a/code/modules/events/apc_short.dm
+++ b/code/modules/events/apc_short.dm
@@ -59,7 +59,17 @@
log_and_message_admins("APC Short event shorted out [affected_apc_count] APCs.")
/proc/power_restore(announce=TRUE)
- power_restore_quick(announce)
+ if(announce)
+ GLOB.event_announcement.Announce("Power has been restored to [station_name()]. We apologize for the inconvenience.", "Power Systems Nominal", new_sound = 'sound/AI/poweron.ogg')
+
+ // recharge the APCs
+ for(var/thing in GLOB.apcs)
+ var/obj/machinery/power/apc/A = thing
+ if(!is_station_level(A.z))
+ continue
+ var/obj/item/stock_parts/cell/C = A.get_cell()
+ if(C)
+ C.give(C.maxcharge)
/proc/power_restore_quick(announce=TRUE)
if(announce)
diff --git a/code/modules/events/holidays/AprilFools.dm b/code/modules/events/holidays/AprilFools.dm
deleted file mode 100644
index 562e6b98e0d..00000000000
--- a/code/modules/events/holidays/AprilFools.dm
+++ /dev/null
@@ -1 +0,0 @@
-//placeholder for holiday stuff
diff --git a/code/modules/events/holidays/Christmas.dm b/code/modules/events/holidays/Christmas.dm
deleted file mode 100644
index e04471482a5..00000000000
--- a/code/modules/events/holidays/Christmas.dm
+++ /dev/null
@@ -1,61 +0,0 @@
-/proc/Christmas_Game_Start()
- for(var/obj/structure/flora/tree/pine/xmas in world)
- if(!is_station_level(xmas.z)) continue
- for(var/turf/simulated/floor/T in orange(1,xmas))
- for(var/i=1,i<=rand(1,5),i++)
- new /obj/item/a_gift(T)
- for(var/mob/living/simple_animal/corgi/Ian/Ian in GLOB.mob_list)
- Ian.place_on_head(new /obj/item/clothing/head/helmet/space/santahat(Ian))
-
-/proc/ChristmasEvent()
- for(var/obj/structure/flora/tree/pine/xmas in world)
- var/mob/living/simple_animal/hostile/tree/evil_tree = new /mob/living/simple_animal/hostile/tree(xmas.loc)
- evil_tree.icon_state = xmas.icon_state
- evil_tree.icon_living = evil_tree.icon_state
- evil_tree.icon_dead = evil_tree.icon_state
- evil_tree.icon_gib = evil_tree.icon_state
- qdel(xmas)
-
-/obj/item/toy/xmas_cracker
- name = "xmas cracker"
- icon = 'icons/obj/christmas.dmi'
- icon_state = "cracker"
- desc = "Directions for use: Requires two people, one to pull each end."
- var/cracked = 0
-
-/obj/item/toy/xmas_cracker/New()
- ..()
-
-/obj/item/toy/xmas_cracker/attack(mob/target, mob/user)
- if( !cracked && istype(target,/mob/living/carbon/human) && (target.stat == CONSCIOUS) && !target.get_active_hand() )
- target.visible_message("[user] and [target] pop \an [src]! *pop*", "You pull \an [src] with [target]! *pop*", "You hear a *pop*.")
- var/obj/item/paper/Joke = new /obj/item/paper(user.loc)
- Joke.name = "[pick("awful","terrible","unfunny")] joke"
- Joke.info = pick("What did one snowman say to the other?\n\n'Is it me or can you smell carrots?'",
- "Why couldn't the snowman get laid?\n\nHe was frigid!",
- "Where are santa's helpers educated?\n\nNowhere, they're ELF-taught.",
- "What happened to the man who stole advent calanders?\n\nHe got 25 days.",
- "What does Santa get when he gets stuck in a chimney?\n\nClaus-trophobia.",
- "Where do you find chili beans?\n\nThe north pole.",
- "What do you get from eating tree decorations?\n\nTinsilitis!",
- "What do snowmen wear on their heads?\n\nIce caps!",
- "Why is Christmas just like life on ss13?\n\nYou do all the work and the fat guy gets all the credit.",
- "Why doesn�t Santa have any children?\n\nBecause he only comes down the chimney.")
- new /obj/item/clothing/head/festive(target.loc)
- user.update_icons()
- cracked = 1
- icon_state = "cracker1"
- var/obj/item/toy/xmas_cracker/other_half = new /obj/item/toy/xmas_cracker(target)
- other_half.cracked = 1
- other_half.icon_state = "cracker2"
- target.put_in_active_hand(other_half)
- playsound(user, 'sound/effects/snap.ogg', 50, 1)
- return 1
- return ..()
-
-/obj/item/clothing/head/festive
- name = "festive paper hat"
- icon_state = "xmashat"
- desc = "A crappy paper hat that you are REQUIRED to wear."
- flags_inv = 0
- armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0)
diff --git a/code/modules/events/holidays/Easter.dm b/code/modules/events/holidays/Easter.dm
deleted file mode 100644
index 562e6b98e0d..00000000000
--- a/code/modules/events/holidays/Easter.dm
+++ /dev/null
@@ -1 +0,0 @@
-//placeholder for holiday stuff
diff --git a/code/modules/events/holidays/Holidays.dm b/code/modules/events/holidays/Holidays.dm
deleted file mode 100644
index 5bc49001e3a..00000000000
--- a/code/modules/events/holidays/Holidays.dm
+++ /dev/null
@@ -1,183 +0,0 @@
-//Uncommenting ALLOW_HOLIDAYS in config.txt will enable Holidays
-GLOBAL_VAR_INIT(Holiday) // I didnt update the rest of this code because this file hasnt been ticked in years, and holiday code got overhauled
- // If it really needs fixing, yell at me, -aa
-
-//Just thinking ahead! Here's the foundations to a more robust Holiday event system.
-//It's easy as hell to add stuff. Just set Holiday to something using the switch(or something else)
-//then use if(Holiday == "MyHoliday") to make stuff happen on that specific day only
-//Please, Don't spam stuff up with easter eggs, I'd rather somebody just delete this than people cause
-//the game to lag even more in the name of one-day content.
-
-//////////////////////////////////////////////////////////////////////////////////////////////////////////
-//ALSO, MOST IMPORTANTLY: Don't add stupid stuff! Discuss bonus content with Project-Heads first please!//
-//////////////////////////////////////////////////////////////////////////////////////////////////////////
-// ~Carn
-
-/hook/startup/proc/updateHoliday()
- Get_Holiday()
- return 1
-
-//sets up the Holiday global variable. Shouldbe called on game configuration or something.
-/proc/Get_Holiday()
- if(!Holiday) return // Holiday stuff was not enabled in the config!
-
- Holiday = null // reset our switch now so we can recycle it as our Holiday name
-
- var/YY = text2num(time2text(world.timeofday, "YY")) // get the current year
- var/MM = text2num(time2text(world.timeofday, "MM")) // get the current month
- var/DD = text2num(time2text(world.timeofday, "DD")) // get the current day
-
- //Main switch. If any of these are too dumb/inappropriate, or you have better ones, feel free to change whatever
- switch(MM)
- if(1) //Jan
- switch(DD)
- if(1) Holiday = "New Year's Day"
-
- if(2) //Feb
- switch(DD)
- if(2) Holiday = "Groundhog Day"
- if(14) Holiday = "Valentine's Day"
- if(17) Holiday = "Random Acts of Kindness Day"
-
- if(3) //Mar
- switch(DD)
- if(14) Holiday = "Pi Day"
- if(17) Holiday = "St. Patrick's Day"
- if(27)
- if(YY == 16)
- Holiday = "Easter"
- if(31)
- if(YY == 13)
- Holiday = "Easter"
-
- if(4) //Apr
- switch(DD)
- if(1)
- Holiday = "April Fool's Day"
- if(YY == 18 && prob(50)) Holiday = "Easter"
- if(5)
- if(YY == 15) Holiday = "Easter"
- if(16)
- if(YY == 17) Holiday = "Easter"
- if(20)
- Holiday = "Four-Twenty"
- if(YY == 14 && prob(50)) Holiday = "Easter"
- if(22) Holiday = "Earth Day"
-
- if(5) //May
- switch(DD)
- if(1) Holiday = "Labour Day"
- if(4) Holiday = "FireFighter's Day"
- if(12) Holiday = "Owl and Pussycat Day" //what a dumb day of observence...but we -do- have costumes already :3
-
- if(6) //Jun
-
- if(7) //Jul
- switch(DD)
- if(1) Holiday = "Doctor's Day"
- if(2) Holiday = "UFO Day"
- if(8) Holiday = "Writer's Day"
- if(30) Holiday = "Friendship Day"
-
- if(8) //Aug
- switch(DD)
- if(5) Holiday = "Beer Day"
-
- if(9) //Sep
- switch(DD)
- if(19) Holiday = "Talk-Like-a-Pirate Day"
- if(28) Holiday = "Stupid-Questions Day"
-
- if(10) //Oct
- switch(DD)
- if(4) Holiday = "Animal's Day"
- if(7) Holiday = "Smiling Day"
- if(16) Holiday = "Boss' Day"
- if(31) Holiday = "Halloween"
-
- if(11) //Nov
- switch(DD)
- if(1) Holiday = "Vegan Day"
- if(13) Holiday = "Kindness Day"
- if(19) Holiday = "Flowers Day"
- if(21) Holiday = "Saying-'Hello' Day"
-
- if(12) //Dec
- switch(DD)
- if(10) Holiday = "Human-Rights Day"
- if(14) Holiday = "Monkey Day"
- if(21) if(YY==12) Holiday = "End of the World"
- if(22) Holiday = "Orgasming Day" //lol. These all actually exist
- if(24) Holiday = "Christmas Eve"
- if(25) Holiday = "Christmas"
- if(26) Holiday = "Boxing Day"
- if(31) Holiday = "New Year's Eve"
-
- if(!Holiday)
- //Friday the 13th
- if(DD == 13)
- if(time2text(world.timeofday, "DDD") == "Fri")
- Holiday = "Friday the 13th"
-
-//Allows GA and GM to set the Holiday variable
-/client/proc/Set_Holiday(T as text|null)
- set name = ".Set Holiday"
- set category = "Event"
- set desc = "Force-set the Holiday variable to make the game think it's a certain day."
- if(!check_rights(R_SERVER)) return
-
- Holiday = T
- //get a new station name
- station_name = null
- station_name()
- //update our hub status
- world.update_status()
- Holiday_Game_Start()
-
- message_admins("ADMIN: Event: [key_name_admin(src)] force-set Holiday to \"[Holiday]\"")
- log_admin("[key_name(src)] force-set Holiday to \"[Holiday]\"")
-
-
-//Run at the start of a round
-/proc/Holiday_Game_Start()
- if(Holiday)
- to_chat(world, "and...")
- to_chat(world, "Happy [Holiday] Everybody!")
- switch(Holiday) //special holidays
- if("Easter")
- //do easter stuff
- if("Christmas Eve","Christmas")
- Christmas_Game_Start()
-
- return
-
-//Nested in the random events loop. Will be triggered every 2 minutes
-/proc/Holiday_Random_Event()
- switch(Holiday) //special holidays
-
- if("",null) //no Holiday today! Back to work!
- return
-
- if("Easter") //I'll make this into some helper procs at some point
-/* var/list/turf/simulated/floor/Floorlist = list()
- for(var/turf/simulated/floor/T)
- if(T.contents)
- Floorlist += T
- var/turf/simulated/floor/F = Floorlist[rand(1,Floorlist.len)]
- Floorlist = null
- var/obj/structure/closet/C = locate(/obj/structure/closet) in F
- var/obj/item/reagent_containers/food/snacks/chocolateegg/wrapped/Egg
- if( C ) Egg = new(C)
- else Egg = new(F)
-*/
-/* var/list/obj/containers = list()
- for(var/obj/item/storage/S in world)
- if(!is_station_level(S.z)) continue
- containers += S
-
- message_admins("DEBUG: Event: Egg spawned at [Egg.loc] ([Egg.x],[Egg.y],[Egg.z])")*/
- if("End of the World")
- if(prob(eventchance)) GameOver()
-
- if("Christmas","Christmas Eve")
- if(prob(eventchance)) ChristmasEvent()
diff --git a/code/modules/events/mass_hallucination.dm b/code/modules/events/mass_hallucination.dm
index 196642ce39c..b8f45023a27 100644
--- a/code/modules/events/mass_hallucination.dm
+++ b/code/modules/events/mass_hallucination.dm
@@ -2,7 +2,13 @@
announceWhen = rand(0, 20)
/datum/event/mass_hallucination/start()
- for(var/mob/living/carbon/human/H in GLOB.alive_mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
+ if(H.stat == DEAD)
+ continue
+ var/turf/T = get_turf(H)
+ if(!is_station_level(T.z))
+ continue
var/armor = H.getarmor(type = "rad")
if((RADIMMUNE in H.dna.species.species_traits) || armor >= 75) // Leave radiation-immune species/rad armored players completely unaffected
continue
diff --git a/code/modules/events/sentience.dm b/code/modules/events/sentience.dm
index 918746f4595..ab8a405785f 100644
--- a/code/modules/events/sentience.dm
+++ b/code/modules/events/sentience.dm
@@ -10,7 +10,7 @@
for(var/mob/living/simple_animal/L in GLOB.alive_mob_list)
var/turf/T = get_turf(L)
- if (T.z != 1)
+ if (!is_station_level(T.z))
continue
if(!(L in GLOB.player_list) && !L.mind && (L.sentience_type == sentience_type))
potential += L
diff --git a/code/modules/events/slaughterevent.dm b/code/modules/events/slaughterevent.dm
index ac265adb420..91918894cfd 100644
--- a/code/modules/events/slaughterevent.dm
+++ b/code/modules/events/slaughterevent.dm
@@ -33,7 +33,7 @@
spawn_locs += get_turf(player_mind.current)
if(!spawn_locs) //If we can't find THAT, then just retry
return kill()
- var /obj/effect/dummy/slaughter/holder = new /obj/effect/dummy/slaughter(pick(spawn_locs))
+ var/obj/effect/dummy/slaughter/holder = new /obj/effect/dummy/slaughter(pick(spawn_locs))
var/mob/living/simple_animal/slaughter/S = new /mob/living/simple_animal/slaughter/(holder)
S.holder = holder
player_mind.transfer_to(S)
diff --git a/code/modules/events/spider_terror.dm b/code/modules/events/spider_terror.dm
index 75b86d20cb0..79acc49fe73 100644
--- a/code/modules/events/spider_terror.dm
+++ b/code/modules/events/spider_terror.dm
@@ -1,3 +1,4 @@
+#define TS_HIGHPOP_TRIGGER 80
/datum/event/spider_terror
announceWhen = 240
@@ -22,23 +23,32 @@
if(temp_vent.parent.other_atmosmch.len > 50)
vents += temp_vent
var/spider_type
- var/infestation_type = pick(1, 2, 3, 4, 5)
+ var/infestation_type
+ if((length(GLOB.clients)) < TS_HIGHPOP_TRIGGER)
+ infestation_type = pick(1, 2, 3, 4)
+ else
+ infestation_type = pick(2, 3, 4, 5)
switch(infestation_type)
if(1)
+ // Weakest, only used during lowpop.
spider_type = /mob/living/simple_animal/hostile/poison/terror_spider/green
spawncount = 5
if(2)
- spider_type = /mob/living/simple_animal/hostile/poison/terror_spider/white
- spawncount = 2
- if(3)
+ // Fairly weak. Dangerous in single combat but has little staying power. Always gets whittled down.
spider_type = /mob/living/simple_animal/hostile/poison/terror_spider/prince
spawncount = 1
+ if(3)
+ // Variable. Depends how many they infect.
+ spider_type = /mob/living/simple_animal/hostile/poison/terror_spider/white
+ spawncount = 2
if(4)
- spider_type = /mob/living/simple_animal/hostile/poison/terror_spider/queen
- spawncount = 1
- if(5)
+ // Pretty strong.
spider_type = /mob/living/simple_animal/hostile/poison/terror_spider/princess
spawncount = 2
+ if(5)
+ // Strongest, only used during highpop.
+ spider_type = /mob/living/simple_animal/hostile/poison/terror_spider/queen
+ spawncount = 1
while(spawncount >= 1 && vents.len)
var/obj/machinery/atmospherics/unary/vent_pump/vent = pick(vents)
@@ -60,3 +70,6 @@
new spider_type(vent.loc)
spawncount--
+
+#undef TS_HIGHPOP_TRIGGER
+
diff --git a/code/modules/flufftext/Dreaming.dm b/code/modules/flufftext/Dreaming.dm
index d4c06fdc3a3..a24b73ae56c 100644
--- a/code/modules/flufftext/Dreaming.dm
+++ b/code/modules/flufftext/Dreaming.dm
@@ -19,7 +19,7 @@
var/list/newlist = dreamlist.Copy()
for(var/i in 1 to newlist.len)
newlist[i] = replacetext(newlist[i], "\[DREAMER\]", "[user.name]")
- return dreamlist
+ return newlist
//NIGHTMARES
diff --git a/code/modules/flufftext/Hallucination.dm b/code/modules/flufftext/Hallucination.dm
index 51ac13d4e13..21b99acb910 100644
--- a/code/modules/flufftext/Hallucination.dm
+++ b/code/modules/flufftext/Hallucination.dm
@@ -149,10 +149,12 @@ Gunshots/explosions/opening doors/less rare audio (done)
/obj/effect/hallucination/fake_flood/process()
if(!target)
qdel(src)
+ return
if(next_expand <= world.time)
radius++
if(radius > FAKE_FLOOD_MAX_RADIUS)
qdel(src)
+ return
Expand()
if((get_turf(target) in flood_turfs) && !target.internal)
target.hallucinate("fake_alert", "too_much_tox")
@@ -460,8 +462,9 @@ Gunshots/explosions/opening doors/less rare audio (done)
target = T
var/image/A = null
var/kind = force_kind ? force_kind : pick("clown", "corgi", "carp", "skeleton", "demon","zombie")
- for(var/mob/living/carbon/human/H in GLOB.alive_mob_list)
- if(H == target)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
+ if(H.stat == DEAD || H == target)
continue
if(skip_nearby && (H in view(target)))
continue
@@ -539,7 +542,8 @@ Gunshots/explosions/opening doors/less rare audio (done)
var/mob/living/carbon/human/clone = null
var/clone_weapon = null
- for(var/mob/living/carbon/human/H in GLOB.alive_mob_list)
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
if(H.stat || H.lying)
continue
clone = H
@@ -751,8 +755,10 @@ GLOBAL_LIST_INIT(non_fakeattack_weapons, list(/obj/item/gun/projectile, /obj/ite
target.client.images.Remove(speech_overlay)
else // Radio talk
var/list/humans = list()
- for(var/mob/living/carbon/human/H in GLOB.alive_mob_list)
- humans += H
+ for(var/thing in GLOB.human_list)
+ var/mob/living/carbon/human/H = thing
+ if(H.stat != DEAD)
+ humans += H
person = pick(humans)
target.hear_radio(message_to_multilingual(pick(radio_messages), pick(person.languages)), speaker = person, part_a = "\[[get_frequency_name(PUB_FREQ)]\] ", part_b = " ")
qdel(src)
diff --git a/code/modules/food_and_drinks/drinks/drinks/bottle.dm b/code/modules/food_and_drinks/drinks/drinks/bottle.dm
index 4515a62d86b..f77d4b60ab4 100644
--- a/code/modules/food_and_drinks/drinks/drinks/bottle.dm
+++ b/code/modules/food_and_drinks/drinks/drinks/bottle.dm
@@ -124,6 +124,13 @@
reagents.reaction(M, REAGENT_TOUCH)
reagents.clear_reagents()
+/obj/item/reagent_containers/food/drinks/bottle/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ if(!reagents.total_volume)
+ C.stored_comms["glass"] += 3
+ qdel(src)
+ return TRUE
+ return ..()
+
//Keeping this here for now, I'll ask if I should keep it here.
/obj/item/broken_bottle
name = "Broken Bottle"
@@ -141,6 +148,11 @@
var/icon/broken_outline = icon('icons/obj/drinks.dmi', "broken")
sharp = 1
+/obj/item/broken_bottle/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ C.stored_comms["glass"] += 3
+ qdel(src)
+ return TRUE
+
/obj/item/reagent_containers/food/drinks/bottle/gin
name = "Griffeater Gin"
desc = "A bottle of high quality gin, produced in the New London Space Station."
diff --git a/code/modules/food_and_drinks/food.dm b/code/modules/food_and_drinks/food.dm
index 27f0919a3ce..2180f9a0f63 100644
--- a/code/modules/food_and_drinks/food.dm
+++ b/code/modules/food_and_drinks/food.dm
@@ -33,6 +33,9 @@
deltimer(ant_timer)
return ..()
+/obj/item/reagent_containers/food/set_APTFT()
+ set hidden = TRUE
+
/obj/item/reagent_containers/food/proc/check_for_ants()
if(!antable)
return
diff --git a/code/modules/hydroponics/beekeeping/honeycomb.dm b/code/modules/hydroponics/beekeeping/honeycomb.dm
index 23bc55dfea2..1d086bae0f0 100644
--- a/code/modules/hydroponics/beekeeping/honeycomb.dm
+++ b/code/modules/hydroponics/beekeeping/honeycomb.dm
@@ -17,6 +17,8 @@
pixel_y = rand(8,-8)
update_icon()
+/obj/item/reagent_containers/honeycomb/set_APTFT()
+ set hidden = TRUE
/obj/item/reagent_containers/honeycomb/update_icon()
overlays.Cut()
diff --git a/code/modules/hydroponics/grown.dm b/code/modules/hydroponics/grown.dm
index a3b522187e2..bad8813ea01 100644
--- a/code/modules/hydroponics/grown.dm
+++ b/code/modules/hydroponics/grown.dm
@@ -117,6 +117,7 @@
/obj/item/reagent_containers/food/snacks/grown/throw_impact(atom/hit_atom)
if(!..()) //was it caught by a mob?
if(seed)
+ log_action(thrownby, hit_atom, "Thrown [src] at")
for(var/datum/plant_gene/trait/T in seed.genes)
T.on_throw_impact(src, hit_atom)
if(seed.get_gene(/datum/plant_gene/trait/squash))
@@ -147,11 +148,11 @@
qdel(src)
-/obj/item/reagent_containers/food/snacks/grown/On_Consume()
- if(iscarbon(usr))
+/obj/item/reagent_containers/food/snacks/grown/On_Consume(mob/M, mob/user)
+ if(iscarbon(M))
if(seed)
for(var/datum/plant_gene/trait/T in seed.genes)
- T.on_consume(src, usr)
+ T.on_consume(src, M)
..()
/obj/item/reagent_containers/food/snacks/grown/after_slip(mob/living/carbon/human/H)
@@ -168,6 +169,11 @@
return
return ..()
+/obj/item/reagent_containers/food/snacks/grown/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ C.stored_comms["wood"] += 4
+ qdel(src)
+ return TRUE
+
// For item-containing growns such as eggy or gatfruit
/obj/item/reagent_containers/food/snacks/grown/shell/attack_self(mob/user)
user.unEquip(src)
@@ -185,3 +191,16 @@
else
return ..()
+/obj/item/reagent_containers/food/snacks/grown/proc/log_action(mob/user, atom/target, what_done)
+ var/reagent_str = reagents.log_list()
+ var/genes_str = "No genes"
+ if(seed && length(seed.genes))
+ var/list/plant_gene_names = list()
+ for(var/thing in seed.genes)
+ var/datum/plant_gene/G = thing
+ if(G.dangerous)
+ plant_gene_names += G.name
+ genes_str = english_list(plant_gene_names)
+
+ add_attack_logs(user, target, "[what_done] ([reagent_str] | [genes_str])")
+
diff --git a/code/modules/hydroponics/plant_genes.dm b/code/modules/hydroponics/plant_genes.dm
index a4c6fe7280d..c2f4914351c 100644
--- a/code/modules/hydroponics/plant_genes.dm
+++ b/code/modules/hydroponics/plant_genes.dm
@@ -1,5 +1,7 @@
/datum/plant_gene
var/name
+ /// Used to determine if the trait should be logged when the holder is used
+ var/dangerous = FALSE
/datum/plant_gene/proc/get_name() // Used for manipulator display and gene disk name.
return name
@@ -194,6 +196,7 @@
name = "Liquid Contents"
examine_line = "It has a lot of liquid contents inside."
origin_tech = list("biotech" = 5)
+ dangerous = TRUE
/datum/plant_gene/trait/slip
// Makes plant slippery, unless it has a grown-type trash. Then the trash gets slippery.
@@ -201,6 +204,7 @@
name = "Slippery Skin"
rate = 0.1
examine_line = "It has a very slippery skin."
+ dangerous = TRUE
/datum/plant_gene/trait/slip/on_new(obj/item/reagent_containers/food/snacks/grown/G, newloc)
. = ..()
@@ -224,6 +228,7 @@
name = "Electrical Activity"
rate = 0.2
origin_tech = list("powerstorage" = 5)
+ dangerous = TRUE
/datum/plant_gene/trait/cell_charge/on_slip(obj/item/reagent_containers/food/snacks/grown/G, mob/living/carbon/C)
var/power = G.seed.potency*rate
@@ -298,6 +303,7 @@
name = "Bluespace Activity"
rate = 0.1
origin_tech = list("bluespace" = 5)
+ dangerous = TRUE
/datum/plant_gene/trait/teleport/on_squash(obj/item/reagent_containers/food/snacks/grown/G, atom/target)
if(isliving(target))
@@ -385,6 +391,7 @@
/datum/plant_gene/trait/stinging
name = "Hypodermic Prickles"
+ dangerous = TRUE
/datum/plant_gene/trait/stinging/on_throw_impact(obj/item/reagent_containers/food/snacks/grown/G, atom/target)
if(isliving(target) && G.reagents && G.reagents.total_volume)
@@ -398,6 +405,7 @@
/datum/plant_gene/trait/smoke
name = "gaseous decomposition"
+ dangerous = TRUE
/datum/plant_gene/trait/smoke/on_squash(obj/item/reagent_containers/food/snacks/grown/G, atom/target)
var/datum/effect_system/smoke_spread/chem/S = new
diff --git a/code/modules/library/computers/checkout.dm b/code/modules/library/computers/checkout.dm
index f9aae71b2a5..934234f645e 100644
--- a/code/modules/library/computers/checkout.dm
+++ b/code/modules/library/computers/checkout.dm
@@ -463,4 +463,5 @@
B.author = newbook.author
B.dat = newbook.content
B.icon_state = "book[rand(1,16)]"
+ B.has_drm = TRUE
visible_message("[src]'s printer hums as it produces a completely bound book. How did it do that?")
diff --git a/code/modules/library/lib_items.dm b/code/modules/library/lib_items.dm
index a7dd148b51a..e74625c8715 100644
--- a/code/modules/library/lib_items.dm
+++ b/code/modules/library/lib_items.dm
@@ -151,6 +151,8 @@
var/carved = 0 // Has the book been hollowed out for use as a secret storage item?
var/forbidden = 0 // Prevent ordering of this book. (0=no, 1=yes, 2=emag only)
var/obj/item/store // What's in the book?
+ /// Book DRM. If this var is TRUE, it cannot be scanned and re-uploaded
+ var/has_drm = FALSE
/obj/item/book/attack_self(var/mob/user as mob)
if(carved)
diff --git a/code/modules/library/lib_machines.dm b/code/modules/library/lib_machines.dm
index 65fadaa9b45..0c23a0c5800 100644
--- a/code/modules/library/lib_machines.dm
+++ b/code/modules/library/lib_machines.dm
@@ -3,11 +3,6 @@
GLOBAL_DATUM_INIT(library_catalog, /datum/library_catalog, new())
GLOBAL_LIST_INIT(library_section_names, list("Any", "Fiction", "Non-Fiction", "Adult", "Reference", "Religion"))
-
-/hook/startup/proc/load_manuals()
- GLOB.library_catalog.initialize()
- return 1
-
/*
* Borrowbook datum
*/
@@ -65,7 +60,7 @@ GLOBAL_LIST_INIT(library_section_names, list("Any", "Fiction", "Non-Fiction", "A
/datum/library_catalog
var/list/cached_books = list()
-/datum/library_catalog/proc/initialize()
+/datum/library_catalog/New()
var/newid=1
for(var/typepath in subtypesof(/obj/item/book/manual))
var/obj/item/book/B = new typepath(null)
@@ -155,6 +150,11 @@ GLOBAL_LIST_INIT(library_section_names, list("Any", "Fiction", "Non-Fiction", "A
power_change()
return
if(istype(I, /obj/item/book))
+ // NT with those pesky DRM schemes
+ var/obj/item/book/B = I
+ if(B.has_drm)
+ atom_say("Copyrighted material detected. Scanner is unable to copy book to memory.")
+ return FALSE
user.drop_item()
I.forceMove(src)
return 1
diff --git a/code/modules/mining/abandonedcrates.dm b/code/modules/mining/abandonedcrates.dm
index 9b74c922a6b..044b78a04bc 100644
--- a/code/modules/mining/abandonedcrates.dm
+++ b/code/modules/mining/abandonedcrates.dm
@@ -82,7 +82,7 @@
new /obj/item/clothing/head/corgi(src)
if(67 to 68)
for(var/i in 1 to rand(4, 7))
- var /newitem = pick(subtypesof(/obj/item/stock_parts))
+ var/newitem = pick(subtypesof(/obj/item/stock_parts))
new newitem(src)
if(69 to 70)
new /obj/item/stack/ore/bluespace_crystal(src, 5)
diff --git a/code/modules/mining/lavaland/loot/ashdragon_loot.dm b/code/modules/mining/lavaland/loot/ashdragon_loot.dm
index a0ea3eb7639..21bc247b0df 100644
--- a/code/modules/mining/lavaland/loot/ashdragon_loot.dm
+++ b/code/modules/mining/lavaland/loot/ashdragon_loot.dm
@@ -120,18 +120,13 @@
return
var/mob/living/carbon/human/H = user
- var/random = rand(1,3)
+ var/random = rand(1,2)
switch(random)
if(1)
to_chat(user, "Your flesh begins to melt! Miraculously, you seem fine otherwise.")
H.set_species(/datum/species/skeleton)
if(2)
- to_chat(user, "Power courses through you! You can now shift your form at will.")
- if(user.mind)
- var/obj/effect/proc_holder/spell/targeted/shapeshift/dragon/D = new
- user.mind.AddSpell(D)
- if(3)
to_chat(user, "You feel like you could walk straight through lava now.")
H.weather_immunities |= "lava"
diff --git a/code/modules/mining/lavaland/loot/bubblegum_loot.dm b/code/modules/mining/lavaland/loot/bubblegum_loot.dm
index fa7791edb9e..4ee2c76a419 100644
--- a/code/modules/mining/lavaland/loot/bubblegum_loot.dm
+++ b/code/modules/mining/lavaland/loot/bubblegum_loot.dm
@@ -82,7 +82,7 @@
B.mineEffect(L)
for(var/mob/living/carbon/human/H in GLOB.player_list)
- if(H == L)
+ if(H.stat == DEAD || H == L)
continue
to_chat(H, "You have an overwhelming desire to kill [L]. [L.p_they(TRUE)] [L.p_have()] been marked red! Go kill [L.p_them()]!")
H.put_in_hands(new /obj/item/kitchen/knife/butcher(H))
diff --git a/code/modules/mining/lavaland/loot/tendril_loot.dm b/code/modules/mining/lavaland/loot/tendril_loot.dm
index f54bc974f7e..0af08e40c74 100644
--- a/code/modules/mining/lavaland/loot/tendril_loot.dm
+++ b/code/modules/mining/lavaland/loot/tendril_loot.dm
@@ -383,7 +383,10 @@
var/mob/living/L = target
if(!L.anchored)
L.visible_message("[L] is snagged by [firer]'s hook!")
+ var/old_density = L.density
+ L.density = FALSE // Ensures the hook does not hit the target multiple times
L.forceMove(get_turf(firer))
+ L.density = old_density
/obj/item/projectile/hook/Destroy()
QDEL_NULL(chain)
diff --git a/code/modules/mining/ores_coins.dm b/code/modules/mining/ores_coins.dm
index 8737fdf21b3..c01d04beba8 100644
--- a/code/modules/mining/ores_coins.dm
+++ b/code/modules/mining/ores_coins.dm
@@ -273,7 +273,7 @@ GLOBAL_LIST_INIT(sand_recipes, list(\
icon_state = "Gibtonite active"
var/turf/bombturf = get_turf(src)
var/notify_admins = 0
- if(z != 5)//Only annoy the admins ingame if we're triggered off the mining zlevel
+ if(!is_mining_level(z))//Only annoy the admins ingame if we're triggered off the mining zlevel
notify_admins = 1
if(notify_admins)
diff --git a/code/modules/mob/living/carbon/brain/MMI.dm b/code/modules/mob/living/carbon/brain/MMI.dm
index 16014e7c353..a17d7b8ebbd 100644
--- a/code/modules/mob/living/carbon/brain/MMI.dm
+++ b/code/modules/mob/living/carbon/brain/MMI.dm
@@ -226,13 +226,6 @@
brainmob.emp_damage += rand(0,10)
..()
-/obj/item/mmi/relaymove(var/mob/user, var/direction)
- if(user.stat || user.stunned)
- return
- var/obj/item/rig/rig = src.get_rig()
- if(rig)
- rig.forced_move(direction, user)
-
/obj/item/mmi/Destroy()
if(isrobot(loc))
var/mob/living/silicon/robot/borg = loc
diff --git a/code/modules/mob/living/carbon/human/body_accessories.dm b/code/modules/mob/living/carbon/human/body_accessories.dm
index 043a704ab0c..1583bc62c70 100644
--- a/code/modules/mob/living/carbon/human/body_accessories.dm
+++ b/code/modules/mob/living/carbon/human/body_accessories.dm
@@ -1,17 +1,5 @@
GLOBAL_LIST_INIT(body_accessory_by_name, list("None" = null))
-
-/hook/startup/proc/initalize_body_accessories()
-
- __init_body_accessory(/datum/body_accessory/body)
- __init_body_accessory(/datum/body_accessory/tail)
-
- if(GLOB.body_accessory_by_name.len)
- if(initialize_body_accessory_by_species())
- return TRUE
-
- return FALSE //fail if no bodies are found
-
GLOBAL_LIST_INIT(body_accessory_by_species, list("None" = null))
/proc/initialize_body_accessory_by_species()
diff --git a/code/modules/mob/living/carbon/human/death.dm b/code/modules/mob/living/carbon/human/death.dm
index d213ee7206f..4a0b9ea55b1 100644
--- a/code/modules/mob/living/carbon/human/death.dm
+++ b/code/modules/mob/living/carbon/human/death.dm
@@ -109,9 +109,6 @@
// log_world("k")
sql_report_death(src)
- if(wearing_rig)
- wearing_rig.notify_ai("Warning: user death event. Mobility control passed to integrated intelligence system.")
-
/mob/living/carbon/human/update_revive()
. = ..()
if(. && healthdoll)
diff --git a/code/modules/mob/living/carbon/human/emote.dm b/code/modules/mob/living/carbon/human/emote.dm
index 10c2ac8f119..b69c13987b9 100644
--- a/code/modules/mob/living/carbon/human/emote.dm
+++ b/code/modules/mob/living/carbon/human/emote.dm
@@ -308,14 +308,14 @@
m_type = 1
if("bow", "bows")
- if(!buckled)
+ if(!restrained())
var/M = handle_emote_param(param)
message = "[src] bows[M ? " to [M]" : ""]."
m_type = 1
if("salute", "salutes")
- if(!buckled)
+ if(!restrained())
var/M = handle_emote_param(param)
message = "[src] salutes[M ? " to [M]" : ""]."
diff --git a/code/modules/mob/living/carbon/human/examine.dm b/code/modules/mob/living/carbon/human/examine.dm
index 31825ea3765..60891563ad2 100644
--- a/code/modules/mob/living/carbon/human/examine.dm
+++ b/code/modules/mob/living/carbon/human/examine.dm
@@ -341,7 +341,7 @@
if(decaylevel == 3)
msg += "[p_they(TRUE)] [p_are()] rotting and blackened, the skin sloughing off. The smell is indescribably foul.\n"
if(decaylevel == 4)
- msg += "[p_they(TRUE)] [p_are()] mostly dessicated now, with only bones remaining of what used to be a person.\n"
+ msg += "[p_they(TRUE)] [p_are()] mostly desiccated now, with only bones remaining of what used to be a person.\n"
if(hasHUD(user,"security"))
var/perpname = get_visible_name(TRUE)
diff --git a/code/modules/mob/living/carbon/human/human.dm b/code/modules/mob/living/carbon/human/human.dm
index 16f1738d2f6..e07930f1241 100644
--- a/code/modules/mob/living/carbon/human/human.dm
+++ b/code/modules/mob/living/carbon/human/human.dm
@@ -5,7 +5,6 @@
icon = 'icons/mob/human.dmi'
icon_state = "body_m_s"
deathgasp_on_death = TRUE
- var/obj/item/rig/wearing_rig // This is very not good, but it's much much better than calling get_rig() every update_canmove() call.
/mob/living/carbon/human/New(loc)
icon = null // This is now handled by overlays -- we just keep an icon for the sake of the map editor.
@@ -182,13 +181,6 @@
stat("Tank Pressure", internal.air_contents.return_pressure())
stat("Distribution Pressure", internal.distribute_pressure)
- if(istype(back, /obj/item/rig))
- var/obj/item/rig/suit = back
- var/cell_status = "ERROR"
- if(suit.cell)
- cell_status = "[suit.cell.charge]/[suit.cell.maxcharge]"
- stat(null, "Suit charge: [cell_status]")
-
// I REALLY need to split up status panel things into datums
var/mob/living/simple_animal/borer/B = has_brain_worms()
if(B && B.controlling)
@@ -963,16 +955,6 @@
var/obj/item/clothing/mask/MT = src.wear_mask
tinted += MT.tint
- //god help me
- if(istype(back, /obj/item/rig))
- var/obj/item/rig/O = back
- if(O.helmet && O.helmet == head && (O.helmet.body_parts_covered & HEAD))
- if((O.offline && O.offline_vision_restriction == 1) || (!O.offline && O.vision_restriction == 1))
- tinted = 2
- if((O.offline && O.offline_vision_restriction == 2) || (!O.offline && O.vision_restriction == 2))
- tinted = 3
- //im so sorry
-
return tinted
diff --git a/code/modules/mob/living/carbon/human/human_damage.dm b/code/modules/mob/living/carbon/human/human_damage.dm
index f9058065fb0..621d8330761 100644
--- a/code/modules/mob/living/carbon/human/human_damage.dm
+++ b/code/modules/mob/living/carbon/human/human_damage.dm
@@ -129,13 +129,6 @@
O.heal_damage(0, -amount, internal = 0, robo_repair = O.is_robotic(), updating_health = updating_health)
return STATUS_UPDATE_HEALTH
-
-/mob/living/carbon/human/Paralyse(amount)
- // Notify our AI if they can now control the suit.
- if(wearing_rig && !stat && paralysis < amount) //We are passing out right this second.
- wearing_rig.notify_ai("Warning: user consciousness failure. Mobility control passed to integrated intelligence system.")
- return ..()
-
/mob/living/carbon/human/adjustCloneLoss(amount)
if(dna.species && amount > 0)
amount = amount * dna.species.clone_mod
@@ -342,7 +335,5 @@ This function restores all organs.
..(damage, damagetype, def_zone, blocked)
return 1
- //Handle BRUTE and BURN damage
- handle_suit_punctures(damagetype, damage)
//Handle species apply_damage procs
return dna.species.apply_damage(damage, damagetype, def_zone, blocked, src, sharp, used_weapon)
diff --git a/code/modules/mob/living/carbon/human/human_defense.dm b/code/modules/mob/living/carbon/human/human_defense.dm
index 21a3e8bf274..6141ad02f9f 100644
--- a/code/modules/mob/living/carbon/human/human_defense.dm
+++ b/code/modules/mob/living/carbon/human/human_defense.dm
@@ -531,17 +531,6 @@ emp_act
w_uniform.add_mob_blood(source)
update_inv_w_uniform()
-/mob/living/carbon/human/proc/handle_suit_punctures(var/damtype, var/damage)
-
- if(!wear_suit) return
- if(!istype(wear_suit,/obj/item/clothing/suit/space)) return
- if(damtype != BURN && damtype != BRUTE) return
-
- var/obj/item/clothing/suit/space/SS = wear_suit
- var/penetrated_dam = max(0,(damage - max(0,(SS.breach_threshold - SS.damage))))
-
- if(penetrated_dam) SS.create_breaches(damtype, penetrated_dam)
-
/mob/living/carbon/human/attack_hulk(mob/living/carbon/human/user, does_attack_animation = FALSE)
if(user.a_intent == INTENT_HARM)
if(HAS_TRAIT(user, TRAIT_PACIFISM))
diff --git a/code/modules/mob/living/carbon/human/human_movement.dm b/code/modules/mob/living/carbon/human/human_movement.dm
index 5e1b5163a24..7cb33bce249 100644
--- a/code/modules/mob/living/carbon/human/human_movement.dm
+++ b/code/modules/mob/living/carbon/human/human_movement.dm
@@ -16,12 +16,6 @@
else if(istype(wear_suit, /obj/item/clothing/suit/space/hardsuit))
var/obj/item/clothing/suit/space/hardsuit/C = wear_suit
thrust = C.jetpack
- else if(istype(back,/obj/item/rig))
- var/obj/item/rig/rig = back
- for(var/obj/item/rig_module/maneuvering_jets/module in rig.installed_modules)
- thrust = module.jets
- break
-
if(thrust)
if((movement_dir || thrust.stabilizers) && thrust.allow_thrust(0.01, src))
return 1
diff --git a/code/modules/mob/living/carbon/human/life.dm b/code/modules/mob/living/carbon/human/life.dm
index 90653a6750b..15dfe74880e 100644
--- a/code/modules/mob/living/carbon/human/life.dm
+++ b/code/modules/mob/living/carbon/human/life.dm
@@ -302,14 +302,6 @@
if(!(head && head.flags & AIRTIGHT)) //if NOT (head AND head.flags CONTAIN AIRTIGHT)
null_internals = 1 //not wearing a mask or suitable helmet
- if(istype(back, /obj/item/rig)) //wearing a rigsuit
- var/obj/item/rig/rig = back //needs to be typecasted because this doesn't use get_rig() for some reason
- if(rig.offline && (rig.air_supply && internal == rig.air_supply)) //if rig IS offline AND (rig HAS air_supply AND internal IS air_supply)
- null_internals = 1 //offline suits do not breath
-
- else if(rig.air_supply && internal == rig.air_supply) //if rig HAS air_supply AND internal IS rig air_supply
- skip_contents_check = 1 //skip contents.Find() check, the oxygen is valid even being outside of the mob
-
if(!contents.Find(internal) && (!skip_contents_check)) //if internal NOT IN contents AND skip_contents_check IS false
null_internals = 1 //not a rigsuit and your oxygen is gone
diff --git a/code/modules/mob/living/carbon/human/say.dm b/code/modules/mob/living/carbon/human/say.dm
index 65b4585ff6b..957b0828725 100644
--- a/code/modules/mob/living/carbon/human/say.dm
+++ b/code/modules/mob/living/carbon/human/say.dm
@@ -62,11 +62,6 @@
return ..()
/mob/living/carbon/human/proc/HasVoiceChanger()
- if(istype(back, /obj/item/rig))
- var/obj/item/rig/rig = back
- if(rig.speech && rig.speech.voice_holder && rig.speech.voice_holder.active && rig.speech.voice_holder.voice)
- return rig.speech.voice_holder.voice
-
for(var/obj/item/gear in list(wear_mask, wear_suit, head))
if(!gear)
continue
@@ -134,8 +129,6 @@
S.message = "[S.message]"
verb = translator.speech_verb
return list("verb" = verb)
- if(mind)
- span = mind.speech_span
if((COMIC in mutations) \
|| (locate(/obj/item/organ/internal/cyberimp/brain/clown_voice) in internal_organs) \
|| HAS_TRAIT(src, TRAIT_JESTER))
diff --git a/code/modules/mob/living/carbon/human/species/_species.dm b/code/modules/mob/living/carbon/human/species/_species.dm
index f65cefff49d..a8e1eee5f52 100644
--- a/code/modules/mob/living/carbon/human/species/_species.dm
+++ b/code/modules/mob/living/carbon/human/species/_species.dm
@@ -345,15 +345,17 @@
switch(damagetype)
if(BRUTE)
- H.damageoverlaytemp = 20
damage = damage * brute_mod
+ if(damage)
+ H.damageoverlaytemp = 20
if(organ.receive_damage(damage, 0, sharp, used_weapon))
H.UpdateDamageIcon()
if(BURN)
- H.damageoverlaytemp = 20
damage = damage * burn_mod
+ if(damage)
+ H.damageoverlaytemp = 20
if(organ.receive_damage(0, damage, sharp, used_weapon))
H.UpdateDamageIcon()
@@ -517,9 +519,6 @@
/datum/species/proc/spec_attack_hand(mob/living/carbon/human/M, mob/living/carbon/human/H, datum/martial_art/attacker_style = M.martial_art) //Handles any species-specific attackhand events.
if(!istype(M))
return
- if(H.frozen)
- to_chat(M, "Do not touch Admin-Frozen people.")
- return
if(istype(M))
var/obj/item/organ/external/temp = M.bodyparts_by_name["r_hand"]
@@ -815,20 +814,6 @@ It'll return null if the organ doesn't correspond, so include null checks when u
if(!isnull(hat.lighting_alpha))
H.lighting_alpha = min(hat.lighting_alpha, H.lighting_alpha)
- if(istype(H.back, /obj/item/rig)) ///aghhh so snowflakey
- var/obj/item/rig/rig = H.back
- if(rig.visor)
- if(!rig.helmet || (H.head && rig.helmet == H.head))
- if(rig.visor && rig.visor.vision && rig.visor.active && rig.visor.vision.glasses)
- var/obj/item/clothing/glasses/G = rig.visor.vision.glasses
- if(istype(G))
- H.sight |= G.vision_flags
- H.see_in_dark = max(G.see_in_dark, H.see_in_dark)
- H.see_invisible = min(G.invis_view, H.see_invisible)
-
- if(!isnull(G.lighting_alpha))
- H.lighting_alpha = min(G.lighting_alpha, H.lighting_alpha)
-
if(H.vision_type)
H.sight |= H.vision_type.sight_flags
H.see_in_dark = max(H.see_in_dark, H.vision_type.see_in_dark)
diff --git a/code/modules/mob/living/carbon/human/update_icons.dm b/code/modules/mob/living/carbon/human/update_icons.dm
index 81907ba516f..f5496652dad 100644
--- a/code/modules/mob/living/carbon/human/update_icons.dm
+++ b/code/modules/mob/living/carbon/human/update_icons.dm
@@ -273,10 +273,10 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
overlays_standing[UNDERWEAR_LAYER] = mutable_appearance(underwear_standing, layer = -UNDERWEAR_LAYER)
apply_overlay(UNDERWEAR_LAYER)
- if(lip_style && (LIPS in dna.species.species_traits))
- var/icon/lips = icon("icon" = 'icons/mob/human_face.dmi', "icon_state" = "lips_[lip_style]_s")
- lips.Blend(lip_color, ICON_ADD)
- standing += mutable_appearance(lips, layer = -BODY_LAYER)
+ if(lip_style && (LIPS in dna.species.species_traits))
+ var/mutable_appearance/lips = mutable_appearance('icons/mob/human_face.dmi', "lips_[lip_style]_s")
+ lips.color = lip_color
+ standing += lips
overlays_standing[BODY_LAYER] = standing
apply_overlay(BODY_LAYER)
@@ -964,10 +964,6 @@ GLOBAL_LIST_EMPTY(damage_icon_parts)
var/mutable_appearance/standing
if(back.icon_override)
standing = mutable_appearance(back.icon_override, "[back.icon_state]", layer = -BACK_LAYER)
- else if(istype(back, /obj/item/rig))
- //If this is a rig and a mob_icon is set, it will take species into account in the rig update_icon() proc.
- var/obj/item/rig/rig = back
- standing = rig.mob_icon
else if(back.sprite_sheets && back.sprite_sheets[dna.species.name])
standing = mutable_appearance(back.sprite_sheets[dna.species.name], "[back.icon_state]", layer = -BACK_LAYER)
else
diff --git a/code/modules/mob/living/living.dm b/code/modules/mob/living/living.dm
index f3d23ca3f51..93a3b6f14cd 100644
--- a/code/modules/mob/living/living.dm
+++ b/code/modules/mob/living/living.dm
@@ -59,8 +59,9 @@
//Even if we don't push/swap places, we "touched" them, so spread fire
spreadFire(M)
- if(now_pushing)
- return 1
+ // No pushing if we're already pushing past something, or if the mob we're pushing into is anchored.
+ if(now_pushing || M.anchored)
+ return TRUE
//Should stop you pushing a restrained person out of the way
if(isliving(M))
@@ -68,7 +69,7 @@
if(L.pulledby && L.pulledby != src && L.restrained())
if(!(world.time % 5))
to_chat(src, "[L] is restrained, you cannot push past.")
- return 1
+ return TRUE
if(L.pulling)
if(ismob(L.pulling))
@@ -76,28 +77,28 @@
if(P.restrained())
if(!(world.time % 5))
to_chat(src, "[L] is restrained, you cannot push past.")
- return 1
+ return TRUE
if(moving_diagonally) //no mob swap during diagonal moves.
- return 1
+ return TRUE
if(a_intent == INTENT_HELP) // Help intent doesn't mob swap a mob pulling a structure
if(isstructure(M.pulling) || isstructure(pulling))
- return 1
+ return TRUE
if(!M.buckled && !M.has_buckled_mobs())
var/mob_swap
//the puller can always swap with it's victim if on grab intent
if(M.pulledby == src && a_intent == INTENT_GRAB)
- mob_swap = 1
+ mob_swap = TRUE
//restrained people act if they were on 'help' intent to prevent a person being pulled from being seperated from their puller
else if((M.restrained() || M.a_intent == INTENT_HELP) && (restrained() || a_intent == INTENT_HELP))
- mob_swap = 1
+ mob_swap = TRUE
if(mob_swap)
//switch our position with M
if(loc && !loc.Adjacent(M.loc))
- return 1
- now_pushing = 1
+ return TRUE
+ now_pushing = TRUE
var/oldloc = loc
var/oldMloc = M.loc
@@ -114,18 +115,18 @@
if(!M_passmob)
M.pass_flags &= ~PASSMOB
- now_pushing = 0
- return 1
+ now_pushing = FALSE
+ return TRUE
// okay, so we didn't switch. but should we push?
// not if he's not CANPUSH of course
if(!(M.status_flags & CANPUSH))
- return 1
+ return TRUE
//anti-riot equipment is also anti-push
if(M.r_hand && (prob(M.r_hand.block_chance * 2)) && !istype(M.r_hand, /obj/item/clothing))
- return 1
+ return TRUE
if(M.l_hand && (prob(M.l_hand.block_chance * 2)) && !istype(M.l_hand, /obj/item/clothing))
- return 1
+ return TRUE
//Called when we bump into an obj
/mob/living/proc/ObjBump(obj/O)
@@ -175,13 +176,6 @@
AM.setDir(current_dir)
now_pushing = FALSE
-/mob/living/Stat()
- . = ..()
- if(. && get_rig_stats)
- var/obj/item/rig/rig = get_rig()
- if(rig)
- SetupStat(rig)
-
/mob/living/proc/can_track(mob/living/user)
//basic fast checks go first. When overriding this proc, I recommend calling ..() at the end.
var/turf/T = get_turf(src)
diff --git a/code/modules/mob/living/living_defense.dm b/code/modules/mob/living/living_defense.dm
index b38f1819524..1f0f1cfa0f4 100644
--- a/code/modules/mob/living/living_defense.dm
+++ b/code/modules/mob/living/living_defense.dm
@@ -113,7 +113,7 @@
var/armor = run_armor_check(zone, "melee", "Your armor has protected your [parse_zone(zone)].", "Your armor has softened hit to your [parse_zone(zone)].", I.armour_penetration)
apply_damage(I.throwforce, dtype, zone, armor, is_sharp(I), I)
if(I.thrownby)
- add_attack_logs(I.thrownby, src, "Hit with thrown [I]")
+ add_attack_logs(I.thrownby, src, "Hit with thrown [I]", !I.throwforce ? ATKLOG_ALMOSTALL : null) // Only message if the person gets damages
else
return 1
else
diff --git a/code/modules/mob/living/silicon/ai/ai.dm b/code/modules/mob/living/silicon/ai/ai.dm
index 1c232f9f43c..7f6ed094dce 100644
--- a/code/modules/mob/living/silicon/ai/ai.dm
+++ b/code/modules/mob/living/silicon/ai/ai.dm
@@ -63,6 +63,7 @@ GLOBAL_LIST_INIT(ai_verbs_default, list(
//MALFUNCTION
var/datum/module_picker/malf_picker
+ var/datum/action/innate/ai/choose_modules/modules_action
var/list/datum/AI_Module/current_modules = list()
var/can_dominate_mechs = 0
var/shunted = 0 //1 if the AI is currently shunted. Used to differentiate between shunted and ghosted/braindead
@@ -851,13 +852,6 @@ GLOBAL_LIST_INIT(ai_verbs_default, list(
to_chat(src, "Switched to [network] camera network.")
//End of code by Mord_Sith
-
-/mob/living/silicon/ai/proc/choose_modules()
- set category = "Malfunction"
- set name = "Choose Module"
-
- malf_picker.use(src)
-
/mob/living/silicon/ai/proc/ai_statuschange()
set category = "AI Commands"
set name = "AI Status"
@@ -1028,15 +1022,6 @@ GLOBAL_LIST_INIT(ai_verbs_default, list(
return
-/mob/living/silicon/ai/proc/corereturn()
- set category = "Malfunction"
- set name = "Return to Main Core"
-
- var/obj/machinery/power/apc/apc = loc
- if(!istype(apc))
- to_chat(src, "You are already in your Main Core.")
- return
- apc.malfvacate()
//Toggles the luminosity and applies it by re-entereing the camera.
/mob/living/silicon/ai/proc/toggle_camera_light()
@@ -1181,16 +1166,6 @@ GLOBAL_LIST_INIT(ai_verbs_default, list(
/mob/living/silicon/ai/can_buckle()
return FALSE
-// Pass lying down or getting up to our pet human, if we're in a rig.
-/mob/living/silicon/ai/lay_down()
- set name = "Rest"
- set category = "IC"
-
- resting = 0
- var/obj/item/rig/rig = get_rig()
- if(rig)
- rig.force_rest(src)
-
/mob/living/silicon/ai/switch_to_camera(obj/machinery/camera/C)
if(!C.can_use() || !is_in_chassis())
return FALSE
@@ -1244,8 +1219,17 @@ GLOBAL_LIST_INIT(ai_verbs_default, list(
to_chat(src, "In the top right corner of the screen you will find the Malfunctions tab, where you can purchase various abilities, from upgraded surveillance to station ending doomsday devices.")
to_chat(src, "You are also capable of hacking APCs, which grants you more points to spend on your Malfunction powers. The drawback is that a hacked APC will give you away if spotted by the crew. Hacking an APC takes 60 seconds.")
view_core() //A BYOND bug requires you to be viewing your core before your verbs update
- verbs += /mob/living/silicon/ai/proc/choose_modules
malf_picker = new /datum/module_picker
+ modules_action = new(malf_picker)
+ modules_action.Grant(src)
+
+///Removes all malfunction-related /datum/action's from the target AI.
+/mob/living/silicon/ai/proc/remove_malf_abilities()
+ QDEL_NULL(modules_action)
+ for(var/datum/AI_Module/AM in current_modules)
+ for(var/datum/action/A in actions)
+ if(istype(A, initial(AM.power_type)))
+ qdel(A)
/mob/living/silicon/ai/proc/open_nearest_door(mob/living/target)
if(!istype(target))
diff --git a/code/modules/mob/living/silicon/ai/latejoin.dm b/code/modules/mob/living/silicon/ai/latejoin.dm
index 75e8854b45c..e1be5450811 100644
--- a/code/modules/mob/living/silicon/ai/latejoin.dm
+++ b/code/modules/mob/living/silicon/ai/latejoin.dm
@@ -1,15 +1,5 @@
GLOBAL_LIST_EMPTY(empty_playable_ai_cores)
-/hook/roundstart/proc/spawn_empty_ai()
- for(var/obj/effect/landmark/start/S in GLOB.landmarks_list)
- if(S.name != "AI")
- continue
- if(locate(/mob/living) in S.loc)
- continue
- GLOB.empty_playable_ai_cores += new /obj/structure/AIcore/deactivated(get_turf(S))
-
- return 1
-
/mob/living/silicon/ai/verb/wipe_core()
set name = "Wipe Core"
set category = "OOC"
diff --git a/code/modules/mob/living/silicon/pai/pai.dm b/code/modules/mob/living/silicon/pai/pai.dm
index 3d1293d2a34..2a5a7b0aa08 100644
--- a/code/modules/mob/living/silicon/pai/pai.dm
+++ b/code/modules/mob/living/silicon/pai/pai.dm
@@ -435,9 +435,6 @@
// Pass lying down or getting up to our pet human, if we're in a rig.
if(stat == CONSCIOUS && istype(loc,/obj/item/paicard))
resting = 0
- var/obj/item/rig/rig = get_rig()
- if(istype(rig))
- rig.force_rest(src)
else
resting = !resting
to_chat(src, "You are now [resting ? "resting" : "getting up"]")
diff --git a/code/modules/mob/living/silicon/pai/recruit.dm b/code/modules/mob/living/silicon/pai/recruit.dm
index f52da9942e4..920dff8a8c2 100644
--- a/code/modules/mob/living/silicon/pai/recruit.dm
+++ b/code/modules/mob/living/silicon/pai/recruit.dm
@@ -1,6 +1,6 @@
// Recruiting observers to play as pAIs
-GLOBAL_DATUM(paiController, /datum/paiController) // Global handler for pAI candidates
+GLOBAL_DATUM_INIT(paiController, /datum/paiController, new) // Global handler for pAI candidates
/datum/paiCandidate
var/name
@@ -10,12 +10,6 @@ GLOBAL_DATUM(paiController, /datum/paiController) // Global handler for pAI cand
var/comments
var/ready = 0
-
-/hook/startup/proc/paiControllerSetup()
- GLOB.paiController = new /datum/paiController()
- return 1
-
-
/datum/paiController
var/list/pai_candidates = list()
var/list/asked = list()
diff --git a/code/modules/mob/living/silicon/pai/software.dm b/code/modules/mob/living/silicon/pai/software.dm
index 3b51048452e..574dcda3230 100644
--- a/code/modules/mob/living/silicon/pai/software.dm
+++ b/code/modules/mob/living/silicon/pai/software.dm
@@ -13,19 +13,6 @@ GLOBAL_LIST_INIT(pai_emotions, list(
GLOBAL_LIST_EMPTY(pai_software_by_key)
GLOBAL_LIST_EMPTY(default_pai_software)
-/hook/startup/proc/populate_pai_software_list()
- var/r = 1 // I would use ., but it'd sacrifice runtime detection
- for(var/type in subtypesof(/datum/pai_software))
- var/datum/pai_software/P = new type()
- if(GLOB.pai_software_by_key[P.id])
- var/datum/pai_software/O = GLOB.pai_software_by_key[P.id]
- to_chat(world, "pAI software module [P.name] has the same key as [O.name]!")
- r = 0
- continue
- GLOB.pai_software_by_key[P.id] = P
- if(P.default)
- GLOB.default_pai_software[P.id] = P
- return r
/mob/living/silicon/pai/New()
..()
diff --git a/code/modules/mob/living/silicon/robot/drone/drone.dm b/code/modules/mob/living/silicon/robot/drone/drone.dm
index ff7f7fba084..91970d030a6 100644
--- a/code/modules/mob/living/silicon/robot/drone/drone.dm
+++ b/code/modules/mob/living/silicon/robot/drone/drone.dm
@@ -83,7 +83,7 @@
scanner.Grant(src)
update_icons()
-/mob/living/silicon/robot/drone/init()
+/mob/living/silicon/robot/drone/init(alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
laws = new /datum/ai_laws/drone()
connected_ai = null
@@ -354,3 +354,20 @@
/mob/living/simple_animal/drone/flash_eyes(intensity = 1, override_blindness_check = 0, affect_silicon = 0, visual = 0)
if(affect_silicon)
return ..()
+
+/mob/living/silicon/robot/drone/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ if(!client && istype(user, /mob/living/silicon/robot/drone))
+ to_chat(user, "You begin decompiling the other drone.")
+ if(!do_after(user, 5 SECONDS, target = loc))
+ to_chat(user, "You need to remain still while decompiling such a large object.")
+ return
+ if(QDELETED(src) || QDELETED(user))
+ return ..()
+ to_chat(user, "You carefully and thoroughly decompile your downed fellow, storing as much of its resources as you can within yourself.")
+ new/obj/effect/decal/cleanable/blood/oil(get_turf(src))
+ C.stored_comms["metal"] += 15
+ C.stored_comms["glass"] += 15
+ C.stored_comms["wood"] += 5
+ qdel(src)
+ return TRUE
+ return ..()
diff --git a/code/modules/mob/living/silicon/robot/drone/drone_items.dm b/code/modules/mob/living/silicon/robot/drone/drone_items.dm
index 8f2b9fee6ae..a0582c135e4 100644
--- a/code/modules/mob/living/silicon/robot/drone/drone_items.dm
+++ b/code/modules/mob/living/silicon/robot/drone/drone_items.dm
@@ -151,15 +151,13 @@
var/list/stored_comms = list(
"metal" = 0,
"glass" = 0,
- "wood" = 0,
- "plastic" = 0
+ "wood" = 0
)
/obj/item/matter_decompiler/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob)
return
-/obj/item/matter_decompiler/afterattack(atom/target as mob|obj|turf|area, mob/living/user as mob|obj, proximity, params)
-
+/obj/item/matter_decompiler/afterattack(atom/target, mob/living/user, proximity, params)
if(!proximity) return //Not adjacent.
//We only want to deal with using this on turfs. Specific items aren't important.
@@ -168,101 +166,11 @@
return
//Used to give the right message.
- var/grabbed_something = 0
+ var/grabbed_something = FALSE
- for(var/mob/M in T)
- if(istype(M,/mob/living/simple_animal/lizard) || istype(M,/mob/living/simple_animal/mouse))
- src.loc.visible_message("[src.loc] sucks [M] into its decompiler. There's a horrible crunching noise.","It's a bit of a struggle, but you manage to suck [M] into your decompiler. It makes a series of visceral crunching noises.")
- new/obj/effect/decal/cleanable/blood/splatter(get_turf(src))
- qdel(M)
- stored_comms["wood"]++
- stored_comms["wood"]++
- stored_comms["plastic"]++
- stored_comms["plastic"]++
- return
-
- else if(istype(M,/mob/living/silicon/robot/drone) && !M.client)
-
- var/mob/living/silicon/robot/drone/D = src.loc
-
- if(!istype(D))
- return
-
- to_chat(D, "You begin decompiling the other drone.")
-
- if(!do_after(D, 50, target = target))
- to_chat(D, "You need to remain still while decompiling such a large object.")
- return
-
- if(!M || !D) return
-
- to_chat(D, "You carefully and thoroughly decompile your downed fellow, storing as much of its resources as you can within yourself.")
-
- qdel(M)
- new/obj/effect/decal/cleanable/blood/oil(get_turf(src))
-
- stored_comms["metal"] += 15
- stored_comms["glass"] += 15
- stored_comms["wood"] += 5
- stored_comms["plastic"] += 5
-
- return
- else
- continue
-
- for(var/obj/W in T)
- //Different classes of items give different commodities.
- if(istype(W,/obj/item/cigbutt))
- stored_comms["plastic"]++
- else if(istype(W,/obj/structure/spider/spiderling))
- stored_comms["wood"]++
- stored_comms["wood"]++
- stored_comms["plastic"]++
- stored_comms["plastic"]++
- else if(istype(W,/obj/item/light))
- var/obj/item/light/L = W
- if(L.status >= 2) //In before someone changes the inexplicably local defines. ~ Z
- stored_comms["metal"]++
- stored_comms["glass"]++
- else
- continue
- else if(istype(W,/obj/effect/decal/remains/robot))
- stored_comms["metal"]++
- stored_comms["metal"]++
- stored_comms["plastic"]++
- stored_comms["plastic"]++
- stored_comms["glass"]++
- else if(istype(W,/obj/item/trash))
- stored_comms["metal"]++
- stored_comms["plastic"]++
- stored_comms["plastic"]++
- else if(istype(W,/obj/effect/decal/cleanable/blood/gibs/robot))
- stored_comms["metal"]++
- stored_comms["metal"]++
- stored_comms["glass"]++
- stored_comms["glass"]++
- else if(istype(W,/obj/item/ammo_casing))
- stored_comms["metal"]++
- else if(istype(W,/obj/item/shard))
- stored_comms["glass"]++
- stored_comms["glass"]++
- stored_comms["glass"]++
- else if(istype(W,/obj/item/reagent_containers/food/snacks/grown))
- stored_comms["wood"]++
- stored_comms["wood"]++
- stored_comms["wood"]++
- stored_comms["wood"]++
- else if(istype(W,/obj/item/broken_bottle))
- stored_comms["glass"]++
- stored_comms["glass"]++
- stored_comms["glass"]++
- else if(istype(W,/obj/item/light/tube) || istype(W,/obj/item/light/bulb))
- stored_comms["glass"]++
- else
- continue
-
- qdel(W)
- grabbed_something = 1
+ for(var/atom/movable/A in T)
+ if(A.decompile_act(src, user)) // Each decompileable mob or obj needs to have this defined
+ grabbed_something = TRUE
if(grabbed_something)
to_chat(user, "You deploy your decompiler and clear out the contents of \the [T].")
@@ -353,11 +261,5 @@
stack_wood = new /obj/item/stack/sheet/wood(src.module)
stack_wood.amount = 1
stack = stack_wood
- if("plastic")
- if(!stack_plastic)
- stack_plastic = new /obj/item/stack/sheet/plastic(src.module)
- stack_plastic.amount = 1
- stack = stack_plastic
-
stack.amount++
decompiler.stored_comms[type]--
diff --git a/code/modules/mob/living/silicon/robot/robot.dm b/code/modules/mob/living/silicon/robot/robot.dm
index cc9d22ec673..faa51a58ec0 100644
--- a/code/modules/mob/living/silicon/robot/robot.dm
+++ b/code/modules/mob/living/silicon/robot/robot.dm
@@ -112,7 +112,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
/mob/living/silicon/robot/get_cell()
return cell
-/mob/living/silicon/robot/New(loc,var/syndie = 0,var/unfinished = 0, var/alien = 0)
+/mob/living/silicon/robot/New(loc, syndie = FALSE, unfinished = FALSE, alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
spark_system = new /datum/effect_system/spark_spread()
spark_system.set_up(5, 0, src)
spark_system.attach(src)
@@ -134,7 +134,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
radio = new /obj/item/radio/borg(src)
common_radio = radio
- init()
+ init(ai_to_sync_to = ai_to_sync_to)
if(has_camera && !camera)
camera = new /obj/machinery/camera(src)
@@ -172,14 +172,16 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
scanner = new(src)
scanner.Grant(src)
-/mob/living/silicon/robot/proc/init(var/alien=0)
+/mob/living/silicon/robot/proc/init(alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
aiCamera = new/obj/item/camera/siliconcam/robot_camera(src)
make_laws()
additional_law_channels["Binary"] = ":b "
- var/new_ai = select_active_ai_with_fewest_borgs()
- if(new_ai)
+ var/found_ai = ai_to_sync_to
+ if(!found_ai)
+ found_ai = select_active_ai_with_fewest_borgs()
+ if(found_ai)
lawupdate = 1
- connect_to_ai(new_ai)
+ connect_to_ai(found_ai)
else
lawupdate = 0
@@ -1148,7 +1150,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
if(module)
if(module.type == /obj/item/robot_module/janitor)
var/turf/tile = loc
- if(isturf(tile))
+ if(stat != DEAD && isturf(tile))
var/floor_only = TRUE
for(var/A in tile)
if(istype(A, /obj/effect))
@@ -1348,7 +1350,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
is_emaggable = FALSE
default_cell_type = /obj/item/stock_parts/cell/bluespace
-/mob/living/silicon/robot/deathsquad/init()
+/mob/living/silicon/robot/deathsquad/init(alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
laws = new /datum/ai_laws/deathsquad
module = new /obj/item/robot_module/deathsquad(src)
aiCamera = new/obj/item/camera/siliconcam/robot_camera(src)
@@ -1378,7 +1380,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
var/eprefix = "Amber"
-/mob/living/silicon/robot/ert/init()
+/mob/living/silicon/robot/ert/init(alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
laws = new /datum/ai_laws/ert_override
radio = new /obj/item/radio/borg/ert(src)
radio.recalculateChannels()
@@ -1434,7 +1436,7 @@ GLOBAL_LIST_INIT(robot_verbs_default, list(
xeno_disarm_chance = 10
default_cell_type = /obj/item/stock_parts/cell/bluespace
-/mob/living/silicon/robot/destroyer/init()
+/mob/living/silicon/robot/destroyer/init(alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
..()
module = new /obj/item/robot_module/destroyer(src)
module.add_languages(src)
diff --git a/code/modules/mob/living/silicon/robot/syndicate.dm b/code/modules/mob/living/silicon/robot/syndicate.dm
index 0d1968b3e7a..f5b58696059 100644
--- a/code/modules/mob/living/silicon/robot/syndicate.dm
+++ b/code/modules/mob/living/silicon/robot/syndicate.dm
@@ -21,7 +21,7 @@
..()
cell = new /obj/item/stock_parts/cell/hyper(src)
-/mob/living/silicon/robot/syndicate/init()
+/mob/living/silicon/robot/syndicate/init(alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
laws = new /datum/ai_laws/syndicate_override
module = new /obj/item/robot_module/syndicate(src)
@@ -47,7 +47,7 @@
Your energy saw functions as a circular saw, but can be activated to deal more damage, and your operative pinpointer will find and locate fellow nuclear operatives. \
Help the operatives secure the disk at all costs!"
-/mob/living/silicon/robot/syndicate/medical/init()
+/mob/living/silicon/robot/syndicate/medical/init(alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
..()
module = new /obj/item/robot_module/syndicate_medical(src)
@@ -67,7 +67,7 @@
Be aware that physical contact or taking damage will break your disguise. \
Help the operatives secure the disk at all costs!"
-/mob/living/silicon/robot/syndicate/saboteur/init()
+/mob/living/silicon/robot/syndicate/saboteur/init(alien = FALSE, mob/living/silicon/ai/ai_to_sync_to = null)
..()
module = new /obj/item/robot_module/syndicate_saboteur(src)
diff --git a/code/modules/mob/living/simple_animal/bot/bot.dm b/code/modules/mob/living/simple_animal/bot/bot.dm
index cb45fd98e8b..e51dc527832 100644
--- a/code/modules/mob/living/simple_animal/bot/bot.dm
+++ b/code/modules/mob/living/simple_animal/bot/bot.dm
@@ -756,7 +756,7 @@ Pass a positive integer as an argument to override a bot's default speed.
// send a radio signal with multiple data key/values
/mob/living/simple_animal/bot/proc/post_signal_multiple(var/freq, var/list/keyval)
- if(z != 1) //Bot control will only work on station.
+ if(!is_station_level(z)) //Bot control will only work on station.
return
var/datum/radio_frequency/frequency = SSradio.return_frequency(freq)
if(!frequency)
diff --git a/code/modules/mob/living/simple_animal/bot/construction.dm b/code/modules/mob/living/simple_animal/bot/construction.dm
index 024e2b5f304..e18672ffa20 100644
--- a/code/modules/mob/living/simple_animal/bot/construction.dm
+++ b/code/modules/mob/living/simple_animal/bot/construction.dm
@@ -474,8 +474,7 @@
return
build_step++
to_chat(user, "You complete the Securitron! Beep boop.")
- var/mob/living/simple_animal/bot/secbot/S = new /mob/living/simple_animal/bot/secbot
- S.forceMove(get_turf(src))
+ var/mob/living/simple_animal/bot/secbot/S = new /mob/living/simple_animal/bot/secbot(get_turf(src))
S.name = created_name
S.robot_arm = robot_arm
qdel(I)
@@ -512,7 +511,7 @@
//General Griefsky
else if((istype(I, /obj/item/wrench)) && (build_step == 3))
- var/obj/item/griefsky_assembly/A = new /obj/item/griefsky_assembly
+ var/obj/item/griefsky_assembly/A = new /obj/item/griefsky_assembly(get_turf(src))
user.put_in_hands(A)
to_chat(user, "You adjust the arm slots for extra weapons!.")
user.unEquip(src, 1)
@@ -540,8 +539,7 @@
if(!user.unEquip(I))
return
to_chat(user, "You complete General Griefsky!.")
- var/mob/living/simple_animal/bot/secbot/griefsky/S = new /mob/living/simple_animal/bot/secbot/griefsky
- S.forceMove(get_turf(src))
+ new /mob/living/simple_animal/bot/secbot/griefsky(get_turf(src))
qdel(I)
qdel(src)
@@ -556,8 +554,7 @@
if(!user.unEquip(I))
return
to_chat(user, "You complete Genewul Giftskee!.")
- var/mob/living/simple_animal/bot/secbot/griefsky/toy/S = new /mob/living/simple_animal/bot/secbot/griefsky/toy
- S.forceMove(get_turf(src))
+ new /mob/living/simple_animal/bot/secbot/griefsky/toy(get_turf(src))
qdel(I)
qdel(src)
diff --git a/code/modules/mob/living/simple_animal/friendly/lizard.dm b/code/modules/mob/living/simple_animal/friendly/lizard.dm
index 96688963b73..566791786f6 100644
--- a/code/modules/mob/living/simple_animal/friendly/lizard.dm
+++ b/code/modules/mob/living/simple_animal/friendly/lizard.dm
@@ -23,3 +23,14 @@
butcher_results = list(/obj/item/reagent_containers/food/snacks/meat = 1)
can_collar = 1
gold_core_spawnable = FRIENDLY_SPAWN
+
+/mob/living/simple_animal/lizard/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ if(!istype(user, /mob/living/silicon/robot/drone))
+ user.visible_message("[user] sucks [src] into its decompiler. There's a horrible crunching noise.", \
+ "It's a bit of a struggle, but you manage to suck [src] into your decompiler. It makes a series of visceral crunching noises.")
+ new/obj/effect/decal/cleanable/blood/splatter(get_turf(src))
+ C.stored_comms["wood"] += 2
+ C.stored_comms["glass"] += 2
+ qdel(src)
+ return TRUE
+ return ..()
diff --git a/code/modules/mob/living/simple_animal/friendly/mouse.dm b/code/modules/mob/living/simple_animal/friendly/mouse.dm
index a48b36cb0c7..152e2494132 100644
--- a/code/modules/mob/living/simple_animal/friendly/mouse.dm
+++ b/code/modules/mob/living/simple_animal/friendly/mouse.dm
@@ -234,3 +234,14 @@
gold_core_spawnable = NO_SPAWN
can_collar = 0
butcher_results = list(/obj/item/stack/sheet/metal = 1)
+
+/mob/living/simple_animal/mouse/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ if(!(istype(user, /mob/living/silicon/robot/drone)))
+ user.visible_message("[user] sucks [src] into its decompiler. There's a horrible crunching noise.", \
+ "It's a bit of a struggle, but you manage to suck [src] into your decompiler. It makes a series of visceral crunching noises.")
+ new/obj/effect/decal/cleanable/blood/splatter(get_turf(src))
+ C.stored_comms["wood"] += 2
+ C.stored_comms["glass"] += 2
+ qdel(src)
+ return TRUE
+ return ..()
diff --git a/code/modules/mob/living/simple_animal/hostile/bees.dm b/code/modules/mob/living/simple_animal/hostile/bees.dm
index 3276416fe7f..3419279ffe5 100644
--- a/code/modules/mob/living/simple_animal/hostile/bees.dm
+++ b/code/modules/mob/living/simple_animal/hostile/bees.dm
@@ -95,6 +95,10 @@
for(var/mob/A in searched_for)
. += A
+// All bee sprites are made up of overlays. They do not have any special sprite overlays for items placed on them, such as collars, so this proc is unneeded.
+/mob/living/simple_animal/hostile/poison/bees/regenerate_icons()
+ return
+
/mob/living/simple_animal/hostile/poison/bees/proc/generate_bee_visuals()
overlays.Cut()
diff --git a/code/modules/mob/living/simple_animal/hostile/headcrab.dm b/code/modules/mob/living/simple_animal/hostile/headcrab.dm
index 08eb7128055..c093c8e3d36 100644
--- a/code/modules/mob/living/simple_animal/hostile/headcrab.dm
+++ b/code/modules/mob/living/simple_animal/hostile/headcrab.dm
@@ -31,8 +31,7 @@
if(H.stat == DEAD || (!H.check_death_method() && H.health <= HEALTH_THRESHOLD_DEAD))
Zombify(H)
break
- var/cycles = 4
- if(cycles >= 4)
+ if(times_fired % 4 == 0)
for(var/mob/living/simple_animal/K in oview(src, 1)) //Only for corpse right next to/on same tile
if(K.stat == DEAD || (!K.check_death_method() && K.health <= HEALTH_THRESHOLD_DEAD))
visible_message("[src] consumes [K] whole!")
@@ -40,8 +39,6 @@
health += 10
qdel(K)
break
- cycles = 0
- cycles++
/mob/living/simple_animal/hostile/headcrab/OpenFire(atom/A)
if(check_friendly_fire)
@@ -93,7 +90,6 @@
if(is_zombie)
qdel(src)
-
/mob/living/simple_animal/hostile/headcrab/handle_automated_speech() // This way they have different screams when attacking, sometimes. Might be seen as sphagetthi code though.
if(speak_chance)
if(rand(0,200) < speak_chance)
@@ -106,7 +102,6 @@
M.loc = get_turf(src)
return ..()
-
/mob/living/simple_animal/hostile/headcrab/update_icons()
. = ..()
if(is_zombie)
diff --git a/code/modules/mob/living/simple_animal/hostile/terror_spiders/princess.dm b/code/modules/mob/living/simple_animal/hostile/terror_spiders/princess.dm
index 047219a151b..6f33c51b246 100644
--- a/code/modules/mob/living/simple_animal/hostile/terror_spiders/princess.dm
+++ b/code/modules/mob/living/simple_animal/hostile/terror_spiders/princess.dm
@@ -15,7 +15,7 @@
ai_target_method = TS_DAMAGE_SIMPLE
icon_state = "terror_princess1"
icon_living = "terror_princess1"
- icon_dead = "terror_princess_dead1"
+ icon_dead = "terror_princess1_dead"
maxHealth = 150
health = 150
regen_points_per_hp = 1 // always regens very fast
@@ -51,7 +51,7 @@
if(fed == 0)
icon_state = "terror_princess1"
icon_living = "terror_princess1"
- icon_dead = "terror_princess_dead1"
+ icon_dead = "terror_princess1_dead"
desc = "An enormous spider. It looks strangely cute and fluffy, with soft pink fur covering most of its body."
else if(fed == 1)
icon_state = "terror_princess2"
diff --git a/code/modules/mob/living/simple_animal/simple_animal.dm b/code/modules/mob/living/simple_animal/simple_animal.dm
index 7d31b5d523b..d4f8e7c4c3d 100644
--- a/code/modules/mob/living/simple_animal/simple_animal.dm
+++ b/code/modules/mob/living/simple_animal/simple_animal.dm
@@ -615,3 +615,8 @@
if(pcollar && collar_type)
add_overlay("[collar_type]collar")
add_overlay("[collar_type]tag")
+
+/mob/living/simple_animal/Login()
+ ..()
+ walk(src, 0) // if mob is moving under ai control, then stop AI movement
+
diff --git a/code/modules/mob/mob.dm b/code/modules/mob/mob.dm
index 3b86faeb7e6..1c7f8fa6ae9 100644
--- a/code/modules/mob/mob.dm
+++ b/code/modules/mob/mob.dm
@@ -880,6 +880,9 @@ GLOBAL_LIST_INIT(slot_equipment_priority, list( \
return
if(!Adjacent(usr))
return
+ if(IsFrozen(src) && !is_admin(usr))
+ to_chat(usr, "Interacting with admin-frozen players is not permitted.")
+ return
if(isLivingSSD(src) && M.client && M.client.send_ssd_warning(src))
return
show_inv(usr)
diff --git a/code/modules/mob/new_player/poll.dm b/code/modules/mob/new_player/poll.dm
index 19893819e0c..2e109d36d34 100644
--- a/code/modules/mob/new_player/poll.dm
+++ b/code/modules/mob/new_player/poll.dm
@@ -90,7 +90,7 @@
if(adminonly)
question = "(Admin only poll) " + question
- var output = ""
+ var/output = ""
if(polltype == POLLTYPE_MULTI || polltype == POLLTYPE_OPTION)
select_query = GLOB.dbcon.NewQuery("SELECT text, percentagecalc, (SELECT COUNT(optionid) FROM [format_table_name("poll_vote")] WHERE optionid = poll_option.id GROUP BY optionid) AS votecount FROM [format_table_name("poll_option")] WHERE pollid = [pollid]")
select_query.Execute()
diff --git a/code/modules/mob/transform_procs.dm b/code/modules/mob/transform_procs.dm
index 2ee4a9d2a9c..8e7adea666b 100644
--- a/code/modules/mob/transform_procs.dm
+++ b/code/modules/mob/transform_procs.dm
@@ -82,14 +82,11 @@
O.notify_ai(1)
if(O.mind && O.mind.assigned_role == "Cyborg")
- if(O.mind.role_alt_title == "Android")
+ if(O.mind.role_alt_title == "Robot")
O.mmi = new /obj/item/mmi/robotic_brain(O)
- else if(O.mind.role_alt_title == "Robot")
- O.mmi = null //Robots do not have removable brains.
else
O.mmi = new /obj/item/mmi(O)
-
- if(O.mmi) O.mmi.transfer_identity(src) //Does not transfer key/client.
+ O.mmi.transfer_identity(src) //Does not transfer key/client.
O.update_pipe_vision()
diff --git a/code/modules/nano/nanomapgen.dm b/code/modules/nano/nanomapgen.dm
deleted file mode 100644
index b0a8869191f..00000000000
--- a/code/modules/nano/nanomapgen.dm
+++ /dev/null
@@ -1,90 +0,0 @@
-// This file is a modified version of https://raw2.github.com/Baystation12/OldCode-BS12/master/code/TakePicture.dm
-
-#define NANOMAP_ICON_SIZE 4
-#define NANOMAP_MAX_ICON_DIMENSION 1024
-
-#define NANOMAP_TILES_PER_IMAGE (NANOMAP_MAX_ICON_DIMENSION / NANOMAP_ICON_SIZE)
-
-#define NANOMAP_TERMINALERR 5
-#define NANOMAP_INPROGRESS 2
-#define NANOMAP_BADOUTPUT 2
-#define NANOMAP_SUCCESS 1
-#define NANOMAP_WATCHDOGSUCCESS 4
-#define NANOMAP_WATCHDOGTERMINATE 3
-
-
-//Call these procs to dump your world to a series of image files (!!)
-//NOTE: Does not explicitly support non 32x32 icons or stuff with large pixel_* values, so don't blame me if it doesn't work perfectly
-
-/client/proc/nanomapgen_DumpImage()
- set name = "Generate NanoUI Map"
- set category = "Mapping"
-
- if(holder)
- nanomapgen_DumpTile(1, 1, text2num(input(usr,"Enter the Z level to generate")))
-
-/client/proc/nanomapgen_DumpTile(var/startX = 1, var/startY = 1, var/currentZ = 1, var/endX = -1, var/endY = -1)
-
- if(endX < 0 || endX > world.maxx)
- endX = world.maxx
-
- if(endY < 0 || endY > world.maxy)
- endY = world.maxy
-
- if(currentZ < 0 || currentZ > world.maxz)
- to_chat(usr, "NanoMapGen: ERROR: currentZ ([currentZ]) must be between 1 and [world.maxz]")
-
- sleep(3)
- return NANOMAP_TERMINALERR
-
- if(startX > endX)
- to_chat(usr, "NanoMapGen: ERROR: startX ([startX]) cannot be greater than endX ([endX])")
-
- sleep(3)
- return NANOMAP_TERMINALERR
-
- if(startY > endX)
- to_chat(usr, "NanoMapGen: ERROR: startY ([startY]) cannot be greater than endY ([endY])")
- sleep(3)
- return NANOMAP_TERMINALERR
-
- var/icon/Tile = icon(file("nano/mapbase1024.png"))
- if(Tile.Width() != NANOMAP_MAX_ICON_DIMENSION || Tile.Height() != NANOMAP_MAX_ICON_DIMENSION)
- log_world("NanoMapGen: ERROR: BASE IMAGE DIMENSIONS ARE NOT [NANOMAP_MAX_ICON_DIMENSION]x[NANOMAP_MAX_ICON_DIMENSION]")
- sleep(3)
- return NANOMAP_TERMINALERR
-
- log_world("NanoMapGen: GENERATE MAP ([startX],[startY],[currentZ]) to ([endX],[endY],[currentZ])")
- to_chat(usr, "NanoMapGen: GENERATE MAP ([startX],[startY],[currentZ]) to ([endX],[endY],[currentZ])")
-
- var/count = 0
- for(var/WorldX = startX, WorldX <= endX, WorldX++)
- for(var/WorldY = startY, WorldY <= endY, WorldY++)
-
- var/atom/Turf = locate(WorldX, WorldY, currentZ)
-
- var/icon/TurfIcon = new(Turf.icon, Turf.icon_state)
- TurfIcon.Scale(NANOMAP_ICON_SIZE, NANOMAP_ICON_SIZE)
-
- Tile.Blend(TurfIcon, ICON_OVERLAY, ((WorldX - 1) * NANOMAP_ICON_SIZE), ((WorldY - 1) * NANOMAP_ICON_SIZE))
-
- count++
-
- if(count % 8000 == 0)
- log_world("NanoMapGen: [count] tiles done")
- sleep(1)
-
- var/mapFilename = "nanomap_z[currentZ]-new.png"
-
- log_world("NanoMapGen: sending [mapFilename] to client")
-
- usr << browse(Tile, "window=picture;file=[mapFilename];display=0")
-
- log_world("NanoMapGen: Done.")
-
- to_chat(usr, "NanoMapGen: Done. File [mapFilename] uploaded to your cache.")
-
- if(Tile.Width() != NANOMAP_MAX_ICON_DIMENSION || Tile.Height() != NANOMAP_MAX_ICON_DIMENSION)
- return NANOMAP_BADOUTPUT
-
- return NANOMAP_SUCCESS
diff --git a/code/modules/paperwork/ticketmachine.dm b/code/modules/paperwork/ticketmachine.dm
index c5939c392b1..2234e2911a6 100644
--- a/code/modules/paperwork/ticketmachine.dm
+++ b/code/modules/paperwork/ticketmachine.dm
@@ -108,7 +108,7 @@
maptext_x = 10
if(100)
maptext_x = 8
- maptext = "[current_number]" //Finally, apply the maptext
+ maptext = "[ticket_number]"
/obj/machinery/ticket_machine/attackby(obj/item/I, mob/user, params)
if(istype(I, /obj/item/hand_labeler_refill))
@@ -151,8 +151,8 @@
to_chat(user, "You take a ticket from [src], looks like you're ticket number #[ticket_number]...")
var/obj/item/ticket_machine_ticket/theirticket = new /obj/item/ticket_machine_ticket(get_turf(src))
theirticket.name = "Ticket #[ticket_number]"
- theirticket.maptext = "[ticket_number]"
- theirticket.saved_maptext = "[ticket_number]"
+ theirticket.maptext = "[ticket_number]"
+ theirticket.saved_maptext = "[ticket_number]"
theirticket.ticket_number = ticket_number
theirticket.source = src
theirticket.owner = user.UID()
@@ -167,9 +167,13 @@
user.adjust_fire_stacks(1)
user.IgniteMob()
+// Stop AI penetrating the bureaucracy
+/obj/machinery/ticket_machine/attack_ai(mob/user)
+ return
+
/obj/item/ticket_machine_ticket
name = "Ticket"
- desc = "A ticket which shows your place in the Head of Personnel's line. Made from Nanotrasen patented NanoPaper®. Though solid, its form seems to shimmer slightly. Feels (and burns) just like the real thing."
+ desc = "A ticket which shows your place in the Head of Personnel's line. Made from Nanotrasen patented NanoPaper. Though solid, its form seems to shimmer slightly. Feels (and burns) just like the real thing."
icon = 'icons/obj/bureaucracy.dmi'
icon_state = "ticket"
maptext_x = 7
diff --git a/code/modules/power/apc.dm b/code/modules/power/apc.dm
index 56e38d31935..409abe3d724 100644
--- a/code/modules/power/apc.dm
+++ b/code/modules/power/apc.dm
@@ -1052,7 +1052,8 @@
occupier.eyeobj.name = "[occupier.name] (AI Eye)"
if(malf.parent)
qdel(malf)
- occupier.verbs += /mob/living/silicon/ai/proc/corereturn
+ var/datum/action/innate/ai/return_to_core/R = new
+ R.Grant(occupier)
occupier.cancel_camera()
if((seclevel2num(get_security_level()) == SEC_LEVEL_DELTA) && malf.nuking)
for(var/obj/item/pinpointer/point in GLOB.pinpointer_list)
diff --git a/code/modules/power/lighting.dm b/code/modules/power/lighting.dm
index 0a31d882488..3e8d71b3280 100644
--- a/code/modules/power/lighting.dm
+++ b/code/modules/power/lighting.dm
@@ -634,6 +634,12 @@
shatter()
return ..()
+/obj/item/light/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ C.stored_comms["glass"] += 1
+ C.stored_comms["metal"] += 1
+ qdel(src)
+ return TRUE
+
/obj/item/light/tube
name = "light tube"
desc = "A replacement light tube."
diff --git a/code/modules/power/singularity/narsie.dm b/code/modules/power/singularity/narsie.dm
index 80b10ab3a8b..bead9c935ef 100644
--- a/code/modules/power/singularity/narsie.dm
+++ b/code/modules/power/singularity/narsie.dm
@@ -127,6 +127,8 @@
/obj/singularity/narsie/proc/acquire(var/mob/food)
if(food == target)
return
+ if(!target)
+ return
to_chat(target, "[uppertext(SSticker.cultdat.entity_name)] HAS LOST INTEREST IN YOU")
target = food
if(ishuman(target))
diff --git a/code/modules/power/tracker.dm b/code/modules/power/tracker.dm
index c8964c7ec34..621c5f02747 100644
--- a/code/modules/power/tracker.dm
+++ b/code/modules/power/tracker.dm
@@ -29,10 +29,10 @@
//set the control of the tracker to a given computer if closer than SOLAR_MAX_DIST
/obj/machinery/power/tracker/proc/set_control(obj/machinery/power/solar_control/SC)
if(SC && (get_dist(src, SC) > SOLAR_MAX_DIST))
- return 0
+ return FALSE
control = SC
SC.connected_tracker = src
- return 1
+ return TRUE
//set the control of the tracker to null and removes it from the previous control computer if needed
/obj/machinery/power/tracker/proc/unset_control()
@@ -44,7 +44,7 @@
if(!S)
S = new /obj/item/solar_assembly(src)
S.glass_type = /obj/item/stack/sheet/glass
- S.tracker = 1
+ S.tracker = TRUE
S.anchored = TRUE
S.forceMove(src)
update_icon()
@@ -63,7 +63,7 @@
. = TRUE
if(!I.tool_use_check(user, 0))
return
- playsound(src.loc, 'sound/machines/click.ogg', 50, 1)
+ playsound(loc, 'sound/machines/click.ogg', 50, 1)
user.visible_message("[user] begins to take the glass off the solar tracker.")
if(I.use_tool(src, user, 50, volume = I.tool_volume))
user.visible_message("[user] takes the glass off the tracker.")
@@ -76,7 +76,7 @@
stat |= BROKEN
unset_control()
-/obj/machinery/power/solar/deconstruct(disassembled = TRUE)
+/obj/machinery/power/tracker/deconstruct(disassembled = TRUE)
if(!(flags & NODECONSTRUCT))
if(disassembled)
var/obj/item/solar_assembly/S = locate() in src
@@ -85,8 +85,8 @@
S.give_glass(stat & BROKEN)
else
playsound(src, "shatter", 70, TRUE)
- new /obj/item/shard(src.loc)
- new /obj/item/shard(src.loc)
+ new /obj/item/shard(loc)
+ new /obj/item/shard(loc)
qdel(src)
// Tracker Electronic
diff --git a/code/modules/projectiles/gun.dm b/code/modules/projectiles/gun.dm
index 411a460ac62..3e41bf81271 100644
--- a/code/modules/projectiles/gun.dm
+++ b/code/modules/projectiles/gun.dm
@@ -387,10 +387,6 @@
toggle_gunlight()
visible_message("[src]'s light fades and turns off.")
-/obj/item/gun/pickup(mob/user)
- . = ..()
- if(azoom)
- azoom.Grant(user)
/obj/item/gun/dropped(mob/user)
..()
@@ -522,3 +518,27 @@
if(zoomable)
azoom = new()
azoom.gun = src
+ RegisterSignal(src, COMSIG_ITEM_EQUIPPED, .proc/ZoomGrantCheck)
+
+/**
+ * Proc which will be called when the gun receives the `COMSIG_ITEM_EQUIPPED` signal.
+ *
+ * This happens if the mob picks up the gun, or equips it to any of their slots.
+ * If the slot is anything other than either of their hands (such as the back slot), un-zoom them, and `Remove` the zoom action button from the mob.
+ * Otherwise, `Grant` the mob the zoom action button.
+ *
+ * Arguments:
+ * * source - the gun that got equipped, which is `src`.
+ * * user - the mob equipping the gun.
+ * * slot - the slot the gun is getting equipped to.
+ */
+/obj/item/gun/proc/ZoomGrantCheck(datum/source, mob/user, slot)
+ // Checks if the gun got equipped into either of the user's hands.
+ if(slot != slot_r_hand && slot != slot_l_hand)
+ // If its not in their hands, un-zoom, and remove the zoom action button.
+ zoom(user, FALSE)
+ azoom.Remove(user)
+ return FALSE
+
+ // The gun is equipped in their hands, give them the zoom ability.
+ azoom.Grant(user)
diff --git a/code/modules/projectiles/guns/energy.dm b/code/modules/projectiles/guns/energy.dm
index ce0abc8cc69..695ab02c43b 100644
--- a/code/modules/projectiles/guns/energy.dm
+++ b/code/modules/projectiles/guns/energy.dm
@@ -15,7 +15,6 @@
ammo_x_offset = 2
var/shaded_charge = 0 //if this gun uses a stateful charge bar for more detail
var/selfcharge = 0
- var/use_external_power = 0 //if set, the weapon will look for an external power source to draw from, otherwise it recharges magically
var/charge_tick = 0
var/charge_delay = 4
@@ -68,11 +67,6 @@
charge_tick = 0
if(!cell)
return // check if we actually need to recharge
- var/obj/item/ammo_casing/energy/E = ammo_type[select]
- if(use_external_power)
- var/obj/item/stock_parts/cell/external = get_external_cell()
- if(!external || !external.use(E.e_cost)) //Take power from the borg...
- return //Note, uses /10 because of shitty mods to the cell system
cell.give(100) //... to recharge the shot
on_recharge()
update_icon()
@@ -207,14 +201,3 @@
var/obj/item/ammo_casing/energy/shot = ammo_type[select] //Necessary to find cost of shot
if(R.cell.use(shot.e_cost)) //Take power from the borg...
cell.give(shot.e_cost) //... to recharge the shot
-
-/obj/item/gun/energy/proc/get_external_cell()
- if(istype(loc, /obj/item/rig_module))
- var/obj/item/rig_module/module = loc
- if(module.holder && module.holder.wearer)
- var/mob/living/carbon/human/H = module.holder.wearer
- if(istype(H) && H.back)
- var/obj/item/rig/suit = H.back
- if(istype(suit))
- return suit.cell
- return null
diff --git a/code/modules/projectiles/guns/energy/laser.dm b/code/modules/projectiles/guns/energy/laser.dm
index 3e9c882458e..9106d80ef98 100644
--- a/code/modules/projectiles/guns/energy/laser.dm
+++ b/code/modules/projectiles/guns/energy/laser.dm
@@ -95,12 +95,6 @@
..()
damage = min(damage+7, 100)
-/obj/item/gun/energy/lasercannon/mounted
- name = "mounted laser cannon"
- selfcharge = 1
- use_external_power = 1
- charge_delay = 10
-
/obj/item/gun/energy/lasercannon/cyborg
/obj/item/gun/energy/lasercannon/cyborg/newshot()
diff --git a/code/modules/projectiles/guns/energy/nuclear.dm b/code/modules/projectiles/guns/energy/nuclear.dm
index 2df2d877c53..3d9925da974 100644
--- a/code/modules/projectiles/guns/energy/nuclear.dm
+++ b/code/modules/projectiles/guns/energy/nuclear.dm
@@ -21,11 +21,6 @@
/obj/item/gun/energy/gun/cyborg/emp_act()
return
-/obj/item/gun/energy/gun/mounted
- name = "mounted energy gun"
- selfcharge = 1
- use_external_power = 1
-
/obj/item/gun/energy/gun/mini
name = "miniature energy gun"
desc = "A small, pistol-sized energy gun with a built-in flashlight. It has two settings: disable and kill."
diff --git a/code/modules/projectiles/guns/energy/special.dm b/code/modules/projectiles/guns/energy/special.dm
index e64aced32f9..da72c971130 100644
--- a/code/modules/projectiles/guns/energy/special.dm
+++ b/code/modules/projectiles/guns/energy/special.dm
@@ -112,10 +112,6 @@
max_mod_capacity = 0
empty_state = null
-/obj/item/gun/energy/kinetic_accelerator/crossbow/ninja
- name = "energy dart thrower"
- ammo_type = list(/obj/item/ammo_casing/energy/dart)
-
/obj/item/gun/energy/kinetic_accelerator/crossbow/large
name = "energy crossbow"
desc = "A reverse engineered weapon using syndicate technology."
@@ -312,6 +308,8 @@
icon_state = "esniper"
origin_tech = "combat=6;materials=5;powerstorage=4"
ammo_type = list(/obj/item/ammo_casing/energy/sniper)
+ item_state = null
+ weapon_weight = WEAPON_HEAVY
slot_flags = SLOT_BACK
w_class = WEIGHT_CLASS_BULKY
zoomable = TRUE
@@ -422,7 +420,7 @@
update_icon()
if(istype(loc, /mob/living/carbon))
- var /mob/living/carbon/M = loc
+ var/mob/living/carbon/M = loc
if(src == M.machine)
update_dat()
M << browse("Temperature Gun Configuration [dat]", "window=tempgun;size=510x102")
diff --git a/code/modules/projectiles/guns/energy/stun.dm b/code/modules/projectiles/guns/energy/stun.dm
index 70bb8be7e46..141366dd5d9 100644
--- a/code/modules/projectiles/guns/energy/stun.dm
+++ b/code/modules/projectiles/guns/energy/stun.dm
@@ -7,11 +7,6 @@
ammo_type = list(/obj/item/ammo_casing/energy/electrode)
ammo_x_offset = 3
-/obj/item/gun/energy/taser/mounted
- name = "mounted taser gun"
- selfcharge = 1
- use_external_power = 1
-
/obj/item/gun/energy/shock_revolver
name = "tesla revolver"
desc = "A high-tech revolver that fires internal, reusable shock cartridges in a revolving cylinder. The cartridges can be recharged using conventional rechargers."
diff --git a/code/modules/projectiles/guns/syringe_gun.dm b/code/modules/projectiles/guns/syringe_gun.dm
index 72c60277dec..467cd62468e 100644
--- a/code/modules/projectiles/guns/syringe_gun.dm
+++ b/code/modules/projectiles/guns/syringe_gun.dm
@@ -65,7 +65,8 @@
/obj/item/gun/syringe/attackby(obj/item/A, mob/user, params, show_msg = TRUE)
if(istype(A, /obj/item/reagent_containers/syringe))
- if(length(syringes) < max_syringes)
+ var/in_clip = length(syringes) + (chambered.BB ? 1 : 0)
+ if(in_clip < max_syringes)
if(!user.unEquip(A))
return
to_chat(user, "You load [A] into \the [src]!")
diff --git a/code/modules/projectiles/projectile.dm b/code/modules/projectiles/projectile.dm
index c10d8dec600..c33c649ae77 100644
--- a/code/modules/projectiles/projectile.dm
+++ b/code/modules/projectiles/projectile.dm
@@ -247,8 +247,8 @@
M.Turn(Angle)
transform = M
- var/Pixel_x = round(sin(Angle) + 16 * sin(Angle) * 2)
- var/Pixel_y = round(cos(Angle) + 16 * cos(Angle) * 2)
+ var/Pixel_x = round(sin(Angle) + 16 * sin(Angle) * 2, 1)
+ var/Pixel_y = round(cos(Angle) + 16 * cos(Angle) * 2, 1)
var/pixel_x_offset = pixel_x + Pixel_x
var/pixel_y_offset = pixel_y + Pixel_y
var/new_x = x
diff --git a/code/modules/projectiles/projectile/magic.dm b/code/modules/projectiles/projectile/magic.dm
index 4505d984f84..4aee2398b68 100644
--- a/code/modules/projectiles/projectile/magic.dm
+++ b/code/modules/projectiles/projectile/magic.dm
@@ -196,7 +196,7 @@
var/mob/living/silicon/robot/Robot = new_mob
Robot.mmi = new /obj/item/mmi(new_mob)
Robot.lawupdate = FALSE
- Robot.connected_ai = null
+ Robot.disconnect_from_ai()
Robot.clear_inherent_laws()
Robot.clear_zeroth_law()
if(ishuman(M))
diff --git a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm
index f2740676314..abdf0305934 100644
--- a/code/modules/reagents/chemistry/recipes/pyrotechnics.dm
+++ b/code/modules/reagents/chemistry/recipes/pyrotechnics.dm
@@ -56,7 +56,6 @@
/datum/chemical_reaction/nitroglycerin
name = "Nitroglycerin"
id = "nitroglycerin"
- result = "nitroglycerin"
required_reagents = list("glycerol" = 1, "facid" = 1, "sacid" = 1)
result_amount = 2
diff --git a/code/modules/reagents/chemistry/recipes/slime_extracts.dm b/code/modules/reagents/chemistry/recipes/slime_extracts.dm
index b1fb33edf85..1525ed42bd3 100644
--- a/code/modules/reagents/chemistry/recipes/slime_extracts.dm
+++ b/code/modules/reagents/chemistry/recipes/slime_extracts.dm
@@ -38,7 +38,7 @@
/datum/chemical_reaction/slimemonkey/on_reaction(datum/reagents/holder)
feedback_add_details("slime_cores_used","[type]")
for(var/i = 1, i <= 3, i++)
- var /obj/item/reagent_containers/food/snacks/monkeycube/M = new /obj/item/reagent_containers/food/snacks/monkeycube
+ var/obj/item/reagent_containers/food/snacks/monkeycube/M = new /obj/item/reagent_containers/food/snacks/monkeycube
M.forceMove(get_turf(holder.my_atom))
//Green
diff --git a/code/modules/reagents/reagent_containers/applicator.dm b/code/modules/reagents/reagent_containers/applicator.dm
index 73c3c3759b1..87be22d3c8f 100644
--- a/code/modules/reagents/reagent_containers/applicator.dm
+++ b/code/modules/reagents/reagent_containers/applicator.dm
@@ -5,6 +5,7 @@
icon_state = "mender"
item_state = "mender"
volume = 200
+ possible_transfer_amounts = null
resistance_flags = ACID_PROOF
container_type = REFILLABLE | AMOUNT_VISIBLE
temperature_min = 270
@@ -21,6 +22,9 @@
ignore_flags = TRUE
to_chat(user, "You short out the safeties on [src].")
+/obj/item/reagent_containers/applicator/set_APTFT()
+ set hidden = TRUE
+
/obj/item/reagent_containers/applicator/on_reagent_change()
if(!emagged)
var/found_forbidden_reagent = FALSE
@@ -93,6 +97,20 @@
playsound(get_turf(src), pick('sound/goonstation/items/mender.ogg', 'sound/goonstation/items/mender2.ogg'), 50, 1)
+/obj/item/reagent_containers/applicator/verb/empty()
+ set name = "Empty Applicator"
+ set category = "Object"
+ set src in usr
+
+ if(usr.incapacitated())
+ return
+ if(alert(usr, "Are you sure you want to empty [src]?", "Empty Applicator:", "Yes", "No") != "Yes")
+ return
+ if(!usr.incapacitated() && isturf(usr.loc) && loc == usr)
+ to_chat(usr, "You empty [src] onto the floor.")
+ reagents.reaction(usr.loc)
+ reagents.clear_reagents()
+
/obj/item/reagent_containers/applicator/brute
name = "brute auto-mender"
list_reagents = list("styptic_powder" = 200)
@@ -104,3 +122,6 @@
/obj/item/reagent_containers/applicator/dual
name = "dual auto-mender"
list_reagents = list("synthflesh" = 200)
+
+/obj/item/reagent_containers/applicator/dual/syndi // It magically goes through hardsuits. Don't ask how.
+ ignore_flags = TRUE
diff --git a/code/modules/reagents/reagent_containers/bottle.dm b/code/modules/reagents/reagent_containers/bottle.dm
index 6c836988e8b..4274c3114db 100644
--- a/code/modules/reagents/reagent_containers/bottle.dm
+++ b/code/modules/reagents/reagent_containers/bottle.dm
@@ -42,6 +42,13 @@
var/image/lid = image(icon, src, "lid_bottle")
overlays += lid
+/obj/item/reagent_containers/glass/bottle/decompile_act(obj/item/matter_decompiler/C, mob/user)
+ if(!reagents.total_volume)
+ C.stored_comms["glass"] += 3
+ qdel(src)
+ return TRUE
+ return ..()
+
/obj/item/reagent_containers/glass/bottle/toxin
name = "toxin bottle"
desc = "A small bottle containing toxic compounds."
diff --git a/code/modules/reagents/reagent_containers/glass_containers.dm b/code/modules/reagents/reagent_containers/glass_containers.dm
index 1e42899111b..175ae757df4 100644
--- a/code/modules/reagents/reagent_containers/glass_containers.dm
+++ b/code/modules/reagents/reagent_containers/glass_containers.dm
@@ -47,6 +47,9 @@
reagents.reaction(M, REAGENT_TOUCH)
reagents.clear_reagents()
else
+ if(!iscarbon(M)) // Non-carbons can't process reagents
+ to_chat(user, "You cannot find a way to feed [M].")
+ return
if(M != user)
M.visible_message("[user] attempts to feed something to [M].", \
"[user] attempts to feed something to you.")
diff --git a/code/modules/reagents/reagent_containers/syringes.dm b/code/modules/reagents/reagent_containers/syringes.dm
index 8783d8a8c19..6e0f4277bde 100644
--- a/code/modules/reagents/reagent_containers/syringes.dm
+++ b/code/modules/reagents/reagent_containers/syringes.dm
@@ -24,6 +24,9 @@
mode = SYRINGE_INJECT
update_icon()
+/obj/item/reagent_containers/syringe/set_APTFT()
+ set hidden = TRUE
+
/obj/item/reagent_containers/syringe/on_reagent_change()
update_icon()
diff --git a/code/modules/recycling/disposal.dm b/code/modules/recycling/disposal.dm
index 13d88100042..e6dd04408c2 100644
--- a/code/modules/recycling/disposal.dm
+++ b/code/modules/recycling/disposal.dm
@@ -265,7 +265,7 @@
update()
return
-/obj/machinery/disposal/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
+/obj/machinery/disposal/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = FALSE, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
if(!ui)
ui = new(user, src, ui_key, "DisposalBin", name, 300, 250, master_ui, state)
diff --git a/code/modules/research/designs/autolathe_designs.dm b/code/modules/research/designs/autolathe_designs.dm
index 1a57f2e2aee..b843b2d17a2 100644
--- a/code/modules/research/designs/autolathe_designs.dm
+++ b/code/modules/research/designs/autolathe_designs.dm
@@ -195,6 +195,14 @@
build_path = /obj/item/floor_painter
category = list("initial", "Miscellaneous")
+/datum/design/airlock_painter
+ name = "Airlock painter"
+ id = "airlock_painter"
+ build_type = AUTOLATHE
+ materials = list(MAT_METAL = 3000, MAT_GLASS = 1000)
+ build_path = /obj/item/airlock_painter
+ category = list("initial", "Miscellaneous")
+
/datum/design/metal
name = "Metal"
id = "metal"
diff --git a/code/modules/research/designs/mechfabricator_designs.dm b/code/modules/research/designs/mechfabricator_designs.dm
index 76eabe46761..a1ea27b0592 100644
--- a/code/modules/research/designs/mechfabricator_designs.dm
+++ b/code/modules/research/designs/mechfabricator_designs.dm
@@ -948,8 +948,8 @@
category = list("Exosuit Equipment")
/datum/design/mech_grenade_launcher
- name = "Exosuit Weapon (SGL-6 Grenade Launcher)"
- desc = "Allows for the construction of SGL-6 Grenade Launcher."
+ name = "Exosuit Weapon (SGL-6 Flashbang Launcher)"
+ desc = "Allows for the construction of SGL-6 Flashbang Launcher."
id = "mech_grenade_launcher"
build_type = MECHFAB
req_tech = list("combat" = 4, "engineering" = 4)
diff --git a/code/modules/security_levels/security levels.dm b/code/modules/security_levels/security levels.dm
index 00c575e53b0..71fd1750902 100644
--- a/code/modules/security_levels/security levels.dm
+++ b/code/modules/security_levels/security levels.dm
@@ -123,10 +123,6 @@ GLOBAL_DATUM_INIT(security_announcement_down, /datum/announcement/priority/secur
FA.overlays.Cut()
FA.overlays += image('icons/obj/monitors.dmi', "overlay_delta")
- if(level >= SEC_LEVEL_RED)
- GLOB.atc.reroute_traffic(yes = TRUE) // Tell them fuck off we're busy.
- else
- GLOB.atc.reroute_traffic(yes = FALSE)
SSnightshift.check_nightshift(TRUE)
else
diff --git a/code/modules/shuttle/emergency.dm b/code/modules/shuttle/emergency.dm
index 99e31ef25ed..aa0a21a165a 100644
--- a/code/modules/shuttle/emergency.dm
+++ b/code/modules/shuttle/emergency.dm
@@ -150,11 +150,6 @@
emergency_shuttle_called.Announce("The emergency shuttle has been called. [redAlert ? "Red Alert state confirmed: Dispatching priority shuttle. " : "" ]It will arrive in [timeLeft(600)] minutes.[reason][SSshuttle.emergencyLastCallLoc ? "\n\nCall signal traced. Results can be viewed on any communications console." : "" ]")
- if(reason == "Automatic Crew Transfer" && signalOrigin == null) // Best way we have to check that it's actually a crew transfer and not just a player using the same message- any other calls to this proc should have a signalOrigin.
- GLOB.atc.shift_ending()
- else // Emergency shuttle call (probably)
- GLOB.atc.reroute_traffic(yes = TRUE)
-
/obj/docking_port/mobile/emergency/cancel(area/signalOrigin)
if(!canRecall)
diff --git a/code/modules/shuttle/ert.dm b/code/modules/shuttle/ert.dm
index 32af5e429fa..a600376ed23 100644
--- a/code/modules/shuttle/ert.dm
+++ b/code/modules/shuttle/ert.dm
@@ -9,7 +9,7 @@
/obj/machinery/computer/shuttle/ert/tgui_act(action, list/params, datum/tgui/ui, datum/tgui_state/state)
if(action == "move")
var/authorized_roles = list(SPECIAL_ROLE_ERT, SPECIAL_ROLE_DEATHSQUAD)
- if(!((usr.mind.assigned_role in authorized_roles) || is_admin(usr)))
+ if(!((usr.mind?.assigned_role in authorized_roles) || is_admin(usr)))
message_admins("Potential ERT shuttle hijack, ERT shuttle moved by unauthorized user: [key_name_admin(usr)]")
..()
diff --git a/code/modules/space_management/level_traits.dm b/code/modules/space_management/level_traits.dm
index 1d88f70454f..6aa3fa802a7 100644
--- a/code/modules/space_management/level_traits.dm
+++ b/code/modules/space_management/level_traits.dm
@@ -61,3 +61,16 @@ GLOBAL_LIST_INIT(default_map_traits, MAP_TRANSITION_CONFIG)
/proc/level_name_to_num(name)
var/datum/space_level/S = GLOB.space_manager.get_zlev_by_name(name)
return S.zpos
+
+/**
+ * Proc to get a list of all the linked-together Z-Levels
+ *
+ * Returns a list of zlevel numbers which can be accessed from travelling space naturally
+ */
+/proc/get_all_linked_levels_zpos()
+ var/list/znums = list()
+ for(var/i in GLOB.space_manager.z_list)
+ var/datum/space_level/SL = GLOB.space_manager.z_list[i]
+ if(SL.linkage == CROSSLINKED)
+ znums |= SL.zpos
+ return znums
diff --git a/code/modules/surgery/organs/robolimbs.dm b/code/modules/surgery/organs/robolimbs.dm
index eb40fa40994..e69889a709b 100644
--- a/code/modules/surgery/organs/robolimbs.dm
+++ b/code/modules/surgery/organs/robolimbs.dm
@@ -3,18 +3,6 @@ GLOBAL_LIST_EMPTY(chargen_robolimbs)
GLOBAL_LIST_EMPTY(selectable_robolimbs)
GLOBAL_DATUM(basic_robolimb, /datum/robolimb)
-/proc/populate_robolimb_list()
- GLOB.basic_robolimb = new()
- for(var/limb_type in typesof(/datum/robolimb))
- var/datum/robolimb/R = new limb_type()
- GLOB.all_robolimbs[R.company] = R
- if(!R.unavailable_at_chargen)
- if(R != "head" && R != "chest" && R != "groin" ) //Part of the method that ensures only IPCs can access head, chest and groin prosthetics.
- if(R.has_subtypes) //Ensures solos get added to the list as well be incorporating has_subtypes == 1 and has_subtypes == 2.
- GLOB.chargen_robolimbs[R.company] = R //List only main brands and solo parts.
- if(R.selectable)
- GLOB.selectable_robolimbs[R.company] = R
-
/datum/robolimb
var/company = "Unbranded" // Shown when selecting the limb.
var/desc = "A generic unbranded robotic prosthesis." // Seen when examining a limb.
diff --git a/code/modules/surgery/rig_removal.dm b/code/modules/surgery/rig_removal.dm
deleted file mode 100644
index de15eacf8f3..00000000000
--- a/code/modules/surgery/rig_removal.dm
+++ /dev/null
@@ -1,59 +0,0 @@
-//Procedures in this file: Unsealing a Rig.
-
-/datum/surgery/rigsuit
- name = "Rig Unsealing"
- steps = list(/datum/surgery_step/rigsuit)
- possible_locs = list("chest")
-
-/datum/surgery/rigsuit/can_start(mob/user, mob/living/carbon/target)
- if(ishuman(target))
- var/mob/living/carbon/human/H = target
- var/obj/item/backitem = H.get_item_by_slot(slot_back)
- if(istype(backitem,/obj/item/rig)) //Check if we have a rig to operate on
- if(backitem.flags&NODROP) //Check if the rig is sealed, if not, we don't need to operate
- return 1
- return 0
-
-//Bay12 removal
-/datum/surgery_step/rigsuit
- name="Cut Seals"
- allowed_tools = list(
- /obj/item/weldingtool = 80,
- /obj/item/circular_saw = 60,
- /obj/item/gun/energy/plasmacutter = 100
- )
-
- can_infect = 0
- blood_level = 0
-
- time = 50
-
-/datum/surgery_step/hardsuit/can_use(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
- if(!istype(target))
- return 0
- if(tool.tool_behaviour == TOOL_WELDER)
- if(!tool.tool_use_check(user, 0))
- return
- if(!tool.use(1))
- return
- return (target_zone == "chest") && istype(target.back, /obj/item/rig) && (target.back.flags&NODROP)
-
-/datum/surgery_step/rigsuit/begin_step(mob/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
- user.visible_message("[user] starts cutting through the support systems of [target]'s [target.back] with \the [tool]." , \
- "You start cutting through the support systems of [target]'s [target.back] with \the [tool].")
- ..()
-
-/datum/surgery_step/rigsuit/end_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
-
- var/obj/item/rig/rig = target.back
- if(!istype(rig))
- return
- rig.reset()
- user.visible_message("[user] has cut through the support systems of [target]'s [rig] with \the [tool].", \
- "You have cut through the support systems of [target]'s [rig] with \the [tool].")
- return 1
-
-/datum/surgery_step/rigsuit/fail_step(mob/living/user, mob/living/carbon/human/target, target_zone, obj/item/tool)
- user.visible_message("[user]'s [tool] can't quite seem to get through the metal...", \
- "Your [tool] can't quite seem to get through the metal. It's weakening, though - try again.")
- return 0
diff --git a/code/modules/surgery/surgery.dm b/code/modules/surgery/surgery.dm
index 0b13d18f9da..294e98d38d0 100644
--- a/code/modules/surgery/surgery.dm
+++ b/code/modules/surgery/surgery.dm
@@ -111,7 +111,7 @@
prob_chance *= get_location_modifier(target)
- if(!ispath(surgery.steps[surgery.status], /datum/surgery_step/robotics) && !ispath(surgery.steps[surgery.status], /datum/surgery_step/rigsuit))//Repairing robotic limbs doesn't hurt, and neither does cutting someone out of a rig
+ if(!ispath(surgery.steps[surgery.status], /datum/surgery_step/robotics))//Repairing robotic limbs doesn't hurt, and neither does cutting someone out of a rig
if(ishuman(target))
var/mob/living/carbon/human/H = target //typecast to human
prob_chance *= get_pain_modifier(H)//operating on conscious people is hard.
@@ -196,7 +196,7 @@
if(AStar(E.loc, M.loc, /turf/proc/Distance, 2, simulated_only = 0))
germs++
- if(tool.blood_DNA && tool.blood_DNA.len) //germs from blood-stained tools
+ if(tool && tool.blood_DNA && tool.blood_DNA.len) //germs from blood-stained tools
germs += 30
if(E.internal_organs.len)
diff --git a/code/modules/tgui/modules/crew_monitor.dm b/code/modules/tgui/modules/crew_monitor.dm
index 783498542e4..f1da4ed89ba 100644
--- a/code/modules/tgui/modules/crew_monitor.dm
+++ b/code/modules/tgui/modules/crew_monitor.dm
@@ -14,13 +14,13 @@
if("track")
if(isAI(usr))
var/mob/living/silicon/ai/AI = usr
- var/mob/living/carbon/human/H = locate(params["track"]) in GLOB.mob_list
+ var/mob/living/carbon/human/H = locate(params["track"]) in GLOB.human_list
if(hassensorlevel(H, SUIT_SENSOR_TRACKING))
AI.ai_actual_track(H)
return TRUE
-/datum/tgui_module/crew_monitor/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
+/datum/tgui_module/crew_monitor/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = FALSE, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
if(!ui)
// The 557 may seem random, but its the perfectsize for margins on the nanomap
diff --git a/code/modules/unit_tests/_unit_tests.dm b/code/modules/unit_tests/_unit_tests.dm
index 5b1409af4e7..80467d19846 100644
--- a/code/modules/unit_tests/_unit_tests.dm
+++ b/code/modules/unit_tests/_unit_tests.dm
@@ -3,6 +3,7 @@
#ifdef UNIT_TESTS
#include "component_tests.dm"
+#include "map_templates.dm"
#include "reagent_id_typos.dm"
#include "spawn_humans.dm"
#include "sql.dm"
diff --git a/code/modules/unit_tests/map_templates.dm b/code/modules/unit_tests/map_templates.dm
new file mode 100644
index 00000000000..b590526a46b
--- /dev/null
+++ b/code/modules/unit_tests/map_templates.dm
@@ -0,0 +1,7 @@
+/datum/unit_test/map_templates/Run()
+ var/list/datum/map_template/templates = subtypesof(/datum/map_template)
+ for(var/I in templates)
+ var/datum/map_template/MT = new I // The new is important here to ensure stuff gets set properly
+ // Check if it even has a path and if so, does it exist
+ if(MT.mappath && !fexists(MT.mappath))
+ Fail("The map file for [MT.type] does not exist!")
diff --git a/config/example/config.txt b/config/example/config.txt
index 5934ea733b5..3a56570a03d 100644
--- a/config/example/config.txt
+++ b/config/example/config.txt
@@ -277,9 +277,6 @@ TICKLAG 0.5
## Whether the server will talk to other processes through socket_talk
SOCKET_TALK 0
-## Uncomment this to ban use of ToR
-#TOR_BAN
-
## Comment this out to disable automuting
#AUTOMUTE_ON
diff --git a/config/names/dreams.txt b/config/names/dreams.txt
index 89f559dae88..4bd2c2b984e 100644
--- a/config/names/dreams.txt
+++ b/config/names/dreams.txt
@@ -105,7 +105,7 @@ a grey
a kidan
a diona
a drask
-the ai core
+the AI core
the mining station
the research station
a beaker of strange liquid
diff --git a/config/names/nightmares.txt b/config/names/nightmares.txt
index 71df2e90cff..022a0494edd 100644
--- a/config/names/nightmares.txt
+++ b/config/names/nightmares.txt
@@ -10,7 +10,7 @@ a dead grey
a dead kidan
a dead diona
a dead drask
-the malf ai core
+the malf AI core
bLoOd
has been called
a horrible sense of dread comes over you
diff --git a/goon/browserassets/js/browserOutput.js b/goon/browserassets/js/browserOutput.js
index 40a69245188..3cac81ca8e2 100644
--- a/goon/browserassets/js/browserOutput.js
+++ b/goon/browserassets/js/browserOutput.js
@@ -166,30 +166,79 @@ function emojiparse(el) {
}
}
-// Colorizes the highlight spans
-function setHighlightColor(match) {
- match.style.background = opts.highlightColor
+// Recolorizes the highlight spans
+function setHighlightColor() {
+ var highlightspans = document.getElementsByClassName("highlight")
+ for(var i in highlightspans){
+ highlightspans[i].setAttribute("style","background-color:"+opts.highlightColor)
+ }
+}
+
+function escapeRegexCharacters(input){ //escapes any characters that could be interpreted as regex patterns, potentially causing patterns to break if not escaped
+ return input.replace(/[.*+?^${}()|[\]\\]/g, '\\$&');
}
//Highlights words based on user settings
function highlightTerms(el) {
- if(regexHasError) return; //just stop right there ig the regex is gonna except
+
+ if (regexHasError) return; //just stop right there ig the regex is gonna except
+
+ function highlightRecursor(element, term){ //recursor function to do the highlighting proper
+ var regex = new RegExp(term, "gi");
+
+ function replace(str) {
+ return str.replace(regex, '$&');
+ }
+
+ var s = '';
+ var work = element.innerHTML;
+ var ind = 0;
+
+ while(ind < work.length) {
+
+ var next_term = work.substring(ind).search(regex);
+ if(next_term != -1) next_term += ind;
+ var next_tag = work.indexOf('<', ind);
+ if(next_tag == -1) {
+ s+=replace(work.substring(ind));
+ break;
+ }
+ else if(next_term==-1) {
+ s += work.substring(ind);
+ break;
+ }
+ else if(next_tag < next_term) {
+ var temp = work.indexOf('>', next_tag);
+ s += work.substring(ind,temp+1);
+ ind = temp+1;
+ }
+ else {
+ s += replace(work.substring(ind, next_tag));
+ ind = next_tag;
+ }
+ }
+
+ element.innerHTML = s;
+ }
+
for (var i = 0; i < opts.highlightTerms.length; i++) { //Each highlight term
if(opts.highlightTerms[i]) {
if(!opts.highlightRegexEnable){
- if(el.innerText.toString().toLowerCase().includes(opts.highlightTerms[i].toLowerCase())) //match normally
- el.innerHTML = ''+el.innerHTML+'' //encloseincludes
- continue;
+ var innerTerms = opts.highlightTerms[i].split(" ")
+ for(var a in innerTerms){
+ highlightRecursor(el, escapeRegexCharacters(innerTerms[a]))
+ }
}
- var rexp;
- try{
- rexp = new RegExp(opts.highlightTerms[i],"gmi")
- } catch(e){
- el.innerHTML+=' Your highlight regex - '+opts.highlightTerms[i]+' - is malformed. Thrown exception: '+e+''
- regexHasError = true;
- return;
+ else {
+ try{
+ new RegExp(opts.highlightTerms[i], "gmi"); // check to make sure the pattern wont cause issues
+ } catch(e){
+ el.innerHTML += ' Your highlight regex pattern -- ' + opts.highlightTerms[i] + ' -- is malformed. Your highlights have been disabled until they are next edited Thrown exception: '+e+'';
+ regexHasError = true;
+ return;
+ }
+ highlightRecursor(el, opts.highlightTerms[i]);
}
- el.innerHTML = el.innerHTML.replace(rexp,"$0") //i cant figure out a proper, non snowflakey way to let people select the group that gets highlighted
}
}
}
@@ -1043,15 +1092,21 @@ $(function() {
count++;
}
- var color = $('#highlightColor').val();
opts.highlightRegexEnable = document.querySelector("#highlightRegexEnable").checked
- color = color.trim();
- if (color == '' || color.charAt(0) != '#') {
- opts.highlightColor = '#FFFF00';
- } else {
- opts.highlightColor = color;
+
+ var color = $('#highlightColor').val();
+ if(color != opts.highlightColor) { // did the color even change?
+ color = color.trim();
+ if (color == '' || color.charAt(0) != '#') {
+ opts.highlightColor = '#FFFF00';
+ } else {
+ opts.highlightColor = color;
+ }
+ setHighlightColor();
}
+
regexHasError = false; //they changed the regex so it might be valid now
+ internalOutput('Highlights have been updated.',"internal") // simplest way to test if pattern works, why reinvent the wheel?
var $popup = $('#highlightPopup').closest('.popup');
$popup.remove();
diff --git a/icons/effects/lasers2.dmi b/icons/effects/lasers2.dmi
deleted file mode 100644
index f774fb9430b..00000000000
Binary files a/icons/effects/lasers2.dmi and /dev/null differ
diff --git a/icons/mob/actions/actions.dmi b/icons/mob/actions/actions.dmi
index 4ea648dea13..80a5dbe5b04 100644
Binary files a/icons/mob/actions/actions.dmi and b/icons/mob/actions/actions.dmi differ
diff --git a/icons/mob/feet.dmi b/icons/mob/feet.dmi
index e6f132a73a5..3892442c6ea 100644
Binary files a/icons/mob/feet.dmi and b/icons/mob/feet.dmi differ
diff --git a/icons/mob/hands.dmi b/icons/mob/hands.dmi
index 6d6165509c8..66d1474d61a 100644
Binary files a/icons/mob/hands.dmi and b/icons/mob/hands.dmi differ
diff --git a/icons/mob/head.dmi b/icons/mob/head.dmi
index 88b28aff5a9..5200ad72e5a 100644
Binary files a/icons/mob/head.dmi and b/icons/mob/head.dmi differ
diff --git a/icons/mob/hud.dmi b/icons/mob/hud.dmi
index df6b8f4de1f..92006f54cc2 100644
Binary files a/icons/mob/hud.dmi and b/icons/mob/hud.dmi differ
diff --git a/icons/mob/human_face.dmi b/icons/mob/human_face.dmi
index ff471760fe8..9b6d9468b9d 100644
Binary files a/icons/mob/human_face.dmi and b/icons/mob/human_face.dmi differ
diff --git a/icons/mob/inhands/guns_lefthand.dmi b/icons/mob/inhands/guns_lefthand.dmi
index a0a6b7b3f39..940731f6e73 100644
Binary files a/icons/mob/inhands/guns_lefthand.dmi and b/icons/mob/inhands/guns_lefthand.dmi differ
diff --git a/icons/mob/inhands/guns_righthand.dmi b/icons/mob/inhands/guns_righthand.dmi
index 545318bbed5..3ad61ad5794 100644
Binary files a/icons/mob/inhands/guns_righthand.dmi and b/icons/mob/inhands/guns_righthand.dmi differ
diff --git a/icons/mob/inhands/items_lefthand.dmi b/icons/mob/inhands/items_lefthand.dmi
index fb8efeadfb1..a378d2e5b04 100644
Binary files a/icons/mob/inhands/items_lefthand.dmi and b/icons/mob/inhands/items_lefthand.dmi differ
diff --git a/icons/mob/inhands/items_righthand.dmi b/icons/mob/inhands/items_righthand.dmi
index e11fd688338..0a8847d7e4a 100644
Binary files a/icons/mob/inhands/items_righthand.dmi and b/icons/mob/inhands/items_righthand.dmi differ
diff --git a/icons/mob/rig_back.dmi b/icons/mob/rig_back.dmi
deleted file mode 100644
index 923939d323e..00000000000
Binary files a/icons/mob/rig_back.dmi and /dev/null differ
diff --git a/icons/mob/rig_modules.dmi b/icons/mob/rig_modules.dmi
deleted file mode 100644
index 3d18b5435ce..00000000000
Binary files a/icons/mob/rig_modules.dmi and /dev/null differ
diff --git a/icons/mob/species/skrell/helmet.dmi b/icons/mob/species/skrell/helmet.dmi
index e17fa4174c5..ef05daf5115 100644
Binary files a/icons/mob/species/skrell/helmet.dmi and b/icons/mob/species/skrell/helmet.dmi differ
diff --git a/icons/mob/species/tajaran/helmet.dmi b/icons/mob/species/tajaran/helmet.dmi
index 298ff823ea4..00c3f1d2bdc 100644
Binary files a/icons/mob/species/tajaran/helmet.dmi and b/icons/mob/species/tajaran/helmet.dmi differ
diff --git a/icons/mob/species/tajaran/suit.dmi b/icons/mob/species/tajaran/suit.dmi
index 2f7d8f34907..61929dcceda 100644
Binary files a/icons/mob/species/tajaran/suit.dmi and b/icons/mob/species/tajaran/suit.dmi differ
diff --git a/icons/mob/species/unathi/helmet.dmi b/icons/mob/species/unathi/helmet.dmi
index 1fc21dd1611..68f6171bb19 100644
Binary files a/icons/mob/species/unathi/helmet.dmi and b/icons/mob/species/unathi/helmet.dmi differ
diff --git a/icons/mob/species/unathi/suit.dmi b/icons/mob/species/unathi/suit.dmi
index 14d1eaaa73a..eabd0f94672 100644
Binary files a/icons/mob/species/unathi/suit.dmi and b/icons/mob/species/unathi/suit.dmi differ
diff --git a/icons/mob/suit.dmi b/icons/mob/suit.dmi
index d71fb9b1d21..52a619508be 100644
Binary files a/icons/mob/suit.dmi and b/icons/mob/suit.dmi differ
diff --git a/icons/obj/clothing/gloves.dmi b/icons/obj/clothing/gloves.dmi
index f7f54357fdb..06bb96f43a5 100644
Binary files a/icons/obj/clothing/gloves.dmi and b/icons/obj/clothing/gloves.dmi differ
diff --git a/icons/obj/clothing/hats.dmi b/icons/obj/clothing/hats.dmi
index f942f9fd8cd..c9ebceba369 100644
Binary files a/icons/obj/clothing/hats.dmi and b/icons/obj/clothing/hats.dmi differ
diff --git a/icons/obj/clothing/shoes.dmi b/icons/obj/clothing/shoes.dmi
index 30cdfae56ef..aae2d9df6fb 100644
Binary files a/icons/obj/clothing/shoes.dmi and b/icons/obj/clothing/shoes.dmi differ
diff --git a/icons/obj/clothing/suits.dmi b/icons/obj/clothing/suits.dmi
index 7400d5d63ef..6d116a6b02e 100644
Binary files a/icons/obj/clothing/suits.dmi and b/icons/obj/clothing/suits.dmi differ
diff --git a/icons/obj/decorations.dmi b/icons/obj/decorations.dmi
index 8bbfa2e3592..79acc379c39 100644
Binary files a/icons/obj/decorations.dmi and b/icons/obj/decorations.dmi differ
diff --git a/icons/obj/device.dmi b/icons/obj/device.dmi
index b5c25d474d1..75838e00075 100644
Binary files a/icons/obj/device.dmi and b/icons/obj/device.dmi differ
diff --git a/icons/obj/items.dmi b/icons/obj/items.dmi
index bc7e927aab2..a82f3fa10a2 100644
Binary files a/icons/obj/items.dmi and b/icons/obj/items.dmi differ
diff --git a/icons/obj/rig_modules.dmi b/icons/obj/rig_modules.dmi
deleted file mode 100644
index 90b1873d58e..00000000000
Binary files a/icons/obj/rig_modules.dmi and /dev/null differ
diff --git a/icons/obj/statue.dmi b/icons/obj/statue.dmi
index bcaddb9f34f..2d9ca959b1b 100644
Binary files a/icons/obj/statue.dmi and b/icons/obj/statue.dmi differ
diff --git a/nano/images/Cyberiad_nanomap_z1.png b/nano/images/Cyberiad_nanomap_z1.png
index ff8c0bf01fe..126f9021dac 100644
Binary files a/nano/images/Cyberiad_nanomap_z1.png and b/nano/images/Cyberiad_nanomap_z1.png differ
diff --git a/nano/images/Delta_nanomap_z1.png b/nano/images/Delta_nanomap_z1.png
index 42499592f85..f0f4e31bca3 100644
Binary files a/nano/images/Delta_nanomap_z1.png and b/nano/images/Delta_nanomap_z1.png differ
diff --git a/nano/images/MetaStation_nanomap_z1.png b/nano/images/MetaStation_nanomap_z1.png
index 57bdbda01f9..280e28a2bc3 100644
Binary files a/nano/images/MetaStation_nanomap_z1.png and b/nano/images/MetaStation_nanomap_z1.png differ
diff --git a/nano/layouts/layout_default.tmpl b/nano/layouts/layout_default.tmpl
index 2c0953fc0a9..d3a86461a76 100644
--- a/nano/layouts/layout_default.tmpl
+++ b/nano/layouts/layout_default.tmpl
@@ -21,10 +21,10 @@
{{:helper.link('Hide Map', 'close', {'showMap' : 0})}}
Zoom Level:
- x1.0
- x1.5
- x2.0
- x2.5
+ x1
+ x2
+ x4
+ x8
@@ -44,4 +44,4 @@
\ No newline at end of file
+
diff --git a/nano/layouts/layout_program.tmpl b/nano/layouts/layout_program.tmpl
index eb0ac27c8bf..4d1dc615fc9 100644
--- a/nano/layouts/layout_program.tmpl
+++ b/nano/layouts/layout_program.tmpl
@@ -58,10 +58,10 @@
{{:helper.link('Hide Map', 'close', {'showMap' : 0})}}
Zoom Level:
- x1.0
- x1.5
- x2.0
- x2.5
+ x1
+ x2
+ x4
+ x8
@@ -82,4 +82,4 @@
\ No newline at end of file
+
diff --git a/nano/package-lock.json b/nano/package-lock.json
index b96939c5d9a..14642f304d6 100644
--- a/nano/package-lock.json
+++ b/nano/package-lock.json
@@ -1728,9 +1728,9 @@
"dev": true
},
"elliptic": {
- "version": "6.5.2",
- "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.2.tgz",
- "integrity": "sha512-f4x70okzZbIQl/NSRLkI/+tteV/9WqL98zx+SQ69KbXxmVrmjwsNUPn/gYJJ0sHvEak24cZgHIPegRePAtA/xw==",
+ "version": "6.5.3",
+ "resolved": "https://registry.npmjs.org/elliptic/-/elliptic-6.5.3.tgz",
+ "integrity": "sha512-IMqzv5wNQf+E6aHeIqATs0tOLeOTwj1QKbRcS3jBbYkl5oLAserA8yJTT7/VyHUYG91PRmPyeQDObKLPpeS4dw==",
"requires": {
"bn.js": "^4.4.0",
"brorand": "^1.0.1",
diff --git a/nano/templates/atmos_control_map_header.tmpl b/nano/templates/atmos_control_map_header.tmpl
index 9a741a249e5..c64fce951f7 100644
--- a/nano/templates/atmos_control_map_header.tmpl
+++ b/nano/templates/atmos_control_map_header.tmpl
@@ -1,8 +1,8 @@
{{:helper.link('Show Detail List', 'file-text', {'showMap' : 0})}}
Zoom Level:
- x1.0
- x1.5
- x2.0
- x2.5
-
\ No newline at end of file
+ x1
+ x2
+ x4
+ x8
+
diff --git a/nano/templates/comm_console.tmpl b/nano/templates/comm_console.tmpl
index e7224df2ecc..2c36a011ac6 100644
--- a/nano/templates/comm_console.tmpl
+++ b/nano/templates/comm_console.tmpl
@@ -71,13 +71,6 @@ Used In File(s): /code/game/machinery/computers/communications.dm
{{:helper.link('Restart Nano-Mob Hunter GO! Server','power-off',{'operation':'RestartNanoMob'})}}
-
- {{if data.atcSquelched}}
- {{:helper.link('Enable ATC Relay', 'signal', {'operation': 'ToggleATC'})}}
- {{else}}
- {{:helper.link('Disable ATC Relay', 'signal', {'operation': 'ToggleATC'})}}
- {{/if}}
-
{{else data.screen==2}}
diff --git a/nano/templates/sec_camera_map_header.tmpl b/nano/templates/sec_camera_map_header.tmpl
index 8052673efe1..ebe90da3015 100644
--- a/nano/templates/sec_camera_map_header.tmpl
+++ b/nano/templates/sec_camera_map_header.tmpl
@@ -16,8 +16,8 @@ Used In File(s): \code\game\machinery\computer\camera.dm
Zoom Level:
- x1.0
- x1.5
- x2.0
- x2.5
-
\ No newline at end of file
+ x1
+ x2
+ x4
+ x8
+
diff --git a/paradise.dme b/paradise.dme
index 694cf92448b..9dc2f733200 100644
--- a/paradise.dme
+++ b/paradise.dme
@@ -87,6 +87,7 @@
#include "code\__HELPERS\files.dm"
#include "code\__HELPERS\game.dm"
#include "code\__HELPERS\global_lists.dm"
+#include "code\__HELPERS\heap.dm"
#include "code\__HELPERS\icon_smoothing.dm"
#include "code\__HELPERS\icons.dm"
#include "code\__HELPERS\lists.dm"
@@ -108,8 +109,6 @@
#include "code\__HELPERS\sorts\InsertSort.dm"
#include "code\__HELPERS\sorts\MergeSort.dm"
#include "code\__HELPERS\sorts\TimSort.dm"
-#include "code\_DATASTRUCTURES\heap.dm"
-#include "code\_DATASTRUCTURES\stacks.dm"
#include "code\_globalvars\configuration.dm"
#include "code\_globalvars\game_modes.dm"
#include "code\_globalvars\genetics.dm"
@@ -136,7 +135,6 @@
#include "code\_onclick\observer.dm"
#include "code\_onclick\other_mobs.dm"
#include "code\_onclick\overmind.dm"
-#include "code\_onclick\rig.dm"
#include "code\_onclick\telekinesis.dm"
#include "code\_onclick\hud\_defines.dm"
#include "code\_onclick\hud\action_button.dm"
@@ -207,8 +205,6 @@
#include "code\controllers\controller.dm"
#include "code\controllers\failsafe.dm"
#include "code\controllers\globals.dm"
-#include "code\controllers\hooks-defs.dm"
-#include "code\controllers\hooks.dm"
#include "code\controllers\master.dm"
#include "code\controllers\subsystem.dm"
#include "code\controllers\verbs.dm"
@@ -220,7 +216,6 @@
#include "code\controllers\subsystem\atoms.dm"
#include "code\controllers\subsystem\changelog.dm"
#include "code\controllers\subsystem\chat.dm"
-#include "code\controllers\subsystem\dcs.dm"
#include "code\controllers\subsystem\events.dm"
#include "code\controllers\subsystem\fires.dm"
#include "code\controllers\subsystem\garbage.dm"
@@ -250,8 +245,10 @@
#include "code\controllers\subsystem\throwing.dm"
#include "code\controllers\subsystem\ticker.dm"
#include "code\controllers\subsystem\timer.dm"
+#include "code\controllers\subsystem\titlescreen.dm"
#include "code\controllers\subsystem\vote.dm"
#include "code\controllers\subsystem\weather.dm"
+#include "code\controllers\subsystem\processing\dcs.dm"
#include "code\controllers\subsystem\processing\fastprocess.dm"
#include "code\controllers\subsystem\processing\obj.dm"
#include "code\controllers\subsystem\processing\processing.dm"
@@ -612,7 +609,6 @@
#include "code\game\jobs\access.dm"
#include "code\game\jobs\job_exp.dm"
#include "code\game\jobs\job_objective.dm"
-#include "code\game\jobs\job_scaling.dm"
#include "code\game\jobs\jobs.dm"
#include "code\game\jobs\whitelist.dm"
#include "code\game\jobs\job\central.dm"
@@ -686,7 +682,6 @@
#include "code\game\machinery\syndicatebomb.dm"
#include "code\game\machinery\teleporter.dm"
#include "code\game\machinery\transformer.dm"
-#include "code\game\machinery\turntable.dm"
#include "code\game\machinery\turret_control.dm"
#include "code\game\machinery\vending.dm"
#include "code\game\machinery\washing_machine.dm"
@@ -872,6 +867,7 @@
#include "code\game\objects\items\toys.dm"
#include "code\game\objects\items\trash.dm"
#include "code\game\objects\items\devices\aicard.dm"
+#include "code\game\objects\items\devices\airlock_painter.dm"
#include "code\game\objects\items\devices\autopsy.dm"
#include "code\game\objects\items\devices\camera_bug.dm"
#include "code\game\objects\items\devices\chameleonproj.dm"
@@ -1198,7 +1194,6 @@
#include "code\modules\admin\sql_notes.dm"
#include "code\modules\admin\stickyban.dm"
#include "code\modules\admin\topic.dm"
-#include "code\modules\admin\ToRban.dm"
#include "code\modules\admin\watchlist.dm"
#include "code\modules\admin\DB ban\functions.dm"
#include "code\modules\admin\permissionverbs\permissionedit.dm"
@@ -1330,9 +1325,6 @@
#include "code\modules\buildmode\submodes\save.dm"
#include "code\modules\buildmode\submodes\throwing.dm"
#include "code\modules\buildmode\submodes\variable_edit.dm"
-#include "code\modules\busy_space\air_traffic.dm"
-#include "code\modules\busy_space\loremaster.dm"
-#include "code\modules\busy_space\organizations.dm"
#include "code\modules\client\asset_cache.dm"
#include "code\modules\client\client defines.dm"
#include "code\modules\client\client procs.dm"
@@ -1382,7 +1374,6 @@
#include "code\modules\clothing\shoes\magboots.dm"
#include "code\modules\clothing\shoes\miscellaneous.dm"
#include "code\modules\clothing\spacesuits\alien.dm"
-#include "code\modules\clothing\spacesuits\breaches.dm"
#include "code\modules\clothing\spacesuits\chronosuit.dm"
#include "code\modules\clothing\spacesuits\ert.dm"
#include "code\modules\clothing\spacesuits\hardsuit.dm"
@@ -1390,24 +1381,6 @@
#include "code\modules\clothing\spacesuits\plasmamen.dm"
#include "code\modules\clothing\spacesuits\syndi.dm"
#include "code\modules\clothing\spacesuits\void.dm"
-#include "code\modules\clothing\spacesuits\rig\rig.dm"
-#include "code\modules\clothing\spacesuits\rig\rig_armormod.dm"
-#include "code\modules\clothing\spacesuits\rig\rig_attackby.dm"
-#include "code\modules\clothing\spacesuits\rig\rig_pieces.dm"
-#include "code\modules\clothing\spacesuits\rig\rig_verbs.dm"
-#include "code\modules\clothing\spacesuits\rig\rig_wiring.dm"
-#include "code\modules\clothing\spacesuits\rig\modules\combat.dm"
-#include "code\modules\clothing\spacesuits\rig\modules\computer.dm"
-#include "code\modules\clothing\spacesuits\rig\modules\modules.dm"
-#include "code\modules\clothing\spacesuits\rig\modules\ninja.dm"
-#include "code\modules\clothing\spacesuits\rig\modules\utility.dm"
-#include "code\modules\clothing\spacesuits\rig\modules\vision.dm"
-#include "code\modules\clothing\spacesuits\rig\suits\alien.dm"
-#include "code\modules\clothing\spacesuits\rig\suits\combat.dm"
-#include "code\modules\clothing\spacesuits\rig\suits\ert_suits.dm"
-#include "code\modules\clothing\spacesuits\rig\suits\light.dm"
-#include "code\modules\clothing\spacesuits\rig\suits\merc.dm"
-#include "code\modules\clothing\spacesuits\rig\suits\station.dm"
#include "code\modules\clothing\suits\alien.dm"
#include "code\modules\clothing\suits\armor.dm"
#include "code\modules\clothing\suits\bio.dm"
@@ -1527,7 +1500,6 @@
#include "code\modules\examine\descriptions\weapons.dm"
#include "code\modules\ext_scripts\irc.dm"
#include "code\modules\ext_scripts\python.dm"
-#include "code\modules\fancytitle\fancytitle.dm"
#include "code\modules\fish\fish_eggs.dm"
#include "code\modules\fish\fish_items.dm"
#include "code\modules\fish\fish_types.dm"
@@ -2119,7 +2091,6 @@
#include "code\modules\modular_computers\NTNet\NTNet_relay.dm"
#include "code\modules\modular_computers\NTNet\NTNRC\conversation.dm"
#include "code\modules\nano\nanoexternal.dm"
-#include "code\modules\nano\nanomapgen.dm"
#include "code\modules\nano\nanoui.dm"
#include "code\modules\nano\subsystem.dm"
#include "code\modules\nano\interaction\admin.dm"
@@ -2420,7 +2391,6 @@
#include "code\modules\surgery\other.dm"
#include "code\modules\surgery\plastic_surgery.dm"
#include "code\modules\surgery\remove_embedded_object.dm"
-#include "code\modules\surgery\rig_removal.dm"
#include "code\modules\surgery\robotics.dm"
#include "code\modules\surgery\surgery.dm"
#include "code\modules\surgery\tools.dm"
diff --git a/sound/turntable/testloop.ogg b/sound/turntable/testloop.ogg
deleted file mode 100644
index 453ad568fa2..00000000000
Binary files a/sound/turntable/testloop.ogg and /dev/null differ
diff --git a/sound/turntable/testloop1.ogg b/sound/turntable/testloop1.ogg
deleted file mode 100644
index 5e1210bfd06..00000000000
Binary files a/sound/turntable/testloop1.ogg and /dev/null differ
diff --git a/sound/turntable/testloop2.ogg b/sound/turntable/testloop2.ogg
deleted file mode 100644
index 5feaa762936..00000000000
Binary files a/sound/turntable/testloop2.ogg and /dev/null differ
diff --git a/sound/turntable/testloop3.ogg b/sound/turntable/testloop3.ogg
deleted file mode 100644
index 9ac0e02b773..00000000000
Binary files a/sound/turntable/testloop3.ogg and /dev/null differ
diff --git a/tgui/docs/tutorial-and-examples.md b/tgui/docs/tutorial-and-examples.md
index 08bb6f92321..590ea0f0ee7 100644
--- a/tgui/docs/tutorial-and-examples.md
+++ b/tgui/docs/tutorial-and-examples.md
@@ -37,7 +37,7 @@ powerful interactions for embedded objects or remote access.
Let's start with a very basic hello world.
```dm
-/obj/machinery/my_machine/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
+/obj/machinery/my_machine/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = FALSE, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state)
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
if(!ui)
ui = new(user, src, ui_key, "my_machine", name, 300, 300, master_ui, state)
@@ -240,7 +240,7 @@ and builds a new array based on what was returned by that function.
```
If you need more examples of what you can do with React, see the
-[interface conversion guide](docs/converting-old-tgui-interfaces.md).
+[interface conversion guide](docs/converting-old-nano-interfaces.md).
#### Splitting UIs into smaller, modular components
@@ -294,7 +294,7 @@ here's what you need (note that you'll probably be forced to clean your shit up
upon code review):
```dm
-/obj/copypasta/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state) // Remember to use the appropriate state.
+/obj/copypasta/tgui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = FALSE, datum/tgui/master_ui = null, datum/tgui_state/state = GLOB.tgui_default_state) // Remember to use the appropriate state.
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
if(!ui)
ui = new(user, src, ui_key, "copypasta", name, 300, 300, master_ui, state)
diff --git a/tgui/yarn.lock b/tgui/yarn.lock
index 905d2871b69..84cab5eb253 100644
--- a/tgui/yarn.lock
+++ b/tgui/yarn.lock
@@ -1241,9 +1241,9 @@ bluebird@^3.5.5:
integrity sha512-XpNj6GDQzdfW+r2Wnn7xiSAd7TM3jzkxGXBGTtWKuSXv1xUV+azxAm8jdWZN06QTQk+2N2XB9jRDkvbmQmcRtg==
bn.js@^4.0.0, bn.js@^4.1.0, bn.js@^4.1.1, bn.js@^4.4.0:
- version "4.11.8"
- resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.8.tgz#2cde09eb5ee341f484746bb0309b3253b1b1442f"
- integrity sha512-ItfYfPLkWHUjckQCk8xC+LwxgK8NYcXywGigJgSwOP8Y2iyWT4f2vsZnoOXTTbo+o5yXmIUJ4gn5538SO5S3gA==
+ version "4.11.9"
+ resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.9.tgz#26d556829458f9d1e81fc48952493d0ba3507828"
+ integrity sha512-E6QoYqCKZfgatHTdHzs1RRKP7ip4vvm+EyRUeE2RF0NblwVvb0p6jSVeNTOFxPn26QXN2o6SMfNxKp6kU8zQaw==
body-parser@1.19.0:
version "1.19.0"
@@ -2198,9 +2198,9 @@ electron-to-chromium@^1.3.390:
integrity sha512-DbCBdwtARI0l3e3m6ZIxVaTNahb6dSsmGjuag/twiVcWuM4MSpL5IfsJsJSyqLqxosE/m0CXlZaBmxegQW/dAg==
elliptic@^6.0.0:
- version "6.5.2"
- resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.2.tgz#05c5678d7173c049d8ca433552224a495d0e3762"
- integrity sha512-f4x70okzZbIQl/NSRLkI/+tteV/9WqL98zx+SQ69KbXxmVrmjwsNUPn/gYJJ0sHvEak24cZgHIPegRePAtA/xw==
+ version "6.5.3"
+ resolved "https://registry.yarnpkg.com/elliptic/-/elliptic-6.5.3.tgz#cb59eb2efdaf73a0bd78ccd7015a62ad6e0f93d6"
+ integrity sha512-IMqzv5wNQf+E6aHeIqATs0tOLeOTwj1QKbRcS3jBbYkl5oLAserA8yJTT7/VyHUYG91PRmPyeQDObKLPpeS4dw==
dependencies:
bn.js "^4.4.0"
brorand "^1.0.1"
@@ -3730,9 +3730,9 @@ lodash.uniq@^4.5.0:
integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M=
lodash@^4.17.13, lodash@^4.17.14, lodash@^4.17.15, lodash@^4.17.5:
- version "4.17.15"
- resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.15.tgz#b447f6670a0455bbfeedd11392eff330ea097548"
- integrity sha512-8xOcRHvCjnocdS5cpwXQXVzmmh5e5+saE2QGoeQmbKmRS6J3VQppPOIt0MnmE+4xlZoumy0GPG0D0MVIQbNA1A==
+ version "4.17.19"
+ resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.19.tgz#e48ddedbe30b3321783c5b4301fbd353bc1e4a4b"
+ integrity sha512-JNvd8XER9GQX0v2qJgsaN/mzFCNA5BRe/j8JN9d+tWyGLSodKQHKFicdwNYzWwI3wjRnaKPsGj1XkBjx/F96DQ==
loose-envify@^1.0.0, loose-envify@^1.4.0:
version "1.4.0"
diff --git a/tools/github-actions/README.MD b/tools/github-actions/README.MD
new file mode 100644
index 00000000000..74b31f5bdd6
--- /dev/null
+++ b/tools/github-actions/README.MD
@@ -0,0 +1,6 @@
+# GitHub Actions Scripts
+
+This folder contains all the script and tools required for GitHub actions. If you add something to this directory, **PLEASE** document it in here
+
+- `nanomap-renderer` - A linux application to render NanoMap images of the ingame maps automatically. Based off of SpacemanDMM (Modified source [here](https://github.com/AffectedArc07/ParaSpacemanDMM), original source [here](https://github.com/Spacemaniac/SpacemanDMM))
+- `nanomap-renderer-invoker.sh` - A script which invokes the render tool and clones the maps to the correct directory
diff --git a/tools/github-actions/nanomap-renderer b/tools/github-actions/nanomap-renderer
new file mode 100755
index 00000000000..69fa906c94e
Binary files /dev/null and b/tools/github-actions/nanomap-renderer differ
diff --git a/tools/github-actions/nanomap-renderer-invoker.sh b/tools/github-actions/nanomap-renderer-invoker.sh
new file mode 100755
index 00000000000..b6fadfac5f1
--- /dev/null
+++ b/tools/github-actions/nanomap-renderer-invoker.sh
@@ -0,0 +1,14 @@
+#!/bin/bash
+# Generate maps
+tools/github-actions/nanomap-renderer minimap "./_maps/map_files/cyberiad/cyberiad.dmm"
+tools/github-actions/nanomap-renderer minimap "./_maps/map_files/Delta/delta.dmm"
+tools/github-actions/nanomap-renderer minimap "./_maps/map_files/MetaStation/MetaStation.v41A.II.dmm"
+# Move and rename files so the game understands them
+cd "data/nanomaps"
+mv "cyberiad_nanomap_z1.png" "Cyberiad_nanomap_z1.png"
+mv "delta_nanomap_z1.png" "Delta_nanomap_z1.png"
+mv "MetaStation.v41A.II_nanomap_z1.png" "MetaStation_nanomap_z1.png"
+cd "../../"
+cp "data/nanomaps/Cyberiad_nanomap_z1.png" "nano/images"
+cp "data/nanomaps/Delta_nanomap_z1.png" "nano/images"
+cp "data/nanomaps/MetaStation_nanomap_z1.png" "nano/images"
|
|