From e975b11e1885457295a51778d8337b097549228d Mon Sep 17 00:00:00 2001 From: David Athay Date: Tue, 19 May 2009 15:58:58 +0100 Subject: Fixed targeting and warn on attack-range not being found in itemdb. Tried to make the client continue attacking (it does not need to send attack packets, but just continue playing attack animation and sounds). Now logs a warning when a weapon is found without an attack-range (I keep finding weapons with an attack-range of 0 which makes it hard to target monsters). --- src/resources/itemdb.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/resources') diff --git a/src/resources/itemdb.cpp b/src/resources/itemdb.cpp index 99907ca7..fa31c556 100644 --- a/src/resources/itemdb.cpp +++ b/src/resources/itemdb.cpp @@ -210,6 +210,10 @@ void ItemDB::load() } } + if (weaponType > 0) + if (attackRange == 0) + logger->log("ItemDB: Missing attack range from weapon %i!", id); + #define CHECK_PARAM(param, error_value) \ if (param == error_value) \ logger->log("ItemDB: Missing " #param " attribute for item %i!",id) -- cgit v1.2.3-60-g2f50