//-------------------------------------
if (FrameCounter == 160)            // Time for the Cadillac 1 to appear ?
{
   short meux[5] = {-8,-63,74,-86,20};
   short meuy[5] = {-13,25,25,-10,-7};
   char  meudepth[5] = {10,13,13,13,11};
   char  meuaction[5] = {1,2,2,2,6};
   short meuscale[5] = {7200,6700,6700,6400,4096};
   char  meuchar[5] = {12,13,14,41,19};

   Chars[11]->Set_Location (550,180);
   Chars[11]->SetDepth (12);
   Chars[11]->StartAction (0, 0);
   Chars[11]->Scale (6400);
   for (i = 0; i < 5; i++)
   {
      Chars[meuchar[i]]->Set_Location (550 + meux[i],180 + meuy[i]);
      AddAttach (Chars[meuchar[i]], Chars[11], meux[i], meuy[i]);
      Chars[meuchar[i]]->SetDepth (meudepth[i]);
      Chars[meuchar[i]]->StartAction (meuaction[i], 0);
      Chars[meuchar[i]]->Scale (meuscale[i]);
   }

   Chars[45]->Set_Location (550 - 86,180 - 8);  // Fire sprite
   AddAttach (Chars[45], Chars[11], -86, -8);
   Chars[45]->SetDepth (13);
}
//-------------------------------------
else if (FrameCounter == 600)       // Time for the transam to appear ?
{
   short meux[6] = {-10,-68,68,-82,-82,-12};
   short meuy[6] = {-16,19,19,-10,-10,-18};
   char  meudepth[6] = {1,4,4,4,4,2};
   char  meuaction[6] = {1,2,2,1,1,4};
   short meuscale[6] = {6500,5300,5300,5000,5000,4096};
   char  meuchar[6] = {30,31,32,39,40,37};

   Chars[29]->Set_Location (-150,70);
   Chars[29]->SetDepth (3);
   Chars[29]->StartAction (0, 0);
   Chars[29]->Scale (5300);
   for (i = 0; i < 6; i++)
   {
      Chars[meuchar[i]]->Set_Location (-150 + meux[i],70 + meuy[i]);
      AddAttach (Chars[meuchar[i]], Chars[29], meux[i], meuy[i]);
      Chars[meuchar[i]]->SetDepth (meudepth[i]);
      Chars[meuchar[i]]->StartAction (meuaction[i], 0);
      Chars[meuchar[i]]->Scale (meuscale[i]);
   }

   Chars[44]->Set_Location (-150 - 82,120 - 5);   // Fire sprite
   AddAttach (Chars[44], Chars[29], -82, -5);
   Chars[44]->SetDepth (4);
   Chars[48]->Set_Location (-150 - 82,120 - 15);  // Explosion1 sprite
   AddAttach (Chars[48], Chars[29], -82, -15);
   Chars[48]->SetDepth (4);
   Chars[49]->Set_Location (-150 - 82,120 - 15);  // Explosion2 sprite
   AddAttach (Chars[49], Chars[29], -82, -15);
   Chars[49]->SetDepth (4);
}
//-------------------------------------
if (CarChaseTimerFar == 1)              // Time for the 18-wheels truck to
{                                       //  appear ?
   Chars[50]->Set_Location (560,145);
   Chars[50]->SetDepth (2);
   Chars[50]->StartAction (0, 0);
   CarChaseTimerFar = 2;
}
else if ((CarChaseTimerFar == 2) && (!GamePause))  // Move truck...
{
   int truckpiece[10] = {290,227,164,101, 38,-25,-88,-151,-214,-277};
   short offsx[10] =    { 62,125,188,251,314,377,440, 503, 566, 621};
   point pru = Chars[50]->Coordinate ();

   if ((pru.y > 70) && (pru.x < 350) && ((FrameCounter & 3) == 0))
   {
      Chars[50]->Move (-1, -1);
      pru.y--;
   }
   else
      Chars[50]->Move (-1, 0);

   if (pru.x == -740)
   {
      Chars[50]->StopAction ();
      CarChaseTimerFar = 3;
   }

   for (i = 0; i < 10; i++)
   {
      if (truckpiece[i] == pru.x)
      {
         Chars[51 + i]->Set_Location (pru.x + offsx[i],pru.y);
         AddAttach (Chars[51 + i], Chars[50], offsx[i],0);
         Chars[51 + i]->SetDepth (2);
         Chars[51 + i]->StartAction (i + 1, 0);
      }
   }
}
//-------------------------------------
if (CarChaseTimerNear == 2)         // Time for the white car to appear ?
{                                      
   short meux[7] =      { -25,  15, -25, -58,  77, -80,  14};
   short meuy[7] =      {   0, -12,   1,  23,  23,  -5, -10};
   char  meudepth[7] =  {  10,  10,  13,  13,  13,  13,  11};
   char  meuaction[7] = {   1,   8,   2,   6,   6,   0,   6};
   short meuscale[7] =  {6640,6400,6780,6400,6400,6000,4096};
   char  meuchar[7] =   {   1,   2,   3,   4,   5,  38,  10};

   Chars[0]->Set_Location (550,180);
   Chars[0]->SetDepth (12);
   Chars[0]->StartAction (0, 0);
   Chars[0]->Scale (6400);
   for (i = 0; i < 7; i++)
   {
      Chars[meuchar[i]]->Set_Location (550 + meux[i],180 + meuy[i]);
      AddAttach (Chars[meuchar[i]], Chars[0], meux[i], meuy[i]);
      Chars[meuchar[i]]->SetDepth (meudepth[i]);
      Chars[meuchar[i]]->StartAction (meuaction[i], 0);
      Chars[meuchar[i]]->Scale (meuscale[i]);
   }

   Chars[43]->Set_Location (550 - 80,180 - 5);   // Fire sprite
   AddAttach (Chars[43], Chars[0], -80, -5);
   Chars[43]->SetDepth (13);

   CarChaseTimerNear++;
}
//-------------------------------------
else if (CarChaseTimerNear == 4)    // Time for the Cadillac 2 to appear ?
{
   short meux[5] = {-8,-63,74,-86,20};
   short meuy[5] = {-13,25,25,-10,-7};
   char  meudepth[5] = {10,13,13,13,11};
   char  meuaction[5] = {1,2,2,2,6};
   short meuscale[5] = {7200,6700,6700,6400,4096};
   char  meuchar[5] = {21,22,23,42,28};

   Chars[20]->Set_Location (550,180);
   Chars[20]->SetDepth (12);
   Chars[20]->StartAction (0, 0);
   Chars[20]->Scale (6400);
   for (i = 0; i < 5; i++)
   {
      Chars[meuchar[i]]->Set_Location (550 + meux[i],180 + meuy[i]);
      AddAttach (Chars[meuchar[i]], Chars[20], meux[i], meuy[i]);
      Chars[meuchar[i]]->SetDepth (meudepth[i]);
      Chars[meuchar[i]]->StartAction (meuaction[i], 0);
      Chars[meuchar[i]]->Scale (meuscale[i]);
   }

   Chars[46]->Set_Location (550 - 86,180 - 8);  // Fire sprite
   AddAttach (Chars[46], Chars[20], -86, -8);
   Chars[46]->SetDepth (13);

   CarChaseTimerNear++;
}

