home *** CD-ROM | disk | FTP | other *** search
- /*
- INTERPLAY AREXX COMMAND TEST SCRIPT
-
- Copyright (c) 1994 Optonica Limited
- Written by Kevin Stevens
- */
-
- ADDRESS TOIPPORT
-
- /* change these variables to test the different AREXX functionality */
- pagetest = 0
- mediatest = 0
- boxtest = 1
-
-
- if pagetest ~= 0 then do
- PAGE TYPE
- say 'Error = ' INTERPLAY.ERROR
-
- PAGE NAME
- say 'Error = ' INTERPLAY.ERROR
-
- PAGE NUMBER
- say 'Error = ' INTERPLAY.ERROR
-
- PAGE GOTO 2
- say 'Error = ' INTERPLAY.ERROR
- end
-
-
- if mediatest ~= 0 then do
- MEDIACLIP hd1:test/test.mclip
- say 'Error = ' INTERPLAY.ERROR
- end
-
-
- if boxtest ~= 0 then do
- count = 0
- do while count >= 0
- count = count + 1
- BOX TYPE count
- boxtype = INTERPLAY.ERROR
- select
- when boxtype = 'EMPTY' then do
- say 'EMPTY = ' count
-
- BOX ACTIVE count
- if INTERPLAY.ERROR ~= count then
- say "Can't activate box " count
- end
-
- when boxtype = 'BACKGROUND' then do
- BOX INFO count
- say 'BACKG = ' INTERPLAY.ERROR
- end
-
- when boxtype = 'IMAGE' then do
- BOX INFO count
- say 'IMAGE = ' INTERPLAY.ERROR
- end
-
- when boxtype = 'TITLE' then do
- BOX INFO count
- say 'TITLE = ' INTERPLAY.ERROR
- do 2
- do subbox = 1 to 4
- BOX ACTIVE count subbox
- end
- do subbox = 4 to 1 BY -1
- BOX ACTIVE count subbox
- end
- end
- end /* play with sub-boxes */
-
- when boxtype = 'TEXT' then do
- do 2
- do subbox = 1 to 4
- BOX ACTIVE count subbox
- end
- do subbox = 4 to 1 BY -1
- BOX ACTIVE count subbox
- end
- end /* play with sub-boxes */
-
- BOX INFO count /* get text file name */
- say 'TEXT = ' INTERPLAY.ERROR
-
- TEXT LINE TOTAL /* get no of lines in text file */
- say 'LINES = ' INTERPLAY.ERROR
-
- TEXT LINE DISPLAY /* get no of lines in box display */
- say 'DISPLAY = ' INTERPLAY.ERROR
-
- TEXT LINE /* get current top line number */
- say 'TOP LINE = ' INTERPLAY.ERROR
-
- TEXT ADD 1 'Hello Mum 2!' /* add text AFTER line 1 */
- TEXT ADD 0 'Hello Mum 1!' /* add text BEFORE line 1 */
- TEXT ADD '-1' 'Hello Mum 3!' /* add text at end */
- say 'add line = ' INTERPLAY.ERROR
-
- lineno = INTERPLAY.ERROR + 1
- TEXT LINE lineno /* get the text for a line */
- say 'TEXT LINE' lineno '=' INTERPLAY.ERROR
-
- TEXT DOWN 2 /* scroll text up & down */
- TEXT UP 1
- BOX SELECT count 2 /* select text UP gadget */
-
- TEXT FILE 'hd1:text/IP_FeatureList.txt' /* display a NEW text file */
- end
-
- when boxtype = 'LIST' then do
- LIST TEXT
- say 'TEXT = ' INTERPLAY.ERROR
-
- LIST NUMBER
- say 'ITEM NO = ' INTERPLAY.ERROR
-
- LIST DOWN 10
- LIST UP 5
-
- LIST ITEMS
- say 'ITEMS = ' INTERPLAY.ERROR
-
- listno = 0
- do while listno >= 0
- listno = listno + 1
- LIST TEXT listno
- if( INTERPLAY.ERROR == '' ) then do
- listno = -1
- end
- else do
- say 'ITEM' listno 'TEXT = "'||INTERPLAY.ERROR||'"'
- end
- end
- end
-
- when boxtype = 'ANIM' then do
- BOX INFO count
- say 'TEXT = ' INTERPLAY.ERROR
- end
-
- when boxtype = '' then do
- count = -1
- end
-
- otherwise do
- say 'UNKNOWN BOX TYPE = ' boxtype
- end
- end
- end
- end
-
- exit
-