Hi there, thank you for this resource it should prove extremely useful however I have two questions if some one could please answer: (I am a beginner)
> Firstly when I download the sample files and run launcher.exe it says “usage: launcher filename” could some one just briefly interpret this describing how this application is used exactly. For example I have a game installed in my C:\ named abc.exe what is the command I would enter for the launcher to work and hook?
> Secondly can this method be used to interact with game textures for example changing them or recognising coordinates or does it simply draw directly above the game with no means of interaction?
Thank you.
[C++] Direct3D hooking sample
Quote:Original post by cykino
> Firstly when I download the sample files and run launcher.exe it says “usage: launcher filename” could some one just briefly interpret this describing how this application is used exactly. For example I have a game installed in my C:\ named abc.exe what is the command I would enter for the launcher to work and hook?
launcher abc.exe
Quote:> Secondly can this method be used to interact with game textures for example changing them or recognising coordinates or does it simply draw directly above the game with no means of interaction?
You can do anything. I only demonstrated modifying the behavior of Present to draw a colored quad.
Ive tried to test this and I cannot seem to get it to work. I have no problems with the compilation. But when I launch Egyptian_Addiction.exe and then run Launcher.exe "Egyptian_Addiction.exe" nothing happens. Am I doing something in the wrong order?
EDIT: I read the OP just a little bit more and saw what I needed to do. It is working now.
Thanks,
Soul
[Edited by - DaSoul on January 21, 2006 11:34:37 AM]
EDIT: I read the OP just a little bit more and saw what I needed to do. It is working now.
Thanks,
Soul
[Edited by - DaSoul on January 21, 2006 11:34:37 AM]
Quote:Original post by Pipo DeClownThe staff are aware of this and it should be sorted out fairly soon I hope. NeXe (or the other hosted sites) are not gone forever [smile]
The sample file is gone, NeXe is destroyed?! Doh!
Jack
Is there a way to just hook the specific function EndScene() in the vtable instead of creating a wrapper class?
ie, couldn't you do something like:
It just seems like creating a whole class for one little function is a lot of extra code.
ie, couldn't you do something like:
__stdcall HRESULT MyEndScene(void * this) { IDirect3DDevice9 * device = (IDirect3DDevice9 *)this; // do some rendering calls return device->EndScene();}
It just seems like creating a whole class for one little function is a lot of extra code.
Quote:Original post by ApolloEx
Is there a way to just hook the specific function EndScene() in the vtable instead of creating a wrapper class?
ie, couldn't you do something like:__stdcall HRESULT MyEndScene(void * this) { IDirect3DDevice9 * device = (IDirect3DDevice9 *)this; // do some rendering calls return device->EndScene();}
It just seems like creating a whole class for one little function is a lot of extra code.
Assuming you inserted a pointer to that function into the vtable, that would result in infinite recursion. Think about what device->EndScene(); is doing.
Quote:Original post by WashuQuote:Original post by ApolloEx
Is there a way to just hook the specific function EndScene() in the vtable instead of creating a wrapper class?
ie, couldn't you do something like:__stdcall HRESULT MyEndScene(void * this) { IDirect3DDevice9 * device = (IDirect3DDevice9 *)this; // do some rendering calls return device->EndScene();}
It just seems like creating a whole class for one little function is a lot of extra code.
Assuming you inserted a pointer to that function into the vtable, that would result in infinite recursion. Think about what device->EndScene(); is doing.
Whoops. Should have called a function pointer to the old address.
Assuming you know the layout of the vtable though (which you do since it's based on COM) then yes, you could change the implementation such that you didn't need to implement that interface. On the other hand, typically if you are going to hijack one function, you'll probably need to hijack others.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement