Stencyl 3.4.0 is now out. Get it now!

How debug a windows game

giordano

  • Posts: 76
Hi, I start saying that I've always done game in flash and this is the first time I do a game in windows so I'm completely new about this. Now, I would like to know if there's a way to debug my game, in particular I would like to see the exceptions that are thrown and things like these. Thank you

JeffreyDriver

  • Posts: 1306
Errors will show up in the logs and give you an indication of what the problem is. Also make use of the 'print' blocks so you can check what's happening in your code.

Luyren

  • *
  • Posts: 1370
Sometimes it's also good to test on Flash. I've had cases where the Windows Export crashed, while Flash gave me an error message I could work with and eventually fix the issue.
Working.

giordano

  • Posts: 76
Sometimes it's also good to test on Flash. I've had cases where the Windows Export crashed, while Flash gave me an error message I could work with and eventually fix the issue.
I know, but I'm using some cpp classes and so I can't export on flash

yoplalala

  • *
  • Posts: 1430
What kind of cpp classes you are using ?
You can use the only in windows block
or use
#if windows
#end

giordano

  • Posts: 76
I'm using the cpp class for the socket and the one for making a thread, but I will try the #if windows condition

giordano

  • Posts: 76
But another problem I have is that a method from the socket class throws an exception, but I can't see what kind of exception is and so I don't know how to catch it. So if there's a way to do a debug directly in windows it will be perfect

SadiQ

  • Posts: 1749
Sometimes it's also good to test on Flash. I've had cases where the Windows Export crashed, while Flash gave me an error message I could work with and eventually fix the issue.

I've had issues where my app worked in flash and yet it crashed in windows, and it's annoying if you discover it too late.

As for debugging windows builds, you could try to use visual studio's debugger. It's not pretty, but it's better than nothing.

Have you first made sure there is no haxe library that does what you need? That way you can skip using external cpp classes.
Proud member of the League of Idiotic Stencylers! Doing things in Stencyl that probably shouldn't be done.

giordano

  • Posts: 76
I've done some research and the libraries I'm using are the only one available for Windows... now I'm using the visual studio debugger but it's not very helpful since I'm still not seeing which exceptions are thrown


giordano

  • Posts: 76