fump
June 13th, 2009, 17:03
As the title says I'm trying out some code injection. My goal is to replace a function in a game so that I can play it in different ways.
I'm not honestly sure if this is the right place to post this sort of thing, but any help in finding where I could get aid would be appreciated.
The type of injection that is being used is with SetWindowsHookEx the target method to be replace is Direct3DCreate9. The problem seems to be that the application is not loading D3D9.dll itself but is loading a dll called SFMiddleWare and that dll is what loads D3D9.
Currently I'm overwriting LoadLibraryA with my own so that I can catch when SFMiddleWare is loaded and immediately after its done I try to replace Direct3DCreate9.
Some things that are being assumed is:
D3D9.dll will be in the IAT after SFMiddleWare.dll is done being loaded
And that LoadLibrary will not spawn any threads so that I could do something like
myLoadLib( fileName)
hresult r = LoadLibrary(fileName);
myHook(-HookStructForD3D-);
return r;
Thanks in advance
I'm not honestly sure if this is the right place to post this sort of thing, but any help in finding where I could get aid would be appreciated.
The type of injection that is being used is with SetWindowsHookEx the target method to be replace is Direct3DCreate9. The problem seems to be that the application is not loading D3D9.dll itself but is loading a dll called SFMiddleWare and that dll is what loads D3D9.
Currently I'm overwriting LoadLibraryA with my own so that I can catch when SFMiddleWare is loaded and immediately after its done I try to replace Direct3DCreate9.
Some things that are being assumed is:
D3D9.dll will be in the IAT after SFMiddleWare.dll is done being loaded
And that LoadLibrary will not spawn any threads so that I could do something like
myLoadLib( fileName)
hresult r = LoadLibrary(fileName);
myHook(-HookStructForD3D-);
return r;
Thanks in advance