home *** CD-ROM | disk | FTP | other *** search
/ PC Underground / UNDERGROUND.ISO / graphic / fade_txt.pas < prev    next >
Pascal/Delphi Source File  |  1995-08-03  |  1KB  |  36 lines

  1. Uses Crt,Gif,ModeXLib,Fade;
  2. Var
  3.   Text_Pal:Array[0..767] of Byte;
  4.   i:word;
  5.  
  6. Begin
  7.   Init_Mode13;                  {use Mode 13h}
  8.   Screen_Off;                   {screen off during loading}
  9.   LoadGif('vflog210');          {load static part}
  10.   Move(Palette[210*3],          {its palette part (colors 210..255)}
  11.   Text_Pal[210*3],46*3);        {enter}
  12.   Show_Pic13;                   {copy static picture to VGA}
  13.  
  14.   LoadGif('texts');             {load picture with texts}
  15.   Move(Palette,Text_Pal,14*3);  {its palette part (colors 0..13)}
  16.                                 {enter}
  17.   Move(Text_Pal,Palette,768);   {set finished palette}
  18.   SetPal;
  19.  
  20.   Move(vscreen^,                {first text can be copied}
  21.     Ptr($a000,160*320)^,19*320);{directly to screen}
  22.   Screen_On;                    {picture now finished -> switch on}
  23.   Colors:=14;                   {pictures with 14 colors in this program !}
  24.  
  25.   For i:=1 to 6 do Begin        {fade to the next 6 texts, one after the other}
  26.     Delay(500);                 {time to read}
  27.     Fade1(vscreen,              {fade next picture to old location (y=160)}
  28.       text_pal,i*20,160,19);
  29.     Fade_ResetPic(160,19);      {and "reset"}
  30.     If KeyPressed Then Exit;    {anyone who has had enough can cancel here}
  31.   End;
  32.  
  33.   Readln;
  34.   TextMode(3);
  35. End.
  36.