Example #1
0
        private int GetAxisStates(AxisMapping axsMapping) {
            int rtrnInt = 0;
            // check both pos and neg. add them toegeather to get the final value
            if(GetButtonStates(axsMapping.positiveKey)) { rtrnInt += 1; } 
            if(GetButtonStates(axsMapping.negativeKey)) { rtrnInt -= 1; }

            return rtrnInt;
        }
Example #2
0
        private int GetAxisStates(AxisMapping axsMapping)
        {
            int rtrnInt = 0;

            // check both pos and neg. add them toegeather to get the final value
            if (GetButtonStates(axsMapping.positiveKey))
            {
                rtrnInt += 1;
            }
            if (GetButtonStates(axsMapping.negativeKey))
            {
                rtrnInt -= 1;
            }

            return(rtrnInt);
        }