Ejemplo n.º 1
0
 public CriAtomSource ApplySetting(CriAtomSource target)
 {
     if (_isSearchById)
     {
         target.SetAisacControl(_aisacTargetId, _aisacControlvalue);
     }
     else
     {
         target.SetAisacControl(_aisacTargetName, _aisacControlvalue);
     }
     return(target);
 }
    // Start is called before the first frame update
    void Start()
    {
        source.SetAisacControl(aisacControllerName_B, currentControlValue[0]);
        source.SetAisacControl(aisacControllerName_C, currentControlValue[1]);
        source.SetAisacControl(aisacControllerName_D, currentControlValue[2]);
        //ステージ開始時にBGMを鳴らす
        //source.Play();


        //中間地点からスタートしたとき
        if (RemainingLife.waypoint)
        {
            currentControlValue[0] += 1.0f;
            if (1.0f < currentControlValue[0])
            {
                currentControlValue[0] = 1.0f;
            }
            source.SetAisacControl(aisacControllerName_B, currentControlValue[0]);

            currentControlValue[1] += 1.0f;
            if (1.0f < currentControlValue[1])
            {
                currentControlValue[1] = 1.0f;
            }
            source.SetAisacControl(aisacControllerName_C, currentControlValue[1]);
        }
    }
Ejemplo n.º 3
0
    IEnumerator FadeAisacCoroutine(float targetAisacValue)
    {
        // 現在値を反映。これがないと、連続で切り替えた時にAISAC値が飛んでしまう
        lastAisacValue_ = currentAisacValue_;
        // FadeTimeプロパティを使ってフェード
        for (float t = 0; t < AisacFadeTime; t += Time.deltaTime)
        {
            currentAisacValue_ = Mathf.Lerp(lastAisacValue_, targetAisacValue, Mathf.Clamp01(t / AisacFadeTime));
            atomSource_.SetAisacControl(AisacControlID, currentAisacValue_);
            yield return(null);
        }

        // フェード完了
        currentAisacValue_ = lastAisacValue_ = targetAisacValue;
        atomSource_.SetAisacControl(AisacControlID, targetAisacValue);

        currentAisacCoroutine_ = null;
    }
Ejemplo n.º 4
0
 // Start is called before the first frame update
 void Start()
 {
     source.SetAisacControl(aisacControllerName_B, currentControlValue[0]);
     source.SetAisacControl(aisacControllerName_C, currentControlValue[1]);
     source.SetAisacControl(aisacControllerName_D, currentControlValue[2]);
     //ステージ開始時にBGMを鳴らす
     //source.Play();
 }