Explosions with NxOgre

Ewyx

06-12-2009 19:41:31

First time writer, been lurking around for a bit however.

What's the best way to go around doing explosions with NxOgre and PhysX. I was thinking of messing around with ForceField, but I can't seem to wrap my head around it? Is it even worth bothering, or should I just use a simpler method for doing this?

Also, my second question is, is CCD even worth bothering with? Especially if you're working with an extension other people are meant to use. Should I just drop the whole idea and use raycasting? What I'm more concerned is not about high-speed projectiles like bullets, but perhaps something you can still track with your eye [it still looses height over time], but still too fast to cause tunneling.

betajaen

06-12-2009 20:02:23

Forcefields for explosions, no doubt.

CCD is worth using but it can't do fast moving things like bullets, raycasting and sweeping are better alternatives for missiles and bullets. But if you want explosions, you'll get shrapnel and for that you need CCD. ;)

Ewyx

06-12-2009 21:29:05

I read sweeping is accessible through NxOgre only in detritus? Should I have any worries if I use the PhysX call with BloodyMess?

betajaen

06-12-2009 21:34:11

It's more iffy. But you need to be extra careful with the userData of the Shapes/NxActors when using the representive_cast function when you want to get the Shape/RigidBody out of them.