C++ Help D3DPT_POINT

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat

HakerHelp

Newbie
Aug 27, 2012
1
212
0
Hi need help with the code.

https://dankonoy.com/9/progdirectx9/107/4799-sistemy-chastic.htm

At the end describes how to obtain the distance now I need to get it !


C++:
if((NumVertices == 1201 && primCount == 1279)){




if (SpriteCreated1 == FALSE)
{
D3DXAssembleShader(ShaderAdd, sizeof(ShaderAdd), NULL, NULL, 0, &ShaderBufferAdd, NULL);
pDevice->CreatePixelShader((const DWORD*)ShaderBufferAdd->GetBufferPointer(), &sAdd);
ShaderBufferAdd->Release();

D3DXCreateTextureFromFile( pDevice, "target.png", &IMAGE1 );
SpriteCreated1 = TRUE;
} 

bool SpriteCreated1 = false;
LPDIRECT3DTEXTURE9 IMAGE1;
LPD3DXSPRITE SPRITE1 = NULL;
IDirect3DPixelShader9 *sAdd = NULL;
char ShaderAdd[] = "ps.1.0 def c0, 0.0f, 0.0f, 0.0f, 0.0f tex t0 add r0, c0, t0";
ID3DXBuffer *ShaderBufferAdd = NULL;
LPDIRECT3DSTATEBLOCK9 pStateBlock = NULL;
float pSize = 5; //pic size

D3DXCreateSprite( pDevice, &SPRITE1 );
SPRITE1->Begin( D3DXSPRITE_ALPHABLEND | -50);
SPRITE1->Draw( IMAGE1, NULL, NULL, NULL, 0xFFFFFFFFF );
SPRITE1->End( ); 


if( SPRITE1 != NULL ){ SPRITE1->Release(); SPRITE1 = NULL; }

LPDIRECT3DSTATEBLOCK9 pStateBlock = NULL; 
pDevice->CreateStateBlock( D3DSBT_ALL, &pStateBlock );
pStateBlock->Capture(); 

pDevice->SetTexture( 0, IMAGE1);
pDevice->SetPixelShader(sAdd);
pDevice->SetRenderState(D3DRS_ALPHATESTENABLE, TRUE);
pDevice->SetRenderState(D3DRS_ZENABLE, D3DZB_FALSE);
pDevice->SetRenderState(D3DRS_ZFUNC, D3DCMP_ALWAYS);
pDevice->SetRenderState(D3DRS_POINTSPRITEENABLE, 1);

pDevice->SetRenderState(D3DRS_POINTSIZE, *((DWORD*)&pSize));


pDevice->DrawPrimitive(D3DPT_POINTLIST, 0, 10);


pStateBlock->Apply();
pStateBlock->Release();
}
 
Attention! Before you post:

Read the How to Ask Questions Guide
99% of questions are answered in the Beginner's Guide, do it before asking a question.

No Hack Requests. Post in the correct section.  Search the forum first. Read the rules.

How to make a good post:

  • Fill out the form correctly
  • Tell us the game name & coding language
  • Post everything we need to know to help you
  • Ask specific questions, be descriptive
  • Post errors, line numbers & screenshots
  • Post code snippets using code tags
  • If it's a large project, zip it up and attach it

If you do not comply, your post may be deleted.  We want to help, please make a good post and we will do our best to help you.

Community Mods