Search Unity

  1. Unity 2020.1 has been released.
    Dismiss Notice
  2. We are looking for feedback on the experimental Unity Safe Mode which is aiming to help you resolve compilation errors faster during project startup.
    Dismiss Notice
  3. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Feedback Request - add "links" to Debug.Log

Discussion in 'Editor & General Support' started by joshcamas, Jul 15, 2019.

  1. joshcamas


    Jun 16, 2017

    I've implemented IronPython into Unity, and I've also implemented special error logging and such. It would be super amazing if I could also add support for opening python files + line by clicking an error. How I imagine it is adding a "link":

    Code (CSharp):
    1. Debug.Log("Hello, <link=0>click me!</link>",null,(id) => { Debug.Log("You clicked " + id + "!!");});
    Obviously this is just one way to do it out of a million ways - but essentially this example attaches a delegate to when the user pressed a link, and it passes in a index / id, allowing multiple "links" per log.

    I feel like this could be super powerful, since of course you can do *anything* with this - in my case I'd open my code editor, but you could attach any sort of logic at all
    Last edited: Jul 15, 2019
    DrummerB likes this.