[Fix] GMMove Update Edge Case With Clients (#4686)

* [Fix] GMMove with clients

* Exclude clients entirely for position update caching
This commit is contained in:
Chris Miles
2025-02-15 16:20:37 -06:00
committed by GitHub
parent 02e2f6771c
commit e88ea24966
+2 -2
View File
@@ -851,7 +851,7 @@ void MobMovementManager::SendCommandToClients(
_impl->Stats.TotalSentPosition++;
}
if (c->m_last_seen_mob_position.contains(mob->GetID())) {
if (!mob->IsClient() && c->m_last_seen_mob_position.contains(mob->GetID())) {
if (c->m_last_seen_mob_position[mob->GetID()] == mob->GetPosition() && anim == 0) {
LogPositionUpdate(
"Mob [{}] has already been sent to client [{}] at this position, skipping",
@@ -913,7 +913,7 @@ void MobMovementManager::SendCommandToClients(
_impl->Stats.TotalSentPosition++;
}
if (c->m_last_seen_mob_position.contains(mob->GetID())) {
if (!mob->IsClient() && c->m_last_seen_mob_position.contains(mob->GetID())) {
if (c->m_last_seen_mob_position[mob->GetID()] == mob->GetPosition() && anim == 0) {
LogPositionUpdate(
"Mob [{}] has already been sent to client [{}] at this position, skipping",