Class LightRangePredicate

java.lang.Object
com.hypixel.hytale.server.spawning.util.LightRangePredicate

public class LightRangePredicate extends Object
Light condition tester.
Since:
2018-04-10
  • Constructor Details

    • LightRangePredicate

      public LightRangePredicate()
  • Method Details

    • lightToPrecentage

      public static int lightToPrecentage(byte light)
    • setLightRange

      public void setLightRange(@Nonnull LightType type, double[] lightRange)
    • setLightRange

      public void setLightRange(@Nullable double[] lightRange)
    • setSkyLightRange

      public void setSkyLightRange(@Nullable double[] lightRange)
    • setSunlightRange

      public void setSunlightRange(@Nullable double[] lightRange)
    • setRedLightRange

      public void setRedLightRange(@Nullable double[] lightRange)
    • setGreenLightRange

      public void setGreenLightRange(@Nullable double[] lightRange)
    • setBlueLightRange

      public void setBlueLightRange(@Nullable double[] lightRange)
    • isTestLightValue

      public boolean isTestLightValue()
    • isTestSkyLightValue

      public boolean isTestSkyLightValue()
    • isTestSunlightValue

      public boolean isTestSunlightValue()
    • isTestRedLightValue

      public boolean isTestRedLightValue()
    • isTestGreenLightValue

      public boolean isTestGreenLightValue()
    • isTestBlueLightValue

      public boolean isTestBlueLightValue()
    • test

      public boolean test(@Nonnull World world, @Nonnull org.joml.Vector3d position, @Nonnull ComponentAccessor<EntityStore> componentAccessor)
    • test

      public boolean test(ComponentAccessor<ChunkStore> componentAccessor, @Nonnull Ref<ChunkStore> sectionRef, int x, int y, int z, double sunlightFactor)
    • testLight

      public boolean testLight(byte lightValue)
    • testSkyLight

      public boolean testSkyLight(byte lightValue)
    • testSunlight

      public boolean testSunlight(byte lightValue)
    • testRedLight

      public boolean testRedLight(byte lightValue)
    • testGreenLight

      public boolean testGreenLight(byte lightValue)
    • testBlueLight

      public boolean testBlueLight(byte lightValue)
    • calculateLightValue

      public static byte calculateLightValue(@Nonnull BlockSection blockSection, int x, int y, int z, double sunlightFactor)