In CS Lewis' Narnia books, as most of you no doubt remember, Lewis presents several stories of Aslan, the great Lion a noble, good and wild Being that represents God in the stories which always involve the good Narnians and humans resolving some problems brought about by evil, in one way or the other.
In one of the books, The Last Battle, the "bad guys" are represented by a greedy and power-hungry ape named Shift who convinces a slow-witted but well-meaning donkey (named Puzzle) to put on a lion skin and pretend to be Aslan. By thus manipulating Puzzle, Shift sets out to deceive Narnians into submitting to Shift's rules, rather than Aslan's. In the process, Shift has the Narnians doing labor for their enemies, the Calormenes (who, it has been suggested, seem to be allegorical Muslems). The Calormenes have their own evil, cruel god named Tash.
A great battle is eventually mounted to end the deception and the enslavement of the Narnians. In the end, of course, Aslan and the Narnians win out over the greed and deception of Shift and the other "bad guys," including the Calormene army.
In the process, we meet one of the Calormene soldiers (Emeth), who seems to be a good-souled person who just happens to believe in Tash, because that is the way he was raised. Still, Emeth has a good heart. His desire is to love and see his god, and to do good and honorably serve in the name of that god.
In the end, when the truth comes out and Aslan wins the day, some of the people in the story go to meet the one true God (in a heaven-like state, apparently). Emeth decides to step through the door to meet the True God, knowing now that he has served the wrong god all his life. Here's a part of the dialog from that part of the story...
Then I fell at his feet and thought, Surely this is the hour of death, for the Lion (who is worthy of all honor) will know that I have served Tash all my days and not him. Nevertheless, it is better to see the Lion and die than to be Tisroc [emperor] of the world and live and not to have seen him. But the Glorious One bent down his golden head and touched my forehead with his tongue and said, "Son, thou art welcome. "
But I said, "Alas, Lord, I am no son of thine but the servant of Tash."
He answered, "Child, all the service thou hast done to Tash, I account as service done to me."
Then by reasons of my great desire for wisdom and understanding, I overcame my fear and questioned the Glorious One and said, "Lord, is it then true, as the Ape said, that thou and Tash are one? "
The Lion growled so that the earth shook (but his wrath was not against me) and said, "It is false. Not because he and I are one, but because we are opposites, I take to me the services which thou hast done to him. For I and he are of such different kinds that no service which is vile can be done to me, and none which is not vile can be done to him."
"Therefore if any man swear by Tash and keep his oath for the oath’s sake, it is by me that he has truly sworn, though he know it not, and it is I who reward him. And if any man do a cruelty in my name, then, though he says the name Aslan, it is Tash whom he serves and by Tash his deed is accepted.
"Dost thou understand, child?"
I said, "Lord, thou knowest how much I understand." But I said also (for the truth constrained me), "Yet I have been seeking Tash all my days."
"Beloved," said the Glorious One, "unless thy desire had been for me thou wouldst not have sought so long and so truly. For all find what they truly seek."
I've always enjoyed the story and respected the logic behind it. There is not "good" done for an evil thing and "good" done for God, as two separate and distinct things. There is not "truth" known about an evil thing and "truth" known about God, as two separate things. There is only Truth, and Goodness, and Love, and Grace and these are ALL OF GOD. In truth, Lewis is stating, anything done of love, goodness, purity, grace, justice, honesty and beauty, all these things are OF God, because they are part of God's nature.
Seems reasonable to me.