Fixes clockwork sigil candidate runtime, cleans up some jobban checks with defines (#5304)
This commit is contained in:
committed by
Poojawa
parent
03b33075e5
commit
9e229691cc
@@ -72,19 +72,18 @@ GLOBAL_LIST_EMPTY(antagonists)
|
||||
/datum/antagonist/proc/is_banned(mob/M)
|
||||
if(!M)
|
||||
return FALSE
|
||||
. = (jobban_isbanned(M,"Syndicate") || (job_rank && jobban_isbanned(M,job_rank)))
|
||||
. = (jobban_isbanned(M, ROLE_SYNDICATE) || (job_rank && jobban_isbanned(M,job_rank)))
|
||||
|
||||
/datum/antagonist/proc/replace_banned_player()
|
||||
set waitfor = FALSE
|
||||
|
||||
var/list/mob/dead/observer/candidates = pollCandidatesForMob("Do you want to play as a [name]?", "[name]", null, job_rank, 50, owner.current)
|
||||
var/mob/dead/observer/theghost = null
|
||||
if(candidates.len)
|
||||
theghost = pick(candidates)
|
||||
if(LAZYLEN(candidates))
|
||||
var/client/C = pick(candidates)
|
||||
to_chat(owner, "Your mob has been taken over by a ghost! Appeal your job ban if you want to avoid this in the future!")
|
||||
message_admins("[key_name_admin(theghost)] has taken control of ([key_name_admin(owner.current)]) to replace a jobbaned player.")
|
||||
message_admins("[key_name_admin(C)] has taken control of ([key_name_admin(owner.current)]) to replace a jobbaned player.")
|
||||
owner.current.ghostize(0)
|
||||
owner.current.key = theghost.key
|
||||
owner.current.key = C.key
|
||||
|
||||
/datum/antagonist/proc/on_removal()
|
||||
remove_innate_effects()
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
name = "Brother"
|
||||
antagpanel_category = "Brother"
|
||||
job_rank = ROLE_BROTHER
|
||||
var/special_role = "blood brother"
|
||||
var/special_role = ROLE_BROTHER
|
||||
var/datum/team/brother_team/team
|
||||
|
||||
/datum/antagonist/brother/create_team(datum/team/brother_team/new_team)
|
||||
|
||||
@@ -396,7 +396,7 @@
|
||||
var/datum/objective/assassinate/kill_objective = new
|
||||
kill_objective.owner = owner
|
||||
if(team_mode) //No backstabbing while in a team
|
||||
kill_objective.find_target_by_role(role = "Changeling", role_type = 1, invert = 1)
|
||||
kill_objective.find_target_by_role(role = ROLE_CHANGELING, role_type = 1, invert = 1)
|
||||
else
|
||||
kill_objective.find_target()
|
||||
objectives += kill_objective
|
||||
@@ -404,7 +404,7 @@
|
||||
var/datum/objective/maroon/maroon_objective = new
|
||||
maroon_objective.owner = owner
|
||||
if(team_mode)
|
||||
maroon_objective.find_target_by_role(role = "Changeling", role_type = 1, invert = 1)
|
||||
maroon_objective.find_target_by_role(role = ROLE_CHANGELING, role_type = 1, invert = 1)
|
||||
else
|
||||
maroon_objective.find_target()
|
||||
objectives += maroon_objective
|
||||
@@ -426,7 +426,7 @@
|
||||
var/datum/objective/escape/escape_with_identity/identity_theft = new
|
||||
identity_theft.owner = owner
|
||||
if(team_mode)
|
||||
identity_theft.find_target_by_role(role = "Changeling", role_type = 1, invert = 1)
|
||||
identity_theft.find_target_by_role(role = ROLE_CHANGELING, role_type = 1, invert = 1)
|
||||
else
|
||||
identity_theft.find_target()
|
||||
objectives += identity_theft
|
||||
|
||||
@@ -51,7 +51,7 @@
|
||||
var/mob/living/current = owner.current
|
||||
SSticker.mode.servants_of_ratvar += owner
|
||||
SSticker.mode.update_servant_icons_added(owner)
|
||||
owner.special_role = "Servant of Ratvar"
|
||||
owner.special_role = ROLE_SERVANT_OF_RATVAR
|
||||
owner.current.log_message("<font color=#BE8700>Has been converted to the cult of Ratvar!</font>", INDIVIDUAL_ATTACK_LOG)
|
||||
if(issilicon(current))
|
||||
if(iscyborg(current) && !silent)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
var/should_specialise = TRUE //do we split into AI and human, set to true on inital assignment only
|
||||
var/ai_datum = /datum/antagonist/traitor/AI
|
||||
var/human_datum = /datum/antagonist/traitor/human
|
||||
var/special_role = "traitor"
|
||||
var/special_role = ROLE_TRAITOR
|
||||
var/employer = "The Syndicate"
|
||||
var/give_objectives = TRUE
|
||||
var/should_give_codewords = TRUE
|
||||
|
||||
@@ -135,8 +135,8 @@
|
||||
adj = "objectiveless"
|
||||
else
|
||||
return
|
||||
new_owner.assigned_role = "Space Ninja"
|
||||
new_owner.special_role = "Space Ninja"
|
||||
new_owner.assigned_role = ROLE_NINJA
|
||||
new_owner.special_role = ROLE_NINJA
|
||||
new_owner.add_antag_datum(src)
|
||||
message_admins("[key_name_admin(admin)] has [adj] ninja'ed [new_owner.current].")
|
||||
log_admin("[key_name(admin)] has [adj] ninja'ed [new_owner.current].")
|
||||
|
||||
@@ -122,7 +122,7 @@
|
||||
nuke_team = new_team
|
||||
|
||||
/datum/antagonist/nukeop/admin_add(datum/mind/new_owner,mob/admin)
|
||||
new_owner.assigned_role = "Syndicate"
|
||||
new_owner.assigned_role = ROLE_SYNDICATE
|
||||
new_owner.add_antag_datum(src)
|
||||
message_admins("[key_name_admin(admin)] has nuke op'ed [new_owner.current].")
|
||||
log_admin("[key_name(admin)] has nuke op'ed [new_owner.current].")
|
||||
|
||||
@@ -184,7 +184,7 @@
|
||||
carbon_mob.flash_act(1, 1)
|
||||
rev_mind.current.Stun(100)
|
||||
rev_mind.add_antag_datum(/datum/antagonist/rev,rev_team)
|
||||
rev_mind.special_role = "Revolutionary"
|
||||
rev_mind.special_role = ROLE_REV
|
||||
return TRUE
|
||||
|
||||
/datum/antagonist/rev/head/proc/demote()
|
||||
|
||||
@@ -161,12 +161,12 @@
|
||||
/datum/antagonist/wizard/apply_innate_effects(mob/living/mob_override)
|
||||
var/mob/living/M = mob_override || owner.current
|
||||
update_wiz_icons_added(M, wiz_team ? TRUE : FALSE) //Don't bother showing the icon if you're solo wizard
|
||||
M.faction |= "wizard"
|
||||
M.faction |= ROLE_WIZARD
|
||||
|
||||
/datum/antagonist/wizard/remove_innate_effects(mob/living/mob_override)
|
||||
var/mob/living/M = mob_override || owner.current
|
||||
update_wiz_icons_removed(M)
|
||||
M.faction -= "wizard"
|
||||
M.faction -= ROLE_WIZARD
|
||||
|
||||
|
||||
/datum/antagonist/wizard/get_admin_commands()
|
||||
|
||||
+7
-7
@@ -693,20 +693,20 @@
|
||||
var/datum/antagonist/changeling/C = has_antag_datum(/datum/antagonist/changeling)
|
||||
if(!C)
|
||||
C = add_antag_datum(/datum/antagonist/changeling)
|
||||
special_role = "Changeling"
|
||||
special_role = ROLE_CHANGELING
|
||||
return C
|
||||
|
||||
/datum/mind/proc/make_Wizard()
|
||||
if(!has_antag_datum(/datum/antagonist/wizard))
|
||||
special_role = "Wizard"
|
||||
assigned_role = "Wizard"
|
||||
special_role = ROLE_WIZARD
|
||||
assigned_role = ROLE_WIZARD
|
||||
add_antag_datum(/datum/antagonist/wizard)
|
||||
|
||||
|
||||
/datum/mind/proc/make_Cultist()
|
||||
if(!has_antag_datum(/datum/antagonist/cult,TRUE))
|
||||
SSticker.mode.add_cultist(src,FALSE,equip=TRUE)
|
||||
special_role = "Cultist"
|
||||
special_role = ROLE_CULTIST
|
||||
to_chat(current, "<font color=\"purple\"><b><i>You catch a glimpse of the Realm of Nar-Sie, The Geometer of Blood. You now see how flimsy your world is, you see that it should be open to the knowledge of Nar-Sie.</b></i></font>")
|
||||
to_chat(current, "<font color=\"purple\"><b><i>Assist your new bretheren in their dark dealings. Their goal is yours, and yours is theirs. You serve the Dark One above all else. Bring It back.</b></i></font>")
|
||||
|
||||
@@ -715,7 +715,7 @@
|
||||
head.give_flash = TRUE
|
||||
head.give_hud = TRUE
|
||||
add_antag_datum(head)
|
||||
special_role = "Head Revolutionary"
|
||||
special_role = ROLE_REV_HEAD
|
||||
|
||||
/datum/mind/proc/AddSpell(obj/effect/proc_holder/spell/S)
|
||||
spell_list += S
|
||||
@@ -816,7 +816,7 @@
|
||||
//XENO
|
||||
/mob/living/carbon/alien/mind_initialize()
|
||||
..()
|
||||
mind.special_role = "Alien"
|
||||
mind.special_role = ROLE_ALIEN
|
||||
|
||||
//AI
|
||||
/mob/living/silicon/ai/mind_initialize()
|
||||
@@ -831,5 +831,5 @@
|
||||
//PAI
|
||||
/mob/living/silicon/pai/mind_initialize()
|
||||
..()
|
||||
mind.assigned_role = "pAI"
|
||||
mind.assigned_role = ROLE_PAI
|
||||
mind.special_role = ""
|
||||
|
||||
Reference in New Issue
Block a user