Skill Upgrade System (Yanfly JP manager + Status Menu)

Heathurr

Veteran
Veteran
Joined
Aug 10, 2015
Messages
38
Reaction score
2
First Language
English
Okay so there's two things I wanna do with this project. I'm not even 100% sure they're possible, but I'm hoping. This most likely will require two separate scripts but...eh, we'll see. 

First of all, let me say that when I use the term "skills" in the context of this thread, I'm not talking about special moves and abilities and spells and whatnot. I'm talking about increasing skill levels with weapons and various elements. So for example. Characters might start out with the following skills (just as an example):

Axe
Sword
Dagger
Mace
Polearm

Fire
Water
Wind
Earth

And during the progress of the game, they can earn JP or whatever and then spend that JP to upgrade those skills. 

My ideal system for this was to have spells and actions feed exp into variables automatically. So like actor 1 attacks with a sword, actor 1 receives 8 JP into their sword skill, which would be a variable named sword exp actor 1. And when "sword exp actor 1" is greater than or equal to 100, "sword level actor 1" goes up by 1 and 100 pts are subtracted from the exp value. The two big roadblocks to this system are that it seems like it's probably impossible to do based on the bit of asking around I've done. And that if I can't diminish JP rewards or escalate costs for higher levels, I'm encouraging grinding and it could make my game trivially easy.

So it's not perfect. But if I can't do that, what I'd like to do instead is just allow players to manually level up their skills via a skill menu by purchasing the levels with JP. But again...diminishing JP returns on enemies or escalating upgrade costs would be necessary for game balance.

The SECOND part of this request would just be to add a screen to the yanfly status menu thingy that would allow players to see their skills. Like here:

 
What do you think? :D
 

mjshi

Jack of Most Trades
Veteran
Joined
Feb 16, 2013
Messages
969
Reaction score
807
First Language
English
Primarily Uses
N/A
I can probably fulfill the second request-- the first request sounds really similar to Learn Skills Based on Usage or Weapon Levels systems. Instead of having JP, I'd recommend just substituting for those two scripts, if what you want is automatically "leveling up" skills and weapons. They don't even use any variables-- the stuff levels automatically.

--

Edit: Actually, Yanfly's Status menu already supports the skill option. Go to line 80 of Yanfly's Status Menu script (or find this bit of code)

   #  [    :custom1,     "Skills"],and replace the "#" with a space.
 
Last edited by a moderator:

Heathurr

Veteran
Veteran
Joined
Aug 10, 2015
Messages
38
Reaction score
2
First Language
English
Unfortunately, those examples aren't quite what I'm looking for. The first one is really close, but there are a few issues:

It seems to be entirely for learning new special moves and spells, rather than upgrading a character's skillset. I'm more talking about a persistent set of skill levels that, once they reach a certain threshold, characters can learn new abilities. So like if my main character had sword, fire, and wind leveled to a certain point, she might have a lightning slash ability or whatever. Or if she had her hammer and earth skills leveled to a certain point, she'd unlock the ability to, say, hit the ground with her hammer and cause an earthquake.
 
 

Heathurr

Veteran
Veteran
Joined
Aug 10, 2015
Messages
38
Reaction score
2
First Language
English
That's...PRETTY damn close. Thank you!
 

Heathurr

Veteran
Veteran
Joined
Aug 10, 2015
Messages
38
Reaction score
2
First Language
English
lmao all the comments are in spanish. This is gonna be tricky.
 

Heathurr

Veteran
Veteran
Joined
Aug 10, 2015
Messages
38
Reaction score
2
First Language
English
Looks like it's actually portuguese. This is gonna be tricky.
 

e:
 

I can probably fulfill the second request-- the first request sounds really similar to Learn Skills Based on Usage or Weapon Levels systems. Instead of having JP, I'd recommend just substituting for those two scripts, if what you want is automatically "leveling up" skills and weapons. They don't even use any variables-- the stuff levels automatically.

--

Edit: Actually, Yanfly's Status menu already supports the skill option. Go to line 80 of Yanfly's Status Menu script (or find this bit of code)

   #  [    :custom1,     "Skills"],
and replace the "#" with a space.
Okay, we're making progress I think. But how can I make the skill command in yanfly's menu call the attribute_level screen from mog's script? Right now it's doing this:

 
Last edited by a moderator:

mjshi

Jack of Most Trades
Veteran
Joined
Feb 16, 2013
Messages
969
Reaction score
807
First Language
English
Primarily Uses
N/A
Can you provide both scripts in spoiler tags? You probably want to keep any customizations that you've made, so I'd need to edit your script directly.
 
Last edited by a moderator:

Ramiro

Now with an army of Mecha-Ralphs!
Veteran
Joined
Aug 5, 2015
Messages
858
Reaction score
364
First Language
Spanish
In atellier RGSS:

Features

This system activates element and weapon proficiency, incrmenting damage as they level up.
This system also adds a way to learn some skills when certain proficiency levels are required.

Usage

For the ability to do more damage when certain element is increased, you must set the attack element.

To activate the effect of increasing a weapon's proficiency with skills, you must put a weapon type as requeriment for it, except is the skill is the normal attack (ID:1)

This is portuguese, but for spanish users is somewhat "easy" to understand :p

I don't know how to use YEA with this thou
 

Heathurr

Veteran
Veteran
Joined
Aug 10, 2015
Messages
38
Reaction score
2
First Language
English
Can you provide both scripts in spoiler tags? You probably want to keep any customizations that you've made, so I'd need to edit your script directly.
Sure! Here's the mog script:

