Exemple #1
0
        /**
         * <summary>Creates a new instance of the 'Input: Check' Action, set to check if a tap or click is being made</summary>
         * <param name = "requireDoubleClick">If True, it must be a double-tap / double-click</param>
         * <returns>The generated Action</returns>
         */
        public static ActionInputCheck CreateNew_TapOrClick(bool requireDoubleClick = false)
        {
            ActionInputCheck newAction = (ActionInputCheck)CreateInstance <ActionInputCheck>();

            newAction.checkType = (requireDoubleClick) ? InputCheckType.DoubleTapOrClick : InputCheckType.SingleTapOrClick;
            return(newAction);
        }
Exemple #2
0
        /**
         * <summary>Creates a new instance of the 'Input: Check' Action, set to check if a button is pressed</summary>
         * <param name = "buttonName">The button to check for</param>
         * <returns>The generated Action</returns>
         */
        public static ActionInputCheck CreateNew_Button(string buttonName)
        {
            ActionInputCheck newAction = (ActionInputCheck)CreateInstance <ActionInputCheck>();

            newAction.checkType = InputCheckType.Button;
            newAction.inputName = buttonName;
            return(newAction);
        }
Exemple #3
0
        /**
         * <summary>Creates a new instance of the 'Input: Check' Action, set to check if a axis is held down</summary>
         * <param name = "axisName">The axis to check for</param>
         * <param name = "axisValue">The axis value to check for</param>
         * <param name = "condition">The condition to check for</param>
         * <returns>The generated Action</returns>
         */
        public static ActionInputCheck CreateNew_Axis(string axisName, float axisValue = 0.2f, IntCondition condition = IntCondition.MoreThan)
        {
            ActionInputCheck newAction = (ActionInputCheck)CreateInstance <ActionInputCheck>();

            newAction.checkType     = InputCheckType.Axis;
            newAction.inputName     = axisName;
            newAction.axisValue     = axisValue;
            newAction.axisCondition = condition;
            return(newAction);
        }