home *** CD-ROM | disk | FTP | other *** search
/ WarCraft 2000 - Nuclear Epidemic / W2000.nrg / SOURCE.War2000 / RESFILE.H < prev    next >
Text File  |  1998-01-12  |  800b  |  24 lines

  1. /*             Work with the resource files
  2.  *   
  3.  *  You must use this module for  accesss to files.This 
  4.  * routine allows you to read  files from disk  or from 
  5.  * the resource file, you even will not recognise where
  6.  * the given file is.
  7.  */
  8. typedef HANDLE ResFile;
  9. //Opening the resource file
  10. ResFile RReset(LPCSTR lpFileName);
  11. //Rewriting file
  12. ResFile RRewrite(LPCSTR lpFileName);
  13. //Getting size of the resource file
  14. DWORD RFileSize(HANDLE hFile);
  15. // Setting file position 
  16. DWORD RSeek(ResFile hFile,int pos);
  17. //Reading the file
  18. DWORD RBlockRead(ResFile hFile,LPVOID lpBuffer,DWORD BytesToRead);
  19. //Writing the file
  20. DWORD RBlockWrite(ResFile hFile,LPVOID lpBuffer,DWORD BytesToWrite);
  21. //Returns last error
  22. DWORD IOresult(void);
  23. //Close the file
  24. void RClose(ResFile hFile);