You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-10 13:00:37 +00:00
Merge pull request #18405 from flashyincceo/gdscript-constants-help
Fix Ctrl+click on @GDScript constants
This commit is contained in:
@@ -2636,6 +2636,13 @@ Error GDScriptLanguage::lookup_code(const String &p_code, const String &p_symbol
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if ("PI" == p_symbol || "TAU" == p_symbol || "INF" == p_symbol || "NAN" == p_symbol) {
|
||||||
|
r_result.type = ScriptLanguage::LookupResult::RESULT_CLASS_CONSTANT;
|
||||||
|
r_result.class_name = "@GDScript";
|
||||||
|
r_result.class_member = p_symbol;
|
||||||
|
return OK;
|
||||||
|
}
|
||||||
|
|
||||||
GDScriptParser p;
|
GDScriptParser p;
|
||||||
p.parse(p_code, p_base_path, false, "", true);
|
p.parse(p_code, p_base_path, false, "", true);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user