Update to feedback gathering:

- Rounds that end in invalid ways will now be logged,
- Round results are logged

- Rounds that don't end with a code-determined reboot will still not log at all (so rounds that end in a crash will not log at all - not even round start or mode.)

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@2457 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
baloh.matevz
2011-10-30 18:42:19 +00:00
parent 1fe9c0b2fd
commit 1f9a77c377
22 changed files with 123 additions and 6 deletions

View File

@@ -116,15 +116,18 @@
/datum/game_mode/blob/declare_completion()
if(stage >= 3)
feedback_set_details("round_end_result","loss - blob took over")
world << "<FONT size = 3><B>The blob has taken over the station!</B></FONT>"
world << "<B>The entire station was eaten by the Blob</B>"
check_quarantine()
else if(station_was_nuked)
feedback_set_details("round_end_result","halfwin - nuke")
world << "<FONT size = 3><B>Partial Win: The station has been destroyed!</B></FONT>"
world << "<B>Directive 7-12 has been successfully carried out preventing the Blob from spreading.</B>"
else
feedback_set_details("round_end_result","win - blob eliminated")
world << "<FONT size = 3><B>The staff has won!</B></FONT>"
world << "<B>The alien organism has been eradicated from the station</B>"

View File

@@ -284,8 +284,12 @@
/datum/game_mode/cult/declare_completion()
if(!check_cult_victory())
feedback_set_details("round_end_result","win - cult win")
feedback_set("round_end_result",acolytes_survived)
world << "\red <FONT size = 3><B> The cult wins! It has succeeded in serving its dark masters!</B></FONT>"
else
feedback_set_details("round_end_result","loss - staff stopped the cult")
feedback_set("round_end_result",acolytes_survived)
world << "\red <FONT size = 3><B> The staff managed to stop the cult!</B></FONT>"
world << "\b Cultists escaped: [acolytes_survived]"

View File

@@ -168,9 +168,16 @@ var/global/datum/controller/gameticker/ticker
spawn(50)
if (mode.station_was_nuked)
feedback_set_details("end_proper","nuke")
world << "\blue <B>Rebooting due to destruction of station in [restart_timeout/10] seconds</B>"
else
feedback_set_details("end_proper","proper completion")
world << "\blue <B>Restarting in [restart_timeout/10] seconds</B>"
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
sleep(restart_timeout)
world.Reboot()
@@ -207,8 +214,4 @@ var/global/datum/controller/gameticker/ticker
if (findtext("[handler]","auto_declare_completion_"))
call(mode, handler)()
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
return 1

View File

@@ -36,6 +36,11 @@
if(malf_ai.len < 1)
world << "Uh oh, its malfunction and there is no AI! Please report this."
world << "Rebooting world in 5 seconds."
feedback_set_details("end_error","malf - no AI")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
sleep(50)
world.Reboot()
return
@@ -193,30 +198,37 @@
var/crew_evacuated = (emergency_shuttle.location==2)
if ( station_captured && station_was_nuked)
feedback_set_details("round_end_result","win - AI win - nuke")
world << "<FONT size = 3><B>AI Victory</B></FONT>"
world << "<B>Everyone was killed by the self-destruct!</B>"
else if ( station_captured && malf_dead && !station_was_nuked)
feedback_set_details("round_end_result","halfwin - AI killed, staff lost control")
world << "<FONT size = 3><B>Neutral Victory</B></FONT>"
world << "<B>The AI has been killed!</B> The staff has lose control over the station."
else if ( station_captured && !malf_dead && !station_was_nuked)
feedback_set_details("round_end_result","win - AI win - no explosion")
world << "<FONT size = 3><B>AI Victory</B></FONT>"
world << "<B>The AI has chosen not to explode you all!</B>"
else if (!station_captured && station_was_nuked)
feedback_set_details("round_end_result","halfwin - everyone killed by nuke")
world << "<FONT size = 3><B>Neutral Victory</B></FONT>"
world << "<B>Everyone was killed by the nuclear blast!</B>"
else if (!station_captured && malf_dead && !station_was_nuked)
feedback_set_details("round_end_result","loss - staff win")
world << "<FONT size = 3><B>Human Victory</B></FONT>"
world << "<B>The AI has been killed!</B> The staff is victorious."
else if (!station_captured && !malf_dead && !station_was_nuked && crew_evacuated)
feedback_set_details("round_end_result","halfwin - evacuated")
world << "<FONT size = 3><B>Neutral Victory</B></FONT>"
world << "<B>The Corporation has lose [station_name()]! All survived personnel will be fired!</B>"
else if (!station_captured && !malf_dead && !station_was_nuked && !crew_evacuated)
feedback_set_details("round_end_result","nalfwin - interrupted")
world << "<FONT size = 3><B>Neutral Victory</B></FONT>"
world << "<B>Round was mysteriously interrupted!</B>"
..()

