Displaying math answer

Hello again, I have made this addition math activity where the numbers generate randomly and change every 5 seconds. However, what I am having trouble with is displaying the result/answer on the side of the screen to each math equation after the 5 seconds if that makes sense.

Best Answers

  • Two.ETwo.E Posts: 597
    Accepted Answer

    Attach is file.

    All I did was edit the Yellow scene (easy).

    I added a game.attribute called Display. And set it to 0.

    I unlocked the equation actor.

    I added a change behaviour so that every 5 seconds, this Display attribute is set to 0.
    And that the Result is updated.

    I added a new actor called display. It is next to your original actor and is unlocked. The logic basically says:

    When Display attribute = 0:
    After 4 seconds, change Display to 1.

    When Display attribute = 1,
    Display Result.

    What this does is displays the answer for 1 second. After 4 seconds. This way it all disappears once a new equation is added.

    Does that help?

  • Two.ETwo.E Posts: 597
    Accepted Answer

    Hi @jessica.michael

    Sorry for the late reply. I've attached a very simple demo project with the logic. Hopefully that helps explains what is happening. I added a few notes to help you navigate around.

    You can then take that concept and apply it to your game!

    Best,
    Two.E

Answers

  • Two.ETwo.E Member Posts: 597

    Can you share your file or a screen shot of the rules on how you are randomly generated the addition equations?

    Best,

  • jessica.michaeljessica.michael Member, PRO Posts: 27

    sorry here is the file. this might more sense

  • Two.ETwo.E Member Posts: 597

    It doesn't really make sense. I have the logic to display the answer after 5 seconds. But that answer is no longer going to make sense because there is now a new equation.

    Does that matter for you? You almost had it right.

  • jessica.michaeljessica.michael Member, PRO Posts: 27

    Yes that does help thank you so much. What if I make the equation display longer for 5 seconds so the answer can display for a little longer? Would this be possible?

  • Two.ETwo.E Member Posts: 597

    The questions change every 5 seconds. So you would change that timer value.

    The correct answer is displayed after 4 seconds a new question is display. If that is too quick / long would need to change that timer value.

  • jessica.michaeljessica.michael Member, PRO Posts: 27

    Okay I tried making the time longer however the answer still displayed for 1 second on the easy level and on the medium and hard the answer wouldn't change.

  • Two.ETwo.E Member Posts: 597
    edited May 2019

    That would be because I only adjusted the logic for easy level. You will need to have a look at what I did. And then apply that to the other Modes.

  • jessica.michaeljessica.michael Member, PRO Posts: 27

    Sorry, I tried to look at what you did but I don't really understand.

  • jessica.michaeljessica.michael Member, PRO Posts: 27

    Great, Thank you so much for your help !!

Sign In or Register to comment.