diff options
author | Max Horn | 2009-05-11 13:31:37 +0000 |
---|---|---|
committer | Max Horn | 2009-05-11 13:31:37 +0000 |
commit | d66d1ffab302c6146d0262c873287347c9f69267 (patch) | |
tree | de9deaf8b2371dfe6f6fd071e43998ed4c85c4a5 /engines/sci/scicore/sciconsole.h | |
parent | 7c75e8e2ef9268bdd69810a59dc6062f0dff376f (diff) | |
download | scummvm-rg350-d66d1ffab302c6146d0262c873287347c9f69267.tar.gz scummvm-rg350-d66d1ffab302c6146d0262c873287347c9f69267.tar.bz2 scummvm-rg350-d66d1ffab302c6146d0262c873287347c9f69267.zip |
SCI: Replace global vars cmd_paramlength & cmd_params by Common::Array<cmd_param_t> param to console hook commands
svn-id: r40452
Diffstat (limited to 'engines/sci/scicore/sciconsole.h')
-rw-r--r-- | engines/sci/scicore/sciconsole.h | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/engines/sci/scicore/sciconsole.h b/engines/sci/scicore/sciconsole.h index dc8d0abd3f..eca3474390 100644 --- a/engines/sci/scicore/sciconsole.h +++ b/engines/sci/scicore/sciconsole.h @@ -52,15 +52,8 @@ union cmd_param_t { reg_t reg; }; -/** The number of parameters passed to a function called from the parser */ -extern unsigned int cmd_paramlength; - -/** The parameters passed to a function called by the parser */ -extern cmd_param_t *cmd_params; - -/** The game state as used by some of the console commands */ -extern struct EngineState *con_gamestate; +typedef int (*ConCommand)(EngineState *s, const Common::Array<cmd_param_t> &cmdParams); /*** FUNCTION DEFINITIONS ***/ @@ -98,7 +91,7 @@ void con_parse(EngineState *s, const char *command); */ -int con_hook_command(int command(EngineState *s), const char *name, const char *param, const char *description); +int con_hook_command(ConCommand command, const char *name, const char *param, const char *description); /* Adds a command to the parser's command list ** Parameters: command: The command to add ** name: The command's name |