Paused on execption

Every time I try to debug the program, nothing runs. I see a notice that says Paused on Exception, and when I try to skip or move forward, I get “Unable to step next. Operation failed with error code 0x80004004.”

Do you have any idea what I am missing on this?

I believe the issue is because you’re declaring the character before you’re calling InitWindow.

Inside of the character, you’re setting up your texture2Ds with a call to LoadTexture, which in itself is ok. However, InitWindow needs to be called first before any LoadTexture calls can succeed and not lead to a crash.

So change this part (comments removed):

 Character Hood;
    Hood.setscreenposition(windowDem[0],windowDem[1]);
    InitWindow(windowDem[0], windowDem[1], "Blizzard of Dume");

To this:

InitWindow(windowDem[0], windowDem[1], "Blizzard of Dume");
 Character Hood;
    Hood.setscreenposition(windowDem[0],windowDem[1]);

And the exception should no longer happen.

Thanks, I have it up an running now. However, my character sprite no longer loads. Any idea on how I can work around that?

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.

Double-check to filepath to your sprite would be a quick check to do, you can also take a look at the terminal when you debug your game to see if there are any error messages that come up.

1 Like

Privacy & Terms