At Jesus’ baptism, the Holy Spirit descended upon Him. Matthew 3:16 says, “And Jesus, when he was baptized, went up straightway out of the water: and, lo, the heavens were opened unto him, and he saw the Spirit of God descending like a dove, and lighting upon him. (cf Mark 1:10 and John 1:32)
He was in John the Baptist when Mary was still carrying Jesus in pregnancy. Lu 1:41 And it came to pass, that, when Elisabeth heard the salutation of Mary, the babe leaped in her womb; and Elisabeth was filled with the Holy Ghost. (Luke 1:15)
He was in Simeon when Jesus was a visiting the temple as an infant. Luke 2:25-26 says, “And, behold, there was a man in Jerusalem, whose name was Simeon; and the same man was just and devout, waiting for the consolation of Israel: and the Holy Ghost was upon him. And it was revealed unto him by the Holy Ghost, that he should not see death, before he had seen the Lord’s Christ.
Jesus was filled with the Spirit when going into the wilderness. Luke 4:1 says, “And Jesus being full of the Holy Ghost returned from Jordan, and was led by the Spirit into the wilderness.”
If the Holy Spirit was around while Jesus was on earth, why does Jesus’ say in John 16:7 that the Holy Spirit would not come if He did not depart.
The Holy Spirit was in the world and working in lives before and during the time of Jesus. However, only after Jesus left did the Holy Spirit take on the additional role of Comforter to the church, which did not exist prior to Jesus building it.