Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #Dekita's=======================================================================
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★
- #===============================================================================
- # v1.3
- # ★ Perfect Stat Point Distribution System ★
- #
- #===============================================================================
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★
- #===============================================================================
- #
- # -- Last updated: 12/08/2012 <-(D/M/Y)
- #
- # -- Difficulty: Plug'n'play - (Easy)
- #
- # -- Customisation: Holy crap on a cracker Batman! - (Very High)
- #
- # -- Requires: N/A
- #
- # -- Recommended: N/A
- #
- # -- Compatable: RPG Maker VX Ace ONLY!
- #
- #===============================================================================
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★
- #===============================================================================
- #===============================================================================
- # ☆ Script Information:
- #=======================
- # This script will Nullify the traditional RPG-Maker "Level up -> increases
- # parameters" feature. Instead when you level you will be presented with a stat
- # point distribution screen. you can then increase each parameter using the
- # points you gain.
- #
- # This script will give you COMPLETE control over all aspects of how your
- # characters stats increase during gameplay.
- #
- # The control and customisation for this "System" has been designed to be
- # as dynamic as possible.
- #===============================================================================
- #===============================================================================
- # ☆ TERMS OF USE:
- #===============================================================================
- #
- # 1. You must give credit to Dekita.
- #
- # 2. This script is for NON-Commercial use ONLY!*
- #
- # 3. You CANNOT give credit to yourself for Re-posting this script
- # or Posting a modified version.*
- #
- # 4. Do not Re-Distribute this script.
- #
- # 5. You are NOT allowed to convert this script to any other engine,
- # E.G converting it from RGSS3 into RGSS2.*
- #
- # 6. ENJOY!
- #
- #-------------------------------------------------------------------------------
- # * = Unless permissions are given by Dekita. < e-mail DekitaRPG@gmail.com
- #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- #===============================================================================
- #===============================================================================
- # ☆ History:
- #============
- # D - M - Y
- # 14/08/2o12 - Released Script.(v1.3)
- # 13/08/2o12 - Added bonus level points.
- # - Released Script.(v1.2)
- # 12/08/2o12 - Added ability to continue using parameter curves growth.
- # - Fixed bug where using "SceneManager.call(Scene_Level_Up)" gave an
- # error message(if no actor had leveled).
- # - Added main menu command, Added switch to show/enable menu command.
- # - Removed a useless script call.(lose_pts)
- # - General tidying of the script.
- # 11/08/2o12 - Added script calls to increase vit,str,dex and mag counters.
- # - Removed "Perfect Stat Point Control Mode"
- # - Changed name of script to Perfect Stat Point Distribution System.
- # - Updated script to give ALOT more control over how
- # x-params/s-params increase/decrease via command options.
- # - Removed formula's method for increasing x/s-params.
- # 08/08/2o12 - Released Script. (v1.1)
- # - Compatability update -> (Perfect Status Screen).
- # 07/08/2o12 - Fixed PROPERTIES_BIGGER_NUMBERS < Customisation module.
- # - Added Gain/Lose points script calls as requested by "The Attendee"
- # @ http://www.rpgmakervxace.net
- # - Released Script. (v1.0)
- # 06/08/2o12 - Added TP cost, HP Cost and GOLD Cost formula's.
- # - Improved layout again.
- # 05/08/2O12 - Added visual Vit,Str,Mag,Dex counters.
- # 02/08/2012 - Added Ability to convert from "PSPDS" into "PSPCS"
- # - Added more customisation.
- # 01/08/2o12 - Added MASS Customisation.
- # - Finished Script Base.
- # 31/07/2o12 - Improved layout.
- # - Added customisation options for when the SPD Screen triggers.
- # 30/07/2o12 - Script now displays actors JP if Yanfly's JP manager is installed.
- # - Added minor customisation.
- # - Improved Layout.
- # 21/07/2o12 - Started script.
- #
- #===============================================================================
- # ☆ Credit and Thanks to :
- #==========================
- # "Adrian Meza" for showing me how to add bonus level points.
- # "Niclas" for showing me how to properly define add_xparam.
- # "De Mack" for showing me how to write a basic distribute parameters script.
- # "Yanfly" for making me want to script to start with.
- #===============================================================================
- #===============================================================================
- # ☆ Foresight Into The Future:
- #==============================
- # EVEN MORE OPTIONS !!
- #
- # Options to increase/decrease HCR/GCR + WUR/CDR
- # ^Yanfly's Skills Cost Manager and Skill restrictions.
- #
- #-------------------------------------------------------------------------------
- # If you have any ideas e-mail me at DekitaRPG@gmail.com
- #===============================================================================
- #===============================================================================
- # ☆ Known Bugs:
- #=================
- # Guardian/Summon Scripts usually override the SPD Screen process if
- # "INBATTLE = true" < Customisation module
- # If you encounter this problem simply set
- # "ONMAP" to "true" and "INBATTLE" to "false" < Customisation module
- #
- #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- # If a new bug is found please e-mail me at DekitaRPG@gmail.com
- #===============================================================================
- #===============================================================================
- # ☆ INSTRUCTIONS:
- #=================
- # Place this script UNDER "▼ Materials" and ABOVE "▼ Main" in your script editor.
- #
- #===============================================================================
- =begin
- #===============================================================================
- # ☆ Script Calls:
- #=================
- #
- # Use the following script call in game (an event) to change the amount of
- # points you gain each time you level up
- $pts = x
- # e.g
- # $pts = 7 <- this will change the points gained per level to 7
- #
- #-------------------------------------------------------------------------------
- #
- # Use the following script call to give an actor x amount of points
- gain_pts(actor_id, value)
- # e.g
- # gain_pts(1, 10) < This will give actor 1, 10 points to distribute.
- #
- # NOTE:
- # value can be negative e.g
- # gain_pts(1, -10) < This will remove 10 points from actor 1.
- #
- # NOTE_2: if an actor does not have the points you try to remove it wont work!
- #
- #-------------------------------------------------------------------------------
- #
- # Use the following script calls to add vit, str, dex or mag counters to an actor.
- inc_vit(actor_id, value)
- inc_str(actor_id, value)
- inc_dex(actor_id, value)
- inc_mag(actor_id, value)
- # NOTE: vit, str, dex and mag does not affect other param's x-params or s-params
- # They are just counters for how many times you have selected that command,
- # I have added these for actors that join the party above level 1, to make it seem
- # like they have already spent x amount of points in vit/str/dex or mag.
- #
- # NOTE_2: as with gain_pts value can be negative.
- #
- #-------------------------------------------------------------------------------
- #
- # Use the following script call in game (an event) to trigger the SPD Screen
- SceneManager.call(Scene_Level_Up)
- # NOTE: If no actor has leveled when you call this scene it will display the first
- # actor in the party. If an actor has leveled it will show the SPDS for them.
- #
- #===============================================================================
- =end
- #===============================================================================
- # ☆ Import:
- #===========
- $imported = {} if $imported.nil?
- $imported["DPB-PSPDS"] = true
- #
- #===============================================================================
- #===============================================================================
- # ☆ Perfect Stat Point Distribution System Begin:
- #=================================================
- module DPB
- module PSPDS
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Command's (selectable) DO NOT CHANGE OR REMOVE ANY OF THESE!
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- COMMANDS =[
- :Vitality, # < DO NOT REMOVE OR
- :Strength, # < CHANGE ANY OF THESE
- :Dexterity,# < COMMANDS
- :Magic, # < DO NOT REMOVE !
- :Finish, # < DO NOT REMOVE !
- ] # Do not remove this.
- #===============================================================================#
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★#
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆#
- # #
- # PSPDS #
- # (Perfect Stat Point Distribution System) #
- # - CUSTOMISATION BEGIN - #
- # #
- # #
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆#
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★#
- #===============================================================================#
- #===============================================================================
- # ☆ Customisation = Tah-Dah
- #===========================
- # I have added as much customisation as i thought was needed.
- # Probably a little too much, :o , if there is such a thing.\..\..
- #
- # It is advised you take a moment to look through the cusomisation options
- # to see if any apply to your current project.
- #
- #===============================================================================
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Vocab Settings
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- LVLUPPTSVOCAB = "Points :" # Help info used for the name of your level up points
- ADDSTATTEXT = "Stat Added !" # Help info for when points are added
- NOPOINTSTEXT = "No Points Left To Add !!" # Help info for when no points are remaining
- VIT_GAIN_VOCAB = "Increases overall Survivability" # Help info for command option 1
- STR_GAIN_VOCAB = "Increases overall Strength" # Help info for command option 2
- DEX_GAIN_VOCAB = "Increases overall Dexterity" # Help info for command option 3
- MAG_GAIN_VOCAB = "Increases overall Magic Power" # Help info for command option 4
- EXIT_VOCAB = "Finish distribution process" # Help info for leaving the SPDS Screen
- MENU_COMMAND_NAME = "PSPDS"
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Display SPD (Stat Point Distribution) Screen
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # By default the SPD Screen will be displayed at the end of battle (if you
- # level up). Some scripts may interfere with this one e.g summoning scripts,
- # when you level after your summon kills a monster in battle, the De-Summon
- # process usually overrides this one :(
- #
- # NOTE: if your party has more than 1 member that levels at the same time
- # then i recommend having both these options = true
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- INBATTLE = false #IF "true" screen triggers at end of battle (if an actor levels up)
- ONMAP = true # IF "true" screen triggers on map screen after an actor levels up.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Draw Actor Graphic ?
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- DRAW_ACTOR_GRAPHIC = false
- DAG_X = 432 # x location for actor graphic
- DAG_Y = 90 # y location for actor graphic
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Font Settings
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- PROPFONTSIZE = 14 # For Displayed Properties
- PARAMFONTSIZE = 20 # For Parameters in point selection window and JP if
- # Yanfly JP Manager is installed
- FONTSIZE = 16 # For Almost Everything Else and information in PSS*
- # (PSS = Perfect Status Screen) * = If imported.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Points gained after each level up
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # This is where you define the amount of distribution points each character
- # gains after each level up.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- LVUPPTS = 5 # Recommended to be under 10
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Default parameter growth
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # This is where you define whether you still gain parameters via
- # the parameter curves in the database.
- # set this to true if you wish to use that method (as well as SPD method).
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- USE_DEFAULT_PARAM_GAIN = false
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Bonus Point Gains
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Here you can grant bonus points on specific levels e.g reach level 10
- # gain 5 bonus spendable points as a reward .
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- BONUS_POINTS_ON_LEVELS = true # If "true" this will grant bonus points on
- # levels listed in LEVELS.
- LEVELS = [10, 20, 30, 40, 50, 75, 100] # If BONUS_POINTS_ON_LEVELS is 'true'
- # these will be the levels that the
- # actor(s) will gain bonus points on.
- ONLY_GAIN_POINTS_ON_LEVELS = false # Make this option "true" if you only want
- # to gains points on the levels stated
- # in LEVELS.
- # NOTE: BONUS_POINTS_ON_LEVELS "MUST!" be
- # "true" for this option to work.
- BONUSPOINTS = 10 # Define here how many bonus points your actors
- # gain on their bonus point levels.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Make this "true" if you want to be able to exit the SPD screen before
- # all points are spent/used.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- EXIT_BEFORE_POINTS_SPENT = true
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # - Switch Settings -
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # These are the switches that govern whether or not certain menu items will
- # appear and/or will be enabled. By binding them to a Switch, you can just
- # set the Switch ON/OFF to show/hide or enable/disable a menu command. If
- # you do not wish to use this feature, set these commands to 0.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- SWITCH_SHOW_PSPDS = 0 # Switch that shows pspds in Main Menu.
- SWITCH_ENABLE_PSPDS = 0 # Switch that enables pspds in Main Menu.
- COMPLETELY_DISABLE_MENU_OPTION = false # set this to true if you want ^_^
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Parameter gain settings
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # These settings adjust the points gained for each point spent
- # in each command option as well as each command options name.
- # You can also put negative values for each parameter.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # !! IMPORTANT !!
- #-----------------
- # It is important to note that Actor Ex-Parameters and Sp-Parameters deal
- # with percentage chance values. This means that their gain/reduce values
- # should be values that represent rates. What this means is:
- # 0.001 = 0.1%
- # 0.01 = 1%
- # 0.1 = 10%
- # 1.0 = 100%
- #
- # Be *very* careful with Ex/Sp-Parameters when defining their gain/reduce values.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- COMMAND_COLUMN_WIDTH = 128
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Option 1 settings (command option 1)
- #-------------------------------------
- # Adjust these to your liking. you can set it to decrease by using "-" before
- # your value. e.g OPTION_1_MaxHP_GAIN = -9.5 will reduce MHP by 9.5
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- COMMAND_NAME_1 = "Vitality" # Name of command option
- #Regular-Parameters
- OPTION_1_MaxHP_GAIN = 9.5 # Maximum HP Stat.
- OPTION_1_MaxMP_GAIN = 0 # Maximum MP Stat.
- OPTION_1_ATK_GAIN = 0 # Attack Stat.
- OPTION_1_DEF_GAIN = 0.4 # Defence Stat.
- OPTION_1_MAT_GAIN = 0 # Magic Attack Stat.
- OPTION_1_MDF_GAIN = 0.4 # Magic Defence Stat.
- OPTION_1_AGI_GAIN = 0 # Agility Stat.
- OPTION_1_LUK_GAIN = 0 # Luck Stat.
- #The following are % gains, 0.01 = 1%
- #X-Parameters
- OPTION_1_HIT_GAIN = 0.00 # Hit Rate.
- OPTION_1_EVA_GAIN = 0.00 # Evasion Rate.
- OPTION_1_CRI_GAIN = 0.00 # Critical Hit Rate.
- OPTION_1_CEV_GAIN = 0.001 # Critical Evasion Rate.
- OPTION_1_MEV_GAIN = 0.00 # Magic Evasion Rate.
- OPTION_1_MRF_GAIN = 0.00 # Magic Reflect Rate.
- OPTION_1_CNT_GAIN = 0.00 # Counter Rate.
- OPTION_1_HRG_GAIN = 0.0005 # HP Regeneration Rate.
- OPTION_1_MRG_GAIN = 0.00 # MP Regeneration Rate.
- OPTION_1_TRG_GAIN = 0.00 # TP Regeneration Rate.
- #S-Parameters
- OPTION_1_TGR_GAIN = 0.013 # Target Rate. (monsters targeting you)
- OPTION_1_GRD_GAIN = 0.013 # Guard Effect Rate
- OPTION_1_REC_GAIN = 0.00 # Recovery Effect Rate.
- OPTION_1_PHA_GAIN = 0.00 # Pharmacology Effect Rate.
- OPTION_1_MCR_GAIN = -0.00 # MP Cost Rate
- OPTION_1_TCR_GAIN = -0.00 # TP Charge Rate.
- OPTION_1_PDR_GAIN = -0.00025 # Physical Damage Rate.(incomming)
- OPTION_1_MDR_GAIN = -0.00025 # Magical Damage Rate.(incomming)
- OPTION_1_FDR_GAIN = -0.00 # Floor Damage Rate.
- OPTION_1_EXR_GAIN = 0 # EXP Gain Rate.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Option 2 settings (command option 2)
- #-------------------------------------
- # Adjust these to your liking. you can set it to decrease by using "-" before
- # your value. e.g OPTION_1_MaxHP_GAIN = -9.5 will reduce MHP by 9.5
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- COMMAND_NAME_2 = "Strength"
- #Regular-Parameters
- OPTION_2_MaxHP_GAIN = 0 # Maximum HP Stat.
- OPTION_2_MaxMP_GAIN = 0 # Maximum MP Stat.
- OPTION_2_ATK_GAIN = 1.2 # Attack Stat.
- OPTION_2_DEF_GAIN = 0.6 # Defence Stat.
- OPTION_2_MAT_GAIN = -0.01 # Magic Attack Stat.
- OPTION_2_MDF_GAIN = -0.01 # Magic Defence Stat.
- OPTION_2_AGI_GAIN = 0 # Agility Stat.
- OPTION_2_LUK_GAIN = 0.1 # Luck Stat.
- #The following are % gains, 0.01 = 1%
- #X-Parameters
- OPTION_2_HIT_GAIN = 0.00 # Hit Rate.
- OPTION_2_EVA_GAIN = 0.00 # Evasion Rate.
- OPTION_2_CRI_GAIN = 0.00 # Critical Hit Rate.
- OPTION_2_CEV_GAIN = 0.00 # Critical Evasion Rate.
- OPTION_2_MEV_GAIN = 0.00 # Magic Evasion Rate.
- OPTION_2_MRF_GAIN = 0.00 # Magic Reflect Rate.
- OPTION_2_CNT_GAIN = 0.0005 # Counter Rate.
- OPTION_2_HRG_GAIN = 0.00 # HP Regeneration Rate.
- OPTION_2_MRG_GAIN = 0.00 # MP Regeneration Rate.
- OPTION_2_TRG_GAIN = 0.00 # TP Regeneration Rate.
- #S-Parameters
- OPTION_2_TGR_GAIN = 0.0009 # Target Rate. (monsters targeting you)
- OPTION_2_GRD_GAIN = 0.005 # Guard Effect Rate
- OPTION_2_REC_GAIN = 0.00 # Recovery Effect Rate.
- OPTION_2_PHA_GAIN = 0.00 # Pharmacology Effect Rate.
- OPTION_2_MCR_GAIN = -0.00 # MP Cost Rate
- OPTION_2_TCR_GAIN = -0.00 # TP Charge Rate.
- OPTION_2_PDR_GAIN = -0.0020 # Physical Damage Rate.(incomming)
- OPTION_2_MDR_GAIN = -0.00 # Magical Damage Rate.(incomming)
- OPTION_2_FDR_GAIN = -0.00 # Floor Damage Rate.
- OPTION_2_EXR_GAIN = 0 # EXP Gain Rate.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Option 3 settings (command option 3)
- #-------------------------------------
- # Adjust these to your liking. you can set it to decrease by using "-" before
- # your value. e.g OPTION_1_MaxHP_GAIN = -9.5 will reduce MHP by 9.5
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- COMMAND_NAME_3 = "Dexterity"
- #Regular-Parameters
- OPTION_3_MaxHP_GAIN = 0 # Maximum HP Stat.
- OPTION_3_MaxMP_GAIN = 0 # Maximum MP Stat.
- OPTION_3_ATK_GAIN = 0 # Attack Stat.
- OPTION_3_DEF_GAIN = 0 # Defence Stat.
- OPTION_3_MAT_GAIN = 0 # Magic Attack Stat.
- OPTION_3_MDF_GAIN = 0 # Magic Defence Stat.
- OPTION_3_AGI_GAIN = 1.2 # Agility Stat.
- OPTION_3_LUK_GAIN = 0.6 # Luck Stat.
- #The following are % gains, 0.01 = 1%
- #X-Parameters
- OPTION_3_HIT_GAIN = 0.005 # Hit Rate.
- OPTION_3_EVA_GAIN = 0.0005 # Evasion Rate.
- OPTION_3_CRI_GAIN = 0.001 # Critical Hit Rate.
- OPTION_3_CEV_GAIN = 0.0005 # Critical Evasion Rate.
- OPTION_3_MEV_GAIN = 0.00025 # Magic Evasion Rate.
- OPTION_3_MRF_GAIN = 0.00 # Magic Reflect Rate.
- OPTION_3_CNT_GAIN = 0.0002 # Counter Rate.
- OPTION_3_HRG_GAIN = 0.00 # HP Regeneration Rate.
- OPTION_3_MRG_GAIN = 0.00 # MP Regeneration Rate.
- OPTION_3_TRG_GAIN = 0.0005 # TP Regeneration Rate.
- #S-Parameters
- OPTION_3_TGR_GAIN = 0.00 # Target Rate. (monsters targeting you)
- OPTION_3_GRD_GAIN = 0.00 # Guard Effect Rate
- OPTION_3_REC_GAIN = 0.00 # Recovery Effect Rate.
- OPTION_3_PHA_GAIN = 0.00 # Pharmacology Effect Rate.
- OPTION_3_MCR_GAIN = -0.00 # MP Cost Rate
- OPTION_3_TCR_GAIN = -0.0025 # TP Charge Rate.
- OPTION_3_PDR_GAIN = -0.00 # Physical Damage Rate.(incomming)
- OPTION_3_MDR_GAIN = -0.00 # Magical Damage Rate.(incomming)
- OPTION_3_FDR_GAIN = -0.00 # Floor Damage Rate.
- OPTION_3_EXR_GAIN = 0 # EXP Gain Rate.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Option 4 settings (command option 4)
- #-------------------------------------
- # Adjust these to your liking. you can set it to decrease by using "-" before
- # your value. e.g OPTION_1_MaxHP_GAIN = -9.5 will reduce MHP by 9.5
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- COMMAND_NAME_4 = "Magic"
- #Regular-Parameters
- OPTION_4_MaxHP_GAIN = 0 # Maximum HP Stat.
- OPTION_4_MaxMP_GAIN = 9.5 # Maximum MP Stat.
- OPTION_4_ATK_GAIN = -0.01 # Attack Stat.
- OPTION_4_DEF_GAIN = -0.01 # Defence Stat.
- OPTION_4_MAT_GAIN = 1.2 # Magic Attack Stat.
- OPTION_4_MDF_GAIN = 0.6 # Magic Defence Stat.
- OPTION_4_AGI_GAIN = 0 # Agility Stat.
- OPTION_4_LUK_GAIN = 0.1 # Luck Stat.
- #The following are % gains, 0.01 = 1%
- #X-Parameters
- OPTION_4_HIT_GAIN = 0.00 # Hit Rate.
- OPTION_4_EVA_GAIN = 0.00 # Evasion Rate.
- OPTION_4_CRI_GAIN = 0.00 # Critical Hit Rate.
- OPTION_4_CEV_GAIN = 0.00 # Critical Evasion Rate.
- OPTION_4_MEV_GAIN = 0.001 # Magic Evasion Rate.
- OPTION_4_MRF_GAIN = 0.00 # Magic Reflect Rate.
- OPTION_4_CNT_GAIN = 0.00 # Counter Rate.
- OPTION_4_HRG_GAIN = 0.00 # HP Regeneration Rate.
- OPTION_4_MRG_GAIN = 0.0005 # MP Regeneration Rate.
- OPTION_4_TRG_GAIN = 0.00 # TP Regeneration Rate.
- #S-Parameters
- OPTION_4_TGR_GAIN = 0.00 # Target Rate. (monsters targeting you)
- OPTION_4_GRD_GAIN = 0.004 # Guard Effect Rate
- OPTION_4_REC_GAIN = 0.00 # Recovery Effect Rate.
- OPTION_4_PHA_GAIN = 0.00 # Pharmacology Effect Rate.
- OPTION_4_MCR_GAIN = -0.0025 # MP Cost Rate
- OPTION_4_TCR_GAIN = -0.00 # TP Charge Rate.
- OPTION_4_PDR_GAIN = -0.00 # Physical Damage Rate.(incomming)
- OPTION_4_MDR_GAIN = -0.0020 # Magical Damage Rate.(incomming)
- OPTION_4_FDR_GAIN = -0.00 # Floor Damage Rate.
- OPTION_4_EXR_GAIN = 0 # EXP Gain Rate.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Option 5 settings (this is the leave screen command).
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- FINISHVOCAB = "Done" # Command name for leaving the SPDS Screen
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Option cost settings
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # These settings adjust the amount of points it costs to gain an increase
- # in that particular command option.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- OPTION_1_COST = 1 # Default = 1
- OPTION_2_COST = 1 # Default = 1
- OPTION_3_COST = 1 # Default = 1
- OPTION_4_COST = 1 # Default = 1
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Parameters Gauge Settings
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # Set this to "true" if you wish to have Gauges for params e.g
- # MaxHP, MaxMP, Atk, Def, Mat, Mdf, Agi, Luk.
- # Set it to "false" to draw params in boxes.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- DRAW_PARAM_GAUGES = true
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Parameters Colour Settings
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # These settings adjust the way the parameters window visually appears.
- # Each of the stats have a non-window colour. Adjust them as you see fit.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- PARAM_COLOUR ={
- # ParamID => [:stat, Colour1, Colour2 ],
- 2 => [ :atk, Color.new(225, 100, 100), Color.new(240, 150, 150)],
- 3 => [ :def, Color.new(250, 150, 30), Color.new(250, 180, 100)],
- 4 => [ :mat, Color.new( 70, 140, 200), Color.new(135, 180, 230)],
- 5 => [ :mdf, Color.new(135, 130, 190), Color.new(170, 160, 220)],
- 6 => [ :agi, Color.new( 60, 180, 80), Color.new(120, 200, 120)],
- 7 => [ :luk, Color.new(255, 240, 100), Color.new(255, 250, 200)],
- } # Do not remove this.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # ☆ Properties Window Settings
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- # These settings adjust the way the properties window visually appears.
- # The properties have abbreviations, but leaving them as such makes things
- # confusing (as it's sometimes hard to figure out what the abbreviations
- # mean). Change the way the appear, whether or not they appear, and what
- # order they will appear in.
- #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
- #---------------------------------------------------------------------------
- # ☆ Just for the hell of it:
- #----------------------------
- # This option is for those people who like to have large number values for
- # their stats,
- # e.g
- # accuracy = 17,982.
- # attack = 6021.
- #
- # Simply set "PROPERTIES_BIGGER_NUMBERS" to "true" to activate this option.
- #
- # NOTE:
- # This doesnt acctually increase your stats to ridiculous values
- # It just makes it appear that way :)
- # your still not gonna be hitting monsters for 6,932,123,21.5 :D
- #
- # This is also very usefull if you want your game to have a more
- # unique looking stat progression system
- # e.g
- # People cant calculate the stats as easy
- #---------------------------------------------------------------------------
- PROPERTIES_BIGGER_NUMBERS = false
- # This option is how much the parameters value will be multiplied by
- # IF PROPERTIES_BIGGER_NUMBERS = true
- # VISUAL PURPOSES ONLY!
- PARAMS_BIGGER_NUMBER_VALUE = 8.5
- # This option is how much the properties value will be multiplied by
- # IF PROPERTIES_BIGGER_NUMBERS = true
- # VISUAL PURPOSES ONLY!
- # ONLY AFFECTS NON-% STATS e.g stats such as MP Cost Rate will remain a %.
- PROPERTIES_BIGGER_NUMBER_VALUE = 850
- # These are the parameters that appear in column 1.
- # This column's settings are only relevant if DRAW_PARAM_GAUGES = false (above)
- PROPERTIES_PARAMCOLUMN =[
- [:mhp, "Max HP"], #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- [:mmp, "Max MP"], # <- Rename these to whatever you want your
- [:atk, "Attack"], # <- origional parameters to be called :)
- [:def, "Defence"], # <-
- [:mat, "M Attack"], # <-
- [:mdf, "M Defence"], # <-
- [:agi, "Speed"], # <-
- [:luk, "Luck"], #-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
- ] # Do not remove this.
- # These are the properties that appear in column 2.
- PROPERTIES_COLUMN1 =[
- [:hit, "Hit Rate"],
- [:eva, "Evasion"],
- [:cri, "Critical Hit"],
- [:cev, "Critical Evade"],
- [:mev, "Magic Evasion"],
- [:mrf, "Magic Reflect"],
- [:cnt, "Counter Rate"],
- [:tgr, "Target Rate"],
- ] # Do not remove this.
- # These are the properties that appear in column 3.
- PROPERTIES_COLUMN2 =[
- [:hrg, "HP Regen"],
- [:mrg, "MP Regen"],
- [:trg, "TP Regen"],
- [:rec, "Recovery"],
- [:grd, "Guard Rate"],
- [:pha, "Item Boost"],
- [:exr, "EXP Rate"],
- [:tcr, "TP Charge"],
- ] # Do not remove this.
- # These are the properties that appear in column 4.
- PROPERTIES_COLUMN3 =[
- [:hcr, "HP Cost Rate"], # Requires YEA - Skill Cost Manager
- [:mcr, "MP Cost Rate"],
- [:tcr_y, "TP Cost Rate"], # Requires YEA - Skill Cost Manager
- [:cdr, "Cooldown Rate"], # Requires YEA - Skill Restrictions
- [:wur, "Warmup Rate"], # Requires YEA - Skill Restrictions
- [:pdr, "Physical Damage"],
- [:mdr, "Magical Damage"],
- [:fdr, "Floor Damage"],
- ] # Do not remove this.
- DRAW_ALL_COLUMNS = true # This option is for those who do not want all 4 columns
- # Simply set this to false to only draw 3 columns
- # e.g the param column, column1 and column2.
- #===============================================================================#
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★#
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆#
- # #
- # PSPDS #
- # (Perfect Stat Point Distribution System) #
- # - CUSTOMISATION END - #
- # #
- # #
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆#
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★#
- #===============================================================================#
- # - DekitaRPG@gmail.com - #
- #===============================================================================#
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★#
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆#
- # #
- # PSPDS #
- # (Perfect Stat Point Distribution System) #
- # - SCRIPT BEGIN - #
- # #
- # #
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆#
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★#
- #===============================================================================#
- # - DekitaRPG@gmail.com - #
- #===============================================================================#
- # ARE YOU MODIFYING BEYOND THIS POINT? \.\. #
- # YES?\.\. #
- # OMG, REALLY? #
- # WELL SLAP MY FACE AND CALL ME A DRAGON.\..\.. #
- # I REALLY DIDN'T THINK YOU HAD IT IN YOU.\..\.. #
- #===============================================================================#
- NEW_STATS_COLUMN =[
- [:vit_pts, DPB::PSPDS::COMMAND_NAME_1],
- [:str_pts, DPB::PSPDS::COMMAND_NAME_2],
- [:dex_pts, DPB::PSPDS::COMMAND_NAME_3],
- [:mag_pts, DPB::PSPDS::COMMAND_NAME_4],
- ] # Do not remove this.
- end # PSPDS
- end # DPB
- #===============================================================================
- # Switch
- #===============================================================================
- module Switch
- #-----------------------------------------------------------------------------
- # self.pspds_show
- #-----------------------------------------------------------------------------
- def self.pspds_show
- return true if DPB::PSPDS::SWITCH_SHOW_PSPDS <= 0
- return $game_switches[DPB::PSPDS::SWITCH_SHOW_PSPDS]
- end
- #-----------------------------------------------------------------------------
- # self.pspds_enable
- #-----------------------------------------------------------------------------
- def self.pspds_enable
- return true if DPB::PSPDS::SWITCH_ENABLE_PSPDS <= 0
- return $game_switches[DPB::PSPDS::SWITCH_ENABLE_PSPDS]
- end
- end # Switch
- #------------------------------------------------------------------------------#
- #==============================================================================#
- # ** Game_BattlerBase
- #==============================================================================#
- class Game_BattlerBase
- alias dpb_pspds_init initialize
- def initialize(*args, &block)
- clear_xparam_plus
- clear_sparam_plus
- dpb_pspds_init(*args, &block)
- end
- #--------
- def xparam(xparam_id)
- (features_sum(FEATURE_XPARAM, xparam_id) + xparam_plus(xparam_id))
- end
- def xparam_plus(xparam_id)
- @xparam_plus[xparam_id]
- end
- def clear_xparam_plus
- @xparam_plus = [0] * 10
- end
- def add_xparam(xparam_id, value)
- @xparam_plus[xparam_id] += value
- refresh
- end
- #--------
- def sparam(sparam_id)
- (features_pi(FEATURE_SPARAM, sparam_id) + sparam_plus(sparam_id))
- end
- def sparam_plus(sparam_id)
- @sparam_plus[sparam_id]
- end
- def clear_sparam_plus
- @sparam_plus = [0] * 10
- end
- def add_sparam(sparam_id, value)
- @sparam_plus[sparam_id] += value
- refresh
- end
- #--------
- end # Game_BattlerBase
- $pts = DPB::PSPDS::LVUPPTS
- $bonuspts = DPB::PSPDS::BONUSPOINTS
- $vitpts = 1 # < DO NOT CHANGE!
- $strpts = 1 # < DO NOT CHANGE!
- $dexpts = 1 # < DO NOT CHANGE!
- $magpts = 1 # < DO NOT CHANGE!
- class Scene_Level_Up < Scene_MenuBase
- def msg
- s = ["#{DPB::PSPDS::VIT_GAIN_VOCAB}
- Points Cost : #{@actor.cost_caract(0)}",
- "#{DPB::PSPDS::STR_GAIN_VOCAB}
- Points Cost : #{@actor.cost_caract(1)}",
- "#{DPB::PSPDS::DEX_GAIN_VOCAB}
- Points Cost : #{@actor.cost_caract(2)}",
- "#{DPB::PSPDS::MAG_GAIN_VOCAB}
- Points Cost : #{@actor.cost_caract(3)}",
- "#{DPB::PSPDS::EXIT_VOCAB} "]
- return s
- end
- #-----------------------------------------------------------------------------
- # * Start Processing
- #-----------------------------------------------------------------------------
- def start
- super
- if $game_temp.actor_level_up[0]
- @actor = $game_temp.actor_level_up[0] # For menu screen access.
- else
- end
- create_status_window
- create_command_window
- create_help_window
- @help_window.set_text(msg[@command_window.index])
- @help_window.y = (Graphics.height - 80)
- @help_window.opacity = 0
- $game_temp.actor_level_up.delete_at(0)
- end
- def create_command_window
- @command_window = Window_Level_upCommand.new
- @command_window.set_handler(:gain_vit, method(:command_gain_vit))
- @command_window.set_handler(:gain_str, method(:command_gain_str))
- @command_window.set_handler(:gain_dex, method(:command_gain_dex))
- @command_window.set_handler(:gain_mag, method(:command_gain_mag))
- @command_window.set_handler(:retour, method(:command_return))
- @command_window.set_handler(:pagedown, method(:next_actor))
- @command_window.set_handler(:pageup, method(:prev_actor))
- @command_window.y = 0
- end
- #--------
- def command_return
- if @actor.level_up_pts < 0
- @help_window.set_text(" ")
- wait(0)
- @command_window.activate
- else
- return_scene
- end
- end
- #--------
- def create_status_window
- @status_window = Window_Status_Level_up.new(@actor)
- @status_window.x = 0
- @status_window.y = 0
- end
- #--------
- def command_gain_vit
- index = @command_window.index
- # actor = $game_actors[@actor.actor_id]
- @command_window.refresh
- if @actor.level_up_pts >= @actor.cost_caract(index)
- @actor.gain_lvl_pts(-@actor.cost_caract(index))
- @actor.gain_vit_pts($vitpts)
- #reg's
- @actor.add_param(0, DPB::PSPDS::OPTION_1_MaxHP_GAIN)
- @actor.add_param(1, DPB::PSPDS::OPTION_1_MaxMP_GAIN)
- @actor.add_param(2, DPB::PSPDS::OPTION_1_ATK_GAIN)
- @actor.add_param(3, DPB::PSPDS::OPTION_1_DEF_GAIN)
- @actor.add_param(4, DPB::PSPDS::OPTION_1_MAT_GAIN)
- @actor.add_param(5, DPB::PSPDS::OPTION_1_MDF_GAIN)
- @actor.add_param(6, DPB::PSPDS::OPTION_1_AGI_GAIN)
- @actor.add_param(7, DPB::PSPDS::OPTION_1_LUK_GAIN)
- #x's
- @actor.add_xparam(0, DPB::PSPDS::OPTION_1_HIT_GAIN)
- @actor.add_xparam(1, DPB::PSPDS::OPTION_1_EVA_GAIN)
- @actor.add_xparam(2, DPB::PSPDS::OPTION_1_CRI_GAIN)
- @actor.add_xparam(3, DPB::PSPDS::OPTION_1_CEV_GAIN)
- @actor.add_xparam(4, DPB::PSPDS::OPTION_1_MEV_GAIN)
- @actor.add_xparam(5, DPB::PSPDS::OPTION_1_MRF_GAIN)
- @actor.add_xparam(6, DPB::PSPDS::OPTION_1_CNT_GAIN)
- @actor.add_xparam(7, DPB::PSPDS::OPTION_1_HRG_GAIN)
- @actor.add_xparam(8, DPB::PSPDS::OPTION_1_MRG_GAIN)
- @actor.add_xparam(9, DPB::PSPDS::OPTION_1_TRG_GAIN)
- #s's
- @actor.add_sparam(0, DPB::PSPDS::OPTION_1_TGR_GAIN)
- @actor.add_sparam(1, DPB::PSPDS::OPTION_1_GRD_GAIN)
- @actor.add_sparam(2, DPB::PSPDS::OPTION_1_REC_GAIN)
- @actor.add_sparam(3, DPB::PSPDS::OPTION_1_PHA_GAIN)
- @actor.add_sparam(4, DPB::PSPDS::OPTION_1_MCR_GAIN)
- @actor.add_sparam(5, DPB::PSPDS::OPTION_1_TCR_GAIN)
- @actor.add_sparam(6, DPB::PSPDS::OPTION_1_PDR_GAIN)
- @actor.add_sparam(7, DPB::PSPDS::OPTION_1_MDR_GAIN)
- @actor.add_sparam(8, DPB::PSPDS::OPTION_1_FDR_GAIN)
- @actor.add_sparam(9, DPB::PSPDS::OPTION_1_EXR_GAIN)
- #end inc stat
- @help_window.set_text(DPB::PSPDS::ADDSTATTEXT)
- else
- @help_window.set_text(DPB::PSPDS::NOPOINTSTEXT)
- end
- @status_window.refresh
- @command_window.refresh
- wait(25)
- @command_window.activate
- end
- #--------
- def command_gain_str
- index = @command_window.index
- @command_window.refresh
- if @actor.level_up_pts >= @actor.cost_caract(index)
- @actor.gain_lvl_pts(-@actor.cost_caract(index))
- @actor.gain_str_pts($strpts)
- #reg's
- @actor.add_param(0, DPB::PSPDS::OPTION_2_MaxHP_GAIN)
- @actor.add_param(1, DPB::PSPDS::OPTION_2_MaxMP_GAIN)
- @actor.add_param(2, DPB::PSPDS::OPTION_2_ATK_GAIN)
- @actor.add_param(3, DPB::PSPDS::OPTION_2_DEF_GAIN)
- @actor.add_param(4, DPB::PSPDS::OPTION_2_MAT_GAIN)
- @actor.add_param(5, DPB::PSPDS::OPTION_2_MDF_GAIN)
- @actor.add_param(6, DPB::PSPDS::OPTION_2_AGI_GAIN)
- @actor.add_param(7, DPB::PSPDS::OPTION_2_LUK_GAIN)
- #x's
- @actor.add_xparam(0, DPB::PSPDS::OPTION_2_HIT_GAIN)
- @actor.add_xparam(1, DPB::PSPDS::OPTION_2_EVA_GAIN)
- @actor.add_xparam(2, DPB::PSPDS::OPTION_2_CRI_GAIN)
- @actor.add_xparam(3, DPB::PSPDS::OPTION_2_CEV_GAIN)
- @actor.add_xparam(4, DPB::PSPDS::OPTION_2_MEV_GAIN)
- @actor.add_xparam(5, DPB::PSPDS::OPTION_2_MRF_GAIN)
- @actor.add_xparam(6, DPB::PSPDS::OPTION_2_CNT_GAIN)
- @actor.add_xparam(7, DPB::PSPDS::OPTION_2_HRG_GAIN)
- @actor.add_xparam(8, DPB::PSPDS::OPTION_2_MRG_GAIN)
- @actor.add_xparam(9, DPB::PSPDS::OPTION_2_TRG_GAIN)
- #s's
- @actor.add_sparam(0, DPB::PSPDS::OPTION_2_TGR_GAIN)
- @actor.add_sparam(1, DPB::PSPDS::OPTION_2_GRD_GAIN)
- @actor.add_sparam(2, DPB::PSPDS::OPTION_2_REC_GAIN)
- @actor.add_sparam(3, DPB::PSPDS::OPTION_2_PHA_GAIN)
- @actor.add_sparam(4, DPB::PSPDS::OPTION_2_MCR_GAIN)
- @actor.add_sparam(5, DPB::PSPDS::OPTION_2_TCR_GAIN)
- @actor.add_sparam(6, DPB::PSPDS::OPTION_2_PDR_GAIN)
- @actor.add_sparam(7, DPB::PSPDS::OPTION_2_MDR_GAIN)
- @actor.add_sparam(8, DPB::PSPDS::OPTION_2_FDR_GAIN)
- @actor.add_sparam(9, DPB::PSPDS::OPTION_2_EXR_GAIN)
- #end inc stat
- @help_window.set_text(DPB::PSPDS::ADDSTATTEXT)
- else
- @help_window.set_text(DPB::PSPDS::NOPOINTSTEXT)
- end
- @status_window.refresh
- @command_window.refresh
- wait(25)
- @command_window.activate
- end
- #--------
- def command_gain_dex
- index = @command_window.index
- @command_window.refresh
- if @actor.level_up_pts >= @actor.cost_caract(index)
- @actor.gain_lvl_pts(-@actor.cost_caract(index))
- @actor.gain_dex_pts($dexpts)
- #reg's
- @actor.add_param(0, DPB::PSPDS::OPTION_3_MaxHP_GAIN)
- @actor.add_param(1, DPB::PSPDS::OPTION_3_MaxMP_GAIN)
- @actor.add_param(2, DPB::PSPDS::OPTION_3_ATK_GAIN)
- @actor.add_param(3, DPB::PSPDS::OPTION_3_DEF_GAIN)
- @actor.add_param(4, DPB::PSPDS::OPTION_3_MAT_GAIN)
- @actor.add_param(5, DPB::PSPDS::OPTION_3_MDF_GAIN)
- @actor.add_param(6, DPB::PSPDS::OPTION_3_AGI_GAIN)
- @actor.add_param(7, DPB::PSPDS::OPTION_3_LUK_GAIN)
- #x's
- @actor.add_xparam(0, DPB::PSPDS::OPTION_3_HIT_GAIN)
- @actor.add_xparam(1, DPB::PSPDS::OPTION_3_EVA_GAIN)
- @actor.add_xparam(2, DPB::PSPDS::OPTION_3_CRI_GAIN)
- @actor.add_xparam(3, DPB::PSPDS::OPTION_3_CEV_GAIN)
- @actor.add_xparam(4, DPB::PSPDS::OPTION_3_MEV_GAIN)
- @actor.add_xparam(5, DPB::PSPDS::OPTION_3_MRF_GAIN)
- @actor.add_xparam(6, DPB::PSPDS::OPTION_3_CNT_GAIN)
- @actor.add_xparam(7, DPB::PSPDS::OPTION_3_HRG_GAIN)
- @actor.add_xparam(8, DPB::PSPDS::OPTION_3_MRG_GAIN)
- @actor.add_xparam(9, DPB::PSPDS::OPTION_3_TRG_GAIN)
- #s's
- @actor.add_sparam(0, DPB::PSPDS::OPTION_3_TGR_GAIN)
- @actor.add_sparam(1, DPB::PSPDS::OPTION_3_GRD_GAIN)
- @actor.add_sparam(2, DPB::PSPDS::OPTION_3_REC_GAIN)
- @actor.add_sparam(3, DPB::PSPDS::OPTION_3_PHA_GAIN)
- @actor.add_sparam(4, DPB::PSPDS::OPTION_3_MCR_GAIN)
- @actor.add_sparam(5, DPB::PSPDS::OPTION_3_TCR_GAIN)
- @actor.add_sparam(6, DPB::PSPDS::OPTION_3_PDR_GAIN)
- @actor.add_sparam(7, DPB::PSPDS::OPTION_3_MDR_GAIN)
- @actor.add_sparam(8, DPB::PSPDS::OPTION_3_FDR_GAIN)
- @actor.add_sparam(9, DPB::PSPDS::OPTION_3_EXR_GAIN)
- #end inc stat
- @help_window.set_text(DPB::PSPDS::ADDSTATTEXT)
- else
- @help_window.set_text(DPB::PSPDS::NOPOINTSTEXT)
- end
- @status_window.refresh
- @command_window.refresh
- wait(25)
- @command_window.activate
- end
- #--------
- def command_gain_mag
- index = @command_window.index
- @command_window.refresh
- if @actor.level_up_pts >= @actor.cost_caract(index)
- @actor.gain_lvl_pts(-@actor.cost_caract(index))
- @actor.gain_mag_pts($magpts)
- #reg's
- @actor.add_param(0, DPB::PSPDS::OPTION_4_MaxHP_GAIN)
- @actor.add_param(1, DPB::PSPDS::OPTION_4_MaxMP_GAIN)
- @actor.add_param(2, DPB::PSPDS::OPTION_4_ATK_GAIN)
- @actor.add_param(3, DPB::PSPDS::OPTION_4_DEF_GAIN)
- @actor.add_param(4, DPB::PSPDS::OPTION_4_MAT_GAIN)
- @actor.add_param(5, DPB::PSPDS::OPTION_4_MDF_GAIN)
- @actor.add_param(6, DPB::PSPDS::OPTION_4_AGI_GAIN)
- @actor.add_param(7, DPB::PSPDS::OPTION_4_LUK_GAIN)
- #x's
- @actor.add_xparam(0, DPB::PSPDS::OPTION_4_HIT_GAIN)
- @actor.add_xparam(1, DPB::PSPDS::OPTION_4_EVA_GAIN)
- @actor.add_xparam(2, DPB::PSPDS::OPTION_4_CRI_GAIN)
- @actor.add_xparam(3, DPB::PSPDS::OPTION_4_CEV_GAIN)
- @actor.add_xparam(4, DPB::PSPDS::OPTION_4_MEV_GAIN)
- @actor.add_xparam(5, DPB::PSPDS::OPTION_4_MRF_GAIN)
- @actor.add_xparam(6, DPB::PSPDS::OPTION_4_CNT_GAIN)
- @actor.add_xparam(7, DPB::PSPDS::OPTION_4_HRG_GAIN)
- @actor.add_xparam(8, DPB::PSPDS::OPTION_4_MRG_GAIN)
- @actor.add_xparam(9, DPB::PSPDS::OPTION_4_TRG_GAIN)
- #s's
- @actor.add_sparam(0, DPB::PSPDS::OPTION_4_TGR_GAIN)
- @actor.add_sparam(1, DPB::PSPDS::OPTION_4_GRD_GAIN)
- @actor.add_sparam(2, DPB::PSPDS::OPTION_4_REC_GAIN)
- @actor.add_sparam(3, DPB::PSPDS::OPTION_4_PHA_GAIN)
- @actor.add_sparam(4, DPB::PSPDS::OPTION_4_MCR_GAIN)
- @actor.add_sparam(5, DPB::PSPDS::OPTION_4_TCR_GAIN)
- @actor.add_sparam(6, DPB::PSPDS::OPTION_4_PDR_GAIN)
- @actor.add_sparam(7, DPB::PSPDS::OPTION_4_MDR_GAIN)
- @actor.add_sparam(8, DPB::PSPDS::OPTION_4_FDR_GAIN)
- @actor.add_sparam(9, DPB::PSPDS::OPTION_4_EXR_GAIN)
- #end inc stat
- @help_window.set_text(DPB::PSPDS::ADDSTATTEXT)
- else
- @help_window.set_text(DPB::PSPDS::NOPOINTSTEXT)
- end
- @status_window.refresh
- @command_window.refresh
- wait(25)
- @command_window.activate
- end
- #--------
- def wait(time)
- t = 0
- loop do
- Graphics.update
- if t == time
- break
- end
- t += 1
- end
- end
- #--------
- def update
- super
- @help_window.set_text(msg[@command_window.index])
- end
- #--------
- def on_actor_change
- @status_window.actor = @actor
- @status_window.refresh
- @command_window.activate
- end
- end
- #--------
- if DPB::PSPDS::INBATTLE
- class Scene_Battle < Scene_Base # < Default setting. Only used when "INBATTLE" is true
- alias old_update update
- def update
- old_update
- if $game_temp.actor_level_up[0]
- SceneManager.call(Scene_Level_Up)
- end
- end
- end
- end
- #--------
- if DPB::PSPDS::ONMAP
- class Scene_Map < Scene_Base # < Only used if "ONMAP" is true
- alias old_update update
- def update
- old_update
- if $game_temp.actor_level_up[0]
- SceneManager.call(Scene_Level_Up)
- end
- end
- end
- end
- #--------
- class Game_Actor < Game_Battler
- attr_reader :level_up_pts
- attr_reader :vit_pts
- attr_reader :str_pts
- attr_reader :dex_pts
- attr_reader :mag_pts
- alias old_initialize initialize
- def initialize(actor_id)
- old_initialize(actor_id)
- @level_up_pts = 0
- @vit_pts = 0
- @str_pts = 0
- @dex_pts = 0
- @mag_pts = 0
- end
- #--------
- def cost_caract(param)
- tbl = [DPB::PSPDS::OPTION_1_COST,
- DPB::PSPDS::OPTION_2_COST,
- DPB::PSPDS::OPTION_3_COST,
- DPB::PSPDS::OPTION_4_COST,
- 0,
- 0,
- 0,
- 0] # DO NOT MODIFY THIS
- note = $data_classes[@class_id].note
- note.each_line do |line|
- if line.include?("<cost_caract>")
- line2 = line.gsub!("<cost_caract> ","")
- tbl = eval(line2)
- end
- end
- return tbl[param]
- end
- #========================
- def gain_lvl_pts(value)
- @level_up_pts += value
- if @level_up_pts < 0
- @level_up_pts = 0
- end
- end
- #=======================
- def gain_vit_pts(value)
- @vit_pts += value
- if @vit_pts < 0
- @vit_pts = 0
- end
- end
- #--------
- def gain_str_pts(value)
- @str_pts += value
- if @str_pts < 0
- @str_pts = 0
- end
- end
- #--------
- def gain_dex_pts(value)
- @dex_pts += value
- if @dex_pts < 0
- @dex_pts = 0
- end
- end
- #--------
- def gain_mag_pts(value)
- @mag_pts += value
- if @mag_pts < 0
- @mag_pts = 0
- end
- end
- #========================
- def param_base(param_id)
- if DPB::PSPDS::USE_DEFAULT_PARAM_GAIN
- return self.class.params[param_id, @level]
- else
- return self.class.params[param_id, 1]
- end
- end
- #========================
- if DPB::PSPDS::ONLY_GAIN_POINTS_ON_LEVELS
- def level_up
- @level += 1
- $game_temp.actor_level_up.push(self) unless $game_temp.actor_level_up.include?(self)
- self.class.learnings.each do |learning|
- learn_skill(learning.skill_id) if learning.level == @level
- end
- if DPB::PSPDS::BONUS_POINTS_ON_LEVELS
- return unless DPB::PSPDS::LEVELS.include?(@level)
- gain_lvl_pts($bonuspts)
- else
- end
- end
- else
- def level_up
- @level += 1
- $game_temp.actor_level_up.push(self) unless $game_temp.actor_level_up.include?(self)
- self.class.learnings.each do |learning|
- learn_skill(learning.skill_id) if learning.level == @level
- end
- gain_lvl_pts($pts)
- if DPB::PSPDS::BONUS_POINTS_ON_LEVELS
- return unless DPB::PSPDS::LEVELS.include?(@level)
- gain_lvl_pts($bonuspts)
- else
- end
- end
- end
- end # Game_Actor
- #========================
- class Game_Temp
- attr_accessor :actor_level_up
- alias old_initialize initialize
- def initialize
- old_initialize
- @actor_level_up = []
- end
- end
- #========================
- class Game_Interpreter
- def gain_pts(actor_id, value)
- actor = $game_actors[actor_id]
- return if actor == nil
- actor.gain_lvl_pts(value)
- end
- #--------
- def inc_vit(actor_id, value)
- actor = $game_actors[actor_id]
- return if actor == nil
- actor.gain_vit_pts(value)
- end
- #--------
- def inc_str(actor_id, value)
- actor = $game_actors[actor_id]
- return if actor == nil
- actor.gain_str_pts(value)
- end
- #--------
- def inc_dex(actor_id, value)
- actor = $game_actors[actor_id]
- return if actor == nil
- actor.gain_dex_pts(value)
- end
- #--------
- def inc_mag(actor_id, value)
- actor = $game_actors[actor_id]
- return if actor == nil
- actor.gain_mag_pts(value)
- end
- end
- #========================
- if DPB::PSPDS::COMPLETELY_DISABLE_MENU_OPTION
- else
- #==============================================================================
- # Window_MenuCommand
- #==============================================================================
- class Window_MenuCommand < Window_Command
- #--------------------------------------------------------------------------
- # alias method: add_formation_command
- #--------------------------------------------------------------------------
- alias window_menucommand_add_formation_command_pspds add_formation_command
- def add_formation_command
- add_pspds_command unless $imported["DPB-PMS"]
- window_menucommand_add_formation_command_pspds
- end
- #--------------------------------------------------------------------------
- # new method: add_class_command
- #--------------------------------------------------------------------------
- def add_pspds_command
- return unless Switch.pspds_show
- text = DPB::PSPDS::MENU_COMMAND_NAME
- add_command(text, :pspds, Switch.pspds_enable)
- end
- end # Window_MenuCommand
- #==============================================================================
- # Scene_Menu
- #==============================================================================
- class Scene_Menu < Scene_MenuBase
- #--------------------------------------------------------------------------
- # alias method: create_command_window
- #--------------------------------------------------------------------------
- alias scene_menu_create_command_window_pspds create_command_window
- def create_command_window
- scene_menu_create_command_window_pspds
- @command_window.set_handler(:pspds, method(:command_personal))
- end
- #--------------------------------------------------------------------------
- # alias method: on_personal_ok
- #--------------------------------------------------------------------------
- alias scene_menu_on_personal_ok_pspds on_personal_ok
- def on_personal_ok
- case @command_window.current_symbol
- when :pspds
- SceneManager.call(Scene_Level_Up)
- else
- scene_menu_on_personal_ok_pspds
- end
- end
- end # Scene_Menu
- end
- #==============================================================================
- # Window_Level_UpCommand
- #==============================================================================
- class Window_Level_upCommand < Window_Command
- #--------------------------------------------------------------------------
- # * Object Initialization
- #--------------------------------------------------------------------------
- def initialize
- @actor = $game_temp.actor_level_up[0]
- super(0, 300)
- @@last_command_symbol = nil
- select_last
- self.opacity = 0
- end
- #--------------------------------------------------------------------------
- # * Get Window Width
- #--------------------------------------------------------------------------
- def window_width
- return DPB::PSPDS::COMMAND_COLUMN_WIDTH
- end
- #--------------------------------------------------------------------------
- # * Get Window Height
- #--------------------------------------------------------------------------
- def window_height
- return 344
- end
- #--------------------------------------------------------------------------
- # * Get Number of Lines to Show
- #--------------------------------------------------------------------------
- def visible_line_number
- item_max
- end
- #--------------------------------------------------------------------------
- # * Create Command Window
- #--------------------------------------------------------------------------
- def make_command_list
- for command in DPB::PSPDS::COMMANDS
- case command
- when :Vitality
- add_command("", :gain_vit, true)
- when :Strength
- add_command("", :gain_str, true)
- when :Dexterity
- add_command("", :gain_dex, true)
- when :Magic
- add_command("", :gain_mag, true)
- if DPB::PSPDS::EXIT_BEFORE_POINTS_SPENT
- :Finish
- add_command(DPB::PSPDS::FINISHVOCAB, :retour, true)
- else
- :Finish
- add_command(DPB::PSPDS::FINISHVOCAB, :retour, @actor.level_up_pts <= 0)
- end
- end
- end
- end
- #--------------------------------------------------------------------------
- # * Processing When OK Button Is Pressed
- #--------------------------------------------------------------------------
- def process_ok
- @@last_command_symbol = current_symbol
- super
- end
- def select_last
- select_symbol(@@last_command_symbol)
- end
- end
- #==============================================================================
- # ** Window_Status
- #------------------------------------------------------------------------------
- # This window displays full status specs on the status screen.
- #==============================================================================
- class Window_Status_Level_up < Window_Selectable
- #--------------------------------------------------------------------------
- # * Object Initialization
- #--------------------------------------------------------------------------
- def initialize(actor)
- super(-50, -50, window_width, window_height)
- contents.font.size = DPB::PSPDS::FONTSIZE
- @actor = actor
- refresh
- activate
- end
- #--------------------------------------------------------------------------
- # window_width
- #--------------------------------------------------------------------------
- def window_width; return Graphics.width - 0; end
- #--------------------------------------------------------------------------
- # window_height
- #--------------------------------------------------------------------------
- def window_height; return Graphics.height - 0; end
- #--------------------------------------------------------------------------
- # * Set Actor
- #--------------------------------------------------------------------------
- def actor=(actor)
- return if @actor == actor
- @actor = actor
- refresh
- end
- #--------------------------------------------------------------------------
- # * Refresh
- #--------------------------------------------------------------------------
- def refresh
- contents.clear
- draw_block1(line_height * 1)
- draw_block2(line_height * 1)
- draw_block3(line_height * 3)
- contents.font.size = 24
- contents.font.size = DPB::PSPDS::FONTSIZE
- end
- #--------------------------------------------------------------------------
- # * Draw Block 1
- #--------------------------------------------------------------------------
- def draw_block1(y)
- draw_actor_face(@actor, (window_width - 24) / 2.5, 0)
- contents.font.size = 22
- draw_actor_name(@actor,(window_width + 24) / 2, line_height * 0)
- contents.font.size = DPB::PSPDS::FONTSIZE
- draw_actor_class(@actor, (window_width + 24) / 2, line_height * 1.6)
- if DPB::PSPDS::DRAW_ACTOR_GRAPHIC
- draw_actor_graphic(@actor, DPB::PSPDS::DAG_X, DPB::PSPDS::DAG_Y)#, 50)
- else
- end
- end
- #--------------------------------------------------------------------------
- # * Draw Block 2
- #--------------------------------------------------------------------------
- def draw_block2(y)
- draw_basic_info(32, y)
- draw_exp_info(4, y+line_height * 7)
- end
- #--------------------------------------------------------------------------
- # * Draw Block 3
- #--------------------------------------------------------------------------
- def draw_block3(y)
- # draw_parameter_graph
- end
- #--------------------------------------------------------------------------
- # * Draw Horizontal Line
- #--------------------------------------------------------------------------
- def draw_horz_line(y)
- line_y = y + line_height / 2 - 1
- contents.fill_rect(0, line_y, contents_width, 2, line_color)
- end
- #--------------------------------------------------------------------------
- # * Get Color of Horizontal Line
- #--------------------------------------------------------------------------
- def line_color
- color = normal_color
- color.alpha = 48
- color
- end
- #--------------------------------------------------------------------------
- # * Draw Experience Information
- #--------------------------------------------------------------------------
- def draw_exp_info(x, y)
- contents.font.size = DPB::PSPDS::FONTSIZE
- s1 = @actor.max_level? ? "----" : @actor.exp
- s2 = @actor.max_level? ? "----" : @actor.next_level_exp - @actor.exp
- s_next = sprintf(Vocab::ExpNext, Vocab::level)
- change_color(system_color)
- draw_text((window_width - 24) / 4 * 3, y-140, 180, line_height, "Next Level")
- draw_text((window_width - 24) / 4 * 3, y-170, 180, line_height, "TOTAL Exp")
- change_color(normal_color)
- draw_text((window_width - 24) / 1.7, y-155, 180, line_height, s1, 2)
- draw_text((window_width - 24) / 1.7, y-120, 180, line_height, s2, 2)
- end
- end
- #--------------------------------------------------------------------------
- # * Draw Parameters
- #--------------------------------------------------------------------------
- def draw_parameters(x, y)
- 6.times {|i| draw_actor_param(@actor, x, y + 7 + line_height * i, i + 2) }
- end
- if DPB::PSPDS::DRAW_ALL_COLUMNS
- #--------------------------------------------------------------------------
- # draw_parameter_graph
- #--------------------------------------------------------------------------
- def draw_parameter_graph
- dy = line_height * 3/2
- maximum = 1
- minimum = @actor.param_max(2)
- for i in 2..7
- maximum = [@actor.param(i), maximum].max
- minimum = [@actor.param(i), minimum].min
- end
- maximum += minimum * 0.33 unless maximum == minimum
- for i in 2..7
- rate = calculate_rate(maximum, minimum, i)
- dy = line_height * i - line_height/2
- draw_param_gauge(i, dy, rate)
- self.contents.font.size = DPB::PSPDS::PARAMFONTSIZE
- change_color(system_color)
- draw_text(5, dy + 140, contents.width - 56, line_height, Vocab::param(i))
- dw = (contents.width - 48) * rate - 8
- change_color(normal_color)
- draw_text((window_width - 24) / 4 - 24, dy + 140, dw-8, line_height, @actor.param(i))#.group, 2)
- end
- end
- else
- #--------------------------------------------------------------------------
- # draw_parameter_graph
- #--------------------------------------------------------------------------
- def draw_parameter_graph
- dy = line_height * 3/2
- maximum = 1
- minimum = @actor.param_max(2)
- for i in 2..7
- maximum = [@actor.param(i), maximum].max
- minimum = [@actor.param(i), minimum].min
- end
- maximum += minimum * 0.33 unless maximum == minimum
- for i in 2..7
- rate = calculate_rate(maximum, minimum, i)
- dy = line_height * i - line_height/2
- draw_param_gauge(i, dy, rate)
- self.contents.font.size = DPB::PSPDS::PARAMFONTSIZE
- change_color(system_color)
- draw_text(5, dy + 140, contents.width - 56, line_height, Vocab::param(i))
- dw = (contents.width - 48) * rate - 8
- change_color(normal_color)
- draw_text((window_width - 60) / 3 - 24, dy + 140, dw-8, line_height, @actor.param(i))#.group, 2)
- end
- end
- end
- #--------------------------------------------------------------------------
- # calculate_rate
- #--------------------------------------------------------------------------
- def calculate_rate(maximum, minimum, param_id)
- return 1.0 if maximum == minimum
- rate = (@actor.param(param_id).to_f - minimum) / (maximum - minimum).to_f
- rate *= 0.67
- rate += 0.33
- return rate
- end
- if DPB::PSPDS::DRAW_ALL_COLUMNS
- #--------------------------------------------------------------------------
- # draw_param_gauge
- #--------------------------------------------------------------------------
- def draw_param_gauge(param_id, dy, rate)
- dw = (window_width - 24) / 4 - 12
- colour1 = param_gauge1(param_id)
- colour2 = param_gauge2(param_id)
- draw_gauge(5, dy + 140, dw, rate, colour1, colour2)
- end
- else
- #--------------------------------------------------------------------------
- # draw_param_gauge
- #--------------------------------------------------------------------------
- def draw_param_gauge(param_id, dy, rate)
- dw = (window_width - 24) / 3 - 24
- colour1 = param_gauge1(param_id)
- colour2 = param_gauge2(param_id)
- draw_gauge(5, dy + 140, dw, rate, colour1, colour2)
- end
- end
- #--------------------------------------------------------------------------
- # param_gauge1
- #--------------------------------------------------------------------------
- def param_gauge1(param_id)
- return DPB::PSPDS::PARAM_COLOUR[param_id][1]
- end
- #--------------------------------------------------------------------------
- # param_gauge2
- #--------------------------------------------------------------------------
- def param_gauge2(param_id)
- return DPB::PSPDS::PARAM_COLOUR[param_id][2]
- end
- #--------------------------------------------------------------------------
- # * Draw Basic Information
- #--------------------------------------------------------------------------
- def draw_basic_info(x, y)
- draw_actor_level(@actor, (window_width + 24) / 2, line_height * 0.8)
- draw_level_up_pts(x+200, y + line_height * 7)
- draw_actor_icons(@actor, (window_width - 24) / 2.5, y + line_height * 3)
- contents.font.size = DPB::PSPDS::FONTSIZE
- if DPB::PSPDS::DRAW_PARAM_GAUGES
- draw_parameter_graph
- if DPB::PSPDS::DRAW_ALL_COLUMNS
- draw_actor_hp(@actor, 5, y+106 + line_height * 0,(window_width - 24) / 4 - 12)
- draw_actor_mp(@actor, 5, y+106 + line_height * 1,(window_width - 24) / 4 - 12)
- else
- draw_actor_hp(@actor, 5, y+106 + line_height * 0,(window_width - 24) / 3 - 24)
- draw_actor_mp(@actor, 5, y+106 + line_height * 1,(window_width - 24) / 3 - 24)
- end
- else
- draw_properties_paramcolumn
- end
- contents.font.size = DPB::PSPDS::PROPFONTSIZE
- draw_horz_line(line_height * 4.6)
- draw_horz_line(Graphics.height - line_height * 4)
- draw_new_stats_column
- draw_properties_column1
- draw_properties_column2
- if DPB::PSPDS::DRAW_ALL_COLUMNS
- draw_properties_column3
- else
- end
- reset_font_settings
- if $imported["YEA-JPManager"]
- contents.font.size = DPB::PSPDS::PARAMFONTSIZE
- draw_actor_jp(@actor, (window_width + 24) / 3, line_height * 3.33)
- contents.font.size = DPB::PSPDS::PROPFONTSIZE
- else
- end
- end
- def draw_level_up_pts(x,y)
- contents.font.size = DPB::PSPDS::FONTSIZE + 4
- draw_text((window_width) / 2.5, 4 + line_height * 4,180,line_height,DPB::PSPDS::LVLUPPTSVOCAB + @actor.level_up_pts.to_s)
- end
- #========================
- if DPB::PSPDS::DRAW_ALL_COLUMNS
- #--------------------------------------------------------------------------
- # draw__new_stats_column
- #--------------------------------------------------------------------------
- def draw_new_stats_column
- dx = 0
- dw = (window_width - 24) / 5
- dy = 0
- for property in DPB::PSPDS::NEW_STATS_COLUMN
- dy = draw_property(property, dx, dy, dw)
- end
- end
- #--------------------------------------------------------------------------
- # draw_properties_column1
- #--------------------------------------------------------------------------
- def draw_properties_column1
- dx = 5 + (window_width - 24) / 4
- dw = (window_width - 24) / 3.6 - 24
- dy = 130
- for property in DPB::PSPDS::PROPERTIES_COLUMN1
- dy = draw_property(property, dx, dy, dw)
- end
- end
- #--------------------------------------------------------------------------
- # draw_properties_column2
- #--------------------------------------------------------------------------
- def draw_properties_column2
- dx = 5 + (window_width - 24) / 2
- dw = (window_width - 24) / 3.6 - 24
- dy = 130
- for property in DPB::PSPDS::PROPERTIES_COLUMN2
- dy = draw_property(property, dx, dy, dw)
- end
- end
- #--------------------------------------------------------------------------
- # draw_properties_column3
- #--------------------------------------------------------------------------
- def draw_properties_column3
- dx = 5 + (window_width - 24) / 2 + (window_width / 4.15)
- dw = (window_width - 24) / 3.6 - 24
- dy = 130
- for property in DPB::PSPDS::PROPERTIES_COLUMN3
- dy = draw_property(property, dx, dy, dw)
- end
- end
- #--------------------------------------------------------------------------
- # draw_properties_column4
- #--------------------------------------------------------------------------
- def draw_properties_paramcolumn
- dx = 5
- dw = (window_width - 24) / 3.6 - 24
- dy = 130
- for property in DPB::PSPDS::PROPERTIES_PARAMCOLUMN
- dy = draw_property(property, dx, dy, dw)
- end
- end
- else
- #--------------------------------------------------------------------------
- # draw__new_stats_column
- #--------------------------------------------------------------------------
- def draw_new_stats_column
- dx = 0
- dw = (window_width - 24) / 5
- dy = 0
- for property in DPB::PSPDS::NEW_STATS_COLUMN
- dy = draw_property(property, dx, dy, dw)
- end
- end
- #--------------------------------------------------------------------------
- # draw_properties_column1
- #--------------------------------------------------------------------------
- def draw_properties_column1
- dx = 5 + (window_width - 24) / 3
- dw = (window_width - 24) / 3 - 12
- dy = 130
- for property in DPB::PSPDS::PROPERTIES_COLUMN1
- dy = draw_property(property, dx, dy, dw)
- end
- end
- #--------------------------------------------------------------------------
- # draw_properties_column2
- #--------------------------------------------------------------------------
- def draw_properties_column2
- dx = 5 + (window_width - 24) / 3 * 2
- dw = (window_width - 24) / 3 - 12
- dy = 130
- for property in DPB::PSPDS::PROPERTIES_COLUMN2
- dy = draw_property(property, dx, dy, dw)
- end
- end
- #--------------------------------------------------------------------------
- # draw_properties_column4
- #--------------------------------------------------------------------------
- def draw_properties_paramcolumn
- dx = 5
- dw = (window_width - 24) / 3 - 12
- dy = 130
- for property in DPB::PSPDS::PROPERTIES_PARAMCOLUMN
- dy = draw_property(property, dx, dy, dw)
- end
- end
- end
- if DPB::PSPDS::PROPERTIES_BIGGER_NUMBERS
- #--------------------------------------------------------------------------
- # draw_property
- #--------------------------------------------------------------------------
- def draw_property(property, dx, dy, dw)
- fmt = "%1.2f%%"
- dpb = "%1.0f"
- case property[0]
- #---
- when :mhp
- value = sprintf(dpb, @actor.mhp)
- when :mmp
- value = sprintf(dpb, @actor.mmp)
- when :atk
- value = sprintf(dpb, @actor.atk * DPB::PSPDS::PARAMS_BIGGER_NUMBER_VALUE)
- when :def
- value = sprintf(dpb, @actor.def * DPB::PSPDS::PARAMS_BIGGER_NUMBER_VALUE)
- when :mat
- value = sprintf(dpb, @actor.mat * DPB::PSPDS::PARAMS_BIGGER_NUMBER_VALUE)
- when :mdf
- value = sprintf(dpb, @actor.mdf * DPB::PSPDS::PARAMS_BIGGER_NUMBER_VALUE)
- when :agi
- value = sprintf(dpb, @actor.agi * DPB::PSPDS::PARAMS_BIGGER_NUMBER_VALUE)
- when :luk
- value = sprintf(dpb, @actor.luk * DPB::PSPDS::PARAMS_BIGGER_NUMBER_VALUE)
- when :vit_pts
- value = sprintf(dpb, @actor.vit_pts)
- when :str_pts
- value = sprintf(dpb, @actor.str_pts)
- when :dex_pts
- value = sprintf(dpb, @actor.dex_pts)
- when :mag_pts
- value = sprintf(dpb, @actor.mag_pts)
- when :hit
- value = sprintf(dpb, @actor.hit * DPB::PSPDS::PROPERTIES_BIGGER_NUMBER_VALUE)
- when :eva
- value = sprintf(dpb, @actor.eva * DPB::PSPDS::PROPERTIES_BIGGER_NUMBER_VALUE)
- when :cri
- value = sprintf(fmt, @actor.cri * 100)
- when :cev
- value = sprintf(dpb, @actor.cev * DPB::PSPDS::PROPERTIES_BIGGER_NUMBER_VALUE)
- when :mev
- value = sprintf(dpb, @actor.mev * DPB::PSPDS::PROPERTIES_BIGGER_NUMBER_VALUE)
- when :mrf
- value = sprintf(fmt, @actor.mrf * 100)
- when :cnt
- value = sprintf(fmt, @actor.cnt * 100)
- when :hrg
- value = sprintf(fmt, @actor.hrg * 100)
- when :mrg
- value = sprintf(fmt, @actor.mrg * 100)
- when :trg
- value = sprintf(fmt, @actor.trg * 100)
- when :tgr
- value = sprintf(fmt, @actor.tgr * 100)
- when :grd
- value = sprintf(fmt, @actor.grd * 100)
- when :rec
- value = sprintf(fmt, @actor.rec * 100)
- when :pha
- value = sprintf(fmt, @actor.pha * 100)
- when :mcr
- value = sprintf(fmt, @actor.mcr * 100)
- when :tcr
- value = sprintf(fmt, @actor.tcr * 100)
- when :pdr
- value = sprintf(fmt, @actor.pdr * 100)
- when :mdr
- value = sprintf(fmt, @actor.mdr * 100)
- when :fdr
- value = sprintf(fmt, @actor.fdr * 100)
- when :exr
- value = sprintf(fmt, @actor.exr * 100)
- when :hcr
- return dy unless $imported["YEA-SkillCostManager"]
- value = sprintf(fmt, @actor.hcr * 100)
- when :tcr_y
- return dy unless $imported["YEA-SkillCostManager"]
- value = sprintf(fmt, @actor.tcr_y * 100)
- when :gcr
- return dy unless $imported["YEA-SkillCostManager"]
- value = sprintf(fmt, @actor.gcr * 100)
- when :cdr
- return dy unless $imported["YEA-SkillRestrictions"]
- value = sprintf(fmt, @actor.cdr * 100)
- when :wur
- return dy unless $imported["YEA-SkillRestrictions"]
- value = sprintf(fmt, @actor.wur * 100)
- #---
- else; return dy
- end
- colour = Color.new(0, 0, 0, translucent_alpha/2)
- rect = Rect.new(dx+1, dy+1, dw-2, line_height-2)
- contents.fill_rect(rect, colour)
- change_color(system_color)
- draw_text(dx+4, dy, dw-8, line_height, property[1], 0)
- change_color(normal_color)
- draw_text(dx+4, dy, dw-8, line_height, value, 2)
- return dy + line_height
- end
- else
- #--------------------------------------------------------------------------
- # draw_property
- #--------------------------------------------------------------------------
- def draw_property(property, dx, dy, dw)
- fmt = "%1.2f%%"
- dpb = "%1.0f"
- case property[0]
- #---
- when :mhp
- value = sprintf(dpb, @actor.mhp)
- when :mmp
- value = sprintf(dpb, @actor.mmp)
- when :atk
- value = sprintf(dpb, @actor.atk)
- when :def
- value = sprintf(dpb, @actor.def)
- when :mat
- value = sprintf(dpb, @actor.mat)
- when :mdf
- value = sprintf(dpb, @actor.mdf)
- when :agi
- value = sprintf(dpb, @actor.agi)
- when :luk
- value = sprintf(dpb, @actor.luk)
- when :vit_pts
- value = sprintf(dpb, @actor.vit_pts)
- when :str_pts
- value = sprintf(dpb, @actor.str_pts)
- when :dex_pts
- value = sprintf(dpb, @actor.dex_pts)
- when :mag_pts
- value = sprintf(dpb, @actor.mag_pts)
- when :hit
- value = sprintf(fmt, @actor.hit * 100)
- when :eva
- value = sprintf(fmt, @actor.eva * 100)
- when :cri
- value = sprintf(fmt, @actor.cri * 100)
- when :cev
- value = sprintf(fmt, @actor.cev * 100)
- when :mev
- value = sprintf(fmt, @actor.mev * 100)
- when :mrf
- value = sprintf(fmt, @actor.mrf * 100)
- when :cnt
- value = sprintf(fmt, @actor.cnt * 100)
- when :hrg
- value = sprintf(fmt, @actor.hrg * 100)
- when :mrg
- value = sprintf(fmt, @actor.mrg * 100)
- when :trg
- value = sprintf(fmt, @actor.trg * 100)
- when :tgr
- value = sprintf(fmt, @actor.tgr * 100)
- when :grd
- value = sprintf(fmt, @actor.grd * 100)
- when :rec
- value = sprintf(fmt, @actor.rec * 100)
- when :pha
- value = sprintf(fmt, @actor.pha * 100)
- when :mcr
- value = sprintf(fmt, @actor.mcr * 100)
- when :tcr
- value = sprintf(fmt, @actor.tcr * 100)
- when :pdr
- value = sprintf(fmt, @actor.pdr * 100)
- when :mdr
- value = sprintf(fmt, @actor.mdr * 100)
- when :fdr
- value = sprintf(fmt, @actor.fdr * 100)
- when :exr
- value = sprintf(fmt, @actor.exr * 100)
- when :hcr
- return dy unless $imported["YEA-SkillCostManager"]
- value = sprintf(fmt, @actor.hcr * 100)
- when :tcr_y
- return dy unless $imported["YEA-SkillCostManager"]
- value = sprintf(fmt, @actor.tcr_y * 100)
- when :gcr
- return dy unless $imported["YEA-SkillCostManager"]
- value = sprintf(fmt, @actor.gcr * 100)
- when :cdr
- return dy unless $imported["YEA-SkillRestrictions"]
- value = sprintf(fmt, @actor.cdr * 100)
- when :wur
- return dy unless $imported["YEA-SkillRestrictions"]
- value = sprintf(fmt, @actor.wur * 100)
- #---
- else; return dy
- end
- colour = Color.new(0, 0, 0, translucent_alpha/2)
- rect = Rect.new(dx+1, dy+1, dw-2, line_height-2)
- contents.fill_rect(rect, colour)
- change_color(system_color)
- draw_text(dx+4, dy, dw-8, line_height, property[1], 0)
- change_color(normal_color)
- draw_text(dx+4, dy, dw-8, line_height, value, 2)
- return dy + line_height
- end
- end
- #===============================================================================#
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★#
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆#
- # #
- # PSPDS #
- # (Perfect Stat Point Distribution System) #
- # - SCRIPT END - #
- # #
- # #
- #★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆#
- #☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★☆★#
- #===============================================================================#
- # - DekitaRPG@gmail.com - #
- #===============================================================================#
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement