[SOLVED] Help with shooting functions

I want to shoot backwards, like this:
It never works. How can I do this?.

What are your events for this? Anyways, what you’re probably looking for is:
-Rotate the bullet 180°
-Set bullet speed to negative, not positive.


1 Like

Like this right?:

(1g is the number of the animation)

Yes. How does it work?

1 Like

The problem is, it doesn’t.

No, “1g” is a string. If it’s the name of the animation, then use the correct condition. Otherwise, use a number.

Also, I notice in the fire bullet action, there appea5rs to be a space between the word “Player” and “.X()” (and also the “.Y()”). Can you check this, and remove the space if there is one?

And as @Sciller4 wrote, you’ll need to change the angle or bullet speed to a negative value (but not both) to fire it backwards

It kind of works right know.
(It shoots both)

I attempted to fix it

it now works

But there’s still a problem

Right. You’ll have to be more specific. What’s the problem?

1 Like

Here’s the first part of the code because it don’t let me put both

The second part

Backwards shots good, but in front shot both sides

Right. Seems to me you have two events that both fire a bullet. You should only have one. It seems to me that backwards does not shoot good, but rather that backwards shoots two overlayed bullets.

This is how I would set up the code.

See if that works for you. Toodles!

1 Like

It now works great