Daily news, dev blogs, and stories from Game Developer straight to your inbox
Recreating the time mechanics of Braid (Part 1)
In this first blog post, I present my research findings and say what direction I will be going from here. My goal is to recreate the rewind mechanics of Braid.
February 20, 2013
3 Min Read
Project introduction See Part 2 here
The rewind mechanics of Braid are not entirely unique, but they are few and far between. Prince of Persia: sands of time also used a rewind feature. There are also few time manipulation based flash games, though many of those have a less direct rewind time mechanic.
My first reaction would be to simply save off the state of every object every frame, and then play it all back. The major problem with this solution is the extremely large amount of data that it would require. It would be a good proof of concept and would probably work for a few seconds like in Prince of Persia, but it wouldn't be as powerful as Braid.
Next I searched on the internet to see if someone else has tried to recreate it. The major strategy that came up on many web sites was to make a deterministic engine. The idea behind it is that every action has exactly one outcome. With only one outcome, the actions can also be reversed, and I could save the actions and when they occurred. The problem with this solution is the large amount of designing. It would be very difficult to adapt a full game engine such as Unity into a deterministic engine. I would have to use XNA or a similar language/framework in order to make my own engine in a reasonable amount of time.
Another cool idea that showed up was to make a simulation. The reverse would be as simple as playing the simulation in reverse. It is similar to a deterministic engine except a bit more confusing and a bit less functional.
Eventually I was able to find how Jonathan Blow accomplished the task. Like many other junior programmer, I was a bit disappointed. Instead of some fantastic and complex system, it was simply my first hunch. He saved off relevant pieces of the game state. However, he did an extremely large amount of optimization to make the amount of data manageable.
I will focus on two major optimization to begin with and research what else he did later. The first is only save the state if it changes. This allows for objects that hardly move to use hardly any data instead of everything needing tons of data. The second is only save every few frames and interpoate between the two. This is a trick I probably wouldn't have caught but it is a genious example of the illusion of videogames. It allows the system to save on data by generating during runtime, and most people would not be able to spot the difference.
Now that I have a good direction, I will use Unity at least for prototyping and getting the basic functionality working. I will also add my own little twist and take advantage of the fact that Unity is a 3D engine and make the system in 3D. It will increase the amount of data I need by about 50% due to adding the extra dimension. I can always constrict Unity down to 2D if the data becomes too large.
I don't have much research left to do, so future posts will be all about implementation and polish. This will be a five part series with the fifth being the post mortem.
Read more about:Blogs
You May Also Like
Accessibility and fancy footwork with GLYDR's John Warren - Game Developer Podcast ep. 40Feb 28, 2024
Exploring the 2024 State of the Game Industry report - Game Developer Podcast ep. 39Feb 2, 2024
Phantom inspiration and the ethical auteur with Xalavier Nelson Jr.Dec 8, 2023
Designing Killer Queen: from playground experiment to modern arcade sensationOct 18, 2023
Get daily news, dev blogs, and stories from Game Developer straight to your inbox
Subscribe to Game Developer Newsletters to stay caught up with the latest news, design insights, marketing tips, and more