home *** CD-ROM | disk | FTP | other *** search
/ Virtual Reality Madness / VRMAD96_ONE.ISO / virtek / libex / libex055.c < prev    next >
C/C++ Source or Header  |  1995-08-24  |  404b  |  21 lines

  1.             // Example: 055 from Library Reference
  2. #include "..\3D-Ware\dddware.h"
  3. #include  <stdio.h>
  4. long    seed;
  5. short  main(void)
  6. {
  7.   dddInitKeybd();
  8.   while  (dddkeycode!=_ESC)
  9.   {
  10.     dddRnd();
  11.     if  (dddkeypressed[_SPACE])
  12.     {
  13.       dddSetRnd(10000);
  14.     }
  15.     seed = dddGetRnd();
  16.     printf("The random seed is %d\n",seed);
  17.   }
  18.   dddRestoreKeybd();
  19.   return 0; // Bye.
  20. }
  21.