diff options
| author | Magnus Auvinen <magnus.auvinen@gmail.com> | 2008-03-18 02:14:35 +0000 |
|---|---|---|
| committer | Magnus Auvinen <magnus.auvinen@gmail.com> | 2008-03-18 02:14:35 +0000 |
| commit | 6d07a560a662b336b6c35105b37b6323d0c3ad8b (patch) | |
| tree | 5f8c8409a0616fccf9f8af9a91fb12fa05bae1b0 /src/game/client/gc_console.cpp | |
| parent | c662df41eedb585412e445145b9233e20b2ffe46 (diff) | |
| download | zcatch-6d07a560a662b336b6c35105b37b6323d0c3ad8b.tar.gz zcatch-6d07a560a662b336b6c35105b37b6323d0c3ad8b.zip | |
fixed so that you can bind chat to enter and it still works
Diffstat (limited to 'src/game/client/gc_console.cpp')
| -rw-r--r-- | src/game/client/gc_console.cpp | 25 |
1 files changed, 14 insertions, 11 deletions
diff --git a/src/game/client/gc_console.cpp b/src/game/client/gc_console.cpp index 37e50948..ca1e20cb 100644 --- a/src/game/client/gc_console.cpp +++ b/src/game/client/gc_console.cpp @@ -215,6 +215,20 @@ static void con_sayteam(void *result, void *user_data) chat_say(1, console_arg_string(result, 0)); } + + +static void con_chat(void *result, void *user_data) +{ + const char *mode = console_arg_string(result, 0); + if(strcmp(mode, "all") == 0) + chat_enable_mode(0); + else if(strcmp(mode, "team") == 0) + chat_enable_mode(1); + else + dbg_msg("console", "expected all or team as mode"); +} + + void send_kill(int client_id); static void con_kill(void *result, void *user_data) @@ -330,17 +344,6 @@ static void con_key_input_weapon(void *result, void *user_data) input_data.wanted_weapon = w; } -static void con_chat(void *result, void *user_data) -{ - const char *mode = console_arg_string(result, 0); - if(strcmp(mode, "all") == 0) - chat_enable_mode(0); - else if(strcmp(mode, "team") == 0) - chat_enable_mode(1); - else - dbg_msg("console", "expected all or team as mode"); -} - static void con_toggle_local_console(void *result, void *user_data) { console_toggle(0); |