exp to next level variable vx to vx ace

How would I make a script that would display a character's exp to next level as a variable? I found a script for vx where you would call a script with an event

next_exp(actor_id, variable for actor's next level)

and the script was

Code:
  def next_exp(member_id, var_id)    actor = $game_party.members[member_id]    exp = actor.next_rest_exp_s    exp = 0 if exp == "-------"    $game_variables[var_id] = exp  end
The way that you have it, the code would only work for actors in the current party. I redid it a little bit and made it so that it worked for any actor in the database:

#==============================================================================# ** Game_Interpreter#==============================================================================class Game_Interpreter def next_exp(member_id, var_id) actor = $game_actors[member_id] exp = actor.next_level_exp exp = 0 if actor.max_level? $game_variables[var_id] = exp end endIf that's not what you want simply change "actor = $game_actors[member_id]" to what you had originally: "actor = $game_party.members[member_id]".

Happy RMing!
That works! Thank you! It works just as I needed, and better since its any actor, it helps with those left in the monster farm.
No problem, happy to help.

Good luck!
Where exactly would you put this in the script manager, and how would you make it work exactly? I'm kinda new at editing script. 

Thanks

Original thread: https://forums.rpgmakerweb.com/threads/exp-to-next-level-variable-vx-to-vx-ace.14469/