Need to hook WoW exit/quit menu

User Tag List

Results 1 to 4 of 4
  1. #1
    alex_v's Avatar Member
    Reputation
    1
    Join Date
    Aug 2015
    Posts
    10
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Need to hook WoW exit/quit

    Wow.exe was started, dll is injected and there is a thread running("in dll"). If I quit wow(press quit, exit or X), there is "Unknow exception" popup. If I stop my thread before quitting wow client, there is no error popups. I think I need to hook wow quit to stop my thread and exit without errors. I have tried to hook _atexit, but WoW calls this function many times, not only on quit.
    So, question is: how do I hook player closing wow client?
    Last edited by alex_v; 08-23-2015 at 08:54 PM.

    Need to hook WoW exit/quit
  2. #2
    tobmaps's Avatar Active Member
    Reputation
    43
    Join Date
    Apr 2013
    Posts
    28
    Thanks G/R
    1/11
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by alex_v View Post
    So, question is: how do I hook player closing wow client?
    If your way is "debug" then you can simple
    Code:
            void EnterDebugLoop()
            {
                if (DebugActiveProcess(dwProcessId))
                {
                    DebugSetProcessKillOnExit(0);
                    while (true)
                    {
                        if (!WaitForDebugEvent(&DebugEvent, 500))
                                continue;
                        dwContinueStatus = DBG_CONTINUE;
                        if (DebugEvent.dwDebugEventCode == EXIT_PROCESS_DEBUG_EVENT || DebugEvent.dwDebugEventCode == RIP_EVENT)
                        {
                            GameExit = true;
                            RemoveDebug();
                        }
                        ContinueDebugEvent(DebugEvent.dwProcessId, DebugEvent.dwThreadId, dwContinueStatus);
                    }
                }
                else
                    PrintError("Already attached");
            }

  3. #3
    Jadd's Avatar 🐸 Premium Seller
    Reputation
    1511
    Join Date
    May 2008
    Posts
    2,432
    Thanks G/R
    81/333
    Trade Feedback
    1 (100%)
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by tobmaps View Post
    If your way is "debug" then you can simple
    <snip>
    Sorry, this is really ugly. Just hook WndProc and process the WM_CLOSE event. You can remove your hooks and whatever else there.

  4. #4
    alex_v's Avatar Member
    Reputation
    1
    Join Date
    Aug 2015
    Posts
    10
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Originally Posted by tobmaps View Post
    If your way is "debug"
    CreateRemoteThread, LoadLibrary, need to kill my threads before game exit. One of exceptions was "your thread is running, but DLL is unloaded".
    Originally Posted by Jadd View Post
    WndProc
    I will try to hook WM_CLOSE later, thanks

    I ll share my findings: there are two Lua functions: "Quit" - Esc, Exit game (ingame) and "AccountLogin_Exit" - exit button on account login screen. Replace them and job is done(+WM_CLOSE)
    Last edited by alex_v; 08-24-2015 at 02:48 PM.

Similar Threads

  1. Need help with WoW!
    By thomas1994 in forum World of Warcraft General
    Replies: 37
    Last Post: 11-06-2007, 04:02 PM
  2. Need Help....Hooking Signals
    By shindaustin in forum World of Warcraft Emulator Servers
    Replies: 19
    Last Post: 09-03-2007, 04:44 PM
  3. Account scam (need you own wow private server)
    By oobER POOOOONAGE in forum WoW Scam Prevention
    Replies: 12
    Last Post: 08-21-2007, 02:45 AM
  4. need help with WoW Model View
    By Avianar47 in forum World of Warcraft General
    Replies: 1
    Last Post: 11-08-2006, 08:53 PM
  5. Need Help with WoW Glider
    By paypal in forum World of Warcraft General
    Replies: 2
    Last Post: 07-07-2006, 02:08 AM
All times are GMT -5. The time now is 10:37 AM. Powered by vBulletin® Version 4.2.3
Copyright © 2024 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2024 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search