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.

Experience Script

psiclone":2ttikeop said:
I was wondering if anyone could convert this to VX:

Experience Script

I can do this once I get home today. I'll edit this post.

Edit: Do you want the first or second script from that post? Also, you might want to check out this post before making another request in the future. (Just some advice)


Edit2: Here's the second script.
Code:
#
# Custom_Exp_Curve (Brew) (Edited by Glitchfinder to work in RPG Maker VX)
#
class Game_Actor
  #--------------------------------------------------------------------------
  # * Calculate EXP
  #  modify method to linear curve @ 100 EXP per level
  #--------------------------------------------------------------------------  
  def make_exp_list
    actor = $data_actors[@actor_id]
    @exp_list[1] = 0
    for i in 2..100
      if i >= 99
        @exp_list[i] = 0
      else
        @exp_list[i] = @exp_list[i-1] + 100
      end
    end
  end
  #--------------------------------------------------------------------------
  # * Set EXP
  #  modify method to round off extra exp when leveling up
  #--------------------------------------------------------------------------  
  def exp=(exp, show)
    @exp = [[exp, 9999999].min, 0].max
    # Level up
    while @exp >= @exp_list[@level+1] and @exp_list[@level+1] > 0
      @level += 1
      if @exp < @exp_list[@level+1]
        @exp = @exp_list[@level]
      end
      # Learn skill
      for j in $data_classes[@class_id].learnings
        if j.level == @level
          learn_skill(j.skill_id)
        end
      end
    end
    # Level down
    while @exp < @exp_list[@level]
      @level -= 1
    end
    # Correction if exceeding current max HP and max SP
    @hp = [@hp, self.maxhp].min
    @sp = [@sp, self.maxsp].min
    if show and @level > last_level
      display_level_up(skills - last_skills)
    end
  end
end
 

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