From 0019b5a742333b807c88a032c7c235dfd2c8093b Mon Sep 17 00:00:00 2001 From: Putnam3145 Date: Fri, 1 May 2020 09:02:00 -0700 Subject: [PATCH] Game info verb for ghosts (#11935) * Some ghost QoL stuff * DNR/observer only --- code/game/gamemodes/dynamic/dynamic.dm | 8 ++++++++ code/game/gamemodes/game_mode.dm | 4 ++++ code/modules/mob/dead/observer/observer.dm | 17 +++++++++++++++++ 3 files changed, 29 insertions(+) diff --git a/code/game/gamemodes/dynamic/dynamic.dm b/code/game/gamemodes/dynamic/dynamic.dm index e6e10941c4..659d50c077 100644 --- a/code/game/gamemodes/dynamic/dynamic.dm +++ b/code/game/gamemodes/dynamic/dynamic.dm @@ -839,3 +839,11 @@ GLOBAL_VAR_INIT(dynamic_forced_storyteller, null) return RULE_OF_THREE(40, 20, x) + 50 if (20 to INFINITY) return rand(90, 100) + +/datum/game_mode/dynamic/ghost_info() + . = list() + . += "Current threat: [threat]" + . += "Target threat: [threat_level]" + . += "Storyteller: [storyteller.name]
" + . += "Parameters: centre = [GLOB.dynamic_curve_centre] ; width = [GLOB.dynamic_curve_width].
" + . += "On average, [peaceful_percentage]% of the rounds are more peaceful.
" diff --git a/code/game/gamemodes/game_mode.dm b/code/game/gamemodes/game_mode.dm index 57919863f2..e2c549d911 100644 --- a/code/game/gamemodes/game_mode.dm +++ b/code/game/gamemodes/game_mode.dm @@ -604,3 +604,7 @@ /// Mode specific admin panel. /datum/game_mode/proc/admin_panel() return + +/// Mode specific info for ghost game_info +/datum/game_mode/proc/ghost_info() + return diff --git a/code/modules/mob/dead/observer/observer.dm b/code/modules/mob/dead/observer/observer.dm index dc7384124d..b8e56f3d7c 100644 --- a/code/modules/mob/dead/observer/observer.dm +++ b/code/modules/mob/dead/observer/observer.dm @@ -937,3 +937,20 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp spawners_menu = new(src) spawners_menu.ui_interact(src) + +/mob/dead/observer/verb/game_info() + set name = "Game info" + set desc = "Shows various info relating to the game mode, antagonists etc." + set category = "Ghost" + if(!started_as_observer && can_reenter_corpse) + to_chat(src, "You cannot see this info unless you are an observer or you've chosen Do Not Resuscitate!") + return + var/list/stuff = list("[SSticker.mode.name]") + stuff += "Antagonists:\n" + for(var/datum/antagonist/A in GLOB.antagonists) + if(A.owner) + stuff += "[A.owner] the [A.name]" + var/ghost_info = SSticker.mode.ghost_info() + if(ghost_info) + stuff += ghost_info + to_chat(src,stuff.Join("\n"))