How to make a rhythm game in Unreal engine

Table of Contents

There’s something really satisfying with playing a game to the rhythm of a great soundtrack, so much so that that has been entrancing people for some time now.

These kinds of games aren’t new. Games like Guitar Hero, Rock Band and Just Dance are some of the classics in the genre, making you follow the beats and notes in order to complete missions and earn points.

The main difference today is that rhythm can be blended with other genres in order to create a more satisfying experience.

There is Beat Saber, a VR game in which you slash blocks that come your way using light sabers, Geometry Dash, which mixes rhythm with the platformer genre, Beat Hazard, which puts you in an Asteroids-like game powered by your favorite songs, Crypt of the NecroDancer, a rhythm rogue-like, and many more out there.

With this explosion of rhythm games out there, many people get inspired to make their own and bring something new to the genre. And a good way to do so is by using the Unreal Engine, a fully-featured, high-quality engine that’s easily available to use.

This works better if you’re already familiar with the engine. If you’re still unsure of what you’ll use, consider reading our comparison between Unreal and Unity, another fully-featured engine.

What is a rhythm game?

A rhythm game is a type of video game that tests players’ ability to keep up with specific rhythms. One of the most popular rhythm game is Dance Dance Revolution, which involves arrows that scroll from the top of the screen and require directional input from players at certain cues. These cues indicate when each arrow should be stepped on by making one or more inputs with the feet in a certain direction.

Other common rhythm games involve instruments such as guitars and drums, and sometimes even require singing or rapping. The main goal of all these games is to match the beats and melodies accurately while trying to gain higher scores than other players. In addition to providing entertainment, rhythm games can also help improve coordination and timing skills for players who practice regularly.

How to make a rhythm game In Unreal Engine: a short guide

The Unreal Engine tends to be seen as a bit of an advanced engine. And that has some truth to it: it features many kinds of visual and sound effects out of the box and can reach photo-realistic quality really easily. However, it’s also very flexible, meaning you can use it for many kinds of visual styles.

If you’re already familiar with the engine, then adapting it for a rhythm game can be simple, depending on your knowledge of the engine and music, and we’ll describe some ways to do so in the following steps.

What you need to know

Playing around with rhythm can be tough. In order for the game to be realistic about rhythm, you need to be able to extract the information you need from the songs that will be playing along.

There are multiple ways to do this, and which one to choose will depend on what you want for the game, your knowledge of music and programming, and how much time you’re willing to spend on this aspect of your game.

The simple DIY approach

The simplest way to keep track of rhythm is to take advantage of the song’s BPM. BPM, meaning beats per minute, is, as the name implies, the average number of beats per minute in the song. If your game will rely only on beats, that is a simple way to keep track of them.

Basically, you can just time game events and player events based on the BPM of the current song. If you calculate 60/BPM, you can get a more useful quantity: the number of seconds between each beat.

So you can make events happen once every such second. Adding a bit of leeway can also be helpful in order not to make this too frustrating for the player, for example, if it can grant them a power-up.

Bear in mind, though, that that method may not be completely accurate, as the BPM may change throughout the song. 

This way, you also won’t be able to keep track of other notes and other information about the music too. 

It’s the simplest way but can miss a lot of stuff that could be very useful for your game.

The advanced DIY approach

A song file is pretty much a digital version of a huge amount of waves superposed over one another. Some of those waves come from vocals, others from keyboards, and others from guitars, drums, etc. Just plug the song file into Audacity and you’ll see what I mean.

While that bundle of waves may look like a mess, when you listen to it, you may notice that you’re able to isolate each instrument pretty well. All of the musical information is still there, so you can also extract it using a program.

The way to do so is by using filters. Filters allow you to isolate waves based on frequency ranges and amplitude. This way, you can extract beats and notes from different instruments, and you can also tweak the filters to give you the exact time ranges you’re looking for.

Using this, you can use pretty much any information from a song and apply it to your rhythm game!

Using a plugin

The fastest way, however, is to find a plugin for the Unreal Engine which feeds you all the information you need.

This is the fastest and most reliable way, as not only you don’t need to worry about implementing and testing your own, but it’s also more battle tested and used by many other people.

One possible plugin is AudioAnalyzer. AudioAnalyzer provides a fully-featured analyzer for songs, which you can use to keep track of beats and notes in your rhythm game. The plugin’s developer, ParallelCube, also supplies a simple 3-part tutorial on how you can use it to make a rhythm game.

Coming at about $34,99, it may be a bit of an investment, but it can also be a great time saver if you’re just looking to dive into game development instead of spending a lot of time on this part of the engine.

two teenagers playing guitar hero

We can make your rhythm

You could also just save a lot more time and leave the development step for us.

Here at MainLeaf, we’re a team of experienced game developers which specializes in making tailor-suited games on demand. You ask we make it.

Hit that button on the top of the page and get a quote! This way, we can get to work on making your dream game.

Do you want to create your own game? Let us help.
Click the button below to request a quote for your game
Testimonials
Subscribe for Blog News

Get in touch!

CONTACT US

GAME CALCULATOR SPREADSHEET

Please fill your email below to download your Game Calculator Spreadsheet.