console_commands.rst 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. .. _console_commands:
  2. Console commands
  3. ================
  4. The following are commands that can be typed in the Console tab. In order for a
  5. command to be interpreted as such, you must prefix it with a colon symbol when
  6. entering it in the command prompt:
  7. .. figure:: images/console_command.png
  8. :align: center
  9. Typing a console command with the ``:`` prefix.
  10. crash
  11. -----
  12. Crash the engine for testing purposes. Accepts the following parameters:
  13. ``div_by_zero``
  14. Divide a number by zero.
  15. ``unaligned``
  16. Do an unaligned memory access.
  17. ``segfault``
  18. Trigger a segmentation fault.
  19. ``oom``
  20. Allocate too much memory.
  21. ``assert``
  22. Call CE_ASSERT(false).
  23. game
  24. ----
  25. Pause/resume the game. Accepts one of the following parameters:
  26. ``pause``
  27. Pause the game.
  28. ``resume``
  29. Resume the game.
  30. help
  31. ----
  32. List all commands.
  33. unpause
  34. -------
  35. Resume the engine. Deprecated, use :ref:`game` instead.
  36. pause
  37. -----
  38. Pause the engine. Deprecated, use :ref:`game` instead.
  39. graph
  40. -----
  41. Plot selected profiler data over time. The <field> parameter must be the name
  42. of a profiler record that the engine provides itself or one that you recorded
  43. via the :ref:`Profiler` API. The command accepts the following
  44. parameters:
  45. ``make <name>``
  46. Create a new graph.
  47. ``list``
  48. List all the graphs.
  49. ``range <graph> [min max]``
  50. Set the range of a graph. If the range is omitted, it will be automatically
  51. computed.
  52. ``add <graph> <field>``
  53. Add a field to a graph.
  54. ``remove <graph> <field>``
  55. Remove a field from a graph.
  56. ``hide <graph>``
  57. Hide a graph.
  58. ``show <graph>``
  59. Show a graph.
  60. ``layout <graph> <type>``
  61. Set the layout of a graph.
  62. Type can be one of: ``fill``, ``left``, ``right``, ``bottom`` or ``top``.
  63. ``color <graph> <field> <color>``
  64. Set the color of a field in a graph. Color can be specified as a 3- or
  65. 6-digits hexadecimal RGB number or can be any of: ``yellow``, ``red``, ``green``
  66. or ``blue``.
  67. ``samples <graph> <samples>``
  68. Set the number of samples to show in a graph.