Stack Trace

Where the message came from, can sometimes be even more important than the message itself. That's why if you double click on a message inside the Unity Console, it will open a script and point to a line where the message came from. We have the same feature actually, the Ultimate Logger console has all the features that the Unity default console does.

But in addition you can do the same with the message stack trace to track the message path. For debugging an exception this is a real game changer. And this is actually the second fundamental feature for the Ultimate Logger Console.

So yes, you can select and double click to navigate every stack trace line:

Lines that can't be opened inside your script editor will be marked with grey colour.

Making your own log wrapper

Most of the developers are making their own wrappers to print a log. If you've ever tried to make your own log wrapper, the first issue you will face is a double click problem. Because if you double-click a log line that came from your wrapper, Unity Console will open your wrapper class instead of the place where you have called your wrapper method. 

We do have a solution for this. So, let's try to create a simple log wrapper:

public static class MyLogsWrapper {
	public static void DoPrint(string message) {
		Debug.Log (message);
	}
}

Now let's use it:

MyLogsWrapper.DoPrint ("Hello world");

The Log output will look similar to this:

As you see MyLogsWrapper is now the first entry point which means you'll be redirected to MyLogsWrapper if you double click the log message. But we actually want to be redirected to a NewBehaviourScript class, the highlighted line on the screenshot. All you need to do to achieve this is to right-click on a MyLogsWrapper stack trace line and add it to the ignore list:

Now all log lines that came from a MyLogsWrapper class will be ignored and marked with grey colour. The ignore list can be managed inside the Ignore List tab of a Settings window. So, in our case the ignore list will look like this: