phylactery
Phylactery component
Used for lichtom to turn (almost) any object into a phylactery A mob linked to a phylactery will repeatedly revive on death.
Vars | |
base_respawn_time | The respawn timer of the phylactery. |
---|---|
lich_mind | The mind of the lich who is linked to this phylactery. |
num_resurrections | The number of resurrections that have occurred from this phylactery. |
phylactery_color | The color of the phylactery itself. Applied on creation. |
revive_timer | A timerid to the current revival timer. |
stun_per_resurrection | How much stun (paralyze) is caused on respawn per revival. |
time_per_resurrection | How much time is added on to the respawn time per revival. |
Procs | |
check_if_lich_died | Signal proc for COMSIG_GLOB_MOB_DEATH. |
on_examine | Signal proc for COMSIG_ATOM_EXAMINE. |
on_lich_mind_lost | Signal proc for COMSIG_QDELETING registered on the lich's mind. |
revive_lich | Actually undergo the process of reviving the lich at the site of the phylactery. |
stop_timer | Signal proc for COMSIG_LIVING_REVIVE. |
Var Details
base_respawn_time
The respawn timer of the phylactery.
lich_mind
The mind of the lich who is linked to this phylactery.
num_resurrections
The number of resurrections that have occurred from this phylactery.
phylactery_color
The color of the phylactery itself. Applied on creation.
revive_timer
A timerid to the current revival timer.
stun_per_resurrection
How much stun (paralyze) is caused on respawn per revival.
time_per_resurrection
How much time is added on to the respawn time per revival.
Proc Details
check_if_lich_died
Signal proc for COMSIG_GLOB_MOB_DEATH.
If the mob containing our lich's mind is killed, we can initiate the revival process.
We use the global mob death signal here, instead of registering the normal death signal, as it's entirely possible the wizard mindswaps or is gibbed or something wacky happens, and we need to make sure WHOEVER has our mind is dead
on_examine
Signal proc for COMSIG_ATOM_EXAMINE.
Gives some flavor for the phylactery on examine.
on_lich_mind_lost
Signal proc for COMSIG_QDELETING registered on the lich's mind.
Minds shouldn't be getting deleted but if for some ungodly reason the lich'd mind is deleted our component should go with it, as we don't have a reason to exist anymore.
revive_lich
Actually undergo the process of reviving the lich at the site of the phylactery.
Arguments
- corpse - optional, the old body of the lich. Can be QDELETED or null.
stop_timer
Signal proc for COMSIG_LIVING_REVIVE.
If our lich's mob is revived at some point before returning, stop the timer