From f1f51a597c51e5bfadc9fd8b18372b9d3a64f704 Mon Sep 17 00:00:00 2001 From: Cameron Lennox Date: Mon, 21 Apr 2025 18:25:05 -0400 Subject: [PATCH] More PSG changes (#17503) * Berserker PSG * Makes PSGs more acquirable. - Makes PSGs more acquirable - Standardizes the PSG names (PSG Variant-XXX) - Adds the PSG-BIO to the CMO's locker and CMO supply crate(Just reduces toxin/oxygen/clone attack damage taken) - Adds the PSG-Melee to the Pathfinder locker - Adds the PSG-BIO to the Pathfinder Medic locker - Adds the PSG-S to HoS locker (and HoS supply pack) - Makes it so the Exploration shield pack has a melee and upgraded mining (mob combat) PSG --- code/datums/supplypacks/medical.dm | 3 +- code/datums/supplypacks/misc.dm | 6 +- code/datums/supplypacks/security.dm | 3 +- code/datums/supplypacks/supply.dm | 3 +- .../devices/personal_shield_generator_vr.dm | 63 ++++++++++++++----- .../crates_lockers/closets/misc_vr.dm | 6 +- .../crates_lockers/closets/secure/medical.dm | 5 +- .../closets/secure/security_vr.dm | 3 +- code/modules/mob/_modifiers/modifiers_misc.dm | 8 +++ code/modules/mob/_modifiers/modifiers_vr.dm | 42 +++++++++++++ .../human/species/station/traits/negative.dm | 10 +++ code/modules/projectiles/gun.dm | 13 ++++ 12 files changed, 140 insertions(+), 25 deletions(-) diff --git a/code/datums/supplypacks/medical.dm b/code/datums/supplypacks/medical.dm index 7bf3047c089..5b797bd885a 100644 --- a/code/datums/supplypacks/medical.dm +++ b/code/datums/supplypacks/medical.dm @@ -148,7 +148,8 @@ /obj/item/clothing/gloves/sterile/latex, /obj/item/healthanalyzer, /obj/item/flashlight/pen, - /obj/item/reagent_containers/syringe + /obj/item/reagent_containers/syringe, + /obj/item/personal_shield_generator/belt/medical/loaded ) cost = 50 containertype = /obj/structure/closet/crate/secure/nanomed diff --git a/code/datums/supplypacks/misc.dm b/code/datums/supplypacks/misc.dm index 7d0ae461c7c..661ed31067f 100644 --- a/code/datums/supplypacks/misc.dm +++ b/code/datums/supplypacks/misc.dm @@ -250,11 +250,13 @@ /datum/supply_pack/randomised/misc/explorer_shield name = JOB_EXPLORER + " shield" - desc = "A pair of shields for use by away teams. Requires EVA or Pilot's access." + desc = "Two Physical and Two PSG shields for use by away teams. Requires EVA or Pilot's access." num_contained = 2 contains = list( /obj/item/shield/riot/explorer, - /obj/item/shield/riot/explorer/purple + /obj/item/shield/riot/explorer/purple, + /obj/item/personal_shield_generator/belt/melee, + /obj/item/personal_shield_generator/belt/mining/upgraded ) cost = 75 containertype = /obj/structure/closet/crate/secure/gear diff --git a/code/datums/supplypacks/security.dm b/code/datums/supplypacks/security.dm index 68e61efccbb..493807898c1 100644 --- a/code/datums/supplypacks/security.dm +++ b/code/datums/supplypacks/security.dm @@ -627,7 +627,8 @@ /obj/item/melee/telebaton, /obj/item/shield/riot/tele, /obj/item/clothing/head/beret/sec/corporate/hos, - /obj/item/flashlight/maglight + /obj/item/flashlight/maglight, + /obj/item/personal_shield_generator/belt/security/loaded ) cost = 50 containertype = /obj/structure/closet/crate/secure/nanotrasen diff --git a/code/datums/supplypacks/supply.dm b/code/datums/supplypacks/supply.dm index 1a8935982db..e3f408ddd5d 100644 --- a/code/datums/supplypacks/supply.dm +++ b/code/datums/supplypacks/supply.dm @@ -252,7 +252,8 @@ /obj/item/clothing/accessory/holster/machete, /obj/item/storage/box/explorerkeys, /obj/item/mapping_unit, - /obj/item/clothing/accessory/watch/survival + /obj/item/clothing/accessory/watch/survival, + /obj/item/personal_shield_generator/belt/melee/loaded ) cost = 75 containertype = /obj/structure/closet/crate/secure/xion diff --git a/code/game/objects/items/devices/personal_shield_generator_vr.dm b/code/game/objects/items/devices/personal_shield_generator_vr.dm index 09eaf2cb08a..e62e0199a35 100644 --- a/code/game/objects/items/devices/personal_shield_generator_vr.dm +++ b/code/game/objects/items/devices/personal_shield_generator_vr.dm @@ -29,7 +29,7 @@ actions_types = list(/datum/action/item_action/toggle_shield) var/obj/item/gun/energy/gun/generator/active_weapon var/obj/item/cell/device/bcell = null - var/upgraded = 0 // If the PSG has been upgraded by some method or not. Only used for the mining belt ATM. + var/upgraded = FALSE // If the PSG has been upgraded by some method or not. Only used for the mining belt ATM. var/generator_hit_cost = 100 // Power used when a special effect (such as a bullet being blocked) is performed! Could also be expanded to other things. @@ -485,13 +485,21 @@ // Mining belts /obj/item/personal_shield_generator/belt/mining - name = "mining PSG" - desc = "A personal shield generator designed for mining. It has a warning on the back: 'Do NOT expose the shield to stun-based weaponry.'" + name = "PSG Variant-M" + desc = "A personal shield generator designed for mining and combat with hostile creatures. \ + It has a warning on the back: 'Do NOT expose the shield to stun-based weaponry.'" modifier_type = /datum/modifier/shield_projection/mining /obj/item/personal_shield_generator/belt/mining/loaded bcell = /obj/item/cell/device/shield_generator +/obj/item/personal_shield_generator/belt/mining/upgraded + upgraded = TRUE + modifier_type = /datum/modifier/shield_projection/mining/strong + +/obj/item/personal_shield_generator/belt/mining/upgraded/loaded + bcell = /obj/item/cell/device/shield_generator + /obj/item/personal_shield_generator/belt/mining/update_icon() if(shield_active) icon_state = "shieldpack_mining_on" @@ -512,7 +520,7 @@ to_chat(user, span_warning("This shield generator is already upgraded!")) return modifier_type = /datum/modifier/shield_projection/mining/strong - upgraded = 1 + upgraded = TRUE to_chat(user, span_notice("You upgrade the [src] with the [W]!")) user.drop_from_inventory(W) qdel(W) @@ -523,7 +531,7 @@ //Security belts /obj/item/personal_shield_generator/belt/security - name = "security PSG" + name = "PSG Variant-S" desc = "A personal shield generator designed for security." modifier_type = /datum/modifier/shield_projection/security/weak @@ -536,19 +544,34 @@ else icon_state = "shieldpack_security" -//Misc belts. Admin-spawn only atm. +//PvE focused belt +/obj/item/personal_shield_generator/belt/melee + name = "PSG Variant-B" + desc = "A personal shield generator that creates a field that prevents the functionality of firearms in exchange \ + for enhanceing melee potential. The shield makes its user more resistant to brute and burn, \ + makes them harder to hit, able to hit harder, able to hit faster, allows faster movement, and \ + allows the user to get up from disabling strikes faster." + damage_cost = 5 -/obj/item/personal_shield_generator/belt/adminbus - desc = DEVELOPER_WARNING_NAME + " You REALLY should not see this. If you do, you have either been blessed or are about to be the target of some sick prank." - modifier_type = /datum/modifier/shield_projection/admin - generator_hit_cost = 0 - generator_active_cost = 0 - shield_active = 0 - damage_cost = 0 + modifier_type = /datum/modifier/shield_projection/melee_focus + +/obj/item/personal_shield_generator/belt/melee/loaded + bcell = /obj/item/cell/device/shield_generator + +//Misc belts. + +/obj/item/personal_shield_generator/belt/medical + name = "PSG Variant-BIO" + desc = "A personal shield generator that creates a field that helps against biohazards \ + for enhanceing melee potential. The shield makes its user resistant to toxic attacks, suffocating attacks, and DNA attacks" + + modifier_type = /datum/modifier/shield_projection/biohazard + +/obj/item/personal_shield_generator/belt/medical/loaded bcell = /obj/item/cell/device/shield_generator /obj/item/personal_shield_generator/belt/parry //The 'provides one second of pure immunity to brute/burn/halloss' belt. - name = "PSG variant-P" //Not meant to be used in any serious capacity. + name = "PSG Variant-P" //Not meant to be used in any serious capacity. desc = "A personal shield generator that sacrifices long-term usability in exchange for a strong, short-lived shield projection, enabling the user to be nigh \ impervious for a second." modifier_type = /datum/modifier/shield_projection/parry @@ -558,11 +581,21 @@ shield_active = 0 bcell = /obj/item/cell/device/shield_generator/parry +//Badmin belt +/obj/item/personal_shield_generator/belt/adminbus + desc = DEVELOPER_WARNING_NAME + " You REALLY should not see this. If you do, you have either been blessed or are about to be the target of some sick prank." + modifier_type = /datum/modifier/shield_projection/admin + generator_hit_cost = 0 + generator_active_cost = 0 + shield_active = 0 + damage_cost = 0 + bcell = /obj/item/cell/device/shield_generator + // Backpacks. These are meant to be MUCH stronger in exchange for the fact that you are giving up a backpack slot. // HOWEVER, be careful with these. They come loaded with a gun in them, so they shouldn't be handed out willy-nilly. /obj/item/personal_shield_generator/security - name = "security PSG" + name = "Backpack PSG Variant-S" desc = "A personal shield generator designed for security. Comes with a built in defense pistol." modifier_type = /datum/modifier/shield_projection/security diff --git a/code/game/objects/structures/crates_lockers/closets/misc_vr.dm b/code/game/objects/structures/crates_lockers/closets/misc_vr.dm index 047cfb5369d..234ac7d4190 100644 --- a/code/game/objects/structures/crates_lockers/closets/misc_vr.dm +++ b/code/game/objects/structures/crates_lockers/closets/misc_vr.dm @@ -121,7 +121,8 @@ /obj/item/reagent_containers/food/snacks/liquidfood, /obj/item/reagent_containers/food/snacks/liquidprotein, /obj/item/cataloguer/compact/pathfinder, - /obj/item/mapping_unit) + /obj/item/mapping_unit, + /obj/item/personal_shield_generator/belt/melee/loaded) /obj/structure/closet/secure_closet/pathfinder/Initialize(mapload) if(prob(50)) @@ -171,7 +172,8 @@ /obj/item/gps/medical, /obj/item/geiger, /obj/item/bodybag/cryobag, - /obj/item/cataloguer/compact) + /obj/item/cataloguer/compact, + /obj/item/personal_shield_generator/belt/medical/loaded) /obj/structure/closet/secure_closet/sar/Initialize(mapload) if(prob(50)) diff --git a/code/game/objects/structures/crates_lockers/closets/secure/medical.dm b/code/game/objects/structures/crates_lockers/closets/secure/medical.dm index 5ed99b24eb6..d9615d4c2a3 100644 --- a/code/game/objects/structures/crates_lockers/closets/secure/medical.dm +++ b/code/game/objects/structures/crates_lockers/closets/secure/medical.dm @@ -161,8 +161,9 @@ /obj/item/clothing/suit/bio_suit/cmo, /obj/item/clothing/head/bio_hood/cmo, /obj/item/clothing/shoes/white, - /obj/item/reagent_containers/glass/beaker/vial, //VOREStation Add - /obj/item/storage/belt/medical) //VOREStation Add + /obj/item/reagent_containers/glass/beaker/vial, + /obj/item/storage/belt/medical, + /obj/item/personal_shield_generator/belt/medical/loaded) /obj/structure/closet/secure_closet/CMO/Initialize(mapload) if(prob(50)) diff --git a/code/game/objects/structures/crates_lockers/closets/secure/security_vr.dm b/code/game/objects/structures/crates_lockers/closets/secure/security_vr.dm index b65d1a243ab..4367c57dac5 100644 --- a/code/game/objects/structures/crates_lockers/closets/secure/security_vr.dm +++ b/code/game/objects/structures/crates_lockers/closets/secure/security_vr.dm @@ -63,7 +63,8 @@ /obj/item/clothing/head/beret/sec/corporate/hos, /obj/item/clothing/suit/storage/hooded/wintercoat/security, /obj/item/clothing/shoes/boots/winter/security, - /obj/item/flashlight/maglight) + /obj/item/flashlight/maglight, + /obj/item/personal_shield_generator/security/loaded) //Custom NT Security Lockers, Only found at central command /obj/structure/closet/secure_closet/nanotrasen_security diff --git a/code/modules/mob/_modifiers/modifiers_misc.dm b/code/modules/mob/_modifiers/modifiers_misc.dm index 7a7df3dcce9..4095911a0e8 100644 --- a/code/modules/mob/_modifiers/modifiers_misc.dm +++ b/code/modules/mob/_modifiers/modifiers_misc.dm @@ -437,3 +437,11 @@ the artifact triggers the rage. stacks = MODIFIER_STACK_EXTEND slowdown = 2 + +/datum/modifier/trait/thickdigits + name = "Thick Digits" + desc = "Your hands cannot properly wield weapons." + +/datum/modifier/rednet //Not used here currently, but used downstream. Todo: Port it. + mob_overlay_state = "red_electricity_constant" + slowdown = 1 diff --git a/code/modules/mob/_modifiers/modifiers_vr.dm b/code/modules/mob/_modifiers/modifiers_vr.dm index 21bf74436d7..cd7a748d55a 100644 --- a/code/modules/mob/_modifiers/modifiers_vr.dm +++ b/code/modules/mob/_modifiers/modifiers_vr.dm @@ -333,3 +333,45 @@ max_hal_resistance = 0 min_hal_resistance = 0 effective_hal_resistance = 1 + +/datum/modifier/shield_projection/melee_focus + + //You are expected to be taking a LOT more hits while this is up. + damage_cost = 5 + + //.50% resistance at a full charge, 35% resistance at when we're about to empty. + max_brute_resistance = 0.5 + min_brute_resistance = 0.65 + effective_brute_resistance = 1 + + //.50% resistance at a full charge, 35% resistance at when we're about to empty. + max_fire_resistance = 0.5 + min_fire_resistance = 0.65 + effective_fire_resistance = 1 + + //500% damage taken from halloss. Anti PVP. This is meant to be a PvE weapon. + //This also means that mobs that deal halloss will wreck users of this...Those are (extremely) rare as far as I know. + min_hal_resistance = 5 + max_hal_resistance = 5 + effective_hal_resistance = 1 + + //Stuns are HALF as long. Get stunned for 4 seconds? Only stunned for 2, now. + disable_duration_percent = 0.5 + + //You are QUITE harder to shoot. + evasion = 35 + + //You move SOMEWHAT faster. + slowdown = -0.5 + + //You can't shoot, though. This isn't actually used as this modifier is checked in gun.dm, but it's here anyways. + accuracy = -1000 + + //You attack SOMEWHAT faster + attack_speed_percent = 0.8 + + //You hit SOMEWHAT harder + outgoing_melee_damage_percent = 1.25 + + //You bleed SLIGHTLY slower, since you are taking more hits. + bleeding_rate_percent = 0.75 diff --git a/code/modules/mob/living/carbon/human/species/station/traits/negative.dm b/code/modules/mob/living/carbon/human/species/station/traits/negative.dm index d2e9eb74d7d..dcf4007e513 100644 --- a/code/modules/mob/living/carbon/human/species/station/traits/negative.dm +++ b/code/modules/mob/living/carbon/human/species/station/traits/negative.dm @@ -714,6 +714,16 @@ cost = -5 var_changes = list("dirtslip" = TRUE) +/datum/trait/negative/thick_digits + name = "Thick Digits" + desc = "Your hands are not shaped in a way that allows useage of guns." + cost = -4 + custom_only = FALSE + +/datum/trait/negative/thick_digits/apply(var/datum/species/S,var/mob/living/carbon/human/H) + ..() + H.add_modifier(/datum/modifier/trait/thickdigits) + /datum/trait/negative/nodefib name = "Unreviveable" desc = "For whatever strange genetic reason, defibs cannot restart your heart." diff --git a/code/modules/projectiles/gun.dm b/code/modules/projectiles/gun.dm index f1c3db95193..dc9c21e0f2e 100644 --- a/code/modules/projectiles/gun.dm +++ b/code/modules/projectiles/gun.dm @@ -183,6 +183,19 @@ return 0 var/mob/living/M = user + if(istype(M)) + if(M.has_modifier_of_type(/datum/modifier/underwater_stealth)) + to_chat(user,span_warning("You cannot use guns whilst hiding underwater!")) + return 0 + else if(M.has_modifier_of_type(/datum/modifier/rednet)) + to_chat(user,span_warning("Your gun refuses to fire!")) + return 0 + else if(M.has_modifier_of_type(/datum/modifier/trait/thickdigits)) + to_chat(user,span_warning("Your hands can't pull the trigger!!")) + return 0 + else if(M.has_modifier_of_type(/datum/modifier/shield_projection/melee_focus)) + to_chat(user,span_warning("The shield projection around you prevents you from using anything but melee!!")) + return 0 if(dna_lock && attached_lock.stored_dna) if(!authorized_user(user)) if(attached_lock.safety_level == 0)