Hi,
I did a bit of testing as shown below:
[lua]local function main(event)
textobject.text = math.random(1,100)
end
Runtime:addEventListener(“enterFrame”, main)[/lua]
in contrast with
[lua]local i = 0
while true do
i=i+1
textobject.text = math.random(1,100)
if i==3 then break end
end[/lua]
In the first example I can see the text changing on screen but in the second example, the text doesn’t change at all until the while loop is broken.
Can someone explain this phenomenon to me?
Thank you. [import]uid: 108204 topic_id: 18862 reply_id: 318862[/import]