Skip to content

Commit

Permalink
Fix salaries
Browse files Browse the repository at this point in the history
  • Loading branch information
RestoreMonarchy committed Dec 28, 2024
1 parent 10c2ecd commit ac73318
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
6 changes: 4 additions & 2 deletions Uconomy/Services/SalaryService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,13 @@ void OnDestroy()
StopAllCoroutines();
}


private void OnPlayerConnected(UnturnedPlayer player)
{
if (Uconomy.Instance.Configuration.Instance.EnableSalaries)
{
StartCoroutine(GiveSalary(player.CSteamID));
var coroutine = StartCoroutine(GiveSalary(player.CSteamID));
coroutines[player.CSteamID] = coroutine;
}
}

Expand All @@ -60,6 +61,7 @@ private IEnumerator GiveSalary(CSteamID steamID)
Player player = PlayerTool.getPlayer(steamID);
if (player == null)
{
coroutines.Remove(steamID);
yield break;
}

Expand Down
2 changes: 1 addition & 1 deletion Uconomy/Uconomy.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
<LangVersion>latest</LangVersion>
<RootNamespace>fr34kyn01535.Uconomy</RootNamespace>
<AssemblyName>Uconomy</AssemblyName>
<Version>2.1.0</Version>
<Version>2.1.1</Version>
<AssemblyTitle>Uconomy</AssemblyTitle>
</PropertyGroup>

Expand Down

0 comments on commit ac73318

Please sign in to comment.