This is a quite simple scriptlet that lets you create a state that randomly changes your hero's life or mana points every turn till it wears off.
Nope, Aluxes, it won't revive you if a ghost or a lizard has killed you already!
Script
Code:
# * KRiskPoints XP - Default Battle System Version# Scripter : Kyonides Arkanthes# 2020-07-31# This scriptlet will let you create a state with the ability to set an actor's# Life or Mana Points randomly every turn he or she is afflicted by that.# I think this is a great addition for bosses and mini bosses.# Add a state to the States DB and come back here to set the STATE_ID constant# to the chosen state ID. By the way, you may prefer to create a Skill that# inflicts this state to the hero.# A hero might even get afflicted by both kinds of states.# This state will not revive its target. My sympaties, Aluxes! XDmodule KRiskPoints LIFE_STATE_ID = 20 MANA_STATE_ID = 21endclass Scene_Battle alias :kyon_hprisk_ups1 :update_phase4_step1 def update_phase4_step1 if @active_battler and @active_battler.hp > 0 if @active_battler.state?(KRiskPoints::LIFE_STATE_ID) @active_battler.hp = rand(@active_battler.maxhp + 1) end if @active_battler.state?(KRiskPoints::MANA_STATE_ID) @active_battler.sp = rand(@active_battler.maxsp + 1) end end kyon_hprisk_ups1 endend
Terms & Conditions
Free for use in any non commercial games.
Don't forget to include my nickname in your game credits!
Include the forum's URL as well.
Give me a free copy of your completed game if you include at least 2 of my scripts!