Esempio n. 1
0
    void OnTriggerEnter()
    {
        Debug.Log("REVERB ON", Department.STAGE, Color.YELLOW);
        col = GetComponent <CompCollider>();
        GameObject col_obj   = col.GetCollidedObject();
        CompAudio  col_audio = null;

        if (col_obj != null)
        {
            col_audio = col_obj.GetComponent <CompAudio>();
        }
        else
        {
            Debug.Log("COL_OBJ IS NULL!", Department.STAGE, Color.RED);
        }

        if (col_audio != null)
        {
            Debug.Log(in_value);
            col_audio.SetAuxiliarySends(bus_name, in_value);
        }
        else
        {
            Debug.Log("COL_AUDIO IS NULL!", Department.STAGE, Color.RED);
        }
    }
Esempio n. 2
0
    void OnTriggerLost()
    {
        Debug.Log("[green] REVERB OUT");
        GameObject col_obj = col.GetCollidedObject();

        CompAudio col_audio = col_obj.GetComponent <CompAudio>();

        if (col_audio != null)
        {
            col_audio.SetAuxiliarySends(bus_name, out_value);
        }
    }
Esempio n. 3
0
    void OnTriggerLost()
    {
        Debug.Log("REVERB OUT", Department.STAGE, Color.RED);
        col = GetComponent <CompCollider>();
        GameObject col_obj   = col.GetCollidedObject();
        CompAudio  col_audio = null;

        if (col_obj != null)
        {
            col_audio = col_obj.GetComponent <CompAudio>();
        }
        if (col_audio != null)
        {
            Debug.Log("REVERB OUT", Department.STAGE);
            col_audio.SetAuxiliarySends(bus_name, out_value);
        }
    }