Ports "Removes SSreligion"

This commit is contained in:
Ghommie
2019-06-23 01:45:21 +02:00
parent 2f96e40120
commit 38bc8a4efd
10 changed files with 39 additions and 42 deletions

View File

@@ -18,3 +18,12 @@ GLOBAL_LIST_EMPTY(powernets)
GLOBAL_VAR_INIT(bsa_unlock, FALSE) //BSA unlocked by head ID swipes
GLOBAL_LIST_EMPTY(player_details) // ckey -> /datum/player_details
// All religion stuff
GLOBAL_VAR(religion)
GLOBAL_VAR(deity)
GLOBAL_VAR(bible_name)
GLOBAL_VAR(bible_icon_state)
GLOBAL_VAR(bible_item_state)
GLOBAL_VAR(holy_weapon_type)
GLOBAL_VAR(holy_armor_type)

View File

@@ -1,11 +0,0 @@
SUBSYSTEM_DEF(religion)
name = "Religion"
flags = SS_NO_FIRE|SS_NO_INIT
var/religion
var/deity
var/bible_name
var/bible_icon_state
var/bible_item_state
var/holy_weapon_type
var/holy_armor_type

View File

@@ -58,7 +58,7 @@
item_state = "radio"
/obj/item/holybeacon/attack_self(mob/user)
if(user.mind && (user.mind.isholy) && !SSreligion.holy_armor_type)
if(user.mind && (user.mind.isholy) && !GLOB.holy_armor_type)
beacon_armor(user)
else
playsound(src, 'sound/machines/buzz-sigh.ogg', 40, 1)
@@ -71,13 +71,13 @@
display_names += list(initial(A.name) = A)
var/choice = input(M,"What holy armor kit would you like to order?","Holy Armor Theme") as null|anything in display_names
if(QDELETED(src) || !choice || M.stat || !in_range(M, src) || M.restrained() || !M.canmove || SSreligion.holy_armor_type)
if(QDELETED(src) || !choice || M.stat || !in_range(M, src) || M.restrained() || !M.canmove || GLOB.holy_armor_type)
return
var/index = display_names.Find(choice)
var/A = holy_armor_list[index]
SSreligion.holy_armor_type = A
GLOB.holy_armor_type = A
var/holy_armor_box = new A
SSblackbox.record_feedback("tally", "chaplain_armor", 1, "[choice]")
@@ -245,7 +245,7 @@
reskin_holy_weapon(user)
/obj/item/nullrod/proc/reskin_holy_weapon(mob/M)
if(SSreligion.holy_weapon_type)
if(GLOB.holy_weapon_type)
return
var/obj/item/nullrod/holy_weapon
var/list/holy_weapons_list = typesof(/obj/item/nullrod) + list(
@@ -264,7 +264,7 @@
var/A = display_names[choice] // This needs to be on a separate var as list member access is not allowed for new
holy_weapon = new A
SSreligion.holy_weapon_type = holy_weapon.type
GLOB.holy_weapon_type = holy_weapon.type
SSblackbox.record_feedback("tally", "chaplain_weapon", 1, "[choice]")

View File

@@ -51,7 +51,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "bible",
if(!istype(H))
return
// If H is the Chaplain, we can set the icon_state of the bible (but only once!)
if(!SSreligion.bible_icon_state && H.job == "Chaplain")
if(!GLOB.bible_icon_state && H.job == "Chaplain")
var/dat = "<html><head><title>Pick Bible Style</title></head><body><center><h2>Pick a bible style</h2></center><table>"
for(var/i in 1 to GLOB.biblestates.len)
var/icon/bibleicon = icon('icons/obj/storage.dmi', GLOB.biblestates[i])
@@ -64,7 +64,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "bible",
/obj/item/storage/book/bible/Topic(href, href_list)
if(!usr.canUseTopic(src))
return
if(href_list["seticon"] && SSreligion && !SSreligion.bible_icon_state)
if(href_list["seticon"] && GLOB && !GLOB.bible_icon_state)
var/iconi = text2num(href_list["seticon"])
var/biblename = GLOB.biblenames[iconi]
var/obj/item/storage/book/bible/B = locate(href_list["src"])
@@ -76,8 +76,8 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "bible",
H.dna.add_mutation(CLOWNMUT)
H.equip_to_slot_or_del(new /obj/item/clothing/mask/gas/clown_hat(H), SLOT_WEAR_MASK)
SSreligion.bible_icon_state = B.icon_state
SSreligion.bible_item_state = B.item_state
GLOB.bible_icon_state = B.icon_state
GLOB.bible_item_state = B.item_state
SSblackbox.record_feedback("text", "religion_book", 1, "[biblename]")
usr << browse(null, "window=editicon")

View File

@@ -25,8 +25,8 @@
cross.icon_state = "kingyellow"
font_color = "blue"
prayer_type = "CHAPLAIN PRAYER"
if(SSreligion.deity)
deity = SSreligion.deity
if(GLOB.deity)
deity = GLOB.deity
else if(iscultist(usr))
cross.icon_state = "tome"
font_color = "red"

View File

@@ -24,14 +24,14 @@ Chaplain
var/obj/item/storage/book/bible/booze/B = new
if(SSreligion.religion)
B.deity_name = SSreligion.deity
B.name = SSreligion.bible_name
B.icon_state = SSreligion.bible_icon_state
B.item_state = SSreligion.bible_item_state
to_chat(H, "There is already an established religion onboard the station. You are an acolyte of [SSreligion.deity]. Defer to the Chaplain.")
if(GLOB.religion)
B.deity_name = GLOB.deity
B.name = GLOB.bible_name
B.icon_state = GLOB.bible_icon_state
B.item_state = GLOB.bible_item_state
to_chat(H, "There is already an established religion onboard the station. You are an acolyte of [GLOB.deity]. Defer to the Chaplain.")
H.equip_to_slot_or_del(B, SLOT_IN_BACKPACK)
var/nrt = SSreligion.holy_weapon_type || /obj/item/nullrod
var/nrt = GLOB.holy_weapon_type || /obj/item/nullrod
var/obj/item/nullrod/N = new nrt(H)
H.put_in_hands(N)
return
@@ -74,9 +74,9 @@ Chaplain
else
B.name = "The Holy Book of [new_religion]"
SSreligion.religion = new_religion
SSreligion.bible_name = B.name
SSreligion.deity = B.deity_name
GLOB.religion = new_religion
GLOB.bible_name = B.name
GLOB.deity = B.deity_name
H.equip_to_slot_or_del(B, SLOT_IN_BACKPACK)

View File

@@ -485,11 +485,11 @@ GLOBAL_LIST(cachedbooks) // List of our cached book datums
if(href_list["printbible"])
if(cooldown < world.time)
var/obj/item/storage/book/bible/B = new /obj/item/storage/book/bible(src.loc)
if(SSreligion.bible_icon_state && SSreligion.bible_item_state)
B.icon_state = SSreligion.bible_icon_state
B.item_state = SSreligion.bible_item_state
B.name = SSreligion.bible_name
B.deity_name = SSreligion.deity
if(GLOB.bible_icon_state && GLOB.bible_item_state)
B.icon_state = GLOB.bible_icon_state
B.item_state = GLOB.bible_item_state
B.name = GLOB.bible_name
B.deity_name = GLOB.deity
cooldown = world.time + PRINTER_COOLDOWN
else
say("Printer currently unavailable, please wait a moment.")

View File

@@ -64,8 +64,8 @@
strengthdiv = 8
for(var/mob/living/simple_animal/revenant/R in get_hearers_in_view(7,get_turf(holder.my_atom)))
var/deity
if(SSreligion.deity)
deity = SSreligion.deity
if(GLOB.deity)
deity = GLOB.deity
else
deity = "Christ"
to_chat(R, "<span class='userdanger'>The power of [deity] compels you!</span>")

View File

@@ -11,8 +11,8 @@
/obj/item/nullrod/rosary/Initialize()
.=..()
if(SSreligion.religion)
deity_name = SSreligion.deity
if(GLOB.religion)
deity_name = GLOB.deity
/obj/item/nullrod/rosary/attack(mob/living/carbon/M as mob, mob/living/carbon/user as mob)
if(!istype(M))

View File

@@ -256,7 +256,6 @@
#include "code\controllers\subsystem\ping.dm"
#include "code\controllers\subsystem\radiation.dm"
#include "code\controllers\subsystem\radio.dm"
#include "code\controllers\subsystem\religion.dm"
#include "code\controllers\subsystem\research.dm"
#include "code\controllers\subsystem\server_maint.dm"
#include "code\controllers\subsystem\shuttle.dm"