//Tools private void Start() { //Load the config file NRSettings.LoadSettingsJson(); notes = new List <Target>(); orderedNotes = new List <Target>(); loadedNotes = new List <Target>(); selectedNotes = new List <Target>(); gridNotesStatic = gridTransformParent; timelineNotesStatic = timelineTransformParent; NRSettings.OnLoad(() => { sustainVolume = NRSettings.config.sustainVol; musicVolume = NRSettings.config.mainVol; musicVolumeSlider.value = musicVolume; SetAudioDSP(); }); musicVolumeSlider.onValueChanged.AddListener(val => { musicVolume = val; NRSettings.config.mainVol = musicVolume; NRSettings.SaveSettingsJson(); }); StartCoroutine(CalculateNoteCollidersEnabled()); Physics.autoSyncTransforms = false; }
public void InitPresence() { NRSettings.OnLoad(() => { if (!NRSettings.config.useDiscordRichPresence) { gameObject.SetActive(false); return; } showTime = NRSettings.config.showTimeElapsed; presence.details = "In Menus"; presence.state = ""; presence.startTime = showTime ? new DiscordTimestamp(Time.realtimeSinceStartup) : DiscordTimestamp.Invalid; float duration = 0; presence.endTime = duration > 0 ? new DiscordTimestamp(Time.realtimeSinceStartup + duration) : DiscordTimestamp.Invalid; //Register to a presence change DiscordManager.current.events.OnPresenceUpdate.AddListener((message) => { Debug.Log("Received a new presence! Current App: " + message.ApplicationID + ", " + message.Name); }); DiscordManager.current.SetPresence(presence); }); }
private void Start() { SetDefaultVolumes(); NRSettings.OnLoad(() => { mainSlider.value = (float)NRSettings.config.mainVol; SetMainVol(); }); }
private void Start() { aud = GetComponent <AudioSource>(); volume = volumeSlider.value; NRSettings.OnLoad(() => { noteHitScale = NRSettings.config.noteHitScale; volume = (float)NRSettings.config.noteVol; volumeSlider.value = volume; }); }
//Tools private void Start() { //Load the config file NRSettings.LoadSettingsJson(); notes = new List <Target>(); orderedNotes = new List <Target>(); loadedNotes = new List <Target>(); selectedNotes = new List <Target>(); //securityRules.AddAccessRule(new FileSystemAccessRule(new SecurityIdentifier(WellKnownSidType.WorldSid, null), FileSystemRights.FullControl, AccessControlType.Allow)); gridNotesStatic = gridTransformParent; timelineNotesStatic = timelineTransformParent; //Modify the note colors StartCoroutine(CalculateNoteCollidersEnabled()); Physics.autoSyncTransforms = false; }
public void SetSustainVol() { timeline.sustainVolume = sustainSlider.value; NRSettings.config.sustainVol = timeline.sustainVolume; NRSettings.SaveSettingsJson(); }
public void SetMainVol() { main.volume = mainSlider.value; NRSettings.config.mainVol = main.volume; NRSettings.SaveSettingsJson(); }
public void VolumeChange(Slider vol) { volume = vol.value; NRSettings.config.noteVol = volume; NRSettings.SaveSettingsJson(); }