can someone help me
what i want is to create a score of my app
can someone help me
what i want is to create a score of my app
My quick whack-a-mole example has scoring. Goal hit only the blue blocks when they appear.
https://github.com/roaminggamer/RG_FreeStuff/raw/master/AskEd/2016/10/whack.zip
This is one of several hundred answers found in the AskEd folder of my RG_FreeStuff archive:
create a score variable like this
local score = 0
when some action in your app earns the player a score then add to it
score = score + 100
you will then need to display it somehow
local options = {parent = scene, text = score, x = 100, y = 100, width = 100, fontSize = 12, align = "left"} local scoreText = display.newText(options)
then when the score changes you need to update the UI like this
scoreText.text = score
My quick whack-a-mole example has scoring. Goal hit only the blue blocks when they appear.
https://github.com/roaminggamer/RG_FreeStuff/raw/master/AskEd/2016/10/whack.zip
This is one of several hundred answers found in the AskEd folder of my RG_FreeStuff archive:
create a score variable like this
local score = 0
when some action in your app earns the player a score then add to it
score = score + 100
you will then need to display it somehow
local options = {parent = scene, text = score, x = 100, y = 100, width = 100, fontSize = 12, align = "left"} local scoreText = display.newText(options)
then when the score changes you need to update the UI like this
scoreText.text = score