//-------------------------------------
int fruz;
if (CarKilled[0] < 4)
   fruz = 4;
else
   fruz = 5;
for (i = 0; i < fruz; i++)              // Cadillac 1's guy appearances
{
   u_short timeappear[5] =  {120,240,360,480,600};
   signed char xappear[5] = {-25, 18,-20,-20, 20};
   signed char yappear[5] = {-23,-10,-15,-10,-10};
   char actionappear[5] =   {  3,  0,  0,  0,  0};
   char charappear[5] =     { 16, 17, 15, 18, 19};

   if (CarTimer[0] == timeappear[i])
   {
      point pop = Chars[11]->Coordinate ();
      int zzzz = charappear[i];
      Chars[zzzz]->Set_Location (pop.x + xappear[i], pop.y - yappear[i]);
      AddAttach (Chars[zzzz], Chars[11], xappear[i], yappear[i]);
      Chars[zzzz]->SetDepth (11);
      Chars[zzzz]->StartAction (actionappear[i], 0);
   }
}

//-------------------------------------
if (CarKilled[1] < 4)
   fruz = 4;
else
   fruz = 5;
for (i = 0; i < fruz; i++)              // TransAM's guy appearances
{
   u_short timeappear[5] =  {120,240,360,480,600};
   signed char xappear[5] = { -5,-15, -5,-15, -5};
   signed char yappear[5] = {-15,-20,-20,-23,-10};
   char actionappear[5] =   {  0,  0,  0,  3,  0};
   char charappear[5] =     { 35, 33, 34, 36, 37};

   if (CarTimer[1] == timeappear[i])
   {
      point pop = Chars[29]->Coordinate ();
      int zzzz = charappear[i];
      Chars[zzzz]->Set_Location (pop.x + xappear[i], pop.y - yappear[i]);
      AddAttach (Chars[zzzz], Chars[29], xappear[i], yappear[i]);
      Chars[zzzz]->SetDepth (3);
      Chars[zzzz]->Scale (3250);
      Chars[zzzz]->StartAction (actionappear[i], 0);
   }
}

//-------------------------------------
if (CarKilled[2] < 4)
   fruz = 4;
else
   fruz = 5;
for (i = 0; i < fruz; i++)              // White car's guy appearances
{
   u_short timeappear[5] =  {120,240,360,480,600};
   signed char xappear[5] = {-20, 20,-20,-20, 20};
   signed char yappear[5] = {-14,-14,-14,-25,-14};
   char actionappear[5] = {0,0,0,3,0};
   char charappear[5] = {6,7,8,9,10};

   if (CarTimer[2] == timeappear[i])
   {
      point pop = Chars[0]->Coordinate ();
      int zzzz = charappear[i];
      Chars[zzzz]->Set_Location (pop.x + xappear[i], pop.y - yappear[i]);
      AddAttach (Chars[zzzz], Chars[0], xappear[i], yappear[i]);
      Chars[zzzz]->SetDepth (11);
      Chars[zzzz]->StartAction (actionappear[i], 0);
   }
}

