Sign in to follow this  
MysticC

How to debug LUA

Recommended Posts

Hi,there.I am using LUA as scrpit.But I found it is very hard to debug LUA.Would you give me some advice please? Thank you!

Share this post


Link to post
Share on other sites
It's kind of hard to say, being that you don't provide any details of the kind of problems you're trying to debug. I assume you're logging any and all errors, because Lua does a pretty good job in that department. That pretty much takes care of compile-time debugging. As for run-time debugging, it depends entirely on the language and environment you're using, but the most obvious thing to do is bind a bunch of functions which use your language's/environment's inbuilt debugging tools and then you can use them from Lua. So have a function which logs to the debug console, and bind that to Lua. Have a function which breaks program execution with the debugger, and bind that to Lua.

To suggest anything else, I'd have to know what kind of issues/problems you're trying to debug.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this