IRR4Delphi(cool efect)

Announce new projects or updates of Irrlicht Engine related tools, games, and applications.
Also check the Wiki
Post Reply
djoker
Posts: 39
Joined: Thu Dec 22, 2005 10:25 pm
Location: Portugal

IRR4Delphi(cool efect)

Post by djoker »

keys : q and w - speedup the plane




toyplane.rar


Image
Image
Image
Image
Never underestimate the power of Delphi....Ignorance is bliss, but knowledge is power...
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

Hehe nice one, do you use a physics engine for that?

Cool trails but i'd say the speed increase/decrease should be slower as if you hold the key down for more than a split second it just jumps to the max/min.
Image Image Image
shadowslair
Posts: 758
Joined: Mon Mar 31, 2008 3:32 pm
Location: Bulgaria

Post by shadowslair »

Really nice indeed!!! :D

JP is right. Just increase the sensivity of the key presses.

Ah, and that trail is just awsome. Though I don`t think I`ll use it, is there any chance of posting some code or at least explain the principle of it? Plz :roll:
"Although we walk on the ground and step in the mud... our dreams and endeavors reach the immense skies..."
JP
Posts: 4526
Joined: Tue Sep 13, 2005 2:56 pm
Location: UK
Contact:

Post by JP »

The principle is fairly simple, i've seen them posted before and i think someone posted source for them as well so you might find it if you search.

Basically you have a triangle strip like this:

Code: Select all

-----------
|\   |\   |
| \  | \  |
|  \ |  \ |
-----------
Or thereabouts... my ascii art ain't too hot ;)

And you build up this tri strip progressively putting the new vertices at the position of the plane so it leaves a trail behind it. And then you fade out the oldest vertices and then remove them when they're completely transparent. Applying a nice texture with an alpha channel or alpha blending will give you a nice result.

That's basically it, not very well explained but hopefully you get the idea!
Image Image Image
Halifax
Posts: 1424
Joined: Sun Apr 29, 2007 10:40 pm
Location: $9D95

Post by Halifax »

Yup, that was a good explanation JP. This also can be applied to other things such as in car games where they draw a darken alpha blended triangle strip when it skids.
TheQuestion = 2B || !2B
Post Reply