c'est pas parfait , mais bon ! le Soldat inconnu va nous en faire un extincteur d'ecran

Ps y pas tous les nom des inscrit sur le forum, je m'excuse pour ceux que j'oublie

il n'y a que 10 sprites , on peut en rajouter !!
pour les noms ,y a rien d'autre a faire que de les rajouter dans la variable nom$ ,le program va tenir compte tous seul des lettre rajouté !

Code : Tout sélectionner
#dobro=1
#dobro2=2
#dobro3=3
#dobro4=4
#dobro5=5
#dobro6=6
#dobro7=7
#dobro8=8
#dobro9=9
#dobro10=10
#Police=1
Resultat = InitSprite()
FontID = LoadFont(#Police, "arial", 18, #PB_Font_Bold )
WindowID = OpenWindow(1, 0, 0, 800, 600, #PB_Window_SystemMenu|#PB_Window_BorderLess |#PB_Window_ScreenCentered , "hello")
WindowID = WindowID(1)
Result = OpenWindowedScreen(WindowID,0,0, 800, 600, 1, 0,0)
nom$="D,O,B,R,O, ,C,E,D,E,R,A,V,I,C,K, ,F,W,E,I,L, ,O,L,I,V, ,H,E,I,S, ,S,P,I,T,E,R, ,L,E, ,S,O,L,D,A,T, ,I,N,C,O,N,N,U, ,F,R,E,D, ,P,U,R,E,B,A,S,I,C"
de= Random(800) :; on tire une colonne au hazard
; on crée un sprite
Resultat = CreateSprite(#dobro, 24,24*Len(nom$),0)
While Index<=Len(nom$)+1
Index=Index+1
car$ = StringField(nom$, Index, ",")
y=y+24:; pour que le text descende
StartDrawing(SpriteOutput(#dobro))
BackColor(0, 0,0)
FrontColor(0,255, 0)
Locate(0, y)
DrawingFont(FontID)
DrawText(car$)
StopDrawing()
Wend
CopySprite(#dobro, #dobro2)
CopySprite(#dobro, #dobro3)
CopySprite(#dobro, #dobro4)
CopySprite(#dobro, #dobro5)
CopySprite(#dobro, #dobro6)
CopySprite(#dobro, #dobro7)
CopySprite(#dobro, #dobro8)
CopySprite(#dobro, #dobro9)
CopySprite(#dobro, #dobro10)
; ça c'est pour faire demarer les sprite a des hauteurs differentes
ysprite=-800
ysprite2=-900
ysprite3=-850
ysprite4=-830
ysprite5=-880
ysprite6=-890
ysprite7=-810
ysprite8=-840
ysprite9=-820
ysprite10=-805
Repeat
RandomSeed(Random(255))
If ysprite>650
ysprite=0-Random(1600)-800
de= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite2>650
ysprite2=0-Random(1600)-800
de2= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite3>650
ysprite3=0-Random(1600)-800
de3= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite4>650
ysprite4=0-Random(1600)-800
de4= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite5>650
ysprite5=0-Random(1600)-800
de5= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite6>650
ysprite6=0-Random(1600)-800
de6= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite7>650
ysprite7=0-Random(1600)-800
de7= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite8>650
ysprite8=0-Random(1600)-800
de8= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite9>650
ysprite9=0-Random(1600)-800
de9= Random(800) :; on tire une colonne au hazard
EndIf
If ysprite10>650
ysprite10=0-Random(1600)-800
de10= Random(800) :; on tire une colonne au hazard
EndIf
; petite bidouille pour garder un semblant de multitache !
t=t+1
If t=10
event = WindowEvent()
t=0
EndIf
;******************************
ysprite+10:;vitesse de chaques sprites
ysprite2+8
ysprite3+10
ysprite4+5
ysprite5+9
ysprite6+4:;ça c'est un escargot !
ysprite7+12
ysprite8+15
ysprite9+6
ysprite10+20:; lui va tres vite
; apres avoir essaye plusieur style de sprite
; c'est displaytransparent qui rent le mieux le style "matrix"
DisplayTransparentSprite(#dobro, de, ysprite)
DisplayTransparentSprite(#dobro2, de2, ysprite2)
DisplayTransparentSprite(#dobro3, de3, ysprite3)
DisplayTransparentSprite(#dobro4, de4, ysprite4)
DisplayTransparentSprite(#dobro5, de5, ysprite5)
DisplayTransparentSprite(#dobro6, de6, ysprite6)
DisplayTransparentSprite(#dobro7, de7, ysprite7)
DisplayTransparentSprite(#dobro8, de8, ysprite8)
DisplayTransparentSprite(#dobro9, de9, ysprite9)
DisplayTransparentSprite(#dobro10, de10, ysprite10)
FlipBuffers()
ClearScreen(0, 0,0)
Until event=#PB_Event_CloseWindow
