Archived

This topic is now archived and is closed to further replies.

gustav

Transparent Ghost

Recommended Posts

try this way:


  
m_pd3dDevice->SetRenderState( D3DRS_ALPHABLENDENABLE,true);
m_pd3dDevice->SetRenderState( D3DRS_SRCBLEND, D3DBLEND_ONE );
m_pd3dDevice->SetRenderState( D3DRS_DESTBLEND,D3DBLEND_ONE );
RENDER THE GHOST
m_pd3dDevice->SetRenderState( D3DRS_SRCBLEND, D3DBLEND_ONE );
m_pd3dDevice->SetRenderState( D3DRS_DESTBLEND,D3DBLEND_ZERO );


byezzzz

Share this post


Link to post
Share on other sites
Thanks, I have more pictures on the game at:
http://www.thunder-storm.tk (in swedish)

and


http://www24.brinkster.com/thunderstormweb/gallery/news001.jpg
http://www24.brinkster.com/thunderstormweb/gallery/news002.jpg
http://www24.brinkster.com/thunderstormweb/gallery/news003.jpg
http://www24.brinkster.com/thunderstormweb/gallery/news004.jpg
http://www24.brinkster.com/thunderstormweb/gallery/news005.jpg
http://www24.brinkster.com/thunderstormweb/gallery/news006.jpg

Share this post


Link to post
Share on other sites
if you are building the models procedurally then just use an FVF with diffuse and vertex structures with ARGB components.

If you are using X files, you are going to have to use the CloneMesh call, which accepts as an argument a new FVF and vertex structure, replace the existing vertices with your new one and then do as blue chip said.

Share this post


Link to post
Share on other sites
Just change the material, or make a nwe one, and use that

D3DMATERIAL9 mat;
memset(&mat, 0, sizeof(mat));

mat.Diffuse.r = mat.Diffuse.g = mat.Diffuse.b = 1.0f;
mat.Diffuse.a = opacity; // between 1 and 0

device->SetMaterial(&mat);

// use the above alpha blend thing bluechip said, except make sure you say TRUE instead of true (picky i know)

// render stuff

ahh... just saw you said VB - i dont know the exact calls, but look into materials. It should be very similar.

-Vulcan

[edited by - Vulcan on May 6, 2003 8:18:06 PM]

Share this post


Link to post
Share on other sites
I asked you what is brinkster

Edit: Watch the language. If you try to type in www.brinkster.com, you find that they are a web-hosting service. Also, don't hijack threads and do what you did when you don't get a response. -Jim


[edited by - Jim Adams on May 7, 2003 1:36:21 PM]

Share this post


Link to post
Share on other sites