Skip to content

Commit 7e7ac72

Browse files
committed
fix: don't reset team winstreak count before printing the message to chat
this caused the T winstreak message to always say "0 wins in a row"
1 parent 83867db commit 7e7ac72

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Diff for: TeamSwitchManager.cs

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ public void Start()
2828
var winner = @event.Winner;
2929
if (winner == (int)CsTeam.CounterTerrorist)
3030
{
31-
_terroristWinstreak = 0;
3231
ChaseModUtils.ChatAllPrefixed($"{ChatColors.Blue}CT {ChatColors.Grey}Win - Teams are being switched.");
32+
_terroristWinstreak = 0;
3333
Server.NextFrame(() =>
3434
{
3535
SwitchTeams();
@@ -40,8 +40,8 @@ public void Start()
4040
_terroristWinstreak++;
4141
if (_plugin.Config.MaxTerroristWinStreak > 0 && _terroristWinstreak >= _plugin.Config.MaxTerroristWinStreak)
4242
{
43-
_terroristWinstreak = 0;
4443
ChaseModUtils.ChatAllPrefixed($"{ChatColors.Yellow}T {ChatColors.Grey}Win - Teams are being switched due to winstreak. ({_terroristWinstreak} wins in a row)");
44+
_terroristWinstreak = 0;
4545
Server.NextFrame(() =>
4646
{
4747
SwitchTeams();

0 commit comments

Comments
 (0)