[YOUTUBE]99Nxcn4I_uo[/YOUTUBE]
Code:
class Rendder
{
public:
char unknown0[232]; //0x0000
IDirect3D9Device9* pDevice; //0x00E8
char unknown236[76]; //0x00EC
D3DXMATRIX Projection; //0x0138
D3DXMATRIX View; //0x0178
D3DXMATRIX ViewProjection; //0x01B8
D3DXMATRIX ViewProjection2;
D3DXMATRIX InverseView;
};
class Local
{
public:
char unknown0[20]; //0x0000
LocalCoord* first; //0x0014 //our xyz
};
class LocalCoord
{
public:
char unknown0[16]; //0x0000 // first int could be actions ie firing , ready, hit
D3DXVECTOR3 pos;
char unknown28[24]; //0x001C
Ent* pEnt; //0x0034
char unknown56[140]; //0x0038
LocalCoord* pNext; //0x00C4
LocalCoord* pNext; //0x00C8
};
class Ent
{
public:
Type* pType; //0x0000
};
class Type
{
public:
char unknown0[8]; //0x0000
char ObjType[16]; //0x0008
};
Code:
LocalCoord* pPlayer;
D3DXVECTOR3 W2S(LPDIRECT3DDEVICE9 pDevice, D3DXVECTOR3 in, D3DXMATRIX vpm)
{
D3DXVECTOR4 temp,out;
D3DVIEWPORT9 vp;
pDevice->GetViewport(&vp);
D3DXVec4Transform(&temp,&D3DXVECTOR4(in.x,in.y,in.z,1),&vpm);
float tempInvW2 = 1.0f/temp.w;
out.x = (1.0f + (temp.x*tempInvW2)) * vp.Width /2;
out.y = (1.0f - (temp.y*tempInvW2)) * vp.Height /2;
out.z = temp.z;
return out;
}
Code:
Rendder * pRen = *(Rendder**)(0xEC6818);
Local * local = *(Local**)0xE6EB54;
if(local != 0 && local->first != 0){
for(pPlayer = local->first; pPlayer!= 0; pPlayer = pPlayer->pNext){
sprintf(szDebug,"%s",pPlayer->pEnt->pType->ObjType);
if(strcmp(szDebug,"Vehicle") == 0){
//there are a few others like "Avatar" "OfflineEntity" that i have seen
D3DXVECTOR3 out = W2S(pDevice,D3DXVECTOR3(pPlayer->pos.x,pPlayer->pos.y,pPlayer->pos.z), pRen->ViewProjection2);
if( out.z > 0 )
{
DrawString( out.x,out.y,0,0,255,255,szDebug);
}
}
Get PlayerMatrix:
Code:
0056630E E8 0D60FAFF CALL worldoft.0050C320
00566313 8BC8 MOV ECX,EAX
00566315 E8 E652FAFF CALL worldoft.0050B600
class IHateThisGame;
class PlayerMatrix;
class IHateThisGame
{
public:
char unknown0[16]; //0x0000
PlayerMatrix* pMat; //0x0010
char unknown20[176]; //0x0014
__int8 isA; //0x00C4
};
class PlayerMatrix
{
public:
char unknown0[16]; //0x0000
D3DXMATRIX player;
};
typedef IHateThisGame* (__thiscall* lpunkk)(LocalCoord* p);
lpunkk unkk;
unkk = (lpunkk)(0x50C320);