예제 #1
0
        public override int VisitValueString(YarnSpinnerParser.ValueStringContext context)
        {
            // stripping the " off the front and back
            // actually is this what we want?
            string stringVal = context.COMMAND_STRING().GetText().Trim('"');

            compiler.Emit(OpCode.PushString, new Operand(stringVal));

            return(0);
        }
예제 #2
0
        public override int VisitValueString(YarnSpinnerParser.ValueStringContext context)
        {
            // stripping the " off the front and back
            // actually is this what we want?
            string stringVal = context.COMMAND_STRING().GetText().Trim('"');

            int lineNumber = context.Start.Line;
            string id = compiler.program.RegisterString(stringVal, compiler.currentNode.name, null, lineNumber, false);
            compiler.Emit(ByteCode.PushString, id);

            return 0;
        }