Commit 16d8a969 authored by Cameron Cawley's avatar Cameron Cawley
Browse files

Convert CheckSound,ffb to plain text

parent a87feece
......@@ -35,11 +35,14 @@ INSTTYPE = app
INSTAPP_FILES = !Boot !Run !RunImage !Help Templates\
!Sprites !Sprites22 Sprites Sprites22 CheckSound
INSTAPP_VERSION = Messages
INSTAPP_DEPENDS = !RunImage
INSTAPP_DEPENDS = !RunImage CheckSound
include CApp
!RunImage: bas${SEP}PlayerSrc
${RUN}BasCrunch -1 bas${SEP}PlayerSrc $@
CheckSound: bas${SEP}CheckSound
${RUN}BasCrunch -1 bas${SEP}CheckSound $@
# Dynamic dependencies:
REM Check the availability of MIDI and Sound
REM 0.02 2nd June 1997
REM 0.03 5th Feb 2006 AJG - Fix for double tabs in Help string
DIM text% 256
IF FNCheckSound THEN
*Set Player$Sound 1
ELSE
*Set Player$Sound 0
ENDIF
IF FNCheckMIDI THEN
IF FNCheckMIDIPlayer THEN
*Set Player$MIDI 1
ELSE
*Set Player$MIDI 0
ENDIF
ELSE
*Set Player$MIDI 0
ENDIF
REM Memory to use defaults to 512K
REM Set to 0 to use all available memory
REM AudioMem 0
END
DEFFNCheckSound
LOCAL ERROR
ON ERROR LOCAL:PRINTE$:RESTORE ERROR:=FALSE
E$="This application requires SharedSound 0.44 or later"
OSCLI("RMEnsure SharedSound 0.44 RMload System:Modules.SSound")
OSCLI("RMEnsure SharedSound 0.44 Error "+E$)
E$="This application requires SamplePlayer 0.78 or later"
OSCLI("RMEnsure SamplePlayer 0.78 RMLoad <Player$Dir>.Player")
OSCLI("RMEnsure SamplePlayer 0.78 Error "+E$)
=TRUE
DEFFNCheckMIDIPlayer
LOCAL ERROR
ON ERROR LOCAL:PRINTE$:RESTORE ERROR:=FALSE
E$="This application requires MIDIPlay 2.24 or later"
OSCLI("RMEnsure MIDIPlay 2.24 RMLoad <Player$Dir>.MPlay")
OSCLI("RMEnsure MIDIPlay 2.24 Error "+E$)
=TRUE
DEFFNCheckMIDI
LOCAL V
V=FNGetVersion("MIDI")
=(V<>0)
DEFFNGetVersion(M$)
LOCAL V%,T%,N%
SYS"XOS_Module",18,M$ TO ,,,V%
IF V%=0 THEN
$text%="0"
ELSE
V%=V%+(V%!20)
T%=text%
WHILE ?V%<>9:V%+=1:ENDWHILE
IF ?V%=9:V%+=1:REM 0.03
REPEAT:V%+=1:?T%=?V%:T%+=1:UNTIL ?V%=32
?T%=13
ENDIF
=EVAL($text%)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment