예제 #1
0
 public Function(Craken _parent, Opcode[] _opcodes, string _name, FunctionArgument[] _args, Type _returns)
 {
     parent = _parent;
     iprivate = false;
     ivirtual = true;
     name = _name;
     args = _args;
     returns = _returns;
     opcodes = _opcodes;
 }
예제 #2
0
파일: Script.cs 프로젝트: HeapSpray/Craken
        public Script(Craken _vm, string path)
        {
            vm = _vm;
            if (!File.Exists(path)) { throw new CrakenException(CrakenException.Exceptions.ScriptRead_FAIL); };
            string alltxt, temp;
            alltxt = File.ReadAllText(path);
            // prepare our source for parsing
            temp = vm.StrHelp.Clean(alltxt);
            alltxt = temp;
            // get script's filename. it'll be used as actual name
            string[] splt = path.Replace(@"\", ".").Split('.');
            name = splt[splt.Length - 2];

            Compile(alltxt);
        }
예제 #3
0
 public ExpressionHelper(Craken _craken)
 {
     craken = _craken;
 }
예제 #4
0
파일: Lexer.cs 프로젝트: HeapSpray/Craken
 public Lexer(Craken _craken)
 {
     craken = _craken;
 }