Skip to content

Commit

Permalink
Merge pull request #72 from SPLURT-Station:upstream-updates
Browse files Browse the repository at this point in the history
[UPSTREAM UPDATE] 4.1.2024
  • Loading branch information
MosleyTheMalO authored Jan 5, 2025
2 parents 5db3a9d + a05362b commit f443d4a
Show file tree
Hide file tree
Showing 14 changed files with 67 additions and 40 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/compile_changelogs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ name: Compile changelogs

on:
schedule:
- cron: "15 23 * * *"
- cron: "2 23 * * *"
workflow_dispatch:

jobs:
Expand Down
1 change: 1 addition & 0 deletions code/__DEFINES/logging.dm
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@
#define LOG_CATEGORY_DEBUG_ASSET "debug-asset"
#define LOG_CATEGORY_DEBUG_JOB "debug-job"
#define LOG_CATEGORY_DEBUG_LUA "debug-lua"
#define LOG_CATEGORY_DEBUG_TTS "debug-tts"
#define LOG_CATEGORY_DEBUG_MAPPING "debug-mapping"
#define LOG_CATEGORY_DEBUG_MOBTAG "debug-mobtag"
#define LOG_CATEGORY_DEBUG_SQL "debug-sql"
Expand Down
4 changes: 4 additions & 0 deletions code/__HELPERS/logging/debug.dm
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@
/proc/log_job_debug(text, list/data)
logger.Log(LOG_CATEGORY_DEBUG_JOB, text, data)

/// Logging for TTS
/proc/log_tts(text, list/data)
logger.Log(LOG_CATEGORY_DEBUG_TTS, text, data)

/// Logging for lua scripting
/proc/log_lua(text, list/data)
logger.Log(LOG_CATEGORY_DEBUG_LUA, text, data)
Expand Down
6 changes: 6 additions & 0 deletions code/controllers/subsystem/tts.dm
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,12 @@ SUBSYSTEM_DEF(tts)
var/identifier = current_request.identifier
if(current_request.requests_errored())
current_request.timed_out = TRUE
var/datum/http_response/normal_response = current_request.request.into_response()
var/datum/http_response/blips_response = current_request.request_blips.into_response()
log_tts("TTS HTTP request errored | Normal: [normal_response.error] | Blips: [blips_response.error]", list(
"normal" = normal_response,
"blips" = blips_response
))
continue
current_request.audio_length = text2num(response.headers["audio-length"]) * 10
if(!current_request.audio_length)
Expand Down
11 changes: 11 additions & 0 deletions code/datums/actions/items/toggles.dm
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,17 @@
/datum/action/item_action/call_link
name = "Call MODlink"

/datum/action/item_action/toggle_wearable_hud
name = "Toggle Wearable HUD"
desc = "Toggles your wearable HUD. You can still access examine information while it's off."

/datum/action/item_action/toggle_wearable_hud/Trigger(trigger_flags)
. = ..()
if(!.)
return
var/obj/item/clothing/glasses/hud/hud_display = target
hud_display.toggle_hud_display(owner)

/datum/action/item_action/toggle_nv
name = "Toggle Night Vision"
var/stored_cutoffs
Expand Down
10 changes: 10 additions & 0 deletions code/datums/http.dm
Original file line number Diff line number Diff line change
Expand Up @@ -80,3 +80,13 @@

var/errored = FALSE
var/error

/datum/http_response/serialize_list(list/options, list/semvers)
. = ..()
.["status_code"] = status_code
.["body"] = body
.["headers"] = headers

.["errored"] = errored
.["error"] = error
return .
20 changes: 20 additions & 0 deletions code/modules/clothing/glasses/hud.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@
name = "HUD"
desc = "A heads-up display that provides important info in (almost) real time."
flags_1 = null //doesn't protect eyes because it's a monocle, duh
actions_types = list(/datum/action/item_action/toggle_wearable_hud)
/// Whether the HUD info is on or off
var/display_active = TRUE

/obj/item/clothing/glasses/hud/emp_act(severity)
. = ..()
Expand Down Expand Up @@ -32,6 +35,23 @@
user.say("WHY IS THERE A BAR ON MY HEAD?!!")
return OXYLOSS

/obj/item/clothing/glasses/hud/equipped(mob/living/user, slot)
. = ..()
display_active = TRUE

/obj/item/clothing/glasses/hud/proc/toggle_hud_display(mob/living/carbon/eye_owner)
if(display_active)
display_active = FALSE
for(var/hud_trait as anything in clothing_traits)
REMOVE_CLOTHING_TRAIT(eye_owner, hud_trait)
balloon_alert(eye_owner, "hud disabled")
return

display_active = TRUE
for(var/hud_trait as anything in clothing_traits)
ADD_CLOTHING_TRAIT(eye_owner, hud_trait)
balloon_alert(eye_owner, "hud enabled")

