Ejemplo n.º 1
0
        void FindPairedButton()
        {
            // find the other button witch which this button should be paired
            // (it should have the same axisName)
            var otherAxisButtons = FindObjectsOfType(typeof(AxisTouchButton)) as AxisTouchButton[];

            if (otherAxisButtons != null)
            {
                for (int i = 0; i < otherAxisButtons.Length; i++)
                {
                    if (otherAxisButtons[i].axisName == axisName && otherAxisButtons[i] != this)
                    {
                        m_PairedWith = otherAxisButtons[i];
                    }
                }
            }
        }
Ejemplo n.º 2
0
        void FindPairedButton()
        {
            // find the other button witch which this button should be paired
            // (it should have the same axisName)
            var otherAxisButtons = FindObjectsOfType(typeof(AxisTouchButton)) as AxisTouchButton[];

            if (otherAxisButtons != null)
            {
                for (int i = 0; i < otherAxisButtons.Length; i++)
                {
                    if (otherAxisButtons[i].axisName == axisName && otherAxisButtons[i] != this)
                    {
                        m_PairedWith = otherAxisButtons[i];
                    }
                }
            }
        }