diff options
Diffstat (limited to 'src/game/client/components')
| -rw-r--r-- | src/game/client/components/console.cpp | 14 | ||||
| -rw-r--r-- | src/game/client/components/console.hpp | 3 | ||||
| -rw-r--r-- | src/game/client/components/sounds.cpp | 2 |
3 files changed, 17 insertions, 2 deletions
diff --git a/src/game/client/components/console.cpp b/src/game/client/components/console.cpp index f9ec4ae3..66a2249a 100644 --- a/src/game/client/components/console.cpp +++ b/src/game/client/components/console.cpp @@ -349,6 +349,14 @@ void CONSOLE::client_console_print_callback(const char *str, void *user_data) ((CONSOLE *)user_data)->local_console.print_line(str); } +void CONSOLE::print_line(int type, const char *line) +{ + if(type == 0) + local_console.print_line(line); + else if(type == 1) + remote_console.print_line(line); +} + void CONSOLE::on_init() { // @@ -372,13 +380,15 @@ static void con_team(void *result, void *user_data) send_switch_team(console_arg_int(result, 0)); } -void send_kill(int client_id); - static void con_kill(void *result, void *user_data) { send_kill(-1); } +void send_kill(int client_id); + + + static void con_key_input_state(void *result, void *user_data) { ((int *)user_data)[0] = console_arg_int(result, 0); diff --git a/src/game/client/components/console.hpp b/src/game/client/components/console.hpp index 9b60185c..a13a1d65 100644 --- a/src/game/client/components/console.hpp +++ b/src/game/client/components/console.hpp @@ -1,5 +1,6 @@ #include <engine/e_client_interface.h> #include <game/client/component.hpp> +#include <game/client/lineinput.hpp> class CONSOLE : public COMPONENT { @@ -47,6 +48,8 @@ class CONSOLE : public COMPONENT public: CONSOLE(); + void print_line(int type, const char *line); + virtual void on_init(); virtual void on_reset(); virtual void on_render(); diff --git a/src/game/client/components/sounds.cpp b/src/game/client/components/sounds.cpp index 569bbf01..024d07d4 100644 --- a/src/game/client/components/sounds.cpp +++ b/src/game/client/components/sounds.cpp @@ -11,6 +11,8 @@ void SOUNDS::on_init() snd_set_channel(SOUNDS::CHN_MUSIC, 1.0f, 0.0f); snd_set_channel(SOUNDS::CHN_WORLD, 0.9f, 1.0f); snd_set_channel(SOUNDS::CHN_GLOBAL, 1.0f, 0.0f); + + snd_set_listener_pos(0.0f, 0.0f); } void SOUNDS::on_render() |