Allow max size of controller to be configurable (#126)
* modifiable max length of a controller in all 3 axis * added a 1-255 range on the sizes * fixed values to [1, 63]
This commit is contained in:
@@ -117,6 +117,10 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
||||
private double wirelessBoosterExp = 1.5;
|
||||
// Autocrafting
|
||||
private boolean enableCraftingSubstitutes = false;
|
||||
// Controller sizes
|
||||
private int maxControllerSizeX = 7;
|
||||
private int maxControllerSizeY = 7;
|
||||
private int maxControllerSizeZ = 7;
|
||||
|
||||
private AEConfig( final File configFile )
|
||||
{
|
||||
@@ -181,6 +185,11 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
||||
this.addCustomCategoryComment( "autocrafting", "Enable patterns with substitutions on to have their substitutes to be auto craftable.\nThis changes the crafting tree, and can show missing ingredients for the substitute, instead of the patterned item" );
|
||||
this.enableCraftingSubstitutes = this.get( "autocrafting", "EnableAutocraftinSubstitutes", this.enableCraftingSubstitutes ).getBoolean( this.enableCraftingSubstitutes );
|
||||
|
||||
this.addCustomCategoryComment( "ControllerSize", "Set the max size of a controller in any of the 3 axis.\nEach is between [1, 64)" );
|
||||
this.maxControllerSizeX = Math.min(Math.max(this.get( "ControllerSize", "maxControllerSizeX", this.maxControllerSizeX ).getInt(this.maxControllerSizeX), 1), 63);
|
||||
this.maxControllerSizeY = Math.min(Math.max(this.get( "ControllerSize", "maxControllerSizeY", this.maxControllerSizeY ).getInt(this.maxControllerSizeY), 1), 63);
|
||||
this.maxControllerSizeZ = Math.min(Math.max(this.get( "ControllerSize", "maxControllerSizeZ", this.maxControllerSizeZ ).getInt(this.maxControllerSizeZ), 1), 63);
|
||||
|
||||
this.clientSync();
|
||||
|
||||
this.addCustomCategoryComment( "features", "Warning: Disabling a feature may disable other features depending on it." );
|
||||
@@ -763,4 +772,10 @@ public final class AEConfig extends Configuration implements IConfigurableObject
|
||||
{
|
||||
return this.enableCraftingSubstitutes;
|
||||
}
|
||||
|
||||
public int getMaxControllerSizeX() { return this.maxControllerSizeX; }
|
||||
|
||||
public int getMaxControllerSizeY() { return this.maxControllerSizeY; }
|
||||
|
||||
public int getMaxControllerSizeZ() { return this.maxControllerSizeZ; }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user