Added some debugging tools. Plan to add a log system soon. Still some things to remove. First level works fine.