This commit is contained in:
Ryll-Ryll
2020-07-20 22:12:02 -04:00
parent 732d83f249
commit dca567b119
3 changed files with 14 additions and 42 deletions
+7 -1
View File
@@ -1262,7 +1262,13 @@
//Job + antagonist
if(M.mind)
special_role_description = "Role: <b>[M.mind.assigned_role]</b>; Antagonist: <font color='red'><b>[M.mind.special_role]</b></font>"
special_role_description = "Role: <b>[M.mind.assigned_role]</b>; Antagonist: <font color='red'><b>"
var/i = 0
for(var/datum/antagonist/A in M.mind.antag_datums)
special_role_description += "[A.name]"
if(i++ != length(M.mind.antag_datums))
special_role_description += ", "
special_role_description += "</b></font>"
else
special_role_description = "Role: <i>Mind datum missing</i> Antagonist: <i>Mind datum missing</i>"
+1 -1
View File
@@ -668,7 +668,7 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
if(!ai_found && isAI(found))
ai_found = 1
var/is_antag = 0
if(found.mind && found.mind.special_role)
if(is_special_character(found))
is_antag = 1
founds += "Name: [found.name]([found.real_name]) Key: [found.key] Ckey: [found.ckey] [is_antag ? "(Antag)" : null] "
msg += "[original_word]<font size='1' color='[is_antag ? "red" : "black"]'>(<A HREF='?_src_=holder;[HrefToken(TRUE)];adminmoreinfo=[REF(found)]'>?</A>|<A HREF='?_src_=holder;[HrefToken(TRUE)];adminplayerobservefollow=[REF(found)]'>F</A>)</font> "
+6 -40
View File
@@ -297,52 +297,18 @@
// moved out of admins.dm because things other than admin procs were calling this.
/**
* Is this mob special to the gamemode?
*
* returns 1 for special characters and 2 for heroes of gamemode
*
*/
/// Returns TRUE if the game has started and we're either an AI with a 0th law, or we're someone with a special role/antag datum
/proc/is_special_character(mob/M)
if(!SSticker.HasRoundStarted())
return FALSE
if(!istype(M))
return FALSE
if(issilicon(M))
if(iscyborg(M)) //For cyborgs, returns 1 if the cyborg has a law 0 and special_role. Returns 0 if the borg is merely slaved to an AI traitor.
return FALSE
else if(isAI(M))
var/mob/living/silicon/ai/A = M
if(A.laws && A.laws.zeroth && A.mind && A.mind.special_role)
return TRUE
if(iscyborg(M)) //For cyborgs, returns 1 if the cyborg has a law 0 and special_role. Returns 0 if the borg is merely slaved to an AI traitor.
return FALSE
if(M.mind && M.mind.special_role)//If they have a mind and special role, they are some type of traitor or antagonist.
switch(SSticker.mode.config_tag)
if("revolution")
if(is_revolutionary(M))
return 2
if("cult")
if(M.mind in SSticker.mode.cult)
return 2
if("nuclear")
if(M.mind.has_antag_datum(/datum/antagonist/nukeop,TRUE))
return 2
if("changeling")
if(M.mind.has_antag_datum(/datum/antagonist/changeling,TRUE))
return 2
if("wizard")
if(iswizard(M))
return 2
if("apprentice")
if(M.mind in SSticker.mode.apprentices)
return 2
if("monkey")
if(isliving(M))
var/mob/living/L = M
if(L.diseases && (locate(/datum/disease/transformation/jungle_fever) in L.diseases))
return 2
return TRUE
if(M.mind && LAZYLEN(M.mind.antag_datums)) //they have an antag datum!
if(isAI(M))
var/mob/living/silicon/ai/A = M
return (A.laws?.zeroth && (A.mind?.special_role || !isnull(M.mind?.antag_datums)))
if(M.mind?.special_role || !isnull(M.mind?.antag_datums)) //they have an antag datum!
return TRUE
return FALSE