Merge pull request #5702 from Citadel-Station-13/upstream-merge-35639

[MIRROR] Refactors anti-magic into a component
This commit is contained in:
LetterJay
2018-02-25 16:59:38 -06:00
committed by GitHub
42 changed files with 378 additions and 128 deletions
+4
View File
@@ -13,6 +13,10 @@
obj_flags = UNIQUE_RENAME
var/reskinned = FALSE
/obj/item/nullrod/Initialize()
. = ..()
AddComponent(/datum/component/anti_magic, TRUE, TRUE)
/obj/item/nullrod/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] is killing [user.p_them()]self with [src]! It looks like [user.p_theyre()] trying to get closer to god!</span>")
return (BRUTELOSS|FIRELOSS)
+10
View File
@@ -17,6 +17,12 @@ GLOBAL_LIST_INIT(biblenames, list("Bible", "Quran", "Scrapbook", "Burning Bible"
GLOBAL_LIST_INIT(biblestates, list("bible", "koran", "scrapbook", "burning", "honk1", "honk2", "creeper", "white", "holylight", "atheist", "tome", "kingyellow", "ithaqua", "scientology", "melted", "necronomicon"))
GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "bible", "bible", "bible", "syringe_kit", "syringe_kit", "syringe_kit", "syringe_kit", "syringe_kit", "kingyellow", "ithaqua", "scientology", "melted", "necronomicon"))
/mob/proc/bible_check() //The bible, if held, might protect against certain things
var/obj/item/storage/book/bible/B = locate() in src
if(is_holding(B))
return B
return 0
/obj/item/storage/book/bible
name = "bible"
desc = "Apply to head repeatedly."
@@ -29,6 +35,10 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "bible",
var/deity_name = "Christ"
force_string = "holy"
/obj/item/storage/book/bible/Initialize()
. = ..()
AddComponent(/datum/component/anti_magic, FALSE, TRUE)
/obj/item/storage/book/bible/suicide_act(mob/user)
user.visible_message("<span class='suicide'>[user] is offering [user.p_them()]self to [deity_name]! It looks like [user.p_theyre()] trying to commit suicide!</span>")
return (BRUTELOSS)