From 0b21618a054fbfa9f4b5e99a5044f2b2dd1d642b Mon Sep 17 00:00:00 2001 From: Perttu Ahola Date: Sun, 4 Mar 2012 13:40:40 +0200 Subject: [PATCH] Tune group digging time stuff a bit --- src/serverremoteplayer.cpp | 2 +- src/tool.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/serverremoteplayer.cpp b/src/serverremoteplayer.cpp index 8a81f1d2..9dd4723f 100644 --- a/src/serverremoteplayer.cpp +++ b/src/serverremoteplayer.cpp @@ -183,8 +183,8 @@ void ServerRemotePlayer::punch(ServerActiveObject *puncher, // "Material" groups of the player std::map groups; - groups["snappy"] = 1; groups["choppy"] = 2; + groups["fleshy"] = 3; IItemDefManager *idef = m_env->getGameDef()->idef(); ItemStack punchitem = puncher->getWieldedItem(); diff --git a/src/tool.cpp b/src/tool.cpp index 3c61ad6e..69141f4e 100644 --- a/src/tool.cpp +++ b/src/tool.cpp @@ -135,10 +135,10 @@ HitParams getHitParams(const std::map &groups, DigParams digprop = getDigParams(groups, tp, time_from_last_punch); - // If digging time would be 1 second, 8 half-hearts go in 1 second. + // Damage in hp is equivalent to nodes dug in time_from_last_punch s16 hp = 0; if(digprop.diggable) - hp = 8.0 / digprop.time; + hp = time_from_last_punch / digprop.time; // Wear is the same as for digging a single node s16 wear = (float)digprop.wear; -- 2.30.2