Computer Science Canada

put statements clearing line in turing4

Author:  RobinK [ Wed Mar 31, 2004 11:31 pm ]
Post subject:  put statements clearing line in turing4

I just switch to turing405 recently. I am now modifing one of my games to use some of turing4's features.

But I noticed that when a put statement is used, the whole line is cleared. This renders my whole program useless. How do I prevent that?

Author:  TheZsterBunny [ Thu Apr 01, 2004 2:46 am ]
Post subject: 

when you put, it clears the whole line.

try adding .. to the end of the line

the .. allows turing to continue along a line. This is useful for:

a) keeping existing information
b) getting input from the user

also, some handy similar commands

get variable:* - gets everything until the token (enter) rather than space.
put "things".. - keeps the rest of the line for use

Its too early to think more

-bunny

Author:  Tony [ Thu Apr 01, 2004 8:59 am ]
Post subject: 

I'm guessing that the issue here is the fact that then \n character is used the entire line becomes of the background color Confused

I would sujest using Font.Draw() instead to prevent clearning of the background image

Author:  Jodo Yodo [ Thu Apr 01, 2004 5:43 pm ]
Post subject: 

If you mean that the text is killing all of the text after it, then what Zster bunny said is correct (add '..' to the end). Otherwise, if what you mean is that the text is creating a band of colour that isn't the same as the background (assuming it isn't textured, since if it was, you'd be advanced enough to probably know about the '..' thing), simply do this:

code:

colourback (colourthingy)


Where 'colourthingy' is the name or number of the colour.


: