From 8c9c98e896e4dd25e3c3ea1b586473ff89856aa4 Mon Sep 17 00:00:00 2001 From: NotAdam Date: Thu, 31 Jan 2019 23:55:55 +1100 Subject: [PATCH] Revert "fix npcs not facing target after being pushed" This reverts commit 692c32b934239bbffe5b47f50536877ba4628238. --- src/world/Actor/BNpc.cpp | 5 ++--- src/world/Actor/BNpc.h | 2 +- 2 files changed, 3 insertions(+), 4 deletions(-) diff --git a/src/world/Actor/BNpc.cpp b/src/world/Actor/BNpc.cpp index 145bd6f8..97dd4db9 100644 --- a/src/world/Actor/BNpc.cpp +++ b/src/world/Actor/BNpc.cpp @@ -222,7 +222,7 @@ bool Sapphire::Entity::BNpc::moveTo( const FFXIVARR_POSITION3& pos ) { // do this first, this will update local actor position and the position of other actors // and then this npc will then path from the position after pushing/being pushed - pushNearbyBNpcs( pos ); + pushNearbyBNpcs(); if( Util::distance( getPos(), pos ) <= m_naviTargetReachedDistance ) { @@ -629,7 +629,7 @@ void Sapphire::Entity::BNpc::checkAggro() } } -void Sapphire::Entity::BNpc::pushNearbyBNpcs( const Common::FFXIVARR_POSITION3& pos ) +void Sapphire::Entity::BNpc::pushNearbyBNpcs() { for( auto& bNpc : m_inRangeBNpc ) { @@ -651,7 +651,6 @@ void Sapphire::Entity::BNpc::pushNearbyBNpcs( const Common::FFXIVARR_POSITION3& auto x = ( cosf( angle ) ); auto z = ( sinf( angle ) ); - bNpc->face( pos ); bNpc->setPos( pos.x + ( x * factor * delta ), pos.y, pos.z + ( z * factor * delta ) ); diff --git a/src/world/Actor/BNpc.h b/src/world/Actor/BNpc.h index d13f7eea..429203ec 100644 --- a/src/world/Actor/BNpc.h +++ b/src/world/Actor/BNpc.h @@ -98,7 +98,7 @@ namespace Sapphire::Entity void checkAggro(); - void pushNearbyBNpcs( const Common::FFXIVARR_POSITION3& pos ); + void pushNearbyBNpcs(); private: uint32_t m_bNpcBaseId;