Dr. Schlock is a rather
enigmatic character - everything about his
personality is
evil, but his work always ends up benefiting the cause of
good (not counting the
animal testing he did in the beginning). Schlock is constantly
scheming, trying to
weasel out of situations, and doing whatever he thinks would benefit him (and only him) in the
long term, but these effects tend to be cancelled out by the fact that he is such a
coward. When faced with the choice of
saving the world from a deadly virus or having to face a very angry
Sam the
vampire, he quite reluctantly saves the world.
Part of the reason he ends up on the side of good is that he seeks revenge on Dr. Crabtree, who manages to be many times more evil than Schlock, for eating the brains of his other self. Also, he vaguely realizes that if he doesn't change things for the better, he will eventually end up facing the same future he came from, which sucked enough the first time around.
And, of course, if all else fails, there is the mortal fear of Bun-Bun to keep him in check.