You had roving eyes. While eating and conversing with your friends you were also looking around noticing things.
Most people could look across a table at their friend and not notice the person behind the friend standing up and drawing a gun. Their focus is narrow - like the person walking to their car.
You noticed the individuals because 1. You were looking 2. They were not acting like a normal person and 3. Once you noticed you looked closer.
That can be learned - but the person has to want to.
It’s difficult to get people to be aware these days, especially if they need to put effort into it & learn a new ways of being. I live right outside a major metro area & when I go downtown & see people on their various devices in public...I just can’t understand it.