Shoot projectiles up and down

I’m making a top-down dungeon crawl type of game, and I want the ability to shoot projectiles the direction the character is currently walking. So when they’re moving left, and press a button, they shoot left; when they move up, they shoot up, etc.

I have it working for left and right, but can’t seem to make my character shoot projectiles up and down. I’ve found help on shooting projectiles, but everything I found was about shooting left and right, and I didn’t find anything on shooting up and down. I have the “Match Rotation” checkbox checked on the emitter, and have the up/down control mapped to a “Flip” control (like I do with left/right) but the character continues only shooting left and right.

Can anyone help me here? Here’s the game currently: http://www.flowlab.io/game/play/243704
(Move with arrow keys, shoot with spacebar.)
Thanks!

The emitter always emits in the direction the emitting object is facing. If you want you have to your player shoot “up” without pointing the players direction up, you could do this:

  1. make a separate object to actually handle the projectile shooting, call it “gun” or something, and make sure you turn off collisions on this object. This object could be invisible if you like (just edit the sprite and click the red “x” to delete it).

  2. on game start, attach the “gun” to your player.

  3. add the emitter to your gun, along with a trigger to fire.

  4. make your gun object rotate to the direction you want to shoot with arrow keys.

Here is an example: http://flowlab.io/game/view/245564

I just made the gun sprite a small arrow so that you can see the direction it is facing,

That’s exactly what I want, thanks so much!!

how do you make the tank rotate and shoot were its facing

http://flowlab.io/game/view/656620