Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

3 Dimensional Chat / How do you make an object smoothly fade until you can't see it?

Author
Message
Xander
21
Years of Service
User Offline
Joined: 3rd Mar 2003
Location: In college...yeah!
Posted: 10th May 2003 05:12
DB Classic please. I know about the "fade" command, but it only affects the light data. I don't want to change the ambient light level. However, it says in the help files that using this command somehow will "make an object slowly fade until completely invisible." What is that supposed to mean? It doesn't seem to work. Do I have to use the command repetatively? I would appreciate a small code example with a fading cube or something. Thanks.
Xander
Bolt of Bolt Software Productions
Xander
21
Years of Service
User Offline
Joined: 3rd Mar 2003
Location: In college...yeah!
Posted: 10th May 2003 05:13
Oh yeah, it is also ghosted.

Xander
Bolt of Bolt Software Productions
Zach
21
Years of Service
User Offline
Joined: 23rd Feb 2003
Location: Ms, USA
Posted: 10th May 2003 06:39
try a loop using the fade object command to fade the object more and more until you can't see it anymore...

Tupelo, Ms
JAT
21
Years of Service
User Offline
Joined: 7th Nov 2002
Location:
Posted: 10th May 2003 09:10
I don't know DB, but perhaps if you can set the alpha channel of the material diffuse color to diminishing values to zero, and the D3D device has alpha blending enabled, you can make the object using the material fade transparent. Maybe someone can translate this into DB-speak.

-JT

John Thompson
http://www.jtgame.com/jtedit
Ian T
21
Years of Service
User Offline
Joined: 12th Sep 2002
Location: Around
Posted: 10th May 2003 19:46
Yeah, I think that translated to ghosting/fade object...

--Mouse

Famous Fighting Furball
arras
21
Years of Service
User Offline
Joined: 3rd Feb 2003
Location: Slovakia
Posted: 12th May 2003 14:45
Up to my knoweledge you cant fade it like this in DB.
Ghost object command is affected by object(texture) color. Darker color-more transparent object will be. If Black, it will be unvisible.

Fade object is working only in very small range. Thats at last what I found out when I was testing it.

Please corect me if I am not right somebody, because If there is posibility to fade object without changing ambient level I would like to know about it too...
AsriCE
21
Years of Service
User Offline
Joined: 10th Jan 2003
Location: Brunei
Posted: 12th May 2003 16:51
I have this feature implemented in my game "Ninja Kura" in the credits at the end. Bare in mind that the backdrop colour is black. You can download the source here http://www.darkbasicpro.com/apollo/view.php?t=9309&b=5

This Plain Is Used As Background


For Fading In:


For Fading Out:


Hope this helps.

Asri CE Crew

Anak Brunei!
arras
21
Years of Service
User Offline
Joined: 3rd Feb 2003
Location: Slovakia
Posted: 13th May 2003 15:25
Yes thats good way but limits you in use. If there is something having only one colour you can do it like this. But if there is object with complex texture and background, you can try to change texture colour each time you want to fade more or less, but it would be lot of work coding and result would be so slow that it would be useles in real time probably.

imagine you have particle sistem, which create smoke afther cannon fire. You have several plane objects textured with smoke texture and you need to fade smoke slowly untill its invisible...

Login to post a reply

Server time is: 2024-05-06 12:58:09
Your offset time is: 2024-05-06 12:58:09