Merge pull request #4608 from Fox-McCloud/remove-mindslave

Can Deconvert Mindslaves and Vampire Thralls
This commit is contained in:
TheDZD
2016-06-11 12:11:34 -04:00
committed by GitHub
7 changed files with 30 additions and 12 deletions
+1
View File
@@ -247,6 +247,7 @@ var/list/potential_theft_objectives=subtypesof(/datum/theft_objective) \
return 1
return 0
/datum/objective/protect/mindslave //subytpe for mindslave implants
/datum/objective/hijack
martyr_compatible = 0 //Technically you won't get both anyway.
+3 -2
View File
@@ -366,10 +366,11 @@
traitor_mind.special_role = null
traitor_mind.som = null
slaved.leave_serv_hud(traitor_mind)
for(var/datum/objective/protect/mindslave/MS in traitor_mind.objectives)
traitor_mind.objectives -= MS
update_traitor_icons_removed(traitor_mind)
// to_chat(world, "Removed [traitor_mind.current.name] from traitor shit")
to_chat(traitor_mind.current, "\red <FONT size = 3><B>The fog clouding your mind clears. You remember nothing from the moment you were implanted until now.(You don't remember who implanted you)</B></FONT>")
to_chat(traitor_mind.current, "<span class='userdanger'>You are no longer a mindslave; you have complete and free control of your own faculties, once more!</span>")
/datum/game_mode/proc/assign_exchange_role(var/datum/mind/owner)
//set faction
+1 -2
View File
@@ -351,8 +351,7 @@ You are weak to holy things and starlight. Don't go into space and avoid the Cha
vampire_mind.som = null
slaved.leave_serv_hud(vampire_mind)
update_vampire_icons_removed(vampire_mind)
// to_chat(world, "Removed [vampire_mind.current.name] from vampire shit")
to_chat(vampire_mind.current, "\red <FONT size = 3><B>The fog clouding your mind clears. You remember nothing from the moment you were enthralled until now.</B></FONT>")
vampire_mind.current.visible_message("<span class='userdanger'>[vampire_mind.current] looks as though a burden has been lifted!</span>", "<span class='userdanger'>The dark fog in your mind clears as you regain control of your own faculties, you are no longer a vampire thrall!</span>")
if(vampire_mind.current.hud_used)
vampire_mind.current.hud_used.remove_vampire_hud()
@@ -267,6 +267,10 @@
W.destroy()
playsound(usr.loc, 'sound/effects/creepyshriek.ogg', 100, 1)
/proc/isvampirethrall(mob/living/M as mob)
return istype(M) && M.mind && ticker && ticker.mode && (M.mind in ticker.mode.vampire_enthralled)
/obj/effect/proc_holder/spell/vampire/targetted/enthrall
name = "Enthrall (300)"
desc = "You use a large portion of your power to sway those loyal to none to be loyal to you only."
@@ -56,11 +56,11 @@
ticker.mode.traitors += H.mind
H.mind.special_role = "traitor"
to_chat(H, "<span class='warning'><B>You're now completely loyal to [user.name]!</B> You now must lay down your life to protect them and assist in their goals at any cost.</span>")
var/datum/objective/protect/p = new
p.owner = H.mind
p.target = user:mind
p.explanation_text = "Obey every order from and protect [user:real_name], the [user:mind:assigned_role=="MODE" ? (user:mind:special_role) : (user:mind:assigned_role)]."
H.mind.objectives += p
var/datum/objective/protect/mindslave/MS = new
MS.owner = H.mind
MS.target = user:mind
MS.explanation_text = "Obey every order from and protect [user:real_name], the [user:mind:assigned_role=="MODE" ? (user:mind:special_role) : (user:mind:assigned_role)]."
H.mind.objectives += MS
for(var/datum/objective/objective in H.mind.objectives)
to_chat(H, "<B>Objective #1</B>: [objective.explanation_text]")
@@ -71,10 +71,16 @@
var/datum/mindslaves/slaved = user.mind.som
H.mind.som = slaved
slaved.serv += H
slaved.add_serv_hud(user.mind,"syndicate")//handles master servent icons
slaved.add_serv_hud(H.mind,"mindslave")
slaved.add_serv_hud(user.mind, "master") //handles master servent icons
slaved.add_serv_hud(H.mind, "mindslave")
log_admin("[ckey(user.key)] has mind-slaved [ckey(H.key)].")
activated = 1
return 1
return 0
return 0
/obj/item/weapon/implant/traitor/removed(mob/target)
if(..())
ticker.mode.remove_traitor_mind(target.mind)
return 1
return 0
@@ -297,6 +297,13 @@
if(data >= 75 && prob(33)) // 30 units, 150 seconds
if (!M.confused) M.confused = 1
M.confused += 3
if(isvampirethrall(M))
ticker.mode.remove_vampire_mind(M.mind)
holder.remove_reagent(src.id, src.volume)
M.jitteriness = 0
M.stuttering = 0
M.confused = 0
return
if(iscultist(M))
ticker.mode.remove_cultist(M.mind)
holder.remove_reagent(src.id, src.volume) // maybe this is a little too perfect and a max() cap on the statuses would be better??