Skip to content

Commit

Permalink
[Gamepad] Prevent player applying stat points to maxed stat
Browse files Browse the repository at this point in the history
  • Loading branch information
StephenCWills authored and AJenbo committed Oct 28, 2021
1 parent e2408bc commit f090da3
Showing 1 changed file with 2 additions and 9 deletions.
11 changes: 2 additions & 9 deletions Source/controls/plrctrls.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1460,15 +1460,8 @@ void PerformPrimaryAction()

if (chrflag && !chrbtnactive && Players[MyPlayerId]._pStatPts > 0) {
CheckChrBtns();
for (int i = 0; i < 4; i++) {
Rectangle button = ChrBtnsRect[i];
button.position = GetPanelPosition(UiPanels::Character, button.position);
if (button.Contains(MousePosition)) {
chrbtn[i] = true;
chrbtnactive = true;
ReleaseChrBtns(false);
}
}
if (chrbtnactive)
ReleaseChrBtns(false);
return;
}

Expand Down

0 comments on commit f090da3

Please sign in to comment.