• Welcome to Dark Bit Factory & Gravity.
 

Matrix Console Screen

Started by Hotshot, January 05, 2009

Previous topic - Next topic

0 Members and 0 Guests are viewing this topic.

Hotshot


Dim As Integer x,y,choice

Locate 25,55
Print "press Esc key to exit...";       
   
Do         
    x=Rnd * 80
    Y=Rnd * 25
   
    Locate y,x
   
    choice=Rnd(1)
       
    Select Case As Const Choice
            Case 0
                    Color 10
                    Print "1";                   
            Case 1
                    Color 2
                    Print "0";
        End Select
   
Loop Until  Inkey = Chr(27)


:)

Shockwave

Cool :)

Use the extended ascii set and scroll them down the screen and it will look pretty authentic :)
Shockwave ^ Codigos
Challenge Trophies Won:

bikerboy

#2
it looks nice and it surely could be imroved with some other characters and motion.

continue coding ;)

Ps. you forgot to put it to sleep :P

End Select
   
Loop Until  Inkey = Chr(27)


should be
End Select
sleep 1
Loop Until  Inkey = Chr(27)


or this one (correct me someone if i'm wrong with this, it's the first time i'm doing it)

DIM SHARED AS DOUBLE OLD,DV
Dim As Integer x,y,choice
        Locate 25,55
        Print "press Esc key to exit...";       
   
Do   
    x=Rnd * 80
    Y=Rnd * 25
   
    Locate y,x
   
    choice=Rnd(1)
    OLD=TIMER 
    Select Case As Const Choice
            Case 0
                    Color 10
                    Print "1"                 
            Case 1
                    Color 2
                    Print "0"
        End Select
        sleep 1
        DV=TIMER-OLD
Loop Until  Inkey = Chr(27)


Shockwave

Sleep (time in millisecs) pauses your program and returns some time to the operating system, it's good practice to do this as Bikerboy said.
Shockwave ^ Codigos
Challenge Trophies Won: