Originally Posted by
Dolphe
Update 2: Got everything working except getting the ACDadress (ACD data) (I think the offsets has changed)
= can't get item information / or your char info
Edit 2 : Gonna go to bed now, (Still have no idea about the last offset) so I'll finish off tomorrow.
why not let the dev to fix his code? I am pretty sure he understand his code better. But if Evozer is away, just send me what part of code is failing and I will look at it.
edit: LoL, I see in OP that you are the dev. I see.
Just let me know how can I help.
edit2:
In Evozer's code:
Code:
private void GetACDAddress()
{
int c = reader.ReadInt(DiabloIII.ObjectManager, 0x868, 0);
short id = (short)(0xFFFF & ACDID);
int bitShift = reader.ReadInt(c + 0x18C);
int acd = reader.ReadInt(reader.ReadInt(c + 0x148)) + 4 * (id >> bitShift) + 0x2D0 * (id & ((1 << bitShift) - 1));
ACDAddress = acd;
}
But as I said in the (1.0.8.16416 offsets)other topic, the ObjectManagerStorage offset is changed in 1.0.8 from 0x794 to 0x7CC
In Evozer's code 0x868 is a bad formatted number, because in reality it WAS 0x794+0x0D4 (the result is the same)
0x794 is the offset of ObjectManagerStorage derived from ObjectManager's address and 0x0D4 is the ACD container's offset inside ObjectManagerStorage.
TLDR: the proper code is:
Code:
private void GetACDAddress()
{
int c = reader.ReadInt(DiabloIII.ObjectManager, 0x7CC+0x0D4, 0);
...
}
Code:
private int GetFastAttribGroup()
{
int c = reader.ReadInt(DiabloIII.ObjectManager, 0x7CC+0x0C8, 0x70);
...
}
Code:
private Actor GetActorFromID(int id)
{
int c = memory.ReadInt(ObjectManager, 0x7CC+0x134);
...
}
Code:
public List<Actor> GetActors()
AND
public List<ACDActor> GetACDActors()
{
...
int container = memory.ReadInt(ObjectManager, 0x7CC+0x134);
...
}
Code:
public ACDActor Player()
{
int index = memory.ReadInt(ObjectManager, 0x7CC+0x1B8, 0);
return new ACDActor(GetActorFromID(memory.ReadInt(ObjectManager, 0x7CC+0xA8, 0x60 + index * 0x8598)));
...
}
There can be more problems in the code, but you can handle them now.