use of net.minecraftforge.common.config.ConfigElement in project BuildCraft by BuildCraft.
the class BCConfigElement method getChildElements.
@Override
public List<IConfigElement> getChildElements() {
if (!isProp) {
List<IConfigElement> elements = new ArrayList<>();
Iterator<ConfigCategory> ccI = cat.getChildren().iterator();
Iterator<Property> pI = cat.getOrderedValues().iterator();
while (ccI.hasNext()) {
ConfigCategory child = ccI.next();
if (!child.parent.getQualifiedName().equals(cat.getQualifiedName())) {
continue;
}
ConfigElement temp = new BCConfigElement(child);
if (temp.showInGui()) {
elements.add(temp);
}
}
while (pI.hasNext()) {
ConfigElement temp = new ConfigElement(pI.next());
if (temp.showInGui()) {
elements.add(temp);
}
}
return elements;
} else {
return null;
}
}
use of net.minecraftforge.common.config.ConfigElement in project BiomesOPlenty by Glitchfiend.
the class GuiBOPFactory method getConfigElements.
private static List<IConfigElement> getConfigElements() {
List<IConfigElement> list = new ArrayList<IConfigElement>();
List<IConfigElement> convenience_settings = new ConfigElement(GameplayConfigurationHandler.config.getCategory(CONVENIENCE_SETTINGS.toLowerCase())).getChildElements();
List<IConfigElement> gui_settings = new ConfigElement(config.getCategory(GUI_SETTINGS.toLowerCase())).getChildElements();
List<IConfigElement> texture_settings = new ConfigElement(config.getCategory(VISUAL_SETTINGS.toLowerCase())).getChildElements();
List<IConfigElement> trail_settings = new ConfigElement(config.getCategory(TRAIL_SETTINGS.toLowerCase())).getChildElements();
list.add(new DummyCategoryElement(I18n.translateToLocal("config.category.convenienceSettings.title"), "config.category.convenienceSettings", convenience_settings));
list.add(new DummyCategoryElement(I18n.translateToLocal("config.category.guiSettings.title"), "config.category.guiSettings", gui_settings));
list.add(new DummyCategoryElement(I18n.translateToLocal("config.category.textureSettings.title"), "config.category.textureSettings", texture_settings));
if (TrailManager.trailsMap.containsKey(PlayerUtil.getClientPlayerUUID())) {
list.add(new DummyCategoryElement(I18n.translateToLocal("config.category.trailSettings.title"), "config.category.trailSettings", trail_settings));
}
return list;
}
use of net.minecraftforge.common.config.ConfigElement in project TUMAT by canitzp.
the class GuiConf method getConfigElements.
private static List<IConfigElement> getConfigElements() {
List<IConfigElement> list = new ArrayList<>();
for (int i = 0; i < ConfigCats.values().length; i++) {
ConfigCats cat = ConfigCats.values()[i];
ConfigHandler.config.setCategoryComment(cat.name, cat.desc);
list.add(new ConfigElement(ConfigHandler.config.getCategory(cat.name)));
}
return list;
}
use of net.minecraftforge.common.config.ConfigElement in project BluePower by Qmunity.
the class BPGuiConfig method getConfigElements.
@SuppressWarnings({ "rawtypes", "unchecked" })
private static List<IConfigElement> getConfigElements() {
List<IConfigElement> list = new ArrayList<IConfigElement>();
List<IConfigElement> listZinc = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_ZINC)).getChildElements();
List<IConfigElement> listCopper = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_COPPER)).getChildElements();
List<IConfigElement> listSilver = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_SILVER)).getChildElements();
List<IConfigElement> listTungsten = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_TUNGSTEN)).getChildElements();
List<IConfigElement> listRuby = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_RUBY)).getChildElements();
List<IConfigElement> listAmethyst = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_AMETHYST)).getChildElements();
List<IConfigElement> listSapphire = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_SAPPHIRE)).getChildElements();
List<IConfigElement> listTeslatite = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_TESLATITE)).getChildElements();
List<IConfigElement> listWorldGen = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_WORLDGEN)).getChildElements();
List<IConfigElement> listSettings = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_SETTINGS)).getChildElements();
List<IConfigElement> listRecipes = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_RECIPES)).getChildElements();
List<IConfigElement> listEnchants = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_ENCHANTS)).getChildElements();
List<IConfigElement> listPneumaticTube = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_TUBES)).getChildElements();
List<IConfigElement> listCircuitDatabase = new ConfigElement(BluePower.config.getCategory(Refs.CONFIG_CIRCUIT_DATABASE)).getChildElements();
list.add(new DummyConfigElement.DummyCategoryElement("World Gen", "config.bluepower:worldgen", listWorldGen));
list.add(new DummyConfigElement.DummyCategoryElement("Settings", "config.bluepower:settings", listSettings));
list.add(new DummyConfigElement.DummyCategoryElement("Recipes", "config.bluepower:recipes", listRecipes));
list.add(new DummyConfigElement.DummyCategoryElement("Enchantments", "config.bluepower:enchantments", listEnchants));
list.add(new DummyConfigElement.DummyCategoryElement("Pneumatic Tubes", "config.bluepower:tubes", listPneumaticTube));
list.add(new DummyConfigElement.DummyCategoryElement("Circuit Database", "config.bluepower:circuitDatabase", listCircuitDatabase));
list.add(new DummyConfigElement.DummyCategoryElement("Copper", "config.bluepower:copper", listCopper));
list.add(new DummyConfigElement.DummyCategoryElement("Zinc", "config.bluepower:zinc", listZinc));
list.add(new DummyConfigElement.DummyCategoryElement("Silver", "config.bluepower:silver", listSilver));
list.add(new DummyConfigElement.DummyCategoryElement("Tungsten", "config.bluepower:tungsten", listTungsten));
list.add(new DummyConfigElement.DummyCategoryElement("Ruby", "config.bluepower:ruby", listRuby));
list.add(new DummyConfigElement.DummyCategoryElement("Amethyst", "config.bluepower:amethyst", listAmethyst));
list.add(new DummyConfigElement.DummyCategoryElement("Sapphire", "config.bluepower:sapphire", listSapphire));
list.add(new DummyConfigElement.DummyCategoryElement("Teslatite", "config.bluepower:teslatite", listTeslatite));
return list;
}
use of net.minecraftforge.common.config.ConfigElement in project Geolosys by oitsjustjose.
the class ConfigGUI method getConfigElements.
private static List<IConfigElement> getConfigElements() {
ArrayList<IConfigElement> list = new ArrayList<IConfigElement>();
list.add(new ConfigElement(Config.getInstance().FeatureControl));
list.add(new ConfigElement(Config.getInstance().Samples));
list.add(new ConfigElement(Config.getInstance().UserEntries));
return list;
}
Aggregations