Fixes config.continous_rounds and adds check

This commit is contained in:
mwerezak
2014-06-01 15:49:13 -04:00
parent dbe43db59a
commit cc4a6e0f26
3 changed files with 10 additions and 4 deletions

View File

@@ -40,7 +40,7 @@
var/traitor_scaling = 0 //if amount of traitors scales based on amount of players var/traitor_scaling = 0 //if amount of traitors scales based on amount of players
var/objectives_disabled = 0 //if objectives are disabled or not var/objectives_disabled = 0 //if objectives are disabled or not
var/protect_roles_from_antagonist = 0// If security and such can be traitor/cult/other var/protect_roles_from_antagonist = 0// If security and such can be traitor/cult/other
var/continous_rounds = 1 // Gamemodes which end instantly will instead keep on going until the round ends by escape shuttle or nuke. var/continous_rounds = 0 // Gamemodes which end instantly will instead keep on going until the round ends by escape shuttle or nuke.
var/allow_Metadata = 0 // Metadata is supported. var/allow_Metadata = 0 // Metadata is supported.
var/popup_admin_pm = 0 //adminPMs to non-admins show in a pop-up 'reply' window when set to 1. var/popup_admin_pm = 0 //adminPMs to non-admins show in a pop-up 'reply' window when set to 1.
var/Ticklag = 0.9 var/Ticklag = 0.9

View File

@@ -129,7 +129,7 @@ Implants;
return 1 return 1
return 0 return 0
/datum/game_mode/proc/cleanup() //the end conditions specified by check_finished() have been met, let's clean up. /datum/game_mode/proc/cleanup() //This is called when the round has ended but not the game, if any cleanup would be necessary in that case.
return return
/datum/game_mode/proc/declare_completion() /datum/game_mode/proc/declare_completion()

View File

@@ -310,8 +310,14 @@ var/global/datum/controller/gameticker/ticker
emergency_shuttle.process() emergency_shuttle.process()
var/mode_finished = (!post_game && mode.check_finished()) var/game_finished = 0
var/game_finished = (emergency_shuttle.location == 2 || mode.station_was_nuked) var/mode_finished = 0
if (config.continous_rounds)
game_finished = (emergency_shuttle.location == 2 || mode.station_was_nuked)
mode_finished = (!post_game && mode.check_finished())
else
game_finished = (mode.check_finished() || (emergency_shuttle.location == 2 && emergency_shuttle.alert == 1))
mode_finished = game_finished
if(!mode.explosion_in_progress && game_finished && (mode_finished || post_game)) if(!mode.explosion_in_progress && game_finished && (mode_finished || post_game))
current_state = GAME_STATE_FINISHED current_state = GAME_STATE_FINISHED