-
Notifications
You must be signed in to change notification settings - Fork 3
Getting Started
Before you install, make sure your project has:
- Unity
2020.2
or greater! - TextMeshPro package version
3.0.1
or greater! This should already ship with Unity2020.2+
.
Then, follow one of the guides below to install the DeveloperConsole:
- Using a
.unitypackage
installer (experimental) - Using OpenUPM
- Using the Unity Package Manager and a downloaded tarball
- Using the Unity Package Manager and git
After installing, make sure to import the TextMeshPro Essential Resources by going to Window > TextMeshPro > Import TMP Essential Resources if you haven't already done so!
You can refer back to these pages for instructions on how to update the package to a new version, as well.
By default, you can open the in-game console by pressing the backquote key (`
) (or tilde, ~
, on QWERTY keyboards). This will open the console UI and allow you to start entering commands. For your first command, try printing the working directory:
~ $ pwd
C:\Users\MyUser\AppData\LocalLow\DefaultCompany\DeveloperConsole
~ $ █
Just like in a Bash console, past inputs can be cycled through using the up and down arrow keys. For a list of all commands that can be called, enter $ help
.
To customize the console's settings, go to Window > DeveloperConsole > Settings. This will create a ConsoleSettings
asset in your projects directory. Hover over any of the settings to get a description of what that feature does. For a more detailed description of the console's settings, see the settings documentation.
The DeveloperConsole
package was created with the intention that you would extend its functionality by creating console commands specific to your own project. Creating a console command can be as simple as tagging a static method with a CommandAttribute
:
[Command("cmd")]
public static void MyCommand (Vector3 v)
{
// Your command's code
}
and calling it like so:
~ $ cmd (1 2 3)
~ $ █
or as complicated as creating a custom class that manually parses command-line arguments. See the documentation on console commands for more information on creating your own commands.