xyonico / BeatSaberSongLoader

A plugin for adding custom songs into Beat Saber
MIT License
238 stars 38 forks source link

ChromaToggle Detection #26

Open Caeden117 opened 6 years ago

Caeden117 commented 6 years ago
uh oh this shouldnt be here i am bad with computer

I added ChromaToggle detection in GetCustomSongInfo for any difficultyLevel object that have the chromaToggle option set to On.

Due to how ChromaToggle uses bombs inside of notes to determine what type they are (0 = Normal, 1 = Alternate, 2 = Gray), people without ChromaToggle will pretty much fail in any map designed for ChromaToggle.

This solves the issue by checking whether or not the difficultyLevel has chromaToggle as described before, then checks to see if SongLoader can detect ChromaToggle's MainSettingsModel. If it cannot, it skips that difficulty option.

This also allows songs to have one difficulty made for ChromaToggle and one difficulty made without it, and players without ChromaToggle can play the difficulties made without the use of the plugin.