Ok, i think i understood, thank you very much.![]()
Ok, i think i understood, thank you very much.![]()
Hello, again...
Since i think i well understood what is, and how works the ObjectManager, i don't know why, but i fond incoherent values.
Here is what I do:
--------Constant values--------
clientConnection = 0x011CA260
o_ToMgr = 0x2864
o_ToFirstObject = 0xAC
o_NextObject = 0x3C
object_GUID = 0x30
-------------------------------
I read it, and i add an offset to get a start of the ObjManager.
It's like that: (clientConnection) + o_ToMgr
Ok, we are at start of the structure.
Then, i add the offset to go at the first object.
This is: (clientConnection) + o_ToMgr + o_ToFirstObject
So... MgrFirst = (clientConnection) + o_ToMgr + o_ToFirstObject
We are now at the first point.
So, in theory, i can get X, Y, Z, and others parameters for this object if i add others offsets.
But now, i just want, for the moment, to find my target's GUID in the ObjectManager.
So, i use a static adress to get my target's GUID. (0x010A58B
And i made a program to loop in search of this GUID, but in the ObjectManager.
So, MyTargetGUID = (0x010A58B
And, MyFoundGUID = MgrFirst + (i * o_NextObject) + object_GUID
(Where "i" is the number wich tells how many times we looped in order to go to next Object after a loop..)
But...I suppose MyFoundGUID is unique, and my program give me, sometimes, sames values (0,0,1...).
So i can conclude that... I don't find the values i expect.
I know this is hard to read, but i wanted to explain how i did as good as possible.
I read some helps on this subject but.. i didn't manage to do what i want.
This include Shynd's guids, and madx ones...
THANKS ALOT.
Pixion.
Last edited by Pixion; 01-09-2009 at 05:28 PM.
thats not an array, but a linked list!
Code:while (!done) { current_object_guid = (UInt64) WoW.ReadInteger(current_object); if (current_object == 0 || (current_object & 0x1) == 0x01) done = true; else { if (current_object_guid == (guid & 0xFFFFFFFF)) return WoW.ReadString(current_object + nameStringOffset, 512); current_object = WoW.ReadInteger(current_object + offset + 4); } }
I don't understand this part.
What is guid & 0xFFFFFFFF ? 512 ? 4 ?if (current_object_guid == (guid & 0xFFFFFFFF))
return WoW.ReadString(current_object + nameStringOffset, 512);
current_object = WoW.ReadInteger(current_object + offset + 4);
I've never talk about an array or something else, but what is a "linked list" ?
I thinked it was just..a list...
Thanks.
Pixion.
g3ggo why do you read the guid as a integrer? guid is 8 bytes not 4, you wouldnt get a correct value.
Hum, can a GUID be < 0 ?
No, you are likely treating them as Int64 instead of UInt64.
So yeah, if your GUIDs turn out to be negative youre doing it wrong.
yes, just pasted the code for finding players GUIDs.
sorry for that![]()
was currently reworking that part and so i really mixed that up
still its a linked list and no array.
but here the code to scan all objects.
Code:while (!done) { UInt64 objectGUID = WoW.ReadLong(curObj + 0x30); UInt64 targetGUID = 0; eObjType objectType = (eObjType) WoW.ReadInteger(curObj + 0x14); ... curObj = WoW.ReadInteger(curObj + 0x3C); if (curObj == 0 || (curObj & 0x1) == 0x01) done = true; }
hmm if you are treating them ans Int64 (signed 64 bit integer) they will be negative.
the highest bit is set on mobs (0x8...) so its treated as a negative number if you
treat that number as signed.
i simply use UInt64 for that, since i dont have any reason to use signs with GUIDs
here some GUIDs
Code:PLAYER: 0x0000000000333333 [*****] HP: 18777/18777 PLAYER: 0x0000000001111111 [****] HP: 26671/26671 MOB: 0xf53000746111e9d2 [Frostfederhexe] (9416/9416) MOB: 0xf530007460256860 [Frostfederkreischerin] (11770/11770) MOB: 0xf530007460256a9e [Frostfederkreischerin] (12175/12175) MOB: 0xf530007461256a9d [Frostfederhexe] (9740/9740) MOB: 0xf530007470256d63 [Gipfeljunges] (11379/11379) OBJECT: 0x21 0xf11002eee6000277 [Turm] OBJECT: 0x21 0xf11002eeea000347 [Turm] OBJECT: 0x21 0xf11002eee500035c [Träger] OBJECT: 0x21 0xf11002eee700035d [Träger] OBJECT: 0x21 0xf11002eee800035e [Turm] OBJECT: 0x21 0xf11002eee900035f [Träger] OBJECT: 0x21 0xf11002eee300035a [Turm] OBJECT: 0x21 0xf11002eee400035b [Träger] OBJECT: 0x21 0xf11002f5ca00060b [�] OBJECT: 0x0b 0xf120024635000001 [Gerüstwagen] OBJECT: 0x0b 0xf120024636000004 [Gerüstwagen] OBJECT: 0x0b 0xf120024635000003 [Gerüstwagen] OBJECT: 0x0b 0xf120024636000002 [Gerüstwagen] OBJECT: 0x21 0xf11002f13400065e [�] OBJECT: 0x03 0xf51002e61c0f3d47 [Saronitader] OBJECT: 0x03 0xf51002ed1a0f5665 [Osterei] OBJECT: 0x03 0xf51002ed1a0f56b3 [Osterei] OBJECT: 0x03 0xf51002ed1d0f573c [Osterei] OBJECT: 0x03 0xf51002ed1a0f576b [Osterei] OBJECT: 0x03 0xf51002ed1a0f57d9 [Osterei] OBJECT: 0x03 0xf51002ed1a0f58bf [Osterei] OBJECT: 0x03 0xf51002ed1a0f5a48 [Osterei]
Ok, it works now.
Autoit is a bit hard with Pointers, Hexa calculs and value types (long, int, int64...)
Thanks you.![]()