# Debug

> Class containing methods to ease debugging while developing a game.

## Definition

* **Type:** Class
* **Namespace:** [UnityEngine](/engine/6000.7/script-reference/unityengine.md)
* **Assembly:** UnityEngine.CoreModule

```csharp
public class Debug
```

## Static Properties

| Property                                                                                                | Description                                                                   |
| ------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------- |
| [developerConsoleEnabled](/engine/6000.7/script-reference/unityengine/debug/developerconsoleenabled.md) | Allows you to enable or disable the developer console.                        |
| [developerConsoleVisible](/engine/6000.7/script-reference/unityengine/debug/developerconsolevisible.md) | Controls whether the development console is visible.                          |
| [isDebugBuild](/engine/6000.7/script-reference/unityengine/debug/isdebugbuild.md)                       | In the Build Settings dialog there is a check box called "Development Build". |
| [unityLogger](/engine/6000.7/script-reference/unityengine/debug/unitylogger.md)                         | Get default debug logger.                                                     |

## Static Methods

| Method                                                                                                    | Description                                                                                                                                                                       |
| --------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [Assert](/engine/6000.7/script-reference/unityengine/debug/assert.md)                                     | Assert a condition and logs an error message to the Unity console on failure.                                                                                                     |
| [AssertFormat](/engine/6000.7/script-reference/unityengine/debug/assertformat.md)                         | Assert a condition and logs a formatted error message to the Unity console on failure.                                                                                            |
| [Break](/engine/6000.7/script-reference/unityengine/debug/break.md)                                       | Pauses the editor.                                                                                                                                                                |
| [CheckIntegrity](/engine/6000.7/script-reference/unityengine/debug/checkintegrity.md)                     | Performs an integrity check of the currently running process and return discovered errors.                                                                                        |
| [ClearDeveloperConsole](/engine/6000.7/script-reference/unityengine/debug/cleardeveloperconsole.md)       | Clears all previously printed messages, warnings, and errors from the developer console.                                                                                          |
| [DrawLine](/engine/6000.7/script-reference/unityengine/debug/drawline.md)                                 | Draws a line between specified start and end points.                                                                                                                              |
| [DrawRay](/engine/6000.7/script-reference/unityengine/debug/drawray.md)                                   | Draws a line from `start` to `start` + `dir` in world coordinates.                                                                                                                |
| [ExtractStackTraceNoAlloc](/engine/6000.7/script-reference/unityengine/debug/extractstacktracenoalloc.md) | Populate an unmanaged buffer with the current managed call stack as a sequence of UTF-8 bytes, without allocating GC memory. Returns the number of bytes written into the buffer. |
| [IsValidationLevelEnabled](/engine/6000.7/script-reference/unityengine/debug/isvalidationlevelenabled.md) | Returns whether a given validation level is currently enabled.                                                                                                                    |
| [Log](/engine/6000.7/script-reference/unityengine/debug/log.md)                                           | Logs a message to the Unity Console.                                                                                                                                              |
| [LogAssertion](/engine/6000.7/script-reference/unityengine/debug/logassertion.md)                         | A variant of Debug.Log that logs an assertion message to the console.                                                                                                             |
| [LogAssertionFormat](/engine/6000.7/script-reference/unityengine/debug/logassertionformat.md)             | Logs a formatted assertion message to the Unity console.                                                                                                                          |
| [LogError](/engine/6000.7/script-reference/unityengine/debug/logerror.md)                                 | A variant of Debug.Log that logs an error message to the console.                                                                                                                 |
| [LogErrorFormat](/engine/6000.7/script-reference/unityengine/debug/logerrorformat.md)                     | Logs a formatted error message to the Unity console.                                                                                                                              |
| [LogException](/engine/6000.7/script-reference/unityengine/debug/logexception.md)                         | A variant of Debug.Log that logs an exception message to the console.                                                                                                             |
| [LogFormat](/engine/6000.7/script-reference/unityengine/debug/logformat.md)                               | Logs a formatted message to the Unity Console.                                                                                                                                    |
| [LogWarning](/engine/6000.7/script-reference/unityengine/debug/logwarning.md)                             | A variant of Debug.Log that logs a warning message to the console.                                                                                                                |
| [LogWarningFormat](/engine/6000.7/script-reference/unityengine/debug/logwarningformat.md)                 | Logs a formatted warning message to the Unity Console.                                                                                                                            |
| [RetrieveStartupLogs](/engine/6000.7/script-reference/unityengine/debug/retrievestartuplogs.md)           | Returns any captured startup logs                                                                                                                                                 |

## Structs

| Struct                                                                              | Description                 |
| ----------------------------------------------------------------------------------- | --------------------------- |
| [Debug.StartupLog](/engine/6000.7/script-reference/unityengine/debug/startuplog.md) | Information about a message |
