Shooting Game Problem!

Hi Blender Community!

I’m making a shooter with zombies, but I’m having a problem with the bullets.
Lets say I’m am standing forward. I shoot and the bullet goes straight. BUT THEN,
when I turn 90 degrees left (or right) the bullet goes sideways, as if it was locked on
an axis. Then, when I’m turned around 180 degrees, the bullet goes through the player.

Can someone help me please! :frowning:

Thanks! :smiley:

How is the bullet fired? It sounds like the bullet is being fired on a world axis (rather than using local co-ordinates).

I don’t know where to find that, could you tell me, please?

I suspect it’s exactly what Rubbernuke said. You can find it on the motion actuator you’re using to move your projectile. Tick the “L” to make the force/linear velocity use local coordinates.

When I click the L the bullet does spirals…
I don’t get it. ):

Post a blend and lets have a look at it.

Here it is! :slight_smile:

of it does spirals it might be spinning around the wrong axis. use the y axis for movement, be sure the rotation is applied (strg+a) and check if the bullet might be parented to the player. if it is, press alt+p to unparent.

here is the fixed .blend file
just set the local flag (the little L next to the livear velocity settings)
also i added an empty to spwan the bullet, instead of the weapon itself.
and i set the bullet to be dynamic instead of rigid body.


bullet_solution.blend (835 KB)

THANK YOU SO MUCH fr3shdumbl3dore,
I knew there was a problem with the spawning 'cause the
bullet came out of the gun…
And the physics, I tried different pyhsics to see which would work
best, and I saved it with Ridgid Body before uploading it here. It was
originaly dynamic though. You deserve some credit, because w/o you,
I might’ve given up! I’ll mention you in credits 4 sure!

Thanks again man! :smiley:

an empty is the best solution, as it can have logic but is not visible and you can defive the axis freely. the gun may be rotated a bit so you can see it better, but the bullet should still shoot straight.

thanks that’s kind ^^
btw i’ve seen that the bounding radius (you find it in the physics settings) is way to big for that small bullet. i didn’t change that, but it should be just a bit bigger than the actual bullet.

I’ll keep that in mind next time! Thanks! :slight_smile: