/*
 F1GP-Guide 14/16 Arexx Front End
 ©1996 von Age Ass (Heiko Schröder) - - - - Multiview/Amigaguide Version
 ©1994-1995 Jim Hines All rights Reserved - - - - AmigaGuide Version
 */

NL = '0a'x


if ~show('L','rexxsupport.library') then
	call addlib('rexxsupport.library',0,-30)
if ~show('L','rexxarplib.library') then
	call addlib('rexxarplib.library',0,-30)
if ~show('L','rexxreqtools.library') then
 	call addlib('rexxreqtools.library',0,-30)

if ~exists('fgpguide.prefs') then do
	call Request(100, 100,"fgpguide.prefs DOES NOT EXIST\You MUST create it by using the\TG-Screen program." ,, "Live Long and Prosper",,)
	exit
end

screenmode = open(sm, 'fgpguide.prefs', 'r')
smvar = readln(sm)
close(sm)
parse var smvar width '|' height


call openport(notifyport)
call openscreen(0, 4, hireslace, 'Formel 1 Grand Prix 1996 v14/16 ©1996 Heiko Schröder', fgpguide,, width, height, 0)

/* WORKBENCH COLORS */
	Screencolor(fgpguide, 0, 8, 8, 7)
	Screencolor(fgpguide, 1, 0, 0, 0)
	Screencolor(fgpguide, 2, 0, 15, 15)
	Screencolor(fgpguide, 3, 14, 14, 3)
	Screencolor(fgpguide, 4, 7, 7, 15)
	Screencolor(fgpguide, 5, 15, 15, 15)
	Screencolor(fgpguide, 6, 11, 10, 9)
	Screencolor(fgpguide, 7, 15, 11, 10)

/*  PIC COLORS */
	Screencolor(fgpguide, 8, 0, 0, 0)
	Screencolor(fgpguide, 9, 1, 1, 1)
	Screencolor(fgpguide, 10, 3, 3, 3)
	Screencolor(fgpguide, 11, 5, 5, 5)
	Screencolor(fgpguide, 12, 7, 7, 7)
	Screencolor(fgpguide, 13, 9, 9, 9)
	Screencolor(fgpguide, 14, 10, 10, 10)
	Screencolor(fgpguide, 15, 12, 12, 12)

address ARexx "'call CreateHost(hostport, notifyport, fgpguide)'"

WaitForPort hostport
WaitForPort hostport
WaitForPort hostport

/* ========THESE DIRS & FILES PERTAIN TO THE MARK AND VIEW COMMANDS === 

if exists('fgp_1996.Guide') then do
	call PostMsg(0, 0,'Loading previously saved episode list.', fgp_1996.GUIDE)
	end*/

address command 'Multiview fgp_1996.GUIDE pubscreen fgpGUIDE'

fgpexit:
closescreen(fgpguide)
address command 'avail flush >nil:' /* flushes the no longer needed libs from memory */
exit
