Based on my previous thread there, I've made a conditional branch that if the player had, for example, 500 Mana(EXP), he'd be able to use them as currency for leveling up. Although the level up part worked, but the animation, nor the show level up text worked. And, it just shows the else part even if the player has 500 Mana (And it still levels up once) :/
Animation doesn't play in a conditional branch.
RPG Maker MV SupportBecause this is mv I am not really sure. But most of the time when I get problems like this I add a Wait 1 frame between the Animation and the Change level.
Because sometimes a script disallows both message and animation happen on the same time.
If this does not work than it is odd to me as well :s
Edit:
Else I would simply remove the message and just make a nice level up animation 😉
Because sometimes a script disallows both message and animation happen on the same time.
If this does not work than it is odd to me as well :s
Edit:
Else I would simply remove the message and just make a nice level up animation 😉
If it shows the Else part, it means the condition is not being met. I'm guessing Level UP! is the name of a variable? Where are you setting it? Not in that event. You should put a Control Variables Level UP! = Actor (Liliana)'s MP, right before the conditional branch.
Or is that done at the top of your event? You've only shown a part of the event, so it would be good to see what's right at the top, and right at the bottom.
Or is that done at the top of your event? You've only shown a part of the event, so it would be good to see what's right at the top, and right at the bottom.
The top is just a text asking the player(s) what they want to do in that event spot, and then they'd be presented with these choices.
And.. How do I say this? The strange part is that I made a dummy event where it should trigger the variable if the player have 500EXP or above. Even with that, the Else part shows up, yet, when I pressed the menu, the actor is leveled up :/
And.. How do I say this? The strange part is that I made a dummy event where it should trigger the variable if the player have 500EXP or above. Even with that, the Else part shows up, yet, when I pressed the menu, the actor is leveled up :/
Was there some other way the actor could level up?
If you want to create a small demo using just default resources, and can get it to happen there, I'd be happy to download it and have a play around.
To repeat my question though, where are you setting the variable that you're testing? You can't just do this:
Control Variables: Level Up! = Actor's MP
once, then have it auto-update every time the player's MP changes. You need to do Control Variables to put the MP into a variable immediately before the conditional branch that checks it.
If you want to create a small demo using just default resources, and can get it to happen there, I'd be happy to download it and have a play around.
To repeat my question though, where are you setting the variable that you're testing? You can't just do this:
Control Variables: Level Up! = Actor's MP
once, then have it auto-update every time the player's MP changes. You need to do Control Variables to put the MP into a variable immediately before the conditional branch that checks it.
I set one in the Common events with a Switch to trigger it if the player gained some EXP from battles with this code:
Code:
Control Variables: #0005 Level UP! = $gameParty.members[0].nextRequiredExp()
So to me, that's saying if your party leader has more than 500 EXP to reach the next level, it will show the animation and increase the level. Is that what you intended?
Yes.
But your OP says the requirement is to have 500 EXP. That is not the same as 500 EXP required to reach the next level.
I'm sorry but, what do you mean?
So... I figured what the problem was.
I forgot the default system that as soon as the player gain some EXPs, it'll automatically level up, that's why the variables failed to work .___.
I forgot the default system that as soon as the player gain some EXPs, it'll automatically level up, that's why the variables failed to work .___.
if you want MP or other EXP to level up your actor, remove exp gain from enemies
or inside battles, but add variable to gain exp.
than the way you want will work if you put the common event correctly to level up.
there a re serveral ways to do that though.
exp gain in battle automatically level up the actor when the exp is reach.
custom exp = always better though, depening on the gameplay and mechanic.
or inside battles, but add variable to gain exp.
than the way you want will work if you put the common event correctly to level up.
there a re serveral ways to do that though.
exp gain in battle automatically level up the actor when the exp is reach.
custom exp = always better though, depening on the gameplay and mechanic.
I originally wanted to replace that with the gold as a Mana for leveling up. Maybe I should go back to that and work on it.
What I mean is you said in your OP that if the player has 500 EXP, you want this to happen. But your variable is set to how much EXP is needed for the next level, not how much the player has.
So imagine you have 200 EXP and you need 800 more in order to level up. The condition would be true, because 800 > 500.
However, if you had 800 EXP and only needed 200 more in order to level up, the condition would be false, because 200 < 500.
If you want it to be based on how much EXP they have, change
Code:
Control Variables: #0005 Level UP! = $gameParty.members[0].nextRequiredExp()
to
Code:
Control Variables: #0005 Level UP! = $gameParty.members[0].exp()
But then you have the other issue of leveling up automatically when they gain EXP. If you didn't want that to happen at all, it'd be a pretty small & simple plugin to do all the battle end stuff except give EXP (or put the EXP into a variable).
I wanna cry. After some revamp of the variable, it finally worked. I'll post this in my devlog soon.
I should reward myself with a latte 😢
The burden is finally dropped.
I should reward myself with a latte 😢
The burden is finally dropped.
This thread is being closed, due to being solved. If for some reason you would like this thread re-opened, please report this post and leave a message why. Thank you.
Original thread: https://forums.rpgmakerweb.com/threads/animation-doesnt-play-in-a-conditional-branch.124163/