Results 1 to 9 of 9

Hybrid View

  1. #1
    why06's Avatar
    Join Date
    Jul 2009
    Gender
    male
    Location
    IBM
    Posts
    4,304
    Reputation
    170
    Thanks
    2,204
    My Mood
    Flirty
    Try running it in VS debugger, and find the point where it freezes. Seems like its local.

    "Every gun that is made, every warship launched, every rocket fired signifies, in the final sense, a theft from those who hunger and are not fed, those who are cold and are not clothed. This world in arms is not spending money alone. It is spending the sweat of its laborers, the genius of its scientists, the hopes of its children. The cost of one modern heavy bomber is this: a modern brick school in more than 30 cities. It is two electric power plants, each serving a town of 60,000 population. It is two fine, fully equipped hospitals. It is some fifty miles of concrete pavement. We pay for a single fighter plane with a half million bushels of wheat. We pay for a single destroyer with new homes that could have housed more than 8,000 people. This is, I repeat, the best way of life to be found on the road the world has been taking. This is not a way of life at all, in any true sense. Under the cloud of threatening war, it is humanity hanging from a cross of iron."
    - Dwight D. Eisenhower

  2. #2
    MerkurAlex's Avatar
    Join Date
    Mar 2009
    Gender
    male
    Posts
    4
    Reputation
    10
    Thanks
    0
    Quote Originally Posted by why06 View Post
    Try running it in VS debugger, and find the point where it freezes. Seems like its local.
    Are you suggesting I run my dll(that I normally inject into the game) in VS debugger?

    Im probably missing something please explain.

  3. #3
    why06's Avatar
    Join Date
    Jul 2009
    Gender
    male
    Location
    IBM
    Posts
    4,304
    Reputation
    170
    Thanks
    2,204
    My Mood
    Flirty
    Quote Originally Posted by MerkurAlex View Post
    Are you suggesting I run my dll(that I normally inject into the game) in VS debugger?

    Im probably missing something please explain.
    I was under the impression that this was a game you were making. In that case, idk, it really depends exactly what the code does. Something about what ur .dll does is causing adverse effects in the game. Just make sure you don't have any loose ends. =/

    It could be a combination of your .dll and the game causing the loop.

    "Every gun that is made, every warship launched, every rocket fired signifies, in the final sense, a theft from those who hunger and are not fed, those who are cold and are not clothed. This world in arms is not spending money alone. It is spending the sweat of its laborers, the genius of its scientists, the hopes of its children. The cost of one modern heavy bomber is this: a modern brick school in more than 30 cities. It is two electric power plants, each serving a town of 60,000 population. It is two fine, fully equipped hospitals. It is some fifty miles of concrete pavement. We pay for a single fighter plane with a half million bushels of wheat. We pay for a single destroyer with new homes that could have housed more than 8,000 people. This is, I repeat, the best way of life to be found on the road the world has been taking. This is not a way of life at all, in any true sense. Under the cloud of threatening war, it is humanity hanging from a cross of iron."
    - Dwight D. Eisenhower

  4. #4
    MerkurAlex's Avatar
    Join Date
    Mar 2009
    Gender
    male
    Posts
    4
    Reputation
    10
    Thanks
    0
    With my current code (see below) the hook(detour) works the first time(just like before) and then the process seems to continue but if I try to close the process it stops responding.

    I ran the program with IDA pro injected the dll and then went through the steps to make that hook run when it did IDA said it caused an unknown exception.

    Current code(basically the same thing but for a different address point):
    Code:
    #include <windows.h>
    #include "detours.h"
    #include <iostream>
    #include <fstream>
    using namespace std;
    
    int (__stdcall* DemoBugFixPoint)(void);
    int __stdcall DemoBugFixPoint(void)
    {
    	ofstream myfile;
    	  myfile.open ("legends.log");
    	  myfile << "SetRights(demo bug fix) applied to new logon.\n";
    	  myfile.close();
    
    	  return DemoBugFixPointHook();
    }
    
    BOOL APIENTRY DllMain(HANDLE hModule, DWORD ul_reason_for_call, LPVOID lpReserved)
    {
    switch (ul_reason_for_call)
    {
    	case DLL_PROCESS_ATTACH:
    		DemoBugFixPointHook = (int (__stdcall*)(void))DetourFunction((PBYTE)0x004B8ABF, (PBYTE)DemoBugFixPoint);
    		break;
    	case DLL_THREAD_ATTACH:
    		break;
    	case DLL_THREAD_DETACH:
    		break;
    	case DLL_PROCESS_DETACH:
    		DetourRemove((PBYTE)0x004B8ABF, (PBYTE)DemoBugFixPointHook); //Remove hook
    		break;
    }
    return TRUE;
    }
    btw the assembly of "0x004B8ABF" is just NOP im not sure if that is an issue if it is can someone explain an easier way to run my function when the program reaches that address point?

Similar Threads

  1. Favorite Quote
    By EleMentX in forum Spammers Corner
    Replies: 13
    Last Post: 01-04-2020, 04:36 PM
  2. MPGH PM Chat Quote Thread
    By arunforce in forum Entertainment
    Replies: 39
    Last Post: 05-12-2013, 08:24 PM
  3. MPGH AIM Chat Quote Thread
    By ace76543 in forum Entertainment
    Replies: 30
    Last Post: 09-25-2011, 12:14 PM
  4. MPGH IRC Chat Quote Thread
    By i eat trees in forum Entertainment
    Replies: 746
    Last Post: 07-02-2011, 10:07 PM
  5. Quotes & Lists
    By radnomguywfq3 in forum General
    Replies: 15
    Last Post: 01-17-2008, 05:14 PM