Skip to main content
This guide will walk you through the complete process of compiling Friday Night Funkin’ from source code. Make sure to follow each step carefully to avoid compilation errors.
Do NOT download the repository using the Download ZIP button on GitHub or you may run into errors! Use Git clone instead.

Prerequisites

Before you begin, you’ll need to install the following tools:
  • Haxe - The programming language and compiler
  • Git - Version control system

Initial Setup

1

Navigate to your desired directory

Open a command prompt and navigate to the folder where you want the source code:
cd C:\Users\YOURNAME\Documents
Replace the path with your preferred location.
2

Clone the repository

Clone the base repository using Git:
git clone https://github.com/FunkinCrew/funkin.git
3

Enter the repository directory

cd funkin
4

Download game assets

Download the game’s proprietary assets as a submodule:
git submodule update --init --recursive
By performing this operation, you are downloading Content which is proprietary and protected by national and international copyright and trademark laws. See the LICENSE.md file for Funkin.assets for more information.
5

Install hmm (Haxe Module Manager)

Install hmm globally and set it up:
haxelib --global install hmm
haxelib --global run hmm setup
6

Install Haxe libraries

Install all required Haxe libraries for the current branch:
hmm install
If you have issues installing Lime, try using Funkin’s patched libraries:
haxelib --global git haxelib https://github.com/FunkinCrew/haxelib.git
haxelib --global git hmm https://github.com/FunkinCrew/hmm.git
7

Set up Lime

Configure Lime for your system:
haxelib run lime setup

Platform-Specific Setup

Windows Requirements

Download and install the Visual Studio Build Tools.When prompted, select Individual Components and make sure to download:
  • MSVC v143 VS 2022 C++ x64/x86 build tools
  • Windows 10/11 SDK

Building the Game

1

Rebuild Lime binaries (Native only)

If you are targeting native platforms, rebuild Lime for your platform:
lime rebuild windows
lime rebuild windows -debug
2

Build and run the game

Build and launch the game for your platform:
lime test windows

Build Flags

You can customize your build with various flags. Add them after your build command:
lime test windows -debug -DGITHUB_BUILD

Debug and Development Flags

Builds the game in debug mode with:
  • In-game debug functions enabled
  • Disabled compile-time optimizations
  • Asset redirection enabled
  • VSCode debug server enabled (may slow the game)
lime test windows -debug
Enables in-game debug functions (like time travel with PgUp/PgDn) without other debug features:
lime test windows -DGITHUB_BUILD
Forces the game to load assets from the project’s assets folder rather than the exported folder. Great for fast iteration:
lime test windows -debug -DREDIRECT_ASSETS_FOLDER
The game will break if you try to distribute it with this flag enabled.

Feature Flags

Enable: -DFEATURE_POLYMOD_MODS
Disable: -DNO_FEATURE_POLYMOD_MODS
Controls whether the game loads mods from the ./mods folder.
Enable: -DFEATURE_DISCORD_RPC
Disable: -DNO_FEATURE_DISCORD_RPC
Controls Discord integration for status updates.
Enable: -DFEATURE_VIDEO_PLAYBACK
Disable: -DNO_FEATURE_VIDEO_PLAYBACK
Controls support for video cutscenes.
Enable: -DFEATURE_SCREENSHOTS
Disable: -DNO_FEATURE_SCREENSHOTS
Controls the screenshot feature.
Enable: -DFEATURE_CHART_EDITOR
Disable: -DNO_FEATURE_CHART_EDITOR
Controls access to the chart editor in the Debug menu.
Enable: -DFEATURE_STAGE_EDITOREnables the experimental stage editor.
Enable: -DFEATURE_GHOST_TAPPINGEnables experimental gameplay changes to the anti-mash system.

Next Steps

Mac Compilation

Additional considerations for Mac builds

Mobile Compilation

Android and iOS compilation guides

Troubleshooting

Fix common compilation issues

Contributing

Learn how to contribute code

Troubleshooting

If you experience any issues during compilation, check the Troubleshooting Guide for solutions to common problems.
DO NOT open an issue on GitHub for compilation problems without first consulting the troubleshooting guide.

Build docs developers (and LLMs) love