Ejemplo n.º 1
0
        /* ---------------------------------------------------------------- */
        // SetValue
        /* ---------------------------------------------------------------- */
        public static SingleStatement SetValueByCalculate(
            string targetKey,
            Operator ope,
            ConstantValue constantValue)
        {
            OperatorValidator.Validate_IsCalculateOperator(ope);

            var calculate = LPG.CreateSingleStatement_CALCULATE(
                CreateTargetState(constantValue.Type, targetKey),
                ope,
                LPG.CreateExpression_ROOMSTATE(GimmickTarget.Item, targetKey),
                LPG.CreateExpression_CONSTANT(constantValue));

            return(calculate);
        }
Ejemplo n.º 2
0
        public static SingleStatement SendSignalToSelfByCompare(
            string compareKey_1st,
            Operator ope,
            string compareKey_2nd,
            string sendKey)
        {
            OperatorValidator.Validate_IsCompareOperator(ope);

            var sendSignal = LPG.CreateSingleStatement_COMPARE(
                new TargetState(TargetStateTarget.Item, sendKey, ParameterType.Signal),
                ope,
                LPG.CreateExpression_ROOMSTATE(GimmickTarget.Item, compareKey_1st),
                LPG.CreateExpression_ROOMSTATE(GimmickTarget.Item, compareKey_2nd));

            return(sendSignal);
        }
Ejemplo n.º 3
0
        public static SingleStatement SetValueByCompare(
            string targetKey,
            ParameterType targetType,
            string key_1st,
            Operator ope,
            ConstantValue constantValue_2nd)
        {
            OperatorValidator.Validate_IsCompareOperator(ope);

            var statement = LPG.CreateSingleStatement_SETVALUE_BY_COMPARE(
                CreateTargetState(targetType, targetKey),
                LPG.CreateExpression_ROOMSTATE(GimmickTarget.Item, key_1st),
                ope,
                LPG.CreateExpression_CONSTANT(constantValue_2nd));

            return(statement);
        }