[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:
CitadelStationBot
2017-05-18 09:06:01 -05:00
committed by Poojawa
parent 59b8cfbc93
commit c6a671a11b
30 changed files with 551 additions and 292 deletions

View File

@@ -1,4 +1,5 @@
#define ANTAG_DATUM_CULT /datum/antagonist/cult #define ANTAG_DATUM_CULT /datum/antagonist/cult
#define ANTAG_DATUM_CULT_MASTER /datum/antagonist/cult/master #define ANTAG_DATUM_CULT_MASTER /datum/antagonist/cult/master
#define ANTAG_DATUM_CLOCKCULT /datum/antagonist/clockcult #define ANTAG_DATUM_CLOCKCULT /datum/antagonist/clockcult
#define ANTAG_DATUM_CLOCKCULT_SILENT /datum/antagonist/clockcult/silent #define ANTAG_DATUM_CLOCKCULT_SILENT /datum/antagonist/clockcult/silent
#define ANTAG_DATUM_DEVIL /datum/antagonist/devil

View File

@@ -3,6 +3,7 @@
#define CONTRACT_PRESTIGE "prestige" #define CONTRACT_PRESTIGE "prestige"
#define CONTRACT_MAGIC "magic" #define CONTRACT_MAGIC "magic"
#define CONTRACT_REVIVE "revive" #define CONTRACT_REVIVE "revive"
#define CONTRACT_FRIEND "friend"
#define CONTRACT_KNOWLEDGE "knowledge" #define CONTRACT_KNOWLEDGE "knowledge"
#define CONTRACT_UNWILLING "unwilling" #define CONTRACT_UNWILLING "unwilling"

View File

@@ -420,7 +420,7 @@
return return
/datum/ai_laws/proc/clear_law_sixsixsix(force) /datum/ai_laws/proc/clear_law_sixsixsix(force)
if(force || !(owner && owner.mind.devilinfo)) if(force || !is_devil(owner))
devillaws = null devillaws = null
/datum/ai_laws/proc/associate(mob/living/silicon/M) /datum/ai_laws/proc/associate(mob/living/silicon/M)

View File

@@ -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/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/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) /datum/antagonist/New(datum/mind/new_owner)
typecache_datum_blacklist = typecacheof(typecache_datum_blacklist) typecache_datum_blacklist = typecacheof(typecache_datum_blacklist)
@@ -59,4 +60,4 @@
return return
/datum/antagonist/proc/farewell() /datum/antagonist/proc/farewell()
return return

View File

@@ -56,13 +56,12 @@
var/antag_hud_icon_state = null //this mind's ANTAG_HUD should have this icon_state 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/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/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/damnation_type = 0
var/datum/mind/soulOwner //who owns the soul. Under normal circumstances, this will point to src 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/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/mob/living/enslaved_to //If this mind's master is another mob (i.e. adamantine golems)
var/datum/language_holder/language_holder var/datum/language_holder/language_holder
/datum/mind/New(var/key) /datum/mind/New(var/key)
@@ -73,7 +72,9 @@
SSticker.minds -= src SSticker.minds -= src
if(islist(antag_datums)) if(islist(antag_datums))
for(var/i in 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 antag_datums = null
return ..() return ..()
@@ -324,7 +325,8 @@
"nuclear", "nuclear",
"traitor", // "traitorchan", "traitor", // "traitorchan",
"monkey", "monkey",
"clockcult" "clockcult",
"devil"
) )
var/text = "" var/text = ""
@@ -595,8 +597,9 @@
if(SSticker.mode.config_tag == "devil") if(SSticker.mode.config_tag == "devil")
text = uppertext(text) text = uppertext(text)
text = "<i><b>[text]</b></i>: " text = "<i><b>[text]</b></i>: "
if(src in SSticker.mode.devils) var/datum/antagonist/devil/devilinfo = has_antag_datum(ANTAG_DATUM_DEVIL)
if(devilinfo && !devilinfo.ascendable) 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>" 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 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>" 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>") 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"]) else if(href_list["devil"])
var/datum/antagonist/devil/devilinfo = has_antag_datum(ANTAG_DATUM_DEVIL)
switch(href_list["devil"]) switch(href_list["devil"])
if("clear") if("clear")
if(src in SSticker.mode.devils) if(src in SSticker.mode.devils)
if(istype(current,/mob/living/carbon/true_devil/)) remove_devil(current)
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)
message_admins("[key_name_admin(usr)] has de-devil'ed [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].") 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 SSticker.mode.sintouched -= src
message_admins("[key_name_admin(usr)] has de-sintouch'ed [current].") message_admins("[key_name_admin(usr)] has de-sintouch'ed [current].")
log_admin("[key_name(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)) if(!ishuman(current) && !iscyborg(current))
to_chat(usr, "<span class='warning'>This only works on humans and cyborgs!</span>") to_chat(usr, "<span class='warning'>This only works on humans and cyborgs!</span>")
return return
SSticker.mode.devils += src add_devil(current, FALSE)
special_role = "devil"
SSticker.mode.finalize_devil(src, FALSE)
SSticker.mode.add_devil_objectives(src, 2)
announceDevilLaws()
announce_objectives()
message_admins("[key_name_admin(usr)] has devil'ed [current].") message_admins("[key_name_admin(usr)] has devil'ed [current].")
log_admin("[key_name(usr)] has devil'ed [current].") log_admin("[key_name(usr)] has devil'ed [current].")
if("ascendable_devil") if("ascendable_devil")
@@ -1213,12 +1191,7 @@
if(!ishuman(current) && !iscyborg(current)) if(!ishuman(current) && !iscyborg(current))
to_chat(usr, "<span class='warning'>This only works on humans and cyborgs!</span>") to_chat(usr, "<span class='warning'>This only works on humans and cyborgs!</span>")
return return
SSticker.mode.devils += src add_devil(current, TRUE)
special_role = "devil"
SSticker.mode.finalize_devil(src, TRUE)
SSticker.mode.add_devil_objectives(src, 2)
announceDevilLaws()
announce_objectives()
message_admins("[key_name_admin(usr)] has devil'ed [current]. The devil has been marked as ascendable.") 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.") log_admin("[key_name(usr)] has devil'ed [current]. The devil has been marked as ascendable.")
if("sintouched") if("sintouched")
@@ -1448,8 +1421,8 @@
if(!(src in SSticker.mode.cult)) if(!(src in SSticker.mode.cult))
SSticker.mode.add_cultist(src,FALSE) SSticker.mode.add_cultist(src,FALSE)
special_role = "Cultist" 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>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 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>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 var/datum/antagonist/cult/C
C.cult_memorization(src) C.cult_memorization(src)
var/mob/living/carbon/human/H = current var/mob/living/carbon/human/H = current
@@ -1542,6 +1515,9 @@
spell_list += S spell_list += S
S.action.Grant(current) S.action.Grant(current)
/datum/mind/proc/owns_soul()
return soulOwner == src
//To remove a specific spell from a mind //To remove a specific spell from a mind
/datum/mind/proc/RemoveSpell(obj/effect/proc_holder/spell/spell) /datum/mind/proc/RemoveSpell(obj/effect/proc_holder/spell/spell)
if(!spell) if(!spell)
@@ -1639,4 +1615,4 @@
/mob/living/silicon/pai/mind_initialize() /mob/living/silicon/pai/mind_initialize()
..() ..()
mind.assigned_role = "pAI" mind.assigned_role = "pAI"
mind.special_role = "" mind.special_role = ""

View File

@@ -108,6 +108,15 @@
if(soulowner) if(soulowner)
soulowner.death(gibbed) 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)
///////////////// /////////////////

View File

@@ -75,7 +75,7 @@ Credit where due:
/proc/remove_servant_of_ratvar(mob/living/L, silent = FALSE) /proc/remove_servant_of_ratvar(mob/living/L, silent = FALSE)
if(!L || !L.mind) if(!L || !L.mind)
return return
var/datum/antagonist/clockcult/clock_datum = L.mind.has_antag_datum(/datum/antagonist/clockcult) var/datum/antagonist/clockcult/clock_datum = L.mind.has_antag_datum(ANTAG_DATUM_CLOCKCULT)
if(!clock_datum) if(!clock_datum)
return FALSE return FALSE
clock_datum.silent = silent clock_datum.silent = silent

View File

@@ -1,5 +1,6 @@
/mob/living/proc/check_devil_bane_multiplier(obj/item/weapon, mob/living/attacker) /mob/living/proc/check_devil_bane_multiplier(obj/item/weapon, mob/living/attacker)
switch(mind.devilinfo.bane) var/datum/antagonist/devil/devilInfo = mind.has_antag_datum(ANTAG_DATUM_DEVIL)
switch(devilInfo.bane)
if(BANE_WHITECLOTHES) if(BANE_WHITECLOTHES)
if(ishuman(attacker)) if(ishuman(attacker))
var/mob/living/carbon/human/H = attacker var/mob/living/carbon/human/H = attacker
@@ -21,13 +22,13 @@
/obj/item/clothing/under/suit_jacket/white = 0.5, /obj/item/clothing/under/suit_jacket/white = 0.5,
/obj/item/clothing/under/burial = 1 /obj/item/clothing/under/burial = 1
) )
if(whiteness[U.type]) if(U && whiteness[U.type])
src.visible_message("<span class='warning'>[src] seems to have been harmed by the purity of [attacker]'s clothes.</span>", "<span class='notice'>Unsullied white clothing is disrupting your form.</span>") src.visible_message("<span class='warning'>[src] seems to have been harmed by the purity of [attacker]'s clothes.</span>", "<span class='notice'>Unsullied white clothing is disrupting your form.</span>")
return whiteness[U.type] + 1 return whiteness[U.type] + 1
if(BANE_TOOLBOX) if(BANE_TOOLBOX)
if(istype(weapon,/obj/item/weapon/storage/toolbox)) if(istype(weapon,/obj/item/weapon/storage/toolbox))
src.visible_message("<span class='warning'>The [weapon] seems unusually robust this time.</span>", "<span class='notice'>The [weapon] is your unmaking!</span>") src.visible_message("<span class='warning'>The [weapon] seems unusually robust this time.</span>", "<span class='notice'>The [weapon] is your unmaking!</span>")
return 2.5 // Will take four hits with a normal toolbox. return 2.5 // Will take four hits with a normal toolbox to crit.
if(BANE_HARVEST) if(BANE_HARVEST)
if(istype(weapon,/obj/item/weapon/reagent_containers/food/snacks/grown/)) if(istype(weapon,/obj/item/weapon/reagent_containers/food/snacks/grown/))
src.visible_message("<span class='warning'>The spirits of the harvest aid in the exorcism.</span>", "<span class='notice'>The harvest spirits are harming you.</span>") src.visible_message("<span class='warning'>The spirits of the harvest aid in the exorcism.</span>", "<span class='notice'>The harvest spirits are harming you.</span>")

View File

@@ -19,7 +19,6 @@
+ <span class='notice'>Crew</span>: Resist the lure of sin and remain pure!" + <span class='notice'>Crew</span>: Resist the lure of sin and remain pure!"
/datum/game_mode/devil/pre_setup() /datum/game_mode/devil/pre_setup()
if(config.protect_roles_from_antagonist) if(config.protect_roles_from_antagonist)
restricted_jobs += protected_jobs restricted_jobs += protected_jobs
if(config.protect_assistant_from_antagonist) if(config.protect_assistant_from_antagonist)
@@ -56,10 +55,22 @@
return 1 return 1
/datum/game_mode/devil/proc/post_setup_finalize(datum/mind/devil) /datum/game_mode/devil/proc/post_setup_finalize(datum/mind/devil)
set waitfor = FALSE add_devil(devil.current, ascendable = TRUE) //Devil gamemode devils are ascendable.
sleep(rand(10,100)) add_devil_objectives(devil,2)
finalize_devil(devil, TRUE)
sleep(100) /proc/is_devil(mob/living/M)
add_devil_objectives(devil, objective_count) //This has to be in a separate loop, as we need devil names to be generated before we give objectives in devil agent. return M && M.mind && M.mind.has_antag_datum(ANTAG_DATUM_DEVIL)
devil.announceDevilLaws()
devil.announce_objectives() /proc/add_devil(mob/living/L, ascendable = FALSE)
if(!L || !L.mind)
return FALSE
var/datum/antagonist/devil/devil_datum = L.mind.add_antag_datum(ANTAG_DATUM_DEVIL)
devil_datum.ascendable = ascendable
return devil_datum
/proc/remove_devil(mob/living/L)
if(!L || !L.mind)
return FALSE
var/datum/antagonist/devil_datum = L.mind.has_antag_datum(ANTAG_DATUM_DEVIL)
devil_datum.on_removal()
return TRUE

View File

