WOLOLO Cleanup v2

Moves the timer (and deconversion) to the mind datum instead of on the
staff.

Rewrites nullrod reskin list-building to instead rely on a variable set
on the subtype of nullrod to determine whether or not to include it by
default.
- By default, all nullrod subtypes EXCEPT fluff subtypes and the
missionary_staff subtype have this set to TRUE.
- Fluff subtypes still re-add themselves to the list as appropriate
through their fluff_transformations list entries, like they previously
did.
- This also allows future coders to potentially make new nullrod
variants that are not reskin options (such as for admin-only versions,
or special away mission reward versions) with better stats / effects by
simply setting "reskin_selectable = FALSE" in the subtype declaration
instead of manually removing the path from the list
This commit is contained in:
FalseIncarnate
2016-08-14 01:02:23 -04:00
parent 8d15e683a6
commit 03fafac9d9
2 changed files with 37 additions and 27 deletions
+23 -3
View File
@@ -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, "<span class='warning'>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.</span>")
to_chat(current, "<span class='warning'>This means you don't remember who you were working for or what you were doing.</span>")