mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-07-12 16:37:19 +01:00
a802b48e2a
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" />
34 lines
988 B
Plaintext
34 lines
988 B
Plaintext
/singleton/psionic_power/charge
|
|
name = "Charge"
|
|
desc = "Use this spell on an item with a cell to charge it."
|
|
icon_state = "wiz_charge"
|
|
point_cost = 1
|
|
ability_flags = PSI_FLAG_ANTAG
|
|
spell_path = /obj/item/spell/charge
|
|
|
|
/obj/item/spell/charge
|
|
name = "charge"
|
|
icon_state = "audible_deception"
|
|
item_icons = null
|
|
cast_methods = CAST_USE
|
|
aspect = ASPECT_PSIONIC
|
|
cooldown = 5
|
|
psi_cost = 5
|
|
|
|
/obj/item/spell/charge/on_melee_cast(atom/hit_atom, mob/living/user, def_zone)
|
|
var/obj/item/cell/C = hit_atom.get_cell()
|
|
if(!C)
|
|
return
|
|
if(C.percent() >= 100)
|
|
to_chat(user, SPAN_WARNING("That cell is already charged."))
|
|
return
|
|
psi_cost = C.maxcharge * 0.001
|
|
. = ..()
|
|
if(!.)
|
|
return
|
|
user.visible_message(SPAN_NOTICE("[user] lays [get_pronoun("his")] hand on \the [C]..."), SPAN_NOTICE("You lay your hand on \the [C]..."),)
|
|
if(do_after(user, 1 SECOND))
|
|
to_chat(user, SPAN_WARNING("You restore some power to \the [C]."))
|
|
C.give(C.maxcharge * 0.1)
|
|
psi_cost = initial(psi_cost)
|