To me, that sounded an awful lot like judgement is based on works, which doesn't jive with other Scripture indicating faith as the basis of salvation. Why did Jesus state it this way?
Then, I think my question was answered in Luke 6: "No good tree bears bad fruit, nor does a bad tree bear good fruit. Each tree is recognized by its own fruit. ... The good man brings good things out of the good stored up in his heart, and the evil man brings evil things out of the evil stored up in his heart."
Faith will produce works.
This also raises the issue of works of nonbelievers seeming "good," but ultimately not being altruistic. I'll leave that for another day.