From 7dce459eb227272ae5ca29fd4ca9ec63b1f54fcc Mon Sep 17 00:00:00 2001 From: SkyratBot <59378654+SkyratBot@users.noreply.github.com> Date: Mon, 26 Sep 2022 02:09:38 +0200 Subject: [PATCH] [MIRROR] Captain Jetpack now fits on suit storage slot. [MDB IGNORE] (#16435) * Captain Jetpack now fits on suit storage slot. (#70107) * Adds a base modsuit chestplate allow list, cutting down on copy paste * Allows Jetpacks to work while equipped to a de-hardcoded slot_flags list * Allows the Captain's jetpack to fit on space suits and MODsuits by default * Makes the Captain's jetpack fit on the Suit storage slot. * Captain Jetpack now fits on suit storage slot. Co-authored-by: Xander3359 <66163761+Xander3359@users.noreply.github.com> --- code/game/objects/items/tanks/jetpack.dm | 5 +- .../clothing/spacesuits/_spacesuits.dm | 6 ++- code/modules/clothing/suits/_suits.dm | 6 ++- code/modules/mod/mod_clothes.dm | 5 ++ code/modules/mod/mod_control.dm | 2 +- code/modules/mod/mod_theme.dm | 51 +------------------ 6 files changed, 20 insertions(+), 55 deletions(-) diff --git a/code/game/objects/items/tanks/jetpack.dm b/code/game/objects/items/tanks/jetpack.dm index b9ce200a0c6..5639d70fd8e 100644 --- a/code/game/objects/items/tanks/jetpack.dm +++ b/code/game/objects/items/tanks/jetpack.dm @@ -30,12 +30,12 @@ AddComponent(/datum/component/jetpack, stabilizers, COMSIG_JETPACK_ACTIVATED, COMSIG_JETPACK_DEACTIVATED, JETPACK_ACTIVATION_FAILED, get_mover, check_on_move, /datum/effect_system/trail_follow/ion) /obj/item/tank/jetpack/item_action_slot_check(slot) - if(slot == ITEM_SLOT_BACK) + if(slot & slot_flags) return TRUE /obj/item/tank/jetpack/equipped(mob/user, slot, initial) . = ..() - if(on && slot != ITEM_SLOT_BACK) + if(on && !(slot & slot_flags)) turn_off(user) /obj/item/tank/jetpack/dropped(mob/user, silent) @@ -179,6 +179,7 @@ w_class = WEIGHT_CLASS_NORMAL volume = 90 resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | ACID_PROOF //steal objective items are hard to destroy. + slot_flags = ITEM_SLOT_BACK | ITEM_SLOT_SUITSTORE /obj/item/tank/jetpack/oxygen/security name = "security jetpack (oxygen)" diff --git a/code/modules/clothing/spacesuits/_spacesuits.dm b/code/modules/clothing/spacesuits/_spacesuits.dm index 60fc13caf54..b9d7f4da3be 100644 --- a/code/modules/clothing/spacesuits/_spacesuits.dm +++ b/code/modules/clothing/spacesuits/_spacesuits.dm @@ -34,7 +34,11 @@ w_class = WEIGHT_CLASS_BULKY clothing_flags = STOPSPRESSUREDAMAGE | THICKMATERIAL body_parts_covered = CHEST|GROIN|LEGS|FEET|ARMS|HANDS - allowed = list(/obj/item/flashlight, /obj/item/tank/internals) + allowed = list( + /obj/item/flashlight, + /obj/item/tank/internals, + /obj/item/tank/jetpack/oxygen/captain, + ) slowdown = 1 armor = list(MELEE = 0, BULLET = 0, LASER = 0,ENERGY = 0, BOMB = 0, BIO = 100, FIRE = 80, ACID = 70) flags_inv = HIDEGLOVES|HIDESHOES|HIDEJUMPSUIT|HIDESEXTOY|HIDETAIL //SKYRAT EDIT CHANGE - ADDED HIDETAIL. ADDED HIDESEXTOY TO PREVENT VISUAL BUGS. diff --git a/code/modules/clothing/suits/_suits.dm b/code/modules/clothing/suits/_suits.dm index 8e1c7303db5..8df2df9a1d0 100644 --- a/code/modules/clothing/suits/_suits.dm +++ b/code/modules/clothing/suits/_suits.dm @@ -4,7 +4,11 @@ lefthand_file = 'icons/mob/inhands/clothing/suits_lefthand.dmi' righthand_file = 'icons/mob/inhands/clothing/suits_righthand.dmi' var/fire_resist = T0C+100 - allowed = list(/obj/item/tank/internals/emergency_oxygen, /obj/item/tank/internals/plasmaman) + allowed = list( + /obj/item/tank/internals/emergency_oxygen, + /obj/item/tank/internals/plasmaman, + /obj/item/tank/jetpack/oxygen/captain, + ) armor = list(MELEE = 0, BULLET = 0, LASER = 0,ENERGY = 0, BOMB = 0, BIO = 0, FIRE = 0, ACID = 0) drop_sound = 'sound/items/handling/cloth_drop.ogg' pickup_sound = 'sound/items/handling/cloth_pickup.ogg' diff --git a/code/modules/mod/mod_clothes.dm b/code/modules/mod/mod_clothes.dm index fc7d0c55ac1..597aeaaa764 100644 --- a/code/modules/mod/mod_clothes.dm +++ b/code/modules/mod/mod_clothes.dm @@ -17,6 +17,11 @@ icon_state = "chestplate" worn_icon = 'icons/mob/clothing/modsuit/mod_clothing.dmi' blood_overlay_type = "armor" + allowed = list( + /obj/item/tank/internals, + /obj/item/flashlight, + /obj/item/tank/jetpack/oxygen/captain, + ) armor = list(MELEE = 0, BULLET = 0, LASER = 0, ENERGY = 0, BOMB = 0, BIO = 0, FIRE = 0, ACID = 0, WOUND = 0) body_parts_covered = CHEST|GROIN heat_protection = CHEST|GROIN diff --git a/code/modules/mod/mod_control.dm b/code/modules/mod/mod_control.dm index 58ce64c4546..cc9b2ab405e 100644 --- a/code/modules/mod/mod_control.dm +++ b/code/modules/mod/mod_control.dm @@ -114,7 +114,7 @@ helmet = new /obj/item/clothing/head/mod(src) mod_parts += helmet chestplate = new /obj/item/clothing/suit/mod(src) - chestplate.allowed = typecacheof(theme.allowed_suit_storage) + chestplate.allowed += typecacheof(theme.allowed_suit_storage) mod_parts += chestplate gauntlets = new /obj/item/clothing/gloves/mod(src) mod_parts += gauntlets diff --git a/code/modules/mod/mod_theme.dm b/code/modules/mod/mod_theme.dm index 184fef249b7..4cbbf928b7e 100644 --- a/code/modules/mod/mod_theme.dm +++ b/code/modules/mod/mod_theme.dm @@ -48,10 +48,7 @@ /// Modules blacklisted from the MOD. var/list/module_blacklist = list() /// Allowed items in the chestplate's suit storage. - var/list/allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, - ) + var/list/allowed_suit_storage = list() /// List of skins with their appropriate clothing flags. var/list/skins = list( "standard" = list( @@ -122,9 +119,7 @@ allowed_suit_storage = list( /obj/item/construction/rcd, /obj/item/fireaxe/metal_h2_axe, - /obj/item/flashlight, /obj/item/storage/bag/construction, - /obj/item/tank/internals, ) skins = list( "engineering" = list( @@ -171,10 +166,8 @@ allowed_suit_storage = list( /obj/item/analyzer, /obj/item/fireaxe/metal_h2_axe, - /obj/item/flashlight, /obj/item/pipe_dispenser, /obj/item/t_scanner, - /obj/item/tank/internals, ) skins = list( "atmospheric" = list( @@ -225,12 +218,10 @@ /obj/item/analyzer, /obj/item/construction/rcd, /obj/item/fireaxe/metal_h2_axe, - /obj/item/flashlight, /obj/item/melee/baton/telescopic, /obj/item/pipe_dispenser, /obj/item/storage/bag/construction, /obj/item/t_scanner, - /obj/item/tank/internals, ) skins = list( "advanced" = list( @@ -288,8 +279,6 @@ complexity_max = DEFAULT_MAX_COMPLEXITY - 5 charge_drain = DEFAULT_CHARGE_DRAIN * 2 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/resonator, /obj/item/mining_scanner, /obj/item/t_scanner/adv_mining_scanner, @@ -373,8 +362,6 @@ slowdown_inactive = 0.5 slowdown_active = 0 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/mail, /obj/item/delivery/small, /obj/item/paper, @@ -419,8 +406,6 @@ slowdown_inactive = 1 slowdown_active = 0.5 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/healthanalyzer, /obj/item/reagent_containers/dropper, /obj/item/reagent_containers/cup/beaker, @@ -505,8 +490,6 @@ slowdown_active = 0.25 inbuilt_modules = list(/obj/item/mod/module/quick_carry/advanced) allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/healthanalyzer, /obj/item/reagent_containers/dropper, /obj/item/reagent_containers/cup/beaker, @@ -569,8 +552,6 @@ slowdown_active = 1.25 inbuilt_modules = list(/obj/item/mod/module/reagent_scanner/advanced) allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/analyzer, /obj/item/dnainjector, /obj/item/biopsy_tool, @@ -620,8 +601,6 @@ slowdown_inactive = 1 slowdown_active = 0.5 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/reagent_containers/spray/pepper, @@ -674,8 +653,6 @@ slowdown_inactive = 0.75 slowdown_active = 0.25 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/reagent_containers/spray/pepper, @@ -732,8 +709,6 @@ slowdown_inactive = 0.75 slowdown_active = 0.25 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/restraints/handcuffs, @@ -782,8 +757,6 @@ slowdown_inactive = 1.75 slowdown_active = 1.25 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/bikehorn, /obj/item/food/grown/banana, /obj/item/grown/bananapeel, @@ -838,8 +811,6 @@ ui_theme = "syndicate" inbuilt_modules = list(/obj/item/mod/module/armor_booster) allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/restraints/handcuffs, @@ -921,8 +892,6 @@ ui_theme = "syndicate" inbuilt_modules = list(/obj/item/mod/module/armor_booster) allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/restraints/handcuffs, @@ -980,8 +949,6 @@ ui_theme = "wizard" inbuilt_modules = list(/obj/item/mod/module/anti_magic/wizard) allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/teleportation_scroll, /obj/item/highfrequencyblade/wizard, /obj/item/gun/magic, @@ -1032,8 +999,6 @@ ui_theme = "hackerman" inbuilt_modules = list(/obj/item/mod/module/welding/camera_vision, /obj/item/mod/module/hacker, /obj/item/mod/module/weapon_recall, /obj/item/mod/module/adrenaline_boost, /obj/item/mod/module/energy_net) allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/gun, /obj/item/ammo_box, /obj/item/ammo_casing, @@ -1089,8 +1054,6 @@ ui_theme = "hackerman" inbuilt_modules = list(/obj/item/mod/module/anomaly_locked/kinesis/prebuilt/prototype) allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/analyzer, /obj/item/t_scanner, /obj/item/pipe_dispenser, @@ -1140,8 +1103,6 @@ slowdown_inactive = 0.5 slowdown_active = 0 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/restraints/handcuffs, @@ -1217,8 +1178,6 @@ siemens_coefficient = 0 complexity_max = DEFAULT_MAX_COMPLEXITY + 10 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/restraints/handcuffs, @@ -1272,8 +1231,6 @@ slowdown_inactive = 0.5 slowdown_active = 0 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/restraints/handcuffs, @@ -1323,8 +1280,6 @@ slowdown_inactive = 0 slowdown_active = 0 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/restraints/handcuffs, ) skins = list( @@ -1371,8 +1326,6 @@ slowdown_inactive = 0.5 slowdown_active = 0 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/gun, ) skins = list( @@ -1422,8 +1375,6 @@ slowdown_inactive = 0 slowdown_active = 0 allowed_suit_storage = list( - /obj/item/flashlight, - /obj/item/tank/internals, /obj/item/gun, ) skins = list(