[MIRROR] April Fools Day replaces the overflow role with Clowns (#6041)
* April Fools Day replaces the overflow role with Clowns (#36533) * Refactors overflow job assignment * Fixes job selection * April Fools Day replaces the overflow role with Clowns
This commit is contained in:
committed by
Poojawa
parent
4ad2b2975a
commit
99487a6bbb
@@ -655,6 +655,8 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
//The job before the current job. I only use this to get the previous jobs color when I'm filling in blank rows.
|
||||
var/datum/job/lastJob
|
||||
|
||||
var/datum/job/overflow = SSjob.GetJob(SSjob.overflow_role)
|
||||
|
||||
for(var/datum/job/job in SSjob.occupations)
|
||||
|
||||
index += 1
|
||||
@@ -682,7 +684,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
var/available_in_days = job.available_in_days(user.client)
|
||||
HTML += "<font color=red>[rank]</font></td><td><font color=red> \[IN [(available_in_days)] DAYS\]</font></td></tr>"
|
||||
continue
|
||||
if((job_civilian_low & ASSISTANT) && (rank != "Assistant") && !jobban_isbanned(user, "Assistant"))
|
||||
if((job_civilian_low & overflow.flag) && (rank != SSjob.overflow_role) && !jobban_isbanned(user, SSjob.overflow_role))
|
||||
HTML += "<font color=orange>[rank]</font></td><td></td></tr>"
|
||||
continue
|
||||
if((rank in GLOB.command_positions) || (rank == "AI"))//Bold head jobs
|
||||
@@ -721,8 +723,8 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
|
||||
HTML += "<a class='white' href='?_src_=prefs;preference=job;task=setJobLevel;level=[prefUpperLevel];text=[rank]' oncontextmenu='javascript:return setJobPrefRedirect([prefLowerLevel], \"[rank]\");'>"
|
||||
|
||||
if(rank == "Assistant")//Assistant is special
|
||||
if(job_civilian_low & ASSISTANT)
|
||||
if(rank == SSjob.overflow_role)//Overflow is special
|
||||
if(job_civilian_low & overflow.flag)
|
||||
HTML += "<font color=green>Yes</font>"
|
||||
else
|
||||
HTML += "<font color=red>No</font>"
|
||||
@@ -738,7 +740,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
HTML += "</td'></tr></table>"
|
||||
HTML += "</center></table>"
|
||||
|
||||
var/message = "Be an Assistant if preferences unavailable"
|
||||
var/message = "Be an [SSjob.overflow_role] if preferences unavailable"
|
||||
if(joblessrole == BERANDOMJOB)
|
||||
message = "Get random job if preferences unavailable"
|
||||
else if(joblessrole == RETURNTOLOBBY)
|
||||
@@ -826,7 +828,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
ShowChoices(user)
|
||||
return
|
||||
|
||||
if(role == "Assistant")
|
||||
if(role == SSjob.overflow_role)
|
||||
if(job_civilian_low & job.flag)
|
||||
job_civilian_low &= ~job.flag
|
||||
else
|
||||
@@ -976,11 +978,11 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
if("random")
|
||||
switch(joblessrole)
|
||||
if(RETURNTOLOBBY)
|
||||
if(jobban_isbanned(user, "Assistant"))
|
||||
if(jobban_isbanned(user, SSjob.overflow_role))
|
||||
joblessrole = BERANDOMJOB
|
||||
else
|
||||
joblessrole = BEASSISTANT
|
||||
if(BEASSISTANT)
|
||||
joblessrole = BEOVERFLOW
|
||||
if(BEOVERFLOW)
|
||||
joblessrole = BERANDOMJOB
|
||||
if(BERANDOMJOB)
|
||||
joblessrole = RETURNTOLOBBY
|
||||
|
||||
@@ -149,10 +149,11 @@
|
||||
/datum/holiday/april_fools
|
||||
name = APRIL_FOOLS
|
||||
begin_day = 1
|
||||
end_day = 2
|
||||
end_day = 5
|
||||
begin_month = APRIL
|
||||
|
||||
/datum/holiday/april_fools/celebrate()
|
||||
SSjob.overflow_role = "Clown"
|
||||
SSticker.login_music = 'sound/ambience/clown.ogg'
|
||||
for(var/mob/dead/new_player/P in GLOB.mob_list)
|
||||
if(P.client)
|
||||
|
||||
@@ -436,9 +436,9 @@
|
||||
if (job.title in GLOB.command_positions)
|
||||
position_class = "commandPosition"
|
||||
dat += "<a class='[position_class]' href='byond://?src=[REF(src)];SelectedJob=[job.title]'>[job.title] ([job.current_positions])</a><br>"
|
||||
if(!job_count) //if there's nowhere to go, assistant opens up.
|
||||
if(!job_count) //if there's nowhere to go, overflow opens up.
|
||||
for(var/datum/job/job in SSjob.occupations)
|
||||
if(job.title != "Assistant")
|
||||
if(job.title != SSjob.overflow_role)
|
||||
continue
|
||||
dat += "<a class='otherPosition' href='byond://?src=[REF(src)];SelectedJob=[job.title]'>[job.title] ([job.current_positions])</a><br>"
|
||||
break
|
||||
|
||||
Reference in New Issue
Block a user