Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

Text size

edited April 2013 in Bugs Posts: 116

This object is only drawn when the win condition is met but sometimes the text is different sizes.

Suspiciously I do have other objects that change text size but I'd expect this to be thread isolated?

At the time of a win I should not be changing the text size for anything.


Win = class() function Win:init() -- you can accept and set parameters here self.colorR = math.random(1,255) self.colorB = math.random(1,255) self.colorG = math.random(1,255) end function Win:draw() -- Codea does not automatically call this method -- textSize(90) self.colorR = math.random(1,255) self.colorB = math.random(1,255) self.colorG = math.random(1,255) fill(self.colorR,self.colorB,self.colorG) textSize(90) text("YOU WIN",WIDTH/2,HEIGHT/2) end function Win:touched(touch) -- Codea does not automatically call this method end

Comments

  • Posts: 116

    Never mind... Confused font size with text size. You can delete this... Duh!

Sign In or Register to comment.