Author: Nicholas Ventimiglia (nventimiglia)
File : Media:GUIConsole.zip
NOTE: Nicholas Ventimiglia's website is : http://www.avariceonline.com/ . I plan to update it shortly with more goodies.
I had a need for a console application for testing Unity3d services, so I made one.
It has a text input
You can register "interpreters" to process the input (ie: chat interpreter)
It has a command menu (buttons) on the right... to make testing things easier
Separation of the model (ConsoleContext) from the UI (ConsoleGUI)
Support for toggling visibility
Support for listening to Application Log Events.
Unzip the package. Run the scene. ConsoleGUI.cs is the needed view script. The datamodel (ConsoleContext.cs) does not inherit from monobehaviour.
If you want to change the default settings (like colors) there is a ConsoleSetup.cs monobehaviour. It makes any desired changes to the static datamodel on Awake.
Using the Console script from your scripts:
ConsoleContext.Instance is a public static accessor
Log (string, type)
- Adds a message to the list.
- Adds a warning message to the list.
- Adds a error message to the list.
- Adds a success message to the list.
- Adds a input message to the list.
- Adds a output message to the list.
- Clears all of the messages from the list and the screen.
- Submits a argument for evaluation by the command parser.