Clean up minor code change

This commit is contained in:
Patrick
2022-06-23 18:40:21 +04:00
parent 8454c3602b
commit b3c2966365

View File

@@ -124,14 +124,14 @@ public class EasyGiantsFoundryPlugin extends Plugin
@Subscribe @Subscribe
public void onStatChanged(StatChanged statChanged) public void onStatChanged(StatChanged statChanged)
{ {
final int currBoost = statChanged.getBoostedLevel(); final int curBoost = statChanged.getBoostedLevel();
// if the difference between current and last boost is != 0 then a stat boost (or drop) change occurred // if the difference between current and last boost is != 0 then a stat boost (or drop) change occurred
if (!statChanged.getSkill().equals(Skill.SMITHING) || if (!statChanged.getSkill().equals(Skill.SMITHING) ||
currBoost - lastBoost != 0 || curBoost != lastBoost ||
!state.isEnabled() || !state.isEnabled() ||
state.getCurrentStage() == null) state.getCurrentStage() == null)
{ {
lastBoost = currBoost; lastBoost = curBoost;
return; return;
} }