Skip to content

Commit

Permalink
docs: add console commands reference
Browse files Browse the repository at this point in the history
  • Loading branch information
dbartolini committed Oct 17, 2024
1 parent 5ec7690 commit 95bb037
Show file tree
Hide file tree
Showing 3 changed files with 77 additions and 0 deletions.
76 changes: 76 additions & 0 deletions docs/reference/console_commands.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,76 @@
Console commands
================

The following are commands that can be typed in the Console tab. In order for a
command to be interpreted as such, you must prefix it with a colon symbol when
entering it in the command prompt:

.. image:: images/console_command.png

game
----

Pause/resume the game. Accepts one of the following parameters:

``pause``
Pause the game.

``resume``
Resume the game.

help
----

List all commands.

unpause
-------

Resume the engine. Deprecated, use :ref:`game` instead.

pause
-----

Pause the engine. Deprecated, use :ref:`game` instead.

graph
-----

Plot selected profiler data over time. The <field> parameter must be the name
of a profiler record that the engine provides itself or one that you recorded
via the :ref:`Profiler` API. The command accepts the following
parameters:

``make <name>``
Create a new graph.

``list``
List all the graphs.

``range <graph> [min max]``
Set the range of a graph. If the range is omitted, it will be automatically
computed.

``add <graph> <field>``
Add a field to a graph.

``remove <graph> <field>``
Remove a field from a graph.

``hide <graph>``
Hide a graph.

``show <graph>``
Show a graph.

``layout <graph> <type>``
Set the layout of a graph.
Type can be one of: ``fill``, ``left``, ``right``, ``bottom`` or ``top``.

``color <graph> <field> <color>``
Set the color of a field in a graph. Color can be specified as a 3- or
6-digits hexadecimal RGB number or can be any of: ``yellow``, ``red``, ``green``
or ``blue``.

``samples <graph> <samples>``
Set the number of samples to show in a graph.
Binary file added docs/reference/images/console_command.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
1 change: 1 addition & 0 deletions docs/reference/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ Reference
.. toctree::
:maxdepth: 2

console_commands
boot_config
command_line

0 comments on commit 95bb037

Please sign in to comment.