aboutsummaryrefslogtreecommitdiff
path: root/src/server/scripts
diff options
context:
space:
mode:
Diffstat (limited to 'src/server/scripts')
-rw-r--r--src/server/scripts/World/boosted_xp.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/server/scripts/World/boosted_xp.cpp b/src/server/scripts/World/boosted_xp.cpp
index df03dab4a81..9d73e5afadf 100644
--- a/src/server/scripts/World/boosted_xp.cpp
+++ b/src/server/scripts/World/boosted_xp.cpp
@@ -17,17 +17,17 @@
#include "GameTime.h"
#include "ScriptMgr.h"
+#include "Util.h"
#include "World.h"
-#include <boost/date_time/posix_time/posix_time.hpp>
-
namespace
{
bool IsXPBoostActive()
{
- auto now = boost::posix_time::to_tm(boost::posix_time::from_time_t(GameTime::GetGameTime()));
+ time_t time = GameTime::GetGameTime();
+ tm localTm = TimeBreakdown(time);
uint32 weekdayMaskBoosted = sWorld->getIntConfig(CONFIG_XP_BOOST_DAYMASK);
- uint32 weekdayMask = (1 << now.tm_wday);
+ uint32 weekdayMask = (1 << localTm.tm_wday);
bool currentDayBoosted = (weekdayMask & weekdayMaskBoosted) != 0;
return currentDayBoosted;
}