From 4a275ec3259817118d93ada1ab947c75cef28284 Mon Sep 17 00:00:00 2001 From: dwinters99 <65516417+dwinters99@users.noreply.github.com> Date: Mon, 11 May 2026 17:59:58 -0400 Subject: [PATCH 1/4] old bot commands --- code/controllers/subsystem/ticker.dm | 6 +++++- code/modules/discord/tgs_commands.dm | 2 +- config/apoc_config.txt | 2 ++ .../code/controllers/configuration/entries/general.dm | 2 ++ modular_zapoc/modules/discord/tgs_commands.dm | 11 +++++++++++ tgstation.dme | 2 ++ 6 files changed, 23 insertions(+), 2 deletions(-) create mode 100644 config/apoc_config.txt create mode 100644 modular_zapoc/master_files/code/controllers/configuration/entries/general.dm create mode 100644 modular_zapoc/modules/discord/tgs_commands.dm diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index d0d7ccc37a81..376048b57481 100644 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -151,7 +151,11 @@ SUBSYSTEM_DEF(ticker) window_flash(C, ignorepref = TRUE) //let them know lobby has opened up. to_chat(world, span_notice("Welcome to [station_name()]!")) for(var/channel_tag in CONFIG_GET(str_list/channel_announce_new_game)) - send2chat(new /datum/tgs_message_content("New round starting on [SSmapping.current_map.map_name]!"), channel_tag) + if(SSticker.GetTimeLeft() == -10) // APOC EDIT CHANGE START - DISCORD + send2chat(new /datum/tgs_message_content("New round delayed. Thanks for playing Apocrypha XIII!"), channel_tag) // APOC EDIT CHANGE + else + send2chat(new /datum/tgs_message_content("<@&1474327242510303336> New round starting on [SSmapping.config.map_name]!"), channel_tag) + // APOC EDIT CHANGE END current_state = GAME_STATE_PREGAME SEND_SIGNAL(src, COMSIG_TICKER_ENTER_PREGAME) diff --git a/code/modules/discord/tgs_commands.dm b/code/modules/discord/tgs_commands.dm index 6903bf7dcc65..6d22c9c59b22 100644 --- a/code/modules/discord/tgs_commands.dm +++ b/code/modules/discord/tgs_commands.dm @@ -4,7 +4,7 @@ /datum/tgs_chat_command/tgscheck/Run(datum/tgs_chat_user/sender, params) var/server = CONFIG_GET(string/public_address) || CONFIG_GET(string/server) - return new /datum/tgs_message_content("[GLOB.round_id ? "Round #[GLOB.round_id]: " : ""][GLOB.clients.len] players on [SSmapping.current_map.map_name]; Round [SSticker.HasRoundStarted() ? (SSticker.IsRoundInProgress() ? "Active" : "Finishing") : "Starting"] -- [server ? server : "[world.internet_address]:[world.port]"]") + return new /datum/tgs_message_content("[GLOB.round_id ? "Round #[GLOB.round_id] ([ROUND_TIME()]): " : "([ROUND_TIME()]): "]Players: [length(GLOB.clients)] (Active: [get_active_player_count(0,1,0)]), Map: [SSmapping.config.map_name], Round [SSticker.HasRoundStarted() ? (SSticker.IsRoundInProgress() ? "Active" : "Finishing") : "Starting/Delayed"] -- Join now! [server]") // APOC EDIT CHANGE - DISCORD /datum/tgs_chat_command/gameversion name = "gameversion" diff --git a/config/apoc_config.txt b/config/apoc_config.txt new file mode 100644 index 000000000000..04429ad80286 --- /dev/null +++ b/config/apoc_config.txt @@ -0,0 +1,2 @@ +## NICE images for COOL discord users, seperated by commas i.e. BITE_IMG_LIST http://url/image.gif, http://url/image.png +# BITE_IMG_LIST diff --git a/modular_zapoc/master_files/code/controllers/configuration/entries/general.dm b/modular_zapoc/master_files/code/controllers/configuration/entries/general.dm new file mode 100644 index 000000000000..c42cd57bdd26 --- /dev/null +++ b/modular_zapoc/master_files/code/controllers/configuration/entries/general.dm @@ -0,0 +1,2 @@ +/datum/config_entry/string/bite_img_list // APOC EDIT START + config_entry_value = "No bites for you." diff --git a/modular_zapoc/modules/discord/tgs_commands.dm b/modular_zapoc/modules/discord/tgs_commands.dm new file mode 100644 index 000000000000..0021ff05d9c2 --- /dev/null +++ b/modular_zapoc/modules/discord/tgs_commands.dm @@ -0,0 +1,11 @@ +// APOC EDIT START - obviously // fangfuckies :3 +/datum/tgs_chat_command/fangfuckies // Friend + name = "fangfuckies" + help_text = "Posts a random biting gif (0.1% chance for an ultra-rare bonus gif.)" + +/datum/tgs_chat_command/fangfuckies/Run(datum/tgs_chat_user/sender, params) + var/random_image = splittext(CONFIG_GET(string/bite_img_list), ", ") // comma + space delimiter + if(prob(0.1)) + return new /datum/tgs_message_content("https://images2.imgbox.com/de/57/LouUHBzY_o.gif") // sneefer + + return new /datum/tgs_message_content("[pick(random_image)]") diff --git a/tgstation.dme b/tgstation.dme index 747a494f82f0..0385d4d1b7ba 100644 --- a/tgstation.dme +++ b/tgstation.dme @@ -7879,6 +7879,7 @@ #include "modular_darkpack\modules\westfield_mall\code\modular_rooms.dm" #include "modular_darkpack\modules\z_travel\code\manhole.dm" #include "modular_darkpack\modules\z_travel\code\transfer_point.dm" +#include "modular_zapoc\master_files\code\controllers\configuration\entries\general.dm" #include "modular_zapoc\master_files\code\game\objects\structures\stairs.dm" #include "modular_zapoc\modules\areas\code\areas.dm" #include "modular_zapoc\modules\areas\code\voivodate.dm" @@ -7897,6 +7898,7 @@ #include "modular_zapoc\modules\decor\code\man_crystal.dm" #include "modular_zapoc\modules\decor\code\superhigh_railing.dm" #include "modular_zapoc\modules\decor\code\torch.dm" +#include "modular_zapoc\modules\discord\tgs_commands.dm" #include "modular_zapoc\modules\gray_masses\code\gray_core.dm" #include "modular_zapoc\modules\gray_masses\code\gray_man.dm" #include "modular_zapoc\modules\gray_masses\code\tall_gray_man.dm" From 42f59af77f5ff17f43761a793c6fcb19173513d5 Mon Sep 17 00:00:00 2001 From: dwinters99 <65516417+dwinters99@users.noreply.github.com> Date: Mon, 11 May 2026 18:14:30 -0400 Subject: [PATCH 2/4] var change --- code/controllers/subsystem/ticker.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 376048b57481..e0b33e2afa39 100644 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -154,7 +154,7 @@ SUBSYSTEM_DEF(ticker) if(SSticker.GetTimeLeft() == -10) // APOC EDIT CHANGE START - DISCORD send2chat(new /datum/tgs_message_content("New round delayed. Thanks for playing Apocrypha XIII!"), channel_tag) // APOC EDIT CHANGE else - send2chat(new /datum/tgs_message_content("<@&1474327242510303336> New round starting on [SSmapping.config.map_name]!"), channel_tag) + send2chat(new /datum/tgs_message_content("<@&1474327242510303336> New round starting on [station_name()]!"), channel_tag) // APOC EDIT CHANGE END current_state = GAME_STATE_PREGAME SEND_SIGNAL(src, COMSIG_TICKER_ENTER_PREGAME) From 9fef7a38fe5d7196a19c51260fac82da50713099 Mon Sep 17 00:00:00 2001 From: dwinters99 <65516417+dwinters99@users.noreply.github.com> Date: Mon, 11 May 2026 18:17:04 -0400 Subject: [PATCH 3/4] ??? --- code/modules/discord/tgs_commands.dm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/code/modules/discord/tgs_commands.dm b/code/modules/discord/tgs_commands.dm index 6d22c9c59b22..4ff42cef2e3f 100644 --- a/code/modules/discord/tgs_commands.dm +++ b/code/modules/discord/tgs_commands.dm @@ -4,7 +4,7 @@ /datum/tgs_chat_command/tgscheck/Run(datum/tgs_chat_user/sender, params) var/server = CONFIG_GET(string/public_address) || CONFIG_GET(string/server) - return new /datum/tgs_message_content("[GLOB.round_id ? "Round #[GLOB.round_id] ([ROUND_TIME()]): " : "([ROUND_TIME()]): "]Players: [length(GLOB.clients)] (Active: [get_active_player_count(0,1,0)]), Map: [SSmapping.config.map_name], Round [SSticker.HasRoundStarted() ? (SSticker.IsRoundInProgress() ? "Active" : "Finishing") : "Starting/Delayed"] -- Join now! [server]") // APOC EDIT CHANGE - DISCORD + return new /datum/tgs_message_content("[GLOB.round_id ? "Round #[GLOB.round_id] ([ROUND_TIME()]): " : "([ROUND_TIME()]): "]Players: [length(GLOB.clients.len)] (Active: [get_active_player_count(0,1,0)]), Map: [station_name()], Round [SSticker.HasRoundStarted() ? (SSticker.IsRoundInProgress() ? "Active" : "Finishing") : "Starting/Delayed"] -- Join now! [server]") // APOC EDIT CHANGE - DISCORD /datum/tgs_chat_command/gameversion name = "gameversion" From 73ff8991e57ef3f0d00b0d52fb71981d58cd5348 Mon Sep 17 00:00:00 2001 From: dwinters99 <65516417+dwinters99@users.noreply.github.com> Date: Mon, 11 May 2026 18:22:19 -0400 Subject: [PATCH 4/4] soft revert --- code/modules/discord/tgs_commands.dm | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/code/modules/discord/tgs_commands.dm b/code/modules/discord/tgs_commands.dm index 4ff42cef2e3f..de9473495e02 100644 --- a/code/modules/discord/tgs_commands.dm +++ b/code/modules/discord/tgs_commands.dm @@ -4,8 +4,9 @@ /datum/tgs_chat_command/tgscheck/Run(datum/tgs_chat_user/sender, params) var/server = CONFIG_GET(string/public_address) || CONFIG_GET(string/server) - return new /datum/tgs_message_content("[GLOB.round_id ? "Round #[GLOB.round_id] ([ROUND_TIME()]): " : "([ROUND_TIME()]): "]Players: [length(GLOB.clients.len)] (Active: [get_active_player_count(0,1,0)]), Map: [station_name()], Round [SSticker.HasRoundStarted() ? (SSticker.IsRoundInProgress() ? "Active" : "Finishing") : "Starting/Delayed"] -- Join now! [server]") // APOC EDIT CHANGE - DISCORD - +// return new /datum/tgs_message_content("[GLOB.round_id ? "Round #[GLOB.round_id] ([ROUND_TIME()]): " : "([ROUND_TIME()]): "]Players: [length(GLOB.clients.len)] (Active: [get_active_player_count(0,1,0)]), Map: [station_name()], Round [SSticker.HasRoundStarted() ? (SSticker.IsRoundInProgress() ? "Active" : "Finishing") : "Starting/Delayed"] -- Join now! [server]") // APOC EDIT CHANGE - DISCORD + return new /datum/tgs_message_content("[GLOB.round_id ? "Round #[GLOB.round_id]: " : ""][GLOB.clients.len] players on [SSmapping.current_map.map_name]; Round [SSticker.HasRoundStarted() ? (SSticker.IsRoundInProgress() ? "Active" : "Finishing") : "Starting"] -- [server ? server : "[world.internet_address]:[world.port]"]") +#warn fix this when the upstream pull is merged /datum/tgs_chat_command/gameversion name = "gameversion" help_text = "Gets the version details from the show-server-revision verb, basically"