diff --git a/code/controllers/subsystem/ticker.dm b/code/controllers/subsystem/ticker.dm index 17fb9f71624..855059c2188 100644 --- a/code/controllers/subsystem/ticker.dm +++ b/code/controllers/subsystem/ticker.dm @@ -36,6 +36,7 @@ var/datum/subsystem/ticker/ticker var/triai = 0 //Global holder for Triumvirate var/tipped = 0 //Did we broadcast the tip of the day yet? + var/selected_tip // What will be the tip of the day? var/timeLeft = 1200 //pregame timer @@ -88,8 +89,8 @@ var/datum/subsystem/ticker/ticker timeLeft -= wait if(timeLeft <= 300 && !tipped) - send_random_tip() - tipped = 1 + send_tip_of_the_round() + tipped = TRUE if(timeLeft <= 0) current_state = GAME_STATE_SETTING_UP @@ -447,13 +448,21 @@ var/datum/subsystem/ticker/ticker return 1 -/datum/subsystem/ticker/proc/send_random_tip() - var/list/randomtips = file2list("config/tips.txt") - var/list/memetips = file2list("config/sillytips.txt") - if(randomtips.len && prob(95)) - world << "Tip of the round: [html_encode(pick(randomtips))]" - else if(memetips.len) - world << "Tip of the round: [html_encode(pick(memetips))]" +/datum/subsystem/ticker/proc/send_tip_of_the_round() + var/m + if(selected_tip) + m = selected_tip + else + var/list/randomtips = file2list("config/tips.txt") + var/list/memetips = file2list("config/sillytips.txt") + if(randomtips.len && prob(95)) + m = pick(randomtips) + else if(memetips.len) + m = pick(memetips) + + if(m) + world << "Tip of the round: \ + [html_encode(m)]" /datum/subsystem/ticker/proc/check_queue() if(!queued_players.len || !config.hard_popcap) @@ -525,6 +534,7 @@ var/datum/subsystem/ticker/ticker triai = ticker.triai tipped = ticker.tipped + selected_tip = ticker.selected_tip timeLeft = ticker.timeLeft diff --git a/code/modules/admin/admin_verbs.dm b/code/modules/admin/admin_verbs.dm index 800aeb911b9..5f957e88dd6 100644 --- a/code/modules/admin/admin_verbs.dm +++ b/code/modules/admin/admin_verbs.dm @@ -97,7 +97,8 @@ var/list/admin_verbs_fun = list( /client/proc/toggle_nuke, /client/proc/mass_zombie_infection, /client/proc/mass_zombie_cure, - /client/proc/polymorph_all + /client/proc/polymorph_all, + /client/proc/show_tip ) var/list/admin_verbs_spawn = list( /datum/admins/proc/spawn_atom, /*allows us to spawn instances*/ diff --git a/code/modules/admin/verbs/randomverbs.dm b/code/modules/admin/verbs/randomverbs.dm index 6bc96629d66..a36d82818ae 100644 --- a/code/modules/admin/verbs/randomverbs.dm +++ b/code/modules/admin/verbs/randomverbs.dm @@ -1063,6 +1063,34 @@ var/list/datum/outfit/custom_outfits = list() //Admin created outfits message_admins("Mass polymorph started by [who_did_it] is complete.") + +/client/proc/show_tip() + set category = "Admin" + set name = "Show Tip" + set desc = "Sends a tip (that you specify) to all players. After all \ + you're the experienced player here." + + if(!holder) + return + + var/input = input(usr, "Please specify your tip that you want to send to the players.", "Tip", "") as message|null + if(!input) + return + + if(!ticker) + return + + ticker.selected_tip = input + + // If we've already tipped, then send it straight away. + if(ticker.tipped) + ticker.send_tip_of_the_round() + + + message_admins("[key_name_admin(usr)] sent a tip of the round.") + log_admin("[key_name(usr)] sent \"[input]\" as the Tip of the Round.") + feedback_add_details("admin_verb","TIP") + #define ON_PURRBATION(H) (!(H.dna.features["tail_human"] == "None" && H.dna.features["ears"] == "None")) /proc/mass_purrbation()