Save-Point

Full Version: Save-Point
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Board Message
Sorry, you do not have permission to access this resource.
Save-Point - Skill based on FFVI's Celes Runic

Save-Point

Full Version: Skill based on FFVI's Celes Runic
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3 4 5 6
Now that I can make my first thread, here I'll go.
Of all the things that I want, I can find them already (as mentioned in my intoduction to this forum).

However, there is one thing that keeps barking at me and that is a lack of a script. A lack of a skill similar to the Runic ability of Celes' in Final Fantasy VI.
Mainly for RPG Maker XP.
Long story short, I am requesting for a script request.
One last RMXP script request from me, if anyone is interested.
I won't mind donating 5 USD or 10 USD as a thank you.
Provided that one has a PayPal account and also that the script works properly, of course.

That said, for those who don't know of Final Fantasy VI in general, I'll give a quick rundown on the Runic skill.
What it does is that it restores a certain amount of MP to the user.
But it happens only once per turn. I'll list the scenario below.

Scenario:
The player character (e.g. Celes) uses "Runic" which costs no MP to activate.
An enemy (e.g. Black Mage) uses a Magical attack.
Let's say it uses Fire.
Let's say the Fire magic costs 6 MP to cast.
As a result of activating the Runic, the Fire magic is ABSORBED by the player character, restoring 6 MP in the process.
Only absorbs once per turn which means any other subsequence Magical attacks are used in that 1 turn, the player character cannot absorb the magical attacks.
The process repeats.
Hmm~ It might be a little beyond me to script this, but I can see how it would work in theory.

A status effect that lasts however long, a check that determines if the attack being received is magical, a check of it's SP cost...
@Zackwell
Yes, it's more or less like that in a nutshell.
It might just be easier to add a value into 'Game_Battler' called runic_turns_left.

By casting the Runic spell, it sets the user's runic_turns_left value to 2. And in each battle turn, this value decreases by one until it hits zero (no lower of course). And if the caster is hit with a spell attack while runic_turns_left is more than zero, then the skill_effect script gets adjusted to let the user of the runic spell absorb the SP instead of taking damage.... and changing the turns left value to 0 of course.

Just off the top of my head. This could be REALLY interesting if the user is also a Blue Mage too. Tongue sticking out

Winking Wanna find an avatar, even if it's Monopoly's 'Just Visiting' tile? Laughing Laughing Laughing
@DerVVulfman
In other words, a script is most likely not needed?
If so, I'll try and see if I can do it on my own with your instructions.
If not, I'll go on waiting with an "Edit" update, roughly around October 5th based on my timezone.

Edit: Hold on. You mentioned skill_effect script. Something I most likely shall not tinker with due to the lack of scripting knowledge. I guess I'll wait.
Laughing Er, Game_Battler is a script in the default scripts. And 'skill_effect' is a method within. So by that, I did mean by making a script. Simpler in design than you may have thought. Well........ by MY standard anyway.

I wouldn't need to make a status ailment/effect for this. Just a timer value in Game_Battler that gets counted down while seeing if the player is hit by a skill.
@DerVVulfman
Which in other words, ehhh, I still need to tinker with the scripts anyway.
I'll see whether it will work when the time comes.
Just got home half an hour forty minutes ago.....

I whipped this up. Winking Just call it Just Runics.

Code:
#==============================================================================
# ** Just Runics
#------------------------------------------------------------------------------
#  By DerVVulfman
#  v 1.0
#  October 3, 2017
#==============================================================================


  
module Runic
  
  # List of Skills by ID
  # This, by their skill ID in the database
  #
    SKILL_LIST = [81]
    
  # Number of turns
  # How many turns it lasts...
  #
    TURNS = 1
    
    
  # Show Animation Effect per turn?
  # If true, the shielded runic animation plays on turn start
  #
    SHOW = true
    
  # Pop that shows target/self protected
  # (Or nil if no pop to show)
  #
    SPELL_POP  = "Runic Barrier"
  
  # Words that show target/self absorbed SP
  # Format is RUNIC_ABSORB + value + RUNIC_SUFFIX
  # (Or nil per word not showing)
  #
    RUNIC_ABSORB = "Absorb"
    RUNIC_SUFFIX = "SP"
  
end


#==============================================================================
# ** Game_Battler
#------------------------------------------------------------------------------
#  This class deals with battlers. It's used as a superclass for the Game_Actor
#  and Game_Enemy classes.
#==============================================================================

class Game_Battler
  #--------------------------------------------------------------------------
  # * Alias Listings
  #--------------------------------------------------------------------------
  alias runic_gb_initialize initialize
  alias runic_gb_skill_effect skill_effect
  #--------------------------------------------------------------------------
  # * Public Instance Variables
  #--------------------------------------------------------------------------
  attr_accessor :runic_counter            # runic absorb counter
  attr_accessor :runic_animation          # runic spell animation
  #--------------------------------------------------------------------------
  # * Object Initialization
  #--------------------------------------------------------------------------
  def initialize
    # Perform the original call
    runic_gb_initialize
    # The added value
    @runic_counter = 0
    @runic_animation = 0
  end
  #--------------------------------------------------------------------------
  # * Apply Skill Effects
  #     user  : the one using skills (battler)
  #     skill : skill
  #--------------------------------------------------------------------------
  def skill_effect(user, skill)
    # If skill is slated as a runic barrier spell
    if Runic::SKILL_LIST.include?(skill.id)
      # Set the number of turns
      @runic_counter = Runic::TURNS
      # Self/caster turns must be increased 1
      @runic_counter += 1 if user == self
      # Show applied pop text if text set
      self.damage = Runic::SPELL_POP unless Runic::SPELL_POP.nil?
      # Set the barrier animation ID for self
      @runic_animation = skill.animation2_id
      # End Method
      return true
    end
    # Perform the original call
    effective = runic_gb_skill_effect(user, skill)
    # If positive damage during runic effect
    if @runic_counter > 0
      if self.damage > 0
        # Restore health befoer damage
        self.hp += self.damage
        # Add attacker's SP cost into SP score
        self.sp += skill.sp_cost
        # Clear critical flag
        self.critical = false
        # Change Pop message
        word1 = word2 = ""
        word1 = Runic::RUNIC_ABSORB unless Runic::RUNIC_ABSORB.nil?
        word2 = Runic::RUNIC_SUFFIX unless Runic::RUNIC_SUFFIX.nil?
        self.damage = word1 +(skill.sp_cost).to_s + word2
        # And turn the runic effect off
        @runic_counter = 0
      return effective
      end
    end
    # End Method
    return effective
  end
end



#==============================================================================
# ** Scene_Battle
#------------------------------------------------------------------------------
#  This class performs battle screen processing.
#==============================================================================

class Scene_Battle
  #--------------------------------------------------------------------------
  # * Frame Update (main phase step 6 : refresh)
  #--------------------------------------------------------------------------
  alias runic_sb_start_phase2 start_phase2
  alias runic_sb_update_phase4_step6 update_phase4_step6
  #--------------------------------------------------------------------------
  # * Start Party Command Phase
  #--------------------------------------------------------------------------
  def start_phase2
    # Cycle through enemies
    for enemy in $game_troop.enemies
      # Perform runic animation
      runic_animation(enemy)
    end
    # Cycle through actors
    for actor in $game_party.actors
      # Perform runic animation
      runic_animation(actor)
    end
    # Perform the original call
    runic_sb_start_phase2
  end
  #--------------------------------------------------------------------------
  # * Start Runic Animation Effect at Party Command Start
  #     target : target (actor or enemy)
  #--------------------------------------------------------------------------
  def runic_animation(target)
    return unless Runic::SHOW == true
    return unless target.exist?
    return unless target.hp > 0
    return unless target.runic_counter > 0
    target.animation_id = target.runic_animation
    target.animation_hit = true
  end
  #--------------------------------------------------------------------------
  # * Frame Update (main phase step 6 : refresh)
  #--------------------------------------------------------------------------
  def update_phase4_step6
    # Update Runic counter (never below 0)
    @active_battler.runic_counter -= 1
    @active_battler.runic_counter == 0 if @active_battler.runic_counter < 0
    # Perform the original call
    runic_sb_update_phase4_step6
  end
end
^ See, that's elegance right there. Might even have to use it for something myself~
I kind of feel the need to ask this... what if an ally casts a healing spell on the runic hero? Should it absorb the spell's SP? Is that really convenient? Just a thought for our dear forumer to play with...
Pages: 1 2 3 4 5 6