#==============================================================================# +++ MOG - Saga Skill System (v1.0) +++#==============================================================================# By Moghunter# https://atelierrgss.wordpress.com/#==============================================================================# O script ativa o sistema de nível e exp dos atributos resultando em# maior dano na medida que o nível é avançado.# O sistema também adiciona o sistema de aprendizagem semi aleatório de # habilidades quando o requerimento do nível do atributo é alcançado.# Este sistema é baseado no jogo Romancing Saga.#==============================================================================# NOTA - É necessário que o personagem tenha o tipo de comando da habilidade# ativado para que a habilidade seja aprendida.# EX - O personagem não vai aprender as habilidades de magia se o # personagem não tiver o comando de magia ativado.#==============================================================================#==============================================================================# ● COMMANDO DE AUMENTAR O LEVEL MANUALMENTE.#==============================================================================# Para aumentar o level do atributo use o comando abaixo.## element_lv_up(ACTOR_ID , ATTRIBUTE_ID, VALUE)# # element_lv_up(2,5,1)#==============================================================================# Para aumentar o level do tipo de arma use o comando abaixo.## weapon_lv_up(ACTOR_ID , ATTRIBUTE_ID, VALUE)# # weapon_lv_up(2,5,1)#==============================================================================#==============================================================================# ● COMMANDO DE AUMENTAR A EXP MANUALMENTE.#==============================================================================# Para aumentar a experiência do atributo use o comando abaixo.## element_exp_up(ACTOR_ID , ATTRIBUTE_ID, VALUE)# # element_exp_up(2,5,20)#==============================================================================# Para aumentar a experiência do tipo de arma use o comando abaixo.## weapon_exp_up(ACTOR_ID , ATTRIBUTE_ID, VALUE)# # weapon_exp_up(2,5,20)#==============================================================================module MOG_SAGA_SKILL #---------------------------------------------------------------------------- # Ativar o sistema de aprendizagem de habilidade. #---------------------------------------------------------------------------- ENABLE_SKILL_LEARNING = true #---------------------------------------------------------------------------- # Definição da % de change de aprender a habilidade ao atingir o nível # necessário, essa porcentagem é subtraída pela diferença do level # do atributo, ou seja, quando maior o level do elemento maior será a # chance de aprender a habilidade. #---------------------------------------------------------------------------- SUCCESS_RATE = 20 #---------------------------------------------------------------------------- # Definição da animação ao aprender a habilidade. #---------------------------------------------------------------------------- LEARNING_ANIMATION_ID = 147 #---------------------------------------------------------------------------- # Definição do texto da janela de Log. #---------------------------------------------------------------------------- BATTLE_LOG_TEXT = "learns" #---------------------------------------------------------------------------- #Definição das habilidade que serão aprendidas. Referente aos elementos. # # ELEMENT_LEARN_SKILL[ A ] = {B => C, B => C, B=> C, ...} # # A - ID do elemento. # B - ID da Habilidade. # C - Nivel mínimo necessário para aprender a habilidade. #---------------------------------------------------------------------------- ELEMENT_LEARN_SKILL = [] ELEMENT_LEARN_SKILL[1] = {100=>5, 105=>10, 106=>15} #Bare Hands(Physical) ELEMENT_LEARN_SKILL[2] = {26=>4 ,27=>12 , 28=>20, 29=>8,#Restoration(Absorb) 30=>24 ,31=>6, 32=>14, 33=>10, 34=>26} ELEMENT_LEARN_SKILL[3] = {51=>4 ,52=>15 ,52=>8 ,53=>25 ,41=>6} #Fire ELEMENT_LEARN_SKILL[4] = {55=>4 ,56=>15 ,57=>8 ,58=>25 ,26=>6} #Ice ELEMENT_LEARN_SKILL[5] = {59=>4 ,60=>15 ,61=>8 ,62=>25 ,40=>6} #Thunder ELEMENT_LEARN_SKILL[6] = {63=>4, 64 =>20 , 44=>10} #Water ELEMENT_LEARN_SKILL[7] = {65=>4, 66 =>20 , 39=>10} #Earth ELEMENT_LEARN_SKILL[8] = {67=>4, 68 =>20 , 35=>10} #Wind ELEMENT_LEARN_SKILL[9] = {69=>4, 70 =>20 , 49=>10} #Holy ELEMENT_LEARN_SKILL[10] = {71=>4, 72 =>20 , 47=>10} #Dark #---------------------------------------------------------------------------- #Definição das habilidade que serão aprendidas. Referente aos tipos de armas. # # WEAPON_LEARN_SKILL[ A ] = {B => C, B => C, B=> C, ...} # # A - ID do elemento # B - ID da Habilidade(Skill) # C - Nivel mínimo necessário para aprender a habilidade. #---------------------------------------------------------------------------- WEAPON_LEARN_SKILL = [] WEAPON_LEARN_SKILL[1] = {83=>10 , 84=> 25} #Axe WEAPON_LEARN_SKILL[2] = {88=>10 , 89=> 25} #Claw WEAPON_LEARN_SKILL[3] = {93=>10 , 94=> 25} #Spear WEAPON_LEARN_SKILL[4] = {95=>10 , 99=> 25} #Sword WEAPON_LEARN_SKILL[5] = {100=>10 , 102=> 15, 103=> 25} #Katana WEAPON_LEARN_SKILL[6] = {108=>10 , 109=> 25} #Bow WEAPON_LEARN_SKILL[7] = {113=>10 , 114=> 25} #Dagger WEAPON_LEARN_SKILL[8] = {80=>5 , 81=> 10} #Gun #---------------------------------------------------------------------------- #Definição das habilidade que não serão aprendidas pelos personagens # # ACTOR_NOT_LEARN_SKILL_ID[ACTOR_ID] = [SKILL_ID1,SKILL_ID2,SKILL_ID3 ...] #---------------------------------------------------------------------------- ACTOR_NOT_LEARN_SKILL_ID = [] #ACTOR_NOT_LEARN_SKILL_ID[1] = [26,27,28,29,30] #ACTOR_NOT_LEARN_SKILL_ID[2] = [100,110]end#==============================================================================# ● ATTRIBUTE LEVEL#==============================================================================module MOG_ATTRIBUTE_LEVEL #---------------------------------------------------------------------------- #Definição dos elementos ignorados pelo sistema. # # DISABLE_ELEMENT_ID = [2,5,8] # #---------------------------------------------------------------------------- DISABLE_ELEMENT_ID = [] #---------------------------------------------------------------------------- #Definição dos tipos de armas ignorados pelo sistema. #---------------------------------------------------------------------------- DISABLE_WEAPON_ID = [] #---------------------------------------------------------------------------- #Definição do elemento de ataques sem armas. #Esse é ativado quando o personagem ataca sem armas. #---------------------------------------------------------------------------- BARE_HANDS_ELEMENT_ID = 1 #---------------------------------------------------------------------------- #Definição da exp necessária para atingir o próximo nível. (level x valor) #---------------------------------------------------------------------------- NEXT_EXP_LEVEL_BASE = 5 #---------------------------------------------------------------------------- #Definição do level maximo. #---------------------------------------------------------------------------- MAX_ATTRIBUTE_LEVEL = 100 #---------------------------------------------------------------------------- #Definição da porcentagem de dano a cada level. #---------------------------------------------------------------------------- DAMAGE_PERCENTAGE_PER_LEVEL = 5 #---------------------------------------------------------------------------- #Nome da janela de atributo. #---------------------------------------------------------------------------- ATTRIBUTE_LEVEL_NAME = "Attribute Level" #---------------------------------------------------------------------------- #Apresentar a porcentagem da experiência. #---------------------------------------------------------------------------- SHOW_PERCENTAGE = true #---------------------------------------------------------------------------- #Ativar a janela de apertar o botão. #---------------------------------------------------------------------------- SHOW_PRESS_BUTTON_WINDOW = true #---------------------------------------------------------------------------- #Definição do texto da janela de ajuda. #---------------------------------------------------------------------------- PRESS_BUTTON_TEXT = "(C Button) Attribute Status"end$imported = {} if $imported.nil?$imported[:mog_saga_skill_system] = true#==============================================================================# ■ Game Interpreter#==============================================================================class Game_Interpreter #-------------------------------------------------------------------------- # ● Element LV #-------------------------------------------------------------------------- def element_lv_up(actor_id,atr_id,value) return if atr_id < 0 return if MOG_ATTRIBUTE_LEVEL::DISABLE_ELEMENT_ID.include?(atr_id) $game_party.members.each do |actor| if actor.id == actor_id and ![nil,""].include?(actor.attribute_level[0][atr_id][5]) actor.attribute_level[0][atr_id][0] += value actor.attribute_level[0][atr_id][0] = 1 if actor.attribute_level[0][atr_id][0] < 0 actor.attribute_level[0][atr_id][0] = MOG_ATTRIBUTE_LEVEL::MAX_ATTRIBUTE_LEVEL if actor.attribute_level[0][atr_id][0] > MOG_ATTRIBUTE_LEVEL::MAX_ATTRIBUTE_LEVEL actor.attribute_level[0][atr_id][1] = 0 end end end #-------------------------------------------------------------------------- # ● Element EXP #-------------------------------------------------------------------------- def element_exp_up(actor_id,atr_id,value) return if atr_id < 0 return if MOG_ATTRIBUTE_LEVEL::DISABLE_ELEMENT_ID.include?(atr_id) $game_party.members.each do |actor| if actor.id == actor_id and ![nil,""].include?(actor.attribute_level[0][atr_id][5]) next if actor.atr_max_level?(atr_id,0) actor.attribute_level[0][atr_id][1] += value.abs element_lv_up(actor_id,atr_id,1) if actor.atr_level_up?(atr_id,0) end end end #-------------------------------------------------------------------------- # ● Weapon LV #-------------------------------------------------------------------------- def weapon_lv_up(actor_id,atr_id,value) return if atr_id < 0 return if MOG_ATTRIBUTE_LEVEL::DISABLE_WEAPON_ID.include?(atr_id) $game_party.members.each do |actor| if actor.id == actor_id and ![nil,""].include?(actor.attribute_level[1][atr_id][5]) actor.attribute_level[1][atr_id][0] += value actor.attribute_level[1][atr_id][0] = 1 if actor.attribute_level[1][atr_id][0] < 0 actor.attribute_level[1][atr_id][0] = MOG_ATTRIBUTE_LEVEL::MAX_ATTRIBUTE_LEVEL if actor.attribute_level[1][atr_id][0] > MOG_ATTRIBUTE_LEVEL::MAX_ATTRIBUTE_LEVEL actor.attribute_level[1][atr_id][1] = 0 end end end #-------------------------------------------------------------------------- # ● Weapon LV #-------------------------------------------------------------------------- def weapon_exp_up(actor_id,atr_id,value) return if atr_id < 0 return if MOG_ATTRIBUTE_LEVEL::DISABLE_WEAPON_ID.include?(atr_id) $game_party.members.each do |actor| if actor.id == actor_id and ![nil,""].include?(actor.attribute_level[1][atr_id][5]) next if actor.atr_max_level?(atr_id,1) actor.attribute_level[1][atr_id][1] += value.abs weapon_lv_up(actor_id,atr_id,1) if actor.atr_level_up?(atr_id,1) end end end end#==============================================================================# ■ Window_Status#==============================================================================class Window_Attribute_Level < Window_Selectable #-------------------------------------------------------------------------- # ● Object Initialization #-------------------------------------------------------------------------- def initialize(actor) super(0, 0, Graphics.width, Graphics.height) self.visible = false @actor = actor refresh end #-------------------------------------------------------------------------- # ● Set Actor #-------------------------------------------------------------------------- def actor=(actor) return if @actor == actor @actor = actor refresh end #-------------------------------------------------------------------------- # ● Actor Elements #-------------------------------------------------------------------------- def actor_attributes atr = [] for i in @actor.attribute_level[0] next if i == nil or i[5] == "" next if i[4] == MOG_ATTRIBUTE_LEVEL::BARE_HANDS_ELEMENT_ID next if MOG_ATTRIBUTE_LEVEL::DISABLE_ELEMENT_ID.include?(i[4]) atr.push(i) end atr.push(@actor.attribute_level[0][MOG_ATTRIBUTE_LEVEL::BARE_HANDS_ELEMENT_ID]) for i in @actor.attribute_level[1] next if i == nil or i[5] == "" next if MOG_ATTRIBUTE_LEVEL::DISABLE_WEAPON_ID.include?(i[4]) atr.push(i) end return atr end #-------------------------------------------------------------------------- # ● Refresh #-------------------------------------------------------------------------- def refresh contents.clear contents.font.size = 24 contents.font.bold = false atrbutes = actor_attributes sw = Graphics.width - 16 ; sh = Graphics.height - 80 h_limit = sh / 32 ; x = 0 ; y = 48 sp = atrbutes.size > h_limit * 2 ? 3 : 2 ; x_space = sw / sp change_color(normal_color) draw_text(0,0,sw,32,MOG_ATTRIBUTE_LEVEL::ATTRIBUTE_LEVEL_NAME.to_s, 1) draw_horz_line(line_height * 1) atrbutes.each_with_index do |i, index| contents.font.size = 24 contents.font.bold = false x2 = x_space * (index / h_limit) y2 = -((h_limit * 32) * (index / h_limit)) change_color(normal_color) draw_text(x + x2,y + y2 + 32 * index,x_space - 64,32,i[5].to_s, 0) contents.font.color = Color.new(200,200,200,255) draw_text(x + x2 + x_space - 64,y + y2 + 32 * index,64,32,"LV".to_s, 0) draw_text(x + x2 + x_space - 74,y + y2 + 32 * index,64,32,i[0].to_s.to_s, 2) draw_gauge(x + x2, line_height - 12 + y + y2 + 32 * index, x_space - 64, i, tp_gauge_color1, tp_gauge_color2) if MOG_ATTRIBUTE_LEVEL::SHOW_PERCENTAGE contents.font.size = 18 contents.font.bold = true contents.font.color = Color.new(250,250,200,255) value_max = @actor.atr_next_exp(i[4],i[6]) ; value_max = 1 if value_max < 1 value = i[1].to_f / value_max.to_f * 100 value = 100 if @actor.atr_max_level?(i[4],i[6]) draw_text(x + x2,16 + y + y2 + 32 * index,x_space - 64,32,value.round(1).to_s, 0) end end end #-------------------------------------------------------------------------- # ● Draw Gauge #-------------------------------------------------------------------------- def draw_gauge(x, y, width, atr, color1, color2) fill_w = width * atr[1] / @actor.atr_next_exp(atr[4],atr[6]) fill_w = width if @actor.atr_max_level?(atr[4],atr[6]) gauge_y = y + line_height - 8 contents.fill_rect(x, gauge_y, width, 6, gauge_back_color) contents.gradient_fill_rect(x, gauge_y, fill_w, 6, color1, color2) 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 #-------------------------------------------------------------------------- # ● Line Color #-------------------------------------------------------------------------- def line_color color = normal_color ; color.alpha = 48 ; color end #-------------------------------------------------------------------------- # ● Update #-------------------------------------------------------------------------- def update super self.opacity = 255 end end#==============================================================================# ■ Window_Status#==============================================================================class Window_Attribute_Button < Window_Selectable attr_accessor :fade_time #-------------------------------------------------------------------------- # ● Object Initialization #-------------------------------------------------------------------------- def initialize super(0, 0, Graphics.width, 64) self.y = Graphics.height - self.height ; @fade_time = 60 self.opacity = 0 ; self.contents_opacity = 0 self.visible = MOG_ATTRIBUTE_LEVEL::SHOW_PRESS_BUTTON_WINDOW refresh end #-------------------------------------------------------------------------- # ● Refresh #-------------------------------------------------------------------------- def refresh contents.clear draw_text(0,0,self.width - 32,32,MOG_ATTRIBUTE_LEVEL::pRESS_BUTTON_TEXT.to_s,1) end #-------------------------------------------------------------------------- # ● Update #-------------------------------------------------------------------------- def update super if @fade_time > 0 @fade_time -= 1 ; self.opacity += 20 ; self.contents_opacity += 20 else if self.opacity > 0 self.y += 5 ; self.opacity -= 5 ; self.contents_opacity -= 5 end end end end#==============================================================================# ■ Scene_Status#==============================================================================class Scene_Status < Scene_MenuBase #-------------------------------------------------------------------------- # ● Start #-------------------------------------------------------------------------- alias mog_atr_start start def start mog_atr_start @attribute_window = Window_Attribute_Level.new(@actor) @attribute_window.z = @status_window.z + 50 @attribute_Button_window = Window_Attribute_Button.new @attribute_Button_window.z = @attribute_window.z - 1 end #-------------------------------------------------------------------------- # ● On Actor Change #-------------------------------------------------------------------------- alias mog_atr_on_actor_change on_actor_change def on_actor_change mog_atr_on_actor_change @attribute_window.actor = @actor end #-------------------------------------------------------------------------- # ● Update #-------------------------------------------------------------------------- alias mog_atr_update update def update mog_atr_update if Input.trigger?:)C) Sound.play_ok ; @attribute_Button_window.fade_time = 0 @attribute_window.visible = @attribute_window.visible ? false : true end end end#==============================================================================# ■ Game_Battler#==============================================================================class Game_Battler < Game_BattlerBase attr_accessor :attribute_level #-------------------------------------------------------------------------- # ● Initialize #-------------------------------------------------------------------------- alias mog_attribute_initialize initialize def initialize initial_attribute_level mog_attribute_initialize end #-------------------------------------------------------------------------- # ● Initial Attribute Level #-------------------------------------------------------------------------- def initial_attribute_level @attribute_level = [[],[]] $data_system.elements.each_with_index do |i, index| @attribute_level[0].push([1,0,0,false,index,i,0]) end $data_system.weapon_types.each_with_index do |i, index| @attribute_level[1].push([1,0,0,false,index,i,1]) end end #-------------------------------------------------------------------------- # ● Atr Clear EXP Phase #-------------------------------------------------------------------------- def atr_clear_exp_phase @attribute_level[0].each do |i| ; i[3] = false ; end @attribute_level[1].each do |i| ; i[3] = false ; end end #-------------------------------------------------------------------------- # ● Atr Base EXP #-------------------------------------------------------------------------- def atr_base_exp return 1 end #-------------------------------------------------------------------------- # ● Add Atr EXP #-------------------------------------------------------------------------- def add_atr_exp(atr_id,type) return if !atr_exp?(atr_id,type) @attribute_level[type][atr_id][1] += atr_base_exp @attribute_level[type][atr_id][2] += atr_base_exp atr_level_up(atr_id,type) if atr_level_up?(atr_id,type) end #-------------------------------------------------------------------------- # ● Atr EXP ? #-------------------------------------------------------------------------- def atr_exp?(atr_id,type) return false if atr_id < 0 return false if atr_max_level?(atr_id,type) return false if @attribute_level[type][atr_id][3] return false if [nil,""].include?(@attribute_level[type][atr_id][5]) return false if type == 0 and MOG_ATTRIBUTE_LEVEL::DISABLE_ELEMENT_ID.include?(atr_id) return false if type == 1 and MOG_ATTRIBUTE_LEVEL::DISABLE_WEAPON_ID.include?(atr_id) return true end #-------------------------------------------------------------------------- # ● Atr Level UP #-------------------------------------------------------------------------- def atr_level_up?(atr_id,type) return false if atr_max_level?(atr_id,type) return true if @attribute_level[type][atr_id][1] >= atr_next_exp(atr_id,type) return false end #-------------------------------------------------------------------------- # ● Atr Max Level #-------------------------------------------------------------------------- def atr_max_level?(atr_id,type) return true if @attribute_level[type][atr_id][0] >= MOG_ATTRIBUTE_LEVEL::MAX_ATTRIBUTE_LEVEL return false end #-------------------------------------------------------------------------- # ● Atr Level UP #-------------------------------------------------------------------------- def atr_next_exp(atr_id,type) return @attribute_level[type][atr_id][0] * MOG_ATTRIBUTE_LEVEL::NEXT_EXP_LEVEL_BASE end #-------------------------------------------------------------------------- # ● Atr Level UP #-------------------------------------------------------------------------- def atr_level_up(atr_id,type) @attribute_level[type][atr_id][0] += 1 @attribute_level[type][atr_id][1] = 0 unless atr_max_level?(atr_id,type) end #-------------------------------------------------------------------------- # ● Make Atr Damage Value #-------------------------------------------------------------------------- alias mog_atr_make_damage_value make_damage_value def make_damage_value(user, item) mog_atr_make_damage_value(user, item) if attribute_effect?(user, item) make_atr_damage_value(user, item) excute_add_atr_exp(user, item) if $imported[:mog_atb_system] and coop_make_damage_value?(user, item) for actor in BattleManager.cskill_members(item.id) next if actor == user make_atr_damage_value(actor, item) excute_add_atr_exp(actor, item) end end end end #-------------------------------------------------------------------------- # ● Attribute Effect #-------------------------------------------------------------------------- def attribute_effect?(user, item) return false if item == nil return false if item.is_a?(RPG::Item) return false if user.is_a?(Game_Enemy) return true end #-------------------------------------------------------------------------- # ● Execute Add Atr EXP #-------------------------------------------------------------------------- def excute_add_atr_exp(user, item) if item.id == user.attack_skill_id if user.equips[0] != nil atr_id_1 = user.equips[0].wtype_id user.add_atr_exp(atr_id_1,1) else user.add_atr_exp(MOG_ATTRIBUTE_LEVEL::BARE_HANDS_ELEMENT_ID,0) user.attribute_level[1][0][3] = true end if user.dual_wield? and user.equips[1] != nil atr_id_2 = user.equips[1].wtype_id user.add_atr_exp(atr_id_2,1) end user.attribute_level[1][atr_id_1][3] = true if atr_id_1 != nil user.attribute_level[1][atr_id_2][3] = true if atr_id_2 != nil else user.add_atr_exp(item.damage.element_id,0) if user.equips[0] != nil and (item.required_wtype_id1 == user.equips[0].wtype_id or item.required_wtype_id2 == user.equips[0].wtype_id) user.add_atr_exp(user.equips[0].wtype_id,1) ; wp_1 = true end if user.dual_wield? and user.equips[1] != nil and (item.required_wtype_id1 == user.equips[1].wtype_id or item.required_wtype_id2 == user.equips[1].wtype_id) user.add_atr_exp(user.equips[1].wtype_id,1) ; wp_2 = true end user.attribute_level[0][item.damage.element_id][3] = true user.attribute_level[1][user.equips[0].wtype_id][3] = true if wp_1 user.attribute_level[1][user.equips[1].wtype_id][3] = true if wp_2 end end #-------------------------------------------------------------------------- # ● Atr Dmg P #-------------------------------------------------------------------------- def atr_dmg_p(user,atr_id,type) ((user.attribute_level[type][atr_id][0] - 1) * MOG_ATTRIBUTE_LEVEL::DAMAGE_PERCENTAGE_PER_LEVEL) end #-------------------------------------------------------------------------- # ● Make Atr Damage Value #-------------------------------------------------------------------------- def make_atr_damage_value(user, item) b_damage = @result.hp_damage if item.damage.to_hp? b_damage = @result.mp_damage if item.damage.to_mp? b_damage = 0 if b_damage.nil? if item.id == user.attack_skill_id if user.equips[0] != nil atr_id = user.equips[0].wtype_id dam = b_damage * atr_dmg_p(user,atr_id,1) / 100 execute_atr_damage(user,dam,item) else dam = b_damage * atr_dmg_p(user,MOG_ATTRIBUTE_LEVEL::BARE_HANDS_ELEMENT_ID,0) / 100 execute_atr_damage(user,dam,item) end if user.dual_wield? and user.equips[1] != nil atr_id = user.equips[1].wtype_id dam = b_damage * atr_dmg_p(user,atr_id,1) / 100 execute_atr_damage(user,dam,item) end else dam = b_damage * atr_dmg_p(user,item.damage.element_id,0) / 100 execute_atr_damage(user,dam,item) if user.equips[0] != nil and (item.required_wtype_id1 == user.equips[0].wtype_id or item.required_wtype_id2 == user.equips[0].wtype_id) atr_id = user.equips[0].wtype_id dam = b_damage * atr_dmg_p(user,atr_id,1) / 100 execute_atr_damage(user,dam,item) end if user.dual_wield? and user.equips[1] != nil and (item.required_wtype_id1 == user.equips[1].wtype_id or item.required_wtype_id2 == user.equips[1].wtype_id) atr_id = user.equips[1].wtype_id dam = b_damage * atr_dmg_p(user,atr_id,1) / 100 execute_atr_damage(user,dam,item) end end end #-------------------------------------------------------------------------- # ● Execute ATR Damage #-------------------------------------------------------------------------- def execute_atr_damage(user,b_damage,item) m_size = 1 if $imported[:mog_atb_system] and coop_make_damage_value?(user, item) m_size = BattleManager.cskill_members(item.id).size if BattleManager.cskill_members(item.id).size > 0 end @result.hp_damage += (b_damage / m_size) if item.damage.to_hp? @result.mp_damage += (b_damage / m_size) if item.damage.to_mp? end end#==============================================================================# ■ Scene Battle#==============================================================================class Scene_Battle < Scene_Base #-------------------------------------------------------------------------- # ● Use Item #-------------------------------------------------------------------------- alias mog_atr_level_use_item use_item def use_item mog_atr_level_use_item @subject.atr_clear_exp_phase end end#==============================================================================# ■ Game Battler#==============================================================================class Game_Battler < Game_BattlerBase #-------------------------------------------------------------------------- # ● Make Action #-------------------------------------------------------------------------- def make_action_r(skill_id, target_index) clear_actions action = Game_Action.new(self, true) action.set_skill(skill_id) action.target_index = target_index @actions.push(action) end end#==============================================================================# ■ Game Actor#==============================================================================class Game_Actor < Game_Battler attr_reader :actor_idend#==============================================================================# ■ Scene Battle#==============================================================================class Scene_Battle < Scene_Base #-------------------------------------------------------------------------- # ● Execute Action #-------------------------------------------------------------------------- alias mog_atr_level_execute_action execute_action def execute_action execute_random_learning if execute_random_learning? mog_atr_level_execute_action end #-------------------------------------------------------------------------- # ● Execute Random Learning? #-------------------------------------------------------------------------- def execute_random_learning? return false if !MOG_SAGA_SKILL::ENABLE_SKILL_LEARNING return false if @subject.nil? return false if @subject.is_a?(Game_Enemy) item = @subject.current_action.item rescue nil return false if item == nil return false if item.is_a?(RPG::Item) return false if $imported[:mog_atb_system] and BattleManager.is_cskill?(item.id) return true end #-------------------------------------------------------------------------- # ● Execute Random Learning #-------------------------------------------------------------------------- def execute_random_learning item = @subject.current_action.item ; success = false ; skill_id = 0 ; skill = nil if item.id == @subject.attack_skill_id if @subject.equips[0] != nil atr_id = @subject.equips[0].wtype_id ; type = 1 else atr_id = MOG_ATTRIBUTE_LEVEL::BARE_HANDS_ELEMENT_ID ; type = 0 end skill_list = MOG_SAGA_SKILL::ELEMENT_LEARN_SKILL[atr_id] if type == 0 skill_list = MOG_SAGA_SKILL::WEAPON_LEARN_SKILL[atr_id] if type == 1 else atr_id = item.damage.element_id ; type = 0 skill_list = MOG_SAGA_SKILL::ELEMENT_LEARN_SKILL[atr_id] end if skill_list != nil ; skill_list.each do |i| ; skill_id = i[0] skill = $data_skills[skill_id] if atr_learn_skill?(skill,atr_id,i[1],type) success = true ; @subject.learn_skill(skill_id) ; break end end end if success and skill_id != 0 target = @subject.current_action.target_index @subject.make_action_r(skill_id, target) @log_window.display_learned_skill(@subject.name,skill.name) execute_learning_animation end end #-------------------------------------------------------------------------- # ● Atr Learn Skill #-------------------------------------------------------------------------- def atr_learn_skill?(skill,atr_id,lv_r,type) return false if skill == nil return false if $imported[:mog_atb_system] and BattleManager.is_cskill?(skill.id) nskill = MOG_SAGA_SKILL::ACTOR_NOT_LEARN_SKILL_ID[@subject.actor_id] return false if !nskill.nil? and nskill.include?(skill.id) return false if !@subject.added_skill_types.include?(skill.stype_id) return false if @subject.skill_learn?(skill) return false if @subject.attribute_level[type][atr_id][0] < lv_r success_rate = MOG_SAGA_SKILL::SUCCESS_RATE + (@subject.attribute_level[type][atr_id][0] - lv_r).abs return false if success_rate < rand(100) return true end #-------------------------------------------------------------------------- # ● Execute Learning Animation #-------------------------------------------------------------------------- def execute_learning_animation @subject.animation_id = MOG_SAGA_SKILL::LEARNING_ANIMATION_ID return if @subject.animation_id.nil? or @subject.animation_id < 1 animation = $data_animations[@subject.animation_id] rescue nil return if animation.nil? anid = (animation.frame_max * 4) + 1 ; anid.times do ; update_basic ; end end end#==============================================================================# ■ Window BattleLog#==============================================================================class Window_BattleLog < Window_Selectable #-------------------------------------------------------------------------- # ● Display Learned Skill #-------------------------------------------------------------------------- def display_learned_skill(battler_name,skill_name) text = battler_name.to_s + " " + MOG_SAGA_SKILL::BATTLE_LOG_TEXT + " " + skill_name.to_s + "!" replace_text(text) ; wait endend
 And here's the yanfly script:

