From 9adbb7aa86a134707a9b5470d1bf83fb24ba5f90 Mon Sep 17 00:00:00 2001 From: David Markowitz <39972741+EmosewaMC@users.noreply.github.com> Date: Thu, 29 Dec 2022 06:34:53 -0800 Subject: [PATCH] Address World Server Packet timing and erroneous log (#929) * Fix overread in projectile behavior * Fix stuns * Correctly read in bitStream * Fix projectile behavior * Address movement type issues * Update shutdown time to be accurate * Fix small issues --- dGame/dBehaviors/BasicAttackBehavior.cpp | 2 +- dWorldServer/WorldServer.cpp | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dGame/dBehaviors/BasicAttackBehavior.cpp b/dGame/dBehaviors/BasicAttackBehavior.cpp index 0378cb5e..97068d91 100644 --- a/dGame/dBehaviors/BasicAttackBehavior.cpp +++ b/dGame/dBehaviors/BasicAttackBehavior.cpp @@ -40,7 +40,7 @@ void BasicAttackBehavior::Handle(BehaviorContext* context, RakNet::BitStream* bi void BasicAttackBehavior::DoHandleBehavior(BehaviorContext* context, RakNet::BitStream* bitStream, BehaviorBranchContext branch) { auto* targetEntity = EntityManager::Instance()->GetEntity(branch.target); if (!targetEntity) { - Game::logger->Log("BasicAttackBehavior", "Target targetEntity %i not found.", branch.target); + Game::logger->Log("BasicAttackBehavior", "Target targetEntity %llu not found.", branch.target); return; } diff --git a/dWorldServer/WorldServer.cpp b/dWorldServer/WorldServer.cpp index de6deb2a..73157c09 100644 --- a/dWorldServer/WorldServer.cpp +++ b/dWorldServer/WorldServer.cpp @@ -416,7 +416,7 @@ int main(int argc, char** argv) { HandlePacket(packet); auto t2 = std::chrono::high_resolution_clock::now(); - timeSpent += std::chrono::duration_cast(t2 - t1).count(); + timeSpent += std::chrono::duration_cast>(t2 - t1).count(); Game::server->DeallocatePacket(packet); packet = nullptr; } else {