Can fly's smell their own festering death

I ask this in total seriousness, and hope someone in the field of fly’s will give me a scientific answer.

So my little doggy likes to poop outside, attracting lots of pestering little fly’s, that eventually make their way into my house.

Oddly, it seems that the minute I sit down to do some work, or while I am sleeping, these fly’s love to come and buzz the old radio tower, very annoying. And persistant they are, non stop bombardment, you can shoo them and they just keep coming back for more.

So I go grab the trusty fly swatter, and one of 2 things happen, I swat at one, and he gets the hint, and goes into hiding, or somehow, like magic, before I even swat at them, they go into hiding.

So is it that they can smell their dead buddies on the swatter and go run for cover, is it the first swat that sort of sends some fear into them and they go running, is there some trick that I can use to get these little bastards.

Right now, I am waiting for this one particularly unruly booger to come out of hiding, at which point I am going to capture him, freeze him just enough to slow him down, and attach a thin piece of thread to him with crazy glue, so I can put him on a leash, this should prove for great amusement at this hour. Yes!, this is what it has come to, an all out war.

They see you coming from a mile away… and if they’re smart they get the point - if not, they are culled from the gene pool.