Yeah, this is absolutely true. I think a lot of people forget this when they're sitting at home judging the actions of the police. It's impossible to imagine how stressful these situations must be if you haven't been in them.
I actually saw some footage of the incident today and it's much more complex than it first appeared. The kid didn't have a weapon at the point he was shot, but it's very likely the officer didn't know he'd gotten rid of it.