mirror of
https://github.com/vgstation-coders/vgstation13.git
synced 2025-12-10 02:16:05 +00:00
shitmixedmodeithink
This commit is contained in:
@@ -22,6 +22,9 @@
|
||||
possible_traitors = get_players_for_role(ROLE_TRAITOR)
|
||||
|
||||
for(var/datum/mind/player in possible_traitors)
|
||||
if(mixed && (player in ticker.mode.modePlayer))
|
||||
possible_traitors -= player
|
||||
continue
|
||||
for(var/job in restricted_jobs)
|
||||
if(player.assigned_role == job) //Players with a job that is in the restricted job list can't turn into traitors!
|
||||
possible_traitors -= player
|
||||
@@ -66,7 +69,7 @@
|
||||
continue
|
||||
if(istype(traitor))
|
||||
traitor.special_role = "traitor"
|
||||
|
||||
//if(mixed)ticker.mode.modePlayer |= traitors //merge into master antag list
|
||||
log_admin("Starting a round of AutoTraitor with [traitors.len] starting traitors.")
|
||||
message_admins("Starting a round of AutoTraitor with [traitors.len] starting traitors.")
|
||||
|
||||
|
||||
@@ -133,7 +133,7 @@ You must kill it all while minimizing the damage to the station."})
|
||||
|
||||
sleep(wait_time)
|
||||
|
||||
send_intercept(0)
|
||||
if(!mixed) send_intercept(0)
|
||||
|
||||
sleep(100)
|
||||
|
||||
@@ -173,7 +173,7 @@ You must kill it all while minimizing the damage to the station."})
|
||||
var/T = M.loc
|
||||
if((istype(T, /turf/space)) || ((istype(T, /turf)) && (M.z!=1)))
|
||||
pre_escapees += M
|
||||
send_intercept(1)
|
||||
if(!mixed) send_intercept(1)
|
||||
outbreak = 1
|
||||
|
||||
research_shuttle.lockdown = "Under directive 7-10, [station_name()] is quarantined until further notice." //LOCKDOWN THESE SHUTTLES
|
||||
@@ -182,5 +182,5 @@ You must kill it all while minimizing the damage to the station."})
|
||||
command_alert("Biohazard outbreak containment status reaching critical mass, total quarantine failure is now possibile. As such, Directive 7-12 has now been authorized for [station_name()].", "Final Measure")
|
||||
for(var/mob/camera/blob/B in player_list)
|
||||
to_chat(B, "<span class='blob'>The beings intend to eliminate you with a final suicidal attack, you must stop them quickly or consume the station before this occurs!</span>")
|
||||
send_intercept(2)
|
||||
if(!mixed) send_intercept(2)
|
||||
return
|
||||
|
||||
@@ -52,6 +52,9 @@ var/list/possible_changeling_IDs = list("Alpha","Beta","Gamma","Delta","Epsilon"
|
||||
var/list/datum/mind/possible_changelings = get_players_for_role(ROLE_CHANGELING)
|
||||
|
||||
for(var/datum/mind/player in possible_changelings)
|
||||
if(mixed && (player in ticker.mode.modePlayer))
|
||||
possible_changelings -= player
|
||||
continue
|
||||
for(var/job in restricted_jobs)//Removing robots from the list
|
||||
if(player.assigned_role == job)
|
||||
possible_changelings -= player
|
||||
@@ -74,6 +77,7 @@ var/list/possible_changeling_IDs = list("Alpha","Beta","Gamma","Delta","Epsilon"
|
||||
modePlayer += changelings
|
||||
log_admin("Starting a round of changeling with [changelings.len] changelings.")
|
||||
message_admins("Starting a round of changeling with [changelings.len] changelings.")
|
||||
//if(mixed) ticker.mode.modePlayer |= changelings
|
||||
return 1
|
||||
else
|
||||
log_admin("Failed to set-up a round of changeling. Couldn't find any volunteers to be changeling.")
|
||||
@@ -88,7 +92,7 @@ var/list/possible_changeling_IDs = list("Alpha","Beta","Gamma","Delta","Epsilon"
|
||||
greet_changeling(changeling)
|
||||
if(!mixed)
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
return
|
||||
|
||||
|
||||
@@ -22,6 +22,9 @@
|
||||
var/list/datum/mind/possible_changelings = get_players_for_role(ROLE_CHANGELING)
|
||||
|
||||
for(var/datum/mind/player in possible_changelings)
|
||||
if(mixed && (player in ticker.mode.modePlayer))
|
||||
possible_changelings -= player
|
||||
continue
|
||||
for(var/job in restricted_jobs)//Removing robots from the list
|
||||
if(player.assigned_role == job)
|
||||
possible_changelings -= player
|
||||
@@ -31,7 +34,12 @@
|
||||
//possible_changelings-=changeling
|
||||
changelings += changeling
|
||||
modePlayer += changelings
|
||||
return ..()
|
||||
//if(mixed) ticker.mode.modePlayer |= changelings
|
||||
. = ..()
|
||||
if(!. && mixed)
|
||||
for(var/datum/mind/P in modePlayer)
|
||||
ticker.mode.modePlayer -= P
|
||||
return .
|
||||
else
|
||||
return 0
|
||||
|
||||
|
||||
@@ -91,6 +91,9 @@
|
||||
|
||||
var/list/cultists_possible = get_players_for_role(ROLE_CULTIST)
|
||||
for(var/datum/mind/player in cultists_possible)
|
||||
if(mixed && (player in ticker.mode.modePlayer))
|
||||
cultists_possible -= player
|
||||
continue
|
||||
for(var/job in restricted_jobs)//Removing heads and such from the list
|
||||
if(player.assigned_role == job)
|
||||
cultists_possible -= player
|
||||
@@ -102,14 +105,16 @@
|
||||
cultists_possible -= cultist
|
||||
cult += cultist
|
||||
|
||||
if(cult.len <= 0)
|
||||
. = cult.len <= 0
|
||||
if(.)
|
||||
log_admin("Failed to set-up a round of cult. Couldn't pick any players to be starting cultists.")
|
||||
message_admins("Failed to set-up a round of cult. Couldn't pick any players to be starting cultists.")
|
||||
else
|
||||
log_admin("Starting a round of cult with [cult.len] starting cultists.")
|
||||
message_admins("Starting a round of cult with [cult.len] starting cultists.")
|
||||
//if(mixed) ticker.mode.modePlayer |= cult
|
||||
|
||||
return (cult.len > 0)
|
||||
return !.
|
||||
|
||||
/datum/game_mode/cult/proc/blood_check()
|
||||
max_spilled_blood = (max(bloody_floors.len,max_spilled_blood))
|
||||
@@ -261,7 +266,7 @@
|
||||
|
||||
if(!mixed)
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
|
||||
/datum/game_mode/cult/proc/pick_objective()
|
||||
|
||||
@@ -138,7 +138,7 @@
|
||||
stage = 1
|
||||
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
|
||||
|
||||
..()
|
||||
|
||||
@@ -20,5 +20,5 @@
|
||||
|
||||
/datum/game_mode/extended/post_setup()
|
||||
spawn (rand(waittime_l, waittime_h)) // To reduce extended meta.
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
@@ -101,7 +101,7 @@
|
||||
greet_vox(raider)
|
||||
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
|
||||
/datum/game_mode/heist/proc/is_raider_crew_alive()
|
||||
var/raider_crew_count = raiders.len
|
||||
|
||||
@@ -83,7 +83,7 @@ Rebooting world in 5 seconds."})
|
||||
if(emergency_shuttle)
|
||||
emergency_shuttle.always_fake_recall = 1
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
|
||||
|
||||
|
||||
@@ -102,7 +102,7 @@
|
||||
log_admin("Created [memes.len] memes.")
|
||||
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
return
|
||||
|
||||
|
||||
@@ -50,7 +50,7 @@
|
||||
message_admins("Meteor storm confirmed by Space Weather Incorporated. Announcement arrives in [round((meteorannouncedelay-450)/600)] minutes, actual meteors in [round((meteordelay+meteorannouncedelay-450)/600)] minutes. Shuttle will take [10*meteorshuttlemultiplier] minutes to arrive and supplies will be dispatched in the Bar.")
|
||||
|
||||
spawn(rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
|
||||
spawn(meteorannouncedelay)
|
||||
if(prob(70)) //Slighty off-scale
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
/datum/game_mode/mixed
|
||||
name = "mixed"
|
||||
config_tag = "mixed"
|
||||
var/list/datum/game_mode/modes[3] // 3 game modes in 1
|
||||
|
||||
var/list/datum/game_mode/modes // 3 game modes in 1
|
||||
var/list/datum/mind/picked_antags
|
||||
uplink_welcome = "Syndicate Uplink Console:"
|
||||
uplink_uses = 10
|
||||
|
||||
required_players = 20
|
||||
required_players = 1
|
||||
required_players_secret = 25
|
||||
|
||||
var/const/prob_int_murder_target = 50 // intercept names the assassination target half the time
|
||||
@@ -34,17 +34,44 @@
|
||||
to_chat(world, "<B>Anything can happen!</B>")
|
||||
|
||||
/datum/game_mode/mixed/pre_setup()
|
||||
. = 1
|
||||
modes = list()
|
||||
picked_antags = list()
|
||||
var/list/datum/game_mode/possible = typesof(/datum/game_mode) - list(/datum/game_mode, /datum/game_mode/mixed, /datum/game_mode/malfunction, /datum/game_mode/traitor, /datum/game_mode/traitor/double_agents, /datum/game_mode/sandbox, /datum/game_mode/revolution, /datum/game_mode/meteor, /datum/game_mode/extended, /datum/game_mode/heist, /datum/game_mode/nuclear, /datum/game_mode/traitor/changeling, /datum/game_mode/wizard/raginmages, /datum/game_mode/blob)
|
||||
possible = shuffle(possible)
|
||||
for(var/i = 0, i < 2, i++)
|
||||
var/datum/game_mode/M = pick(possible)
|
||||
modes[i] = M
|
||||
while(modes.len < 3)
|
||||
if(!possible.len) break
|
||||
var/ourmode = pick(possible)
|
||||
possible -= ourmode
|
||||
var/datum/game_mode/M = new ourmode
|
||||
M.mixed = 1
|
||||
if(!M.pre_setup())
|
||||
del(M)
|
||||
continue
|
||||
modePlayer |= M.modePlayer
|
||||
modes += M
|
||||
possible = shuffle(possible)
|
||||
for(var/datum/game_mode/M in modes)
|
||||
M.pre_setup()
|
||||
if(!modes.len)
|
||||
. = 0
|
||||
else
|
||||
var/keylist[]
|
||||
for(var/datum/mind/mind in modePlayer)
|
||||
keylist += mind
|
||||
log_admin("The gamemode setup for mixed started with [modes.len] mode\s [list2text(modes, " ")] with [list2text(keylist, " ")] as antag\s.")
|
||||
message_admins("The gamemode setup for mixed started with [modes.len] mode\s.")
|
||||
world.log << "The gamemode setup for mixed started with [modes.len] mode\s [list2text(modes, " ")] with [list2text(keylist, " ")] as antag\s."
|
||||
|
||||
|
||||
/datum/game_mode/mixed/post_setup()
|
||||
for(var/datum/game_mode/M in modes)
|
||||
M.post_setup()
|
||||
spawn() M.post_setup()
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
|
||||
/datum/game_mode/mixed/check_finished()
|
||||
for(var/datum/game_mode/M in modes)
|
||||
if(M.check_finished())
|
||||
return 1
|
||||
/datum/game_mode/mixed/declare_completion()
|
||||
for(var/datum/game_mode/M in modes)
|
||||
M.declare_completion()
|
||||
@@ -178,7 +178,7 @@
|
||||
the_bomb.r_code = nuke_code
|
||||
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
|
||||
return ..()
|
||||
|
||||
|
||||
@@ -83,7 +83,7 @@
|
||||
greet_head(head_mind)
|
||||
modePlayer += heads
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
|
||||
|
||||
|
||||
@@ -96,7 +96,7 @@
|
||||
if(emergency_shuttle)
|
||||
emergency_shuttle.always_fake_recall = 1
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
|
||||
|
||||
|
||||
@@ -94,7 +94,7 @@
|
||||
obj_count++
|
||||
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
|
||||
/datum/game_mode/rp_revolution/send_intercept()
|
||||
var/intercepttext = "<FONT size = 3><B>Cent. Com. Update</B> Requested staus information:</FONT><HR>"
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
|
||||
modePlayer += head_revolutionaries
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
|
||||
/datum/game_mode/revolution/rp_revolution/greet_revolutionary(var/datum/mind/rev_mind, var/you_are=1)
|
||||
var/obj_count = 1
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
modePlayer += traitors
|
||||
if(!mixed)
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
return 1
|
||||
|
||||
|
||||
@@ -57,6 +57,9 @@
|
||||
var/list/datum/mind/possible_vampires = get_players_for_role(ROLE_VAMPIRE)
|
||||
|
||||
for(var/datum/mind/player in possible_vampires)
|
||||
if(mixed && (player in ticker.mode.modePlayer))
|
||||
possible_vampires -= player
|
||||
continue
|
||||
for(var/job in restricted_jobs)//Removing robots from the list
|
||||
if(player.assigned_role == job)
|
||||
possible_vampires -= player
|
||||
@@ -73,6 +76,7 @@
|
||||
modePlayer += vampires
|
||||
log_admin("Starting a round of vampire with [vampires.len] vampires.")
|
||||
message_admins("Starting a round of vampire with [vampires.len] vampires.")
|
||||
//if(mixed) ticker.mode.modePlayer |= vampires
|
||||
return 1
|
||||
else
|
||||
log_admin("Failed to set-up a round of vampire. Couldn't find any volunteers to be vampires.")
|
||||
@@ -87,7 +91,7 @@
|
||||
greet_vampire(vampire)
|
||||
if(!mixed)
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
return
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
var/datum/mind/wizard
|
||||
while(possible_wizards.len)
|
||||
wizard = pick(possible_wizards)
|
||||
if(wizard.special_role)
|
||||
if(wizard.special_role || (mixed && (wizard in ticker.mode.modePlayer)))
|
||||
possible_wizards -= wizard
|
||||
wizard = null
|
||||
continue
|
||||
@@ -75,7 +75,7 @@
|
||||
update_all_wizard_icons()
|
||||
if(!mixed)
|
||||
spawn (rand(waittime_l, waittime_h))
|
||||
send_intercept()
|
||||
if(!mixed) send_intercept()
|
||||
..()
|
||||
return
|
||||
|
||||
|
||||
@@ -1 +1 @@
|
||||
sandbox
|
||||
mixed
|
||||
|
||||
Reference in New Issue
Block a user