mirror of
https://github.com/Bubberstation/Bubberstation.git
synced 2025-12-27 10:02:12 +00:00
* Allows admins to overrule God (#78429) ## About The Pull Request Adds a "manage religious sect" verb to the "game" menu of the admin panel. It can be used to assign the chaplain's sect if they haven't picked one yet, or reassign it (to a different one, or to nothing) if they already have. This is likely mostly going to be used for ahelps where someone misclicks or suddenly logs off and wants to be replaced by a different chaplain with different ideas. ## Why It's Good For The Game Admins asked me to make it ## Changelog 🆑 admin: Admins can now reset or modify the chaplain's sect from a UI panel /🆑 * Allows admins to overrule God * Updates modular to use the reset signal for nulling the altars instead --------- Co-authored-by: Jacquerel <hnevard@gmail.com> Co-authored-by: Giz <13398309+vinylspiders@users.noreply.github.com>
51 lines
1.3 KiB
Plaintext
51 lines
1.3 KiB
Plaintext
// All religion stuff
|
|
GLOBAL_VAR(religion)
|
|
GLOBAL_VAR(deity)
|
|
GLOBAL_DATUM(religious_sect, /datum/religion_sect)
|
|
|
|
//bible
|
|
GLOBAL_VAR(bible_name)
|
|
GLOBAL_VAR(bible_icon_state)
|
|
GLOBAL_VAR(bible_inhand_icon_state)
|
|
|
|
//altar
|
|
GLOBAL_LIST_EMPTY(chaplain_altars)
|
|
|
|
//gear
|
|
GLOBAL_VAR(holy_weapon_type)
|
|
GLOBAL_VAR(holy_armor_type)
|
|
|
|
/// Sets a new religious sect used by all chaplains int he round
|
|
/proc/set_new_religious_sect(path, reset_existing = FALSE)
|
|
if(!ispath(path, /datum/religion_sect))
|
|
message_admins("[ADMIN_LOOKUPFLW(usr)] has tried to spawn an item when selecting a sect.")
|
|
return
|
|
|
|
if(!isnull(GLOB.religious_sect))
|
|
if (!reset_existing)
|
|
return
|
|
reset_religious_sect()
|
|
|
|
GLOB.religious_sect = new path()
|
|
for(var/i in GLOB.player_list)
|
|
if(!isliving(i))
|
|
continue
|
|
var/mob/living/am_i_holy_living = i
|
|
if(!am_i_holy_living.mind?.holy_role)
|
|
continue
|
|
GLOB.religious_sect.on_conversion(am_i_holy_living)
|
|
SEND_GLOBAL_SIGNAL(COMSIG_RELIGIOUS_SECT_CHANGED)
|
|
|
|
/// Removes any existing religious sect from chaplains, allowing another to be selected
|
|
/proc/reset_religious_sect()
|
|
for(var/i in GLOB.player_list)
|
|
if(!isliving(i))
|
|
continue
|
|
var/mob/living/am_i_holy_living = i
|
|
if(!am_i_holy_living.mind?.holy_role)
|
|
continue
|
|
GLOB.religious_sect.on_deconversion(am_i_holy_living)
|
|
|
|
GLOB.religious_sect = null
|
|
SEND_GLOBAL_SIGNAL(COMSIG_RELIGIOUS_SECT_RESET)
|