Thought you were trying to get the list directly from packet received and not from the ram :(.
Here is what I use for entity browsing :
Entity collection and skill cooldown data use the same base structure. That's why I made a generic template collection class.
The offset is the one you talked I suppose (mine is from the french client).
Very simple way to use this (linked list):
Here is what I use for entity browsing :
Code:
struct EntityElement
{
EntityElement* next;
EntityElement* previous;
int id;
Entity* entity;
};
template <typename T>
struct Collection
{
DWORD unk1;
DWORD unk2;
template <typename T>
struct Container
{
T* begin;
T* unkLink1;
T* unkLink2;
};
Container<T> *container;// 8
int nbElements;
BYTE unk3[0x1c];// 10
std::string name;// 2c : name of the collection
};
typedef Collection<EntityElement> EntityCollection;
typedef Collection<SkillCooldownDataElement> SkillCooldownCollection;
enum EntityCollectionType {ECT_Chara, ECT_Effect, ECT_Duel};
Code:
EntityCollection* GetEntityCollection(EntityCollectionType type, ULONG lpBase)
{
size_t* addr = (size_t*)lpBase;
if(addr)
addr = ThreadSafeReadAddress(addr, 0);
addr = (size_t*)((size_t)addr+0x61C+type*sizeof(EntityCollection));
return (EntityCollection*)addr;
}
Very simple way to use this (linked list):
Code:
EntityCollection* ec = GetEntityCollection(ECT_Chara);
EntityElement *el = ec->container->begin;
for(int i = 0; i < ec->nbElements; ++i)
{
Entity* ent = el->entity;
// any code there...
el = el->next;
}