Sky force collision top down shooter

^ an example of what I want

I am trying to replicate this but for the life of me - I cannot understand how to get the collision for ground units to work

I tried extending my projectiles collision downwards…but the problem is when the bullet collision at the bottom collides…with the ground unit…it looks like the bullet goes PAST the ground unit due to perspective

as in this game it looks like its not exactly TOP DOWN…its angled slightly

Is there a way to somehow have things collide from the camera’s perspective?

Url is broken

Fixed the link - should work now

Usually similar games detect collision in screen space, so every object have some “flat” collision in screen coordinates - points, circles and rectangles.

Well, it is not easy to make it in unreal.

I think you should try to extend ground objects collision to height of player shots, and player’s collision to height of their shots, and look how it works for you.

I do have the enemy collisions extended upwards - but with perspective it makes it look like the bullets are going “past” the enemy Mesh on the ground and hitting the collision at the top. (at the end of the video)

you did give me an idea though of what to look up - “screen space collision” I just wasn’t sure what terms to look up or what to even research for this kind of thing.

I just found this - maybe I can compare the projectile - compare screen space with the enemy on screen if they are within range it counts as a hit?

This seemed to work for me…I wonder about the == part where I wrote in 35…- I think that number will have to depend on the size of the enemy

And the other problem would be that I looks the “hit results” hard to do a check if whatever actor I “hit” has an “enemy tag”

this solution is very expensive on mobile, you will have to cast to all classes every frame and compare their positions in space screen to your projectiles space screen.

Does anyone find a better setup for that?

I do face the same issue, have you find any work around?

I manage to it with tick and linetrace, don’t know if it is viable as ticks tend to be expensive.

First I separate the projectiles in two groups, on the player projectile and 2 enemy projectile.

The enemy projectile spawns at the players height, using a line trace to spawn at best location, so that projectile handle collisions normal as it is at the same height as the player.

The player projectile ticks every frame, doing a line trace for my object channel from the camera location in the direction of the projectile, I multiplied it to 10000 as I will not put any unit 2000 below the player, and I do have some spare length, but that value is up to you.

I think it is doable, only the players projectile are doing the ticks so as long as the atk speed is reasonable.