Skip to content

Commit

Permalink
Fix buffs not sending updates in some cases
Browse files Browse the repository at this point in the history
If no other buff was present, a selft casted concentration buff only updated the concentration amount, not the stat.
Similar to the issue 578c21e fixed.
  • Loading branch information
bm01 committed Nov 11, 2024
1 parent 4601f7f commit f604e98
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions GameServer/ECS-Components/EffectListComponent.cs
Original file line number Diff line number Diff line change
Expand Up @@ -188,11 +188,9 @@ public void RequestPlayerUpdate(EffectService.PlayerUpdate playerUpdate)
RequestedPlayerUpdates |= playerUpdate;
}

// Force an update in case our effect list component isn't ticking.
// This should only happen when the caster doesn't have any effect and is casting a concentration buff on another target.
// Alternatively we could add it to the entity manager, then it would send updates before being removed, but the end result is the same.
if (!EntityManagerId.IsSet)
SendPlayerUpdates();
// Forces an update in case our effect list component isn't ticking.
// Don't call `SendPlayerUpdates` directly.
EntityManager.Add(this);
}

public void SendPlayerUpdates()
Expand Down

0 comments on commit f604e98

Please sign in to comment.