PDA

View Full Version : Projectile Friction!



Ingulit
September 18th, 2007, 10:45 PM
I'm essentially trying to make a marble gun. Currently, it's working great in the fact that the marbles show up, they bounce off of shit, etc. HOWEVER, I have one major problem that I can't seem to be able to fix; the marbles never slow down (noticeably). Preferably, what I'd like the marbles to do is bounce maybe 2-3 times off of metal surfaces, but each time they should take a considerable blow to their speed. As of right now, it's as if friction doesn't exist...

In the .projectile tag, I have the projectile moving at an initial 40 units per second and they reflect off of every material except water. I've tried many values, but in a last-ditch effort I made all the parallel and perpendicular friction factors 0.9 to try to slow these jumping beans down. The result is a bunch of never-stopping marbles bouncing all over the place.

Has anyone tried something like this before, and gotten it to work? It's starting to look bad for me...

EDIT: Videos! I cranked up the contrail's size so that you could see the projectiles; these are SUPPOSED to behave like marbles. As you can see, that's not quite how it happens. The parallel and perpendicular friction for my projectile are both 0.9 for every material type.

http://www.youtube.com/watch?v=i1GKOXlfVHo
i1GKOXlfVHo

Ingulit
September 18th, 2007, 11:02 PM
Now with videos!

(My Youtube tags don't work :'( )

Bad Waffle
September 18th, 2007, 11:13 PM
They need some gravity. It's a tag like "air friction" or something, look in the grenade tag for it.

Jay2645
September 18th, 2007, 11:17 PM
i1GKOXlfVHo
Fixed.

Ingulit
September 19th, 2007, 05:48 PM
So, uh, in the .projectile tag, under the "reflection" section for each of the different shader types... Apparently the perpendicular friction and the parallel friction are backwards?

Kiwibird
September 19th, 2007, 07:23 PM
What I would do is look at the fragmentation grenade projectile and copy all the physical properties and then tweak it from there.

Ingulit
September 19th, 2007, 08:01 PM
That's how I got started :P

EDIT: I do know the basics, guyz. I only post here if I can't deduce what the fuck is wrong, and when Bungie is no help.

Kiwibird
September 20th, 2007, 03:09 PM
Hmm, well sorry it's not working. It worked for me when I made the Frag Grenades into Tennis Balls. Maybe your missing something very tiny and you just passed over it. I hope you figure it out!