Trying to replicate the wonder and magnitude of an entire universe in a video game is a tall order.

But Hello Games, the team behind the upcoming PS4 and PC title "No Man's Sky," which is scheduled for release this year, is doing the best it can — and so far, it looks spectacular.

A huge secret behind the realism is a fascinating biological algorithm that's been described as a scientific "Superformula." Relying on this and other math to generate star systems and worlds, they've created an immersive cosmos full of unique planets and animals unlike anything we've ever seen.

It looks like a space adventure straight out of our imaginations, capturing the sense of wonder that you might have felt as a kid after first seeing "Star Wars," then staring up at the night sky, wondering what it'd be like to explore billions and billions of worlds.

There are a ton of details that we still don't know, but we do know players will start on a random planet at the edge of a galaxy, and then explore their way — planet by planet — towards the center.

In May, the New Yorker's Raffi Khatchadourian took readers on a tour of the universe Hello Games has created so far, with a focus on how they're building it.

So how do you make a universe?

There are more than eighteen quintillion planets in the game, each with its own ecosystem and perhaps, wildlife.

That's 18,446,744,073,709,551,616 worlds. It's a huge number, but let's focus on what's actually important: the way they are generating unique worlds and populating them with fantastic creatures, because that's the thing that's really amazing.

The imagery in the original trailer was incredible enough — if you somehow haven't seen it yet (and as my colleague Dave Smith has pointed out, even if you have), take a look:

Pretty cool, right? Khatchadourian writes that "The arc of [Hello Games co-founder Sean] Murray's journey — the unbroken sweep from ocean to land to heavens — implied an unprecedented range of possible discovery."

The writer captured even more on his trip to the company's studio, about an hour outside of London.

Here's how he describes one of his experiences with the game:

Murray is known for nervously hovering during demos. “I’ll walk around a little, then I’ll let you have the controller for a bit,” he said. I watched as he traversed a field of orange grass, passing cyan ferns and indigo shrubs, down to a lagoon inhabited by dinosaurs and antelope. After three planets and five minutes, he handed me the controller, leaving me in a brilliantly colored dreamscape, with crystal formations, viridescent and sapphire, scattered in clusters on arid earth. Single-leaf flora the height of redwoods swayed like seaweed. I wandered over hills and came to a sea the color of lava and waded in. The sea was devoid of life. With the press of a button, I activated a jet pack and popped into the air. Fog hung across the sea, and Murray pointed to the hazy outline of distant cliffs. “There are some sort of caves over there,” he said, and I headed for them. The No Man’s Sky cosmos was shaped by an ideal form of wildness—mathematical noise—and the caves were as uncharted as any material caves. I climbed into one of them. “Let’s see how big it is,” Murray said.

The cave’s interior was rendered in blues, greens, purples, and browns, and the light filled it with warmth. Luminescent bits of matter, like inanimate fireflies, filled the air.

There are about a dozen people working on No Man's Sky, according to Khatchadourian. That's tiny compared to the hundreds who might work on a title for a big studio. But even with hundreds, you couldn't hand-code an entire universe.

Instead, Hello Games relies on something known as procedural generation, where mathematical algorithms provide the rules that give the universe its structure — the universal laws for how everything works.

Procedurally generated worlds aren't a new concept; they existed in older games like Elite, seen below:

But there's a problem with many of these worlds. It's really hard to find equations that will create a natural feel. They're either overly monotonous — "imagine a row of more or less identical trees, stretching to infinity," writes Khatchadourian — or too chaotic to make any sense.

Losing a sense of realistic infinity and complexity of a universe might yank players out of the game. So Murray came up with a basic mathematical architecture to make it convincing.

Instead of hard-coding the layout of his universe, Murray left that work to what's probably best approximated as a random number generator, i.e. software to automatically build the structure of the galaxy, stars, planets, the chance a planet might have an atmosphere or life.

"The system combines entropy and structure," writes Khatchadourian.

Even then, the equations the team came up with were either too wild and random — or too repetitive and boring. So they turned to biology for help.

In 2003, a plant geneticist from Belgium named John Gielis discovered an equation that can describe an incredibly large number of natural shapes, including "the contours of diatoms, starfish, spiderwebs, shells, snowflakes, crystals," and more, according to Khatchadourian.

Gielis called it the "Superformula." According to Nature, it's "a modified version of the equation for a circle."

"When I found the formula, all these beautiful shapes came rolling out of my computer," Gielis told Nature. "It seemed too good to be true — I spent two years thinking 'What did I do wrong?' and 'How come no one else has discovered it?'"

When Murray and the rest of the team plugged the Superformula into the game, it worked. Things that didn't have natural variety all of a sudden took on varied but still possible shapes. It was what they needed, or at least a major part of it.

That's not the only place they took inspiration. After seeing "Interstellar," Murray was impressed by the "very perfect 'mathlike' terrain" of a planet in the film, so they incorporated that math into the design, too.

The team had to make some unnatural changes, though. Some things, like flying a spaceship out of an atmosphere, felt more fun when tweaked to be less realistic, and so concessions to realism were made in the name of enjoyment.

No Man's Sky isn't finished yet, and we don't know exactly what it will be like. But that exploration process, with a random start and journey towards the center of the universe — with incredible creatures and diverse worlds explored along the way — sounds something like many of us have always wanted to do.

There's also this: Hello Games' new cosmos is so vast — basically, as big as players have time to explore — that the company doesn't even know what's out there in the their own universe. Many planets will be lifeless, but a few will have complex life, of some form or another. They currently have an artificial intelligence-powered "drone" traveling from world to world in the game, examining and photographing their creations.

And as for what's at the center, who knows? But this digital universe looks beautiful and intriguing enough that we want to find out.

Here's a video put together by the New Yorker on what we know about the game so far.

Check out the full New Yorker story for far more about the game itself and the journey to make it happen.