Rain World is a game about surviving inside a “chaotic, roiling, alive ecosystem.” You play as a versatile creature known as a slugcat, which exists in the middle of a food chain, both predator and prey.

Its survival loop demands that you set out from your safe spot, find and eat enough food so you can return to hibernation without starving to death, while also avoiding the animals that want to eat you.

However, you have limited time to do this, as the strange planet you’re on suffers from regular, bone-crushing downpours. If you’re outside of a hibernation spot when the weather turns, you’ll die no matter how much food you’ve eaten. Fortunately, there is a “rain clock” that can be brought up that gives an idea of how long you have left until the rains arrive.

But it’s not enough to simply survive in Rain World, as the game’s intro encourages players to set off across the world to reunite the slugcat with its family. Moving across the game’s regions is further incentivized by the scarcity of resources. The more you eat one day, the less there will be during the next, so you have to search around in new areas.

Small beginnings

Programmer Joar Jakobsson began working on the ideas that would evolve into Rain World back in 2011 when he was an exchange student living in Seoul, South Korea. It was at this time that he was poking around with different programming ideas and showing them to a friend. At one point his friend picked one of the ideas out as interesting, and encouraged Jakobsson to pursue it further.

That idea was the procedural animation technique that is used throughout Rain World. “Contrary to the classic Disney style of animation, where you draw every frame and then replay them, what I'm doing is I have a bunch of points in space and I connect them at certain distances,” Jakobsson explains. “So, for example, if you have 10 points connected to each other they are acting as a frame. On top of that I draw what is basically a paper doll, like a thing constructed out of different parts, which go together to make the shape.”

All of the creatures in Rain World are pieced together in this way. It means they are soft and bendable and can navigate pretty much any environment that Jakobsson puts them in. Jakobsson then extended the fluidity of the procedural animation so that it was also found in the behavior of the creatures in the prototype he put together. “Originally I had the idea that it would be the world with only three creatures: the little bat, and the slugcat that eats the bat, and then the lizard which eats the slugcat,” Jakobsson says.

That trinity of creatures proved interesting enough by itself for Jakobsson to start constructing a small world for players to wrestle their way through. It was only after the success of the Kickstarter for Rain World, which raised $63,255 back in 2014, that the game’s scope really blew up. This meant adding more creatures and increasing the size and diversity of the game world for them to inhabit.

Out of control

What makes Rain World different than most other survival and stealth-based games is the AI programming that drives its ecosystems. The rigidity that designers rely on to deliver a specific experience in those genres is mostly absent in Rain World. For example, there are no set patrol paths for the enemy creatures that a player can learn. And if you reload an area, the creatures won’t necessarily be found in the same places.

“Instead of thinking 'how can I make this creature act and serve as an obstacle in the game, I went at it from the angle of 'how can I make this creature behave in such a way that it can find food and move around and get back to its home before the night comes',” says Jakobsson. “So instead of the AI creatures just existing as a player obstacle, they exist in their own right, they exist there for themselves.”

In other words, the creatures in Rain World have an intelligence based on their own survival needs rather than being in service of the player. As level designer James Therrien notes, the creatures exist perpetually in the world, even when they’re out of sight of the player. “So outside of your frame they're all still alive. They're hunting food, they're getting into territorial fights, they're finding new shelters and homes,” Therrien says.

What this AI programming makes for are enemies that can be very difficult to deal with, as they are unpredictable. This encourages the player to be resourceful and to evade enemies instead of confronting them directly. This is the experience that Jakobsson outlined as his goal in the first post of Rain World’s devlog on TIGSource:

“Instead of being easily killable [the enemies] have been made intelligent enough to be interesting opponents in stealth situations,” he writes. “Ironically an entity that is stupid enough can be difficult to outsmart. The goal of the Rain World enemies is the opposite of that, being smart enough to be outwitted.”

What Jakobsson learned about this approach to creating enemies is that it comes with a fee to pay. Not having complete control over the creatures means that the game can churn out situations that are impossible for the player to beat. “If you design an enemy to be fun, it will be fun. Whereas if you design an enemy to care for itself then, that might actually be super difficult and frustrating. Which sorta is the case occasionally in Rain World,” says Jakobsson. Realizing this meant that the team had to come up with ways to help the player deal with the challenge.

Feeling lucky

One system that was introduced to Rain World to help players get used to its tough ecosystems is something called “karma symbols.” It’s a form of scoring system that starts out with five symbols with the player at the lowest one. To go up one symbol, the player needs to survive for a day, but if they die then the symbol goes down by one, which encourages them to survive for as many consecutive days as possible.

“You need to have the symbol at a certain level in order to progress to a new region. This was because if you can just go into a new region, it's very possible for the player to throw themselves into deep water too quickly. They could be lucky, get five regions ahead, and then save, and then be totally out of their element,” Jakobsson says. “So the idea with this is that you need to be in a region and prove that you can actually persistently survive there in order to be allowed to the next region.”

While the karma symbols are mostly used to gate players and stop them rushing ahead, it also rewards skilled players. “If you get to the highest level then you're actually free to move around anywhere until you start dying,” Jakobsson says. “So the idea was to slow down an inexperienced player a little bit while the skilled player would be free to move around as they want.”

However, not everything comes down to skill in Rain World, as luck can also be a big factor due to its AI-driven creatures. Even though the team have spent years constantly running through the game and tweaking it to try to balance difficulty, it still needs further fine tuning. This was demonstrated in the week leading up to the game’s release when a number of streamers got their hands on Rain World for the first time.

“I feel so bad for some of the streamers,” Therrien says. “We had one streamer who opened up the game and the RNG wasn't with her, and it was extremely difficult and it was a bunch of no-win situations she was presented with really early on. And she's just like 'screw this, I'm not playing this game, it's impossible'. And then you'll have another player who'll get into it and the algorithm gives them a pretty clear path at the beginning and they’re like 'this game is pretty cool'. So, yes, dice rolls.”

Taming the animals

The problems caused by the unpredictable creatures are worsened by the fact that some areas in the game require the player to utilize friendlier creatures to bypass an obstacle. It’s sometimes the case that the creature needed to progress decides not to show up when the player needs it.

“We've tried to skew the odds a little bit. So we tried stuff like 'maybe in this general area these creatures are attracted to being here' or maybe 'this creature likes to be in rooms with water', so not everything goes everywhere,” Jakobsson says.

Therrien refers to this as “room attractiveness,” which was a way to keep creatures in a certain territory, but gave them the freedom to go beyond it if they heard or smelled food elsewhere. “So there's a bit of that, but we wanted to maintain the chaos of the game, because we found that as soon as we were too restrictive about where the creatures went, then it just turned into a basic platformer,” Therrien says. “You had this big, wild ecosystem that was just now a room obstacle, which was 100 percent what we didn't wanna do.”

The one thing that the team did have control over is the world and environment design. It ended up being this that helped out the most with trying to contain and influence the creatures without compromising the fluidity of the ecosystems. In some cases it would literally be a case of changing the height of a wall, so that instead of being five tiles high it was six tiles high.

“A lot of it was a process of iteration where we would see how these creatures would move through the environments,” says Therrien. “I'd run a region maybe 15 or 20 times and get a sense of where the trouble points would be, how far creatures could go to in a certain amount of time. And then it would be a lot of placing little obstacles in those creatures' ways that would either stop the AI pathfinding, or things like that.”

You can get a sense of the scale of such an undertaking by looking at the numbers behind Rain World. Its 2D world is divided into 12 distinct regions (which all have sub-regions), and spans around 1600 individual rooms in total. Plus, most of the rooms offer several routes through them, either along the ground, through ventspaces, or across the top on pipework.

“I was hoping to create parkour-ish situations where you enter a room and see the exit, and there are multiple routes you can take to get to where you need to go, and it's enough of a variation that you can avoid a creature, or if something's blocking your path you can move around it, or if you have an object you can sort of use that to your advantage,” Therrien says.

While all these routes helped players escape death it meant even more work as the various creatures throughout each region have different movement abilities. It might happen that when Therrien was trying to block one creature from advancing through an area it would open up the possibility for another species to slide on through.

Maze runner

The point is that the team ended up creating a labyrinth to help the survivability of players. But that opened up problems around navigation. With so many possible routes to take and with the world being so vast, it’s easy for players to get lost. This wasn’t ideal at the start of game, especially as players are still trying to get used to dealing with the hostile creatures pursuing them relentlessly. This led to the team adding in ways to offer a bit of direction at the start of the game.

“Initially, we really wanted there to be no guiding. The whole point was that you had to figure everything out. We didn't want to have any tutorialization,” Therrien says. “We wanted it to be something where you have to experiment and then hopefully you discover interesting things and that completely changes your method of playing. Kinda like the opposite of the metroidvania where you get keys and things to open up access to different regions. We wanted something where you just discover a new gameplay mechanic kinda by accident and all of a sudden other branches of the game open up to you.”

But it became clear in testing that giving players no guidance at all wasn’t going to work. So a compromise was found. The first screens of the game now contain snippets of text that tell the player to find food and to hibernate before the rains come. There’s also a small holographic creature that guides the player towards food and safety, warns them of dangers, and also leads towards one of the game’s first story beats.

These small bits of guidance were one of the last parts of the balancing act required to tip the odds in the player’s favor. “We put it at the level we think is sorta good because we wanted to give you a little bit of a breadcrumb trail but we don't want to just set you off in the exact direction without any hesitation or doubt,” says Therrien.

Now that Rain World is out, Jakobsson and Therrien are taking as much feedback as possible, and observing as many new players as they can. They’re highly aware that the game’s balance still isn’t where it needs to be but they hope to get it at that sweet spot.