
I were bored.
Wallhack
Code:
void Wallhack( LPDIRECT3DDEVICE9 D3DDEVICE, DWORD VALUE )
{
D3DDEVICE->SetRenderState( D3DRS_ZENABLE, VALUE );
}
FullBright
Code:
void FullBright( LPDIRECT3DDEVICE9 D3DDEVICE, DWORD VALUE )
{
D3DDEVICE->SetRenderState( D3DRS_LIGHTING, VALUE );
}
Fillmode
Code:
void Fillmode( LPDIRECT3DDEVICE9 D3DDEVICE, DWORD FILLMODE )
{
D3DDEVICE->SetRenderState( D3DRS_FILLMODE, FILLMODE );
}
Chams
Code:
void Chams( LPDIRECT3DDEVICE9 D3DDEVICE, DWORD COLOR )
{
D3DDEVICE->SetRenderState( D3DRS_AMBIENT, COLOR );
}
Instant Chams
Code:
void InstantChams( LPDIRECT3DDEVICE9 D3DDEVICE, LPDIRECT3DTEXTURE9 tCOLOR, DWORD COLOR )
{
GenerateTexture( D3DDEVICE, &tCOLOR, COLOR );
D3DDEVICE->SetTexture( 0, tCOLOR );
}
Usage
Code:
/*Wallhack*/
Wallhack( pDevice, D3DZB_FALSE );
/*FullBright*/
FullBright( pDevice, D3DZB_FALSE );
/*Fillmode*/
FullBright( pDevice, D3DFILL_WIREFRAME ); //You even can use Point etc.
/*Chams*/
Chams( pDevice, Red );
/*Instant Chams*/
InstantChams( pDevice, tYellow, Yellow );//Define tYellow like that: LPDIRECT3DTEXTURE9 tYellow;
Please NOTE:
The Instant Chams Function requires another function, too.( GenerateTexture )
Credits for that @
azorbix
Code:
HRESULT GenerateTexture(IDirect3DDevice9 *pD3Ddev, IDirect3DTexture9 **ppD3Dtex, DWORD colour32)
{
if( FAILED(pD3Ddev->CreateTexture(8, 8, 1, 0, D3DFMT_A4R4G4B4, D3DPOOL_MANAGED, ppD3Dtex, NULL)) )
return E_FAIL;
WORD colour16 = ((WORD)((colour32>>28)&0xF)<<12)
|(WORD)(((colour32>>20)&0xF)<<8)
|(WORD)(((colour32>>12)&0xF)<<4)
|(WORD)(((colour32>>4)&0xF)<<0);
D3DLOCKED_RECT d3dlr;
(*ppD3Dtex)->LockRect(0, &d3dlr, 0, 0);
WORD *pDst16 = (WORD*)d3dlr.pBits;
for(int xy=0; xy < 8*8; xy++)
*pDst16++ = colour16;
(*ppD3Dtex)->UnlockRect(0);
return S_OK;
}
Here are a few screenshots




Credits:
UnlimitedCheating