diff --git a/code/datums/mind.dm b/code/datums/mind.dm
index a3c60066ef9..04eedf6a1bc 100644
--- a/code/datums/mind.dm
+++ b/code/datums/mind.dm
@@ -1530,7 +1530,7 @@
if(G)
G.reenter_corpse()
-/datum/mind/proc/make_zealot(mob/living/carbon/human/missionary)
+/datum/mind/proc/make_zealot(mob/living/carbon/human/missionary, convert_duration = 6000, team_color = "red")
if(!missionary || !istype(missionary)) //better provide a proper missionary or the rest of this is gonna break
return 0
@@ -1566,13 +1566,33 @@
slaved.serv += current
slaved.add_serv_hud(missionary.mind, "master") //handles master servent icons
slaved.add_serv_hud(src, "mindslave")
+
+ var/obj/item/clothing/under/jumpsuit = null
+ if(ishuman(current)) //only bother with the jumpsuit stuff if we are a human type, since we won't have the slot otherwise
+ var/mob/living/carbon/human/H = current
+ if(H.w_uniform)
+ jumpsuit = H.w_uniform
+ jumpsuit.color = team_color
+ H.update_inv_w_uniform(0,0)
+
+ log_admin("[ckey(missionary.key)] has converted [ckey(current.key)] as a zealot.")
+ addtimer(src, "remove_zealot", convert_duration, FALSE, jumpsuit) //deconverts after the timer expires
+
return 1
-/datum/mind/proc/remove_zealot()
+/datum/mind/proc/remove_zealot(obj/item/clothing/under/jumpsuit = null)
if(!zealot_master) //if they aren't a zealot, we can't remove their zealot status, obviously. don't bother with the rest so we don't confuse them with the messages
return
- zealot_master = null
ticker.mode.remove_traitor_mind(src)
+ log_admin("[ckey(current.key)] has deconverted and is no longer a zealot of [ckey(zealot_master.key)].")
+ zealot_master = null
+
+ if(jumpsuit)
+ jumpsuit.color = initial(jumpsuit.color) //reset the jumpsuit no matter where our mind is
+ if(ishuman(current)) //but only try updating us if we are still a human type since it is a human proc
+ var/mob/living/carbon/human/H = current
+ H.update_inv_w_uniform(0,0)
+
to_chat(current, "You seem to have forgotten the events of the past 10 minutes or so, and your head aches a bit as if someone beat it savagely with a stick.")
to_chat(current, "This means you don't remember who you were working for or what you were doing.")
diff --git a/code/game/objects/items/weapons/holy_weapons.dm b/code/game/objects/items/weapons/holy_weapons.dm
index 68c7727dc2b..f93e4b67eca 100644
--- a/code/game/objects/items/weapons/holy_weapons.dm
+++ b/code/game/objects/items/weapons/holy_weapons.dm
@@ -9,6 +9,7 @@
throwforce = 10
w_class = 1
var/reskinned = FALSE
+ var/reskin_selectable = TRUE //set to FALSE if a subtype is meant to not normally be available as a reskin option (fluff ones will get re-added through their list)
var/list/fluff_transformations = list() //does it have any special transformations only accessible to it? Should only be subtypes of /obj/item/weapon/nullrod
/obj/item/weapon/nullrod/suicide_act(mob/user)
@@ -31,7 +32,11 @@
reskin_holy_weapon(user)
/obj/item/weapon/nullrod/proc/reskin_holy_weapon(mob/M)
- var/list/holy_weapons_list = typesof(/obj/item/weapon/nullrod) - typesof(/obj/item/weapon/nullrod/fluff)
+ var/list/holy_weapons_list = typesof(/obj/item/weapon/nullrod)
+ for(var/entry in holy_weapons_list)
+ var/obj/item/weapon/nullrod/variant = entry
+ if(initial(variant.reskin_selectable) == FALSE)
+ holy_weapons_list -= variant
if(fluff_transformations.len)
for(var/thing in fluff_transformations)
holy_weapons_list += thing
@@ -57,6 +62,9 @@
M.put_in_active_hand(holy_weapon)
qdel(src)
+/obj/item/weapon/nullrod/fluff //fluff subtype to be used for all donator nullrods
+ reskin_selectable = FALSE
+
/obj/item/weapon/nullrod/godhand
name = "god hand"
icon_state = "disintegrate"
@@ -446,12 +454,13 @@
to_chat(M, "Being in the presence of [holder]'s [src] is interfering with your powers!")
/obj/item/weapon/nullrod/missionary_staff
- reskinned = TRUE
- icon_state = "godstaff-red"
- item_state = "godstaff-red"
name = "holy staff"
desc = "It has a mysterious, protective aura."
description_antag = "This seemingly standard holy staff is actually a disguised neurotransmitter capable of inducing blind zealotry in its victims. It must be allowed to recharge in the presence of a linked set of missionary robes. Activate the staff while wearing robes to link, then aim the staff at your victim to try and convert them."
+ reskinned = TRUE
+ reskin_selectable = FALSE
+ icon_state = "godstaff-red"
+ item_state = "godstaff-red"
w_class = 5
force = 5
slot_flags = SLOT_BACK
@@ -558,27 +567,8 @@
to_chat(missionary, "You successfully convert [target] to your cause. The following grows because of your faith!")
faith -= 100
//if you made it this far: congratulations! you are now a religious zealot!
- target.mind.make_zealot(missionary)
+ target.mind.make_zealot(missionary, convert_duration, team_color)
target << sound('sound/misc/wololo.ogg', 0, 1, 25)
missionary.say("WOLOLO!")
missionary << sound('sound/misc/wololo.ogg', 0, 1, 25)
-
- var/obj/item/clothing/under/jumpsuit = null
-
- if(target.w_uniform)
- jumpsuit = target.w_uniform
- jumpsuit.color = team_color
- target.update_inv_w_uniform(0,0)
-
- log_admin("[ckey(missionary.key)] has converted [ckey(target.key)] as a zealot.")
- addtimer(src, "do_deconvert", convert_duration, FALSE, target, missionary, jumpsuit) //deconverts after the timer expires
-
-/obj/item/weapon/nullrod/missionary_staff/proc/do_deconvert(mob/living/carbon/human/target, mob/living/carbon/human/missionary, obj/item/clothing/under/jumpsuit)
- if(!target || !istype(target)) //if we didn't supply a target (or a non-human target), stop here
- return 0
- if(jumpsuit)
- jumpsuit.color = initial(jumpsuit.color)
- target.update_inv_w_uniform(0,0)
- target.mind.remove_zealot()
- log_admin("[ckey(target.key)] has deconverted and is no longer a zealot of [ckey(missionary.key)].")
\ No newline at end of file