LightLevelGrowthModifierAsset

public class LightLevelGrowthModifierAsset extends GrowthModifierAsset

Class LightLevelGrowthModifierAsset. Provides lightlevelgrowthmodifierasset functionality for the Hytale server.

java.lang.Object > GrowthModifierAsset > LightLevelGrowthModifierAsset

Field Summary

artificialLight

protected ArtificialLight artificialLight

Field artificialLight.

sunlight

protected Rangef sunlight

Field sunlight.

requireBoth

protected boolean requireBoth

Field requireBoth.

redRange

final Range redRange

Field redRange.

greenRange

final Range greenRange

Field greenRange.

blueRange

final Range blueRange

Field blueRange.

range

final Rangef range

Field range.

sunlightFactor

final double sunlightFactor

Field sunlightFactor.

daylight

final double daylight

Field daylight.

blockSection

final BlockSection blockSection

Field blockSection.

lightRaw

final short lightRaw

Field lightRaw.

redLight

final byte redLight

Field redLight.

greenLight

final byte greenLight

Field greenLight.

blueLight

final byte blueLight

Field blueLight.

skyLight

final byte skyLight

Field skyLight.

worldTimeResource

final WorldTimeResource worldTimeResource

Field worldTimeResource.

red

protected Range red

Field red.

green

protected Range green

Field green.

blue

protected Range blue

Field blue.

Method Detail

getArtificialLight

public ArtificialLight getArtificialLight ()

Method getArtificialLight.

getSunlight

public Rangef getSunlight ()

Method getSunlight.

isRequireBoth

public boolean isRequireBoth ()

Method isRequireBoth.

checkArtificialLight

protected boolean checkArtificialLight (final byte red, final byte green, final byte blue)

Method checkArtificialLight.

Parameters:
final byte red
final byte green
final byte blue

isInRange

public return isInRange (redRange, red)

Method isInRange.

Parameters:
redRange redRange
red red

checkSunLight

protected boolean checkSunLight (final WorldTimeResource worldTimeResource, final byte sky)

Method checkSunLight.

Parameters:
final WorldTimeResource worldTimeResource
final byte sky

getCurrentGrowthMultiplier

public double getCurrentGrowthMultiplier (final CommandBuffer commandBuffer, final Ref sectionRef, final Ref blockRef, final int x, final int y, final int z, final boolean initialTick)

Method getCurrentGrowthMultiplier.

Parameters:
final CommandBuffer commandBuffer
final Ref sectionRef
final Ref blockRef
final int x
final int y
final int z
final boolean initialTick

if

public else if (this.checkArtificialLight(redLight, greenLight, blueLight)

Method if.

Parameters:
this.checkArtificialLight(redLight this.checkArtificialLight(redLight
greenLight greenLight
blueLight blueLight

toString

public String toString ()

Method toString.

getRed

public Range getRed ()

Method getRed.

getGreen

public Range getGreen ()

Method getGreen.

getBlue

public Range getBlue ()

Method getBlue.