Obito pretty much is the the anti naruto which is hope Obito fell into despair and gave up
i think he might have had an idea, but at the kakashi gaiden chapters it was decided.
He was planned since the beginning because kakashi had the left eye and he had the right eye
Obitos first appearance was in chapter 16 Titled who are you
You must be registered for see links
So are gaara, nagato and sasuke.