Decode()

7 Day RogueLike 2021 Game Jam Submission


My Role

I worked as the Game Designer and Main Programmer.
My main tasks were:

  • Design the concept, core loop and main mechanics.
  • Implement in Unity3D and C# the roguelike loop and combat mechanics.
  • Design the levels and progression.
  • Build and publish the game on itch.io


The Game

UNITY 3D / C#

TECHNOLOGY

1

TEAM SIZE

7

DEV. TIME (DAYS)

WEB

PLATFORM

Features

  • Simple roguelike, i.e.:
    • Procedurally generated levels
    • Permanent death
    • Simple graphics reminiscent of the original Rogue game.
  • Space theme.
  • Innovative "combat" system based on hacking computers.

Goals

  • Learn about Roguelikes, their complexities and challenges.
  • Create a new portfolio piece.
  • Link this project with a bigger concept to be developed in the future.

Constraints / Risks

  • 1 week development
  • Solo developer
  • No prior experience and limited knowledge of the roguelike genre.



Key Design Points

Hacking Based "Combat"





Mission: Find a combat replacement that fits the space/hacking theme I chose.

Following one of the main goals, this game is meant to be the starting point of a bigger project that would contain various different games in the future.

This defined the space theme and also added the hacking component. These constraints helped create a different type of combat system where the player needs to hack the computers in order to defeat them.


Strategy:

In this combat system each computer has a level of vulnerability (replacing an enemy's health) and a defense (that could be a firewall of some sort).

The player attacks with hacking attempts using a system that is lightly base in Dungeons & Dragons:

  • Each computer has a defense attribute (armor class) and a total vulnerability (hit points)
  • The player has an attack chance that is defined by a sort of die roll. Random number between 1 and 20.
  • If the attack chance is higher than the enemy computer's defense attribute, the attack hits.
  • If the attack hits, the player rolls their attack die, choosing a random number between the parameters minimum attack and maximum attack (defined by the player's current hacking level).
  • The randomly chosen number is then taken from the computer's vulnerability.
  • Repeat all steps until the computer's vulnerability reaches 0.

Each victory gives the player hacking experience and a reward. There are various types of computers with different rewards.

  • Code cracking computers: when defeated grant the player a code that opens doors in the level.
  • Beneficial computers: when defeated always give the player an upgrade or positive effect.
  • Negative computers: when defeated always give the player a downgrade or negative effect.
  • Random computers: when defeated can grant a positive or negative effect chosen at random.
  • All computers reward "hacking experience" when defeated.

Code Locked Doors


Mission: How to link the hacking mechanic with the level navigation?

Create a navigation system that fits the main mechanic: hacking.


Strategy:

To add further meaning to the hacking mechanic, I decided to link the level navigation to the hacking rewards.

Each room has a defined amount of doors leading to other rooms to explore. Each room is linked to the next via a hallway and a code locked door.

In order to explore all the rooms, the player needs to crack all the codes available.

Just like in the original Rogue, exploring all the available rooms is not a requirement to find the elevator that takes you to the next floor. However, it is expected that the player feels the curiosity to uncover all the darkened rooms before leaving the floor.

The fact that computers were spawned at random rooms as part of the procedural generation of each floor, represented a technical implementation challenge that borrowed some of its complexity from Operations Research when we faced the problem of "computer A" being spawned in a room that could only be reached by opening doors requiring the very same code that "computer A" rewarded. See more in the Technical Achievements section.


Finite Resources





Mission: Define a resource the player has to care for and that can trigger a game over.

Given that the combat system designed prevented the enemies from taking health from the player, a new finite resource had to be added.


Strategy:

Decode() is about an astronaut fulfilling a special mission: activating an important computer at the deepest section of a heavily damaged Spaceship.

Computers are passive and waiting to be hacked, however the game needs a defeat condition. So the space suit autonomy was added.

I had recently finished playing the awesome game Outer Wilds, so the survival characteristics of space travel were very fresh in my memory. And my creativity took advantage of it.

The player has a finite amount of suit autonomy. If they run out of it, they die.


Therefore, the goal goes from:

  • Reach the deepest room in the spaceship and activate the last computer.
  • to...
  • Reach the deepest room in the spaceship and activate the last computer before running out of autonomy.

Autonomy lowers every step the character takes, every time a hacking attack misses and as part of the negative rewards a computer can give.

Total autonomy increases every time the player increases their hacking experience level.

Adding this mechanic gives the game a little touch of strategy as it prevents the player from crazily hacking all and every computer they find. They need to start being conscious about their autonomy and try to avoid negative effects or unnecessary interactions. They also need to search for the most efficient route to avoid unnecessary steps.


Difficulty Progression


Mission: Create a progression system using the elements already designed.

How to make the higher floors more and more challenging?


Strategy:

To increase difficulty on the higher floors the following elements were tuned accordingly:

  • Amount of codes needed to explore all the rooms
  • Defense and total vulnerability for computers that contained the more advanced codes

Thought process behind these choice:

  • A more defensive and less vulnerable computer meant that the player would require more turns to defeat it, spending more autonomy in each encounter.
  • Requiring more colors to explore the whole floor meant that the player would be forced to hack more computers (trigger the previous point) but also gave a higher chance for the elevator to be more hidden than usual.

These changes were play tested to ensure that, even though the player would arrive at the higher floors with a higher level and therefore more total autonomy, the computers should represent a challenge anyway.

This is a topic that could not be deeply explored within the Game Jam's time frame so more balancing and tuning is definitely needed.




Technical Achievements




  • Procedural generation:
    • Generated a grid based layout with n x m tiles available to create rooms. The algorithm ensures that every row has the same total length with different sized rooms inside it.
    • Generate an algorithm that linked the previously spawned rooms via hallways taking into consideration the rooms alignment and common tiles in the grid (avoiding hallways going nowhere).
    • Generated a hallway coloring algorithm that considered each floor's required codes (code = color) and supported "hidden" rooms that were surrounded by doors of the same special color.
    • Generated a path finding algorithm that starts from the "initial room" and simulates the possible paths the player can take with the accessible codes. This ensures the spawning of code cracking computers within the range of other known codes and avoids isolated computers.
  • Generated an on-screen text based dialogue management system that waits for the player's input before showing the rest of the text. The system acknowledges the maximum UI space available preventing overflow. It was inspired by the old school text adventure games.
  • Created a battle system that uses a simplified version of Dungeons & Dragons combat system.



Main Takeaways




  • Thanks to my participation in this Game Jam I got to learn and understand a lot about the roguelike and roguelite genre and truly appreciate their beauty and complexity.
  • The game is incredibly simple in terms of art and sound, but technically it was an important challenge and many systems and lessons emanated from its creation.
  • As planned, Decode() is the starting point for a bigger project involving more games taking place in the same common universe.