{$ifndef unix}
{$A+,B-,D+,E+,F-,G+,I+,L+,N+,O-,P+,Q-,R-,S+,T-,V-,X+,Y+}
{$else}
{$B-,I+,S-,T-,X+}
{$endif}
unit ovrfirst;
interface

procedure initplanets;
procedure inithost;

implementation
uses
 utils,
 kb,
 vbios,
 data,
 grafik,
 hsiraw,
{$ifndef unix}
 crt;
{$else}
 xcrt;
{$endif}

procedure initplanets;
begin
{$ifndef unix}
 if not isegavga then begin
  writeln('Ben”tigt VGA-kompatiblen Adapter...   *sorry*  :-(');
  halt;
 end;
 writeln('Freie Datenspeicher (XMS):',memavail,'/800000');
 if memavail<800000 then halt;
{$endif}
 hsiread('planets1.raw');
 kbdelay(1750000);
 if ioresult<>0 then;
 filemode:=$90;

 new(planets1);
 new(planets2);

 new(bases1);
 new(bases2);
 new(bases3);
 new(bases4);

 new(ships1);
 new(ships2);
 new(ships3);
 new(ships4);
 new(ships5);
 new(ships6);
 new(ships7);

 new(msglist);
 initgrafik;
end;

procedure inithost;
begin
 textmode(co80);
 if ioresult<>0 then;
 filemode:=$90;
 textattr:=$7;
{$ifndef unix}
 writeln('Freie Datenspeicher (XMS):',memavail,'/33554432 (32M)'#10);
{$ifdef DPMI}
 if memavail<33554432 then halt;
{$endif}
 asm
  mov ax,$1112
  xor bx,bx
  int $10
 end;
 windmax:=$3149;
{$endif}
 new(msglist);
end;

end.