RTS style gun shooting

This isn’t really a tech question, more of trying to get some other developers’ opinions. I have an RTS-style game that involves multiple gangsters (say roughly a dozen ‘fighting’ at a time) shooting pistols, rifles, shotguns, and machine guns. My question is whether or not it’s worth it (in terms of gameplay/realism) to add a bullet tracer or even bullet object coming out of the gun’s barrel or is it simply enough to go with the muzzle flash? Yes it would improve performance to leave out any further instantiating (especially the tracers, I hear they can be ‘expensive’) and I also see a lot of other RTS games that simply use the muzzle flash and bullet impacts. So…is it worth it to add slight bullet tracers to see something fly out of the gun and hit the ‘enemy’? Thanks in advance.

Maybe. I mean, really, it depends. You would have to build it and look at it and decide whether it makes the game better. I frequently build things I pull from the game as annoying or detrimental. So really, you just want to make sure that whatever you build is simple and lightweight - you don’t want to invest too much time and energy in it just to take a look.

It doesn’t have to be real. If your people fire their guns like thirty times in this or that direction, you can just flash a little line on the screen between them and the enemy, and it looks like you have bullets and trails but you are really just randomly flickering a sprite.

This is also literally what particle systems are for. If you want something more reliably indicative of real gunfire, but that is light on system resources, that’s where you should be looking.

I’d pick one of those and start messing around with it.

5 Likes

A lot of games will use both approaches. Usually most weapons will use just muzzle flash and hitscan, with some big guns having full projectiles.

I think that - in general - you want to limit the number of actual projectiles on screen if you have a RTS style combat, just because at like 30+ characters on screen it’d be kinda distracting and annoying if theres a billion tracers everywhere. Not even so much about performance, mostly just about not cluttering up the screen too much.

2 Likes

I would put tracers on only the high damage or extremely long range weapons. This will let the player know where damage is coming from.

Also if you put it on a machine gun, not all shots needs a tracer could have a random but low chance per shot.

Or then again maybe it would be FREAKIN’ SWEET and JUST PLAIN AWESOME. :wink:

3 Likes

Yea that’s how I felt with tracers on…it was cluttered.

I’m thinking it might not be worth it…plus I like the idea of the performance savings. Thanks the replies.

In real life military rounds are organized to have a tracer round ever 5 or 10 bullets, when using machine guns. I can’t remember exactly, although some people have been known to remove all rounds from a belt (container) and replace them with all tracer rounds, which coincidentally looks pretty awesome especially during night fire exercises!! :smile:
During the day tracers are largely pointless for small caliber rounds = smaller than 50 caliber.

Just a point of fact - don’t take this as a suggestion for a game, which the top requirement should be for it to be fun and look good to the player.

4 Likes

Depends on the specs of the platform your putting it on and the number of combatants. PC/Console should be no problem with small < 100 combatants. Mobile/Web probably < 20. These numbers are guesses.

I would never use an object as a bullet as the particle system can be co-opted and is designed to work well with lots of fast moving objects.

Truthfully the only way to know is to test it, what is your largest scene with your highest unit count, now double it and test on the lowest spec hardware you will support.

It’s very easy to flip the bullet logic from collision to raycast to dice roll but you will still probably want the particle fx even without the collisions.

And is also a great way to start a range fire!

Not necessarily true. On a 240B (7.62mm round), the tracers are still visible during daytime. They still provide value in theory to others observing your firing pattern to locate the target if they need to. In many conditions, this won’t be necessary, as the chunks of debris and dust kicked up from your round impact will also be a good indicator of where the target is, but in dusty/windy conditions or even light rain, the tracers can be helpful.

2 Likes

Tracers are so that the squad leader and other soldiers can see the firing lines and coverage of their automatic fire, among other reasons. In our M4s, we had 4 tracers at the bottom and then 4+1 ball/tracer to the top. It was easier to count in 5s, and the end of the magazine shouldn’t come as a surprise at a bad time. In combat, you may not be able to see where bullet puffs are, but you can see tracers fairly easily in a larger field of vision. And even the SAW is pretty visible in the daytime except in bright sunlight.

But the 4+1 ball/tracer thing is widespread in military long arms, but not in gangsters’ Tommy guns or police officers with Colt Monitors. As far as game goes, it might be hilarious to have everyone shooting laser beams. But I’d assume you can mock it up and see, I’d be curious if adding tracers to whatever you’re doing would be that much more resource intensive.

1 Like

I think in a game context, fun/helpful/performant should always take precedence over realism. That said, there are a ton of other options besides outright laser tracer beams.

One option would be a highly transparent white line that appears briefly, sort of suggesting a little shockwave or something. Achieves the same effect as the tracer round in a more subtle manner, I’d think. But like others have said, you’ll have to try it out and see what works best.

1 Like