V-Gears 0
Free Final Fantasy VII engine.
ConfigCmdHandlerCommands.h File Reference
#include <OgreRenderWindow.h>
#include <OgreRoot.h>
#include <OgreStringConverter.h>
#include "Console.h"
#include "EntityManager.h"
#include "Logger.h"
#include "XmlMapFile.h"
#include "XmlMapsFile.h"
#include "VGearsGameState.h"
#include "common/VGearsApplication.h"
#include "ConfigCmdHandler.h"
#include "ConfigVarHandler.h"
Include dependency graph for ConfigCmdHandlerCommands.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

void CmdQuit (const Ogre::StringVector &params)
 Command to quit the application. More...
 
void CmdEcho (const Ogre::StringVector &params)
 Command to print to console. More...
 
void CmdConfigVarList (const Ogre::StringVector &params)
 Searches variables in the variable list and prints them. More...
 
void CmdConfigCmdList (const Ogre::StringVector &params)
 Searches the command list and prints the comands. More...
 
void CmdSetConfigVar (const Ogre::StringVector &params)
 Sets the value of a configuration value. More...
 
void CmdToggleConfigVar (const Ogre::StringVector &params)
 Changes the value of a configuration value conditionally. More...
 
void CmdIncrementConfigVar (const Ogre::StringVector &params)
 Increments the value of a configuration variable. More...
 
void CmdSetLogLevel (const Ogre::StringVector &params)
 Configures the log level. More...
 
void CmdMap (const Ogre::StringVector &params)
 Changes the game map. More...
 
void CmdMapCompletion (Ogre::StringVector &complete_params)
 Loads a list of map names. More...
 
void CmdResolution (const Ogre::StringVector &params)
 Sets the resolution and full screen mode. More...
 
void CmdResolutionCompletition (Ogre::StringVector &complete_params)
 Loads a list of resolution modes. More...
 
void CmdScreenshot (const Ogre::StringVector &params)
 Saves a screenshot of the current game window. More...
 

Function Documentation

◆ CmdConfigCmdList()

void CmdConfigCmdList ( const Ogre::StringVector &  params)

Searches the command list and prints the comands.

Parameters
[in]paramsCommand parameters. The first one is the command name. If no more is passed, all commands will be printed. If another parameter is passed, the command with that name (if any) will be printed. If more than two parameter are passed, a command usage string will be printed instead.

◆ CmdConfigVarList()

void CmdConfigVarList ( const Ogre::StringVector &  params)

Searches variables in the variable list and prints them.

Parameters
[in]paramsCommand parameters. The first one is the command name. If no more are passed, all variables will be printed. If another parameter is passed, the variables with that name (if any) will be printed. If more than two parameter are passed, a command usage string will be printed instead.

◆ CmdEcho()

void CmdEcho ( const Ogre::StringVector &  params)

Command to print to console.

Parameters
[in]paramsCommand parameters. All of them will be concatenated and printed. If none are supplied, a command usage text will be printed instead.

◆ CmdIncrementConfigVar()

void CmdIncrementConfigVar ( const Ogre::StringVector &  params)

Increments the value of a configuration variable.

Parameters
[in]paramsCommand parameters. Exactly five must be provided. The first one is the command name. The second one is the variable to increment. The third one is the minimum value the variable will take. The fourth one is the maximum value the variable will take. The fifth value is the increment to apply to the variable. The variable in the second parameter will be incremented by the value in the fith one, but it will be capped between the third and fourth one. If there are more or less than five parameters, a usage text will be printed and nothing will be done.

◆ CmdMap()

void CmdMap ( const Ogre::StringVector &  params)

Changes the game map.

Parameters
[in]paramsCommand parameters. Exactly two must be provided. The first one is the command name. The second one is the map ID. If there are more or less than five parameters, a usage text will be printed and nothing will be done.

◆ CmdMapCompletion()

void CmdMapCompletion ( Ogre::StringVector &  complete_params)

Loads a list of map names.

Parameters
[in]complete_paramsThe map names will be loaded here.

◆ CmdQuit()

void CmdQuit ( const Ogre::StringVector &  params)

Command to quit the application.

Parameters
[in]paramsCommand parameters. Ignored.

◆ CmdResolution()

void CmdResolution ( const Ogre::StringVector &  params)

Sets the resolution and full screen mode.

Parameters
[in]paramsCommand parameters. Three or four must be provided. The first one is the command name. The second one is the resolution width. The third one is the resolution height. The fourth one is optional and can be used to toggle the full screen. "true", "yes" or 1 will set the game in full screen mode. Anything else will set it to windowed mode.

◆ CmdResolutionCompletition()

void CmdResolutionCompletition ( Ogre::StringVector &  complete_params)

Loads a list of resolution modes.

A resolution mode is represented by a string with the format "[w] [h] [f]", where [w] is the resolution width, in pixels, [h] is the resolution height, in pixels and [f] is the full screen state (0 for windowed mode, 1 for full screen)

Parameters
[in]complete_paramsThe resolution modes will be loaded here.

◆ CmdScreenshot()

void CmdScreenshot ( const Ogre::StringVector &  params)

Saves a screenshot of the current game window.

Parameters
[in]paramsCommand parameters. Unused.

◆ CmdSetConfigVar()

void CmdSetConfigVar ( const Ogre::StringVector &  params)

Sets the value of a configuration value.

Parameters
[in]paramsCommand parameters. The first one is the command name. The second one is a variable name. The third one is optional and is a value for the variable. If a value is supplied, the variable will be given that value. If not, the variable will be reset to it's default value. If there is no variable by that name, nothing will be done. In any case, a feedback will be printed to console. If less than two or more than three parameters are passed, a usage text will be printed and nothing will be done.

◆ CmdSetLogLevel()

void CmdSetLogLevel ( const Ogre::StringVector &  params)

Configures the log level.

Parameters
[in]paramsCommand parameters. Exactly two must be provided. The first one is the command name. The second one is the log level. Accepted values are 1 (only errors), 2 (errors and warnings) and 3 (all). If there are more or less than five parameters, a usage text will be printed and nothing will be done.

◆ CmdToggleConfigVar()

void CmdToggleConfigVar ( const Ogre::StringVector &  params)

Changes the value of a configuration value conditionally.

Parameters
[in]paramsCommand parameters. The first one is the command name. The next ones are possible values for the variables. If the value of the variable is the current one, the next one will be assigned. Once the value is changed once, no more steps will be taken and the function will return. If the last provided value is the current value of the variable, it will not be changed.