display.newText and the .text property

I’m using display.newText to display some text that has a value that changes throughout the game. In fact, what is being displayed isn’t relevant, it could be any text value that changes throughtout a game.

The problem is that when I want to update the value the text becomes blurred because the new text is being drawn over the old text. At least, that’s what it looks like to me. I have written some code to remove the text object from the display group and nil it, before redrawing the text object, but still the text becomes blurry.

localGroup:remove(myTextObject)  
myTextObject = nil  

Is that code above not sufficient to remove a text object completely from the display?

Any ideas much appreciated. [import]uid: 26769 topic_id: 10998 reply_id: 310998[/import]

Well, I’ve solved the problem but I’m not altogether sure how. I think it was to do with the scope that I created the object within. By creating the object outside of any functions it now appears to be being drawn correctly.

Onwards! [import]uid: 26769 topic_id: 10998 reply_id: 39992[/import]

Onwards indeed!

Nice name :wink:

Peach [import]uid: 52491 topic_id: 10998 reply_id: 40114[/import]