[snippet]Get Object By GUID menu

User Tag List

Results 1 to 5 of 5
  1. #1
    J0llyGr33n's Avatar Corporal
    Reputation
    1
    Join Date
    Sep 2011
    Posts
    20
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    [snippet]Get Object By GUID

    Hey all, just occurred to me that I have not actually posted anything or really given anything back so I decided I wanted to post some simple code I have been using.
    First Id like you to note its kinda messy, but it puts the basic idea out there. Its basically a replica of how you would get an object by GUID from object manager except I moved it over to check the Display ID as well. This way I can find anything in Object Manager by Model - This specific piece of code was used in my fishing program but with minor tweaking could be easily used to check for anything via Display ID.

    Edit: Just noticed I ****ed up on title. Its meant to be GetObjectbydisplay

    Edit: Removed a silly mistake I just noticed
    Code:
    DWORD ObjectManager::GetObjectByDisplay(HANDLE hProcess, DWORD BaseAddress, int DisplayId, DWORD s_curMgr, UINT64 localGUID)
    {
    	// The code below finds the object based on its display id and returns its object base.
    	DWORD BytesRead;
    	DWORD cObj, lObj, nObj;
    	UINT64 cGUID;
    	DWORD DescriptorFields;
    	//DWORD ObjectEnd =0x20;
    	DWORD Object_CreatedByOffset = 0x20;
    	DWORD DisplayId_Offset = 0x28;
    	int count = 0;
    	ReadProcessMemory(hProcess, (LPCVOID)(s_curMgr + 0xC0), &cObj, 4, &BytesRead);
    	while (cObj != 0 && (cObj & 1) == 0)
    	{
    		ReadProcessMemory(hProcess, (LPCVOID)(cObj + 0xC), &DescriptorFields, 4, &BytesRead);
    		ReadProcessMemory(hProcess, (LPCVOID)(DescriptorFields + Object_CreatedByOffset), &cGUID, 8, &BytesRead);
    		ReadProcessMemory(hProcess, (LPCVOID)(DescriptorFields +  DisplayId_Offset), &DisplayId, 4, &BytesRead);
    		
    		if (cGUID == localGUID)
    		{
    			count = count + 1;
    			if(DisplayId == 668)
    			{
    				lObj = cObj; // lObj is our fishing bobbers object.
    				return lObj;
    				break;
    			}
    		}
    
    		ReadProcessMemory(hProcess, (LPCVOID)(cObj + 0x3C), &nObj, 4, &BytesRead);
    		if (nObj == cObj)
    		{
    			//std::cout << "returned";
    			return -1;
    		}
    		else
    		{
    			cObj = nObj;
    		}
    	}
    	return -1;
    }
    I hope this is helpful to someone. Feel free to comment on the code, or anything - I'm always open to constructive criticism and want to improve because I understand I am far from perfect. Just keep in mind that the main point of this is to point out the idea, and show a way to do it.

    Note no real error checking.
    Last edited by J0llyGr33n; 03-23-2012 at 11:11 AM.

    [snippet]Get Object By GUID
  2. #2
    Reflexes's Avatar Private
    Reputation
    1
    Join Date
    Mar 2012
    Posts
    5
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hi, i wanna send you a message but icant because u have too many messages inside the meassagebox.

  3. #3
    J0llyGr33n's Avatar Corporal
    Reputation
    1
    Join Date
    Sep 2011
    Posts
    20
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Hey Reflexes should be better now. Try again.

  4. #4
    Master674's Avatar Elite User
    Reputation
    487
    Join Date
    May 2008
    Posts
    578
    Thanks G/R
    2/23
    Trade Feedback
    1 (100%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    <something used to be here... its gone now>
    Last edited by Master674; 10-15-2012 at 12:57 PM.

  5. #5
    J0llyGr33n's Avatar Corporal
    Reputation
    1
    Join Date
    Sep 2011
    Posts
    20
    Thanks G/R
    0/0
    Trade Feedback
    0 (0%)
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    @Master
    I've been working with this way because I am still new to dealing with WoW and I have yet to explore my options entirely. While I do experiment with different things I've yet to update my classes because I don't like implementing things I don't understand well. I'm not amazing at C++ but have enough to get by and am working on improving on it.

    Thanks for your feedback

Similar Threads

  1. [C# snippet] Get player info by GUID (name, race and class)
    By T@rget in forum WoW Memory Editing
    Replies: 1
    Last Post: 09-03-2016, 01:11 PM
  2. Get Object GUID by Pointer
    By Amrok in forum WoW Memory Editing
    Replies: 3
    Last Post: 09-01-2011, 01:58 PM
  3. HOW TO: How to go about getting a leveling guide for free
    By baddelini in forum World of Warcraft Guides
    Replies: 11
    Last Post: 03-10-2009, 07:12 PM
  4. Easy way to get object sizes
    By crediar in forum WoW Memory Editing
    Replies: 8
    Last Post: 05-19-2008, 05:07 PM
  5. Lol Just What I Get For Stealing Guides!
    By Zore. in forum Community Chat
    Replies: 5
    Last Post: 08-11-2007, 04:28 PM
All times are GMT -5. The time now is 02:22 PM. Powered by vBulletin® Version 4.2.3
Copyright © 2025 vBulletin Solutions, Inc. All rights reserved. User Alert System provided by Advanced User Tagging (Pro) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Google Authenticator verification provided by Two-Factor Authentication (Free) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
Digital Point modules: Sphinx-based search