#============================================================================== # # ▼ SaGa Project: BP Mechanic Ver 2.00 # -- Last Updated: 2014.09.24 # -- Level: Easy # -- Requires: n/a # # -- Author: Lowell # -- Thanks: CaptainJet # -- Usage: Free for Non Commercial #============================================================================== #============================================================================== # ▼ Updates # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= # # 2014.09.24 - Rewrote the script from the ground up, included default settings. # 2014.01.30 - Added MP Recovery Function. # 2014.01.25 - Started Script # #============================================================================== # ▼ Introduction # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= # Based on the Romancing SaGa: Minstrels Song battle system, this script # modifies MP to behave exactly as it does in Romancing SaGa: Minstrels Song # # Currently this script only performs the background functions such as setting. # Initial BP and the BP Regen Rate. # # As far as the visual effect that display BP in game, I have no plans to # include it at the moment. # # On a side note, the BP Mechanic can be completely ignored if you set the # default Initial and Recovery settings to 100 and 0 respectively. Actors will # behave much like they would by default if the script wasn't implemented. #============================================================================== # ▼ Instructions # =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= # To install this script, open up your script editor and copy/paste this script # to an open slot below ▼ Materials/素材 but above ▼ Main. Remember to save. # # ----------------------------------------------------------------------------- # NOTETAGS # These note tags can be used within the following locations in the database # * ACTOR # * ENEMY # # ----------------------------------------------------------------------------- # # Initial BP Setup # # , , # * Sets the starting MP value to a percentage of your Max MP. # # ** EXAMPLE ** # # * An actor with a MAX MP value of 20 would start with 8 MP # * An actor with a MAX MP value of 13 would start with 5 MP # # ----------------------------------------------------------------------------- # # BP Regeneration # , , # # * Performs a fixed MP Recovery rate at the end of each turn. # * This is was included since the default programs lacks this function in Ace # # ** EXAMPLE ** # # The actor/enemy will regenerate 4 MP at the end of every turn. # #=============================================================================== $imported = {} if $imported.nil? $imported["LOWE-BPMechanic"] = true module LOWE module BP_MECHANIC INIT_BP_ACTOR = 30 # Sets Initial BP for undefined actors INIT_BP_ENEMY = 20 # Sets Initial BP for undefined enemies BP_REGEN_ACTOR = 2 # Sets BP Regen Rate for undefined actors BP_REGEN_ENEMY = 2 # Sets BP Regen Rate for undefined enemies end end #------------------------------------------------------------------------------- # RPG::Actor #------------------------------------------------------------------------------- class RPG::Actor #------------------------------ # Initial BP setup #------------------------------ def bpm_initial_bp if @note =~ //i return $1.to_i else return LOWE::BP_MECHANIC::INIT_BP_ACTOR end end #------------------------------ # BP Regen Setup #------------------------------ def bpm_regen_bp if @note =~ //i return $1.to_i else return LOWE::BP_MECHANIC::BP_REGEN_ACTOR end end end #------------------------------------------------------------------------------- # RPG::Enemy #------------------------------------------------------------------------------- class RPG::Enemy #------------------------------ # Initial BP Setup #------------------------------ def bpm_initial_bp if @note =~ //i return $1.to_i else return LOWE::BP_MECHANIC::INIT_BP_ACTOR end end #------------------------------ # BP Regen Setup #------------------------------ def bpm_regen_bp if @note =~ //i return $1.to_i else return LOWE::BP_MECHANIC::BP_REGEN_ENEMY end end end #------------------------------------------------------------------------------- # Game #------------------------------------------------------------------------------- class Game_Actor #------------------------------ # Gets Initial BP for Actors #------------------------------ def bpm_set_initial_bp init_bp = (actor.bpm_initial_bp * self.mmp / 100).to_i self.mp = init_bp end #init_mp #------------------------------ # Gets BP Regen for Actors #------------------------------ def bpm_set_regen_bp self.mp += actor.bpm_regen_bp.to_i end #regen_mp end #Game #------------------------------------------------------------------------------- # Game #------------------------------------------------------------------------------- class Game_Enemy #------------------------------ # Gets Initial BP for Enemies #------------------------------ def bpm_set_initial_bp init_bp = (enemy.bpm_initial_bp * self.mmp / 100).to_i self.mp = init_bp end #init_mp #------------------------------ # Gets BP Regen for Enemies #------------------------------ def bpm_set_regen_bp self.mp += enemy.bpm_regen_bp.to_i end #regen_mp end #Game class Game_Battler < Game_BattlerBase #------------------------ # Battle Start Alias # Sets Everyones Initial BP #------------------------ alias lowe_battle_start on_battle_start def on_battle_start bpm_set_initial_bp end #on_battle_start #------------------------ # Battle Start Alias # Performs Default BP Regen #------------------------ alias lowe_turn_end on_turn_end def on_turn_end bpm_set_regen_bp end #on_turn_end end #Game_Battler