home *** CD-ROM | disk | FTP | other *** search
/ Revista CD Expert 51 / PCGamer51_17Demos.iso / games / colobotdemo / colobotdemo10e.exe / script / tlaby2.txt < prev    next >
Text File  |  2001-06-10  |  419b  |  29 lines

  1. extern void object::Solution( )
  2. {
  3.     while ( true )
  4.     {
  5.         object    front, left, right;
  6.  
  7.         front = radar(Barrier,   0, 45, 0, 5);
  8.         left  = radar(Barrier,  90, 45, 0, 5);
  9.         right = radar(Barrier, -90, 45, 0, 5);
  10.  
  11.         if ( front == null )
  12.         {
  13.             move(5);
  14.             continue;
  15.         }
  16.         if ( left == null )
  17.         {
  18.             turn(90);
  19.             continue;
  20.         }
  21.         if ( right == null )
  22.         {
  23.             turn(-90);
  24.             continue;
  25.         }
  26.         break;
  27.     }
  28. }
  29.