Author Topic: Debug/Error Catching?  (Read 465 times)

Titanicus

  • Sentient
  • **
  • Posts: 61
  • Karma: +3/-0
    • View Profile
Debug/Error Catching?
« on: March 04, 2015, 01:07:14 AM »
Just wondering what the best way to set up our scripts for error catching and debug is. Would rather not run into random crashes that are difficult to impossible to find because of no error catching and such. :)

Titanicus

  • Sentient
  • **
  • Posts: 61
  • Karma: +3/-0
    • View Profile
Re: Debug/Error Catching?
« Reply #1 on: March 07, 2015, 05:07:46 AM »
Getting a crash when I try to remove a file from my mod directory. Specifically, I have a modded version of the LeaderAI.as file, but when I rename/delete it (want to game to just use the default one), the game crashes on map load. (Appcrash).

How do I debug this? Seems strange that the game would crash when i'm trying to get it to simply stop shadowing a file.

*Edit: I accidently modified the base file and it was trying to access a variable that I had deleted.
In any case, some idea how to debug this via a log or debug output would be *swell*.
« Last Edit: March 07, 2015, 05:15:03 AM by Titanicus »

GGLucas

  • Dr. Evil
  • BMS Staff
  • Delusional
  • *
  • Posts: 1877
  • Karma: +300/-6
    • View Profile
Re: Debug/Error Catching?
« Reply #2 on: March 07, 2015, 08:23:18 AM »
The error log is dumped to My Games/Star Ruler 2/log.txt (or ~/.starruler2/log.txt).

Titanicus

  • Sentient
  • **
  • Posts: 61
  • Karma: +3/-0
    • View Profile
Re: Debug/Error Catching?
« Reply #3 on: March 07, 2015, 09:12:12 AM »
Ah... My Games. Thanks and I hope this helps out someone else :)