#==============================================================================# # ▼ Yanfly Engine Ace - Ace Status Menu v1.02# -- Last Updated: 2011.12.26# -- Level: Normal# -- Requires: n/a# #==============================================================================$imported = {} if $imported.nil?$imported["YEA-StatusMenu"] = true#==============================================================================# ▼ Updates# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=# 2012.08.06 - Fix Sp Paramater TCR# 2011.12.26 - Compatibility Update: Rename Actor# 2011.12.23 - Started Script and Finished.# #==============================================================================# ▼ Introduction# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=# This script changes the status screen completely to something the player can# interact with more and be able to view actor data with more clarity. The# player is able to view the general information for an actor (parameters and# experience), a parameters bar graph, the various hidden extra parameters# (named properties in the script), and a customizable biography for the actor.# Also with this script, biographies can be changed at any time using a script# call to add more of a personal touch to characters.# #==============================================================================# ▼ Instructions# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=# To install this script, open up your script editor and copy/paste this script# to an open slot below ▼ Materials/素材 but above ▼ Main. Remember to save.# # -----------------------------------------------------------------------------# Script Calls - These commands are used with script calls.# -----------------------------------------------------------------------------# $game_actors[x].description = string# Changes the biography description for actor x to that of the string. Use \n# to designate linebreaks in the string. If you wish to use text codes, write# them in the strings as \\n[2] or \\c[3] to make them work properly.# #==============================================================================# ▼ Compatibility# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=# This script is made strictly for RPG Maker VX Ace. It is highly unlikely that# it will run with RPG Maker VX without adjusting.# #==============================================================================module YEA module STATUS #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- # - Command Window Settings - #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- # This section adjusts the commands that appear in the command window used # for the status screen. Rearrange the commands, add new ones, remove them # as you see fit. # # ------------------------------------------------------------------------- # :command Description # ------------------------------------------------------------------------- # :general Adds general page. # :parameters Adds parameters page. # :properties Adds properties page. # :biography Adds biography page. # # :rename Requires YEA - Rename Actor # :retitle Requires YEA - Retitle Actor # #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- COMMANDS =[ # The order at which the menu items are shown. # [ :command, "Display"], [ :general, "General"], [ :properties, "Properties"], [ :custom1, "Skills"], # [ :custom2, "Equipment"], # [ :custom3, "Class"], [ :biography, "Biography"], [ :rename, "Rename"], # Requires YEA - Rename Actor [ :retitle, "Retitle"], # Requires YEA - Rename Actor ] # Do not remove this. #-------------------------------------------------------------------------- # - Status Custom Commands - # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - # For those who use scripts to that may produce unique effects for the # status menu, use this hash to manage the custom commands for the Status # Command Window. You can disable certain commands or prevent them from # appearing by using switches. If you don't wish to bind them to a switch, # set the proper switch to 0 for it to have no impact. #-------------------------------------------------------------------------- CUSTOM_STATUS_COMMANDS ={ # :command => [EnableSwitch, ShowSwitch, Handler Method, Window Draw], :custom1 => [ 0, 0, :command_name1, :draw_custom1], :custom2 => [ 0, 0, :command_name2, :draw_custom2], :custom3 => [ 0, 0, :command_name3, :draw_custom3], } # Do not remove this. #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- # - General Window Settings - #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- # These settings adjust the way the general window visually appears. # Not many changes need to be done here other than vocab changes. #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- PARAMETERS_VOCAB = "Status" # Title used for Parameters. EXPERIENCE_VOCAB = "Experience" # Title used for Experience. NEXT_TOTAL_VOCAB = "Next %s Total Exp" # Label used for total experience. #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- # - Parameters Window 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. #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- PROPERTIES_FONT_SIZE = 24 # Font size used for properties. # These are the properties that appear in column 1. PROPERTIES_COLUMN1 =[ [:hit, "Hit"], [:eva, "Evade"], [:cri, "Crit"], [:cev, "Crit Evade"], [:mev, "Mag Evade"], [:mrf, "Magic Reflect"], ] # Do not remove this. # These are the properties that appear in column 2. PROPERTIES_COLUMN2 =[ [:hrg, "VP Regen"], [:mrg, "SP Regen"], [:pha, "Item Effect"], [:mcr, "SP Cost Mod"], [:cnt, "Counter"], [:tgr, "Emnity"], ] # Do not remove this. # These are the properties that appear in column 3. PROPERTIES_COLUMN3 =[ ] # Do not remove this. #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- # - Biography Window Settings - #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- # These settings adjust the way the biography appears including the title # used at the top, the font size, and whatnot. #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- BIOGRAPHY_NICKNAME_TEXT = "%s" # How the nickname will appear. BIOGRAPHY_NICKNAME_SIZE = 32 # Size of the font used. end # STATUSend # YEA#==============================================================================# ▼ Editting anything past this point may potentially result in causing# computer damage, incontinence, explosion of user's head, coma, death, and/or# halitosis so edit at your own risk.#==============================================================================#==============================================================================# ■ Numeric#==============================================================================class Numeric #-------------------------------------------------------------------------- # new method: group_digits #-------------------------------------------------------------------------- unless $imported["YEA-CoreEngine"] def group; return self.to_s; end end # $imported["YEA-CoreEngine"] end # Numeric#==============================================================================# ■ Game_Temp#==============================================================================class Game_Temp #-------------------------------------------------------------------------- # public instance variables #-------------------------------------------------------------------------- attr_accessor :scene_status_index attr_accessor :scene_status_oy end # Game_Temp#==============================================================================# ■ Game_Actor#==============================================================================class Game_Actor < Game_Battler #-------------------------------------------------------------------------- # new method: description= #-------------------------------------------------------------------------- def description=(text) @description = text end #-------------------------------------------------------------------------- # overwrite method: description #-------------------------------------------------------------------------- def description return @description unless @description.nil? return actor.description end end # Game_Actor#==============================================================================# ■ Window_StatusCommand#==============================================================================class Window_StatusCommand < Window_Command #-------------------------------------------------------------------------- # public instance variables #-------------------------------------------------------------------------- attr_accessor :item_window #-------------------------------------------------------------------------- # initialize #-------------------------------------------------------------------------- def initialize(dx, dy) super(dx, dy) @actor = nil end #-------------------------------------------------------------------------- # window_width #-------------------------------------------------------------------------- def window_width; return 160; end #-------------------------------------------------------------------------- # actor= #-------------------------------------------------------------------------- def actor=(actor) return if @actor == actor @actor = actor refresh end #-------------------------------------------------------------------------- # visible_line_number #-------------------------------------------------------------------------- def visible_line_number; return 4; end #-------------------------------------------------------------------------- # ok_enabled? #-------------------------------------------------------------------------- def ok_enabled? return handle?(current_symbol) end #-------------------------------------------------------------------------- # make_command_list #-------------------------------------------------------------------------- def make_command_list return unless @actor for command in YEA::STATUS::COMMANDS case command[0] #--- Default --- when :general, :parameters, :properties, :biography add_command(command[1], command[0]) #--- Yanfly Engine Ace --- when :rename next unless $imported["YEA-RenameActor"] add_command(command[1], command[0], @actor.rename_allow?) when :retitle next unless $imported["YEA-RenameActor"] add_command(command[1], command[0], @actor.retitle_allow?) #--- Custom Commands --- else process_custom_command(command) 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 #-------------------------------------------------------------------------- # process_ok #-------------------------------------------------------------------------- def process_ok $game_temp.scene_status_index = index $game_temp.scene_status_oy = self.oy super end #-------------------------------------------------------------------------- # process_custom_command #-------------------------------------------------------------------------- def process_custom_command(command) return unless YEA::STATUS::CUSTOM_STATUS_COMMANDS.include?(command[0]) show = YEA::STATUS::CUSTOM_STATUS_COMMANDS[command[0]][1] continue = show <= 0 ? true : $game_switches[show] return unless continue text = command[1] switch = YEA::STATUS::CUSTOM_STATUS_COMMANDS[command[0]][0] enabled = switch <= 0 ? true : $game_switches[switch] add_command(text, command[0], enabled) end #-------------------------------------------------------------------------- # update #-------------------------------------------------------------------------- def update super update_item_window end #-------------------------------------------------------------------------- # update_item_window #-------------------------------------------------------------------------- def update_item_window return if @item_window.nil? return if @current_index == current_symbol @current_index = current_symbol @item_window.refresh end #-------------------------------------------------------------------------- # item_window= #-------------------------------------------------------------------------- def item_window=(window) @item_window = window update end #-------------------------------------------------------------------------- # update_help #-------------------------------------------------------------------------- def update_help return if @actor.nil? @help_window.set_text(@actor.actor.description) end end # Window_StatusCommand#==============================================================================# ■ Window_StatusActor#==============================================================================class Window_StatusActor < Window_Base #-------------------------------------------------------------------------- # initialize #-------------------------------------------------------------------------- def initialize(dx, dy) super(dx, dy, window_width, fitting_height(4)) @actor = nil end #-------------------------------------------------------------------------- # window_width #-------------------------------------------------------------------------- def window_width; return Graphics.width - 160; end #-------------------------------------------------------------------------- # actor= #-------------------------------------------------------------------------- def actor=(actor) return if @actor == actor @actor = actor refresh end #-------------------------------------------------------------------------- # refresh #-------------------------------------------------------------------------- def refresh contents.clear return unless @actor draw_actor_face(@actor, 0, 0) draw_actor_simple_status(@actor, 108, line_height / 2) end end # Window_StatusActor#==============================================================================# ■ Window_StatusItem#==============================================================================class Window_StatusItem < Window_Base #-------------------------------------------------------------------------- # initialize #-------------------------------------------------------------------------- def initialize(dx, dy, command_window) super(dx, dy, Graphics.width, Graphics.height - dy) @command_window = command_window @actor = nil refresh end #-------------------------------------------------------------------------- # actor= #-------------------------------------------------------------------------- def actor=(actor) return if @actor == actor @actor = actor refresh end #-------------------------------------------------------------------------- # refresh #-------------------------------------------------------------------------- def refresh contents.clear reset_font_settings return unless @actor draw_window_contents end #-------------------------------------------------------------------------- # draw_window_contents #-------------------------------------------------------------------------- def draw_window_contents case @command_window.current_symbol when :general draw_actor_general when :parameters draw_parameter_graph when :properties draw_properties_list when :biography, :rename, :retitle draw_actor_biography else draw_custom end end #-------------------------------------------------------------------------- # draw_actor_general #-------------------------------------------------------------------------- def draw_actor_general change_color(system_color) text = YEA::STATUS::pARAMETERS_VOCAB draw_text(0, 0, contents.width/2, line_height, text, 1) text = YEA::STATUS::EXPERIENCE_VOCAB draw_text(contents.width/2, 0, contents.width/2, line_height, text, 1) draw_general_parameters draw_general_experience end #-------------------------------------------------------------------------- # draw_general_parameters #-------------------------------------------------------------------------- def draw_general_parameters dx = 24 dy = line_height / 2 draw_actor_level(dx, line_height*1+dy, contents.width/2 - 24) draw_actor_param(0, dx, line_height*2+dy, contents.width/2 - 24) draw_actor_param(1, dx, line_height*3+dy, contents.width/2 - 24) draw_actor_param(2, dx, line_height*4+dy, contents.width/4 - 12) draw_actor_param(4, dx, line_height*5+dy, contents.width/4 - 12) draw_actor_param(6, dx, line_height*6+dy, contents.width/4 - 12) dx += contents.width/4 - 12 draw_actor_param(3, dx, line_height*4+dy, contents.width/4 - 12) draw_actor_param(5, dx, line_height*5+dy, contents.width/4 - 12) draw_actor_param(7, dx, line_height*6+dy, contents.width/4 - 12) end #-------------------------------------------------------------------------- # draw_actor_level #-------------------------------------------------------------------------- def draw_actor_level(dx, dy, dw) 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, Vocab::level) change_color(normal_color) draw_text(dx+4, dy, dw-8, line_height, @actor.level.group, 2) end #-------------------------------------------------------------------------- # draw_actor_param #-------------------------------------------------------------------------- def draw_actor_param(param_id, dx, dy, dw) 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, Vocab::param(param_id)) change_color(normal_color) draw_text(dx+4, dy, dw-8, line_height, @actor.param(param_id).group, 2) end #-------------------------------------------------------------------------- # draw_general_experience #-------------------------------------------------------------------------- def draw_general_experience if @actor.max_level? s1 = @actor.exp.group s2 = "-------" s3 = "-------" else s1 = @actor.exp.group s2 = (@actor.next_level_exp - @actor.exp).group s3 = @actor.next_level_exp.group end s_next = sprintf(Vocab::ExpNext, Vocab::level) total_next_text = sprintf(YEA::STATUS::NEXT_TOTAL_VOCAB, Vocab::level) change_color(system_color) dx = contents.width/2 + 12 dy = line_height * 3 / 2 dw = contents.width/2 - 36 draw_text(dx, dy + line_height * 0, dw, line_height, Vocab::ExpTotal) draw_text(dx, dy + line_height * 2, dw, line_height, s_next) draw_text(dx, dy + line_height * 4, dw, line_height, total_next_text) change_color(normal_color) draw_text(dx, dy + line_height * 1, dw, line_height, s1, 2) draw_text(dx, dy + line_height * 3, dw, line_height, s2, 2) draw_text(dx, dy + line_height * 5, dw, line_height, s3, 2) end #-------------------------------------------------------------------------- # draw_parameter_graph #-------------------------------------------------------------------------- def draw_parameter_graph draw_parameter_title 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) change_color(system_color) draw_text(28, dy, contents.width - 56, line_height, Vocab::param(i)) dw = (contents.width - 48) * rate - 8 change_color(normal_color) draw_text(28, dy, dw, line_height, @actor.param(i).group, 2) 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 #-------------------------------------------------------------------------- # draw_param_gauge #-------------------------------------------------------------------------- def draw_param_gauge(param_id, dy, rate) dw = contents.width - 48 colour1 = param_gauge1(param_id) colour2 = param_gauge2(param_id) draw_gauge(24, dy, dw, rate, colour1, colour2) end #-------------------------------------------------------------------------- # param_gauge1 #-------------------------------------------------------------------------- def param_gauge1(param_id) return YEA::STATUS::pARAM_COLOUR[param_id][1] end #-------------------------------------------------------------------------- # param_gauge2 #-------------------------------------------------------------------------- def param_gauge2(param_id) return YEA::STATUS::pARAM_COLOUR[param_id][2] end #-------------------------------------------------------------------------- # draw_parameter_title #-------------------------------------------------------------------------- def draw_parameter_title colour = Color.new(0, 0, 0, translucent_alpha/2) rect = Rect.new(0, 0, contents.width, contents.height) contents.fill_rect(rect, colour) change_color(system_color) text = YEA::STATUS::pARAMETERS_VOCAB draw_text(0, line_height/3, contents.width, line_height, text, 1) end #-------------------------------------------------------------------------- # draw_properties_list #-------------------------------------------------------------------------- def draw_properties_list contents.font.size = YEA::STATUS::pROPERTIES_FONT_SIZE draw_properties_column1 draw_properties_column2 draw_properties_column3 reset_font_settings end #-------------------------------------------------------------------------- # draw_properties_column1 #-------------------------------------------------------------------------- def draw_properties_column1 dx = 8 dw = (contents.width - 24) / 2 - 24 dy = 22 for property in YEA::STATUS::pROPERTIES_COLUMN1 dy = draw_property(property, dx, dy, dw) end end #-------------------------------------------------------------------------- # draw_properties_column2 #-------------------------------------------------------------------------- def draw_properties_column2 dx = 120 + (contents.width - 24) / 3 dw = (contents.width - 24) / 2 - 24 dy = 22 for property in YEA::STATUS::pROPERTIES_COLUMN2 dy = draw_property(property, dx, dy, dw) end end #-------------------------------------------------------------------------- # draw_properties_column3 #-------------------------------------------------------------------------- def draw_properties_column3 dx = 24 + (contents.width - 24) / 3 * 2 dw = (contents.width - 24) / 3 - 24 dy = 0 for property in YEA::STATUS::pROPERTIES_COLUMN3 dy = draw_property(property, dx, dy, dw) end end #-------------------------------------------------------------------------- # draw_property #-------------------------------------------------------------------------- def draw_property(property, dx, dy, dw) fmt = "%1.2f%%" case property[0] #--- 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 #-------------------------------------------------------------------------- # draw_actor_biography #-------------------------------------------------------------------------- def draw_actor_biography fmt = YEA::STATUS::BIOGRAPHY_NICKNAME_TEXT text = sprintf(fmt, @actor.name, @actor.nickname) contents.font.size = YEA::STATUS::BIOGRAPHY_NICKNAME_SIZE draw_text(0, 0, contents.width, line_height*2, text, 1) reset_font_settings draw_text_ex(24, line_height*2, @actor.description) end #-------------------------------------------------------------------------- # draw_custom #-------------------------------------------------------------------------- def draw_custom current_symbol = @command_window.current_symbol return unless YEA::STATUS::CUSTOM_STATUS_COMMANDS.include?(current_symbol) method(YEA::STATUS::CUSTOM_STATUS_COMMANDS[current_symbol][3]).call end #-------------------------------------------------------------------------- # draw_custom1 #-------------------------------------------------------------------------- def draw_custom1 dx = 0; dy = 0 for skill in @actor.skills next if skill.nil? next unless @actor.added_skill_types.include?(skill.stype_id) draw_item_name(skill, dx, dy) dx = dx == contents.width / 2 + 16 ? 0 : contents.width / 2 + 16 dy += line_height if dx == 0 return if dy + line_height > contents.height end end #-------------------------------------------------------------------------- # draw_custom2 #-------------------------------------------------------------------------- def draw_custom2 dx = 4; dy = 0; slot_id = 0 for equip in @actor.equips change_color(system_color) text = Vocab.etype(@actor.equip_slots[slot_id]) draw_text(dx, dy, contents.width - dx, line_height, text) reset_font_settings draw_item_name(equip, dx+92, dy) unless equip.nil? slot_id += 1 dy += line_height break if dy + line_height > contents.height end dw = Graphics.width * 2 / 5 - 24 dx = contents.width - dw; dy = 0 param_id = 0 8.times do 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) size = $imported["YEA-AceEquipEngine"] ? YEA::EQUIP::STATUS_FONT_SIZE : 20 contents.font.size = size change_color(system_color) draw_text(dx+4, dy, dw, line_height, Vocab::param(param_id)) change_color(normal_color) dwa = (Graphics.width * 2 / 5 - 2) / 2 draw_text(dx, dy, dwa, line_height, @actor.param(param_id).group, 2) reset_font_settings change_color(system_color) draw_text(dx + dwa, dy, 22, line_height, "→", 1) param_id += 1 dy += line_height break if dy + line_height > contents.height end end #-------------------------------------------------------------------------- # draw_custom3 #-------------------------------------------------------------------------- def draw_custom3 return unless $imported["YEA-ClassSystem"] data = [] for class_id in YEA::CLASS_SYSTEM::CLASS_ORDER next if $data_classes[class_id].nil? item = $data_classes[class_id] next unless @actor.unlocked_classes.include?(item.id) or YEA::CLASS_SYSTEM::DEFAULT_UNLOCKS.include?(item.id) data.push(item) end dx = 0; dy = 0; class_index = 0 for class_id in data item = data[class_index] reset_font_settings if item == @actor.class change_color(text_color(YEA::CLASS_SYSTEM::CURRENT_CLASS_COLOUR)) elsif item == @actor.subclass change_color(text_color(YEA::CLASS_SYSTEM::SUBCLASS_COLOUR)) else change_color(normal_color) end icon = item.icon_index draw_icon(icon, dx, dy) text = item.name draw_text(24, dy, contents.width-24, line_height, text) next if YEA::CLASS_SYSTEM::MAINTAIN_LEVELS level = @actor.class_level(item.id) contents.font.size = YEA::CLASS_SYSTEM::LEVEL_FONT_SIZE text = sprintf(YEA::CLASS_SYSTEM::CLASS_LEVEL, level.group) dwa = contents.width - (Graphics.width * 2 / 5 - 24) - 28 draw_text(dx, dy, dwa, line_height, text, 2) class_index += 1 dy += line_height break if dy + line_height > contents.height end dw = Graphics.width * 2 / 5 - 24 dx = contents.width - dw; dy = 0 param_id = 0 8.times do 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) contents.font.size = YEA::CLASS_SYSTEM::pARAM_FONT_SIZE change_color(system_color) draw_text(dx+4, dy, dw, line_height, Vocab::param(param_id)) change_color(normal_color) dwa = (Graphics.width * 2 / 5 - 2) / 2 draw_text(dx, dy, dwa, line_height, @actor.param(param_id).group, 2) reset_font_settings change_color(system_color) draw_text(dx + dwa, dy, 22, line_height, "→", 1) param_id += 1 dy += line_height break if dy + line_height > contents.height end end end # Window_StatusItem#==============================================================================# ■ Scene_Status#==============================================================================class Scene_Status < Scene_MenuBase #-------------------------------------------------------------------------- # start #-------------------------------------------------------------------------- def start super create_help_window create_command_window create_status_window create_item_window relocate_windows end #-------------------------------------------------------------------------- # create_command_window #-------------------------------------------------------------------------- def create_command_window wy = @help_window.height @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)) process_custom_status_commands end #-------------------------------------------------------------------------- # process_custom_status_commands #-------------------------------------------------------------------------- def process_custom_status_commands for command in YEA::STATUS::COMMANDS next unless YEA::STATUS::CUSTOM_STATUS_COMMANDS.include?(command[0]) called_method = YEA::STATUS::CUSTOM_STATUS_COMMANDS[command[0]][2] @command_window.set_handler(command[0], method(called_method)) end end #-------------------------------------------------------------------------- # create_status_window #-------------------------------------------------------------------------- def create_status_window wy = @help_window.height @status_window = Window_StatusActor.new(@command_window.width, wy) @status_window.viewport = @viewport @status_window.actor = @actor end #-------------------------------------------------------------------------- # create_item_window #-------------------------------------------------------------------------- def create_item_window dy = @command_window.y + @command_window.height @item_window = Window_StatusItem.new(0, dy, @command_window) @item_window.viewport = @viewport @item_window.actor = @actor @command_window.item_window = @item_window end #-------------------------------------------------------------------------- # relocate_windows #-------------------------------------------------------------------------- def relocate_windows return unless $imported["YEA-AceMenuEngine"] case Menu.help_window_location when 0 # Top @help_window.y = 0 @command_window.y = @help_window.height @item_window.y = @command_window.y + @command_window.height when 1 # Middle @command_window.y = 0 @help_window.y = @command_window.height @item_window.y = @help_window.y + @help_window.height else # Bottom @command_window.y = 0 @item_window.y = @command_window.height @help_window.y = @item_window.y + @item_window.height end @status_window.y = @command_window.y end #-------------------------------------------------------------------------- # on_actor_change #-------------------------------------------------------------------------- def on_actor_change @command_window.actor = @actor @status_window.actor = @actor @item_window.actor = @actor @command_window.activate end #-------------------------------------------------------------------------- # new method: command_name1 #-------------------------------------------------------------------------- def command_name1 SceneManager.call(Scene_Skill) end #-------------------------------------------------------------------------- # new method: command_name2 #-------------------------------------------------------------------------- def command_name2 SceneManager.call(Scene_Equip) end #-------------------------------------------------------------------------- # new method: command_name3 #-------------------------------------------------------------------------- def command_name3 unless $imported["YEA-ClassSystem"] @command_window.activate return end SceneManager.call(Scene_Class) end end # Scene_Status#==============================================================================# # ▼ End of File# #==============================================================================
Thank you so much!
 
Last edited by a moderator:

mjshi

Jack of Most Trades
Veteran
Joined
Feb 16, 2013
Messages
969
Reaction score
807
First Language
English
Primarily Uses
N/A
Okay, the problem with these two scripts is that their Scenes are overwriting each other. So, what is it that you'd like to happen?

Are we overwriting the default magic/special skills, and just having the "Skills" tab pull up the attributes screen?

When the attributes screen is up, do you want the Status screen to still be in the background, or have the game map in the background?

EDIT: Also, I've put these two scripts in a clean project and I'm only getting the attributes screen when I press confirm (or Z, or Space, or Enter, whatever) on the biography tab. Which is strange. Are you having the same problem?
 
Last edited by a moderator:

Heathurr

Veteran
Veteran
Joined
Aug 10, 2015
Messages
38
Reaction score
2
First Language
English
Default magical/special skills should still be accessible from the window_menucommand scene. Remember I'm making a distinction between a character's spells and abilities and their skill levels. Which I guess this script is referring to as "attributes".

What I was hoping for was to have an option in the status menu command window to bring up the attributes screen that we see in the background there (and also to eliminate that prompt that shows up telling the player to push C for the attribute screen) 

I'm still not even sure if this script is gonna be able to do what I want it to do.

In terms of the attributes script, what I want it to do is:

     - Increase an actor's parameters when the attribute is leveled up
     - Escalate costs of attribute level-ups so the player can't just grind up on level 1 enemies and roflstomp my game   
 

mjshi

Jack of Most Trades
Veteran
Joined
Feb 16, 2013
Messages
969
Reaction score
807
First Language
English
Primarily Uses
N/A
I've eliminated the prompt, but what I'd asked was do you want the Yanfly status screen to show up in the background of (behind) the attributes screen?
 

Heathurr

Veteran
Veteran
Joined
Aug 10, 2015
Messages
38
Reaction score
2
First Language
English
Oh. No, sorry. Just the game map. 
 

mjshi

Jack of Most Trades
Veteran
Joined
Feb 16, 2013
Messages
969
Reaction score
807
First Language
English
Primarily Uses
N/A
Heathurr, I'm sorry, but I don't think I can edit this easily. The thing is, the MOG script has the attributes screen defined as a window, and a window can't stand by its own without a scene. Not only that, but Yanfly and MOG's scripts are overwriting each other. It's quite messy.
I don't know enough Ruby to get a window to appear over another window. So far, I have this:
 
MOG modified to not have prompt (modifications start on line 359)

Code:
#==============================================================================# ■ Window_Status#===============================================================================begin class Window_Attribute_Button < Window_Selectable  attr_accessor :fade_time  #--------------------------------------------------------------------------  # ● Object Initialization  #--------------------------------------------------------------------------  def initialize      super(0, 0, Graphics.width, 64)      self.y = Graphics.height - self.height ; @fade_time = 60      self.opacity = 0 ; self.contents_opacity = 0       self.visible = MOG_ATTRIBUTE_LEVEL::SHOW_PRESS_BUTTON_WINDOW      refresh  end   #--------------------------------------------------------------------------  # ● Refresh  #--------------------------------------------------------------------------  def refresh      contents.clear      draw_text(0,0,self.width - 32,32,MOG_ATTRIBUTE_LEVEL::PRESS_BUTTON_TEXT.to_s,1)  end  #--------------------------------------------------------------------------  # ● Update  #--------------------------------------------------------------------------  def update      super      if @fade_time > 0         @fade_time -= 1 ; self.opacity += 20 ; self.contents_opacity += 20      else            if self.opacity > 0            self.y += 5 ; self.opacity -= 5 ; self.contents_opacity -= 5           end      end      end  end=end#==============================================================================# ■ Scene_Status#==============================================================================class Scene_Status < Scene_MenuBase    #--------------------------------------------------------------------------  # ● Start  #--------------------------------------------------------------------------  alias mog_atr_start start  def start      mog_atr_start       @attribute_window = Window_Attribute_Level.new(@actor)      @attribute_window.z = @status_window.z + 50  end    #--------------------------------------------------------------------------  # ● On Actor Change  #--------------------------------------------------------------------------  alias mog_atr_on_actor_change on_actor_change  def on_actor_change      mog_atr_on_actor_change      @attribute_window.actor = @actor        end    #--------------------------------------------------------------------------  # ● Update  #--------------------------------------------------------------------------  alias mog_atr_update update  def update    mog_atr_update    if Input.trigger? (:C)      Sound.play_ok      @attribute_window.visible = @attribute_window.visible ? false : true    end  end  end#==============================================================================# ■ Game_Battler#==============================================================================class Game_Battler < Game_BattlerBase    attr_accessor :attribute_level    #--------------------------------------------------------------------------  # ● Initialize  #--------------------------------------------------------------------------  alias mog_attribute_initialize initialize  def initialize      initial_attribute_level      mog_attribute_initialize  end    #--------------------------------------------------------------------------  # ● Initial Attribute Level  #--------------------------------------------------------------------------  def initial_attribute_level      @attribute_level = [[],[]]      $data_system.elements.each_with_index do |i, index|         @attribute_level[0].push([1,0,0,false,index,i,0])      end      $data_system.weapon_types.each_with_index do |i, index|         @attribute_level[1].push([1,0,0,false,index,i,1])      end  end  #--------------------------------------------------------------------------  # ● Atr Clear EXP Phase  #--------------------------------------------------------------------------  def atr_clear_exp_phase      @attribute_level[0].each do |i| ; i[3] = false ; end      @attribute_level[1].each do |i| ; i[3] = false ; end  end      #--------------------------------------------------------------------------  # ● Atr Base EXP  #--------------------------------------------------------------------------  def atr_base_exp      return 1  end  #--------------------------------------------------------------------------  # ● Add Atr EXP  #--------------------------------------------------------------------------  def add_atr_exp(atr_id,type)       return if !atr_exp?(atr_id,type)       @attribute_level[type][atr_id][1] += atr_base_exp       @attribute_level[type][atr_id][2] += atr_base_exp       atr_level_up(atr_id,type) if atr_level_up?(atr_id,type)  end  #--------------------------------------------------------------------------  # ● Atr EXP ?  #--------------------------------------------------------------------------  def atr_exp?(atr_id,type)       return false if atr_id < 0       return false if atr_max_level?(atr_id,type)              return false if @attribute_level[type][atr_id][3]       return false if [nil,""].include?(@attribute_level[type][atr_id][5])              return false if type == 0 and MOG_ATTRIBUTE_LEVEL::DISABLE_ELEMENT_ID.include?(atr_id)       return false if type == 1 and MOG_ATTRIBUTE_LEVEL::DISABLE_WEAPON_ID.include?(atr_id)       return true  end    #--------------------------------------------------------------------------  # ● Atr Level UP  #--------------------------------------------------------------------------  def atr_level_up?(atr_id,type)      return false if atr_max_level?(atr_id,type)      return true if @attribute_level[type][atr_id][1] >= atr_next_exp(atr_id,type)      return false  end  #--------------------------------------------------------------------------  # ● Atr Max Level  #--------------------------------------------------------------------------  def atr_max_level?(atr_id,type)      return true if @attribute_level[type][atr_id][0] >= MOG_ATTRIBUTE_LEVEL::MAX_ATTRIBUTE_LEVEL      return false  end    #--------------------------------------------------------------------------  # ● Atr Level UP  #--------------------------------------------------------------------------  def atr_next_exp(atr_id,type)      return @attribute_level[type][atr_id][0] * MOG_ATTRIBUTE_LEVEL::NEXT_EXP_LEVEL_BASE  end  #--------------------------------------------------------------------------  # ● Atr Level UP  #--------------------------------------------------------------------------  def atr_level_up(atr_id,type)      @attribute_level[type][atr_id][0] += 1      @attribute_level[type][atr_id][1] = 0 unless atr_max_level?(atr_id,type)  end  #--------------------------------------------------------------------------  # ● Make Atr Damage Value  #--------------------------------------------------------------------------  alias mog_atr_make_damage_value make_damage_value  def make_damage_value(user, item)      mog_atr_make_damage_value(user, item)      if attribute_effect?(user, item)                  make_atr_damage_value(user, item)         excute_add_atr_exp(user, item)         if $imported[:mog_atb_system] and coop_make_damage_value?(user, item)            for actor in BattleManager.cskill_members(item.id)                next if actor == user                make_atr_damage_value(actor, item)                excute_add_atr_exp(actor, item)            end         end      end  end    #--------------------------------------------------------------------------  # ● Attribute Effect  #--------------------------------------------------------------------------  def attribute_effect?(user, item)      return false if item == nil      return false if item.is_a?(RPG::Item)      return false if user.is_a?(Game_Enemy)      return true  end    #--------------------------------------------------------------------------  # ● Execute Add Atr EXP  #--------------------------------------------------------------------------  def excute_add_atr_exp(user, item)      if item.id == user.attack_skill_id          if user.equips[0] != nil             atr_id_1 = user.equips[0].wtype_id             user.add_atr_exp(atr_id_1,1)          else                user.add_atr_exp(MOG_ATTRIBUTE_LEVEL::BARE_HANDS_ELEMENT_ID,0)             user.attribute_level[1][0][3] = true          end          if user.dual_wield? and user.equips[1] != nil             atr_id_2 = user.equips[1].wtype_id             user.add_atr_exp(atr_id_2,1)          end          user.attribute_level[1][atr_id_1][3] = true if atr_id_1 != nil          user.attribute_level[1][atr_id_2][3] = true if atr_id_2 != nil      else           user.add_atr_exp(item.damage.element_id,0)         if user.equips[0] != nil and            (item.required_wtype_id1 == user.equips[0].wtype_id or            item.required_wtype_id2 == user.equips[0].wtype_id)                     user.add_atr_exp(user.equips[0].wtype_id,1) ; wp_1 = true         end         if user.dual_wield? and user.equips[1] != nil and            (item.required_wtype_id1 == user.equips[1].wtype_id or            item.required_wtype_id2 == user.equips[1].wtype_id)            user.add_atr_exp(user.equips[1].wtype_id,1) ; wp_2 = true         end            user.attribute_level[0][item.damage.element_id][3] = true         user.attribute_level[1][user.equips[0].wtype_id][3] = true if wp_1         user.attribute_level[1][user.equips[1].wtype_id][3] = true if wp_2      end  end    #--------------------------------------------------------------------------  # ● Atr Dmg P  #--------------------------------------------------------------------------  def atr_dmg_p(user,atr_id,type)      ((user.attribute_level[type][atr_id][0] - 1)  * MOG_ATTRIBUTE_LEVEL::DAMAGE_PERCENTAGE_PER_LEVEL)  end        #--------------------------------------------------------------------------  # ● Make Atr Damage Value  #--------------------------------------------------------------------------  def make_atr_damage_value(user, item)      b_damage = @result.hp_damage if item.damage.to_hp?      b_damage = @result.mp_damage if item.damage.to_mp?      b_damage = 0 if b_damage.nil?      if item.id == user.attack_skill_id         if user.equips[0] != nil            atr_id = user.equips[0].wtype_id            dam = b_damage * atr_dmg_p(user,atr_id,1) / 100            execute_atr_damage(user,dam,item)         else               dam = b_damage * atr_dmg_p(user,MOG_ATTRIBUTE_LEVEL::BARE_HANDS_ELEMENT_ID,0) / 100            execute_atr_damage(user,dam,item)                   end          if user.dual_wield? and user.equips[1] != nil            atr_id = user.equips[1].wtype_id            dam = b_damage * atr_dmg_p(user,atr_id,1) / 100            execute_atr_damage(user,dam,item)         end      else            dam = b_damage * atr_dmg_p(user,item.damage.element_id,0) / 100            execute_atr_damage(user,dam,item)            if user.equips[0] != nil and               (item.required_wtype_id1 == user.equips[0].wtype_id or                item.required_wtype_id2 == user.equips[0].wtype_id)                atr_id = user.equips[0].wtype_id                dam = b_damage * atr_dmg_p(user,atr_id,1) / 100                execute_atr_damage(user,dam,item)            end            if user.dual_wield? and user.equips[1] != nil and               (item.required_wtype_id1 == user.equips[1].wtype_id or               item.required_wtype_id2 == user.equips[1].wtype_id)               atr_id = user.equips[1].wtype_id               dam = b_damage * atr_dmg_p(user,atr_id,1) / 100                              execute_atr_damage(user,dam,item)            end       end  end    #--------------------------------------------------------------------------  # ● Execute ATR Damage  #--------------------------------------------------------------------------  def execute_atr_damage(user,b_damage,item)      m_size = 1      if $imported[:mog_atb_system] and coop_make_damage_value?(user, item)          m_size = BattleManager.cskill_members(item.id).size if BattleManager.cskill_members(item.id).size > 0      end              @result.hp_damage += (b_damage / m_size) if item.damage.to_hp?      @result.mp_damage += (b_damage / m_size) if item.damage.to_mp?      end  end#==============================================================================# ■ Scene Battle#==============================================================================class Scene_Battle < Scene_Base    #--------------------------------------------------------------------------  # ● Use Item  #--------------------------------------------------------------------------  alias mog_atr_level_use_item use_item  def use_item      mog_atr_level_use_item      @subject.atr_clear_exp_phase  end  end#==============================================================================# ■ Game Battler#==============================================================================class Game_Battler < Game_BattlerBase    #--------------------------------------------------------------------------  # ● Make Action  #--------------------------------------------------------------------------  def make_action_r(skill_id, target_index)        clear_actions      action = Game_Action.new(self, true)      action.set_skill(skill_id)      action.target_index = target_index      @actions.push(action)      end   end#==============================================================================# ■ Game Actor#==============================================================================class Game_Actor < Game_Battler  attr_reader   :actor_idend#==============================================================================# ■ Scene Battle#==============================================================================class Scene_Battle < Scene_Base    #--------------------------------------------------------------------------  # ● Execute Action  #--------------------------------------------------------------------------  alias mog_atr_level_execute_action execute_action  def execute_action      execute_random_learning if execute_random_learning?      mog_atr_level_execute_action  end  #--------------------------------------------------------------------------  # ● Execute Random Learning?  #--------------------------------------------------------------------------  def execute_random_learning?      return false if !MOG_SAGA_SKILL::ENABLE_SKILL_LEARNING      return false if @subject.nil?      return false if @subject.is_a?(Game_Enemy)          item = @subject.current_action.item rescue nil      return false if item == nil      return false if item.is_a?(RPG::Item)      return false if $imported[:mog_atb_system] and BattleManager.is_cskill?(item.id)      return true  end    #--------------------------------------------------------------------------  # ● Execute Random Learning  #--------------------------------------------------------------------------  def execute_random_learning      item = @subject.current_action.item ; success = false ; skill_id = 0 ; skill = nil      if item.id ==  @subject.attack_skill_id         if @subject.equips[0] != nil            atr_id = @subject.equips[0].wtype_id ; type = 1         else               atr_id = MOG_ATTRIBUTE_LEVEL::BARE_HANDS_ELEMENT_ID ; type = 0         end           skill_list = MOG_SAGA_SKILL::ELEMENT_LEARN_SKILL[atr_id] if type == 0         skill_list = MOG_SAGA_SKILL::WEAPON_LEARN_SKILL[atr_id] if type == 1      else         atr_id = item.damage.element_id ; type = 0         skill_list = MOG_SAGA_SKILL::ELEMENT_LEARN_SKILL[atr_id]      end      if skill_list != nil ; skill_list.each do |i| ; skill_id = i[0]         skill = $data_skills[skill_id]         if atr_learn_skill?(skill,atr_id,i[1],type)            success = true ; @subject.learn_skill(skill_id) ; break         end      end      end      if success and skill_id != 0         target = @subject.current_action.target_index          @subject.make_action_r(skill_id, target)         @log_window.display_learned_skill(@subject.name,skill.name)         execute_learning_animation      end  end  #--------------------------------------------------------------------------  # ● Atr Learn Skill  #--------------------------------------------------------------------------  def atr_learn_skill?(skill,atr_id,lv_r,type)      return false if skill == nil      return false if $imported[:mog_atb_system] and BattleManager.is_cskill?(skill.id)      nskill = MOG_SAGA_SKILL::ACTOR_NOT_LEARN_SKILL_ID[@subject.actor_id]      return false if !nskill.nil? and nskill.include?(skill.id)      return false if !@subject.added_skill_types.include?(skill.stype_id)      return false if @subject.skill_learn?(skill)      return false if @subject.attribute_level[type][atr_id][0] < lv_r      success_rate = MOG_SAGA_SKILL::SUCCESS_RATE + (@subject.attribute_level[type][atr_id][0] - lv_r).abs      return false if success_rate < rand(100)      return true  end  #--------------------------------------------------------------------------  # ● Execute Learning Animation  #--------------------------------------------------------------------------  def execute_learning_animation      @subject.animation_id = MOG_SAGA_SKILL::LEARNING_ANIMATION_ID      return if @subject.animation_id.nil? or @subject.animation_id < 1      animation = $data_animations[@subject.animation_id] rescue nil      return if animation.nil?      anid = (animation.frame_max * 4) + 1 ; anid.times do ; update_basic ; end  end  end#==============================================================================# ■ Window BattleLog#==============================================================================class Window_BattleLog < Window_Selectable    #--------------------------------------------------------------------------  # ● Display Learned Skill  #--------------------------------------------------------------------------  def display_learned_skill(battler_name,skill_name)      text = battler_name.to_s + " " + MOG_SAGA_SKILL::BATTLE_LOG_TEXT + " " + skill_name.to_s + "!"      replace_text(text) ; wait  endend 
 
Yanfly modified with "Skills" tab that opens the attribute window, but behind all other windows:
Code:
#==============================================================================# # ▼ Yanfly Engine Ace - Ace Status Menu v1.02# -- Last Updated: 2011.12.26# -- Level: Normal# -- Requires: n/a# #============================================================================== $imported = {} if $imported.nil?$imported["YEA-StatusMenu"] = true #==============================================================================# ▼ Updates# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=# 2012.08.06 - Fix Sp Paramater TCR# 2011.12.26 - Compatibility Update: Rename Actor# 2011.12.23 - Started Script and Finished.# #==============================================================================# ▼ Introduction# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=# This script changes the status screen completely to something the player can# interact with more and be able to view actor data with more clarity. The# player is able to view the general information for an actor (parameters and# experience), a parameters bar graph, the various hidden extra parameters# (named properties in the script), and a customizable biography for the actor.# Also with this script, biographies can be changed at any time using a script# call to add more of a personal touch to characters.# #==============================================================================# ▼ Instructions# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=# To install this script, open up your script editor and copy/paste this script# to an open slot below ▼ Materials/素材 but above ▼ Main. Remember to save.# # -----------------------------------------------------------------------------# Script Calls - These commands are used with script calls.# -----------------------------------------------------------------------------# $game_actors[x].description = string# Changes the biography description for actor x to that of the string. Use \n# to designate linebreaks in the string. If you wish to use text codes, write# them in the strings as \\n[2] or \\c[3] to make them work properly.# #==============================================================================# ▼ Compatibility# =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=# This script is made strictly for RPG Maker VX Ace. It is highly unlikely that# it will run with RPG Maker VX without adjusting.# #============================================================================== module YEA  module STATUS        #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    # - Command Window Settings -    #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    # This section adjusts the commands that appear in the command window used    # for the status screen. Rearrange the commands, add new ones, remove them    # as you see fit.    #     # -------------------------------------------------------------------------    # :command         Description    # -------------------------------------------------------------------------    # :general         Adds general page.    # :parameters      Adds parameters page.    # :properties      Adds properties page.    # :biography       Adds biography page.    #     # :rename          Requires YEA - Rename Actor    # :retitle         Requires YEA - Retitle Actor    #     #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    COMMANDS =[ # The order at which the menu items are shown.    # [    :command,    "Display"],      [    :general,    "General"],      [ :properties, "Properties"],      [    :atr_mog,     "Skills"],    # [    :custom2,  "Equipment"],    # [    :custom3,      "Class"],      [  :biography,  "Biography"],      [     :rename,     "Rename"],  # Requires YEA - Rename Actor      [    :retitle,    "Retitle"],  # Requires YEA - Rename Actor    ] # Do not remove this.        #--------------------------------------------------------------------------    # - Status Custom Commands -    # - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -    # For those who use scripts to that may produce unique effects for the    # status menu, use this hash to manage the custom commands for the Status    # Command Window. You can disable certain commands or prevent them from    # appearing by using switches. If you don't wish to bind them to a switch,    # set the proper switch to 0 for it to have no impact.    #--------------------------------------------------------------------------    CUSTOM_STATUS_COMMANDS ={    # :command => [EnableSwitch, ShowSwitch, Handler Method, Window Draw],      :custom1 => [           0,          0, :command_name1, :draw_custom1],      :custom2 => [           0,          0, :command_name2, :draw_custom2],      :custom3 => [           0,          0, :command_name3, :draw_custom3],    } # Do not remove this.        #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    # - General Window Settings -    #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    # These settings adjust the way the general window visually appears.    # Not many changes need to be done here other than vocab changes.    #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    PARAMETERS_VOCAB = "Status"         # Title used for Parameters.    EXPERIENCE_VOCAB = "Experience"         # Title used for Experience.    NEXT_TOTAL_VOCAB = "Next %s Total Exp"  # Label used for total experience.        #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    # - Parameters Window 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.    #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    PROPERTIES_FONT_SIZE = 24        # Font size used for properties.        # These are the properties that appear in column 1.    PROPERTIES_COLUMN1 =[      [:hit, "Hit"],      [:eva, "Evade"],      [:cri, "Crit"],      [:cev, "Crit Evade"],      [:mev, "Mag Evade"],      [:mrf, "Magic Reflect"],    ] # Do not remove this.        # These are the properties that appear in column 2.    PROPERTIES_COLUMN2 =[      [:hrg, "VP Regen"],      [:mrg, "SP Regen"],      [:pha, "Item Effect"],      [:mcr, "SP Cost Mod"],      [:cnt, "Counter"],      [:tgr, "Emnity"],    ] # Do not remove this.        # These are the properties that appear in column 3.    PROPERTIES_COLUMN3 =[          ] # Do not remove this.        #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    # - Biography Window Settings -    #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    # These settings adjust the way the biography appears including the title    # used at the top, the font size, and whatnot.    #=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-    BIOGRAPHY_NICKNAME_TEXT = "%s"   # How the nickname will appear.    BIOGRAPHY_NICKNAME_SIZE = 32            # Size of the font used.      end # STATUSend # YEA #==============================================================================# ▼ Editting anything past this point may potentially result in causing# computer damage, incontinence, explosion of user's head, coma, death, and/or# halitosis so edit at your own risk.#============================================================================== #==============================================================================# ■ Numeric#============================================================================== class Numeric    #--------------------------------------------------------------------------  # new method: group_digits  #--------------------------------------------------------------------------  unless $imported["YEA-CoreEngine"]  def group; return self.to_s; end  end # $imported["YEA-CoreEngine"]    end # Numeric #==============================================================================# ■ Game_Temp#============================================================================== class Game_Temp    #--------------------------------------------------------------------------  # public instance variables  #--------------------------------------------------------------------------  attr_accessor :scene_status_index  attr_accessor :scene_status_oy  end # Game_Temp #==============================================================================# ■ Game_Actor#============================================================================== class Game_Actor < Game_Battler    #--------------------------------------------------------------------------  # new method: description=  #--------------------------------------------------------------------------  def description=(text)    @description = text  end    #--------------------------------------------------------------------------  # overwrite method: description  #--------------------------------------------------------------------------  def description    return @description unless @description.nil?    return actor.description  end  end # Game_Actor #==============================================================================# ■ Window_StatusCommand#============================================================================== class Window_StatusCommand < Window_Command    #--------------------------------------------------------------------------  # public instance variables  #--------------------------------------------------------------------------  attr_accessor :item_window    #--------------------------------------------------------------------------  # initialize  #--------------------------------------------------------------------------  def initialize(dx, dy)    super(dx, dy)    @actor = nil  end    #--------------------------------------------------------------------------  # window_width  #--------------------------------------------------------------------------  def window_width; return 160; end    #--------------------------------------------------------------------------  # actor=  #--------------------------------------------------------------------------  def actor=(actor)    return if @actor == actor    @actor = actor    refresh  end    #--------------------------------------------------------------------------  # visible_line_number  #--------------------------------------------------------------------------  def visible_line_number; return 4; end    #--------------------------------------------------------------------------  # ok_enabled?  #--------------------------------------------------------------------------  def ok_enabled?    return handle?(current_symbol)  end    #--------------------------------------------------------------------------  # make_command_list  #--------------------------------------------------------------------------  def make_command_list    return unless @actor    for command in YEA::STATUS::COMMANDS      case command[0]      #--- Default ---      when :general, :parameters, :properties, :biography, :atr_mog        add_command(command[1], command[0])      #--- Yanfly Engine Ace ---      when :rename        next unless $imported["YEA-RenameActor"]        add_command(command[1], command[0], @actor.rename_allow?)      when :retitle        next unless $imported["YEA-RenameActor"]        add_command(command[1], command[0], @actor.retitle_allow?)      #--- Custom Commands ---      else        process_custom_command(command)      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    #--------------------------------------------------------------------------  # process_ok  #--------------------------------------------------------------------------  def process_ok    $game_temp.scene_status_index = index    $game_temp.scene_status_oy = self.oy    super  end    #--------------------------------------------------------------------------  # process_custom_command  #--------------------------------------------------------------------------  def process_custom_command(command)    return unless YEA::STATUS::CUSTOM_STATUS_COMMANDS.include?(command[0])    show = YEA::STATUS::CUSTOM_STATUS_COMMANDS[command[0]][1]    continue = show <= 0 ? true : $game_switches[show]    return unless continue    text = command[1]    switch = YEA::STATUS::CUSTOM_STATUS_COMMANDS[command[0]][0]    enabled = switch <= 0 ? true : $game_switches[switch]    add_command(text, command[0], enabled)  end    #--------------------------------------------------------------------------  # update  #--------------------------------------------------------------------------  def update    super    update_item_window  end    #--------------------------------------------------------------------------  # update_item_window  #--------------------------------------------------------------------------  def update_item_window    return if @item_window.nil?    return if @current_index == current_symbol    @current_index = current_symbol    @item_window.refresh  end    #--------------------------------------------------------------------------  # item_window=  #--------------------------------------------------------------------------  def item_window=(window)    @item_window = window    update  end    #--------------------------------------------------------------------------  # update_help  #--------------------------------------------------------------------------  def update_help    return if @actor.nil?    @help_window.set_text(@actor.actor.description)  end  end # Window_StatusCommand #==============================================================================# ■ Window_StatusActor#============================================================================== class Window_StatusActor < Window_Base    #--------------------------------------------------------------------------  # initialize  #--------------------------------------------------------------------------  def initialize(dx, dy)    super(dx, dy, window_width, fitting_height(4))    @actor = nil  end    #--------------------------------------------------------------------------  # window_width  #--------------------------------------------------------------------------  def window_width; return Graphics.width - 160; end    #--------------------------------------------------------------------------  # actor=  #--------------------------------------------------------------------------  def actor=(actor)    return if @actor == actor    @actor = actor    refresh  end    #--------------------------------------------------------------------------  # refresh  #--------------------------------------------------------------------------  def refresh    contents.clear    return unless @actor    draw_actor_face(@actor, 0, 0)    draw_actor_simple_status(@actor, 108, line_height / 2)  end  end # Window_StatusActor #==============================================================================# ■ Window_StatusItem#============================================================================== class Window_StatusItem < Window_Base    #--------------------------------------------------------------------------  # initialize  #--------------------------------------------------------------------------  def initialize(dx, dy, command_window)    super(dx, dy, Graphics.width, Graphics.height - dy)    @command_window = command_window    @actor = nil    refresh  end    #--------------------------------------------------------------------------  # actor=  #--------------------------------------------------------------------------  def actor=(actor)    return if @actor == actor    @actor = actor    refresh  end    #--------------------------------------------------------------------------  # refresh  #--------------------------------------------------------------------------  def refresh    contents.clear    reset_font_settings    return unless @actor    draw_window_contents  end    #--------------------------------------------------------------------------  # draw_window_contents  #--------------------------------------------------------------------------  def draw_window_contents    case @command_window.current_symbol    when :general      draw_actor_general    when :parameters      draw_parameter_graph    when :properties      draw_properties_list    when :biography, :rename, :retitle      draw_actor_biography    when :atr_mog      draw_atrmog    else      draw_custom    end  end    #--------------------------------------------------------------------------  # draw_actor_general  #--------------------------------------------------------------------------  def draw_actor_general    change_color(system_color)    text = YEA::STATUS::PARAMETERS_VOCAB    draw_text(0, 0, contents.width/2, line_height, text, 1)    text = YEA::STATUS::EXPERIENCE_VOCAB    draw_text(contents.width/2, 0, contents.width/2, line_height, text, 1)    draw_general_parameters    draw_general_experience  end    #--------------------------------------------------------------------------  # draw_general_parameters  #--------------------------------------------------------------------------  def draw_general_parameters    dx = 24    dy = line_height / 2    draw_actor_level(dx, line_height*1+dy, contents.width/2 - 24)    draw_actor_param(0, dx, line_height*2+dy, contents.width/2 - 24)    draw_actor_param(1, dx, line_height*3+dy, contents.width/2 - 24)    draw_actor_param(2, dx, line_height*4+dy, contents.width/4 - 12)    draw_actor_param(4, dx, line_height*5+dy, contents.width/4 - 12)    draw_actor_param(6, dx, line_height*6+dy, contents.width/4 - 12)    dx += contents.width/4 - 12    draw_actor_param(3, dx, line_height*4+dy, contents.width/4 - 12)    draw_actor_param(5, dx, line_height*5+dy, contents.width/4 - 12)    draw_actor_param(7, dx, line_height*6+dy, contents.width/4 - 12)  end    #--------------------------------------------------------------------------  # draw_actor_level  #--------------------------------------------------------------------------  def draw_actor_level(dx, dy, dw)    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, Vocab::level)    change_color(normal_color)    draw_text(dx+4, dy, dw-8, line_height, @actor.level.group, 2)  end    #--------------------------------------------------------------------------  # draw_actor_param  #--------------------------------------------------------------------------  def draw_actor_param(param_id, dx, dy, dw)    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, Vocab::param(param_id))    change_color(normal_color)    draw_text(dx+4, dy, dw-8, line_height, @actor.param(param_id).group, 2)  end    #--------------------------------------------------------------------------  # draw_general_experience  #--------------------------------------------------------------------------  def draw_general_experience    if @actor.max_level?      s1 = @actor.exp.group      s2 = "-------"      s3 = "-------"    else      s1 = @actor.exp.group      s2 = (@actor.next_level_exp - @actor.exp).group      s3 = @actor.next_level_exp.group    end    s_next = sprintf(Vocab::ExpNext, Vocab::level)    total_next_text = sprintf(YEA::STATUS::NEXT_TOTAL_VOCAB, Vocab::level)    change_color(system_color)    dx = contents.width/2 + 12    dy = line_height * 3 / 2    dw = contents.width/2 - 36    draw_text(dx, dy + line_height * 0, dw, line_height, Vocab::ExpTotal)    draw_text(dx, dy + line_height * 2, dw, line_height, s_next)    draw_text(dx, dy + line_height * 4, dw, line_height, total_next_text)    change_color(normal_color)    draw_text(dx, dy + line_height * 1, dw, line_height, s1, 2)    draw_text(dx, dy + line_height * 3, dw, line_height, s2, 2)    draw_text(dx, dy + line_height * 5, dw, line_height, s3, 2)  end    #--------------------------------------------------------------------------  # draw_parameter_graph  #--------------------------------------------------------------------------  def draw_parameter_graph    draw_parameter_title    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)      change_color(system_color)      draw_text(28, dy, contents.width - 56, line_height, Vocab::param(i))      dw = (contents.width - 48) * rate - 8      change_color(normal_color)      draw_text(28, dy, dw, line_height, @actor.param(i).group, 2)    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    #--------------------------------------------------------------------------  # draw_param_gauge  #--------------------------------------------------------------------------  def draw_param_gauge(param_id, dy, rate)    dw = contents.width - 48    colour1 = param_gauge1(param_id)    colour2 = param_gauge2(param_id)    draw_gauge(24, dy, dw, rate, colour1, colour2)  end    #--------------------------------------------------------------------------  # param_gauge1  #--------------------------------------------------------------------------  def param_gauge1(param_id)    return YEA::STATUS::PARAM_COLOUR[param_id][1]  end    #--------------------------------------------------------------------------  # param_gauge2  #--------------------------------------------------------------------------  def param_gauge2(param_id)    return YEA::STATUS::PARAM_COLOUR[param_id][2]  end    #--------------------------------------------------------------------------  # draw_parameter_title  #--------------------------------------------------------------------------  def draw_parameter_title    colour = Color.new(0, 0, 0, translucent_alpha/2)    rect = Rect.new(0, 0, contents.width, contents.height)    contents.fill_rect(rect, colour)    change_color(system_color)    text = YEA::STATUS::PARAMETERS_VOCAB    draw_text(0, line_height/3, contents.width, line_height, text, 1)  end    #--------------------------------------------------------------------------  # draw_properties_list  #--------------------------------------------------------------------------  def draw_properties_list    contents.font.size = YEA::STATUS::PROPERTIES_FONT_SIZE    draw_properties_column1    draw_properties_column2    draw_properties_column3    reset_font_settings  end    #--------------------------------------------------------------------------  # draw_properties_column1  #--------------------------------------------------------------------------  def draw_properties_column1    dx = 8    dw = (contents.width - 24) / 2 - 24    dy = 22    for property in YEA::STATUS::PROPERTIES_COLUMN1      dy = draw_property(property, dx, dy, dw)    end  end    #--------------------------------------------------------------------------  # draw_properties_column2  #--------------------------------------------------------------------------  def draw_properties_column2    dx = 120 + (contents.width - 24) / 3    dw = (contents.width - 24) / 2 - 24    dy = 22    for property in YEA::STATUS::PROPERTIES_COLUMN2      dy = draw_property(property, dx, dy, dw)    end  end    #--------------------------------------------------------------------------  # draw_properties_column3  #--------------------------------------------------------------------------  def draw_properties_column3    dx = 24 + (contents.width - 24) / 3 * 2    dw = (contents.width - 24) / 3 - 24    dy = 0    for property in YEA::STATUS::PROPERTIES_COLUMN3      dy = draw_property(property, dx, dy, dw)    end  end    #--------------------------------------------------------------------------  # draw_property  #--------------------------------------------------------------------------  def draw_property(property, dx, dy, dw)    fmt = "%1.2f%%"    case property[0]    #---    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    #--------------------------------------------------------------------------  # draw_actor_biography  #--------------------------------------------------------------------------  def draw_actor_biography    fmt = YEA::STATUS::BIOGRAPHY_NICKNAME_TEXT    text = sprintf(fmt, @actor.name, @actor.nickname)    contents.font.size = YEA::STATUS::BIOGRAPHY_NICKNAME_SIZE    draw_text(0, 0, contents.width, line_height*2, text, 1)    reset_font_settings    draw_text_ex(24, line_height*2, @actor.description)  end    #--------------------------------------------------------------------------  # draw_custom  #--------------------------------------------------------------------------  def draw_custom    current_symbol = @command_window.current_symbol    return unless YEA::STATUS::CUSTOM_STATUS_COMMANDS.include?(current_symbol)    method(YEA::STATUS::CUSTOM_STATUS_COMMANDS[current_symbol][3]).call  end    #--------------------------------------------------------------------------  # draw_custom1  #--------------------------------------------------------------------------  def draw_atrmog    atrtxt = "Press Confirm to open the attributes window."    text = sprintf(atrtxt)    contents.font.size = YEA::STATUS::BIOGRAPHY_NICKNAME_SIZE    draw_text(0, 0, contents.width, line_height*2, text, 1)    reset_font_settings  end    #--------------------------------------------------------------------------  # draw_custom2  #--------------------------------------------------------------------------  def draw_custom2    dx = 4; dy = 0; slot_id = 0    for equip in @actor.equips      change_color(system_color)      text = Vocab.etype(@actor.equip_slots[slot_id])      draw_text(dx, dy, contents.width - dx, line_height, text)      reset_font_settings      draw_item_name(equip, dx+92, dy) unless equip.nil?      slot_id += 1      dy += line_height      break if dy + line_height > contents.height    end    dw = Graphics.width * 2 / 5 - 24    dx = contents.width - dw; dy = 0    param_id = 0    8.times do      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)      size = $imported["YEA-AceEquipEngine"] ? YEA::EQUIP::STATUS_FONT_SIZE : 20      contents.font.size = size      change_color(system_color)      draw_text(dx+4, dy, dw, line_height, Vocab::param(param_id))      change_color(normal_color)      dwa = (Graphics.width * 2 / 5 - 2) / 2      draw_text(dx, dy, dwa, line_height, @actor.param(param_id).group, 2)      reset_font_settings      change_color(system_color)      draw_text(dx + dwa, dy, 22, line_height, "→", 1)      param_id += 1      dy += line_height      break if dy + line_height > contents.height    end  end    #--------------------------------------------------------------------------  # draw_custom3  #--------------------------------------------------------------------------  def draw_custom3    return unless $imported["YEA-ClassSystem"]    data = []    for class_id in YEA::CLASS_SYSTEM::CLASS_ORDER      next if $data_classes[class_id].nil?      item = $data_classes[class_id]      next unless @actor.unlocked_classes.include?(item.id) or         YEA::CLASS_SYSTEM::DEFAULT_UNLOCKS.include?(item.id)      data.push(item)    end    dx = 0; dy = 0; class_index = 0    for class_id in data      item = data[class_index]      reset_font_settings      if item == @actor.class        change_color(text_color(YEA::CLASS_SYSTEM::CURRENT_CLASS_COLOUR))      elsif item == @actor.subclass        change_color(text_color(YEA::CLASS_SYSTEM::SUBCLASS_COLOUR))      else        change_color(normal_color)      end      icon = item.icon_index      draw_icon(icon, dx, dy)      text = item.name      draw_text(24, dy, contents.width-24, line_height, text)      next if YEA::CLASS_SYSTEM::MAINTAIN_LEVELS      level = @actor.class_level(item.id)      contents.font.size = YEA::CLASS_SYSTEM::LEVEL_FONT_SIZE      text = sprintf(YEA::CLASS_SYSTEM::CLASS_LEVEL, level.group)      dwa = contents.width - (Graphics.width * 2 / 5 - 24) - 28      draw_text(dx, dy, dwa, line_height, text, 2)      class_index += 1      dy += line_height      break if dy + line_height > contents.height    end    dw = Graphics.width * 2 / 5 - 24    dx = contents.width - dw; dy = 0    param_id = 0    8.times do      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)      contents.font.size = YEA::CLASS_SYSTEM::PARAM_FONT_SIZE      change_color(system_color)      draw_text(dx+4, dy, dw, line_height, Vocab::param(param_id))      change_color(normal_color)      dwa = (Graphics.width * 2 / 5 - 2) / 2      draw_text(dx, dy, dwa, line_height, @actor.param(param_id).group, 2)      reset_font_settings      change_color(system_color)      draw_text(dx + dwa, dy, 22, line_height, "→", 1)      param_id += 1      dy += line_height      break if dy + line_height > contents.height    end  end  end # Window_StatusItem #==============================================================================# ■ Scene_Status#============================================================================== class Scene_Status < Scene_MenuBase    #--------------------------------------------------------------------------  # start  #--------------------------------------------------------------------------  def start    super    create_help_window    create_command_window    create_status_window    create_item_window    relocate_windows  end    #--------------------------------------------------------------------------  # create_command_window  #--------------------------------------------------------------------------  def create_command_window    wy = @help_window.height    @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))    process_custom_status_commands  end    #--------------------------------------------------------------------------  # process_custom_status_commands  #--------------------------------------------------------------------------  def process_custom_status_commands    for command in YEA::STATUS::COMMANDS      next unless YEA::STATUS::CUSTOM_STATUS_COMMANDS.include?(command[0])      called_method = YEA::STATUS::CUSTOM_STATUS_COMMANDS[command[0]][2]      @command_window.set_handler(command[0], method(called_method))    end  end    #--------------------------------------------------------------------------  # create_status_window  #--------------------------------------------------------------------------  def create_status_window    wy = @help_window.height    @status_window = Window_StatusActor.new(@command_window.width, wy)    @status_window.viewport = @viewport    @status_window.actor = @actor  end    #--------------------------------------------------------------------------  # create_item_window  #--------------------------------------------------------------------------  def create_item_window    dy = @command_window.y + @command_window.height    @item_window = Window_StatusItem.new(0, dy, @command_window)    @item_window.viewport = @viewport    @item_window.actor = @actor    @command_window.item_window = @item_window  end    #--------------------------------------------------------------------------  # relocate_windows  #--------------------------------------------------------------------------  def relocate_windows    return unless $imported["YEA-AceMenuEngine"]    case Menu.help_window_location    when 0 # Top      @help_window.y = 0      @command_window.y = @help_window.height      @item_window.y = @command_window.y + @command_window.height    when 1 # Middle      @command_window.y = 0      @help_window.y = @command_window.height      @item_window.y = @help_window.y + @help_window.height    else # Bottom      @command_window.y = 0      @item_window.y = @command_window.height      @help_window.y = @item_window.y + @item_window.height    end    @status_window.y = @command_window.y  end    #--------------------------------------------------------------------------  # on_actor_change  #--------------------------------------------------------------------------  def on_actor_change    @command_window.actor = @actor    @status_window.actor = @actor    @item_window.actor = @actor    @command_window.activate  end    #--------------------------------------------------------------------------  # new method: command_name1  #--------------------------------------------------------------------------    #--------------------------------------------------------------------------  # new method: command_name2  #--------------------------------------------------------------------------  def command_name2    SceneManager.call(Scene_Equip)  end    #--------------------------------------------------------------------------  # new method: command_name3  #--------------------------------------------------------------------------  def command_name3    unless $imported["YEA-ClassSystem"]      @command_window.activate      return    end    SceneManager.call(Scene_Class)  end  end # Scene_Status #==============================================================================# # ▼ End of File# #============================================================================== 
 
Putting MOG's script below Yanfly's results in the attributes screen popping up every single time you press space/c/enter etc...
 
It's probably better if you get someone else to help you implement it. I thought it would be a simple SceneManager.call(Scene) but oh, how wrong I was xD
 
I recommend that you start a new topic with just this script problem, in RGSSx Script Support, as it doesn't involve writing a completely new script, just modifying existing ones.
 
Last edited by a moderator:

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Profile Posts

Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.
Do you Find Tilesetting or Looking for Tilesets/Plugins more fun? Personally I like making my tileset for my Game (Cretaceous Park TM) xD
How many parameters is 'too many'??

Forum statistics

Threads
105,860
Messages
1,017,038
Members
137,567
Latest member
sashalag
Top