View File

@@ -46,6 +46,9 @@
else
survivors[player.real_name] = "alive"
feedback_set_details("round_end_result","end - evacuation")
feedback_set("round_end_result",survivors.len)
if (survivors.len)
world << "\blue <B>The following survived the meteor attack!</B>"
for(var/survivor in survivors)

View File

@@ -263,34 +263,42 @@
//herp //Used for tracking if the syndies got the shuttle off of the z-level
if (!disk_rescued && station_was_nuked && !herp)
feedback_set_details("round_end_result","win - syndicate nuke")
world << "<FONT size = 3><B>Syndicate Victory!</B></FONT>"
world << "<B>[syndicate_name()] operatives have destroyed [station_name()]!</B>"
else if (!disk_rescued && station_was_nuked && herp)
feedback_set_details("round_end_result","halfwin - syndicate nuke - did not evacuate in time")
world << "<FONT size = 3><B>Total Annihilation</B></FONT>"
world << "<B>[syndicate_name()] operatives destroyed [station_name()] but did not leave the area in time and got caught in the explosion.</B> Next time, don't lose the disk!"
else if (!disk_rescued && !station_was_nuked && derp && !herp)
feedback_set_details("round_end_result","halfwin - blew wrong station")
world << "<FONT size = 3><B>Neutral Victory</B></FONT>"
world << "<B>[syndicate_name()] operatives secured the authentication disk but blew up something that wasn't [station_name()].</B> Next time, don't lose the disk!"
else if (!disk_rescued && !station_was_nuked && derp && herp)
feedback_set_details("round_end_result","halfwin - blew wrong station - did not evacuate in time")
world << "<FONT size = 3><B>[syndicate_name()] operatives have earned Darwin Award!</B></FONT>"
world << "<B>[syndicate_name()] operatives blew up something that wasn't [station_name()] and got caught in the explosion.</B> Next time, don't lose the disk!"
else if ( disk_rescued )
feedback_set_details("round_end_result","loss - evacuation - disk secured")
world << "<FONT size = 3><B>Crew Victory</B></FONT>"
world << "<B>The Research Staff has saved the disc and stopped the [syndicate_name()] Operatives!</B>"
else if (!disk_rescued && is_operatives_are_dead())
feedback_set_details("round_end_result","loss - evacuation - disk not secured")
world << "<FONT size = 3><B>Crew Victory</B></FONT>"
world << "<B>The Research Staff has stopped the [syndicate_name()] Operatives!</B>"
else if (!disk_rescued && crew_evacuated)
feedback_set_details("round_end_result","halfwin - detonation averted")
world << "<FONT size = 3><B>Neutral Victory</B></FONT>"
world << "<B>[syndicate_name()] operatives recovered the abandoned authentication disk but detonation of [station_name()] was averted.</B> Next time, don't lose the disk!"
else if (!disk_rescued && !crew_evacuated)
feedback_set_details("round_end_result","halfwin - interrupted")
world << "<FONT size = 3><B>Neutral Victory</B></FONT>"
world << "<B>Round was mysteriously interrupted!</B>"

View File

@@ -206,6 +206,11 @@
if(!ticker.mode.check_finished())//If the mode does not deal with the nuke going off so just reboot because everyone is stuck as is
world << "<B>Resetting in 30 seconds!</B>"
feedback_set_details("end_error","nuke - unhandled ending")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
sleep(300)
log_game("Rebooting due to nuclear detonation")
world.Reboot()

View File

@@ -303,8 +303,10 @@
//////////////////////////////////////////////////////////////////////
/datum/game_mode/revolution/declare_completion()
if(finished == 1)
feedback_set_details("round_end_result","win - heads killed")
world << "\red <FONT size = 3><B> The heads of staff were killed or abandoned the station! The revolutionaries win!</B></FONT>"
else if(finished == 2)
feedback_set_details("round_end_result","loss - rev heads killed")
world << "\red <FONT size = 3><B> The heads of staff managed to stop the revolution!</B></FONT>"
..()
return 1

