home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-385-Vol-1of3.iso / w / wgt3_ex.zip / WGT31.C < prev    next >
C/C++ Source or Header  |  1992-09-22  |  442b  |  24 lines

  1. #include <wgt.h>
  2. #include <conio.h>
  3.  
  4. // WordUp Graphics Toolkit Demo program 31
  5. // Shows how to use WGT library files.
  6.  
  7. int i;
  8. block sprites[201];
  9. color pal[256];
  10.  
  11. void main(void)
  12. {
  13. vga256();
  14. setlib("demo31.wlb");
  15. setpassword("WGT");
  16. wloadsprites(&pal,"Demo31.spr",sprites);
  17. // Loads a sprite file from within demo31.wlb
  18. wcls(0);
  19. do {
  20. wputblock(rand()%300,rand()%180,sprites[1],0);
  21. } while (!kbhit());
  22. textmode(C80);
  23. }
  24.