a set of RGSS3 scripts that are useable. I will post all my scripts in one thread. I am taking requests, but for now keep it simple, I am very new to RGSS3 so the next ATBS is out. I know ruby, basically. with a background in programming I can figure most things out.
Lets get started shall we?
Note:Its better to grab the demo. RRR and the Blog posts seem to mess up my script formatting >_> So I have uploaded a demo which contains all the scripts here. and when I update or post a new script, I will also update the demo.
Blog: RGSS 3 Demo:Demo Credit?: Adam Balan (Adrien.) and Enterbrain.
#============================================================================== # ■ Adrien's Basic Shop # # Version 1.0 # Author: Adrien. (A.) #------------------------------------------------------------------------------ # The worlds most simple shop changer for prices you have ever seen. # essentially, set the module variables to the variables you want then # add values to those variables. # # TO DO: # It seems with variables, and I could be wrong that: if, elsif and else # does not like eachother in terms of dealing with one or more varaibles. # Thus the if statements you see bellow cannot be combined or things get # broken.... # # #==============================================================================
module STORE
#-------------------------------------------------------------------------- # ● VAR # --> INC = Variable you set + Value you set to that variable # --> MULT = Variable you set + Value you set to that variable #-------------------------------------------------------------------------- module VAR INC = 1 MULT = 3 end end
class Window_ShopBuy
#-------------------------------------------------------------------------- # ● price(item) # item : item # The value willchange based on the variables and their values. #-------------------------------------------------------------------------- alias adrien_price_change price def price(item) if $game_variables[STORE::VAR::INC] adrien_price_change(item) + $game_variables[STORE::VAR::INC] else adrien_price_change(item) end
if $game_variables[STORE::VAR::MULT] adrien_price_change(item) * $game_variables[STORE::VAR::MULT] else adrien_price_change(item) end
if $game_variables[STORE::VAR::MULT] && $game_variables[STORE::VAR::INC] (adrien_price_change(item) + $game_variables[STORE::VAR::INC]) * $game_variables[STORE::VAR::MULT] else adrien_price_change(item) end
end
end
Battle Add on
--> Plug and play --> Battle Add On -->Version: 1.1 -- See Script for notes -->Notes: Plug and Play
CODE
#============================================================================== # ■ Battle Extras # # # Author: Adrien. (A.) # Version: 1.1 # Comptaibility?: No issue? # # This script is used to change the out put of some things in battle its a plug # and play script which is extremly basic and simply by nature. Read each of the # module descriptions bellow to understand how to use. #------------------------------------------------------------------------------ # Credit: Regendo - Idea #------------------------------------------------------------------------------ # # Version 1.0 Initial Release # Version 1.1 # - Added new methods that allow better use and ease of use. # - Added reset exp method for after the battle regardless the out come # #------------------------------------------------------------------------------ # Instructions: # # Check out the module bellow and set your values accordingly. # you can now use $battle.mult_val(val) and $battle.div_val(val) # to change the exp out put the way you want it out put, this will then # reset after battle regardless of the out come. # #------------------------------------------------------------------------------ # Plug and Play #==============================================================================
module BATTLE
#-------------------------------------------------------------------------- # ● Multiply or Divide (or both) the exp gained from enemies. # --> If Divde and Multiply are given a value then # it will multiply and then divide the final total. #-------------------------------------------------------------------------- module EXP MULT = 2.6 DIV = 0.8 end
#-------------------------------------------------------------------------- # ● Multiply or Divide (or both) the gold gained from enemies. # --> If Divde and Multiply are given a value then # it will multiply and then divide the final total. #-------------------------------------------------------------------------- module GOLD MULT = 0 DIV = 0 end
#-------------------------------------------------------------------------- # ● Set Variables. # this will set all variables #-------------------------------------------------------------------------- module STATS MULT = 10 DIV = 11 end
end
class Battle
attr_accessor :exp_mult attr_accessor :exp_div
#-------------------------------------------------------------------------- # ● initialize # set the variables to be used as the default module varibles #-------------------------------------------------------------------------- def initialize @exp_mult = BATTLE::EXP::MULT @exp_div = BATTLE::EXP::DIV end
#-------------------------------------------------------------------------- # ● mult_val(val) # val : val #-------------------------------------------------------------------------- def mult_val(val) @exp_mult = mult_priv_val * val end
#-------------------------------------------------------------------------- # ● div_val(val) # val : val #-------------------------------------------------------------------------- def div_val(val) @exp_div = div_priv_val * val end
#-------------------------------------------------------------------------- # ● core_reset # just call initialize re-init the variables. #-------------------------------------------------------------------------- def core_reset initialize end
#-------------------------------------------------------------------------- # ● mult_priv_val # private method. # sets up the @exp variable for use in exp formula #-------------------------------------------------------------------------- def mult_priv_val if @exp_mult @exp_mult else @exp_mult = BATTLE::EXP::MULT end end
#-------------------------------------------------------------------------- # ● div_priv_val # private method. # sets up the @exp variable for use in the exp formula #-------------------------------------------------------------------------- def div_priv_val if @exp_div @exp_div else @exp_mult = BATTLE::EXP::DIV end end
private :mult_priv_val private :div_priv_val
end
module DataManager
#-------------------------------------------------------------------------- # ● create_game_objects # $battle is what you will use to call either: # $battle.mult_val(val) or $battle.div_val(val) #-------------------------------------------------------------------------- class< 0 (enemy.exp * $battle.exp_mult).to_i elsif BATTLE::EXP::DIV > 0 (enemy.exp / $battle.exp_div).to_i elsif BATTLE::EXP::DIV > 0 && BATTLE::EXP::MULT > 0 ((enemy.exp * $battle.exp_mult) / $battle.exp_div).to_i else adrien_change_enemy_exp end end
#-------------------------------------------------------------------------- # ● gold # Uses module set variables to multiply or divide the # amount of gold given after a battle. #-------------------------------------------------------------------------- alias adrien_change_gold_give gold def gold if BATTLE::GOLD::MULT > 0 (enemy.gold * BATTLE::GOLD::MULT).to_i elsif BATTLE::GOLD::DIV > 0 (enemy.gold / BATTLE::GOLD::DIV).to_i elsif BATTLE::GOLD::DIV > 0 && BATTLE::GOLD::MULT > 0 ((enemy.gold * BATTLE::GOLD::MULT) / BATTLE::GOLD::DIV).to_i else adrien_change_gold_give end end
#-------------------------------------------------------------------------- # ● param_base(param_id) # param_id : id of param # Used to set all the params of a individual enemy based on module # variables. #-------------------------------------------------------------------------- alias adrien_param_base param_base def param_base(param_id) if BATTLE::STATS::MULT > 0 (enemy.params[param_id] * $game_variables[BATTLE::STATS::MULT]).to_i elsif BATTLE::STATS::DIV > 0 (enemy.params[param_id] / $game_variables[BATTLE::STATS::DIV]).to_i elsif BATTLE::STATS::DIV > 0 && BATTLE::STATS::MULT > 0 ((enemy.params[param_id] * $game_variables[BATTLE::STATS::MULT]) / $game_vraiables[BATTLE::STATS::DIV]).to_i else adrien_param_base(param_id) end end
end
Window_Steps
--> Plug and play --> Show_NickName Post -->Version: 1.1 -- cleaned up the script -->Notes: Plug and Play
CODE
#============================================================================== # Window Steps Script #------------------------------------------------------------------------------ # Allows you to show the current amount of steps in the status menu when you # open up the menu via esc on the keyboard. # # Author: Adam Balan (Adrien., A.) # Incomptaibility?: Nothing. # Notes: plug and play. # Version 1.1 #==============================================================================
#============================================================================== # Module WindowVocab #------------------------------------------------------------------------------ # STEPS = name of the steps vocab. #==============================================================================
module WindowVocab STEPS = "steps" #name of the steps end
#============================================================================== # Window_Steps #------------------------------------------------------------------------------ #  Window Steps shows a steps window above the gold in the menu. #==============================================================================
class Window_Steps < Window_Base #-------------------------------------------------------------------------- # Initialize the class. #-------------------------------------------------------------------------- def initialize super(0, 0, 160, fitting_height(1)) refresh end
#-------------------------------------------------------------------------- # Refresh the box. #-------------------------------------------------------------------------- def refresh contents.clear draw_currency_value(value, currency_unit, 4, 0, contents.width - 8) end #-------------------------------------------------------------------------- # Get the value of the steps. #-------------------------------------------------------------------------- def value $game_party.steps end #-------------------------------------------------------------------------- # Define the Vocab. #-------------------------------------------------------------------------- def currency_unit WindowVocab::STEPS end end
#============================================================================== # Scene_Menu #------------------------------------------------------------------------------ # Create the Menu - we are only editing one method and adding a new. # # Alias: start method to add the steps window. #==============================================================================
class Scene_Menu < Scene_MenuBase
#-------------------------------------------------------------------------- # Alias: start method. #-------------------------------------------------------------------------- alias start_a start def start start_a create_steps_window end
--> Plug and play --> Show_NickName -->Version: 1.0 -->Notes: Plug and Play
CODE
#============================================================================== #============================================================================== # Show_NickName # # # Author: Adrien. (Adam Balan) # Version: 1.0 # # This script will show the nick name of the character in the status window. #============================================================================== #==============================================================================
#============================================================================== # Window_Base #------------------------------------------------------------------------------ #  We add nick name to the simple status #============================================================================== class Window_Base
#-------------------------------------------------------------------------- # Alias: Adrien_ShowNickName_draw_actor_simple_status -> Adds Nick Name. #-------------------------------------------------------------------------- alias adrien_shownickname_draw_actor_simple_status draw_actor_simple_status def draw_actor_simple_status(actor, x, y, *args) adrien_shownickname_draw_actor_simple_status(actor, x, y, *args) change_color(system_color) # Draw "Nick:" in the system colour draw_text(x, y+50, 50, line_height, "Nick:") draw_actor_nickname(actor, x+45, y+50) end
end
Info Window
--> Plug and play --> Show info box -->Version: 1.0 -->Notes: Plug and Play
I finally have a consistent template for coding. But RRR Breaks some of my formatting for special characters and apparently the script....For easier reading, until I upload a demo of my scripts. its best to get it from the blog post.
CODE
#============================================================================== # Script: Window_Show_InfoMap # Version: 1.0 # Notes: Plug and Play # Comptabilit?: None? # Author: Adam Balan (Adrien.) #============================================================================== # ♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♦♠¦â™¦â™¦â™¦â™¦ # #============================================================================== # ---> Updates <---- # 0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0-0 # # No Updates # #============================================================================== # ♦♦♦♦♦Introduction♦♦♦♦♦ # # # ♦-------Who/What/Why?-----♦ # # This script is meant to be a plug and play. # it will show a window on screeen that will # display level, gold, steps, Hp and Mp along wiht xp. # # # ♦-------How To Use?-------♦ # # # Plug and play # # ♦-------FAQ?--------------♦ # # None # #==============================================================================
#---------------------------------------------------------------# # # # Class: Window_Show_InfoMap # # Method: initialize, refresh, draw_window_content,# # update # # Alias: ---------------------------------- # # # # Notes: This creates, updates and maintains # # the box that appears on the map. # # This box will show party size, map name, # # gold and steps and updates in real time. # #---------------------------------------------------------------# class Window_Show_InfoMap < Window_Base
def update super sec = (Graphics.frame_count / Graphics.frame_rate) % 1 if sec > @total_sec % 1 or sec == 0 refresh end end
end
#---------------------------------------------------------------# # # # Class: Scene_Map # # Method: create_all_windows, create_show_informap # # Alias: adrien_create_all_windows_a1 # # # # Notes: Adds the information window # # to the map the player is on. # #---------------------------------------------------------------#