"Now there comes a time, Vasettha, when after a long period of time this world expands. When the world expands beings
for the most part fall from the realm of Radiance and come here; and they exist made of mind, feeding on joy, self-luminous, moving through the air, constantly beautiful; thus they remain for a long, long time. Now at that time, all had become one world of water dark, and of darkness that maketh blind. No moon nor sun appeared no stars were seen, nor constellations, neither was night manifest nor day, neither months nor half-months, neither years nor seasons, neither female nor male. Beings were reckoned just as beings only. And to those beings, Vasettha, sooner or later after a long time, earth with its savors was spread out in the waters. Even as a scum forms on the surface of boiled milky rice that is cooling, so did the earth appear. ~ Aganna Sutta"
Even so, questions regarding the origins of the world and such were not considered important by the Buddha and not made out to be a big deal as in other religions. In a famous story, a man called Malunkyaputta approached the Buddha and demanded that the Buddha explain the origin of the universe before he would become a disciple of the Buddha. Then the Buddha said that he would not go into a discussion of the origin of the Universe. To him, gaining knowledge about such matters was a waste of time because a man's immediate problem was his own suffering and his task was to liberate himself from the present state of affairs. To illustrate this, the Buddha related the parable of a man who was shot by a poisoned arrow. This foolish man refused to have the arrow removed until he was told who shot the arrow, what he looks like, the kind of wood the arrow was made of and so on. The Buddha said that before the man could learn such information, he would be dead. Similarly, our immediate task is to be enlightened, not to speculate about the metaphysical. Thus, the Buddha's teachings centre around mankind and emphasises the methods by which he can liberate himself. These teachings are encapsulated in the Four Noble Truths.