This commit is contained in:
parent
7466529ffd
commit
943eb36e2d
3 changed files with 10 additions and 3 deletions
|
@ -1,6 +1,7 @@
|
|||
package de.com.baseband.client;
|
||||
|
||||
import de.com.baseband.prod.LoadHandler;
|
||||
import de.tudbut.parsing.TCNArray;
|
||||
import net.minecraftforge.common.ForgeVersion;
|
||||
import net.minecraftforge.fml.common.Mod;
|
||||
import net.minecraftforge.fml.common.event.FMLPostInitializationEvent;
|
||||
|
@ -32,6 +33,7 @@ public class DevStub implements IFMLLoadingPlugin {
|
|||
LoadHandler.data.set("release-branch", false);
|
||||
LoadHandler.data.set("branch", "[dev]");
|
||||
LoadHandler.data.set("username", "root");
|
||||
LoadHandler.data.set("disabledModules", new TCNArray());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -107,7 +107,6 @@ public abstract class Feature extends ToggleButton implements SetCommand {
|
|||
}
|
||||
|
||||
public final void register(Minecraft mc) {
|
||||
Setup = de.com.baseband.client.Setup.get();
|
||||
this.mc = mc;
|
||||
|
||||
this.text = toString();
|
||||
|
|
|
@ -15,8 +15,14 @@ public class Features {
|
|||
ArrayList<Feature> filteredFeatures = new ArrayList<>(Arrays.asList(Setup.get().Features));
|
||||
for (int i = 0; i < filteredFeatures.size(); i++) {
|
||||
Feature value = filteredFeatures.get(i);
|
||||
if(!value.canExist()) {
|
||||
filteredFeatures.remove(i--);
|
||||
value.Setup = de.com.baseband.client.Setup.get();
|
||||
try {
|
||||
if (!value.canExist()) {
|
||||
filteredFeatures.remove(i--);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
BaseBand.LOGGER.error("Unable to check feature {}", value.toString());
|
||||
}
|
||||
}
|
||||
features = filteredFeatures.toArray(new Feature[0]);
|
||||
|
|
Loading…
Add table
Reference in a new issue