View File

@@ -198,6 +198,7 @@
/datum/game_mode/wizard/declare_completion()
if(finished)
feedback_set_details("round_end_result","loss - wizard killed")
world << "\red <FONT size = 3><B> The wizard[(wizards.len>1)?"s":""] has been killed by the crew! The Space Wizards Federation has been taught a lesson they will not soon forget!</B></FONT>"
..()
return 1

View File

@@ -77,6 +77,11 @@
if(ticker)
world <<"\red <B>World will reboot in 10 seconds</B>"
feedback_set_details("end_error","mode vote - [winner]")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
sleep(100)
log_game("Rebooting due to mode vote")
world.Reboot()
@@ -93,6 +98,11 @@
world <<"\red <B>World will reboot in 5 seconds</B>"
feedback_set_details("end_error","restart vote")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
sleep(50)
log_game("Rebooting due to restart vote")
world.Reboot()

View File

@@ -2133,9 +2133,14 @@
if(confirm == "Cancel")
return
if(confirm == "Yes")
world << "\red <b>Restarting world!</b> \blue Initiated by [usr.client.stealth ? "Admin Candidate" : usr.key]!"
world << "\red <b>Restarting world!</b> \blue Initiated by [usr.client.stealth ? "Admin" : usr.key]!"
log_admin("[key_name(usr)] initiated a reboot.")
feedback_set_details("end_error","admin reboot - by [usr.key] [usr.client.stealth ? "(stealth)" : ""]")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
sleep(50)
world.Reboot()
@@ -2290,8 +2295,14 @@
set name="Immediate Reboot"
if( alert("Reboot server?",,"Yes","No") == "No")
return
world << "\red <b>Rebooting world!</b> \blue Initiated by [usr.client.stealth ? "Admin Candidate" : usr.key]!"
world << "\red <b>Rebooting world!</b> \blue Initiated by [usr.client.stealth ? "Admin" : usr.key]!"
log_admin("[key_name(usr)] initiated an immediate reboot.")
feedback_set_details("end_error","immediate admin reboot - by [usr.key] [usr.client.stealth ? "(stealth)" : ""]")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
world.Reboot()
/client/proc/deadchat()

View File

@@ -48,6 +48,11 @@
if (!cancel && !abandon_allowed)
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn (300)
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -51,6 +51,11 @@
if (!cancel && !abandon_allowed)
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn (300)
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -24,6 +24,12 @@
break
if (!( cancel ))
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn( 300 )
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -64,6 +64,11 @@
if (!cancel && !abandon_allowed)
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn (300)
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -43,6 +43,12 @@
break
if (!( cancel ))
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn( 300 )
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -32,6 +32,12 @@
break
if (!( cancel ))
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn( 300 )
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -53,6 +53,12 @@
break
if (!( cancel ))
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn( 300 )
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -19,6 +19,12 @@
break
if (!( cancel ))
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn( 300 )
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -34,6 +34,12 @@
break
if (!( cancel ))
world << "<B>Everyone is dead! Resetting in 30 seconds!</B>"
feedback_set_details("end_error","no live players")
feedback_set_details("round_end","[time2text(world.realtime)]")
if(blackbox)
blackbox.save_all_data_to_sql()
spawn( 300 )
log_game("Rebooting because of no live players")
world.Reboot()

View File

@@ -105,6 +105,7 @@
break
if (monkeywin)
feedback_set_details("round_end_result","win - monkey win")
world << "<FONT size=3 color=red><B>The monkeys have won! Humanity is doomed!</B></FONT>"
for (var/mob/living/carbon/human/player in world)
if (player.client)
@@ -112,6 +113,7 @@
player.monkeyize()
sleep(200)
else
feedback_set_details("round_end_result","loss - crew win")
world << "<FONT size=3 color=red><B>The Research Staff has stopped the monkey invasion!</B></FONT>"
..()
return 1

View File

@@ -49,8 +49,10 @@
/datum/game_mode/ruby/declare_completion()
if(abominationwins)
feedback_set_details("round_end_result","win - abomination win")
world << "<B>The Abomination has murdered the station and sacrificed himself to Cjopaze!</B> (played by [winnerkey])"
else
feedback_set_details("round_end_result","loss - abomination killed")
world << "<B>The Abomination has been stopped and Cjopaze's influence resisted! The station lives another day,</B>"
if(killed.len > 0)
world << "Those who were sacrificed shall be remembered: "