home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
AMOS PD CD
/
amospdcd.iso
/
601-625
/
apd602
/
slide_show_ck.amos
/
slide_show_ck.amosSourceCode
Wrap
AMOS Source Code
|
1993-02-25
|
6KB
|
244 lines
'
'
' Slideshow Construction Kit v3.0
' -------------------------------
'
'
' Written by Ben Ashley, 1991 for Odyssey Software
'
Screen Close 0
Get Fonts
Screen Open 1,320,256,2,Lowres : Colour 1,$FFF : Pen 1 : Paper 0
Curs Off : Flash Off : Cls 0
Load Iff ":Utilities/SS.Iff",0
Limit Mouse 0,0 To 400,400
Set Font 3
Menu$(1)="(SFont 3) (INk 1,0) (INk 2,1) (INk 3,0)"
Menu$(1)="PROJECT " : Menu$(2)="EDIT " : Menu$(3)="MISC"
Menu$(1,1)="LOAD SHOW"
Menu$(1,2)="SAVE SHOW"
Menu$(1,3)="LOAD IFF"
Menu$(1,4)="LOAD MUSIC"
Menu$(1,5)="ABOUT"
Menu$(1,6)="QUIT"
'
Menu$(2,1)="NEXT PICTURE"
Menu$(2,2)="PREVIOUS PICTURE"
Menu$(2,3)="CLEAR PICTURE"
Menu$(2,4)="VIEW PICTURE"
Menu$(2,5)="PLAY MUSIC"
Menu$(2,6)="STOP MUSIC"
Menu$(2,7)="SET TEMPO"
Menu$(2,8)="SET VOLUME"
'
Menu$(3,1)="AUTHOR"
Menu$(3,2)="SET DELAY"
Menu$(3,3)="SET MAX PICS"
'
Menu On
'
' Set up all varibles, arrays, e.t.c
'
MA=100
N=1
Dim P$(MA)
Dim X$(MA)
DEL=200
M$=""
VOL=63 : TEMP=17
A$="ANON"
V$="V3.0"
S$=String$(" ",10)
S$=S$+"WELCOME TO "+V$+" OF SLIDESHOW CONSTRUCTION KIT"
S$=S$+" NEW IMPROVEMENTS: 1. COMPLETE RE-WRITE 2. A NICE BACKGROUND SCREEN AND FONT "
S$=S$+"3. NEW SCRIPTS INSTRUCTIONS FOR USE: THIS PROGRAM IS TO CONSTRUCT SLIDESHOWS "
S$=S$+"WHICH CAN BE RUN FROM THE SHOWER PROGRAMS. THEN THESE PROGRAMS CAN BE DISTRIBUTED AROUND "
S$=S$+"THE WORLD OF P.D. I HAVE COMPILED ONE OF THE SLIDE SHOWERS SO THAT YOU CAN RUN SLIDESHOWS FROM"
S$=S$+" THE CLI WITH AN EXTENSION NAME INSTEAD OF SELECTING ONE FROM A FILE REQUESTER. "
S$=S$+"I AM WRITING THIS SCROLLY, 15 MINUTES BEFORE I PLAY RUGBY AGAINST SOUTH WIGSTON... "
S$=S$+"AH WELL NO DAUDLING HERE'S THE BASIC USAGE... "
S$=S$+"FIRST YOU MUST SET THE MAXIMUM PICTURE NUMBER TO THE AMOUNT OF PICS YOU WANT IN YOUR SLIDESHOW."
S$=S$+"THEN LOAD EACH PICTURE ONE BY ONE INCREASING THE PICTURE NUMBER EACH TIME. "
S$=S$+"NOW IF YOU WANT A MUSIC FILE THEN LOAD IT NOW AND SET THE VOLUME AND TEMPO."
S$=S$+"IF YOU WANT ENTER YOUR NAME IN THE AUTHOR BOX. THIS MUST BE IN CAPITALS! ( IT WILL BE AUTOMATICALLY CHANGED UP IF IT IS NOT!"
S$=S$+" THAT'S THE BASIC USAGE..... "
V=1 : L=Len(S$)
'
Global F$,QUIT,MA,N,P$(),DEL,M$,VOL,TEMP,A$,V$,S$,V,L,X$()
'
MAIN
'
Procedure MAIN
Ink 1,0
Repeat
On Error Proc HELP
DIS
If Choice
CHECKMENU
End If
Until QUIT=True
Fade 3 : Wait 15*3
Edit
End Proc
'
Procedure CHECKMENU
On Error Proc HELP
If Choice(1)=1 and Choice(2)=1 Then LOSH
If Choice(1)=1 and Choice(2)=2 Then SASH
If Choice(1)=1 and Choice(2)=3 Then LOIF
If Choice(1)=1 and Choice(2)=4 Then LOMU
If Choice(1)=1 and Choice(2)=5 Then ABOUT
If Choice(1)=1 and Choice(2)=6 Then QUIT=True
'
If Choice(1)=2 and Choice(2)=1 Then NEPI
If Choice(1)=2 and Choice(2)=2 Then PRPI
If Choice(1)=2 and Choice(2)=3 Then CLPI
If Choice(1)=2 and Choice(2)=4 Then VIPI
If Choice(1)=2 and Choice(2)=5 Then Music 1
If Choice(1)=2 and Choice(2)=6 Then Music Off
CL
End Proc
'
Procedure DIS
Text 137,81," "+V$
Text 12,150,"PICTURE"+Str$(N)+" OUT OF"+Str$(MA)+" "
Text 12,158,"NAME:"+X$(N)
Text 12,166,"AUTHOR:"+A$
Text 12,174,"MUSIC FILE:"+M$
Text 12,182,"VOLUME:"+Str$(VOL)+" TEMPO:"+Str$(TEMP)+" "
Text 12,190,"DELAY RATE:"+Str$(DEL)
End Proc
'
Procedure CL
For F=150 To 250 Step 8
Text 12,F,String$(" ",50)
Next F
End Proc
'
Procedure LOSH
F$=Fsel$("*.Sld","","Load a Slideshow","")
If F$=""
Pop Proc
End If
Open In 1,F$
Input #1,V$
Input #1,MA$
MA=Val(MA$)
Input #1,VOL$
VOL=Val(VOL$)
Input #1,TEMP$
TEMP=Val(TEMP$)
Input #1,M$
Input #1,A$
For X=1 To MA
Input #1,P$(X)
Next X
Close 1
End Proc
'
Procedure SASH
F$=Fsel$("*.Sld","","Save a Slideshow","")
If F$=""
Pop Proc
End If
Open Out 1,F$
Print #1,V$
Print #1,MA
Print #1,VOL
Print #1,TEMP
Print #1,M$
Print #1,A$
For X=1 To MA
Print #1,P$(X)
Next X
Close 1
End Proc
'
Procedure LOIF
F$=Fsel$("","","Load an IFF Screen","")
If F$=""
Pop Proc
End If
P$(N)=F$
X$(N)=Upper$(F$)
Load Iff F$,1
Screen To Front 0
Screen 0
End Proc
'
Procedure LOMU
F$=Fsel$("*.Abk","","Load an .Abk File","")
If F$=""
Pop Proc
End If
M$=Upper$(F$)
Load M$
End Proc
'
Procedure ABOUT
Ink 20,0
Text 12,200,"ABOUT MODE. CLICK MOUSE TO EXIT"
Text 12,210," ODYSSEY SOFTWARE PRODUCTIONS "
Ink 1,0
Text 137,81," "
Repeat
Text 137,81,Mid$(S$,V,9) : V=V+1
If V>L
V=1
End If
Wait 5
Until Mouse Key=1
Text 137,81,String$(" ",10)
Text 12,200," "
Text 12,210," "
End Proc
'
Procedure NEPI
N=N+1
If N>MA
N=MA
End If
End Proc
'
Procedure PRPI
N=N-1
If N<1
N=1
End If
End Proc
'
Procedure CLPI
P$(N)=""
Screen Close 1
End Proc
'
Procedure VIPI
Screen To Front 1
Repeat
Until Mouse Key<>0
Screen To Front 0
End Proc
'
Procedure HELP
E=Errn
If E=30
E$="BAD IFF FORMAT"
End If
If E=261
E$="ILLEGAL FUNCTION CALL"
End If
If E=11
E$="OUT OF VARIBLE SPACE"
End If
Ink 22,0
Text 12,200,"ERROR CODE "+Str$(E)+" HAS OCCURED."
Text 12,220,E$
Text 12,240," CLICK MOUSE ! "
Repeat
Until Mouse Key<>0
Ink 1,0
Text 12,200," "
Text 12,220," "
Text 12,240," "
Resume Next
End Proc