Moved in the debug context from the scripting library. It may be more use to people here