You’ve probably seen the psychedelic, CRT-filtered madness of Balatro by now. It’s that poker-themed roguelike that basically took over the internet, selling millions of copies and making everyone obsessed with "Mult" triggers and lucky 7s. But for the nerds and curious players among us, there’s a weirder question under the hood. What is Balatro made in?
Most people just assume it’s another Unity or Godot game. It looks polished, runs on everything from a Steam Deck to an iPhone, and handles complex math without breaking a sweat.
The reality is way cooler. It wasn't built in a massive corporate engine. It was built by a solo developer named LocalThunk using a framework that most big studios wouldn't touch for a commercial release.
The Core Engine: It’s All About LÖVE
Honestly, the answer is a bit poetic. Balatro is made in LÖVE (also known as Love2D).
If you aren't a programmer, you’ve probably never heard of it. LÖVE isn't an "engine" in the way Unreal is—there's no 3D editor where you drag and drop trees or light sources. It’s a framework. Basically, it’s a collection of tools that let you talk to your computer’s graphics card and speakers using a programming language called Lua.
LocalThunk wrote the game almost entirely in code. No fancy visual editors. Just a text editor and a lot of math.
Why Lua?
Lua is a "scripting" language. It’s famous for being fast, tiny, and incredibly easy to embed in other things. You’ve actually probably played games that use Lua without knowing it—World of Warcraft uses it for its UI, and Roblox is essentially built on a version of it.
In Balatro, Lua handles everything:
- The logic that calculates your score (which can get into the trillions).
- The way Jokers interact with each other.
- The RNG (random number generation) that decides if your Wheel of Fortune actually hits or just says "Nope!"
Because Lua is so flexible, LocalThunk could iterate fast. In interviews, he’s mentioned that he isn't even a "poker guy." He just liked the aesthetic. Using a lightweight framework like LÖVE allowed him to experiment with weird mechanics—like Jokers that gain permanent value—without fighting against a heavy engine’s built-in rules.
The Secret Sauce: Shaders and "The Vibe"
If you’ve played the game, you know the background looks like a melting 90s screensaver. It’s wavy, colorful, and slightly hypnotic. That isn't a video file playing in the background.
What is Balatro made in to get that look? GLSL (OpenGL Shading Language).
LocalThunk used custom shaders to create the CRT effect, the burning fire on the score numbers, and the warping backgrounds. Shaders are essentially small programs that run directly on your GPU. They are notoriously difficult to write because they require a lot of linear algebra and "math-brain," but they are incredibly efficient.
This is why Balatro can run on a potato. Since the heavy lifting for the visuals is handled by the GPU through these shaders, the CPU is free to crunch the numbers for your 15-joker combo.
How it Ended Up on Consoles
This is where things get tricky. Love2D is amazing for PC, Mac, and Linux. But it doesn't "officially" support PlayStation, Xbox, or Nintendo Switch.
So how did a solo dev get a Lua-based game onto the Nintendo eShop?
Basically, they had to "port" the framework. While LocalThunk handled the game's soul and code, the publisher (Playstack) helped bring in experts to wrap that Lua code into something consoles could understand. They use a wrapper—essentially a translator—that takes the LÖVE commands and tells the Switch or PS5 how to execute them.
It’s a massive technical achievement for a game that started as a hobby project in December 2021.
The "Programming Horror" of Balatro
Once the game blew up, some people poked around the source code. In the world of "clean code" and professional software engineering, Balatro is... unique.
There’s a legendary (and very long) if-else chain in the code that checks for every single Joker in the game. Most "proper" programmers would say you should use a dictionary or an object-oriented approach.
But here’s the thing: it doesn't matter.
LocalThunk’s "messy" code works perfectly. It’s a reminder that players don't care if your code is elegant; they care if the game is fun. The fact that the game was made in a simple framework allowed him to prioritize the "feel" over technical perfection.
Actionable Takeaways for Aspiring Devs
If you're looking at Balatro and thinking, "I want to make the next indie hit," here is the actual path LocalThunk took:
- Start Small: He didn't build a 3D RPG. He built a card game.
- Pick a Simple Tool: Love2D is free and open-source. You can download it right now and have a "Hello World" on your screen in five minutes.
- Learn Lua: It’s one of the friendliest languages for beginners. It reads almost like English.
- Focus on the Feedback Loop: LocalThunk spent years tweaking the balance based on how it felt to play, not just what the math said.
The biggest lesson? You don't need a million-dollar engine to make a million-dollar game. You just need a good idea, a text editor, and a little bit of LÖVE.
To see the engine in action or start your own project, check out the LÖVE 2D official site or dive into the Balatro community wiki to see the sheer complexity of the math that Lua is handling behind the scenes.