[MIRROR] Devil refactor+small revamp (#887)
* Devil refactor+small revamp * Delete mind.dm.rej * clean up rej * Delete admin_investigate.dm.rej * Delete mapping.dm.rej * compile fix
This commit is contained in:
committed by
Poojawa
parent
59b8cfbc93
commit
c6a671a11b
@@ -420,7 +420,7 @@
|
||||
return
|
||||
|
||||
/datum/ai_laws/proc/clear_law_sixsixsix(force)
|
||||
if(force || !(owner && owner.mind.devilinfo))
|
||||
if(force || !is_devil(owner))
|
||||
devillaws = null
|
||||
|
||||
/datum/ai_laws/proc/associate(mob/living/silicon/M)
|
||||
|
||||
@@ -7,6 +7,7 @@
|
||||
|
||||
var/can_coexist_with_others = TRUE //Whether or not the person will be able to have more than one datum
|
||||
var/list/typecache_datum_blacklist = list() //List of datums this type can't coexist with
|
||||
var/delete_on_death = TRUE
|
||||
|
||||
/datum/antagonist/New(datum/mind/new_owner)
|
||||
typecache_datum_blacklist = typecacheof(typecache_datum_blacklist)
|
||||
@@ -59,4 +60,4 @@
|
||||
return
|
||||
|
||||
/datum/antagonist/proc/farewell()
|
||||
return
|
||||
return
|
||||
+20
-44
@@ -56,13 +56,12 @@
|
||||
var/antag_hud_icon_state = null //this mind's ANTAG_HUD should have this icon_state
|
||||
var/datum/atom_hud/antag/antag_hud = null //this mind's antag HUD
|
||||
var/datum/gang/gang_datum //Which gang this mind belongs to, if any
|
||||
var/datum/devilinfo/devilinfo //Information about the devil, if any.
|
||||
var/damnation_type = 0
|
||||
var/datum/mind/soulOwner //who owns the soul. Under normal circumstances, this will point to src
|
||||
var/hasSoul = TRUE // If false, renders the character unable to sell their soul.
|
||||
var/isholy = FALSE //is this person a chaplain or admin role allowed to use bibles
|
||||
|
||||
var/mob/living/enslaved_to //If this mind's master is another mob (i.e. adamantine golems)
|
||||
|
||||
var/datum/language_holder/language_holder
|
||||
|
||||
/datum/mind/New(var/key)
|
||||
@@ -73,7 +72,9 @@
|
||||
SSticker.minds -= src
|
||||
if(islist(antag_datums))
|
||||
for(var/i in antag_datums)
|
||||
qdel(i)
|
||||
var/datum/antagonist/antag_datum = i
|
||||
if(antag_datum.delete_on_death)
|
||||
qdel(i)
|
||||
antag_datums = null
|
||||
return ..()
|
||||
|
||||
@@ -324,7 +325,8 @@
|
||||
"nuclear",
|
||||
"traitor", // "traitorchan",
|
||||
"monkey",
|
||||
"clockcult"
|
||||
"clockcult",
|
||||
"devil"
|
||||
)
|
||||
var/text = ""
|
||||
|
||||
@@ -595,8 +597,9 @@
|
||||
if(SSticker.mode.config_tag == "devil")
|
||||
text = uppertext(text)
|
||||
text = "<i><b>[text]</b></i>: "
|
||||
if(src in SSticker.mode.devils)
|
||||
if(devilinfo && !devilinfo.ascendable)
|
||||
var/datum/antagonist/devil/devilinfo = has_antag_datum(ANTAG_DATUM_DEVIL)
|
||||
if(devilinfo)
|
||||
if(!devilinfo.ascendable)
|
||||
text += "<b>DEVIL</b>|<a href='?src=\ref[src];devil=ascendable_devil'>Ascendable Devil</a>|sintouched|<a href='?src=\ref[src];devil=clear'>human</a>"
|
||||
else
|
||||
text += "<a href='?src=\ref[src];devil=devil'>DEVIL</a>|<b>ASCENDABLE DEVIL</b>|sintouched|<a href='?src=\ref[src];devil=clear'>human</a>"
|
||||
@@ -1156,34 +1159,14 @@
|
||||
to_chat(usr, "<span class='notice'>The objectives for traitor [key] have been generated. You can edit them and anounce manually.</span>")
|
||||
|
||||
else if(href_list["devil"])
|
||||
var/datum/antagonist/devil/devilinfo = has_antag_datum(ANTAG_DATUM_DEVIL)
|
||||
switch(href_list["devil"])
|
||||
if("clear")
|
||||
if(src in SSticker.mode.devils)
|
||||
if(istype(current,/mob/living/carbon/true_devil/))
|
||||
if(devilinfo)
|
||||
devilinfo.regress_blood_lizard()
|
||||
else
|
||||
to_chat(usr, "<span class='warning'>Something went wrong with removing the devil, we were unable to find an attached devilinfo.</span>.")
|
||||
SSticker.mode.devils -= src
|
||||
special_role = null
|
||||
to_chat(current, "<span class='userdanger'>Your infernal link has been severed! You are no longer a devil!</span>")
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/infernal_jaunt)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/aimed/fireball/hellish)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/summon_contract)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/conjure_item/violin)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/greater)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/ascended)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/summon_dancefloor)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/sintouch)
|
||||
RemoveSpell(/obj/effect/proc_holder/spell/targeted/sintouch/ascended)
|
||||
remove_devil(current)
|
||||
message_admins("[key_name_admin(usr)] has de-devil'ed [current].")
|
||||
devilinfo = null
|
||||
if(issilicon(current))
|
||||
var/mob/living/silicon/S = current
|
||||
S.clear_law_sixsixsix(current)
|
||||
log_admin("[key_name(usr)] has de-devil'ed [current].")
|
||||
else if(src in SSticker.mode.sintouched)
|
||||
if(src in SSticker.mode.sintouched)
|
||||
SSticker.mode.sintouched -= src
|
||||
message_admins("[key_name_admin(usr)] has de-sintouch'ed [current].")
|
||||
log_admin("[key_name(usr)] has de-sintouch'ed [current].")
|
||||
@@ -1196,12 +1179,7 @@
|
||||
if(!ishuman(current) && !iscyborg(current))
|
||||
to_chat(usr, "<span class='warning'>This only works on humans and cyborgs!</span>")
|
||||
return
|
||||
SSticker.mode.devils += src
|
||||
special_role = "devil"
|
||||
SSticker.mode.finalize_devil(src, FALSE)
|
||||
SSticker.mode.add_devil_objectives(src, 2)
|
||||
announceDevilLaws()
|
||||
announce_objectives()
|
||||
add_devil(current, FALSE)
|
||||
message_admins("[key_name_admin(usr)] has devil'ed [current].")
|
||||
log_admin("[key_name(usr)] has devil'ed [current].")
|
||||
if("ascendable_devil")
|
||||
@@ -1213,12 +1191,7 @@
|
||||
if(!ishuman(current) && !iscyborg(current))
|
||||
to_chat(usr, "<span class='warning'>This only works on humans and cyborgs!</span>")
|
||||
return
|
||||
SSticker.mode.devils += src
|
||||
special_role = "devil"
|
||||
SSticker.mode.finalize_devil(src, TRUE)
|
||||
SSticker.mode.add_devil_objectives(src, 2)
|
||||
announceDevilLaws()
|
||||
announce_objectives()
|
||||
add_devil(current, TRUE)
|
||||
message_admins("[key_name_admin(usr)] has devil'ed [current]. The devil has been marked as ascendable.")
|
||||
log_admin("[key_name(usr)] has devil'ed [current]. The devil has been marked as ascendable.")
|
||||
if("sintouched")
|
||||
@@ -1448,8 +1421,8 @@
|
||||
if(!(src in SSticker.mode.cult))
|
||||
SSticker.mode.add_cultist(src,FALSE)
|
||||
special_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 the 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 compatriots 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>")
|
||||
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>")
|
||||
var/datum/antagonist/cult/C
|
||||
C.cult_memorization(src)
|
||||
var/mob/living/carbon/human/H = current
|
||||
@@ -1542,6 +1515,9 @@
|
||||
spell_list += S
|
||||
S.action.Grant(current)
|
||||
|
||||
/datum/mind/proc/owns_soul()
|
||||
return soulOwner == src
|
||||
|
||||
//To remove a specific spell from a mind
|
||||
/datum/mind/proc/RemoveSpell(obj/effect/proc_holder/spell/spell)
|
||||
if(!spell)
|
||||
@@ -1639,4 +1615,4 @@
|
||||
/mob/living/silicon/pai/mind_initialize()
|
||||
..()
|
||||
mind.assigned_role = "pAI"
|
||||
mind.special_role = ""
|
||||
mind.special_role = ""
|
||||
@@ -108,6 +108,15 @@
|
||||
if(soulowner)
|
||||
soulowner.death(gibbed)
|
||||
|
||||
/////////////////
|
||||
// Demon Bind //
|
||||
/////////////////
|
||||
//When the soulowner dies, the soulsharer dies, but NOT vice versa
|
||||
//This is intended for two players(or AI) and two mobs
|
||||
|
||||
/datum/soullink/oneway/ownerDies(gibbed, mob/living/owner)
|
||||
if(soulsharer)
|
||||
soulsharer.dust(FALSE)
|
||||
|
||||
|
||||
/////////////////
|
||||
|
||||
Reference in New Issue
Block a user