mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-07-20 04:17:33 +01:00
Psi Rework Part 2: Scenes From A Memory (#21736)
The next step in the Psi Reworks is here, this time adding all of the remaining sources and applications of Psi-sensitivity and Psi-protection that were on my To-Do list. Aside from a variety of tweaks and bugfixes to powers, the most player-facing addition is the new Psi-sensitivity related traits, which are High Psi-sensitivity, and Low Psi-sensitivity. These traits modify the character's psi-sensitivity, which messes with their interactions with psionics in a variety of ways. All of these new sources and interactions with psionics are handled entirely through components, which operate on the previously added COMSIG_PSI signals. Check the changelog file for more specific details on what all was fixed. I've fixed quite a lot of bugs and issues with the various psi powers. I have actually tested this PR and verified that it works as advertised. <img width="1902" height="1015" alt="image" src="https://github.com/user-attachments/assets/e922593c-0595-4b63-bee4-36080d9cb8b4" />
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
name = "assay"
|
||||
desc = "Read someone's psionic potential."
|
||||
icon_state = "generic"
|
||||
item_icons = null
|
||||
cast_methods = CAST_MELEE|CAST_INNATE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 10
|
||||
@@ -53,7 +54,7 @@
|
||||
to_chat(user, SPAN_WARNING("Psionic power does not flow through a dead person."))
|
||||
return
|
||||
|
||||
var/psi_blocked = target.is_psi_blocked(user)
|
||||
var/psi_blocked = target.is_psi_blocked(user, FALSE)
|
||||
if(psi_blocked)
|
||||
to_chat(user, psi_blocked)
|
||||
return
|
||||
@@ -61,20 +62,14 @@
|
||||
user.visible_message(SPAN_NOTICE("[user] lays both [user.get_pronoun("his")] palms on [target]'s temples..."),
|
||||
SPAN_NOTICE("You lay your palms on [target]'s temples and begin tracing their Nlom signature..."))
|
||||
if(do_mob(user, target, 4 SECONDS))
|
||||
if(!target.psi)
|
||||
to_chat(user, SPAN_NOTICE("[target] is psionically perceptive, but nothing more: [target.get_pronoun("he")] cannot manipulate the fabric that weaves \
|
||||
this universe."))
|
||||
if(target.psi)
|
||||
switch(target.psi.get_rank())
|
||||
if(PSI_RANK_SENSITIVE)
|
||||
to_chat(user, SPAN_NOTICE("[target] is psionically sensitive, just like your typical Skrell. They can manipulate psionics, but not to a very \
|
||||
precise degree."))
|
||||
if(PSI_RANK_HARMONIOUS)
|
||||
to_chat(user, SPAN_WARNING("[target] is psionically harmonious. This isn't a feat just about anyone can manage: only those born with a certain \
|
||||
psionic attitude among Skrell can reach this level, and with strenuous training. They are capable of using psionics \
|
||||
with very fine precision."))
|
||||
if(PSI_RANK_APEX)
|
||||
to_chat(user, SPAN_DANGER("Your psionic power is dwarfed by [target]. Just like a supernova in the night sky, their signature is absolutely brilliant \
|
||||
beyond comprehension. This is the apex of psionic power, you are sure."))
|
||||
if(PSI_RANK_LIMITLESS)
|
||||
to_chat(user, SPAN_DANGER("A psionic power like this shouldn't be possible... what in the Stars is going on?"))
|
||||
var/target_psi_sensitivity = target.check_psi_sensitivity()
|
||||
|
||||
// Not using a switch case here because I need finer control of the domain than is permitted by TO statements.
|
||||
if (target_psi_sensitivity < 0)
|
||||
to_chat(user, SPAN_NOTICE("[target] has little to no ability to sense the fabric that weaves this universe."))
|
||||
else if (target_psi_sensitivity < PSI_RANK_SENSITIVE)
|
||||
to_chat(user, SPAN_NOTICE("[target] has only a limited perception of psionic signals, like a typical human. They can hear psionics, but have limited ability to interpret them."))
|
||||
else if (target_psi_sensitivity < PSI_RANK_HARMONIOUS)
|
||||
to_chat(user, SPAN_NOTICE("[target] is psionically sensitive, just like your typical skrell. They are capable of interpreting telepathic signals."))
|
||||
else
|
||||
to_chat(user, SPAN_NOTICE("[target] is exceptionally capable of handling and interpreting psionic messages, doing so trivially and intuitively."))
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
/obj/item/spell/barrier
|
||||
name = "psionic barrier"
|
||||
icon_state = "generic"
|
||||
item_icons = null
|
||||
cast_methods = CAST_USE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 20
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
/obj/item/spell/charge
|
||||
name = "charge"
|
||||
icon_state = "audible_deception"
|
||||
item_icons = null
|
||||
cast_methods = CAST_USE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 5
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "commune"
|
||||
desc = "Déjà-vu."
|
||||
icon_state = "overload"
|
||||
item_icons = null
|
||||
cast_methods = CAST_RANGED|CAST_MELEE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 10
|
||||
@@ -36,12 +37,11 @@
|
||||
to_chat(user, SPAN_WARNING("Not even a psion of your level can speak to the dead."))
|
||||
return
|
||||
|
||||
var/psi_blocked = target.is_psi_blocked(user)
|
||||
var/psi_blocked = target.is_psi_blocked(user, FALSE)
|
||||
if(psi_blocked)
|
||||
to_chat(user, psi_blocked)
|
||||
return
|
||||
|
||||
user.visible_message(SPAN_NOTICE("<i>[user] blinks, their eyes briefly developing an unnatural shine.</i>"))
|
||||
var/text = tgui_input_text(user, "What would you like to say?", "Commune", "", MAX_MESSAGE_LEN, TRUE)
|
||||
if(!text)
|
||||
return
|
||||
@@ -62,7 +62,16 @@
|
||||
to_chat(M, "<span class='notice'>[user] psionically says to [target]:</span> [text]")
|
||||
|
||||
var/mob/living/carbon/human/H = target
|
||||
if(H.check_psi_sensitivity() >= 1)
|
||||
var/target_sensitivity = H.check_psi_sensitivity()
|
||||
if(target_sensitivity >= 1)
|
||||
// Augmented case for anyone with enhancements to their psi-sensitivity.
|
||||
to_chat(H, SPAN_NOTICE("<i>[user] blinks, their eyes briefly developing an unnatural shine.</i>"))
|
||||
to_chat(H, SPAN_CULT("<b>You instinctively sense [user] passing a thought into your mind:</b> [text]"))
|
||||
else
|
||||
else if (target_sensitivity >= 0)
|
||||
// Standard case for most characters.
|
||||
to_chat(H, SPAN_ALIEN("<b>A thought from outside your consciousness slips into your mind:</b> [text]"))
|
||||
else
|
||||
// Negative sensitivity case, message arrives scrambled.
|
||||
// 25% of the message is scrambled per negative point of psi-sensitivity. Allowing fractional points.
|
||||
var/scrambled_message = stars(text, (abs(target_sensitivity) * 25))
|
||||
to_chat(H, SPAN_ALIEN("<b>A half-formed thought passes through your mind:</b> [scrambled_message]"))
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
/obj/item/spell/electrocute
|
||||
name = "electrocute"
|
||||
icon_state = "chain_lightning"
|
||||
item_icons = null
|
||||
cast_methods = CAST_MELEE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 10
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
name = "emotional suggestion"
|
||||
desc = "Suggest an emotion to someone."
|
||||
icon_state = "generic"
|
||||
item_icons = null
|
||||
cast_methods = CAST_RANGED|CAST_MELEE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 10
|
||||
@@ -35,12 +36,11 @@
|
||||
to_chat(user, SPAN_WARNING("Not even a psion of your level can suggest to the dead."))
|
||||
return
|
||||
|
||||
var/psi_blocked = target.is_psi_blocked(user)
|
||||
var/psi_blocked = target.is_psi_blocked(user, FALSE)
|
||||
if(psi_blocked)
|
||||
to_chat(user, psi_blocked)
|
||||
return
|
||||
|
||||
user.visible_message(SPAN_NOTICE("<i>[user] blinks, their eyes briefly developing an unnatural shine.</i>"))
|
||||
var/text = tgui_input_list(user, "Which emotion would you like to suggest?", "Emotional Suggestion", list("Calm", "Happiness", "Sadness", "Fear", "Anger", "Stress", "Confusion"))
|
||||
if(!text)
|
||||
return
|
||||
@@ -62,7 +62,16 @@
|
||||
to_chat(M, "<span class='notice'>[user] psionically suggests an emotion to [target]:</span> [text]")
|
||||
|
||||
var/mob/living/carbon/human/H = target
|
||||
if(H.check_psi_sensitivity() > 0)
|
||||
var/target_sensitivity = H.check_psi_sensitivity()
|
||||
if(target_sensitivity >= 1)
|
||||
// Augmented case for anyone with enhancements to their psi-sensitivity
|
||||
to_chat(H, SPAN_NOTICE("<i>[user] blinks, their eyes briefly developing an unnatural shine.</i>"))
|
||||
to_chat(H, SPAN_NOTICE("You sense [user]'s psyche link with your own, and an emotion of <b>[text]</b> washes through your mind."))
|
||||
else
|
||||
else if (target_sensitivity >= 0)
|
||||
// Standard case for most characters.
|
||||
to_chat(H, SPAN_NOTICE("An emotion from outside your consciousness slips into your mind: <b>[text]</b>."))
|
||||
else
|
||||
// Negative sensitivity case, message arrives scrambled.
|
||||
// 25% of the message is scrambled per negative point of psi-sensitivity. Allowing fractional points.
|
||||
var/scrambled_message = stars(text, (abs(target_sensitivity) * 25))
|
||||
to_chat(H, SPAN_NOTICE("A half-formed emotion passes through your mind: <b>[scrambled_message]</b>."))
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "focus"
|
||||
desc = "Psionic drugs? No way."
|
||||
icon_state = "blink"
|
||||
item_icons = null
|
||||
cast_methods = CAST_USE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 50
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "mend"
|
||||
desc = "Clear!"
|
||||
icon_state = "mend_wounds"
|
||||
item_icons = null
|
||||
cast_methods = CAST_MELEE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 50
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
for(var/mob/living/L in GLOB.mob_list)
|
||||
if(L == user)
|
||||
continue
|
||||
if(!L.is_psi_blocked(user))
|
||||
if(!L.is_psi_blocked(user, TRUE))
|
||||
continue
|
||||
if(GET_Z(L) != GET_Z(user))
|
||||
continue
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "psionic recovery"
|
||||
desc = "It's an aura recharge."
|
||||
icon_state = "generic"
|
||||
item_icons = null
|
||||
cast_methods = CAST_USE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 5
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "psionic search"
|
||||
desc = "A psionic magnifying glass."
|
||||
icon_state = "generic"
|
||||
item_icons = null
|
||||
cast_methods = CAST_USE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 5
|
||||
@@ -30,9 +31,7 @@
|
||||
for(var/mob/living/carbon/human/H in GLOB.human_mob_list)
|
||||
if(H == L)
|
||||
continue
|
||||
if((GET_Z(H) == GET_Z(L)) && !H.is_psi_blocked(user))
|
||||
if(HAS_TRAIT(H, TRAIT_PSIONIC_SUPPRESSION))
|
||||
continue
|
||||
if((GET_Z(H) == GET_Z(L)) && !H.is_psi_blocked(user, TRUE))
|
||||
level_humans |= H
|
||||
if(H.psi)
|
||||
if(H.psi.get_rank() >= PSI_RANK_APEX)
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "psi-stamina weave"
|
||||
desc = "Kind of like charging up your aura."
|
||||
icon_state = "generic"
|
||||
item_icons = null
|
||||
cast_methods = CAST_USE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 0
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
/singleton/psionic_power/psi_suppression
|
||||
name = "Psionic Suppression"
|
||||
desc = "Hold in one of your hands to make yourself invisible to Psi-Search."
|
||||
desc = "Activate to toggle passive mind-shielding on yourself. While active, you cannot send or receive telepathic messages, and you are nearly impossible to detect as psychic."
|
||||
icon_state = "tech_shield"
|
||||
point_cost = 1
|
||||
ability_flags = PSI_FLAG_CANON
|
||||
@@ -9,19 +9,23 @@
|
||||
/obj/item/spell/psi_suppression
|
||||
name = "psionic suppression"
|
||||
icon_state = "generic"
|
||||
item_icons = null
|
||||
cast_methods = CAST_INNATE
|
||||
aspect = ASPECT_PSIONIC
|
||||
psi_cost = 5
|
||||
|
||||
/obj/item/spell/psi_suppression/Destroy()
|
||||
to_chat(owner, SPAN_NOTICE("You are no longer hidden from Psi-Search."))
|
||||
REMOVE_TRAIT(owner, TRAIT_PSIONIC_SUPPRESSION, TRAIT_SOURCE_PSIONICS)
|
||||
return ..()
|
||||
|
||||
/obj/item/spell/psi_suppression/on_innate_cast(mob/user)
|
||||
. = ..()
|
||||
if(!.)
|
||||
return
|
||||
|
||||
to_chat(user, SPAN_NOTICE("You are now hidden from Psi-Search."))
|
||||
ADD_TRAIT(user, TRAIT_PSIONIC_SUPPRESSION, TRAIT_SOURCE_PSIONICS)
|
||||
var/suppression_comp = user.GetComponent(PSI_SUPPRESSION_COMPONENT)
|
||||
if (suppression_comp)
|
||||
to_chat(user, SPAN_NOTICE("You are no longer suppressing your psi-signature!"))
|
||||
qdel(suppression_comp)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
to_chat(user, SPAN_NOTICE("You are now suppressing your psi-signature!"))
|
||||
user.AddComponent(PSI_SUPPRESSION_COMPONENT)
|
||||
qdel(src)
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "read mind"
|
||||
desc = "Rip thoughts from someone's mind."
|
||||
icon_state = "generic"
|
||||
item_icons = null
|
||||
cast_methods = CAST_MELEE|CAST_USE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 10
|
||||
@@ -33,14 +34,15 @@
|
||||
to_chat(user, SPAN_WARNING("Not even a psion of your level can speak to the dead."))
|
||||
return
|
||||
|
||||
var/psi_blocked = target.is_psi_blocked(user)
|
||||
var/psi_blocked = target.is_psi_blocked(user, FALSE)
|
||||
if(psi_blocked)
|
||||
to_chat(user, psi_blocked)
|
||||
return
|
||||
|
||||
var/safe_mode = FALSE
|
||||
var/target_sensitivity = target.check_psi_sensitivity()
|
||||
// Safe mode triggers if the caster's psi-sensitivity isn't 2 or more points greater than the receiver's sensitivity.
|
||||
if(user.check_psi_sensitivity() - target.check_psi_sensitivity() < PSI_RANK_HARMONIOUS)
|
||||
if(user.check_psi_sensitivity() - target_sensitivity < PSI_RANK_HARMONIOUS)
|
||||
safe_mode = TRUE
|
||||
|
||||
user.visible_message(SPAN_WARNING("[user] lays a palm on [hit_atom]'s forehead..."))
|
||||
@@ -62,7 +64,11 @@
|
||||
to_chat(user, SPAN_NOTICE("<b>You receive nothing useful from \the [target].</b>"))
|
||||
to_chat(target, SPAN_NOTICE("Your mind blanks out momentarily."))
|
||||
else
|
||||
if(safe_mode)
|
||||
if (target_sensitivity < 0)
|
||||
// Negative sensitivity (of target) case. Underdeveloped Zona Bovinae return a scrambled message.
|
||||
var/scrambled_message = stars(answer, (abs(target_sensitivity) * 25))
|
||||
to_chat(user, SPAN_NOTICE("<b>You tease a half-formed thought from [target]'s mind: <i>[scrambled_message]</i></b>"))
|
||||
else if(safe_mode)
|
||||
to_chat(user, SPAN_NOTICE("<b>You skim the first thoughts in [target]'s mind: <i>[answer]</i></b>"))
|
||||
else
|
||||
to_chat(user, SPAN_NOTICE("<b>You pry the answer to your question from [target]'s mind: <i>[answer]</i></b>"))
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "rejuvenate"
|
||||
desc = "Blood bag who?"
|
||||
icon_state = "mend_life"
|
||||
item_icons = null
|
||||
cast_methods = CAST_MELEE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 50
|
||||
|
||||
@@ -11,6 +11,7 @@
|
||||
name = "skinsight"
|
||||
desc = "A health analyzer, but cooler."
|
||||
icon_state = "blink"
|
||||
item_icons = null
|
||||
cast_methods = CAST_MELEE|CAST_USE
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 10
|
||||
|
||||
@@ -10,6 +10,7 @@
|
||||
name = "spasm"
|
||||
desc = "Made you drop your gun."
|
||||
icon_state = "control"
|
||||
item_icons = null
|
||||
cast_methods = CAST_RANGED
|
||||
aspect = ASPECT_PSIONIC
|
||||
cooldown = 100
|
||||
|
||||
Reference in New Issue
Block a user