From f4fee8e13666f4154bc52d24f6df6810fb21426b Mon Sep 17 00:00:00 2001 From: Iamgoofball Date: Mon, 3 Aug 2026 23:54:19 -0700 Subject: [PATCH 01/10] pushing work for now --- .../~darkpack/traits/declarations.dm | 1 + code/_globalvars/traits/_traits.dm | 1 + code/_globalvars/traits/admin_tooling.dm | 1 + .../subsystem/processing/personality.dm | 4 + code/modules/jobs/job_types/_job.dm | 2 + config/game_options.txt | 2 +- modular_darkpack/modules/cars/code/car.dm | 24 +- .../modules/cars/code/car_actions.dm | 2 +- .../doors/code/components/door_ownership.dm | 2 +- .../modules/doors/code/vampdoor.dm | 9 +- .../modules/economy/code/credit_card.dm | 4 +- .../modules/economy/code/dollar.dm | 3 +- .../modules/government/code/passport.dm | 4 + modular_darkpack/modules/jobs/code/_jobs.dm | 96 ++++++++ .../jobs/code/miscelllaneous/citizen.dm | 3 +- .../modules/jobs/code/police/captain.dm | 4 +- .../modules/jobs/code/police/dispatcher.dm | 4 +- .../modules/jobs/code/police/fbi.dm | 5 +- .../modules/jobs/code/police/police.dm | 6 +- .../modules/jobs/code/police/sergeant.dm | 8 +- .../modules/goofcode/door_improvements.dm | 214 ++++++++++++++++++ modular_vcg/modules/goofcode/icons/docs.dmi | Bin 0 -> 390 bytes .../modules/goofcode/icons/docsonfloor.dmi | Bin 0 -> 263 bytes .../modules/goofcode/personality_disables.dm | 8 + modular_vcg/modules/goofcode/state_id.dm | 35 +++ tgstation.dme | 3 + .../CharacterPreferences/QuirksPage.tsx | 14 +- 27 files changed, 425 insertions(+), 34 deletions(-) create mode 100644 modular_vcg/modules/goofcode/door_improvements.dm create mode 100644 modular_vcg/modules/goofcode/icons/docs.dmi create mode 100644 modular_vcg/modules/goofcode/icons/docsonfloor.dmi create mode 100644 modular_vcg/modules/goofcode/personality_disables.dm create mode 100644 modular_vcg/modules/goofcode/state_id.dm diff --git a/code/__DEFINES/~darkpack/traits/declarations.dm b/code/__DEFINES/~darkpack/traits/declarations.dm index 00643bc96b5e..89843c08b0c8 100644 --- a/code/__DEFINES/~darkpack/traits/declarations.dm +++ b/code/__DEFINES/~darkpack/traits/declarations.dm @@ -199,5 +199,6 @@ Remember to update _globalvars/traits.dm if you're adding/removing/renaming trai #define TRAIT_GLOWING_EYES "glowing_eyes" #define TRAIT_PROMETHEAN_CLAY "promethean_clay" #define TRAIT_UNCONTROLLABLE "uncontrollable" +#define TRAIT_UNDOCUMENTED "undocumented" // GOVERNMENT // END TRAIT DEFINES diff --git a/code/_globalvars/traits/_traits.dm b/code/_globalvars/traits/_traits.dm index 6bdc61f5a5ff..a820571caef8 100644 --- a/code/_globalvars/traits/_traits.dm +++ b/code/_globalvars/traits/_traits.dm @@ -792,6 +792,7 @@ GLOBAL_LIST_INIT(traits_by_type, list( "TRAIT_WEAK_WILLED" = TRAIT_WEAK_WILLED, // DARKPACK EDIT ADD - MERITS_FLAWS "TRAIT_WYRMTAINTED" = TRAIT_WYRMTAINTED, // DARKPACK EDIT ADD - WEREWOLF "TRAIT_WYRMTAINTED_SPRITE" = TRAIT_WYRMTAINTED_SPRITE, // DARKPACK EDIT ADD - WEREWOLF + "TRAIT_UNDOCUMENTED" = TRAIT_UNDOCUMENTED, // CRIMSON GRID EDIT ADD - Undocumented quirk ), /mob/living/carbon = list( "TRAIT_BRAINLESS_CARBON" = TRAIT_BRAINLESS_CARBON, diff --git a/code/_globalvars/traits/admin_tooling.dm b/code/_globalvars/traits/admin_tooling.dm index da65cfa50859..d39969c3b68b 100644 --- a/code/_globalvars/traits/admin_tooling.dm +++ b/code/_globalvars/traits/admin_tooling.dm @@ -458,6 +458,7 @@ GLOBAL_LIST_INIT(admin_visible_traits, list( "TRAIT_WEAK_WILLED" = TRAIT_WEAK_WILLED, // DARKPACK EDIT ADD - MERITS_FLAWS "TRAIT_WYRMTAINTED" = TRAIT_WYRMTAINTED, // DARKPACK EDIT ADD - WEREWOLF "TRAIT_WYRMTAINTED_SPRITE" = TRAIT_WYRMTAINTED_SPRITE, // DARKPACK EDIT ADD - WEREWOLF + "TRAIT_UNDOCUMENTED" = TRAIT_UNDOCUMENTED, // CRIMSON GRID EDIT ADD - Undocumented quirk ), /obj/item = list( "TRAIT_APC_SHOCKING" = TRAIT_APC_SHOCKING, diff --git a/code/controllers/subsystem/processing/personality.dm b/code/controllers/subsystem/processing/personality.dm index 8b642edd84a5..0223509a7941 100644 --- a/code/controllers/subsystem/processing/personality.dm +++ b/code/controllers/subsystem/processing/personality.dm @@ -31,6 +31,10 @@ PROCESSING_SUBSYSTEM_DEF(personalities) if(isnull(personality_key)) // Abstract personality, ignore continue + /// CRIMSON GRID EDIT: Adds disabling specific personalities. + if(personality_type::disabled_vtm) + continue + /// CRIMSON GRID EDIT END if(personalities_by_key[personality_key]) stack_trace("Personality save key collision! \ key: [personality_key] - \ diff --git a/code/modules/jobs/job_types/_job.dm b/code/modules/jobs/job_types/_job.dm index 3d9c11900f15..b328a8057108 100644 --- a/code/modules/jobs/job_types/_job.dm +++ b/code/modules/jobs/job_types/_job.dm @@ -218,6 +218,7 @@ account_id = bank_account.account_id bank_account.replaceable = FALSE // DARKPACK EDIT ADD - (Finance affects starting money) + /* CRIMSON EDIT - moved to the wallet population cuz we calc streetwise into it var/finance = st_get_stat(STAT_FINANCE) switch(finance) if(0) @@ -239,6 +240,7 @@ if(5) bank_account.account_balance = rand(2000, 3000) bank_account.paycheck_amount = 250 + CRIMSON EDIT END */ // DARKPACK EDIT ADD END add_mob_memory(/datum/memory/key/account, remembered_id = account_id) add_mob_memory(/datum/memory/key/bank_pin, remembered_id = bank_account.bank_pin) // DARKPACK EDIT ADD diff --git a/config/game_options.txt b/config/game_options.txt index c58c96e122ec..34ca196806f7 100644 --- a/config/game_options.txt +++ b/config/game_options.txt @@ -487,7 +487,7 @@ MICE_ROUNDSTART 10 ROUNDSTART_TRAITS ## Uncomment to disable human moods. -DISABLE_HUMAN_MOOD +#DISABLE_HUMAN_MOOD ## Enable night shifts #ENABLE_NIGHT_SHIFTS diff --git a/modular_darkpack/modules/cars/code/car.dm b/modular_darkpack/modules/cars/code/car.dm index 0e41f33c4b5d..951ceda43d17 100644 --- a/modular_darkpack/modules/cars/code/car.dm +++ b/modular_darkpack/modules/cars/code/car.dm @@ -532,8 +532,12 @@ log_combat(driver, L, "hit with", src) var/dam = prev_speed if(driver) - var/driver_skill = clamp(driver.st_get_stat(STAT_DRIVE)/2, 1, 4) - dam = round(dam/driver_skill) + if(driver.st_get_stat(STAT_DRIVE)) // no protection at 0 + var/driver_skill = clamp(driver.st_get_stat(STAT_DRIVE)/2, 1, 4) + dam = round(dam/driver_skill) + else + dam = round(dam) + dam = dam * (1 + 100/driver.get_drunk_amount()) // WE LOVE DUIS driver.apply_damage(prev_speed, BRUTE, BODY_ZONE_CHEST) take_damage(dam) return @@ -718,21 +722,25 @@ controlling(0, -turn_speed) /obj/darkpack_car/proc/controlling(adjusting_speed, adjusting_turn) - var/drift = clamp(driver.st_get_stat(STAT_DRIVE)/4, 0.25, 4) + var/drift + if(!driver.st_get_stat(STAT_DRIVE) || driver.get_drunk_amount()) // 0 drive??? + drift = rand(0.05, 3) + else + drift = clamp(1/driver.st_get_stat(STAT_DRIVE), 0.2, 1) var/adjust_true = adjusting_turn if(speed_in_pixels != 0) - movement_vector = SIMPLIFY_DEGREES(movement_vector+adjust_true) + movement_vector = SIMPLIFY_DEGREES((movement_vector+adjust_true)*drift) apply_vector_angle() if(adjusting_speed) if(on) if(adjusting_speed > 0 && speed_in_pixels <= 0) playsound(src, 'modular_darkpack/modules/cars/sounds/stopping.ogg', 10, FALSE) speed_in_pixels = speed_in_pixels+adjusting_speed*3 - movement_vector = SIMPLIFY_DEGREES(movement_vector+adjust_true*drift) + movement_vector = SIMPLIFY_DEGREES((movement_vector+adjust_true)*drift) else if(adjusting_speed < 0 && speed_in_pixels > 0) playsound(src, 'modular_darkpack/modules/cars/sounds/stopping.ogg', 10, FALSE) speed_in_pixels = speed_in_pixels+adjusting_speed*3 - movement_vector = SIMPLIFY_DEGREES(movement_vector+adjust_true*drift) + movement_vector = SIMPLIFY_DEGREES((movement_vector+adjust_true)*drift) else speed_in_pixels = min(stage*64, max(-stage*64, speed_in_pixels+adjusting_speed*stage)) playsound(src, 'modular_darkpack/modules/cars/sounds/drive.ogg', 10, FALSE) @@ -740,11 +748,11 @@ if(adjusting_speed > 0 && speed_in_pixels < 0) playsound(src, 'modular_darkpack/modules/cars/sounds/stopping.ogg', 10, FALSE) speed_in_pixels = min(0, speed_in_pixels+adjusting_speed*3) - movement_vector = SIMPLIFY_DEGREES(movement_vector+adjust_true*drift) + movement_vector = SIMPLIFY_DEGREES((movement_vector+adjust_true)*drift) else if(adjusting_speed < 0 && speed_in_pixels > 0) playsound(src, 'modular_darkpack/modules/cars/sounds/stopping.ogg', 10, FALSE) speed_in_pixels = max(0, speed_in_pixels+adjusting_speed*3) - movement_vector = SIMPLIFY_DEGREES(movement_vector+adjust_true*drift) + movement_vector = SIMPLIFY_DEGREES((movement_vector+adjust_true)*drift) /obj/darkpack_car/proc/apply_vector_angle() var/new_dir = angle2dir(movement_vector) diff --git a/modular_darkpack/modules/cars/code/car_actions.dm b/modular_darkpack/modules/cars/code/car_actions.dm index 7d4ea543c544..c09ec8117c6b 100644 --- a/modular_darkpack/modules/cars/code/car_actions.dm +++ b/modular_darkpack/modules/cars/code/car_actions.dm @@ -86,7 +86,7 @@ var/mob/living/driver = owner if(CONFIG_GET(flag/punishing_zero_dots) && driver.st_get_stat(STAT_DRIVE) < 1) to_chat(owner, span_danger("You don't know what you're doing!")) - return FALSE + // return FALSE // CRIMSON GRID EDIT - now this is pod racing if(!ISADVANCEDTOOLUSER(clicker)) return diff --git a/modular_darkpack/modules/doors/code/components/door_ownership.dm b/modular_darkpack/modules/doors/code/components/door_ownership.dm index 84b7f3d0d59d..3c2f479b8523 100644 --- a/modular_darkpack/modules/doors/code/components/door_ownership.dm +++ b/modular_darkpack/modules/doors/code/components/door_ownership.dm @@ -59,7 +59,7 @@ if(LOCK_OWNERSHIP_CAR) if(CONFIG_GET(flag/punishing_zero_dots) && human.st_get_stat(STAT_DRIVE) < 1) to_chat(human, span_danger("Shouldnt you learn how to drive before owning a car?")) - return + // return // CRIMSON GRID EDIT - now this is pod racing ownership_question = "Is this my car?" alert_title = "Vehicle" if(LOCK_OWNERSHIP_APARTMENT) diff --git a/modular_darkpack/modules/doors/code/vampdoor.dm b/modular_darkpack/modules/doors/code/vampdoor.dm index 9fdb6c5d079d..b64ad5c419d2 100644 --- a/modular_darkpack/modules/doors/code/vampdoor.dm +++ b/modular_darkpack/modules/doors/code/vampdoor.dm @@ -38,6 +38,8 @@ /// Number of successes needed to bash down var/bash_successes_needed = 1 +// MODULAR CRIMSON CITY EDIT - check door_improvements.dm +/* /obj/structure/vampdoor/Initialize(mapload) . = ..() @@ -50,6 +52,7 @@ COMSIG_ATOM_MAGICALLY_UNLOCKED = PROC_REF(on_magic_unlock), ) AddElement(/datum/element/connect_loc, loc_connections) +*/ /obj/structure/vampdoor/CanAStarPass(to_dir, datum/can_pass_info/pass_info) return !density || !locked @@ -216,7 +219,7 @@ to_chat(user, span_warning("[src] is locked!")) else toggle_door(user) - +/* CRIMSON GUARD EDIT - See door_improvements.dm /obj/structure/vampdoor/attack_hand_secondary(mob/user, list/modifiers) . = ..() if(. == SECONDARY_ATTACK_CANCEL_ATTACK_CHAIN) @@ -282,6 +285,7 @@ if(!has_keys) to_chat(user, span_warning("You need a key to lock/unlock this door!")) return SECONDARY_ATTACK_CANCEL_ATTACK_CHAIN +*/ /obj/structure/vampdoor/item_interaction(mob/living/user, obj/item/tool, list/modifiers) if(istype(tool, /obj/item/door_repair_kit)) @@ -366,7 +370,7 @@ return toggle_lock(user) if(!need_key) return toggle_lock(user) - +/* CRIMSON GRID EDIT - See door_improvements.dm /obj/structure/vampdoor/proc/toggle_lock(mob/living/user) playsound(src, lock_sound, 75, TRUE) if(!locked) @@ -379,6 +383,7 @@ proc_unlock("key") locked = FALSE return TRUE +*/ /obj/structure/vampdoor/proc/reset_transform() pixel_z = initial(pixel_z) diff --git a/modular_darkpack/modules/economy/code/credit_card.dm b/modular_darkpack/modules/economy/code/credit_card.dm index 986269a0d905..2469b190c731 100644 --- a/modular_darkpack/modules/economy/code/credit_card.dm +++ b/modular_darkpack/modules/economy/code/credit_card.dm @@ -98,7 +98,7 @@ registered_account.civilian_bounty?.on_reset(src) LAZYREMOVE(registered_account.bank_cards, src) registered_account = null - +/* CRIMSON GRID EDIT - moved to other post_equip /datum/outfit/job/vampire/post_equip(mob/living/carbon/human/user, visuals_only = FALSE) . = ..() @@ -114,7 +114,7 @@ if(account && account.account_id == user.account_id) card.set_account(account) - +*/ /obj/item/proc/GetCreditCard() return null diff --git a/modular_darkpack/modules/economy/code/dollar.dm b/modular_darkpack/modules/economy/code/dollar.dm index 8e607c7bed1c..3c4d95e965db 100644 --- a/modular_darkpack/modules/economy/code/dollar.dm +++ b/modular_darkpack/modules/economy/code/dollar.dm @@ -8,8 +8,9 @@ righthand_file = null ONFLOOR_ICON_HELPER('modular_darkpack/modules/deprecated/icons/onfloor.dmi') w_class = WEIGHT_CLASS_TINY + full_w_class = WEIGHT_CLASS_TINY resistance_flags = FLAMMABLE - max_amount = 1000 + max_amount = 5000 merge_type = /obj/item/stack/dollar /obj/item/stack/dollar/Initialize(mapload, new_amount, merge = TRUE, list/mat_override = null, mat_amt = 1) diff --git a/modular_darkpack/modules/government/code/passport.dm b/modular_darkpack/modules/government/code/passport.dm index 37bcf6bf42b7..09703c2d3caa 100644 --- a/modular_darkpack/modules/government/code/passport.dm +++ b/modular_darkpack/modules/government/code/passport.dm @@ -1,3 +1,4 @@ +/* CRIMSON GRID EDIT - Everyone has identification now by default. /datum/loadout_item/pocket_items/passport name = "Identification" item_path = /obj/item/passport @@ -11,6 +12,7 @@ LAZYADD(outfit.backpack_contents, /obj/item/card/drivers_license) else return ..() +*/ /obj/item/passport name = "passport" @@ -33,6 +35,7 @@ var/fake_identity = FALSE var/datum/storyteller_roll/investigation/examine_roll +/* CRIMSON GRID EDIT /obj/item/passport/Initialize(mapload) . = ..() var/mob/living/carbon/human/user = null @@ -43,6 +46,7 @@ if(user) // Init and equiping via loadout are both too soon to be able to catch the illegal identity quirk link_human(user) +*/ /obj/item/passport/proc/link_human(mob/living/carbon/human/user) if(HAS_TRAIT(user, TRAIT_ILLEGAL_IDENTITY)) diff --git a/modular_darkpack/modules/jobs/code/_jobs.dm b/modular_darkpack/modules/jobs/code/_jobs.dm index f31c0912168a..963b0d7fbc05 100644 --- a/modular_darkpack/modules/jobs/code/_jobs.dm +++ b/modular_darkpack/modules/jobs/code/_jobs.dm @@ -54,9 +54,14 @@ box = null pda_slot = null var/uses_default_clan_clothes = FALSE + var/list/wallet_contents = list() + var/no_wallet = FALSE + var/no_credit_card = FALSE /datum/outfit/job/vampire/pre_equip(mob/living/carbon/human/H, visuals_only) . = ..() + if(!id) + id = /obj/item/storage/wallet/darkpack if(uses_default_clan_clothes == TRUE && uniform == initial(uniform)) var/datum/splat/vampire/kindred/kindred = get_kindred_splat(H) if(kindred) @@ -88,6 +93,97 @@ if(phone) phone.owner_weakref = WEAKREF(user) phone.update_initialized_contacts() + // CRIMSON GRID EDIT BEGIN - Wallets and money splits, and identification. + var/obj/item/storage/wallet/darkpack/wallet = locate() in user.contents + if(wallet && !no_wallet) + if(wallet_contents) + for(var/path in wallet_contents) + var/number = wallet_contents[path] + if(!isnum(number))//Default to 1 + number = 1 + for(var/i in 1 to number) + SSwardrobe.provide_type(path, wallet) + var/finance = user.st_get_stat(STAT_FINANCE) + var/streetwise = user.st_get_stat(STAT_STREETWISE) + var/obj/item/stack/dollar/cash_money = SSwardrobe.provide_type(/obj/item/stack/dollar, wallet) + var/obj/item/card/credit/card = locate() in user.gather_belongings() + if(!no_credit_card && !card) + card = SSwardrobe.provide_type(/obj/item/card/credit, wallet) // make one + if(card && card.has_checked == FALSE) + card.registered_name = user.real_name + var/datum/bank_account/account = SSeconomy.bank_accounts_by_id["[user.account_id]"] + if(!account) + account = new /datum/bank_account() + card.set_account(account) + + var/datum/bank_account/bank_account = card?.registered_account + var/streetwise_mult + var/total_money + switch(streetwise) + if(0) + streetwise_mult = 0 + if(1) + streetwise_mult = 0.2 + if(2) + streetwise_mult = 0.4 + if(3) + streetwise_mult = 0.6 + if(4) + streetwise_mult = 0.8 + if(5) + streetwise_mult = 0.9 + switch(finance) + if(0) + if(!CONFIG_GET(flag/punishing_zero_dots)) + total_money = rand(50, 100) + if(bank_account) + bank_account.paycheck_amount = 15 + else + total_money = 50 + if(bank_account) + bank_account.paycheck_amount = 10 + if(1) + total_money = rand(100, 200) + if(bank_account) + bank_account.paycheck_amount = 40 + if(2) + total_money = rand(300, 600) + if(bank_account) + bank_account.paycheck_amount = 80 + if(3) + total_money = rand(800, 1200) + if(bank_account) + bank_account.paycheck_amount = 120 + if(4) + total_money = rand(1200, 1600) + if(bank_account) + bank_account.paycheck_amount = 160 + if(5) + total_money = rand(2000, 3000) + if(bank_account) + bank_account.paycheck_amount = 250 + if(bank_account) + bank_account.account_balance = total_money * streetwise_mult + cash_money.add(total_money * (1 - streetwise_mult)) + else + cash_money.add(total_money) // no bank accounts somehow + var/country = user?.client?.prefs?.read_preference(/datum/preference/choiced/country_of_origin) + var/driving_skill = user.st_get_stat(STAT_DRIVE) + var/obj/item/card/drivers_license/license + if(country == "United States") + if(!driving_skill) + license = SSwardrobe.provide_type(/obj/item/card/drivers_license/state_issued_id, wallet) + else + license = SSwardrobe.provide_type(/obj/item/card/drivers_license, wallet) + license.link_human(user) + else + if(driving_skill) + license = SSwardrobe.provide_type(/obj/item/card/drivers_license/international, wallet) + license.link_human(user) + var/obj/item/passport/passport = SSwardrobe.provide_type(/obj/item/passport, wallet) + passport.link_human(user) + else + CRASH("[src] didn't have a wallet and doesn't have no_wallet set! File a bug report.") /datum/job/after_spawn(mob/living/spawned, client/player_client) . = ..() diff --git a/modular_darkpack/modules/jobs/code/miscelllaneous/citizen.dm b/modular_darkpack/modules/jobs/code/miscelllaneous/citizen.dm index 1eecac4916c9..d8c12946c3e8 100644 --- a/modular_darkpack/modules/jobs/code/miscelllaneous/citizen.dm +++ b/modular_darkpack/modules/jobs/code/miscelllaneous/citizen.dm @@ -35,5 +35,6 @@ name = JOB_CITIZEN jobtype = /datum/job/vampire/citizen l_pocket = /obj/item/smartphone - backpack_contents = list(/obj/item/card/credit) + id = /obj/item/storage/wallet/darkpack + wallet_contents = list(/obj/item/card/credit) uses_default_clan_clothes = TRUE diff --git a/modular_darkpack/modules/jobs/code/police/captain.dm b/modular_darkpack/modules/jobs/code/police/captain.dm index f3a4db76409b..ab639c9a42c8 100644 --- a/modular_darkpack/modules/jobs/code/police/captain.dm +++ b/modular_darkpack/modules/jobs/code/police/captain.dm @@ -29,14 +29,14 @@ belt = /obj/item/storage/belt/holster/detective/darkpack/officer id = /obj/item/card/police/captain l_pocket = /obj/item/smartphone - r_pocket = /obj/item/vamp/keys/police/secure/captain + r_pocket = /obj/item/storage/wallet/darkpack backpack_contents = list( - /obj/item/card/credit = 1, /obj/item/ammo_box/darkpack/c9mm = 1, /obj/item/restraints/handcuffs = 1, /obj/item/melee/baton/vamp = 1, /obj/item/storage/medkit/darkpack/ifak = 1 ) + wallet_contents = list(/obj/item/card/credit, /obj/item/vamp/keys/police/secure/captain) /datum/outfit/job/vampire/police_captain/post_equip(mob/living/carbon/human/H) . = ..() diff --git a/modular_darkpack/modules/jobs/code/police/dispatcher.dm b/modular_darkpack/modules/jobs/code/police/dispatcher.dm index 822a5b67cc21..53d31b47afa9 100644 --- a/modular_darkpack/modules/jobs/code/police/dispatcher.dm +++ b/modular_darkpack/modules/jobs/code/police/dispatcher.dm @@ -29,5 +29,5 @@ shoes = /obj/item/clothing/shoes/vampire/businessblack id = /obj/item/card/government l_pocket = /obj/item/smartphone - r_pocket = /obj/item/vamp/keys/dispatch - backpack_contents = list(/obj/item/card/credit=1) + r_pocket = /obj/item/storage/wallet/darkpack + wallet_contents = list(/obj/item/vamp/keys/dispatch,/obj/item/card/credit=1) diff --git a/modular_darkpack/modules/jobs/code/police/fbi.dm b/modular_darkpack/modules/jobs/code/police/fbi.dm index 75b247a8b663..88f14c1a8e5f 100644 --- a/modular_darkpack/modules/jobs/code/police/fbi.dm +++ b/modular_darkpack/modules/jobs/code/police/fbi.dm @@ -31,8 +31,9 @@ id = /obj/item/card/police/fbi gloves = /obj/item/clothing/gloves/vampire/investigator l_pocket = /obj/item/smartphone - r_pocket = /obj/item/vamp/keys/police/federal - backpack_contents = list(/obj/item/card/police/sergeant=1, /obj/item/camera/detective=1, /obj/item/camera_film=1, /obj/item/taperecorder=1, /obj/item/tape=1, /obj/item/card/credit=1, /obj/item/ammo_box/darkpack/c45acp/hp=1, /obj/item/storage/medkit/darkpack/ifak=1) + r_pocket = /obj/item/storage/wallet/darkpack + backpack_contents = list( /obj/item/camera/detective=1, /obj/item/camera_film=1, /obj/item/taperecorder=1, /obj/item/tape=1, /obj/item/ammo_box/darkpack/c45acp/hp=1, /obj/item/storage/medkit/darkpack/ifak=1) + wallet_contents = list(/obj/item/card/police/sergeant=1,/obj/item/vamp/keys/police/federal,/obj/item/card/credit=1) /datum/outfit/job/vampire/fbi/post_equip(mob/living/carbon/human/agent) ..() diff --git a/modular_darkpack/modules/jobs/code/police/police.dm b/modular_darkpack/modules/jobs/code/police/police.dm index 11e2fb127123..4d03dc82c3f7 100644 --- a/modular_darkpack/modules/jobs/code/police/police.dm +++ b/modular_darkpack/modules/jobs/code/police/police.dm @@ -38,8 +38,12 @@ belt = /obj/item/storage/belt/security/police id = /obj/item/card/police l_pocket = /obj/item/smartphone - r_pocket = /obj/item/vamp/keys/police + r_pocket = /obj/item/storage/wallet/darkpack backpack_contents = list(/obj/item/card/credit=1, /obj/item/ammo_box/darkpack/c9mm = 1, /obj/item/storage/medkit/darkpack/ifak = 1) + wallet_contents = list( + /obj/item/vamp/keys/police=1, + /obj/item/card/credit=1 + ) /datum/outfit/job/vampire/police_officer/post_equip(mob/living/carbon/human/H) ..() diff --git a/modular_darkpack/modules/jobs/code/police/sergeant.dm b/modular_darkpack/modules/jobs/code/police/sergeant.dm index f88bb12b754a..e718ed96384f 100644 --- a/modular_darkpack/modules/jobs/code/police/sergeant.dm +++ b/modular_darkpack/modules/jobs/code/police/sergeant.dm @@ -38,8 +38,12 @@ belt = /obj/item/storage/belt/holster/detective/darkpack/officer id = /obj/item/card/police/sergeant l_pocket = /obj/item/smartphone - r_pocket = /obj/item/vamp/keys/police/secure - backpack_contents = list(/obj/item/card/credit=1, /obj/item/ammo_box/darkpack/c9mm = 1, /obj/item/restraints/handcuffs = 1, /obj/item/melee/baton/vamp = 1, /obj/item/storage/medkit/darkpack/ifak = 1) + r_pocket = /obj/item/storage/wallet/darkpack + backpack_contents = list(/obj/item/ammo_box/darkpack/c9mm = 1, /obj/item/restraints/handcuffs = 1, /obj/item/melee/baton/vamp = 1, /obj/item/storage/medkit/darkpack/ifak = 1) + wallet_contents = list( + /obj/item/vamp/keys/police/secure, + /obj/item/card/credit=1 + ) /datum/outfit/job/vampire/police_sergeant/post_equip(mob/living/carbon/human/H) ..() diff --git a/modular_vcg/modules/goofcode/door_improvements.dm b/modular_vcg/modules/goofcode/door_improvements.dm new file mode 100644 index 000000000000..f0797bb7e45f --- /dev/null +++ b/modular_vcg/modules/goofcode/door_improvements.dm @@ -0,0 +1,214 @@ +/obj/structure/vampdoor + var/static/list/slots_to_check = list( + ITEM_SLOT_BELT, + ITEM_SLOT_ID, + ITEM_SLOT_RPOCKET, + ITEM_SLOT_LPOCKET, + ITEM_SLOT_SUITSTORE, + ITEM_SLOT_DEX_STORAGE, + ITEM_SLOT_BACK, + ) + var/was_locked = FALSE + var/mob/auto_opener + var/turf/our_turf + var/list/adjacent_turfs = list() + +/obj/structure/vampdoor/Initialize(mapload) + . = ..() + + if(mapload) + GLOB.city_door_lock_ids |= lock_id + + register_context() + + var/static/list/loc_connections = list( + COMSIG_ATOM_MAGICALLY_UNLOCKED = PROC_REF(on_magic_unlock), + ) + AddElement(/datum/element/connect_loc, loc_connections) + RegisterSignal(src, COMSIG_ATOM_BUMPED, PROC_REF(on_bumped)) + our_turf = get_turf(src) + adjacent_turfs = RANGE_TURFS(1, get_turf(src)) + for(var/turf in adjacent_turfs) + RegisterSignal(turf, COMSIG_ATOM_EXITED, PROC_REF(walked_through)) + RegisterSignal(turf, COMSIG_TURF_CHANGE, PROC_REF(turf_changed)) + +/obj/structure/vampdoor/proc/turf_changed(turf/changed, path, list/new_baseturfs, flags, list/post_change_callbacks) + SIGNAL_HANDLER + UnregisterSignal(changed, COMSIG_TURF_CHANGE) + adjacent_turfs -= changed + post_change_callbacks += CALLBACK(src, PROC_REF(re_register_turf)) + +/obj/structure/vampdoor/proc/re_register_turf(turf/changed) + RegisterSignal(changed, COMSIG_ATOM_EXITED, PROC_REF(walked_through)) + RegisterSignal(changed, COMSIG_TURF_CHANGE, PROC_REF(turf_changed)) + +/obj/structure/vampdoor/Destroy(force) + UnregisterSignal(src, COMSIG_ATOM_BUMPED) + for(var/turf in adjacent_turfs) + UnregisterSignal(turf, COMSIG_ATOM_EXITED) + UnregisterSignal(turf, COMSIG_TURF_CHANGE) + adjacent_turfs -= turf + our_turf = null + auto_opener = null + . = ..() + + +/obj/structure/vampdoor/proc/walked_through(datum/source, atom/movable/thing) + SIGNAL_HANDLER + if(thing != auto_opener) + return // we don't care, didn't auto-open the door, thus is not the one holding it + if(thing.loc in adjacent_turfs) + return // we don't care, they're holding the door open still as they're adjacent + if(isliving(thing)) + var/mob/living/living_passing = thing + if(living_passing.move_intent == MOVE_INTENT_WALK) // Don't auto-close if you're walking. + return + if(living_passing.combat_mode) // Don't auto-close if you're in combat mode. + return + auto_opener = null // we have given up on auto-closing at this point, we don't want to auto-close if we walk back through it after having left it + if(ishuman(thing)) + var/mob/living/carbon/human/passing_human = thing + if(!HAS_PERSONALITY(passing_human, /datum/personality/slacking/lazy)) // lazy people don't close doors they walk through + close_door(passing_human) + +/obj/structure/vampdoor/proc/on_bumped(datum/source, atom/bumper) + SIGNAL_HANDLER + if(!closed) + return + if(isliving(bumper)) + var/mob/living/live_bumper = bumper + if(live_bumper.move_intent == MOVE_INTENT_WALK) + return + switch(dir) + if(NORTH) + if(live_bumper.dir == EAST || live_bumper.dir == WEST) + return + if(SOUTH) + if(live_bumper.dir == EAST || live_bumper.dir == WEST) + return + if(EAST) + if(live_bumper.dir == NORTH || live_bumper.dir == SOUTH) + return + if(WEST) + if(live_bumper.dir == NORTH || live_bumper.dir == SOUTH) + return + if(locked) + if(got_the_key(live_bumper)) + was_locked = TRUE + toggle_lock(live_bumper) + else + return // AIN'T GOT THE KEY! + open_door(live_bumper) + auto_opener = live_bumper + live_bumper.Move(our_turf) + +#define AINT_GOT_THE_KEY FALSE +#define GOT_THE_KEY TRUE + +/obj/structure/vampdoor/proc/got_the_key(mob/living/leonard) + var/obj/item/vamp/keys/found_keys + for(var/obj/item/held_thing in leonard.held_items) + if(istype(held_thing, /obj/item/vamp/keys) && check_the_key(held_thing)) + found_keys = TRUE + break + if(held_thing.atom_storage && !held_thing.atom_storage.locked) // no pulling keys out of lockboxes to unlock doors + for(var/obj/item/possible_key in held_thing) + if(istype(held_thing, /obj/item/vamp/keys) && check_the_key(held_thing)) + found_keys = TRUE + break + if(found_keys) + break + for(var/slot in slots_to_check) + var/obj/item/possible_key = leonard.get_item_by_slot(slot) + if(!possible_key) + continue + if(istype(possible_key, /obj/item/vamp/keys) && check_the_key(possible_key)) + found_keys = TRUE + break + if(possible_key.atom_storage && !possible_key.atom_storage.locked) + for(var/obj/item/possible_key_two in possible_key) + if(istype(possible_key_two, /obj/item/vamp/keys) && check_the_key(possible_key_two)) + found_keys = TRUE + break + if(!found_keys) + return AINT_GOT_THE_KEY + return GOT_THE_KEY + +/obj/structure/vampdoor/proc/check_the_key(obj/item/vamp/keys/skeleton_key) + if(skeleton_key.roundstart_fix) // this is so fucking stupid and needs reworked to not exist + lock_id = pick(skeleton_key.accesslocks) + skeleton_key.roundstart_fix = FALSE + return TRUE + if(skeleton_key.accesslocks) + for(var/i in skeleton_key.accesslocks) + if(i == lock_id) + return TRUE + return FALSE + +/obj/structure/vampdoor/attack_hand_secondary(mob/user, list/modifiers) + . = ..() + if(. == SECONDARY_ATTACK_CANCEL_ATTACK_CHAIN) + return + if(door_broken) + balloon_alert(user, "door broken!") + return SECONDARY_ATTACK_CANCEL_ATTACK_CHAIN + var/mob/living/living_user = user + if(living_user.combat_mode) + if(ishuman(user)) + var/mob/living/carbon/human/human_user = user + if(!bash_roll) + bash_roll = new() + bash_roll.difficulty = bash_difficulty + bash_roll.successes_needed = bash_successes_needed + var/roll = bash_roll.st_roll(user, src) + switch(roll) + if(ROLL_SUCCESS) + balloon_alert(human_user, "winding punch...") + if(do_after(human_user, 1 TURNS, src)) + proc_unlock(50) + Shake(rand(-1, 1), rand(-1, 1), 0.2 SECONDS, 0.1 SECONDS) + break_door(human_user) + else + balloon_alert(human_user, "not adjacent!") + return SECONDARY_ATTACK_CANCEL_ATTACK_CHAIN + if(ROLL_FAILURE) + Shake(rand(-1, 1), rand(-1, 1), 0.2 SECONDS, 0.1 SECONDS) + playsound(get_turf(src), 'modular_darkpack/master_files/sounds/effects/door/get_bent.ogg', 50, TRUE) + proc_unlock(5) + balloon_alert(human_user, "failed to breach!") + if(ROLL_BOTCH) + Shake(rand(-1, 1), rand(-1, 1), 0.2 SECONDS, 0.1 SECONDS) + playsound(get_turf(src), 'modular_darkpack/master_files/sounds/effects/door/get_bent.ogg', 50, TRUE) + proc_unlock(5) + balloon_alert(human_user, "hurt your shoulder!") + human_user.adjust_brute_loss(1 LETHAL_TTRPG_DAMAGE, user.get_active_hand()) + else + if(lock_id == LOCKACCESS_ALL) + toggle_lock(user) + return SECONDARY_ATTACK_CANCEL_ATTACK_CHAIN + if(got_the_key(user)) + toggle_lock(user) + return SECONDARY_ATTACK_CANCEL_ATTACK_CHAIN + else + balloon_alert(user, "ain't got the key!") + return SECONDARY_ATTACK_CANCEL_ATTACK_CHAIN + +/obj/structure/vampdoor/proc/toggle_lock(mob/living/user) + playsound(src, lock_sound, 75, TRUE) + if(!locked) + if(user) + balloon_alert(user, "locked") + locked = TRUE + else + if(user) + balloon_alert(user, "unlocked") + proc_unlock("key") + locked = FALSE + return TRUE + + +#undef AINT_GOT_THE_KEY +#undef GOT_THE_KEY + +/obj/item/vamp/keys + slot_flags = ITEM_SLOT_ID | ITEM_SLOT_BELT | ITEM_SLOT_LPOCKET | ITEM_SLOT_RPOCKET | ITEM_SLOT_SUITSTORE diff --git a/modular_vcg/modules/goofcode/icons/docs.dmi b/modular_vcg/modules/goofcode/icons/docs.dmi new file mode 100644 index 0000000000000000000000000000000000000000..354a33047a806f4a46baff5fa315e24a9d0f54ee GIT binary patch literal 390 zcmV;10eSw3P)V=-0C=2JR&a84_w-Y6@%7{?OD!tS%+FJ>RWQ*r;NmRL zOex6#a*U0*I5Sc+(=$pSoZ^zil2jm53CxJkOi|+EOvx-N1_~K+ai$d|=B7f}$_lQ2 zE?|=ZnynjHvVSB(0001)Nkl%Kp?1OoSbFIfCLzYl+zR$ kP=KH^ng9c%0K)(R0D=M{=(g*o$N&HU07*qoM6N<$g1qIKApigX literal 0 HcmV?d00001 diff --git a/modular_vcg/modules/goofcode/icons/docsonfloor.dmi b/modular_vcg/modules/goofcode/icons/docsonfloor.dmi new file mode 100644 index 0000000000000000000000000000000000000000..55bb1913bf00322ef67b12dd16f4002736214457 GIT binary patch literal 263 zcmeAS@N?(olHy`uVBq!ia0vp^3LwnF3?v&v(vJfv=>VS)*8>L*{AXbJZ_MyNjbZBK z$!_J1t5&VD^YYD3PTjKW-ddnC#*!evU)e_1!5cyiE*d|0q;uX!^CUx2Pwx&3;~?Y9#$F0@9!)wj zDMTTd^GwHipTI|td`{|Uv2jTj6)qE1eYVW$#wo6Kb$SVt8E37Pj@VSM;smr)&C|s( zL}Oxdf<$9OV896m*9O%qzKo#@?x-@lHY{GexN%#b)Eowe$1j;rKmDMR3e>^i>FVdQ I&MBb@0N^TP2><{9 literal 0 HcmV?d00001 diff --git a/modular_vcg/modules/goofcode/personality_disables.dm b/modular_vcg/modules/goofcode/personality_disables.dm new file mode 100644 index 000000000000..bc676c77ffec --- /dev/null +++ b/modular_vcg/modules/goofcode/personality_disables.dm @@ -0,0 +1,8 @@ +/datum/personality + var/disabled_vtm = FALSE + +/datum/personality/nt + disabled_vtm = TRUE + +/datum/personality/department + disabled_vtm = TRUE diff --git a/modular_vcg/modules/goofcode/state_id.dm b/modular_vcg/modules/goofcode/state_id.dm new file mode 100644 index 000000000000..d0d1bd63c701 --- /dev/null +++ b/modular_vcg/modules/goofcode/state_id.dm @@ -0,0 +1,35 @@ +/obj/item/card/drivers_license/state_issued_id + name = "state issued identification" + desc = "An identification card issued by the state to serve as a valid form of identification. Does NOT qualify as a license to drive!" + icon = 'modular_vcg/modules/goofcode/icons/docs.dmi' + icon_state = "state_id" + slot_flags = NONE + ONFLOOR_ICON_HELPER('modular_vcg/modules/goofcode/icons/docsonfloor.dmi') + + +/obj/item/card/drivers_license/international + name = "international driver's license" + desc = "An identification card issued by the state of California to serve as temporary driver's license during the holder's stay in the United States." + +/datum/quirk/darkpack/undocumented + name = "Undocumented" + desc = "For one reason or another, you just don't have valid identification! The cops might take issue with this." + ttrpg_sources = list(/datum/source_book/homebrew = WE_MADE_IT_UP) + value = 0 + quirk_flags = QUIRK_HUMAN_ONLY|QUIRK_HIDE_FROM_SCAN + icon = FA_ICON_FILE_CIRCLE_QUESTION + mob_trait = TRAIT_UNDOCUMENTED + gain_text = span_warning("You feel poorly documented.") + lose_text = span_notice("You feel well documented.") + medical_record_text = "Patient chronically misplaces critical documents." + failure_message = "I can't believe I forgot to look for my ID there!" + +/datum/quirk/darkpack/undocumented/add() + . = ..() + var/mob/living/carbon/human/undocumented = astype(quirk_holder) + if(!undocumented) + return + + for(var/item in undocumented.gather_belongings()) // prolly a faster way to do this + if(istype(item, /obj/item/passport) || istype(item, /obj/item/card/drivers_license)) + qdel(item) diff --git a/tgstation.dme b/tgstation.dme index 22f42f544f34..64b3bb3fd716 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -8163,6 +8163,9 @@ #include "modular_vcg\master_files\code\modules\mentor\mentorsay.dm" #include "modular_vcg\master_files\code\modules\mocking\client.dm" #include "modular_vcg\modules\ghost_visibility_notice\code\observer.dm" +#include "modular_vcg\modules\goofcode\door_improvements.dm" +#include "modular_vcg\modules\goofcode\personality_disables.dm" +#include "modular_vcg\modules\goofcode\state_id.dm" #include "modular_vcg\modules\jobs\code\camarilla\prince.dm" #include "modular_vcg\modules\jobs\code\garou\councillor.dm" #include "modular_vcg\modules\jobs\code\garou\guardian.dm" diff --git a/tgui/packages/tgui/interfaces/PreferencesMenu/CharacterPreferences/QuirksPage.tsx b/tgui/packages/tgui/interfaces/PreferencesMenu/CharacterPreferences/QuirksPage.tsx index 05a1af48b454..f4bcddb89305 100644 --- a/tgui/packages/tgui/interfaces/PreferencesMenu/CharacterPreferences/QuirksPage.tsx +++ b/tgui/packages/tgui/interfaces/PreferencesMenu/CharacterPreferences/QuirksPage.tsx @@ -21,6 +21,7 @@ import { import { useRandomToggleState } from '../useRandomToggleState'; import { useServerPrefs } from '../useServerPrefs'; import { getRandomization, PreferenceList } from './MainPage'; +import { PersonalityPage } from './PersonalityPage'; function getColorValueClass(quirk: Quirk) { if (quirk.value > 0) { @@ -564,7 +565,7 @@ function QuirkPage() { } export function QuirkPersonalityPage() { - const [contentPage, setContentPage] = useState<'quirks'>( // DARKPACK EDIT CHANGE - ORIGINAL: const [contentPage, setContentPage] = useState<'quirks' | 'personality'>( + const [contentPage, setContentPage] = useState<'quirks' | 'personality'>( 'quirks', ); @@ -583,7 +584,7 @@ export function QuirkPersonalityPage() { Quirks - { /* // DARKPACK EDIT REMOVAL START + {