summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog1
-rw-r--r--src/game.cpp16
2 files changed, 10 insertions, 7 deletions
diff --git a/ChangeLog b/ChangeLog
index 448abae7..857e55e3 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,4 +1,5 @@
0.0.12 (? May 2005)
+- Right mouse button to attack (enables also ranged attacks)
- Added XML item database
- Fixed crash when map server is down
- New map (Shimris cave)
diff --git a/src/game.cpp b/src/game.cpp
index 10c2a63c..1afa5e79 100644
--- a/src/game.cpp
+++ b/src/game.cpp
@@ -357,13 +357,15 @@ void do_input()
}
}
else if (target->isMonster()) {
- player_node->action = ATTACK;
- action(0, target->id);
- player_node->walk_time = tick_time;
- if (player_node->weapon == 2)
- sound.playSfx("sfx/bow_shoot_1.ogg");
- else
- sound.playSfx("sfx/fist-swish.ogg");
+ if (player_node->action == STAND) {
+ player_node->action = ATTACK;
+ action(0, target->id);
+ player_node->walk_time = tick_time;
+ if (player_node->weapon == 2)
+ sound.playSfx("sfx/bow_shoot_1.ogg");
+ else
+ sound.playSfx("sfx/fist-swish.ogg");
+ }
}
else if (target->isPlayer()) {
// Begin a trade