/obj/item/clothing/glasses/hud/health
name = "health scanner HUD"
desc = "A heads-up display that scans the humanoids in view and provides accurate data about their health status."
Expand Down
2 changes: 1 addition & 1 deletion code/modules/loadout/loadout_menu.dm
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
to_chat(preferences.parent, span_warning("You cannot select this item!"))
return

if(!isnull(selected_item.donator_only) && !GLOB.donator_list[preferences?.parent?.ckey])
if(selected_item.donator_only && !GLOB.donator_list[preferences?.parent?.ckey])
to_chat(preferences.parent, span_warning("This item is for donators only."))
return
// SKYRAT EDIT END
Expand Down
4 changes: 4 additions & 0 deletions code/modules/logging/categories/log_category_debug.dm
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@
category = LOG_CATEGORY_DEBUG_LUA
master_category = /datum/log_category/debug

/datum/log_category/debug_tts
category = LOG_CATEGORY_DEBUG_TTS
master_category = /datum/log_category/debug

// This is not in the debug master category on purpose, do not add it
/datum/log_category/debug_runtime
category = LOG_CATEGORY_RUNTIME
Expand Down
4 changes: 4 additions & 0 deletions html/changelogs/archive/2025-01.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,3 +50,7 @@
2025-01-04:
MosleyTheMalO:
- rscadd: adds a batch of our custom drinks (modular_splurt)
LT3:
- qol: Wearable HUDs can be toggled on and off
ReturnToZender:
- qol: Flowers no longer donator-only in the loadout
Original file line number Diff line number Diff line change
Expand Up @@ -606,48 +606,39 @@
/datum/loadout_item/head/poppy
name = "Poppy Flower"
item_path = /obj/item/food/grown/poppy
donator_only = TRUE

/datum/loadout_item/head/lily
name = "Lily Flower"
item_path = /obj/item/food/grown/poppy/lily
donator_only = TRUE

/datum/loadout_item/head/geranium
name = "Geranium Flower"
item_path = /obj/item/food/grown/poppy/geranium
donator_only = TRUE

/datum/loadout_item/head/fraxinella
name = "Fraxinella Flower"
item_path = /obj/item/food/grown/poppy/geranium/fraxinella
donator_only = TRUE

/datum/loadout_item/head/harebell
name = "Harebell Flower"
item_path = /obj/item/food/grown/harebell
donator_only = TRUE

/datum/loadout_item/head/rose
name = "Rose Flower"
item_path = /obj/item/food/grown/rose
donator_only = TRUE

/datum/loadout_item/head/carbon_rose
name = "Carbon Rose Flower"
item_path = /obj/item/grown/carbon_rose
donator_only = TRUE

/datum/loadout_item/head/sunflower
name = "Sunflower"
item_path = /obj/item/food/grown/sunflower
donator_only = TRUE

/datum/loadout_item/head/rainbow_bunch
name = "Rainbow Bunch"
item_path = /obj/item/food/grown/rainbow_flower
additional_displayed_text = list(TOOLTIP_RANDOM_COLOR)
donator_only = TRUE

// Legacy unpaintable cowboy hat because it fits a character better
/datum/loadout_item/head/cowboyhat_legacy
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,3 +30,8 @@
name = "Mandibles (Top)"
icon = 'modular_zubbers/icons/customization/snouts.dmi'
icon_state = "mandibles1"

/datum/sprite_accessory/snouts/mammal/snaggletooth
name = "Snaggletooth"
icon = 'modular_zubbers/icons/customization/snouts.dmi'
icon_state = "snaggletooth"
Original file line number Diff line number Diff line change
Expand Up @@ -74,32 +74,3 @@
restricted_roles = list(JOB_BLUESHIELD, JOB_HEAD_OF_SECURITY, JOB_SECURITY_OFFICER, JOB_WARDEN, JOB_DETECTIVE, JOB_SECURITY_MEDIC, JOB_CORRECTIONS_OFFICER)
//Every other item in this set is role restricted, and it's like they forgot the boots.
//I don't think anyone on Skyrat noticed because this is ckey whitelisted there.

//Flowers
/datum/loadout_item/head/donator/poppy
donator_only = FALSE

/datum/loadout_item/head/donator/lily
donator_only = FALSE

/datum/loadout_item/head/donator/geranium
donator_only = FALSE

/datum/loadout_item/head/donator/fraxinella
donator_only = FALSE

/datum/loadout_item/head/donator/harebell
donator_only = FALSE

/datum/loadout_item/head/donator/rose
donator_only = FALSE

/datum/loadout_item/head/donator/carbon_rose
donator_only = FALSE

/datum/loadout_item/head/donator/sunflower
donator_only = FALSE

/datum/loadout_item/head/donator/rainbow_bunch
donator_only = FALSE

Binary file modified modular_zubbers/icons/customization/snouts.dmi
Binary file not shown.

0 comments on commit f443d4a

Please sign in to comment.