Hello, Once again I'm asking for your help, I've been using a script to reduce party XP when fleeing a battle but I want it to prevent player going down a level when going to 1xp of that level. Example: Player is lvl4 has 69/420xp, he flees and losses xp and now is 1/420 instead going lvl3 369/420xp. The issue occurs when you lose skills and in game you can upgrade it and it costs a lot of skill points to get lvl 1 to lvl 3 skill.
What is the best option in your opinion to implement this? I've got few ideas but don't know if hung-up would work.
TL😀R: I want to prevent player dropping lvl and stopping at 1xp before going down a lvl making game not force you lose lvl skills and stats no mater how many times you flee a battle and lose xp.
$imported = {} if $imported.nil?
$imported["Sprawl_Escape"] = true
module BattleManager
def self.process_abort
replay_bgm_and_bgs
SceneManager.return
battle_end(1)
$game_party.all_members.each do |actor|
@exp_loss = -1 * actor.exp * 0.40;
actor.gain_exp(@exp_loss)
end
@xp_loss_str = @exp_loss * -1
text = "You lose " + @xp_loss_str.to_i.to_s
text = text + " experience points for fleeing."
$game_message.add('\.' + text)
wait_for_message
return true
end
end
What is the best option in your opinion to implement this? I've got few ideas but don't know if hung-up would work.
TL😀R: I want to prevent player dropping lvl and stopping at 1xp before going down a lvl making game not force you lose lvl skills and stats no mater how many times you flee a battle and lose xp.
$imported = {} if $imported.nil?
$imported["Sprawl_Escape"] = true
module BattleManager
def self.process_abort
replay_bgm_and_bgs
SceneManager.return
battle_end(1)
$game_party.all_members.each do |actor|
@exp_loss = -1 * actor.exp * 0.40;
actor.gain_exp(@exp_loss)
end
@xp_loss_str = @exp_loss * -1
text = "You lose " + @xp_loss_str.to_i.to_s
text = text + " experience points for fleeing."
$game_message.add('\.' + text)
wait_for_message
return true
end
end