Here's a novel, common sense idea for someone confronted by police for whatever reason: Shut up and cooperate! Zip your lips, raise your hands if told to do so, and don't try to fight or run because if you do, you'll make yourself look guilty.
And if you make yourself appear to be guilty, guess what? They're going to do their job and arrest you - because their job is protect the rest of us. And if you mouth off or fight, or reach for your weapon and try to run away, they're going to SHOOT you! What do you expect???
Also, if you cooperate, you won't cause riots where those who weren't there won't have to jump to conclusions and automatically make the police look like "the bad guys." We have a police force for a reason: To enforce the law!
This is happening way too often because people mouth off and argue and fight, instead of simply cooperating.