(EntityFX fx, IBlockAccess blockAccess, double x, double y, double z)
| 1051 | } |
| 1052 | |
| 1053 | public static void updateReddustFX(EntityFX fx, IBlockAccess blockAccess, double x, double y, double z) |
| 1054 | { |
| 1055 | if (redstoneColors != null) |
| 1056 | { |
| 1057 | IBlockState iblockstate = blockAccess.getBlockState(new BlockPos(x, y, z)); |
| 1058 | int i = getRedstoneLevel(iblockstate, 15); |
| 1059 | int j = redstoneColors.getColor(i); |
| 1060 | int k = j >> 16 & 255; |
| 1061 | int l = j >> 8 & 255; |
| 1062 | int i1 = j & 255; |
| 1063 | float f = (float)k / 255.0F; |
| 1064 | float f1 = (float)l / 255.0F; |
| 1065 | float f2 = (float)i1 / 255.0F; |
| 1066 | fx.setRBGColorF(f, f1, f2); |
| 1067 | } |
| 1068 | } |
| 1069 | |
| 1070 | private static int getRedstoneLevel(IBlockState state, int def) |
| 1071 | { |
no test coverage detected