Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Windows / print before looping

Years of Service
User Offline
Joined: 30th Jul 2015
Posted: 30th Jul 2015 11:26
so I'm going through some tutorials and I'm have a few issues using print before a loop
when I use the code

on my computer running windows 7 ultimate 64 bit
the screen is black
but broadcasting it to my tab s (android)
it displays Hello World

same with a timer function and I wonder why in windows it displays nothing unless it's inside the loop but on the android it displays fine (apparently like it should)
Any info is appreciated
Years of Service
User Offline
Joined: 4th Apr 2003
Location: Gods own County, UK
Posted: 30th Jul 2015 12:40 Edited at: 30th Jul 2015 12:44

The correct behaviour is that your example should display a black screen.

Print() must be repeated every cycle, it is cleared after every Sync() (in a standard setup)
You also have to Sync() every cycle.

Your code should look like this:

As you progress you will use the createText() function and associated commands. These remain on screen and are massively more versatile.

Why did it appear to work on Android? You did a single Sync and then nothing else. So you got the result of one Sync, essentially a frozen screen. In Windows because of the double-buffering system, it takes 2 Syncs right at the start of the program to get things going.

Quidquid latine dictum sit, altum sonatur
TutCity is being rebuilt
Years of Service
User Offline
Joined: 30th Jul 2015
Posted: 30th Jul 2015 19:35
Very helpful explanation, I need to see things for myself so I did a sync() print() sync() before the loop and it displayed as the frozen screen in windows Then I confused myself again. I used the createtext() function and found it would work with only one sync, even in windows. Why does that not need a second sync() but print () does?

Login to post a reply

Server time is: 2023-12-07 02:36:03
Your offset time is: 2023-12-07 02:36:03