summaryrefslogtreecommitdiff
path: root/src/game.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2011-12-10 17:52:33 +0300
committerAndrei Karas <akaras@inbox.ru>2011-12-10 17:54:21 +0300
commit03c15cd2ca4587d8bb275df738a9841081cb12f3 (patch)
tree48f5aefc096725a803e74323e0e400baddd0baf4 /src/game.cpp
parent39eef459c1134008086fdce273eac4767724ef68 (diff)
downloadmanaverse-03c15cd2ca4587d8bb275df738a9841081cb12f3.tar.gz
manaverse-03c15cd2ca4587d8bb275df738a9841081cb12f3.tar.bz2
manaverse-03c15cd2ca4587d8bb275df738a9841081cb12f3.tar.xz
manaverse-03c15cd2ca4587d8bb275df738a9841081cb12f3.zip
Fix talk to npc key delay.
Diffstat (limited to 'src/game.cpp')
-rw-r--r--src/game.cpp3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/game.cpp b/src/game.cpp
index 683ba418b..2937d6bb7 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -1507,8 +1507,7 @@ void Game::handleMoveAndAttack(SDL_Event &event, bool wasDown)
}
// Talk to the nearest NPC if 't' pressed
- if (event.type == SDL_KEYDOWN &&
- keyboard.getKeyIndex(event.key.keysym.sym)
+ if (wasDown && keyboard.getKeyIndex(event.key.keysym.sym)
== KeyboardConfig::KEY_TALK &&
!keyboard.isKeyActive(keyboard.KEY_EMOTE))
{