/**
* Creates a integer property.
*
* @param name Name of the property.
* @param category Category of the property.
* @param defaultValue Default value of the property.
* @param minValue Minimum value of the property.
* @param maxValue Maximum value of the property.
* @param comment A brief description what the property does.
* @param langKey A language key used for localization of GUIs
* @return The value of the new integer property.
*/
public int getInt(String name, String category, int defaultValue, int minValue, int maxValue, String comment, String langKey)
{
Property prop = this.get(category, name, defaultValue);
prop.setLanguageKey(langKey);
prop.setComment(comment + " [range: " + minValue + " ~ " + maxValue + ", default: " + defaultValue + "]");
prop.setMinValue(minValue);
prop.setMaxValue(maxValue);
return prop.getInt(defaultValue) < minValue ? minValue : (prop.getInt(defaultValue) > maxValue ? maxValue : prop.getInt(defaultValue));
}
As you can see it returns min value if value in config lower than it. It means the default zero value is will be translated always to 1.
As we can see there passed the 1 as min value https://github.com/Shadows-of-Fire/Foundry/blob/1.12.2/src/main/java/exter/foundry/config/FoundryConfig.java#L65
And there implementation of getInt in forge
As you can see it returns min value if value in config lower than it. It means the default zero value is will be translated always to 1.