
class _player;
class _Object;
class _player
{
public:
__int32 Get;
_Object* Object;
BYTE ClientID;
__int8 Team;
char Name[12];
__int16 check;
__int8 check1;
__int8 check2;
__int32 PlayerSlotTeam;
__int32 Tester;
bool Has_C4;
__int32 State;
__int32 Rank;
__int32 Tester2;
__int32 CheckAgain1;
__int8 SpecHealth;
__int8 SpecHealthOB;
//===============dont touch above =====================//
char Pad9[184];
__int16 pad;
__int16 pad1;
__int16 pad2;
};
class _Object
{
public:
char pad0[4];
vect Origin;
vec3_t Unknown;
vec3_t Unknown1;
};
_player * player = (_player * )(CShellBase + 0x5A1554);
for( unsigned int i = 0; i < 16; i++ ){
playerAddy = (CShellBase + 0x5A1554) + (i * 0x1AC);
player = (_player*)(playerAddy);
if(player->Object !=NULL ){
D3DXVECTOR3 vScreenCoord,vScreenCoord2;
D3DXMATRIX projection, view, world;
D3DXVECTOR3 vWorldLocation = player->Object->Origin;
D3DVIEWPORT9 viewPort;
pDevice->GetTransform(D3DTS_VIEW, &view);
pDevice->GetTransform(D3DTS_PROJECTION, &projection);
pDevice->GetTransform(D3DTS_WORLD, &world);
pDevice->GetViewport(&viewPort);
D3DXVec3Project(&vScreenCoord, &vWorldLocation, &viewPort, &projection, &view, &world);
if(vScreenCoord.z <= 1){
if(player->Team == Me->Team)
{
sprintf(szName,"%s[%.1f]",player->Name,playerDistance);
DrawEngineString(ulBase, szName, vScreenCoord.x, vScreenCoord.y, D3DCOLOR_XRGB(0, 120, 255), true);
}
else
{
sprintf(szName,"%s[%.1f]",player->Name,playerDistance);
DrawEngineString(ulBase, szName, vScreenCoord.x, vScreenCoord.y, D3DCOLOR_XRGB(255,120,0), true);
}
if(player->Has_C4 == 1 )
{
DrawEngineString(ulBase, "[C4]", vScreenCoord.x, vScreenCoord.y+10, D3DCOLOR_XRGB(255, 0, 0), true);
}
typedef int (__thiscall *lpGetMeIdxInPlayerInfoList)(unsigned long ulCL***ientShell);
lpGetMeIdxInPlayerInfoList GetMeIdxInPlayerInfoList;
GetMeIdxInPlayerInfoList = (lpGetMeIdxInPlayerInfoList)(CShellBase + 0x17DA0);
typedef void (__thiscall *lpDrawEngineString)(unsigned long ulBase, char *String, int x, int y, unsigned long Color, bool Shadow);
lpDrawEngineString DrawEngineString;
DrawEngineString = (lpDrawEngineString )(CShellBase + 0x1A4ED0);