
-----------------------------------
Mikeevd
Thu Apr 28, 2005 9:44 pm

How do you.... (I'm a newbie)
-----------------------------------
I just began using turing and I'm getting a hang of the basics but I don't really know how to do any of the more advanced things even after reading the manual over.  So if anyone could help me with the following:

What's the code for making the screen pretty much all black and having a countdown in large font in the middle...and then it breaks off onto the next part of the program after it hits "1".  I have no idea how to make this flow and I have no idea how to make the countdown thing at all, I've seen it before and am interested in seeing how it works...

Thanks in advance...

-----------------------------------
apomb
Thu Apr 28, 2005 9:54 pm


-----------------------------------
you could try the colorback(black)
cls
at the beginning of your program to make it fill the background black ... then look up Draw.Textin the F10 manual

hope this helps
-Compwiz

-----------------------------------
Mikeevd
Thu Apr 28, 2005 10:29 pm


-----------------------------------
Well I'm not at the computer with Turing on it yet so until I am and see what you said, more replies would be useful just incase :)

Thanks!

-----------------------------------
[Gandalf]
Thu Apr 28, 2005 10:44 pm


-----------------------------------
You might also want to look up delay(number) and for loops (or just loops in general).

Here is a small example.


for i : 1 .. 10
put i
delay(1000)
end for
cls
put "countdown complete"

-----------------------------------
Mikeevd
Fri Apr 29, 2005 1:11 pm


-----------------------------------
I looked up everything and understand how what you did works but how do I make each number as the countdown goes centered on it's an empty black screen...

I'm trying to make an empty black screen with large green font in the middle counting down from 10 to 1 but not showing any of the previous numbers like this:

10
9
8
7

...I'm not even sure how to make the count go down like that...only works 1 to 10 for me.

Sorry for all the  questions...thanks again.

-----------------------------------
Mikeevd
Fri Apr 29, 2005 1:15 pm


-----------------------------------
I just realized my dumbness...I can just put:

put "10"
delay (1000)
cls
put "9"


etc...

-----------------------------------
1of42
Fri Apr 29, 2005 3:35 pm


-----------------------------------
A much better way:


colorback (black)
cls

for decreasing i : 10 .. 1
   put i
   delay (1000)
end for

-----------------------------------
hacker101
Fri May 06, 2005 8:39 pm

Help
-----------------------------------
Just uses drawfillbox or you can use setscreen. 

To draw big text use Font Draw command



drawfillbox (1,1,640,400,16)


-----------------------------------
Cervantes
Sat May 07, 2005 7:26 am


-----------------------------------

View.Set ("offscreenonly")
colourback (black)
cls

var font := Font.New ("Impact:72")

for decreasing i : 10 .. 1
    for rep : 1 .. 2
        for c : 1 .. 255
            if rep = 1 then
                RGB.SetColour (200, 0, 255 - c, 0)
            else
                RGB.SetColour (200, 0, c, 0)
            end if
            cls
            Font.Draw (intstr (i), round (maxx / 2 - Font.Width (intstr (i), font) / 2), round (maxy / 2 - 72 / 2), font, 200)
            View.Update
            delay (1)
        end for
    end for
    delay (400)
    cls
end for


-----------------------------------
syphon4
Fri Jun 03, 2005 7:25 pm

countdown
-----------------------------------
heres something probaby at your level that you will understand...

var Counter : int := 10

drawfillbox (0, 0, maxx, maxy, 7)
colourback (black)
colour (green)

loop
    put " " : 40, Counter
    exit when Counter = 1
    Counter := Counter - 1
end loop

-----------------------------------
Cervantes
Fri Jun 03, 2005 7:39 pm


-----------------------------------
1.)
colourback (black) line is useless.  colourback only does anything when cls is called.  Either do the drawfillbox, or colourback & cls.
5.)
Instead of doing put : 40, Counter, you could use locate().
6.)
According to convention, classes start with capital letters; variables do not.  (correct?)
