Skip to content

Custom Sound

Sound files should be in one of acc, mp3, ogg, wav formats, with the filename serving as the sound ID. A default metadata JSON is generated upon using the sound, allowing you to edit and apply sound file metadata on the next game launch.

By setting "type": "BGM" in the metadata, the sound file will be instantiated as BGMData instead of SoundData. You can also customize the BGM parts in the metadata.

Subdirectories in the Sound folder will serve as ID prefixes. For example, AI_PlayMusic will use Instrument/sound_id, so you should place the sound file in the Instrument folder if you plan to replace instrument sounds.

You can override existing in-game sounds using the same ID. For example, chicken uses sound id Animal/Chicken/chicken, if you want to replace this sound, you should put your sound file named chicken with one of the supported formats, in Sound/Animal/Chicken/ folder.

Sounds loaded by CWL will be available to use anywhere in the game via sound id.

cs
pc.PlaySound("clown_horn"); // <- Card.PlaySound
SE.PlaySound("clown_horn");

Custom BGM & Playlist

Version Notice

Custom BGM & Playlist feature is added in CWL 1.19.0.

Game comes with 100+ BGMs, they are defined by a numeric id and sound file id. You may check them out here:

BGM Items
bgm idsound idbgm name
1001 no bgmNo BGM
2002 pop01Pop01
3003 PSML516PSML516
4004 hoshinokisekiHoshi No Kiseki
5005 elomap1Tyris 1
6006 elomap2Tyris 2
7007 elomap3Tyris 3
8008 town2 magicTown 2
9009 fun villageFun Village
10010 bouken no junbiBouken No Junbi
11011 bukikoubouBuki Kobo
12012 kiminoita natsuKiminoita Natsu
13013 ruinsRuins
14014 village1Village
15015 Atlantean_Twilight256Atlantean Twilight
16016 intro2Intro 2
17017 cobaltCobalt
18018 mitologiaMitologia
19019 morning breezeMorning Breeze
20020 morning breeze(sunny day)Morning Breeze(Sunny Day)
21021 PSML047PSML047
22022 Pyramid-naibuPyramid
23023 mysterious-forestMysterious Forest
24024 PSML514PSML514
25025 nodokana muraNodokana Mura
26026 kokyoKokyo
27027 fun gameMayonakano Omochabako
28028 kagayaku tsukiKagayaku Tsuki
29029 MapBGMMap BGM
30030 a moment in the morningA Moment In The Morning
31031 SBGMv2_05SBGM 5
32032 daybreakDaybreak
33033 hoshi to tsukiHoshi To Tsuki No Oka
34034 ep2Epilogue 2
35035 nibiiro no soraNibiiro No Sora
36036 oita kataribeOita Kataribe
37037 kaerimichi pianoKaerimichi(Piano)
38038 moriMori
39039 rainaRaina
40040 laid back guitarsLaid Back Guitars
41041 earlgreyEarlgrey Guitar
42042 mayonakano-parkMayonakano Park
43043 Along-the-riverside-roadAlong the riverside road
44044 heya_guitar 1Heya Guitar
45045 Sancho_Panza 1Sancho Panza
46046 dwarfDwarf
47047 nonbiri dwarfNonbiri Dwarf
48048 nazoooki shindenNazoooki Shinden
49049 kamigamiga nemuru bashoKamigamiga Nemuru Basho
50050 titleTitle
51051 yukiYuki
52052 dark themeFear 2
53053 hoardHoard
54054 The House of LeavesThe House of Leaves
55055 BGM_0 sirube-2Sirube
56056 orc01Orc01
57057 VillageMearas Village 2
58058 PSML060PSML060
59059 tyris4Tyris 4
60060 mayoimichiMayoimichi
61061 hyousetsuHyousetsu
62062 workshopMearas Workshop
63063 shopShop
64064 TownMearas Town
65065 soaringSoaring
66066 soraochiSoraochiruhi
67067 WizartoriumWizartorium
68068 grayGray
69069 escapeEscape
70070 arifureta shiawaseArifureta Shiawase
71071 TaikutsuTaikutsu
72072 Netherworld_ShantyNetherworld Shanty
73073 tabinohajimeTabino Hajime
74074 gagGag
75075 happyMearas Happy
76076 villageMearas Village 3
77077 dragon and toastDragon and Toast
78078 legend of oneLegend of One
79079 koudouKoudou
80080 big mojoBig Mojo
81081 exoticsExotics
82082 magic cityMearas Magic City
83083 gothicGothic
84084 fieldField
85085 PSML0515PSML515
86086 anosoraAnosorano Mukouni
87087 memoryMemory
88088 memory 2Memory 2
89089 semi yuugataSemi. Yuugata.
90090 hirusagariHirusagari Kibun
91091 nichiyoNichiyo No Gogo
92092 itazuraItazura Kids
93093 cat lifeCat Life
94094 ensolaradoEnsolarado
95095 BGM3 11BGM3-11
96096 BGM3 7varBGM3-7 Var
97097 BGM3 11var 1BGM3-11 Var
98098 Pixel MythPixel Myth
99099 TsukitowatashiTsukito Watashi
100100 Tsukino KobuneTsukino Kobune
101101 flashbackFlashback
102102 punipuniPunipunichuiho
103103 sabakuSabakuwo Iku
104104 butouButoukai
105105 anime OPElin OP
106106 anime EDElin ED
107107 BGM3-1 1BGM3-1
108108 wafuWafu
109109 Into LegendAnd Thus Into Legend
110110 defenderDefender
111111 snow forestSnow Forest
112112 hirahiraHirahira
113113 lunaLuna
114114 orc05Orchestra 5
115115 xmasHoly Night
116116 xmas 2Jingle Bell
117117 atonementShokuzai No Mori

Add New BGM

Custom BGMs are placed in the Sound/BGM sub folder, unlike custom sounds, you need to manually edit the id field in the metadata JSON. Be sure to launch game once to let CWL generate the files for you first.

CWL suggests using wav or ogg formats, this is because the Unity codec with Elin's game version (2021.3.34f1) might encounter problems decoding mp3 files.

The id is an arbitrary number, set it to larger than what game uses at last (117) and make it less likely to collide with other BGM's id.

Important to note, this id is purely for the BGM. Your sound id is still the file name without extension, e.g. BGM/My Sound File

When you assign an existing id to your BGM, then it becomes a global BGM replacement. E.g. Assigning id 56 to the song metadata Adventure-YOASOBI.json, will replace in game BGM 056 orc01 with sound Adventure-YOASOBI. This is why you want your new BGM (non-replacement ones) to use a unique id, otherwise the next BGM with the same id will replace yours.

056 orc01 is the title menu BGM.

Add Playlist

Your playlists are placed in the Sound/BGM/Playlist folder, and they are simple JSON files. It contains 2 lists and a single bool value shuffle.

json
{
    "shuffle": true,
    "list": [
        "megalovania"
    ],
    "remove": [
        "024 PSML514",
        "023 mysterious-forest",
		"MySomeOtherBGM/*"
    ]
}

The sound id (not BGM id) in list will be merged into the playlist, and remove will remove the entries (if present) from the playlist. You can also use existing game sound ids.

You may also use wildcards as the list and remove entry, currently 2 patterns are provided:

json
"remove": [
	"**"
]

Which will remove all entries prior to merging.

json
"remove": [
	"<dir>/*"
]

Which will remove all entries from Sound/BGM/<dir>/ folder prior to merging.

Playlist Type

The playlist JSON file name should match one of the following:

  • "Global"
  • An existing playlist name
  • A zone type name

Here are some of the game playlists:

Playlists
  • Battle [1]
    • 054 The House of Leaves
  • Blank [4]
    • 041 earlgrey
    • 090 hirusagari
    • 044 heya_guitar 1
    • 043 Along-the-riverside-road
  • Day [1]
    • 004 hoshinokiseki
  • Dungeon [4]
    • 024 PSML514
    • 022 Pyramid-naibu
    • 023 mysterious-forest
    • 048 nazoooki shinden
  • Dungeon2 [6]
    • 072 Netherworld_Shanty
    • 077 dragon and toast
    • 078 legend of one
    • 079 koudou
    • 080 big mojo
    • 081 exotics
  • Dungeon_Boss [1]
    • 098 Pixel Myth
  • EloMap [3]
    • 006 elomap2
    • 007 elomap3
    • 059 tyris4
  • Festival_Noyel [1]
    • 051 yuki
  • Festival_Olvina [1]
    • 051 yuki
  • Festival_Yowyn [1]
    • 093 cat life
  • Field [1]
    • 015 Atlantean_Twilight256
  • Hoard [1]
    • 053 hoard
  • Lot [1]
    • 061 hyousetsu
  • Night [2]
    • 005 elomap1
    • 004 hoshinokiseki
  • Underground [2]
    • 046 dwarf
    • 047 nonbiri dwarf

Blank is the default playlist for all zones that don't have an explicit playlist defined.

To view the zone type names and their playlists (if any):

Global Override

A special playlist named Global can be provided and it will be merged into all playlists.

Playlist Merge

For example, all nefia zones (Zone_RandomDungeon, Zone_RandomDungeonFactory, Zone_Mine...etc) share a playlist called Dungeon. If you want to add or remove songs for this playlist, you should use Dungeon.json in your Sound/BGM/Playlist/ folder.

Your changes in Dungeon.json will be merged into game's Dungeon playlist, be it adding or removing songs. This will affect all zones that share this playlist.

Another common use case is to add songs when you are in overworld map. The overworld map is a zone type Region and it has a playlist EloMap.

Zone Override

In addition to the playlist merge, you can also specifiy zone overrides for each zone type. These playlists will be using the zone type name, and its contents will be merged on top of the zone's default playlist (Blank if none specified in the sheet).

So, you could add songs to the overworld map playlist via Region.json instead of EloMap.json too.

Merge Order

The three types of playlists will be applied in the order of Global, Playlist Merge, Zone Override. They are also affected by your mod load order. Keep that in mind when you do nested remove, especially with ** or <dir>/* pattern matching.

Hot Reload/BGM View

After loading the save file in the game, you can view and control the current playlist using the CWL panel:

Once you have edited the playlist JSON while the game is running, you can hot-reload all playlists. Although the CWL has console commands for hot-reloading newly added audio files, it is not recommended due to potential indexing issues.

Examples

To remove all songs in overworld exploration playlist and add your new songs, define these in Sound/BGM/Playlist/EloMap.json or Sound/BGM/Playlist/Region.json:

json
{
    "shuffle": true,
    "list": [
        "my new BGM sound id1",
        "my new BGM sound id2"
    ],
    "remove": [
        "**"
    ]
}