mirror of
https://github.com/gwdevhub/gMod.git
synced 2026-07-22 18:39:31 +00:00
Separated DirectX content from:
1) dll entry functions 2) Server (inside the dll) 3) Server-Client interface. uMod now detects if a DirectX device was created and is under "control" of uMod (a counter is shown after the game name). Thus if the injection did not work properly, uMod wont show a DX9 or DX9EX count.
This commit is contained in:
@@ -18,7 +18,8 @@ along with Universal Modding Engine. If not, see <http://www.gnu.org/licenses/>
|
||||
|
||||
|
||||
|
||||
#include "uMod_Main.h"
|
||||
#include "..\uMod_DXMain\uMod_Main.h"
|
||||
#include "uMod_IDirect3DDevice9.h"
|
||||
|
||||
#ifndef RETURN_QueryInterface
|
||||
#define RETURN_QueryInterface 0x01000000L
|
||||
@@ -28,6 +29,10 @@ along with Universal Modding Engine. If not, see <http://www.gnu.org/licenses/>
|
||||
#define PRE_MESSAGE "uMod_IDirect3DDevice9"
|
||||
#endif
|
||||
|
||||
#ifndef DEF_DX_VERSION
|
||||
#define DEF_DX_VERSION VERSION_DX9
|
||||
#endif
|
||||
|
||||
|
||||
int uMod_IDirect3DDevice9::CreateSingleTexture(void)
|
||||
{
|
||||
@@ -136,7 +141,8 @@ uMod_IDirect3DDevice9::uMod_IDirect3DDevice9( IDirect3DDevice9* pOriginal, uMod_
|
||||
NormalRendering = true;
|
||||
|
||||
uMod_Server = server;
|
||||
uMod_Client = new uMod_TextureClient( uMod_Server, this); //get a new texture client for this device
|
||||
uMod_Client = new uMod_TextureClient_DX9( this, DEF_DX_VERSION); //get a new texture client for this device
|
||||
uMod_Client->ConnectToServer( uMod_Server);
|
||||
|
||||
LastCreatedTexture = NULL;
|
||||
LastCreatedVolumeTexture = NULL;
|
||||
|
||||
Reference in New Issue
Block a user