home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
AMOS PD CD
/
amospdcd.iso
/
551-575
/
apd571
/
progs
/
scroller
/
sa16scroll.amos
/
sa16scroll.amosSourceCode
< prev
Wrap
AMOS Source Code
|
1993-12-02
|
2KB
|
99 lines
' New Scroll V2.1 - Sausage : Main Code + Bounce
' Angeldust : Multi-Speed + Bug Fix
' Freeze + Mirror + 16 Point
'
Unpack 5 To 1
Colour 8,$0
Colour 9,$0
Colour 10,$0
Shift Up 2,8,11,1
Screen Open 0,640,140,16,Lowres : Cls 0 : Curs Off : Flash Off
Screen 1
Flash 13,"(111,2)(222,2)(333,2)(555,2)(777,2)(999,2)(bbb,2)(ddd,2)"
Screen 0
Get Icon Palette
'Colour 1,$FFF
Global PP$
SS=80
Set Rainbow 0,0,100,"(5,-1,125)","",""
Rainbow 0,0,0,80
A$="A:M 320,0,RB;L X=0;L RA=1;J A;"
Amreg(1)=SS
' Bounce or No Bounce
' Bounce 1
B$="A:M 0,12,54;M 0,-24,52;"
B$=B$+"M 0,12,54;"
B$=B$+"J A;"
'
' For a halt you have to use trial and error !!
M$=M$+"A angeldust HM Cpresents a sixteen point scroller"
M$=M$+" NA thanks to sausage HC for the scroll routine"
M$=M$+""
' leave this empty
M$=M$+" "
N$=" abcdefghijklmnopqrstuvwxyz"
Channel 0 To Screen Offset 0 : Amal 0,A$
Amal On 0
Channel 1 To Screen Display 0 : Amal 1,B$
Amal On 1
Screen Display 0,140,-50,320,135
Do
SP=0 : C=1
For L=1 To Len(M$)
REAPEET:
PP$=Mid$(M$,L,1)
SPEEED
If Mouse Key=1 Then End
' Speed of Scroll
If(PP$="A") or(PP$="B") or(PP$="C") or(PP$="D") or(PP$="E")
Inc L : Goto REAPEET
End If
' Halts Scroll
If PP$="H"
Amal Freeze 0 : Wait 100 : Amal On 0 : Inc L
End If
' Starts Mirror effect
If PP$="M"
FLAG=1 : Inc L
End If
' Stops Mirror effect
If PP$="N"
FLAG=0 : Inc L
End If
'
S=Instr(N$,PP$) : If S=0 Then Goto REAPEET
Paste Icon SP+320,105,S
If FLAG=1
Paste Icon SP+320,105+18,$4000+S
End If
SP=SP+16
If SP>304 Then Gosub SLEEP
Next L
Gosub QUICKCOPY
Loop
QUICKCOPY:
Screen Copy 0,320,136-40,640,136 To 0,0,136-40
Cls 0,320,136-40 To 640,136
Amreg(0)=0 : SP=0 :
Return
SLEEP:
If Amreg(0)=1 Then Goto QUICKCOPY
Goto SLEEP
Procedure SPEEED
Shared PP$
If PP$="A"
Amreg(1)=30
End If
If PP$="B"
Amreg(1)=40
End If
If PP$="C"
Amreg(1)=80
End If
If PP$="D"
Amreg(1)=100
End If
If PP$="E"
Amreg(1)=120
End If
End Proc