Game Development Community

t2dTextObject and changing text

by Mr Zurkon · in iTorque 2D · 08/10/2011 (2:59 pm) · 2 replies

I'm trying to change the text of a t2dTextObject but it won't update.

I've created the object like this
%scoreText = new t2dTextObject(highscore) {blah blah

I'm trying to change it by using:
highscore.text("test");

am I using the wrong type of object? should I be using something else?

#1
08/10/2011 (3:25 pm)
IIRC, is either
highscore.text = "test";
OR
highscore.setText("test");

You are mixing both ;)
#2
08/10/2011 (9:54 pm)
Like Novack pointed out, it's highscore.text = "test';