diff options
| author | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
|---|---|---|
| committer | FluorescentCIAAfricanAmerican <[email protected]> | 2020-04-22 12:56:21 -0400 |
| commit | 3bf9df6b2785fa6d951086978a3e66f49427166a (patch) | |
| tree | 2c0f1f0c63c4832882bc93814ebd2c2b1c6224e5 /common/ihfx/util | |
| download | archived-source-engine-2018-hl2-src-master.tar.xz archived-source-engine-2018-hl2-src-master.zip | |
Diffstat (limited to 'common/ihfx/util')
| -rw-r--r-- | common/ihfx/util/hfxinterfacehelper.h | 54 |
1 files changed, 54 insertions, 0 deletions
diff --git a/common/ihfx/util/hfxinterfacehelper.h b/common/ihfx/util/hfxinterfacehelper.h new file mode 100644 index 0000000..354749e --- /dev/null +++ b/common/ihfx/util/hfxinterfacehelper.h @@ -0,0 +1,54 @@ + +typedef int (*NovintHFX_ExposeInterfaceFn)(void **ppInterface, void *hwnd, const char *cmd, unsigned int versionMaj, unsigned int versionMin, void *pMouseEnableFN, unsigned int TargetDevices); +inline const char *HFX_GetVersionMajorString(){ + return HFX_VERSION_MAJOR_SZ; +} +inline const char *HFX_GetVersionMinorString(){ + return HFX_VERSION_MINOR_SZ; +} +inline const char *HFX_CONNECT_FUNCTION_NAME(){ + return "_export_ExposeInterfaceHFX_" HFX_VERSION_MAJOR_SZ "_" HFX_VERSION_MINOR_SZ "_"; +} +inline const char *HFX_CONNECT_FUNCTION_NAME_XML(){ + return "_export_ExposeInterfaceHFX_XML_" HFX_VERSION_MAJOR_SZ "_" HFX_VERSION_MINOR_SZ "_"; +} +inline const char *HFX_DYNAMIC_LIBRARY_NAME(const unsigned int tries = 0){ + switch(tries) + { + default: + return 0; + break; + +#ifdef HFX_DLL_CUSTOM_NAME + case 0: + return HFX_DLL_CUSTOM_NAME; + break; +#endif + +#ifndef HFX_DLL_CUSTOM_NAME + case 0: +#else + case 1: +#endif + return "NovintHFX_" HFX_VERSION_MAJOR_SZ "." HFX_VERSION_MINOR_SZ ".dll"; + break; + +#ifndef HFX_DLL_CUSTOM_NAME + case 1: +#else + case 2: +#endif + return "NovintHFX.dll"; + break; + + }; +} +inline unsigned int HFX_GetVersionMajor(){ + return HFX_VERSION_MAJOR; +} +inline unsigned int HFX_GetVersionMinor(){ + return HFX_VERSION_MINOR; +} +inline double HFX_GetVersion(){ + return HFX_VERSION_FLOAT; +}
\ No newline at end of file |