mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
[BOUNTY] Holy Light sect, dedicated to healing (#17924)
* you defy the light * revive and be less bad flavor * Update code/modules/religion/religion_sects.dm Co-authored-by: Molti <108117184+Moltijoe@users.noreply.github.com> --------- Co-authored-by: Molti <108117184+Moltijoe@users.noreply.github.com>
This commit is contained in:
@@ -391,6 +391,11 @@
|
||||
alert_type = null
|
||||
var/hand
|
||||
var/deathTick = 0
|
||||
var/efficiency = 1
|
||||
|
||||
/datum/status_effect/hippocraticOath/on_creation(mob/living/new_owner, _efficiency)
|
||||
efficiency = _efficiency
|
||||
. = ..()
|
||||
|
||||
/datum/status_effect/hippocraticOath/on_apply()
|
||||
//Makes the user passive, it's in their oath not to harm!
|
||||
@@ -426,8 +431,9 @@
|
||||
if(iscarbon(owner))
|
||||
var/mob/living/carbon/itemUser = owner
|
||||
var/obj/item/heldItem = itemUser.get_item_for_held_index(hand)
|
||||
if(heldItem == null || heldItem.type != /obj/item/rod_of_asclepius) //Checks to make sure the rod is still in their hand
|
||||
if(heldItem == null || !istype(heldItem, /obj/item/rod_of_asclepius)) //Checks to make sure the rod is still in their hand
|
||||
var/obj/item/rod_of_asclepius/newRod = new(itemUser.loc)
|
||||
newRod.efficiency = efficiency
|
||||
newRod.activated()
|
||||
if(!itemUser.has_hand_for_held_index(hand))
|
||||
//If user does not have the corresponding hand anymore, give them one and return the rod to their hand
|
||||
@@ -447,31 +453,31 @@
|
||||
//Because a servant of medicines stops at nothing to help others, lets keep them on their toes and give them an additional boost.
|
||||
if(itemUser.health < itemUser.maxHealth)
|
||||
new /obj/effect/temp_visual/heal(get_turf(itemUser), "#375637")
|
||||
itemUser.adjustBruteLoss(-1.5)
|
||||
itemUser.adjustFireLoss(-1.5)
|
||||
itemUser.adjustToxLoss(-1.5, forced = TRUE) //Because Slime People are people too
|
||||
itemUser.adjustOxyLoss(-1.5)
|
||||
itemUser.adjustStaminaLoss(-1.5)
|
||||
itemUser.adjustOrganLoss(ORGAN_SLOT_BRAIN, -1.5)
|
||||
itemUser.adjustCloneLoss(-0.5) //Becasue apparently clone damage is the bastion of all health
|
||||
itemUser.adjustBruteLoss(-1.5 * efficiency)
|
||||
itemUser.adjustFireLoss(-1.5 * efficiency)
|
||||
itemUser.adjustToxLoss(-1.5 * efficiency, forced = TRUE) //Because Slime People are people too
|
||||
itemUser.adjustOxyLoss(-1.5 * efficiency)
|
||||
itemUser.adjustStaminaLoss(-1.5 * efficiency)
|
||||
itemUser.adjustOrganLoss(ORGAN_SLOT_BRAIN, -1.5 * efficiency)
|
||||
itemUser.adjustCloneLoss(-0.5 * efficiency) //Becasue apparently clone damage is the bastion of all health
|
||||
//Heal all those around you, unbiased
|
||||
for(var/mob/living/L in view(7, owner))
|
||||
if(L.health < L.maxHealth)
|
||||
new /obj/effect/temp_visual/heal(get_turf(L), "#375637")
|
||||
if(iscarbon(L))
|
||||
L.adjustBruteLoss(-3.5)
|
||||
L.adjustFireLoss(-3.5)
|
||||
L.adjustToxLoss(-3.5, forced = TRUE) //Because Slime People are people too
|
||||
L.adjustOxyLoss(-3.5)
|
||||
L.adjustStaminaLoss(-3.5)
|
||||
L.adjustOrganLoss(ORGAN_SLOT_BRAIN, -3.5)
|
||||
L.adjustCloneLoss(-1) //Becasue apparently clone damage is the bastion of all health
|
||||
L.adjustBruteLoss(-3.5 * efficiency)
|
||||
L.adjustFireLoss(-3.5 * efficiency)
|
||||
L.adjustToxLoss(-3.5 * efficiency, forced = TRUE) //Because Slime People are people too
|
||||
L.adjustOxyLoss(-3.5 * efficiency)
|
||||
L.adjustStaminaLoss(-3.5 * efficiency)
|
||||
L.adjustOrganLoss(ORGAN_SLOT_BRAIN, -3.5 * efficiency)
|
||||
L.adjustCloneLoss(-1 * efficiency) //Becasue apparently clone damage is the bastion of all health
|
||||
else if(issilicon(L))
|
||||
L.adjustBruteLoss(-3.5)
|
||||
L.adjustFireLoss(-3.5)
|
||||
L.adjustBruteLoss(-3.5 * efficiency)
|
||||
L.adjustFireLoss(-3.5 * efficiency)
|
||||
else if(isanimal(L))
|
||||
var/mob/living/simple_animal/SM = L
|
||||
SM.adjustHealth(-3.5, forced = TRUE)
|
||||
SM.adjustHealth(-3.5 * efficiency, forced = TRUE)
|
||||
|
||||
/datum/status_effect/good_music
|
||||
id = "Good Music"
|
||||
|
||||
@@ -40,6 +40,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "burning",
|
||||
var/mob/affecting = null
|
||||
var/deity_name = "Christ"
|
||||
force_string = "holy"
|
||||
var/success_heal_chance = 60
|
||||
|
||||
/obj/item/storage/book/bible/Initialize()
|
||||
. = ..()
|
||||
@@ -124,7 +125,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "burning",
|
||||
to_chat(user, span_warning("You don't have the dexterity to do this!"))
|
||||
return
|
||||
|
||||
if (HAS_TRAIT(user, TRAIT_CLUMSY) && prob(50))
|
||||
if (HAS_TRAIT(user, TRAIT_CLUMSY) && prob(success_heal_chance))
|
||||
to_chat(user, span_danger("[src] slips out of your hand and hits your head."))
|
||||
user.take_bodypart_damage(10)
|
||||
user.Unconscious(400)
|
||||
@@ -149,7 +150,7 @@ GLOBAL_LIST_INIT(bibleitemstates, list("bible", "koran", "scrapbook", "burning",
|
||||
to_chat(user, span_warning("You can't heal yourself!"))
|
||||
return
|
||||
|
||||
if(prob(60) && bless(M, user))
|
||||
if(prob(success_heal_chance) && bless(M, user))
|
||||
smack = 0
|
||||
else if(iscarbon(M))
|
||||
var/mob/living/carbon/C = M
|
||||
|
||||
@@ -96,6 +96,7 @@ GLOBAL_LIST_EMPTY(aide_list)
|
||||
var/activated = FALSE
|
||||
var/usedHand
|
||||
var/list/advanced_surgeries = list()
|
||||
var/efficiency = 1
|
||||
|
||||
/obj/item/rod_of_asclepius/attack_self(mob/user)
|
||||
if(activated)
|
||||
@@ -131,7 +132,7 @@ GLOBAL_LIST_EMPTY(aide_list)
|
||||
to_chat(itemUser, failText)
|
||||
return
|
||||
to_chat(itemUser, span_notice("The snake, satisfied with your oath, attaches itself and the rod to your forearm with an inseparable grip. Your thoughts seem to only revolve around the core idea of helping others, and harm is nothing more than a distant, wicked memory..."))
|
||||
var/datum/status_effect/hippocraticOath/effect = itemUser.apply_status_effect(STATUS_EFFECT_HIPPOCRATIC_OATH)
|
||||
var/datum/status_effect/hippocraticOath/effect = itemUser.apply_status_effect(STATUS_EFFECT_HIPPOCRATIC_OATH, efficiency)
|
||||
effect.hand = usedHand
|
||||
activated()
|
||||
|
||||
|
||||
@@ -424,3 +424,45 @@
|
||||
to_chat(user, span_notice("HONK"))
|
||||
qdel(offering)
|
||||
return
|
||||
|
||||
///////////// Sect of the Holy Light /////////////
|
||||
/datum/religion_sect/holylight
|
||||
name = "Holy Light"
|
||||
desc = "A sect dedicated to healing."
|
||||
convert_opener = "Welcome to the Holy Light, disciple. Heal others to gain favor."
|
||||
alignment = ALIGNMENT_GOOD // literally the only good sect besides default lol
|
||||
rites_list = list(/datum/religion_rites/medibot, /datum/religion_rites/holysight, /datum/religion_rites/healrod, /datum/religion_rites/holyrevival)
|
||||
altar_icon_state = "convertaltar-heal"
|
||||
COOLDOWN_DECLARE(last_heal)
|
||||
|
||||
/datum/religion_sect/holylight/on_conversion(mob/living/L)
|
||||
. = ..()
|
||||
for(var/obj/item/storage/book/bible/da_bible in L.GetAllContents())
|
||||
da_bible.success_heal_chance = 80
|
||||
|
||||
/datum/religion_sect/holylight/sect_bless(mob/living/L, mob/living/user)
|
||||
if(!ishuman(L))
|
||||
return FALSE
|
||||
|
||||
if(!COOLDOWN_FINISHED(src, last_heal)) // immersion broken
|
||||
user.visible_message(span_notice("The Holy Light has exhausted its power. It may heal again in [(COOLDOWN_TIMELEFT(src, last_heal))/10] seconds."))
|
||||
return FALSE
|
||||
COOLDOWN_START(src, last_heal, 12 SECONDS)
|
||||
|
||||
var/mob/living/carbon/human/H = L
|
||||
var/heal_amt = 20
|
||||
var/list/hurt_limbs = H.get_damaged_bodyparts(1, 1, null, BODYPART_ANY)
|
||||
if(hurt_limbs.len)
|
||||
var/amount_healed = 0
|
||||
for(var/X in hurt_limbs)
|
||||
var/obj/item/bodypart/affecting = X
|
||||
amount_healed += (heal_amt * 2) + min(affecting.brute_dam - heal_amt, 0) + min(affecting.burn_dam - heal_amt, 0)
|
||||
if(affecting.heal_damage(heal_amt, heal_amt, null, BODYPART_ANY))
|
||||
H.update_damage_overlays()
|
||||
adjust_favor(amount_healed, user)
|
||||
H.visible_message(span_notice("[user] heals [H] with the power of [GLOB.deity]!"))
|
||||
to_chat(H, span_boldnotice("May the power of [GLOB.deity] compel you to be healed!"))
|
||||
playsound(user, 'sound/magic/staff_healing.ogg', 25, TRUE, -1)
|
||||
SEND_SIGNAL(H, COMSIG_ADD_MOOD_EVENT, "blessing", /datum/mood_event/blessing)
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
@@ -573,3 +573,122 @@
|
||||
new /obj/item/stack/sheet/mineral/bananium (altar_turf)
|
||||
playsound(altar_turf, 'sound/items/bikehorn.ogg', 50, TRUE)
|
||||
return TRUE
|
||||
|
||||
/*********Holy Light**********/
|
||||
/datum/religion_rites/medibot
|
||||
name = "Angelic Assistance"
|
||||
desc = "Creates a medibot."
|
||||
ritual_length = 15 SECONDS
|
||||
ritual_invocations = list(
|
||||
"To prolong healing far past even my expiration...",
|
||||
"...Automated, soulless, but efficient...",
|
||||
"...Grant us this sustaining robot...",
|
||||
)
|
||||
invoke_msg = "So that we may live forever!"
|
||||
favor_cost = 150
|
||||
|
||||
/datum/religion_rites/medibot/invoke_effect(mob/living/user, atom/movable/religious_tool)
|
||||
var/altar_turf = get_turf(religious_tool)
|
||||
var/atom/newitem = new /mob/living/simple_animal/bot/medbot (altar_turf)
|
||||
newitem.name = "\improper Holy Medibot"
|
||||
playsound(altar_turf, 'sound/magic/staff_healing.ogg', 50, TRUE)
|
||||
return TRUE
|
||||
|
||||
/datum/religion_rites/holysight
|
||||
name = "Holy Sight"
|
||||
desc = "Creates a medhud implant."
|
||||
ritual_length = 15 SECONDS
|
||||
ritual_invocations = list(
|
||||
"To aid in our journey to heal...",
|
||||
"...Grant us the ability to see within...",
|
||||
)
|
||||
invoke_msg = "So that we may seek the injured!"
|
||||
favor_cost = 250
|
||||
|
||||
/datum/religion_rites/holysight/invoke_effect(mob/living/user, atom/movable/religious_tool)
|
||||
var/altar_turf = get_turf(religious_tool)
|
||||
var/atom/newitem = new /obj/item/autosurgeon/cmo (altar_turf)
|
||||
newitem.name = "autosurgeon of truesight"
|
||||
playsound(altar_turf, 'sound/magic/staff_healing.ogg', 50, TRUE)
|
||||
return TRUE
|
||||
|
||||
/datum/religion_rites/healrod
|
||||
name = "The White"
|
||||
desc = "Creates an area-of-effect healing rod."
|
||||
ritual_length = 20 SECONDS
|
||||
ritual_invocations = list(
|
||||
"To ensure all remain healthy...",
|
||||
"...Grant us a tool capable of passively healing the injured...",
|
||||
"...One that binds us to an unbreakable contract of pacifism..."
|
||||
)
|
||||
invoke_msg = "So that we may heal all indiscriminately!"
|
||||
favor_cost = 400
|
||||
|
||||
/obj/item/rod_of_asclepius/white
|
||||
name = "\improper Rod of The White"
|
||||
desc = "A sleek white rod with a snake spiraling along it."
|
||||
efficiency = 0.5
|
||||
|
||||
/obj/item/rod_of_asclepius/white/Initialize()
|
||||
. = ..()
|
||||
add_atom_colour(GLOB.freon_color_matrix, TEMPORARY_COLOUR_PRIORITY)
|
||||
|
||||
/datum/religion_rites/healrod/invoke_effect(mob/living/user, atom/movable/religious_tool)
|
||||
var/altar_turf = get_turf(religious_tool)
|
||||
new /obj/item/rod_of_asclepius/white (altar_turf)
|
||||
playsound(altar_turf, 'sound/magic/staff_healing.ogg', 75, TRUE)
|
||||
return TRUE
|
||||
|
||||
/datum/religion_rites/holyrevival
|
||||
name = "Rebirth"
|
||||
desc = "Regenerates a being to its once pure state."
|
||||
ritual_length = 60 SECONDS
|
||||
ritual_invocations = list(
|
||||
"This being is in dire need of your assistance...",
|
||||
"...As they have been inflicted with great ailment...",
|
||||
"...Please, grant us the unbridled power of the Holy Light...",
|
||||
"...We will channel our power in your name...",
|
||||
)
|
||||
invoke_msg = "So that this being may be reborn in your image!"
|
||||
favor_cost = 650
|
||||
|
||||
/datum/religion_rites/holyrevival/perform_rite(mob/living/user, atom/religious_tool)
|
||||
if(!ismovable(religious_tool))
|
||||
to_chat(user, span_warning("This rite requires a religious device that individuals can be buckled to."))
|
||||
return FALSE
|
||||
var/atom/movable/movable_reltool = religious_tool
|
||||
if(!movable_reltool)
|
||||
return FALSE
|
||||
if(!LAZYLEN(movable_reltool.buckled_mobs))
|
||||
. = FALSE
|
||||
if(!movable_reltool.can_buckle)
|
||||
to_chat(user, span_warning("This rite requires a religious device that individuals can be buckled to."))
|
||||
return
|
||||
to_chat(user, span_warning("This rite requires an individual to be buckled to [movable_reltool]."))
|
||||
return
|
||||
return ..()
|
||||
|
||||
/datum/religion_rites/holyrevival/invoke_effect(mob/living/user, atom/movable/religious_tool)
|
||||
if(!ismovable(religious_tool))
|
||||
CRASH("[name]'s perform_rite had a movable atom that has somehow turned into a non-movable!")
|
||||
var/atom/movable/movable_reltool = religious_tool
|
||||
if(!movable_reltool?.buckled_mobs?.len)
|
||||
return FALSE
|
||||
var/mob/living/carbon/human/man_to_revive
|
||||
for(var/i in movable_reltool.buckled_mobs)
|
||||
if(istype(i,/mob/living/carbon/human))
|
||||
man_to_revive = i
|
||||
break
|
||||
if(!man_to_revive)
|
||||
return FALSE
|
||||
var/was_dead = man_to_revive.stat == DEAD
|
||||
man_to_revive.revive(TRUE)
|
||||
if(was_dead) // aheal needs downside
|
||||
man_to_revive.adjustCloneLoss(75) // can be slowly healed with the rod of asclepius anyways
|
||||
man_to_revive.add_atom_colour(GLOB.freon_color_matrix, TEMPORARY_COLOUR_PRIORITY)
|
||||
to_chat(man_to_revive, span_userdanger("As you rise anew, you forget all that had previously harmed you!"))
|
||||
man_to_revive.emote("smile")
|
||||
man_to_revive.visible_message(span_notice("[man_to_revive] rises, reborn in the Holy Light!"))
|
||||
var/altar_turf = get_turf(religious_tool)
|
||||
playsound(altar_turf, 'sound/magic/staff_healing.ogg', 100, TRUE)
|
||||
return TRUE
|
||||
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 25 KiB After Width: | Height: | Size: 26 KiB |
Reference in New Issue
Block a user