Navigation Menu

Skip to content

Commit

Permalink
Added beacon-coloring to our glasses
Browse files Browse the repository at this point in the history
* re #4112
  • Loading branch information
HenryLoenwind committed Mar 26, 2017
1 parent be0d329 commit b373526
Showing 1 changed file with 8 additions and 0 deletions.
Expand Up @@ -16,11 +16,13 @@
import net.minecraft.block.properties.IProperty;
import net.minecraft.block.state.BlockStateContainer;
import net.minecraft.block.state.IBlockState;
import net.minecraft.entity.passive.EntitySheep;
import net.minecraft.item.EnumDyeColor;
import net.minecraft.util.BlockRenderLayer;
import net.minecraft.util.EnumFacing;
import net.minecraft.util.math.BlockPos;
import net.minecraft.world.IBlockAccess;
import net.minecraft.world.World;
import net.minecraftforge.fml.relauncher.Side;
import net.minecraftforge.fml.relauncher.SideOnly;

Expand Down Expand Up @@ -116,4 +118,10 @@ public int getBlockTint(IBlockState state, @Nullable IBlockAccess worldIn, @Null
return state.getValue(BlockColored.COLOR).getMapColor().colorValue;
}

@Override
@Nullable
public float[] getBeaconColorMultiplier(IBlockState state, World world, BlockPos pos, BlockPos beaconPos) {
return EntitySheep.getDyeRgb(state.getValue(BlockColored.COLOR));
}

}

0 comments on commit b373526

Please sign in to comment.