Advertisement

3D top-down Shooter, how to deal with height levels?

Started by July 05, 2016 08:40 AM
3 comments, last by DieselRay 8 years, 4 months ago

Hi everybody,

I'm about to start work on a 3D top-down shooter / tower defense game. One of the elements I want to have in the game is some vertical mobility, i.e. different height levels the game entities can climb up to or jump off, and eventually also flying enemies and flying player characters. I however have no idea how to best handle this in a way that doesn't make shooting an aiming weird.

Now when I look at how other 3D top-down shooters handles this... they mostly don't. From what I've seen 99% of 3D top-down shooters just keep everything on one plane so the game only has to handle aiming in the horizontal sense. The two exceptions I know off are AirMech and Running with rifles. AirMech sorta cheats by having a lower plane and a higher plane of combat, with a button to change whether your shots hit things in the lower or in the higher plane. I don't like how this feels when playing the game and I don't want to use it for my own design.

Running with Rifles has a system that interests me more, in that shooting at targets on higher ground happens automatically when aiming in their general direction. The best thing about it is that it is seamless, you just aim and shoot, and it works. However, I don't know how well RwR's system works with moving or flying targets, especially flying and moving targets with ground targets running underneath. Would this system still work? Or would it end up failing to properly hit the higher moving targets at all and just be frustrating?

Does anyone have thoughts on how this can be done, how Running with Rifles does this, and what might work for me?

[edit] I forgot to mention: Running with Rifles uses hitscan for most weapons which eliminates from of the aiming weirdness. I want to use ballistic trajectories for all weapons which will probably exacerbate the issues with hitting higher moving targets.

Hmm, tough problem. You could go with a manual lock-on mode, but that requires an additional UI / input and could be frustrating if someone locks on to the wrong thing. You could also try to do it automatic like RwR, but you'd have to look at what is around the area the player is shooting at, and try to guess whether they are trying to hit something above or below. I'm imagining taking a sphere or maybe a cone, based upon the projectile velocity and the players aim, and looking for enemies within it, and seeing if the shot would possibly hit them if it was aimed there way. You'd probably also need some preferences for enemies that were aimed at or hit earlier, and possibly enemies that are heading towards the player, or low on health, etc. Basically, you'd need a very healthy amount of aim assist.

Advertisement

Raytrace and see if the player's aiming at anything along only the x/y coordinates, if it picks anything up, adjust where the player's aiming along the z coordinate,

Have the player keep aiming at that z coordinate while the enemy it aimed at is still alive, and within maybe 1.5 times the weapon range.

If projectiles are that slow, or there's lots of really mobile flyers (or flyers that do things like divebomb/change z coordinates), build in leading, so if the player's aiming at an air target along the x/y coordinates their weapon leads shots.

A ray trace is likely to fail if the player never aimed directly aimed at the target, and immediately went to leading it's target. A spherecast might work, but a cone or frustum would be more accurate.

I like the Sphere/Cone check idea. It would be possible to build in target preferences per weapon type. Thanks for the replies, this helps me look in the right direction!

This topic is closed to new replies.

Advertisement