Final Score Display

Hey guys!

I have a problem displaying the final score on the game over scene.

Here's the thing, my score increases every 0.1 second.

When I try to display the final score on the game over scene (create actor > Display text etc.), the score keeps increasing.

I do realize that I have to stop the attribute from changing or save the value or something, but I don't know how to do that.

Thank you. :) <3

Comments

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    @binou6 said:
    I do realize that I have to stop the attribute from changing or save the value or something, but I don't know how to do that.

    Yep, you're close! On the game over scene, change attribute game.finalScore to game.score. Then use game.finalScore in the Display Text expression. The fact that game.score keeps increasing every 0.1 seconds won't matter once you've stored the value of it in a new attribute.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • binou6binou6 Member Posts: 2

    Ohhh! I see! Thank you so much for your help! :)

  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949

    You're welcome!

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

Sign In or Register to comment.