@@ -78,8 +78,15 @@ GLOBAL_LIST_INIT(lawlorify, list (
BANISH_FUNERAL_GARB = "If your corpse is clad in funeral garments, you will be unable to resurrect." BANISH_FUNERAL_GARB = "If your corpse is clad in funeral garments, you will be unable to resurrect."
) )
)) ))
/datum/devilinfo
var/datum/mind/owner = null //These are also used in the codex gigas, so let's declare them globally.
GLOBAL_LIST_INIT(devil_pre_title, list("Dark ", "Hellish ", "Fallen ", "Fiery ", "Sinful ", "Blood ", "Fluffy "))
GLOBAL_LIST_INIT(devil_title, list("Lord ", "Prelate ", "Count ", "Viscount ", "Vizier ", "Elder ", "Adept "))
GLOBAL_LIST_INIT(devil_syllable, list("hal", "ve", "odr", "neit", "ci", "quon", "mya", "folth", "wren", "geyr", "hil", "niet", "twou", "phi", "coa"))
GLOBAL_LIST_INIT(devil_suffix, list(" the Red", " the Soulless", " the Master", ", the Lord of all things", ", Jr."))
/datum/antagonist/devil
//Don't delete upon mind destruction, otherwise soul re-selling will break.
delete_on_death = FALSE
var/obligation var/obligation
var/ban var/ban
var/bane var/bane
@@ -89,55 +96,63 @@ GLOBAL_LIST_INIT(lawlorify, list (
var/reviveNumber = 0 var/reviveNumber = 0
var/form = BASIC_DEVIL var/form = BASIC_DEVIL
var/exists = 0 var/exists = 0
var/static/list/dont_remove_spells = list( var/static/list/removable_devil_spells = list(
/obj/effect/proc_holder/spell/targeted/summon_contract, /obj/effect/proc_holder/spell/aimed/fireball/hellish,
/obj/effect/proc_holder/spell/targeted/conjure_item/violin, /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork,
/obj/effect/proc_holder/spell/targeted/summon_dancefloor) /obj/effect/proc_holder/spell/aimed/fireball/hellish,
/obj/effect/proc_holder/spell/targeted/infernal_jaunt,
/obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/greater,
/obj/effect/proc_holder/spell/targeted/sintouch,
/obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/ascended,
/obj/effect/proc_holder/spell/targeted/sintouch/ascended)
var/static/list/devil_spells = list(
/obj/effect/proc_holder/spell/aimed/fireball/hellish,
/obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork,
/obj/effect/proc_holder/spell/aimed/fireball/hellish,
/obj/effect/proc_holder/spell/targeted/infernal_jaunt,
/obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/greater,
/obj/effect/proc_holder/spell/targeted/sintouch,
/obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/ascended,
/obj/effect/proc_holder/spell/targeted/sintouch/ascended,
/obj/effect/proc_holder/spell/targeted/summon_contract,
/obj/effect/proc_holder/spell/targeted/conjure_item/violin,
/obj/effect/proc_holder/spell/targeted/summon_dancefloor)
var/ascendable = FALSE var/ascendable = FALSE
/datum/devilinfo/New() /datum/antagonist/devil/New()
..() ..()
dont_remove_spells = typecacheof(dont_remove_spells) devil_spells = typecacheof(devil_spells)
truename = randomDevilName()
ban = randomdevilban()
bane = randomdevilbane()
obligation = randomdevilobligation()
banish = randomdevilbanish()
GLOB.allDevils[lowertext(truename)] = src
/proc/randomDevilInfo(name = randomDevilName()) /proc/devilInfo(name)
var/datum/devilinfo/devil = new
devil.truename = name
devil.bane = randomdevilbane()
devil.obligation = randomdevilobligation()
devil.ban = randomdevilban()
devil.banish = randomdevilbanish()
return devil
/proc/devilInfo(name, saveDetails = 0)
if(GLOB.allDevils[lowertext(name)]) if(GLOB.allDevils[lowertext(name)])
return GLOB.allDevils[lowertext(name)] return GLOB.allDevils[lowertext(name)]
else else
var/datum/devilinfo/devil = randomDevilInfo(name) var/datum/fakeDevil/devil = new /datum/fakeDevil(name)
GLOB.allDevils[lowertext(name)] = devil GLOB.allDevils[lowertext(name)] = devil
devil.exists = saveDetails
return devil return devil
/proc/randomDevilName() /proc/randomDevilName()
var/preTitle = "" var/name = ""
var/title = ""
var/mainName = ""
var/suffix = ""
if(prob(65)) if(prob(65))
if(prob(35)) if(prob(35))
preTitle = pick("Dark ", "Hellish ", "Fiery ", "Sinful ", "Blood ") name = pick(GLOB.devil_pre_title)
title = pick("Lord ", "Fallen Prelate ", "Count ", "Viscount ", "Vizier ", "Elder ", "Adept ") name += pick(GLOB.devil_title)
var/probability = 100 var/probability = 100
mainName = pick("Hal", "Ve", "Odr", "Neit", "Ci", "Quon", "Mya", "Folth", "Wren", "Gyer", "Geyr", "Hil", "Niet", "Twou", "Hu", "Don") name += pick(GLOB.devil_syllable)
while(prob(probability)) while(prob(probability))
mainName += pick("hal", "ve", "odr", "neit", "ca", "quon", "mya", "folth", "wren", "gyer", "geyr", "hil", "niet", "twoe", "phi", "coa") name += pick(GLOB.devil_syllable)
probability -= 20 probability -= 20
if(prob(40)) if(prob(40))
suffix = pick(" the Red", " the Soulless", " the Master", ", the Lord of all things", ", Jr.") name += pick(GLOB.devil_suffix)
return preTitle + title + mainName + suffix return name
/proc/randomdevilobligation() /proc/randomdevilobligation()
return pick(OBLIGATION_FOOD, OBLIGATION_FIDDLE, OBLIGATION_DANCEOFF, OBLIGATION_GREET, OBLIGATION_PRESENCEKNOWN, OBLIGATION_SAYNAME, OBLIGATION_ANNOUNCEKILL, OBLIGATION_ANSWERTONAME) return pick(OBLIGATION_FOOD, OBLIGATION_FIDDLE, OBLIGATION_DANCEOFF, OBLIGATION_GREET, OBLIGATION_PRESENCEKNOWN, OBLIGATION_SAYNAME, OBLIGATION_ANNOUNCEKILL, OBLIGATION_ANSWERTONAME)
@@ -151,7 +166,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
/proc/randomdevilbanish() /proc/randomdevilbanish()
return pick(BANISH_WATER, BANISH_COFFIN, BANISH_FORMALDYHIDE, BANISH_RUNES, BANISH_CANDLES, BANISH_DESTRUCTION, BANISH_FUNERAL_GARB) return pick(BANISH_WATER, BANISH_COFFIN, BANISH_FORMALDYHIDE, BANISH_RUNES, BANISH_CANDLES, BANISH_DESTRUCTION, BANISH_FUNERAL_GARB)
/datum/devilinfo/proc/add_soul(datum/mind/soul) /datum/antagonist/devil/proc/add_soul(datum/mind/soul)
if(soulsOwned.Find(soul)) if(soulsOwned.Find(soul))
return return
soulsOwned += soul soulsOwned += soul
@@ -169,13 +184,13 @@ GLOBAL_LIST_INIT(lawlorify, list (
if(ARCH_THRESHOLD) if(ARCH_THRESHOLD)
increase_arch_devil() increase_arch_devil()
/datum/devilinfo/proc/remove_soul(datum/mind/soul) /datum/antagonist/devil/proc/remove_soul(datum/mind/soul)
if(soulsOwned.Remove(soul)) if(soulsOwned.Remove(soul))
check_regression() check_regression()
to_chat(owner.current, "<span class='warning'>You feel as though a soul has slipped from your grasp.</span>") to_chat(owner.current, "<span class='warning'>You feel as though a soul has slipped from your grasp.</span>")
update_hud() update_hud()
/datum/devilinfo/proc/check_regression() /datum/antagonist/devil/proc/check_regression()
if(form == ARCH_DEVIL) if(form == ARCH_DEVIL)
return //arch devil can't regress return //arch devil can't regress
//Yes, fallthrough behavior is intended, so I can't use a switch statement. //Yes, fallthrough behavior is intended, so I can't use a switch statement.
@@ -187,7 +202,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
remove_spells() remove_spells()
to_chat(owner.current, "<span class='warning'>As punishment for your failures, all of your powers except contract creation have been revoked.") to_chat(owner.current, "<span class='warning'>As punishment for your failures, all of your powers except contract creation have been revoked.")
/datum/devilinfo/proc/regress_humanoid() /datum/antagonist/devil/proc/regress_humanoid()
to_chat(owner.current, "<span class='warning'>Your powers weaken, have more contracts be signed to regain power.") to_chat(owner.current, "<span class='warning'>Your powers weaken, have more contracts be signed to regain power.")
if(ishuman(owner.current)) if(ishuman(owner.current))
var/mob/living/carbon/human/H = owner.current var/mob/living/carbon/human/H = owner.current
@@ -198,7 +213,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
owner.current.forceMove(get_turf(owner.current))//Fixes dying while jaunted leaving you permajaunted. owner.current.forceMove(get_turf(owner.current))//Fixes dying while jaunted leaving you permajaunted.
form = BASIC_DEVIL form = BASIC_DEVIL
/datum/devilinfo/proc/regress_blood_lizard() /datum/antagonist/devil/proc/regress_blood_lizard()
var/mob/living/carbon/true_devil/D = owner.current var/mob/living/carbon/true_devil/D = owner.current
to_chat(D, "<span class='warning'>Your powers weaken, have more contracts be signed to regain power.") to_chat(D, "<span class='warning'>Your powers weaken, have more contracts be signed to regain power.")
D.oldform.loc = D.loc D.oldform.loc = D.loc
@@ -209,7 +224,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
update_hud() update_hud()
/datum/devilinfo/proc/increase_blood_lizard() /datum/antagonist/devil/proc/increase_blood_lizard()
to_chat(owner.current, "<span class='warning'>You feel as though your humanoid form is about to shed. You will soon turn into a blood lizard.") to_chat(owner.current, "<span class='warning'>You feel as though your humanoid form is about to shed. You will soon turn into a blood lizard.")
sleep(50) sleep(50)
if(ishuman(owner.current)) if(ishuman(owner.current))
@@ -227,7 +242,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
/datum/devilinfo/proc/increase_true_devil() /datum/antagonist/devil/proc/increase_true_devil()
to_chat(owner.current, "<span class='warning'>You feel as though your current form is about to shed. You will soon turn into a true devil.") to_chat(owner.current, "<span class='warning'>You feel as though your current form is about to shed. You will soon turn into a true devil.")
sleep(50) sleep(50)
var/mob/living/carbon/true_devil/A = new /mob/living/carbon/true_devil(owner.current.loc) var/mob/living/carbon/true_devil/A = new /mob/living/carbon/true_devil(owner.current.loc)
@@ -241,7 +256,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
update_hud() update_hud()
/datum/devilinfo/proc/increase_arch_devil() /datum/antagonist/devil/proc/increase_arch_devil()
if(!ascendable) if(!ascendable)
return return
var/mob/living/carbon/true_devil/D = owner.current var/mob/living/carbon/true_devil/D = owner.current
@@ -291,17 +306,17 @@ GLOBAL_LIST_INIT(lawlorify, list (
SSticker.mode.devil_ascended++ SSticker.mode.devil_ascended++
form = ARCH_DEVIL form = ARCH_DEVIL
/datum/devilinfo/proc/remove_spells() /datum/antagonist/devil/proc/remove_spells()
for(var/X in owner.spell_list) for(var/X in owner.spell_list)
var/obj/effect/proc_holder/spell/S = X var/obj/effect/proc_holder/spell/S = X
if(!is_type_in_typecache(S, dont_remove_spells)) if(is_type_in_typecache(S, removable_devil_spells))
owner.RemoveSpell(S) owner.RemoveSpell(S)
/datum/devilinfo/proc/give_summon_contract() /datum/antagonist/devil/proc/give_summon_contract()
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_contract(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_contract(null))
/datum/devilinfo/proc/give_base_spells(give_summon_contract = 0) /datum/antagonist/devil/proc/give_base_spells(give_summon_contract = 0)
remove_spells() remove_spells()
owner.AddSpell(new /obj/effect/proc_holder/spell/aimed/fireball/hellish(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/aimed/fireball/hellish(null))
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork(null))
@@ -312,25 +327,25 @@ GLOBAL_LIST_INIT(lawlorify, list (
if(obligation == OBLIGATION_DANCEOFF) if(obligation == OBLIGATION_DANCEOFF)
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_dancefloor(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_dancefloor(null))
/datum/devilinfo/proc/give_lizard_spells() /datum/antagonist/devil/proc/give_lizard_spells()
remove_spells() remove_spells()
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork(null))
owner.AddSpell(new /obj/effect/proc_holder/spell/aimed/fireball/hellish(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/aimed/fireball/hellish(null))
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/infernal_jaunt(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/infernal_jaunt(null))
/datum/devilinfo/proc/give_true_spells() /datum/antagonist/devil/proc/give_true_spells()
remove_spells() remove_spells()
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/greater(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/greater(null))
owner.AddSpell(new /obj/effect/proc_holder/spell/aimed/fireball/hellish(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/aimed/fireball/hellish(null))
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/infernal_jaunt(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/infernal_jaunt(null))
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/sintouch(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/sintouch(null))
/datum/devilinfo/proc/give_arch_spells() /datum/antagonist/devil/proc/give_arch_spells()
remove_spells() remove_spells()
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/ascended(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/summon_pitchfork/ascended(null))
owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/sintouch/ascended(null)) owner.AddSpell(new /obj/effect/proc_holder/spell/targeted/sintouch/ascended(null))
/datum/devilinfo/proc/beginResurrectionCheck(mob/living/body) /datum/antagonist/devil/proc/beginResurrectionCheck(mob/living/body)
if(SOULVALUE>0) if(SOULVALUE>0)
to_chat(owner.current, "<span class='userdanger'>Your body has been damaged to the point that you may no longer use it. At the cost of some of your power, you will return to life soon. Remain in your body.</span>") to_chat(owner.current, "<span class='userdanger'>Your body has been damaged to the point that you may no longer use it. At the cost of some of your power, you will return to life soon. Remain in your body.</span>")
sleep(DEVILRESURRECTTIME) sleep(DEVILRESURRECTTIME)
@@ -350,7 +365,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
else else
to_chat(owner.current, "<span class='userdanger'>Your hellish powers are too weak to resurrect yourself.</span>") to_chat(owner.current, "<span class='userdanger'>Your hellish powers are too weak to resurrect yourself.</span>")
/datum/devilinfo/proc/check_banishment(mob/living/body) /datum/antagonist/devil/proc/check_banishment(mob/living/body)
switch(banish) switch(banish)
if(BANISH_WATER) if(BANISH_WATER)
if(istype(body, /mob/living/carbon)) if(istype(body, /mob/living/carbon))
@@ -394,7 +409,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
return 1 return 1
return 0 return 0
/datum/devilinfo/proc/hellish_resurrection(mob/living/body) /datum/antagonist/devil/proc/hellish_resurrection(mob/living/body)
message_admins("[owner.name] (true name is: [truename]) is resurrecting using hellish energy.</a>") message_admins("[owner.name] (true name is: [truename]) is resurrecting using hellish energy.</a>")
if(SOULVALUE < ARCH_THRESHOLD && ascendable) // once ascended, arch devils do not go down in power by any means. if(SOULVALUE < ARCH_THRESHOLD && ascendable) // once ascended, arch devils do not go down in power by any means.
reviveNumber += LOSS_PER_DEATH reviveNumber += LOSS_PER_DEATH
@@ -413,7 +428,7 @@ GLOBAL_LIST_INIT(lawlorify, list (
create_new_body() create_new_body()
check_regression() check_regression()
/datum/devilinfo/proc/create_new_body() /datum/antagonist/devil/proc/create_new_body()
if(GLOB.blobstart.len > 0) if(GLOB.blobstart.len > 0)
var/turf/targetturf = get_turf(pick(GLOB.blobstart)) var/turf/targetturf = get_turf(pick(GLOB.blobstart))
var/mob/currentMob = owner.current var/mob/currentMob = owner.current
@@ -451,8 +466,65 @@ GLOBAL_LIST_INIT(lawlorify, list (
throw EXCEPTION("Unable to find a blobstart landmark for hellish resurrection") throw EXCEPTION("Unable to find a blobstart landmark for hellish resurrection")
/datum/devilinfo/proc/update_hud() /datum/antagonist/devil/proc/update_hud()
if(istype(owner.current, /mob/living/carbon)) if(istype(owner.current, /mob/living/carbon))
var/mob/living/C = owner.current var/mob/living/C = owner.current
if(C.hud_used && C.hud_used.devilsouldisplay) if(C.hud_used && C.hud_used.devilsouldisplay)
C.hud_used.devilsouldisplay.update_counter(SOULVALUE) C.hud_used.devilsouldisplay.update_counter(SOULVALUE)
/datum/antagonist/devil/greet()
to_chat(owner.current, "<span class='warning'><b>You remember your link to the infernal. You are [truename], an agent of hell, a devil. And you were sent to the plane of creation for a reason. A greater purpose. Convince the crew to sin, and embroiden Hell's grasp.</b></span>")
to_chat(owner.current, "<span class='warning'><b>However, your infernal form is not without weaknesses.</b></span>")
to_chat(owner.current, "You may not use violence to coerce someone into selling their soul.")
to_chat(owner.current, "You may not directly and knowingly physically harm a devil, other than yourself.")
to_chat(owner.current, GLOB.lawlorify[LAW][bane])
to_chat(owner.current, GLOB.lawlorify[LAW][ban])
to_chat(owner.current, GLOB.lawlorify[LAW][obligation])
to_chat(owner.current, GLOB.lawlorify[LAW][banish])
to_chat(owner.current, "<span class='warning'>Remember, the crew can research your weaknesses if they find out your devil name.</span><br>")
.=..()
/datum/antagonist/devil/on_gain()
owner.store_memory("Your devilic true name is [truename]<br>[GLOB.lawlorify[LAW][ban]]<br>You may not use violence to coerce someone into selling their soul.<br>You may not directly and knowingly physically harm a devil, other than yourself.<br>[GLOB.lawlorify[LAW][bane]]<br>[GLOB.lawlorify[LAW][obligation]]<br>[GLOB.lawlorify[LAW][banish]]<br>")
if(issilicon(owner.current))
var/mob/living/silicon/robot_devil = owner.current
var/laws = list("You may not use violence to coerce someone into selling their soul.", "You may not directly and knowingly physically harm a devil, other than yourself.", GLOB.lawlorify[LAW][ban], GLOB.lawlorify[LAW][obligation], "Accomplish your objectives at all costs.")
robot_devil.set_law_sixsixsix(laws)
sleep(10)
if(owner.assigned_role == "Clown" && ishuman(owner.current))
var/mob/living/carbon/human/S = owner.current
to_chat(S, "<span class='notice'>Your infernal nature has allowed you to overcome your clownishness.</span>")
S.dna.remove_mutation(CLOWNMUT)
.=..()
/datum/antagonist/devil/on_removal()
to_chat(owner.current, "<span class='userdanger'>Your infernal link has been severed! You are no longer a devil!</span>")
.=..()
/datum/antagonist/devil/apply_innate_effects(mob/living/mob_override)
give_base_spells(1)
owner.current.grant_all_languages(TRUE)
update_hud()
.=..()
/datum/antagonist/devil/remove_innate_effects(mob/living/mob_override)
for(var/X in owner.spell_list)
var/obj/effect/proc_holder/spell/S = X
if(is_type_in_typecache(S, devil_spells))
owner.RemoveSpell(S)
.=..()
//A simple super light weight datum for the codex gigas.
/datum/fakeDevil
var/truename
var/bane
var/obligation
var/ban
var/banish
/datum/fakeDevil/New(name = randomDevilName())
truename = name
bane = randomdevilbane()
obligation = randomdevilobligation()
ban = randomdevilban()
banish = randomdevilbanish()

View File

@@ -29,25 +29,6 @@
text += "<br>" text += "<br>"
to_chat(world, text) to_chat(world, text)
/datum/game_mode/proc/finalize_devil(datum/mind/devil_mind, ascendable = FALSE)
set waitfor = FALSE
var/trueName= randomDevilName()
devil_mind.devilinfo = devilInfo(trueName, 1)
devil_mind.devilinfo.ascendable = ascendable
devil_mind.store_memory("Your devilic true name is [devil_mind.devilinfo.truename]<br>[GLOB.lawlorify[LAW][devil_mind.devilinfo.ban]]<br>You may not use violence to coerce someone into selling their soul.<br>You may not directly and knowingly physically harm a devil, other than yourself.<br>[GLOB.lawlorify[LAW][devil_mind.devilinfo.bane]]<br>[GLOB.lawlorify[LAW][devil_mind.devilinfo.obligation]]<br>[GLOB.lawlorify[LAW][devil_mind.devilinfo.banish]]<br>")
devil_mind.devilinfo.owner = devil_mind
devil_mind.devilinfo.give_base_spells(1)
if(issilicon(devil_mind.current))
add_law_sixsixsix(devil_mind.current)
sleep(10)
devil_mind.devilinfo.update_hud()
if(devil_mind.assigned_role == "Clown" && ishuman(devil_mind.current))
var/mob/living/carbon/human/S = devil_mind.current
to_chat(S, "<span class='notice'>Your infernal nature has allowed you to overcome your clownishness.</span>")
S.dna.remove_mutation(CLOWNMUT)
/datum/game_mode/proc/add_devil_objectives(datum/mind/devil_mind, quantity) /datum/game_mode/proc/add_devil_objectives(datum/mind/devil_mind, quantity)
var/list/validtypes = list(/datum/objective/devil/soulquantity, /datum/objective/devil/soulquality, /datum/objective/devil/sintouch, /datum/objective/devil/buy_target) var/list/validtypes = list(/datum/objective/devil/soulquantity, /datum/objective/devil/soulquality, /datum/objective/devil/sintouch, /datum/objective/devil/buy_target)
for(var/i = 1 to quantity) for(var/i = 1 to quantity)
@@ -60,28 +41,16 @@
else else
objective.find_target() objective.find_target()
/datum/mind/proc/announceDevilLaws() /datum/game_mode/proc/printdevilinfo(mob/living/ply)
var/datum/antagonist/devil/devilinfo = is_devil(ply)
if(!devilinfo) if(!devilinfo)
return
to_chat(current, "<span class='warning'><b>You remember your link to the infernal. You are [src.devilinfo.truename], an agent of hell, a devil. And you were sent to the plane of creation for a reason. A greater purpose. Convince the crew to sin, and embroiden Hell's grasp.</b></span>")
to_chat(current, "<span class='warning'><b>However, your infernal form is not without weaknesses.</b></span>")
to_chat(current, "You may not use violence to coerce someone into selling their soul.")
to_chat(current, "You may not directly and knowingly physically harm a devil, other than yourself.")
to_chat(current, GLOB.lawlorify[LAW][src.devilinfo.bane])
to_chat(current, GLOB.lawlorify[LAW][src.devilinfo.ban])
to_chat(current, GLOB.lawlorify[LAW][src.devilinfo.obligation])
to_chat(current, GLOB.lawlorify[LAW][src.devilinfo.banish])
to_chat(current, "<br/><br/><span class='warning'>Remember, the crew can research your weaknesses if they find out your devil name.</span><br>")
/datum/game_mode/proc/printdevilinfo(datum/mind/ply)
if(!ply.devilinfo)
return "Target is not a devil." return "Target is not a devil."
var/text = "</br>The devil's true name is: [ply.devilinfo.truename]</br>" var/text = "</br>The devil's true name is: [devilinfo.truename]</br>"
text += "The devil's bans were:</br>" text += "The devil's bans were:</br>"
text += " [GLOB.lawlorify[LORE][ply.devilinfo.ban]]</br>" text += " [GLOB.lawlorify[LORE][devilinfo.ban]]</br>"
text += " [GLOB.lawlorify[LORE][ply.devilinfo.bane]]</br>" text += " [GLOB.lawlorify[LORE][devilinfo.bane]]</br>"
text += " [GLOB.lawlorify[LORE][ply.devilinfo.obligation]]</br>" text += " [GLOB.lawlorify[LORE][devilinfo.obligation]]</br>"
text += " [GLOB.lawlorify[LORE][ply.devilinfo.banish]]</br></br>" text += " [GLOB.lawlorify[LORE][devilinfo.banish]]</br></br>"
return text return text
/datum/game_mode/proc/update_devil_icons_added(datum/mind/devil_mind) /datum/game_mode/proc/update_devil_icons_added(datum/mind/devil_mind)

View File

@@ -14,7 +14,9 @@
/datum/objective/devil/soulquantity/check_completion() /datum/objective/devil/soulquantity/check_completion()
var/count = 0 var/count = 0
for(var/S in owner.devilinfo.soulsOwned) var/datum/antagonist/devil/devilDatum = owner.has_antag_datum(ANTAG_DATUM_DEVIL)
var/list/souls = devilDatum.soulsOwned
for(var/S in souls) //Just a sanity check.
var/datum/mind/L = S var/datum/mind/L = S
if(L.soulOwner == owner) if(L.soulOwner == owner)
count++ count++
@@ -52,9 +54,11 @@
/datum/objective/devil/soulquality/check_completion() /datum/objective/devil/soulquality/check_completion()
var/count = 0 var/count = 0
for(var/S in owner.devilinfo.soulsOwned) var/datum/antagonist/devil/devilDatum = owner.has_antag_datum(ANTAG_DATUM_DEVIL)
var/list/souls = devilDatum.soulsOwned
for(var/S in souls)
var/datum/mind/L = S var/datum/mind/L = S
if(L.soulOwner != L && L.damnation_type == contractType) if(!L.owns_soul() && L.damnation_type == contractType)
count++ count++
return count>=target_amount return count>=target_amount
@@ -91,16 +95,21 @@
/datum/objective/devil/outsell/New() /datum/objective/devil/outsell/New()
/datum/objective/devil/outsell/update_explanation_text() /datum/objective/devil/outsell/update_explanation_text()
explanation_text = "Purchase and retain control over more souls than [target.devilinfo.truename], known to mortals as [target.name], the [target.assigned_role]." var/datum/antagonist/devil/opponent = target.has_antag_datum(ANTAG_DATUM_DEVIL)
explanation_text = "Purchase and retain control over more souls than [opponent.truename], known to mortals as [target.name], the [target.assigned_role]."
/datum/objective/devil/outsell/check_completion() /datum/objective/devil/outsell/check_completion()
var/selfcount = 0 var/selfcount = 0
for(var/S in owner.devilinfo.soulsOwned) var/datum/antagonist/devil/devilDatum = owner.has_antag_datum(ANTAG_DATUM_DEVIL)
var/list/souls = devilDatum.soulsOwned
for(var/S in souls)
var/datum/mind/L = S var/datum/mind/L = S
if(L.soulOwner == owner) if(L.soulOwner == owner)
selfcount++ selfcount++
var/targetcount = 0 var/targetcount = 0
for(var/S in target.devilinfo.soulsOwned) devilDatum = target.has_antag_datum(ANTAG_DATUM_DEVIL)
souls = devilDatum.soulsOwned
for(var/S in souls)
var/datum/mind/L = S var/datum/mind/L = S
if(L.soulOwner == target) if(L.soulOwner == target)
targetcount++ targetcount++

View File

@@ -41,18 +41,20 @@
/mob/living/carbon/true_devil/proc/convert_to_archdevil() /mob/living/carbon/true_devil/proc/convert_to_archdevil()
maxHealth = 5000 // not an IMPOSSIBLE amount, but still near impossible. maxHealth = 500 // not an IMPOSSIBLE amount, but still near impossible.
ascended = TRUE ascended = TRUE
health = maxHealth health = maxHealth
icon_state = "arch_devil" icon_state = "arch_devil"
/mob/living/carbon/true_devil/proc/set_name() /mob/living/carbon/true_devil/proc/set_name()
name = mind.devilinfo.truename var/datum/antagonist/devil/devilinfo = mind.has_antag_datum(ANTAG_DATUM_DEVIL)
name = devilinfo.truename
real_name = name real_name = name
/mob/living/carbon/true_devil/Login() /mob/living/carbon/true_devil/Login()
..() ..()
mind.announceDevilLaws() var/datum/antagonist/devil/devilinfo = mind.has_antag_datum(ANTAG_DATUM_DEVIL)
devilinfo.greet()
mind.announce_objectives() mind.announce_objectives()
@@ -60,7 +62,7 @@
stat = DEAD stat = DEAD
..(gibbed) ..(gibbed)
drop_all_held_items() drop_all_held_items()
INVOKE_ASYNC(mind.devilinfo, /datum/devilinfo/proc/beginResurrectionCheck, src) INVOKE_ASYNC(mind.has_antag_datum(ANTAG_DATUM_DEVIL), /datum/antagonist/devil/proc/beginResurrectionCheck, src)
/mob/living/carbon/true_devil/examine(mob/user) /mob/living/carbon/true_devil/examine(mob/user)

View File

@@ -234,10 +234,6 @@
to_chat(killer, "Your radio has been upgraded! Use :t to speak on an encrypted channel with Syndicate Agents!") to_chat(killer, "Your radio has been upgraded! Use :t to speak on an encrypted channel with Syndicate Agents!")
killer.add_malf_picker() killer.add_malf_picker()
/datum/game_mode/proc/add_law_sixsixsix(mob/living/silicon/devil)
var/laws = list("You may not use violence to coerce someone into selling their soul.", "You may not directly and knowingly physically harm a devil, other than yourself.", GLOB.lawlorify[LAW][devil.mind.devilinfo.ban], GLOB.lawlorify[LAW][devil.mind.devilinfo.obligation], "Accomplish your objectives at all costs.")
devil.set_law_sixsixsix(laws)
/datum/game_mode/proc/auto_declare_completion_traitor() /datum/game_mode/proc/auto_declare_completion_traitor()
if(traitors.len) if(traitors.len)
var/text = "<br><font size=3><b>The [traitor_name]s were:</b></font>" var/text = "<br><font size=3><b>The [traitor_name]s were:</b></font>"

View File

@@ -529,7 +529,7 @@
"<span class='notice'>You hear a soft click.</span>") "<span class='notice'>You hear a soft click.</span>")
/obj/item/toy/talking/codex_gigas/generate_messages() /obj/item/toy/talking/codex_gigas/generate_messages()
var/datum/devilinfo/devil = randomDevilInfo() var/datum/fakeDevil/devil = new
var/list/messages = list() var/list/messages = list()
messages += "Some fun facts about: [devil.truename]" messages += "Some fun facts about: [devil.truename]"
messages += "[GLOB.lawlorify[LORE][devil.bane]]" messages += "[GLOB.lawlorify[LORE][devil.bane]]"

View File

@@ -602,20 +602,19 @@
user.visible_message("<span class='suicide'>[user] impales [user.p_them()]self in [user.p_their()] abdomen with [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>") user.visible_message("<span class='suicide'>[user] impales [user.p_them()]self in [user.p_their()] abdomen with [src]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
return (BRUTELOSS) return (BRUTELOSS)
/obj/item/weapon/twohanded/pitchfork/demonic/pickup(mob/user) /obj/item/weapon/twohanded/pitchfork/demonic/pickup(mob/living/user)
if(isliving(user)) if(isliving(user) && user.mind && user.owns_soul() && !is_devil(user))
var/mob/living/U = user var/mob/living/U = user
if(U.mind && !U.mind.devilinfo && (U.mind.soulOwner == U.mind)) //Burn hands unless they are a devil or have sold their soul U.visible_message("<span class='warning'>As [U] picks [src] up, [U]'s arms briefly catch fire.</span>", \
U.visible_message("<span class='warning'>As [U] picks [src] up, [U]'s arms briefly catch fire.</span>", \ "<span class='warning'>\"As you pick up [src] your arms ignite, reminding you of all your past sins.\"</span>")
"<span class='warning'>\"As you pick up [src] your arms ignite, reminding you of all your past sins.\"</span>") if(ishuman(U))
if(ishuman(U)) var/mob/living/carbon/human/H = U
var/mob/living/carbon/human/H = U H.apply_damage(rand(force/2, force), BURN, pick("l_arm", "r_arm"))
H.apply_damage(rand(force/2, force), BURN, pick("l_arm", "r_arm")) else
else U.adjustFireLoss(rand(force/2,force))
U.adjustFireLoss(rand(force/2,force))
/obj/item/weapon/twohanded/pitchfork/demonic/attack(mob/target, mob/living/carbon/human/user) /obj/item/weapon/twohanded/pitchfork/demonic/attack(mob/target, mob/living/carbon/human/user)
if(user.mind && !user.mind.devilinfo && (user.mind.soulOwner != user.mind)) if(user.mind && user.owns_soul() && !is_devil(user))
to_chat(user, "<span class ='warning'>[src] burns in your hands.</span>") to_chat(user, "<span class ='warning'>[src] burns in your hands.</span>")
user.apply_damage(rand(force/2, force), BURN, pick("l_arm", "r_arm")) user.apply_damage(rand(force/2, force), BURN, pick("l_arm", "r_arm"))
..() ..()

View File

@@ -295,3 +295,52 @@
/obj/effect/mob_spawn/human/hotel_staff/Destroy() /obj/effect/mob_spawn/human/hotel_staff/Destroy()
new/obj/structure/fluff/empty_sleeper/syndicate(get_turf(src)) new/obj/structure/fluff/empty_sleeper/syndicate(get_turf(src))
..() ..()
/obj/effect/mob_spawn/human/demonic_friend
name = "Essence of friendship"
desc = "Oh boy! Oh boy! A friend!"
mob_name = "Demonic friend"
icon = 'icons/obj/cardboard_cutout.dmi'
icon_state = "cutout_basic"
uniform = /obj/item/clothing/under/assistantformal
shoes = /obj/item/clothing/shoes/laceup
pocket1 = /obj/item/device/radio/off
back = /obj/item/weapon/storage/backpack
implants = list(/obj/item/weapon/implant/mindshield) //No revolutionaries, he's MY friend.
death = FALSE
roundstart = FALSE
random = TRUE
has_id = TRUE
id_job = "SuperFriend"
id_access = "assistant"
var/obj/effect/proc_holder/spell/targeted/summon_friend/spell
var/datum/mind/owner
/obj/effect/mob_spawn/human/demonic_friend/Initialize(mapload, datum/mind/owner_mind, obj/effect/proc_holder/spell/targeted/summon_friend/summoning_spell)
..()
owner = owner_mind
flavour_text = "You have been given a reprieve from your eternity of torment, to be [owner.name]'s friend for their short mortal coil. Be aware that if you do not live up to [owner.name]'s expectations, they can send you back to hell with a single thought. [owner.name]'s death will also return you to hell."
var/area/A = get_area(src)
if(!mapload && A)
notify_ghosts("\A friendship shell has been completed in \the [A.name].", source = src, action=NOTIFY_ATTACK, flashwindow = FALSE)
objectives = "Be [owner.name]'s friend, and keep [owner.name] alive, so you don't get sent back to hell."
spell = summoning_spell
/obj/effect/mob_spawn/human/demonic_friend/special(mob/living/L)
if(!QDELETED(owner.current) && owner.current.stat != DEAD)
L.real_name = "[owner.name]'s best friend"
L.name = L.real_name
soullink(/datum/soullink/oneway, owner.current, L)
spell.friend = L
spell.charge_counter = spell.charge_max
L.mind.hasSoul = FALSE
var/mob/living/carbon/human/H = L
var/obj/item/worn = H.wear_id
var/obj/item/weapon/card/id/id = worn.GetID()
id.registered_name = L.real_name
id.update_label()
else
to_chat(L, "<span class='userdanger'>Your owner is already dead! You will soon perish.</span>")
addtimer(CALLBACK(L, /mob.proc/dust, 150)) //Give em a few seconds as a mercy.

View File

@@ -1,4 +1,3 @@
//////////////////////////////// ////////////////////////////////
/proc/message_admins(msg) /proc/message_admins(msg)
msg = "<span class=\"admin\"><span class=\"prefix\">ADMIN LOG:</span> <span class=\"message\">[msg]</span></span>" msg = "<span class=\"admin\"><span class=\"prefix\">ADMIN LOG:</span> <span class=\"message\">[msg]</span></span>"
@@ -705,7 +704,7 @@
to_chat(usr, "<b>No Devils located</b>" ) to_chat(usr, "<b>No Devils located</b>" )
/datum/admins/proc/output_devil_info(mob/living/M) /datum/admins/proc/output_devil_info(mob/living/M)
if(istype(M) && M.mind && M.mind.devilinfo) if(is_devil(M))
to_chat(usr, SSticker.mode.printdevilinfo(M.mind)) to_chat(usr, SSticker.mode.printdevilinfo(M.mind))
else else
to_chat(usr, "<b>[M] is not a devil.") to_chat(usr, "<b>[M] is not a devil.")

View File

@@ -567,13 +567,14 @@
for(var/X in SSticker.mode.devils) for(var/X in SSticker.mode.devils)
var/datum/mind/devil = X var/datum/mind/devil = X
var/mob/M = devil.current var/mob/M = devil.current
var/datum/antagonist/devil/devilinfo = devil.has_antag_datum(ANTAG_DATUM_DEVIL)
if(M) if(M)
dat += "<tr><td><a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name] : [devil.devilinfo.truename]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>" dat += "<tr><td><a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name] : [devilinfo.truename]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>" dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
dat += "<td><A HREF='?_src_=holder;traitor=\ref[M]'>Show Objective</A></td></tr>" dat += "<td><A HREF='?_src_=holder;traitor=\ref[M]'>Show Objective</A></td></tr>"
dat += "<td><A HREF='?_src_=holder;admincheckdevilinfo=\ref[M]'>Show all devil info</A></td></tr>" dat += "<td><A HREF='?_src_=holder;admincheckdevilinfo=\ref[M]'>Show all devil info</A></td></tr>"
else else
dat += "<tr><td><a href='?_src_=vars;Vars=\ref[devil]'>[devil.name] : [devil.devilinfo.truename] ([devil.key])</a><i>devil body destroyed!</i></td></tr>" dat += "<tr><td><a href='?_src_=vars;Vars=\ref[devil]'>[devil.name] : [devilinfo.truename] ([devil.key])</a><i>devil body destroyed!</i></td></tr>"
dat += "<td><A href='?priv_msg=[devil.key]'>PM</A></td>" dat += "<td><A href='?priv_msg=[devil.key]'>PM</A></td>"
dat += "</table>" dat += "</table>"

View File

@@ -20,6 +20,7 @@
var/oxy_damage = 0 var/oxy_damage = 0
density = 1 density = 1
anchored = 1 anchored = 1
var/banType = "lavaland"
/obj/effect/mob_spawn/attack_ghost(mob/user) /obj/effect/mob_spawn/attack_ghost(mob/user)
if(!SSticker.HasRoundStarted() || !loc) if(!SSticker.HasRoundStarted() || !loc)
@@ -27,7 +28,7 @@
if(!uses) if(!uses)
to_chat(user, "<span class='warning'>This spawner is out of charges!</span>") to_chat(user, "<span class='warning'>This spawner is out of charges!</span>")
return return
if(jobban_isbanned(user, "lavaland")) if(jobban_isbanned(user, banType))
to_chat(user, "<span class='warning'>You are jobanned!</span>") to_chat(user, "<span class='warning'>You are jobanned!</span>")
return return
var/ghost_role = alert("Become [mob_name]? (Warning, You can no longer be cloned!)",,"Yes","No") var/ghost_role = alert("Become [mob_name]? (Warning, You can no longer be cloned!)",,"Yes","No")

View File

@@ -32,11 +32,7 @@
var/mob/living/carbon/human/devil = create_event_devil(spawn_loc) var/mob/living/carbon/human/devil = create_event_devil(spawn_loc)
Mind.transfer_to(devil) Mind.transfer_to(devil)
SSticker.mode.finalize_devil(Mind, FALSE) add_devil(devil, ascendable = FALSE)
SSticker.mode.add_devil_objectives(src, 2)
Mind.announceDevilLaws()
Mind.announce_objectives()
spawned_mobs += devil spawned_mobs += devil
message_admins("[key_name_admin(devil)] has been made into a devil by an event.") message_admins("[key_name_admin(devil)] has been made into a devil by an event.")

View File

@@ -1,3 +1,9 @@
#define PRE_TITLE 1
#define TITLE 2
#define SYLLABLE 3
#define MULTIPLE_SYLLABLE 4
#define SUFFIX 5
/obj/item/weapon/book/codex_gigas /obj/item/weapon/book/codex_gigas
name = "Codex Gigas" name = "Codex Gigas"
icon_state ="demonomicon" icon_state ="demonomicon"
@@ -8,16 +14,14 @@
unique = 1 unique = 1
title = "The codex gigas" title = "The codex gigas"
var/inUse = 0 var/inUse = 0
var/currentName = ""
var/currentSection = PRE_TITLE
/obj/item/weapon/book/codex_gigas/attack_self(mob/user) /obj/item/weapon/book/codex_gigas/attack_self(mob/user)
if(is_blind(user)) if(is_blind(user))
to_chat(user, "<span class='warning'>As you are trying to read, you suddenly feel very stupid.</span>") to_chat(user, "<span class='warning'>As you are trying to read, you suddenly feel very stupid.</span>")
return return
if(ismonkey(user)) if(!user.is_literate())
to_chat(user, "<span class='notice'>You skim through the book but can't comprehend any of it.</span>") to_chat(user, "<span class='notice'>You skim through the book but can't comprehend any of it.</span>")
return return
if(inUse) if(inUse)
@@ -27,31 +31,78 @@
if(U.check_acedia()) if(U.check_acedia())
to_chat(user, "<span class='notice'>None of this matters, why are you reading this? You put the [title] down.</span>") to_chat(user, "<span class='notice'>None of this matters, why are you reading this? You put the [title] down.</span>")
return return
inUse = 1 user.visible_message("[user] opens [title] and begins reading intently.")
var/devilName = copytext(sanitize(input(user, "What infernal being do you wish to research?", "Codex Gigas", null) as text),1,MAX_MESSAGE_LEN) ask_name(user)
var/speed = 300
var/correctness = 85
var/willpower = 98 /obj/item/weapon/book/codex_gigas/proc/perform_research(mob/user, devilName)
if(!devilName)
user.visible_message("[user] closes [title] without looking anything up.")
return
inUse = TRUE
var/speed = 300
var/correctness = 85
if(ishuman(user))
var/mob/living/carbon/human/U = user
if(U.job in list("Curator")) // the curator is both faster, and more accurate than normal crew members at research if(U.job in list("Curator")) // the curator is both faster, and more accurate than normal crew members at research
speed = 45 speed = 100
correctness = 100 correctness = 100
willpower = 100
if(U.job in list("Captain", "Security Officer", "Head of Security", "Detective", "Warden"))
willpower = 99
if(U.job in list("Clown")) // WHO GAVE THE CLOWN A DEMONOMICON? BAD THINGS WILL HAPPEN!
willpower = 25
correctness -= U.getBrainLoss() *0.5 //Brain damage makes researching hard. correctness -= U.getBrainLoss() *0.5 //Brain damage makes researching hard.
speed += U.getBrainLoss() * 3 speed += U.getBrainLoss() * 3
user.visible_message("[user] opens [title] and begins reading intently.") if(do_after(user, speed, 0, user))
if(do_after(U, speed, 0, U)) var/usedName = devilName
var/usedName = devilName if(!prob(correctness))
if(!prob(correctness)) usedName += "x"
usedName += "x" var/datum/antagonist/devil/devil = devilInfo(usedName)
var/datum/devilinfo/devil = devilInfo(usedName, 0) display_devil(devil, user, usedName)
user << browse("Information on [devilName]<br><br><br>[GLOB.lawlorify[LORE][devil.ban]]<br>[GLOB.lawlorify[LORE][devil.bane]]<br>[GLOB.lawlorify[LORE][devil.obligation]]<br>[GLOB.lawlorify[LORE][devil.banish]]", "window=book[window_size != null ? ";size=[window_size]" : ""]") sleep(10)
inUse = 0 onclose(user, "book")
sleep(10) inUse = FALSE
if(!prob(willpower))
U.influenceSin()
onclose(user, "book")
/obj/item/weapon/book/codex_gigas/proc/display_devil(datum/antagonist/devil/devil, mob/reader, devilName)
reader << browse("Information on [devilName]<br><br><br>[GLOB.lawlorify[LORE][devil.ban]]<br>[GLOB.lawlorify[LORE][devil.bane]]<br>[GLOB.lawlorify[LORE][devil.obligation]]<br>[GLOB.lawlorify[LORE][devil.banish]]", "window=book[window_size != null ? ";size=[window_size]" : ""]")
/obj/item/weapon/book/codex_gigas/proc/ask_name(mob/reader)
ui_interact(reader)
/obj/item/weapon/book/codex_gigas/ui_act(action, params)
if(..())
return
if(!action)
return FALSE
if(action == "search")
SStgui.close_uis(src)
addtimer(CALLBACK(src, .proc/perform_research, usr, currentName), 0)
currentName = ""
currentSection = PRE_TITLE
return FALSE
else
currentName += action
var/oldSection = currentSection
if(GLOB.devil_pre_title.Find(action))
currentSection = TITLE
else if(GLOB.devil_title.Find(action))
currentSection = SYLLABLE
else if(GLOB.devil_syllable.Find(action))
if (currentSection>=SYLLABLE)
currentSection = MULTIPLE_SYLLABLE
else
currentSection = SYLLABLE
else if(GLOB.devil_suffix.Find(action))
currentSection = SUFFIX
else
to_chat(world, "Codex gigas failure [action]")
return currentSection != oldSection
/obj/item/weapon/book/codex_gigas/ui_interact(mob/user, ui_key = "main", datum/tgui/ui = null, force_open = 0, \
datum/tgui/master_ui = null, datum/ui_state/state = GLOB.default_state)
ui = SStgui.try_update_ui(user, src, ui_key, ui, force_open)
if(!ui)
ui = new(user, src, ui_key, "codex_gigas", name, 450, 450, master_ui, state)
ui.open()
/obj/item/weapon/book/codex_gigas/ui_data(mob/user)
var/list/data = list()
data["name"]=currentName
data["currentSection"]=currentSection
return data

View File

@@ -34,8 +34,8 @@
if(SSticker && SSticker.mode) if(SSticker && SSticker.mode)
SSblackbox.ReportDeath(src) SSblackbox.ReportDeath(src)
if(mind && mind.devilinfo) if(is_devil(src))
INVOKE_ASYNC(mind.devilinfo, /datum/devilinfo.proc/beginResurrectionCheck, src) INVOKE_ASYNC(is_devil(src), /datum/antagonist/devil.proc/beginResurrectionCheck, src)
/mob/living/carbon/human/proc/makeSkeleton() /mob/living/carbon/human/proc/makeSkeleton()
status_flags |= DISFIGURED status_flags |= DISFIGURED

View File

@@ -811,23 +811,22 @@
/mob/living/proc/owns_soul() /mob/living/proc/owns_soul()
if(mind) if(mind)
return mind.soulOwner == mind return mind.soulOwner == mind
return 1 return TRUE
/mob/living/proc/return_soul() /mob/living/proc/return_soul()
hellbound = 0 hellbound = 0
if(mind) if(mind)
if(mind.soulOwner.devilinfo)//Not sure how this could happen, but whatever. var/datum/antagonist/devil/devilInfo = mind.soulOwner.has_antag_datum(ANTAG_DATUM_DEVIL)
mind.soulOwner.devilinfo.remove_soul(mind) if(devilInfo)//Not sure how this could be null, but let's just try anyway.
devilInfo.remove_soul(mind)
mind.soulOwner = mind mind.soulOwner = mind
/mob/living/proc/has_bane(banetype) /mob/living/proc/has_bane(banetype)
if(mind) var/datum/antagonist/devil/devilInfo = is_devil(src)
if(mind.devilinfo) return (banetype == devilInfo.bane)
return mind.devilinfo.bane == banetype
return 0
/mob/living/proc/check_weakness(obj/item/weapon, mob/living/attacker) /mob/living/proc/check_weakness(obj/item/weapon, mob/living/attacker)
if(mind && mind.devilinfo) if(mind && mind.has_antag_datum(ANTAG_DATUM_DEVIL))
return check_devil_bane_multiplier(weapon, attacker) return check_devil_bane_multiplier(weapon, attacker)
return 1 return 1

View File

@@ -32,12 +32,14 @@
/obj/item/weapon/paper/contract/employment/attack(mob/living/M, mob/living/carbon/human/user) /obj/item/weapon/paper/contract/employment/attack(mob/living/M, mob/living/carbon/human/user)
var/deconvert = 0 var/deconvert = FALSE
if(M.mind == target && target.soulOwner != target) if(M.mind == target && !M.owns_soul())
if(user.mind && (user.mind.assigned_role == "Lawyer")) if(user.mind && (user.mind.assigned_role == "Lawyer"))
deconvert = prob (25) deconvert = TRUE
else if (user.mind && (user.mind.assigned_role =="Head of Personnel") || (user.mind.assigned_role == "Centcom Commander")) else if (user.mind && (user.mind.assigned_role =="Head of Personnel") || (user.mind.assigned_role == "Centcom Commander"))
deconvert = prob (10) // the HoP doesn't have AS much legal training deconvert = prob (25) // the HoP doesn't have AS much legal training
else
deconvert = prob (5)
if(deconvert) if(deconvert)
M.visible_message("<span class='notice'>[user] reminds [M] that [M]'s soul was already purchased by Nanotrasen!</span>") M.visible_message("<span class='notice'>[user] reminds [M] that [M]'s soul was already purchased by Nanotrasen!</span>")
to_chat(M, "<span class='boldnotice'>You feel that your soul has returned to its rightful owner, Nanotrasen.</span>") to_chat(M, "<span class='boldnotice'>You feel that your soul has returned to its rightful owner, Nanotrasen.</span>")
@@ -57,6 +59,7 @@
var/contractType = 0 var/contractType = 0
resistance_flags = LAVA_PROOF | FIRE_PROOF | ACID_PROOF resistance_flags = LAVA_PROOF | FIRE_PROOF | ACID_PROOF
var/datum/mind/owner var/datum/mind/owner
var/datum/antagonist/devil/devil_datum
icon_state = "paper_onfire" icon_state = "paper_onfire"
/obj/item/weapon/paper/contract/infernal/power /obj/item/weapon/paper/contract/infernal/power
@@ -84,6 +87,10 @@
name = "paper- contract for knowledge" name = "paper- contract for knowledge"
contractType = CONTRACT_KNOWLEDGE contractType = CONTRACT_KNOWLEDGE
/obj/item/weapon/paper/contract/infernal/friend
name = "paper- contract for a friend"
contractType = CONTRACT_FRIEND
/obj/item/weapon/paper/contract/infernal/unwilling /obj/item/weapon/paper/contract/infernal/unwilling
name = "paper- infernal contract" name = "paper- infernal contract"
contractType = CONTRACT_UNWILLING contractType = CONTRACT_UNWILLING
@@ -91,11 +98,10 @@
/obj/item/weapon/paper/contract/infernal/New(atom/loc, mob/living/nTarget, datum/mind/nOwner) /obj/item/weapon/paper/contract/infernal/New(atom/loc, mob/living/nTarget, datum/mind/nOwner)
..() ..()
owner = nOwner owner = nOwner
devil_datum = owner.has_antag_datum(ANTAG_DATUM_DEVIL)
target = nTarget target = nTarget
update_text() update_text()
/obj/item/weapon/paper/contract/infernal
/obj/item/weapon/paper/contract/infernal/suicide_act(mob/user) /obj/item/weapon/paper/contract/infernal/suicide_act(mob/user)
if(signed && (user == target.current) && istype(user,/mob/living/carbon/human/)) if(signed && (user == target.current) && istype(user,/mob/living/carbon/human/))
var/mob/living/carbon/human/H = user var/mob/living/carbon/human/H = user
@@ -111,49 +117,56 @@
info = "This shouldn't be seen. Error DEVIL:6" info = "This shouldn't be seen. Error DEVIL:6"
/obj/item/weapon/paper/contract/infernal/power/update_text(signature = "____________", blood = 0) /obj/item/weapon/paper/contract/infernal/power/update_text(signature = "____________", blood = 0)
info = "<center><B>Contract for infernal power</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [owner.devilinfo.truename], in exchange for power and physical strength. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, " info = "<center><B>Contract for infernal power</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [devil_datum.truename], in exchange for power and physical strength. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, "
if(blood) if(blood)
info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>" info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>"
else else
info += "<i>[signature]</i>" info += "<i>[signature]</i>"
/obj/item/weapon/paper/contract/infernal/wealth/update_text(signature = "____________", blood = 0) /obj/item/weapon/paper/contract/infernal/wealth/update_text(signature = "____________", blood = 0)
info = "<center><B>Contract for unlimited wealth</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [owner.devilinfo.truename], in exchange for a pocket that never runs out of valuable resources. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, " info = "<center><B>Contract for unlimited wealth</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [devil_datum.truename], in exchange for a pocket that never runs out of valuable resources. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, "
if(blood) if(blood)
info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>" info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>"
else else
info += "<i>[signature]</i>" info += "<i>[signature]</i>"
/obj/item/weapon/paper/contract/infernal/prestige/update_text(signature = "____________", blood = 0) /obj/item/weapon/paper/contract/infernal/prestige/update_text(signature = "____________", blood = 0)
info = "<center><B>Contract for prestige</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [owner.devilinfo.truename], in exchange for prestige and esteem among my peers. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, " info = "<center><B>Contract for prestige</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [devil_datum.truename], in exchange for prestige and esteem among my peers. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, "
if(blood) if(blood)
info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>" info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>"
else else
info += "<i>[signature]</i>" info += "<i>[signature]</i>"
/obj/item/weapon/paper/contract/infernal/magic/update_text(signature = "____________", blood = 0) /obj/item/weapon/paper/contract/infernal/magic/update_text(signature = "____________", blood = 0)
info = "<center><B>Contract for magic</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [owner.devilinfo.truename], in exchange for arcane abilities beyond normal human ability. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, " info = "<center><B>Contract for magic</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [devil_datum.truename], in exchange for arcane abilities beyond normal human ability. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, "
if(blood) if(blood)
info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>" info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>"
else else
info += "<i>[signature]</i>" info += "<i>[signature]</i>"
/obj/item/weapon/paper/contract/infernal/revive/update_text(signature = "____________", blood = 0) /obj/item/weapon/paper/contract/infernal/revive/update_text(signature = "____________", blood = 0)
info = "<center><B>Contract for resurrection</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [owner.devilinfo.truename], in exchange for resurrection and curing of all injuries. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, " info = "<center><B>Contract for resurrection</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [devil_datum.truename], in exchange for resurrection and curing of all injuries. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, "
if(blood) if(blood)
info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>" info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>"
else else
info += "<i>[signature]</i>" info += "<i>[signature]</i>"
/obj/item/weapon/paper/contract/infernal/knowledge/update_text(signature = "____________", blood = 0) /obj/item/weapon/paper/contract/infernal/knowledge/update_text(signature = "____________", blood = 0)
info = "<center><B>Contract for knowledge</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [owner.devilinfo.truename], in exchange for boundless knowledge. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, " info = "<center><B>Contract for knowledge</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [devil_datum.truename], in exchange for boundless knowledge. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, "
if(blood)
info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>"
else
info += "<i>[signature]</i>"
/obj/item/weapon/paper/contract/infernal/friend/update_text(signature = "____________", blood = 0)
info = "<center><B>Contract for a friend</B></center><BR><BR><BR>I, [target] of sound mind, do hereby willingly offer my soul to the infernal hells by way of the infernal agent [devil_datum.truename], in exchange for a friend. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, "
if(blood) if(blood)
info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>" info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>"
else else
info += "<i>[signature]</i>" info += "<i>[signature]</i>"
/obj/item/weapon/paper/contract/infernal/unwilling/update_text(signature = "____________", blood = 0) /obj/item/weapon/paper/contract/infernal/unwilling/update_text(signature = "____________", blood = 0)
info = "<center><B>Contract for slave</B></center><BR><BR><BR>I, [target], hereby offer my soul to the infernal hells by way of the infernal agent [owner.devilinfo.truename]. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, " info = "<center><B>Contract for slave</B></center><BR><BR><BR>I, [target], hereby offer my soul to the infernal hells by way of the infernal agent [devil_datum.truename]. I understand that upon my demise, my soul shall fall into the infernal hells, and my body may not be resurrected, cloned, or otherwise brought back to life. I also understand that this will prevent my brain from being used in an MMI.<BR><BR><BR>Signed, "
if(blood) if(blood)
info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>" info += "<font face=\"Nyala\" color=#600A0A size=6><i>[signature]</i></font>"
else else
@@ -179,33 +192,40 @@
return ..() return ..()
/obj/item/weapon/paper/contract/infernal/proc/attempt_signature(mob/living/carbon/human/user, blood = 0) /obj/item/weapon/paper/contract/infernal/proc/attempt_signature(mob/living/carbon/human/user, blood = 0)
if(user.IsAdvancedToolUser() && user.is_literate()) if(!user.IsAdvancedToolUser() || !user.is_literate())
if(user.mind == target)
if(user.mind.soulOwner != owner)
if (contractType == CONTRACT_REVIVE)
to_chat(user, "<span class='notice'>You are already alive, this contract would do nothing.</span>")
else
if(signed)
to_chat(user, "<span class='notice'>This contract has already been signed. It may not be signed again.</span>")
else
to_chat(user, "<span class='notice'>You quickly scrawl your name on the contract</span>")
if(FulfillContract(target.current, blood)<=0)
to_chat(user, "<span class='notice'>But it seemed to have no effect, perhaps even Hell itself cannot grant this boon?</span>")
return 1
else
to_chat(user, "<span class='notice'>This devil already owns your soul, you may not sell it to them again.</span>")
else
to_chat(user, "<span class='notice'>Your signature simply slides off the sheet, it seems this contract is not meant for you to sign.</span>")
else
to_chat(user, "<span class='notice'>You don't know how to read or write.</span>") to_chat(user, "<span class='notice'>You don't know how to read or write.</span>")
return 0 return 0
if(user.mind != target)
to_chat(user, "<span class='notice'>Your signature simply slides off the sheet, it seems this contract is not meant for you to sign.</span>")
return 0
if(user.mind.soulOwner == owner)
to_chat(user, "<span class='notice'>This devil already owns your soul, you may not sell it to them again.</span>")
return 0
if(signed)
to_chat(user, "<span class='notice'>This contract has already been signed. It may not be signed again.</span>")
return 0
if(!user.mind.hasSoul)
to_chat(user, "<span class='notice'>You do not possess a soul.</span>")
return 0
if(prob(user.getBrainLoss()))
to_chat(user, "<span class='notice'>You quickly scrawl 'your name' on the contract.</span>")
signIncorrectly()
return 0
if (contractType == CONTRACT_REVIVE)
to_chat(user, "<span class='notice'>You are already alive, this contract would do nothing.</span>")
return 0
else
to_chat(user, "<span class='notice'>You quickly scrawl your name on the contract</span>")
if(fulfillContract(target.current, blood)<=0)
to_chat(user, "<span class='notice'>But it seemed to have no effect, perhaps even Hell itself cannot grant this boon?</span>")
return 1
/obj/item/weapon/paper/contract/infernal/revive/attack(mob/M, mob/living/user) /obj/item/weapon/paper/contract/infernal/revive/attack(mob/M, mob/living/user)
if (target == M.mind && M.stat == DEAD && M.mind.soulOwner == M.mind) if (target == M.mind && M.stat == DEAD && M.mind.soulOwner == M.mind)
if (cooldown) if (cooldown)
to_chat(user, "<span class='notice'>Give [M] a chance to think through the contract, don't rush him.</span>") to_chat(user, "<span class='notice'>Give [M] a chance to think through the contract, don't rush them.</span>")
return 0 return 0
cooldown = TRUE cooldown = TRUE
var/mob/living/carbon/human/H = M var/mob/living/carbon/human/H = M
@@ -223,7 +243,7 @@
add_logs(user, H, "infernally revived via contract") add_logs(user, H, "infernally revived via contract")
user.visible_message("<span class='notice'>With a sudden blaze, [H] stands back up.</span>") user.visible_message("<span class='notice'>With a sudden blaze, [H] stands back up.</span>")
H.fakefire() H.fakefire()
FulfillContract(H, 1)//Revival contracts are always signed in blood fulfillContract(H, 1)//Revival contracts are always signed in blood
addtimer(CALLBACK(H, /mob/living/carbon/human.proc/fakefireextinguish), 5, TIMER_UNIQUE) addtimer(CALLBACK(H, /mob/living/carbon/human.proc/fakefireextinguish), 5, TIMER_UNIQUE)
addtimer(CALLBACK(src, "resetcooldown"), 300, TIMER_UNIQUE) addtimer(CALLBACK(src, "resetcooldown"), 300, TIMER_UNIQUE)
else else
@@ -233,20 +253,26 @@
cooldown = FALSE cooldown = FALSE
/obj/item/weapon/paper/contract/infernal/proc/FulfillContract(mob/living/carbon/human/user = target.current, blood = 0) /obj/item/weapon/paper/contract/infernal/proc/fulfillContract(mob/living/carbon/human/user = target.current, blood = FALSE)
signed = 1 signed = TRUE
if(user.mind.soulOwner != user.mind) //They already sold their soul to someone else? if(user.mind.soulOwner != user.mind) //They already sold their soul to someone else?
user.mind.soulOwner.devilinfo.remove_soul(user.mind) //Then they lose their claim. var/datum/antagonist/devil/ownerDevilInfo = user.mind.soulOwner.has_antag_datum(ANTAG_DATUM_DEVIL)
ownerDevilInfo.remove_soul(user.mind) //Then they lose their claim.
user.mind.soulOwner = owner user.mind.soulOwner = owner
user.hellbound = contractType user.hellbound = contractType
user.mind.damnation_type = contractType user.mind.damnation_type = contractType
owner.devilinfo.add_soul(user.mind) var/datum/antagonist/devil/devilInfo = owner.has_antag_datum(ANTAG_DATUM_DEVIL)
devilInfo.add_soul(user.mind)
update_text(user.real_name, blood) update_text(user.real_name, blood)
to_chat(user, "<span class='notice'>A profound emptiness washes over you as you lose ownership of your soul.</span>") to_chat(user, "<span class='notice'>A profound emptiness washes over you as you lose ownership of your soul.</span>")
to_chat(user, "<span class='boldnotice'>This does NOT make you an antagonist if you were not already.</span>") to_chat(user, "<span class='boldnotice'>This does NOT make you an antagonist if you were not already.</span>")
return 1 return TRUE
/obj/item/weapon/paper/contract/infernal/power/FulfillContract(mob/living/carbon/human/user = target.current, blood = 0) /obj/item/weapon/paper/contract/infernal/proc/signIncorrectly(mob/living/carbon/human/user = target.current, blood = FALSE)
signed = 1
update_text("your name", blood)
/obj/item/weapon/paper/contract/infernal/power/fulfillContract(mob/living/carbon/human/user = target.current, blood = FALSE)
if(!user.dna) if(!user.dna)
return -1 return -1
user.dna.add_mutation(HULK) user.dna.add_mutation(HULK)
@@ -254,13 +280,14 @@
organ.Insert(user) organ.Insert(user)
return ..() return ..()
/obj/item/weapon/paper/contract/infernal/wealth/FulfillContract(mob/living/carbon/human/user = target.current, blood = 0) /obj/item/weapon/paper/contract/infernal/wealth/fulfillContract(mob/living/carbon/human/user = target.current, blood = 0)
if(!istype(user) || !user.mind) // How in the hell could that happen? if(!istype(user) || !user.mind) // How in the hell could that happen?
return -1 return -1
user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_wealth(null)) user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_wealth(null))
return ..() return ..()
/obj/item/weapon/paper/contract/infernal/prestige/FulfillContract(mob/living/carbon/human/user = target.current, blood = 0) /obj/item/weapon/paper/contract/infernal/prestige/fulfillContract(mob/living/carbon/human/user = target.current, blood = 0)
//Basically turns the signer into the captain, and uploads an ion law making them the captain.
var/obj/item/worn = user.wear_id var/obj/item/worn = user.wear_id
var/obj/item/weapon/card/id/id = null var/obj/item/weapon/card/id/id = null
if(worn) if(worn)
@@ -292,16 +319,22 @@
return ..() return ..()
/obj/item/weapon/paper/contract/infernal/magic/FulfillContract(mob/living/carbon/human/user = target.current, blood = 0) /obj/item/weapon/paper/contract/infernal/magic/fulfillContract(mob/living/carbon/human/user = target.current, blood = 0)
if(!istype(user) || !user.mind) if(!istype(user) || !user.mind)
return -1 return -1
user.mind.AddSpell(new /obj/effect/proc_holder/spell/aimed/fireball(null)) user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/conjure_item/spellpacket/robeless(null))
user.mind.AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/knock(null)) user.mind.AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/knock(null))
return ..() return ..()
/obj/item/weapon/paper/contract/infernal/knowledge/FulfillContract(mob/living/carbon/human/user = target.current, blood = 0) /obj/item/weapon/paper/contract/infernal/knowledge/fulfillContract(mob/living/carbon/human/user = target.current, blood = 0)
if(!istype(user) || !user.mind) if(!istype(user) || !user.mind)
return -1 return -1
user.dna.add_mutation(XRAY) user.dna.add_mutation(XRAY)
user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/view_range(null)) user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/view_range(null))
return ..() return ..()
/obj/item/weapon/paper/contract/infernal/friend/fulfillContract(mob/living/user = target.current, blood = 0)
if(!istype(user) || !user.mind)
return -1
user.mind.AddSpell(new /obj/effect/proc_holder/spell/targeted/summon_friend(null))
return ..()

View File

@@ -52,7 +52,7 @@
user.put_in_hands(contract) user.put_in_hands(contract)
else else
var/obj/item/weapon/paper/contract/infernal/contract // = new(user.loc, C.mind, contractType, user.mind) var/obj/item/weapon/paper/contract/infernal/contract // = new(user.loc, C.mind, contractType, user.mind)
var/contractTypeName = input(user, "What type of contract?") in list ("Power", "Wealth", "Prestige", "Magic", "Knowledge") var/contractTypeName = input(user, "What type of contract?") in list ("Power", "Wealth", "Prestige", "Magic", "Knowledge", "Friendship")
switch(contractTypeName) switch(contractTypeName)
if("Power") if("Power")
contract = new /obj/item/weapon/paper/contract/infernal/power(C.loc, C.mind, user.mind) contract = new /obj/item/weapon/paper/contract/infernal/power(C.loc, C.mind, user.mind)
@@ -64,6 +64,8 @@
contract = new /obj/item/weapon/paper/contract/infernal/magic(C.loc, C.mind, user.mind) contract = new /obj/item/weapon/paper/contract/infernal/magic(C.loc, C.mind, user.mind)
if("Knowledge") if("Knowledge")
contract = new /obj/item/weapon/paper/contract/infernal/knowledge(C.loc, C.mind, user.mind) contract = new /obj/item/weapon/paper/contract/infernal/knowledge(C.loc, C.mind, user.mind)
if("Friendship")
contract = new /obj/item/weapon/paper/contract/infernal/friend(C.loc, C.mind, user.mind)
C.put_in_hands(contract) C.put_in_hands(contract)
else else
to_chat(user, "<span class='notice'>[C] seems to not be sentient. You cannot summon a contract for [C.p_them()].</span>") to_chat(user, "<span class='notice'>[C] seems to not be sentient. You cannot summon a contract for [C.p_them()].</span>")
@@ -106,7 +108,7 @@
continuing = 1 continuing = 1
else else
for(var/mob/living/C in orange(2, get_turf(user.loc))) //Can also phase in when nearby a potential buyer. for(var/mob/living/C in orange(2, get_turf(user.loc))) //Can also phase in when nearby a potential buyer.
if (C.mind && C.mind.soulOwner == C.mind) if (C.owns_soul())
continuing = 1 continuing = 1
break break
if(continuing) if(continuing)

View File

@@ -35,10 +35,39 @@
charge_max = 50 charge_max = 50
cooldown_min = 10 cooldown_min = 10
action_icon_state = "camera_jump" action_icon_state = "camera_jump"
var/ranges = list(7,8,9,10/*,11,12*/) var/ranges = list(7,8,9,10)
/obj/effect/proc_holder/spell/targeted/view_range/cast(list/targets, mob/user = usr) /obj/effect/proc_holder/spell/targeted/view_range/cast(list/targets, mob/user = usr)
for(var/mob/C in targets) for(var/mob/C in targets)
if(!C.client) if(!C.client)
continue continue
C.client.change_view(input("Select view range:", "Range", 4) in ranges) C.client.change_view(input("Select view range:", "Range", 4) in ranges)
/obj/effect/proc_holder/spell/targeted/summon_friend
name = "Summon Friend"
desc = "The reward for selling your soul."
invocation_type = "none"
include_user = 1
range = -1
clothes_req = 0
charge_max = 50
cooldown_min = 10
action_icon_state = "sacredflame"
var/mob/living/friend
var/obj/effect/mob_spawn/human/demonic_friend/friendShell
/obj/effect/proc_holder/spell/targeted/summon_friend/cast(list/targets, mob/user = usr)
if(!QDELETED(friend))
to_chat(friend, "<span class='userdanger'>Your master has deemed you a poor friend. Your durance in hell will now resume.</span>")
friend.dust(TRUE)
qdel(friendShell)
return
if(!QDELETED(friendShell))
qdel(friendShell)
return
for(var/C in targets)
var/mob/living/L = C
friendShell = new /obj/effect/mob_spawn/human/demonic_friend(L.loc, L.mind, src)
/obj/effect/proc_holder/spell/targeted/conjure_item/spellpacket/robeless
clothes_req = FALSE

View File

@@ -181,12 +181,13 @@
for(var/V in listeners) for(var/V in listeners)
var/mob/living/L = V var/mob/living/L = V
if(L.mind && L.mind.devilinfo && findtext(message, L.mind.devilinfo.truename)) var/datum/antagonist/devil/devilinfo = is_devil(L)
var/start = findtext(message, L.mind.devilinfo.truename) if(devilinfo && findtext(message, devilinfo.truename))
listeners = list(L) //let's be honest you're never going to find two devils with the same name var/start = findtext(message, devilinfo.truename)
listeners = list(L) //Devil names are unique.
power_multiplier *= 5 //if you're a devil and god himself addressed you, you fucked up power_multiplier *= 5 //if you're a devil and god himself addressed you, you fucked up
//Cut out the name so it doesn't trigger commands //Cut out the name so it doesn't trigger commands
message = copytext(message, 0, start)+copytext(message, start + length(L.mind.devilinfo.truename), length(message) + 1) message = copytext(message, 0, start)+copytext(message, start + length(devilinfo.truename), length(message) + 1)
break break
else if(dd_hasprefix(message, L.real_name)) else if(dd_hasprefix(message, L.real_name))
specific_listeners += L //focus on those with the specified name specific_listeners += L //focus on those with the specified name
@@ -362,8 +363,9 @@
cooldown = COOLDOWN_MEME cooldown = COOLDOWN_MEME
for(var/V in listeners) for(var/V in listeners)
var/mob/living/L = V var/mob/living/L = V
if(L.mind && L.mind.devilinfo) if(is_devil(L))
L.say("[L.mind.devilinfo.truename]") var/datum/antagonist/devil/devilinfo = is_devil(L)
L.say("[devilinfo.truename]")
else else
L.say("[L.real_name]") L.say("[L.real_name]")
sleep(5) //So the chat flows more naturally sleep(5) //So the chat flows more naturally

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,50 @@
<ui-display title='Codex Gigas'>
<ui-section>
{{data.name}}
</ui-section>
<ui-section label='Prefix'>
<ui-button state='{{data.currentSection == 1 ? null : "disabled"}}' action='Dark '>Dark</ui-button>
<ui-button state='{{data.currentSection == 1 ? null : "disabled"}}' action='Hellish '>Hellish</ui-button>
<ui-button state='{{data.currentSection == 1 ? null : "disabled"}}' action='Fallen '>Fallen</ui-button>
<ui-button state='{{data.currentSection == 1 ? null : "disabled"}}' action='Fiery '>Fiery</ui-button>
<ui-button state='{{data.currentSection == 1 ? null : "disabled"}}' action='Sinful '>Sinful</ui-button>
<ui-button state='{{data.currentSection == 1 ? null : "disabled"}}' action='Blood '>Blood</ui-button>
<ui-button state='{{data.currentSection == 1 ? null : "disabled"}}' action='Fluffy '>Fluffy</ui-button>
</ui-section>
<ui-section label='Title'>
<ui-button state='{{data.currentSection <= 2 ? null : "disabled"}}' action='Lord '>Lord</ui-button>
<ui-button state='{{data.currentSection <= 2 ? null : "disabled"}}' action='Prelate '>Prelate</ui-button>
<ui-button state='{{data.currentSection <= 2 ? null : "disabled"}}' action='Count '>Count</ui-button>
<ui-button state='{{data.currentSection <= 2 ? null : "disabled"}}' action='Viscount '>Viscount</ui-button>
<ui-button state='{{data.currentSection <= 2 ? null : "disabled"}}' action='Vizier '>Vizier</ui-button>
<ui-button state='{{data.currentSection <= 2 ? null : "disabled"}}' action='Elder '>Elder</ui-button>
<ui-button state='{{data.currentSection <= 2 ? null : "disabled"}}' action='Adept '>Adept</ui-button>
</ui-section>
<ui-section label='Name'>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='hal'>hal</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='ve'>ve</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='odr'>odr</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='neit'>neit</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='ci'>ci</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='quon'>quon</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='mya'>mya</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='folth'>folth</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='wren'>wren</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='geyr'>geyr</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='hil'>hil</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='niet'>niet</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='twou'>twou</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='phi'>phi</ui-button>
<ui-button state='{{data.currentSection <= 4 ? null : "disabled"}}' action='coa'>coa</ui-button>
</ui-section>
<ui-section label='suffix'>
<ui-button state='{{data.currentSection == 4 ? null : "disabled"}}' action=' the Red'>the Red</ui-button>
<ui-button state='{{data.currentSection == 4 ? null : "disabled"}}' action=' the Soulless'>the Soulless</ui-button>
<ui-button state='{{data.currentSection == 4 ? null : "disabled"}}' action=' the Master'>the Master</ui-button>
<ui-button state='{{data.currentSection == 4 ? null : "disabled"}}' action=', the Lord of all things'>the Lord of all things</ui-button>
<ui-button state='{{data.currentSection == 4 ? null : "disabled"}}' action=', Jr.'>jr</ui-button>
</ui-section>
<ui-section label ='submit'>
<ui-button state='{{data.currentSection >= 4 ? null : "disabled"}}' action='search'>search</ui-button>
<ui-section>
</ui-display>