Hi Gangas ![Big Grin](images/emotions/emo2.png)
Whyz myz menuz nots gettingz overdraws?
Thatzz whyzz:
Serious Notice:
Put this Code at the top of your Present or Endscene.
Code:
pDevice->SetRenderState( D3DRS_SRCBLEND, D3DBLEND_SRCALPHA );
pDevice->SetRenderState( D3DRS_BLENDOP, D3DBLENDOP_ADD );
pDevice->SetRenderState( D3DRS_DESTBLEND, D3DBLEND_INVSRCALPHA );
pDevice->SetRenderState( D3DRS_ALPHATESTENABLE, FALSE );
pDevice->SetRenderState( D3DRS_SEPARATEALPHABLENDENABLE, FALSE );
pDevice->SetRenderState( D3DRS_STENCILENABLE, FALSE );
pDevice->SetRenderState( D3DRS_ALPHABLENDENABLE, TRUE );
pDevice->SetRenderState( D3DRS_VERTEXBLEND, D3DVBF_DISABLE );
pDevice->SetRenderState( D3DRS_INDEXEDVERTEXBLENDENABLE, FALSE );
pDevice->SetRenderState( D3DRS_COLORWRITEENABLE, D3DCOLORWRITEENABLE_ALPHA | D3DCOLORWRITEENABLE_BLUE |D3DCOLORWRITEENABLE_GREEN | D3DCOLORWRITEENABLE_RED );
pDevice->SetRenderState( D3DRS_SHADEMODE, D3DSHADE_GOURAUD );
pDevice->SetRenderState( D3DRS_FOGENABLE, FALSE );
pDevice->SetRenderState( D3DRS_SPECULARENABLE, FALSE );
pDevice->SetRenderState( D3DRS_LIGHTING, FALSE );
pDevice->SetRenderState( D3DRS_CULLMODE, D3DCULL_NONE );
pDevice->SetRenderState( D3DRS_ZWRITEENABLE, FALSE );
pDevice->SetRenderState( D3DRS_ZENABLE, FALSE );
pDevice->SetRenderState( D3DRS_FILLMODE, D3DFILL_SOLID );
//Additional if you use remove the /* and */ and edit Sprites to the name of your sprite.
/*
Sprites->Begin( D3DXSPRITE_DONOTSAVESTATE | D3DXSPRITE_DONOTMODIFY_RENDERSTATE || D3DXSPRITE_ALPHABLEND );
*/
AJAJAJAJ!
Creditz MicroSoftz DirectX 9z