Skip to content

Commit

Permalink
Add new setting logEligibilityErrors, and put all instances of "Unabl…
Browse files Browse the repository at this point in the history
…e to determine blocks eligibility..." behind it
  • Loading branch information
AlgorithmX2 committed Jan 23, 2019
1 parent 47f3e20 commit d07d5e7
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 1 deletion.
Expand Up @@ -291,7 +291,7 @@ private static Class<?> getDeclaringClass(
}
catch ( final NoClassDefFoundError e )
{
Log.info( "Unable to determine blocks eligibility for chiseling, " + blkClass.getName() + " attempted to load " + e.getMessage() );
Log.eligibility( "Unable to determine blocks eligibility for chiseling, " + blkClass.getName() + " attempted to load " + e.getMessage() + " missing @SideOnly( Side.CLIENT ) or @Optional?" );
return blkClass;
}
catch ( final Throwable t )
Expand Down
4 changes: 4 additions & 0 deletions src/main/java/mod/chiselsandbits/config/ModConfig.java
Expand Up @@ -156,6 +156,9 @@ public class ModConfig extends Configuration
@Configured( category = "Client Performance Settings" )
public static UseVBO useVBO;

@Configured( category = "Troubleshooting" )
public boolean logEligibilityErrors;

@Configured( category = "Troubleshooting" )
public boolean useGetLightValue;

Expand Down Expand Up @@ -398,6 +401,7 @@ private void setDefaults()
disableCustomVertexFormats = false;
enableFaceLightmapExtraction = true;
useGetLightValue = true;
logEligibilityErrors = false;

showUsage = true;
invertBitBagFullness = false;
Expand Down
9 changes: 9 additions & 0 deletions src/main/java/mod/chiselsandbits/core/Log.java
Expand Up @@ -40,4 +40,13 @@ public static void noTileError(
}
}

public static void eligibility(
String message )
{
if ( ChiselsAndBits.getConfig().logEligibilityErrors )
{
getLogger().info( message );
}
}

}
1 change: 1 addition & 0 deletions src/main/resources/assets/chiselsandbits/lang/en_us.lang
Expand Up @@ -239,6 +239,7 @@ mod.chiselsandbits.config.ironChiselUses=Iron Chisel Uses
mod.chiselsandbits.config.diamondChiselUses=Diamond Chisel Uses
mod.chiselsandbits.config.goldChiselUses=Gold Chisel uses
mod.chiselsandbits.config.wrenchUses=Wrench Uses
mod.chiselsandbits.config.logEligibilityErrors=Log Exceptions when calculating Eligibility
mod.chiselsandbits.config.disableCustomVertexFormats=Disable Using Custom Vertex Formats
mod.chiselsandbits.config.enableModelCompression=Compress Vertex Data In Memory
mod.chiselsandbits.config.useGetLightValue=Use Get Light Value to get light value of blocks.
Expand Down

0 comments on commit d07d5e7

Please sign in to comment.