Where did my event go wrong? Loop/variables/cond. branch

● ARCHIVED · READ-ONLY
Started by Dymdez 6 posts View original ↗
  1. Disclaimer: Still new @ loops/break loops and cond. branches within...

    Ok, the idea of this combat tutorial event is that I setup a control variable for 2 things. The player's maxhp and current hp. The player is called upon to "block" and attack from a guard. If the player's HP = MAXHP after the attack, the player successfully guarded the attack, and the event moves on. However, if the player's hp is less than maxhp, the event will restore players health to max, then loop back and give them another chance at blocking successfully. For some reason, this event will always move on, regardless of hp. I don't know why it isn't looping if the player takes damage. Thanks in advance!

    HrLsYae.png
  2. Exactly before the conditional branch, put again the same control variable for the 

    [SIZE=13.63636302948px]Control Variables:[0062:player Current Hp]  = [Rain]'s HP[/SIZE]

    That will probably fix it.

    What happens is, you set MAX HP 

    you set Current HP (FULL I assume on start)

    Then something happens.

    If takes damage it does not update the current HP before the conditional branch.

    That's why you have to add after what you do and before the conditional branch...

    Control Variables:[0062:player Current Hp]  = [Rain]'s HP

    so the conditional branch will get an updated value of Rain's HP.

    Press Spoiler for Tutorial game.

    Also search for Andar (moderator) and look at his signature.

    He has a lot of tutorials there.  ;)
  3. Unless this is the only page related to the event you mentioned, could you please post screenshots of your eventing from the beginning? Thanks.
  4. @susan it was the only bit

    @dread thanks so much! that did it, and now i see why..

    variables.. love/hate em
  5. Glad I helped you @Dymdez 
  6. 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.