Ejemplo n.º 1
0
        public override string GetSummary()
        {
            if (variable == null)
            {
                return("Error: No variable selected");
            }

            string summary = variable.Key + " ";

            summary += Condition.GetOperatorDescription(compareOperator) + " ";

            if (variable.GetType() == typeof(BooleanVariable))
            {
                summary += booleanData.GetDescription();
            }
            else if (variable.GetType() == typeof(IntegerVariable))
            {
                summary += integerData.GetDescription();
            }
            else if (variable.GetType() == typeof(FloatVariable))
            {
                summary += floatData.GetDescription();
            }
            else if (variable.GetType() == typeof(StringVariable))
            {
                summary += stringData.GetDescription();
            }

            return(summary);
        }
Ejemplo n.º 2
0
        public override string GetSummary()
        {
            if (slider == null)
            {
                return("Error: Slider object not selected");
            }

            return(slider.name + " = " + value.GetDescription());
        }
Ejemplo n.º 3
0
        public override string GetSummary()
        {
            if (variable == null)
            {
                return("Error: Variable not selected");
            }

            string description = variable.Key;

            switch (setOperator)
            {
            default:
            case SetOperator.Assign:
                description += " = ";
                break;

            case SetOperator.Negate:
                description += " =! ";
                break;

            case SetOperator.Add:
                description += " += ";
                break;

            case SetOperator.Subtract:
                description += " -= ";
                break;

            case SetOperator.Multiply:
                description += " *= ";
                break;

            case SetOperator.Divide:
                description += " /= ";
                break;
            }

            if (variable.GetType() == typeof(BooleanVariable))
            {
                description += booleanData.GetDescription();
            }
            else if (variable.GetType() == typeof(IntegerVariable))
            {
                description += integerData.GetDescription();
            }
            else if (variable.GetType() == typeof(FloatVariable))
            {
                description += floatData.GetDescription();
            }
            else if (variable.GetType() == typeof(StringVariable))
            {
                description += stringData.GetDescription();
            }

            return(description);
        }