score tutorial

0 favourites
  • 10 posts
From the Asset Store
Carousel Animation, make carousel of you image gallery or anything
  • anyone have a tutorial capx to make a score? like in game score when playing,and then the score will be appear on game over layout.

  • I am quite new to C2 myself, but I am currently making a simplistic game that uses a timer as a score.

    The way you would do it however is using a variable:

    Define a variable and call it Score and default value to 0

    In your layout add a text string and call it ScoreDisplay with default text "0"

    Whenever an action increases the score, in your event you would go System > Add to (under variables section) and then add whatever score value you want to the variable.

    System > Every tick set the text value of ScoreDisplay to your variable.

    This should get the job done.

  • yes,i know that,but i want it appear on the another layout ex:GameOver layout.

    i have try to make it on GameOver layout.

    but,there's nothing happen with the score.

    ex: ``Game``

    Score = 5

    ``GameOver``

    Score = 0

  • Create a GameOverScore text in the GameOver layout by clicking the layout before you create the object.

    Then, in your event to show the GameOver layout, set the GameOverScore text property to the Score value.

    I hope this is what you meant. Else, maybe describe what you want in more details.

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • you need to try my game to understand

    scirra.com/arcade/example/12273/tibiame-fans-tibiame-hops

  • help pleaseee

  • ,

    This is what I do,Use a global variable for the score.

    Every tick-Set text of Score text in the game to Global variable Score

    In the event sheet of gameover layout,Creat another global variable called Highscore.And make a text object called Highscore text in the gameover layout.

    Event: Score>highscore ---> highscore set to score.

  • Have you tried doing what Digitalsa suggested, it should work.

    Without the code I can only guess that you are either:

    Not setting the text to the value of the score var correctly.

    Resetting the score var to zero at an inappropriate time eg before the restart button is pressed.

  • I have created a capx. However, I do not have enough permission for posting a link here or even pm.

    Send me your email address and I will send you a download link of the capx.

  • Thanks everybody,now it can <img src="smileys/smiley36.gif" border="0" align="middle" />

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)