The king wanted Siddhartha to become a great ruler so he created a plan for Siddhartha to never see anything that would cause negative emotions and make Siddhartha want to teach.
Your son will either become a great ruler or a great teacher.
I will not let him become a great teacher.
Siddhartha was surrounded by luxury and comfort. He was always wearing the finest clothes and did not leave the city walls. He married someone and had a son.
This is the life.
One day, Siddhartha went beyond the castle garden and for the first time, he saw an old person, a sick person, and a dead person. He finally saw human suffering, and he was disturbed and decided to leave his life behind to find a way to end suffering.
*Cough cough*
Hello young boy
*Dead*
Huh?
After 6 years of looking for answers with Hindu scholars, he decided he would sit down under a tree and would not move until he found the mystery of life.
I will stay here until I find the mystery of life.
48 days later..
After 48 days, a understanding on how to end suffering and sorrow. When he stood up, he was now Buddha, the "Awakened One"
I am no longer Siddhartha, but Buddha.
Buddha wanted to share this knowledge with other, so he became a teacher. In the end, the prophet was right and Buddha became a good teacher whose beliefs spread all across the world.