From d94296e1347ff28e38e8916b4b6d975c270a371a Mon Sep 17 00:00:00 2001 From: forest2001 Date: Mon, 4 Dec 2023 21:25:33 +0000 Subject: [PATCH 1/5] grr --- code/modules/admin/tabs/event_tab.dm | 17 +++++++---------- code/modules/admin/topic/topic_events.dm | 15 ++++++--------- 2 files changed, 13 insertions(+), 19 deletions(-) diff --git a/code/modules/admin/tabs/event_tab.dm b/code/modules/admin/tabs/event_tab.dm index 7a6359ccf090..2c232dc8bf0b 100644 --- a/code/modules/admin/tabs/event_tab.dm +++ b/code/modules/admin/tabs/event_tab.dm @@ -217,18 +217,15 @@ if(!istype(chosen_ert)) return - - var/launch_broadcast = tgui_alert(usr, "Would you like to broadcast the beacon launch? This will reveal the distress beacon to all players.", "Announce distress beacon?", list("Yes", "No"), 20 SECONDS) - if(launch_broadcast == "Yes") + var/launch_broadcast = FALSE + var/lb_prompt = tgui_alert(usr, "Would you like to broadcast the beacon launch? This will reveal the distress beacon to all players.", "Announce distress beacon?", list("Yes", "No"), 20 SECONDS) + if(lb_prompt == "Yes") launch_broadcast = TRUE - else - launch_broadcast = FALSE - var/announce_receipt = tgui_alert(usr, "Would you like to announce the beacon received message? This will reveal the distress beacon to all players.", "Announce beacon received?", list("Yes", "No"), 20 SECONDS) - if(announce_receipt == "Yes") + var/announce_receipt = FALSE + var/ar_prompt = tgui_alert(usr, "Would you like to announce the beacon received message? This will reveal the distress beacon to all players.", "Announce beacon received?", list("Yes", "No"), 20 SECONDS) + if(ar_prompt == "Yes") announce_receipt = TRUE - else - announce_receipt = FALSE var/turf/override_spawn_loc var/prompt = tgui_alert(usr, "Spawn at their assigned spawn, or at your location?", "Spawnpoint Selection", list("Spawn", "Current Location"), 0) @@ -238,7 +235,7 @@ if(prompt == "Current Location") override_spawn_loc = get_turf(usr) - chosen_ert.activate(quiet_launch = launch_broadcast, announce_incoming = announce_receipt, override_spawn_loc = override_spawn_loc) + chosen_ert.activate(launch_broadcast, announce_receipt, override_spawn_loc) message_admins("[key_name_admin(usr)] admin-called a [choice == "Randomize" ? "randomized ":""]distress beacon: [chosen_ert.name]") diff --git a/code/modules/admin/topic/topic_events.dm b/code/modules/admin/topic/topic_events.dm index 5e59ba4835f5..69fad4985c0d 100644 --- a/code/modules/admin/topic/topic_events.dm +++ b/code/modules/admin/topic/topic_events.dm @@ -205,18 +205,15 @@ em_call.mob_max = humans.len em_call.players_to_offer = humans em_call.owner = owner - - var/launch_broadcast = tgui_alert(usr, "Would you like to broadcast the beacon launch? This will reveal the distress beacon to all players.", "Announce distress beacon?", list("Yes", "No"), 20 SECONDS) - if(launch_broadcast == "Yes") + var/launch_broadcast = FALSE + var/lb_prompt = tgui_alert(usr, "Would you like to broadcast the beacon launch? This will reveal the distress beacon to all players.", "Announce distress beacon?", list("Yes", "No"), 20 SECONDS) + if(lb_prompt == "Yes") launch_broadcast = TRUE - else - launch_broadcast = FALSE - var/announce_receipt = tgui_alert(usr, "Would you like to announce the beacon received message? This will reveal the distress beacon to all players.", "Announce beacon received?", list("Yes", "No"), 20 SECONDS) - if(announce_receipt == "Yes") + var/announce_receipt = FALSE + var/ar_prompt = tgui_alert(usr, "Would you like to announce the beacon received message? This will reveal the distress beacon to all players.", "Announce beacon received?", list("Yes", "No"), 20 SECONDS) + if(ar_prompt == "Yes") announce_receipt = TRUE - else - announce_receipt = FALSE em_call.activate(launch_broadcast, announce_receipt) From 8497e3cda2fdb2135fc826bc16e1fdb4ddbbe5f3 Mon Sep 17 00:00:00 2001 From: forest2001 Date: Mon, 4 Dec 2023 21:32:45 +0000 Subject: [PATCH 2/5] oops --- code/game/machinery/vending/cm_vending.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/machinery/vending/cm_vending.dm b/code/game/machinery/vending/cm_vending.dm index b0a09dcd1767..a2e455aaaa1e 100644 --- a/code/game/machinery/vending/cm_vending.dm +++ b/code/game/machinery/vending/cm_vending.dm @@ -443,7 +443,7 @@ GLOBAL_LIST_EMPTY(vending_products) /// Handles redeeming coin tokens. /obj/structure/machinery/cm_vending/attackby(obj/item/attacking_item, mob/user) if(!istype(attacking_item, /obj/item/coin/marine)) - ..() + return ..() if(!can_access_to_vend(user, ignore_hack = TRUE)) return FALSE redeem_token(attacking_item, user) From f785acaba7616c3041ed32fb16a822bc4206b1ff Mon Sep 17 00:00:00 2001 From: forest2001 Date: Mon, 4 Dec 2023 22:17:15 +0000 Subject: [PATCH 3/5] FOREST HOW DID YOU BUGGER THIS UP --- code/modules/admin/tabs/event_tab.dm | 10 +++++----- code/modules/admin/topic/topic_events.dm | 12 ++++++------ 2 files changed, 11 insertions(+), 11 deletions(-) diff --git a/code/modules/admin/tabs/event_tab.dm b/code/modules/admin/tabs/event_tab.dm index 2c232dc8bf0b..acfc72c01e67 100644 --- a/code/modules/admin/tabs/event_tab.dm +++ b/code/modules/admin/tabs/event_tab.dm @@ -217,10 +217,10 @@ if(!istype(chosen_ert)) return - var/launch_broadcast = FALSE - var/lb_prompt = tgui_alert(usr, "Would you like to broadcast the beacon launch? This will reveal the distress beacon to all players.", "Announce distress beacon?", list("Yes", "No"), 20 SECONDS) - if(lb_prompt == "Yes") - launch_broadcast = TRUE + var/quiet_launch = TRUE + var/ql_prompt = tgui_alert(usr, "Would you like to broadcast the beacon launch? This will reveal the distress beacon to all players.", "Announce distress beacon?", list("Yes", "No"), 20 SECONDS) + if(ql_prompt == "Yes") + quiet_launch = FALSE var/announce_receipt = FALSE var/ar_prompt = tgui_alert(usr, "Would you like to announce the beacon received message? This will reveal the distress beacon to all players.", "Announce beacon received?", list("Yes", "No"), 20 SECONDS) @@ -235,7 +235,7 @@ if(prompt == "Current Location") override_spawn_loc = get_turf(usr) - chosen_ert.activate(launch_broadcast, announce_receipt, override_spawn_loc) + chosen_ert.activate(quiet_launch, announce_receipt, override_spawn_loc) message_admins("[key_name_admin(usr)] admin-called a [choice == "Randomize" ? "randomized ":""]distress beacon: [chosen_ert.name]") diff --git a/code/modules/admin/topic/topic_events.dm b/code/modules/admin/topic/topic_events.dm index 69fad4985c0d..0c37e81f2641 100644 --- a/code/modules/admin/topic/topic_events.dm +++ b/code/modules/admin/topic/topic_events.dm @@ -205,17 +205,17 @@ em_call.mob_max = humans.len em_call.players_to_offer = humans em_call.owner = owner - var/launch_broadcast = FALSE - var/lb_prompt = tgui_alert(usr, "Would you like to broadcast the beacon launch? This will reveal the distress beacon to all players.", "Announce distress beacon?", list("Yes", "No"), 20 SECONDS) - if(lb_prompt == "Yes") - launch_broadcast = TRUE + var/quiet_launch = TRUE + var/ql_prompt = tgui_alert(usr, "Would you like to broadcast the beacon launch? This will reveal the distress beacon to all players.", "Announce distress beacon?", list("Yes", "No"), 20 SECONDS) + if(ql_prompt == "Yes") + quiet_launch = FALSE var/announce_receipt = FALSE var/ar_prompt = tgui_alert(usr, "Would you like to announce the beacon received message? This will reveal the distress beacon to all players.", "Announce beacon received?", list("Yes", "No"), 20 SECONDS) if(ar_prompt == "Yes") announce_receipt = TRUE - - em_call.activate(launch_broadcast, announce_receipt) + log_debug("ERT DEBUG (CUSTOM SET): [quiet_launch] - [announce_receipt]") + em_call.activate(quiet_launch, announce_receipt) message_admins("[key_name_admin(usr)] created [humans_to_spawn] humans as [job_name] at [get_area(initial_spot)]") From c3027eb521bb3a8f19be5edfac2edcabfd60feea Mon Sep 17 00:00:00 2001 From: forest2001 Date: Mon, 4 Dec 2023 22:32:16 +0000 Subject: [PATCH 4/5] fixes UPP message too --- code/datums/emergency_calls/emergency_call.dm | 2 +- code/modules/mob/living/carbon/human/inventory.dm | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/code/datums/emergency_calls/emergency_call.dm b/code/datums/emergency_calls/emergency_call.dm index 9db46955a5ea..c6f71382b877 100644 --- a/code/datums/emergency_calls/emergency_call.dm +++ b/code/datums/emergency_calls/emergency_call.dm @@ -200,7 +200,7 @@ SSticker.mode.picked_calls += src show_join_message() //Show our potential candidates the message to let them join. - message_admins("Distress beacon: '[name]' activated [src.hostility? "[SPAN_WARNING("(THEY ARE HOSTILE)")]":"(they are friendly)"]. Looking for candidates.") + message_admins("Distress beacon: '[name]' activated [hostility? "[SPAN_WARNING("(THEY ARE HOSTILE)")]":"(they are friendly)"]. Looking for candidates.") if(!quiet_launch) marine_announcement("A distress beacon has been launched from the [MAIN_SHIP_NAME].", "Priority Alert", 'sound/AI/distressbeacon.ogg', logging = ARES_LOG_SECURITY) diff --git a/code/modules/mob/living/carbon/human/inventory.dm b/code/modules/mob/living/carbon/human/inventory.dm index b86a6a625f57..b54f03e2ce7d 100644 --- a/code/modules/mob/living/carbon/human/inventory.dm +++ b/code/modules/mob/living/carbon/human/inventory.dm @@ -550,6 +550,7 @@ to_chat(src, SPAN_WARNING("You can't put \the [interact_item.name] on [target_mob]!")) return visible_message(SPAN_NOTICE("[src] tries to put \the [interact_item.name] on [target_mob]."), null, null, 5) + log_interact(src, target_mob, "[key_name(src)] attempted to put [interact_item.name] on [key_name(target_mob)]'s ([slot_to_process]).") if(do_after(src, get_strip_delay(src, target_mob), INTERRUPT_ALL, BUSY_ICON_GENERIC, target_mob, INTERRUPT_MOVED, BUSY_ICON_GENERIC)) if(interact_item == get_active_hand() && !target_mob.get_item_by_slot(slot_to_process) && Adjacent(target_mob)) if(interact_item.flags_item & WIELDED) //to prevent re-wielding it during the do_after @@ -558,6 +559,7 @@ drop_inv_item_on_ground(interact_item) if(interact_item && !QDELETED(interact_item)) //Might be self-deleted? target_mob.equip_to_slot_if_possible(interact_item, slot_to_process, 1, 0, 1, 1) + log_interact(src, target_mob, "[key_name(src)] put [interact_item.name] on [key_name(target_mob)]'s ([slot_to_process]) successfully.") if(ishuman(target_mob) && target_mob.stat == DEAD) var/mob/living/carbon/human/human_target = target_mob human_target.disable_lights() // take that powergamers -spookydonut From 9bd58fdfced81ef3ca42bf04e2037bb37afb8207 Mon Sep 17 00:00:00 2001 From: forest2001 Date: Mon, 4 Dec 2023 22:42:47 +0000 Subject: [PATCH 5/5] undo token fix --- code/game/machinery/vending/cm_vending.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/game/machinery/vending/cm_vending.dm b/code/game/machinery/vending/cm_vending.dm index a2e455aaaa1e..b0a09dcd1767 100644 --- a/code/game/machinery/vending/cm_vending.dm +++ b/code/game/machinery/vending/cm_vending.dm @@ -443,7 +443,7 @@ GLOBAL_LIST_EMPTY(vending_products) /// Handles redeeming coin tokens. /obj/structure/machinery/cm_vending/attackby(obj/item/attacking_item, mob/user) if(!istype(attacking_item, /obj/item/coin/marine)) - return ..() + ..() if(!can_access_to_vend(user, ignore_hack = TRUE)) return FALSE redeem_token(attacking_item, user)