OnscreenText value

Hi, all. I am trying to figure out how to get an variable integer into the text portion of the OnscreenText command.

What is want is

c = 10 (c will actually represent a random number)
OnscreenText(text = c, style=1, etc, etc.

I figured out how to put a string in there using; text = self.a, but it won’t work for integers unless I put quotations around them.

I tried %d, but couldn’t get that to work either.

Thanks.

Did you try text = str(self.a) ?

That worked. Thank you!