Skip to content

Commit

Permalink
fix: ensure skill point addition is pre-setting for syncing reasons
Browse files Browse the repository at this point in the history
  • Loading branch information
TisRyno committed Apr 8, 2024
1 parent 214de7e commit 3f9665e
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions LethalProgression/SkillGUI.cs
Original file line number Diff line number Diff line change
Expand Up @@ -332,16 +332,15 @@ public void RemoveSkillPoint(Skill skill, int amt)
amt = allocatedPoints;
}

skill.AddLevel(-amt);

// Add skill points first to stop desync
LP_NetworkManager.xpInstance.SetSkillPoints(LP_NetworkManager.xpInstance.GetSkillPoints() + amt);

skill.AddLevel(-amt);
UpdateStatInfo(skill);

foreach (var button in skillButtonsList)
{
if (button.name == skill.GetShortName())
LoadSkillData(skill, button);
}
}

// START SPECIAL BOYS:
Expand Down

0 comments on commit 3f9665e

Please sign in to comment.