[RMVX ACE] I WANT TO SHOW STAT PARAMETERS IN SHOP

Posts

Pages: 1
Hi, guys.

I never noticed that the RPG Maker doesn't have this basic feature.

I want the increase of stat parameters due to weapon, armor or helmet, etc. to be visible in the shop scene. Players should know what they buy.

Example: I have a weapon listed in the shop, which gives +5 ATK and -5 DEF.

What I want the shop to display:
ATK +5
DEF -5
MAT 0
MDF 0
AGI 0
LUK 0

What the shop displays by default:
+0

Does anyone want to help me with this?

I'm currently using SELL-ONLY SHOP SCRIPT v1.0 by Enelvon and Seiryuki btw.

Thanks in advance.
Marrend
Guardian of the Description Thread
21781
I was looking at your posts in Discord. The fact that you only have one actor means we could probably do a little something...

class Window_ShopStatus < Window_Base
  def draw_equip_info(x, y)
    #status_members.each_with_index do |actor, i|
      #draw_actor_equip_info(x, y + line_height * (0 * 2.4), actor)
    #end
    draw_actor_equip_info(x, line_height, $game_party.members[0])
  end
  
  def draw_actor_equip_info(x, y, actor)
    6.times { |i| 
      change_color(system_color)
      draw_text(x, y*(i+1), 112, line_height, Vocab::param(i+2))
      enabled = actor.equippable?(@item)
      change_color(normal_color, enabled)
      #draw_text(x, y, 112, line_height, actor.name)    
      item1 = current_equipped_item(actor, @item.etype_id)
      draw_actor_param_change(x, y*(i+1), actor, item1, i+2) if enabled
      #draw_item_name(item1, x, y + line_height, enabled)
    }
  end
  
  def draw_actor_param_change(x, y, actor, item1, param_id)
    rect = Rect.new(x, y, contents.width - 4 - x, line_height)
    change = @item.params[param_id] - (item1 ? item1.params[param_id] : 0)
    change_color(param_change_color(change))
    draw_text(rect, sprintf("%+d", change), 2)
  end
end


...like this.
Along the same lines as Marrend, it's a little crowded so may be worth commenting out the actor name / item name as well if you like.

class Window_ShopStatus < Window_Base
  #--------------------------------------------------------------------------
  # * Number of Actors Displayable at Once (override)
  #--------------------------------------------------------------------------
  def page_size
    return 1
  end
  #--------------------------------------------------------------------------
  # * Draw Actor Equipment Information (override)
  #--------------------------------------------------------------------------
  def draw_actor_equip_info(x, y, actor)
    enabled = actor.equippable?(@item)
    change_color(normal_color, enabled)
    draw_text(x, y - line_height, 112, line_height, actor.name)
    item1 = current_equipped_item(actor, @item.etype_id)
    draw_actor_param_change(x, y, actor, item1) if enabled
    draw_item_name(item1, x, y + (8 * line_height), enabled)
  end
  #--------------------------------------------------------------------------
  # * Draw Actor Parameter Change (override)
  #--------------------------------------------------------------------------
  def draw_actor_param_change(x, y, actor, item1)
    8.times.each do |param_id|
      rect = Rect.new(x, y + (param_id * line_height),
                      contents.width - 4 - x, line_height)
      change = @item.params[param_id] - (item1 ? item1.params[param_id] : 0)
      change_color(normal_color)
      draw_text(rect, sprintf("%s", $data_system.terms.params[param_id]))
      change_color(param_change_color(change))
      draw_text(rect, sprintf("%+d", change), 2)
    end
  end
end
Thank you both, guys. You're awesome.
Pages: 1