-
-
Notifications
You must be signed in to change notification settings - Fork 50
Adding Songs
This tutorial will teach you how to add a custom song to the Freeplay Menu.
To create a new song in your files, head to \ProjectFNF\assets\songs\
, this folder should have a bunch folders with the names of songs. Create a new folder here, and name it what you want to call this new song. Make sure the name is not capitalized. Instead of using spaces in the song name, you have to use a -
instead. For this tutorial, I will be using "Tutorial Remix" as my song name, so I would create a new folder named "tutorial-remix" and not "tutorial remix" or "Tutorial Remix".
Once you have this folder created, make sure you have your song audio. This must be in the .ogg
format, and you can convert other file types to .ogg in many ways, but it is reccomended to use Audacity, which is a free Audio recording and Editing software. The background music should be named "Inst.ogg" and Vocals should be "Voices.ogg", however the voices are optional.
Once you have the sound files for the song, head back to \assets\
and then head to \preload\data\
where you will find a bunch of folders just like in the songs folder. Each of these folders should contain 3 files, song.json
, song-easy.json
and song-hard.json
. Note that "song" should also be the name of the folder, so Philly would have philly-easy.json
, philly.json
, and philly-hard.json
. Create a new folder with the same name as you set in the songs folder, and then create 3 files named song.json
, song-easy.json
and song-hard.json
. Make sure to change "song" to the folder name or else it will not work!
Open each of the .jsons, and then inside of them paste a json from another chart in the files. You can then edit this chart via the Debug Menu in game.
If you already have a .json chart setup for your song, you can simply replace the jsons with this one. Make sure you set the song to the correct song name as well!
Once you have your song charts finished, head over to \ProjectFNF\source\
and then open FreeplayState.hx
. This is the State that creates the whole Freeplay menu. Scroll down to line 82 and then remove the two // at the start of the line so to give it functionality. Line 82 should be the following:
// addWeek(['songname'],7,['characters']); If you wanna add stages that ignore the Weeks and unlocks
Where it says "songname", change this to the name of your song. This time you can use capitalization, but make sure to still use "-" instead of a space. Where it says "characters", simply replace it with the name of one of the characters in the game, this can be but is not limited to:
bf
gf
dad
spooky
pico
mom
monster
senpai
Basically you can use any characters in the files and code for this, as long as it has a icon
This value that you will set basically takes the icon of that character from IconGrid.png
and puts it right next to the song in the freeplay list. If you don't want a icon, just leave this blank. To add more levels to this line, add ,'songname' to the end of the other song name and if you want that to have a different icon, simply add a comma and then write another characters name in quotes.