Author Topic: How do I alter the physics size of a projectile?  (Read 1388 times)

According to Muffinmix's tutorial (which I read up on now, which answered a lot of other stupid questions), the physics of a given projectile (like, the actually hitting stuff) only happens at the dead center of said projectile. When I was testing some rocket-launcher-related stuff, I noticed the rocket's model seemed to clip through bricks, which suggests that this is true. This might be an issue, since I was hoping for some moderately larger-than-average projectiles. Is there a way to alter the size of a projectile to prevent the edges clipping through the target? (i'm using a rather small projectile model that's covered by a decent-sized emitter)

No. Projectiles are essentially just infinitely small points with a velocity that do a hitscan raycast each frame and update their position/velocity. The rotation of the model is just the velocity. They do not have a physics size. (well, except for cases where you have projectiles colliding with projectiles, but that's a whole other weird business)

Actually, a recent update added a new variable for projectile datablocks, ballRadius.

Though this doesn't make the projectile any wider, just longer. This would prevent it clipping from the front, but not from the sides.

Actually, a recent update added a new variable for projectile datablocks, ballRadius.

Though this doesn't make the projectile any wider, just longer. This would prevent it clipping from the front, but not from the sides.
Clipping from the sides is really the main issue here, since they don't really make that big of a scene upon impact anyway.
nuts though. Any sort of workarounds to this that anyone knows of?

Clipping from the sides is really the main issue here, since they don't really make that big of a scene upon impact anyway.
nuts though. Any sort of workarounds to this that anyone knows of?

You could use a radius search every 50 ms or so, and essentially handle collisions yourself. Or maybe fire some secondary, invisible projectiles around it in a circle, and when one of them explodes, explode the rest of them.


Also, I recommend using the same topic as opposed to creating 3 separate ones, as the problems are all fairly related.