Team Fortress 2 Source Code as on 22/4/2020
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

105 lines
3.8 KiB

  1. //========= Copyright Valve Corporation, All rights reserved. ============//
  2. //
  3. // Purpose:
  4. //
  5. // $NoKeywords: $
  6. //
  7. //=============================================================================//
  8. // Steam header file includes all definitions for Grid.lib
  9. #ifndef INCLUDED_STEAMLIBAPI_H
  10. #define INCLUDED_STEAMLIBAPI_H
  11. #ifndef _WIN32 // Linux from here for temporary non-Steam server
  12. #include "Steamlib_null.h"
  13. #else // Win32 from here
  14. #if defined(_MSC_VER) && (_MSC_VER > 1000)
  15. #pragma once
  16. #endif
  17. #ifdef __cplusplus
  18. extern "C"
  19. {
  20. #endif
  21. extern int STEAM_Startup(void);
  22. extern int STEAM_Mount(const char *szMountPath);
  23. extern int STEAM_Unmount(void);
  24. extern void STEAM_Shutdown(void);
  25. extern FILE *STEAM_fopen(const char *filename, const char *options);
  26. extern int STEAM_fclose(FILE *file);
  27. extern unsigned int STEAM_fread(void *buffer, unsigned int rdsize, unsigned int count,FILE *file);
  28. extern int STEAM_fgetc(FILE *file);
  29. extern unsigned int STEAM_fwrite(void *buffer, unsigned int rdsize, unsigned int count,FILE *file);
  30. extern int STEAM_fprintf( FILE *fp, const char *format, ... );
  31. extern int STEAM_vfprintf( FILE *fp, const char *format, va_list argptr);
  32. extern int STEAM_fseek(FILE *file, long offset, int method);
  33. extern long STEAM_ftell(FILE *file);
  34. extern int STEAM_stat(const char *path, struct _stat *buf);
  35. extern int STEAM_feof( FILE *stream );
  36. extern int STEAM_ferror( FILE *stream );
  37. extern void STEAM_clearerr( FILE *stream );
  38. extern void STEAM_strerror( FILE *stream, char *p, int maxlen );
  39. extern void STEAM_rewind( FILE *stream );
  40. extern int STEAM_fflush( FILE *stream );
  41. extern int STEAM_flushall( void );
  42. extern unsigned int STEAM_FileSize( FILE *file );
  43. extern void STEAM_setbuf( FILE *stream, char *buffer);
  44. extern int STEAM_setvbuf( FILE *stream, char *buffer, int mode, size_t size);
  45. extern char *STEAM_fgets(char *string, int n, FILE *stream);
  46. extern int STEAM_fputc(int c, FILE *stream);
  47. extern int STEAM_fputs(const char *string, FILE *stream);
  48. extern FILE *STEAM_tmpfile(void);
  49. typedef enum // Filter elements returned by SteamFind{First,Next}
  50. {
  51. STEAMFindLocalOnly, // limit search to local filesystem
  52. STEAMFindRemoteOnly, // limit search to remote repository
  53. STEAMFindAll // do not limit search (duplicates allowed)
  54. } STEAMFindFilter;
  55. extern HANDLE STEAM_FindFirstFile(char *pszMatchName, STEAMFindFilter filter, WIN32_FIND_DATA *findInfo);
  56. extern int STEAM_FindNextFile(HANDLE dir, WIN32_FIND_DATA *findInfo);
  57. extern int STEAM_FindClose(HANDLE dir);
  58. extern long STEAM_findfirst(char *pszMatchName, STEAMFindFilter filter, struct _finddata_t *fileinfo );
  59. extern int STEAM_findnext(long dir, struct _finddata_t *fileinfo );
  60. extern int STEAM_findclose(long dir);
  61. extern HINSTANCE STEAM_LoadLibrary( const char *dllName );
  62. extern void STEAM_GetLocalCopy( const char *fileName );
  63. extern void STEAM_LogLevelLoadStarted( const char *name );
  64. extern void STEAM_LogLevelLoadFinished( const char *name );
  65. extern int STEAM_HintResourceNeed( const char *mapcycle, int forgetEverything );
  66. extern int STEAM_PauseResourcePreloading(void);
  67. extern int STEAM_ForgetAllResourceHints(void);
  68. extern int STEAM_ResumeResourcePreloading(void);
  69. extern int STEAM_BlockForResources( const char *hintlist );
  70. extern void STEAM_UseDaemon(int enable);
  71. extern unsigned int STEAM_FileSize( FILE *file );
  72. extern void STEAM_TrackProgress(int enable);
  73. extern STEAM_RegisterAppProgressCallback( void(*fpProgCallBack)(void), int freq );
  74. extern STEAM_RegisterAppKeepAliveTicCallback( void(*fpKeepAliveTicCallBack)(char* scr_msg) );
  75. extern void STEAM_UpdateProgress( void );
  76. extern int STEAM_ProgressCounter(void);
  77. extern void STEAM_GetInterfaceVersion( char *p, int maxlen );
  78. extern int STEAM_FileIsAvailLocal( const char *file );
  79. #ifdef __cplusplus
  80. }
  81. #endif
  82. #endif // ndef _WIN32
  83. #endif /* #ifndef INCLUDED_STEAMLIBAPI_H */