The Han Solo they don't want you to remember:
Ender Wiggin: The dichotomy of goodness and malice, genius and ignorance
In the beginning, Han Solo was dark, apathetic, and filled with greed. His deviance from the traditional selfless hero role adds another dimension to his character. The question posed: can he be trusted? is slow to be answered. The formation of his morality throughout the movie is motivated by the leadership of Luke Skywalker, the archetypical hero of the series. Byronic heroes are well known to struggle with their ego and conscience. Han Solo is slow to discard the notion of every-man-for-himself, but eventually joins the Jedi's cause due to a perceived moral obligation, rather than financial incentives. This serves to reinforce the perceived power of goodness in the force, which through Luke Skywalker, transforms and idealizes Han.
Ender Wiggin constantly reassures himself that he is nothing like Peter. He wishes for Stilson and Bonzo to leave him be, but once triggered, kills them both in self-defense. He weeps after causing such pain to others, yet does what is necessary to prevent further attack. His tactical prowess leads to his merciless acts of self-defense. As he puts it:
I hit him once to win that fight, I kept hitting him to win the rest.
As much as he fights the Peter within him, he eventually gives in to the notion that he though he tries to focus on the Val in him, he has also Peter's ability to kill. His despair breeds apathy, which allows him to be used as the machine they need him to be. In order to defeat the Buggers, Ender must show no mercy...
By the same token, he cheats to win the war game, and again to eliminate the Bugger race as a whole.