From d531869a7c3c73d79c6ead71c7736f285bf6e1a1 Mon Sep 17 00:00:00 2001 From: rune-scape <allie.smith.epic@gmail.com> Date: Thu, 1 Dec 2022 05:20:42 -0500 Subject: GDScript: Fix subclass script path issues --- modules/gdscript/gdscript.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'modules/gdscript/gdscript.h') diff --git a/modules/gdscript/gdscript.h b/modules/gdscript/gdscript.h index 2df89d812c..7911ea47ec 100644 --- a/modules/gdscript/gdscript.h +++ b/modules/gdscript/gdscript.h @@ -240,6 +240,7 @@ public: virtual Error reload(bool p_keep_state = false) override; virtual void set_path(const String &p_path, bool p_take_over = false) override; + String get_script_path() const; Error load_source_code(const String &p_path); Error load_byte_code(const String &p_path); @@ -432,7 +433,7 @@ public: csi.write[_debug_call_stack_pos - i - 1].line = _call_stack[i].line ? *_call_stack[i].line : 0; if (_call_stack[i].function) { csi.write[_debug_call_stack_pos - i - 1].func = _call_stack[i].function->get_name(); - csi.write[_debug_call_stack_pos - i - 1].file = _call_stack[i].function->get_script()->get_path(); + csi.write[_debug_call_stack_pos - i - 1].file = _call_stack[i].function->get_script()->get_script_path(); } } return csi; -- cgit v1.2.3