• Our friends from AlphaCentauri2.info are in need of technical assistance. If you have experience with the LAMP stack and some hours to spare, please help them out and post here.

Can never tell what file a Runtime error is in..

Pazyryk

Deity
Joined
Jun 13, 2008
Messages
3,584
This is starting to annoy me. Is there a workaround?

Runtime Error: [string "C:\Users\Pazyryk\Documents\My Games\Sid Mei..."]:80: attempt to compare number with nil

Usually I can figure it out. But looking at line 80 in five different .lua files is not optimal...
 
Not as far as I know; it's just as annoying as you'd think. Why they'd print the full filename when the default directory is always your big long My Documents/etc. path, I have no idea.

What you CAN do is do some print statement debugging: put a print statement near line 80 in each file it might be, and see which one prints right before/after the crash.

This also leads to a really easy way to debug it: add a blank line to the first file, two blank lines to the second, three to the third, and so on. Then, see what line number it crashes on the next time: if it's 83 now, then you know it was file #3.
 
Back
Top Bottom