summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRicardo Subtil <ricasubtil@gmail.com>2024-01-12 17:53:59 +0000
committerRicardo Subtil <ricasubtil@gmail.com>2024-01-12 17:53:59 +0000
commita06e5f70bcc06fab9d3303dc40e2d912e2db7df3 (patch)
tree605d3b79a9e9af9f60cb758c1d0dd0e609eb5458
parent3ce73e5d419011d1642ed30a3417362b82c41898 (diff)
downloadredot-engine-a06e5f70bcc06fab9d3303dc40e2d912e2db7df3.tar.gz
Simplify script paths to ensure proper resource path checks
-rw-r--r--modules/gdscript/gdscript_parser.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/gdscript/gdscript_parser.cpp b/modules/gdscript/gdscript_parser.cpp
index f3a4f2eaa6..59f5d29993 100644
--- a/modules/gdscript/gdscript_parser.cpp
+++ b/modules/gdscript/gdscript_parser.cpp
@@ -330,7 +330,7 @@ Error GDScriptParser::parse(const String &p_source_code, const String &p_script_
tokenizer.set_source_code(source);
tokenizer.set_cursor_position(cursor_line, cursor_column);
- script_path = p_script_path;
+ script_path = p_script_path.simplify_path();
current = tokenizer.scan();
// Avoid error or newline as the first token.
// The latter can mess with the parser when opening files filled exclusively with comments and newlines.