Skip to content

Commit

Permalink
remove ULV from overclock button
Browse files Browse the repository at this point in the history
  • Loading branch information
serenibyss committed Aug 9, 2021
1 parent 98a6ca6 commit 019ed53
Showing 1 changed file with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -294,9 +294,9 @@ protected long getVoltageByTier(final int tier) {

public String[] getAvailableOverclockingTiers() {
final int maxTier = getOverclockingTier(getMaxVoltage());
final String[] result = new String[maxTier + 2];
final String[] result = new String[maxTier + 1];
result[0] = "gregtech.gui.overclock.off";
if (maxTier + 1 >= 0) System.arraycopy(GTValues.VN, 0, result, 1, maxTier + 1);
if (maxTier >= 0) System.arraycopy(GTValues.VN, 1, result, 1, maxTier);
return result;
}

Expand Down Expand Up @@ -422,21 +422,19 @@ public void enableOverclockVoltage() {
setOverclockVoltage(getMaxVoltage());
}

// The overclocking tier
// it is 1 greater than the index into GTValues.V since here the "0 tier" represents 0 EU or no overclock
public int getOverclockTier() {
if (this.overclockVoltage == 0) {
return 0;
}
return 1 + getOverclockingTier(this.overclockVoltage);
return getOverclockingTier(this.overclockVoltage);
}

public void setOverclockTier(final int tier) {
if (tier == 0) {
setOverclockVoltage(0);
return;
}
setOverclockVoltage(getVoltageByTier(tier - 1));
setOverclockVoltage(getVoltageByTier(tier));
}

@Override
Expand Down

0 comments on commit 019ed53

Please sign in to comment.