@SuppressWarnings({ "rawtypes" }) private static @Nonnull List<IConfigElement> getConfigElements() { final List<IConfigElement> list = new ArrayList<IConfigElement>(); for (final String cat : Config.getConfig().getCategoryNames()) { final ConfigCategory cc = Config.getConfig().getCategory(cat); if (cc.isChild()) continue; final ConfigElement ce = new ConfigElement<String>(cc); list.add(ce); } return list; }
private static List<IConfigElement> getConfigElements() { PROPERTIES.clear(); ImmutableList.Builder<IConfigElement> builder = ImmutableList.builder(); Map<String, AuthlibLoginHelper.Data> accounts = AuthlibLoginHelper.getInstance().listAccounts(); for (Map.Entry<String, AuthlibLoginHelper.Data> entry : accounts.entrySet()) { String name = entry.getKey(); AuthlibLoginHelper.Data data = entry.getValue(); boolean skip = data.userid.isEmpty() && !data.accessToken.isPresent(); String[] choices = skip ? SKIP_CHOICES.toArray(new String[0]) : LOGIN_CHOICES.toArray(new String[0]); Property property = new Property(name, choices[0], Property.Type.STRING, choices); property.setComment(skip ? SKIP_COMMENT : LOGIN_COMMENT); builder.add(new ConfigElement(property)); PROPERTIES.put(name, property); } return builder.build(); }
@Override protected GuiScreen buildChildScreen() { List<IConfigElement> list = new ArrayList<IConfigElement>(); list.add(new DummyCategoryElement("forgeChunkLoadingModCfg", "forge.configgui.ctgy.forgeChunkLoadingModConfig", ModOverridesEntry.class)); list.addAll((new ConfigElement(ForgeChunkManager.getDefaultsCategory())).getChildElements()); // This GuiConfig object specifies the configID of the object and as such will force-save when it is closed. The parent // GuiConfig object's propertyList will also be refreshed to reflect the changes. return new GuiConfig(this.owningScreen, list, this.owningScreen.modID, "chunkLoader", this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, GuiConfig.getAbridgedConfigPath(ForgeChunkManager.getConfig().toString()), I18n.format("forge.configgui.ctgy.forgeChunkLoadingConfig")); }
/** * This method is called in the constructor and is used to set the childScreen field. */ @Override protected GuiScreen buildChildScreen() { List<IConfigElement> list = new ArrayList<IConfigElement>(); list.add(new DummyCategoryElement("addForgeChunkLoadingModCfg", "forge.configgui.ctgy.forgeChunkLoadingAddModConfig", AddModOverrideEntry.class)); for (ConfigCategory cc : ForgeChunkManager.getModCategories()) list.add(new ConfigElement(cc)); return new GuiConfig(this.owningScreen, list, this.owningScreen.modID, this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, this.owningScreen.title, I18n.format("forge.configgui.ctgy.forgeChunkLoadingModConfig")); }
/** Create configuration element list */ private static List<IConfigElement> getElements() { ArrayList<IConfigElement> list = new ArrayList<IConfigElement>(); List<IConfigElement> listGeneral = new ConfigElement( ThaumOresMod.config.getInstance().getCategory(TOConfig.categoryGeneral)).getChildElements(); List<IConfigElement> listDebug = new ConfigElement( ThaumOresMod.config.getInstance().getCategory(TOConfig.categoryDebug)).getChildElements(); List<IConfigElement> listGeneration = new ConfigElement( ThaumOresMod.config.getInstance().getCategory(TOConfig.categoryGeneration)).getChildElements(); list.add(new DummyCategoryElement(TOConfig.categoryGeneral, TOConfig.categoryGeneral, listGeneral)); list.add(new DummyCategoryElement(TOConfig.categoryDebug, TOConfig.categoryDebug, listDebug)); list.add(new DummyCategoryElement(TOConfig.categoryGeneration, TOConfig.categoryGeneration, listGeneration)); return list; }
private static List<IConfigElement> getConfigElements(GuiScreen parent) { List<IConfigElement> list = new ArrayList<IConfigElement>(); String[] names = new String[]{ Config.CATEGORY_CLIENT, Config.CATEGORY_WORLD, Config.CATEGORY_ENTITY, Config.CATEGORY_ITEM, Config.CATEGORY_BLOCKS, Config.CATEGORY_MACHINE, Config.CATEGORY_MINIONS }; for (String section : names) { list.add(new ConfigElement(CrystalMod.proxy.mainConfig.getCategory(section).setLanguageKey(Lang.prefix+"config." + section.toLowerCase()))); } return list; }
@Override protected GuiScreen buildChildScreen() { List<IConfigElement> list = new ArrayList<IConfigElement>(); list.add(new DummyCategoryElement("forgeChunkLoadingModCfg", "forge.configgui.ctgy.forgeChunkLoadingModConfig", ModOverridesEntry.class)); list.addAll((new ConfigElement(ForgeChunkManager.getDefaultsCategory())).getChildElements()); // This GuiConfig object specifies the configID of the object and as such will force-save when it is closed. The parent // GuiConfig object's propertyList will also be refreshed to reflect the changes. return new GuiConfig(this.owningScreen, list, this.owningScreen.modID, "chunkLoader", this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, GuiConfig.getAbridgedConfigPath(ForgeChunkManager.getConfig().toString()), I18n.func_135052_a("forge.configgui.ctgy.forgeChunkLoadingConfig")); }
/** * This method is called in the constructor and is used to set the childScreen field. */ @Override protected GuiScreen buildChildScreen() { List<IConfigElement> list = new ArrayList<IConfigElement>(); list.add(new DummyCategoryElement("addForgeChunkLoadingModCfg", "forge.configgui.ctgy.forgeChunkLoadingAddModConfig", AddModOverrideEntry.class)); for (ConfigCategory cc : ForgeChunkManager.getModCategories()) list.add(new ConfigElement(cc)); return new GuiConfig(this.owningScreen, list, this.owningScreen.modID, this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, this.owningScreen.title, I18n.func_135052_a("forge.configgui.ctgy.forgeChunkLoadingModConfig")); }
@SuppressWarnings("rawtypes") private static @Nonnull List<IConfigElement> getConfigElements() { final List<IConfigElement> list = new ArrayList<IConfigElement>(); for (final String cat : Config.getConfig().getCategoryNames()) { final ConfigCategory cc = Config.getConfig().getCategory(cat); if (cc.isChild()) continue; final ConfigElement ce = new ConfigElement<String>(cc); list.add(ce); } return list; }
private static List<IConfigElement> getConfigElements() { List<IConfigElement> elements = new ArrayList<IConfigElement>(); for (String name : Blockbuster.proxy.forge.getCategoryNames()) { ConfigCategory category = Blockbuster.proxy.forge.getCategory(name); category.setLanguageKey("blockbuster.config." + name + ".title"); if (name.indexOf(".") == -1) { elements.add(new ConfigElement(category)); } } return elements; }
@Override protected GuiScreen buildChildScreen() { Configuration configuration = ModConfiguration.getConfig(); ConfigElement configurationCategory = new ConfigElement(configuration.getCategory(ModConfiguration.CATEGORY_NUGGETS)); List<IConfigElement> propertiesOnThisScreen = configurationCategory.getChildElements(); String windowTitle = I18n.format("uncrafting.options.nuggets"); return new GuiConfig(this.owningScreen, propertiesOnThisScreen, this.owningScreen.modID, ModConfiguration.CATEGORY_NUGGETS, this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, windowTitle ); }
public static List<IConfigElement> getElements() { buttonorder.clear(); for (int i = 0; i < JEIButtons.btnCustom.length; i++) { buttonorder.add("enableCustomButton." + i); buttonorder.add("customName." + i); buttonorder.add("customCommand." + i); } List<IConfigElement> entries = new ArrayList<IConfigElement>(); for (String name : ConfigHandler.config.getCategoryNames()) if (name.equals(ConfigHandler.CATEGORY_CUSTOM)) entries.add(new ConfigElement(ConfigHandler.config.getCategory(name).setPropertyOrder(buttonorder))); else entries.add(new ConfigElement(ConfigHandler.config.getCategory(name))); return entries; }
@SuppressWarnings("rawtypes") private static List<IConfigElement> getConfigElements() { final List<IConfigElement> list = new ArrayList<IConfigElement>(); for (final String cat : ConfigHandler.instance.getCategoryNames()) { final ConfigCategory cc = ConfigHandler.instance.getCategory(cat); if (cc.isChild()) continue; final ConfigElement ce = new ConfigElement<String>(cc); list.add(ce); } return list; }
private static List<IConfigElement> getConfigElements() { List<IConfigElement> ret = new ArrayList(); Configuration config = NeiLotr.mod.getConfig().getConfigFile(); for (String category : config.getCategoryNames()) { ret.addAll(new ConfigElement(config.getCategory(category)).getChildElements()); } return ret; }
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; }
private static List<IConfigElement> getConfigElements() { List<IConfigElement> configElements = new ArrayList<IConfigElement>(); Configuration config = ModConfig.CONFIG; if (config != null) { ConfigCategory categoryClient = config.getCategory(ModConfig.CLIENT_CAT); configElements.addAll(new ConfigElement(categoryClient).getChildElements()); } return configElements; }
@Override protected GuiScreen buildChildScreen() { Configuration config = VExConfig.getConfig(); ConfigElement categoryBlocks = new ConfigElement(config.getCategory(VExConfig.CATEGORY_NAME_BLOCKS)); List<IConfigElement> propertiesOnScreen = categoryBlocks.getChildElements(); String windowTitle = I18n.format("gui.config.category.blocks"); return new GuiConfig(owningScreen, propertiesOnScreen, owningScreen.modID, this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, windowTitle); }
@SuppressWarnings({ "rawtypes" }) private static List<IConfigElement> getElements() { List<IConfigElement> list = new ArrayList<IConfigElement>(); for (String category : ConfigurationHandler.INSTANCE.usedCategories) list.add(new ConfigElement(ConfigurationHandler.INSTANCE.configFile.getCategory(category))); return list; }
@SuppressWarnings("unchecked") public List<IConfigElement> getConfigElements() { List<IConfigElement> list = new ArrayList<>(); list.addAll(new ConfigElement(config.getCategory(NETWORK_PICKER)).getChildElements()); list.addAll(new ConfigElement(config.getCategory(NETWORK_BAG)).getChildElements()); list.addAll(new ConfigElement(config.getCategory(INFINITE_WIRELESS_TRANSMITTER)).getChildElements()); list.addAll(new ConfigElement(config.getCategory(WIRELESS_CRAFTING_GRID)).getChildElements()); return list; }
private static List<IConfigElement> getConfigElements() { List<IConfigElement> configElements = new ArrayList<IConfigElement>(); Configuration config = Config.getConfig(); if (config != null) { ConfigCategory category = config.getCategory(Config.getCategory()); configElements.addAll(new ConfigElement(category).getChildElements()); } return configElements; }
public static List<IConfigElement> getEntries() { List<IConfigElement> entries = new ArrayList<IConfigElement>(); Set<String> categories = config.getCategoryNames(); Iterator<String> i = categories.iterator(); while (i.hasNext()) { String categoryName = i.next(); ConfigCategory category = config.getCategory(categoryName); entries.addAll(new ConfigElement(category).getChildElements()); } return entries; }
public static List<IConfigElement> getElements() { ArrayList<IConfigElement> configElements = new ArrayList<>(); configElements.add(new ConfigElement(TF2weapons.conf.getCategory("modcompatibility"))); configElements.add(new ConfigElement(TF2weapons.conf.getCategory("spawn rate"))); configElements.add(new ConfigElement(TF2weapons.conf.getCategory("world gen"))); configElements.add(new ConfigElement(TF2weapons.conf.getCategory("default building targets"))); configElements.add(new ConfigElement(TF2weapons.conf.getCategory("sound volume"))); configElements.addAll(new ConfigElement(TF2weapons.conf.getCategory("gameplay")).getChildElements()); return configElements; /*List<IConfigElement> list = new ConfigElement(TF2weapons.conf.getCategory("gameplay")).getChildElements(); list.addAll(new ConfigElement(TF2weapons.conf.getCategory("modcompatibility")).getChildElements()); return list;*/ }
public YouTubeConfigurationGui(GuiScreen parentScreen) { super( parentScreen, new ConfigElement( YouTubeConfiguration.getInstance() .getConfig() .getCategory(Configuration.CATEGORY_GENERAL)) .getChildElements(), YouTubeChat.MODID, false, false, "YouTube Chat"); }
@Override protected GuiScreen buildChildScreen() { // This GuiConfig object specifies the configID of the object and as such will force-save when it is closed. The parent // GuiConfig object's entryList will also be refreshed to reflect the changes. return new GuiConfig(this.owningScreen, (new ConfigElement(ForgeModContainer.getConfig().getCategory(Configuration.CATEGORY_GENERAL))).getChildElements(), this.owningScreen.modID, Configuration.CATEGORY_GENERAL, this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, GuiConfig.getAbridgedConfigPath(ForgeModContainer.getConfig().toString())); }
@Override protected GuiScreen buildChildScreen() { // This GuiConfig object specifies the configID of the object and as such will force-save when it is closed. The parent // GuiConfig object's entryList will also be refreshed to reflect the changes. return new GuiConfig(this.owningScreen, (new ConfigElement(ForgeModContainer.getConfig().getCategory(Configuration.CATEGORY_CLIENT))).getChildElements(), this.owningScreen.modID, Configuration.CATEGORY_CLIENT, this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, GuiConfig.getAbridgedConfigPath(ForgeModContainer.getConfig().toString())); }
@Override protected GuiScreen buildChildScreen() { ConfigCategory cfg = ForgeModContainer.getConfig().getCategory(VERSION_CHECK_CAT); Map<String, Property> values = new HashMap<String, Property>(cfg.getValues()); values.remove("Global"); Property global = ForgeModContainer.getConfig().get(VERSION_CHECK_CAT, "Global", true); List<Property> props = new ArrayList<Property>(); for (ModContainer mod : ForgeVersion.gatherMods().keySet()) { values.remove(mod.getModId()); props.add(ForgeModContainer.getConfig().get(VERSION_CHECK_CAT, mod.getModId(), true)); //Get or make the value in the config } props.addAll(values.values()); // Add any left overs from the config Collections.sort(props, new Comparator<Property>() { @Override public int compare(Property o1, Property o2) { return o1.getName().compareTo(o2.getName()); } }); List<IConfigElement> list = new ArrayList<IConfigElement>(); list.add(new ConfigElement(global)); for (Property prop : props) { list.add(new ConfigElement(prop)); } // This GuiConfig object specifies the configID of the object and as such will force-save when it is closed. The parent // GuiConfig object's propertyList will also be refreshed to reflect the changes. return new GuiConfig(this.owningScreen, list, this.owningScreen.modID, VERSION_CHECK_CAT, true, true, GuiConfig.getAbridgedConfigPath(ForgeModContainer.getConfig().toString())); }
@Override protected GuiScreen buildChildScreen() { List<IConfigElement> list = new ArrayList<IConfigElement>(); list.add(new DummyConfigElement("modID", "", ConfigGuiType.STRING, "forge.configgui.modID").setCustomListEntryClass(ModIDEntry.class)); list.add(new ConfigElement(new Property("maximumTicketCount", "200", Property.Type.INTEGER, "forge.configgui.maximumTicketCount"))); list.add(new ConfigElement(new Property("maximumChunksPerTicket", "25", Property.Type.INTEGER, "forge.configgui.maximumChunksPerTicket"))); return new GuiConfig(this.owningScreen, list, this.owningScreen.modID, this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, this.owningScreen.title, I18n.format("forge.configgui.ctgy.forgeChunkLoadingAddModConfig")); }
public GuiConfigMod(GuiScreen parent) { super(parent, new ConfigElement( MacroKey.instance.configuration.getCategory(Configuration.CATEGORY_GENERAL)) .getChildElements(), Reference.MOD_ID, false, false, "Config Options for MacroKey"); titleLine2 = MacroKey.instance.configuration.getConfigFile().getAbsolutePath(); }
private static List<IConfigElement> getConfigElements(GuiScreen parent) { List<IConfigElement> list = new ArrayList<IConfigElement>(); String prefix = MvesMod.MODID + ".config."; for (Section section : Section.values()) { if (!section.sync || !CONFIGHANDLER.configLockedByServer) { list.add(new ConfigElement(CONFIGHANDLER.configuration.getCategory(section.name).setLanguageKey(prefix + section.name))); } } return list; }
public GuiConfigDailies(GuiScreen parent) { super (parent, new ConfigElement(ConfigurationHandler.config.getCategory(Configuration.CATEGORY_CLIENT)).getChildElements(), DailiesMod.MODID, false, false, DailiesMod.metadata.name); titleLine2 = ConfigurationHandler.config.getConfigFile().getAbsolutePath(); }
public static List<IConfigElement> getConfigElements() { List<IConfigElement> list = new ArrayList<IConfigElement>(); list.addAll(new ConfigElement(config.getCategory(Constants.CONFIG_CATEGORY_DIMENSIONS)).getChildElements()); list.addAll(new ConfigElement(config.getCategory(Constants.CONFIG_CATEGORY_SCHEMATIC)).getChildElements()); list.addAll(new ConfigElement(config.getCategory(Constants.CONFIG_CATEGORY_ACHIEVEMENTS)).getChildElements()); list.addAll(new ConfigElement(config.getCategory(Constants.CONFIG_CATEGORY_ENTITIES)).getChildElements()); list.addAll(new ConfigElement(config.getCategory(Constants.CONFIG_CATEGORY_GENERAL)).getChildElements()); return list; }
public MuonGuiConfig(GuiScreen parent) { super(parent, new ConfigElement(MuonConfig.getConfig().getCategory(MuonConfig.CATEGORY_GENERATION)).getChildElements(), "muon", false, false, "Muon "+MuonConfig.config.getCategory(MuonConfig.CATEGORY_GENERATION).getName(), MuonConfig.config.getConfigFile().getName()); }
@Override protected GuiScreen buildChildScreen() { List<IConfigElement> list = new ArrayList<IConfigElement>(); list.add(new DummyConfigElement("modID", "", ConfigGuiType.STRING, "forge.configgui.modID").setCustomListEntryClass(ModIDEntry.class)); list.add(new ConfigElement<Integer>(new Property("maximumTicketCount", "200", Property.Type.INTEGER, "forge.configgui.maximumTicketCount"))); list.add(new ConfigElement<Integer>(new Property("maximumChunksPerTicket", "25", Property.Type.INTEGER, "forge.configgui.maximumChunksPerTicket"))); return new GuiConfig(this.owningScreen, list, this.owningScreen.modID, this.configElement.requiresWorldRestart() || this.owningScreen.allRequireWorldRestart, this.configElement.requiresMcRestart() || this.owningScreen.allRequireMcRestart, this.owningScreen.title, I18n.func_135052_a("forge.configgui.ctgy.forgeChunkLoadingAddModConfig")); }
private static List<IConfigElement> getConfigElements() { List<IConfigElement> elements = new ArrayList<IConfigElement>(); for (String name : Metamorph.proxy.forge.getCategoryNames()) { ConfigCategory category = Metamorph.proxy.forge.getCategory(name); category.setLanguageKey("metamorph.config." + name + ".title"); elements.add(new ConfigElement(category)); } return elements; }
private static List<IConfigElement> getConfigElements(GuiScreen parent) { List<IConfigElement> list = new ArrayList<IConfigElement>(); String prefix = TravelHutMod.MODID + ".config."; for (Section section : Section.values()) { if (!section.sync || !ConfigHandler.configLockedByServer) { list.add(new ConfigElement(ConfigHandler.configuration.getCategory(section.name).setLanguageKey(prefix + section.name))); } } return list; }
private static List<IConfigElement> getConfigCategories() { List<IConfigElement> categories = new ArrayList<IConfigElement>(); for (String category : ModConfig.configuration.getCategoryNames()) { ConfigCategory cc = ModConfig.configuration.getCategory(category); if (cc.isChild()) continue; ConfigElement ce = new ConfigElement(cc); categories.add(ce); } return categories; }