#Debugger not stopping at breakpoint whilst still executing the code

1 messages · Page 1 of 1 (latest)

safe pine
#

As the title says the debugger is not stopping at the breakpoints I set in my instantiated GDScript Objects.

Here is my setup:
I have a "StatusEffect" base class that extends Resource.
To this Resource I attach a GDScript that handles the logic for a specific "StatusEffect" called "StatusEffectAction"
Any GDScript I attach extends StatusEffectAction.
In my StatusEffect instance I instantiate the script and treat it as a StatusEffectAction as seen in the first screenshot.

Heres the problem:
I call the apply_turn_start_effect on the instance of the StatusEffectAction. Here the breakpoints still work.
Then I step into the method and the debugger still works but the breakpoints get ignored and I don't see the pointer for the current line. (There is also no extra thread created or anything)
You can also see me still being able to step through each line but as I mentioned the pointer is not visible in the editor.

Does anyone know whats going on and maybe knows a way how I could fix this?

fading wren
#

It is hard to tell due to this being a gif, but it seems the breakpoint is working, so the other ones must not be the ones being called. There is a lot of functios with similar names here, it is hard to tell.

#

You are also using the "Step out" button, so you may be skipping them due to that.

safe pine
#

The local variables that are shown on the right are ones in the script with the 4 breakpoints, so that code is getting executed.
I'm also using the step Into button which should get me to the next line in the function that I'm calling which it does.

fading wren
#

I see you using the button with the red arrow pointing straight down in the gif.
The step into button is the one with the curved arrow

#

Altho just hitting F12 should reach it.

#

Is this a built-in script?

safe pine
#

Got time for a chat? Its easier to explain that way I think.

safe pine
fading wren
#

I am about to leave, i gotta work.
But do note that you do not need to load() nor preload() scripts with a class_name.

Their class_name is a direct reference to the Script itself

safe pine
#

Yeah I know that, thing is I'm extending from my StatusEffectAction, so creating class_names for each doesnt make sense if in the code I'm only treating them as StatusEffectActions. Or am I wrong?

fading wren
#

The standard in all languages is to give them a class name regardless (as in, usually mandatory).

But i am still puzzled as to why the breakpoint is not working tbh. My only guess is that it is related to the manual loading of the script.

safe pine
#

Yeah same here gdpixel maybe someone can clear this up.