From 7d1e019808dced37434af7c7c14ed5569e87f50e Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Wed, 24 Feb 2010 03:01:49 +0200 Subject: Fix talk request flood. Fix talk request flood from keyboard. Fix duplicate lines in NPC dialogs. Signed-off-by: Jared Adams --- src/game.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/game.cpp b/src/game.cpp index 7ebf6f8e..b3670641 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -865,7 +865,8 @@ void Game::handleInput() } // Talk to the nearest NPC if 't' pressed - if ( keyboard.isKeyActive(keyboard.KEY_TALK) ) + if (event.type == SDL_KEYDOWN && + keyboard.getKeyIndex(event.key.keysym.sym) == KeyboardConfig::KEY_TALK) { Being *target = player_node->getTarget(); -- cgit v1.2.3-70-g09d2