//-------------------------------------
if (CarKilled[3] < 4)
   fruz = 4;
else
   fruz = 5;
for (i = 0; i < fruz; i++)              // Cadillac 2's guy appearances
{
   u_short timeappear[5] =  {120,240,360,480,600};
   signed char xappear[5] = {-25,-20, 18,-20, 18};
   signed char yappear[5] = {-23,-10,-10,-15,-10};
   char actionappear[5] =   {  3,  0,  0,  0,  0};
   char charappear[5] =     { 25, 26, 27, 24, 28};

   if (CarTimer[3] == timeappear[i])
   {
      point pop = Chars[20]->Coordinate ();
      int zzzz = charappear[i];
      Chars[zzzz]->Set_Location (pop.x + xappear[i], pop.y - yappear[i]);
      AddAttach (Chars[zzzz], Chars[20], xappear[i], yappear[i]);
      Chars[zzzz]->SetDepth (11);
      Chars[zzzz]->StartAction (actionappear[i], 0);
   }
}

//---------------------------------------------------------------------------
if (CarChaseTimerNear == 6)         // Time for the helicopter to appear ?
{
   short meux[11] =      {-126, 44,165,92,88,88, 74, -25,175, 0};
   short meuy[11] =      { -47,-52,  4,48,-2,-2,-81,-105,-84, 0};
   char  meudepth[11] =  {   5,  5,  5, 5, 3, 6,  5,   5,  6, 6};
   char  meuaction[11] = {   0,  1,  2, 4, 5, 6,  8,   9, 10, 3};

   Chars[61]->Set_Location (100,200);
   Chars[61]->SetDepth (5);
   Chars[61]->StartAction (3, 0);
   Chars[61]->MakeBlinkable ();
   for (i = 0; i < 10; i++)
   {
      Chars[i + 62]->Set_Location (100 + meux[i],200 + meuy[i]);
      AddAttach (Chars[i + 62], Chars[61], meux[i], meuy[i]);
      Chars[i + 62]->SetDepth (meudepth[i]);
      Chars[i + 62]->StartAction (meuaction[i], 0);
      Chars[i + 62]->MakeBlinkable ();
   }

   Chars[83]->Set_Location (100 + 88,200 - 2);
   AddAttach (Chars[83], Chars[61], 88, -2);
   Chars[83]->SetDepth (5);
   Chars[83]->StartAction (0, 0);

   Chars[72]->Set_Location (100 + 44,200 - 52); // Patch sprite
   AddAttach (Chars[72], Chars[61], 44, -52);
   Chars[72]->SetDepth (6);
   Chars[73]->Set_Location (100 + 32,200 - 7);  // Patch sprite
   AddAttach (Chars[73], Chars[61], 32, -7);
   Chars[73]->SetDepth (6);
   Chars[74]->Set_Location (100 + 92,200 - 52); // Patch sprite
   AddAttach (Chars[74], Chars[61], 92, -52);
   Chars[74]->SetDepth (6);
   Chars[75]->Set_Location (100 - 19,200);      // Patch sprite
   AddAttach (Chars[75], Chars[61], -19, 0);
   Chars[75]->SetDepth (6);

   Chars[76]->Set_Location (100 - 33,200);      // Fire sprite
   AddAttach (Chars[76], Chars[61], -33, 0);
   Chars[76]->SetDepth (6);
   Chars[77]->Set_Location (100 + 17,200 - 52); // Fire sprite
   AddAttach (Chars[77], Chars[61], 17, -52);
   Chars[77]->SetDepth (6);
   Chars[78]->Set_Location (100 + 23,200 + 12); // Fire sprite
   AddAttach (Chars[78], Chars[61], 23, 12);
   Chars[78]->SetDepth (6);
   Chars[79]->Set_Location (100 + 87,200 - 48); // Fire sprite
   AddAttach (Chars[79], Chars[61], 87, -48);
   Chars[79]->SetDepth (6);
   Chars[80]->Set_Location (100 - 20,200 - 18); // Fire sprite
   AddAttach (Chars[80], Chars[61], -20, -18);
   Chars[80]->SetDepth (6);
   Chars[81]->Set_Location (100 + 30,200);      // Fire sprite
   AddAttach (Chars[81], Chars[61], 30, 0);
   Chars[81]->SetDepth (6);

   CarChaseTimerNear = 7;
}

if (CarChaseTimerNear == 9)      // Time for the boss to start shooting ?
{
   Chars[83]->StartAction (1, 0);
   CarChaseTimerNear++;
}

if (CarKilled[5] == 5)
{
   Chars[83]->StartAction (0, 0);
   CarKilled[5] = 6;
   EndRound = 1;
   bkgnd[0].BuildDestClut (0);
   for (i = 0; i < NbrChars; i++)
      Chars[i]->BuildDestClut (0);
}
