Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- =begin =========================================================================
- Dekita's v1.4
- ★ Perfect Status Screen™ ★
- ===============================================================================
- ☆ Script Information:
- =======================
- This script will Display necessary information regarding an actors stats,
- parameters, "Vitality", "Strength", "Dexterity" and "Magic".
- Also displays elemental/state resistances and attack values.
- NOTE: PAGEFOUR reffers to the fourth page of information i added, i have set it
- to display "PAGEFOUR" first, therefor PAGEFOUR = the first page you see on
- opening the status screen.
- NOTE: THIS SCRIPT REQUIRES "Dekita's - Perfect Stat Point Distribution System"
- ================================================================================
- ★☆★☆★☆★☆★☆★☆★☆★ TERMS AND CONDITIONS: ☆★☆★☆★☆★☆★☆★☆★☆★☆
- ================================================================================
- 1. You must give credit to "Dekita"
- 2. You are NOT allowed to repost this script.(or modified versions)
- 3. You are NOT allowed to convert this script.(into other game engines e.g RGSS2)
- 4. You are NOT allowed to use this script for Commercial games.
- 5. ENJOY!
- "FINE PRINT"
- By using this script you hereby agree to the above terms and conditions,
- if any violation of the above terms occurs "legal action" may be taken.
- Not understanding the above terms and conditions does NOT mean that
- they do not apply to you.
- If you wish to discuss the terms and conditions in further detail you can
- contact me at http://dekitarpg.wordpress.com/ or DekitaRPG@gmail.com
- ===============================================================================
- ☆ History:
- ============
- D - M - Y
- 20/09/2o12 - Updated script,(v1.4)
- Optimized coding,
- fixed pvari script calls,
- 27/08/2o12 - Added controlable variable info.v1.3
- 21/08/2o12 - Finished.(v1.2)
- 14/08/2o12 - Started modification for Dekita - Elements and states distribution.
- 11/08/2o12 - released Script. (v1.01)
- - Spiced up some shit
- - Added "Page Three" (outbound element and status info)
- 08/08/2o12 - Released Script. (v1.0)
- 07/08/2o12 - started script.
- ================================================================================
- ☆ INSTRUCTIONS:
- =================
- Place this script UNDER "▼ Materials" and ABOVE "▼ Main" in your script editor.
- Place this script UNDER "Dekita - Perfect Stat Point Distribution System".
- ===============================================================================
- ☆ Script Calls:
- =================
- Dont see why you would want to but you can use this script call to
- call the status screen.
- SceneManager.call(Scene_Status)
- Use the script call below to change an actors "Perfect information"
- change[x] for the information number, actor_id to actors database number
- and inset your text between the inverted comma's > " "
- pinfo[x](actor_id, " Text goes here ")
- e.g
- pinfo1(1, "This is an example")
- pinfo2(1, "This is an example")
- pinfo3(1, "This is an example")
- pinfo4(1, "This is an example")
- pinfo5(1, "This is an example")
- use this script call to change an actors perfect variable, use these as you see
- fit, you could do all sorts of things with them, e.g set a common event to run on
- an actors death, and use it as a death counter. whatever you want ^_^
- pvari[x](actor_id, value)
- e.g
- pvari1(1, 50)
- pvari2(1, 50)
- pvari3(1, 50)
- pvari4(1, 50)
- ================================================================================
- =end
- $imported = {} if $imported.nil?
- $imported[:Dekita__Status_Screen] = true
- #===============================================================================
- # ☆ Perfect Status Screen Begin:
- #================================
- module DPB ; module PSS
- COMMANDS =[
- [:pagefour, "IIII"],
- [:pageone, "I"],
- [:pagetwo, "II"],
- [:pagethree, "III"],
- ]#DO NOT REMOVE #######################
- # CUSTOMISATION BEGIN #
- #######################
- Actor_Info_Column =[
- [:name],
- [:nickname],
- [:class],
- [:level],
- [:exp_total],
- [:exp_to_next],
- [:death_counter], # Requires Dekita - Actor Death Counter
- [:atl],
- [:dfl],
- # [:pvari_1],
- ]#
- Page_Two_Info_Column_One =[
- [:mhp],
- [:mmp],
- [:mtp],# <- Requires - Dekita__TP_Limits
- [:atk],
- [:def],
- [:mat],
- [:mdf],
- [:agi],
- [:luk],
- ]#
- Page_Two_Info_Column_Two =[
- [:hit],
- [:eva],
- [:cri],
- [:cev],
- [:mev],
- [:mrf],
- [:cnt],
- [:hrg],
- [:mrg],
- # [:trg],# TP Regeneration rate
- ]#
- Page_Two_Info_Column_Three =[
- [:tgr],
- [:grd],
- [:rec],
- # [:pha], # Pharmacology rate
- [:mcr],
- [:tcr],
- [:pdr],
- [:mdr],
- [:exr],
- [:fdr],
- ]#
- Elements_Column_One =[
- [:element_slot_1],
- [:element_slot_2],
- [:element_slot_3],
- [:element_slot_4],
- [:element_slot_5],
- [:element_slot_6],
- [:element_slot_7],
- [:element_slot_8],
- [:element_slot_9],
- ]#
- States_Column_One =[
- [:status_slot_1],
- [:status_slot_2],
- [:status_slot_3],
- [:status_slot_4],
- [:status_slot_5],
- [:status_slot_6],
- [:status_slot_7],
- [:status_slot_8],
- [:status_slot_9],
- ]#
- States_Column_Two =[
- [:status_slot_1_row_2],
- [:status_slot_2_row_2],
- [:status_slot_3_row_2],
- [:status_slot_4_row_2],
- [:status_slot_5_row_2],
- [:status_slot_6_row_2],
- [:status_slot_7_row_2],
- [:status_slot_8_row_2],
- [:status_slot_9_row_2],
- ]#
- Attack_Elements_Column_One =[
- [:atk_element_slot_1],
- [:atk_element_slot_2],
- [:atk_element_slot_3],
- [:atk_element_slot_4],
- [:atk_element_slot_5],
- [:atk_element_slot_6],
- [:atk_element_slot_7],
- [:atk_element_slot_8],
- [:atk_element_slot_9],
- ]#
- Attack_States_Column_One =[
- [:atk_status_slot_1],
- [:atk_status_slot_2],
- [:atk_status_slot_3],
- [:atk_status_slot_4],
- [:atk_status_slot_5],
- [:atk_status_slot_6],
- [:atk_status_slot_7],
- [:atk_status_slot_8],
- [:atk_status_slot_9],
- ]#
- Attack_States_Column_Two =[
- [:atk_status_slot_1_row_2],
- [:atk_status_slot_2_row_2],
- [:atk_status_slot_3_row_2],
- [:atk_status_slot_4_row_2],
- [:atk_status_slot_5_row_2],
- [:atk_status_slot_6_row_2],
- [:atk_status_slot_7_row_2],
- [:atk_status_slot_8_row_2],
- [:atk_status_slot_9_row_2],
- ]#
- # # Do not remove this.
- p 'Loaded : DPBz - Status Screen'
- # # Do not remove this. #####################
- # CUSTOMISATION END #
- #####################
- #===============================================================================#
- # http://dekitarpg.wordpress.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.\..\.. #
- #===============================================================================#
- # - SCRIPT BEGIN - #
- #===============================================================================#
- unless $imported[:Dekita__CORE]
- msgbox("'Dekita : Status Screen'
- The Above Script Requires 'Dekita__CORE, v1.0' in order to function properly,
- It must also be placed below it!
- You can get the latest version of all my scripts @
- http://dekitarpg.wordpress.com/")
- exit
- end
- end ; end # PSS ; DPB
- #==============================================================================
- class Game_BattlerBase
- #==============================================================================
- def atk_element_rate(element_id)
- features_sum(FEATURE_ATK_ELEMENT, element_id)
- end
- end # Game_BattlerBase
- #==============================================================================
- class Game_Temp
- #==============================================================================
- attr_accessor :scene_status_index
- attr_accessor :scene_status_oy
- end # Game_Temp
- #==============================================================================
- class Window_StatusCommand < Window_Command
- #==============================================================================
- attr_accessor :item_window
- def initialize(dx, dy)
- super(dx, dy)
- @actor = nil
- self.opacity = 0
- end
- def window_width; return 0; end
- def actor=(actor)
- return if @actor == actor
- @actor = actor
- refresh
- end
- def visible_line_number; return 4; end
- def ok_enabled?
- return handle?(current_symbol)
- end
- def make_command_list
- return unless @actor
- for command in DPB::PSS::COMMANDS
- case command[0]
- when :pageone, :pagetwo, :pagethree, :pagefour
- add_command(command[1], command[0])
- else
- end
- end
- if !$game_temp.scene_status_index.nil?
- select($game_temp.scene_status_index)
- self.oy = $game_temp.scene_status_oy
- end
- $game_temp.scene_status_index = nil
- $game_temp.scene_status_oy = nil
- end
- def process_ok
- $game_temp.scene_status_index = index
- $game_temp.scene_status_oy = self.oy
- super
- end
- def update
- super
- update_item_window
- end
- def update_item_window
- return if @item_window.nil?
- return if @current_index == current_symbol
- @current_index = current_symbol
- @item_window.refresh
- end
- def item_window=(window)
- @item_window = window
- update
- end
- def update_help
- return if @actor.nil?
- @help_window.set_text(@actor.actor.description)
- end
- end # Window_StatusCommand
- #==============================================================================
- class Window_StatusItem < Window_Base
- #==============================================================================
- #include Dekita__CORE__Module
- def initialize(dx, dy, command_window)
- super(dx, dy, Graphics.width, Graphics.height - dy)
- @command_window = command_window
- @actor = nil
- refresh
- end
- def actor=(actor)
- return if @actor == actor
- @actor = actor
- refresh
- end
- def refresh
- contents.clear
- reset_font_settings
- return unless @actor
- draw_window_contents
- end
- def draw_window_contents
- case @command_window.current_symbol
- when :pageone
- draw_block1(line_height * 1)
- draw_block2(line_height * 1)
- draw_block4(line_height * 14)
- draw_page_one(0, 0)
- draw_new_stats_column if $imported[:Dekita__PSPDS]
- draw_points_column if $imported[:Dekita__PSPDS]
- when :pagetwo
- draw_block1(line_height * 1)
- draw_block2(line_height * 1)
- draw_block4(line_height * 14)
- draw_page_two(0, 0)
- when :pagethree
- draw_block1(line_height * 1)
- draw_block2(line_height * 1)
- draw_block4(line_height * 14)
- draw_page_three(0, 0)
- when :pagefour
- draw_block1(line_height * 1)
- draw_block2(line_height * 1)
- draw_block3(line_height * 7)
- draw_block4(line_height * 14)
- draw_page_four(0, 0)
- contents.font.size = Dekita__CORE::Info_Font_Size
- draw_commands_infoo if $imported[:Dekita__Equip]
- else
- end
- end
- def draw_commands_infoo
- dx = 0
- dw = (Graphics.width - 24) / 5
- dy = 0
- for info in Dekita__Equip::Commands_list
- dy = draw_command_column_info(info, dx, dy, dw)
- end
- end
- def draw_command_column_info(info, dx, dy, dw)
- case info[0]
- when :equip
- when :optimize
- when :clear
- 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(Color.new(111,111,111))
- if Dekita__Equip::Use_Command_Icons
- draw_icon(info[2], dx, dy, enable_DPBz_icons?)
- draw_text(dx+25, dy, dw-8, line_height, info[1], 0)
- else
- draw_text(dx+4, dy, dw-8, line_height, info[1], 0)
- end
- return dy + line_height
- end
- def draw_block1(y)
- draw_actor_face(@actor, window_width/ 2.5, 0)
- if DPB::PSPDS::DRAW_ACTOR_GRAPHIC
- draw_actor_graphic(@actor, DPB::PSPDS::DAG_X, DPB::PSPDS::DAG_Y)#, 50)
- else
- end
- end
- def draw_block2(y)
- draw_basic_info(136, y)
- end
- def draw_block3(y)
- draw_equipments((Graphics.width - 24) / 2 * 1 - 7, line_height * 4.7)
- end
- def draw_block4(y)
- draw_description(4, y)
- end
- def draw_horz_line(y)
- line_y = y + line_height / 2 - 1
- contents.fill_rect(0, line_y, contents_width, 2, line_color)
- end
- def line_color
- color = normal_color
- color.alpha = 48
- color
- end
- end
- def draw_basic_info(x, y)
- draw_actor_icons(@actor, (window_width - 24) / 2.5, y + line_height * 3)
- contents.font.size = Dekita__CORE::Info_Font_Size
- end
- def draw_page_one(x, y)
- contents.font.size = Dekita__CORE::Info_Font_Size
- draw_properties_paramcolumn
- draw_horz_line(line_height * 4)
- draw_horz_line(Graphics.height - line_height * 4)
- draw_properties_column1
- draw_properties_column2
- reset_font_settings
- end
- def draw_page_two(x, y)
- contents.font.size = Dekita__CORE::Info_Font_Size
- draw_horz_line(line_height * 4)
- draw_ele_column_one
- draw_states_column_one
- draw_states_column_two
- draw_horz_line(Graphics.height - line_height * 4)
- reset_font_settings
- end
- def draw_page_three(x, y)
- contents.font.size = Dekita__CORE::Info_Font_Size
- draw_horz_line(line_height * 4)
- draw_atk_ele_column_one
- draw_atk_states_column_one
- draw_atk_states_column_two
- draw_horz_line(Graphics.height - line_height * 4)
- reset_font_settings
- end
- def draw_page_four(x, y)
- contents.font.size = Dekita__CORE::Info_Font_Size
- draw_horz_line(line_height * 4)
- draw_actor_info_column
- draw_horz_line(Graphics.height - line_height * 4)
- reset_font_settings
- end
- def draw_equipments(x, y)
- @actor.equips.each_with_index do |item, i|
- draw_item_name(item, x, y + (line_height * 1) * i)
- end
- change_color(Dekita__CORE::Value_Color_Settings(""))
- draw_actors_slots(y)
- end
- def draw_actors_slots(y)
- my_x = Graphics.width / 3
- slots_id = 0
- amount = @actor.equip_slots.size
- amount.times {|i|
- draw_text(my_x, y + line_height * i, my_x, line_height, slot_name(slots_id))
- slots_id += 1
- }
- end
- def slot_name(index)
- @actor ? Vocab::etype(@actor.equip_slots[index]) : ""
- end
- def draw_description(x, y)
- draw_text_ex(x, y, @actor.description)
- end
- def draw_actor_info_column
- dx = 0
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for information in DPB::PSS::Actor_Info_Column
- dy = draw_stat_info_DPBz(information, @actor, dx, dy, dw)
- end
- end
- def draw_new_stats_column
- dx = 0
- dw = (window_width - 24) / 5
- dy = 0
- for property in DPB::PSPDS::NEW_STATS_COLUMN
- dy = draw_stat_info_DPBz(property, @actor, dx, dy, dw)
- end
- end
- def draw_properties_column1
- dx = window_width / 3 * 1 - 6
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for property in DPB::PSS::Page_Two_Info_Column_Two
- dy = draw_stat_info_DPBz(property, @actor, dx, dy, dw)
- end
- end
- def draw_properties_column2
- dx = window_width / 3 * 2 - 12
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for property in DPB::PSS::Page_Two_Info_Column_Three
- dy = draw_stat_info_DPBz(property, @actor, dx, dy, dw)
- end
- end
- def draw_properties_paramcolumn
- dx = window_width / 3 * 0
- dw = ((window_width) / 3) - 12
- dy = line_height * 4.7
- for property in DPB::PSS::Page_Two_Info_Column_One
- dy = draw_stat_info_DPBz(property, @actor, dx, dy, dw)
- end
- end#
- def draw_points_column
- dx = (window_width - 24) / 5 * 4
- dw = (window_width - 24) / 5
- dy = 0
- for property in DPB::PSPDS::POINTS_COLUMN
- dy = draw_points_info_DPBz(property, @actor, dx, dy, dw)
- end
- end
- def draw_ele_column_one
- dx = 0
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for element in DPB::PSS::Elements_Column_One
- dy = draw_stat_info_DPBz(element, @actor, dx, dy, dw)
- end
- end
- def draw_ele_column_two
- dx = window_width / 3 - 6
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for element in DPB::PSS::Elements_Column_Two
- dy = draw_stat_info_DPBz(element, @actor, dx, dy, dw)
- end
- end
- def draw_states_column_one
- dx = window_width / 3 - 6
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for state in DPB::PSS::States_Column_One
- dy = draw_stat_info_DPBz(state, @actor, dx, dy, dw)
- end
- end
- def draw_states_column_two
- dx = (window_width / 3 * 2) - 12
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for state in DPB::PSS::States_Column_Two
- dy = draw_stat_info_DPBz(state, @actor, dx, dy, dw)
- end
- end
- def draw_atk_ele_column_one
- dx = 0 # window_width / 3 * 2 - 12
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for element in DPB::PSS::Attack_Elements_Column_One
- dy = draw_stat_info_DPBz(element, @actor, dx, dy, dw)
- end
- end
- def draw_atk_states_column_one
- dx = window_width / 3 - 6
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for state in DPB::PSS::Attack_States_Column_One
- dy = draw_stat_info_DPBz(state, @actor, dx, dy, dw)
- end
- end
- def draw_atk_states_column_two
- dx = (window_width / 3 * 2) - 12
- dw = window_width / 3 - 12
- dy = line_height * 4.7
- for state in DPB::PSS::Attack_States_Column_Two
- dy = draw_stat_info_DPBz(state, @actor, dx, dy, dw)
- end
- end
- def window_width
- Graphics.width - 0
- end
- def window_height
- Graphics.height - 0
- end
- #end #WindowStatusItem
- #==============================================================================
- class Scene_Status < Scene_MenuBase
- #==============================================================================
- def start
- super
- create_status_window
- create_command_window
- create_item_window
- end
- def create_command_window
- wy = 0
- @command_window = Window_StatusCommand.new(0, wy)
- @command_window.viewport = @viewport
- @command_window.actor = @actor
- @command_window.help_window = @help_window
- @command_window.set_handler(:cancel, method(:return_scene))
- @command_window.set_handler(:pagedown, method(:next_actor))
- @command_window.set_handler(:pageup, method(:prev_actor))
- @command_window.set_handler(:pageone, method(:command_pageone))
- @command_window.set_handler(:pagetwo, method(:command_pagetwo))
- @command_window.set_handler(:pagethree, method(:command_pagethree))
- @command_window.set_handler(:pagefour, method(:command_pagefour))
- end
- def create_status_window
- wy = 0
- end
- def create_item_window
- dy = 0
- @item_window = Window_StatusItem.new(0, dy, @command_window)
- @item_window.viewport = @viewport
- @item_window.actor = @actor
- @command_window.item_window = @item_window
- end
- def on_actor_change
- @command_window.actor = @actor
- @item_window.actor = @actor
- @command_window.activate
- end
- def command_pageone
- SceneManager.call(Scene_Level_Up)
- end
- def command_pagetwo
- unless $imported["DPB-ADDESC"]
- @command_window.activate
- return
- end
- SceneManager.call(Scene_Element_Up)
- end
- def command_pagethree
- unless $imported["DPB-ADDSTC"]
- @command_window.activate
- return
- end
- SceneManager.call(Scene_State_Up)
- end
- def command_pagefour
- SceneManager.call(Scene_Equip)
- end
- end # Scene_Status
- #===============================================================================#
- # - SCRIPT END - #
- #===============================================================================#
- # http://dekitarpg.wordpress.com/ #
- #===============================================================================#
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement