Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

Another Question about making new status?

How do you draw out a new parameter. for in G777 Script there is an option to add evade to the status menu.

I was wondering how do you do exactly that?
 
Alright i wanted evasion to apper in the status and equip window in the default menus.

I looked at the create your own attributes. but i'll wait a bit till the scripting academy is open before i mess around further with the defaults.

Since i made G777 Status set to false.
 
Well, this is the basic command for drawing evasion stat.

Code:
width = 192 # change this to whatever
self.contents.font.color = system_color
self.contents.draw_text(x + 4, y, width - 4, 32, 'Evasion : ')
self.contents.font.color = normal_color
self.contents.draw_text(x + 4, y, width - 4, 32, actor.eva.to_s, 2)

So, in for the equipping, go into Window_EquipLeft:
Code:
  #--------------------------------------------------------------------------
  # * Refresh
  #--------------------------------------------------------------------------
  def refresh
    self.contents.clear
    draw_actor_name(@actor, 4, 0)
    draw_actor_level(@actor, 4, 32)
    draw_actor_parameter(@actor, 4, 64, 0)
    draw_actor_parameter(@actor, 4, 96, 1)
    draw_actor_parameter(@actor, 4, 128, 2)
    if @new_atk != nil
      self.contents.font.color = system_color
      self.contents.draw_text(160, 64, 40, 32, "->", 1)
      self.contents.font.color = normal_color
      self.contents.draw_text(200, 64, 36, 32, @new_atk.to_s, 2)
    end
    if @new_pdef != nil
      self.contents.font.color = system_color
      self.contents.draw_text(160, 96, 40, 32, "->", 1)
      self.contents.font.color = normal_color
      self.contents.draw_text(200, 96, 36, 32, @new_pdef.to_s, 2)
    end
    if @new_mdef != nil
      self.contents.font.color = system_color
      self.contents.draw_text(160, 128, 40, 32, "->", 1)
      self.contents.font.color = normal_color
      self.contents.draw_text(200, 128, 36, 32, @new_mdef.to_s, 2)
    end
  end

Just play around with this method, changing the text posisitioning until you find something you like. Insert that block from above, replace width and actor with @actor and you should be set.

Same goes in refresh method of Window_Status.

Let me know if you get lost anywhere. This is good practice on creating windows. :yes:
 

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top