Skip to main content

All Questions

Tagged with
Filter by
Sorted by
Tagged with
1 vote
1 answer
101 views

Unable to Shoot Enemies Due to Proximity in a 2D Game

I’m developing a 2D top down shooter where the player has a pistol. However, I've noticed that when enemies get too close, the player can't shoot them because the pistol doesn't have a collider. I ...
Javier Triviño's user avatar
1 vote
1 answer
71 views

Why won't my bullets shoot?

I am making a top-down shooter in Unity (following a Brackeys tutorial for the top-down shooting mechanic). When I press the left mouse button a bullet prefab spawns, as it should, however there is no ...
John Hughes's user avatar
0 votes
2 answers
301 views

2D - How to make a gun muzzle aim at the mouse when the rotation pivot isn't on the muzzle?

I'm making a simple 2D shooter game in pygame and I've come across an issue when making the character aim its gun at the mouse. To make the gun aim up and down, I've set it so that the gun uses the ...
jaregax432-awinceo's user avatar
0 votes
1 answer
113 views

Why the enemy is flipping constantly when it collides with an obstacle?

I'm making a 2D platformer with Unity. I have an enemy patrol that shoots bullet. The enemy is working fine until it reaches to a point that should be turn around. (when collides with an obstacle or ...
Ali's user avatar
  • 55
0 votes
0 answers
335 views

Unity 2D Player Shoots at my joystick position

Hi I am new to unity and have only a little coding knowledge. Right now I have made my character shoot at my touch position on mobile but when ever I touch the joystick, whick I use to move my ...
Anees's user avatar
  • 1
0 votes
2 answers
488 views

"Instantiate" function in Unity spawns enemy but it doesn't show up

So, I'm making a top down shooter (2D) and I already made an enemy prefab. It walks to the player and damages it, and reacts to bullets physically until it eventually dies. The prefab itself is ok, ...
tralph3's user avatar
  • 101
2 votes
1 answer
126 views

2D bone animation - point gun at mouse

How is this handled? https://www.youtube.com/watch?v=egk3yD1w4Wo It's some form of kinematics which I kinda understand and I have a very solid grip of trig, but I don't know how to start with having ...
NuBc4k3's user avatar
  • 31
5 votes
4 answers
21k views

How can I make the player "look" to the mouse direction? (Pygame / 2D)

Here's my code: ...
Ericson Willians's user avatar
0 votes
1 answer
1k views

Rotating A 2D Cannon Based On Mouse Position [duplicate]

I'm creating a game like bubble shooter, I have a cannon which is in the image bellow: I want to rotate the cannon based on mouse position. So far I tried various solutions I found over the web but ...
Game Dev 4 Life's user avatar
0 votes
1 answer
79 views

Rotating 2D-Projectile towards mouse, hides the projectile (Maybe changes the layer)

I want to shoot towards my mouse, which is working fine now. After this was solved, I wanted to rotate the projectile, so that it's looking to the mouse. This is my code: ...
TobiasW's user avatar
  • 987
2 votes
1 answer
156 views

My bullet changes the velocity depending on where I click

I want to build a little 2D-Sidescrolling shooter and I'm now at the shooting script. I already figured out how to shoot a bullet towards my mouse pointer. I got something like this : ...
TobiasW's user avatar
  • 987
0 votes
1 answer
295 views

Questions about networking theory in a 2d shooter game [duplicate]

So currently I am starting to work on a 2d top down space shooter game, and I have just got to networking. So far the client can draw a ship at a desired x, y and rotational coordinate with any set of ...
Lemon Drop's user avatar
-2 votes
1 answer
350 views

Spawning enemies outside of view [closed]

I'm trying to create a 2d shooter for Android. How do I spawn enemies "above" the screen, so that they "enter" the game screen instead of spawning at the top of it? I think I need to make a game ...
user2180680's user avatar
0 votes
1 answer
375 views

Character movement relative to cursor position

I want my top-down shooter character to move towards the mouse when pressing the up arrow and strafe relative at right angles to it when pressing the left and right arrow keys. I can't figure out how ...
user2130844's user avatar
0 votes
1 answer
3k views

How to make a top down shooter? [closed]

I want to know is with XNA 4.0 (and C#) How do I exactly make a top down shooter? I have been looking for ages, but have been unable to find out how. If someone could tell me how to get started with ...
DarkMiner's user avatar