diff options
author | Juan Linietsky <reduzio@gmail.com> | 2014-02-15 21:16:33 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2014-02-15 21:16:33 -0300 |
commit | 8c1731b67995add31361ae526b0e6af76346181e (patch) | |
tree | f96080fdbb6e0f0f3fcc12bf10fc92928f0310cb /script/gdscript/gd_parser.cpp | |
parent | 9afdb3e0ad5bfbdafe307212f5d4ebcc7c3ac852 (diff) | |
download | redot-engine-8c1731b67995add31361ae526b0e6af76346181e.tar.gz |
-project settings are saved when changed
-load() was in the GDScript docs but missing in the scripting-different music for platformer 2D and 3D
-fix how documentation is generated, built in doc browser should be always up to date
-copypaste, scrolling, etc in builtin doc
-built-in scripts get saved now (though debugger may not always work on them)
-Theme can be set to controls as a property
Diffstat (limited to 'script/gdscript/gd_parser.cpp')
-rw-r--r-- | script/gdscript/gd_parser.cpp | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/script/gdscript/gd_parser.cpp b/script/gdscript/gd_parser.cpp index cfb324e1ae..e558ceb416 100644 --- a/script/gdscript/gd_parser.cpp +++ b/script/gdscript/gd_parser.cpp @@ -557,7 +557,7 @@ GDParser::Node* GDParser::_parse_expression(Node *p_parent,bool p_static,bool p_ //indexing using "." - if (tokenizer.get_token(1)!=GDTokenizer::TK_IDENTIFIER) { + if (tokenizer.get_token(1)!=GDTokenizer::TK_IDENTIFIER && tokenizer.get_token(1)!=GDTokenizer::TK_BUILT_IN_FUNC ) { _set_error("Expected identifier as member"); return NULL; } else if (tokenizer.get_token(2)==GDTokenizer::TK_PARENTHESIS_OPEN) { @@ -566,7 +566,13 @@ GDParser::Node* GDParser::_parse_expression(Node *p_parent,bool p_static,bool p_ op->op=OperatorNode::OP_CALL; IdentifierNode * id = alloc_node<IdentifierNode>(); - id->name=tokenizer.get_token_identifier(1); + if (tokenizer.get_token(1)==GDTokenizer::TK_BUILT_IN_FUNC ) { + //small hack so built in funcs don't obfuscate methods + + id->name=GDFunctions::get_func_name(tokenizer.get_token_built_in_func(1)); + } else { + id->name=tokenizer.get_token_identifier(1); + } op->arguments.push_back(expr); // call what op->arguments.push_back(id); // call func |