Added grass/foliage coloring for other blocks, moved advancements/recipes to the data folder

This commit is contained in:
Forstride 2019-01-15 20:04:43 -05:00
parent 90421e3530
commit ebaa00d0f0
337 changed files with 39 additions and 19 deletions

View file

@ -27,6 +27,7 @@ import net.minecraft.item.ItemStack;
import net.minecraft.particles.ItemParticleData;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.MathHelper;
import net.minecraft.world.ColorizerFoliage;
import net.minecraft.world.ColorizerGrass;
import net.minecraft.world.IWorldReaderBase;
import net.minecraft.world.World;
@ -52,15 +53,25 @@ public class ClientProxy extends CommonProxy
BlockColors blockColors = Minecraft.getInstance().getBlockColors();
ItemColors itemColors = Minecraft.getInstance().getItemColors();
//Grass Coloring
blockColors.register((state, world, pos, tintIndex) ->
world != null && pos != null ? BiomeColorHelper.getGrassColor(world, pos) : ColorizerGrass.get(0.5D, 1.0D)
, BOPBlocks.sandy_grass_block, BOPBlocks.loamy_grass_block);
itemColors.register((stack, tintIndex) ->
{
world != null && pos != null ? BiomeColorHelper.getGrassColor(world, pos) : ColorizerGrass.get(0.5D, 1.0D),
BOPBlocks.loamy_grass_block, BOPBlocks.sandy_grass_block, BOPBlocks.silty_grass_block, BOPBlocks.short_grass,
BOPBlocks.devilweed, BOPBlocks.watergrass);
//Foliage Coloring
blockColors.register((state, world, pos, tintIndex) ->
world != null && pos != null ? BiomeColorHelper.getFoliageColor(world, pos) : ColorizerFoliage.getDefault(),
BOPBlocks.flowering_leaves, BOPBlocks.mahogany_leaves, BOPBlocks.palm_leaves, BOPBlocks.willow_leaves,
BOPBlocks.ivy, BOPBlocks.willow_vine, BOPBlocks.bush);
//Item Coloring
itemColors.register((stack, tintIndex) -> {
IBlockState iblockstate = ((ItemBlock)stack.getItem()).getBlock().getDefaultState();
return blockColors.getColor(iblockstate, null, null, tintIndex);
}, BOPBlocks.sandy_grass_block, BOPBlocks.loamy_grass_block);
return blockColors.getColor(iblockstate, null, null, tintIndex); },
BOPBlocks.loamy_grass_block, BOPBlocks.sandy_grass_block, BOPBlocks.silty_grass_block, BOPBlocks.short_grass,
BOPBlocks.devilweed, BOPBlocks.flowering_leaves, BOPBlocks.mahogany_leaves, BOPBlocks.palm_leaves,
BOPBlocks.willow_leaves, BOPBlocks.ivy, BOPBlocks.willow_vine);
}
@Override

View file

@ -7,23 +7,23 @@
{ "from": [ 0, 0, 0 ],
"to": [ 16, 16, 16 ],
"faces": {
"down": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 0 },
"up": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 0 },
"north": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 0 },
"south": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 0 },
"west": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 0 },
"east": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 0 }
"down": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 1 },
"up": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 1 },
"north": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 1 },
"south": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 1 },
"west": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 1 },
"east": { "uv": [ 0, 0, 16, 16 ], "texture": "#under", "tintindex": 1 }
}
},
{ "from": [ 0, 0, 0 ],
"to": [ 16, 16, 16 ],
"faces": {
"down": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "down", "tintindex": 1 },
"up": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "up", "tintindex": 1 },
"north": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "north", "tintindex": 1 },
"south": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "south", "tintindex": 1 },
"west": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "west", "tintindex": 1 },
"east": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "east", "tintindex": 1 }
"down": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "down"},
"up": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "up"},
"north": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "north"},
"south": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "south"},
"west": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "west"},
"east": { "uv": [ 0, 0, 16, 16 ], "texture": "#over", "cullface": "east"}
}
}
]

Some files were not shown because too many files have changed in this diff Show more