From e5967a3fb9ffbdc57172ad2c159e1e447a6c6f35 Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 12:48:56 +0300 Subject: [PATCH 01/32] [Modular] Hash is no longer recursive (#1024) Unhashed Co-authored-by: SomeRandomOwl <2568378+SomeRandomOwl@users.noreply.github.com> --- modular_skyrat/modules/morenarcotics/code/thc.dm | 4 ++++ modular_skyrat/modules/morenarcotics/code/thc_item.dm | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/modular_skyrat/modules/morenarcotics/code/thc.dm b/modular_skyrat/modules/morenarcotics/code/thc.dm index 74bdc3c637d..69d1418a99b 100644 --- a/modular_skyrat/modules/morenarcotics/code/thc.dm +++ b/modular_skyrat/modules/morenarcotics/code/thc.dm @@ -46,6 +46,10 @@ ph = 6 taste_description = "skunk" +/datum/reagent/drug/thc/concentrated + name = "Concentrated THC" + description = "TCH in pure concentrated form" + /datum/reagent/drug/thc/on_mob_life(mob/living/carbon/M, seconds_per_tick, times_fired) var/high_message = pick("You feel relaxed.", "You feel fucked up.", "You feel totally wrecked...") if(M.hud_used!=null) diff --git a/modular_skyrat/modules/morenarcotics/code/thc_item.dm b/modular_skyrat/modules/morenarcotics/code/thc_item.dm index 6f4cdd26a26..b948c8a9cd4 100644 --- a/modular_skyrat/modules/morenarcotics/code/thc_item.dm +++ b/modular_skyrat/modules/morenarcotics/code/thc_item.dm @@ -14,7 +14,7 @@ icon_state = "dab" volume = 40 has_variable_transfer_amount = FALSE - list_reagents = list(/datum/reagent/drug/thc = 40) //horrendously powerful + list_reagents = list(/datum/reagent/drug/thc/concentrated = 40) //horrendously powerful /obj/item/reagent_containers/hashbrick name = "hash brick" From 62d600fec605117e1e3883db2b206977c9c513ce Mon Sep 17 00:00:00 2001 From: Yaroslav Nurkov <78199449+AnywayFarus@users.noreply.github.com> Date: Sat, 9 Dec 2023 12:49:21 +0300 Subject: [PATCH 02/32] Automatic changelog for PR #1024 [ci skip] --- html/changelogs/AutoChangeLog-pr-1024.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-1024.yml diff --git a/html/changelogs/AutoChangeLog-pr-1024.yml b/html/changelogs/AutoChangeLog-pr-1024.yml new file mode 100644 index 00000000000..9763971c666 --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-1024.yml @@ -0,0 +1,4 @@ +author: "SomeRandomOwl and Iamgoofball" +delete-after: True +changes: + - bugfix: "Hash Bricks and Dabs are no longer recursive" \ No newline at end of file From 831cf71c17ea9e3f98be116eaac2865aa71186bc Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 12:49:34 +0300 Subject: [PATCH 03/32] [MIRROR] No longer stuck inside legion when you revive [MDB IGNORE] (#1025) * No longer stuck inside legion when you revive (#80112) --------- Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Co-authored-by: Autisem <36102060+Autisem@users.noreply.github.com> --- code/modules/mob/living/basic/lavaland/legion/legion.dm | 7 +++++++ code/modules/mob/living/death.dm | 7 ++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/code/modules/mob/living/basic/lavaland/legion/legion.dm b/code/modules/mob/living/basic/lavaland/legion/legion.dm index b64c3b257a0..080f397226e 100644 --- a/code/modules/mob/living/basic/lavaland/legion/legion.dm +++ b/code/modules/mob/living/basic/lavaland/legion/legion.dm @@ -52,6 +52,7 @@ . = ..() if (gone != stored_mob) return + UnregisterSignal(stored_mob, COMSIG_LIVING_REVIVE) ai_controller.clear_blackboard_key(BB_LEGION_CORPSE) stored_mob.remove_status_effect(/datum/status_effect/grouped/stasis, STASIS_LEGION_EATEN) stored_mob.add_mood_event(MOOD_CATEGORY_LEGION_CORE, /datum/mood_event/healsbadman/long_term) // This will still probably mostly be gone before you are alive @@ -72,6 +73,7 @@ consumed.extinguish_mob() consumed.fully_heal(HEAL_DAMAGE) consumed.apply_status_effect(/datum/status_effect/grouped/stasis, STASIS_LEGION_EATEN) + RegisterSignal(consumed, COMSIG_LIVING_REVIVE, PROC_REF(on_consumed_revive)) consumed.forceMove(src) ai_controller?.set_blackboard_key(BB_LEGION_CORPSE, consumed) ai_controller?.set_blackboard_key(BB_LEGION_RECENT_LINES, consumed.copy_recent_speech(line_chance = 80)) @@ -84,6 +86,11 @@ cancer.Insert(consumed, special = TRUE, drop_if_replaced = FALSE) /// A Legion which only drops skeletons instead of corpses which might have fun loot, so it cannot be farmed + +/mob/living/basic/mining/legion/proc/on_consumed_revive(full_heal_flags) + SIGNAL_HANDLER + gib() + /mob/living/basic/mining/legion/spawner_made corpse_type = /obj/effect/mob_spawn/corpse/human/legioninfested/skeleton/charred diff --git a/code/modules/mob/living/death.dm b/code/modules/mob/living/death.dm index 6174a5793bc..c4ad9aab656 100644 --- a/code/modules/mob/living/death.dm +++ b/code/modules/mob/living/death.dm @@ -10,19 +10,20 @@ **/ /mob/living/proc/gib(drop_bitflags=NONE) var/prev_lying = lying_angle - if(stat != DEAD) - death(TRUE) + spawn_gibs(drop_bitflags) if(!prev_lying) gib_animation() + if(stat != DEAD) + death(TRUE) + ghostize() spill_organs(drop_bitflags) if(drop_bitflags & DROP_BODYPARTS) spread_bodyparts(drop_bitflags) - spawn_gibs(drop_bitflags) SEND_SIGNAL(src, COMSIG_LIVING_GIBBED, drop_bitflags) qdel(src) From 6d0d6e5d3531e3d4755cd31ea157df6de4835421 Mon Sep 17 00:00:00 2001 From: Yaroslav Nurkov <78199449+AnywayFarus@users.noreply.github.com> Date: Sat, 9 Dec 2023 12:49:55 +0300 Subject: [PATCH 04/32] Automatic changelog for PR #1025 [ci skip] --- html/changelogs/AutoChangeLog-pr-1025.yml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-1025.yml diff --git a/html/changelogs/AutoChangeLog-pr-1025.yml b/html/changelogs/AutoChangeLog-pr-1025.yml new file mode 100644 index 00000000000..31f7266eb3e --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-1025.yml @@ -0,0 +1,5 @@ +author: "Autisem" +delete-after: True +changes: + - bugfix: "Being revived inside a legion now sets you free" + - bugfix: "in some rare cases gib() did infact not spawn gib\n/🆑" \ No newline at end of file From bc00cec3bac5b018328bb1352ef3b9d048b398f7 Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 12:50:13 +0300 Subject: [PATCH 05/32] Synthetic Humanoids. Now taste-less and less picky! (#1026) gives synth tongue NONE foodtypes Co-authored-by: Hypertorus Fusion Reactor <109750345+dis-integrates-the-integration-tests@users.noreply.github.com> --- modular_skyrat/modules/synths/code/bodyparts/tongue.dm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modular_skyrat/modules/synths/code/bodyparts/tongue.dm b/modular_skyrat/modules/synths/code/bodyparts/tongue.dm index d5c2564fdb3..1d64febe161 100644 --- a/modular_skyrat/modules/synths/code/bodyparts/tongue.dm +++ b/modular_skyrat/modules/synths/code/bodyparts/tongue.dm @@ -8,6 +8,8 @@ attack_verb_simple = list("beep", "boop") modifies_speech = TRUE taste_sensitivity = 25 // not as good as an organic tongue + liked_foodtypes = NONE + disliked_foodtypes = NONE maxHealth = 100 //RoboTongue! zone = BODY_ZONE_HEAD slot = ORGAN_SLOT_TONGUE From f1a749f89cef356d1c16733b962cba34c71a6e84 Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 12:51:23 +0300 Subject: [PATCH 06/32] [MIRROR] Fixes issues on guns with BOLT_TYPE_LOCKING [MDB IGNORE] (#1028) * Fixes issues on guns with BOLT_TYPE_LOCKING (#80154) --------- Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Co-authored-by: TJatPBnJ <69724863+TJatPBnJ@users.noreply.github.com> Co-authored-by: Mothblocks <35135081+Mothblocks@ users.noreply.github.com> --- code/modules/projectiles/gun.dm | 4 +++- code/modules/projectiles/guns/ballistic.dm | 4 ++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/code/modules/projectiles/gun.dm b/code/modules/projectiles/gun.dm index eba77d57446..be7ecd1a95d 100644 --- a/code/modules/projectiles/gun.dm +++ b/code/modules/projectiles/gun.dm @@ -271,7 +271,8 @@ /obj/item/gun/afterattack(atom/target, mob/living/user, flag, params) ..() - return fire_gun(target, user, flag, params) | AFTERATTACK_PROCESSED_ITEM + fire_gun(target, user, flag, params) + return AFTERATTACK_PROCESSED_ITEM /obj/item/gun/proc/fire_gun(atom/target, mob/living/user, flag, params) if(QDELETED(target)) @@ -403,6 +404,7 @@ update_appearance() return TRUE +///returns true if the gun successfully fires /obj/item/gun/proc/process_fire(atom/target, mob/living/user, message = TRUE, params = null, zone_override = "", bonus_spread = 0) var/base_bonus_spread = 0 if(user) diff --git a/code/modules/projectiles/guns/ballistic.dm b/code/modules/projectiles/guns/ballistic.dm index 52ab71e4cea..d7e2d16a9b0 100644 --- a/code/modules/projectiles/guns/ballistic.dm +++ b/code/modules/projectiles/guns/ballistic.dm @@ -490,11 +490,11 @@ if (empty_alarm && last_shot_succeeded) playsound(src, empty_alarm_sound, empty_alarm_volume, empty_alarm_vary) update_appearance() - if (last_shot_succeeded && bolt_type == BOLT_TYPE_LOCKING) + if (last_shot_succeeded && bolt_type == BOLT_TYPE_LOCKING && semi_auto) bolt_locked = TRUE update_appearance() -/obj/item/gun/ballistic/afterattack() +/obj/item/gun/ballistic/fire_gun(atom/target, mob/living/user, flag, params) prefire_empty_checks() . = ..() //The gun actually firing postfire_empty_checks(.) From 6863804d28bcb103ccfbd6084fe2dd30dc4c790d Mon Sep 17 00:00:00 2001 From: Yaroslav Nurkov <78199449+AnywayFarus@users.noreply.github.com> Date: Sat, 9 Dec 2023 13:01:16 +0300 Subject: [PATCH 07/32] Automatic changelog for PR #1026 [ci skip] --- html/changelogs/AutoChangeLog-pr-1026.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-1026.yml diff --git a/html/changelogs/AutoChangeLog-pr-1026.yml b/html/changelogs/AutoChangeLog-pr-1026.yml new file mode 100644 index 00000000000..721e909ed80 --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-1026.yml @@ -0,0 +1,4 @@ +author: "KannaLisvern" +delete-after: True +changes: + - qol: "Synthetics no longer have the same food prefs as humans" \ No newline at end of file From f59335ac83f06317f917794db6d73764589e6d06 Mon Sep 17 00:00:00 2001 From: Yaroslav Nurkov <78199449+AnywayFarus@users.noreply.github.com> Date: Sat, 9 Dec 2023 13:01:55 +0300 Subject: [PATCH 08/32] Automatic changelog for PR #1028 [ci skip] --- html/changelogs/AutoChangeLog-pr-1028.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-1028.yml diff --git a/html/changelogs/AutoChangeLog-pr-1028.yml b/html/changelogs/AutoChangeLog-pr-1028.yml new file mode 100644 index 00000000000..e6c49deec20 --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-1028.yml @@ -0,0 +1,4 @@ +author: "TJatPBnJ" +delete-after: True +changes: + - bugfix: "Bolt action rifles no longer open their bolt when firing their last bullet." \ No newline at end of file From 5385e780d5d9c38e07b5700abe12488f2a859a02 Mon Sep 17 00:00:00 2001 From: Changelogs Date: Sat, 9 Dec 2023 12:26:01 +0000 Subject: [PATCH 09/32] Automatic changelog compile [ci skip] --- html/changelogs/AutoChangeLog-pr-1024.yml | 4 ---- html/changelogs/AutoChangeLog-pr-1025.yml | 5 ----- html/changelogs/AutoChangeLog-pr-1026.yml | 4 ---- html/changelogs/AutoChangeLog-pr-1028.yml | 4 ---- html/changelogs/archive/2023-12.yml | 10 ++++++++++ 5 files changed, 10 insertions(+), 17 deletions(-) delete mode 100644 html/changelogs/AutoChangeLog-pr-1024.yml delete mode 100644 html/changelogs/AutoChangeLog-pr-1025.yml delete mode 100644 html/changelogs/AutoChangeLog-pr-1026.yml delete mode 100644 html/changelogs/AutoChangeLog-pr-1028.yml diff --git a/html/changelogs/AutoChangeLog-pr-1024.yml b/html/changelogs/AutoChangeLog-pr-1024.yml deleted file mode 100644 index 9763971c666..00000000000 --- a/html/changelogs/AutoChangeLog-pr-1024.yml +++ /dev/null @@ -1,4 +0,0 @@ -author: "SomeRandomOwl and Iamgoofball" -delete-after: True -changes: - - bugfix: "Hash Bricks and Dabs are no longer recursive" \ No newline at end of file diff --git a/html/changelogs/AutoChangeLog-pr-1025.yml b/html/changelogs/AutoChangeLog-pr-1025.yml deleted file mode 100644 index 31f7266eb3e..00000000000 --- a/html/changelogs/AutoChangeLog-pr-1025.yml +++ /dev/null @@ -1,5 +0,0 @@ -author: "Autisem" -delete-after: True -changes: - - bugfix: "Being revived inside a legion now sets you free" - - bugfix: "in some rare cases gib() did infact not spawn gib\n/🆑" \ No newline at end of file diff --git a/html/changelogs/AutoChangeLog-pr-1026.yml b/html/changelogs/AutoChangeLog-pr-1026.yml deleted file mode 100644 index 721e909ed80..00000000000 --- a/html/changelogs/AutoChangeLog-pr-1026.yml +++ /dev/null @@ -1,4 +0,0 @@ -author: "KannaLisvern" -delete-after: True -changes: - - qol: "Synthetics no longer have the same food prefs as humans" \ No newline at end of file diff --git a/html/changelogs/AutoChangeLog-pr-1028.yml b/html/changelogs/AutoChangeLog-pr-1028.yml deleted file mode 100644 index e6c49deec20..00000000000 --- a/html/changelogs/AutoChangeLog-pr-1028.yml +++ /dev/null @@ -1,4 +0,0 @@ -author: "TJatPBnJ" -delete-after: True -changes: - - bugfix: "Bolt action rifles no longer open their bolt when firing their last bullet." \ No newline at end of file diff --git a/html/changelogs/archive/2023-12.yml b/html/changelogs/archive/2023-12.yml index a6bd0fe3ac9..c686611b3f7 100644 --- a/html/changelogs/archive/2023-12.yml +++ b/html/changelogs/archive/2023-12.yml @@ -331,3 +331,13 @@ - rscadd: Adds various hair ties, they hold up your hair. theselfish: - spellcheck: You can now holo-display your coat. No idea what a Dislpay is. +2023-12-09: + Autisem: + - bugfix: Being revived inside a legion now sets you free + - bugfix: "in some rare cases gib() did infact not spawn gib\n/\U0001F191" + KannaLisvern: + - qol: Synthetics no longer have the same food prefs as humans + SomeRandomOwl and Iamgoofball: + - bugfix: Hash Bricks and Dabs are no longer recursive + TJatPBnJ: + - bugfix: Bolt action rifles no longer open their bolt when firing their last bullet. From 4d1fcb5af375663ae317e91a79744bd7ac4f3c79 Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:01:16 +0300 Subject: [PATCH 10/32] [MIRROR] Adds wound armor to heretic robes and gives heretic blades knife level wounding [MDB IGNORE] (#1029) * Adds wound armor to heretic robes and gives heretic blades knife level wounding (#80146) --------- Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Co-authored-by: KittyNoodle <78111117+KittyNoodle@users.noreply.github.com> --- code/modules/antagonists/heretic/items/heretic_armor.dm | 3 +++ code/modules/antagonists/heretic/items/heretic_blades.dm | 2 ++ 2 files changed, 5 insertions(+) diff --git a/code/modules/antagonists/heretic/items/heretic_armor.dm b/code/modules/antagonists/heretic/items/heretic_armor.dm index 502c52c17fb..e1f79612406 100644 --- a/code/modules/antagonists/heretic/items/heretic_armor.dm +++ b/code/modules/antagonists/heretic/items/heretic_armor.dm @@ -34,6 +34,7 @@ bio = 20 fire = 20 acid = 20 + wound = 20 /obj/item/clothing/suit/hooded/cultrobes/eldritch/examine(mob/user) . = ..() @@ -64,6 +65,7 @@ laser = 30 energy = 30 bomb = 15 + wound = 10 /obj/item/clothing/head/hooded/cult_hoodie/void/Initialize(mapload) . = ..() @@ -89,6 +91,7 @@ laser = 30 energy = 30 bomb = 15 + wound = 10 /obj/item/clothing/suit/hooded/cultrobes/void/Initialize(mapload) . = ..() diff --git a/code/modules/antagonists/heretic/items/heretic_blades.dm b/code/modules/antagonists/heretic/items/heretic_blades.dm index 19470e29699..8eb08a76427 100644 --- a/code/modules/antagonists/heretic/items/heretic_blades.dm +++ b/code/modules/antagonists/heretic/items/heretic_blades.dm @@ -14,6 +14,8 @@ w_class = WEIGHT_CLASS_NORMAL force = 20 throwforce = 10 + wound_bonus = 5 + bare_wound_bonus = 15 toolspeed = 0.375 demolition_mod = 0.8 hitsound = 'sound/weapons/bladeslice.ogg' From 0760ca26a1072273fbba0673946e3a5a55180a28 Mon Sep 17 00:00:00 2001 From: Yaroslav Nurkov <78199449+AnywayFarus@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:01:39 +0300 Subject: [PATCH 11/32] Automatic changelog for PR #1029 [ci skip] --- html/changelogs/AutoChangeLog-pr-1029.yml | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-1029.yml diff --git a/html/changelogs/AutoChangeLog-pr-1029.yml b/html/changelogs/AutoChangeLog-pr-1029.yml new file mode 100644 index 00000000000..880a034d8a5 --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-1029.yml @@ -0,0 +1,5 @@ +author: "KittyNoodle" +delete-after: True +changes: + - balance: "heretic robes now have wound armor" + - balance: "heretic blades now have knife-level wound bonuses" \ No newline at end of file From 2f792cfbbb3910b668136619a5f910fd6d8a8cb9 Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:22:08 +0300 Subject: [PATCH 12/32] [MIRROR] Cups end their attack chain early when attacked with specific items [MDB IGNORE] (#1030) * Cups end their attack chain early when attacked with specific items (#80140) --------- Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Co-authored-by: SyncIt21 <110812394+SyncIt21@users.noreply.github.com> --- .../reagents/reagent_containers/cups/_cup.dm | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/code/modules/reagents/reagent_containers/cups/_cup.dm b/code/modules/reagents/reagent_containers/cups/_cup.dm index 36991f71f61..5770d431399 100644 --- a/code/modules/reagents/reagent_containers/cups/_cup.dm +++ b/code/modules/reagents/reagent_containers/cups/_cup.dm @@ -168,34 +168,34 @@ if(hotness && reagents) reagents.expose_temperature(hotness) to_chat(user, span_notice("You heat [name] with [attacking_item]!")) - return + return TRUE //Cooling method if(istype(attacking_item, /obj/item/extinguisher)) var/obj/item/extinguisher/extinguisher = attacking_item if(extinguisher.safety) - return + return TRUE if (extinguisher.reagents.total_volume < 1) to_chat(user, span_warning("\The [extinguisher] is empty!")) - return + return TRUE var/cooling = (0 - reagents.chem_temp) * extinguisher.cooling_power * 2 reagents.expose_temperature(cooling) to_chat(user, span_notice("You cool the [name] with the [attacking_item]!")) playsound(loc, 'sound/effects/extinguish.ogg', 75, TRUE, -3) extinguisher.reagents.remove_all(1) - return + return TRUE if(istype(attacking_item, /obj/item/food/egg)) //breaking eggs var/obj/item/food/egg/attacking_egg = attacking_item if(!reagents) - return - if(reagents.total_volume >= reagents.maximum_volume) + return TRUE + if(reagents.holder_full()) to_chat(user, span_notice("[src] is full.")) else to_chat(user, span_notice("You break [attacking_egg] in [src].")) attacking_egg.reagents.trans_to(src, attacking_egg.reagents.total_volume, transferred_by = user) qdel(attacking_egg) - return + return TRUE return ..() From 3d26d868d43d0ff46c4efcf8edc6d3a743965ecc Mon Sep 17 00:00:00 2001 From: Yaroslav Nurkov <78199449+AnywayFarus@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:22:30 +0300 Subject: [PATCH 13/32] Automatic changelog for PR #1030 [ci skip] --- html/changelogs/AutoChangeLog-pr-1030.yml | 4 ++++ 1 file changed, 4 insertions(+) create mode 100644 html/changelogs/AutoChangeLog-pr-1030.yml diff --git a/html/changelogs/AutoChangeLog-pr-1030.yml b/html/changelogs/AutoChangeLog-pr-1030.yml new file mode 100644 index 00000000000..94564a01fb3 --- /dev/null +++ b/html/changelogs/AutoChangeLog-pr-1030.yml @@ -0,0 +1,4 @@ +author: "SyncIt21" +delete-after: True +changes: + - bugfix: "Eggs don't leave behind their shells when cracked into a soup pot. Cups end their attack chain early when dealing with specific items" \ No newline at end of file From 958defa5b5458108836d5e11ad456210976fc687 Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:22:43 +0300 Subject: [PATCH 14/32] [MIRROR] Addresses Icon Smoothing Runtimes [MDB IGNORE] (#1031) * Addresses Icon Smoothing Runtimes (#80171) --------- Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Co-authored-by: san7890 --- code/__HELPERS/icon_smoothing.dm | 2 ++ 1 file changed, 2 insertions(+) diff --git a/code/__HELPERS/icon_smoothing.dm b/code/__HELPERS/icon_smoothing.dm index 6a1cfd6191a..5c5ff5a059a 100644 --- a/code/__HELPERS/icon_smoothing.dm +++ b/code/__HELPERS/icon_smoothing.dm @@ -166,6 +166,8 @@ xxx xxx xxx ///do not use, use QUEUE_SMOOTH(atom) /atom/proc/smooth_icon() + if(QDELETED(src)) + return smoothing_flags &= ~SMOOTH_QUEUED flags_1 |= HTML_USE_INITAL_ICON_1 if (!z) From d44f2bb25cfb61211dca593efd6a7438a6862c04 Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:24:32 +0300 Subject: [PATCH 15/32] [MIRROR] Abductor Ship Bitrunner Domain [MDB IGNORE] (#1033) * Abductor Ship Bitrunner Domain (#80106) --------- Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Co-authored-by: IsaacExists <125638858+IsaacExists@users.noreply.github.com> --- _maps/safehouses/abductor.dmm | 94 + _maps/virtual_domains/abductor_ship.dmm | 2230 +++++++++++++++++ code/modules/bitrunning/outfits.dm | 5 + .../virtual_domain/domains/abductor_ship.dm | 15 + .../virtual_domain/modular_mob_segment.dm | 6 + .../mob/living/basic/trooper/abductor.dm | 42 + strings/modular_maps/safehouse.toml | 3 + tgstation.dme | 2 + 8 files changed, 2397 insertions(+) create mode 100644 _maps/safehouses/abductor.dmm create mode 100644 _maps/virtual_domains/abductor_ship.dmm create mode 100644 code/modules/bitrunning/virtual_domain/domains/abductor_ship.dm create mode 100644 code/modules/mob/living/basic/trooper/abductor.dm diff --git a/_maps/safehouses/abductor.dmm b/_maps/safehouses/abductor.dmm new file mode 100644 index 00000000000..f18b1b6978d --- /dev/null +++ b/_maps/safehouses/abductor.dmm @@ -0,0 +1,94 @@ +//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE +"a" = ( +/turf/closed/wall/mineral/abductor, +/area/virtual_domain/safehouse) +"b" = ( +/obj/effect/landmark/bitrunning/hololadder_spawn, +/turf/open/floor/plating/abductor, +/area/virtual_domain/safehouse) +"d" = ( +/obj/modular_map_connector, +/turf/open/floor/plating/abductor, +/area/virtual_domain/safehouse) +"n" = ( +/turf/open/floor/plating/abductor, +/area/virtual_domain/safehouse) +"o" = ( +/obj/effect/landmark/bitrunning/cache_goal_turf, +/turf/open/floor/plating/abductor2, +/area/virtual_domain/safehouse) +"t" = ( +/obj/effect/landmark/bitrunning/hololadder_spawn, +/turf/open/floor/plating/abductor2, +/area/virtual_domain/safehouse) +"u" = ( +/obj/machinery/abductor/console, +/turf/open/floor/plating/abductor, +/area/virtual_domain/safehouse) +"v" = ( +/obj/machinery/door/airlock/abductor, +/turf/open/floor/plating/abductor, +/area/virtual_domain/safehouse) +"E" = ( +/obj/machinery/abductor/pad{ + desc = "A funky looking disc, built into the floor." + }, +/turf/open/floor/plating/abductor, +/area/virtual_domain/safehouse) + +(1,1,1) = {" +n +a +a +a +a +d +"} +(2,1,1) = {" +a +E +t +t +b +a +"} +(3,1,1) = {" +a +n +n +n +n +a +"} +(4,1,1) = {" +v +n +n +n +n +v +"} +(5,1,1) = {" +a +n +n +n +n +a +"} +(6,1,1) = {" +a +u +o +o +n +a +"} +(7,1,1) = {" +n +a +a +a +a +n +"} diff --git a/_maps/virtual_domains/abductor_ship.dmm b/_maps/virtual_domains/abductor_ship.dmm new file mode 100644 index 00000000000..ebb4a042bb9 --- /dev/null +++ b/_maps/virtual_domains/abductor_ship.dmm @@ -0,0 +1,2230 @@ +//MAP CONVERTED BY dmm2tgm.py THIS HEADER COMMENT PREVENTS RECONVERSION, DO NOT REMOVE +"bK" = ( +/turf/closed/wall/mineral/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"cp" = ( +/obj/structure/table/abductor, +/obj/item/food/soylentgreen{ + pixel_x = -6; + pixel_y = 5 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"cr" = ( +/obj/item/flashlight/lantern{ + pixel_x = 4; + pixel_y = -8; + light_on = 1 + }, +/obj/item/flashlight/lantern{ + pixel_x = -9; + pixel_y = 8; + light_on = 1 + }, +/turf/template_noop, +/area/virtual_domain/safehouse) +"dM" = ( +/obj/item/storage/medkit/regular, +/obj/item/storage/medkit/regular, +/turf/template_noop, +/area/virtual_domain/safehouse) +"fk" = ( +/obj/effect/mob_spawn/corpse/human/abductor, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"ge" = ( +/turf/template_noop, +/area/virtual_domain/safehouse) +"gF" = ( +/obj/machinery/abductor/pad{ + desc = "A funky looking disc, built into the floor." + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"gO" = ( +/obj/structure/table/abductor, +/obj/item/poster/random_abductor{ + pixel_x = 9; + pixel_y = 3 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"ih" = ( +/obj/structure/table/abductor, +/obj/item/storage/belt/military/abductor{ + pixel_x = 5; + pixel_y = 8 + }, +/obj/item/storage/belt/military/abductor{ + pixel_x = -5; + pixel_y = -1 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"kl" = ( +/obj/structure/table_frame/abductor, +/obj/item/organ/internal/lungs{ + pixel_x = 8; + pixel_y = 7 + }, +/obj/item/shard/plastitanium{ + pixel_x = -8; + pixel_y = 1 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"kt" = ( +/obj/structure/table/abductor, +/obj/item/multitool/abductor{ + pixel_y = 6; + pixel_x = 5 + }, +/obj/item/screwdriver/abductor{ + pixel_y = 8; + pixel_x = -1 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"kN" = ( +/obj/machinery/fat_sucker, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"lC" = ( +/obj/structure/table/abductor, +/obj/item/clothing/head/helmet/abductor{ + pixel_x = -5; + pixel_y = 7 + }, +/obj/item/abductor/silencer{ + pixel_x = 6; + pixel_y = -4 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"lN" = ( +/turf/open/floor/holofloor/hyperspace, +/area/ruin/space/has_grav/powered/virtual_domain) +"lR" = ( +/obj/effect/baseturf_helper/virtual_domain, +/turf/template_noop, +/area/virtual_domain/safehouse) +"lW" = ( +/obj/machinery/iv_drip, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"mR" = ( +/obj/machinery/abductor/pad, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"nT" = ( +/obj/structure/table/abductor, +/obj/item/food/soylentgreen{ + pixel_x = 4; + pixel_y = -1 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"oL" = ( +/obj/effect/landmark/bitrunning/mob_segment, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"pL" = ( +/obj/effect/spawner/structure/window/reinforced/plasma/plastitanium, +/turf/open/space/basic, +/area/ruin/space/has_grav/powered/virtual_domain) +"pT" = ( +/obj/effect/decal/cleanable/blood/footprints, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"rw" = ( +/obj/structure/table/abductor, +/obj/item/toy/plush/abductor/agent{ + pixel_x = 10; + pixel_y = 8 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"rY" = ( +/obj/modular_map_root/safehouse{ + key = "abductor" + }, +/turf/template_noop, +/area/virtual_domain/safehouse) +"sv" = ( +/obj/structure/table/abductor, +/obj/item/crowbar/abductor, +/obj/item/stock_parts/cell/infinite/abductor{ + pixel_x = 5; + pixel_y = -3 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"to" = ( +/obj/effect/decal/cleanable/molten_object{ + pixel_x = 9; + pixel_y = 7 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"uk" = ( +/obj/structure/table/abductor, +/obj/item/wrench/abductor{ + pixel_x = 2; + pixel_y = 7 + }, +/obj/item/wirecutters/abductor{ + pixel_x = -3; + pixel_y = 4 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"uw" = ( +/obj/structure/bed/abductor, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"ux" = ( +/obj/machinery/door/airlock/abductor{ + name = "Command Center"; + locked = 1 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"uD" = ( +/obj/machinery/computer/camera_advanced/abductor, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"vY" = ( +/obj/machinery/door/airlock/abductor{ + name = "Repair Bay" + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"vZ" = ( +/obj/machinery/abductor/gland_dispenser, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"xB" = ( +/turf/closed/indestructible/opsglass, +/area/ruin/space/has_grav/powered/virtual_domain) +"xM" = ( +/obj/effect/decal/cleanable/molten_object{ + pixel_x = -6; + pixel_y = -7 + }, +/obj/effect/landmark/bitrunning/cache_spawn, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"yt" = ( +/obj/effect/decal/cleanable/blood/xtracks, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"zX" = ( +/obj/machinery/abductor/experiment, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"AG" = ( +/obj/item/shell/server, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Fy" = ( +/obj/effect/decal/cleanable/molten_object/large{ + pixel_x = -5; + pixel_y = 14 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"GX" = ( +/obj/structure/chair/office{ + dir = 4 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"IC" = ( +/obj/structure/table/abductor, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"JC" = ( +/obj/item/organ/external/tail/cat, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"JR" = ( +/obj/machinery/door/airlock/abductor{ + name = "Experimentation Lab" + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"JU" = ( +/obj/structure/closet/abductor, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"KK" = ( +/obj/structure/bed/abductor, +/obj/effect/decal/cleanable/blood/old, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"KX" = ( +/turf/closed/indestructible/binary, +/area/space) +"Lz" = ( +/obj/structure/table/abductor, +/obj/item/melee/baton/abductor{ + desc = "Even aliens can see the use of a good old-fashioned beating stick."; + pixel_x = 6; + pixel_y = -5 + }, +/obj/item/gun/energy/shrink_ray{ + pixel_x = -5; + pixel_y = 7 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Mr" = ( +/obj/machinery/chem_dispenser/abductor, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"MC" = ( +/obj/item/kirbyplants/photosynthetic, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Ne" = ( +/obj/machinery/abductor/console, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"NW" = ( +/obj/structure/server, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"PB" = ( +/obj/item/organ/external/antennae, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Qp" = ( +/turf/template_noop, +/area/space) +"QC" = ( +/obj/structure/chair/comfy/teal{ + dir = 8 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Rd" = ( +/obj/effect/spawner/structure/window/reinforced/plasma/plastitanium, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Rg" = ( +/obj/structure/table/abductor, +/obj/item/ammo_box/magazine/smgm45, +/obj/item/ammo_box/magazine/smgm45{ + pixel_x = 9; + pixel_y = 3 + }, +/obj/item/gun/ballistic/automatic/c20r/unrestricted{ + pixel_x = -5; + pixel_y = -5 + }, +/turf/template_noop, +/area/virtual_domain/safehouse) +"RI" = ( +/obj/machinery/door/airlock/abductor, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Sd" = ( +/obj/machinery/recharge_station, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Ub" = ( +/obj/structure/chair/comfy/shuttle{ + dir = 8 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Uf" = ( +/obj/item/flashlight/seclite{ + pixel_x = 9; + pixel_y = -11 + }, +/obj/item/clothing/suit/armor/vest/alt{ + pixel_x = 10; + pixel_y = 8 + }, +/obj/item/clothing/suit/armor/vest/alt{ + pixel_x = -6; + pixel_y = 6 + }, +/obj/item/clothing/suit/armor/vest/alt{ + pixel_x = 2; + pixel_y = -2 + }, +/turf/template_noop, +/area/virtual_domain/safehouse) +"Us" = ( +/obj/structure/table/abductor, +/obj/item/abductor/mind_device{ + desc = "Just holding this makes your head ache."; + pixel_x = 3 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"UX" = ( +/obj/effect/landmark/bitrunning/cache_spawn, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Vl" = ( +/obj/machinery/harvester, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"VE" = ( +/obj/structure/table/abductor, +/obj/item/storage/box/alienhandcuffs, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"VY" = ( +/obj/effect/mob_spawn/corpse/human/abductor{ + pixel_x = 9; + pixel_y = -5 + }, +/obj/effect/decal/cleanable/xenoblood, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"We" = ( +/obj/structure/table/abductor, +/obj/item/dualsaber/green{ + pixel_x = -5; + pixel_y = 2 + }, +/obj/item/gun/ballistic/automatic/c20r/unrestricted{ + pixel_x = 8; + pixel_y = -6 + }, +/turf/template_noop, +/area/virtual_domain/safehouse) +"Wk" = ( +/obj/structure/table/abductor, +/obj/item/weldingtool/abductor, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"WS" = ( +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"XU" = ( +/obj/effect/decal/cleanable/xenoblood/xgibs/body, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"Yq" = ( +/obj/effect/decal/cleanable/xenoblood/xsplatter, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) +"YV" = ( +/turf/closed/indestructible/alien, +/area/ruin/space/has_grav/powered/virtual_domain) +"ZM" = ( +/obj/structure/chair/comfy/shuttle{ + dir = 4 + }, +/turf/open/floor/plating/abductor, +/area/ruin/space/has_grav/powered/virtual_domain) + +(1,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(2,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(3,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(4,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(5,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(6,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +KX +KX +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(7,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +KX +KX +YV +YV +YV +YV +kN +lW +uw +IC +IC +uw +lW +kN +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(8,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +KX +KX +YV +YV +YV +YV +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(9,1,1) = {" +Qp +Qp +Qp +KX +KX +KX +KX +KX +KX +YV +YV +YV +YV +WS +WS +WS +WS +WS +WS +WS +WS +WS +oL +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(10,1,1) = {" +Qp +Qp +KX +KX +lN +lN +lN +lN +YV +YV +YV +YV +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(11,1,1) = {" +Qp +KX +KX +lN +lN +lN +lN +YV +YV +YV +YV +WS +WS +WS +MC +YV +YV +YV +WS +WS +YV +YV +YV +MC +WS +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +"} +(12,1,1) = {" +KX +KX +lN +lN +lN +lN +YV +YV +YV +YV +lW +WS +WS +YV +YV +YV +bK +YV +WS +WS +YV +YV +YV +YV +YV +WS +WS +lW +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +"} +(13,1,1) = {" +KX +lN +lN +lN +lN +YV +YV +YV +YV +WS +WS +WS +YV +YV +bK +bK +YV +YV +WS +WS +YV +YV +YV +YV +YV +YV +WS +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +"} +(14,1,1) = {" +KX +lN +lN +lN +YV +YV +YV +YV +WS +WS +WS +YV +YV +JU +yt +VY +YV +MC +WS +WS +MC +YV +ih +Yq +JU +YV +YV +UX +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +"} +(15,1,1) = {" +KX +lN +lN +lN +YV +bK +YV +UX +WS +WS +YV +YV +Wk +WS +WS +WS +YV +WS +WS +WS +WS +YV +rw +WS +WS +WS +YV +YV +Vl +WS +MC +YV +bK +YV +YV +KX +KX +Qp +Qp +"} +(16,1,1) = {" +KX +lN +lN +lN +YV +bK +YV +WS +WS +YV +YV +uk +WS +oL +YV +YV +WS +WS +WS +WS +WS +WS +YV +YV +WS +WS +JU +YV +YV +YV +YV +YV +YV +bK +YV +YV +KX +Qp +Qp +"} +(17,1,1) = {" +KX +lN +lN +lN +YV +bK +YV +WS +WS +YV +JU +WS +WS +WS +vY +WS +WS +WS +WS +WS +WS +WS +WS +RI +WS +WS +XU +gO +YV +YV +YV +AG +YV +YV +bK +YV +KX +Qp +Qp +"} +(18,1,1) = {" +KX +lN +lN +lN +YV +YV +YV +MC +Vl +YV +UX +WS +MC +YV +YV +WS +WS +WS +WS +WS +WS +WS +WS +YV +YV +JU +fk +lC +YV +YV +NW +WS +NW +YV +bK +YV +KX +Qp +Qp +"} +(19,1,1) = {" +KX +lN +lN +lN +pL +YV +YV +YV +YV +YV +YV +YV +YV +MC +WS +WS +ge +ge +ge +ge +ge +rY +WS +WS +MC +YV +YV +YV +YV +YV +NW +WS +NW +YV +bK +YV +KX +Qp +Qp +"} +(20,1,1) = {" +KX +lN +lN +pL +pL +uD +ZM +ZM +WS +Rd +MC +WS +WS +WS +WS +WS +ge +ge +ge +ge +ge +ge +WS +WS +WS +WS +WS +WS +YV +YV +xB +xB +xB +YV +bK +YV +KX +Qp +Qp +"} +(21,1,1) = {" +KX +lN +lN +pL +Ne +WS +WS +WS +WS +ux +WS +WS +WS +WS +WS +WS +ge +ge +Uf +cr +ge +ge +WS +WS +WS +WS +WS +WS +WS +YV +WS +WS +WS +YV +bK +YV +KX +Qp +Qp +"} +(22,1,1) = {" +KX +lN +lN +pL +Lz +WS +WS +WS +WS +Rd +WS +WS +WS +WS +WS +WS +ge +ge +We +Rg +ge +ge +WS +WS +WS +oL +WS +WS +WS +RI +WS +oL +WS +YV +bK +YV +KX +Qp +Qp +"} +(23,1,1) = {" +KX +lN +lN +pL +Ne +WS +WS +WS +WS +ux +WS +WS +WS +WS +WS +WS +ge +ge +ge +ge +ge +ge +WS +WS +WS +WS +WS +WS +WS +YV +WS +WS +WS +YV +bK +YV +KX +Qp +Qp +"} +(24,1,1) = {" +KX +lN +lN +pL +pL +uD +Ub +Ub +WS +Rd +MC +WS +WS +WS +WS +WS +ge +ge +ge +ge +dM +ge +WS +WS +WS +WS +WS +WS +YV +YV +xB +xB +xB +YV +bK +YV +KX +Qp +Qp +"} +(25,1,1) = {" +KX +lN +lN +lN +pL +YV +YV +YV +YV +YV +YV +YV +YV +MC +WS +WS +ge +ge +ge +ge +ge +lR +WS +WS +MC +YV +YV +YV +YV +bK +NW +WS +NW +YV +bK +YV +KX +Qp +Qp +"} +(26,1,1) = {" +KX +lN +lN +lN +YV +YV +YV +MC +uw +YV +Mr +JC +uw +YV +YV +WS +WS +WS +WS +WS +WS +WS +WS +YV +YV +MC +xM +cp +YV +bK +NW +WS +NW +YV +bK +YV +KX +Qp +Qp +"} +(27,1,1) = {" +KX +lN +lN +lN +YV +bK +YV +UX +WS +YV +uw +WS +WS +pT +JR +WS +WS +WS +WS +WS +WS +WS +WS +RI +WS +WS +WS +Us +YV +bK +bK +AG +YV +YV +bK +YV +KX +Qp +Qp +"} +(28,1,1) = {" +KX +lN +lN +lN +YV +bK +YV +WS +WS +YV +YV +mR +WS +WS +YV +YV +WS +WS +WS +WS +WS +WS +YV +YV +Fy +WS +IC +YV +YV +YV +YV +YV +YV +bK +YV +YV +KX +Qp +Qp +"} +(29,1,1) = {" +KX +lN +lN +lN +YV +bK +YV +WS +WS +WS +YV +YV +kl +PB +WS +KK +YV +WS +WS +WS +WS +YV +VE +to +oL +QC +YV +YV +UX +WS +MC +YV +bK +YV +YV +KX +KX +Qp +Qp +"} +(30,1,1) = {" +KX +lN +lN +lN +YV +YV +YV +YV +WS +WS +WS +YV +YV +uw +MC +vZ +YV +MC +WS +WS +WS +YV +nT +WS +MC +YV +YV +WS +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +"} +(31,1,1) = {" +KX +lN +lN +lN +lN +YV +YV +YV +YV +gF +WS +WS +YV +YV +YV +YV +YV +YV +WS +WS +YV +YV +YV +YV +YV +YV +WS +WS +gF +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +"} +(32,1,1) = {" +KX +KX +lN +lN +lN +lN +YV +YV +YV +YV +lW +oL +WS +YV +YV +YV +bK +YV +WS +WS +YV +bK +YV +YV +YV +WS +WS +lW +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +"} +(33,1,1) = {" +Qp +KX +KX +lN +lN +lN +lN +YV +YV +YV +YV +WS +WS +WS +MC +YV +YV +YV +WS +WS +YV +YV +YV +MC +WS +WS +oL +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +"} +(34,1,1) = {" +Qp +Qp +KX +KX +lN +lN +lN +lN +YV +YV +YV +YV +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(35,1,1) = {" +Qp +Qp +Qp +KX +KX +KX +KX +KX +KX +YV +YV +YV +YV +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +WS +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(36,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +KX +KX +YV +YV +YV +YV +zX +WS +GX +WS +WS +WS +WS +GX +WS +zX +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(37,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +KX +KX +YV +YV +YV +YV +Sd +sv +Sd +WS +WS +Sd +kt +Sd +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(38,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +KX +KX +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +YV +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(39,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +KX +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(40,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(41,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(42,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(43,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} +(44,1,1) = {" +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +Qp +"} diff --git a/code/modules/bitrunning/outfits.dm b/code/modules/bitrunning/outfits.dm index 4b3e54f329a..41a65b228ff 100644 --- a/code/modules/bitrunning/outfits.dm +++ b/code/modules/bitrunning/outfits.dm @@ -14,3 +14,8 @@ . = ..() user.psykerize() +/datum/outfit/bitductor + name = "Bitrunning Abductor" + uniform = /obj/item/clothing/under/abductor + gloves = /obj/item/clothing/gloves/fingerless + shoes = /obj/item/clothing/shoes/jackboots diff --git a/code/modules/bitrunning/virtual_domain/domains/abductor_ship.dm b/code/modules/bitrunning/virtual_domain/domains/abductor_ship.dm new file mode 100644 index 00000000000..6475a20a0c7 --- /dev/null +++ b/code/modules/bitrunning/virtual_domain/domains/abductor_ship.dm @@ -0,0 +1,15 @@ +/datum/lazy_template/virtual_domain/abductor_ship + name = "Abductor Ship" + cost = BITRUNNER_COST_MEDIUM + desc = "Board an abductor ship and take their goodies." + difficulty = BITRUNNER_DIFFICULTY_MEDIUM + extra_loot = list(/obj/item/toy/plush/abductor/agent = 1) + help_text = "An abductor mothership unknowingly entered a hostile environment. \ + They are currently preparing to escape the area with their gear and loot including \ + the crate. Be careful, they are known for their advanced weaponry." + is_modular = TRUE + key = "abductor_ship" + map_name = "abductor_ship" + mob_modules = list(/datum/modular_mob_segment/abductor_agents) + reward_points = BITRUNNER_REWARD_MEDIUM + forced_outfit = /datum/outfit/bitductor diff --git a/code/modules/bitrunning/virtual_domain/modular_mob_segment.dm b/code/modules/bitrunning/virtual_domain/modular_mob_segment.dm index b845eee564d..ab691274bc5 100644 --- a/code/modules/bitrunning/virtual_domain/modular_mob_segment.dm +++ b/code/modules/bitrunning/virtual_domain/modular_mob_segment.dm @@ -72,6 +72,12 @@ /mob/living/basic/trooper/syndicate/melee, ) +/datum/modular_mob_segment/abductor_agents + mobs = list( + /mob/living/basic/trooper/abductor/melee, + /mob/living/basic/trooper/abductor/ranged, + ) + /datum/modular_mob_segment/syndicate_elite mobs = list( /mob/living/basic/trooper/syndicate/melee/sword/space/stormtrooper, diff --git a/code/modules/mob/living/basic/trooper/abductor.dm b/code/modules/mob/living/basic/trooper/abductor.dm new file mode 100644 index 00000000000..7f5ed6fff9b --- /dev/null +++ b/code/modules/mob/living/basic/trooper/abductor.dm @@ -0,0 +1,42 @@ +/// Abductor troopers +/mob/living/basic/trooper/abductor + name = "Abductor Agent" + desc = "Mezaflorp?" + speed = 1.1 + faction = list(ROLE_SYNDICATE) + loot = list(/obj/effect/mob_spawn/corpse/human/abductor) + mob_spawner = /obj/effect/mob_spawn/corpse/human/abductor + +/mob/living/basic/trooper/abductor/melee + melee_damage_lower = 15 + melee_damage_upper = 15 + loot = list(/obj/effect/gibspawner/human) + attack_verb_continuous = "beats" + attack_verb_simple = "beat" + attack_sound = 'sound/weapons/egloves.ogg' + attack_vis_effect = ATTACK_EFFECT_SLASH + r_hand = /obj/item/melee/baton/abductor + var/projectile_deflect_chance = 0 + +/mob/living/basic/trooper/abductor/ranged + loot = list(/obj/effect/gibspawner/human) + ai_controller = /datum/ai_controller/basic_controller/trooper/ranged + r_hand = /obj/item/gun/energy/alien + /// Type of bullet we use + var/casingtype = /obj/item/ammo_casing/energy/lasergun + /// Sound to play when firing weapon + var/projectilesound = 'sound/weapons/laser2.ogg' + /// number of burst shots + var/burst_shots = 1 + /// Time between taking shots + var/ranged_cooldown = 5 SECONDS + +/mob/living/basic/trooper/abductor/ranged/Initialize(mapload) + . = ..() + AddComponent(\ + /datum/component/ranged_attacks,\ + casing_type = casingtype,\ + projectile_sound = projectilesound,\ + cooldown_time = ranged_cooldown,\ + burst_shots = burst_shots,\ + ) diff --git a/strings/modular_maps/safehouse.toml b/strings/modular_maps/safehouse.toml index 98feaa323e3..90faf735140 100644 --- a/strings/modular_maps/safehouse.toml +++ b/strings/modular_maps/safehouse.toml @@ -1,5 +1,8 @@ directory = "_maps/safehouses/" +[rooms.abductor] +modules = ["abductor.dmm"] + [rooms.bathroom] modules = ["bathroom.dmm"] diff --git a/tgstation.dme b/tgstation.dme index 433c2e967a9..9d5a4454fc3 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -3483,6 +3483,7 @@ #include "code\modules\bitrunning\util\virtual_mob.dm" #include "code\modules\bitrunning\virtual_domain\modular_mob_segment.dm" #include "code\modules\bitrunning\virtual_domain\virtual_domain.dm" +#include "code\modules\bitrunning\virtual_domain\domains\abductor_ship.dm" #include "code\modules\bitrunning\virtual_domain\domains\ash_drake.dm" #include "code\modules\bitrunning\virtual_domain\domains\beach_bar.dm" #include "code\modules\bitrunning\virtual_domain\domains\blood_drunk_miner.dm" @@ -4809,6 +4810,7 @@ #include "code\modules\mob\living\basic\trader\trader_ai.dm" #include "code\modules\mob\living\basic\trader\trader_data.dm" #include "code\modules\mob\living\basic\trader\trader_items.dm" +#include "code\modules\mob\living\basic\trooper\abductor.dm" #include "code\modules\mob\living\basic\trooper\nanotrasen.dm" #include "code\modules\mob\living\basic\trooper\pirate.dm" #include "code\modules\mob\living\basic\trooper\russian.dm" From 207ea0f98f29cd79331e5b731fd9cbfd395a41ba Mon Sep 17 00:00:00 2001 From: Iajret Creature <122297233+Steals-The-PRs@users.noreply.github.com> Date: Sat, 9 Dec 2023 16:25:34 +0300 Subject: [PATCH 16/32] [MIRROR] General maintenance for canisters [MDB IGNORE] (#1036) * General maintenance for canisters (#80145) --------- Co-authored-by: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Co-authored-by: SyncIt21 <110812394+SyncIt21@users.noreply.github.com> --- .../__DEFINES/atmospherics/atmos_machinery.dm | 5 + code/_globalvars/lists/canisters.dm | 29 ++ .../greyscale_configs/greyscale_objects.dm | 5 - .../json_configs/canister_proto.json | 39 --- .../machinery/portable/canister.dm | 324 +++++------------- .../mecha/equipment/tools/air_tank.dm | 6 +- .../obj/pipes_n_cables/prototype_canister.dmi | Bin 1871 -> 0 bytes tgstation.dme | 1 + .../interfaces/{Canister.jsx => Canister.tsx} | 79 +++-- 9 files changed, 175 insertions(+), 313 deletions(-) create mode 100644 code/_globalvars/lists/canisters.dm delete mode 100644 code/datums/greyscale/json_configs/canister_proto.json delete mode 100644 icons/obj/pipes_n_cables/prototype_canister.dmi rename tgui/packages/tgui/interfaces/{Canister.jsx => Canister.tsx} (83%) diff --git a/code/__DEFINES/atmospherics/atmos_machinery.dm b/code/__DEFINES/atmospherics/atmos_machinery.dm index cd770ba317d..eb0f853ee94 100644 --- a/code/__DEFINES/atmospherics/atmos_machinery.dm +++ b/code/__DEFINES/atmospherics/atmos_machinery.dm @@ -77,3 +77,8 @@ ///What direction is the machine pumping (into pump/port or out to the tank/area)? #define PUMP_IN TRUE #define PUMP_OUT FALSE + +///Max allowed pressure for canisters to release air per tick +#define CAN_MAX_RELEASE_PRESSURE (ONE_ATMOSPHERE * 25) +///Min allowed pressure for canisters to release air per tick +#define CAN_MIN_RELEASE_PRESSURE (ONE_ATMOSPHERE * 0.1) diff --git a/code/_globalvars/lists/canisters.dm b/code/_globalvars/lists/canisters.dm new file mode 100644 index 00000000000..f8ec95f6020 --- /dev/null +++ b/code/_globalvars/lists/canisters.dm @@ -0,0 +1,29 @@ +///List of all the gases, used in labelling the canisters +GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) + +///Returns a map of canister id to its type path +/proc/init_gas_id_to_canister() + return sort_list(list( + GAS_N2 = /obj/machinery/portable_atmospherics/canister/nitrogen, + GAS_O2 = /obj/machinery/portable_atmospherics/canister/oxygen, + GAS_CO2 = /obj/machinery/portable_atmospherics/canister/carbon_dioxide, + GAS_PLASMA = /obj/machinery/portable_atmospherics/canister/plasma, + GAS_N2O = /obj/machinery/portable_atmospherics/canister/nitrous_oxide, + GAS_NITRIUM = /obj/machinery/portable_atmospherics/canister/nitrium, + GAS_BZ = /obj/machinery/portable_atmospherics/canister/bz, + GAS_AIR = /obj/machinery/portable_atmospherics/canister/air, + GAS_WATER_VAPOR = /obj/machinery/portable_atmospherics/canister/water_vapor, + GAS_TRITIUM = /obj/machinery/portable_atmospherics/canister/tritium, + GAS_HYPER_NOBLIUM = /obj/machinery/portable_atmospherics/canister/nob, + GAS_PLUOXIUM = /obj/machinery/portable_atmospherics/canister/pluoxium, + "caution" = /obj/machinery/portable_atmospherics/canister, + GAS_MIASMA = /obj/machinery/portable_atmospherics/canister/miasma, + GAS_FREON = /obj/machinery/portable_atmospherics/canister/freon, + GAS_HYDROGEN = /obj/machinery/portable_atmospherics/canister/hydrogen, + GAS_HEALIUM = /obj/machinery/portable_atmospherics/canister/healium, + GAS_PROTO_NITRATE = /obj/machinery/portable_atmospherics/canister/proto_nitrate, + GAS_ZAUKER = /obj/machinery/portable_atmospherics/canister/zauker, + GAS_HELIUM = /obj/machinery/portable_atmospherics/canister/helium, + GAS_ANTINOBLIUM = /obj/machinery/portable_atmospherics/canister/antinoblium, + GAS_HALON = /obj/machinery/portable_atmospherics/canister/halon + )) diff --git a/code/datums/greyscale/config_types/greyscale_configs/greyscale_objects.dm b/code/datums/greyscale/config_types/greyscale_configs/greyscale_objects.dm index 08df98148a1..7202c41ecc5 100644 --- a/code/datums/greyscale/config_types/greyscale_configs/greyscale_objects.dm +++ b/code/datums/greyscale/config_types/greyscale_configs/greyscale_objects.dm @@ -112,11 +112,6 @@ name = "Hazard Striped Canister" json_config = 'code/datums/greyscale/json_configs/canister_hazard.json' -/datum/greyscale_config/prototype_canister - name = "Prototype Canister" - icon_file = 'icons/obj/pipes_n_cables/prototype_canister.dmi' - json_config = 'code/datums/greyscale/json_configs/canister_proto.json' - /datum/greyscale_config/stationary_canister name = "Stationary Canister" icon_file = 'icons/obj/pipes_n_cables/stationary_canisters.dmi' diff --git a/code/datums/greyscale/json_configs/canister_proto.json b/code/datums/greyscale/json_configs/canister_proto.json deleted file mode 100644 index 09f19b80e9b..00000000000 --- a/code/datums/greyscale/json_configs/canister_proto.json +++ /dev/null @@ -1,39 +0,0 @@ -{ - "": [ - { - "type": "icon_state", - "icon_state": "can_base", - "blend_mode": "overlay", - "color_ids": [ 1 ] - }, - { - "type": "icon_state", - "icon_state": "can_shader", - "blend_mode": "multiply" - }, - { - "type": "icon_state", - "icon_state": "stand", - "blend_mode": "overlay" - }, - { - "type": "icon_state", - "icon_state": "decals", - "blend_mode": "overlay" - }, - [ - { - "type": "icon_state", - "icon_state": "light_base", - "blend_mode": "overlay", - "color_ids": [ 2 ] - }, - { - "type": "icon_state", - "icon_state": "light", - "blend_mode": "overlay", - "color_ids": [ 3 ] - } - ] - ] -} diff --git a/code/modules/atmospherics/machinery/portable/canister.dm b/code/modules/atmospherics/machinery/portable/canister.dm index 28c0bd93f25..c38ee248c91 100644 --- a/code/modules/atmospherics/machinery/portable/canister.dm +++ b/code/modules/atmospherics/machinery/portable/canister.dm @@ -1,33 +1,7 @@ +///The default pressure for releasing air into an holding tank or the turf #define CAN_DEFAULT_RELEASE_PRESSURE (ONE_ATMOSPHERE) - -///List of all the gases, used in labelling the canisters -GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) - -/proc/init_gas_id_to_canister() - return sort_list(list( - GAS_N2 = /obj/machinery/portable_atmospherics/canister/nitrogen, - GAS_O2 = /obj/machinery/portable_atmospherics/canister/oxygen, - GAS_CO2 = /obj/machinery/portable_atmospherics/canister/carbon_dioxide, - GAS_PLASMA = /obj/machinery/portable_atmospherics/canister/plasma, - GAS_N2O = /obj/machinery/portable_atmospherics/canister/nitrous_oxide, - GAS_NITRIUM = /obj/machinery/portable_atmospherics/canister/nitrium, - GAS_BZ = /obj/machinery/portable_atmospherics/canister/bz, - GAS_AIR = /obj/machinery/portable_atmospherics/canister/air, - GAS_WATER_VAPOR = /obj/machinery/portable_atmospherics/canister/water_vapor, - GAS_TRITIUM = /obj/machinery/portable_atmospherics/canister/tritium, - GAS_HYPER_NOBLIUM = /obj/machinery/portable_atmospherics/canister/nob, - GAS_PLUOXIUM = /obj/machinery/portable_atmospherics/canister/pluoxium, - "caution" = /obj/machinery/portable_atmospherics/canister, - GAS_MIASMA = /obj/machinery/portable_atmospherics/canister/miasma, - GAS_FREON = /obj/machinery/portable_atmospherics/canister/freon, - GAS_HYDROGEN = /obj/machinery/portable_atmospherics/canister/hydrogen, - GAS_HEALIUM = /obj/machinery/portable_atmospherics/canister/healium, - GAS_PROTO_NITRATE = /obj/machinery/portable_atmospherics/canister/proto_nitrate, - GAS_ZAUKER = /obj/machinery/portable_atmospherics/canister/zauker, - GAS_HELIUM = /obj/machinery/portable_atmospherics/canister/helium, - GAS_ANTINOBLIUM = /obj/machinery/portable_atmospherics/canister/antinoblium, - GAS_HALON = /obj/machinery/portable_atmospherics/canister/halon - )) +///The temperature resistance of this canister +#define TEMPERATURE_RESISTANCE (1000 + T0C) /obj/machinery/portable_atmospherics/canister name = "canister" @@ -44,8 +18,6 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) pressure_resistance = 7 * ONE_ATMOSPHERE req_access = list() - var/icon/canister_overlay_file = 'icons/obj/pipes_n_cables/canisters.dmi' - ///Is the valve open? var/valve_open = FALSE ///Used to log opening and closing of the valve, available on VV @@ -55,40 +27,17 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) ///Maximum pressure allowed on initialize inside the canister, multiplied by the filled var var/maximum_pressure = 90 * ONE_ATMOSPHERE ///Stores the path of the gas for mapped canisters - var/gas_type + var/datum/gas/gas_type ///Player controlled var that set the release pressure of the canister var/release_pressure = ONE_ATMOSPHERE - ///Maximum pressure allowed for release_pressure var - var/can_max_release_pressure = (ONE_ATMOSPHERE * 25) - ///Minimum pressure allower for release_pressure var - var/can_min_release_pressure = (ONE_ATMOSPHERE * 0.1) - ///Maximum amount of external heat that the canister can handle before taking damage - var/temperature_resistance = 1000 + T0C - ///Initial temperature gas mixture - var/starter_temp - // Prototype vars - ///Is the canister a prototype one? - var/prototype = FALSE - ///Timer variables - var/valve_timer = null - var/timer_set = 30 - var/default_timer_set = 30 - var/minimum_timer_set = 1 - var/maximum_timer_set = 300 - var/timing = FALSE - ///If true, the prototype canister requires engi access to be used - var/restricted = FALSE ///Window overlay showing the gas inside the canister var/image/window - + ///Is shielding turned on/off var/shielding_powered = FALSE - + ///The powercell used to enable shielding var/obj/item/stock_parts/cell/internal_cell - + ///Is the cell hatch opened var/cell_container_opened = FALSE - - var/protected_contents = FALSE - ///used while processing to update appearance only when its pressure state changes var/current_pressure_state @@ -308,46 +257,6 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) air_contents.gases[/datum/gas/nitrous_oxide][MOLES] = (N2O_ANESTHETIC * maximum_pressure * filled) * air_contents.volume / (R_IDEAL_GAS_EQUATION * air_contents.temperature) SSair.start_processing_machine(src) -/** - * Getter for the amount of time left in the timer of prototype canisters - */ -/obj/machinery/portable_atmospherics/canister/proc/get_time_left() - if(timing) - . = round(max(0, valve_timer - world.time) * 0.1, 1) - else - . = timer_set - -/** - * Starts the timer of prototype canisters - */ -/obj/machinery/portable_atmospherics/canister/proc/set_active() - timing = !timing - if(timing) - valve_timer = world.time + (timer_set SECONDS) - update_appearance() - -/obj/machinery/portable_atmospherics/canister/proto - name = "prototype canister" - greyscale_config = /datum/greyscale_config/prototype_canister - greyscale_colors = "#ffffff#a50021#ffffff" - -/obj/machinery/portable_atmospherics/canister/proto/default - name = "prototype canister" - desc = "The best way to fix an atmospheric emergency... or the best way to introduce one." - volume = 5000 - max_integrity = 300 - temperature_resistance = 2000 + T0C - can_max_release_pressure = (ONE_ATMOSPHERE * 30) - can_min_release_pressure = (ONE_ATMOSPHERE / 30) - prototype = TRUE - -/obj/machinery/portable_atmospherics/canister/proto/default/oxygen - name = "prototype canister" - desc = "A prototype canister for a prototype bike, what could go wrong?" - gas_type = /datum/gas/oxygen - filled = 1 - release_pressure = ONE_ATMOSPHERE*2 - /** * Called on Initialize(), fill the canister with the gas_type specified up to the filled level (half if 0.5, full if 1) * Used for canisters spawned in maps and by admins @@ -356,8 +265,6 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) if(!gas_type) return air_contents.add_gas(gas_type) - if(starter_temp) - air_contents.temperature = starter_temp air_contents.gases[gas_type][MOLES] = (maximum_pressure * filled) * air_contents.volume / (R_IDEAL_GAS_EQUATION * air_contents.temperature) SSair.start_processing_machine(src) @@ -376,25 +283,24 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) . = ..() if(shielding_powered) - . += mutable_appearance(canister_overlay_file, "shielding") - . += emissive_appearance(canister_overlay_file, "shielding", src) + . += mutable_appearance('icons/obj/pipes_n_cables/canisters.dmi', "shielding") + . += emissive_appearance('icons/obj/pipes_n_cables/canisters.dmi', "shielding", src) if(cell_container_opened) - . += mutable_appearance(canister_overlay_file, "cell_hatch") + . += mutable_appearance('icons/obj/pipes_n_cables/canisters.dmi', "cell_hatch") - var/isBroken = machine_stat & BROKEN ///Function is used to actually set the overlays - if(isBroken) - . += mutable_appearance(canister_overlay_file, "broken") + if(machine_stat & BROKEN) + . += mutable_appearance('icons/obj/pipes_n_cables/canisters.dmi', "broken") if(holding) - . += mutable_appearance(canister_overlay_file, "can-open") + . += mutable_appearance('icons/obj/pipes_n_cables/canisters.dmi', "can-open") if(connected_port) - . += mutable_appearance(canister_overlay_file, "can-connector") + . += mutable_appearance('icons/obj/pipes_n_cables/canisters.dmi', "can-connector") - var/light_state = get_pressure_state(air_contents.return_pressure()) + var/light_state = get_pressure_state() if(light_state) //happens when pressure is below 10kpa which means no light - . += mutable_appearance(canister_overlay_file, light_state) - . += emissive_appearance(canister_overlay_file, "[light_state]-light", src, alpha = src.alpha) + . += mutable_appearance('icons/obj/pipes_n_cables/canisters.dmi', light_state) + . += emissive_appearance('icons/obj/pipes_n_cables/canisters.dmi', "[light_state]-light", src, alpha = src.alpha) update_window() @@ -402,18 +308,20 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) . = ..() update_window() +///Updates the overlays of this canister based on its air contents /obj/machinery/portable_atmospherics/canister/proc/update_window() if(!air_contents) return + var/static/alpha_filter if(!alpha_filter) // Gotta do this separate since the icon may not be correct at world init - alpha_filter = filter(type="alpha", icon=icon(icon, "window-base")) + alpha_filter = filter(type="alpha", icon = icon('icons/obj/pipes_n_cables/canisters.dmi', "window-base")) cut_overlay(window) - window = image(icon, icon_state="window-base", layer=FLOAT_LAYER) + window = image('icons/obj/pipes_n_cables/canisters.dmi', icon_state = "window-base", layer = FLOAT_LAYER) var/list/window_overlays = list() for(var/visual in air_contents.return_visuals(get_turf(src))) - var/image/new_visual = image(visual, layer=FLOAT_LAYER) + var/image/new_visual = image(visual, layer = FLOAT_LAYER) new_visual.filters = alpha_filter window_overlays += new_visual window.overlays = window_overlays @@ -421,7 +329,7 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) // Both of these procs handle the external temperature damage. /obj/machinery/portable_atmospherics/canister/should_atmos_process(datum/gas_mixture/air, exposed_temperature) - return (exposed_temperature > temperature_resistance && !shielding_powered) + return (exposed_temperature > TEMPERATURE_RESISTANCE && !shielding_powered) /obj/machinery/portable_atmospherics/canister/atmos_expose(datum/gas_mixture/air, exposed_temperature) take_damage(5, BURN, 0) @@ -446,38 +354,40 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) var/obj/item/stock_parts/cell/active_cell = item if(!cell_container_opened) balloon_alert(user, "open the hatch first") - return + return TRUE if(!user.transferItemToLoc(active_cell, src)) - return + return TRUE if(internal_cell) user.put_in_hands(internal_cell) balloon_alert(user, "you successfully replace the cell") else balloon_alert(user, "you successfully install the cell") internal_cell = active_cell - return + return TRUE + return ..() /obj/machinery/portable_atmospherics/canister/screwdriver_act(mob/living/user, obj/item/screwdriver) - if(screwdriver.tool_behaviour != TOOL_SCREWDRIVER) - return screwdriver.play_tool_sound(src, 50) cell_container_opened = !cell_container_opened to_chat(user, span_notice("You [cell_container_opened ? "open" : "close"] the cell container hatch of [src].")) update_appearance() - return TRUE + return TOOL_ACT_TOOLTYPE_SUCCESS /obj/machinery/portable_atmospherics/canister/crowbar_act(mob/living/user, obj/item/tool) + . = TOOL_ACT_TOOLTYPE_SUCCESS + if(!cell_container_opened || !internal_cell) return + internal_cell.forceMove(drop_location()) - balloon_alert(user, "you successfully remove the cell") - return TRUE + balloon_alert(user, "cell removed") /obj/machinery/portable_atmospherics/canister/welder_act_secondary(mob/living/user, obj/item/I) - . = ..() + . = TOOL_ACT_TOOLTYPE_SUCCESS if(!I.tool_start_check(user, amount=1)) - return TRUE + return + var/pressure = air_contents.return_pressure() if(pressure > 300) to_chat(user, span_alert("The pressure gauge on [src] indicates a high pressure inside... maybe you want to reconsider?")) @@ -487,26 +397,21 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) if(I.use_tool(src, user, 3 SECONDS, volume=50)) to_chat(user, span_notice("You cut [src] apart.")) deconstruct(TRUE) - return TRUE /obj/machinery/portable_atmospherics/canister/welder_act(mob/living/user, obj/item/tool) - . = ..() + . = TOOL_ACT_TOOLTYPE_SUCCESS if(user.combat_mode) return FALSE - if(atom_integrity >= max_integrity) - return TRUE - if(machine_stat & BROKEN) - return TRUE - if(!tool.tool_start_check(user, amount=1)) - return TRUE + if(atom_integrity >= max_integrity || (machine_stat & BROKEN) || !tool.tool_start_check(user, amount = 1)) + return + to_chat(user, span_notice("You begin repairing cracks in [src]...")) while(tool.use_tool(src, user, 2.5 SECONDS, volume=40)) atom_integrity = min(atom_integrity + 25, max_integrity) if(atom_integrity >= max_integrity) to_chat(user, span_notice("You've finished repairing [src].")) - return TRUE + return to_chat(user, span_notice("You repair some of the cracks in [src]...")) - return TRUE /obj/machinery/portable_atmospherics/canister/Exited(atom/movable/gone, direction) . = ..() @@ -525,9 +430,7 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) return canister_break() -/** - * Handle canisters disassemble, releases the gas content in the turf - */ +///Handle canisters disassemble, releases the gas content in the turf /obj/machinery/portable_atmospherics/canister/proc/canister_break() disconnect() var/datum/gas_mixture/expelled_gas = air_contents.remove(air_contents.total_moles()) @@ -550,6 +453,7 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) . = ..() if(!.) return + if(close_valve) valve_open = FALSE update_appearance() @@ -558,26 +462,22 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) user.investigate_log("started a transfer into [holding].", INVESTIGATE_ATMOS) /obj/machinery/portable_atmospherics/canister/process(seconds_per_tick) - var/our_pressure = air_contents.return_pressure() var/our_temperature = air_contents.return_temperature() - protected_contents = FALSE if(shielding_powered) var/power_factor = round(log(10, max(our_pressure - pressure_limit, 1)) + log(10, max(our_temperature - temp_limit, 1))) var/power_consumed = power_factor * 250 * seconds_per_tick if(powered(AREA_USAGE_EQUIP, ignore_use_power = TRUE)) use_power(power_consumed, AREA_USAGE_EQUIP) - protected_contents = TRUE - else if(internal_cell?.use(power_consumed * 0.025)) - protected_contents = TRUE - else + else if(!internal_cell?.use(power_consumed * 0.025)) shielding_powered = FALSE SSair.start_processing_machine(src) investigate_log("shielding turned off due to power loss") ///return the icon_state component for the canister's indicator light based on its current pressure reading -/obj/machinery/portable_atmospherics/canister/proc/get_pressure_state(air_pressure) +/obj/machinery/portable_atmospherics/canister/proc/get_pressure_state() + var/air_pressure = air_contents.return_pressure() switch(air_pressure) if((40 * ONE_ATMOSPHERE) to INFINITY) return "can-3" @@ -593,9 +493,6 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) /obj/machinery/portable_atmospherics/canister/process_atmos() if(machine_stat & BROKEN) return PROCESS_KILL - if(timing && valve_timer < world.time) - valve_open = !valve_open - timing = FALSE // Handle gas transfer. if(valve_open) @@ -613,7 +510,7 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) excited = TRUE return ..() //we have already updated appearance so dont need to update again below - var/new_pressure_state = get_pressure_state(air_contents.return_pressure()) + var/new_pressure_state = get_pressure_state() if(current_pressure_state != new_pressure_state) //update apperance only when its pressure changes significantly from its current value update_appearance() current_pressure_state = new_pressure_state @@ -632,8 +529,8 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) /obj/machinery/portable_atmospherics/canister/ui_static_data(mob/user) return list( "defaultReleasePressure" = round(CAN_DEFAULT_RELEASE_PRESSURE), - "minReleasePressure" = round(can_min_release_pressure), - "maxReleasePressure" = round(can_max_release_pressure), + "minReleasePressure" = round(CAN_MIN_RELEASE_PRESSURE), + "maxReleasePressure" = round(CAN_MAX_RELEASE_PRESSURE), "pressureLimit" = round(pressure_limit), "holdingTankLeakPressure" = round(TANK_LEAK_PRESSURE), "holdingTankFragPressure" = round(TANK_FRAGMENT_PRESSURE) @@ -645,85 +542,69 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) "tankPressure" = round(air_contents.return_pressure()), "releasePressure" = round(release_pressure), "valveOpen" = !!valve_open, - "isPrototype" = !!prototype, "hasHoldingTank" = !!holding, "hasHypernobCrystal" = !!nob_crystal_inserted, "reactionSuppressionEnabled" = !!suppress_reactions ) - if (prototype) - . += list( - "restricted" = restricted, - "timing" = timing, - "time_left" = get_time_left(), - "timer_set" = timer_set, - "timer_is_not_default" = timer_set != default_timer_set, - "timer_is_not_min" = timer_set != minimum_timer_set, - "timer_is_not_max" = timer_set != maximum_timer_set - ) - if (holding) var/datum/gas_mixture/holding_mix = holding.return_air() - . += list( - "holdingTank" = list( - "name" = holding.name, - "tankPressure" = round(holding_mix.return_pressure()) - ) + .["holdingTank"] = list( + "name" = holding.name, + "tankPressure" = round(holding_mix.return_pressure()) ) + else + .["holdingTank"] = null + . += list( "shielding" = shielding_powered, - "hasCell" = (internal_cell ? TRUE : FALSE), - "cellCharge" = internal_cell?.percent() + "cellCharge" = internal_cell ? internal_cell.percent() : 0 ) /obj/machinery/portable_atmospherics/canister/ui_act(action, params) . = ..() if(.) return + switch(action) if("relabel") var/label = tgui_input_list(usr, "New canister label", "Canister", GLOB.gas_id_to_canister) if(isnull(label)) return - if(!..()) - var/newtype = GLOB.gas_id_to_canister[label] - if(newtype) - var/obj/machinery/portable_atmospherics/canister/replacement = newtype - investigate_log("was relabelled to [initial(replacement.name)] by [key_name(usr)].", INVESTIGATE_ATMOS) - name = initial(replacement.name) - desc = initial(replacement.desc) - icon_state = initial(replacement.icon_state) - base_icon_state = icon_state - set_greyscale(initial(replacement.greyscale_colors), initial(replacement.greyscale_config)) - if("restricted") - restricted = !restricted - if(restricted) - req_access = list(ACCESS_ENGINEERING) - else - req_access = list() - . = TRUE + var/newtype = GLOB.gas_id_to_canister[label] + if(isnull(newtype)) + return + var/obj/machinery/portable_atmospherics/canister/replacement = newtype + investigate_log("was relabelled to [initial(replacement.name)] by [key_name(usr)].", INVESTIGATE_ATMOS) + name = initial(replacement.name) + desc = initial(replacement.desc) + icon_state = initial(replacement.icon_state) + base_icon_state = icon_state + set_greyscale(initial(replacement.greyscale_colors), initial(replacement.greyscale_config)) + if("pressure") var/pressure = params["pressure"] if(pressure == "reset") pressure = CAN_DEFAULT_RELEASE_PRESSURE . = TRUE else if(pressure == "min") - pressure = can_min_release_pressure + pressure = CAN_MIN_RELEASE_PRESSURE . = TRUE else if(pressure == "max") - pressure = can_max_release_pressure + pressure = CAN_MAX_RELEASE_PRESSURE . = TRUE else if(pressure == "input") - pressure = tgui_input_number(usr, "New release pressure", "Canister Pressure", release_pressure, can_max_release_pressure, can_min_release_pressure) - if(!isnull(pressure) && !..()) + pressure = tgui_input_number(usr, "New release pressure", "Canister Pressure", release_pressure, CAN_MAX_RELEASE_PRESSURE, CAN_MIN_RELEASE_PRESSURE) + if(!isnull(pressure)) . = TRUE else if(text2num(pressure) != null) pressure = text2num(pressure) . = TRUE if(.) - release_pressure = clamp(round(pressure), can_min_release_pressure, can_max_release_pressure) + release_pressure = clamp(round(pressure), CAN_MIN_RELEASE_PRESSURE, CAN_MAX_RELEASE_PRESSURE) investigate_log("was set to [release_pressure] kPa by [key_name(usr)].", INVESTIGATE_ATMOS) - if("valve") //logging for openning canisters + + if("valve") var/logmsg var/admin_msg var/danger = FALSE @@ -757,24 +638,7 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) investigate_log(logmsg, INVESTIGATE_ATMOS) release_log += logmsg . = TRUE - if("timer") - var/change = params["change"] - switch(change) - if("reset") - timer_set = default_timer_set - if("decrease") - timer_set = max(minimum_timer_set, timer_set - 10) - if("increase") - timer_set = min(maximum_timer_set, timer_set + 10) - if("input") - var/user_input = tgui_input_number(usr, "Set time to valve toggle", "Canister Timer", timer_set, maximum_timer_set, minimum_timer_set) - if(isnull(user_input) || QDELETED(usr) || QDELETED(src) || !usr.can_perform_action(src, FORBID_TELEKINESIS_REACH)) - return - timer_set = user_input - log_admin("[key_name(usr)] has activated a prototype valve timer") - . = TRUE - if("toggle_timer") - set_active() + if("eject") if(holding) if(valve_open) @@ -788,7 +652,9 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) SSair.start_processing_machine(src) message_admins("[ADMIN_LOOKUPFLW(usr)] turned [shielding_powered ? "on" : "off"] the [src] powered shielding.") usr.investigate_log("turned [shielding_powered ? "on" : "off"] the [src] powered shielding.") + update_appearance() . = TRUE + if("reaction_suppression") if(!nob_crystal_inserted) stack_trace("[usr] tried to toggle reaction suppression on a canister without a noblium crystal inside, possible href exploit attempt.") @@ -798,38 +664,32 @@ GLOBAL_LIST_INIT(gas_id_to_canister, init_gas_id_to_canister()) message_admins("[ADMIN_LOOKUPFLW(usr)] turned [suppress_reactions ? "on" : "off"] the [src] reaction suppression.") usr.investigate_log("turned [suppress_reactions ? "on" : "off"] the [src] reaction suppression.") . = TRUE + if("recolor") - select_colors() + var/initial_config = initial(greyscale_config) + if(isnull(initial_config)) + return FALSE + + var/datum/greyscale_modify_menu/menu = new( + src, usr, list("[initial_config]"), CALLBACK(src, PROC_REF(recolor)), + starting_icon_state = initial(icon_state), + starting_config = initial_config, + starting_colors = initial(greyscale_colors) + ) + menu.ui_interact(usr) . = TRUE update_appearance() -/obj/machinery/portable_atmospherics/canister/proc/select_colors() - var/atom/fake_atom = src - var/list/allowed_configs = list() - var/config = initial(fake_atom.greyscale_config) - if(!config) - return - allowed_configs += "[config]" - - var/datum/greyscale_modify_menu/menu = new( - src, usr, allowed_configs, CALLBACK(src, PROC_REF(recolor)), - starting_icon_state=initial(fake_atom.icon_state), - starting_config=initial(fake_atom.greyscale_config), - starting_colors=initial(fake_atom.greyscale_colors) - ) - menu.ui_interact(usr) - /obj/machinery/portable_atmospherics/canister/proc/recolor(datum/greyscale_modify_menu/menu) - set_greyscale(menu.split_colors) + set_greyscale(menu.split_colors, menu.config.type) /obj/machinery/portable_atmospherics/canister/unregister_holding() valve_open = FALSE return ..() /obj/machinery/portable_atmospherics/canister/take_atmos_damage() - if(shielding_powered) - return FALSE - return ..() + return shielding_powered ? FALSE : ..() #undef CAN_DEFAULT_RELEASE_PRESSURE +#undef TEMPERATURE_RESISTANCE diff --git a/code/modules/vehicles/mecha/equipment/tools/air_tank.dm b/code/modules/vehicles/mecha/equipment/tools/air_tank.dm index 3062d9923bc..f00444ae598 100644 --- a/code/modules/vehicles/mecha/equipment/tools/air_tank.dm +++ b/code/modules/vehicles/mecha/equipment/tools/air_tank.dm @@ -107,8 +107,8 @@ "auto_pressurize_on_seal" = auto_pressurize_on_seal, "port_connected" = internal_tank?.connected_port ? TRUE : FALSE, "tank_release_pressure" = round(internal_tank.release_pressure), - "tank_release_pressure_min" = internal_tank.can_min_release_pressure, - "tank_release_pressure_max" = internal_tank.can_max_release_pressure, + "tank_release_pressure_min" = CAN_MIN_RELEASE_PRESSURE, + "tank_release_pressure_max" = CAN_MAX_RELEASE_PRESSURE, "tank_pump_active" = tank_pump_active, "tank_pump_direction" = tank_pump_direction, "tank_pump_pressure" = round(tank_pump_pressure), @@ -122,7 +122,7 @@ switch(action) if("set_cabin_pressure") var/new_pressure = text2num(params["new_pressure"]) - internal_tank.release_pressure = clamp(round(new_pressure), internal_tank.can_min_release_pressure, internal_tank.can_max_release_pressure) + internal_tank.release_pressure = clamp(round(new_pressure), CAN_MIN_RELEASE_PRESSURE, CAN_MAX_RELEASE_PRESSURE) return TRUE if("toggle_port") if(internal_tank.connected_port) diff --git a/icons/obj/pipes_n_cables/prototype_canister.dmi b/icons/obj/pipes_n_cables/prototype_canister.dmi deleted file mode 100644 index fb73aa2ed6d25ff3fa474cf427c56877cd06953f..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 1871 zcmb`I=~vPT7sr2)idlrmWh|An%!w97t*|sn&BrB|)KSz&#|4>^q)^co1;i!PDKd{4 zq^OMPQ>KwhsiWhPSk$;rE<-L5^dEdel;p8WfuB_5&$437?RRCtd-7>ug4Ey-t_2uEyZ1 z@(8`s(6(4<>~+`RE%HrqI0@Z#7CKm`n5@%eoWdnfJF(!{RnGZAu+Deu5-@f~V2_@Xk_m zY(`CSRYCFLUjyl=%jc>JKbhoG=-o=ve0R1;W$_bhah*z6$rWkH%{`ZiM3@`&`!U~< z26{|ffIu`gb(K+muBxBXQCG(?*m`tVa3Iqhnx0sWaQl5?;y6hBRWVaG-PqWep!mc0 zW74Vl&!3BF9ooie05KK6ek;2mnnZe+j9On>N*+r>Mzwd(&mRTE8*8dJ(@6kra`OB0 z+quiB(R#TRa{jQCus%DBAA1d<358+5+)!vOr^1_vqQ)LHc|~_RNq7Q{1TonR1{B8& zW3$=OSZr5trbqr>;rIg|tr!1=0{+!Oi_3E%W2=WcEf1FTNtWlvfd1D2hVSR&lYFla zXQ#Yc6$k=)dwa!`t=G8A-_iD&m-J!DWK#$PqD*^>Ylv+X65h+4D60lJIXUeq>H=(H z;?UIR(QWF18r;Gx=MVnChn>@w;%5+;53sT_E>xv&l9eqg0`kj9)0O7FxrfE5)uBr- zo?~i8AhE0e?po_JTv%3M^}XPbkMct_SPQpg)Qrb;hdNrv9XI};rSlrWJuMuc-jN8> z^ye_oD=SQOQN~b`dJ_u^iwp^A9|Eg&;@4~Z8z|DgT(_>GKS5L0Ru2l_hsjQc9fsnp zI`b62>3SdoYDVT)T*kokcF6VC=eVg!;SjaFgpaGPq>#VhI8ZVBk5iD_SrwQXd^wt8 zm%*#gByk>h4ekJdo31Yjs1k&MPJP5fey?6dG=bo=t>4$EXiqBW(-|r!^ysCxIK5Zc zfVH??Q=p45n?*6ec5)u1ILWs6&M3YGYM(t*5w4=k?PU``XOYpOCZ1F#$nUF;zi2I* z6y}}26U9$ufGYkpti^LkABmUE;BcW6Ef`h!HkwM^t3Jwy)WyMB)Xo?>iIoVaO( zj6`hN#mC2AXp0ndb%BffE<|bWHb@kG^BDy_?ce|g$ZN{J_9LDtM>)rLcs_d9OxoR))plDj(J=HX^JqG7mDDo!&2BVTV+=@5H;% zH9St)*ZCt@hZ&;y8+tIGU55RGNX^0owFm#16&+nAW~Ny&D{&uNE@DZ|(l#PyskCNZ zET1#C`eV%Q^ln3wPCHtLU@WDrGSF{UDz;(l87Y14V)C1VqTW&x(Y}H#pUV3*%Cl)`$SYbcTTWi z`gNKmd3G|2KO9TBd1{yaJzmzvmv``t`=AN14Mc3lx1k0&4vXcj-PwjsZ5#VOt&@vb zK;zSm3Qzrx#X86U3v+s8#zKRFrZIi{k1b$=pfdffh+buUr6eU!X3T5b04=85oXwYe zN7|0F^b=r$)!4(b!L0`wG=+4 z%6G_1+nhamLERzfk{nBPIn3O&ADn#_^#7tTg9ouL*D;3|)gKb@`j4L**EKrxFV!M@ A`2YX_ diff --git a/tgstation.dme b/tgstation.dme index 9d5a4454fc3..e57cb153d00 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -609,6 +609,7 @@ #include "code\_globalvars\time_vars.dm" #include "code\_globalvars\lists\achievements.dm" #include "code\_globalvars\lists\ambience.dm" +#include "code\_globalvars\lists\canisters.dm" #include "code\_globalvars\lists\client.dm" #include "code\_globalvars\lists\color.dm" #include "code\_globalvars\lists\crafting.dm" diff --git a/tgui/packages/tgui/interfaces/Canister.jsx b/tgui/packages/tgui/interfaces/Canister.tsx similarity index 83% rename from tgui/packages/tgui/interfaces/Canister.jsx rename to tgui/packages/tgui/interfaces/Canister.tsx index efb74f42177..87d41a4b8e1 100644 --- a/tgui/packages/tgui/interfaces/Canister.jsx +++ b/tgui/packages/tgui/interfaces/Canister.tsx @@ -1,38 +1,60 @@ import { toFixed } from 'common/math'; +import { BooleanLike } from 'common/react'; import { useBackend } from '../backend'; import { Box, Button, Flex, Icon, Knob, LabeledControls, LabeledList, RoundGauge, Section, Tooltip } from '../components'; import { formatSiUnit } from '../format'; import { Window } from '../layouts'; -const formatPressure = (value) => { +const formatPressure = (value: number) => { if (value < 10000) { return toFixed(value) + ' kPa'; } return formatSiUnit(value * 1000, 1, 'Pa'); }; +type HoldingTank = { + name: string; + tankPressure: number; +}; + +type Data = { + portConnected: BooleanLike; + tankPressure: number; + releasePressure: number; + defaultReleasePressure: number; + minReleasePressure: number; + maxReleasePressure: number; + hasHypernobCrystal: BooleanLike; + cellCharge: number; + pressureLimit: number; + valveOpen: BooleanLike; + holdingTank: HoldingTank; + holdingTankLeakPressure: number; + holdingTankFragPressure: number; + shielding: BooleanLike; + reactionSuppressionEnabled: BooleanLike; +}; + export const Canister = (props) => { - const { act, data } = useBackend(); + const { act, data } = useBackend(); const { - portConnected, + shielding, + holdingTank, + pressureLimit, + valveOpen, tankPressure, releasePressure, defaultReleasePressure, minReleasePressure, maxReleasePressure, + portConnected, + cellCharge, hasHypernobCrystal, reactionSuppressionEnabled, - hasCell, - cellCharge, - pressureLimit, - valveOpen, - isPrototype, - hasHoldingTank, - holdingTank, - holdingTankLeakPressure, holdingTankFragPressure, - restricted, + holdingTankLeakPressure, } = data; + return ( @@ -42,19 +64,10 @@ export const Canister = (props) => { title="Canister" buttons={ <> - {!!isPrototype && ( -