void Start() { byte[] clapBytes = clap.GetWavBytes(); sample = Bass.BASS_SampleLoad(clapBytes, 0, clapBytes.Length, 50, BASSFlag.BASS_DEFAULT); initLocalPos = transform.localPosition; }
// Use this for initialization protected override void Start() { editor = ChartEditor.GetInstance(); initLocalPos = transform.localPosition; #if BASS_AUDIO clapBytes = clap.GetWavBytes(); sample = Bass.BASS_SampleLoad(clapBytes, 0, clapBytes.Length, 15, BASSFlag.BASS_DEFAULT); #else clapSource = gameObject.AddComponent <AudioSource>(); #endif base.Start(); }
void Start() { byte[] comboBreakBytes = comboBreak.GetWavBytes(); sample = Bass.BASS_SampleLoad(comboBreakBytes, 0, comboBreakBytes.Length, 1, BASSFlag.BASS_DEFAULT); channel = Bass.BASS_SampleGetChannel(sample, false); editor = GameObject.FindGameObjectWithTag("Editor").GetComponent <ChartEditor>(); initSize = transform.localScale.y; transform.localScale = new Vector3(transform.localScale.x, 0, transform.localScale.z); hitWindowFeeder = gameObject.AddComponent <HitWindowFeeder>(); guitarGameplayRulestate = new GuitarGameplayRulestate(KickMissFeedback); drumsGameplayRulestate = new DrumsGameplayRulestate(KickMissFeedback); initialised = true; statsPanel.SetActive(false); EventsManager.onApplicationModeChangedEventList.Add(OnApplicationModeChanged); EventsManager.onChartReloadEventList.Add(OnChartReloaded); }