fixes some quirk stuff

This commit is contained in:
Putnam
2020-02-01 00:32:08 -08:00
parent 3d9e84a3f8
commit 847e6382c0
3 changed files with 10 additions and 10 deletions
@@ -35,7 +35,7 @@ PROCESSING_SUBSYSTEM_DEF(quirks)
var/list/my_quirks = cli.prefs.all_quirks.Copy()
var/list/cut
if(job?.blacklisted_quirks)
cut = filter_quirks(my_quirks, job)
cut = filter_quirks(my_quirks, job.blacklisted_quirks)
for(var/V in my_quirks)
var/datum/quirk/Q = quirks[V]
if(Q)
@@ -63,11 +63,11 @@ PROCESSING_SUBSYSTEM_DEF(quirks)
for(var/i in quirk_names)
. += quirk_points_by_name(i)
/datum/controller/subsystem/processing/quirks/proc/filter_quirks(list/our_quirks, datum/job/job)
/datum/controller/subsystem/processing/quirks/proc/filter_quirks(list/our_quirks, list/blacklisted_quirks)
var/list/cut = list()
var/list/banned_names = list()
var/pointscut = 0
for(var/i in job.blacklisted_quirks)
for(var/i in blacklisted_quirks)
var/name = quirk_name_by_path(i)
if(name)
banned_names += name
@@ -20,7 +20,7 @@ GLOBAL_LIST_EMPTY(antagonists)
var/show_in_antagpanel = TRUE //This will hide adding this antag type in antag panel, use only for internal subtypes that shouldn't be added directly but still show if possessed by mind
var/antagpanel_category = "Uncategorized" //Antagpanel will display these together, REQUIRED
var/show_name_in_check_antagonists = FALSE //Will append antagonist name in admin listings - use for categories that share more than one antag type
var/list/blacklisted_quirks = list("Pacifist","Mute") // Quirks that will be removed upon gaining this antag. Pacifist and mute are default.
var/list/blacklisted_quirks = list(/datum/quirk/nonviolent,/datum/quirk/mute) // Quirks that will be removed upon gaining this antag. Pacifist and mute are default.
/datum/antagonist/New()
GLOB.antagonists += src
@@ -122,12 +122,12 @@ GLOBAL_LIST_EMPTY(antagonists)
/datum/antagonist/proc/remove_blacklisted_quirks()
var/mob/living/L = owner
if(istype(L))
for(var/q in L.roundstart_quirks)
var/list/cut = list()
cut = SSquirks.filter_quirks(L.roundstart_quirks,blacklisted_quirks)
for(var/q in cut)
var/datum/quirk/Q = q
if(Q.name in blacklisted_quirks)
if(Q.antag_removal_text)
to_chat(L, "<span class='boldannounce'>[Q.antag_removal_text]</span>")
L.remove_quirk(Q.type)
if(Q.antag_removal_text)
to_chat(L, "<span class='boldannounce'>[Q.antag_removal_text]</span>")
//Returns the team antagonist belongs to if any.
/datum/antagonist/proc/get_team()
@@ -2,7 +2,7 @@
name = "Survivalist"
show_in_antagpanel = FALSE
show_name_in_check_antagonists = TRUE
blacklisted_quirks = list("Pacifist") // mutes are allowed
blacklisted_quirks = list(/datum/quirk/nonviolent) // mutes are allowed
var/greet_message = ""
/datum/antagonist/survivalist/proc/forge_objectives()