aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormegamage <none@none>2009-01-03 22:14:32 -0600
committermegamage <none@none>2009-01-03 22:14:32 -0600
commite19482bcb4a0867ca729779ab680fd10b849d797 (patch)
tree4400663dbcc3fd430012ab32ed95dde1a4e90d9e
parent5d4dcba0de0d764ae9bf81071171ef41e377b063 (diff)
*Fix a bug about corpse reclaim delay timer.
--HG-- branch : trunk
-rw-r--r--src/game/Player.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/game/Player.cpp b/src/game/Player.cpp
index 36d261827e3..0db4a665d80 100644
--- a/src/game/Player.cpp
+++ b/src/game/Player.cpp
@@ -18792,7 +18792,8 @@ uint32 Player::GetCorpseReclaimDelay(bool pvp) const
time_t now = time(NULL);
// 0..2 full period
- uint32 count = (now < m_deathExpireTime) ? (m_deathExpireTime - now)/DEATH_EXPIRE_STEP : 0;
+ // should be ceil(x)-1 but not floor(x)
+ uint32 count = (now < m_deathExpireTime - 1) ? (m_deathExpireTime - 1 - now)/DEATH_EXPIRE_STEP : 0;
return copseReclaimDelay[count];
}