A starting point to create your own terminal emulator in a Godot game, for example, to implement hacking-style gameplay.
Link to GitHub project
https://github.com/andrea-calligaris/terminal-emulator
Preview image

Features
- Editable prompt, colors, monospaced font, and fully functional caret.
- Internal environment variables.
- Command history.
- Autocompletion with
Tab.
- Command argument parsing: typed options (value, integer, flag), short and long names, positional arguments (required or optional with defaults), bundled short flags, and error reporting.
- Auto-generated help: running any command with
--help or -h prints usage, arguments, and options derived from its schema.
- Wrapped lines that adjust automatically when the window is resized.
- Text selection with the mouse, with copy and paste support (both via shortcuts and the popup menu).
- Commands can run for extended periods (e.g. simulating
ping) without freezing the UI.
- Multi-line paste executes commands sequentially without freezing the UI.
- Automatic and manual scrolling.
- Popup menu for copy, paste, and potential future features.
- Multi-line command input using
Shift + Enter.
- Word-based cursor navigation using
Ctrl + arrows or Alt + arrows.
- Can gain and lose focus, allowing integration with other windows or panels.