From 647c903435f03fe397e7b99da71d8e3f8d557299 Mon Sep 17 00:00:00 2001 From: Sergey Date: Fri, 4 Jul 2025 03:45:38 +0300 Subject: [PATCH] 1.21.5 --- assets/minecraft/atlases/armor_trims.json | 124 +- assets/minecraft/atlases/banner_patterns.json | 22 +- assets/minecraft/atlases/beds.json | 14 +- assets/minecraft/atlases/blocks.json | 114 +- assets/minecraft/atlases/chests.json | 14 +- assets/minecraft/atlases/decorated_pot.json | 8 +- assets/minecraft/atlases/gui.json | 16 +- assets/minecraft/atlases/map_decorations.json | 16 +- assets/minecraft/atlases/mob_effects.json | 14 +- assets/minecraft/atlases/paintings.json | 14 +- assets/minecraft/atlases/particles.json | 14 +- assets/minecraft/atlases/shield_patterns.json | 30 +- assets/minecraft/atlases/shulker_boxes.json | 14 +- assets/minecraft/atlases/signs.json | 14 +- .../blockstates/acacia_trapdoor.json | 3 +- .../minecraft/blockstates/bamboo_fence.json | 12 +- .../blockstates/bamboo_fence_gate.json | 24 +- .../blockstates/bamboo_trapdoor.json | 3 +- .../minecraft/blockstates/birch_trapdoor.json | 3 +- .../blockstates/brown_mushroom_block.json | 5 - assets/minecraft/blockstates/bush.json | 7 + .../minecraft/blockstates/cactus_flower.json | 7 + .../blockstates/cherry_trapdoor.json | 3 +- .../blockstates/chiseled_bookshelf.json | 39 +- .../minecraft/blockstates/creaking_heart.json | 38 +- .../blockstates/crimson_trapdoor.json | 3 +- .../minecraft/blockstates/firefly_bush.json | 7 + .../blockstates/jungle_trapdoor.json | 3 +- assets/minecraft/blockstates/leaf_litter.json | 160 + .../blockstates/mangrove_trapdoor.json | 3 +- .../minecraft/blockstates/mushroom_stem.json | 5 - .../blockstates/pale_oak_trapdoor.json | 3 +- assets/minecraft/blockstates/pink_petals.json | 12 +- .../blockstates/red_mushroom_block.json | 5 - .../blockstates/short_dry_grass.json | 7 + .../blockstates/spruce_trapdoor.json | 3 +- .../minecraft/blockstates/tall_dry_grass.json | 7 + assets/minecraft/blockstates/test_block.json | 16 + .../blockstates/test_instance_block.json | 7 + .../blockstates/warped_trapdoor.json | 3 +- assets/minecraft/blockstates/wildflowers.json | 156 + assets/minecraft/equipment/saddle.json | 44 + assets/minecraft/items/allay_spawn_egg.json | 12 +- .../minecraft/items/armadillo_spawn_egg.json | 12 +- assets/minecraft/items/axolotl_spawn_egg.json | 12 +- assets/minecraft/items/bat_spawn_egg.json | 12 +- assets/minecraft/items/bee_spawn_egg.json | 12 +- assets/minecraft/items/blaze_spawn_egg.json | 12 +- assets/minecraft/items/blue_egg.json | 6 + assets/minecraft/items/bogged_spawn_egg.json | 12 +- assets/minecraft/items/breeze_spawn_egg.json | 12 +- assets/minecraft/items/brown_egg.json | 6 + assets/minecraft/items/bush.json | 13 + assets/minecraft/items/cactus_flower.json | 6 + assets/minecraft/items/camel_spawn_egg.json | 12 +- assets/minecraft/items/cat_spawn_egg.json | 12 +- .../items/cave_spider_spawn_egg.json | 12 +- assets/minecraft/items/chicken_spawn_egg.json | 12 +- assets/minecraft/items/cod_spawn_egg.json | 12 +- assets/minecraft/items/cow_spawn_egg.json | 12 +- .../minecraft/items/creaking_spawn_egg.json | 12 +- assets/minecraft/items/creeper_spawn_egg.json | 12 +- assets/minecraft/items/crossbow.json | 84 +- assets/minecraft/items/dolphin_spawn_egg.json | 12 +- assets/minecraft/items/donkey_spawn_egg.json | 12 +- assets/minecraft/items/drowned_spawn_egg.json | 12 +- .../items/elder_guardian_spawn_egg.json | 12 +- .../items/ender_dragon_spawn_egg.json | 12 +- .../minecraft/items/enderman_spawn_egg.json | 12 +- .../minecraft/items/endermite_spawn_egg.json | 12 +- assets/minecraft/items/evoker_spawn_egg.json | 12 +- assets/minecraft/items/firefly_bush.json | 6 + assets/minecraft/items/fox_spawn_egg.json | 12 +- assets/minecraft/items/frog_spawn_egg.json | 12 +- assets/minecraft/items/ghast_spawn_egg.json | 12 +- .../minecraft/items/glow_squid_spawn_egg.json | 12 +- assets/minecraft/items/goat_spawn_egg.json | 12 +- .../minecraft/items/guardian_spawn_egg.json | 12 +- assets/minecraft/items/hoglin_spawn_egg.json | 12 +- assets/minecraft/items/horse_spawn_egg.json | 12 +- assets/minecraft/items/husk_spawn_egg.json | 12 +- .../minecraft/items/iron_golem_spawn_egg.json | 12 +- assets/minecraft/items/leaf_litter.json | 6 + assets/minecraft/items/llama_spawn_egg.json | 12 +- .../minecraft/items/magma_cube_spawn_egg.json | 12 +- .../minecraft/items/mooshroom_spawn_egg.json | 12 +- assets/minecraft/items/mule_spawn_egg.json | 12 +- assets/minecraft/items/ocelot_spawn_egg.json | 12 +- assets/minecraft/items/panda_spawn_egg.json | 12 +- assets/minecraft/items/parrot_spawn_egg.json | 12 +- assets/minecraft/items/phantom_spawn_egg.json | 12 +- assets/minecraft/items/pig_spawn_egg.json | 12 +- .../items/piglin_brute_spawn_egg.json | 12 +- assets/minecraft/items/piglin_spawn_egg.json | 12 +- .../minecraft/items/pillager_spawn_egg.json | 12 +- .../minecraft/items/polar_bear_spawn_egg.json | 12 +- .../minecraft/items/pufferfish_spawn_egg.json | 12 +- assets/minecraft/items/rabbit_spawn_egg.json | 12 +- assets/minecraft/items/ravager_spawn_egg.json | 12 +- assets/minecraft/items/salmon_spawn_egg.json | 12 +- assets/minecraft/items/sheep_spawn_egg.json | 12 +- assets/minecraft/items/short_dry_grass.json | 6 + assets/minecraft/items/shulker_spawn_egg.json | 12 +- .../minecraft/items/silverfish_spawn_egg.json | 12 +- .../items/skeleton_horse_spawn_egg.json | 12 +- .../minecraft/items/skeleton_spawn_egg.json | 12 +- assets/minecraft/items/slime_spawn_egg.json | 12 +- assets/minecraft/items/sniffer_spawn_egg.json | 12 +- .../minecraft/items/snow_golem_spawn_egg.json | 12 +- assets/minecraft/items/spider_spawn_egg.json | 12 +- assets/minecraft/items/squid_spawn_egg.json | 12 +- assets/minecraft/items/stray_spawn_egg.json | 12 +- assets/minecraft/items/strider_spawn_egg.json | 12 +- assets/minecraft/items/tadpole_spawn_egg.json | 12 +- assets/minecraft/items/tall_dry_grass.json | 6 + assets/minecraft/items/test_block.json | 34 + .../minecraft/items/test_instance_block.json | 6 + .../items/trader_llama_spawn_egg.json | 12 +- .../items/tropical_fish_spawn_egg.json | 12 +- assets/minecraft/items/turtle_spawn_egg.json | 12 +- assets/minecraft/items/vex_spawn_egg.json | 12 +- .../minecraft/items/villager_spawn_egg.json | 12 +- .../minecraft/items/vindicator_spawn_egg.json | 12 +- .../items/wandering_trader_spawn_egg.json | 12 +- assets/minecraft/items/warden_spawn_egg.json | 12 +- assets/minecraft/items/wildflowers.json | 6 + assets/minecraft/items/witch_spawn_egg.json | 12 +- .../items/wither_skeleton_spawn_egg.json | 12 +- assets/minecraft/items/wither_spawn_egg.json | 12 +- assets/minecraft/items/wolf_spawn_egg.json | 12 +- assets/minecraft/items/zoglin_spawn_egg.json | 12 +- .../items/zombie_horse_spawn_egg.json | 12 +- assets/minecraft/items/zombie_spawn_egg.json | 12 +- .../items/zombie_villager_spawn_egg.json | 12 +- .../items/zombified_piglin_spawn_egg.json | 12 +- assets/minecraft/lang/deprecated.json | 14 +- assets/minecraft/lang/en_us.json | 249 +- assets/minecraft/models/block/bush.json | 6 + .../minecraft/models/block/cactus_flower.json | 6 + .../models/block/creaking_heart_active.json | 7 - .../creaking_heart_active_horizontal.json | 7 - .../models/block/creaking_heart_awake.json | 7 + .../creaking_heart_awake_horizontal.json | 7 + .../models/block/creaking_heart_dormant.json | 7 + .../creaking_heart_dormant_horizontal.json | 7 + .../minecraft/models/block/firefly_bush.json | 7 + .../minecraft/models/block/leaf_litter_1.json | 6 + .../minecraft/models/block/leaf_litter_2.json | 6 + .../minecraft/models/block/leaf_litter_3.json | 6 + .../minecraft/models/block/leaf_litter_4.json | 6 + .../models/block/short_dry_grass.json | 6 + .../models/block/tall_dry_grass.json | 6 + .../models/block/template_leaf_litter_1.json | 16 + .../models/block/template_leaf_litter_2.json | 16 + .../models/block/template_leaf_litter_3.json | 16 + .../models/block/template_leaf_litter_4.json | 16 + .../models/block/test_block_accept.json | 6 + .../models/block/test_block_fail.json | 6 + .../models/block/test_block_log.json | 6 + .../models/block/test_block_start.json | 6 + .../models/block/test_instance_block.json | 6 + .../minecraft/models/block/wildflowers_1.json | 7 + .../minecraft/models/block/wildflowers_2.json | 7 + .../minecraft/models/block/wildflowers_3.json | 7 + .../minecraft/models/block/wildflowers_4.json | 7 + .../models/item/allay_spawn_egg.json | 6 + .../models/item/armadillo_spawn_egg.json | 6 + .../models/item/axolotl_spawn_egg.json | 6 + .../minecraft/models/item/bat_spawn_egg.json | 6 + .../minecraft/models/item/bee_spawn_egg.json | 6 + .../models/item/blaze_spawn_egg.json | 6 + assets/minecraft/models/item/blue_egg.json | 6 + .../models/item/bogged_spawn_egg.json | 6 + .../models/item/breeze_spawn_egg.json | 6 + assets/minecraft/models/item/brown_egg.json | 6 + assets/minecraft/models/item/bush.json | 6 + .../minecraft/models/item/cactus_flower.json | 6 + .../models/item/camel_spawn_egg.json | 6 + .../minecraft/models/item/cat_spawn_egg.json | 6 + .../models/item/cave_spider_spawn_egg.json | 6 + .../models/item/chicken_spawn_egg.json | 6 + .../minecraft/models/item/cod_spawn_egg.json | 6 + .../minecraft/models/item/cow_spawn_egg.json | 6 + .../models/item/creaking_spawn_egg.json | 6 + .../models/item/creeper_spawn_egg.json | 6 + .../models/item/dolphin_spawn_egg.json | 6 + .../models/item/donkey_spawn_egg.json | 6 + .../models/item/drowned_spawn_egg.json | 6 + .../models/item/elder_guardian_spawn_egg.json | 6 + .../models/item/ender_dragon_spawn_egg.json | 6 + .../models/item/enderman_spawn_egg.json | 6 + .../models/item/endermite_spawn_egg.json | 6 + .../models/item/evoker_spawn_egg.json | 6 + .../minecraft/models/item/firefly_bush.json | 6 + .../minecraft/models/item/fox_spawn_egg.json | 6 + .../minecraft/models/item/frog_spawn_egg.json | 6 + .../models/item/ghast_spawn_egg.json | 6 + .../models/item/glow_squid_spawn_egg.json | 6 + .../minecraft/models/item/goat_spawn_egg.json | 6 + .../models/item/guardian_spawn_egg.json | 6 + .../models/item/hoglin_spawn_egg.json | 6 + .../models/item/horse_spawn_egg.json | 6 + .../minecraft/models/item/husk_spawn_egg.json | 6 + .../models/item/iron_golem_spawn_egg.json | 6 + assets/minecraft/models/item/leaf_litter.json | 6 + .../models/item/llama_spawn_egg.json | 6 + .../models/item/magma_cube_spawn_egg.json | 6 + .../models/item/mooshroom_spawn_egg.json | 6 + .../minecraft/models/item/mule_spawn_egg.json | 6 + .../models/item/ocelot_spawn_egg.json | 6 + .../models/item/panda_spawn_egg.json | 6 + .../models/item/parrot_spawn_egg.json | 6 + .../models/item/phantom_spawn_egg.json | 6 + .../minecraft/models/item/pig_spawn_egg.json | 6 + .../models/item/piglin_brute_spawn_egg.json | 6 + .../models/item/piglin_spawn_egg.json | 6 + .../models/item/pillager_spawn_egg.json | 6 + .../models/item/polar_bear_spawn_egg.json | 6 + .../models/item/pufferfish_spawn_egg.json | 6 + .../models/item/rabbit_spawn_egg.json | 6 + .../models/item/ravager_spawn_egg.json | 6 + .../models/item/salmon_spawn_egg.json | 6 + .../models/item/sheep_spawn_egg.json | 6 + .../models/item/short_dry_grass.json | 6 + .../models/item/shulker_spawn_egg.json | 6 + .../models/item/silverfish_spawn_egg.json | 6 + .../models/item/skeleton_horse_spawn_egg.json | 6 + .../models/item/skeleton_spawn_egg.json | 6 + .../models/item/slime_spawn_egg.json | 6 + .../models/item/sniffer_spawn_egg.json | 6 + .../models/item/snow_golem_spawn_egg.json | 6 + .../models/item/spider_spawn_egg.json | 6 + .../models/item/squid_spawn_egg.json | 6 + .../models/item/stray_spawn_egg.json | 6 + .../models/item/strider_spawn_egg.json | 6 + .../models/item/tadpole_spawn_egg.json | 6 + .../minecraft/models/item/tall_dry_grass.json | 6 + .../models/item/template_spawn_egg.json | 7 - .../models/item/trader_llama_spawn_egg.json | 6 + .../models/item/tropical_fish_spawn_egg.json | 6 + .../models/item/turtle_spawn_egg.json | 6 + .../minecraft/models/item/vex_spawn_egg.json | 6 + .../models/item/villager_spawn_egg.json | 6 + .../models/item/vindicator_spawn_egg.json | 6 + .../item/wandering_trader_spawn_egg.json | 6 + .../models/item/warden_spawn_egg.json | 6 + assets/minecraft/models/item/wildflowers.json | 6 + .../models/item/witch_spawn_egg.json | 6 + .../item/wither_skeleton_spawn_egg.json | 6 + .../models/item/wither_spawn_egg.json | 6 + .../minecraft/models/item/wolf_spawn_egg.json | 6 + .../models/item/zoglin_spawn_egg.json | 6 + .../models/item/zombie_horse_spawn_egg.json | 6 + .../models/item/zombie_spawn_egg.json | 6 + .../item/zombie_villager_spawn_egg.json | 6 + .../item/zombified_piglin_spawn_egg.json | 6 + assets/minecraft/particles/firefly.json | 5 + assets/minecraft/particles/tinted_leaves.json | 16 + assets/minecraft/post_effect/blur.json | 60 +- assets/minecraft/post_effect/creeper.json | 11 +- .../minecraft/post_effect/entity_outline.json | 21 +- assets/minecraft/post_effect/invert.json | 14 +- assets/minecraft/post_effect/spider.json | 80 +- .../minecraft/post_effect/transparency.json | 13 +- .../minecraft/shaders/core/blit_screen.json | 9 - assets/minecraft/shaders/core/lightmap.json | 17 - assets/minecraft/shaders/core/particle.json | 17 - assets/minecraft/shaders/core/position.json | 15 - .../shaders/core/position_color.json | 11 - .../shaders/core/position_color_lightmap.json | 12 - .../core/position_color_tex_lightmap.json | 12 - .../minecraft/shaders/core/position_tex.json | 12 - .../shaders/core/position_tex_color.json | 12 - .../core/rendertype_armor_cutout_no_cull.json | 27 - .../core/rendertype_armor_entity_glint.json | 18 - .../core/rendertype_armor_translucent.json | 27 - .../shaders/core/rendertype_beacon_beam.json | 16 - .../shaders/core/rendertype_breeze_wind.json | 28 - .../shaders/core/rendertype_clouds.json | 16 - .../shaders/core/rendertype_crumbling.json | 12 - .../shaders/core/rendertype_cutout.json | 23 - .../core/rendertype_cutout_mipped.json | 23 - .../shaders/core/rendertype_end_gateway.json | 14 - .../shaders/core/rendertype_end_portal.fsh | 10 +- .../shaders/core/rendertype_end_portal.json | 14 - .../shaders/core/rendertype_end_portal.vsh | 4 + .../shaders/core/rendertype_energy_swirl.json | 28 - .../shaders/core/rendertype_entity_alpha.json | 11 - .../core/rendertype_entity_cutout.json | 25 - .../rendertype_entity_cutout_no_cull.json | 25 - ...ertype_entity_cutout_no_cull_z_offset.json | 25 - .../shaders/core/rendertype_entity_decal.json | 20 - .../shaders/core/rendertype_entity_glint.json | 17 - .../core/rendertype_entity_no_outline.json | 24 - .../core/rendertype_entity_shadow.json | 16 - .../core/rendertype_entity_smooth_cutout.json | 25 - .../shaders/core/rendertype_entity_solid.json | 20 - .../core/rendertype_entity_translucent.json | 25 - ...endertype_entity_translucent_emissive.json | 28 - .../shaders/core/rendertype_eyes.json | 23 - .../shaders/core/rendertype_glint.json | 17 - .../core/rendertype_glint_translucent.json | 17 - .../shaders/core/rendertype_gui.json | 11 - .../rendertype_gui_ghost_recipe_overlay.json | 11 - .../shaders/core/rendertype_gui_overlay.json | 11 - .../core/rendertype_gui_text_highlight.json | 11 - ...ndertype_item_entity_translucent_cull.json | 19 - .../shaders/core/rendertype_leash.json | 16 - .../shaders/core/rendertype_lightning.json | 15 - .../shaders/core/rendertype_lines.json | 17 - .../shaders/core/rendertype_outline.json | 12 - .../shaders/core/rendertype_solid.json | 18 - .../shaders/core/rendertype_text.json | 17 - .../core/rendertype_text_background.json | 16 - ...endertype_text_background_see_through.json | 11 - .../core/rendertype_text_intensity.json | 17 - ...rendertype_text_intensity_see_through.json | 12 - .../core/rendertype_text_see_through.json | 12 - .../shaders/core/rendertype_translucent.json | 18 - .../rendertype_translucent_moving_block.json | 13 - .../shaders/core/rendertype_tripwire.json | 23 - .../shaders/core/rendertype_water_mask.json | 11 - .../shaders/core/rendertype_world_border.fsh | 17 + .../shaders/core/rendertype_world_border.vsh | 18 + assets/minecraft/shaders/post/bits.fsh | 3 +- assets/minecraft/shaders/post/bits.json | 15 - assets/minecraft/shaders/post/blit.json | 12 - assets/minecraft/shaders/post/blit.vsh | 4 +- assets/minecraft/shaders/post/blur.vsh | 4 +- assets/minecraft/shaders/post/box_blur.fsh | 3 +- assets/minecraft/shaders/post/box_blur.json | 15 - .../minecraft/shaders/post/color_convolve.fsh | 11 +- .../shaders/post/color_convolve.json | 19 - .../shaders/post/entity_outline.json | 12 - .../shaders/post/entity_outline_box_blur.json | 18 - assets/minecraft/shaders/post/invert.json | 13 - assets/minecraft/shaders/post/invert.vsh | 4 +- assets/minecraft/shaders/post/rotscale.vsh | 4 +- assets/minecraft/shaders/post/screenquad.vsh | 4 +- assets/minecraft/shaders/post/sobel.vsh | 4 +- assets/minecraft/shaders/post/spider.json | 18 - .../minecraft/shaders/post/transparency.json | 22 - assets/minecraft/textures/block/bush.png | 3 + .../textures/block/cactus_flower.png | 3 + ...rt_active.png => creaking_heart_awake.png} | 0 .../textures/block/creaking_heart_dormant.png | 3 + ...ctive.png => creaking_heart_top_awake.png} | 0 .../block/creaking_heart_top_dormant.png | 3 + .../minecraft/textures/block/firefly_bush.png | 3 + .../textures/block/firefly_bush_emissive.png | 3 + .../block/firefly_bush_emissive.png.mcmeta | 5 + .../minecraft/textures/block/leaf_litter.png | 3 + .../textures/block/short_dry_grass.png | 3 + .../textures/block/tall_dry_grass.png | 3 + .../textures/block/test_block_accept.png | 3 + .../textures/block/test_block_fail.png | 3 + .../textures/block/test_block_log.png | 3 + .../textures/block/test_block_start.png | 3 + .../textures/block/test_instance_block.png | 3 + .../minecraft/textures/block/wildflowers.png | 3 + .../textures/block/wildflowers_stem.png | 3 + .../textures/colormap/dry_foliage.png | 3 + .../minecraft/textures/entity/camel/camel.png | 4 +- .../textures/entity/chicken/cold_chicken.png | 3 + .../temperate_chicken.png} | 0 .../textures/entity/chicken/warm_chicken.png | 3 + .../textures/entity/cow/brown_mooshroom.png | 4 +- .../textures/entity/cow/cold_cow.png | 3 + assets/minecraft/textures/entity/cow/cow.png | 3 - .../textures/entity/cow/red_mooshroom.png | 4 +- .../textures/entity/cow/temperate_cow.png | 3 + .../textures/entity/cow/warm_cow.png | 3 + .../entity/equipment/camel_saddle/saddle.png | 3 + .../entity/equipment/donkey_saddle/saddle.png | 3 + .../entity/equipment/horse_saddle/saddle.png | 3 + .../entity/equipment/mule_saddle/saddle.png | 3 + .../entity/equipment/pig_saddle/saddle.png | 3 + .../skeleton_horse_saddle/saddle.png | 3 + .../strider_saddle/saddle.png} | 0 .../equipment/zombie_horse_saddle/saddle.png | 3 + .../textures/entity/horse/donkey.png | 4 +- .../textures/entity/horse/horse_black.png | 4 +- .../textures/entity/horse/horse_brown.png | 4 +- .../textures/entity/horse/horse_chestnut.png | 4 +- .../textures/entity/horse/horse_creamy.png | 4 +- .../textures/entity/horse/horse_darkbrown.png | 4 +- .../textures/entity/horse/horse_gray.png | 4 +- .../textures/entity/horse/horse_skeleton.png | 4 +- .../textures/entity/horse/horse_white.png | 4 +- .../textures/entity/horse/horse_zombie.png | 4 +- .../minecraft/textures/entity/horse/mule.png | 4 +- .../textures/entity/pig/cold_pig.png | 3 + assets/minecraft/textures/entity/pig/pig.png | 3 - .../textures/entity/pig/pig_saddle.png | 3 - .../textures/entity/pig/temperate_pig.png | 3 + .../textures/entity/pig/warm_pig.png | 3 + .../textures/entity/sheep/sheep_fur.png | 3 - .../textures/entity/sheep/sheep_wool.png | 3 + .../entity/sheep/sheep_wool_undercoat.png | 3 + .../textures/item/allay_spawn_egg.png | 3 + .../textures/item/armadillo_spawn_egg.png | 3 + .../textures/item/axolotl_spawn_egg.png | 3 + .../minecraft/textures/item/bat_spawn_egg.png | 3 + .../minecraft/textures/item/bee_spawn_egg.png | 3 + .../textures/item/blaze_spawn_egg.png | 3 + assets/minecraft/textures/item/blue_egg.png | 3 + .../textures/item/bogged_spawn_egg.png | 3 + .../textures/item/breeze_spawn_egg.png | 3 + assets/minecraft/textures/item/brown_egg.png | 3 + .../textures/item/camel_spawn_egg.png | 3 + .../minecraft/textures/item/cat_spawn_egg.png | 3 + .../textures/item/cave_spider_spawn_egg.png | 3 + .../textures/item/chicken_spawn_egg.png | 3 + .../minecraft/textures/item/cod_spawn_egg.png | 3 + .../minecraft/textures/item/cow_spawn_egg.png | 3 + .../textures/item/creaking_spawn_egg.png | 3 + .../textures/item/creeper_spawn_egg.png | 3 + .../textures/item/dolphin_spawn_egg.png | 3 + .../textures/item/donkey_spawn_egg.png | 3 + .../textures/item/drowned_spawn_egg.png | 3 + .../item/elder_guardian_spawn_egg.png | 3 + .../textures/item/ender_dragon_spawn_egg.png | 3 + .../textures/item/enderman_spawn_egg.png | 3 + .../textures/item/endermite_spawn_egg.png | 3 + .../textures/item/evoker_spawn_egg.png | 3 + .../minecraft/textures/item/firefly_bush.png | 3 + .../minecraft/textures/item/fox_spawn_egg.png | 3 + .../textures/item/frog_spawn_egg.png | 3 + .../textures/item/ghast_spawn_egg.png | 3 + .../textures/item/glow_squid_spawn_egg.png | 3 + .../textures/item/goat_spawn_egg.png | 3 + .../textures/item/guardian_spawn_egg.png | 3 + .../textures/item/hoglin_spawn_egg.png | 3 + .../textures/item/horse_spawn_egg.png | 3 + .../textures/item/husk_spawn_egg.png | 3 + .../textures/item/iron_golem_spawn_egg.png | 3 + .../minecraft/textures/item/leaf_litter.png | 3 + .../textures/item/llama_spawn_egg.png | 3 + .../textures/item/magma_cube_spawn_egg.png | 3 + .../textures/item/mooshroom_spawn_egg.png | 3 + .../textures/item/mule_spawn_egg.png | 3 + .../textures/item/ocelot_spawn_egg.png | 3 + .../textures/item/panda_spawn_egg.png | 3 + .../textures/item/parrot_spawn_egg.png | 3 + .../textures/item/phantom_spawn_egg.png | 3 + .../minecraft/textures/item/pig_spawn_egg.png | 3 + .../textures/item/piglin_brute_spawn_egg.png | 3 + .../textures/item/piglin_spawn_egg.png | 3 + .../textures/item/pillager_spawn_egg.png | 3 + .../textures/item/polar_bear_spawn_egg.png | 3 + .../textures/item/pufferfish_spawn_egg.png | 3 + .../textures/item/rabbit_spawn_egg.png | 3 + .../textures/item/ravager_spawn_egg.png | 3 + .../textures/item/salmon_spawn_egg.png | 3 + .../textures/item/sheep_spawn_egg.png | 3 + .../textures/item/shulker_spawn_egg.png | 3 + .../textures/item/silverfish_spawn_egg.png | 3 + .../item/skeleton_horse_spawn_egg.png | 3 + .../textures/item/skeleton_spawn_egg.png | 3 + .../textures/item/slime_spawn_egg.png | 3 + .../textures/item/sniffer_spawn_egg.png | 3 + .../textures/item/snow_golem_spawn_egg.png | 3 + assets/minecraft/textures/item/spawn_egg.png | 3 - .../textures/item/spawn_egg_overlay.png | 3 - .../textures/item/spider_spawn_egg.png | 3 + .../textures/item/squid_spawn_egg.png | 3 + .../textures/item/stray_spawn_egg.png | 3 + .../textures/item/strider_spawn_egg.png | 3 + .../textures/item/tadpole_spawn_egg.png | 3 + .../textures/item/trader_llama_spawn_egg.png | 3 + .../textures/item/tropical_fish_spawn_egg.png | 3 + .../textures/item/turtle_spawn_egg.png | 3 + .../minecraft/textures/item/vex_spawn_egg.png | 3 + .../textures/item/villager_spawn_egg.png | 3 + .../textures/item/vindicator_spawn_egg.png | 3 + .../item/wandering_trader_spawn_egg.png | 3 + .../textures/item/warden_spawn_egg.png | 3 + .../minecraft/textures/item/wildflowers.png | 3 + .../textures/item/witch_spawn_egg.png | 3 + .../item/wither_skeleton_spawn_egg.png | 3 + .../textures/item/wither_spawn_egg.png | 3 + .../textures/item/wolf_spawn_egg.png | 3 + .../textures/item/zoglin_spawn_egg.png | 3 + .../textures/item/zombie_horse_spawn_egg.png | 3 + .../textures/item/zombie_spawn_egg.png | 3 + .../item/zombie_villager_spawn_egg.png | 3 + .../item/zombified_piglin_spawn_egg.png | 3 + ...t_entity.png => enchanted_glint_armor.png} | 0 ...cmeta => enchanted_glint_armor.png.mcmeta} | 0 .../minecraft/textures/particle/firefly.png | 3 + assets/minecraft/textures/particle/leaf_0.png | 3 + assets/minecraft/textures/particle/leaf_1.png | 3 + .../minecraft/textures/particle/leaf_10.png | 3 + .../minecraft/textures/particle/leaf_11.png | 3 + assets/minecraft/textures/particle/leaf_2.png | 3 + assets/minecraft/textures/particle/leaf_3.png | 3 + assets/minecraft/textures/particle/leaf_4.png | 3 + assets/minecraft/textures/particle/leaf_5.png | 3 + assets/minecraft/textures/particle/leaf_6.png | 3 + assets/minecraft/textures/particle/leaf_7.png | 3 + assets/minecraft/textures/particle/leaf_8.png | 3 + assets/minecraft/textures/particle/leaf_9.png | 3 + .../blaze3d/GpuOutOfMemoryException.java | 11 + com/mojang/blaze3d/TracyFrameCapture.java | 92 +- com/mojang/blaze3d/audio/Library.java | 29 +- com/mojang/blaze3d/buffers/BufferType.java | 22 +- com/mojang/blaze3d/buffers/BufferUsage.java | 36 +- com/mojang/blaze3d/buffers/GpuBuffer.java | 130 +- com/mojang/blaze3d/buffers/GpuFence.java | 8 +- com/mojang/blaze3d/font/SheetGlyphInfo.java | 3 +- .../blaze3d/opengl/AbstractUniform.java | 49 + .../blaze3d/opengl/DirectStateAccess.java | 84 + com/mojang/blaze3d/opengl/GlBuffer.java | 79 + .../blaze3d/opengl/GlCommandEncoder.java | 712 + .../blaze3d/{platform => opengl}/GlConst.java | 178 +- .../blaze3d/{platform => opengl}/GlDebug.java | 82 +- com/mojang/blaze3d/opengl/GlDebugLabel.java | 135 + com/mojang/blaze3d/opengl/GlDevice.java | 312 + com/mojang/blaze3d/opengl/GlProgram.java | 335 + com/mojang/blaze3d/opengl/GlRenderPass.java | 145 + .../blaze3d/opengl/GlRenderPipeline.java | 19 + com/mojang/blaze3d/opengl/GlShaderModule.java | 59 + .../{platform => opengl}/GlStateManager.java | 475 +- com/mojang/blaze3d/opengl/GlTexture.java | 94 + com/mojang/blaze3d/opengl/Uniform.java | 189 + .../blaze3d/opengl/VertexArrayCache.java | 175 + com/mojang/blaze3d/opengl/package-info.java | 11 + .../blaze3d/pipeline/BlendFunction.java | 27 + .../pipeline/CompiledRenderPipeline.java | 13 + com/mojang/blaze3d/pipeline/MainTarget.java | 114 +- com/mojang/blaze3d/pipeline/RenderCall.java | 9 - .../blaze3d/pipeline/RenderPipeline.java | 488 + com/mojang/blaze3d/pipeline/RenderTarget.java | 243 +- .../blaze3d/pipeline/TextureTarget.java | 7 +- .../blaze3d/platform/DepthTestFunction.java | 15 + com/mojang/blaze3d/platform/DestFactor.java | 24 + com/mojang/blaze3d/platform/DisplayData.java | 18 +- .../platform/FramerateLimitTracker.java | 35 +- com/mojang/blaze3d/platform/GLX.java | 82 +- com/mojang/blaze3d/platform/GlUtil.java | 34 - com/mojang/blaze3d/platform/LogicOp.java | 12 + com/mojang/blaze3d/platform/NativeImage.java | 151 +- com/mojang/blaze3d/platform/PolygonMode.java | 12 + com/mojang/blaze3d/platform/SourceFactor.java | 25 + com/mojang/blaze3d/platform/TextureUtil.java | 122 +- com/mojang/blaze3d/platform/Window.java | 19 +- .../resource/CrossFrameResourcePool.java | 8 +- .../resource/GraphicsResourceAllocator.java | 4 +- .../resource/RenderTargetDescriptor.java | 22 +- .../blaze3d/resource/ResourceDescriptor.java | 7 + .../blaze3d/shaders/AbstractUniform.java | 100 - .../blaze3d/shaders/CompiledShader.java | 94 - com/mojang/blaze3d/shaders/ShaderType.java | 43 + com/mojang/blaze3d/shaders/Uniform.java | 527 - com/mojang/blaze3d/shaders/UniformType.java | 42 + .../blaze3d/systems/CommandEncoder.java | 47 + com/mojang/blaze3d/systems/GpuDevice.java | 61 + com/mojang/blaze3d/systems/RenderPass.java | 65 + com/mojang/blaze3d/systems/RenderSystem.java | 574 +- com/mojang/blaze3d/systems/ScissorState.java | 55 + com/mojang/blaze3d/textures/AddressMode.java | 12 + com/mojang/blaze3d/textures/FilterMode.java | 12 + com/mojang/blaze3d/textures/GpuTexture.java | 71 + .../blaze3d/textures/TextureFormat.java | 31 + com/mojang/blaze3d/textures/package-info.java | 11 + com/mojang/blaze3d/vertex/BufferBuilder.java | 10 +- com/mojang/blaze3d/vertex/BufferUploader.java | 54 - com/mojang/blaze3d/vertex/PoseStack.java | 160 +- .../vertex/SheetedDecalTextureGenerator.java | 3 +- com/mojang/blaze3d/vertex/VertexBuffer.java | 234 - com/mojang/blaze3d/vertex/VertexConsumer.java | 32 +- com/mojang/blaze3d/vertex/VertexFormat.java | 146 +- .../blaze3d/vertex/VertexFormatElement.java | 85 +- com/mojang/math/MatrixUtil.java | 28 +- com/mojang/math/OctahedralGroup.java | 77 +- com/mojang/math/Quadrant.java | 50 + com/mojang/math/SymmetricGroup3.java | 18 +- com/mojang/math/Transformation.java | 15 +- .../realmsclient/RealmsAvailability.java | 2 +- com/mojang/realmsclient/RealmsMainScreen.java | 16 +- .../realmsclient/client/RealmsClient.java | 79 +- .../worldupload/RealmsCreateWorldFlow.java | 2 +- .../client/worldupload/RealmsWorldUpload.java | 2 +- .../realmsclient/dto/RealmsWorldOptions.java | 19 +- .../gui/screens/AddRealmPopupScreen.java | 4 +- .../gui/screens/RealmsBackupScreen.java | 2 +- .../gui/screens/RealmsBrokenWorldScreen.java | 6 +- .../screens/RealmsConfigureWorldScreen.java | 6 +- .../gui/screens/RealmsCreateRealmScreen.java | 6 +- .../gui/screens/RealmsInviteScreen.java | 2 +- .../screens/RealmsNotificationsScreen.java | 3 +- .../screens/RealmsPendingInvitesScreen.java | 4 +- .../gui/screens/RealmsPlayerScreen.java | 8 +- .../gui/screens/RealmsResetWorldScreen.java | 5 +- .../RealmsSelectFileToUploadScreen.java | 11 +- .../RealmsSelectWorldTemplateScreen.java | 2 +- .../gui/screens/RealmsSlotOptionsScreen.java | 4 +- .../screens/RealmsSubscriptionInfoScreen.java | 4 +- .../gui/screens/RealmsTermsScreen.java | 2 +- .../gui/screens/RealmsUploadScreen.java | 2 +- .../util/RealmsTextureManager.java | 2 +- .../util/task/CloseServerTask.java | 5 +- .../realmsclient/util/task/DownloadTask.java | 2 +- .../util/task/GetServerDetailsTask.java | 2 +- .../util/task/OpenServerTask.java | 5 +- .../util/task/RealmCreationTask.java | 2 +- .../util/task/ResettingWorldTask.java | 2 +- .../realmsclient/util/task/RestoreTask.java | 2 +- .../util/task/SwitchMinigameTask.java | 2 +- .../util/task/SwitchSlotTask.java | 2 +- .../adventure/adventuring_time.json | 6 +- .../adventure/hero_of_the_village.json | 12 +- .../minecraft/advancement/adventure/root.json | 2 +- .../{nether => adventure}/use_lodestone.json | 6 +- .../adventure/voluntary_exile.json | 16 +- data/minecraft/advancement/end/root.json | 2 +- .../husbandry/complete_catalogue.json | 55 +- .../husbandry/leash_all_frog_variants.json | 21 +- .../minecraft/advancement/husbandry/root.json | 2 +- .../advancement/husbandry/whole_pack.json | 45 +- data/minecraft/advancement/nether/root.json | 2 +- .../recipes/decorations/lodestone.json | 17 +- .../advancement/recipes/food/cake.json | 2 +- .../advancement/recipes/misc/leaf_litter.json | 32 + .../misc/pink_dye_from_cactus_flower.json | 32 + .../misc/yellow_dye_from_wildflowers.json | 32 + data/minecraft/advancement/story/root.json | 2 +- data/minecraft/cat_variant/all_black.json | 21 + data/minecraft/cat_variant/black.json | 8 + .../cat_variant/british_shorthair.json | 8 + data/minecraft/cat_variant/calico.json | 8 + data/minecraft/cat_variant/jellie.json | 8 + data/minecraft/cat_variant/persian.json | 8 + data/minecraft/cat_variant/ragdoll.json | 8 + data/minecraft/cat_variant/red.json | 8 + data/minecraft/cat_variant/siamese.json | 8 + data/minecraft/cat_variant/tabby.json | 8 + data/minecraft/cat_variant/white.json | 8 + data/minecraft/chicken_variant/cold.json | 13 + data/minecraft/chicken_variant/temperate.json | 8 + data/minecraft/chicken_variant/warm.json | 12 + data/minecraft/cow_variant/cold.json | 13 + data/minecraft/cow_variant/temperate.json | 8 + data/minecraft/cow_variant/warm.json | 13 + .../minecart_improvements/pack.mcmeta | 2 +- .../redstone_experiments/pack.mcmeta | 2 +- .../datapacks/trade_rebalance/pack.mcmeta | 2 +- data/minecraft/frog_variant/cold.json | 12 + data/minecraft/frog_variant/temperate.json | 8 + data/minecraft/frog_variant/warm.json | 12 + .../loot_table/blocks/black_banner.json | 2 +- .../loot_table/blocks/blue_banner.json | 2 +- .../loot_table/blocks/brown_banner.json | 2 +- data/minecraft/loot_table/blocks/bush.json | 44 + .../loot_table/blocks/cactus_flower.json | 21 + .../loot_table/blocks/cyan_banner.json | 2 +- .../loot_table/blocks/firefly_bush.json | 21 + .../loot_table/blocks/gray_banner.json | 2 +- .../loot_table/blocks/green_banner.json | 2 +- .../loot_table/blocks/leaf_litter.json | 77 + .../loot_table/blocks/light_blue_banner.json | 2 +- .../loot_table/blocks/light_gray_banner.json | 2 +- .../loot_table/blocks/lime_banner.json | 2 +- .../loot_table/blocks/magenta_banner.json | 2 +- .../loot_table/blocks/orange_banner.json | 2 +- .../loot_table/blocks/pink_banner.json | 2 +- .../loot_table/blocks/purple_banner.json | 2 +- .../loot_table/blocks/red_banner.json | 2 +- .../loot_table/blocks/resin_brick_slab.json | 24 +- .../loot_table/blocks/short_dry_grass.json | 44 + .../loot_table/blocks/tall_dry_grass.json | 44 + .../loot_table/blocks/white_banner.json | 2 +- .../loot_table/blocks/wildflowers.json | 77 + .../loot_table/blocks/yellow_banner.json | 2 +- .../loot_table/chests/ruined_portal.json | 25 + .../chests/village/village_cartographer.json | 21 + .../chests/village/village_desert_house.json | 21 + .../chests/village/village_plains_house.json | 21 + .../chests/village/village_savanna_house.json | 21 + .../chests/village/village_snowy_house.json | 21 + .../chests/village/village_taiga_house.json | 21 + .../chests/village/village_tannery.json | 21 + .../chests/village/village_weaponsmith.json | 21 + .../loot_table/entities/magma_cube.json | 15 +- data/minecraft/loot_table/entities/sheep.json | 64 +- .../loot_table/gameplay/chicken_lay.json | 50 +- .../loot_table/shearing/mooshroom.json | 10 +- data/minecraft/loot_table/shearing/sheep.json | 64 +- data/minecraft/pig_variant/cold.json | 13 + data/minecraft/pig_variant/temperate.json | 8 + data/minecraft/pig_variant/warm.json | 12 + data/minecraft/recipe/black_bundle.json | 4 +- data/minecraft/recipe/black_shulker_box.json | 4 +- data/minecraft/recipe/blue_bundle.json | 4 +- data/minecraft/recipe/blue_shulker_box.json | 4 +- ..._trim_smithing_template_smithing_trim.json | 1 + data/minecraft/recipe/brown_bundle.json | 4 +- data/minecraft/recipe/brown_shulker_box.json | 4 +- data/minecraft/recipe/cake.json | 2 +- ..._trim_smithing_template_smithing_trim.json | 1 + data/minecraft/recipe/cyan_bundle.json | 4 +- data/minecraft/recipe/cyan_shulker_box.json | 4 +- ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + data/minecraft/recipe/gray_bundle.json | 4 +- data/minecraft/recipe/gray_dye.json | 1 + data/minecraft/recipe/gray_shulker_box.json | 4 +- data/minecraft/recipe/green_bundle.json | 4 +- data/minecraft/recipe/green_shulker_box.json | 4 +- ..._trim_smithing_template_smithing_trim.json | 1 + data/minecraft/recipe/leaf_litter.json | 10 + data/minecraft/recipe/light_blue_bundle.json | 4 +- .../recipe/light_blue_shulker_box.json | 4 +- data/minecraft/recipe/light_gray_bundle.json | 4 +- .../recipe/light_gray_shulker_box.json | 4 +- data/minecraft/recipe/lime_bundle.json | 4 +- data/minecraft/recipe/lime_shulker_box.json | 4 +- data/minecraft/recipe/lodestone.json | 2 +- data/minecraft/recipe/magenta_bundle.json | 4 +- .../minecraft/recipe/magenta_shulker_box.json | 4 +- .../recipe/netherite_axe_smithing.json | 1 - .../recipe/netherite_boots_smithing.json | 1 - .../recipe/netherite_chestplate_smithing.json | 1 - .../recipe/netherite_helmet_smithing.json | 1 - .../recipe/netherite_hoe_smithing.json | 1 - .../recipe/netherite_leggings_smithing.json | 1 - .../recipe/netherite_pickaxe_smithing.json | 1 - .../recipe/netherite_shovel_smithing.json | 1 - .../recipe/netherite_sword_smithing.json | 1 - data/minecraft/recipe/orange_bundle.json | 4 +- data/minecraft/recipe/orange_shulker_box.json | 4 +- data/minecraft/recipe/pink_bundle.json | 4 +- .../recipe/pink_dye_from_cactus_flower.json | 12 + data/minecraft/recipe/pink_shulker_box.json | 4 +- data/minecraft/recipe/pumpkin_pie.json | 2 +- data/minecraft/recipe/purple_bundle.json | 4 +- data/minecraft/recipe/purple_shulker_box.json | 4 +- ..._trim_smithing_template_smithing_trim.json | 1 + data/minecraft/recipe/red_bundle.json | 4 +- data/minecraft/recipe/red_shulker_box.json | 4 +- ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + ..._trim_smithing_template_smithing_trim.json | 1 + data/minecraft/recipe/white_bundle.json | 4 +- data/minecraft/recipe/white_shulker_box.json | 4 +- ..._trim_smithing_template_smithing_trim.json | 1 + data/minecraft/recipe/yellow_bundle.json | 4 +- .../recipe/yellow_dye_from_wildflowers.json | 12 + data/minecraft/recipe/yellow_shulker_box.json | 4 +- .../city/entrance/entrance_connector.nbt | 4 +- .../city/entrance/entrance_path_1.nbt | 4 +- .../city/entrance/entrance_path_2.nbt | 4 +- .../city/entrance/entrance_path_3.nbt | 4 +- .../city/entrance/entrance_path_4.nbt | 4 +- .../city/entrance/entrance_path_5.nbt | 4 +- .../city_center/city_center_1.nbt | 4 +- .../city_center/city_center_2.nbt | 4 +- .../city_center/city_center_3.nbt | 2 +- .../city_center/walls/bottom_1.nbt | 4 +- .../city_center/walls/bottom_2.nbt | 4 +- .../city_center/walls/bottom_left_corner.nbt | 4 +- .../city_center/walls/bottom_right_corner.nbt | 4 +- .../walls/bottom_right_corner_1.nbt | 4 +- .../walls/bottom_right_corner_2.nbt | 4 +- .../ancient_city/city_center/walls/left.nbt | 4 +- .../ancient_city/city_center/walls/right.nbt | 4 +- .../ancient_city/city_center/walls/top.nbt | 4 +- .../city_center/walls/top_left_corner.nbt | 4 +- .../city_center/walls/top_right_corner.nbt | 4 +- .../ancient_city/structures/barracks.nbt | 4 +- .../ancient_city/structures/camp_1.nbt | 2 +- .../ancient_city/structures/camp_2.nbt | 4 +- .../ancient_city/structures/camp_3.nbt | 4 +- .../ancient_city/structures/chamber_1.nbt | 4 +- .../ancient_city/structures/chamber_2.nbt | 4 +- .../ancient_city/structures/chamber_3.nbt | 4 +- .../ancient_city/structures/ice_box_1.nbt | 4 +- .../structures/large_pillar_1.nbt | 4 +- .../ancient_city/structures/large_ruin_1.nbt | 4 +- .../structures/medium_pillar_1.nbt | 4 +- .../ancient_city/structures/medium_ruin_1.nbt | 4 +- .../ancient_city/structures/medium_ruin_2.nbt | 4 +- .../ancient_city/structures/sauna_1.nbt | 4 +- .../ancient_city/structures/small_ruin_1.nbt | 4 +- .../ancient_city/structures/small_ruin_2.nbt | 4 +- .../ancient_city/structures/small_statue.nbt | 4 +- .../ancient_city/structures/tall_ruin_1.nbt | 4 +- .../ancient_city/structures/tall_ruin_2.nbt | 4 +- .../ancient_city/structures/tall_ruin_3.nbt | 4 +- .../ancient_city/structures/tall_ruin_4.nbt | 4 +- .../walls/intact_corner_wall_1.nbt | 4 +- .../walls/intact_horizontal_wall_1.nbt | 4 +- .../walls/intact_horizontal_wall_2.nbt | 4 +- .../walls/intact_horizontal_wall_bridge.nbt | 4 +- .../intact_horizontal_wall_passage_1.nbt | 4 +- .../walls/intact_horizontal_wall_stairs_1.nbt | 4 +- .../walls/intact_horizontal_wall_stairs_2.nbt | 4 +- .../walls/intact_horizontal_wall_stairs_3.nbt | 4 +- .../walls/intact_horizontal_wall_stairs_4.nbt | 4 +- .../walls/intact_intersection_wall_1.nbt | 4 +- .../walls/intact_lshape_wall_1.nbt | 4 +- .../walls/ruined_corner_wall_1.nbt | 4 +- .../walls/ruined_corner_wall_2.nbt | 4 +- .../walls/ruined_horizontal_wall_stairs_1.nbt | 4 +- .../walls/ruined_horizontal_wall_stairs_2.nbt | 4 +- .../walls/ruined_horizontal_wall_stairs_3.nbt | 4 +- .../walls/ruined_horizontal_wall_stairs_4.nbt | 4 +- .../structure/bastion/blocks/air.nbt | 4 +- .../structure/bastion/blocks/gold.nbt | 4 +- .../bastion/bridge/bridge_pieces/bridge.nbt | 4 +- .../bridge/connectors/back_bridge_bottom.nbt | 4 +- .../bridge/connectors/back_bridge_top.nbt | 4 +- .../structure/bastion/bridge/legs/leg_0.nbt | 4 +- .../structure/bastion/bridge/legs/leg_1.nbt | 4 +- .../bastion/bridge/rampart_plates/plate_0.nbt | 4 +- .../bastion/bridge/ramparts/rampart_0.nbt | 4 +- .../bastion/bridge/ramparts/rampart_1.nbt | 4 +- .../bridge/starting_pieces/entrance.nbt | 4 +- .../bridge/starting_pieces/entrance_base.nbt | 4 +- .../bridge/starting_pieces/entrance_face.nbt | 4 +- .../bastion/bridge/walls/wall_base_0.nbt | 4 +- .../bastion/bridge/walls/wall_base_1.nbt | 4 +- .../bastion/hoglin_stable/air_base.nbt | 4 +- .../connectors/end_post_connector.nbt | 4 +- .../hoglin_stable/large_stables/inner_0.nbt | 4 +- .../hoglin_stable/large_stables/inner_1.nbt | 4 +- .../hoglin_stable/large_stables/inner_2.nbt | 4 +- .../hoglin_stable/large_stables/inner_3.nbt | 4 +- .../hoglin_stable/large_stables/inner_4.nbt | 4 +- .../hoglin_stable/large_stables/outer_0.nbt | 4 +- .../hoglin_stable/large_stables/outer_1.nbt | 4 +- .../hoglin_stable/large_stables/outer_2.nbt | 4 +- .../hoglin_stable/large_stables/outer_3.nbt | 4 +- .../hoglin_stable/large_stables/outer_4.nbt | 4 +- .../bastion/hoglin_stable/posts/end_post.nbt | 4 +- .../hoglin_stable/posts/stair_post.nbt | 4 +- .../rampart_plates/rampart_plate_1.nbt | 4 +- .../hoglin_stable/ramparts/ramparts_1.nbt | 4 +- .../hoglin_stable/ramparts/ramparts_2.nbt | 4 +- .../hoglin_stable/ramparts/ramparts_3.nbt | 4 +- .../hoglin_stable/small_stables/inner_0.nbt | 4 +- .../hoglin_stable/small_stables/inner_1.nbt | 4 +- .../hoglin_stable/small_stables/inner_2.nbt | 4 +- .../hoglin_stable/small_stables/inner_3.nbt | 4 +- .../hoglin_stable/small_stables/outer_0.nbt | 4 +- .../hoglin_stable/small_stables/outer_1.nbt | 4 +- .../hoglin_stable/small_stables/outer_2.nbt | 4 +- .../hoglin_stable/small_stables/outer_3.nbt | 4 +- .../hoglin_stable/stairs/stairs_1_0.nbt | 4 +- .../hoglin_stable/stairs/stairs_1_1.nbt | 4 +- .../hoglin_stable/stairs/stairs_1_2.nbt | 4 +- .../hoglin_stable/stairs/stairs_1_3.nbt | 4 +- .../hoglin_stable/stairs/stairs_1_4.nbt | 4 +- .../hoglin_stable/stairs/stairs_2_0.nbt | 4 +- .../hoglin_stable/stairs/stairs_2_1.nbt | 4 +- .../hoglin_stable/stairs/stairs_2_2.nbt | 4 +- .../hoglin_stable/stairs/stairs_2_3.nbt | 4 +- .../hoglin_stable/stairs/stairs_2_4.nbt | 4 +- .../hoglin_stable/stairs/stairs_3_0.nbt | 4 +- .../hoglin_stable/stairs/stairs_3_1.nbt | 4 +- .../hoglin_stable/stairs/stairs_3_2.nbt | 4 +- .../hoglin_stable/stairs/stairs_3_3.nbt | 4 +- .../hoglin_stable/stairs/stairs_3_4.nbt | 4 +- .../starting_pieces/stairs_0_mirrored.nbt | 4 +- .../starting_pieces/stairs_1_mirrored.nbt | 4 +- .../starting_pieces/stairs_2_mirrored.nbt | 4 +- .../starting_pieces/stairs_3_mirrored.nbt | 4 +- .../starting_pieces/stairs_4_mirrored.nbt | 4 +- .../starting_pieces/starting_stairs_0.nbt | 4 +- .../starting_pieces/starting_stairs_1.nbt | 4 +- .../starting_pieces/starting_stairs_2.nbt | 4 +- .../starting_pieces/starting_stairs_3.nbt | 4 +- .../starting_pieces/starting_stairs_4.nbt | 4 +- .../hoglin_stable/walls/side_wall_0.nbt | 4 +- .../hoglin_stable/walls/side_wall_1.nbt | 4 +- .../bastion/hoglin_stable/walls/wall_base.nbt | 2 +- .../bastion/mobs/crossbow_piglin.nbt | 4 +- .../structure/bastion/mobs/empty.nbt | 4 +- .../structure/bastion/mobs/hoglin.nbt | 4 +- .../structure/bastion/mobs/melee_piglin.nbt | 4 +- .../bastion/mobs/melee_piglin_always.nbt | 4 +- .../structure/bastion/mobs/sword_piglin.nbt | 4 +- .../treasure/bases/centers/center_0.nbt | 4 +- .../treasure/bases/centers/center_1.nbt | 4 +- .../treasure/bases/centers/center_2.nbt | 4 +- .../treasure/bases/centers/center_3.nbt | 4 +- .../bastion/treasure/bases/lava_basin.nbt | 4 +- .../bastion/treasure/big_air_full.nbt | 4 +- .../bastion/treasure/brains/center_brain.nbt | 4 +- .../connectors/center_to_wall_middle.nbt | 4 +- .../connectors/center_to_wall_top.nbt | 4 +- .../center_to_wall_top_entrance.nbt | 4 +- .../treasure/corners/bottom/corner_0.nbt | 4 +- .../treasure/corners/bottom/corner_1.nbt | 2 +- .../bastion/treasure/corners/edges/bottom.nbt | 4 +- .../bastion/treasure/corners/edges/middle.nbt | 4 +- .../bastion/treasure/corners/edges/top.nbt | 4 +- .../treasure/corners/middle/corner_0.nbt | 4 +- .../treasure/corners/middle/corner_1.nbt | 4 +- .../bastion/treasure/corners/top/corner_0.nbt | 4 +- .../bastion/treasure/corners/top/corner_1.nbt | 4 +- .../bastion/treasure/entrances/entrance_0.nbt | 4 +- .../bastion/treasure/extensions/empty.nbt | 4 +- .../bastion/treasure/extensions/fire_room.nbt | 4 +- .../bastion/treasure/extensions/house_0.nbt | 4 +- .../bastion/treasure/extensions/house_1.nbt | 4 +- .../treasure/extensions/large_bridge_0.nbt | 4 +- .../treasure/extensions/large_bridge_1.nbt | 4 +- .../treasure/extensions/large_bridge_2.nbt | 4 +- .../treasure/extensions/large_bridge_3.nbt | 4 +- .../treasure/extensions/roofed_bridge.nbt | 4 +- .../treasure/extensions/small_bridge_0.nbt | 4 +- .../treasure/extensions/small_bridge_1.nbt | 4 +- .../treasure/extensions/small_bridge_2.nbt | 4 +- .../treasure/extensions/small_bridge_3.nbt | 4 +- .../treasure/ramparts/bottom_wall_0.nbt | 4 +- .../treasure/ramparts/lava_basin_main.nbt | 4 +- .../treasure/ramparts/lava_basin_side.nbt | 4 +- .../treasure/ramparts/mid_wall_main.nbt | 4 +- .../treasure/ramparts/mid_wall_side.nbt | 4 +- .../bastion/treasure/ramparts/top_wall.nbt | 4 +- .../bastion/treasure/roofs/center_roof.nbt | 4 +- .../bastion/treasure/roofs/corner_roof.nbt | 4 +- .../bastion/treasure/roofs/wall_roof.nbt | 2 +- .../bastion/treasure/stairs/lower_stairs.nbt | 4 +- .../bastion/treasure/walls/bottom/wall_0.nbt | 4 +- .../bastion/treasure/walls/bottom/wall_1.nbt | 4 +- .../bastion/treasure/walls/bottom/wall_2.nbt | 4 +- .../bastion/treasure/walls/bottom/wall_3.nbt | 4 +- .../bastion/treasure/walls/entrance_wall.nbt | 4 +- .../bastion/treasure/walls/lava_wall.nbt | 4 +- .../bastion/treasure/walls/mid/wall_0.nbt | 4 +- .../bastion/treasure/walls/mid/wall_1.nbt | 4 +- .../bastion/treasure/walls/mid/wall_2.nbt | 2 +- .../treasure/walls/outer/bottom_corner.nbt | 4 +- .../walls/outer/medium_outer_wall.nbt | 2 +- .../treasure/walls/outer/mid_corner.nbt | 4 +- .../treasure/walls/outer/outer_wall.nbt | 4 +- .../treasure/walls/outer/tall_outer_wall.nbt | 4 +- .../treasure/walls/outer/top_corner.nbt | 4 +- .../treasure/walls/top/main_entrance.nbt | 4 +- .../bastion/treasure/walls/top/wall_0.nbt | 4 +- .../bastion/treasure/walls/top/wall_1.nbt | 4 +- .../structure/bastion/units/air_base.nbt | 4 +- .../bastion/units/center_pieces/center_0.nbt | 4 +- .../bastion/units/center_pieces/center_1.nbt | 4 +- .../bastion/units/center_pieces/center_2.nbt | 4 +- .../structure/bastion/units/edges/edge_0.nbt | 4 +- .../bastion/units/fillers/stage_0.nbt | 4 +- .../bastion/units/pathways/pathway_0.nbt | 4 +- .../bastion/units/pathways/pathway_wall_0.nbt | 4 +- .../bastion/units/rampart_plates/plate_0.nbt | 4 +- .../bastion/units/ramparts/ramparts_0.nbt | 2 +- .../bastion/units/ramparts/ramparts_1.nbt | 4 +- .../bastion/units/ramparts/ramparts_2.nbt | 4 +- .../bastion/units/stages/rot/stage_1_0.nbt | 4 +- .../bastion/units/stages/stage_0_0.nbt | 4 +- .../bastion/units/stages/stage_0_1.nbt | 4 +- .../bastion/units/stages/stage_0_2.nbt | 4 +- .../bastion/units/stages/stage_0_3.nbt | 4 +- .../bastion/units/stages/stage_1_0.nbt | 4 +- .../bastion/units/stages/stage_1_1.nbt | 4 +- .../bastion/units/stages/stage_1_2.nbt | 4 +- .../bastion/units/stages/stage_1_3.nbt | 4 +- .../bastion/units/stages/stage_2_0.nbt | 4 +- .../bastion/units/stages/stage_2_1.nbt | 4 +- .../bastion/units/stages/stage_3_0.nbt | 4 +- .../bastion/units/stages/stage_3_1.nbt | 4 +- .../bastion/units/stages/stage_3_2.nbt | 4 +- .../bastion/units/stages/stage_3_3.nbt | 4 +- .../bastion/units/wall_units/edge_0_large.nbt | 4 +- .../bastion/units/wall_units/unit_0.nbt | 4 +- .../bastion/units/walls/connected_wall.nbt | 4 +- .../bastion/units/walls/wall_base.nbt | 4 +- data/minecraft/structure/empty.nbt | 3 + .../structure/end_city/base_floor.nbt | 4 +- .../structure/end_city/base_roof.nbt | 4 +- .../structure/end_city/bridge_end.nbt | 4 +- .../end_city/bridge_gentle_stairs.nbt | 4 +- .../structure/end_city/bridge_piece.nbt | 4 +- .../end_city/bridge_steep_stairs.nbt | 4 +- .../structure/end_city/fat_tower_base.nbt | 4 +- .../structure/end_city/fat_tower_middle.nbt | 4 +- .../structure/end_city/fat_tower_top.nbt | 4 +- .../structure/end_city/second_floor_1.nbt | 4 +- .../structure/end_city/second_floor_2.nbt | 4 +- .../structure/end_city/second_roof.nbt | 4 +- data/minecraft/structure/end_city/ship.nbt | 4 +- .../structure/end_city/third_floor_1.nbt | 4 +- .../structure/end_city/third_floor_2.nbt | 4 +- .../structure/end_city/third_roof.nbt | 4 +- .../structure/end_city/tower_base.nbt | 4 +- .../structure/end_city/tower_floor.nbt | 4 +- .../structure/end_city/tower_piece.nbt | 4 +- .../structure/end_city/tower_top.nbt | 4 +- data/minecraft/structure/fossil/skull_1.nbt | 4 +- .../structure/fossil/skull_1_coal.nbt | 4 +- data/minecraft/structure/fossil/skull_2.nbt | 4 +- .../structure/fossil/skull_2_coal.nbt | 4 +- data/minecraft/structure/fossil/skull_3.nbt | 4 +- .../structure/fossil/skull_3_coal.nbt | 4 +- data/minecraft/structure/fossil/skull_4.nbt | 4 +- .../structure/fossil/skull_4_coal.nbt | 4 +- data/minecraft/structure/fossil/spine_1.nbt | 4 +- .../structure/fossil/spine_1_coal.nbt | 4 +- data/minecraft/structure/fossil/spine_2.nbt | 4 +- .../structure/fossil/spine_2_coal.nbt | 4 +- data/minecraft/structure/fossil/spine_3.nbt | 4 +- .../structure/fossil/spine_3_coal.nbt | 4 +- data/minecraft/structure/fossil/spine_4.nbt | 4 +- .../structure/fossil/spine_4_coal.nbt | 4 +- data/minecraft/structure/igloo/bottom.nbt | 4 +- data/minecraft/structure/igloo/middle.nbt | 4 +- data/minecraft/structure/igloo/top.nbt | 4 +- .../structure/nether_fossils/fossil_1.nbt | 4 +- .../structure/nether_fossils/fossil_10.nbt | 4 +- .../structure/nether_fossils/fossil_11.nbt | 4 +- .../structure/nether_fossils/fossil_12.nbt | 4 +- .../structure/nether_fossils/fossil_13.nbt | 4 +- .../structure/nether_fossils/fossil_14.nbt | 4 +- .../structure/nether_fossils/fossil_2.nbt | 4 +- .../structure/nether_fossils/fossil_3.nbt | 2 +- .../structure/nether_fossils/fossil_4.nbt | 4 +- .../structure/nether_fossils/fossil_5.nbt | 4 +- .../structure/nether_fossils/fossil_6.nbt | 4 +- .../structure/nether_fossils/fossil_7.nbt | 4 +- .../structure/nether_fossils/fossil_8.nbt | 4 +- .../structure/nether_fossils/fossil_9.nbt | 4 +- .../structure/pillager_outpost/base_plate.nbt | 2 +- .../pillager_outpost/feature_cage1.nbt | 4 +- .../pillager_outpost/feature_cage2.nbt | 4 +- .../feature_cage_with_allays.nbt | 4 +- .../pillager_outpost/feature_logs.nbt | 4 +- .../pillager_outpost/feature_plate.nbt | 4 +- .../pillager_outpost/feature_targets.nbt | 4 +- .../pillager_outpost/feature_tent1.nbt | 4 +- .../pillager_outpost/feature_tent2.nbt | 4 +- .../structure/pillager_outpost/watchtower.nbt | 4 +- .../pillager_outpost/watchtower_overgrown.nbt | 4 +- .../ruined_portal/giant_portal_1.nbt | 4 +- .../ruined_portal/giant_portal_2.nbt | 4 +- .../ruined_portal/giant_portal_3.nbt | 4 +- .../structure/ruined_portal/portal_1.nbt | 4 +- .../structure/ruined_portal/portal_10.nbt | 4 +- .../structure/ruined_portal/portal_2.nbt | 2 +- .../structure/ruined_portal/portal_3.nbt | 4 +- .../structure/ruined_portal/portal_4.nbt | 4 +- .../structure/ruined_portal/portal_5.nbt | 4 +- .../structure/ruined_portal/portal_6.nbt | 4 +- .../structure/ruined_portal/portal_7.nbt | 4 +- .../structure/ruined_portal/portal_8.nbt | 4 +- .../structure/ruined_portal/portal_9.nbt | 4 +- .../shipwreck/rightsideup_backhalf.nbt | 4 +- .../rightsideup_backhalf_degraded.nbt | 4 +- .../shipwreck/rightsideup_fronthalf.nbt | 4 +- .../rightsideup_fronthalf_degraded.nbt | 4 +- .../structure/shipwreck/rightsideup_full.nbt | 4 +- .../shipwreck/rightsideup_full_degraded.nbt | 4 +- .../structure/shipwreck/sideways_backhalf.nbt | 4 +- .../shipwreck/sideways_backhalf_degraded.nbt | 4 +- .../shipwreck/sideways_fronthalf.nbt | 4 +- .../shipwreck/sideways_fronthalf_degraded.nbt | 4 +- .../structure/shipwreck/sideways_full.nbt | 4 +- .../shipwreck/sideways_full_degraded.nbt | 4 +- .../shipwreck/upsidedown_backhalf.nbt | 4 +- .../upsidedown_backhalf_degraded.nbt | 4 +- .../shipwreck/upsidedown_fronthalf.nbt | 4 +- .../upsidedown_fronthalf_degraded.nbt | 4 +- .../structure/shipwreck/upsidedown_full.nbt | 4 +- .../shipwreck/upsidedown_full_degraded.nbt | 4 +- .../structure/shipwreck/with_mast.nbt | 4 +- .../shipwreck/with_mast_degraded.nbt | 4 +- .../trail_ruins/buildings/group_full_1.nbt | 4 +- .../trail_ruins/buildings/group_full_2.nbt | 4 +- .../trail_ruins/buildings/group_full_3.nbt | 4 +- .../trail_ruins/buildings/group_full_4.nbt | 4 +- .../trail_ruins/buildings/group_full_5.nbt | 4 +- .../trail_ruins/buildings/group_hall_1.nbt | 4 +- .../trail_ruins/buildings/group_hall_2.nbt | 4 +- .../trail_ruins/buildings/group_hall_3.nbt | 4 +- .../trail_ruins/buildings/group_hall_4.nbt | 4 +- .../trail_ruins/buildings/group_hall_5.nbt | 4 +- .../trail_ruins/buildings/group_lower_1.nbt | 4 +- .../trail_ruins/buildings/group_lower_2.nbt | 2 +- .../trail_ruins/buildings/group_lower_3.nbt | 2 +- .../trail_ruins/buildings/group_lower_4.nbt | 4 +- .../trail_ruins/buildings/group_lower_5.nbt | 4 +- .../trail_ruins/buildings/group_room_1.nbt | 4 +- .../trail_ruins/buildings/group_room_2.nbt | 4 +- .../trail_ruins/buildings/group_room_3.nbt | 4 +- .../trail_ruins/buildings/group_room_4.nbt | 4 +- .../trail_ruins/buildings/group_room_5.nbt | 4 +- .../trail_ruins/buildings/group_upper_1.nbt | 4 +- .../trail_ruins/buildings/group_upper_2.nbt | 4 +- .../trail_ruins/buildings/group_upper_3.nbt | 4 +- .../trail_ruins/buildings/group_upper_4.nbt | 4 +- .../trail_ruins/buildings/group_upper_5.nbt | 4 +- .../trail_ruins/buildings/large_room_1.nbt | 4 +- .../trail_ruins/buildings/large_room_2.nbt | 4 +- .../trail_ruins/buildings/large_room_3.nbt | 4 +- .../trail_ruins/buildings/large_room_4.nbt | 4 +- .../trail_ruins/buildings/large_room_5.nbt | 4 +- .../trail_ruins/buildings/one_room_1.nbt | 4 +- .../trail_ruins/buildings/one_room_2.nbt | 4 +- .../trail_ruins/buildings/one_room_3.nbt | 4 +- .../trail_ruins/buildings/one_room_4.nbt | 4 +- .../trail_ruins/buildings/one_room_5.nbt | 4 +- .../structure/trail_ruins/decor/decor_1.nbt | 4 +- .../structure/trail_ruins/decor/decor_2.nbt | 4 +- .../structure/trail_ruins/decor/decor_3.nbt | 4 +- .../structure/trail_ruins/decor/decor_4.nbt | 4 +- .../structure/trail_ruins/decor/decor_5.nbt | 4 +- .../structure/trail_ruins/decor/decor_6.nbt | 4 +- .../structure/trail_ruins/decor/decor_7.nbt | 4 +- .../trail_ruins/roads/long_road_end.nbt | 4 +- .../trail_ruins/roads/road_end_1.nbt | 4 +- .../trail_ruins/roads/road_section_1.nbt | 4 +- .../trail_ruins/roads/road_section_2.nbt | 4 +- .../trail_ruins/roads/road_section_3.nbt | 4 +- .../trail_ruins/roads/road_section_4.nbt | 4 +- .../trail_ruins/roads/road_spacer_1.nbt | 4 +- .../structure/trail_ruins/tower/hall_1.nbt | 4 +- .../structure/trail_ruins/tower/hall_2.nbt | 4 +- .../structure/trail_ruins/tower/hall_3.nbt | 4 +- .../structure/trail_ruins/tower/hall_4.nbt | 4 +- .../structure/trail_ruins/tower/hall_5.nbt | 4 +- .../trail_ruins/tower/large_hall_1.nbt | 4 +- .../trail_ruins/tower/large_hall_2.nbt | 4 +- .../trail_ruins/tower/large_hall_3.nbt | 4 +- .../trail_ruins/tower/large_hall_4.nbt | 4 +- .../trail_ruins/tower/large_hall_5.nbt | 4 +- .../trail_ruins/tower/one_room_1.nbt | 4 +- .../trail_ruins/tower/one_room_2.nbt | 4 +- .../trail_ruins/tower/one_room_3.nbt | 4 +- .../trail_ruins/tower/one_room_4.nbt | 4 +- .../trail_ruins/tower/one_room_5.nbt | 4 +- .../trail_ruins/tower/platform_1.nbt | 4 +- .../trail_ruins/tower/platform_2.nbt | 4 +- .../trail_ruins/tower/platform_3.nbt | 4 +- .../trail_ruins/tower/platform_4.nbt | 4 +- .../trail_ruins/tower/platform_5.nbt | 4 +- .../structure/trail_ruins/tower/stable_1.nbt | 4 +- .../structure/trail_ruins/tower/stable_2.nbt | 4 +- .../structure/trail_ruins/tower/stable_3.nbt | 4 +- .../structure/trail_ruins/tower/stable_4.nbt | 4 +- .../structure/trail_ruins/tower/stable_5.nbt | 4 +- .../structure/trail_ruins/tower/tower_1.nbt | 4 +- .../structure/trail_ruins/tower/tower_2.nbt | 4 +- .../structure/trail_ruins/tower/tower_3.nbt | 4 +- .../structure/trail_ruins/tower/tower_4.nbt | 4 +- .../structure/trail_ruins/tower/tower_5.nbt | 4 +- .../trail_ruins/tower/tower_top_1.nbt | 4 +- .../trail_ruins/tower/tower_top_2.nbt | 4 +- .../trail_ruins/tower/tower_top_3.nbt | 4 +- .../trail_ruins/tower/tower_top_4.nbt | 4 +- .../trail_ruins/tower/tower_top_5.nbt | 4 +- .../chamber/addon/c1_breeze.nbt | 4 +- .../chamber/addon/full_corner_column.nbt | 4 +- .../chamber/addon/full_stacked_walkway.nbt | 4 +- .../chamber/addon/full_stacked_walkway_2.nbt | 4 +- .../chamber/addon/grate_bridge.nbt | 4 +- .../chamber/addon/hanging_platform.nbt | 4 +- .../chamber/addon/lower_staircase_down.nbt | 4 +- .../chamber/addon/short_grate_platform.nbt | 4 +- .../chamber/addon/short_platform.nbt | 4 +- .../chamber/addon/walkway_with_bridge_1.nbt | 4 +- .../trial_chambers/chamber/assembly.nbt | 4 +- .../chamber/assembly/cover_1.nbt | 4 +- .../chamber/assembly/cover_2.nbt | 4 +- .../chamber/assembly/cover_3.nbt | 4 +- .../chamber/assembly/cover_4.nbt | 4 +- .../chamber/assembly/cover_5.nbt | 4 +- .../chamber/assembly/cover_6.nbt | 4 +- .../chamber/assembly/cover_7.nbt | 4 +- .../chamber/assembly/full_column.nbt | 4 +- .../chamber/assembly/hanging_1.nbt | 4 +- .../chamber/assembly/hanging_2.nbt | 4 +- .../chamber/assembly/hanging_3.nbt | 4 +- .../chamber/assembly/hanging_4.nbt | 4 +- .../chamber/assembly/hanging_5.nbt | 4 +- .../chamber/assembly/left_staircase_1.nbt | 4 +- .../chamber/assembly/left_staircase_2.nbt | 4 +- .../chamber/assembly/left_staircase_3.nbt | 4 +- .../chamber/assembly/platform_1.nbt | 4 +- .../chamber/assembly/right_staircase_1.nbt | 4 +- .../chamber/assembly/right_staircase_2.nbt | 4 +- .../chamber/assembly/right_staircase_3.nbt | 4 +- .../chamber/assembly/spawner_1.nbt | 4 +- .../trial_chambers/chamber/chamber_1.nbt | 4 +- .../trial_chambers/chamber/chamber_2.nbt | 4 +- .../trial_chambers/chamber/chamber_4.nbt | 4 +- .../trial_chambers/chamber/chamber_8.nbt | 2 +- .../trial_chambers/chamber/entrance_cap.nbt | 4 +- .../trial_chambers/chamber/eruption.nbt | 4 +- .../chamber/eruption/breeze_slice_1.nbt | 4 +- .../chamber/eruption/center_1.nbt | 4 +- .../chamber/eruption/quadrant_1.nbt | 4 +- .../chamber/eruption/quadrant_2.nbt | 4 +- .../chamber/eruption/quadrant_3.nbt | 4 +- .../chamber/eruption/quadrant_4.nbt | 4 +- .../chamber/eruption/quadrant_5.nbt | 4 +- .../chamber/eruption/slice_1.nbt | 4 +- .../chamber/eruption/slice_2.nbt | 4 +- .../chamber/eruption/slice_3.nbt | 4 +- .../trial_chambers/chamber/pedestal.nbt | 4 +- .../chamber/pedestal/center_1.nbt | 4 +- .../chamber/pedestal/ominous_slice_1.nbt | 4 +- .../chamber/pedestal/quadrant_1.nbt | 4 +- .../chamber/pedestal/quadrant_2.nbt | 4 +- .../chamber/pedestal/quadrant_3.nbt | 4 +- .../chamber/pedestal/slice_1.nbt | 4 +- .../chamber/pedestal/slice_2.nbt | 4 +- .../chamber/pedestal/slice_3.nbt | 4 +- .../chamber/pedestal/slice_4.nbt | 4 +- .../chamber/pedestal/slice_5.nbt | 4 +- .../trial_chambers/chamber/slanted.nbt | 4 +- .../trial_chambers/chamber/slanted/center.nbt | 4 +- .../chamber/slanted/hallway_1.nbt | 4 +- .../chamber/slanted/hallway_2.nbt | 4 +- .../chamber/slanted/hallway_3.nbt | 4 +- .../chamber/slanted/ominous_upper_arm_1.nbt | 4 +- .../chamber/slanted/quadrant_1.nbt | 4 +- .../chamber/slanted/quadrant_2.nbt | 2 +- .../chamber/slanted/quadrant_3.nbt | 2 +- .../chamber/slanted/quadrant_4.nbt | 4 +- .../trial_chambers/chamber/slanted/ramp_1.nbt | 4 +- .../trial_chambers/chamber/slanted/ramp_2.nbt | 4 +- .../trial_chambers/chamber/slanted/ramp_3.nbt | 4 +- .../trial_chambers/chamber/slanted/ramp_4.nbt | 4 +- .../chests/connectors/supply.nbt | 4 +- .../trial_chambers/chests/supply.nbt | 4 +- .../corridor/addon/arrow_dispenser.nbt | 4 +- .../corridor/addon/bridge_lower.nbt | 4 +- .../corridor/addon/chandelier_upper.nbt | 4 +- .../corridor/addon/decoration_upper.nbt | 4 +- .../corridor/addon/display_1.nbt | 4 +- .../corridor/addon/display_2.nbt | 4 +- .../corridor/addon/display_3.nbt | 4 +- .../corridor/addon/head_upper.nbt | 4 +- .../corridor/addon/ladder_to_middle.nbt | 4 +- .../corridor/addon/open_walkway.nbt | 4 +- .../corridor/addon/open_walkway_upper.nbt | 4 +- .../corridor/addon/reward_upper.nbt | 4 +- .../corridor/addon/staircase.nbt | 4 +- .../trial_chambers/corridor/addon/wall.nbt | 4 +- .../corridor/addon/walled_walkway.nbt | 4 +- .../corridor/atrium/bogged_relief.nbt | 4 +- .../corridor/atrium/breeze_relief.nbt | 4 +- .../corridor/atrium/grand_staircase_1.nbt | 4 +- .../corridor/atrium/grand_staircase_2.nbt | 4 +- .../corridor/atrium/grand_staircase_3.nbt | 4 +- .../corridor/atrium/spider_relief.nbt | 4 +- .../corridor/atrium/spiral_relief.nbt | 4 +- .../trial_chambers/corridor/atrium_1.nbt | 4 +- .../trial_chambers/corridor/end_1.nbt | 4 +- .../trial_chambers/corridor/end_2.nbt | 4 +- .../trial_chambers/corridor/entrance_1.nbt | 4 +- .../trial_chambers/corridor/entrance_2.nbt | 4 +- .../trial_chambers/corridor/entrance_3.nbt | 4 +- .../trial_chambers/corridor/first_plate.nbt | 4 +- .../trial_chambers/corridor/second_plate.nbt | 4 +- .../trial_chambers/corridor/straight_1.nbt | 4 +- .../trial_chambers/corridor/straight_2.nbt | 4 +- .../trial_chambers/corridor/straight_3.nbt | 4 +- .../trial_chambers/corridor/straight_4.nbt | 4 +- .../trial_chambers/corridor/straight_5.nbt | 4 +- .../trial_chambers/corridor/straight_6.nbt | 4 +- .../trial_chambers/corridor/straight_7.nbt | 4 +- .../trial_chambers/corridor/straight_8.nbt | 4 +- .../structure/trial_chambers/decor/barrel.nbt | 4 +- .../trial_chambers/decor/black_bed.nbt | 4 +- .../trial_chambers/decor/blue_bed.nbt | 4 +- .../trial_chambers/decor/brown_bed.nbt | 4 +- .../trial_chambers/decor/candle_1.nbt | 4 +- .../trial_chambers/decor/candle_2.nbt | 4 +- .../trial_chambers/decor/candle_3.nbt | 4 +- .../trial_chambers/decor/candle_4.nbt | 4 +- .../trial_chambers/decor/cyan_bed.nbt | 4 +- .../trial_chambers/decor/dead_bush_pot.nbt | 4 +- .../trial_chambers/decor/disposal.nbt | 4 +- .../trial_chambers/decor/empty_pot.nbt | 4 +- .../trial_chambers/decor/flow_pot.nbt | 4 +- .../trial_chambers/decor/gray_bed.nbt | 4 +- .../trial_chambers/decor/green_bed.nbt | 4 +- .../trial_chambers/decor/guster_pot.nbt | 4 +- .../trial_chambers/decor/light_blue_bed.nbt | 4 +- .../trial_chambers/decor/light_gray_bed.nbt | 4 +- .../trial_chambers/decor/lime_bed.nbt | 4 +- .../trial_chambers/decor/magenta_bed.nbt | 4 +- .../trial_chambers/decor/orange_bed.nbt | 4 +- .../trial_chambers/decor/pink_bed.nbt | 4 +- .../trial_chambers/decor/purple_bed.nbt | 4 +- .../trial_chambers/decor/red_bed.nbt | 4 +- .../trial_chambers/decor/scrape_pot.nbt | 4 +- .../trial_chambers/decor/undecorated_pot.nbt | 4 +- .../trial_chambers/decor/white_bed.nbt | 4 +- .../trial_chambers/decor/yellow_bed.nbt | 4 +- .../trial_chambers/dispensers/chamber.nbt | 4 +- .../dispensers/floor_dispenser.nbt | 4 +- .../dispensers/wall_dispenser.nbt | 4 +- .../trial_chambers/hallway/cache_1.nbt | 4 +- .../hallway/corner_staircase.nbt | 4 +- .../hallway/corner_staircase_down.nbt | 4 +- .../hallway/corridor_connector_1.nbt | 4 +- .../trial_chambers/hallway/encounter_1.nbt | 4 +- .../trial_chambers/hallway/encounter_2.nbt | 4 +- .../trial_chambers/hallway/encounter_3.nbt | 4 +- .../trial_chambers/hallway/encounter_4.nbt | 4 +- .../trial_chambers/hallway/encounter_5.nbt | 4 +- .../trial_chambers/hallway/left_corner.nbt | 4 +- .../hallway/long_straight_staircase.nbt | 4 +- .../hallway/long_straight_staircase_down.nbt | 4 +- .../hallway/lower_hallway_connector.nbt | 4 +- .../trial_chambers/hallway/right_corner.nbt | 4 +- .../trial_chambers/hallway/rubble.nbt | 4 +- .../trial_chambers/hallway/rubble_chamber.nbt | 4 +- .../hallway/rubble_chamber_thin.nbt | 4 +- .../trial_chambers/hallway/rubble_thin.nbt | 4 +- .../trial_chambers/hallway/straight.nbt | 4 +- .../hallway/straight_staircase.nbt | 2 +- .../hallway/straight_staircase_down.nbt | 4 +- .../hallway/trapped_staircase.nbt | 4 +- .../hallway/upper_hallway_connector.nbt | 4 +- .../intersection/intersection_1.nbt | 4 +- .../intersection/intersection_2.nbt | 4 +- .../intersection/intersection_3.nbt | 4 +- .../trial_chambers/reward/ominous_vault.nbt | 4 +- .../structure/trial_chambers/reward/vault.nbt | 4 +- .../trial_chambers/spawner/breeze/breeze.nbt | 4 +- .../spawner/connectors/breeze.nbt | 4 +- .../spawner/connectors/melee.nbt | 4 +- .../spawner/connectors/ranged.nbt | 4 +- .../spawner/connectors/slow_ranged.nbt | 4 +- .../spawner/connectors/small_melee.nbt | 4 +- .../trial_chambers/spawner/melee/husk.nbt | 4 +- .../trial_chambers/spawner/melee/spider.nbt | 4 +- .../trial_chambers/spawner/melee/zombie.nbt | 4 +- .../spawner/ranged/poison_skeleton.nbt | 4 +- .../spawner/ranged/skeleton.nbt | 4 +- .../trial_chambers/spawner/ranged/stray.nbt | 4 +- .../spawner/slow_ranged/poison_skeleton.nbt | 4 +- .../spawner/slow_ranged/skeleton.nbt | 4 +- .../spawner/slow_ranged/stray.nbt | 4 +- .../spawner/small_melee/baby_zombie.nbt | 4 +- .../spawner/small_melee/cave_spider.nbt | 4 +- .../spawner/small_melee/silverfish.nbt | 4 +- .../spawner/small_melee/slime.nbt | 4 +- .../structure/underwater_ruin/big_brick_1.nbt | 4 +- .../structure/underwater_ruin/big_brick_2.nbt | 4 +- .../structure/underwater_ruin/big_brick_3.nbt | 4 +- .../structure/underwater_ruin/big_brick_8.nbt | 4 +- .../underwater_ruin/big_cracked_1.nbt | 4 +- .../underwater_ruin/big_cracked_2.nbt | 4 +- .../underwater_ruin/big_cracked_3.nbt | 4 +- .../underwater_ruin/big_cracked_8.nbt | 4 +- .../structure/underwater_ruin/big_mossy_1.nbt | 4 +- .../structure/underwater_ruin/big_mossy_2.nbt | 4 +- .../structure/underwater_ruin/big_mossy_3.nbt | 4 +- .../structure/underwater_ruin/big_mossy_8.nbt | 4 +- .../structure/underwater_ruin/big_warm_4.nbt | 4 +- .../structure/underwater_ruin/big_warm_5.nbt | 4 +- .../structure/underwater_ruin/big_warm_6.nbt | 4 +- .../structure/underwater_ruin/big_warm_7.nbt | 4 +- .../structure/underwater_ruin/brick_1.nbt | 4 +- .../structure/underwater_ruin/brick_2.nbt | 4 +- .../structure/underwater_ruin/brick_3.nbt | 4 +- .../structure/underwater_ruin/brick_4.nbt | 4 +- .../structure/underwater_ruin/brick_5.nbt | 4 +- .../structure/underwater_ruin/brick_6.nbt | 4 +- .../structure/underwater_ruin/brick_7.nbt | 4 +- .../structure/underwater_ruin/brick_8.nbt | 4 +- .../structure/underwater_ruin/cracked_1.nbt | 4 +- .../structure/underwater_ruin/cracked_2.nbt | 4 +- .../structure/underwater_ruin/cracked_3.nbt | 4 +- .../structure/underwater_ruin/cracked_4.nbt | 4 +- .../structure/underwater_ruin/cracked_5.nbt | 4 +- .../structure/underwater_ruin/cracked_6.nbt | 4 +- .../structure/underwater_ruin/cracked_7.nbt | 4 +- .../structure/underwater_ruin/cracked_8.nbt | 4 +- .../structure/underwater_ruin/mossy_1.nbt | 4 +- .../structure/underwater_ruin/mossy_2.nbt | 4 +- .../structure/underwater_ruin/mossy_3.nbt | 4 +- .../structure/underwater_ruin/mossy_4.nbt | 4 +- .../structure/underwater_ruin/mossy_5.nbt | 4 +- .../structure/underwater_ruin/mossy_6.nbt | 4 +- .../structure/underwater_ruin/mossy_7.nbt | 4 +- .../structure/underwater_ruin/mossy_8.nbt | 4 +- .../structure/underwater_ruin/warm_1.nbt | 4 +- .../structure/underwater_ruin/warm_2.nbt | 4 +- .../structure/underwater_ruin/warm_3.nbt | 4 +- .../structure/underwater_ruin/warm_4.nbt | 4 +- .../structure/underwater_ruin/warm_5.nbt | 4 +- .../structure/underwater_ruin/warm_6.nbt | 4 +- .../structure/underwater_ruin/warm_7.nbt | 4 +- .../structure/underwater_ruin/warm_8.nbt | 4 +- .../village/common/animals/cat_black.nbt | 4 +- .../village/common/animals/cat_british.nbt | 4 +- .../village/common/animals/cat_calico.nbt | 4 +- .../village/common/animals/cat_jellie.nbt | 4 +- .../village/common/animals/cat_persian.nbt | 4 +- .../village/common/animals/cat_ragdoll.nbt | 4 +- .../village/common/animals/cat_red.nbt | 4 +- .../village/common/animals/cat_siamese.nbt | 4 +- .../village/common/animals/cat_tabby.nbt | 4 +- .../village/common/animals/cat_white.nbt | 4 +- .../village/common/animals/cows_1.nbt | 4 +- .../village/common/animals/horses_1.nbt | 4 +- .../village/common/animals/horses_2.nbt | 4 +- .../village/common/animals/horses_3.nbt | 4 +- .../village/common/animals/horses_4.nbt | 4 +- .../village/common/animals/horses_5.nbt | 4 +- .../village/common/animals/pigs_1.nbt | 4 +- .../village/common/animals/sheep_1.nbt | 4 +- .../village/common/animals/sheep_2.nbt | 4 +- .../structure/village/common/iron_golem.nbt | 4 +- .../structure/village/common/well_bottom.nbt | 4 +- .../structure/village/decays/grass_11x13.nbt | 4 +- .../structure/village/decays/grass_16x16.nbt | 4 +- .../structure/village/decays/grass_9x9.nbt | 2 +- .../structure/village/desert/camel_spawn.nbt | 4 +- .../village/desert/desert_lamp_1.nbt | 4 +- .../desert/houses/desert_animal_pen_1.nbt | 4 +- .../desert/houses/desert_animal_pen_2.nbt | 4 +- .../desert/houses/desert_armorer_1.nbt | 4 +- .../desert/houses/desert_butcher_shop_1.nbt | 4 +- .../houses/desert_cartographer_house_1.nbt | 4 +- .../village/desert/houses/desert_farm_1.nbt | 4 +- .../village/desert/houses/desert_farm_2.nbt | 4 +- .../village/desert/houses/desert_fisher_1.nbt | 4 +- .../desert/houses/desert_fletcher_house_1.nbt | 4 +- .../desert/houses/desert_large_farm_1.nbt | 4 +- .../desert/houses/desert_library_1.nbt | 4 +- .../village/desert/houses/desert_mason_1.nbt | 4 +- .../desert/houses/desert_medium_house_1.nbt | 4 +- .../desert/houses/desert_medium_house_2.nbt | 4 +- .../desert/houses/desert_shepherd_house_1.nbt | 4 +- .../desert/houses/desert_small_house_1.nbt | 4 +- .../desert/houses/desert_small_house_2.nbt | 4 +- .../desert/houses/desert_small_house_3.nbt | 4 +- .../desert/houses/desert_small_house_4.nbt | 4 +- .../desert/houses/desert_small_house_5.nbt | 4 +- .../desert/houses/desert_small_house_6.nbt | 4 +- .../desert/houses/desert_small_house_7.nbt | 4 +- .../desert/houses/desert_small_house_8.nbt | 4 +- .../desert/houses/desert_tannery_1.nbt | 4 +- .../village/desert/houses/desert_temple_1.nbt | 4 +- .../village/desert/houses/desert_temple_2.nbt | 4 +- .../desert/houses/desert_tool_smith_1.nbt | 2 +- .../desert/houses/desert_weaponsmith_1.nbt | 4 +- .../village/desert/streets/corner_01.nbt | 4 +- .../village/desert/streets/corner_02.nbt | 4 +- .../village/desert/streets/crossroad_01.nbt | 4 +- .../village/desert/streets/crossroad_02.nbt | 4 +- .../village/desert/streets/crossroad_03.nbt | 4 +- .../village/desert/streets/square_01.nbt | 4 +- .../village/desert/streets/square_02.nbt | 4 +- .../village/desert/streets/straight_01.nbt | 4 +- .../village/desert/streets/straight_02.nbt | 4 +- .../village/desert/streets/straight_03.nbt | 4 +- .../village/desert/streets/turn_01.nbt | 4 +- .../desert/terminators/terminator_01.nbt | 4 +- .../desert/terminators/terminator_02.nbt | 4 +- .../town_centers/desert_meeting_point_1.nbt | 4 +- .../town_centers/desert_meeting_point_2.nbt | 4 +- .../town_centers/desert_meeting_point_3.nbt | 4 +- .../village/desert/villagers/baby.nbt | 4 +- .../village/desert/villagers/nitwit.nbt | 4 +- .../village/desert/villagers/unemployed.nbt | 4 +- .../zombie/houses/desert_medium_house_1.nbt | 4 +- .../zombie/houses/desert_medium_house_2.nbt | 4 +- .../zombie/houses/desert_small_house_1.nbt | 4 +- .../zombie/houses/desert_small_house_2.nbt | 4 +- .../zombie/houses/desert_small_house_3.nbt | 4 +- .../zombie/houses/desert_small_house_4.nbt | 4 +- .../zombie/houses/desert_small_house_5.nbt | 4 +- .../zombie/houses/desert_small_house_6.nbt | 4 +- .../zombie/houses/desert_small_house_7.nbt | 4 +- .../zombie/houses/desert_small_house_8.nbt | 4 +- .../desert/zombie/streets/corner_01.nbt | 4 +- .../desert/zombie/streets/corner_02.nbt | 4 +- .../desert/zombie/streets/crossroad_01.nbt | 4 +- .../desert/zombie/streets/crossroad_02.nbt | 4 +- .../desert/zombie/streets/crossroad_03.nbt | 4 +- .../desert/zombie/streets/square_01.nbt | 2 +- .../desert/zombie/streets/square_02.nbt | 4 +- .../desert/zombie/streets/straight_01.nbt | 4 +- .../desert/zombie/streets/straight_02.nbt | 4 +- .../desert/zombie/streets/straight_03.nbt | 4 +- .../village/desert/zombie/streets/turn_01.nbt | 4 +- .../zombie/terminators/terminator_02.nbt | 4 +- .../town_centers/desert_meeting_point_1.nbt | 4 +- .../town_centers/desert_meeting_point_2.nbt | 4 +- .../town_centers/desert_meeting_point_3.nbt | 4 +- .../desert/zombie/villagers/nitwit.nbt | 4 +- .../desert/zombie/villagers/unemployed.nbt | 4 +- .../plains/houses/plains_accessory_1.nbt | 4 +- .../plains/houses/plains_animal_pen_1.nbt | 4 +- .../plains/houses/plains_animal_pen_2.nbt | 4 +- .../plains/houses/plains_animal_pen_3.nbt | 4 +- .../plains/houses/plains_armorer_house_1.nbt | 4 +- .../plains/houses/plains_big_house_1.nbt | 4 +- .../plains/houses/plains_butcher_shop_1.nbt | 4 +- .../plains/houses/plains_butcher_shop_2.nbt | 4 +- .../plains/houses/plains_cartographer_1.nbt | 4 +- .../plains/houses/plains_fisher_cottage_1.nbt | 4 +- .../plains/houses/plains_fletcher_house_1.nbt | 4 +- .../plains/houses/plains_large_farm_1.nbt | 4 +- .../plains/houses/plains_library_1.nbt | 4 +- .../plains/houses/plains_library_2.nbt | 4 +- .../plains/houses/plains_masons_house_1.nbt | 4 +- .../plains/houses/plains_medium_house_1.nbt | 4 +- .../plains/houses/plains_medium_house_2.nbt | 4 +- .../plains/houses/plains_meeting_point_4.nbt | 4 +- .../plains/houses/plains_meeting_point_5.nbt | 4 +- .../houses/plains_shepherds_house_1.nbt | 4 +- .../plains/houses/plains_small_farm_1.nbt | 4 +- .../plains/houses/plains_small_house_1.nbt | 4 +- .../plains/houses/plains_small_house_2.nbt | 4 +- .../plains/houses/plains_small_house_3.nbt | 4 +- .../plains/houses/plains_small_house_4.nbt | 4 +- .../plains/houses/plains_small_house_5.nbt | 4 +- .../plains/houses/plains_small_house_6.nbt | 4 +- .../plains/houses/plains_small_house_7.nbt | 4 +- .../plains/houses/plains_small_house_8.nbt | 4 +- .../village/plains/houses/plains_stable_1.nbt | 2 +- .../village/plains/houses/plains_stable_2.nbt | 4 +- .../plains/houses/plains_tannery_1.nbt | 4 +- .../village/plains/houses/plains_temple_3.nbt | 4 +- .../village/plains/houses/plains_temple_4.nbt | 4 +- .../plains/houses/plains_tool_smith_1.nbt | 4 +- .../plains/houses/plains_weaponsmith_1.nbt | 4 +- .../village/plains/plains_lamp_1.nbt | 4 +- .../village/plains/streets/corner_01.nbt | 4 +- .../village/plains/streets/corner_02.nbt | 4 +- .../village/plains/streets/corner_03.nbt | 4 +- .../village/plains/streets/crossroad_01.nbt | 4 +- .../village/plains/streets/crossroad_02.nbt | 4 +- .../village/plains/streets/crossroad_03.nbt | 4 +- .../village/plains/streets/crossroad_04.nbt | 4 +- .../village/plains/streets/crossroad_05.nbt | 4 +- .../village/plains/streets/crossroad_06.nbt | 4 +- .../village/plains/streets/straight_01.nbt | 4 +- .../village/plains/streets/straight_02.nbt | 4 +- .../village/plains/streets/straight_03.nbt | 4 +- .../village/plains/streets/straight_04.nbt | 4 +- .../village/plains/streets/straight_05.nbt | 4 +- .../village/plains/streets/straight_06.nbt | 4 +- .../village/plains/streets/turn_01.nbt | 4 +- .../plains/terminators/terminator_01.nbt | 4 +- .../plains/terminators/terminator_02.nbt | 4 +- .../plains/terminators/terminator_03.nbt | 4 +- .../plains/terminators/terminator_04.nbt | 4 +- .../town_centers/plains_fountain_01.nbt | 2 +- .../town_centers/plains_meeting_point_1.nbt | 4 +- .../town_centers/plains_meeting_point_2.nbt | 4 +- .../town_centers/plains_meeting_point_3.nbt | 4 +- .../village/plains/villagers/baby.nbt | 4 +- .../village/plains/villagers/nitwit.nbt | 4 +- .../village/plains/villagers/unemployed.nbt | 4 +- .../zombie/houses/plains_animal_pen_3.nbt | 4 +- .../zombie/houses/plains_big_house_1.nbt | 4 +- .../zombie/houses/plains_butcher_shop_2.nbt | 4 +- .../zombie/houses/plains_fletcher_house_1.nbt | 4 +- .../zombie/houses/plains_medium_house_1.nbt | 4 +- .../zombie/houses/plains_medium_house_2.nbt | 4 +- .../zombie/houses/plains_meeting_point_4.nbt | 4 +- .../zombie/houses/plains_meeting_point_5.nbt | 4 +- .../houses/plains_shepherds_house_1.nbt | 4 +- .../zombie/houses/plains_small_house_1.nbt | 4 +- .../zombie/houses/plains_small_house_2.nbt | 4 +- .../zombie/houses/plains_small_house_3.nbt | 4 +- .../zombie/houses/plains_small_house_4.nbt | 4 +- .../zombie/houses/plains_small_house_5.nbt | 4 +- .../zombie/houses/plains_small_house_6.nbt | 4 +- .../zombie/houses/plains_small_house_7.nbt | 4 +- .../zombie/houses/plains_small_house_8.nbt | 4 +- .../plains/zombie/houses/plains_stable_1.nbt | 2 +- .../plains/zombie/streets/corner_01.nbt | 4 +- .../plains/zombie/streets/corner_02.nbt | 4 +- .../plains/zombie/streets/corner_03.nbt | 4 +- .../plains/zombie/streets/crossroad_01.nbt | 4 +- .../plains/zombie/streets/crossroad_02.nbt | 4 +- .../plains/zombie/streets/crossroad_03.nbt | 4 +- .../plains/zombie/streets/crossroad_04.nbt | 4 +- .../plains/zombie/streets/crossroad_05.nbt | 4 +- .../plains/zombie/streets/crossroad_06.nbt | 4 +- .../plains/zombie/streets/straight_01.nbt | 4 +- .../plains/zombie/streets/straight_02.nbt | 4 +- .../plains/zombie/streets/straight_03.nbt | 4 +- .../plains/zombie/streets/straight_04.nbt | 4 +- .../plains/zombie/streets/straight_05.nbt | 4 +- .../plains/zombie/streets/straight_06.nbt | 4 +- .../village/plains/zombie/streets/turn_01.nbt | 4 +- .../town_centers/plains_fountain_01.nbt | 4 +- .../town_centers/plains_meeting_point_1.nbt | 4 +- .../town_centers/plains_meeting_point_2.nbt | 4 +- .../town_centers/plains_meeting_point_3.nbt | 2 +- .../plains/zombie/villagers/nitwit.nbt | 4 +- .../plains/zombie/villagers/unemployed.nbt | 4 +- .../savanna/houses/savanna_animal_pen_1.nbt | 4 +- .../savanna/houses/savanna_animal_pen_2.nbt | 2 +- .../savanna/houses/savanna_animal_pen_3.nbt | 4 +- .../savanna/houses/savanna_armorer_1.nbt | 4 +- .../houses/savanna_butchers_shop_1.nbt | 4 +- .../houses/savanna_butchers_shop_2.nbt | 4 +- .../savanna/houses/savanna_cartographer_1.nbt | 4 +- .../houses/savanna_fisher_cottage_1.nbt | 4 +- .../houses/savanna_fletcher_house_1.nbt | 4 +- .../savanna/houses/savanna_large_farm_1.nbt | 4 +- .../savanna/houses/savanna_large_farm_2.nbt | 4 +- .../savanna/houses/savanna_library_1.nbt | 4 +- .../savanna/houses/savanna_mason_1.nbt | 4 +- .../savanna/houses/savanna_medium_house_1.nbt | 4 +- .../savanna/houses/savanna_medium_house_2.nbt | 4 +- .../savanna/houses/savanna_shepherd_1.nbt | 4 +- .../savanna/houses/savanna_small_farm.nbt | 4 +- .../savanna/houses/savanna_small_house_1.nbt | 4 +- .../savanna/houses/savanna_small_house_2.nbt | 4 +- .../savanna/houses/savanna_small_house_3.nbt | 4 +- .../savanna/houses/savanna_small_house_4.nbt | 4 +- .../savanna/houses/savanna_small_house_5.nbt | 4 +- .../savanna/houses/savanna_small_house_6.nbt | 4 +- .../savanna/houses/savanna_small_house_7.nbt | 4 +- .../savanna/houses/savanna_small_house_8.nbt | 4 +- .../savanna/houses/savanna_tannery_1.nbt | 4 +- .../savanna/houses/savanna_temple_1.nbt | 4 +- .../savanna/houses/savanna_temple_2.nbt | 4 +- .../savanna/houses/savanna_tool_smith_1.nbt | 4 +- .../savanna/houses/savanna_weaponsmith_1.nbt | 4 +- .../savanna/houses/savanna_weaponsmith_2.nbt | 4 +- .../village/savanna/savanna_lamp_post_01.nbt | 4 +- .../village/savanna/streets/corner_01.nbt | 4 +- .../village/savanna/streets/corner_03.nbt | 4 +- .../village/savanna/streets/crossroad_02.nbt | 2 +- .../village/savanna/streets/crossroad_03.nbt | 4 +- .../village/savanna/streets/crossroad_04.nbt | 4 +- .../village/savanna/streets/crossroad_05.nbt | 4 +- .../village/savanna/streets/crossroad_06.nbt | 4 +- .../village/savanna/streets/crossroad_07.nbt | 4 +- .../village/savanna/streets/split_01.nbt | 4 +- .../village/savanna/streets/split_02.nbt | 4 +- .../village/savanna/streets/straight_02.nbt | 4 +- .../village/savanna/streets/straight_04.nbt | 4 +- .../village/savanna/streets/straight_05.nbt | 4 +- .../village/savanna/streets/straight_06.nbt | 4 +- .../village/savanna/streets/straight_08.nbt | 4 +- .../village/savanna/streets/straight_09.nbt | 4 +- .../village/savanna/streets/straight_10.nbt | 4 +- .../village/savanna/streets/straight_11.nbt | 4 +- .../village/savanna/streets/turn_01.nbt | 4 +- .../savanna/terminators/terminator_05.nbt | 4 +- .../town_centers/savanna_meeting_point_1.nbt | 4 +- .../town_centers/savanna_meeting_point_2.nbt | 4 +- .../town_centers/savanna_meeting_point_3.nbt | 4 +- .../town_centers/savanna_meeting_point_4.nbt | 4 +- .../village/savanna/villagers/baby.nbt | 4 +- .../village/savanna/villagers/nitwit.nbt | 4 +- .../village/savanna/villagers/unemployed.nbt | 4 +- .../zombie/houses/savanna_animal_pen_2.nbt | 2 +- .../zombie/houses/savanna_animal_pen_3.nbt | 4 +- .../zombie/houses/savanna_large_farm_2.nbt | 4 +- .../zombie/houses/savanna_medium_house_1.nbt | 4 +- .../zombie/houses/savanna_medium_house_2.nbt | 4 +- .../zombie/houses/savanna_small_house_1.nbt | 4 +- .../zombie/houses/savanna_small_house_2.nbt | 4 +- .../zombie/houses/savanna_small_house_3.nbt | 4 +- .../zombie/houses/savanna_small_house_4.nbt | 4 +- .../zombie/houses/savanna_small_house_5.nbt | 4 +- .../zombie/houses/savanna_small_house_6.nbt | 4 +- .../zombie/houses/savanna_small_house_7.nbt | 4 +- .../zombie/houses/savanna_small_house_8.nbt | 4 +- .../savanna/zombie/streets/corner_01.nbt | 4 +- .../savanna/zombie/streets/corner_03.nbt | 4 +- .../savanna/zombie/streets/crossroad_02.nbt | 4 +- .../savanna/zombie/streets/crossroad_03.nbt | 4 +- .../savanna/zombie/streets/crossroad_04.nbt | 4 +- .../savanna/zombie/streets/crossroad_05.nbt | 4 +- .../savanna/zombie/streets/crossroad_06.nbt | 4 +- .../savanna/zombie/streets/crossroad_07.nbt | 4 +- .../savanna/zombie/streets/split_01.nbt | 2 +- .../savanna/zombie/streets/split_02.nbt | 4 +- .../savanna/zombie/streets/straight_02.nbt | 4 +- .../savanna/zombie/streets/straight_04.nbt | 4 +- .../savanna/zombie/streets/straight_05.nbt | 4 +- .../savanna/zombie/streets/straight_06.nbt | 4 +- .../savanna/zombie/streets/straight_08.nbt | 4 +- .../savanna/zombie/streets/straight_09.nbt | 4 +- .../savanna/zombie/streets/straight_10.nbt | 4 +- .../savanna/zombie/streets/straight_11.nbt | 4 +- .../savanna/zombie/streets/turn_01.nbt | 4 +- .../zombie/terminators/terminator_05.nbt | 4 +- .../town_centers/savanna_meeting_point_1.nbt | 4 +- .../town_centers/savanna_meeting_point_2.nbt | 4 +- .../town_centers/savanna_meeting_point_3.nbt | 4 +- .../town_centers/savanna_meeting_point_4.nbt | 4 +- .../savanna/zombie/villagers/nitwit.nbt | 4 +- .../savanna/zombie/villagers/unemployed.nbt | 4 +- .../snowy/houses/snowy_animal_pen_1.nbt | 4 +- .../snowy/houses/snowy_animal_pen_2.nbt | 4 +- .../snowy/houses/snowy_armorer_house_1.nbt | 4 +- .../snowy/houses/snowy_armorer_house_2.nbt | 4 +- .../snowy/houses/snowy_butchers_shop_1.nbt | 4 +- .../snowy/houses/snowy_butchers_shop_2.nbt | 2 +- .../houses/snowy_cartographer_house_1.nbt | 4 +- .../village/snowy/houses/snowy_farm_1.nbt | 4 +- .../village/snowy/houses/snowy_farm_2.nbt | 2 +- .../snowy/houses/snowy_fisher_cottage.nbt | 4 +- .../snowy/houses/snowy_fletcher_house_1.nbt | 4 +- .../village/snowy/houses/snowy_library_1.nbt | 4 +- .../snowy/houses/snowy_masons_house_1.nbt | 4 +- .../snowy/houses/snowy_masons_house_2.nbt | 4 +- .../snowy/houses/snowy_medium_house_1.nbt | 4 +- .../snowy/houses/snowy_medium_house_2.nbt | 4 +- .../snowy/houses/snowy_medium_house_3.nbt | 4 +- .../snowy/houses/snowy_shepherds_house_1.nbt | 4 +- .../snowy/houses/snowy_small_house_1.nbt | 4 +- .../snowy/houses/snowy_small_house_2.nbt | 4 +- .../snowy/houses/snowy_small_house_3.nbt | 4 +- .../snowy/houses/snowy_small_house_4.nbt | 4 +- .../snowy/houses/snowy_small_house_5.nbt | 4 +- .../snowy/houses/snowy_small_house_6.nbt | 4 +- .../snowy/houses/snowy_small_house_7.nbt | 4 +- .../snowy/houses/snowy_small_house_8.nbt | 4 +- .../village/snowy/houses/snowy_tannery_1.nbt | 4 +- .../village/snowy/houses/snowy_temple_1.nbt | 4 +- .../snowy/houses/snowy_tool_smith_1.nbt | 4 +- .../snowy/houses/snowy_weapon_smith_1.nbt | 4 +- .../village/snowy/snowy_lamp_post_01.nbt | 4 +- .../village/snowy/snowy_lamp_post_02.nbt | 4 +- .../village/snowy/snowy_lamp_post_03.nbt | 4 +- .../village/snowy/streets/corner_01.nbt | 2 +- .../village/snowy/streets/corner_02.nbt | 4 +- .../village/snowy/streets/corner_03.nbt | 4 +- .../village/snowy/streets/crossroad_01.nbt | 4 +- .../village/snowy/streets/crossroad_02.nbt | 4 +- .../village/snowy/streets/crossroad_03.nbt | 4 +- .../village/snowy/streets/crossroad_04.nbt | 4 +- .../village/snowy/streets/crossroad_05.nbt | 4 +- .../village/snowy/streets/crossroad_06.nbt | 4 +- .../village/snowy/streets/square_01.nbt | 4 +- .../village/snowy/streets/straight_01.nbt | 4 +- .../village/snowy/streets/straight_02.nbt | 4 +- .../village/snowy/streets/straight_03.nbt | 4 +- .../village/snowy/streets/straight_04.nbt | 4 +- .../village/snowy/streets/straight_06.nbt | 2 +- .../village/snowy/streets/straight_08.nbt | 4 +- .../village/snowy/streets/turn_01.nbt | 4 +- .../town_centers/snowy_meeting_point_1.nbt | 4 +- .../town_centers/snowy_meeting_point_2.nbt | 4 +- .../town_centers/snowy_meeting_point_3.nbt | 4 +- .../village/snowy/villagers/baby.nbt | 4 +- .../village/snowy/villagers/nitwit.nbt | 4 +- .../village/snowy/villagers/unemployed.nbt | 4 +- .../zombie/houses/snowy_medium_house_1.nbt | 4 +- .../zombie/houses/snowy_medium_house_2.nbt | 4 +- .../zombie/houses/snowy_medium_house_3.nbt | 4 +- .../zombie/houses/snowy_small_house_1.nbt | 4 +- .../zombie/houses/snowy_small_house_2.nbt | 4 +- .../zombie/houses/snowy_small_house_3.nbt | 4 +- .../zombie/houses/snowy_small_house_4.nbt | 4 +- .../zombie/houses/snowy_small_house_5.nbt | 4 +- .../zombie/houses/snowy_small_house_6.nbt | 4 +- .../zombie/houses/snowy_small_house_7.nbt | 4 +- .../zombie/houses/snowy_small_house_8.nbt | 4 +- .../snowy/zombie/streets/corner_01.nbt | 2 +- .../snowy/zombie/streets/corner_02.nbt | 4 +- .../snowy/zombie/streets/corner_03.nbt | 4 +- .../snowy/zombie/streets/crossroad_01.nbt | 4 +- .../snowy/zombie/streets/crossroad_02.nbt | 4 +- .../snowy/zombie/streets/crossroad_03.nbt | 4 +- .../snowy/zombie/streets/crossroad_04.nbt | 4 +- .../snowy/zombie/streets/crossroad_05.nbt | 4 +- .../snowy/zombie/streets/crossroad_06.nbt | 4 +- .../snowy/zombie/streets/square_01.nbt | 4 +- .../snowy/zombie/streets/straight_01.nbt | 4 +- .../snowy/zombie/streets/straight_02.nbt | 4 +- .../snowy/zombie/streets/straight_03.nbt | 4 +- .../snowy/zombie/streets/straight_04.nbt | 4 +- .../snowy/zombie/streets/straight_06.nbt | 4 +- .../snowy/zombie/streets/straight_08.nbt | 4 +- .../village/snowy/zombie/streets/turn_01.nbt | 4 +- .../town_centers/snowy_meeting_point_1.nbt | 4 +- .../town_centers/snowy_meeting_point_2.nbt | 4 +- .../town_centers/snowy_meeting_point_3.nbt | 4 +- .../village/snowy/zombie/villagers/nitwit.nbt | 4 +- .../snowy/zombie/villagers/unemployed.nbt | 4 +- .../taiga/houses/taiga_animal_pen_1.nbt | 4 +- .../village/taiga/houses/taiga_armorer_2.nbt | 4 +- .../taiga/houses/taiga_armorer_house_1.nbt | 4 +- .../taiga/houses/taiga_butcher_shop_1.nbt | 4 +- .../houses/taiga_cartographer_house_1.nbt | 4 +- .../taiga/houses/taiga_fisher_cottage_1.nbt | 4 +- .../taiga/houses/taiga_fletcher_house_1.nbt | 4 +- .../taiga/houses/taiga_large_farm_1.nbt | 4 +- .../taiga/houses/taiga_large_farm_2.nbt | 4 +- .../village/taiga/houses/taiga_library_1.nbt | 4 +- .../taiga/houses/taiga_masons_house_1.nbt | 4 +- .../taiga/houses/taiga_medium_house_1.nbt | 4 +- .../taiga/houses/taiga_medium_house_2.nbt | 4 +- .../taiga/houses/taiga_medium_house_3.nbt | 4 +- .../taiga/houses/taiga_medium_house_4.nbt | 4 +- .../taiga/houses/taiga_shepherds_house_1.nbt | 4 +- .../taiga/houses/taiga_small_farm_1.nbt | 4 +- .../taiga/houses/taiga_small_house_1.nbt | 4 +- .../taiga/houses/taiga_small_house_2.nbt | 4 +- .../taiga/houses/taiga_small_house_3.nbt | 4 +- .../taiga/houses/taiga_small_house_4.nbt | 4 +- .../taiga/houses/taiga_small_house_5.nbt | 4 +- .../village/taiga/houses/taiga_tannery_1.nbt | 4 +- .../village/taiga/houses/taiga_temple_1.nbt | 4 +- .../taiga/houses/taiga_tool_smith_1.nbt | 2 +- .../taiga/houses/taiga_weaponsmith_1.nbt | 4 +- .../taiga/houses/taiga_weaponsmith_2.nbt | 4 +- .../village/taiga/streets/corner_01.nbt | 4 +- .../village/taiga/streets/corner_02.nbt | 4 +- .../village/taiga/streets/corner_03.nbt | 4 +- .../village/taiga/streets/crossroad_01.nbt | 4 +- .../village/taiga/streets/crossroad_02.nbt | 4 +- .../village/taiga/streets/crossroad_03.nbt | 4 +- .../village/taiga/streets/crossroad_04.nbt | 4 +- .../village/taiga/streets/crossroad_05.nbt | 4 +- .../village/taiga/streets/crossroad_06.nbt | 4 +- .../village/taiga/streets/straight_01.nbt | 4 +- .../village/taiga/streets/straight_02.nbt | 4 +- .../village/taiga/streets/straight_03.nbt | 4 +- .../village/taiga/streets/straight_04.nbt | 4 +- .../village/taiga/streets/straight_05.nbt | 4 +- .../village/taiga/streets/straight_06.nbt | 4 +- .../village/taiga/streets/turn_01.nbt | 4 +- .../village/taiga/taiga_decoration_1.nbt | 4 +- .../village/taiga/taiga_decoration_2.nbt | 4 +- .../village/taiga/taiga_decoration_3.nbt | 4 +- .../village/taiga/taiga_decoration_4.nbt | 4 +- .../village/taiga/taiga_decoration_5.nbt | 4 +- .../village/taiga/taiga_decoration_6.nbt | 4 +- .../village/taiga/taiga_lamp_post_1.nbt | 4 +- .../town_centers/taiga_meeting_point_1.nbt | 4 +- .../town_centers/taiga_meeting_point_2.nbt | 4 +- .../village/taiga/villagers/baby.nbt | 4 +- .../village/taiga/villagers/nitwit.nbt | 4 +- .../village/taiga/villagers/unemployed.nbt | 4 +- .../houses/taiga_cartographer_house_1.nbt | 4 +- .../zombie/houses/taiga_fisher_cottage_1.nbt | 4 +- .../zombie/houses/taiga_large_farm_2.nbt | 4 +- .../taiga/zombie/houses/taiga_library_1.nbt | 4 +- .../zombie/houses/taiga_medium_house_1.nbt | 4 +- .../zombie/houses/taiga_medium_house_2.nbt | 4 +- .../zombie/houses/taiga_medium_house_3.nbt | 4 +- .../zombie/houses/taiga_medium_house_4.nbt | 4 +- .../zombie/houses/taiga_shepherds_house_1.nbt | 4 +- .../zombie/houses/taiga_small_house_1.nbt | 4 +- .../zombie/houses/taiga_small_house_2.nbt | 4 +- .../zombie/houses/taiga_small_house_3.nbt | 4 +- .../zombie/houses/taiga_small_house_4.nbt | 4 +- .../zombie/houses/taiga_small_house_5.nbt | 4 +- .../taiga/zombie/houses/taiga_temple_1.nbt | 4 +- .../zombie/houses/taiga_tool_smith_1.nbt | 2 +- .../zombie/houses/taiga_weaponsmith_2.nbt | 4 +- .../taiga/zombie/streets/corner_01.nbt | 4 +- .../taiga/zombie/streets/corner_02.nbt | 4 +- .../taiga/zombie/streets/corner_03.nbt | 4 +- .../taiga/zombie/streets/crossroad_01.nbt | 4 +- .../taiga/zombie/streets/crossroad_02.nbt | 4 +- .../taiga/zombie/streets/crossroad_03.nbt | 4 +- .../taiga/zombie/streets/crossroad_04.nbt | 4 +- .../taiga/zombie/streets/crossroad_05.nbt | 4 +- .../taiga/zombie/streets/crossroad_06.nbt | 4 +- .../taiga/zombie/streets/straight_01.nbt | 4 +- .../taiga/zombie/streets/straight_02.nbt | 4 +- .../taiga/zombie/streets/straight_03.nbt | 4 +- .../taiga/zombie/streets/straight_04.nbt | 4 +- .../taiga/zombie/streets/straight_05.nbt | 4 +- .../taiga/zombie/streets/straight_06.nbt | 4 +- .../village/taiga/zombie/streets/turn_01.nbt | 4 +- .../town_centers/taiga_meeting_point_1.nbt | 4 +- .../town_centers/taiga_meeting_point_2.nbt | 4 +- .../village/taiga/zombie/villagers/nitwit.nbt | 4 +- .../taiga/zombie/villagers/unemployed.nbt | 4 +- .../structure/woodland_mansion/1x1_a1.nbt | 4 +- .../structure/woodland_mansion/1x1_a2.nbt | 4 +- .../structure/woodland_mansion/1x1_a3.nbt | 4 +- .../structure/woodland_mansion/1x1_a4.nbt | 4 +- .../structure/woodland_mansion/1x1_a5.nbt | 4 +- .../structure/woodland_mansion/1x1_as1.nbt | 4 +- .../structure/woodland_mansion/1x1_as2.nbt | 4 +- .../structure/woodland_mansion/1x1_as3.nbt | 4 +- .../structure/woodland_mansion/1x1_as4.nbt | 4 +- .../structure/woodland_mansion/1x1_b1.nbt | 4 +- .../structure/woodland_mansion/1x1_b2.nbt | 4 +- .../structure/woodland_mansion/1x1_b3.nbt | 4 +- .../structure/woodland_mansion/1x1_b4.nbt | 4 +- .../structure/woodland_mansion/1x1_b5.nbt | 4 +- .../structure/woodland_mansion/1x2_a1.nbt | 4 +- .../structure/woodland_mansion/1x2_a2.nbt | 4 +- .../structure/woodland_mansion/1x2_a3.nbt | 4 +- .../structure/woodland_mansion/1x2_a4.nbt | 4 +- .../structure/woodland_mansion/1x2_a5.nbt | 4 +- .../structure/woodland_mansion/1x2_a6.nbt | 4 +- .../structure/woodland_mansion/1x2_a7.nbt | 4 +- .../structure/woodland_mansion/1x2_a8.nbt | 4 +- .../structure/woodland_mansion/1x2_a9.nbt | 4 +- .../structure/woodland_mansion/1x2_b1.nbt | 4 +- .../structure/woodland_mansion/1x2_b2.nbt | 4 +- .../structure/woodland_mansion/1x2_b3.nbt | 4 +- .../structure/woodland_mansion/1x2_b4.nbt | 4 +- .../structure/woodland_mansion/1x2_b5.nbt | 4 +- .../structure/woodland_mansion/1x2_c1.nbt | 4 +- .../structure/woodland_mansion/1x2_c2.nbt | 4 +- .../structure/woodland_mansion/1x2_c3.nbt | 4 +- .../structure/woodland_mansion/1x2_c4.nbt | 4 +- .../woodland_mansion/1x2_c_stairs.nbt | 4 +- .../structure/woodland_mansion/1x2_d1.nbt | 4 +- .../structure/woodland_mansion/1x2_d2.nbt | 4 +- .../structure/woodland_mansion/1x2_d3.nbt | 4 +- .../structure/woodland_mansion/1x2_d4.nbt | 4 +- .../structure/woodland_mansion/1x2_d5.nbt | 4 +- .../woodland_mansion/1x2_d_stairs.nbt | 4 +- .../structure/woodland_mansion/1x2_s1.nbt | 4 +- .../structure/woodland_mansion/1x2_s2.nbt | 4 +- .../structure/woodland_mansion/1x2_se1.nbt | 4 +- .../structure/woodland_mansion/2x2_a1.nbt | 4 +- .../structure/woodland_mansion/2x2_a2.nbt | 4 +- .../structure/woodland_mansion/2x2_a3.nbt | 4 +- .../structure/woodland_mansion/2x2_a4.nbt | 4 +- .../structure/woodland_mansion/2x2_b1.nbt | 4 +- .../structure/woodland_mansion/2x2_b2.nbt | 4 +- .../structure/woodland_mansion/2x2_b3.nbt | 4 +- .../structure/woodland_mansion/2x2_b4.nbt | 4 +- .../structure/woodland_mansion/2x2_b5.nbt | 4 +- .../structure/woodland_mansion/2x2_s1.nbt | 4 +- .../woodland_mansion/carpet_east.nbt | 4 +- .../woodland_mansion/carpet_north.nbt | 4 +- .../woodland_mansion/carpet_south_1.nbt | 4 +- .../woodland_mansion/carpet_south_2.nbt | 4 +- .../woodland_mansion/carpet_west_1.nbt | 4 +- .../woodland_mansion/carpet_west_2.nbt | 2 +- .../woodland_mansion/corridor_floor.nbt | 4 +- .../structure/woodland_mansion/entrance.nbt | 4 +- .../woodland_mansion/indoors_door_1.nbt | 4 +- .../woodland_mansion/indoors_door_2.nbt | 4 +- .../woodland_mansion/indoors_wall_1.nbt | 4 +- .../woodland_mansion/indoors_wall_2.nbt | 4 +- .../structure/woodland_mansion/roof.nbt | 4 +- .../woodland_mansion/roof_corner.nbt | 4 +- .../structure/woodland_mansion/roof_front.nbt | 4 +- .../woodland_mansion/roof_inner_corner.nbt | 4 +- .../structure/woodland_mansion/small_wall.nbt | 4 +- .../woodland_mansion/small_wall_corner.nbt | 4 +- .../woodland_mansion/wall_corner.nbt | 4 +- .../structure/woodland_mansion/wall_flat.nbt | 4 +- .../woodland_mansion/wall_window.nbt | 4 +- data/minecraft/tags/block/bee_attractive.json | 4 +- .../tags/block/big_dripleaf_placeable.json | 10 +- .../tags/block/camels_spawnable_on.json | 5 + data/minecraft/tags/block/dragon_immune.json | 4 +- ....json => dry_vegetation_may_place_on.json} | 3 +- .../tags/block/edible_for_sheep.json | 8 + .../tags/block/enderman_holdable.json | 3 +- data/minecraft/tags/block/flowers.json | 4 +- .../tags/block/inside_step_sound_blocks.json | 4 +- data/minecraft/tags/block/mineable/axe.json | 33 - data/minecraft/tags/block/mineable/hoe.json | 15 +- .../plays_ambient_desert_block_sounds.json | 7 + data/minecraft/tags/block/replaceable.json | 4 + .../tags/block/replaceable_by_mushrooms.json | 35 + .../tags/block/replaceable_by_trees.json | 7 +- .../minecraft/tags/block/sword_efficient.json | 36 - .../tags/block/sword_instantly_mines.json | 6 + .../tags/block/wall_post_override.json | 3 +- data/minecraft/tags/block/wither_immune.json | 4 +- .../tags/cat_variant/default_spawns.json | 14 - .../tags/cat_variant/full_moon_spawns.json | 6 - .../tags/damage_type/bypasses_shield.json | 10 +- .../tags/entity_type/can_equip_saddle.json | 12 + .../entity_type/can_wear_horse_armor.json | 5 + data/minecraft/tags/item/bee_food.json | 4 +- .../tags/item/book_cloning_target.json | 5 + data/minecraft/tags/item/eggs.json | 7 + data/minecraft/tags/item/flowers.json | 19 + .../biome/has_structure/trial_chambers.json | 2 +- .../biome/has_structure/woodland_mansion.json | 3 +- .../tags/worldgen/biome/is_overworld.json | 2 +- .../spawns_cold_variant_farm_animals.json | 26 + .../spawns_warm_variant_farm_animals.json | 13 + .../structure/on_desert_village_maps.json | 0 .../structure/on_jungle_explorer_maps.json | 0 .../structure/on_plains_village_maps.json | 0 .../structure/on_savanna_village_maps.json | 0 .../structure/on_snowy_village_maps.json | 0 .../structure/on_swamp_explorer_maps.json | 0 .../structure/on_taiga_village_maps.json | 0 data/minecraft/test_environment/default.json | 4 + data/minecraft/test_instance/always_pass.json | 9 + data/minecraft/trim_material/amethyst.json | 3 +- data/minecraft/trim_material/copper.json | 3 +- data/minecraft/trim_material/diamond.json | 1 - data/minecraft/trim_material/emerald.json | 3 +- data/minecraft/trim_material/gold.json | 1 - data/minecraft/trim_material/iron.json | 1 - data/minecraft/trim_material/lapis.json | 3 +- data/minecraft/trim_material/netherite.json | 1 - data/minecraft/trim_material/quartz.json | 3 +- data/minecraft/trim_material/redstone.json | 3 +- data/minecraft/trim_material/resin.json | 3 +- data/minecraft/trim_pattern/bolt.json | 3 +- data/minecraft/trim_pattern/coast.json | 3 +- data/minecraft/trim_pattern/dune.json | 3 +- data/minecraft/trim_pattern/eye.json | 3 +- data/minecraft/trim_pattern/flow.json | 3 +- data/minecraft/trim_pattern/host.json | 3 +- data/minecraft/trim_pattern/raiser.json | 3 +- data/minecraft/trim_pattern/rib.json | 3 +- data/minecraft/trim_pattern/sentry.json | 3 +- data/minecraft/trim_pattern/shaper.json | 3 +- data/minecraft/trim_pattern/silence.json | 3 +- data/minecraft/trim_pattern/snout.json | 3 +- data/minecraft/trim_pattern/spire.json | 3 +- data/minecraft/trim_pattern/tide.json | 3 +- data/minecraft/trim_pattern/vex.json | 3 +- data/minecraft/trim_pattern/ward.json | 3 +- data/minecraft/trim_pattern/wayfinder.json | 3 +- data/minecraft/trim_pattern/wild.json | 3 +- data/minecraft/wolf_sound_variant/angry.json | 8 + data/minecraft/wolf_sound_variant/big.json | 8 + .../minecraft/wolf_sound_variant/classic.json | 8 + data/minecraft/wolf_sound_variant/cute.json | 8 + data/minecraft/wolf_sound_variant/grumpy.json | 8 + data/minecraft/wolf_sound_variant/puglin.json | 8 + data/minecraft/wolf_sound_variant/sad.json | 8 + data/minecraft/wolf_variant/ashen.json | 18 +- data/minecraft/wolf_variant/black.json | 18 +- data/minecraft/wolf_variant/chestnut.json | 18 +- data/minecraft/wolf_variant/pale.json | 14 +- data/minecraft/wolf_variant/rusty.json | 18 +- data/minecraft/wolf_variant/snowy.json | 18 +- data/minecraft/wolf_variant/spotted.json | 18 +- data/minecraft/wolf_variant/striped.json | 18 +- data/minecraft/wolf_variant/woods.json | 18 +- data/minecraft/worldgen/biome/badlands.json | 28 +- .../worldgen/biome/bamboo_jungle.json | 3 +- data/minecraft/worldgen/biome/beach.json | 3 +- .../worldgen/biome/birch_forest.json | 5 +- data/minecraft/worldgen/biome/cold_ocean.json | 3 +- .../minecraft/worldgen/biome/dark_forest.json | 5 +- .../worldgen/biome/deep_cold_ocean.json | 3 +- data/minecraft/worldgen/biome/deep_dark.json | 1 - .../worldgen/biome/deep_frozen_ocean.json | 3 +- .../worldgen/biome/deep_lukewarm_ocean.json | 3 +- data/minecraft/worldgen/biome/deep_ocean.json | 3 +- data/minecraft/worldgen/biome/desert.json | 9 +- .../worldgen/biome/dripstone_caves.json | 1 - .../worldgen/biome/eroded_badlands.json | 28 +- .../worldgen/biome/flower_forest.json | 3 +- data/minecraft/worldgen/biome/forest.json | 6 +- .../worldgen/biome/frozen_ocean.json | 3 +- .../worldgen/biome/frozen_river.json | 4 +- data/minecraft/worldgen/biome/grove.json | 1 - data/minecraft/worldgen/biome/ice_spikes.json | 3 +- data/minecraft/worldgen/biome/jungle.json | 3 +- .../worldgen/biome/lukewarm_ocean.json | 3 +- .../worldgen/biome/mangrove_swamp.json | 4 +- data/minecraft/worldgen/biome/meadow.json | 5 +- .../worldgen/biome/mushroom_fields.json | 3 +- data/minecraft/worldgen/biome/ocean.json | 3 +- .../biome/old_growth_birch_forest.json | 5 +- .../worldgen/biome/old_growth_pine_taiga.json | 3 +- .../biome/old_growth_spruce_taiga.json | 3 +- .../minecraft/worldgen/biome/pale_garden.json | 4 +- data/minecraft/worldgen/biome/plains.json | 4 +- data/minecraft/worldgen/biome/river.json | 4 +- data/minecraft/worldgen/biome/savanna.json | 3 +- .../worldgen/biome/savanna_plateau.json | 3 +- .../minecraft/worldgen/biome/snowy_beach.json | 3 +- .../worldgen/biome/snowy_plains.json | 3 +- .../worldgen/biome/snowy_slopes.json | 1 - .../minecraft/worldgen/biome/snowy_taiga.json | 3 +- .../worldgen/biome/sparse_jungle.json | 3 +- .../minecraft/worldgen/biome/stony_shore.json | 3 +- .../worldgen/biome/sunflower_plains.json | 3 +- data/minecraft/worldgen/biome/swamp.json | 3 + data/minecraft/worldgen/biome/taiga.json | 3 +- data/minecraft/worldgen/biome/warm_ocean.json | 3 +- .../worldgen/biome/windswept_forest.json | 4 +- .../biome/windswept_gravelly_hills.json | 4 +- .../worldgen/biome/windswept_hills.json | 4 +- .../worldgen/biome/windswept_savanna.json | 3 +- .../worldgen/biome/wooded_badlands.json | 28 +- .../birch_bees_0002_leaf_litter.json | 359 + .../configured_feature/birch_leaf_litter.json | 355 + .../configured_feature/birch_tall.json | 8 + .../configured_feature/crimson_fungus.json | 1 + .../crimson_fungus_planted.json | 1 + .../dark_forest_vegetation.json | 16 +- .../dark_oak_leaf_litter.json | 356 + .../configured_feature/fallen_birch_tree.json | 46 + .../fallen_jungle_tree.json | 50 + .../configured_feature/fallen_oak_tree.json | 50 + .../fallen_spruce_tree.json | 46 + .../fallen_super_birch_tree.json | 46 + .../fancy_oak_bees_0002.json | 58 - .../fancy_oak_bees_0002_leaf_litter.json | 360 + .../fancy_oak_leaf_litter.json | 356 + .../configured_feature/oak_bees_0002.json | 57 - .../oak_bees_0002_leaf_litter.json | 359 + .../configured_feature/oak_leaf_litter.json | 355 + .../configured_feature/patch_bush.json | 30 + .../configured_feature/patch_cactus.json | 21 + .../configured_feature/patch_dry_grass.json | 41 + .../patch_firefly_bush.json | 30 + .../patch_grass_meadow.json | 30 + .../configured_feature/patch_leaf_litter.json | 149 + .../configured_feature/trees_badlands.json | 12 + .../configured_feature/trees_birch.json | 12 + .../trees_birch_and_oak.json | 16 - .../trees_birch_and_oak_leaf_litter.json | 24 + .../trees_flower_forest.json | 4 + .../configured_feature/trees_jungle.json | 4 + .../trees_old_growth_pine_taiga.json | 4 + .../trees_old_growth_spruce_taiga.json | 4 + .../configured_feature/trees_plains.json | 4 + .../configured_feature/trees_savanna.json | 4 + .../configured_feature/trees_snowy.json | 12 + .../trees_sparse_jungle.json | 4 + .../configured_feature/trees_taiga.json | 4 + .../trees_windswept_hills.json | 8 + .../configured_feature/warped_fungus.json | 1 + .../warped_fungus_planted.json | 1 + .../wildflowers_birch_forest.json | 189 + .../wildflowers_meadow.json | 189 + .../birch_bees_0002_leaf_litter.json | 17 + .../placed_feature/birch_leaf_litter.json | 17 + .../placed_feature/dark_oak_leaf_litter.json | 17 + .../placed_feature/fallen_birch_tree.json | 17 + .../placed_feature/fallen_jungle_tree.json | 17 + ...ak_bees_0002.json => fallen_oak_tree.json} | 2 +- .../placed_feature/fallen_spruce_tree.json | 17 + .../fallen_super_birch_tree.json | 17 + .../fancy_oak_bees_0002_leaf_litter.json | 17 + .../placed_feature/fancy_oak_leaf_litter.json | 17 + .../oak_bees_0002_leaf_litter.json | 17 + ...ak_bees_0002.json => oak_leaf_litter.json} | 2 +- .../worldgen/placed_feature/patch_bush.json | 19 + .../patch_dry_grass_badlands.json | 19 + .../patch_dry_grass_desert.json | 19 + .../patch_firefly_bush_near_water.json | 90 + .../patch_firefly_bush_near_water_swamp.json | 90 + .../patch_firefly_bush_swamp.json | 19 + .../placed_feature/patch_grass_meadow.json | 21 + .../placed_feature/patch_leaf_litter.json | 19 + .../placed_feature/trees_badlands.json | 2 +- .../worldgen/placed_feature/trees_birch.json | 2 +- ...n => trees_birch_and_oak_leaf_litter.json} | 2 +- .../worldgen/placed_feature/trees_snowy.json | 2 +- .../wildflowers_birch_forest.json | 23 + .../placed_feature/wildflowers_meadow.json | 21 + net/minecraft/ChatFormatting.java | 6 + net/minecraft/CrashReportCategory.java | 29 +- net/minecraft/DetectedVersion.java | 8 +- net/minecraft/SharedConstants.java | 17 +- net/minecraft/Util.java | 25 +- net/minecraft/advancements/Advancement.java | 14 +- .../advancements/AdvancementProgress.java | 3 +- .../advancements/AdvancementRewards.java | 5 +- net/minecraft/advancements/DisplayInfo.java | 14 +- .../critereon/BlockPredicate.java | 39 +- .../critereon/DataComponentMatchers.java | 75 + .../critereon/EntityEquipmentPredicate.java | 12 +- .../critereon/EntityPredicate.java | 26 +- .../critereon/EntitySubPredicates.java | 188 - .../critereon/InventoryChangeTrigger.java | 38 +- .../ItemAttributeModifiersPredicate.java | 69 - .../critereon/ItemBundlePredicate.java | 25 - .../critereon/ItemContainerPredicate.java | 26 - .../critereon/ItemCustomDataPredicate.java | 17 - .../critereon/ItemDamagePredicate.java | 31 - .../critereon/ItemEnchantmentsPredicate.java | 69 - .../ItemFireworkExplosionPredicate.java | 47 - .../critereon/ItemFireworksPredicate.java | 36 - .../advancements/critereon/ItemPredicate.java | 50 +- .../critereon/ItemSubPredicate.java | 17 - .../critereon/ItemSubPredicates.java | 38 - .../critereon/ItemWritableBookPredicate.java | 39 - .../critereon/LootTableTrigger.java | 3 +- .../advancements/critereon/MinMaxBounds.java | 33 + .../advancements/critereon/NbtPredicate.java | 9 +- .../critereon/PlayerPredicate.java | 24 +- .../critereon/RecipeCraftedTrigger.java | 3 +- .../critereon/RecipeUnlockedTrigger.java | 3 +- .../critereon/SheepPredicate.java | 20 +- .../SingleComponentItemPredicate.java | 13 +- net/minecraft/client/ClientBootstrap.java | 2 + net/minecraft/client/GameNarrator.java | 14 +- net/minecraft/client/KeyboardHandler.java | 13 +- net/minecraft/client/Minecraft.java | 200 +- net/minecraft/client/MouseHandler.java | 100 +- net/minecraft/client/Options.java | 255 +- net/minecraft/client/Screenshot.java | 184 +- .../client/color/block/BlockColors.java | 11 +- net/minecraft/client/data/AtlasProvider.java | 174 + net/minecraft/client/data/Main.java | 1 + .../data/models/BlockModelGenerators.java | 4791 ++---- .../data/models/EquipmentAssetProvider.java | 20 +- .../data/models/ItemModelGenerators.java | 304 +- .../client/data/models/ModelProvider.java | 46 +- .../client/data/models/MultiVariant.java | 34 + ...ava => BlockModelDefinitionGenerator.java} | 9 +- .../data/models/blockstates/Condition.java | 129 - .../models/blockstates/ConditionBuilder.java | 46 + .../blockstates/MultiPartGenerator.java | 95 +- .../blockstates/MultiVariantGenerator.java | 130 +- .../models/blockstates/PropertyDispatch.java | 280 +- .../models/blockstates/PropertyValueList.java | 36 + .../data/models/blockstates/Selector.java | 52 - .../data/models/blockstates/Variant.java | 52 - .../models/blockstates/VariantProperties.java | 31 - .../models/blockstates/VariantProperty.java | 47 - .../data/models/model/ModelTemplates.java | 4 + .../data/models/model/TexturedModel.java | 4 + net/minecraft/client/gui/Gui.java | 44 +- net/minecraft/client/gui/GuiGraphics.java | 60 +- .../client/gui/GuiSpriteManager.java | 3 +- .../gui/components/CommandSuggestions.java | 12 +- .../ContainerObjectSelectionList.java | 11 +- .../gui/components/DebugScreenOverlay.java | 103 +- .../FittingMultiLineTextWidget.java | 33 +- .../client/gui/components/PopupScreen.java | 2 +- .../events/ContainerEventHandler.java | 2 +- .../components/toasts/AdvancementToast.java | 23 +- .../gui/components/toasts/SystemToast.java | 7 +- .../client/gui/components/toasts/Toast.java | 6 + .../gui/components/toasts/ToastManager.java | 25 +- .../gui/components/toasts/TutorialToast.java | 7 +- .../client/gui/font/FontManager.java | 8 +- net/minecraft/client/gui/font/FontSet.java | 12 +- .../client/gui/font/FontTexture.java | 27 +- .../client/gui/font/glyphs/SpecialGlyphs.java | 48 +- .../gui/font/providers/GlyphProviderType.java | 8 +- .../gui/font/providers/UnihexProvider.java | 38 +- .../AccessibilityOnboardingScreen.java | 2 +- .../client/gui/screens/ConnectScreen.java | 7 +- .../client/gui/screens/DeathScreen.java | 4 +- .../client/gui/screens/EditServerScreen.java | 5 +- .../client/gui/screens/FaviconTexture.java | 2 +- .../client/gui/screens/LoadingOverlay.java | 28 +- .../gui/screens/RecoverWorldDataScreen.java | 10 +- net/minecraft/client/gui/screens/Screen.java | 75 +- .../client/gui/screens/TitleScreen.java | 7 +- .../screens/advancements/AdvancementTab.java | 6 +- .../advancements/AdvancementsScreen.java | 3 +- .../inventory/AbstractContainerScreen.java | 2 +- .../gui/screens/inventory/AnvilScreen.java | 2 +- .../gui/screens/inventory/BookEditScreen.java | 2 +- .../gui/screens/inventory/BookViewScreen.java | 14 +- .../CreativeModeInventoryScreen.java | 28 +- .../screens/inventory/EnchantmentScreen.java | 4 +- .../inventory/HorseInventoryScreen.java | 7 +- .../screens/inventory/InventoryScreen.java | 4 +- .../gui/screens/inventory/LoomScreen.java | 3 +- .../gui/screens/inventory/MerchantScreen.java | 3 +- .../inventory/StructureBlockEditScreen.java | 15 + .../inventory/TestBlockEditScreen.java | 97 + .../TestInstanceBlockEditScreen.java | 229 + .../multiplayer/JoinMultiplayerScreen.java | 55 +- .../UnsupportedGraphicsWarningScreen.java | 5 +- .../screens/options/VideoSettingsScreen.java | 17 +- .../screens/packs/PackSelectionScreen.java | 7 +- .../reporting/ChatSelectionScreen.java | 8 +- .../worldselection/CreateWorldScreen.java | 28 +- .../worldselection/EditGameRulesScreen.java | 17 +- .../worldselection/EditWorldScreen.java | 9 +- .../worldselection/ExperimentsScreen.java | 3 +- .../worldselection/OptimizeWorldScreen.java | 15 +- .../worldselection/SelectWorldScreen.java | 14 +- net/minecraft/client/main/GameConfig.java | 12 +- net/minecraft/client/main/Main.java | 154 +- .../client/model/AbstractEquineModel.java | 52 - .../client/model/AdultAndBabyModelPair.java | 11 + .../client/model/ArmorStandArmorModel.java | 36 +- .../client/model/ArmorStandModel.java | 18 +- net/minecraft/client/model/BoggedModel.java | 2 +- net/minecraft/client/model/CamelModel.java | 69 +- .../client/model/CamelSaddleModel.java | 77 + net/minecraft/client/model/ChickenModel.java | 11 +- .../client/model/ColdChickenModel.java | 33 + net/minecraft/client/model/ColdCowModel.java | 51 + net/minecraft/client/model/ColdPigModel.java | 33 + net/minecraft/client/model/CowModel.java | 26 +- net/minecraft/client/model/DonkeyModel.java | 25 +- .../client/model/EquineSaddleModel.java | 74 + net/minecraft/client/model/PigModel.java | 6 +- .../client/model/PolarBearModel.java | 6 +- net/minecraft/client/model/WarmCowModel.java | 43 + .../client/model/geom/LayerDefinitions.java | 365 +- .../client/model/geom/ModelLayers.java | 22 + .../client/model/geom/PartNames.java | 1 + .../model/geom/builders/MeshDefinition.java | 4 + .../model/geom/builders/MeshTransformer.java | 2 + .../model/geom/builders/PartDefinition.java | 18 +- .../client/multiplayer/CacheSlot.java | 42 + .../multiplayer/ClientAdvancements.java | 2 +- .../client/multiplayer/ClientChunkCache.java | 13 +- ...ClientConfigurationPacketListenerImpl.java | 17 +- .../client/multiplayer/ClientLevel.java | 90 +- .../multiplayer/ClientPacketListener.java | 276 +- .../multiplayer/MultiPlayerGameMode.java | 31 +- .../client/multiplayer/ServerData.java | 51 +- .../client/multiplayer/ServerList.java | 15 +- .../client/multiplayer/chat/ChatListener.java | 28 +- .../chat/report/ReportEnvironment.java | 2 +- .../client/particle/BreakingItemParticle.java | 2 +- .../particle/FallingLeavesParticle.java | 16 + .../client/particle/FireflyParticle.java | 83 + .../client/particle/ParticleEngine.java | 224 +- .../client/player/AbstractClientPlayer.java | 11 +- net/minecraft/client/player/ClientInput.java | 7 +- .../client/player/KeyboardInput.java | 6 +- net/minecraft/client/player/LocalPlayer.java | 229 +- net/minecraft/client/player/RemotePlayer.java | 5 +- .../client/renderer/BiomeColors.java | 5 + .../client/renderer/CloudRenderer.java | 108 +- .../renderer/CompiledShaderProgram.java | 274 - .../client/renderer/CoreShaders.java | 90 - net/minecraft/client/renderer/CubeMap.java | 153 +- .../client/renderer/GameRenderer.java | 157 +- .../client/renderer/GpuWarnlistManager.java | 28 +- .../client/renderer/ItemBlockRenderTypes.java | 7 + .../client/renderer/ItemInHandRenderer.java | 12 +- .../client/renderer/LevelRenderer.java | 214 +- .../client/renderer/LightTexture.java | 89 +- .../client/renderer/MapRenderer.java | 13 +- .../client/renderer/MaterialMapper.java | 17 + net/minecraft/client/renderer/Octree.java | 7 +- net/minecraft/client/renderer/PostChain.java | 86 +- .../client/renderer/PostChainConfig.java | 48 +- net/minecraft/client/renderer/PostPass.java | 140 +- .../client/renderer/RenderPipelines.java | 759 + .../client/renderer/RenderStateShard.java | 437 +- net/minecraft/client/renderer/RenderType.java | 949 +- .../client/renderer/ScreenEffectRenderer.java | 10 +- .../renderer/SectionOcclusionGraph.java | 58 +- .../client/renderer/ShaderDefines.java | 5 + .../client/renderer/ShaderManager.java | 277 +- .../client/renderer/ShaderProgram.java | 14 - .../client/renderer/ShaderProgramConfig.java | 58 - net/minecraft/client/renderer/Sheets.java | 88 +- .../client/renderer/SkyRenderer.java | 226 +- net/minecraft/client/renderer/ViewArea.java | 2 +- .../client/renderer/WorldBorderRenderer.java | 209 +- .../renderer/block/BlockModelShaper.java | 52 +- .../renderer/block/BlockRenderDispatcher.java | 32 +- .../renderer/block/LiquidBlockRenderer.java | 6 +- .../renderer/block/ModelBlockRenderer.java | 583 +- .../renderer/block/model/BakedQuad.java | 45 +- .../renderer/block/model/BlockElement.java | 51 +- .../block/model/BlockElementFace.java | 64 +- .../renderer/block/model/BlockFaceUV.java | 97 - .../renderer/block/model/BlockModel.java | 113 +- .../block/model/BlockModelDefinition.java | 217 +- .../renderer/block/model/BlockModelPart.java | 24 + .../renderer/block/model/BlockStateModel.java | 106 + .../renderer/block/model/FaceBakery.java | 211 +- .../block/model/ItemModelGenerator.java | 71 +- .../renderer/block/model/ItemTransform.java | 58 +- .../renderer/block/model/MultiVariant.java | 77 - .../block/model/SimpleModelWrapper.java | 30 + .../block/model/SimpleUnbakedGeometry.java | 50 + .../renderer/block/model/SingleVariant.java | 44 + .../renderer/block/model/TextureSlots.java | 2 +- .../block/model/UnbakedBlockStateModel.java | 15 - .../client/renderer/block/model/Variant.java | 120 +- .../renderer/block/model/VariantMutator.java | 30 + .../block/model/multipart/AndCondition.java | 25 - .../model/multipart/CombinedCondition.java | 39 + .../block/model/multipart/Condition.java | 39 +- .../model/multipart/KeyValueCondition.java | 180 +- .../block/model/multipart/MultiPart.java | 109 - .../block/model/multipart/MultiPartModel.java | 140 + .../block/model/multipart/OrCondition.java | 25 - .../block/model/multipart/Selector.java | 84 +- .../blockentity/AbstractSignRenderer.java | 8 +- .../renderer/blockentity/BannerRenderer.java | 9 +- .../renderer/blockentity/BeaconRenderer.java | 58 +- .../renderer/blockentity/BedRenderer.java | 6 +- .../renderer/blockentity/BellRenderer.java | 6 +- .../BlockEntityRenderDispatcher.java | 10 +- .../blockentity/BlockEntityRenderer.java | 2 +- .../blockentity/BlockEntityRenderers.java | 6 +- .../BlockEntityWithBoundingBoxRenderer.java | 134 + .../blockentity/BrushableBlockRenderer.java | 11 +- .../blockentity/CampfireRenderer.java | 6 +- .../renderer/blockentity/ChestRenderer.java | 8 +- .../renderer/blockentity/ConduitRenderer.java | 25 +- .../blockentity/DecoratedPotRenderer.java | 6 +- .../blockentity/EnchantTableRenderer.java | 8 +- .../blockentity/HangingSignRenderer.java | 3 +- .../renderer/blockentity/LecternRenderer.java | 6 +- .../blockentity/PistonHeadRenderer.java | 15 +- .../blockentity/ShulkerBoxRenderer.java | 6 +- .../renderer/blockentity/SignRenderer.java | 3 +- .../blockentity/SkullBlockRenderer.java | 40 +- .../renderer/blockentity/SpawnerRenderer.java | 6 +- .../blockentity/StructureBlockRenderer.java | 168 - .../blockentity/TestInstanceRenderer.java | 38 + .../blockentity/TheEndGatewayRenderer.java | 10 +- .../blockentity/TheEndPortalRenderer.java | 6 +- .../blockentity/TrialSpawnerRenderer.java | 6 +- .../renderer/blockentity/VaultRenderer.java | 8 +- .../chunk/CompileTaskDynamicQueue.java | 2 +- .../renderer/chunk/SectionCompiler.java | 8 +- .../chunk/SectionRenderDispatcher.java | 286 +- .../debug/ChunkCullingDebugRenderer.java | 2 +- .../client/renderer/debug/DebugRenderer.java | 5 +- .../debug/LightSectionDebugRenderer.java | 8 +- .../renderer/debug/SupportBlockRenderer.java | 2 +- .../renderer/entity/AbstractBoatRenderer.java | 5 +- .../entity/AbstractHorseRenderer.java | 6 +- .../entity/AbstractMinecartRenderer.java | 7 +- .../renderer/entity/ArmorStandRenderer.java | 3 +- .../client/renderer/entity/ArrowRenderer.java | 3 +- .../client/renderer/entity/BoatRenderer.java | 3 +- .../client/renderer/entity/CamelRenderer.java | 19 +- .../client/renderer/entity/CatRenderer.java | 5 +- .../renderer/entity/ChickenRenderer.java | 42 +- .../client/renderer/entity/CodRenderer.java | 3 +- .../client/renderer/entity/CowRenderer.java | 54 +- .../renderer/entity/DisplayRenderer.java | 21 +- .../renderer/entity/DonkeyRenderer.java | 66 +- .../entity/DragonFireballRenderer.java | 8 +- .../renderer/entity/DrownedRenderer.java | 11 +- .../entity/ElderGuardianRenderer.java | 3 +- .../renderer/entity/EndCrystalRenderer.java | 3 +- .../renderer/entity/EnderDragonRenderer.java | 43 +- .../entity/EntityRenderDispatcher.java | 221 +- .../renderer/entity/EntityRenderer.java | 100 +- .../renderer/entity/EntityRenderers.java | 60 +- .../renderer/entity/EvokerFangsRenderer.java | 3 +- .../renderer/entity/EvokerRenderer.java | 3 +- .../entity/ExperienceOrbRenderer.java | 8 +- .../renderer/entity/FallingBlockRenderer.java | 12 +- .../entity/FireworkEntityRenderer.java | 3 +- .../renderer/entity/FishingHookRenderer.java | 12 +- .../client/renderer/entity/FoxRenderer.java | 3 +- .../client/renderer/entity/FrogRenderer.java | 7 +- .../renderer/entity/GlowSquidRenderer.java | 3 +- .../renderer/entity/GuardianRenderer.java | 10 +- .../client/renderer/entity/HorseRenderer.java | 56 +- .../renderer/entity/IllusionerRenderer.java | 3 +- .../renderer/entity/IronGolemRenderer.java | 3 +- .../renderer/entity/ItemEntityRenderer.java | 88 +- .../renderer/entity/ItemFrameRenderer.java | 45 +- .../client/renderer/entity/ItemRenderer.java | 52 +- .../renderer/entity/LeashKnotRenderer.java | 3 +- .../entity/LightningBoltRenderer.java | 3 +- .../renderer/entity/LivingEntityRenderer.java | 29 +- .../renderer/entity/LlamaSpitRenderer.java | 3 +- .../renderer/entity/MinecartRenderer.java | 3 +- .../client/renderer/entity/MobRenderer.java | 3 +- .../client/renderer/entity/NoopRenderer.java | 3 +- .../entity/OminousItemSpawnerRenderer.java | 3 +- .../renderer/entity/PaintingRenderer.java | 10 +- .../client/renderer/entity/PandaRenderer.java | 34 +- .../renderer/entity/PhantomRenderer.java | 3 +- .../client/renderer/entity/PigRenderer.java | 54 +- .../client/renderer/entity/RaftRenderer.java | 3 +- .../renderer/entity/SalmonRenderer.java | 3 +- .../client/renderer/entity/SheepRenderer.java | 7 +- .../entity/ShulkerBulletRenderer.java | 3 +- .../renderer/entity/ShulkerRenderer.java | 3 +- .../entity/SpectralArrowRenderer.java | 3 +- .../client/renderer/entity/SquidRenderer.java | 3 +- .../renderer/entity/StriderRenderer.java | 17 +- .../renderer/entity/ThrownItemRenderer.java | 5 +- .../entity/ThrownTridentRenderer.java | 3 +- .../entity/TippableArrowRenderer.java | 3 +- .../renderer/entity/TntMinecartRenderer.java | 3 +- .../client/renderer/entity/TntRenderer.java | 3 +- .../renderer/entity/TropicalFishRenderer.java | 9 +- .../renderer/entity/UndeadHorseRenderer.java | 68 +- .../renderer/entity/VindicatorRenderer.java | 3 +- .../renderer/entity/WindChargeRenderer.java | 3 +- .../renderer/entity/WitherSkullRenderer.java | 3 +- .../client/renderer/entity/WolfRenderer.java | 5 +- .../entity/ZombifiedPiglinRenderer.java | 5 +- .../renderer/entity/layers/ArrowLayer.java | 4 +- .../entity/layers/BeeStingerLayer.java | 4 +- .../entity/layers/CustomHeadLayer.java | 8 +- .../entity/layers/EquipmentLayerRenderer.java | 19 +- .../entity/layers/HorseArmorLayer.java | 44 - .../entity/layers/HorseMarkingLayer.java | 25 +- .../layers/MushroomCowMushroomLayer.java | 25 +- .../renderer/entity/layers/SaddleLayer.java | 41 - .../entity/layers/SheepWoolLayer.java | 26 +- .../layers/SheepWoolUndercoatLayer.java | 37 + .../entity/layers/SimpleEquipmentLayer.java | 59 + .../entity/layers/SnowGolemHeadLayer.java | 7 +- .../entity/layers/StuckInBodyLayer.java | 3 +- .../layers/TropicalFishPatternLayer.java | 2 +- .../layers/VillagerProfessionLayer.java | 75 +- .../entity/player/PlayerRenderer.java | 59 +- .../entity/state/ArmedEntityRenderState.java | 14 +- .../entity/state/AxolotlRenderState.java | 4 +- .../entity/state/CamelRenderState.java | 3 +- .../entity/state/ChickenRenderState.java | 4 + .../renderer/entity/state/CowRenderState.java | 12 + .../entity/state/EnderDragonRenderState.java | 5 +- .../entity/state/EntityRenderState.java | 13 + .../entity/state/EquineRenderState.java | 3 +- .../renderer/entity/state/FoxRenderState.java | 2 +- .../entity/state/HitboxRenderState.java | 13 + .../entity/state/HitboxesRenderState.java | 9 + .../state/HoldingEntityRenderState.java | 2 +- .../entity/state/LivingEntityRenderState.java | 4 +- .../entity/state/LlamaRenderState.java | 2 +- .../entity/state/PandaRenderState.java | 4 +- .../renderer/entity/state/PigRenderState.java | 14 +- .../entity/state/RabbitRenderState.java | 2 +- .../entity/state/SaddleableRenderState.java | 9 - .../state/ServerHitboxesRenderState.java | 22 + .../entity/state/SheepRenderState.java | 24 + .../entity/state/StriderRenderState.java | 10 +- .../entity/state/TropicalFishRenderState.java | 2 +- .../state/VillagerDataHolderRenderState.java | 2 + .../entity/state/VillagerRenderState.java | 7 +- .../state/ZombieVillagerRenderState.java | 7 +- .../renderer/item/BlockModelWrapper.java | 49 +- .../client/renderer/item/ClientItem.java | 12 +- .../renderer/item/ConditionalItemModel.java | 25 +- .../client/renderer/item/ItemModel.java | 11 +- .../renderer/item/ItemModelResolver.java | 15 +- .../renderer/item/ItemStackRenderState.java | 105 +- .../renderer/item/MissingItemModel.java | 22 +- .../renderer/item/ModelRenderProperties.java | 24 + .../client/renderer/item/SelectItemModel.java | 43 +- .../renderer/item/SpecialModelWrapper.java | 42 +- .../item/properties/conditional/Broken.java | 4 +- .../conditional/BundleHasSelectedItem.java | 4 +- .../conditional/ComponentMatches.java | 29 + .../ConditionalItemModelProperties.java | 1 + .../ConditionalItemModelProperty.java | 9 +- .../conditional/CustomModelDataProperty.java | 4 +- .../item/properties/conditional/Damaged.java | 4 +- .../properties/conditional/ExtendedView.java | 4 +- .../conditional/FishingRodCast.java | 6 +- .../properties/conditional/HasComponent.java | 4 +- .../properties/conditional/IsCarried.java | 4 +- .../properties/conditional/IsKeybindDown.java | 2 +- .../properties/conditional/IsSelected.java | 4 +- .../properties/conditional/IsUsingItem.java | 4 +- .../properties/conditional/IsViewEntity.java | 6 +- .../conditional/ItemModelPropertyTest.java | 15 + .../properties/numeric/CompassAngleState.java | 5 +- .../item/properties/numeric/Time.java | 3 +- .../item/properties/select/Charge.java | 9 +- .../properties/select/ComponentContents.java | 55 + .../properties/select/ContextDimension.java | 9 +- .../properties/select/ContextEntityType.java | 9 +- .../select/CustomModelDataProperty.java | 9 +- .../properties/select/DisplayContext.java | 9 +- .../properties/select/ItemBlockState.java | 9 +- .../item/properties/select/LocalTime.java | 10 +- .../item/properties/select/MainHand.java | 11 +- .../select/SelectItemModelProperties.java | 1 + .../select/SelectItemModelProperty.java | 57 +- .../select/TrimMaterialProperty.java | 9 +- .../renderer/special/BedSpecialRenderer.java | 4 +- .../special/ChestSpecialRenderer.java | 4 +- .../special/HangingSignSpecialRenderer.java | 4 +- .../special/ShulkerBoxSpecialRenderer.java | 5 +- .../special/StandingSignSpecialRenderer.java | 4 +- .../renderer/texture/AbstractTexture.java | 110 +- .../renderer/texture/DynamicTexture.java | 35 +- .../renderer/texture/OverlayTexture.java | 9 +- .../renderer/texture/ReloadableTexture.java | 14 +- .../texture/SkinTextureDownloader.java | 2 +- .../renderer/texture/SpriteContents.java | 32 +- .../client/renderer/texture/SpriteLoader.java | 124 +- .../client/renderer/texture/SpriteTicker.java | 3 +- .../client/renderer/texture/TextureAtlas.java | 27 +- .../renderer/texture/TextureAtlasSprite.java | 11 +- .../renderer/texture/TextureManager.java | 24 +- .../renderer/texture/atlas/SpriteSource.java | 3 +- .../texture/atlas/SpriteSourceType.java | 9 - .../renderer/texture/atlas/SpriteSources.java | 37 +- .../atlas/sources/DirectoryLister.java | 20 +- .../atlas/sources/PalettedPermutations.java | 37 +- .../texture/atlas/sources/SingleFile.java | 21 +- .../texture/atlas/sources/SourceFilter.java | 18 +- .../texture/atlas/sources/Unstitcher.java | 31 +- .../client/resources/ClientPackSource.java | 8 +- .../DryFoliageColorReloadListener.java | 27 + .../MapDecorationTextureManager.java | 3 +- .../client/resources/MapTextureManager.java | 2 +- .../resources/MobEffectTextureManager.java | 3 +- .../resources/PaintingTextureManager.java | 3 +- .../client/resources/TextureAtlasHolder.java | 15 +- .../client/resources/model/AtlasIds.java | 23 + .../client/resources/model/AtlasSet.java | 21 +- .../client/resources/model/BakedModel.java | 27 - .../resources/model/BlockModelRotation.java | 117 +- .../model/BlockStateDefinitions.java | 44 + .../model/BlockStateModelLoader.java | 97 +- .../resources/model/ClientItemInfoLoader.java | 33 +- .../resources/model/DelegateBakedModel.java | 51 - .../resources/model/EquipmentClientInfo.java | 14 +- .../resources/model/MissingBlockModel.java | 24 +- .../client/resources/model/ModelBaker.java | 12 +- .../client/resources/model/ModelBakery.java | 182 +- .../resources/model/ModelDebugName.java | 4 +- .../resources/model/ModelDiscovery.java | 275 +- .../resources/model/ModelGroupCollector.java | 21 +- .../client/resources/model/ModelManager.java | 265 +- .../model/ModelResourceLocation.java | 27 - .../client/resources/model/ModelState.java | 15 +- .../resources/model/MultiPartBakedModel.java | 71 - .../resources/model/QuadCollection.java | 128 + .../resources/model/ResolvableModel.java | 2 +- .../client/resources/model/ResolvedModel.java | 131 + .../resources/model/SimpleBakedModel.java | 173 - .../client/resources/model/SpriteGetter.java | 10 +- .../resources/model/UnbakedGeometry.java | 13 + .../client/resources/model/UnbakedModel.java | 96 +- .../resources/model/WeightedBakedModel.java | 28 - .../resources/model/WeightedVariants.java | 46 + .../client/server/IntegratedServer.java | 4 +- net/minecraft/commands/Commands.java | 8 +- net/minecraft/commands/ParserUtils.java | 53 - .../commands/arguments/ComponentArgument.java | 42 +- .../arguments/CompoundTagArgument.java | 2 +- .../commands/arguments/NbtPathArgument.java | 44 +- .../commands/arguments/NbtTagArgument.java | 16 +- .../commands/arguments/ParticleArgument.java | 23 +- .../arguments/ResourceKeyArgument.java | 7 +- .../arguments/ResourceOrIdArgument.java | 28 +- .../arguments/ResourceSelectorArgument.java | 117 + .../arguments/ScoreHolderArgument.java | 4 +- .../commands/arguments/StyleArgument.java | 30 +- .../commands/arguments/blocks/BlockInput.java | 30 +- .../arguments/blocks/BlockStateParser.java | 5 +- .../item/ComponentPredicateParser.java | 90 +- .../commands/arguments/item/ItemParser.java | 14 +- .../arguments/item/ItemPredicateArgument.java | 76 +- .../options/EntitySelectorOptions.java | 41 +- .../commands/functions/MacroFunction.java | 21 +- .../synchronization/ArgumentTypeInfos.java | 32 +- net/minecraft/core/BlockMath.java | 55 +- net/minecraft/core/BlockPos.java | 15 +- net/minecraft/core/ClientAsset.java | 18 + net/minecraft/core/Direction.java | 25 +- net/minecraft/core/HolderGetter.java | 6 + net/minecraft/core/MappedRegistry.java | 15 +- net/minecraft/core/RegistrySetBuilder.java | 75 +- net/minecraft/core/Rotations.java | 84 +- net/minecraft/core/SectionPos.java | 4 + net/minecraft/core/Vec3i.java | 6 + .../core/cauldron/CauldronInteraction.java | 6 +- ....java => DataComponentExactPredicate.java} | 57 +- .../core/component/DataComponentGetter.java | 19 + .../core/component/DataComponentHolder.java | 4 +- .../core/component/DataComponentMap.java | 53 +- .../core/component/DataComponentPatch.java | 162 +- .../core/component/DataComponents.java | 166 +- .../component/PatchedDataComponentMap.java | 4 +- .../AttributeModifiersPredicate.java | 71 + .../component/predicates/BundlePredicate.java | 28 + .../predicates/ContainerPredicate.java | 28 + .../predicates/CustomDataPredicate.java | 18 + .../component/predicates/DamagePredicate.java | 32 + .../predicates/DataComponentPredicate.java | 71 + .../predicates/DataComponentPredicates.java | 38 + .../predicates/EnchantmentsPredicate.java | 70 + .../FireworkExplosionPredicate.java | 46 + .../predicates/FireworksPredicate.java | 35 + .../predicates/JukeboxPlayablePredicate.java} | 20 +- .../predicates/PotionsPredicate.java} | 15 +- .../component/predicates/TrimPredicate.java} | 16 +- .../predicates/WritableBookPredicate.java | 40 + .../predicates/WrittenBookPredicate.java} | 37 +- .../component/predicates/package-info.java | 8 + .../DefaultDispenseItemBehavior.java | 3 +- .../core/dispenser/DispenseItemBehavior.java | 58 +- .../EquipmentDispenseItemBehavior.java | 2 +- .../core/particles/ParticleTypes.java | 4 + .../core/registries/BuiltInRegistries.java | 55 +- net/minecraft/core/registries/Registries.java | 113 +- net/minecraft/data/Main.java | 15 +- .../packs/VanillaAdventureAdvancements.java | 352 +- .../packs/VanillaHusbandryAdvancements.java | 223 +- .../packs/VanillaNetherAdvancements.java | 139 +- .../packs/VanillaStoryAdvancements.java | 79 +- .../packs/VanillaTheEndAdvancements.java | 42 +- .../data/info/DatapackStructureReport.java | 3 +- net/minecraft/data/info/PacketReport.java | 14 +- .../data/loot/BlockLootSubProvider.java | 202 +- .../data/loot/EntityLootSubProvider.java | 37 +- net/minecraft/data/loot/packs/LootData.java | 39 +- .../loot/packs/VanillaArchaeologyLoot.java | 2 +- .../data/loot/packs/VanillaBlockLoot.java | 75 +- .../data/loot/packs/VanillaChestLoot.java | 76 +- .../data/loot/packs/VanillaEntityLoot.java | 51 +- .../data/loot/packs/VanillaGiftLoot.java | 59 +- .../data/loot/packs/VanillaShearingLoot.java | 19 +- .../data/recipes/RecipeProvider.java | 66 +- .../SmithingTransformRecipeBuilder.java | 8 +- .../recipes/SmithingTrimRecipeBuilder.java | 19 +- .../data/recipes/TransmuteRecipeBuilder.java | 14 +- .../recipes/packs/VanillaRecipeProvider.java | 93 +- .../data/registries/VanillaRegistries.java | 27 +- .../data/structures/StructureUpdater.java | 9 +- .../data/tags/BiomeTagsProvider.java | 48 +- .../data/tags/CatVariantTagsProvider.java | 32 - .../data/tags/DamageTypeTagsProvider.java | 15 +- .../data/tags/EntityTypeTagsProvider.java | 18 +- .../data/tags/StructureTagsProvider.java | 7 + .../TradeRebalanceStructureTagsProvider.java | 26 - .../data/tags/VanillaBlockTagsProvider.java | 195 +- .../data/tags/VanillaItemTagsProvider.java | 28 +- .../data/worldgen/BiomeDefaultFeatures.java | 280 +- net/minecraft/data/worldgen/Structures.java | 108 +- .../data/worldgen/TerrainProvider.java | 36 +- .../worldgen/TrialChambersStructurePools.java | 9 +- .../data/worldgen/biome/NetherBiomes.java | 62 +- .../data/worldgen/biome/OverworldBiomes.java | 442 +- .../data/worldgen/features/CaveFeatures.java | 19 +- .../worldgen/features/NetherFeatures.java | 6 +- .../data/worldgen/features/PileFeatures.java | 10 +- .../data/worldgen/features/TreeFeatures.java | 125 +- .../worldgen/features/VegetationFeatures.java | 341 +- .../worldgen/placement/PlacementUtils.java | 18 +- .../worldgen/placement/TreePlacements.java | 58 +- .../placement/VegetationPlacements.java | 320 +- net/minecraft/gametest/Main.java | 13 + .../gametest/framework/AfterBatch.java | 15 - .../gametest/framework/BeforeBatch.java | 15 - .../framework/BlockBasedTestInstance.java | 91 + .../framework/BuiltinTestFunctions.java | 28 + .../gametest/framework/FailedTestTracker.java | 22 + .../framework/FunctionGameTestInstance.java | 56 + .../gametest/framework/GameTest.java | 30 - .../framework/GameTestAssertException.java | 22 +- .../framework/GameTestAssertPosException.java | 34 +- .../gametest/framework/GameTestBatch.java | 16 +- .../framework/GameTestBatchFactory.java | 57 +- .../framework/GameTestEnvironments.java | 20 + .../gametest/framework/GameTestException.java | 11 + .../gametest/framework/GameTestGenerator.java | 11 - .../gametest/framework/GameTestHelper.java | 275 +- .../gametest/framework/GameTestInfo.java | 233 +- .../gametest/framework/GameTestInstance.java | 107 + .../gametest/framework/GameTestInstances.java | 28 + .../gametest/framework/GameTestMainUtil.java | 140 + .../gametest/framework/GameTestRegistry.java | 165 - .../gametest/framework/GameTestRunner.java | 49 +- .../gametest/framework/GameTestSequence.java | 61 +- .../gametest/framework/GameTestServer.java | 182 +- .../gametest/framework/GameTestTicker.java | 25 +- .../framework/GameTestTimeoutException.java | 16 +- .../gametest/framework/GeneratedTest.java | 23 + .../framework/JUnitLikeTestReporter.java | 8 +- .../gametest/framework/LogTestReporter.java | 6 +- .../framework/ReportGameListener.java | 96 +- .../framework/StructureGridSpawner.java | 8 +- .../gametest/framework/StructureUtils.java | 186 +- .../framework/TestClassNameArgument.java | 48 - .../gametest/framework/TestCommand.java | 971 +- .../gametest/framework/TestData.java | 62 + .../framework/TestEnvironmentDefinition.java | 198 + .../gametest/framework/TestFinder.java | 136 +- .../gametest/framework/TestFunction.java | 50 - .../framework/TestFunctionArgument.java | 56 - .../framework/TestFunctionFinder.java | 8 - .../framework/TestFunctionLoader.java | 24 + .../framework/TestInstanceFinder.java | 9 + ...BlockPosFinder.java => TestPosFinder.java} | 4 +- .../framework/UnknownGameTestException.java | 17 + net/minecraft/nbt/ByteArrayTag.java | 59 +- net/minecraft/nbt/ByteTag.java | 70 +- net/minecraft/nbt/CollectionTag.java | 45 +- net/minecraft/nbt/CompoundTag.java | 373 +- net/minecraft/nbt/DoubleTag.java | 71 +- net/minecraft/nbt/EndTag.java | 14 +- net/minecraft/nbt/FloatTag.java | 70 +- net/minecraft/nbt/IntArrayTag.java | 59 +- net/minecraft/nbt/IntTag.java | 70 +- net/minecraft/nbt/ListTag.java | 358 +- net/minecraft/nbt/LongArrayTag.java | 64 +- net/minecraft/nbt/LongTag.java | 70 +- net/minecraft/nbt/NbtIo.java | 4 +- net/minecraft/nbt/NbtOps.java | 259 +- net/minecraft/nbt/NbtUtils.java | 361 +- net/minecraft/nbt/NumericTag.java | 58 +- net/minecraft/nbt/PrimitiveTag.java | 8 + net/minecraft/nbt/ShortTag.java | 70 +- net/minecraft/nbt/SnbtGrammar.java | 827 + net/minecraft/nbt/SnbtOperations.java | 97 + net/minecraft/nbt/SnbtPrinterTagVisitor.java | 16 +- net/minecraft/nbt/StringTag.java | 84 +- net/minecraft/nbt/StringTagVisitor.java | 46 +- net/minecraft/nbt/Tag.java | 64 +- net/minecraft/nbt/TagParser.java | 318 +- net/minecraft/nbt/TagType.java | 4 - .../nbt/TextComponentTagVisitor.java | 38 +- net/minecraft/nbt/visitors/CollectFields.java | 2 +- net/minecraft/nbt/visitors/CollectToTag.java | 106 +- net/minecraft/network/FriendlyByteBuf.java | 62 +- net/minecraft/network/HashedPatchMap.java | 58 + net/minecraft/network/HashedStack.java | 57 + net/minecraft/network/PacketDecoder.java | 12 +- net/minecraft/network/PacketEncoder.java | 2 +- net/minecraft/network/ProtocolInfo.java | 16 +- .../network/SkipPacketDecoderException.java | 14 + .../network/SkipPacketEncoderException.java | 14 + .../network/SkipPacketException.java | 7 +- .../network/chat/ChatTypeDecoration.java | 5 +- net/minecraft/network/chat/ClickEvent.java | 155 +- .../network/chat/ComponentSerialization.java | 36 +- .../network/chat/ComponentUtils.java | 18 +- net/minecraft/network/chat/FilterMask.java | 2 +- net/minecraft/network/chat/HoverEvent.java | 208 +- .../network/chat/LastSeenMessages.java | 26 +- .../network/chat/LastSeenMessagesTracker.java | 2 +- .../chat/LastSeenMessagesValidator.java | 68 +- .../network/chat/MessageSignature.java | 8 + .../network/chat/PlayerChatMessage.java | 30 +- .../network/chat/SignedMessageValidator.java | 6 +- net/minecraft/network/chat/Style.java | 4 +- .../network/chat/contents/NbtContents.java | 27 +- .../network/codec/ByteBufCodecs.java | 63 +- .../network/codec/IdDispatchCodec.java | 15 +- net/minecraft/network/codec/StreamCodec.java | 52 + .../network/protocol/CodecModifier.java | 8 + .../network/protocol/ProtocolInfoBuilder.java | 153 +- .../protocol/SimpleUnboundProtocol.java | 10 + .../network/protocol/UnboundProtocol.java | 10 + .../configuration/ConfigurationProtocols.java | 5 +- .../game/ClientGamePacketListener.java | 7 +- .../ClientboundAddExperienceOrbPacket.java | 80 - .../ClientboundContainerSetContentPacket.java | 63 +- .../game/ClientboundGameEventPacket.java | 2 +- .../game/ClientboundLevelChunkPacketData.java | 47 +- .../game/ClientboundMoveEntityPacket.java | 4 +- .../game/ClientboundPlayerChatPacket.java | 11 +- .../ClientboundPlayerInfoUpdatePacket.java | 2 +- .../game/ClientboundSetPlayerTeamPacket.java | 21 +- .../ClientboundTestInstanceBlockStatus.java | 30 + .../ClientboundUpdateAdvancementsPacket.java | 14 +- .../protocol/game/GamePacketTypes.java | 32 +- .../network/protocol/game/GameProtocols.java | 58 +- .../game/ServerGamePacketListener.java | 6 +- .../game/ServerboundContainerClickPacket.java | 102 +- .../game/ServerboundMovePlayerPacket.java | 9 + .../game/ServerboundMoveVehiclePacket.java | 8 +- .../ServerboundSelectBundleItemPacket.java | 3 + .../ServerboundSetCreativeModeSlotPacket.java | 2 +- .../ServerboundSetStructureBlockPacket.java | 13 + .../game/ServerboundSetTestBlockPacket.java | 30 + ...verboundTestInstanceBlockActionPacket.java | 71 + .../handshake/HandshakeProtocols.java | 3 +- .../protocol/login/LoginProtocols.java | 6 +- .../protocol/status/StatusProtocols.java | 5 +- .../syncher/EntityDataSerializers.java | 26 +- .../recipebook/ServerPlaceRecipe.java | 2 +- net/minecraft/resources/DelegatingOps.java | 147 +- .../resources/RegistryDataLoader.java | 78 +- net/minecraft/resources/RegistryOps.java | 6 +- net/minecraft/resources/ResourceLocation.java | 19 - net/minecraft/server/Bootstrap.java | 8 +- net/minecraft/server/Main.java | 25 +- net/minecraft/server/MinecraftServer.java | 48 +- net/minecraft/server/PlayerAdvancements.java | 4 +- .../server/ServerFunctionLibrary.java | 17 +- net/minecraft/server/ServerScoreboard.java | 20 +- .../server/bossevents/CustomBossEvent.java | 101 +- .../server/bossevents/CustomBossEvents.java | 28 +- .../server/commands/AdvancementCommands.java | 29 +- .../server/commands/BossBarCommands.java | 6 +- .../server/commands/CloneCommands.java | 328 +- .../server/commands/ExecuteCommand.java | 47 +- .../server/commands/FillCommand.java | 250 +- .../server/commands/ForceLoadCommand.java | 6 +- .../server/commands/InCommandFunction.java | 8 + net/minecraft/server/commands/JfrCommand.java | 4 +- .../server/commands/LocateCommand.java | 11 +- net/minecraft/server/commands/OpCommand.java | 2 +- .../server/commands/PlaceCommand.java | 41 +- .../server/commands/RaidCommand.java | 2 +- .../server/commands/ScoreboardCommand.java | 11 +- .../server/commands/SetBlockCommand.java | 57 +- .../server/commands/SetSpawnCommand.java | 2 +- .../commands/SpawnArmorTrimsCommand.java | 123 +- .../server/commands/SpectateCommand.java | 3 +- .../server/commands/SummonCommand.java | 8 +- .../server/commands/TeamCommand.java | 10 +- .../server/commands/TeamMsgCommand.java | 11 +- .../server/commands/TellRawCommand.java | 24 +- .../server/commands/TitleCommand.java | 6 +- .../server/commands/data/DataCommands.java | 36 +- .../server/dedicated/DedicatedServer.java | 4 +- net/minecraft/server/level/ChunkMap.java | 98 +- .../server/level/DistanceManager.java | 319 +- .../server/level/LoadingChunkTracker.java | 49 + .../server/level/ServerChunkCache.java | 107 +- net/minecraft/server/level/ServerEntity.java | 44 +- net/minecraft/server/level/ServerLevel.java | 235 +- net/minecraft/server/level/ServerPlayer.java | 457 +- .../server/level/ServerPlayerGameMode.java | 17 +- .../server/level/SimulationChunkTracker.java | 46 + net/minecraft/server/level/Ticket.java | 83 +- net/minecraft/server/level/TicketType.java | 56 +- .../server/level/TickingTracker.java | 120 - .../server/level/WorldGenRegion.java | 16 +- .../PlayerSafetyServiceTextFilter.java | 12 +- .../network/ServerGamePacketListenerImpl.java | 360 +- .../server/network/ServerTextFilter.java | 4 +- .../server/packs/PackLocationInfo.java | 2 +- .../packs/VanillaPackResourcesBuilder.java | 37 +- .../packs/repository/BuiltInPackSource.java | 11 +- .../packs/repository/ServerPacksSource.java | 12 +- .../resources/PreparableReloadListener.java | 2 + .../resources/ProfiledReloadInstance.java | 50 +- .../ResourceManagerReloadListener.java | 8 +- .../SimpleJsonResourceReloadListener.java | 4 +- .../SimplePreparableReloadListener.java | 8 +- .../packs/resources/SimpleReloadInstance.java | 149 +- .../server/players/GameProfileCache.java | 19 +- net/minecraft/server/players/PlayerList.java | 64 +- net/minecraft/sounds/SoundEvents.java | 67 +- net/minecraft/stats/RecipeBookSettings.java | 4 +- net/minecraft/stats/ServerRecipeBook.java | 45 +- net/minecraft/stats/ServerStatsCounter.java | 135 +- net/minecraft/tags/BiomeTags.java | 2 + net/minecraft/tags/BlockTags.java | 7 +- net/minecraft/tags/CatVariantTags.java | 17 - net/minecraft/tags/EntityTypeTags.java | 2 + net/minecraft/tags/ItemTags.java | 3 + net/minecraft/util/AbstractListBuilder.java | 58 + net/minecraft/util/Brightness.java | 20 +- net/minecraft/util/CommonLinks.java | 2 + net/minecraft/util/ExtraCodecs.java | 37 +- net/minecraft/util/FileSystemUtil.java | 32 + net/minecraft/util/GsonHelper.java | 43 + net/minecraft/util/HashOps.java | 343 + net/minecraft/util/NullOps.java | 24 + .../util/PlaceholderLookupProvider.java | 109 + net/minecraft/util/RandomSource.java | 8 +- .../util/RegistryContextSwapper.java | 9 + net/minecraft/util/SortedArraySet.java | 3 +- net/minecraft/util/StringRepresentable.java | 1 - net/minecraft/util/Unit.java | 3 + .../util/datafix/ComponentDataFixUtils.java | 84 - net/minecraft/util/datafix/DataFixTypes.java | 2 +- net/minecraft/util/datafix/DataFixers.java | 807 +- .../util/datafix/ExtraDataFixUtils.java | 52 +- .../datafix/LegacyComponentDataFixUtils.java | 78 + .../fixes/AbstractBlockPropertyFix.java | 36 + .../AreaEffectCloudDurationScaleFix.java | 16 + ...ntityCustomNameToOverrideComponentFix.java | 48 +- .../datafix/fixes/BannerPatternFormatFix.java | 24 +- .../BlockEntityCustomNameToComponentFix.java | 51 +- .../util/datafix/fixes/BlockEntityIdFix.java | 2 +- ...kEntitySignDoubleSidedEditableTextFix.java | 37 +- .../BlockEntitySignTextStrictJsonFix.java | 27 - .../fixes/BlockPosFormatAndRenamesFix.java | 11 +- .../fixes/BlockPropertyRenameAndFix.java | 34 + .../util/datafix/fixes/BlockStateData.java | 14353 ++++++++-------- .../fixes/ChunkTicketUnpackPosFix.java | 38 + .../datafix/fixes/DropChancesFormatFix.java | 55 + .../datafix/fixes/DropInvalidSignDataFix.java | 68 +- .../fixes/EntityCustomNameToComponentFix.java | 38 +- .../EntityEquipmentToArmorAndHandFix.java | 149 +- .../EntityFallDistanceFloatToDoubleFix.java | 30 + .../fixes/EntityProjectileOwnerFix.java | 6 - .../EntitySpawnerItemVariantComponentFix.java | 146 + .../datafix/fixes/EquipmentFormatFix.java | 123 + .../util/datafix/fixes/FilteredBooksFix.java | 7 +- .../util/datafix/fixes/FilteredSignsFix.java | 9 +- .../datafix/{ => fixes}/FixWolfHealth.java | 4 +- .../datafix/fixes/ForcedChunkToTicketFix.java | 40 + .../util/datafix/fixes/GoatHornIdFix.java | 8 +- .../fixes/InlineBlockPosFormatFix.java | 116 + .../fixes/ItemCustomNameToComponentFix.java | 40 +- .../util/datafix/fixes/ItemLoreFix.java | 29 +- .../util/datafix/fixes/ItemSpawnEggFix.java | 10 +- .../fixes/ItemStackComponentizationFix.java | 7 +- ...StackCustomNameToOverrideComponentFix.java | 23 +- .../util/datafix/fixes/ItemStackTagFix.java | 9 +- .../fixes/ItemStackTagRemainderFix.java | 20 + .../ItemWrittenBookPagesStrictJsonFix.java | 35 - .../util/datafix/fixes/JigsawRotationFix.java | 30 +- .../datafix/fixes/LegacyHoverEventFix.java | 89 + .../util/datafix/fixes/LevelUUIDFix.java | 49 +- .../fixes/MapBannerBlockPosFormatFix.java | 24 +- .../util/datafix/fixes/MapIdFix.java | 12 +- .../fixes/NamedEntityConvertUncheckedFix.java | 19 + .../util/datafix/fixes/NamedEntityFix.java | 4 +- .../fixes/NamedEntityWriteReadFix.java | 20 +- .../fixes/ObjectiveDisplayNameFix.java | 24 - .../datafix/fixes/ObjectiveRenderTypeFix.java | 4 +- .../OminousBannerBlockEntityRenameFix.java | 26 +- .../datafix/fixes/OminousBannerRarityFix.java | 43 +- .../datafix/fixes/OminousBannerRenameFix.java | 36 +- .../fixes/OptionsAccessibilityOnboardFix.java | 2 +- .../fixes/OptionsAddTextBackgroundFix.java | 11 +- .../fixes/OptionsMenuBlurrinessFix.java | 8 +- .../datafix/fixes/OptionsRenameFieldFix.java | 6 +- .../fixes/ParticleUnflatteningFix.java | 17 +- .../datafix/fixes/PlayerEquipmentFix.java | 36 + .../datafix/fixes/RaidRenamesDataFix.java | 44 + .../util/datafix/fixes/References.java | 4 +- .../util/datafix/fixes/ReorganizePoi.java | 2 +- .../datafix/fixes/SaddleEquipmentSlotFix.java | 81 + .../fixes/ScoreboardDisplayNameFix.java | 34 + .../datafix/fixes/TeamDisplayNameFix.java | 31 - .../TextComponentHoverAndClickEventFix.java | 165 + .../fixes/TextComponentStrictJsonFix.java | 20 + .../TextComponentStringifiedFlagsFix.java | 46 + .../datafix/fixes/ThrownPotionSplitFix.java | 46 + .../fixes/TooltipDisplayComponentFix.java | 132 + .../TrialSpawnerConfigInRegistryFix.java | 14 +- .../fixes/UnflattenTextComponentFix.java | 52 + net/minecraft/util/datafix/schemas/V100.java | 100 +- net/minecraft/util/datafix/schemas/V102.java | 19 +- .../util/datafix/schemas/V1451_3.java | 12 +- .../util/datafix/schemas/V1451_6.java | 6 +- net/minecraft/util/datafix/schemas/V1458.java | 52 + net/minecraft/util/datafix/schemas/V1460.java | 143 +- net/minecraft/util/datafix/schemas/V1470.java | 2 +- net/minecraft/util/datafix/schemas/V1488.java | 25 + net/minecraft/util/datafix/schemas/V1800.java | 6 +- net/minecraft/util/datafix/schemas/V1801.java | 2 +- net/minecraft/util/datafix/schemas/V1904.java | 2 +- net/minecraft/util/datafix/schemas/V1906.java | 2 +- net/minecraft/util/datafix/schemas/V1925.java | 24 + net/minecraft/util/datafix/schemas/V1928.java | 2 +- net/minecraft/util/datafix/schemas/V1929.java | 14 +- net/minecraft/util/datafix/schemas/V1931.java | 2 +- net/minecraft/util/datafix/schemas/V2100.java | 2 +- net/minecraft/util/datafix/schemas/V2501.java | 7 +- net/minecraft/util/datafix/schemas/V2502.java | 2 +- net/minecraft/util/datafix/schemas/V2505.java | 4 +- net/minecraft/util/datafix/schemas/V2509.java | 2 +- .../util/datafix/schemas/V2511_1.java | 22 + net/minecraft/util/datafix/schemas/V2519.java | 2 +- net/minecraft/util/datafix/schemas/V2522.java | 2 +- net/minecraft/util/datafix/schemas/V2568.java | 2 +- net/minecraft/util/datafix/schemas/V2571.java | 2 +- net/minecraft/util/datafix/schemas/V2686.java | 2 +- net/minecraft/util/datafix/schemas/V2688.java | 2 +- net/minecraft/util/datafix/schemas/V2704.java | 2 +- net/minecraft/util/datafix/schemas/V3078.java | 2 +- net/minecraft/util/datafix/schemas/V3081.java | 2 +- net/minecraft/util/datafix/schemas/V3083.java | 3 +- net/minecraft/util/datafix/schemas/V3202.java | 2 +- net/minecraft/util/datafix/schemas/V3203.java | 2 +- net/minecraft/util/datafix/schemas/V3325.java | 2 +- net/minecraft/util/datafix/schemas/V3326.java | 2 +- net/minecraft/util/datafix/schemas/V3439.java | 31 + net/minecraft/util/datafix/schemas/V3682.java | 4 +- net/minecraft/util/datafix/schemas/V3689.java | 2 +- net/minecraft/util/datafix/schemas/V3799.java | 2 +- net/minecraft/util/datafix/schemas/V3808.java | 6 +- .../util/datafix/schemas/V3808_1.java | 2 +- .../util/datafix/schemas/V3808_2.java | 2 +- net/minecraft/util/datafix/schemas/V3813.java | 24 + net/minecraft/util/datafix/schemas/V3816.java | 2 +- .../util/datafix/schemas/V3818_3.java | 14 + net/minecraft/util/datafix/schemas/V4071.java | 7 +- net/minecraft/util/datafix/schemas/V4290.java | 45 + net/minecraft/util/datafix/schemas/V4292.java | 45 + net/minecraft/util/datafix/schemas/V4300.java | 32 + net/minecraft/util/datafix/schemas/V4301.java | 39 + net/minecraft/util/datafix/schemas/V4302.java | 20 + net/minecraft/util/datafix/schemas/V4306.java | 23 + net/minecraft/util/datafix/schemas/V4307.java | 33 + net/minecraft/util/datafix/schemas/V4312.java | 36 + net/minecraft/util/datafix/schemas/V501.java | 2 +- net/minecraft/util/datafix/schemas/V700.java | 2 +- net/minecraft/util/datafix/schemas/V701.java | 8 +- net/minecraft/util/datafix/schemas/V702.java | 6 +- net/minecraft/util/datafix/schemas/V703.java | 20 +- net/minecraft/util/datafix/schemas/V704.java | 56 +- net/minecraft/util/datafix/schemas/V705.java | 81 +- net/minecraft/util/datafix/schemas/V99.java | 198 +- .../DebugSampleSubscriptionTracker.java | 9 +- .../parsing/packrat/CachedParseState.java | 228 + .../util/parsing/packrat/Control.java | 13 +- .../parsing/packrat/DelayedException.java | 18 + .../util/parsing/packrat/Dictionary.java | 91 +- .../util/parsing/packrat/ErrorCollector.java | 53 +- .../util/parsing/packrat/NamedRule.java | 7 + .../util/parsing/packrat/ParseState.java | 65 +- net/minecraft/util/parsing/packrat/Rule.java | 39 +- net/minecraft/util/parsing/packrat/Scope.java | 287 +- net/minecraft/util/parsing/packrat/Term.java | 180 +- .../commands/CommandArgumentParser.java | 52 + .../parsing/packrat/commands/Grammar.java | 30 +- .../commands/GreedyPatternParseRule.java | 32 + .../commands/GreedyPredicateParseRule.java | 47 + .../packrat/commands/NumberRunParseRule.java | 45 + .../packrat/commands/ParserBasedArgument.java | 27 + .../commands/ResourceLocationParseRule.java | 10 +- .../packrat/commands/ResourceLookupRule.java | 27 +- .../commands/StringReaderParserState.java | 9 +- .../packrat/commands/StringReaderTerms.java | 63 +- .../packrat/commands/TagParseRule.java | 20 +- .../commands/UnquotedStringParseRule.java | 31 + .../util/profiling/ActiveProfiler.java | 17 +- .../util/profiling/ContinuousProfiler.java | 9 +- .../util/profiling/SingleTickProfiler.java | 2 +- .../profiling/ActiveMetricsRecorder.java | 6 +- .../util/random/SimpleWeightedRandomList.java | 56 - net/minecraft/util/random/Weight.java | 53 - net/minecraft/util/random/Weighted.java | 43 + net/minecraft/util/random/WeightedEntry.java | 45 - net/minecraft/util/random/WeightedList.java | 187 + net/minecraft/util/random/WeightedRandom.java | 25 +- .../util/random/WeightedRandomList.java | 68 - .../util/thread/ParallelMapTransform.java | 207 + .../util/valueproviders/WeightedListInt.java | 22 +- .../util/worldupdate/WorldUpgrader.java | 35 +- net/minecraft/world/BossEvent.java | 30 +- net/minecraft/world/Clearable.java | 8 - net/minecraft/world/Container.java | 37 +- net/minecraft/world/ContainerHelper.java | 6 +- net/minecraft/world/Containers.java | 9 +- net/minecraft/world/LockCode.java | 15 +- net/minecraft/world/RandomSequences.java | 78 +- .../world/RandomizableContainer.java | 24 +- net/minecraft/world/SimpleContainer.java | 5 +- .../world/damagesource/CombatTracker.java | 7 +- .../world/damagesource/DamageEffects.java | 2 +- .../world/effect/InfestedMobEffect.java | 2 +- net/minecraft/world/effect/MobEffect.java | 24 +- .../world/effect/MobEffectInstance.java | 92 +- net/minecraft/world/effect/MobEffectUtil.java | 6 +- net/minecraft/world/effect/MobEffects.java | 22 +- .../world/effect/OozingMobEffect.java | 2 +- net/minecraft/world/entity/AgeableMob.java | 10 +- .../world/entity/AnimationState.java | 4 +- .../world/entity/AreaEffectCloud.java | 147 +- .../world/entity/ConversionType.java | 4 +- net/minecraft/world/entity/Display.java | 252 +- net/minecraft/world/entity/DropChances.java | 49 + net/minecraft/world/entity/Entity.java | 698 +- .../world/entity/EntityAttachments.java | 33 +- .../world/entity/EntityEquipment.java | 74 + net/minecraft/world/entity/EntityEvent.java | 4 +- .../world/entity/EntityReference.java | 104 + .../world/entity/EntitySelector.java | 18 +- net/minecraft/world/entity/EntityType.java | 110 +- net/minecraft/world/entity/EquipmentSlot.java | 10 +- .../world/entity/EquipmentSlotGroup.java | 18 +- .../world/entity/EquipmentTable.java | 3 +- net/minecraft/world/entity/ExperienceOrb.java | 180 +- net/minecraft/world/entity/FlyingMob.java | 46 +- net/minecraft/world/entity/GlowSquid.java | 3 +- .../entity/InsideBlockEffectApplier.java | 97 + .../world/entity/InsideBlockEffectType.java | 26 + net/minecraft/world/entity/Interaction.java | 50 +- .../world/entity/InterpolationHandler.java | 140 + .../world/entity/ItemBasedSteering.java | 21 +- net/minecraft/world/entity/Leashable.java | 54 +- net/minecraft/world/entity/LivingEntity.java | 941 +- net/minecraft/world/entity/Marker.java | 5 - net/minecraft/world/entity/Mob.java | 350 +- net/minecraft/world/entity/NeutralMob.java | 32 +- .../world/entity/OminousItemSpawner.java | 14 +- net/minecraft/world/entity/OwnableEntity.java | 32 +- .../world/entity/PositionMoveRotation.java | 15 +- net/minecraft/world/entity/Saddleable.java | 19 - .../world/entity/SpawnPlacements.java | 177 +- net/minecraft/world/entity/TamableAnimal.java | 67 +- net/minecraft/world/entity/VariantHolder.java | 7 - net/minecraft/world/entity/ai/Brain.java | 12 +- .../ai/attributes/AttributeInstance.java | 35 +- .../entity/ai/attributes/AttributeMap.java | 20 +- .../ai/attributes/AttributeModifier.java | 25 - .../ai/attributes/DefaultAttributes.java | 4 +- .../behavior/AssignProfessionFromJobSite.java | 11 +- .../entity/ai/behavior/GiveGiftToHero.java | 6 +- .../entity/ai/behavior/HarvestFarmland.java | 5 +- .../ai/behavior/LongJumpToPreferredBlock.java | 2 +- .../ai/behavior/LongJumpToRandomPos.java | 21 +- .../entity/ai/behavior/PoiCompetitorScan.java | 10 +- .../ai/behavior/PrepareRamNearestTarget.java | 3 +- .../world/entity/ai/behavior/RamTarget.java | 17 +- .../entity/ai/behavior/RandomStroll.java | 4 +- .../entity/ai/behavior/ResetProfession.java | 28 +- .../entity/ai/behavior/TradeWithVillager.java | 10 +- .../behavior/TryLaySpawnOnWaterNearLand.java | 3 +- .../ai/behavior/VillagerGoalPackages.java | 54 +- .../entity/ai/behavior/VillagerMakeLove.java | 2 +- .../entity/ai/behavior/YieldJobSite.java | 6 +- .../world/entity/ai/control/MoveControl.java | 2 +- .../world/entity/ai/goal/AvoidEntityGoal.java | 15 +- .../world/entity/ai/goal/BegGoal.java | 5 +- .../world/entity/ai/goal/EatBlockGoal.java | 11 +- .../world/entity/ai/goal/FleeSunGoal.java | 5 +- .../world/entity/ai/goal/FollowBoatGoal.java | 2 +- .../ai/goal/LandOnOwnersShoulderGoal.java | 19 +- .../world/entity/ai/goal/MeleeAttackGoal.java | 5 +- .../ai/goal/MoveThroughVillageGoal.java | 8 +- .../world/entity/ai/goal/OfferFlowerGoal.java | 5 +- .../entity/ai/goal/PathfindToRaidGoal.java | 19 +- .../world/entity/ai/goal/RemoveBlockGoal.java | 2 +- .../world/entity/ai/goal/RestrictSunGoal.java | 2 +- .../entity/ai/goal/SitWhenOrderedToGoal.java | 10 +- .../ai/goal/StrollThroughVillageGoal.java | 5 +- .../goal/WaterAvoidingRandomStrollGoal.java | 2 +- .../goal/target/DefendVillageTargetGoal.java | 8 +- .../entity/ai/gossip/GossipContainer.java | 41 +- .../entity/ai/memory/MemoryModuleType.java | 1 + .../ai/sensing/AxolotlAttackablesSensor.java | 2 +- .../world/entity/ai/sensing/PlayerSensor.java | 13 +- .../entity/ai/sensing/SecondaryPoiSensor.java | 2 +- .../world/entity/ai/village/VillageSiege.java | 16 +- net/minecraft/world/entity/ambient/Bat.java | 3 +- .../world/entity/animal/AbstractCow.java | 100 + .../world/entity/animal/AbstractFish.java | 5 +- .../entity/animal/AgeableWaterCreature.java | 2 +- net/minecraft/world/entity/animal/Animal.java | 14 +- net/minecraft/world/entity/animal/Bee.java | 43 +- .../world/entity/animal/Bucketable.java | 31 +- net/minecraft/world/entity/animal/Cat.java | 83 +- .../world/entity/animal/CatVariant.java | 59 +- .../world/entity/animal/CatVariants.java | 77 + .../world/entity/animal/Chicken.java | 90 +- .../world/entity/animal/ChickenVariant.java | 60 + .../world/entity/animal/ChickenVariants.java | 59 + net/minecraft/world/entity/animal/Cow.java | 146 +- .../world/entity/animal/CowVariant.java | 61 + .../world/entity/animal/CowVariants.java | 55 + .../world/entity/animal/Dolphin.java | 93 +- net/minecraft/world/entity/animal/Fox.java | 151 +- .../world/entity/animal/FrogVariant.java | 31 - .../world/entity/animal/IronGolem.java | 3 +- .../world/entity/animal/MushroomCow.java | 81 +- net/minecraft/world/entity/animal/Ocelot.java | 6 +- net/minecraft/world/entity/animal/Panda.java | 15 +- net/minecraft/world/entity/animal/Parrot.java | 48 +- net/minecraft/world/entity/animal/Pig.java | 100 +- .../world/entity/animal/PigVariant.java | 60 + .../world/entity/animal/PigVariants.java | 55 + .../world/entity/animal/Pufferfish.java | 6 +- net/minecraft/world/entity/animal/Rabbit.java | 60 +- net/minecraft/world/entity/animal/Salmon.java | 62 +- .../world/entity/animal/SnowGolem.java | 5 +- net/minecraft/world/entity/animal/Squid.java | 13 +- .../entity/animal/TemperatureVariants.java | 9 + .../world/entity/animal/TropicalFish.java | 118 +- net/minecraft/world/entity/animal/Turtle.java | 147 +- .../world/entity/animal/WaterAnimal.java | 10 +- .../world/entity/animal/WolfVariant.java | 99 - .../world/entity/animal/allay/Allay.java | 90 +- .../entity/animal/armadillo/Armadillo.java | 18 +- .../world/entity/animal/axolotl/Axolotl.java | 78 +- .../entity/animal/axolotl/AxolotlAi.java | 10 +- .../world/entity/animal/axolotl/PlayDead.java | 4 +- .../world/entity/animal/camel/Camel.java | 22 +- .../world/entity/animal/frog/Frog.java | 72 +- .../world/entity/animal/frog/FrogAi.java | 2 +- .../world/entity/animal/frog/FrogVariant.java | 40 + .../entity/animal/frog/FrogVariants.java | 50 + .../world/entity/animal/frog/Tadpole.java | 12 +- .../world/entity/animal/frog/TadpoleAi.java | 10 +- .../world/entity/animal/goat/Goat.java | 14 +- .../world/entity/animal/goat/GoatAi.java | 2 +- .../animal/horse/AbstractChestedHorse.java | 19 +- .../entity/animal/horse/AbstractHorse.java | 172 +- .../world/entity/animal/horse/Horse.java | 33 +- .../world/entity/animal/horse/Llama.java | 78 +- .../entity/animal/horse/SkeletonHorse.java | 10 +- .../entity/animal/horse/SkeletonTrapGoal.java | 2 +- .../entity/animal/horse/TraderLlama.java | 9 +- .../world/entity/animal/horse/Variant.java | 4 + .../entity/animal/{ => sheep}/Sheep.java | 93 +- .../animal/sheep/SheepColorSpawnRules.java | 85 + .../entity/animal/sheep/package-info.java | 8 + .../world/entity/animal/sniffer/Sniffer.java | 3 +- .../world/entity/animal/{ => wolf}/Wolf.java | 147 +- .../entity/animal/wolf/WolfSoundVariant.java | 39 + .../entity/animal/wolf/WolfSoundVariants.java | 68 + .../world/entity/animal/wolf/WolfVariant.java | 51 + .../animal/{ => wolf}/WolfVariants.java | 43 +- .../entity/animal/wolf/package-info.java | 8 + .../entity/boss/enderdragon/EndCrystal.java | 13 +- .../entity/boss/enderdragon/EnderDragon.java | 36 +- .../phases/DragonSittingFlamingPhase.java | 3 +- .../phases/DragonStrafePlayerPhase.java | 2 +- .../world/entity/boss/wither/WitherBoss.java | 10 +- .../world/entity/decoration/ArmorStand.java | 150 +- .../decoration/BlockAttachedEntity.java | 13 +- .../world/entity/decoration/ItemFrame.java | 48 +- .../world/entity/decoration/Painting.java | 54 +- .../world/entity/item/FallingBlockEntity.java | 71 +- .../world/entity/item/ItemEntity.java | 54 +- .../world/entity/item/PrimedTnt.java | 52 +- .../entity/monster/AbstractSkeleton.java | 8 +- .../world/entity/monster/Bogged.java | 5 +- .../world/entity/monster/Creeper.java | 32 +- .../world/entity/monster/Drowned.java | 16 +- .../world/entity/monster/ElderGuardian.java | 8 +- .../world/entity/monster/EnderMan.java | 54 +- .../world/entity/monster/Endermite.java | 5 +- .../world/entity/monster/Evoker.java | 46 +- net/minecraft/world/entity/monster/Ghast.java | 5 +- .../world/entity/monster/Guardian.java | 16 +- .../entity/monster/PatrollingMonster.java | 18 +- .../world/entity/monster/Phantom.java | 34 +- .../world/entity/monster/Ravager.java | 25 +- .../world/entity/monster/Shulker.java | 67 +- .../world/entity/monster/Skeleton.java | 8 +- net/minecraft/world/entity/monster/Slime.java | 16 +- .../entity/monster/SpellcasterIllager.java | 5 +- .../world/entity/monster/Spider.java | 6 +- net/minecraft/world/entity/monster/Stray.java | 2 +- .../world/entity/monster/Strider.java | 82 +- net/minecraft/world/entity/monster/Vex.java | 18 +- .../world/entity/monster/Vindicator.java | 7 +- net/minecraft/world/entity/monster/Witch.java | 18 +- .../world/entity/monster/Zoglin.java | 16 +- .../world/entity/monster/Zombie.java | 31 +- .../world/entity/monster/ZombieVillager.java | 125 +- .../world/entity/monster/ZombifiedPiglin.java | 8 - .../world/entity/monster/breeze/Breeze.java | 9 +- .../world/entity/monster/breeze/LongJump.java | 2 +- .../entity/monster/creaking/Creaking.java | 24 +- .../entity/monster/creaking/CreakingAi.java | 27 +- .../world/entity/monster/hoglin/Hoglin.java | 31 +- .../entity/monster/piglin/AbstractPiglin.java | 19 +- .../world/entity/monster/piglin/Piglin.java | 30 +- .../world/entity/monster/piglin/PiglinAi.java | 10 +- .../entity/monster/piglin/PiglinBrute.java | 3 +- .../StopHoldingItemIfNoLongerAdmiring.java | 4 +- .../world/entity/monster/warden/Warden.java | 57 +- .../monster/warden/WardenSpawnTracker.java | 4 + .../world/entity/npc/AbstractVillager.java | 17 +- .../world/entity/npc/CatSpawner.java | 65 +- .../world/entity/npc/InventoryCarrier.java | 4 +- net/minecraft/world/entity/npc/Villager.java | 201 +- .../world/entity/npc/VillagerData.java | 59 +- .../world/entity/npc/VillagerDataHolder.java | 12 +- .../world/entity/npc/VillagerProfession.java | 123 +- .../world/entity/npc/VillagerTrades.java | 589 +- .../world/entity/npc/VillagerType.java | 110 +- .../world/entity/npc/WanderingTrader.java | 49 +- .../entity/npc/WanderingTraderSpawner.java | 46 +- .../world/entity/player/Abilities.java | 30 +- .../world/entity/player/Inventory.java | 268 +- net/minecraft/world/entity/player/Player.java | 410 +- .../world/entity/player/PlayerEquipment.java | 28 + .../entity/projectile/AbstractArrow.java | 114 +- .../projectile/AbstractHurtingProjectile.java | 6 +- ...nPotion.java => AbstractThrownPotion.java} | 90 +- .../world/entity/projectile/Arrow.java | 26 +- .../entity/projectile/DragonFireball.java | 3 +- .../world/entity/projectile/EvokerFangs.java | 14 +- .../world/entity/projectile/EyeOfEnder.java | 15 +- .../world/entity/projectile/Fireball.java | 13 +- .../projectile/FireworkRocketEntity.java | 36 +- .../world/entity/projectile/FishingHook.java | 11 +- .../entity/projectile/LargeFireball.java | 5 +- .../world/entity/projectile/LlamaSpit.java | 2 +- .../world/entity/projectile/Projectile.java | 48 +- .../entity/projectile/ShulkerBullet.java | 51 +- .../entity/projectile/SpectralArrow.java | 5 +- .../projectile/ThrowableItemProjectile.java | 13 +- .../projectile/ThrowableProjectile.java | 3 +- .../world/entity/projectile/ThrownEgg.java | 7 +- .../entity/projectile/ThrownEnderpearl.java | 18 +- .../projectile/ThrownExperienceBottle.java | 2 +- .../projectile/ThrownLingeringPotion.java | 47 + .../entity/projectile/ThrownSplashPotion.java | 78 + .../entity/projectile/ThrownTrident.java | 5 +- .../world/entity/projectile/WitherSkull.java | 3 +- net/minecraft/world/entity/raid/Raid.java | 302 +- net/minecraft/world/entity/raid/Raider.java | 51 +- net/minecraft/world/entity/raid/Raids.java | 189 +- .../world/entity/variant/BiomeCheck.java | 24 + .../world/entity/variant/ModelAndTexture.java | 28 + .../entity/variant/MoonBrightnessCheck.java | 20 + .../entity/variant/PriorityProvider.java | 105 + .../world/entity/variant/SpawnCondition.java | 11 + .../world/entity/variant/SpawnConditions.java | 12 + .../world/entity/variant/SpawnContext.java | 13 + .../variant/SpawnPrioritySelectors.java | 19 + .../world/entity/variant/StructureCheck.java | 24 + .../world/entity/variant/VariantUtils.java | 30 + .../world/entity/variant/package-info.java | 8 + .../world/entity/vehicle/AbstractBoat.java | 115 +- .../entity/vehicle/AbstractMinecart.java | 159 +- .../world/entity/vehicle/ContainerEntity.java | 14 +- .../entity/vehicle/MinecartBehavior.java | 30 +- .../world/entity/vehicle/MinecartFurnace.java | 12 +- .../world/entity/vehicle/MinecartHopper.java | 3 +- .../world/entity/vehicle/MinecartTNT.java | 96 +- .../entity/vehicle/OldMinecartBehavior.java | 56 +- net/minecraft/world/food/FoodData.java | 12 +- .../inventory/AbstractContainerMenu.java | 58 +- net/minecraft/world/inventory/AnvilMenu.java | 9 +- net/minecraft/world/inventory/ArmorSlot.java | 7 +- .../world/inventory/CartographyTableMenu.java | 4 +- net/minecraft/world/inventory/ClickType.java | 33 +- .../inventory/ContainerSynchronizer.java | 6 +- .../world/inventory/CraftingMenu.java | 2 +- .../world/inventory/EnchantmentMenu.java | 8 +- .../world/inventory/FurnaceResultSlot.java | 2 +- .../world/inventory/HorseInventoryMenu.java | 58 +- net/minecraft/world/inventory/LoomMenu.java | 16 +- .../world/inventory/MerchantResultSlot.java | 2 +- .../inventory/PlayerEnderChestContainer.java | 4 +- net/minecraft/world/inventory/RemoteSlot.java | 70 + net/minecraft/world/inventory/ResultSlot.java | 2 +- net/minecraft/world/inventory/SlotRanges.java | 2 +- .../world/inventory/SmithingMenu.java | 2 +- .../world/inventory/StonecutterMenu.java | 4 +- .../world/item/AdventureModePredicate.java | 42 +- net/minecraft/world/item/AirItem.java | 10 - net/minecraft/world/item/AnimalArmorItem.java | 42 - net/minecraft/world/item/ArmorItem.java | 10 - net/minecraft/world/item/ArmorStandItem.java | 2 +- net/minecraft/world/item/AxeItem.java | 12 +- net/minecraft/world/item/BannerItem.java | 21 - .../world/item/BannerPatternItem.java | 17 - net/minecraft/world/item/BlockItem.java | 11 +- net/minecraft/world/item/BoneMealItem.java | 3 +- net/minecraft/world/item/BucketItem.java | 21 +- net/minecraft/world/item/BundleItem.java | 17 +- net/minecraft/world/item/CompassItem.java | 16 +- .../world/item/CreativeModeTabs.java | 51 +- net/minecraft/world/item/CrossbowItem.java | 63 +- net/minecraft/world/item/DebugStickItem.java | 8 +- net/minecraft/world/item/DiggerItem.java | 22 - .../world/item/DiscFragmentItem.java | 7 +- .../world/item/DispensibleContainerItem.java | 6 +- net/minecraft/world/item/DyeColor.java | 6 +- net/minecraft/world/item/DyeItem.java | 2 +- net/minecraft/world/item/EggItem.java | 4 +- net/minecraft/world/item/EitherHolder.java | 26 +- net/minecraft/world/item/EmptyMapItem.java | 11 +- net/minecraft/world/item/EnderEyeItem.java | 4 +- .../world/item/FireworkRocketItem.java | 12 - .../world/item/FireworkStarItem.java | 20 - .../world/item/HangingEntityItem.java | 42 +- net/minecraft/world/item/HoeItem.java | 5 +- net/minecraft/world/item/InstrumentItem.java | 52 +- net/minecraft/world/item/Item.java | 153 +- .../world/item/ItemDisplayContext.java | 4 + net/minecraft/world/item/ItemStack.java | 284 +- net/minecraft/world/item/Items.java | 243 +- net/minecraft/world/item/JukeboxPlayable.java | 28 +- .../world/item/LingeringPotionItem.java | 25 +- net/minecraft/world/item/MaceItem.java | 60 +- net/minecraft/world/item/MapItem.java | 82 +- net/minecraft/world/item/MobBucketItem.java | 52 +- net/minecraft/world/item/NameTagItem.java | 2 +- net/minecraft/world/item/PickaxeItem.java | 9 - net/minecraft/world/item/PotionItem.java | 9 - net/minecraft/world/item/SaddleItem.java | 29 - net/minecraft/world/item/ShearsItem.java | 34 +- net/minecraft/world/item/ShieldItem.java | 30 - net/minecraft/world/item/ShovelItem.java | 5 +- .../world/item/SmithingTemplateItem.java | 17 +- net/minecraft/world/item/SolidBucketItem.java | 7 +- net/minecraft/world/item/SpawnEggItem.java | 10 +- .../world/item/SplashPotionItem.java | 15 + net/minecraft/world/item/SwordItem.java | 29 - .../world/item/ThrowablePotionItem.java | 13 +- net/minecraft/world/item/TippedArrowItem.java | 9 - net/minecraft/world/item/ToolMaterial.java | 18 +- net/minecraft/world/item/TridentItem.java | 30 +- net/minecraft/world/item/WrittenBookItem.java | 35 - .../world/item/alchemy/PotionContents.java | 47 +- net/minecraft/world/item/alchemy/Potions.java | 47 +- net/minecraft/world/item/component/Bees.java | 25 + .../component/BlockItemStateProperties.java | 17 +- .../world/item/component/BlocksAttacks.java | 182 + .../world/item/component/BundleContents.java | 10 +- .../item/component/ChargedProjectiles.java | 48 +- .../world/item/component/Consumable.java | 4 +- .../world/item/component/Consumables.java | 9 +- .../world/item/component/CustomData.java | 23 +- .../world/item/component/DyedItemColor.java | 36 +- .../item/component/FireworkExplosion.java | 9 +- .../world/item/component/Fireworks.java | 35 +- .../item/component/InstrumentComponent.java | 56 + .../component/ItemAttributeModifiers.java | 31 +- .../item/component/ItemContainerContents.java | 26 +- .../world/item/component/ItemLore.java | 5 +- .../component/OminousBottleAmplifier.java | 3 +- .../item/component/ProvidesTrimMaterial.java | 34 + .../item/component/SeededContainerLoot.java | 16 +- .../item/component/SuspiciousStewEffects.java | 5 +- net/minecraft/world/item/component/Tool.java | 7 +- .../world/item/component/TooltipDisplay.java | 52 + .../world/item/component/TooltipProvider.java | 3 +- .../world/item/component/Unbreakable.java | 31 - .../world/item/component/Weapon.java | 26 + .../item/component/WrittenBookContent.java | 49 +- .../PlaySoundConsumeEffect.java | 5 +- .../TeleportRandomlyConsumeEffect.java | 5 +- .../item/crafting/BookCloningRecipe.java | 13 +- net/minecraft/world/item/crafting/Recipe.java | 2 + .../world/item/crafting/RecipeManager.java | 12 +- .../item/crafting/RecipePropertySet.java | 3 +- .../world/item/crafting/SingleItemRecipe.java | 4 +- .../world/item/crafting/SmithingRecipe.java | 4 +- .../crafting/SmithingTransformRecipe.java | 35 +- .../item/crafting/SmithingTrimRecipe.java | 66 +- .../world/item/crafting/TransmuteRecipe.java | 35 +- .../world/item/crafting/TransmuteResult.java | 61 + .../item/crafting/display/SlotDisplay.java | 33 +- .../item/enchantment/EnchantmentHelper.java | 15 +- .../item/enchantment/EnchantmentInstance.java | 18 +- .../world/item/enchantment/Enchantments.java | 142 +- .../item/enchantment/ItemEnchantments.java | 71 +- .../effects/SetBlockProperties.java | 2 +- .../effects/SummonEntityEffect.java | 2 +- .../providers/EnchantmentsByCost.java | 2 +- .../EnchantmentsByCostWithDifficulty.java | 2 +- .../equipment/AllowedEntitiesProvider.java | 10 + .../world/item/equipment/ArmorMaterial.java | 57 +- .../world/item/equipment/ArmorMaterials.java | 90 +- .../world/item/equipment/EquipmentAssets.java | 1 + .../world/item/equipment/Equippable.java | 60 +- .../world/item/equipment/trim/ArmorTrim.java | 42 +- .../equipment/trim/MaterialAssetGroup.java | 74 + .../item/equipment/trim/TrimMaterial.java | 31 +- .../item/equipment/trim/TrimMaterials.java | 62 +- .../item/equipment/trim/TrimPattern.java | 6 +- .../item/equipment/trim/TrimPatterns.java | 60 +- .../world/item/trading/ItemCost.java | 33 +- .../world/level/BaseCommandBlock.java | 50 +- net/minecraft/world/level/BaseSpawner.java | 110 +- .../world/level/BlockCollisions.java | 4 +- net/minecraft/world/level/BlockGetter.java | 64 +- .../world/level/CollisionGetter.java | 2 +- .../world/level/ColorMapColorUtil.java | 11 + .../world/level/CommonLevelAccessor.java | 4 +- net/minecraft/world/level/CustomSpawner.java | 2 +- .../world/level/DryFoliageColor.java | 14 + net/minecraft/world/level/FoliageColor.java | 6 +- .../world/level/ForcedChunksSavedData.java | 40 - net/minecraft/world/level/GameRules.java | 38 +- net/minecraft/world/level/GameType.java | 3 + net/minecraft/world/level/GrassColor.java | 6 +- net/minecraft/world/level/Level.java | 113 +- net/minecraft/world/level/LevelAccessor.java | 14 +- net/minecraft/world/level/LevelReader.java | 4 + net/minecraft/world/level/NaturalSpawner.java | 74 +- net/minecraft/world/level/SpawnData.java | 16 +- net/minecraft/world/level/Spawner.java | 45 +- net/minecraft/world/level/TicketStorage.java | 375 + .../world/level/WorldDataConfiguration.java | 4 +- net/minecraft/world/level/biome/Biome.java | 22 +- .../world/level/biome/BiomeSource.java | 13 +- .../level/biome/BiomeSpecialEffects.java | 35 +- .../biome/CheckerboardColumnBiomeSource.java | 3 +- .../world/level/biome/FixedBiomeSource.java | 9 +- .../world/level/biome/MobSpawnSettings.java | 58 +- .../level/biome/MultiNoiseBiomeSource.java | 21 +- .../level/biome/OverworldBiomeBuilder.java | 11 +- .../world/level/biome/TheEndBiomeSource.java | 7 +- .../level/block/AbstractCauldronBlock.java | 24 +- .../level/block/AbstractFurnaceBlock.java | 18 +- .../level/block/AmethystClusterBlock.java | 39 +- .../world/level/block/AnvilBlock.java | 16 +- .../world/level/block/AttachedStemBlock.java | 21 +- .../world/level/block/AzaleaBlock.java | 4 +- .../world/level/block/BambooSaplingBlock.java | 14 +- .../world/level/block/BambooStalkBlock.java | 25 +- .../world/level/block/BannerBlock.java | 2 +- .../world/level/block/BarrelBlock.java | 5 +- .../world/level/block/BarrierBlock.java | 9 +- .../world/level/block/BaseCoralFanBlock.java | 4 +- .../level/block/BaseCoralPlantBlock.java | 3 +- .../level/block/BaseCoralPlantTypeBlock.java | 4 +- .../level/block/BaseCoralWallFanBlock.java | 16 +- .../world/level/block/BaseFireBlock.java | 27 +- .../level/block/BasePressurePlateBlock.java | 21 +- .../world/level/block/BaseRailBlock.java | 11 +- .../world/level/block/BaseTorchBlock.java | 5 +- net/minecraft/world/level/block/BedBlock.java | 40 +- .../world/level/block/BeehiveBlock.java | 33 +- .../world/level/block/BeetrootBlock.java | 9 +- .../world/level/block/BellBlock.java | 57 +- .../world/level/block/BigDripleafBlock.java | 56 +- .../level/block/BigDripleafStemBlock.java | 20 +- .../world/level/block/BlastFurnaceBlock.java | 7 +- net/minecraft/world/level/block/Block.java | 82 +- .../world/level/block/BlockTypes.java | 18 +- net/minecraft/world/level/block/Blocks.java | 273 +- .../world/level/block/BonemealableBlock.java | 22 + .../block/BonemealableFeaturePlacerBlock.java | 5 +- .../world/level/block/BrewingStandBlock.java | 8 +- .../world/level/block/BubbleColumnBlock.java | 24 +- .../world/level/block/BucketPickup.java | 4 +- .../world/level/block/BushBlock.java | 53 +- .../world/level/block/ButtonBlock.java | 77 +- .../world/level/block/CactusBlock.java | 46 +- ...dBushBlock.java => CactusFlowerBlock.java} | 16 +- .../world/level/block/CakeBlock.java | 14 +- .../block/CalibratedSculkSensorBlock.java | 4 +- .../world/level/block/CampfireBlock.java | 29 +- .../world/level/block/CandleBlock.java | 48 +- .../world/level/block/CandleCakeBlock.java | 9 +- .../world/level/block/CarpetBlock.java | 2 +- .../world/level/block/CarrotBlock.java | 13 +- .../world/level/block/CarvedPumpkinBlock.java | 8 +- .../world/level/block/CaveVines.java | 2 +- .../level/block/CeilingHangingSignBlock.java | 27 +- .../world/level/block/ChainBlock.java | 18 +- .../world/level/block/ChestBlock.java | 35 +- .../level/block/ChiseledBookShelfBlock.java | 25 +- .../world/level/block/ChorusFlowerBlock.java | 13 +- .../world/level/block/ChorusPlantBlock.java | 2 +- .../world/level/block/CocoaBlock.java | 41 +- .../level/block/ColoredFallingBlock.java | 4 +- .../world/level/block/ComposterBlock.java | 38 +- .../world/level/block/ConduitBlock.java | 3 +- .../world/level/block/CoralPlantBlock.java | 3 +- .../world/level/block/CrafterBlock.java | 5 +- .../world/level/block/CreakingHeartBlock.java | 52 +- .../world/level/block/CropBlock.java | 27 +- .../level/block/CrossCollisionBlock.java | 97 +- .../level/block/DaylightDetectorBlock.java | 2 +- .../world/level/block/DecoratedPotBlock.java | 38 +- .../world/level/block/DetectorRailBlock.java | 3 +- .../world/level/block/DiodeBlock.java | 7 +- .../world/level/block/DirtPathBlock.java | 2 +- .../world/level/block/DispenserBlock.java | 5 +- .../world/level/block/DoorBlock.java | 32 +- .../world/level/block/DoublePlantBlock.java | 4 +- .../world/level/block/DragonEggBlock.java | 7 +- .../world/level/block/DryVegetationBlock.java | 55 + .../level/block/EnchantingTableBlock.java | 2 +- .../world/level/block/EndGatewayBlock.java | 3 +- .../world/level/block/EndPortalBlock.java | 7 +- .../level/block/EndPortalFrameBlock.java | 7 +- .../world/level/block/EndRodBlock.java | 4 +- .../world/level/block/EnderChestBlock.java | 2 +- .../world/level/block/EyeblossomBlock.java | 9 +- .../world/level/block/FallingBlock.java | 4 +- .../world/level/block/FarmBlock.java | 6 +- .../world/level/block/FenceBlock.java | 9 +- .../world/level/block/FenceGateBlock.java | 56 +- .../world/level/block/FireBlock.java | 172 +- .../world/level/block/FireflyBushBlock.java | 61 + ...nkPetalsBlock.java => FlowerBedBlock.java} | 59 +- .../world/level/block/FlowerBlock.java | 12 +- .../world/level/block/FlowerPotBlock.java | 3 +- .../world/level/block/FrogspawnBlock.java | 7 +- .../world/level/block/FungusBlock.java | 4 +- .../world/level/block/FurnaceBlock.java | 7 +- .../world/level/block/GrassBlock.java | 8 +- .../world/level/block/GrindstoneBlock.java | 107 +- .../level/block/GrowingPlantHeadBlock.java | 11 +- .../world/level/block/HangingMossBlock.java | 9 +- .../world/level/block/HangingRootsBlock.java | 2 +- net/minecraft/world/level/block/HayBlock.java | 2 +- .../world/level/block/HeavyCoreBlock.java | 2 +- .../world/level/block/HoneyBlock.java | 9 +- .../world/level/block/HopperBlock.java | 79 +- .../world/level/block/InfestedBlock.java | 2 +- .../block/InfestedRotatedPillarBlock.java | 4 +- .../world/level/block/IronBarsBlock.java | 2 +- .../world/level/block/JigsawBlock.java | 7 +- .../world/level/block/JukeboxBlock.java | 12 +- .../world/level/block/KelpBlock.java | 6 +- .../world/level/block/KelpPlantBlock.java | 4 +- .../world/level/block/LadderBlock.java | 20 +- .../world/level/block/LanternBlock.java | 9 +- .../world/level/block/LavaCauldronBlock.java | 4 +- .../level/block/LayeredCauldronBlock.java | 3 +- .../world/level/block/LeafLitterBlock.java | 73 + .../world/level/block/LeavesBlock.java | 33 +- .../world/level/block/LecternBlock.java | 76 +- .../world/level/block/LeverBlock.java | 66 +- .../world/level/block/LightningRodBlock.java | 10 +- .../world/level/block/LiquidBlock.java | 10 +- .../level/block/LiquidBlockContainer.java | 4 +- .../level/block/MangroveLeavesBlock.java | 16 +- .../level/block/MangrovePropaguleBlock.java | 21 +- .../world/level/block/MangroveRootsBlock.java | 3 +- net/minecraft/world/level/block/Mirror.java | 3 + .../world/level/block/MossyCarpetBlock.java | 100 +- net/minecraft/world/level/block/MudBlock.java | 2 +- .../world/level/block/MultifaceBlock.java | 62 +- .../world/level/block/MushroomBlock.java | 5 +- .../world/level/block/NetherPortalBlock.java | 62 +- .../world/level/block/NetherSproutsBlock.java | 4 +- .../world/level/block/NetherWartBlock.java | 11 +- .../world/level/block/NetherrackBlock.java | 5 +- .../world/level/block/NoteBlock.java | 3 +- .../world/level/block/NyliumBlock.java | 5 +- .../world/level/block/ObserverBlock.java | 8 +- .../level/block/ParticleLeavesBlock.java | 50 - .../level/block/PiglinWallSkullBlock.java | 17 +- .../world/level/block/PipeBlock.java | 70 +- .../world/level/block/PitcherCropBlock.java | 45 +- .../level/block/PointedDripstoneBlock.java | 62 +- .../world/level/block/PotatoBlock.java | 13 +- .../world/level/block/PowderSnowBlock.java | 40 +- .../world/level/block/PumpkinBlock.java | 3 +- .../world/level/block/RedStoneOreBlock.java | 9 +- .../world/level/block/RedStoneWireBlock.java | 106 +- .../world/level/block/RedstoneTorchBlock.java | 2 +- .../world/level/block/RespawnAnchorBlock.java | 13 +- net/minecraft/world/level/block/RodBlock.java | 18 +- .../world/level/block/RootsBlock.java | 5 +- .../world/level/block/RotatedPillarBlock.java | 12 +- net/minecraft/world/level/block/Rotation.java | 30 +- .../world/level/block/SandBlock.java | 32 + .../world/level/block/SaplingBlock.java | 7 +- .../world/level/block/ScaffoldingBlock.java | 42 +- .../world/level/block/SculkBlock.java | 5 +- .../world/level/block/SculkSensorBlock.java | 14 +- .../world/level/block/SculkShriekerBlock.java | 22 +- .../world/level/block/SculkSpreader.java | 26 +- .../world/level/block/SculkVeinBlock.java | 5 +- .../world/level/block/SeaPickleBlock.java | 27 +- .../world/level/block/SeagrassBlock.java | 9 +- .../world/level/block/SegmentableBlock.java | 53 + .../world/level/block/ShortDryGrassBlock.java | 47 + .../world/level/block/ShulkerBoxBlock.java | 63 +- .../world/level/block/SignBlock.java | 3 +- .../level/block/SimpleWaterloggedBlock.java | 6 +- .../world/level/block/SkullBlock.java | 6 +- .../world/level/block/SlabBlock.java | 24 +- .../world/level/block/SlimeBlock.java | 2 +- .../world/level/block/SmallDripleafBlock.java | 3 +- .../world/level/block/SnifferEggBlock.java | 4 +- .../world/level/block/SnowLayerBlock.java | 32 +- .../world/level/block/SoulSandBlock.java | 2 +- .../world/level/block/SoundType.java | 15 + .../world/level/block/SpawnerBlock.java | 11 - .../world/level/block/SporeBlossomBlock.java | 2 +- .../world/level/block/StairBlock.java | 102 +- .../world/level/block/StemBlock.java | 19 +- .../world/level/block/StonecutterBlock.java | 2 +- .../world/level/block/StructureVoidBlock.java | 3 +- .../world/level/block/SugarCaneBlock.java | 10 +- .../world/level/block/SupportType.java | 6 +- .../level/block/SweetBerryBushBlock.java | 22 +- .../world/level/block/TallDryGrassBlock.java | 48 + .../world/level/block/TallGrassBlock.java | 5 +- .../world/level/block/TallSeagrassBlock.java | 7 +- .../world/level/block/TargetBlock.java | 7 +- .../world/level/block/TerracottaBlock.java | 27 + .../world/level/block/TestBlock.java | 135 + .../world/level/block/TestInstanceBlock.java | 49 + .../block/TintedParticleLeavesBlock.java | 37 + net/minecraft/world/level/block/TntBlock.java | 59 +- .../level/block/TorchflowerCropBlock.java | 7 +- .../world/level/block/TrapDoorBlock.java | 26 +- .../world/level/block/TrialSpawnerBlock.java | 12 - .../world/level/block/TripWireBlock.java | 17 +- .../world/level/block/TripWireHookBlock.java | 26 +- .../world/level/block/TurtleEggBlock.java | 14 +- .../world/level/block/TwistingVinesBlock.java | 2 +- .../level/block/TwistingVinesPlantBlock.java | 2 +- .../block/UntintedParticleLeavesBlock.java | 39 + .../world/level/block/VegetationBlock.java | 58 + .../world/level/block/VineBlock.java | 63 +- .../world/level/block/WallBannerBlock.java | 16 +- .../world/level/block/WallBlock.java | 180 +- .../level/block/WallHangingSignBlock.java | 21 +- .../world/level/block/WallSignBlock.java | 24 +- .../world/level/block/WallSkullBlock.java | 18 +- .../world/level/block/WallTorchBlock.java | 19 +- .../world/level/block/WaterlilyBlock.java | 11 +- .../block/WeatheringCopperFullBlock.java | 9 +- net/minecraft/world/level/block/WebBlock.java | 3 +- .../world/level/block/WeepingVinesBlock.java | 2 +- .../level/block/WeepingVinesPlantBlock.java | 2 +- .../world/level/block/WetSpongeBlock.java | 3 +- .../world/level/block/WitherRoseBlock.java | 3 +- .../world/level/block/WitherSkullBlock.java | 2 +- .../entity/AbstractFurnaceBlockEntity.java | 42 +- .../level/block/entity/BannerBlockEntity.java | 48 +- .../block/entity/BannerPatternLayers.java | 18 +- .../level/block/entity/BarrelBlockEntity.java | 6 +- .../entity/BaseContainerBlockEntity.java | 30 +- .../level/block/entity/BeaconBeamOwner.java | 29 + .../level/block/entity/BeaconBlockEntity.java | 113 +- .../block/entity/BeehiveBlockEntity.java | 52 +- .../world/level/block/entity/BlockEntity.java | 159 +- .../level/block/entity/BlockEntityType.java | 5 +- .../block/entity/BoundingBoxRenderable.java | 25 + .../block/entity/BrewingStandBlockEntity.java | 12 +- .../block/entity/BrushableBlockEntity.java | 69 +- .../CalibratedSculkSensorBlockEntity.java | 3 +- .../block/entity/CampfireBlockEntity.java | 40 +- .../level/block/entity/ChestBlockEntity.java | 6 +- .../entity/ChiseledBookShelfBlockEntity.java | 20 +- .../block/entity/CommandBlockEntity.java | 32 +- .../block/entity/ComparatorBlockEntity.java | 11 +- .../block/entity/ConduitBlockEntity.java | 17 +- .../block/entity/CrafterBlockEntity.java | 27 +- .../entity/CreakingHeartBlockEntity.java | 90 +- .../block/entity/DecoratedPotBlockEntity.java | 46 +- .../block/entity/DispenserBlockEntity.java | 6 +- .../entity/EnchantingTableBlockEntity.java | 26 +- .../world/level/block/entity/FuelValues.java | 3 + .../world/level/block/entity/Hopper.java | 2 +- .../level/block/entity/HopperBlockEntity.java | 9 +- .../level/block/entity/JigsawBlockEntity.java | 51 +- .../block/entity/JukeboxBlockEntity.java | 40 +- .../block/entity/LecternBlockEntity.java | 40 +- .../level/block/entity/PotDecorations.java | 38 +- .../RandomizableContainerBlockEntity.java | 11 +- .../entity/SculkCatalystBlockEntity.java | 5 +- .../block/entity/SculkSensorBlockEntity.java | 66 +- .../entity/SculkShriekerBlockEntity.java | 58 +- .../block/entity/ShulkerBoxBlockEntity.java | 14 +- .../level/block/entity/SignBlockEntity.java | 45 +- .../world/level/block/entity/SignText.java | 4 +- .../level/block/entity/SkullBlockEntity.java | 61 +- .../block/entity/SpawnerBlockEntity.java | 10 +- .../block/entity/StructureBlockEntity.java | 225 +- .../level/block/entity/TestBlockEntity.java | 126 + .../block/entity/TestInstanceBlockEntity.java | 455 + .../entity/TheEndGatewayBlockEntity.java | 26 +- .../block/entity/TheEndPortalBlockEntity.java | 3 +- .../block/entity/TrialSpawnerBlockEntity.java | 34 +- .../entity/trialspawner/PlayerDetector.java | 36 +- .../entity/trialspawner/TrialSpawner.java | 98 +- .../trialspawner/TrialSpawnerConfig.java | 26 +- .../trialspawner/TrialSpawnerConfigs.java | 88 +- .../entity/trialspawner/TrialSpawnerData.java | 31 +- .../trialspawner/TrialSpawnerState.java | 11 +- .../block/entity/vault/VaultBlockEntity.java | 45 +- .../level/block/entity/vault/VaultConfig.java | 5 +- .../world/level/block/grower/TreeGrower.java | 20 +- .../level/block/piston/MovingPistonBlock.java | 10 - .../level/block/piston/PistonBaseBlock.java | 51 +- .../level/block/piston/PistonHeadBlock.java | 68 +- .../block/piston/PistonMovingBlockEntity.java | 59 +- .../AmbientDesertBlockSoundsPlayer.java | 54 + .../level/block/state/BlockBehaviour.java | 32 +- .../world/level/block/state/StateHolder.java | 12 +- .../block/state/properties/BlockSetType.java | 2 +- .../properties/BlockStateProperties.java | 13 +- .../state/properties/CreakingHeartState.java | 24 + .../block/state/properties/StructureMode.java | 4 + .../block/state/properties/TestBlockMode.java | 46 + .../world/level/border/WorldBorder.java | 16 + .../world/level/chunk/ChunkAccess.java | 26 +- .../world/level/chunk/ChunkGenerator.java | 21 +- .../world/level/chunk/ChunkSource.java | 8 +- .../world/level/chunk/EmptyLevelChunk.java | 2 +- .../world/level/chunk/ImposterProtoChunk.java | 23 +- .../world/level/chunk/LevelChunk.java | 65 +- .../world/level/chunk/PalettedContainer.java | 15 +- .../world/level/chunk/ProtoChunk.java | 17 +- .../world/level/chunk/UpgradeData.java | 56 +- .../world/level/chunk/status/ChunkStatus.java | 2 + .../level/chunk/storage/ChunkStorage.java | 2 +- .../level/chunk/storage/EntityStorage.java | 16 +- .../world/level/chunk/storage/IOWorker.java | 6 +- .../chunk/storage/SerializableChunkData.java | 197 +- .../level/dimension/end/EndDragonFight.java | 14 +- .../world/level/entity/EntityAccess.java | 5 +- .../PersistentEntitySectionManager.java | 4 + .../world/level/entity/UUIDLookup.java | 7 + .../level/entity/UniquelyIdentifyable.java | 9 + .../gameevent/vibrations/VibrationSystem.java | 20 +- .../level/levelgen/BelowZeroRetrogen.java | 12 +- .../level/levelgen/DebugLevelSource.java | 3 +- .../world/level/levelgen/DensityFunction.java | 25 +- .../level/levelgen/DensityFunctions.java | 368 +- .../world/level/levelgen/FlatLevelSource.java | 9 +- .../world/level/levelgen/Heightmap.java | 25 +- .../levelgen/NoiseBasedChunkGenerator.java | 21 +- .../world/level/levelgen/NoiseChunk.java | 79 +- .../world/level/levelgen/PatrolSpawner.java | 90 +- .../world/level/levelgen/PhantomSpawner.java | 73 +- .../world/level/levelgen/RandomState.java | 29 +- .../world/level/levelgen/SurfaceSystem.java | 19 +- .../UnobstructedPredicate.java | 2 +- .../levelgen/carver/CaveWorldCarver.java | 7 +- .../levelgen/carver/NetherWorldCarver.java | 2 +- .../level/levelgen/carver/WorldCarver.java | 4 +- .../feature/AbstractHugeMushroomFeature.java | 11 +- .../levelgen/feature/BlockColumnFeature.java | 5 +- .../levelgen/feature/BlockPileFeature.java | 2 +- .../levelgen/feature/EndPodiumFeature.java | 22 +- .../levelgen/feature/FallenTreeFeature.java | 132 + .../world/level/levelgen/feature/Feature.java | 2 + .../level/levelgen/feature/FossilFeature.java | 4 +- .../feature/HugeBrownMushroomFeature.java | 32 +- .../levelgen/feature/HugeFungusFeature.java | 2 +- .../feature/HugeRedMushroomFeature.java | 28 +- .../feature/LargeDripstoneFeature.java | 7 +- .../level/levelgen/feature/OreFeature.java | 5 +- .../levelgen/feature/ReplaceBlockFeature.java | 4 +- .../levelgen/feature/ScatteredOreFeature.java | 3 +- .../level/levelgen/feature/SpikeFeature.java | 2 +- .../level/levelgen/feature/TreeFeature.java | 31 +- .../FallenTreeConfiguration.java | 60 + .../stateproviders/WeightedStateProvider.java | 16 +- .../treedecorators/AlterGroundDecorator.java | 22 +- .../AttachedToLogsDecorator.java | 51 + .../CreakingHeartDecorator.java | 4 +- .../PlaceOnGroundDecorator.java | 85 + .../treedecorators/TreeDecoratorType.java | 2 + .../heightproviders/WeightedListHeight.java | 10 +- .../structure/LegacyStructureDataHandler.java | 66 +- .../structure/PoolElementStructurePiece.java | 27 +- .../structure/ScatteredFeaturePiece.java | 14 +- .../levelgen/structure/StructureCheck.java | 48 +- .../StructureFeatureIndexSavedData.java | 31 +- .../levelgen/structure/StructurePiece.java | 14 +- .../structure/StructureSpawnOverride.java | 8 +- .../levelgen/structure/StructureStart.java | 8 +- .../structure/TemplateStructurePiece.java | 10 +- .../structure/pieces/PiecesContainer.java | 4 +- .../structure/pools/FeaturePoolElement.java | 11 +- .../structure/pools/JigsawPlacement.java | 61 +- .../structure/pools/ListPoolElement.java | 6 + .../structure/pools/SinglePoolElement.java | 7 +- .../pools/StructureTemplatePool.java | 6 + .../{Direct.java => DirectPoolAlias.java} | 12 +- .../pools/alias/PoolAliasBinding.java | 22 +- .../pools/alias/PoolAliasBindings.java | 6 +- .../structure/pools/alias/RandomGroup.java | 36 - .../pools/alias/RandomGroupPoolAlias.java | 34 + .../{Random.java => RandomPoolAlias.java} | 20 +- .../structures/DesertPyramidPiece.java | 11 +- .../structure/structures/EndCityPieces.java | 4 +- .../structure/structures/IglooPieces.java | 9 +- .../structure/structures/JigsawStructure.java | 34 +- .../structures/JungleTemplePiece.java | 12 +- .../structure/structures/MineshaftPieces.java | 36 +- .../structures/MineshaftStructure.java | 15 +- .../structures/NetherFortressPieces.java | 8 +- .../structures/NetherFortressStructure.java | 29 +- .../structures/NetherFossilPieces.java | 6 +- .../structures/OceanMonumentPieces.java | 2 +- .../structure/structures/OceanRuinPieces.java | 14 +- .../structures/OceanRuinStructure.java | 16 +- .../structures/RuinedPortalPiece.java | 32 +- .../structures/RuinedPortalStructure.java | 35 +- .../structure/structures/ShipwreckPieces.java | 11 +- .../structures/StrongholdPieces.java | 31 +- .../structure/structures/SwampHutPiece.java | 8 +- .../structures/WoodlandMansionPieces.java | 8 +- .../JigsawReplacementProcessor.java | 2 +- .../templatesystem/StructureTemplate.java | 97 +- .../StructureTemplateManager.java | 8 +- .../rule/blockentity/AppendLoot.java | 13 +- .../world/level/material/FlowingFluid.java | 2 +- net/minecraft/world/level/material/Fluid.java | 16 + .../world/level/material/FluidState.java | 12 + .../world/level/material/LavaFluid.java | 65 +- .../world/level/material/WaterFluid.java | 10 +- .../world/level/saveddata/SavedData.java | 26 +- .../world/level/saveddata/SavedDataType.java | 26 + .../world/level/saveddata/maps/MapBanner.java | 4 +- .../world/level/saveddata/maps/MapFrame.java | 57 +- .../world/level/saveddata/maps/MapId.java | 36 +- .../world/level/saveddata/maps/MapIndex.java | 50 +- .../saveddata/maps/MapItemSavedData.java | 142 +- .../world/level/storage/CommandStorage.java | 87 +- .../level/storage/DimensionDataStorage.java | 94 +- .../level/storage/LevelStorageSource.java | 10 +- .../world/level/storage/PrimaryLevelData.java | 11 +- .../level/storage/loot/BuiltInLootTables.java | 15 +- .../world/level/storage/loot/LootTable.java | 25 +- .../storage/loot/entries/NestedLootTable.java | 5 +- .../functions/CopyCustomDataFunction.java | 12 +- .../loot/functions/SetContainerLootTable.java | 3 +- .../loot/functions/SetInstrumentFunction.java | 3 +- .../SetWrittenBookPagesFunction.java | 7 +- .../loot/functions/ToggleTooltips.java | 65 +- .../loot/providers/number/StorageValue.java | 15 +- .../world/level/timers/FunctionCallback.java | 29 +- .../level/timers/FunctionTagCallback.java | 29 +- .../world/level/timers/TimerCallback.java | 26 +- .../world/level/timers/TimerCallbacks.java | 53 +- .../world/level/timers/TimerQueue.java | 9 +- net/minecraft/world/phys/AABB.java | 42 +- net/minecraft/world/phys/Vec2.java | 6 + .../world/phys/shapes/ArrayVoxelShape.java | 15 +- .../phys/shapes/BitSetDiscreteVoxelShape.java | 21 +- .../world/phys/shapes/CollisionContext.java | 24 +- .../world/phys/shapes/CubeVoxelShape.java | 6 +- .../world/phys/shapes/DiscreteVoxelShape.java | 36 + .../phys/shapes/EntityCollisionContext.java | 22 +- .../phys/shapes/MinecartCollisionContext.java | 2 +- net/minecraft/world/phys/shapes/Shapes.java | 142 +- .../world/phys/shapes/VoxelShape.java | 14 +- net/minecraft/world/scores/Objective.java | 32 +- net/minecraft/world/scores/PlayerTeam.java | 54 +- net/minecraft/world/scores/Score.java | 65 +- net/minecraft/world/scores/ScoreHolder.java | 2 +- net/minecraft/world/scores/Scoreboard.java | 81 +- .../world/scores/ScoreboardSaveData.java | 226 +- net/minecraft/world/scores/Team.java | 49 +- .../scores/criteria/ObjectiveCriteria.java | 7 + .../world/ticks/LevelChunkTicks.java | 18 - net/minecraft/world/ticks/SavedTick.java | 70 +- net/minecraft/world/ticks/TickPriority.java | 3 + version.json | 14 +- 4011 files changed, 68824 insertions(+), 53150 deletions(-) create mode 100644 assets/minecraft/blockstates/bush.json create mode 100644 assets/minecraft/blockstates/cactus_flower.json create mode 100644 assets/minecraft/blockstates/firefly_bush.json create mode 100644 assets/minecraft/blockstates/leaf_litter.json create mode 100644 assets/minecraft/blockstates/short_dry_grass.json create mode 100644 assets/minecraft/blockstates/tall_dry_grass.json create mode 100644 assets/minecraft/blockstates/test_block.json create mode 100644 assets/minecraft/blockstates/test_instance_block.json create mode 100644 assets/minecraft/blockstates/wildflowers.json create mode 100644 assets/minecraft/equipment/saddle.json create mode 100644 assets/minecraft/items/blue_egg.json create mode 100644 assets/minecraft/items/brown_egg.json create mode 100644 assets/minecraft/items/bush.json create mode 100644 assets/minecraft/items/cactus_flower.json create mode 100644 assets/minecraft/items/firefly_bush.json create mode 100644 assets/minecraft/items/leaf_litter.json create mode 100644 assets/minecraft/items/short_dry_grass.json create mode 100644 assets/minecraft/items/tall_dry_grass.json create mode 100644 assets/minecraft/items/test_block.json create mode 100644 assets/minecraft/items/test_instance_block.json create mode 100644 assets/minecraft/items/wildflowers.json create mode 100644 assets/minecraft/models/block/bush.json create mode 100644 assets/minecraft/models/block/cactus_flower.json delete mode 100644 assets/minecraft/models/block/creaking_heart_active.json delete mode 100644 assets/minecraft/models/block/creaking_heart_active_horizontal.json create mode 100644 assets/minecraft/models/block/creaking_heart_awake.json create mode 100644 assets/minecraft/models/block/creaking_heart_awake_horizontal.json create mode 100644 assets/minecraft/models/block/creaking_heart_dormant.json create mode 100644 assets/minecraft/models/block/creaking_heart_dormant_horizontal.json create mode 100644 assets/minecraft/models/block/firefly_bush.json create mode 100644 assets/minecraft/models/block/leaf_litter_1.json create mode 100644 assets/minecraft/models/block/leaf_litter_2.json create mode 100644 assets/minecraft/models/block/leaf_litter_3.json create mode 100644 assets/minecraft/models/block/leaf_litter_4.json create mode 100644 assets/minecraft/models/block/short_dry_grass.json create mode 100644 assets/minecraft/models/block/tall_dry_grass.json create mode 100644 assets/minecraft/models/block/template_leaf_litter_1.json create mode 100644 assets/minecraft/models/block/template_leaf_litter_2.json create mode 100644 assets/minecraft/models/block/template_leaf_litter_3.json create mode 100644 assets/minecraft/models/block/template_leaf_litter_4.json create mode 100644 assets/minecraft/models/block/test_block_accept.json create mode 100644 assets/minecraft/models/block/test_block_fail.json create mode 100644 assets/minecraft/models/block/test_block_log.json create mode 100644 assets/minecraft/models/block/test_block_start.json create mode 100644 assets/minecraft/models/block/test_instance_block.json create mode 100644 assets/minecraft/models/block/wildflowers_1.json create mode 100644 assets/minecraft/models/block/wildflowers_2.json create mode 100644 assets/minecraft/models/block/wildflowers_3.json create mode 100644 assets/minecraft/models/block/wildflowers_4.json create mode 100644 assets/minecraft/models/item/allay_spawn_egg.json create mode 100644 assets/minecraft/models/item/armadillo_spawn_egg.json create mode 100644 assets/minecraft/models/item/axolotl_spawn_egg.json create mode 100644 assets/minecraft/models/item/bat_spawn_egg.json create mode 100644 assets/minecraft/models/item/bee_spawn_egg.json create mode 100644 assets/minecraft/models/item/blaze_spawn_egg.json create mode 100644 assets/minecraft/models/item/blue_egg.json create mode 100644 assets/minecraft/models/item/bogged_spawn_egg.json create mode 100644 assets/minecraft/models/item/breeze_spawn_egg.json create mode 100644 assets/minecraft/models/item/brown_egg.json create mode 100644 assets/minecraft/models/item/bush.json create mode 100644 assets/minecraft/models/item/cactus_flower.json create mode 100644 assets/minecraft/models/item/camel_spawn_egg.json create mode 100644 assets/minecraft/models/item/cat_spawn_egg.json create mode 100644 assets/minecraft/models/item/cave_spider_spawn_egg.json create mode 100644 assets/minecraft/models/item/chicken_spawn_egg.json create mode 100644 assets/minecraft/models/item/cod_spawn_egg.json create mode 100644 assets/minecraft/models/item/cow_spawn_egg.json create mode 100644 assets/minecraft/models/item/creaking_spawn_egg.json create mode 100644 assets/minecraft/models/item/creeper_spawn_egg.json create mode 100644 assets/minecraft/models/item/dolphin_spawn_egg.json create mode 100644 assets/minecraft/models/item/donkey_spawn_egg.json create mode 100644 assets/minecraft/models/item/drowned_spawn_egg.json create mode 100644 assets/minecraft/models/item/elder_guardian_spawn_egg.json create mode 100644 assets/minecraft/models/item/ender_dragon_spawn_egg.json create mode 100644 assets/minecraft/models/item/enderman_spawn_egg.json create mode 100644 assets/minecraft/models/item/endermite_spawn_egg.json create mode 100644 assets/minecraft/models/item/evoker_spawn_egg.json create mode 100644 assets/minecraft/models/item/firefly_bush.json create mode 100644 assets/minecraft/models/item/fox_spawn_egg.json create mode 100644 assets/minecraft/models/item/frog_spawn_egg.json create mode 100644 assets/minecraft/models/item/ghast_spawn_egg.json create mode 100644 assets/minecraft/models/item/glow_squid_spawn_egg.json create mode 100644 assets/minecraft/models/item/goat_spawn_egg.json create mode 100644 assets/minecraft/models/item/guardian_spawn_egg.json create mode 100644 assets/minecraft/models/item/hoglin_spawn_egg.json create mode 100644 assets/minecraft/models/item/horse_spawn_egg.json create mode 100644 assets/minecraft/models/item/husk_spawn_egg.json create mode 100644 assets/minecraft/models/item/iron_golem_spawn_egg.json create mode 100644 assets/minecraft/models/item/leaf_litter.json create mode 100644 assets/minecraft/models/item/llama_spawn_egg.json create mode 100644 assets/minecraft/models/item/magma_cube_spawn_egg.json create mode 100644 assets/minecraft/models/item/mooshroom_spawn_egg.json create mode 100644 assets/minecraft/models/item/mule_spawn_egg.json create mode 100644 assets/minecraft/models/item/ocelot_spawn_egg.json create mode 100644 assets/minecraft/models/item/panda_spawn_egg.json create mode 100644 assets/minecraft/models/item/parrot_spawn_egg.json create mode 100644 assets/minecraft/models/item/phantom_spawn_egg.json create mode 100644 assets/minecraft/models/item/pig_spawn_egg.json create mode 100644 assets/minecraft/models/item/piglin_brute_spawn_egg.json create mode 100644 assets/minecraft/models/item/piglin_spawn_egg.json create mode 100644 assets/minecraft/models/item/pillager_spawn_egg.json create mode 100644 assets/minecraft/models/item/polar_bear_spawn_egg.json create mode 100644 assets/minecraft/models/item/pufferfish_spawn_egg.json create mode 100644 assets/minecraft/models/item/rabbit_spawn_egg.json create mode 100644 assets/minecraft/models/item/ravager_spawn_egg.json create mode 100644 assets/minecraft/models/item/salmon_spawn_egg.json create mode 100644 assets/minecraft/models/item/sheep_spawn_egg.json create mode 100644 assets/minecraft/models/item/short_dry_grass.json create mode 100644 assets/minecraft/models/item/shulker_spawn_egg.json create mode 100644 assets/minecraft/models/item/silverfish_spawn_egg.json create mode 100644 assets/minecraft/models/item/skeleton_horse_spawn_egg.json create mode 100644 assets/minecraft/models/item/skeleton_spawn_egg.json create mode 100644 assets/minecraft/models/item/slime_spawn_egg.json create mode 100644 assets/minecraft/models/item/sniffer_spawn_egg.json create mode 100644 assets/minecraft/models/item/snow_golem_spawn_egg.json create mode 100644 assets/minecraft/models/item/spider_spawn_egg.json create mode 100644 assets/minecraft/models/item/squid_spawn_egg.json create mode 100644 assets/minecraft/models/item/stray_spawn_egg.json create mode 100644 assets/minecraft/models/item/strider_spawn_egg.json create mode 100644 assets/minecraft/models/item/tadpole_spawn_egg.json create mode 100644 assets/minecraft/models/item/tall_dry_grass.json delete mode 100644 assets/minecraft/models/item/template_spawn_egg.json create mode 100644 assets/minecraft/models/item/trader_llama_spawn_egg.json create mode 100644 assets/minecraft/models/item/tropical_fish_spawn_egg.json create mode 100644 assets/minecraft/models/item/turtle_spawn_egg.json create mode 100644 assets/minecraft/models/item/vex_spawn_egg.json create mode 100644 assets/minecraft/models/item/villager_spawn_egg.json create mode 100644 assets/minecraft/models/item/vindicator_spawn_egg.json create mode 100644 assets/minecraft/models/item/wandering_trader_spawn_egg.json create mode 100644 assets/minecraft/models/item/warden_spawn_egg.json create mode 100644 assets/minecraft/models/item/wildflowers.json create mode 100644 assets/minecraft/models/item/witch_spawn_egg.json create mode 100644 assets/minecraft/models/item/wither_skeleton_spawn_egg.json create mode 100644 assets/minecraft/models/item/wither_spawn_egg.json create mode 100644 assets/minecraft/models/item/wolf_spawn_egg.json create mode 100644 assets/minecraft/models/item/zoglin_spawn_egg.json create mode 100644 assets/minecraft/models/item/zombie_horse_spawn_egg.json create mode 100644 assets/minecraft/models/item/zombie_spawn_egg.json create mode 100644 assets/minecraft/models/item/zombie_villager_spawn_egg.json create mode 100644 assets/minecraft/models/item/zombified_piglin_spawn_egg.json create mode 100644 assets/minecraft/particles/firefly.json create mode 100644 assets/minecraft/particles/tinted_leaves.json delete mode 100644 assets/minecraft/shaders/core/blit_screen.json delete mode 100644 assets/minecraft/shaders/core/lightmap.json delete mode 100644 assets/minecraft/shaders/core/particle.json delete mode 100644 assets/minecraft/shaders/core/position.json delete mode 100644 assets/minecraft/shaders/core/position_color.json delete mode 100644 assets/minecraft/shaders/core/position_color_lightmap.json delete mode 100644 assets/minecraft/shaders/core/position_color_tex_lightmap.json delete mode 100644 assets/minecraft/shaders/core/position_tex.json delete mode 100644 assets/minecraft/shaders/core/position_tex_color.json delete mode 100644 assets/minecraft/shaders/core/rendertype_armor_cutout_no_cull.json delete mode 100644 assets/minecraft/shaders/core/rendertype_armor_entity_glint.json delete mode 100644 assets/minecraft/shaders/core/rendertype_armor_translucent.json delete mode 100644 assets/minecraft/shaders/core/rendertype_beacon_beam.json delete mode 100644 assets/minecraft/shaders/core/rendertype_breeze_wind.json delete mode 100644 assets/minecraft/shaders/core/rendertype_clouds.json delete mode 100644 assets/minecraft/shaders/core/rendertype_crumbling.json delete mode 100644 assets/minecraft/shaders/core/rendertype_cutout.json delete mode 100644 assets/minecraft/shaders/core/rendertype_cutout_mipped.json delete mode 100644 assets/minecraft/shaders/core/rendertype_end_gateway.json delete mode 100644 assets/minecraft/shaders/core/rendertype_end_portal.json delete mode 100644 assets/minecraft/shaders/core/rendertype_energy_swirl.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_alpha.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_cutout.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_cutout_no_cull.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_cutout_no_cull_z_offset.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_decal.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_glint.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_no_outline.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_shadow.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_smooth_cutout.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_solid.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_translucent.json delete mode 100644 assets/minecraft/shaders/core/rendertype_entity_translucent_emissive.json delete mode 100644 assets/minecraft/shaders/core/rendertype_eyes.json delete mode 100644 assets/minecraft/shaders/core/rendertype_glint.json delete mode 100644 assets/minecraft/shaders/core/rendertype_glint_translucent.json delete mode 100644 assets/minecraft/shaders/core/rendertype_gui.json delete mode 100644 assets/minecraft/shaders/core/rendertype_gui_ghost_recipe_overlay.json delete mode 100644 assets/minecraft/shaders/core/rendertype_gui_overlay.json delete mode 100644 assets/minecraft/shaders/core/rendertype_gui_text_highlight.json delete mode 100644 assets/minecraft/shaders/core/rendertype_item_entity_translucent_cull.json delete mode 100644 assets/minecraft/shaders/core/rendertype_leash.json delete mode 100644 assets/minecraft/shaders/core/rendertype_lightning.json delete mode 100644 assets/minecraft/shaders/core/rendertype_lines.json delete mode 100644 assets/minecraft/shaders/core/rendertype_outline.json delete mode 100644 assets/minecraft/shaders/core/rendertype_solid.json delete mode 100644 assets/minecraft/shaders/core/rendertype_text.json delete mode 100644 assets/minecraft/shaders/core/rendertype_text_background.json delete mode 100644 assets/minecraft/shaders/core/rendertype_text_background_see_through.json delete mode 100644 assets/minecraft/shaders/core/rendertype_text_intensity.json delete mode 100644 assets/minecraft/shaders/core/rendertype_text_intensity_see_through.json delete mode 100644 assets/minecraft/shaders/core/rendertype_text_see_through.json delete mode 100644 assets/minecraft/shaders/core/rendertype_translucent.json delete mode 100644 assets/minecraft/shaders/core/rendertype_translucent_moving_block.json delete mode 100644 assets/minecraft/shaders/core/rendertype_tripwire.json delete mode 100644 assets/minecraft/shaders/core/rendertype_water_mask.json create mode 100644 assets/minecraft/shaders/core/rendertype_world_border.fsh create mode 100644 assets/minecraft/shaders/core/rendertype_world_border.vsh delete mode 100644 assets/minecraft/shaders/post/bits.json delete mode 100644 assets/minecraft/shaders/post/blit.json delete mode 100644 assets/minecraft/shaders/post/box_blur.json delete mode 100644 assets/minecraft/shaders/post/color_convolve.json delete mode 100644 assets/minecraft/shaders/post/entity_outline.json delete mode 100644 assets/minecraft/shaders/post/entity_outline_box_blur.json delete mode 100644 assets/minecraft/shaders/post/invert.json delete mode 100644 assets/minecraft/shaders/post/spider.json delete mode 100644 assets/minecraft/shaders/post/transparency.json create mode 100644 assets/minecraft/textures/block/bush.png create mode 100644 assets/minecraft/textures/block/cactus_flower.png rename assets/minecraft/textures/block/{creaking_heart_active.png => creaking_heart_awake.png} (100%) create mode 100644 assets/minecraft/textures/block/creaking_heart_dormant.png rename assets/minecraft/textures/block/{creaking_heart_top_active.png => creaking_heart_top_awake.png} (100%) create mode 100644 assets/minecraft/textures/block/creaking_heart_top_dormant.png create mode 100644 assets/minecraft/textures/block/firefly_bush.png create mode 100644 assets/minecraft/textures/block/firefly_bush_emissive.png create mode 100644 assets/minecraft/textures/block/firefly_bush_emissive.png.mcmeta create mode 100644 assets/minecraft/textures/block/leaf_litter.png create mode 100644 assets/minecraft/textures/block/short_dry_grass.png create mode 100644 assets/minecraft/textures/block/tall_dry_grass.png create mode 100644 assets/minecraft/textures/block/test_block_accept.png create mode 100644 assets/minecraft/textures/block/test_block_fail.png create mode 100644 assets/minecraft/textures/block/test_block_log.png create mode 100644 assets/minecraft/textures/block/test_block_start.png create mode 100644 assets/minecraft/textures/block/test_instance_block.png create mode 100644 assets/minecraft/textures/block/wildflowers.png create mode 100644 assets/minecraft/textures/block/wildflowers_stem.png create mode 100644 assets/minecraft/textures/colormap/dry_foliage.png create mode 100644 assets/minecraft/textures/entity/chicken/cold_chicken.png rename assets/minecraft/textures/entity/{chicken.png => chicken/temperate_chicken.png} (100%) create mode 100644 assets/minecraft/textures/entity/chicken/warm_chicken.png create mode 100644 assets/minecraft/textures/entity/cow/cold_cow.png delete mode 100644 assets/minecraft/textures/entity/cow/cow.png create mode 100644 assets/minecraft/textures/entity/cow/temperate_cow.png create mode 100644 assets/minecraft/textures/entity/cow/warm_cow.png create mode 100644 assets/minecraft/textures/entity/equipment/camel_saddle/saddle.png create mode 100644 assets/minecraft/textures/entity/equipment/donkey_saddle/saddle.png create mode 100644 assets/minecraft/textures/entity/equipment/horse_saddle/saddle.png create mode 100644 assets/minecraft/textures/entity/equipment/mule_saddle/saddle.png create mode 100644 assets/minecraft/textures/entity/equipment/pig_saddle/saddle.png create mode 100644 assets/minecraft/textures/entity/equipment/skeleton_horse_saddle/saddle.png rename assets/minecraft/textures/entity/{strider/strider_saddle.png => equipment/strider_saddle/saddle.png} (100%) create mode 100644 assets/minecraft/textures/entity/equipment/zombie_horse_saddle/saddle.png create mode 100644 assets/minecraft/textures/entity/pig/cold_pig.png delete mode 100644 assets/minecraft/textures/entity/pig/pig.png delete mode 100644 assets/minecraft/textures/entity/pig/pig_saddle.png create mode 100644 assets/minecraft/textures/entity/pig/temperate_pig.png create mode 100644 assets/minecraft/textures/entity/pig/warm_pig.png delete mode 100644 assets/minecraft/textures/entity/sheep/sheep_fur.png create mode 100644 assets/minecraft/textures/entity/sheep/sheep_wool.png create mode 100644 assets/minecraft/textures/entity/sheep/sheep_wool_undercoat.png create mode 100644 assets/minecraft/textures/item/allay_spawn_egg.png create mode 100644 assets/minecraft/textures/item/armadillo_spawn_egg.png create mode 100644 assets/minecraft/textures/item/axolotl_spawn_egg.png create mode 100644 assets/minecraft/textures/item/bat_spawn_egg.png create mode 100644 assets/minecraft/textures/item/bee_spawn_egg.png create mode 100644 assets/minecraft/textures/item/blaze_spawn_egg.png create mode 100644 assets/minecraft/textures/item/blue_egg.png create mode 100644 assets/minecraft/textures/item/bogged_spawn_egg.png create mode 100644 assets/minecraft/textures/item/breeze_spawn_egg.png create mode 100644 assets/minecraft/textures/item/brown_egg.png create mode 100644 assets/minecraft/textures/item/camel_spawn_egg.png create mode 100644 assets/minecraft/textures/item/cat_spawn_egg.png create mode 100644 assets/minecraft/textures/item/cave_spider_spawn_egg.png create mode 100644 assets/minecraft/textures/item/chicken_spawn_egg.png create mode 100644 assets/minecraft/textures/item/cod_spawn_egg.png create mode 100644 assets/minecraft/textures/item/cow_spawn_egg.png create mode 100644 assets/minecraft/textures/item/creaking_spawn_egg.png create mode 100644 assets/minecraft/textures/item/creeper_spawn_egg.png create mode 100644 assets/minecraft/textures/item/dolphin_spawn_egg.png create mode 100644 assets/minecraft/textures/item/donkey_spawn_egg.png create mode 100644 assets/minecraft/textures/item/drowned_spawn_egg.png create mode 100644 assets/minecraft/textures/item/elder_guardian_spawn_egg.png create mode 100644 assets/minecraft/textures/item/ender_dragon_spawn_egg.png create mode 100644 assets/minecraft/textures/item/enderman_spawn_egg.png create mode 100644 assets/minecraft/textures/item/endermite_spawn_egg.png create mode 100644 assets/minecraft/textures/item/evoker_spawn_egg.png create mode 100644 assets/minecraft/textures/item/firefly_bush.png create mode 100644 assets/minecraft/textures/item/fox_spawn_egg.png create mode 100644 assets/minecraft/textures/item/frog_spawn_egg.png create mode 100644 assets/minecraft/textures/item/ghast_spawn_egg.png create mode 100644 assets/minecraft/textures/item/glow_squid_spawn_egg.png create mode 100644 assets/minecraft/textures/item/goat_spawn_egg.png create mode 100644 assets/minecraft/textures/item/guardian_spawn_egg.png create mode 100644 assets/minecraft/textures/item/hoglin_spawn_egg.png create mode 100644 assets/minecraft/textures/item/horse_spawn_egg.png create mode 100644 assets/minecraft/textures/item/husk_spawn_egg.png create mode 100644 assets/minecraft/textures/item/iron_golem_spawn_egg.png create mode 100644 assets/minecraft/textures/item/leaf_litter.png create mode 100644 assets/minecraft/textures/item/llama_spawn_egg.png create mode 100644 assets/minecraft/textures/item/magma_cube_spawn_egg.png create mode 100644 assets/minecraft/textures/item/mooshroom_spawn_egg.png create mode 100644 assets/minecraft/textures/item/mule_spawn_egg.png create mode 100644 assets/minecraft/textures/item/ocelot_spawn_egg.png create mode 100644 assets/minecraft/textures/item/panda_spawn_egg.png create mode 100644 assets/minecraft/textures/item/parrot_spawn_egg.png create mode 100644 assets/minecraft/textures/item/phantom_spawn_egg.png create mode 100644 assets/minecraft/textures/item/pig_spawn_egg.png create mode 100644 assets/minecraft/textures/item/piglin_brute_spawn_egg.png create mode 100644 assets/minecraft/textures/item/piglin_spawn_egg.png create mode 100644 assets/minecraft/textures/item/pillager_spawn_egg.png create mode 100644 assets/minecraft/textures/item/polar_bear_spawn_egg.png create mode 100644 assets/minecraft/textures/item/pufferfish_spawn_egg.png create mode 100644 assets/minecraft/textures/item/rabbit_spawn_egg.png create mode 100644 assets/minecraft/textures/item/ravager_spawn_egg.png create mode 100644 assets/minecraft/textures/item/salmon_spawn_egg.png create mode 100644 assets/minecraft/textures/item/sheep_spawn_egg.png create mode 100644 assets/minecraft/textures/item/shulker_spawn_egg.png create mode 100644 assets/minecraft/textures/item/silverfish_spawn_egg.png create mode 100644 assets/minecraft/textures/item/skeleton_horse_spawn_egg.png create mode 100644 assets/minecraft/textures/item/skeleton_spawn_egg.png create mode 100644 assets/minecraft/textures/item/slime_spawn_egg.png create mode 100644 assets/minecraft/textures/item/sniffer_spawn_egg.png create mode 100644 assets/minecraft/textures/item/snow_golem_spawn_egg.png delete mode 100644 assets/minecraft/textures/item/spawn_egg.png delete mode 100644 assets/minecraft/textures/item/spawn_egg_overlay.png create mode 100644 assets/minecraft/textures/item/spider_spawn_egg.png create mode 100644 assets/minecraft/textures/item/squid_spawn_egg.png create mode 100644 assets/minecraft/textures/item/stray_spawn_egg.png create mode 100644 assets/minecraft/textures/item/strider_spawn_egg.png create mode 100644 assets/minecraft/textures/item/tadpole_spawn_egg.png create mode 100644 assets/minecraft/textures/item/trader_llama_spawn_egg.png create mode 100644 assets/minecraft/textures/item/tropical_fish_spawn_egg.png create mode 100644 assets/minecraft/textures/item/turtle_spawn_egg.png create mode 100644 assets/minecraft/textures/item/vex_spawn_egg.png create mode 100644 assets/minecraft/textures/item/villager_spawn_egg.png create mode 100644 assets/minecraft/textures/item/vindicator_spawn_egg.png create mode 100644 assets/minecraft/textures/item/wandering_trader_spawn_egg.png create mode 100644 assets/minecraft/textures/item/warden_spawn_egg.png create mode 100644 assets/minecraft/textures/item/wildflowers.png create mode 100644 assets/minecraft/textures/item/witch_spawn_egg.png create mode 100644 assets/minecraft/textures/item/wither_skeleton_spawn_egg.png create mode 100644 assets/minecraft/textures/item/wither_spawn_egg.png create mode 100644 assets/minecraft/textures/item/wolf_spawn_egg.png create mode 100644 assets/minecraft/textures/item/zoglin_spawn_egg.png create mode 100644 assets/minecraft/textures/item/zombie_horse_spawn_egg.png create mode 100644 assets/minecraft/textures/item/zombie_spawn_egg.png create mode 100644 assets/minecraft/textures/item/zombie_villager_spawn_egg.png create mode 100644 assets/minecraft/textures/item/zombified_piglin_spawn_egg.png rename assets/minecraft/textures/misc/{enchanted_glint_entity.png => enchanted_glint_armor.png} (100%) rename assets/minecraft/textures/misc/{enchanted_glint_entity.png.mcmeta => enchanted_glint_armor.png.mcmeta} (100%) create mode 100644 assets/minecraft/textures/particle/firefly.png create mode 100644 assets/minecraft/textures/particle/leaf_0.png create mode 100644 assets/minecraft/textures/particle/leaf_1.png create mode 100644 assets/minecraft/textures/particle/leaf_10.png create mode 100644 assets/minecraft/textures/particle/leaf_11.png create mode 100644 assets/minecraft/textures/particle/leaf_2.png create mode 100644 assets/minecraft/textures/particle/leaf_3.png create mode 100644 assets/minecraft/textures/particle/leaf_4.png create mode 100644 assets/minecraft/textures/particle/leaf_5.png create mode 100644 assets/minecraft/textures/particle/leaf_6.png create mode 100644 assets/minecraft/textures/particle/leaf_7.png create mode 100644 assets/minecraft/textures/particle/leaf_8.png create mode 100644 assets/minecraft/textures/particle/leaf_9.png create mode 100644 com/mojang/blaze3d/GpuOutOfMemoryException.java create mode 100644 com/mojang/blaze3d/opengl/AbstractUniform.java create mode 100644 com/mojang/blaze3d/opengl/DirectStateAccess.java create mode 100644 com/mojang/blaze3d/opengl/GlBuffer.java create mode 100644 com/mojang/blaze3d/opengl/GlCommandEncoder.java rename com/mojang/blaze3d/{platform => opengl}/GlConst.java (56%) rename com/mojang/blaze3d/{platform => opengl}/GlDebug.java (66%) create mode 100644 com/mojang/blaze3d/opengl/GlDebugLabel.java create mode 100644 com/mojang/blaze3d/opengl/GlDevice.java create mode 100644 com/mojang/blaze3d/opengl/GlProgram.java create mode 100644 com/mojang/blaze3d/opengl/GlRenderPass.java create mode 100644 com/mojang/blaze3d/opengl/GlRenderPipeline.java create mode 100644 com/mojang/blaze3d/opengl/GlShaderModule.java rename com/mojang/blaze3d/{platform => opengl}/GlStateManager.java (59%) create mode 100644 com/mojang/blaze3d/opengl/GlTexture.java create mode 100644 com/mojang/blaze3d/opengl/Uniform.java create mode 100644 com/mojang/blaze3d/opengl/VertexArrayCache.java create mode 100644 com/mojang/blaze3d/opengl/package-info.java create mode 100644 com/mojang/blaze3d/pipeline/BlendFunction.java create mode 100644 com/mojang/blaze3d/pipeline/CompiledRenderPipeline.java delete mode 100644 com/mojang/blaze3d/pipeline/RenderCall.java create mode 100644 com/mojang/blaze3d/pipeline/RenderPipeline.java create mode 100644 com/mojang/blaze3d/platform/DepthTestFunction.java create mode 100644 com/mojang/blaze3d/platform/DestFactor.java delete mode 100644 com/mojang/blaze3d/platform/GlUtil.java create mode 100644 com/mojang/blaze3d/platform/LogicOp.java create mode 100644 com/mojang/blaze3d/platform/PolygonMode.java create mode 100644 com/mojang/blaze3d/platform/SourceFactor.java delete mode 100644 com/mojang/blaze3d/shaders/AbstractUniform.java delete mode 100644 com/mojang/blaze3d/shaders/CompiledShader.java create mode 100644 com/mojang/blaze3d/shaders/ShaderType.java delete mode 100644 com/mojang/blaze3d/shaders/Uniform.java create mode 100644 com/mojang/blaze3d/shaders/UniformType.java create mode 100644 com/mojang/blaze3d/systems/CommandEncoder.java create mode 100644 com/mojang/blaze3d/systems/GpuDevice.java create mode 100644 com/mojang/blaze3d/systems/RenderPass.java create mode 100644 com/mojang/blaze3d/systems/ScissorState.java create mode 100644 com/mojang/blaze3d/textures/AddressMode.java create mode 100644 com/mojang/blaze3d/textures/FilterMode.java create mode 100644 com/mojang/blaze3d/textures/GpuTexture.java create mode 100644 com/mojang/blaze3d/textures/TextureFormat.java create mode 100644 com/mojang/blaze3d/textures/package-info.java delete mode 100644 com/mojang/blaze3d/vertex/BufferUploader.java delete mode 100644 com/mojang/blaze3d/vertex/VertexBuffer.java create mode 100644 com/mojang/math/Quadrant.java rename data/minecraft/advancement/{nether => adventure}/use_lodestone.json (80%) create mode 100644 data/minecraft/advancement/recipes/misc/leaf_litter.json create mode 100644 data/minecraft/advancement/recipes/misc/pink_dye_from_cactus_flower.json create mode 100644 data/minecraft/advancement/recipes/misc/yellow_dye_from_wildflowers.json create mode 100644 data/minecraft/cat_variant/all_black.json create mode 100644 data/minecraft/cat_variant/black.json create mode 100644 data/minecraft/cat_variant/british_shorthair.json create mode 100644 data/minecraft/cat_variant/calico.json create mode 100644 data/minecraft/cat_variant/jellie.json create mode 100644 data/minecraft/cat_variant/persian.json create mode 100644 data/minecraft/cat_variant/ragdoll.json create mode 100644 data/minecraft/cat_variant/red.json create mode 100644 data/minecraft/cat_variant/siamese.json create mode 100644 data/minecraft/cat_variant/tabby.json create mode 100644 data/minecraft/cat_variant/white.json create mode 100644 data/minecraft/chicken_variant/cold.json create mode 100644 data/minecraft/chicken_variant/temperate.json create mode 100644 data/minecraft/chicken_variant/warm.json create mode 100644 data/minecraft/cow_variant/cold.json create mode 100644 data/minecraft/cow_variant/temperate.json create mode 100644 data/minecraft/cow_variant/warm.json create mode 100644 data/minecraft/frog_variant/cold.json create mode 100644 data/minecraft/frog_variant/temperate.json create mode 100644 data/minecraft/frog_variant/warm.json create mode 100644 data/minecraft/loot_table/blocks/bush.json create mode 100644 data/minecraft/loot_table/blocks/cactus_flower.json create mode 100644 data/minecraft/loot_table/blocks/firefly_bush.json create mode 100644 data/minecraft/loot_table/blocks/leaf_litter.json create mode 100644 data/minecraft/loot_table/blocks/short_dry_grass.json create mode 100644 data/minecraft/loot_table/blocks/tall_dry_grass.json create mode 100644 data/minecraft/loot_table/blocks/wildflowers.json create mode 100644 data/minecraft/pig_variant/cold.json create mode 100644 data/minecraft/pig_variant/temperate.json create mode 100644 data/minecraft/pig_variant/warm.json create mode 100644 data/minecraft/recipe/leaf_litter.json create mode 100644 data/minecraft/recipe/pink_dye_from_cactus_flower.json create mode 100644 data/minecraft/recipe/yellow_dye_from_wildflowers.json create mode 100644 data/minecraft/structure/empty.nbt create mode 100644 data/minecraft/tags/block/camels_spawnable_on.json rename data/minecraft/tags/block/{dead_bush_may_place_on.json => dry_vegetation_may_place_on.json} (60%) create mode 100644 data/minecraft/tags/block/edible_for_sheep.json create mode 100644 data/minecraft/tags/block/plays_ambient_desert_block_sounds.json create mode 100644 data/minecraft/tags/block/replaceable_by_mushrooms.json create mode 100644 data/minecraft/tags/block/sword_instantly_mines.json delete mode 100644 data/minecraft/tags/cat_variant/default_spawns.json delete mode 100644 data/minecraft/tags/cat_variant/full_moon_spawns.json create mode 100644 data/minecraft/tags/entity_type/can_equip_saddle.json create mode 100644 data/minecraft/tags/entity_type/can_wear_horse_armor.json create mode 100644 data/minecraft/tags/item/book_cloning_target.json create mode 100644 data/minecraft/tags/item/eggs.json create mode 100644 data/minecraft/tags/item/flowers.json create mode 100644 data/minecraft/tags/worldgen/biome/spawns_cold_variant_farm_animals.json create mode 100644 data/minecraft/tags/worldgen/biome/spawns_warm_variant_farm_animals.json rename data/minecraft/{datapacks/trade_rebalance/data/minecraft => }/tags/worldgen/structure/on_desert_village_maps.json (100%) rename data/minecraft/{datapacks/trade_rebalance/data/minecraft => }/tags/worldgen/structure/on_jungle_explorer_maps.json (100%) rename data/minecraft/{datapacks/trade_rebalance/data/minecraft => }/tags/worldgen/structure/on_plains_village_maps.json (100%) rename data/minecraft/{datapacks/trade_rebalance/data/minecraft => }/tags/worldgen/structure/on_savanna_village_maps.json (100%) rename data/minecraft/{datapacks/trade_rebalance/data/minecraft => }/tags/worldgen/structure/on_snowy_village_maps.json (100%) rename data/minecraft/{datapacks/trade_rebalance/data/minecraft => }/tags/worldgen/structure/on_swamp_explorer_maps.json (100%) rename data/minecraft/{datapacks/trade_rebalance/data/minecraft => }/tags/worldgen/structure/on_taiga_village_maps.json (100%) create mode 100644 data/minecraft/test_environment/default.json create mode 100644 data/minecraft/test_instance/always_pass.json create mode 100644 data/minecraft/wolf_sound_variant/angry.json create mode 100644 data/minecraft/wolf_sound_variant/big.json create mode 100644 data/minecraft/wolf_sound_variant/classic.json create mode 100644 data/minecraft/wolf_sound_variant/cute.json create mode 100644 data/minecraft/wolf_sound_variant/grumpy.json create mode 100644 data/minecraft/wolf_sound_variant/puglin.json create mode 100644 data/minecraft/wolf_sound_variant/sad.json create mode 100644 data/minecraft/worldgen/configured_feature/birch_bees_0002_leaf_litter.json create mode 100644 data/minecraft/worldgen/configured_feature/birch_leaf_litter.json create mode 100644 data/minecraft/worldgen/configured_feature/dark_oak_leaf_litter.json create mode 100644 data/minecraft/worldgen/configured_feature/fallen_birch_tree.json create mode 100644 data/minecraft/worldgen/configured_feature/fallen_jungle_tree.json create mode 100644 data/minecraft/worldgen/configured_feature/fallen_oak_tree.json create mode 100644 data/minecraft/worldgen/configured_feature/fallen_spruce_tree.json create mode 100644 data/minecraft/worldgen/configured_feature/fallen_super_birch_tree.json delete mode 100644 data/minecraft/worldgen/configured_feature/fancy_oak_bees_0002.json create mode 100644 data/minecraft/worldgen/configured_feature/fancy_oak_bees_0002_leaf_litter.json create mode 100644 data/minecraft/worldgen/configured_feature/fancy_oak_leaf_litter.json delete mode 100644 data/minecraft/worldgen/configured_feature/oak_bees_0002.json create mode 100644 data/minecraft/worldgen/configured_feature/oak_bees_0002_leaf_litter.json create mode 100644 data/minecraft/worldgen/configured_feature/oak_leaf_litter.json create mode 100644 data/minecraft/worldgen/configured_feature/patch_bush.json create mode 100644 data/minecraft/worldgen/configured_feature/patch_dry_grass.json create mode 100644 data/minecraft/worldgen/configured_feature/patch_firefly_bush.json create mode 100644 data/minecraft/worldgen/configured_feature/patch_grass_meadow.json create mode 100644 data/minecraft/worldgen/configured_feature/patch_leaf_litter.json create mode 100644 data/minecraft/worldgen/configured_feature/trees_badlands.json create mode 100644 data/minecraft/worldgen/configured_feature/trees_birch.json delete mode 100644 data/minecraft/worldgen/configured_feature/trees_birch_and_oak.json create mode 100644 data/minecraft/worldgen/configured_feature/trees_birch_and_oak_leaf_litter.json create mode 100644 data/minecraft/worldgen/configured_feature/trees_snowy.json create mode 100644 data/minecraft/worldgen/configured_feature/wildflowers_birch_forest.json create mode 100644 data/minecraft/worldgen/configured_feature/wildflowers_meadow.json create mode 100644 data/minecraft/worldgen/placed_feature/birch_bees_0002_leaf_litter.json create mode 100644 data/minecraft/worldgen/placed_feature/birch_leaf_litter.json create mode 100644 data/minecraft/worldgen/placed_feature/dark_oak_leaf_litter.json create mode 100644 data/minecraft/worldgen/placed_feature/fallen_birch_tree.json create mode 100644 data/minecraft/worldgen/placed_feature/fallen_jungle_tree.json rename data/minecraft/worldgen/placed_feature/{oak_bees_0002.json => fallen_oak_tree.json} (87%) create mode 100644 data/minecraft/worldgen/placed_feature/fallen_spruce_tree.json create mode 100644 data/minecraft/worldgen/placed_feature/fallen_super_birch_tree.json create mode 100644 data/minecraft/worldgen/placed_feature/fancy_oak_bees_0002_leaf_litter.json create mode 100644 data/minecraft/worldgen/placed_feature/fancy_oak_leaf_litter.json create mode 100644 data/minecraft/worldgen/placed_feature/oak_bees_0002_leaf_litter.json rename data/minecraft/worldgen/placed_feature/{fancy_oak_bees_0002.json => oak_leaf_litter.json} (86%) create mode 100644 data/minecraft/worldgen/placed_feature/patch_bush.json create mode 100644 data/minecraft/worldgen/placed_feature/patch_dry_grass_badlands.json create mode 100644 data/minecraft/worldgen/placed_feature/patch_dry_grass_desert.json create mode 100644 data/minecraft/worldgen/placed_feature/patch_firefly_bush_near_water.json create mode 100644 data/minecraft/worldgen/placed_feature/patch_firefly_bush_near_water_swamp.json create mode 100644 data/minecraft/worldgen/placed_feature/patch_firefly_bush_swamp.json create mode 100644 data/minecraft/worldgen/placed_feature/patch_grass_meadow.json create mode 100644 data/minecraft/worldgen/placed_feature/patch_leaf_litter.json rename data/minecraft/worldgen/placed_feature/{trees_birch_and_oak.json => trees_birch_and_oak_leaf_litter.json} (91%) create mode 100644 data/minecraft/worldgen/placed_feature/wildflowers_birch_forest.json create mode 100644 data/minecraft/worldgen/placed_feature/wildflowers_meadow.json create mode 100644 net/minecraft/advancements/critereon/DataComponentMatchers.java delete mode 100644 net/minecraft/advancements/critereon/ItemAttributeModifiersPredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemBundlePredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemContainerPredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemCustomDataPredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemDamagePredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemEnchantmentsPredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemFireworkExplosionPredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemFireworksPredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemSubPredicate.java delete mode 100644 net/minecraft/advancements/critereon/ItemSubPredicates.java delete mode 100644 net/minecraft/advancements/critereon/ItemWritableBookPredicate.java create mode 100644 net/minecraft/client/data/AtlasProvider.java create mode 100644 net/minecraft/client/data/models/MultiVariant.java rename net/minecraft/client/data/models/blockstates/{BlockStateGenerator.java => BlockModelDefinitionGenerator.java} (54%) delete mode 100644 net/minecraft/client/data/models/blockstates/Condition.java create mode 100644 net/minecraft/client/data/models/blockstates/ConditionBuilder.java create mode 100644 net/minecraft/client/data/models/blockstates/PropertyValueList.java delete mode 100644 net/minecraft/client/data/models/blockstates/Selector.java delete mode 100644 net/minecraft/client/data/models/blockstates/Variant.java delete mode 100644 net/minecraft/client/data/models/blockstates/VariantProperties.java delete mode 100644 net/minecraft/client/data/models/blockstates/VariantProperty.java create mode 100644 net/minecraft/client/gui/screens/inventory/TestBlockEditScreen.java create mode 100644 net/minecraft/client/gui/screens/inventory/TestInstanceBlockEditScreen.java create mode 100644 net/minecraft/client/model/AdultAndBabyModelPair.java create mode 100644 net/minecraft/client/model/CamelSaddleModel.java create mode 100644 net/minecraft/client/model/ColdChickenModel.java create mode 100644 net/minecraft/client/model/ColdCowModel.java create mode 100644 net/minecraft/client/model/ColdPigModel.java create mode 100644 net/minecraft/client/model/EquineSaddleModel.java create mode 100644 net/minecraft/client/model/WarmCowModel.java create mode 100644 net/minecraft/client/multiplayer/CacheSlot.java create mode 100644 net/minecraft/client/particle/FireflyParticle.java delete mode 100644 net/minecraft/client/renderer/CompiledShaderProgram.java delete mode 100644 net/minecraft/client/renderer/CoreShaders.java create mode 100644 net/minecraft/client/renderer/MaterialMapper.java create mode 100644 net/minecraft/client/renderer/RenderPipelines.java delete mode 100644 net/minecraft/client/renderer/ShaderProgram.java delete mode 100644 net/minecraft/client/renderer/ShaderProgramConfig.java delete mode 100644 net/minecraft/client/renderer/block/model/BlockFaceUV.java create mode 100644 net/minecraft/client/renderer/block/model/BlockModelPart.java create mode 100644 net/minecraft/client/renderer/block/model/BlockStateModel.java delete mode 100644 net/minecraft/client/renderer/block/model/MultiVariant.java create mode 100644 net/minecraft/client/renderer/block/model/SimpleModelWrapper.java create mode 100644 net/minecraft/client/renderer/block/model/SimpleUnbakedGeometry.java create mode 100644 net/minecraft/client/renderer/block/model/SingleVariant.java delete mode 100644 net/minecraft/client/renderer/block/model/UnbakedBlockStateModel.java create mode 100644 net/minecraft/client/renderer/block/model/VariantMutator.java delete mode 100644 net/minecraft/client/renderer/block/model/multipart/AndCondition.java create mode 100644 net/minecraft/client/renderer/block/model/multipart/CombinedCondition.java delete mode 100644 net/minecraft/client/renderer/block/model/multipart/MultiPart.java create mode 100644 net/minecraft/client/renderer/block/model/multipart/MultiPartModel.java delete mode 100644 net/minecraft/client/renderer/block/model/multipart/OrCondition.java create mode 100644 net/minecraft/client/renderer/blockentity/BlockEntityWithBoundingBoxRenderer.java delete mode 100644 net/minecraft/client/renderer/blockentity/StructureBlockRenderer.java create mode 100644 net/minecraft/client/renderer/blockentity/TestInstanceRenderer.java delete mode 100644 net/minecraft/client/renderer/entity/layers/HorseArmorLayer.java delete mode 100644 net/minecraft/client/renderer/entity/layers/SaddleLayer.java create mode 100644 net/minecraft/client/renderer/entity/layers/SheepWoolUndercoatLayer.java create mode 100644 net/minecraft/client/renderer/entity/layers/SimpleEquipmentLayer.java create mode 100644 net/minecraft/client/renderer/entity/state/CowRenderState.java create mode 100644 net/minecraft/client/renderer/entity/state/HitboxRenderState.java create mode 100644 net/minecraft/client/renderer/entity/state/HitboxesRenderState.java delete mode 100644 net/minecraft/client/renderer/entity/state/SaddleableRenderState.java create mode 100644 net/minecraft/client/renderer/entity/state/ServerHitboxesRenderState.java create mode 100644 net/minecraft/client/renderer/item/ModelRenderProperties.java create mode 100644 net/minecraft/client/renderer/item/properties/conditional/ComponentMatches.java create mode 100644 net/minecraft/client/renderer/item/properties/conditional/ItemModelPropertyTest.java create mode 100644 net/minecraft/client/renderer/item/properties/select/ComponentContents.java delete mode 100644 net/minecraft/client/renderer/texture/atlas/SpriteSourceType.java create mode 100644 net/minecraft/client/resources/DryFoliageColorReloadListener.java create mode 100644 net/minecraft/client/resources/model/AtlasIds.java delete mode 100644 net/minecraft/client/resources/model/BakedModel.java create mode 100644 net/minecraft/client/resources/model/BlockStateDefinitions.java delete mode 100644 net/minecraft/client/resources/model/DelegateBakedModel.java delete mode 100644 net/minecraft/client/resources/model/ModelResourceLocation.java delete mode 100644 net/minecraft/client/resources/model/MultiPartBakedModel.java create mode 100644 net/minecraft/client/resources/model/QuadCollection.java create mode 100644 net/minecraft/client/resources/model/ResolvedModel.java delete mode 100644 net/minecraft/client/resources/model/SimpleBakedModel.java create mode 100644 net/minecraft/client/resources/model/UnbakedGeometry.java delete mode 100644 net/minecraft/client/resources/model/WeightedBakedModel.java create mode 100644 net/minecraft/client/resources/model/WeightedVariants.java create mode 100644 net/minecraft/commands/arguments/ResourceSelectorArgument.java create mode 100644 net/minecraft/core/ClientAsset.java rename net/minecraft/core/component/{DataComponentPredicate.java => DataComponentExactPredicate.java} (53%) create mode 100644 net/minecraft/core/component/DataComponentGetter.java create mode 100644 net/minecraft/core/component/predicates/AttributeModifiersPredicate.java create mode 100644 net/minecraft/core/component/predicates/BundlePredicate.java create mode 100644 net/minecraft/core/component/predicates/ContainerPredicate.java create mode 100644 net/minecraft/core/component/predicates/CustomDataPredicate.java create mode 100644 net/minecraft/core/component/predicates/DamagePredicate.java create mode 100644 net/minecraft/core/component/predicates/DataComponentPredicate.java create mode 100644 net/minecraft/core/component/predicates/DataComponentPredicates.java create mode 100644 net/minecraft/core/component/predicates/EnchantmentsPredicate.java create mode 100644 net/minecraft/core/component/predicates/FireworkExplosionPredicate.java create mode 100644 net/minecraft/core/component/predicates/FireworksPredicate.java rename net/minecraft/{advancements/critereon/ItemJukeboxPlayablePredicate.java => core/component/predicates/JukeboxPlayablePredicate.java} (57%) rename net/minecraft/{advancements/critereon/ItemPotionsPredicate.java => core/component/predicates/PotionsPredicate.java} (55%) rename net/minecraft/{advancements/critereon/ItemTrimPredicate.java => core/component/predicates/TrimPredicate.java} (67%) create mode 100644 net/minecraft/core/component/predicates/WritableBookPredicate.java rename net/minecraft/{advancements/critereon/ItemWrittenBookPredicate.java => core/component/predicates/WrittenBookPredicate.java} (50%) create mode 100644 net/minecraft/core/component/predicates/package-info.java delete mode 100644 net/minecraft/data/tags/CatVariantTagsProvider.java delete mode 100644 net/minecraft/data/tags/TradeRebalanceStructureTagsProvider.java create mode 100644 net/minecraft/gametest/Main.java delete mode 100644 net/minecraft/gametest/framework/AfterBatch.java delete mode 100644 net/minecraft/gametest/framework/BeforeBatch.java create mode 100644 net/minecraft/gametest/framework/BlockBasedTestInstance.java create mode 100644 net/minecraft/gametest/framework/BuiltinTestFunctions.java create mode 100644 net/minecraft/gametest/framework/FailedTestTracker.java create mode 100644 net/minecraft/gametest/framework/FunctionGameTestInstance.java delete mode 100644 net/minecraft/gametest/framework/GameTest.java create mode 100644 net/minecraft/gametest/framework/GameTestEnvironments.java create mode 100644 net/minecraft/gametest/framework/GameTestException.java delete mode 100644 net/minecraft/gametest/framework/GameTestGenerator.java create mode 100644 net/minecraft/gametest/framework/GameTestInstance.java create mode 100644 net/minecraft/gametest/framework/GameTestInstances.java create mode 100644 net/minecraft/gametest/framework/GameTestMainUtil.java delete mode 100644 net/minecraft/gametest/framework/GameTestRegistry.java create mode 100644 net/minecraft/gametest/framework/GeneratedTest.java delete mode 100644 net/minecraft/gametest/framework/TestClassNameArgument.java create mode 100644 net/minecraft/gametest/framework/TestData.java create mode 100644 net/minecraft/gametest/framework/TestEnvironmentDefinition.java delete mode 100644 net/minecraft/gametest/framework/TestFunction.java delete mode 100644 net/minecraft/gametest/framework/TestFunctionArgument.java delete mode 100644 net/minecraft/gametest/framework/TestFunctionFinder.java create mode 100644 net/minecraft/gametest/framework/TestFunctionLoader.java create mode 100644 net/minecraft/gametest/framework/TestInstanceFinder.java rename net/minecraft/gametest/framework/{StructureBlockPosFinder.java => TestPosFinder.java} (61%) create mode 100644 net/minecraft/gametest/framework/UnknownGameTestException.java create mode 100644 net/minecraft/nbt/PrimitiveTag.java create mode 100644 net/minecraft/nbt/SnbtGrammar.java create mode 100644 net/minecraft/nbt/SnbtOperations.java create mode 100644 net/minecraft/network/HashedPatchMap.java create mode 100644 net/minecraft/network/HashedStack.java create mode 100644 net/minecraft/network/SkipPacketDecoderException.java create mode 100644 net/minecraft/network/SkipPacketEncoderException.java create mode 100644 net/minecraft/network/protocol/CodecModifier.java create mode 100644 net/minecraft/network/protocol/SimpleUnboundProtocol.java create mode 100644 net/minecraft/network/protocol/UnboundProtocol.java delete mode 100644 net/minecraft/network/protocol/game/ClientboundAddExperienceOrbPacket.java create mode 100644 net/minecraft/network/protocol/game/ClientboundTestInstanceBlockStatus.java create mode 100644 net/minecraft/network/protocol/game/ServerboundSetTestBlockPacket.java create mode 100644 net/minecraft/network/protocol/game/ServerboundTestInstanceBlockActionPacket.java create mode 100644 net/minecraft/server/commands/InCommandFunction.java create mode 100644 net/minecraft/server/level/LoadingChunkTracker.java create mode 100644 net/minecraft/server/level/SimulationChunkTracker.java delete mode 100644 net/minecraft/server/level/TickingTracker.java delete mode 100644 net/minecraft/tags/CatVariantTags.java create mode 100644 net/minecraft/util/AbstractListBuilder.java create mode 100644 net/minecraft/util/FileSystemUtil.java create mode 100644 net/minecraft/util/HashOps.java create mode 100644 net/minecraft/util/PlaceholderLookupProvider.java create mode 100644 net/minecraft/util/RegistryContextSwapper.java delete mode 100644 net/minecraft/util/datafix/ComponentDataFixUtils.java create mode 100644 net/minecraft/util/datafix/LegacyComponentDataFixUtils.java create mode 100644 net/minecraft/util/datafix/fixes/AbstractBlockPropertyFix.java create mode 100644 net/minecraft/util/datafix/fixes/AreaEffectCloudDurationScaleFix.java delete mode 100644 net/minecraft/util/datafix/fixes/BlockEntitySignTextStrictJsonFix.java create mode 100644 net/minecraft/util/datafix/fixes/BlockPropertyRenameAndFix.java create mode 100644 net/minecraft/util/datafix/fixes/ChunkTicketUnpackPosFix.java create mode 100644 net/minecraft/util/datafix/fixes/DropChancesFormatFix.java create mode 100644 net/minecraft/util/datafix/fixes/EntityFallDistanceFloatToDoubleFix.java create mode 100644 net/minecraft/util/datafix/fixes/EntitySpawnerItemVariantComponentFix.java create mode 100644 net/minecraft/util/datafix/fixes/EquipmentFormatFix.java rename net/minecraft/util/datafix/{ => fixes}/FixWolfHealth.java (91%) create mode 100644 net/minecraft/util/datafix/fixes/ForcedChunkToTicketFix.java create mode 100644 net/minecraft/util/datafix/fixes/InlineBlockPosFormatFix.java create mode 100644 net/minecraft/util/datafix/fixes/ItemStackTagRemainderFix.java delete mode 100644 net/minecraft/util/datafix/fixes/ItemWrittenBookPagesStrictJsonFix.java create mode 100644 net/minecraft/util/datafix/fixes/LegacyHoverEventFix.java create mode 100644 net/minecraft/util/datafix/fixes/NamedEntityConvertUncheckedFix.java delete mode 100644 net/minecraft/util/datafix/fixes/ObjectiveDisplayNameFix.java create mode 100644 net/minecraft/util/datafix/fixes/PlayerEquipmentFix.java create mode 100644 net/minecraft/util/datafix/fixes/RaidRenamesDataFix.java create mode 100644 net/minecraft/util/datafix/fixes/SaddleEquipmentSlotFix.java create mode 100644 net/minecraft/util/datafix/fixes/ScoreboardDisplayNameFix.java delete mode 100644 net/minecraft/util/datafix/fixes/TeamDisplayNameFix.java create mode 100644 net/minecraft/util/datafix/fixes/TextComponentHoverAndClickEventFix.java create mode 100644 net/minecraft/util/datafix/fixes/TextComponentStrictJsonFix.java create mode 100644 net/minecraft/util/datafix/fixes/TextComponentStringifiedFlagsFix.java create mode 100644 net/minecraft/util/datafix/fixes/ThrownPotionSplitFix.java create mode 100644 net/minecraft/util/datafix/fixes/TooltipDisplayComponentFix.java create mode 100644 net/minecraft/util/datafix/fixes/UnflattenTextComponentFix.java create mode 100644 net/minecraft/util/datafix/schemas/V1458.java create mode 100644 net/minecraft/util/datafix/schemas/V1488.java create mode 100644 net/minecraft/util/datafix/schemas/V1925.java create mode 100644 net/minecraft/util/datafix/schemas/V2511_1.java create mode 100644 net/minecraft/util/datafix/schemas/V3439.java create mode 100644 net/minecraft/util/datafix/schemas/V3813.java create mode 100644 net/minecraft/util/datafix/schemas/V4290.java create mode 100644 net/minecraft/util/datafix/schemas/V4292.java create mode 100644 net/minecraft/util/datafix/schemas/V4300.java create mode 100644 net/minecraft/util/datafix/schemas/V4301.java create mode 100644 net/minecraft/util/datafix/schemas/V4302.java create mode 100644 net/minecraft/util/datafix/schemas/V4306.java create mode 100644 net/minecraft/util/datafix/schemas/V4307.java create mode 100644 net/minecraft/util/datafix/schemas/V4312.java create mode 100644 net/minecraft/util/parsing/packrat/CachedParseState.java create mode 100644 net/minecraft/util/parsing/packrat/DelayedException.java create mode 100644 net/minecraft/util/parsing/packrat/NamedRule.java create mode 100644 net/minecraft/util/parsing/packrat/commands/CommandArgumentParser.java create mode 100644 net/minecraft/util/parsing/packrat/commands/GreedyPatternParseRule.java create mode 100644 net/minecraft/util/parsing/packrat/commands/GreedyPredicateParseRule.java create mode 100644 net/minecraft/util/parsing/packrat/commands/NumberRunParseRule.java create mode 100644 net/minecraft/util/parsing/packrat/commands/ParserBasedArgument.java create mode 100644 net/minecraft/util/parsing/packrat/commands/UnquotedStringParseRule.java delete mode 100644 net/minecraft/util/random/SimpleWeightedRandomList.java delete mode 100644 net/minecraft/util/random/Weight.java create mode 100644 net/minecraft/util/random/Weighted.java delete mode 100644 net/minecraft/util/random/WeightedEntry.java create mode 100644 net/minecraft/util/random/WeightedList.java delete mode 100644 net/minecraft/util/random/WeightedRandomList.java create mode 100644 net/minecraft/util/thread/ParallelMapTransform.java create mode 100644 net/minecraft/world/entity/DropChances.java create mode 100644 net/minecraft/world/entity/EntityEquipment.java create mode 100644 net/minecraft/world/entity/EntityReference.java create mode 100644 net/minecraft/world/entity/InsideBlockEffectApplier.java create mode 100644 net/minecraft/world/entity/InsideBlockEffectType.java create mode 100644 net/minecraft/world/entity/InterpolationHandler.java delete mode 100644 net/minecraft/world/entity/Saddleable.java delete mode 100644 net/minecraft/world/entity/VariantHolder.java create mode 100644 net/minecraft/world/entity/animal/AbstractCow.java create mode 100644 net/minecraft/world/entity/animal/CatVariants.java create mode 100644 net/minecraft/world/entity/animal/ChickenVariant.java create mode 100644 net/minecraft/world/entity/animal/ChickenVariants.java create mode 100644 net/minecraft/world/entity/animal/CowVariant.java create mode 100644 net/minecraft/world/entity/animal/CowVariants.java delete mode 100644 net/minecraft/world/entity/animal/FrogVariant.java create mode 100644 net/minecraft/world/entity/animal/PigVariant.java create mode 100644 net/minecraft/world/entity/animal/PigVariants.java create mode 100644 net/minecraft/world/entity/animal/TemperatureVariants.java delete mode 100644 net/minecraft/world/entity/animal/WolfVariant.java create mode 100644 net/minecraft/world/entity/animal/frog/FrogVariant.java create mode 100644 net/minecraft/world/entity/animal/frog/FrogVariants.java rename net/minecraft/world/entity/animal/{ => sheep}/Sheep.java (79%) create mode 100644 net/minecraft/world/entity/animal/sheep/SheepColorSpawnRules.java create mode 100644 net/minecraft/world/entity/animal/sheep/package-info.java rename net/minecraft/world/entity/animal/{ => wolf}/Wolf.java (79%) create mode 100644 net/minecraft/world/entity/animal/wolf/WolfSoundVariant.java create mode 100644 net/minecraft/world/entity/animal/wolf/WolfSoundVariants.java create mode 100644 net/minecraft/world/entity/animal/wolf/WolfVariant.java rename net/minecraft/world/entity/animal/{ => wolf}/WolfVariants.java (57%) create mode 100644 net/minecraft/world/entity/animal/wolf/package-info.java create mode 100644 net/minecraft/world/entity/player/PlayerEquipment.java rename net/minecraft/world/entity/projectile/{ThrownPotion.java => AbstractThrownPotion.java} (58%) create mode 100644 net/minecraft/world/entity/projectile/ThrownLingeringPotion.java create mode 100644 net/minecraft/world/entity/projectile/ThrownSplashPotion.java create mode 100644 net/minecraft/world/entity/variant/BiomeCheck.java create mode 100644 net/minecraft/world/entity/variant/ModelAndTexture.java create mode 100644 net/minecraft/world/entity/variant/MoonBrightnessCheck.java create mode 100644 net/minecraft/world/entity/variant/PriorityProvider.java create mode 100644 net/minecraft/world/entity/variant/SpawnCondition.java create mode 100644 net/minecraft/world/entity/variant/SpawnConditions.java create mode 100644 net/minecraft/world/entity/variant/SpawnContext.java create mode 100644 net/minecraft/world/entity/variant/SpawnPrioritySelectors.java create mode 100644 net/minecraft/world/entity/variant/StructureCheck.java create mode 100644 net/minecraft/world/entity/variant/VariantUtils.java create mode 100644 net/minecraft/world/entity/variant/package-info.java create mode 100644 net/minecraft/world/inventory/RemoteSlot.java delete mode 100644 net/minecraft/world/item/AnimalArmorItem.java delete mode 100644 net/minecraft/world/item/ArmorItem.java delete mode 100644 net/minecraft/world/item/BannerPatternItem.java delete mode 100644 net/minecraft/world/item/DiggerItem.java delete mode 100644 net/minecraft/world/item/FireworkStarItem.java delete mode 100644 net/minecraft/world/item/PickaxeItem.java delete mode 100644 net/minecraft/world/item/SaddleItem.java delete mode 100644 net/minecraft/world/item/SwordItem.java create mode 100644 net/minecraft/world/item/component/Bees.java create mode 100644 net/minecraft/world/item/component/BlocksAttacks.java create mode 100644 net/minecraft/world/item/component/InstrumentComponent.java create mode 100644 net/minecraft/world/item/component/ProvidesTrimMaterial.java create mode 100644 net/minecraft/world/item/component/TooltipDisplay.java delete mode 100644 net/minecraft/world/item/component/Unbreakable.java create mode 100644 net/minecraft/world/item/component/Weapon.java create mode 100644 net/minecraft/world/item/crafting/TransmuteResult.java create mode 100644 net/minecraft/world/item/equipment/AllowedEntitiesProvider.java create mode 100644 net/minecraft/world/item/equipment/trim/MaterialAssetGroup.java create mode 100644 net/minecraft/world/level/ColorMapColorUtil.java create mode 100644 net/minecraft/world/level/DryFoliageColor.java delete mode 100644 net/minecraft/world/level/ForcedChunksSavedData.java create mode 100644 net/minecraft/world/level/TicketStorage.java rename net/minecraft/world/level/block/{DeadBushBlock.java => CactusFlowerBlock.java} (54%) create mode 100644 net/minecraft/world/level/block/DryVegetationBlock.java create mode 100644 net/minecraft/world/level/block/FireflyBushBlock.java rename net/minecraft/world/level/block/{PinkPetalsBlock.java => FlowerBedBlock.java} (60%) create mode 100644 net/minecraft/world/level/block/LeafLitterBlock.java delete mode 100644 net/minecraft/world/level/block/ParticleLeavesBlock.java create mode 100644 net/minecraft/world/level/block/SandBlock.java create mode 100644 net/minecraft/world/level/block/SegmentableBlock.java create mode 100644 net/minecraft/world/level/block/ShortDryGrassBlock.java create mode 100644 net/minecraft/world/level/block/TallDryGrassBlock.java create mode 100644 net/minecraft/world/level/block/TerracottaBlock.java create mode 100644 net/minecraft/world/level/block/TestBlock.java create mode 100644 net/minecraft/world/level/block/TestInstanceBlock.java create mode 100644 net/minecraft/world/level/block/TintedParticleLeavesBlock.java create mode 100644 net/minecraft/world/level/block/UntintedParticleLeavesBlock.java create mode 100644 net/minecraft/world/level/block/VegetationBlock.java create mode 100644 net/minecraft/world/level/block/entity/BeaconBeamOwner.java create mode 100644 net/minecraft/world/level/block/entity/BoundingBoxRenderable.java create mode 100644 net/minecraft/world/level/block/entity/TestBlockEntity.java create mode 100644 net/minecraft/world/level/block/entity/TestInstanceBlockEntity.java create mode 100644 net/minecraft/world/level/block/sounds/AmbientDesertBlockSoundsPlayer.java create mode 100644 net/minecraft/world/level/block/state/properties/CreakingHeartState.java create mode 100644 net/minecraft/world/level/block/state/properties/TestBlockMode.java create mode 100644 net/minecraft/world/level/entity/UUIDLookup.java create mode 100644 net/minecraft/world/level/entity/UniquelyIdentifyable.java create mode 100644 net/minecraft/world/level/levelgen/feature/FallenTreeFeature.java create mode 100644 net/minecraft/world/level/levelgen/feature/configurations/FallenTreeConfiguration.java create mode 100644 net/minecraft/world/level/levelgen/feature/treedecorators/AttachedToLogsDecorator.java create mode 100644 net/minecraft/world/level/levelgen/feature/treedecorators/PlaceOnGroundDecorator.java rename net/minecraft/world/level/levelgen/structure/pools/alias/{Direct.java => DirectPoolAlias.java} (72%) delete mode 100644 net/minecraft/world/level/levelgen/structure/pools/alias/RandomGroup.java create mode 100644 net/minecraft/world/level/levelgen/structure/pools/alias/RandomGroupPoolAlias.java rename net/minecraft/world/level/levelgen/structure/pools/alias/{Random.java => RandomPoolAlias.java} (52%) create mode 100644 net/minecraft/world/level/saveddata/SavedDataType.java diff --git a/assets/minecraft/atlases/armor_trims.json b/assets/minecraft/atlases/armor_trims.json index e2fdafaa..7e92af33 100644 --- a/assets/minecraft/atlases/armor_trims.json +++ b/assets/minecraft/atlases/armor_trims.json @@ -1,63 +1,63 @@ { - "sources": [ - { - "type": "paletted_permutations", - "textures": [ - "trims/entity/humanoid/coast", - "trims/entity/humanoid_leggings/coast", - "trims/entity/humanoid/sentry", - "trims/entity/humanoid_leggings/sentry", - "trims/entity/humanoid/dune", - "trims/entity/humanoid_leggings/dune", - "trims/entity/humanoid/wild", - "trims/entity/humanoid_leggings/wild", - "trims/entity/humanoid/ward", - "trims/entity/humanoid_leggings/ward", - "trims/entity/humanoid/eye", - "trims/entity/humanoid_leggings/eye", - "trims/entity/humanoid/vex", - "trims/entity/humanoid_leggings/vex", - "trims/entity/humanoid/tide", - "trims/entity/humanoid_leggings/tide", - "trims/entity/humanoid/snout", - "trims/entity/humanoid_leggings/snout", - "trims/entity/humanoid/rib", - "trims/entity/humanoid_leggings/rib", - "trims/entity/humanoid/spire", - "trims/entity/humanoid_leggings/spire", - "trims/entity/humanoid/wayfinder", - "trims/entity/humanoid_leggings/wayfinder", - "trims/entity/humanoid/shaper", - "trims/entity/humanoid_leggings/shaper", - "trims/entity/humanoid/silence", - "trims/entity/humanoid_leggings/silence", - "trims/entity/humanoid/raiser", - "trims/entity/humanoid_leggings/raiser", - "trims/entity/humanoid/host", - "trims/entity/humanoid_leggings/host", - "trims/entity/humanoid/flow", - "trims/entity/humanoid_leggings/flow", - "trims/entity/humanoid/bolt", - "trims/entity/humanoid_leggings/bolt" - ], - "palette_key": "trims/color_palettes/trim_palette", - "permutations": { - "quartz": "trims/color_palettes/quartz", - "iron": "trims/color_palettes/iron", - "gold": "trims/color_palettes/gold", - "diamond": "trims/color_palettes/diamond", - "netherite": "trims/color_palettes/netherite", - "redstone": "trims/color_palettes/redstone", - "copper": "trims/color_palettes/copper", - "emerald": "trims/color_palettes/emerald", - "lapis": "trims/color_palettes/lapis", - "amethyst": "trims/color_palettes/amethyst", - "iron_darker": "trims/color_palettes/iron_darker", - "gold_darker": "trims/color_palettes/gold_darker", - "diamond_darker": "trims/color_palettes/diamond_darker", - "netherite_darker": "trims/color_palettes/netherite_darker", - "resin": "trims/color_palettes/resin" - } - } - ] -} + "sources": [ + { + "type": "minecraft:paletted_permutations", + "palette_key": "minecraft:trims/color_palettes/trim_palette", + "permutations": { + "amethyst": "minecraft:trims/color_palettes/amethyst", + "copper": "minecraft:trims/color_palettes/copper", + "diamond": "minecraft:trims/color_palettes/diamond", + "diamond_darker": "minecraft:trims/color_palettes/diamond_darker", + "emerald": "minecraft:trims/color_palettes/emerald", + "gold": "minecraft:trims/color_palettes/gold", + "gold_darker": "minecraft:trims/color_palettes/gold_darker", + "iron": "minecraft:trims/color_palettes/iron", + "iron_darker": "minecraft:trims/color_palettes/iron_darker", + "lapis": "minecraft:trims/color_palettes/lapis", + "netherite": "minecraft:trims/color_palettes/netherite", + "netherite_darker": "minecraft:trims/color_palettes/netherite_darker", + "quartz": "minecraft:trims/color_palettes/quartz", + "redstone": "minecraft:trims/color_palettes/redstone", + "resin": "minecraft:trims/color_palettes/resin" + }, + "textures": [ + "minecraft:trims/entity/humanoid/sentry", + "minecraft:trims/entity/humanoid_leggings/sentry", + "minecraft:trims/entity/humanoid/dune", + "minecraft:trims/entity/humanoid_leggings/dune", + "minecraft:trims/entity/humanoid/coast", + "minecraft:trims/entity/humanoid_leggings/coast", + "minecraft:trims/entity/humanoid/wild", + "minecraft:trims/entity/humanoid_leggings/wild", + "minecraft:trims/entity/humanoid/ward", + "minecraft:trims/entity/humanoid_leggings/ward", + "minecraft:trims/entity/humanoid/eye", + "minecraft:trims/entity/humanoid_leggings/eye", + "minecraft:trims/entity/humanoid/vex", + "minecraft:trims/entity/humanoid_leggings/vex", + "minecraft:trims/entity/humanoid/tide", + "minecraft:trims/entity/humanoid_leggings/tide", + "minecraft:trims/entity/humanoid/snout", + "minecraft:trims/entity/humanoid_leggings/snout", + "minecraft:trims/entity/humanoid/rib", + "minecraft:trims/entity/humanoid_leggings/rib", + "minecraft:trims/entity/humanoid/spire", + "minecraft:trims/entity/humanoid_leggings/spire", + "minecraft:trims/entity/humanoid/wayfinder", + "minecraft:trims/entity/humanoid_leggings/wayfinder", + "minecraft:trims/entity/humanoid/shaper", + "minecraft:trims/entity/humanoid_leggings/shaper", + "minecraft:trims/entity/humanoid/silence", + "minecraft:trims/entity/humanoid_leggings/silence", + "minecraft:trims/entity/humanoid/raiser", + "minecraft:trims/entity/humanoid_leggings/raiser", + "minecraft:trims/entity/humanoid/host", + "minecraft:trims/entity/humanoid_leggings/host", + "minecraft:trims/entity/humanoid/flow", + "minecraft:trims/entity/humanoid_leggings/flow", + "minecraft:trims/entity/humanoid/bolt", + "minecraft:trims/entity/humanoid_leggings/bolt" + ] + } + ] +} \ No newline at end of file diff --git a/assets/minecraft/atlases/banner_patterns.json b/assets/minecraft/atlases/banner_patterns.json index e9f9dce7..b683a982 100644 --- a/assets/minecraft/atlases/banner_patterns.json +++ b/assets/minecraft/atlases/banner_patterns.json @@ -1,13 +1,13 @@ { - "sources": [ - { - "type": "single", - "resource": "entity/banner_base" - }, - { - "type": "directory", - "source": "entity/banner", - "prefix": "entity/banner/" - } - ] + "sources": [ + { + "type": "minecraft:single", + "resource": "minecraft:entity/banner_base" + }, + { + "type": "minecraft:directory", + "prefix": "entity/banner/", + "source": "entity/banner" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/atlases/beds.json b/assets/minecraft/atlases/beds.json index 7d552c51..d2e798a5 100644 --- a/assets/minecraft/atlases/beds.json +++ b/assets/minecraft/atlases/beds.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "entity/bed", - "prefix": "entity/bed/" - } - ] + "sources": [ + { + "type": "minecraft:directory", + "prefix": "entity/bed/", + "source": "entity/bed" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/atlases/blocks.json b/assets/minecraft/atlases/blocks.json index 9f54d919..d2cf5a79 100644 --- a/assets/minecraft/atlases/blocks.json +++ b/assets/minecraft/atlases/blocks.json @@ -1,58 +1,58 @@ { - "sources": [ - { - "type": "directory", - "source": "block", - "prefix": "block/" - }, - { - "type": "directory", - "source": "item", - "prefix": "item/" - }, - { - "type": "directory", - "source": "entity/conduit", - "prefix": "entity/conduit/" - }, - { - "type": "single", - "resource": "entity/bell/bell_body" - }, - { - "type": "single", - "resource": "entity/decorated_pot/decorated_pot_side" - }, - { - "type": "single", - "resource": "entity/enchanting_table_book" - }, - { - "type": "paletted_permutations", - "textures": [ - "trims/items/leggings_trim", - "trims/items/chestplate_trim", - "trims/items/helmet_trim", - "trims/items/boots_trim" - ], - "palette_key": "trims/color_palettes/trim_palette", - "permutations": { - "quartz": "trims/color_palettes/quartz", - "iron": "trims/color_palettes/iron", - "gold": "trims/color_palettes/gold", - "diamond": "trims/color_palettes/diamond", - "netherite": "trims/color_palettes/netherite", - "redstone": "trims/color_palettes/redstone", - "copper": "trims/color_palettes/copper", - "emerald": "trims/color_palettes/emerald", - "lapis": "trims/color_palettes/lapis", - "amethyst": "trims/color_palettes/amethyst", - "iron_darker": "trims/color_palettes/iron_darker", - "gold_darker": "trims/color_palettes/gold_darker", - "diamond_darker": "trims/color_palettes/diamond_darker", - "netherite_darker": "trims/color_palettes/netherite_darker", - "resin": "trims/color_palettes/resin" - } - } - ] -} + "sources": [ + { + "type": "minecraft:directory", + "prefix": "block/", + "source": "block" + }, + { + "type": "minecraft:directory", + "prefix": "item/", + "source": "item" + }, + { + "type": "minecraft:directory", + "prefix": "entity/conduit/", + "source": "entity/conduit" + }, + { + "type": "minecraft:single", + "resource": "minecraft:entity/bell/bell_body" + }, + { + "type": "minecraft:single", + "resource": "minecraft:entity/decorated_pot/decorated_pot_side" + }, + { + "type": "minecraft:single", + "resource": "minecraft:entity/enchanting_table_book" + }, + { + "type": "minecraft:paletted_permutations", + "palette_key": "minecraft:trims/color_palettes/trim_palette", + "permutations": { + "amethyst": "minecraft:trims/color_palettes/amethyst", + "copper": "minecraft:trims/color_palettes/copper", + "diamond": "minecraft:trims/color_palettes/diamond", + "diamond_darker": "minecraft:trims/color_palettes/diamond_darker", + "emerald": "minecraft:trims/color_palettes/emerald", + "gold": "minecraft:trims/color_palettes/gold", + "gold_darker": "minecraft:trims/color_palettes/gold_darker", + "iron": "minecraft:trims/color_palettes/iron", + "iron_darker": "minecraft:trims/color_palettes/iron_darker", + "lapis": "minecraft:trims/color_palettes/lapis", + "netherite": "minecraft:trims/color_palettes/netherite", + "netherite_darker": "minecraft:trims/color_palettes/netherite_darker", + "quartz": "minecraft:trims/color_palettes/quartz", + "redstone": "minecraft:trims/color_palettes/redstone", + "resin": "minecraft:trims/color_palettes/resin" + }, + "textures": [ + "minecraft:trims/items/helmet_trim", + "minecraft:trims/items/chestplate_trim", + "minecraft:trims/items/leggings_trim", + "minecraft:trims/items/boots_trim" + ] + } + ] +} \ No newline at end of file diff --git a/assets/minecraft/atlases/chests.json b/assets/minecraft/atlases/chests.json index 963ff39c..81a68b1c 100644 --- a/assets/minecraft/atlases/chests.json +++ b/assets/minecraft/atlases/chests.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "entity/chest", - "prefix": "entity/chest/" - } - ] + "sources": [ + { + "type": "minecraft:directory", + "prefix": "entity/chest/", + "source": "entity/chest" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/atlases/decorated_pot.json b/assets/minecraft/atlases/decorated_pot.json index 0eb56e55..57356d98 100644 --- a/assets/minecraft/atlases/decorated_pot.json +++ b/assets/minecraft/atlases/decorated_pot.json @@ -1,9 +1,9 @@ { "sources": [ { - "type": "directory", - "source": "entity/decorated_pot", - "prefix": "entity/decorated_pot/" + "type": "minecraft:directory", + "prefix": "entity/decorated_pot/", + "source": "entity/decorated_pot" } ] -} +} \ No newline at end of file diff --git a/assets/minecraft/atlases/gui.json b/assets/minecraft/atlases/gui.json index b76173f0..fd2c246a 100644 --- a/assets/minecraft/atlases/gui.json +++ b/assets/minecraft/atlases/gui.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "gui/sprites", - "prefix": "" - } - ] -} + "sources": [ + { + "type": "minecraft:directory", + "prefix": "", + "source": "gui/sprites" + } + ] +} \ No newline at end of file diff --git a/assets/minecraft/atlases/map_decorations.json b/assets/minecraft/atlases/map_decorations.json index 2bd4ced9..f5cf7910 100644 --- a/assets/minecraft/atlases/map_decorations.json +++ b/assets/minecraft/atlases/map_decorations.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "map/decorations", - "prefix": "" - } - ] -} + "sources": [ + { + "type": "minecraft:directory", + "prefix": "", + "source": "map/decorations" + } + ] +} \ No newline at end of file diff --git a/assets/minecraft/atlases/mob_effects.json b/assets/minecraft/atlases/mob_effects.json index cb14804c..d159398c 100644 --- a/assets/minecraft/atlases/mob_effects.json +++ b/assets/minecraft/atlases/mob_effects.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "mob_effect", - "prefix": "" - } - ] + "sources": [ + { + "type": "minecraft:directory", + "prefix": "", + "source": "mob_effect" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/atlases/paintings.json b/assets/minecraft/atlases/paintings.json index 4153b347..1345d6d1 100644 --- a/assets/minecraft/atlases/paintings.json +++ b/assets/minecraft/atlases/paintings.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "painting", - "prefix": "" - } - ] + "sources": [ + { + "type": "minecraft:directory", + "prefix": "", + "source": "painting" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/atlases/particles.json b/assets/minecraft/atlases/particles.json index 896f5af1..18229aff 100644 --- a/assets/minecraft/atlases/particles.json +++ b/assets/minecraft/atlases/particles.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "particle", - "prefix": "" - } - ] + "sources": [ + { + "type": "minecraft:directory", + "prefix": "", + "source": "particle" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/atlases/shield_patterns.json b/assets/minecraft/atlases/shield_patterns.json index 94486579..77793ed1 100644 --- a/assets/minecraft/atlases/shield_patterns.json +++ b/assets/minecraft/atlases/shield_patterns.json @@ -1,17 +1,17 @@ { - "sources": [ - { - "type": "single", - "resource": "entity/shield_base" - }, - { - "type": "single", - "resource": "entity/shield_base_nopattern" - }, - { - "type": "directory", - "source": "entity/shield", - "prefix": "entity/shield/" - } - ] + "sources": [ + { + "type": "minecraft:single", + "resource": "minecraft:entity/shield_base" + }, + { + "type": "minecraft:single", + "resource": "minecraft:entity/shield_base_nopattern" + }, + { + "type": "minecraft:directory", + "prefix": "entity/shield/", + "source": "entity/shield" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/atlases/shulker_boxes.json b/assets/minecraft/atlases/shulker_boxes.json index 2e519094..d4ecef71 100644 --- a/assets/minecraft/atlases/shulker_boxes.json +++ b/assets/minecraft/atlases/shulker_boxes.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "entity/shulker", - "prefix": "entity/shulker/" - } - ] + "sources": [ + { + "type": "minecraft:directory", + "prefix": "entity/shulker/", + "source": "entity/shulker" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/atlases/signs.json b/assets/minecraft/atlases/signs.json index dc198756..1f34aaa1 100644 --- a/assets/minecraft/atlases/signs.json +++ b/assets/minecraft/atlases/signs.json @@ -1,9 +1,9 @@ { - "sources": [ - { - "type": "directory", - "source": "entity/signs", - "prefix": "entity/signs/" - } - ] + "sources": [ + { + "type": "minecraft:directory", + "prefix": "entity/signs/", + "source": "entity/signs" + } + ] } \ No newline at end of file diff --git a/assets/minecraft/blockstates/acacia_trapdoor.json b/assets/minecraft/blockstates/acacia_trapdoor.json index b91b2fc0..3518fc7a 100644 --- a/assets/minecraft/blockstates/acacia_trapdoor.json +++ b/assets/minecraft/blockstates/acacia_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/acacia_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/acacia_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/bamboo_fence.json b/assets/minecraft/blockstates/bamboo_fence.json index 8160db97..fe47ca8f 100644 --- a/assets/minecraft/blockstates/bamboo_fence.json +++ b/assets/minecraft/blockstates/bamboo_fence.json @@ -7,8 +7,7 @@ }, { "apply": { - "model": "minecraft:block/bamboo_fence_side_north", - "uvlock": false + "model": "minecraft:block/bamboo_fence_side_north" }, "when": { "north": "true" @@ -16,8 +15,7 @@ }, { "apply": { - "model": "minecraft:block/bamboo_fence_side_east", - "uvlock": false + "model": "minecraft:block/bamboo_fence_side_east" }, "when": { "east": "true" @@ -25,8 +23,7 @@ }, { "apply": { - "model": "minecraft:block/bamboo_fence_side_south", - "uvlock": false + "model": "minecraft:block/bamboo_fence_side_south" }, "when": { "south": "true" @@ -34,8 +31,7 @@ }, { "apply": { - "model": "minecraft:block/bamboo_fence_side_west", - "uvlock": false + "model": "minecraft:block/bamboo_fence_side_west" }, "when": { "west": "true" diff --git a/assets/minecraft/blockstates/bamboo_fence_gate.json b/assets/minecraft/blockstates/bamboo_fence_gate.json index 12111baf..f989df6c 100644 --- a/assets/minecraft/blockstates/bamboo_fence_gate.json +++ b/assets/minecraft/blockstates/bamboo_fence_gate.json @@ -2,78 +2,62 @@ "variants": { "facing=east,in_wall=false,open=false": { "model": "minecraft:block/bamboo_fence_gate", - "uvlock": false, "y": 270 }, "facing=east,in_wall=false,open=true": { "model": "minecraft:block/bamboo_fence_gate_open", - "uvlock": false, "y": 270 }, "facing=east,in_wall=true,open=false": { "model": "minecraft:block/bamboo_fence_gate_wall", - "uvlock": false, "y": 270 }, "facing=east,in_wall=true,open=true": { "model": "minecraft:block/bamboo_fence_gate_wall_open", - "uvlock": false, "y": 270 }, "facing=north,in_wall=false,open=false": { "model": "minecraft:block/bamboo_fence_gate", - "uvlock": false, "y": 180 }, "facing=north,in_wall=false,open=true": { "model": "minecraft:block/bamboo_fence_gate_open", - "uvlock": false, "y": 180 }, "facing=north,in_wall=true,open=false": { "model": "minecraft:block/bamboo_fence_gate_wall", - "uvlock": false, "y": 180 }, "facing=north,in_wall=true,open=true": { "model": "minecraft:block/bamboo_fence_gate_wall_open", - "uvlock": false, "y": 180 }, "facing=south,in_wall=false,open=false": { - "model": "minecraft:block/bamboo_fence_gate", - "uvlock": false + "model": "minecraft:block/bamboo_fence_gate" }, "facing=south,in_wall=false,open=true": { - "model": "minecraft:block/bamboo_fence_gate_open", - "uvlock": false + "model": "minecraft:block/bamboo_fence_gate_open" }, "facing=south,in_wall=true,open=false": { - "model": "minecraft:block/bamboo_fence_gate_wall", - "uvlock": false + "model": "minecraft:block/bamboo_fence_gate_wall" }, "facing=south,in_wall=true,open=true": { - "model": "minecraft:block/bamboo_fence_gate_wall_open", - "uvlock": false + "model": "minecraft:block/bamboo_fence_gate_wall_open" }, "facing=west,in_wall=false,open=false": { "model": "minecraft:block/bamboo_fence_gate", - "uvlock": false, "y": 90 }, "facing=west,in_wall=false,open=true": { "model": "minecraft:block/bamboo_fence_gate_open", - "uvlock": false, "y": 90 }, "facing=west,in_wall=true,open=false": { "model": "minecraft:block/bamboo_fence_gate_wall", - "uvlock": false, "y": 90 }, "facing=west,in_wall=true,open=true": { "model": "minecraft:block/bamboo_fence_gate_wall_open", - "uvlock": false, "y": 90 } } diff --git a/assets/minecraft/blockstates/bamboo_trapdoor.json b/assets/minecraft/blockstates/bamboo_trapdoor.json index 6b5d03b5..e1b5bd14 100644 --- a/assets/minecraft/blockstates/bamboo_trapdoor.json +++ b/assets/minecraft/blockstates/bamboo_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/bamboo_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/bamboo_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/birch_trapdoor.json b/assets/minecraft/blockstates/birch_trapdoor.json index 47b471d6..a8bb88c0 100644 --- a/assets/minecraft/blockstates/birch_trapdoor.json +++ b/assets/minecraft/blockstates/birch_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/birch_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/birch_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/brown_mushroom_block.json b/assets/minecraft/blockstates/brown_mushroom_block.json index be4820b4..9edb9370 100644 --- a/assets/minecraft/blockstates/brown_mushroom_block.json +++ b/assets/minecraft/blockstates/brown_mushroom_block.json @@ -69,7 +69,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 90 }, "when": { @@ -79,7 +78,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 180 }, "when": { @@ -89,7 +87,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 270 }, "when": { @@ -99,7 +96,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "x": 270 }, "when": { @@ -109,7 +105,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "x": 90 }, "when": { diff --git a/assets/minecraft/blockstates/bush.json b/assets/minecraft/blockstates/bush.json new file mode 100644 index 00000000..55d8078c --- /dev/null +++ b/assets/minecraft/blockstates/bush.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "minecraft:block/bush" + } + } +} \ No newline at end of file diff --git a/assets/minecraft/blockstates/cactus_flower.json b/assets/minecraft/blockstates/cactus_flower.json new file mode 100644 index 00000000..24f6f69b --- /dev/null +++ b/assets/minecraft/blockstates/cactus_flower.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "minecraft:block/cactus_flower" + } + } +} \ No newline at end of file diff --git a/assets/minecraft/blockstates/cherry_trapdoor.json b/assets/minecraft/blockstates/cherry_trapdoor.json index aa843d3f..90aac961 100644 --- a/assets/minecraft/blockstates/cherry_trapdoor.json +++ b/assets/minecraft/blockstates/cherry_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/cherry_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/cherry_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/chiseled_bookshelf.json b/assets/minecraft/blockstates/chiseled_bookshelf.json index 85ec035a..0c9b22b9 100644 --- a/assets/minecraft/blockstates/chiseled_bookshelf.json +++ b/assets/minecraft/blockstates/chiseled_bookshelf.json @@ -3,8 +3,7 @@ { "apply": { "model": "minecraft:block/chiseled_bookshelf", - "uvlock": true, - "y": 0 + "uvlock": true }, "when": { "facing": "north" @@ -12,8 +11,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_occupied_slot_top_left", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_occupied_slot_top_left" }, "when": { "AND": [ @@ -28,8 +26,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_empty_slot_top_left", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_empty_slot_top_left" }, "when": { "AND": [ @@ -44,8 +41,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_occupied_slot_top_mid", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_occupied_slot_top_mid" }, "when": { "AND": [ @@ -60,8 +56,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_empty_slot_top_mid", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_empty_slot_top_mid" }, "when": { "AND": [ @@ -76,8 +71,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_occupied_slot_top_right", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_occupied_slot_top_right" }, "when": { "AND": [ @@ -92,8 +86,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_empty_slot_top_right", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_empty_slot_top_right" }, "when": { "AND": [ @@ -108,8 +101,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_occupied_slot_bottom_left", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_occupied_slot_bottom_left" }, "when": { "AND": [ @@ -124,8 +116,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_empty_slot_bottom_left", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_empty_slot_bottom_left" }, "when": { "AND": [ @@ -140,8 +131,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_occupied_slot_bottom_mid", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_occupied_slot_bottom_mid" }, "when": { "AND": [ @@ -156,8 +146,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_empty_slot_bottom_mid", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_empty_slot_bottom_mid" }, "when": { "AND": [ @@ -172,8 +161,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_occupied_slot_bottom_right", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_occupied_slot_bottom_right" }, "when": { "AND": [ @@ -188,8 +176,7 @@ }, { "apply": { - "model": "minecraft:block/chiseled_bookshelf_empty_slot_bottom_right", - "y": 0 + "model": "minecraft:block/chiseled_bookshelf_empty_slot_bottom_right" }, "when": { "AND": [ diff --git a/assets/minecraft/blockstates/creaking_heart.json b/assets/minecraft/blockstates/creaking_heart.json index 6a3831ca..116f6e50 100644 --- a/assets/minecraft/blockstates/creaking_heart.json +++ b/assets/minecraft/blockstates/creaking_heart.json @@ -1,27 +1,39 @@ { "variants": { - "active=false,axis=x": { + "axis=x,creaking_heart_state=awake": { + "model": "minecraft:block/creaking_heart_awake_horizontal", + "x": 90, + "y": 90 + }, + "axis=x,creaking_heart_state=dormant": { + "model": "minecraft:block/creaking_heart_dormant_horizontal", + "x": 90, + "y": 90 + }, + "axis=x,creaking_heart_state=uprooted": { "model": "minecraft:block/creaking_heart_horizontal", "x": 90, "y": 90 }, - "active=false,axis=y": { + "axis=y,creaking_heart_state=awake": { + "model": "minecraft:block/creaking_heart_awake" + }, + "axis=y,creaking_heart_state=dormant": { + "model": "minecraft:block/creaking_heart_dormant" + }, + "axis=y,creaking_heart_state=uprooted": { "model": "minecraft:block/creaking_heart" }, - "active=false,axis=z": { - "model": "minecraft:block/creaking_heart_horizontal", + "axis=z,creaking_heart_state=awake": { + "model": "minecraft:block/creaking_heart_awake_horizontal", "x": 90 }, - "active=true,axis=x": { - "model": "minecraft:block/creaking_heart_active_horizontal", - "x": 90, - "y": 90 + "axis=z,creaking_heart_state=dormant": { + "model": "minecraft:block/creaking_heart_dormant_horizontal", + "x": 90 }, - "active=true,axis=y": { - "model": "minecraft:block/creaking_heart_active" - }, - "active=true,axis=z": { - "model": "minecraft:block/creaking_heart_active_horizontal", + "axis=z,creaking_heart_state=uprooted": { + "model": "minecraft:block/creaking_heart_horizontal", "x": 90 } } diff --git a/assets/minecraft/blockstates/crimson_trapdoor.json b/assets/minecraft/blockstates/crimson_trapdoor.json index a3be29c0..50f81360 100644 --- a/assets/minecraft/blockstates/crimson_trapdoor.json +++ b/assets/minecraft/blockstates/crimson_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/crimson_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/crimson_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/firefly_bush.json b/assets/minecraft/blockstates/firefly_bush.json new file mode 100644 index 00000000..37303453 --- /dev/null +++ b/assets/minecraft/blockstates/firefly_bush.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "minecraft:block/firefly_bush" + } + } +} \ No newline at end of file diff --git a/assets/minecraft/blockstates/jungle_trapdoor.json b/assets/minecraft/blockstates/jungle_trapdoor.json index 23178033..c858f773 100644 --- a/assets/minecraft/blockstates/jungle_trapdoor.json +++ b/assets/minecraft/blockstates/jungle_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/jungle_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/jungle_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/leaf_litter.json b/assets/minecraft/blockstates/leaf_litter.json new file mode 100644 index 00000000..165771c1 --- /dev/null +++ b/assets/minecraft/blockstates/leaf_litter.json @@ -0,0 +1,160 @@ +{ + "multipart": [ + { + "apply": { + "model": "minecraft:block/leaf_litter_1" + }, + "when": { + "facing": "north", + "segment_amount": "1" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_1", + "y": 90 + }, + "when": { + "facing": "east", + "segment_amount": "1" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_1", + "y": 180 + }, + "when": { + "facing": "south", + "segment_amount": "1" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_1", + "y": 270 + }, + "when": { + "facing": "west", + "segment_amount": "1" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_2" + }, + "when": { + "facing": "north", + "segment_amount": "2|3" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_2", + "y": 90 + }, + "when": { + "facing": "east", + "segment_amount": "2|3" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_2", + "y": 180 + }, + "when": { + "facing": "south", + "segment_amount": "2|3" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_2", + "y": 270 + }, + "when": { + "facing": "west", + "segment_amount": "2|3" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_3" + }, + "when": { + "facing": "north", + "segment_amount": "3" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_3", + "y": 90 + }, + "when": { + "facing": "east", + "segment_amount": "3" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_3", + "y": 180 + }, + "when": { + "facing": "south", + "segment_amount": "3" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_3", + "y": 270 + }, + "when": { + "facing": "west", + "segment_amount": "3" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_4" + }, + "when": { + "facing": "north", + "segment_amount": "4" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_4", + "y": 90 + }, + "when": { + "facing": "east", + "segment_amount": "4" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_4", + "y": 180 + }, + "when": { + "facing": "south", + "segment_amount": "4" + } + }, + { + "apply": { + "model": "minecraft:block/leaf_litter_4", + "y": 270 + }, + "when": { + "facing": "west", + "segment_amount": "4" + } + } + ] +} \ No newline at end of file diff --git a/assets/minecraft/blockstates/mangrove_trapdoor.json b/assets/minecraft/blockstates/mangrove_trapdoor.json index cab73e2e..17c336a6 100644 --- a/assets/minecraft/blockstates/mangrove_trapdoor.json +++ b/assets/minecraft/blockstates/mangrove_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/mangrove_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/mangrove_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/mushroom_stem.json b/assets/minecraft/blockstates/mushroom_stem.json index 7bcbe438..f343a9b9 100644 --- a/assets/minecraft/blockstates/mushroom_stem.json +++ b/assets/minecraft/blockstates/mushroom_stem.json @@ -69,7 +69,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 90 }, "when": { @@ -79,7 +78,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 180 }, "when": { @@ -89,7 +87,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 270 }, "when": { @@ -99,7 +96,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "x": 270 }, "when": { @@ -109,7 +105,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "x": 90 }, "when": { diff --git a/assets/minecraft/blockstates/pale_oak_trapdoor.json b/assets/minecraft/blockstates/pale_oak_trapdoor.json index 52e57594..41deeb52 100644 --- a/assets/minecraft/blockstates/pale_oak_trapdoor.json +++ b/assets/minecraft/blockstates/pale_oak_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/pale_oak_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/pale_oak_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/pink_petals.json b/assets/minecraft/blockstates/pink_petals.json index 990e576e..8784501e 100644 --- a/assets/minecraft/blockstates/pink_petals.json +++ b/assets/minecraft/blockstates/pink_petals.json @@ -5,8 +5,7 @@ "model": "minecraft:block/pink_petals_1" }, "when": { - "facing": "north", - "flower_amount": "1|2|3|4" + "facing": "north" } }, { @@ -15,8 +14,7 @@ "y": 90 }, "when": { - "facing": "east", - "flower_amount": "1|2|3|4" + "facing": "east" } }, { @@ -25,8 +23,7 @@ "y": 180 }, "when": { - "facing": "south", - "flower_amount": "1|2|3|4" + "facing": "south" } }, { @@ -35,8 +32,7 @@ "y": 270 }, "when": { - "facing": "west", - "flower_amount": "1|2|3|4" + "facing": "west" } }, { diff --git a/assets/minecraft/blockstates/red_mushroom_block.json b/assets/minecraft/blockstates/red_mushroom_block.json index 6e61afde..2312116f 100644 --- a/assets/minecraft/blockstates/red_mushroom_block.json +++ b/assets/minecraft/blockstates/red_mushroom_block.json @@ -69,7 +69,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 90 }, "when": { @@ -79,7 +78,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 180 }, "when": { @@ -89,7 +87,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "y": 270 }, "when": { @@ -99,7 +96,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "x": 270 }, "when": { @@ -109,7 +105,6 @@ { "apply": { "model": "minecraft:block/mushroom_block_inside", - "uvlock": false, "x": 90 }, "when": { diff --git a/assets/minecraft/blockstates/short_dry_grass.json b/assets/minecraft/blockstates/short_dry_grass.json new file mode 100644 index 00000000..e13569e8 --- /dev/null +++ b/assets/minecraft/blockstates/short_dry_grass.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "minecraft:block/short_dry_grass" + } + } +} \ No newline at end of file diff --git a/assets/minecraft/blockstates/spruce_trapdoor.json b/assets/minecraft/blockstates/spruce_trapdoor.json index 8aa277c2..4b494ff1 100644 --- a/assets/minecraft/blockstates/spruce_trapdoor.json +++ b/assets/minecraft/blockstates/spruce_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/spruce_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/spruce_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/tall_dry_grass.json b/assets/minecraft/blockstates/tall_dry_grass.json new file mode 100644 index 00000000..3fa49983 --- /dev/null +++ b/assets/minecraft/blockstates/tall_dry_grass.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "minecraft:block/tall_dry_grass" + } + } +} \ No newline at end of file diff --git a/assets/minecraft/blockstates/test_block.json b/assets/minecraft/blockstates/test_block.json new file mode 100644 index 00000000..45bed9fc --- /dev/null +++ b/assets/minecraft/blockstates/test_block.json @@ -0,0 +1,16 @@ +{ + "variants": { + "mode=accept": { + "model": "minecraft:block/test_block_accept" + }, + "mode=fail": { + "model": "minecraft:block/test_block_fail" + }, + "mode=log": { + "model": "minecraft:block/test_block_log" + }, + "mode=start": { + "model": "minecraft:block/test_block_start" + } + } +} \ No newline at end of file diff --git a/assets/minecraft/blockstates/test_instance_block.json b/assets/minecraft/blockstates/test_instance_block.json new file mode 100644 index 00000000..213ba079 --- /dev/null +++ b/assets/minecraft/blockstates/test_instance_block.json @@ -0,0 +1,7 @@ +{ + "variants": { + "": { + "model": "minecraft:block/test_instance_block" + } + } +} \ No newline at end of file diff --git a/assets/minecraft/blockstates/warped_trapdoor.json b/assets/minecraft/blockstates/warped_trapdoor.json index b4d8b33b..16d8a5ee 100644 --- a/assets/minecraft/blockstates/warped_trapdoor.json +++ b/assets/minecraft/blockstates/warped_trapdoor.json @@ -45,8 +45,7 @@ }, "facing=south,half=top,open=true": { "model": "minecraft:block/warped_trapdoor_open", - "x": 180, - "y": 0 + "x": 180 }, "facing=west,half=bottom,open=false": { "model": "minecraft:block/warped_trapdoor_bottom", diff --git a/assets/minecraft/blockstates/wildflowers.json b/assets/minecraft/blockstates/wildflowers.json new file mode 100644 index 00000000..3a2829ef --- /dev/null +++ b/assets/minecraft/blockstates/wildflowers.json @@ -0,0 +1,156 @@ +{ + "multipart": [ + { + "apply": { + "model": "minecraft:block/wildflowers_1" + }, + "when": { + "facing": "north" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_1", + "y": 90 + }, + "when": { + "facing": "east" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_1", + "y": 180 + }, + "when": { + "facing": "south" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_1", + "y": 270 + }, + "when": { + "facing": "west" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_2" + }, + "when": { + "facing": "north", + "flower_amount": "2|3|4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_2", + "y": 90 + }, + "when": { + "facing": "east", + "flower_amount": "2|3|4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_2", + "y": 180 + }, + "when": { + "facing": "south", + "flower_amount": "2|3|4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_2", + "y": 270 + }, + "when": { + "facing": "west", + "flower_amount": "2|3|4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_3" + }, + "when": { + "facing": "north", + "flower_amount": "3|4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_3", + "y": 90 + }, + "when": { + "facing": "east", + "flower_amount": "3|4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_3", + "y": 180 + }, + "when": { + "facing": "south", + "flower_amount": "3|4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_3", + "y": 270 + }, + "when": { + "facing": "west", + "flower_amount": "3|4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_4" + }, + "when": { + "facing": "north", + "flower_amount": "4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_4", + "y": 90 + }, + "when": { + "facing": "east", + "flower_amount": "4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_4", + "y": 180 + }, + "when": { + "facing": "south", + "flower_amount": "4" + } + }, + { + "apply": { + "model": "minecraft:block/wildflowers_4", + "y": 270 + }, + "when": { + "facing": "west", + "flower_amount": "4" + } + } + ] +} \ No newline at end of file diff --git a/assets/minecraft/equipment/saddle.json b/assets/minecraft/equipment/saddle.json new file mode 100644 index 00000000..ef229b4c --- /dev/null +++ b/assets/minecraft/equipment/saddle.json @@ -0,0 +1,44 @@ +{ + "layers": { + "camel_saddle": [ + { + "texture": "minecraft:saddle" + } + ], + "donkey_saddle": [ + { + "texture": "minecraft:saddle" + } + ], + "horse_saddle": [ + { + "texture": "minecraft:saddle" + } + ], + "mule_saddle": [ + { + "texture": "minecraft:saddle" + } + ], + "pig_saddle": [ + { + "texture": "minecraft:saddle" + } + ], + "skeleton_horse_saddle": [ + { + "texture": "minecraft:saddle" + } + ], + "strider_saddle": [ + { + "texture": "minecraft:saddle" + } + ], + "zombie_horse_saddle": [ + { + "texture": "minecraft:saddle" + } + ] + } +} \ No newline at end of file diff --git a/assets/minecraft/items/allay_spawn_egg.json b/assets/minecraft/items/allay_spawn_egg.json index ce06c0df..6d668733 100644 --- a/assets/minecraft/items/allay_spawn_egg.json +++ b/assets/minecraft/items/allay_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -16721153 - }, - { - "type": "minecraft:constant", - "value": -16732673 - } - ] + "model": "minecraft:item/allay_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/armadillo_spawn_egg.json b/assets/minecraft/items/armadillo_spawn_egg.json index 202c8f54..cd895181 100644 --- a/assets/minecraft/items/armadillo_spawn_egg.json +++ b/assets/minecraft/items/armadillo_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -5410451 - }, - { - "type": "minecraft:constant", - "value": -8239032 - } - ] + "model": "minecraft:item/armadillo_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/axolotl_spawn_egg.json b/assets/minecraft/items/axolotl_spawn_egg.json index 4153e5bc..7f2bd75f 100644 --- a/assets/minecraft/items/axolotl_spawn_egg.json +++ b/assets/minecraft/items/axolotl_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -278045 - }, - { - "type": "minecraft:constant", - "value": -5886604 - } - ] + "model": "minecraft:item/axolotl_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/bat_spawn_egg.json b/assets/minecraft/items/bat_spawn_egg.json index c7f1a566..d475496b 100644 --- a/assets/minecraft/items/bat_spawn_egg.json +++ b/assets/minecraft/items/bat_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -11780560 - }, - { - "type": "minecraft:constant", - "value": -15790321 - } - ] + "model": "minecraft:item/bat_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/bee_spawn_egg.json b/assets/minecraft/items/bee_spawn_egg.json index 0cf00f92..a0a8cb0e 100644 --- a/assets/minecraft/items/bee_spawn_egg.json +++ b/assets/minecraft/items/bee_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1195197 - }, - { - "type": "minecraft:constant", - "value": -12377061 - } - ] + "model": "minecraft:item/bee_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/blaze_spawn_egg.json b/assets/minecraft/items/blaze_spawn_egg.json index ba1d31f6..db15e772 100644 --- a/assets/minecraft/items/blaze_spawn_egg.json +++ b/assets/minecraft/items/blaze_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -609791 - }, - { - "type": "minecraft:constant", - "value": -1922 - } - ] + "model": "minecraft:item/blaze_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/blue_egg.json b/assets/minecraft/items/blue_egg.json new file mode 100644 index 00000000..80876a26 --- /dev/null +++ b/assets/minecraft/items/blue_egg.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/blue_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/bogged_spawn_egg.json b/assets/minecraft/items/bogged_spawn_egg.json index 944206c4..d9807d44 100644 --- a/assets/minecraft/items/bogged_spawn_egg.json +++ b/assets/minecraft/items/bogged_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -7693198 - }, - { - "type": "minecraft:constant", - "value": -13546213 - } - ] + "model": "minecraft:item/bogged_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/breeze_spawn_egg.json b/assets/minecraft/items/breeze_spawn_egg.json index a3ea3528..26ef8484 100644 --- a/assets/minecraft/items/breeze_spawn_egg.json +++ b/assets/minecraft/items/breeze_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -5270305 - }, - { - "type": "minecraft:constant", - "value": -7248161 - } - ] + "model": "minecraft:item/breeze_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/brown_egg.json b/assets/minecraft/items/brown_egg.json new file mode 100644 index 00000000..b1f82ae3 --- /dev/null +++ b/assets/minecraft/items/brown_egg.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/brown_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/bush.json b/assets/minecraft/items/bush.json new file mode 100644 index 00000000..9188c7be --- /dev/null +++ b/assets/minecraft/items/bush.json @@ -0,0 +1,13 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/bush", + "tints": [ + { + "type": "minecraft:grass", + "downfall": 1.0, + "temperature": 0.5 + } + ] + } +} \ No newline at end of file diff --git a/assets/minecraft/items/cactus_flower.json b/assets/minecraft/items/cactus_flower.json new file mode 100644 index 00000000..1eebbc51 --- /dev/null +++ b/assets/minecraft/items/cactus_flower.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/cactus_flower" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/camel_spawn_egg.json b/assets/minecraft/items/camel_spawn_egg.json index 20b375c9..f91efe25 100644 --- a/assets/minecraft/items/camel_spawn_egg.json +++ b/assets/minecraft/items/camel_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -212119 - }, - { - "type": "minecraft:constant", - "value": -3435721 - } - ] + "model": "minecraft:item/camel_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/cat_spawn_egg.json b/assets/minecraft/items/cat_spawn_egg.json index 4a2c5653..04f30f13 100644 --- a/assets/minecraft/items/cat_spawn_egg.json +++ b/assets/minecraft/items/cat_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1062770 - }, - { - "type": "minecraft:constant", - "value": -6983082 - } - ] + "model": "minecraft:item/cat_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/cave_spider_spawn_egg.json b/assets/minecraft/items/cave_spider_spawn_egg.json index 3577909b..203d04b4 100644 --- a/assets/minecraft/items/cave_spider_spawn_egg.json +++ b/assets/minecraft/items/cave_spider_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15973810 - }, - { - "type": "minecraft:constant", - "value": -5763570 - } - ] + "model": "minecraft:item/cave_spider_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/chicken_spawn_egg.json b/assets/minecraft/items/chicken_spawn_egg.json index 2f3596c2..170a6400 100644 --- a/assets/minecraft/items/chicken_spawn_egg.json +++ b/assets/minecraft/items/chicken_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -6184543 - }, - { - "type": "minecraft:constant", - "value": -65536 - } - ] + "model": "minecraft:item/chicken_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/cod_spawn_egg.json b/assets/minecraft/items/cod_spawn_egg.json index f556e0ef..7acc524f 100644 --- a/assets/minecraft/items/cod_spawn_egg.json +++ b/assets/minecraft/items/cod_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -4085910 - }, - { - "type": "minecraft:constant", - "value": -1719157 - } - ] + "model": "minecraft:item/cod_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/cow_spawn_egg.json b/assets/minecraft/items/cow_spawn_egg.json index b0e9ab08..6b96bbc4 100644 --- a/assets/minecraft/items/cow_spawn_egg.json +++ b/assets/minecraft/items/cow_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -12306906 - }, - { - "type": "minecraft:constant", - "value": -6184543 - } - ] + "model": "minecraft:item/cow_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/creaking_spawn_egg.json b/assets/minecraft/items/creaking_spawn_egg.json index 66355bea..28d9c05f 100644 --- a/assets/minecraft/items/creaking_spawn_egg.json +++ b/assets/minecraft/items/creaking_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -10526881 - }, - { - "type": "minecraft:constant", - "value": -231406 - } - ] + "model": "minecraft:item/creaking_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/creeper_spawn_egg.json b/assets/minecraft/items/creeper_spawn_egg.json index b46f7a58..902e2a5d 100644 --- a/assets/minecraft/items/creeper_spawn_egg.json +++ b/assets/minecraft/items/creeper_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15882485 - }, - { - "type": "minecraft:constant", - "value": -16777216 - } - ] + "model": "minecraft:item/creeper_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/crossbow.json b/assets/minecraft/items/crossbow.json index 3fd76bea..f5ca3152 100644 --- a/assets/minecraft/items/crossbow.json +++ b/assets/minecraft/items/crossbow.json @@ -1,54 +1,54 @@ { "model": { - "type": "minecraft:condition", - "on_false": { - "type": "minecraft:select", - "cases": [ - { - "model": { - "type": "minecraft:model", - "model": "minecraft:item/crossbow_arrow" - }, - "when": "arrow" + "type": "minecraft:select", + "cases": [ + { + "model": { + "type": "minecraft:model", + "model": "minecraft:item/crossbow_arrow" }, - { - "model": { - "type": "minecraft:model", - "model": "minecraft:item/crossbow_firework" - }, - "when": "rocket" - } - ], - "fallback": { + "when": "arrow" + }, + { + "model": { + "type": "minecraft:model", + "model": "minecraft:item/crossbow_firework" + }, + "when": "rocket" + } + ], + "fallback": { + "type": "minecraft:condition", + "on_false": { "type": "minecraft:model", "model": "minecraft:item/crossbow" }, - "property": "minecraft:charge_type" - }, - "on_true": { - "type": "minecraft:range_dispatch", - "entries": [ - { - "model": { - "type": "minecraft:model", - "model": "minecraft:item/crossbow_pulling_1" + "on_true": { + "type": "minecraft:range_dispatch", + "entries": [ + { + "model": { + "type": "minecraft:model", + "model": "minecraft:item/crossbow_pulling_1" + }, + "threshold": 0.58 }, - "threshold": 0.58 + { + "model": { + "type": "minecraft:model", + "model": "minecraft:item/crossbow_pulling_2" + }, + "threshold": 1.0 + } + ], + "fallback": { + "type": "minecraft:model", + "model": "minecraft:item/crossbow_pulling_0" }, - { - "model": { - "type": "minecraft:model", - "model": "minecraft:item/crossbow_pulling_2" - }, - "threshold": 1.0 - } - ], - "fallback": { - "type": "minecraft:model", - "model": "minecraft:item/crossbow_pulling_0" + "property": "minecraft:crossbow/pull" }, - "property": "minecraft:crossbow/pull" + "property": "minecraft:using_item" }, - "property": "minecraft:using_item" + "property": "minecraft:charge_type" } } \ No newline at end of file diff --git a/assets/minecraft/items/dolphin_spawn_egg.json b/assets/minecraft/items/dolphin_spawn_egg.json index 84cf6744..d62c7743 100644 --- a/assets/minecraft/items/dolphin_spawn_egg.json +++ b/assets/minecraft/items/dolphin_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -14533811 - }, - { - "type": "minecraft:constant", - "value": -394759 - } - ] + "model": "minecraft:item/dolphin_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/donkey_spawn_egg.json b/assets/minecraft/items/donkey_spawn_egg.json index 77847f05..08084f19 100644 --- a/assets/minecraft/items/donkey_spawn_egg.json +++ b/assets/minecraft/items/donkey_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -11320007 - }, - { - "type": "minecraft:constant", - "value": -7965338 - } - ] + "model": "minecraft:item/donkey_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/drowned_spawn_egg.json b/assets/minecraft/items/drowned_spawn_egg.json index 9733efa9..f5a68e33 100644 --- a/assets/minecraft/items/drowned_spawn_egg.json +++ b/assets/minecraft/items/drowned_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -7343657 - }, - { - "type": "minecraft:constant", - "value": -8807323 - } - ] + "model": "minecraft:item/drowned_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/elder_guardian_spawn_egg.json b/assets/minecraft/items/elder_guardian_spawn_egg.json index 09fa97f4..c8fb7e15 100644 --- a/assets/minecraft/items/elder_guardian_spawn_egg.json +++ b/assets/minecraft/items/elder_guardian_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -3224390 - }, - { - "type": "minecraft:constant", - "value": -9144685 - } - ] + "model": "minecraft:item/elder_guardian_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/ender_dragon_spawn_egg.json b/assets/minecraft/items/ender_dragon_spawn_egg.json index cde65d58..7d82e220 100644 --- a/assets/minecraft/items/ender_dragon_spawn_egg.json +++ b/assets/minecraft/items/ender_dragon_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -14935012 - }, - { - "type": "minecraft:constant", - "value": -2065926 - } - ] + "model": "minecraft:item/ender_dragon_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/enderman_spawn_egg.json b/assets/minecraft/items/enderman_spawn_egg.json index 26d3e235..475b4684 100644 --- a/assets/minecraft/items/enderman_spawn_egg.json +++ b/assets/minecraft/items/enderman_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15329770 - }, - { - "type": "minecraft:constant", - "value": -16777216 - } - ] + "model": "minecraft:item/enderman_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/endermite_spawn_egg.json b/assets/minecraft/items/endermite_spawn_egg.json index dded41e0..cc26c7cc 100644 --- a/assets/minecraft/items/endermite_spawn_egg.json +++ b/assets/minecraft/items/endermite_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15329770 - }, - { - "type": "minecraft:constant", - "value": -9539986 - } - ] + "model": "minecraft:item/endermite_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/evoker_spawn_egg.json b/assets/minecraft/items/evoker_spawn_egg.json index a4efa157..e1eff996 100644 --- a/assets/minecraft/items/evoker_spawn_egg.json +++ b/assets/minecraft/items/evoker_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -6972517 - }, - { - "type": "minecraft:constant", - "value": -14803942 - } - ] + "model": "minecraft:item/evoker_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/firefly_bush.json b/assets/minecraft/items/firefly_bush.json new file mode 100644 index 00000000..a60a20fe --- /dev/null +++ b/assets/minecraft/items/firefly_bush.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/firefly_bush" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/fox_spawn_egg.json b/assets/minecraft/items/fox_spawn_egg.json index cc448ddd..36a8475c 100644 --- a/assets/minecraft/items/fox_spawn_egg.json +++ b/assets/minecraft/items/fox_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -2771297 - }, - { - "type": "minecraft:constant", - "value": -3380960 - } - ] + "model": "minecraft:item/fox_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/frog_spawn_egg.json b/assets/minecraft/items/frog_spawn_egg.json index a2929167..0f6f0d48 100644 --- a/assets/minecraft/items/frog_spawn_egg.json +++ b/assets/minecraft/items/frog_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -3115964 - }, - { - "type": "minecraft:constant", - "value": -14468 - } - ] + "model": "minecraft:item/frog_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/ghast_spawn_egg.json b/assets/minecraft/items/ghast_spawn_egg.json index 683f9d0c..6884ad42 100644 --- a/assets/minecraft/items/ghast_spawn_egg.json +++ b/assets/minecraft/items/ghast_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -394759 - }, - { - "type": "minecraft:constant", - "value": -4408132 - } - ] + "model": "minecraft:item/ghast_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/glow_squid_spawn_egg.json b/assets/minecraft/items/glow_squid_spawn_egg.json index be481041..00c1f03c 100644 --- a/assets/minecraft/items/glow_squid_spawn_egg.json +++ b/assets/minecraft/items/glow_squid_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -16165290 - }, - { - "type": "minecraft:constant", - "value": -7999044 - } - ] + "model": "minecraft:item/glow_squid_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/goat_spawn_egg.json b/assets/minecraft/items/goat_spawn_egg.json index 75471773..b1f39c6b 100644 --- a/assets/minecraft/items/goat_spawn_egg.json +++ b/assets/minecraft/items/goat_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -5925764 - }, - { - "type": "minecraft:constant", - "value": -11187906 - } - ] + "model": "minecraft:item/goat_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/guardian_spawn_egg.json b/assets/minecraft/items/guardian_spawn_egg.json index 55e053e1..6d0d8efe 100644 --- a/assets/minecraft/items/guardian_spawn_egg.json +++ b/assets/minecraft/items/guardian_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -10845582 - }, - { - "type": "minecraft:constant", - "value": -950992 - } - ] + "model": "minecraft:item/guardian_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/hoglin_spawn_egg.json b/assets/minecraft/items/hoglin_spawn_egg.json index fe7980f4..770687ae 100644 --- a/assets/minecraft/items/hoglin_spawn_egg.json +++ b/assets/minecraft/items/hoglin_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -3772843 - }, - { - "type": "minecraft:constant", - "value": -10525596 - } - ] + "model": "minecraft:item/hoglin_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/horse_spawn_egg.json b/assets/minecraft/items/horse_spawn_egg.json index 89084d09..402399e8 100644 --- a/assets/minecraft/items/horse_spawn_egg.json +++ b/assets/minecraft/items/horse_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -4153731 - }, - { - "type": "minecraft:constant", - "value": -1121024 - } - ] + "model": "minecraft:item/horse_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/husk_spawn_egg.json b/assets/minecraft/items/husk_spawn_egg.json index 84aa544b..fd0ab914 100644 --- a/assets/minecraft/items/husk_spawn_egg.json +++ b/assets/minecraft/items/husk_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -8818591 - }, - { - "type": "minecraft:constant", - "value": -1651564 - } - ] + "model": "minecraft:item/husk_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/iron_golem_spawn_egg.json b/assets/minecraft/items/iron_golem_spawn_egg.json index f333d3e6..a9a9a4bf 100644 --- a/assets/minecraft/items/iron_golem_spawn_egg.json +++ b/assets/minecraft/items/iron_golem_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -2372158 - }, - { - "type": "minecraft:constant", - "value": -9133262 - } - ] + "model": "minecraft:item/iron_golem_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/leaf_litter.json b/assets/minecraft/items/leaf_litter.json new file mode 100644 index 00000000..d2edcf4e --- /dev/null +++ b/assets/minecraft/items/leaf_litter.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/leaf_litter" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/llama_spawn_egg.json b/assets/minecraft/items/llama_spawn_egg.json index 2ed78189..0eed2d50 100644 --- a/assets/minecraft/items/llama_spawn_egg.json +++ b/assets/minecraft/items/llama_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -4153731 - }, - { - "type": "minecraft:constant", - "value": -6725824 - } - ] + "model": "minecraft:item/llama_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/magma_cube_spawn_egg.json b/assets/minecraft/items/magma_cube_spawn_egg.json index 6dfefdaa..51420eb1 100644 --- a/assets/minecraft/items/magma_cube_spawn_egg.json +++ b/assets/minecraft/items/magma_cube_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -13369344 - }, - { - "type": "minecraft:constant", - "value": -197632 - } - ] + "model": "minecraft:item/magma_cube_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/mooshroom_spawn_egg.json b/assets/minecraft/items/mooshroom_spawn_egg.json index a8d3720a..fa68ef21 100644 --- a/assets/minecraft/items/mooshroom_spawn_egg.json +++ b/assets/minecraft/items/mooshroom_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -6287600 - }, - { - "type": "minecraft:constant", - "value": -4737097 - } - ] + "model": "minecraft:item/mooshroom_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/mule_spawn_egg.json b/assets/minecraft/items/mule_spawn_egg.json index 6890dcb2..5f4292ea 100644 --- a/assets/minecraft/items/mule_spawn_egg.json +++ b/assets/minecraft/items/mule_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15007232 - }, - { - "type": "minecraft:constant", - "value": -11455715 - } - ] + "model": "minecraft:item/mule_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/ocelot_spawn_egg.json b/assets/minecraft/items/ocelot_spawn_egg.json index 333616e3..c6c7a202 100644 --- a/assets/minecraft/items/ocelot_spawn_egg.json +++ b/assets/minecraft/items/ocelot_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1057155 - }, - { - "type": "minecraft:constant", - "value": -11123660 - } - ] + "model": "minecraft:item/ocelot_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/panda_spawn_egg.json b/assets/minecraft/items/panda_spawn_egg.json index e3c983d7..257bf91f 100644 --- a/assets/minecraft/items/panda_spawn_egg.json +++ b/assets/minecraft/items/panda_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1579033 - }, - { - "type": "minecraft:constant", - "value": -15000798 - } - ] + "model": "minecraft:item/panda_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/parrot_spawn_egg.json b/assets/minecraft/items/parrot_spawn_egg.json index f633eea9..e06fce4c 100644 --- a/assets/minecraft/items/parrot_spawn_egg.json +++ b/assets/minecraft/items/parrot_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15882485 - }, - { - "type": "minecraft:constant", - "value": -65536 - } - ] + "model": "minecraft:item/parrot_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/phantom_spawn_egg.json b/assets/minecraft/items/phantom_spawn_egg.json index 9ad747b6..df9b3d66 100644 --- a/assets/minecraft/items/phantom_spawn_egg.json +++ b/assets/minecraft/items/phantom_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -12365430 - }, - { - "type": "minecraft:constant", - "value": -7799040 - } - ] + "model": "minecraft:item/phantom_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/pig_spawn_egg.json b/assets/minecraft/items/pig_spawn_egg.json index d1139e70..a1757032 100644 --- a/assets/minecraft/items/pig_spawn_egg.json +++ b/assets/minecraft/items/pig_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1006174 - }, - { - "type": "minecraft:constant", - "value": -2399393 - } - ] + "model": "minecraft:item/pig_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/piglin_brute_spawn_egg.json b/assets/minecraft/items/piglin_brute_spawn_egg.json index 68c2002e..b0038728 100644 --- a/assets/minecraft/items/piglin_brute_spawn_egg.json +++ b/assets/minecraft/items/piglin_brute_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -10933744 - }, - { - "type": "minecraft:constant", - "value": -396380 - } - ] + "model": "minecraft:item/piglin_brute_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/piglin_spawn_egg.json b/assets/minecraft/items/piglin_spawn_egg.json index f4976251..1c5e1453 100644 --- a/assets/minecraft/items/piglin_spawn_egg.json +++ b/assets/minecraft/items/piglin_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -6725824 - }, - { - "type": "minecraft:constant", - "value": -396380 - } - ] + "model": "minecraft:item/piglin_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/pillager_spawn_egg.json b/assets/minecraft/items/pillager_spawn_egg.json index 0f961d28..e8b1b4ec 100644 --- a/assets/minecraft/items/pillager_spawn_egg.json +++ b/assets/minecraft/items/pillager_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -11325642 - }, - { - "type": "minecraft:constant", - "value": -6972517 - } - ] + "model": "minecraft:item/pillager_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/polar_bear_spawn_egg.json b/assets/minecraft/items/polar_bear_spawn_egg.json index 8beaa452..12c76be1 100644 --- a/assets/minecraft/items/polar_bear_spawn_egg.json +++ b/assets/minecraft/items/polar_bear_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1118498 - }, - { - "type": "minecraft:constant", - "value": -2763059 - } - ] + "model": "minecraft:item/polar_bear_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/pufferfish_spawn_egg.json b/assets/minecraft/items/pufferfish_spawn_egg.json index bd486127..5a1b9bbe 100644 --- a/assets/minecraft/items/pufferfish_spawn_egg.json +++ b/assets/minecraft/items/pufferfish_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -609791 - }, - { - "type": "minecraft:constant", - "value": -13122574 - } - ] + "model": "minecraft:item/pufferfish_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/rabbit_spawn_egg.json b/assets/minecraft/items/rabbit_spawn_egg.json index 499cf291..0f2747c4 100644 --- a/assets/minecraft/items/rabbit_spawn_egg.json +++ b/assets/minecraft/items/rabbit_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -6725824 - }, - { - "type": "minecraft:constant", - "value": -9222095 - } - ] + "model": "minecraft:item/rabbit_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/ravager_spawn_egg.json b/assets/minecraft/items/ravager_spawn_egg.json index caa7b1c8..303bba05 100644 --- a/assets/minecraft/items/ravager_spawn_egg.json +++ b/assets/minecraft/items/ravager_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -9079696 - }, - { - "type": "minecraft:constant", - "value": -10792887 - } - ] + "model": "minecraft:item/ravager_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/salmon_spawn_egg.json b/assets/minecraft/items/salmon_spawn_egg.json index bd0fd4bb..a369b33d 100644 --- a/assets/minecraft/items/salmon_spawn_egg.json +++ b/assets/minecraft/items/salmon_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -6287600 - }, - { - "type": "minecraft:constant", - "value": -15825804 - } - ] + "model": "minecraft:item/salmon_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/sheep_spawn_egg.json b/assets/minecraft/items/sheep_spawn_egg.json index 609bbd43..254bc4ec 100644 --- a/assets/minecraft/items/sheep_spawn_egg.json +++ b/assets/minecraft/items/sheep_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1579033 - }, - { - "type": "minecraft:constant", - "value": -19019 - } - ] + "model": "minecraft:item/sheep_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/short_dry_grass.json b/assets/minecraft/items/short_dry_grass.json new file mode 100644 index 00000000..ac3d2783 --- /dev/null +++ b/assets/minecraft/items/short_dry_grass.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/short_dry_grass" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/shulker_spawn_egg.json b/assets/minecraft/items/shulker_spawn_egg.json index d7ff35fc..aa1422dc 100644 --- a/assets/minecraft/items/shulker_spawn_egg.json +++ b/assets/minecraft/items/shulker_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -7051372 - }, - { - "type": "minecraft:constant", - "value": -11716526 - } - ] + "model": "minecraft:item/shulker_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/silverfish_spawn_egg.json b/assets/minecraft/items/silverfish_spawn_egg.json index 8f28286f..fd5ff757 100644 --- a/assets/minecraft/items/silverfish_spawn_egg.json +++ b/assets/minecraft/items/silverfish_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -9539986 - }, - { - "type": "minecraft:constant", - "value": -13619152 - } - ] + "model": "minecraft:item/silverfish_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/skeleton_horse_spawn_egg.json b/assets/minecraft/items/skeleton_horse_spawn_egg.json index 48c07e13..5b281280 100644 --- a/assets/minecraft/items/skeleton_horse_spawn_egg.json +++ b/assets/minecraft/items/skeleton_horse_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -9934769 - }, - { - "type": "minecraft:constant", - "value": -1710632 - } - ] + "model": "minecraft:item/skeleton_horse_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/skeleton_spawn_egg.json b/assets/minecraft/items/skeleton_spawn_egg.json index e6f776df..5118e265 100644 --- a/assets/minecraft/items/skeleton_spawn_egg.json +++ b/assets/minecraft/items/skeleton_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -4079167 - }, - { - "type": "minecraft:constant", - "value": -11974327 - } - ] + "model": "minecraft:item/skeleton_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/slime_spawn_egg.json b/assets/minecraft/items/slime_spawn_egg.json index a6d20b21..fc8c5998 100644 --- a/assets/minecraft/items/slime_spawn_egg.json +++ b/assets/minecraft/items/slime_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -11427778 - }, - { - "type": "minecraft:constant", - "value": -8470674 - } - ] + "model": "minecraft:item/slime_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/sniffer_spawn_egg.json b/assets/minecraft/items/sniffer_spawn_egg.json index 2930eba9..3461789d 100644 --- a/assets/minecraft/items/sniffer_spawn_egg.json +++ b/assets/minecraft/items/sniffer_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -7922167 - }, - { - "type": "minecraft:constant", - "value": -14308496 - } - ] + "model": "minecraft:item/sniffer_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/snow_golem_spawn_egg.json b/assets/minecraft/items/snow_golem_spawn_egg.json index cdf6accd..04f90e75 100644 --- a/assets/minecraft/items/snow_golem_spawn_egg.json +++ b/assets/minecraft/items/snow_golem_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -2493710 - }, - { - "type": "minecraft:constant", - "value": -8280924 - } - ] + "model": "minecraft:item/snow_golem_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/spider_spawn_egg.json b/assets/minecraft/items/spider_spawn_egg.json index 2ea93aa4..7aa50988 100644 --- a/assets/minecraft/items/spider_spawn_egg.json +++ b/assets/minecraft/items/spider_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -13357785 - }, - { - "type": "minecraft:constant", - "value": -5763570 - } - ] + "model": "minecraft:item/spider_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/squid_spawn_egg.json b/assets/minecraft/items/squid_spawn_egg.json index ad34e590..95204ecb 100644 --- a/assets/minecraft/items/squid_spawn_egg.json +++ b/assets/minecraft/items/squid_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -14533811 - }, - { - "type": "minecraft:constant", - "value": -9402215 - } - ] + "model": "minecraft:item/squid_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/stray_spawn_egg.json b/assets/minecraft/items/stray_spawn_egg.json index af04df23..b73412c0 100644 --- a/assets/minecraft/items/stray_spawn_egg.json +++ b/assets/minecraft/items/stray_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -10389897 - }, - { - "type": "minecraft:constant", - "value": -2233622 - } - ] + "model": "minecraft:item/stray_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/strider_spawn_egg.json b/assets/minecraft/items/strider_spawn_egg.json index 807fdf82..347d47a3 100644 --- a/assets/minecraft/items/strider_spawn_egg.json +++ b/assets/minecraft/items/strider_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -6540234 - }, - { - "type": "minecraft:constant", - "value": -11712179 - } - ] + "model": "minecraft:item/strider_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/tadpole_spawn_egg.json b/assets/minecraft/items/tadpole_spawn_egg.json index 1a2306bf..85a709a9 100644 --- a/assets/minecraft/items/tadpole_spawn_egg.json +++ b/assets/minecraft/items/tadpole_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -9612483 - }, - { - "type": "minecraft:constant", - "value": -15332864 - } - ] + "model": "minecraft:item/tadpole_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/tall_dry_grass.json b/assets/minecraft/items/tall_dry_grass.json new file mode 100644 index 00000000..fb4a4fd6 --- /dev/null +++ b/assets/minecraft/items/tall_dry_grass.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/tall_dry_grass" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/test_block.json b/assets/minecraft/items/test_block.json new file mode 100644 index 00000000..706d749c --- /dev/null +++ b/assets/minecraft/items/test_block.json @@ -0,0 +1,34 @@ +{ + "model": { + "type": "minecraft:select", + "block_state_property": "mode", + "cases": [ + { + "model": { + "type": "minecraft:model", + "model": "minecraft:block/test_block_log" + }, + "when": "log" + }, + { + "model": { + "type": "minecraft:model", + "model": "minecraft:block/test_block_fail" + }, + "when": "fail" + }, + { + "model": { + "type": "minecraft:model", + "model": "minecraft:block/test_block_accept" + }, + "when": "accept" + } + ], + "fallback": { + "type": "minecraft:model", + "model": "minecraft:block/test_block_start" + }, + "property": "minecraft:block_state" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/test_instance_block.json b/assets/minecraft/items/test_instance_block.json new file mode 100644 index 00000000..d153ca1c --- /dev/null +++ b/assets/minecraft/items/test_instance_block.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:block/test_instance_block" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/trader_llama_spawn_egg.json b/assets/minecraft/items/trader_llama_spawn_egg.json index 717eda54..61e69441 100644 --- a/assets/minecraft/items/trader_llama_spawn_egg.json +++ b/assets/minecraft/items/trader_llama_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1399760 - }, - { - "type": "minecraft:constant", - "value": -12229994 - } - ] + "model": "minecraft:item/trader_llama_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/tropical_fish_spawn_egg.json b/assets/minecraft/items/tropical_fish_spawn_egg.json index f0966e93..18fade41 100644 --- a/assets/minecraft/items/tropical_fish_spawn_egg.json +++ b/assets/minecraft/items/tropical_fish_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1087211 - }, - { - "type": "minecraft:constant", - "value": -1553 - } - ] + "model": "minecraft:item/tropical_fish_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/turtle_spawn_egg.json b/assets/minecraft/items/turtle_spawn_egg.json index 1f072089..6a9152c1 100644 --- a/assets/minecraft/items/turtle_spawn_egg.json +++ b/assets/minecraft/items/turtle_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1579033 - }, - { - "type": "minecraft:constant", - "value": -16732241 - } - ] + "model": "minecraft:item/turtle_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/vex_spawn_egg.json b/assets/minecraft/items/vex_spawn_egg.json index 4a941b7d..13c93282 100644 --- a/assets/minecraft/items/vex_spawn_egg.json +++ b/assets/minecraft/items/vex_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -8744796 - }, - { - "type": "minecraft:constant", - "value": -1511951 - } - ] + "model": "minecraft:item/vex_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/villager_spawn_egg.json b/assets/minecraft/items/villager_spawn_egg.json index c8b680aa..a1c89c61 100644 --- a/assets/minecraft/items/villager_spawn_egg.json +++ b/assets/minecraft/items/villager_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -11125709 - }, - { - "type": "minecraft:constant", - "value": -4355214 - } - ] + "model": "minecraft:item/villager_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/vindicator_spawn_egg.json b/assets/minecraft/items/vindicator_spawn_egg.json index f60cf9d9..e6909698 100644 --- a/assets/minecraft/items/vindicator_spawn_egg.json +++ b/assets/minecraft/items/vindicator_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -6972517 - }, - { - "type": "minecraft:constant", - "value": -14197151 - } - ] + "model": "minecraft:item/vindicator_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/wandering_trader_spawn_egg.json b/assets/minecraft/items/wandering_trader_spawn_egg.json index 0e6d1b5f..0db47663 100644 --- a/assets/minecraft/items/wandering_trader_spawn_egg.json +++ b/assets/minecraft/items/wandering_trader_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -12229994 - }, - { - "type": "minecraft:constant", - "value": -1399760 - } - ] + "model": "minecraft:item/wandering_trader_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/warden_spawn_egg.json b/assets/minecraft/items/warden_spawn_egg.json index c51f0f27..8d20e024 100644 --- a/assets/minecraft/items/warden_spawn_egg.json +++ b/assets/minecraft/items/warden_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15776183 - }, - { - "type": "minecraft:constant", - "value": -12986656 - } - ] + "model": "minecraft:item/warden_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/wildflowers.json b/assets/minecraft/items/wildflowers.json new file mode 100644 index 00000000..9d441076 --- /dev/null +++ b/assets/minecraft/items/wildflowers.json @@ -0,0 +1,6 @@ +{ + "model": { + "type": "minecraft:model", + "model": "minecraft:item/wildflowers" + } +} \ No newline at end of file diff --git a/assets/minecraft/items/witch_spawn_egg.json b/assets/minecraft/items/witch_spawn_egg.json index cf62f2ba..94b7d48b 100644 --- a/assets/minecraft/items/witch_spawn_egg.json +++ b/assets/minecraft/items/witch_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -13369344 - }, - { - "type": "minecraft:constant", - "value": -11427778 - } - ] + "model": "minecraft:item/witch_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/wither_skeleton_spawn_egg.json b/assets/minecraft/items/wither_skeleton_spawn_egg.json index b59dd39d..d10bff4a 100644 --- a/assets/minecraft/items/wither_skeleton_spawn_egg.json +++ b/assets/minecraft/items/wither_skeleton_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15461356 - }, - { - "type": "minecraft:constant", - "value": -12104371 - } - ] + "model": "minecraft:item/wither_skeleton_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/wither_spawn_egg.json b/assets/minecraft/items/wither_spawn_egg.json index c4081fb5..b4fe9d30 100644 --- a/assets/minecraft/items/wither_spawn_egg.json +++ b/assets/minecraft/items/wither_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -15461356 - }, - { - "type": "minecraft:constant", - "value": -11701600 - } - ] + "model": "minecraft:item/wither_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/wolf_spawn_egg.json b/assets/minecraft/items/wolf_spawn_egg.json index 66528078..cd97950d 100644 --- a/assets/minecraft/items/wolf_spawn_egg.json +++ b/assets/minecraft/items/wolf_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -2632749 - }, - { - "type": "minecraft:constant", - "value": -3231850 - } - ] + "model": "minecraft:item/wolf_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/zoglin_spawn_egg.json b/assets/minecraft/items/zoglin_spawn_egg.json index 2c763328..3f9c6b08 100644 --- a/assets/minecraft/items/zoglin_spawn_egg.json +++ b/assets/minecraft/items/zoglin_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -3772843 - }, - { - "type": "minecraft:constant", - "value": -1644826 - } - ] + "model": "minecraft:item/zoglin_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/zombie_horse_spawn_egg.json b/assets/minecraft/items/zombie_horse_spawn_egg.json index 142a150e..7e975af9 100644 --- a/assets/minecraft/items/zombie_horse_spawn_egg.json +++ b/assets/minecraft/items/zombie_horse_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -13544908 - }, - { - "type": "minecraft:constant", - "value": -6831484 - } - ] + "model": "minecraft:item/zombie_horse_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/zombie_spawn_egg.json b/assets/minecraft/items/zombie_spawn_egg.json index eb8b35cb..eee9ace3 100644 --- a/assets/minecraft/items/zombie_spawn_egg.json +++ b/assets/minecraft/items/zombie_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -16732241 - }, - { - "type": "minecraft:constant", - "value": -8807323 - } - ] + "model": "minecraft:item/zombie_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/zombie_villager_spawn_egg.json b/assets/minecraft/items/zombie_villager_spawn_egg.json index f351c001..72a41ecd 100644 --- a/assets/minecraft/items/zombie_villager_spawn_egg.json +++ b/assets/minecraft/items/zombie_villager_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -11125709 - }, - { - "type": "minecraft:constant", - "value": -8807323 - } - ] + "model": "minecraft:item/zombie_villager_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/items/zombified_piglin_spawn_egg.json b/assets/minecraft/items/zombified_piglin_spawn_egg.json index 9be3d478..d7699695 100644 --- a/assets/minecraft/items/zombified_piglin_spawn_egg.json +++ b/assets/minecraft/items/zombified_piglin_spawn_egg.json @@ -1,16 +1,6 @@ { "model": { "type": "minecraft:model", - "model": "minecraft:item/template_spawn_egg", - "tints": [ - { - "type": "minecraft:constant", - "value": -1404013 - }, - { - "type": "minecraft:constant", - "value": -11767511 - } - ] + "model": "minecraft:item/zombified_piglin_spawn_egg" } } \ No newline at end of file diff --git a/assets/minecraft/lang/deprecated.json b/assets/minecraft/lang/deprecated.json index 531668eb..c684c464 100644 --- a/assets/minecraft/lang/deprecated.json +++ b/assets/minecraft/lang/deprecated.json @@ -134,6 +134,7 @@ "mco.snapshot.friendsRealm.upgrade", "mco.upload.entry.cheats", "mco.upload.entry.commands", + "mco.upload.hardcore", "mco.upload.size.failure.line1", "mco.upload.size.failure.line2", "mco.version", @@ -240,7 +241,11 @@ "subtitles.ambient.cave", "subtitles.block.creaking_heart.idle", "subtitles.block.eyeblossom.idle", - "subtitles.block.generic.idle" + "subtitles.block.generic.idle", + "entity.minecraft.potion", + "argument.nbt.list.mixed", + "item.minecraft.crossbow.projectile", + "subtitles.entity.wolf.ambient" ], "renamed": { "item.minecraft.dune_armor_trim_smithing_template.new": "item.minecraft.dune_armor_trim_smithing_template", @@ -279,6 +284,11 @@ "commands.drop.no_loot_table": "commands.drop.no_loot_table.entity", "item.op_block_warning.line1": "item.op_warning.line1", "item.op_block_warning.line2": "item.op_warning.line2", - "item.op_block_warning.line3": "item.op_warning.line3" + "item.op_block_warning.line3": "item.op_warning.line3", + "container.shulkerBox.unknownContents": "item.container.loot_table.unknown", + "container.shulkerBox.itemCount": "item.container.item_count", + "container.shulkerBox.more": "item.container.more_items", + "advancements.nether.use_lodestone.description": "advancements.adventure.use_lodestone.description", + "advancements.nether.use_lodestone.title": "advancements.adventure.use_lodestone.title" } } diff --git a/assets/minecraft/lang/en_us.json b/assets/minecraft/lang/en_us.json index c32a35d3..8394be03 100644 --- a/assets/minecraft/lang/en_us.json +++ b/assets/minecraft/lang/en_us.json @@ -89,6 +89,8 @@ "advancements.adventure.two_birds_one_arrow.title": "Two Birds, One Arrow", "advancements.adventure.under_lock_and_key.description": "Unlock a Vault with a Trial Key", "advancements.adventure.under_lock_and_key.title": "Under Lock and Key", + "advancements.adventure.use_lodestone.description": "Use a Compass on a Lodestone", + "advancements.adventure.use_lodestone.title": "Country Lode, Take Me Home", "advancements.adventure.very_very_frightening.description": "Strike a Villager with lightning", "advancements.adventure.very_very_frightening.title": "Very Very Frightening", "advancements.adventure.voluntary_exile.description": "Kill a raid captain.\nMaybe consider staying away from villages for the time being...", @@ -354,6 +356,7 @@ "argument.message.too_long": "Chat message was too long (%s > maximum %s characters)", "argument.nbt.array.invalid": "Invalid array type '%s'", "argument.nbt.array.mixed": "Can't insert %s into %s", + "argument.nbt.expected.compound": "Expected compound tag", "argument.nbt.expected.key": "Expected key", "argument.nbt.expected.value": "Expected value", "argument.nbt.list.mixed": "Can't insert %s into list of %s", @@ -374,6 +377,7 @@ "argument.range.swapped": "Min cannot be bigger than max", "argument.resource_or_id.failed_to_parse": "Failed to parse structure: %s", "argument.resource_or_id.invalid": "Invalid id or tag", + "argument.resource_selector.not_found": "No matches for selector '%s' of type '%s'", "argument.resource_tag.invalid_type": "Tag '%s' has wrong type '%s' (expected '%s')", "argument.resource_tag.not_found": "Can't find tag '%s' of type '%s'", "argument.resource.invalid_type": "Element '%s' has wrong type '%s' (expected '%s')", @@ -1387,7 +1391,9 @@ "block.minecraft.bubble_coral_fan": "Bubble Coral Fan", "block.minecraft.bubble_coral_wall_fan": "Bubble Coral Wall Fan", "block.minecraft.budding_amethyst": "Budding Amethyst", + "block.minecraft.bush": "Bush", "block.minecraft.cactus": "Cactus", + "block.minecraft.cactus_flower": "Cactus Flower", "block.minecraft.cake": "Cake", "block.minecraft.calcite": "Calcite", "block.minecraft.calibrated_sculk_sensor": "Calibrated Sculk Sensor", @@ -1618,6 +1624,7 @@ "block.minecraft.fire_coral_block": "Fire Coral Block", "block.minecraft.fire_coral_fan": "Fire Coral Fan", "block.minecraft.fire_coral_wall_fan": "Fire Coral Wall Fan", + "block.minecraft.firefly_bush": "Firefly Bush", "block.minecraft.fletching_table": "Fletching Table", "block.minecraft.flower_pot": "Flower Pot", "block.minecraft.flowering_azalea": "Flowering Azalea", @@ -1720,6 +1727,7 @@ "block.minecraft.large_fern": "Large Fern", "block.minecraft.lava": "Lava", "block.minecraft.lava_cauldron": "Lava Cauldron", + "block.minecraft.leaf_litter": "Leaf Litter", "block.minecraft.lectern": "Lectern", "block.minecraft.lever": "Lever", "block.minecraft.light": "Light", @@ -2097,6 +2105,7 @@ "block.minecraft.sea_pickle": "Sea Pickle", "block.minecraft.seagrass": "Seagrass", "block.minecraft.set_spawn": "Respawn point set", + "block.minecraft.short_dry_grass": "Short Dry Grass", "block.minecraft.short_grass": "Short Grass", "block.minecraft.shroomlight": "Shroomlight", "block.minecraft.shulker_box": "Shulker Box", @@ -2193,12 +2202,16 @@ "block.minecraft.suspicious_gravel": "Suspicious Gravel", "block.minecraft.suspicious_sand": "Suspicious Sand", "block.minecraft.sweet_berry_bush": "Sweet Berry Bush", + "block.minecraft.tall_dry_grass": "Tall Dry Grass", "block.minecraft.tall_grass": "Tall Grass", "block.minecraft.tall_seagrass": "Tall Seagrass", "block.minecraft.target": "Target", "block.minecraft.terracotta": "Terracotta", + "block.minecraft.test_block": "Test Block", + "block.minecraft.test_instance_block": "Test Instance Block", "block.minecraft.tinted_glass": "Tinted Glass", "block.minecraft.tnt": "TNT", + "block.minecraft.tnt.disabled": "TNT explosions are disabled", "block.minecraft.torch": "Torch", "block.minecraft.torchflower": "Torchflower", "block.minecraft.torchflower_crop": "Torchflower Crop", @@ -2310,6 +2323,7 @@ "block.minecraft.white_terracotta": "White Terracotta", "block.minecraft.white_tulip": "White Tulip", "block.minecraft.white_wool": "White Wool", + "block.minecraft.wildflowers": "Wildflowers", "block.minecraft.wither_rose": "Wither Rose", "block.minecraft.wither_skeleton_skull": "Wither Skeleton Skull", "block.minecraft.wither_skeleton_wall_skull": "Wither Skeleton Wall Skull", @@ -2697,11 +2711,11 @@ "commands.random.roll": "%s rolled %s (from %s to %s)", "commands.random.sample.success": "Randomized value: %s", "commands.recipe.give.failed": "No new recipes were learned", - "commands.recipe.give.success.multiple": "Unlocked %s recipes for %s players", - "commands.recipe.give.success.single": "Unlocked %s recipes for %s", + "commands.recipe.give.success.multiple": "Unlocked %s recipe(s) for %s players", + "commands.recipe.give.success.single": "Unlocked %s recipe(s) for %s", "commands.recipe.take.failed": "No recipes could be forgotten", - "commands.recipe.take.success.multiple": "Took %s recipes from %s players", - "commands.recipe.take.success.single": "Took %s recipes from %s", + "commands.recipe.take.success.multiple": "Took %s recipe(s) from %s players", + "commands.recipe.take.success.single": "Took %s recipe(s) from %s", "commands.reload.failure": "Reload failed; keeping old data", "commands.reload.success": "Reloading!", "commands.ride.already_riding": "%s is already riding %s", @@ -2848,6 +2862,32 @@ "commands.teleport.success.entity.single": "Teleported %s to %s", "commands.teleport.success.location.multiple": "Teleported %s entities to %s, %s, %s", "commands.teleport.success.location.single": "Teleported %s to %s, %s, %s", + "commands.test.batch.starting": "Starting environment %s batch %s", + "commands.test.clear.error.no_tests": "Could not find any tests to clear", + "commands.test.clear.success": "Cleared %s structure(s)", + "commands.test.coordinates": "%s, %s, %s", + "commands.test.coordinates.copy": "Click to copy to clipboard", + "commands.test.create.success": "Created test setup for test %s", + "commands.test.error.no_test_containing_pos": "Can't find a test instance that contains %s, %s, %s", + "commands.test.error.no_test_instances": "Found no test instances", + "commands.test.error.non_existant_test": "Test %s could not be found", + "commands.test.error.structure_not_found": "Test structure %s could not be found", + "commands.test.error.test_instance_not_found": "Test instance block entity could not be found", + "commands.test.error.test_instance_not_found.position": "Test instance block entity could not be found for test at %s, %s, %s", + "commands.test.error.too_large": "The structure size must be less than %s blocks along each axis", + "commands.test.locate.done": "Finished locating, found %s structure(s)", + "commands.test.locate.found": "Found structure at: %s (distance: %s)", + "commands.test.locate.started": "Started locating test structures, this might take a while...", + "commands.test.no_tests": "No tests to run", + "commands.test.relative_position": "Position relative to %s: %s", + "commands.test.reset.error.no_tests": "Could not find any tests to reset", + "commands.test.reset.success": "Reset %s structure(s)", + "commands.test.run.no_tests": "No tests found", + "commands.test.run.running": "Running %s test(s)...", + "commands.test.summary": "Game Test complete! %s test(s) were run", + "commands.test.summary.all_required_passed": "All required tests passed :)", + "commands.test.summary.failed": "%s required test(s) failed :(", + "commands.test.summary.optional_failed": "%s optional test(s) failed", "commands.tick.query.percentiles": "Percentiles: P50: %sms P95: %sms P99: %sms, sample: %s", "commands.tick.query.rate.running": "Target tick rate: %s per second.\nAverage time per tick: %sms (Target: %sms)", "commands.tick.query.rate.sprinting": "Target tick rate: %s per second (ignored, reference only).\nAverage time per tick: %sms", @@ -2980,7 +3020,7 @@ "controls.resetAll": "Reset Keys", "controls.title": "Controls", "createWorld.customize.buffet.biome": "Please select a biome", - "createWorld.customize.buffet.title": "Buffet world customization", + "createWorld.customize.buffet.title": "Single Biome Customization", "createWorld.customize.flat.height": "Height", "createWorld.customize.flat.layer": "%s", "createWorld.customize.flat.layer.bottom": "Bottom - %s", @@ -2989,7 +3029,7 @@ "createWorld.customize.flat.tile": "Layer Material", "createWorld.customize.flat.title": "Superflat Customization", "createWorld.customize.presets": "Presets", - "createWorld.customize.presets.list": "Alternatively, here's some we made earlier!", + "createWorld.customize.presets.list": "Alternatively, here are some we made earlier!", "createWorld.customize.presets.select": "Use Preset", "createWorld.customize.presets.share": "Want to share your preset with someone? Use the box below!", "createWorld.customize.presets.title": "Select a Preset", @@ -3393,6 +3433,7 @@ "entity.minecraft.killer_bunny": "The Killer Bunny", "entity.minecraft.leash_knot": "Leash Knot", "entity.minecraft.lightning_bolt": "Lightning Bolt", + "entity.minecraft.lingering_potion": "Lingering Potion", "entity.minecraft.llama": "Llama", "entity.minecraft.llama_spit": "Llama Spit", "entity.minecraft.magma_cube": "Magma Cube", @@ -3437,6 +3478,7 @@ "entity.minecraft.spawner_minecart": "Minecart with Monster Spawner", "entity.minecraft.spectral_arrow": "Spectral Arrow", "entity.minecraft.spider": "Spider", + "entity.minecraft.splash_potion": "Splash Potion", "entity.minecraft.spruce_boat": "Spruce Boat", "entity.minecraft.spruce_chest_boat": "Spruce Boat with Chest", "entity.minecraft.squid": "Squid", @@ -3551,9 +3593,11 @@ "gameMode.adventure": "Adventure Mode", "gameMode.changed": "Your game mode has been updated to %s", "gameMode.creative": "Creative Mode", - "gameMode.hardcore": "Hardcore Mode!", + "gameMode.hardcore": "Hardcore Mode", "gameMode.spectator": "Spectator Mode", "gameMode.survival": "Survival Mode", + "gamerule.allowFireTicksAwayFromPlayer": "Tick fire away from players", + "gamerule.allowFireTicksAwayFromPlayer.description": "Controls whether or not fire and lava should be able to tick further than 8 chunks away from any player", "gamerule.announceAdvancements": "Announce advancements", "gamerule.blockExplosionDropDecay": "In block interaction explosions, some blocks won't drop their loot", "gamerule.blockExplosionDropDecay.description": "Some of the drops from blocks destroyed by explosions caused by block interactions are lost in the explosion.", @@ -3637,6 +3681,7 @@ "gamerule.spawnRadius": "Respawn location radius", "gamerule.spawnRadius.description": "Controls the size of the area around the spawn point that players can spawn in.", "gamerule.spectatorsGenerateChunks": "Allow spectators to generate terrain", + "gamerule.tntExplodes": "Allow TNT to be activated and to explode", "gamerule.tntExplosionDropDecay": "In TNT explosions, some blocks won't drop their loot", "gamerule.tntExplosionDropDecay.description": "Some of the drops from blocks destroyed by explosions caused by TNT are lost in the explosion.", "gamerule.universalAnger": "Universal anger", @@ -3911,6 +3956,7 @@ "item.minecraft.blaze_spawn_egg": "Blaze Spawn Egg", "item.minecraft.blue_bundle": "Blue Bundle", "item.minecraft.blue_dye": "Blue Dye", + "item.minecraft.blue_egg": "Blue Egg", "item.minecraft.bogged_spawn_egg": "Bogged Spawn Egg", "item.minecraft.bolt_armor_trim_smithing_template": "Smithing Template", "item.minecraft.bolt_armor_trim_smithing_template.new": "Bolt Armor Trim", @@ -3929,6 +3975,7 @@ "item.minecraft.brick": "Brick", "item.minecraft.brown_bundle": "Brown Bundle", "item.minecraft.brown_dye": "Brown Dye", + "item.minecraft.brown_egg": "Brown Egg", "item.minecraft.brush": "Brush", "item.minecraft.bucket": "Bucket", "item.minecraft.bundle": "Bundle", @@ -3983,6 +4030,8 @@ "item.minecraft.creeper_spawn_egg": "Creeper Spawn Egg", "item.minecraft.crossbow": "Crossbow", "item.minecraft.crossbow.projectile": "Projectile:", + "item.minecraft.crossbow.projectile.multiple": "Projectile: %s x %s", + "item.minecraft.crossbow.projectile.single": "Projectile: %s", "item.minecraft.cyan_bundle": "Cyan Bundle", "item.minecraft.cyan_dye": "Cyan Dye", "item.minecraft.danger_pottery_shard": "Danger Pottery Shard", @@ -4039,6 +4088,8 @@ "item.minecraft.fire_charge": "Fire Charge", "item.minecraft.firework_rocket": "Firework Rocket", "item.minecraft.firework_rocket.flight": "Flight Duration:", + "item.minecraft.firework_rocket.multiple_stars": "%s x %s", + "item.minecraft.firework_rocket.single_star": "%s", "item.minecraft.firework_star": "Firework Star", "item.minecraft.firework_star.black": "Black", "item.minecraft.firework_star.blue": "Blue", @@ -4575,13 +4626,14 @@ "item.modifiers.any": "When equipped:", "item.modifiers.armor": "When worn:", "item.modifiers.body": "When equipped:", - "item.modifiers.chest": "When on Body:", + "item.modifiers.chest": "When on Chest:", "item.modifiers.feet": "When on Feet:", "item.modifiers.hand": "When held:", "item.modifiers.head": "When on Head:", "item.modifiers.legs": "When on Legs:", "item.modifiers.mainhand": "When in Main Hand:", "item.modifiers.offhand": "When in Off Hand:", + "item.modifiers.saddle": "When saddled:", "item.nbt_tags": "NBT: %s tag(s)", "item.op_block_warning.line1": "Warning:", "item.op_block_warning.line2": "Use of this item might lead to command execution", @@ -4817,15 +4869,15 @@ "mco.backup.generate.world": "Generate world", "mco.backup.info.title": "Changes From Last Backup", "mco.backup.narration": "Backup from %s", - "mco.backup.nobackups": "This realm doesn't have any backups currently.", - "mco.backup.restoring": "Restoring your realm", + "mco.backup.nobackups": "This Realm doesn't have any backups currently.", + "mco.backup.restoring": "Restoring your Realm", "mco.backup.unknown": "UNKNOWN", "mco.brokenworld.download": "Download", "mco.brokenworld.downloaded": "Downloaded", "mco.brokenworld.message.line1": "Please reset or select another world.", "mco.brokenworld.message.line2": "You can also choose to download the world to singleplayer.", "mco.brokenworld.minigame.title": "This minigame is no longer supported", - "mco.brokenworld.nonowner.error": "Please wait for the realm owner to reset the world", + "mco.brokenworld.nonowner.error": "Please wait for the Realm owner to reset the world", "mco.brokenworld.nonowner.title": "World is out of date", "mco.brokenworld.play": "Play", "mco.brokenworld.reset": "Reset", @@ -4864,12 +4916,12 @@ "mco.configure.world.buttons.settings": "Settings", "mco.configure.world.buttons.subscription": "Subscription", "mco.configure.world.buttons.switchminigame": "Switch Minigame", - "mco.configure.world.close.question.line1": "Your realm will become unavailable.", + "mco.configure.world.close.question.line1": "Your Realm will become unavailable.", "mco.configure.world.close.question.line2": "Are you sure you want to continue?", - "mco.configure.world.closing": "Closing the realm...", + "mco.configure.world.closing": "Closing the Realm...", "mco.configure.world.commandBlocks": "Command Blocks", "mco.configure.world.delete.button": "Delete Realm", - "mco.configure.world.delete.question.line1": "Your realm will be permanently deleted", + "mco.configure.world.delete.question.line1": "Your Realm will be permanently deleted", "mco.configure.world.delete.question.line2": "Are you sure you want to continue?", "mco.configure.world.description": "Realm Description", "mco.configure.world.edit.slot.name": "World Name", @@ -4884,20 +4936,20 @@ "mco.configure.world.invites.normal.tooltip": "Normal User", "mco.configure.world.invites.ops.tooltip": "Operator", "mco.configure.world.invites.remove.tooltip": "Remove", - "mco.configure.world.leave.question.line1": "If you leave this realm you won't see it unless you are invited again", + "mco.configure.world.leave.question.line1": "If you leave this Realm you won't see it unless you are invited again", "mco.configure.world.leave.question.line2": "Are you sure you want to continue?", "mco.configure.world.location": "Location", "mco.configure.world.minigame": "Current: %s", "mco.configure.world.name": "Realm Name", - "mco.configure.world.opening": "Opening the realm...", + "mco.configure.world.opening": "Opening the Realm...", "mco.configure.world.players.error": "A player with the provided name does not exist", "mco.configure.world.players.inviting": "Inviting player...", "mco.configure.world.players.title": "Players", "mco.configure.world.pvp": "PVP", "mco.configure.world.reset.question.line1": "Your world will be regenerated and your current world will be lost", "mco.configure.world.reset.question.line2": "Are you sure you want to continue?", - "mco.configure.world.resourcepack.question": "You need a custom resource pack to play on this realm\n\nDo you want to download it and play?", - "mco.configure.world.resourcepack.question.line1": "You need a custom resource pack to play on this realm", + "mco.configure.world.resourcepack.question": "You need a custom resource pack to play on this Realm\n\nDo you want to download it and play?", + "mco.configure.world.resourcepack.question.line1": "You need a custom resource pack to play on this Realm", "mco.configure.world.resourcepack.question.line2": "Do you want to download it and play?", "mco.configure.world.restore.download.question.line1": "The world will be downloaded and added to your single player worlds.", "mco.configure.world.restore.download.question.line2": "Do you want to continue?", @@ -4906,7 +4958,7 @@ "mco.configure.world.settings.title": "Settings", "mco.configure.world.slot": "World %s", "mco.configure.world.slot.empty": "Empty", - "mco.configure.world.slot.switch.question.line1": "Your realm will be switched to another world", + "mco.configure.world.slot.switch.question.line1": "Your Realm will be switched to another world", "mco.configure.world.slot.switch.question.line2": "Are you sure you want to continue?", "mco.configure.world.slot.tooltip": "Switch to world", "mco.configure.world.slot.tooltip.active": "Join", @@ -4942,20 +4994,20 @@ "mco.configure.world.uninvite.question": "Are you sure that you want to uninvite", "mco.configure.worlds.title": "Worlds", "mco.connect.authorizing": "Logging in...", - "mco.connect.connecting": "Connecting to the realm...", - "mco.connect.failed": "Failed to connect to the realm", + "mco.connect.connecting": "Connecting to the Realm...", + "mco.connect.failed": "Failed to connect to the Realm", "mco.connect.success": "Done", "mco.create.world": "Create", "mco.create.world.error": "You must enter a name!", "mco.create.world.failed": "Failed to create world!", "mco.create.world.reset.title": "Creating world...", "mco.create.world.skip": "Skip", - "mco.create.world.subtitle": "Optionally, select what world to put on your new realm", - "mco.create.world.wait": "Creating the realm...", + "mco.create.world.subtitle": "Optionally, select what world to put on your new Realm", + "mco.create.world.wait": "Creating the Realm...", "mco.download.cancelled": "Download cancelled", "mco.download.confirmation.line1": "The world you are going to download is larger than %s", - "mco.download.confirmation.line2": "You won't be able to upload this world to your realm again", - "mco.download.confirmation.oversized": "The world you are going to download is larger than %s\n\nYou won't be able to upload this world to your realm again", + "mco.download.confirmation.line2": "You won't be able to upload this world to your Realm again", + "mco.download.confirmation.oversized": "The world you are going to download is larger than %s\n\nYou won't be able to upload this world to your Realm again", "mco.download.done": "Download done", "mco.download.downloading": "Downloading", "mco.download.extracting": "Extracting", @@ -5001,7 +5053,7 @@ "mco.minigame.world.info.line2": "You can later return to your original world without losing anything.", "mco.minigame.world.noSelection": "Please make a selection", "mco.minigame.world.restore": "Ending Minigame...", - "mco.minigame.world.restore.question.line1": "The minigame will end and your realm will be restored.", + "mco.minigame.world.restore.question.line1": "The minigame will end and your Realm will be restored.", "mco.minigame.world.restore.question.line2": "Are you sure you want to continue?", "mco.minigame.world.selected": "Selected Minigame:", "mco.minigame.world.slot.screen.title": "Switching World...", @@ -5028,16 +5080,16 @@ "mco.reset.world.template": "World Templates", "mco.reset.world.title": "Reset World", "mco.reset.world.upload": "Upload world", - "mco.reset.world.warning": "This will replace the current world of your realm", + "mco.reset.world.warning": "This will replace the current world of your Realm", "mco.selectServer.buy": "Buy a Realm!", "mco.selectServer.close": "Close", - "mco.selectServer.closed": "Closed realm", - "mco.selectServer.closeserver": "Close realm", + "mco.selectServer.closed": "Closed Realm", + "mco.selectServer.closeserver": "Close Realm", "mco.selectServer.configure": "Configure", - "mco.selectServer.configureRealm": "Configure realm", + "mco.selectServer.configureRealm": "Configure Realm", "mco.selectServer.create": "Create Realm", - "mco.selectServer.create.subtitle": "Select what world to put on your new realm", - "mco.selectServer.expired": "Expired realm", + "mco.selectServer.create.subtitle": "Select what world to put on your new Realm", + "mco.selectServer.expired": "Expired Realm", "mco.selectServer.expiredList": "Your subscription has expired", "mco.selectServer.expiredRenew": "Renew", "mco.selectServer.expiredSubscribe": "Subscribe", @@ -5053,13 +5105,13 @@ "mco.selectServer.minigameNotSupportedInVersion": "Can't play this minigame in %s", "mco.selectServer.noRealms": "You don't seem to have a Realm. Add a Realm to play together with your friends.", "mco.selectServer.note": "Note:", - "mco.selectServer.open": "Open realm", - "mco.selectServer.openserver": "Open realm", + "mco.selectServer.open": "Open Realm", + "mco.selectServer.openserver": "Open Realm", "mco.selectServer.play": "Play", "mco.selectServer.popup": "Realms is a safe, simple way to enjoy an online Minecraft world with up to ten friends at a time. It supports loads of minigames and plenty of custom worlds! Only the owner of the realm needs to pay.", "mco.selectServer.purchase": "Add Realm", "mco.selectServer.trial": "Get a Trial!", - "mco.selectServer.uninitialized": "Click to start your new realm!", + "mco.selectServer.uninitialized": "Click to start your new Realm!", "mco.snapshot.createSnapshotPopup.text": "You are about to create a free Snapshot Realm that will be paired with your paid Realms subscription. This new Snapshot Realm will be accessible for as long as the paid subscription is active. Your paid Realm will not be affected.", "mco.snapshot.createSnapshotPopup.title": "Create Snapshot Realm?", "mco.snapshot.creating": "Creating Snapshot Realm...", @@ -5098,11 +5150,11 @@ "mco.time.minutesAgo": "%1$s minute(s) ago", "mco.time.now": "right now", "mco.time.secondsAgo": "%1$s second(s) ago", - "mco.trial.message.line1": "Want to get your own realm?", + "mco.trial.message.line1": "Want to get your own Realm?", "mco.trial.message.line2": "Click here for more info!", "mco.upload.button.name": "Upload", "mco.upload.cancelled": "Upload cancelled", - "mco.upload.close.failure": "Could not close your realm, please try again later", + "mco.upload.close.failure": "Could not close your Realm, please try again later", "mco.upload.done": "Upload done", "mco.upload.entry.cheats": "%1$s, %2$s", "mco.upload.entry.commands": "%1$s, %2$s", @@ -5162,6 +5214,7 @@ "mount.onboard": "Press %1$s to Dismount", "multiplayer.applyingPack": "Applying resource pack", "multiplayer.disconnect.authservers_down": "Authentication servers are down. Please try again later, sorry!", + "multiplayer.disconnect.bad_chat_index": "Detected missed or reordered chat message from server", "multiplayer.disconnect.banned": "You are banned from this server", "multiplayer.disconnect.banned_ip.expiration": "\nYour ban will be removed on %s", "multiplayer.disconnect.banned_ip.reason": "Your IP address is banned from this server.\nReason: %s", @@ -5697,7 +5750,7 @@ "realms.missing.snapshot.error.text": "Realms is currently not supported in snapshots", "recipe.notFound": "Unknown recipe: %s", "recipe.toast.description": "Check your recipe book", - "recipe.toast.title": "New Recipes Unlocked!", + "recipe.toast.title": "New Recipe(s) Unlocked!", "record.nowPlaying": "Now Playing: %s", "recover_world.bug_tracker": "Report a Bug", "recover_world.button": "Attempt to Recover", @@ -5868,6 +5921,27 @@ "sleep.skipping_night": "Sleeping through this night", "slot.only_single_allowed": "Only single slots allowed, got '%s'", "slot.unknown": "Unknown slot '%s'", + "snbt.parser.empty_key": "Key cannot be empty", + "snbt.parser.expected_binary_numeral": "Expected a binary number", + "snbt.parser.expected_decimal_numeral": "Expected a decimal number", + "snbt.parser.expected_float_type": "Expected a floating point number", + "snbt.parser.expected_hex_escape": "Expected a character literal of length %s", + "snbt.parser.expected_hex_numeral": "Expected a hexadecimal number", + "snbt.parser.expected_integer_type": "Expected an integer number", + "snbt.parser.expected_non_negative_number": "Expected a non-negative number", + "snbt.parser.expected_number_or_boolean": "Expected a number or a boolean", + "snbt.parser.expected_string_uuid": "Expected a string representing a valid UUID", + "snbt.parser.expected_unquoted_string": "Expected a valid unquoted string", + "snbt.parser.infinity_not_allowed": "Non-finite numbers are not allowed", + "snbt.parser.invalid_array_element_type": "Invalid array element type", + "snbt.parser.invalid_character_name": "Invalid Unicode character name", + "snbt.parser.invalid_codepoint": "Invalid Unicode character value: %s", + "snbt.parser.invalid_string_contents": "Invalid string contents", + "snbt.parser.invalid_unquoted_start": "Unquoted strings can't start with digits 0-9, + or -", + "snbt.parser.leading_zero_not_allowed": "Decimal numbers can't start with 0", + "snbt.parser.no_such_operation": "No such operation: %s", + "snbt.parser.number_parse_failure": "Failed to parse number: %s", + "snbt.parser.undescore_not_allowed": "Underscore characters are not allowed at the start or end of a number", "soundCategory.ambient": "Ambient/Environment", "soundCategory.block": "Blocks", "soundCategory.hostile": "Hostile Creatures", @@ -5992,10 +6066,10 @@ "structure_block.load_not_found": "Structure '%s' is not available", "structure_block.load_prepare": "Structure '%s' position prepared", "structure_block.load_success": "Structure loaded from '%s'", - "structure_block.mode_info.corner": "Corner Mode - Placement and Size Marker", - "structure_block.mode_info.data": "Data Mode - Game Logic Marker", - "structure_block.mode_info.load": "Load Mode - Load from File", - "structure_block.mode_info.save": "Save Mode - Write to File", + "structure_block.mode_info.corner": "Corner Mode - Placement and size marker", + "structure_block.mode_info.data": "Data Mode - Game logic marker", + "structure_block.mode_info.load": "Load Mode - Load from file", + "structure_block.mode_info.save": "Save Mode - Write to file", "structure_block.mode.corner": "Corner", "structure_block.mode.data": "Data", "structure_block.mode.load": "Load", @@ -6014,6 +6088,7 @@ "structure_block.size.x": "structure size x", "structure_block.size.y": "structure size y", "structure_block.size.z": "structure size z", + "structure_block.strict": "Strict Placement:", "structure_block.structure_name": "Structure Name", "subtitles.ambient.cave": "Eerie noise", "subtitles.ambient.sound": "Eerie noise", @@ -6071,6 +6146,7 @@ "subtitles.block.creaking_heart.hurt": "Creaking Heart grumbles", "subtitles.block.creaking_heart.idle": "Eerie noise", "subtitles.block.creaking_heart.spawn": "Creaking Heart awakens", + "subtitles.block.deadbush.idle": "Dry sounds", "subtitles.block.decorated_pot.insert": "Decorated Pot fills", "subtitles.block.decorated_pot.insert_fail": "Decorated Pot wobbles", "subtitles.block.decorated_pot.shatter": "Decorated Pot shatters", @@ -6086,6 +6162,7 @@ "subtitles.block.fence_gate.toggle": "Fence Gate creaks", "subtitles.block.fire.ambient": "Fire crackles", "subtitles.block.fire.extinguish": "Fire extinguished", + "subtitles.block.firefly_bush.idle": "Fireflies buzz", "subtitles.block.frogspawn.hatch": "Tadpole hatches", "subtitles.block.furnace.fire_crackle": "Furnace crackles", "subtitles.block.generic.break": "Block broken", @@ -6120,14 +6197,16 @@ "subtitles.block.respawn_anchor.charge": "Respawn Anchor is charged", "subtitles.block.respawn_anchor.deplete": "Respawn Anchor depletes", "subtitles.block.respawn_anchor.set_spawn": "Respawn Anchor sets spawn", + "subtitles.block.sand.idle": "Sandy sounds", + "subtitles.block.sand.wind": "Windy sounds", "subtitles.block.sculk_catalyst.bloom": "Sculk Catalyst blooms", "subtitles.block.sculk_sensor.clicking": "Sculk Sensor clicks", "subtitles.block.sculk_sensor.clicking_stop": "Sculk Sensor stops clicking", "subtitles.block.sculk_shrieker.shriek": "Sculk Shrieker shrieks", "subtitles.block.sculk.charge": "Sculk bubbles", "subtitles.block.sculk.spread": "Sculk spreads", - "subtitles.block.shulker_box.close": "Shulker closes", - "subtitles.block.shulker_box.open": "Shulker opens", + "subtitles.block.shulker_box.close": "Shulker box closes", + "subtitles.block.shulker_box.open": "Shulker box opens", "subtitles.block.sign.waxed_interact_fail": "Sign wobbles", "subtitles.block.smithing_table.use": "Smithing Table used", "subtitles.block.smoker.smoke": "Smoker smokes", @@ -6754,10 +6833,13 @@ "subtitles.entity.wither.shoot": "Wither attacks", "subtitles.entity.wither.spawn": "Wither released", "subtitles.entity.wolf.ambient": "Wolf pants", + "subtitles.entity.wolf.bark": "Wolf barks", "subtitles.entity.wolf.death": "Wolf dies", "subtitles.entity.wolf.growl": "Wolf growls", "subtitles.entity.wolf.hurt": "Wolf hurts", + "subtitles.entity.wolf.pant": "Wolf pants", "subtitles.entity.wolf.shake": "Wolf shakes", + "subtitles.entity.wolf.whine": "Wolf whines", "subtitles.entity.zoglin.ambient": "Zoglin growls", "subtitles.entity.zoglin.angry": "Zoglin growls angrily", "subtitles.entity.zoglin.attack": "Zoglin attacks", @@ -6933,6 +7015,85 @@ "telemetry.property.user_id.title": "User ID", "telemetry.property.world_load_time_ms.title": "World Load Time (Milliseconds)", "telemetry.property.world_session_id.title": "World Session ID", + "test_block.error.missing": "Test structure missing %s block", + "test_block.error.too_many": "Too many %s blocks", + "test_block.invalid_timeout": "Invalid timeout (%s) - must be a positive number of ticks", + "test_block.message": "Message:", + "test_block.mode_info.accept": "Accept Mode - Accept success for (part of) a test", + "test_block.mode_info.fail": "Fail Mode - Fail the test", + "test_block.mode_info.log": "Log Mode - Log a message", + "test_block.mode_info.start": "Start Mode - The starting point for a test", + "test_block.mode.accept": "Accept", + "test_block.mode.fail": "Fail", + "test_block.mode.log": "Log", + "test_block.mode.start": "Start", + "test_instance_block.entities": "Entities:", + "test_instance_block.error.no_test": "Unable to run test instance at %s, %s, %s since it has an undefined test", + "test_instance_block.error.no_test_structure": "Unable to run test instance at %s, %s, %s since it has no test structure", + "test_instance_block.error.unable_to_save": "Unable to save test structure template for test instance at %s, %s, %s", + "test_instance_block.invalid": "[invalid]", + "test_instance_block.reset_success": "Reset succeeded for test: %s", + "test_instance_block.rotation": "Rotation:", + "test_instance_block.size": "Test Structure Size", + "test_instance_block.starting": "Starting test %s", + "test_instance_block.test_id": "Test Instance ID", + "test_instance.action.reset": "Reset and Load", + "test_instance.action.run": "Load and Run", + "test_instance.action.save": "Save Structure", + "test_instance.description.batch": "Batch: %s", + "test_instance.description.failed": "Failed: %s", + "test_instance.description.function": "Function: %s", + "test_instance.description.invalid_id": "Invalid test ID", + "test_instance.description.no_test": "No such test", + "test_instance.description.structure": "Structure: %s", + "test_instance.description.type": "Type: %s", + "test_instance.type.block_based": "Block-Based Test", + "test_instance.type.function": "Built-in Function Test", + "test.error.block_property_mismatch": "Expected property %s to be %s, was %s", + "test.error.block_property_missing": "Block property missing, expected property %s to be %s", + "test.error.entity_property": "Entity %s failed test: %s", + "test.error.entity_property_details": "Entity %s failed test: %s, expected: %s, was: %s", + "test.error.expected_block": "Expected block %s, got %s", + "test.error.expected_block_tag": "Expected block in #%s, got %s", + "test.error.expected_container_contents": "Container should contain: %s", + "test.error.expected_container_contents_single": "Container should contain a single: %s", + "test.error.expected_empty_container": "Container should be empty", + "test.error.expected_entity": "Expected %s", + "test.error.expected_entity_around": "Expected %s to exist around %s, %s, %s", + "test.error.expected_entity_count": "Expected %s entities of type %s, found %s", + "test.error.expected_entity_data": "Expected entity data to be: %s, was: %s", + "test.error.expected_entity_data_predicate": "Entity data mismatch for %s", + "test.error.expected_entity_effect": "Expected %s to have effect %s %s", + "test.error.expected_entity_having": "Entity inventory should contain %s", + "test.error.expected_entity_holding": "Entity should be holding %s", + "test.error.expected_entity_in_test": "Expected %s to exist in test", + "test.error.expected_entity_not_touching": "Did not expect %s touching %s, %s, %s (relative: %s, %s, %s)", + "test.error.expected_entity_touching": "Expected %s touching %s, %s, %s (relative: %s, %s, %s)", + "test.error.expected_item": "Expected item of type %s", + "test.error.expected_items_count": "Expected %s items of type %s, found %s", + "test.error.fail": "Fail conditions met", + "test.error.invalid_block_type": "Unexpected block type found: %s", + "test.error.missing_block_entity": "Missing block entity", + "test.error.position": "%s at %s, %s, %s (relative: %s, %s, %s) on tick %s", + "test.error.sequence.condition_already_triggered": "Condition already triggered at %s", + "test.error.sequence.condition_not_triggered": "Condition not triggered", + "test.error.sequence.invalid_tick": "Succeeded in invalid tick: expected %s", + "test.error.sequence.not_completed": "Test timed out before sequence completed", + "test.error.set_biome": "Failed to set biome for test", + "test.error.spawn_failure": "Failed to create entity %s", + "test.error.state_not_equal": "Incorrect state. Expected %s, was %s", + "test.error.structure.failure": "Failed to place test structure for %s", + "test.error.tick": "%s on tick %s", + "test.error.ticking_without_structure": "Ticking test before placing structure", + "test.error.timeout.no_result": "Didn't succeed or fail within %s ticks", + "test.error.timeout.no_sequences_finished": "No sequences finished within %s ticks", + "test.error.too_many_entities": "Expected only one %s to exist around %s, %s, %s but found %s", + "test.error.unexpected_block": "Did not expect block to be %s", + "test.error.unexpected_entity": "Did not expect %s to exist", + "test.error.unexpected_item": "Did not expect item of type %s", + "test.error.unknown": "Unknown internal error: %s", + "test.error.value_not_equal": "Expected %s to be %s, was %s", + "test.error.wrong_block_entity": "Wrong block entity type: %s", "title.32bit.deprecation": "32-bit system detected: this may prevent you from playing in the future as a 64-bit system will be required!", "title.32bit.deprecation.realms": "Minecraft will soon require a 64-bit system, which will prevent you from playing or using Realms on this device. You will need to manually cancel any Realms subscription.", "title.32bit.deprecation.realms.check": "Do not show this screen again", diff --git a/assets/minecraft/models/block/bush.json b/assets/minecraft/models/block/bush.json new file mode 100644 index 00000000..e58ffca2 --- /dev/null +++ b/assets/minecraft/models/block/bush.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/tinted_cross", + "textures": { + "cross": "minecraft:block/bush" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/cactus_flower.json b/assets/minecraft/models/block/cactus_flower.json new file mode 100644 index 00000000..541d458c --- /dev/null +++ b/assets/minecraft/models/block/cactus_flower.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cross", + "textures": { + "cross": "minecraft:block/cactus_flower" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/creaking_heart_active.json b/assets/minecraft/models/block/creaking_heart_active.json deleted file mode 100644 index cd2b0498..00000000 --- a/assets/minecraft/models/block/creaking_heart_active.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "minecraft:block/cube_column", - "textures": { - "end": "minecraft:block/creaking_heart_top_active", - "side": "minecraft:block/creaking_heart_active" - } -} \ No newline at end of file diff --git a/assets/minecraft/models/block/creaking_heart_active_horizontal.json b/assets/minecraft/models/block/creaking_heart_active_horizontal.json deleted file mode 100644 index c3601332..00000000 --- a/assets/minecraft/models/block/creaking_heart_active_horizontal.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "minecraft:block/cube_column_horizontal", - "textures": { - "end": "minecraft:block/creaking_heart_top_active", - "side": "minecraft:block/creaking_heart_active" - } -} \ No newline at end of file diff --git a/assets/minecraft/models/block/creaking_heart_awake.json b/assets/minecraft/models/block/creaking_heart_awake.json new file mode 100644 index 00000000..75db0a2f --- /dev/null +++ b/assets/minecraft/models/block/creaking_heart_awake.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/cube_column", + "textures": { + "end": "minecraft:block/creaking_heart_top_awake", + "side": "minecraft:block/creaking_heart_awake" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/creaking_heart_awake_horizontal.json b/assets/minecraft/models/block/creaking_heart_awake_horizontal.json new file mode 100644 index 00000000..b4e45301 --- /dev/null +++ b/assets/minecraft/models/block/creaking_heart_awake_horizontal.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/cube_column_horizontal", + "textures": { + "end": "minecraft:block/creaking_heart_top_awake", + "side": "minecraft:block/creaking_heart_awake" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/creaking_heart_dormant.json b/assets/minecraft/models/block/creaking_heart_dormant.json new file mode 100644 index 00000000..6ae07d24 --- /dev/null +++ b/assets/minecraft/models/block/creaking_heart_dormant.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/cube_column", + "textures": { + "end": "minecraft:block/creaking_heart_top_dormant", + "side": "minecraft:block/creaking_heart_dormant" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/creaking_heart_dormant_horizontal.json b/assets/minecraft/models/block/creaking_heart_dormant_horizontal.json new file mode 100644 index 00000000..acb48037 --- /dev/null +++ b/assets/minecraft/models/block/creaking_heart_dormant_horizontal.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/cube_column_horizontal", + "textures": { + "end": "minecraft:block/creaking_heart_top_dormant", + "side": "minecraft:block/creaking_heart_dormant" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/firefly_bush.json b/assets/minecraft/models/block/firefly_bush.json new file mode 100644 index 00000000..668f253c --- /dev/null +++ b/assets/minecraft/models/block/firefly_bush.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/cross_emissive", + "textures": { + "cross": "minecraft:block/firefly_bush", + "cross_emissive": "minecraft:block/firefly_bush_emissive" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/leaf_litter_1.json b/assets/minecraft/models/block/leaf_litter_1.json new file mode 100644 index 00000000..cf22052c --- /dev/null +++ b/assets/minecraft/models/block/leaf_litter_1.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/template_leaf_litter_1", + "textures": { + "texture": "minecraft:block/leaf_litter" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/leaf_litter_2.json b/assets/minecraft/models/block/leaf_litter_2.json new file mode 100644 index 00000000..17325008 --- /dev/null +++ b/assets/minecraft/models/block/leaf_litter_2.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/template_leaf_litter_2", + "textures": { + "texture": "minecraft:block/leaf_litter" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/leaf_litter_3.json b/assets/minecraft/models/block/leaf_litter_3.json new file mode 100644 index 00000000..26644529 --- /dev/null +++ b/assets/minecraft/models/block/leaf_litter_3.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/template_leaf_litter_3", + "textures": { + "texture": "minecraft:block/leaf_litter" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/leaf_litter_4.json b/assets/minecraft/models/block/leaf_litter_4.json new file mode 100644 index 00000000..0e565f75 --- /dev/null +++ b/assets/minecraft/models/block/leaf_litter_4.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/template_leaf_litter_4", + "textures": { + "texture": "minecraft:block/leaf_litter" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/short_dry_grass.json b/assets/minecraft/models/block/short_dry_grass.json new file mode 100644 index 00000000..062a1f33 --- /dev/null +++ b/assets/minecraft/models/block/short_dry_grass.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cross", + "textures": { + "cross": "minecraft:block/short_dry_grass" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/tall_dry_grass.json b/assets/minecraft/models/block/tall_dry_grass.json new file mode 100644 index 00000000..eeefccac --- /dev/null +++ b/assets/minecraft/models/block/tall_dry_grass.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cross", + "textures": { + "cross": "minecraft:block/tall_dry_grass" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/template_leaf_litter_1.json b/assets/minecraft/models/block/template_leaf_litter_1.json new file mode 100644 index 00000000..355e715e --- /dev/null +++ b/assets/minecraft/models/block/template_leaf_litter_1.json @@ -0,0 +1,16 @@ +{ + "ambientocclusion": false, + "textures": { + "particle": "#texture" + }, + "elements": [ + { + "from": [0, 0.25, 0], + "to": [8, 0.25, 8], + "faces": { + "up": {"uv": [0, 0, 8, 8], "texture": "#texture", "tintindex": 0}, + "down": {"uv": [0, 8, 8, 0], "texture": "#texture", "tintindex": 0} + } + } + ] +} diff --git a/assets/minecraft/models/block/template_leaf_litter_2.json b/assets/minecraft/models/block/template_leaf_litter_2.json new file mode 100644 index 00000000..06589413 --- /dev/null +++ b/assets/minecraft/models/block/template_leaf_litter_2.json @@ -0,0 +1,16 @@ +{ + "ambientocclusion": false, + "textures": { + "particle": "#texture" + }, + "elements": [ + { + "from": [0, 0.25, 0], + "to": [8, 0.25, 16], + "faces": { + "up": {"uv": [0, 0, 8, 16], "texture": "#texture", "tintindex": 0}, + "down": {"uv": [0, 16, 8, 0], "texture": "#texture", "tintindex": 0} + } + } + ] +} diff --git a/assets/minecraft/models/block/template_leaf_litter_3.json b/assets/minecraft/models/block/template_leaf_litter_3.json new file mode 100644 index 00000000..bcd97e3a --- /dev/null +++ b/assets/minecraft/models/block/template_leaf_litter_3.json @@ -0,0 +1,16 @@ +{ + "ambientocclusion": false, + "textures": { + "particle": "#texture" + }, + "elements": [ + { + "from": [8, 0.25, 8], + "to": [16, 0.25, 16], + "faces": { + "up": {"uv": [8, 8, 16, 16], "texture": "#texture", "tintindex": 0}, + "down": {"uv": [8, 16, 16, 8], "texture": "#texture", "tintindex": 0} + } + } + ] +} diff --git a/assets/minecraft/models/block/template_leaf_litter_4.json b/assets/minecraft/models/block/template_leaf_litter_4.json new file mode 100644 index 00000000..f8d9d434 --- /dev/null +++ b/assets/minecraft/models/block/template_leaf_litter_4.json @@ -0,0 +1,16 @@ +{ + "ambientocclusion": false, + "textures": { + "particle": "#texture" + }, + "elements": [ + { + "from": [0, 0.25, 0], + "to": [16, 0.25, 16], + "faces": { + "up": {"uv": [0, 0, 16, 16], "texture": "#texture", "tintindex": 0}, + "down": {"uv": [0, 16, 16, 0], "texture": "#texture", "tintindex": 0} + } + } + ] +} diff --git a/assets/minecraft/models/block/test_block_accept.json b/assets/minecraft/models/block/test_block_accept.json new file mode 100644 index 00000000..e9bf9b1c --- /dev/null +++ b/assets/minecraft/models/block/test_block_accept.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "minecraft:block/test_block_accept" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/test_block_fail.json b/assets/minecraft/models/block/test_block_fail.json new file mode 100644 index 00000000..04fd1773 --- /dev/null +++ b/assets/minecraft/models/block/test_block_fail.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "minecraft:block/test_block_fail" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/test_block_log.json b/assets/minecraft/models/block/test_block_log.json new file mode 100644 index 00000000..9799e8df --- /dev/null +++ b/assets/minecraft/models/block/test_block_log.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "minecraft:block/test_block_log" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/test_block_start.json b/assets/minecraft/models/block/test_block_start.json new file mode 100644 index 00000000..387827a4 --- /dev/null +++ b/assets/minecraft/models/block/test_block_start.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "minecraft:block/test_block_start" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/test_instance_block.json b/assets/minecraft/models/block/test_instance_block.json new file mode 100644 index 00000000..dae43c63 --- /dev/null +++ b/assets/minecraft/models/block/test_instance_block.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:block/cube_all", + "textures": { + "all": "minecraft:block/test_instance_block" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/wildflowers_1.json b/assets/minecraft/models/block/wildflowers_1.json new file mode 100644 index 00000000..d6ec7f17 --- /dev/null +++ b/assets/minecraft/models/block/wildflowers_1.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/flowerbed_1", + "textures": { + "flowerbed": "minecraft:block/wildflowers", + "stem": "minecraft:block/wildflowers_stem" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/wildflowers_2.json b/assets/minecraft/models/block/wildflowers_2.json new file mode 100644 index 00000000..7bb30b8b --- /dev/null +++ b/assets/minecraft/models/block/wildflowers_2.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/flowerbed_2", + "textures": { + "flowerbed": "minecraft:block/wildflowers", + "stem": "minecraft:block/wildflowers_stem" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/wildflowers_3.json b/assets/minecraft/models/block/wildflowers_3.json new file mode 100644 index 00000000..e2e004f5 --- /dev/null +++ b/assets/minecraft/models/block/wildflowers_3.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/flowerbed_3", + "textures": { + "flowerbed": "minecraft:block/wildflowers", + "stem": "minecraft:block/wildflowers_stem" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/block/wildflowers_4.json b/assets/minecraft/models/block/wildflowers_4.json new file mode 100644 index 00000000..ee50217b --- /dev/null +++ b/assets/minecraft/models/block/wildflowers_4.json @@ -0,0 +1,7 @@ +{ + "parent": "minecraft:block/flowerbed_4", + "textures": { + "flowerbed": "minecraft:block/wildflowers", + "stem": "minecraft:block/wildflowers_stem" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/allay_spawn_egg.json b/assets/minecraft/models/item/allay_spawn_egg.json new file mode 100644 index 00000000..b7365fef --- /dev/null +++ b/assets/minecraft/models/item/allay_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/allay_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/armadillo_spawn_egg.json b/assets/minecraft/models/item/armadillo_spawn_egg.json new file mode 100644 index 00000000..73c5e691 --- /dev/null +++ b/assets/minecraft/models/item/armadillo_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/armadillo_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/axolotl_spawn_egg.json b/assets/minecraft/models/item/axolotl_spawn_egg.json new file mode 100644 index 00000000..90a12422 --- /dev/null +++ b/assets/minecraft/models/item/axolotl_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/axolotl_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/bat_spawn_egg.json b/assets/minecraft/models/item/bat_spawn_egg.json new file mode 100644 index 00000000..1d2f0475 --- /dev/null +++ b/assets/minecraft/models/item/bat_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/bat_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/bee_spawn_egg.json b/assets/minecraft/models/item/bee_spawn_egg.json new file mode 100644 index 00000000..93aed8c1 --- /dev/null +++ b/assets/minecraft/models/item/bee_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/bee_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/blaze_spawn_egg.json b/assets/minecraft/models/item/blaze_spawn_egg.json new file mode 100644 index 00000000..46864292 --- /dev/null +++ b/assets/minecraft/models/item/blaze_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/blaze_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/blue_egg.json b/assets/minecraft/models/item/blue_egg.json new file mode 100644 index 00000000..5d2aa874 --- /dev/null +++ b/assets/minecraft/models/item/blue_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/blue_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/bogged_spawn_egg.json b/assets/minecraft/models/item/bogged_spawn_egg.json new file mode 100644 index 00000000..fb5ddc07 --- /dev/null +++ b/assets/minecraft/models/item/bogged_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/bogged_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/breeze_spawn_egg.json b/assets/minecraft/models/item/breeze_spawn_egg.json new file mode 100644 index 00000000..e421a590 --- /dev/null +++ b/assets/minecraft/models/item/breeze_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/breeze_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/brown_egg.json b/assets/minecraft/models/item/brown_egg.json new file mode 100644 index 00000000..900e61a9 --- /dev/null +++ b/assets/minecraft/models/item/brown_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/brown_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/bush.json b/assets/minecraft/models/item/bush.json new file mode 100644 index 00000000..b9945900 --- /dev/null +++ b/assets/minecraft/models/item/bush.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:block/bush" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/cactus_flower.json b/assets/minecraft/models/item/cactus_flower.json new file mode 100644 index 00000000..c9760172 --- /dev/null +++ b/assets/minecraft/models/item/cactus_flower.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:block/cactus_flower" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/camel_spawn_egg.json b/assets/minecraft/models/item/camel_spawn_egg.json new file mode 100644 index 00000000..1ac9acb3 --- /dev/null +++ b/assets/minecraft/models/item/camel_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/camel_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/cat_spawn_egg.json b/assets/minecraft/models/item/cat_spawn_egg.json new file mode 100644 index 00000000..385f2c10 --- /dev/null +++ b/assets/minecraft/models/item/cat_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/cat_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/cave_spider_spawn_egg.json b/assets/minecraft/models/item/cave_spider_spawn_egg.json new file mode 100644 index 00000000..f5f57afb --- /dev/null +++ b/assets/minecraft/models/item/cave_spider_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/cave_spider_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/chicken_spawn_egg.json b/assets/minecraft/models/item/chicken_spawn_egg.json new file mode 100644 index 00000000..bd2b54fd --- /dev/null +++ b/assets/minecraft/models/item/chicken_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/chicken_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/cod_spawn_egg.json b/assets/minecraft/models/item/cod_spawn_egg.json new file mode 100644 index 00000000..f77e73aa --- /dev/null +++ b/assets/minecraft/models/item/cod_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/cod_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/cow_spawn_egg.json b/assets/minecraft/models/item/cow_spawn_egg.json new file mode 100644 index 00000000..dff99686 --- /dev/null +++ b/assets/minecraft/models/item/cow_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/cow_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/creaking_spawn_egg.json b/assets/minecraft/models/item/creaking_spawn_egg.json new file mode 100644 index 00000000..7f7e2f93 --- /dev/null +++ b/assets/minecraft/models/item/creaking_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/creaking_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/creeper_spawn_egg.json b/assets/minecraft/models/item/creeper_spawn_egg.json new file mode 100644 index 00000000..226a73e7 --- /dev/null +++ b/assets/minecraft/models/item/creeper_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/creeper_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/dolphin_spawn_egg.json b/assets/minecraft/models/item/dolphin_spawn_egg.json new file mode 100644 index 00000000..91e8a5df --- /dev/null +++ b/assets/minecraft/models/item/dolphin_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/dolphin_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/donkey_spawn_egg.json b/assets/minecraft/models/item/donkey_spawn_egg.json new file mode 100644 index 00000000..77caa043 --- /dev/null +++ b/assets/minecraft/models/item/donkey_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/donkey_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/drowned_spawn_egg.json b/assets/minecraft/models/item/drowned_spawn_egg.json new file mode 100644 index 00000000..c1ec4250 --- /dev/null +++ b/assets/minecraft/models/item/drowned_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/drowned_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/elder_guardian_spawn_egg.json b/assets/minecraft/models/item/elder_guardian_spawn_egg.json new file mode 100644 index 00000000..8d432b66 --- /dev/null +++ b/assets/minecraft/models/item/elder_guardian_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/elder_guardian_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/ender_dragon_spawn_egg.json b/assets/minecraft/models/item/ender_dragon_spawn_egg.json new file mode 100644 index 00000000..d0a2206d --- /dev/null +++ b/assets/minecraft/models/item/ender_dragon_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/ender_dragon_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/enderman_spawn_egg.json b/assets/minecraft/models/item/enderman_spawn_egg.json new file mode 100644 index 00000000..6ea7d688 --- /dev/null +++ b/assets/minecraft/models/item/enderman_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/enderman_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/endermite_spawn_egg.json b/assets/minecraft/models/item/endermite_spawn_egg.json new file mode 100644 index 00000000..775b5e8a --- /dev/null +++ b/assets/minecraft/models/item/endermite_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/endermite_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/evoker_spawn_egg.json b/assets/minecraft/models/item/evoker_spawn_egg.json new file mode 100644 index 00000000..4b120124 --- /dev/null +++ b/assets/minecraft/models/item/evoker_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/evoker_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/firefly_bush.json b/assets/minecraft/models/item/firefly_bush.json new file mode 100644 index 00000000..e166c357 --- /dev/null +++ b/assets/minecraft/models/item/firefly_bush.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/firefly_bush" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/fox_spawn_egg.json b/assets/minecraft/models/item/fox_spawn_egg.json new file mode 100644 index 00000000..3a3fd8d4 --- /dev/null +++ b/assets/minecraft/models/item/fox_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/fox_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/frog_spawn_egg.json b/assets/minecraft/models/item/frog_spawn_egg.json new file mode 100644 index 00000000..08e60641 --- /dev/null +++ b/assets/minecraft/models/item/frog_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/frog_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/ghast_spawn_egg.json b/assets/minecraft/models/item/ghast_spawn_egg.json new file mode 100644 index 00000000..727230af --- /dev/null +++ b/assets/minecraft/models/item/ghast_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/ghast_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/glow_squid_spawn_egg.json b/assets/minecraft/models/item/glow_squid_spawn_egg.json new file mode 100644 index 00000000..1cfe9f30 --- /dev/null +++ b/assets/minecraft/models/item/glow_squid_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/glow_squid_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/goat_spawn_egg.json b/assets/minecraft/models/item/goat_spawn_egg.json new file mode 100644 index 00000000..145421ec --- /dev/null +++ b/assets/minecraft/models/item/goat_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/goat_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/guardian_spawn_egg.json b/assets/minecraft/models/item/guardian_spawn_egg.json new file mode 100644 index 00000000..da7bdc47 --- /dev/null +++ b/assets/minecraft/models/item/guardian_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/guardian_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/hoglin_spawn_egg.json b/assets/minecraft/models/item/hoglin_spawn_egg.json new file mode 100644 index 00000000..f70b2420 --- /dev/null +++ b/assets/minecraft/models/item/hoglin_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/hoglin_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/horse_spawn_egg.json b/assets/minecraft/models/item/horse_spawn_egg.json new file mode 100644 index 00000000..acd1d7e3 --- /dev/null +++ b/assets/minecraft/models/item/horse_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/horse_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/husk_spawn_egg.json b/assets/minecraft/models/item/husk_spawn_egg.json new file mode 100644 index 00000000..67e1acb1 --- /dev/null +++ b/assets/minecraft/models/item/husk_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/husk_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/iron_golem_spawn_egg.json b/assets/minecraft/models/item/iron_golem_spawn_egg.json new file mode 100644 index 00000000..833cd364 --- /dev/null +++ b/assets/minecraft/models/item/iron_golem_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/iron_golem_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/leaf_litter.json b/assets/minecraft/models/item/leaf_litter.json new file mode 100644 index 00000000..3c03d48c --- /dev/null +++ b/assets/minecraft/models/item/leaf_litter.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/leaf_litter" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/llama_spawn_egg.json b/assets/minecraft/models/item/llama_spawn_egg.json new file mode 100644 index 00000000..4950af13 --- /dev/null +++ b/assets/minecraft/models/item/llama_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/llama_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/magma_cube_spawn_egg.json b/assets/minecraft/models/item/magma_cube_spawn_egg.json new file mode 100644 index 00000000..5fd646c6 --- /dev/null +++ b/assets/minecraft/models/item/magma_cube_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/magma_cube_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/mooshroom_spawn_egg.json b/assets/minecraft/models/item/mooshroom_spawn_egg.json new file mode 100644 index 00000000..9b53bf4e --- /dev/null +++ b/assets/minecraft/models/item/mooshroom_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/mooshroom_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/mule_spawn_egg.json b/assets/minecraft/models/item/mule_spawn_egg.json new file mode 100644 index 00000000..1b73ff67 --- /dev/null +++ b/assets/minecraft/models/item/mule_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/mule_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/ocelot_spawn_egg.json b/assets/minecraft/models/item/ocelot_spawn_egg.json new file mode 100644 index 00000000..4adda930 --- /dev/null +++ b/assets/minecraft/models/item/ocelot_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/ocelot_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/panda_spawn_egg.json b/assets/minecraft/models/item/panda_spawn_egg.json new file mode 100644 index 00000000..e18ff722 --- /dev/null +++ b/assets/minecraft/models/item/panda_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/panda_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/parrot_spawn_egg.json b/assets/minecraft/models/item/parrot_spawn_egg.json new file mode 100644 index 00000000..dbda1d12 --- /dev/null +++ b/assets/minecraft/models/item/parrot_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/parrot_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/phantom_spawn_egg.json b/assets/minecraft/models/item/phantom_spawn_egg.json new file mode 100644 index 00000000..0e9a8784 --- /dev/null +++ b/assets/minecraft/models/item/phantom_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/phantom_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/pig_spawn_egg.json b/assets/minecraft/models/item/pig_spawn_egg.json new file mode 100644 index 00000000..c9f75608 --- /dev/null +++ b/assets/minecraft/models/item/pig_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/pig_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/piglin_brute_spawn_egg.json b/assets/minecraft/models/item/piglin_brute_spawn_egg.json new file mode 100644 index 00000000..040d3224 --- /dev/null +++ b/assets/minecraft/models/item/piglin_brute_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/piglin_brute_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/piglin_spawn_egg.json b/assets/minecraft/models/item/piglin_spawn_egg.json new file mode 100644 index 00000000..79439547 --- /dev/null +++ b/assets/minecraft/models/item/piglin_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/piglin_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/pillager_spawn_egg.json b/assets/minecraft/models/item/pillager_spawn_egg.json new file mode 100644 index 00000000..54ab4a3f --- /dev/null +++ b/assets/minecraft/models/item/pillager_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/pillager_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/polar_bear_spawn_egg.json b/assets/minecraft/models/item/polar_bear_spawn_egg.json new file mode 100644 index 00000000..01d5fd1a --- /dev/null +++ b/assets/minecraft/models/item/polar_bear_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/polar_bear_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/pufferfish_spawn_egg.json b/assets/minecraft/models/item/pufferfish_spawn_egg.json new file mode 100644 index 00000000..f1e839df --- /dev/null +++ b/assets/minecraft/models/item/pufferfish_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/pufferfish_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/rabbit_spawn_egg.json b/assets/minecraft/models/item/rabbit_spawn_egg.json new file mode 100644 index 00000000..df2a0fec --- /dev/null +++ b/assets/minecraft/models/item/rabbit_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/rabbit_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/ravager_spawn_egg.json b/assets/minecraft/models/item/ravager_spawn_egg.json new file mode 100644 index 00000000..8f1f906d --- /dev/null +++ b/assets/minecraft/models/item/ravager_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/ravager_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/salmon_spawn_egg.json b/assets/minecraft/models/item/salmon_spawn_egg.json new file mode 100644 index 00000000..c5c93b26 --- /dev/null +++ b/assets/minecraft/models/item/salmon_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/salmon_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/sheep_spawn_egg.json b/assets/minecraft/models/item/sheep_spawn_egg.json new file mode 100644 index 00000000..89c13e31 --- /dev/null +++ b/assets/minecraft/models/item/sheep_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/sheep_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/short_dry_grass.json b/assets/minecraft/models/item/short_dry_grass.json new file mode 100644 index 00000000..9f128fa5 --- /dev/null +++ b/assets/minecraft/models/item/short_dry_grass.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:block/short_dry_grass" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/shulker_spawn_egg.json b/assets/minecraft/models/item/shulker_spawn_egg.json new file mode 100644 index 00000000..d7311177 --- /dev/null +++ b/assets/minecraft/models/item/shulker_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/shulker_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/silverfish_spawn_egg.json b/assets/minecraft/models/item/silverfish_spawn_egg.json new file mode 100644 index 00000000..1d4c065e --- /dev/null +++ b/assets/minecraft/models/item/silverfish_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/silverfish_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/skeleton_horse_spawn_egg.json b/assets/minecraft/models/item/skeleton_horse_spawn_egg.json new file mode 100644 index 00000000..64813700 --- /dev/null +++ b/assets/minecraft/models/item/skeleton_horse_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/skeleton_horse_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/skeleton_spawn_egg.json b/assets/minecraft/models/item/skeleton_spawn_egg.json new file mode 100644 index 00000000..7913cb6d --- /dev/null +++ b/assets/minecraft/models/item/skeleton_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/skeleton_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/slime_spawn_egg.json b/assets/minecraft/models/item/slime_spawn_egg.json new file mode 100644 index 00000000..3f86521f --- /dev/null +++ b/assets/minecraft/models/item/slime_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/slime_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/sniffer_spawn_egg.json b/assets/minecraft/models/item/sniffer_spawn_egg.json new file mode 100644 index 00000000..046de317 --- /dev/null +++ b/assets/minecraft/models/item/sniffer_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/sniffer_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/snow_golem_spawn_egg.json b/assets/minecraft/models/item/snow_golem_spawn_egg.json new file mode 100644 index 00000000..9c3f1221 --- /dev/null +++ b/assets/minecraft/models/item/snow_golem_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/snow_golem_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/spider_spawn_egg.json b/assets/minecraft/models/item/spider_spawn_egg.json new file mode 100644 index 00000000..0d254292 --- /dev/null +++ b/assets/minecraft/models/item/spider_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/spider_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/squid_spawn_egg.json b/assets/minecraft/models/item/squid_spawn_egg.json new file mode 100644 index 00000000..23102e77 --- /dev/null +++ b/assets/minecraft/models/item/squid_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/squid_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/stray_spawn_egg.json b/assets/minecraft/models/item/stray_spawn_egg.json new file mode 100644 index 00000000..87bbb174 --- /dev/null +++ b/assets/minecraft/models/item/stray_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/stray_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/strider_spawn_egg.json b/assets/minecraft/models/item/strider_spawn_egg.json new file mode 100644 index 00000000..424df94f --- /dev/null +++ b/assets/minecraft/models/item/strider_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/strider_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/tadpole_spawn_egg.json b/assets/minecraft/models/item/tadpole_spawn_egg.json new file mode 100644 index 00000000..2e6fb446 --- /dev/null +++ b/assets/minecraft/models/item/tadpole_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/tadpole_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/tall_dry_grass.json b/assets/minecraft/models/item/tall_dry_grass.json new file mode 100644 index 00000000..6b11a1fd --- /dev/null +++ b/assets/minecraft/models/item/tall_dry_grass.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:block/tall_dry_grass" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/template_spawn_egg.json b/assets/minecraft/models/item/template_spawn_egg.json deleted file mode 100644 index 4ae4b4c2..00000000 --- a/assets/minecraft/models/item/template_spawn_egg.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "parent": "item/generated", - "textures": { - "layer0": "item/spawn_egg", - "layer1": "item/spawn_egg_overlay" - } -} diff --git a/assets/minecraft/models/item/trader_llama_spawn_egg.json b/assets/minecraft/models/item/trader_llama_spawn_egg.json new file mode 100644 index 00000000..dd644cb8 --- /dev/null +++ b/assets/minecraft/models/item/trader_llama_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/trader_llama_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/tropical_fish_spawn_egg.json b/assets/minecraft/models/item/tropical_fish_spawn_egg.json new file mode 100644 index 00000000..f3503993 --- /dev/null +++ b/assets/minecraft/models/item/tropical_fish_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/tropical_fish_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/turtle_spawn_egg.json b/assets/minecraft/models/item/turtle_spawn_egg.json new file mode 100644 index 00000000..559691cf --- /dev/null +++ b/assets/minecraft/models/item/turtle_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/turtle_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/vex_spawn_egg.json b/assets/minecraft/models/item/vex_spawn_egg.json new file mode 100644 index 00000000..8ad861c6 --- /dev/null +++ b/assets/minecraft/models/item/vex_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/vex_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/villager_spawn_egg.json b/assets/minecraft/models/item/villager_spawn_egg.json new file mode 100644 index 00000000..3c69426a --- /dev/null +++ b/assets/minecraft/models/item/villager_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/villager_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/vindicator_spawn_egg.json b/assets/minecraft/models/item/vindicator_spawn_egg.json new file mode 100644 index 00000000..371c13f7 --- /dev/null +++ b/assets/minecraft/models/item/vindicator_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/vindicator_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/wandering_trader_spawn_egg.json b/assets/minecraft/models/item/wandering_trader_spawn_egg.json new file mode 100644 index 00000000..54a52c05 --- /dev/null +++ b/assets/minecraft/models/item/wandering_trader_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/wandering_trader_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/warden_spawn_egg.json b/assets/minecraft/models/item/warden_spawn_egg.json new file mode 100644 index 00000000..a26c8a56 --- /dev/null +++ b/assets/minecraft/models/item/warden_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/warden_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/wildflowers.json b/assets/minecraft/models/item/wildflowers.json new file mode 100644 index 00000000..b4e70956 --- /dev/null +++ b/assets/minecraft/models/item/wildflowers.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/wildflowers" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/witch_spawn_egg.json b/assets/minecraft/models/item/witch_spawn_egg.json new file mode 100644 index 00000000..37486399 --- /dev/null +++ b/assets/minecraft/models/item/witch_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/witch_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/wither_skeleton_spawn_egg.json b/assets/minecraft/models/item/wither_skeleton_spawn_egg.json new file mode 100644 index 00000000..b39d9de4 --- /dev/null +++ b/assets/minecraft/models/item/wither_skeleton_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/wither_skeleton_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/wither_spawn_egg.json b/assets/minecraft/models/item/wither_spawn_egg.json new file mode 100644 index 00000000..3c16da2d --- /dev/null +++ b/assets/minecraft/models/item/wither_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/wither_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/wolf_spawn_egg.json b/assets/minecraft/models/item/wolf_spawn_egg.json new file mode 100644 index 00000000..e2b5ddc0 --- /dev/null +++ b/assets/minecraft/models/item/wolf_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/wolf_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/zoglin_spawn_egg.json b/assets/minecraft/models/item/zoglin_spawn_egg.json new file mode 100644 index 00000000..f8740776 --- /dev/null +++ b/assets/minecraft/models/item/zoglin_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/zoglin_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/zombie_horse_spawn_egg.json b/assets/minecraft/models/item/zombie_horse_spawn_egg.json new file mode 100644 index 00000000..9d8a4e2f --- /dev/null +++ b/assets/minecraft/models/item/zombie_horse_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/zombie_horse_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/zombie_spawn_egg.json b/assets/minecraft/models/item/zombie_spawn_egg.json new file mode 100644 index 00000000..f0f63d8d --- /dev/null +++ b/assets/minecraft/models/item/zombie_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/zombie_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/zombie_villager_spawn_egg.json b/assets/minecraft/models/item/zombie_villager_spawn_egg.json new file mode 100644 index 00000000..651e67d8 --- /dev/null +++ b/assets/minecraft/models/item/zombie_villager_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/zombie_villager_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/models/item/zombified_piglin_spawn_egg.json b/assets/minecraft/models/item/zombified_piglin_spawn_egg.json new file mode 100644 index 00000000..fab7c383 --- /dev/null +++ b/assets/minecraft/models/item/zombified_piglin_spawn_egg.json @@ -0,0 +1,6 @@ +{ + "parent": "minecraft:item/generated", + "textures": { + "layer0": "minecraft:item/zombified_piglin_spawn_egg" + } +} \ No newline at end of file diff --git a/assets/minecraft/particles/firefly.json b/assets/minecraft/particles/firefly.json new file mode 100644 index 00000000..592e0f8f --- /dev/null +++ b/assets/minecraft/particles/firefly.json @@ -0,0 +1,5 @@ +{ + "textures": [ + "minecraft:firefly" + ] +} diff --git a/assets/minecraft/particles/tinted_leaves.json b/assets/minecraft/particles/tinted_leaves.json new file mode 100644 index 00000000..ac37a183 --- /dev/null +++ b/assets/minecraft/particles/tinted_leaves.json @@ -0,0 +1,16 @@ +{ + "textures": [ + "minecraft:leaf_0", + "minecraft:leaf_1", + "minecraft:leaf_2", + "minecraft:leaf_3", + "minecraft:leaf_4", + "minecraft:leaf_5", + "minecraft:leaf_6", + "minecraft:leaf_7", + "minecraft:leaf_8", + "minecraft:leaf_9", + "minecraft:leaf_10", + "minecraft:leaf_11" + ] +} diff --git a/assets/minecraft/post_effect/blur.json b/assets/minecraft/post_effect/blur.json index 90aed326..1823c5ec 100644 --- a/assets/minecraft/post_effect/blur.json +++ b/assets/minecraft/post_effect/blur.json @@ -4,7 +4,8 @@ }, "passes": [ { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -16,12 +17,18 @@ "uniforms": [ { "name": "BlurDir", + "type": "vec2", "values": [ 1.0, 0.0 ] + }, + { + "name": "Radius", + "type": "float" } ] }, { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -33,11 +40,17 @@ "uniforms": [ { "name": "BlurDir", + "type": "vec2", "values": [ 0.0, 1.0 ] + }, + { + "name": "Radius", + "type": "float" } ] }, { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -49,13 +62,18 @@ "uniforms": [ { "name": "BlurDir", - "values": [ 1.0, 0.0 ], - "RadiusMultiplier" : 0.5 + "type": "vec2", + "values": [ 1.0, 0.0 ] + }, + { + "name": "Radius", + "type": "float" } ] }, { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -67,12 +85,17 @@ "uniforms": [ { "name": "BlurDir", - "values": [ 0.0, 1.0 ], - "RadiusMultiplier" : 0.5 + "type": "vec2", + "values": [ 0.0, 1.0 ] + }, + { + "name": "Radius", + "type": "float" } ] }, { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -84,13 +107,18 @@ "uniforms": [ { "name": "BlurDir", - "values": [ 1.0, 0.0 ], - "RadiusMultiplier" : 0.25 + "type": "vec2", + "values": [ 1.0, 0.0 ] + }, + { + "name": "Radius", + "type": "float" } ] }, { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -102,8 +130,12 @@ "uniforms": [ { "name": "BlurDir", - "values": [ 0.0, 1.0 ], - "RadiusMultiplier" : 0.25 + "type": "vec2", + "values": [ 0.0, 1.0 ] + }, + { + "name": "Radius", + "type": "float" } ] } diff --git a/assets/minecraft/post_effect/creeper.json b/assets/minecraft/post_effect/creeper.json index 5e816341..ce02f7ef 100644 --- a/assets/minecraft/post_effect/creeper.json +++ b/assets/minecraft/post_effect/creeper.json @@ -4,7 +4,8 @@ }, "passes": [ { - "program": "minecraft:post/color_convolve", + "vertex_shader": "minecraft:post/sobel", + "fragment_shader": "minecraft:post/color_convolve", "inputs": [ { "sampler_name": "In", @@ -15,20 +16,24 @@ "uniforms": [ { "name": "RedMatrix", + "type": "vec3", "values": [ 0.0, 0.0, 0.0 ] }, { "name": "GreenMatrix", + "type": "vec3", "values": [ 0.3, 0.59, 0.11 ] }, { "name": "BlueMatrix", + "type": "vec3", "values": [ 0.0, 0.0, 0.0 ] } ] }, { - "program": "minecraft:post/bits", + "vertex_shader": "minecraft:post/sobel", + "fragment_shader": "minecraft:post/bits", "inputs": [ { "sampler_name": "In", @@ -39,10 +44,12 @@ "uniforms": [ { "name": "Resolution", + "type": "float", "values": [ 16.0 ] }, { "name": "MosaicSize", + "type": "float", "values": [ 4.0 ] } ] diff --git a/assets/minecraft/post_effect/entity_outline.json b/assets/minecraft/post_effect/entity_outline.json index cbecbdd2..c091ac8d 100644 --- a/assets/minecraft/post_effect/entity_outline.json +++ b/assets/minecraft/post_effect/entity_outline.json @@ -4,7 +4,8 @@ }, "passes": [ { - "program": "minecraft:post/entity_outline", + "vertex_shader": "minecraft:post/sobel", + "fragment_shader": "minecraft:post/entity_sobel", "inputs": [ { "sampler_name": "In", @@ -14,7 +15,8 @@ "output": "swap" }, { - "program": "minecraft:post/entity_outline_box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/entity_outline_box_blur", "inputs": [ { "sampler_name": "In", @@ -26,12 +28,14 @@ "uniforms": [ { "name": "BlurDir", + "type": "vec2", "values": [ 1.0, 0.0 ] } ] }, { - "program": "minecraft:post/entity_outline_box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/entity_outline_box_blur", "inputs": [ { "sampler_name": "In", @@ -43,18 +47,27 @@ "uniforms": [ { "name": "BlurDir", + "type": "vec2", "values": [ 0.0, 1.0 ] } ] }, { - "program": "minecraft:post/blit", + "vertex_shader": "minecraft:post/blit", + "fragment_shader": "minecraft:post/blit", "inputs": [ { "sampler_name": "In", "target": "swap" } ], + "uniforms": [ + { + "name": "ColorModulate", + "type": "vec4", + "values": [ 1.0, 1.0, 1.0, 1.0 ] + } + ], "output": "minecraft:entity_outline" } ] diff --git a/assets/minecraft/post_effect/invert.json b/assets/minecraft/post_effect/invert.json index 7ef7355e..a4fa8d23 100644 --- a/assets/minecraft/post_effect/invert.json +++ b/assets/minecraft/post_effect/invert.json @@ -4,7 +4,8 @@ }, "passes": [ { - "program": "minecraft:post/invert", + "vertex_shader": "minecraft:post/blit", + "fragment_shader": "minecraft:post/invert", "inputs": [ { "sampler_name": "In", @@ -15,18 +16,27 @@ "uniforms": [ { "name": "InverseAmount", + "type": "float", "values": [ 0.8 ] } ] }, { - "program": "minecraft:post/blit", + "vertex_shader": "minecraft:post/blit", + "fragment_shader": "minecraft:post/blit", "inputs": [ { "sampler_name": "In", "target": "swap" } ], + "uniforms": [ + { + "name": "ColorModulate", + "type": "vec4", + "values": [ 1.0, 1.0, 1.0, 1.0 ] + } + ], "output": "minecraft:main" } ] diff --git a/assets/minecraft/post_effect/spider.json b/assets/minecraft/post_effect/spider.json index 3eb6ee6b..bbe6eef0 100644 --- a/assets/minecraft/post_effect/spider.json +++ b/assets/minecraft/post_effect/spider.json @@ -7,7 +7,8 @@ }, "passes": [ { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -19,16 +20,19 @@ "uniforms": [ { "name": "BlurDir", + "type": "vec2", "values": [ 1.0, 0.0 ] }, { "name": "Radius", + "type": "float", "values": [ 15.0 ] } ] }, { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -40,16 +44,19 @@ "uniforms": [ { "name": "BlurDir", + "type": "vec2", "values": [ 0.0, 1.0 ] }, { "name": "Radius", + "type": "float", "values": [ 15.0 ] } ] }, { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -61,16 +68,19 @@ "uniforms": [ { "name": "BlurDir", + "type": "vec2", "values": [ 1.0, 0.0 ] }, { "name": "Radius", + "type": "float", "values": [ 7.0 ] } ] }, { - "program": "minecraft:post/box_blur", + "vertex_shader": "minecraft:post/blur", + "fragment_shader": "minecraft:post/box_blur", "inputs": [ { "sampler_name": "In", @@ -82,16 +92,19 @@ "uniforms": [ { "name": "BlurDir", + "type": "vec2", "values": [ 0.0, 1.0 ] }, { "name": "Radius", + "type": "float", "values": [ 7.0 ] } ] }, { - "program": "minecraft:post/spider", + "vertex_shader": "minecraft:post/rotscale", + "fragment_shader": "minecraft:post/spiderclip", "inputs": [ { "sampler_name": "In", @@ -106,24 +119,34 @@ "uniforms": [ { "name": "InScale", + "type": "vec2", "values": [ 1.25, 2.0 ] }, { "name": "InOffset", + "type": "vec2", "values": [ -0.125, -0.1 ] }, + { + "name": "InRotation", + "type": "float", + "values": [ 0 ] + }, { "name": "Scissor", + "type": "vec4", "values": [ 0.0, 0.0, 1.0, 1.0 ] }, { "name": "Vignette", + "type": "vec4", "values": [ 0.1, 0.1, 0.9, 0.9 ] } ] }, { - "program": "minecraft:post/spider", + "vertex_shader": "minecraft:post/rotscale", + "fragment_shader": "minecraft:post/spiderclip", "inputs": [ { "sampler_name": "In", @@ -138,28 +161,34 @@ "uniforms": [ { "name": "InScale", + "type": "vec2", "values": [ 2.35, 4.2 ] }, { "name": "InOffset", + "type": "vec2", "values": [ -1.1, -1.5 ] }, { "name": "InRotation", + "type": "float", "values": [ -45.0 ] }, { "name": "Scissor", + "type": "vec4", "values": [ 0.21, 0.0, 0.79, 1.0 ] }, { "name": "Vignette", + "type": "vec4", "values": [ 0.31, 0.1, 0.69, 0.9 ] } ] }, { - "program": "minecraft:post/spider", + "vertex_shader": "minecraft:post/rotscale", + "fragment_shader": "minecraft:post/spiderclip", "inputs": [ { "sampler_name": "In", @@ -174,28 +203,34 @@ "uniforms": [ { "name": "InScale", + "type": "vec2", "values": [ 2.35, 4.2 ] }, { "name": "InOffset", + "type": "vec2", "values": [ 0.45, -4.45 ] }, { "name": "InRotation", + "type": "float", "values": [ 45.0 ] }, { "name": "Scissor", + "type": "vec4", "values": [ 0.21, 0.0, 0.79, 1.0 ] }, { "name": "Vignette", + "type": "vec4", "values": [ 0.31, 0.1, 0.69, 0.9 ] } ] }, { - "program": "minecraft:post/spider", + "vertex_shader": "minecraft:post/rotscale", + "fragment_shader": "minecraft:post/spiderclip", "inputs": [ { "sampler_name": "In", @@ -210,24 +245,34 @@ "uniforms": [ { "name": "InScale", + "type": "vec2", "values": [ 2.35, 2.35 ] }, { "name": "InOffset", + "type": "vec2", "values": [ -0.385, -1.29 ] }, { "name": "InRotation", + "type": "float", "values": [ 0.0 ] }, + { + "name": "Scissor", + "type": "vec4", + "values": [ 0.0, 0.0, 1.0, 1.0 ] + }, { "name": "Vignette", + "type": "vec4", "values": [ 0.31, 0.1, 0.69, 0.9 ] } ] }, { - "program": "minecraft:post/spider", + "vertex_shader": "minecraft:post/rotscale", + "fragment_shader": "minecraft:post/spiderclip", "inputs": [ { "sampler_name": "In", @@ -242,20 +287,34 @@ "uniforms": [ { "name": "InScale", + "type": "vec2", "values": [ 2.35, 2.35 ] }, { "name": "InOffset", + "type": "vec2", "values": [ -0.965, -1.29 ] }, + { + "name": "InRotation", + "type": "float", + "values": [ 0 ] + }, + { + "name": "Scissor", + "type": "vec4", + "values": [ 0.0, 0.0, 1.0, 1.0 ] + }, { "name": "Vignette", + "type": "vec4", "values": [ 0.31, 0.1, 0.69, 0.9 ] } ] }, { - "program": "minecraft:post/blit", + "vertex_shader": "minecraft:post/blit", + "fragment_shader": "minecraft:post/blit", "inputs": [ { "sampler_name": "In", @@ -266,6 +325,7 @@ "uniforms": [ { "name": "ColorModulate", + "type": "vec4", "values": [ 1.0, 0.8, 0.8, 1.0 ] } ] diff --git a/assets/minecraft/post_effect/transparency.json b/assets/minecraft/post_effect/transparency.json index f0e1ea0c..ab38829a 100644 --- a/assets/minecraft/post_effect/transparency.json +++ b/assets/minecraft/post_effect/transparency.json @@ -4,7 +4,8 @@ }, "passes": [ { - "program": "minecraft:post/transparency", + "vertex_shader": "minecraft:post/screenquad", + "fragment_shader": "minecraft:post/transparency", "inputs": [ { "sampler_name": "Main", @@ -64,13 +65,21 @@ "output": "final" }, { - "program": "minecraft:post/blit", + "vertex_shader": "minecraft:post/blit", + "fragment_shader": "minecraft:post/blit", "inputs": [ { "sampler_name": "In", "target": "final" } ], + "uniforms": [ + { + "name": "ColorModulate", + "type": "vec4", + "values": [ 1.0, 1.0, 1.0, 1.0 ] + } + ], "output": "minecraft:main" } ] diff --git a/assets/minecraft/shaders/core/blit_screen.json b/assets/minecraft/shaders/core/blit_screen.json deleted file mode 100644 index 61d51e1f..00000000 --- a/assets/minecraft/shaders/core/blit_screen.json +++ /dev/null @@ -1,9 +0,0 @@ -{ - "vertex": "minecraft:core/blit_screen", - "fragment": "minecraft:core/blit_screen", - "samplers": [ - { "name": "InSampler" } - ], - "uniforms": [ - ] -} diff --git a/assets/minecraft/shaders/core/lightmap.json b/assets/minecraft/shaders/core/lightmap.json deleted file mode 100644 index 3b90e934..00000000 --- a/assets/minecraft/shaders/core/lightmap.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "vertex": "minecraft:core/blit_screen", - "fragment": "minecraft:core/lightmap", - "samplers": [ - ], - "uniforms": [ - { "name": "AmbientLightFactor", "type": "float", "count": 1, "values": [1.0] }, - { "name": "SkyFactor", "type": "float", "count": 1, "values": [1.0] }, - { "name": "BlockFactor", "type": "float", "count": 1, "values": [1.0] }, - { "name": "UseBrightLightmap", "type": "int", "count": 1, "values": [0] }, - { "name": "SkyLightColor", "type": "float", "count": 3, "values": [1.0] }, - { "name": "NightVisionFactor", "type": "float", "count": 1, "values": [0.0] }, - { "name": "DarknessScale", "type": "float", "count": 1, "values": [0.0] }, - { "name": "DarkenWorldFactor", "type": "float", "count": 1, "values": [0.0] }, - { "name": "BrightnessFactor", "type": "float", "count": 1, "values": [1.0] } - ] -} diff --git a/assets/minecraft/shaders/core/particle.json b/assets/minecraft/shaders/core/particle.json deleted file mode 100644 index 2f334b45..00000000 --- a/assets/minecraft/shaders/core/particle.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "vertex": "minecraft:core/particle", - "fragment": "minecraft:core/particle", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/position.json b/assets/minecraft/shaders/core/position.json deleted file mode 100644 index 29b6475f..00000000 --- a/assets/minecraft/shaders/core/position.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "vertex": "minecraft:core/position", - "fragment": "minecraft:core/position", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/position_color.json b/assets/minecraft/shaders/core/position_color.json deleted file mode 100644 index 6d715d92..00000000 --- a/assets/minecraft/shaders/core/position_color.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "vertex": "minecraft:core/position_color", - "fragment": "minecraft:core/position_color", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/position_color_lightmap.json b/assets/minecraft/shaders/core/position_color_lightmap.json deleted file mode 100644 index d84b26f6..00000000 --- a/assets/minecraft/shaders/core/position_color_lightmap.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:core/position_color_lightmap", - "fragment": "minecraft:core/position_color_lightmap", - "samplers": [ - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/position_color_tex_lightmap.json b/assets/minecraft/shaders/core/position_color_tex_lightmap.json deleted file mode 100644 index f7eb56e0..00000000 --- a/assets/minecraft/shaders/core/position_color_tex_lightmap.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:core/position_color_tex_lightmap", - "fragment": "minecraft:core/position_color_tex_lightmap", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/position_tex.json b/assets/minecraft/shaders/core/position_tex.json deleted file mode 100644 index 9f402324..00000000 --- a/assets/minecraft/shaders/core/position_tex.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:core/position_tex", - "fragment": "minecraft:core/position_tex", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/position_tex_color.json b/assets/minecraft/shaders/core/position_tex_color.json deleted file mode 100644 index f9454656..00000000 --- a/assets/minecraft/shaders/core/position_tex_color.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:core/position_tex_color", - "fragment": "minecraft:core/position_tex_color", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_armor_cutout_no_cull.json b/assets/minecraft/shaders/core/rendertype_armor_cutout_no_cull.json deleted file mode 100644 index 85173fe8..00000000 --- a/assets/minecraft/shaders/core/rendertype_armor_cutout_no_cull.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - }, - "flags": [ - "NO_OVERLAY" - ] - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_armor_entity_glint.json b/assets/minecraft/shaders/core/rendertype_armor_entity_glint.json deleted file mode 100644 index c321e633..00000000 --- a/assets/minecraft/shaders/core/rendertype_armor_entity_glint.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "vertex": "minecraft:core/glint", - "fragment": "minecraft:core/glint", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "GlintAlpha", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] }, - { "name": "TextureMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_armor_translucent.json b/assets/minecraft/shaders/core/rendertype_armor_translucent.json deleted file mode 100644 index 85173fe8..00000000 --- a/assets/minecraft/shaders/core/rendertype_armor_translucent.json +++ /dev/null @@ -1,27 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - }, - "flags": [ - "NO_OVERLAY" - ] - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_beacon_beam.json b/assets/minecraft/shaders/core/rendertype_beacon_beam.json deleted file mode 100644 index f34c777d..00000000 --- a/assets/minecraft/shaders/core/rendertype_beacon_beam.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_beacon_beam", - "fragment": "minecraft:core/rendertype_beacon_beam", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_breeze_wind.json b/assets/minecraft/shaders/core/rendertype_breeze_wind.json deleted file mode 100644 index c5aa6a4d..00000000 --- a/assets/minecraft/shaders/core/rendertype_breeze_wind.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - }, - "flags": [ - "APPLY_TEXTURE_MATRIX", - "NO_CARDINAL_LIGHTING", - "NO_OVERLAY" - ] - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "TextureMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_clouds.json b/assets/minecraft/shaders/core/rendertype_clouds.json deleted file mode 100644 index dc7d8c1e..00000000 --- a/assets/minecraft/shaders/core/rendertype_clouds.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_clouds", - "fragment": "minecraft:core/rendertype_clouds", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ModelOffset", "type": "float", "count": 3, "values": [ 0.0, 0.0, 0.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_crumbling.json b/assets/minecraft/shaders/core/rendertype_crumbling.json deleted file mode 100644 index 9dd3add9..00000000 --- a/assets/minecraft/shaders/core/rendertype_crumbling.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_crumbling", - "fragment": "minecraft:core/rendertype_crumbling", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_cutout.json b/assets/minecraft/shaders/core/rendertype_cutout.json deleted file mode 100644 index ea3a5b05..00000000 --- a/assets/minecraft/shaders/core/rendertype_cutout.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "vertex": "minecraft:core/terrain", - "fragment": "minecraft:core/terrain", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - } - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ModelOffset", "type": "float", "count": 3, "values": [ 0.0, 0.0, 0.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_cutout_mipped.json b/assets/minecraft/shaders/core/rendertype_cutout_mipped.json deleted file mode 100644 index 31880fd5..00000000 --- a/assets/minecraft/shaders/core/rendertype_cutout_mipped.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "vertex": "minecraft:core/terrain", - "fragment": "minecraft:core/terrain", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.5" - } - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ModelOffset", "type": "float", "count": 3, "values": [ 0.0, 0.0, 0.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_end_gateway.json b/assets/minecraft/shaders/core/rendertype_end_gateway.json deleted file mode 100644 index 1ba8c97c..00000000 --- a/assets/minecraft/shaders/core/rendertype_end_gateway.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_end_portal", - "fragment": "minecraft:core/rendertype_end_portal", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "GameTime", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "EndPortalLayers", "type": "int", "count": 1, "values": [ 16 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_end_portal.fsh b/assets/minecraft/shaders/core/rendertype_end_portal.fsh index 46011dd2..539d33d4 100644 --- a/assets/minecraft/shaders/core/rendertype_end_portal.fsh +++ b/assets/minecraft/shaders/core/rendertype_end_portal.fsh @@ -1,14 +1,18 @@ #version 150 +#moj_import #moj_import uniform sampler2D Sampler0; uniform sampler2D Sampler1; uniform float GameTime; -uniform int EndPortalLayers; +uniform float FogStart; +uniform float FogEnd; +uniform vec4 FogColor; in vec4 texProj0; +in float vertexDistance; const vec3[] COLORS = vec3[]( vec3(0.022087, 0.098399, 0.110818), @@ -55,8 +59,8 @@ out vec4 fragColor; void main() { vec3 color = textureProj(Sampler0, texProj0).rgb * COLORS[0]; - for (int i = 0; i < EndPortalLayers; i++) { + for (int i = 0; i < PORTAL_LAYERS; i++) { color += textureProj(Sampler1, texProj0 * end_portal_layer(float(i + 1))).rgb * COLORS[i]; } - fragColor = vec4(color, 1.0); + fragColor = linear_fog(vec4(color, 1.0), vertexDistance, FogStart, FogEnd, FogColor); } diff --git a/assets/minecraft/shaders/core/rendertype_end_portal.json b/assets/minecraft/shaders/core/rendertype_end_portal.json deleted file mode 100644 index 5f93d105..00000000 --- a/assets/minecraft/shaders/core/rendertype_end_portal.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_end_portal", - "fragment": "minecraft:core/rendertype_end_portal", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "GameTime", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "EndPortalLayers", "type": "int", "count": 1, "values": [ 15 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_end_portal.vsh b/assets/minecraft/shaders/core/rendertype_end_portal.vsh index a31786cb..37b5d5c1 100644 --- a/assets/minecraft/shaders/core/rendertype_end_portal.vsh +++ b/assets/minecraft/shaders/core/rendertype_end_portal.vsh @@ -1,16 +1,20 @@ #version 150 +#moj_import #moj_import in vec3 Position; uniform mat4 ModelViewMat; uniform mat4 ProjMat; +uniform int FogShape; out vec4 texProj0; +out float vertexDistance; void main() { gl_Position = ProjMat * ModelViewMat * vec4(Position, 1.0); texProj0 = projection_from_position(gl_Position); + vertexDistance = fog_distance(Position, FogShape); } diff --git a/assets/minecraft/shaders/core/rendertype_energy_swirl.json b/assets/minecraft/shaders/core/rendertype_energy_swirl.json deleted file mode 100644 index f8ad7958..00000000 --- a/assets/minecraft/shaders/core/rendertype_energy_swirl.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - }, - "flags": [ - "APPLY_TEXTURE_MATRIX", - "NO_CARDINAL_LIGHTING", - "NO_OVERLAY", - "EMISSIVE" - ] - }, - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "TextureMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_alpha.json b/assets/minecraft/shaders/core/rendertype_entity_alpha.json deleted file mode 100644 index b1d9f34f..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_alpha.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_entity_alpha", - "fragment": "minecraft:core/rendertype_entity_alpha", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_cutout.json b/assets/minecraft/shaders/core/rendertype_entity_cutout.json deleted file mode 100644 index f1f459b6..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_cutout.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - } - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_cutout_no_cull.json b/assets/minecraft/shaders/core/rendertype_entity_cutout_no_cull.json deleted file mode 100644 index f1f459b6..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_cutout_no_cull.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - } - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_cutout_no_cull_z_offset.json b/assets/minecraft/shaders/core/rendertype_entity_cutout_no_cull_z_offset.json deleted file mode 100644 index f1f459b6..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_cutout_no_cull_z_offset.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - } - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_decal.json b/assets/minecraft/shaders/core/rendertype_entity_decal.json deleted file mode 100644 index eeac88a0..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_decal.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_entity_decal", - "fragment": "minecraft:core/rendertype_entity_decal", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_glint.json b/assets/minecraft/shaders/core/rendertype_entity_glint.json deleted file mode 100644 index c560c554..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_glint.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "vertex": "minecraft:core/glint", - "fragment": "minecraft:core/glint", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "GlintAlpha", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] }, - { "name": "TextureMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_no_outline.json b/assets/minecraft/shaders/core/rendertype_entity_no_outline.json deleted file mode 100644 index 0598bc5b..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_no_outline.json +++ /dev/null @@ -1,24 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "flags": [ - "NO_OVERLAY" - ] - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_shadow.json b/assets/minecraft/shaders/core/rendertype_entity_shadow.json deleted file mode 100644 index b9960d06..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_shadow.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_entity_shadow", - "fragment": "minecraft:core/rendertype_entity_shadow", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_smooth_cutout.json b/assets/minecraft/shaders/core/rendertype_entity_smooth_cutout.json deleted file mode 100644 index f1f459b6..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_smooth_cutout.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - } - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_solid.json b/assets/minecraft/shaders/core/rendertype_entity_solid.json deleted file mode 100644 index 45bbeb78..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_solid.json +++ /dev/null @@ -1,20 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_translucent.json b/assets/minecraft/shaders/core/rendertype_entity_translucent.json deleted file mode 100644 index f1f459b6..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_translucent.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - } - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_entity_translucent_emissive.json b/assets/minecraft/shaders/core/rendertype_entity_translucent_emissive.json deleted file mode 100644 index 4e6bf9f0..00000000 --- a/assets/minecraft/shaders/core/rendertype_entity_translucent_emissive.json +++ /dev/null @@ -1,28 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - }, - "flags": [ - "EMISSIVE" - ] - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler1" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_eyes.json b/assets/minecraft/shaders/core/rendertype_eyes.json deleted file mode 100644 index 3af08632..00000000 --- a/assets/minecraft/shaders/core/rendertype_eyes.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "vertex": "minecraft:core/entity", - "fragment": "minecraft:core/entity", - "defines": { - "flags": [ - "EMISSIVE", - "NO_OVERLAY", - "NO_CARDINAL_LIGHTING" - ] - }, - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_glint.json b/assets/minecraft/shaders/core/rendertype_glint.json deleted file mode 100644 index c560c554..00000000 --- a/assets/minecraft/shaders/core/rendertype_glint.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "vertex": "minecraft:core/glint", - "fragment": "minecraft:core/glint", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "GlintAlpha", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] }, - { "name": "TextureMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_glint_translucent.json b/assets/minecraft/shaders/core/rendertype_glint_translucent.json deleted file mode 100644 index c560c554..00000000 --- a/assets/minecraft/shaders/core/rendertype_glint_translucent.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "vertex": "minecraft:core/glint", - "fragment": "minecraft:core/glint", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "GlintAlpha", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] }, - { "name": "TextureMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_gui.json b/assets/minecraft/shaders/core/rendertype_gui.json deleted file mode 100644 index 29060a48..00000000 --- a/assets/minecraft/shaders/core/rendertype_gui.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "vertex": "minecraft:core/gui", - "fragment": "minecraft:core/gui", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_gui_ghost_recipe_overlay.json b/assets/minecraft/shaders/core/rendertype_gui_ghost_recipe_overlay.json deleted file mode 100644 index 29060a48..00000000 --- a/assets/minecraft/shaders/core/rendertype_gui_ghost_recipe_overlay.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "vertex": "minecraft:core/gui", - "fragment": "minecraft:core/gui", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_gui_overlay.json b/assets/minecraft/shaders/core/rendertype_gui_overlay.json deleted file mode 100644 index 29060a48..00000000 --- a/assets/minecraft/shaders/core/rendertype_gui_overlay.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "vertex": "minecraft:core/gui", - "fragment": "minecraft:core/gui", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_gui_text_highlight.json b/assets/minecraft/shaders/core/rendertype_gui_text_highlight.json deleted file mode 100644 index 29060a48..00000000 --- a/assets/minecraft/shaders/core/rendertype_gui_text_highlight.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "vertex": "minecraft:core/gui", - "fragment": "minecraft:core/gui", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_item_entity_translucent_cull.json b/assets/minecraft/shaders/core/rendertype_item_entity_translucent_cull.json deleted file mode 100644 index dc813b36..00000000 --- a/assets/minecraft/shaders/core/rendertype_item_entity_translucent_cull.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_item_entity_translucent_cull", - "fragment": "minecraft:core/rendertype_item_entity_translucent_cull", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "Light0_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "Light1_Direction", "type": "float", "count": 3, "values": [0.0, 0.0, 0.0] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_leash.json b/assets/minecraft/shaders/core/rendertype_leash.json deleted file mode 100644 index 0aa90d26..00000000 --- a/assets/minecraft/shaders/core/rendertype_leash.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_leash", - "fragment": "minecraft:core/rendertype_leash", - "samplers": [ - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_lightning.json b/assets/minecraft/shaders/core/rendertype_lightning.json deleted file mode 100644 index 78bf9b5e..00000000 --- a/assets/minecraft/shaders/core/rendertype_lightning.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_lightning", - "fragment": "minecraft:core/rendertype_lightning", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_lines.json b/assets/minecraft/shaders/core/rendertype_lines.json deleted file mode 100644 index 32ce8870..00000000 --- a/assets/minecraft/shaders/core/rendertype_lines.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_lines", - "fragment": "minecraft:core/rendertype_lines", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "LineWidth", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "ScreenSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_outline.json b/assets/minecraft/shaders/core/rendertype_outline.json deleted file mode 100644 index 6e4fb121..00000000 --- a/assets/minecraft/shaders/core/rendertype_outline.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_outline", - "fragment": "minecraft:core/rendertype_outline", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_solid.json b/assets/minecraft/shaders/core/rendertype_solid.json deleted file mode 100644 index ce415faa..00000000 --- a/assets/minecraft/shaders/core/rendertype_solid.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "vertex": "minecraft:core/terrain", - "fragment": "minecraft:core/terrain", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ModelOffset", "type": "float", "count": 3, "values": [ 0.0, 0.0, 0.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_text.json b/assets/minecraft/shaders/core/rendertype_text.json deleted file mode 100644 index 8fff4c6f..00000000 --- a/assets/minecraft/shaders/core/rendertype_text.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_text", - "fragment": "minecraft:core/rendertype_text", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_text_background.json b/assets/minecraft/shaders/core/rendertype_text_background.json deleted file mode 100644 index 2709bf99..00000000 --- a/assets/minecraft/shaders/core/rendertype_text_background.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_text_background", - "fragment": "minecraft:core/rendertype_text_background", - "samplers": [ - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_text_background_see_through.json b/assets/minecraft/shaders/core/rendertype_text_background_see_through.json deleted file mode 100644 index 8407a3b3..00000000 --- a/assets/minecraft/shaders/core/rendertype_text_background_see_through.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_text_background_see_through", - "fragment": "minecraft:core/rendertype_text_background_see_through", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_text_intensity.json b/assets/minecraft/shaders/core/rendertype_text_intensity.json deleted file mode 100644 index 04262bf7..00000000 --- a/assets/minecraft/shaders/core/rendertype_text_intensity.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_text_intensity", - "fragment": "minecraft:core/rendertype_text_intensity", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_text_intensity_see_through.json b/assets/minecraft/shaders/core/rendertype_text_intensity_see_through.json deleted file mode 100644 index a1479e1e..00000000 --- a/assets/minecraft/shaders/core/rendertype_text_intensity_see_through.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_text_intensity_see_through", - "fragment": "minecraft:core/rendertype_text_intensity_see_through", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_text_see_through.json b/assets/minecraft/shaders/core/rendertype_text_see_through.json deleted file mode 100644 index c54dc685..00000000 --- a/assets/minecraft/shaders/core/rendertype_text_see_through.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_text_see_through", - "fragment": "minecraft:core/rendertype_text_see_through", - "samplers": [ - { "name": "Sampler0" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_translucent.json b/assets/minecraft/shaders/core/rendertype_translucent.json deleted file mode 100644 index ce415faa..00000000 --- a/assets/minecraft/shaders/core/rendertype_translucent.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "vertex": "minecraft:core/terrain", - "fragment": "minecraft:core/terrain", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ModelOffset", "type": "float", "count": 3, "values": [ 0.0, 0.0, 0.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_translucent_moving_block.json b/assets/minecraft/shaders/core/rendertype_translucent_moving_block.json deleted file mode 100644 index 2e2c8401..00000000 --- a/assets/minecraft/shaders/core/rendertype_translucent_moving_block.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_translucent_moving_block", - "fragment": "minecraft:core/rendertype_translucent_moving_block", - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_tripwire.json b/assets/minecraft/shaders/core/rendertype_tripwire.json deleted file mode 100644 index ea3a5b05..00000000 --- a/assets/minecraft/shaders/core/rendertype_tripwire.json +++ /dev/null @@ -1,23 +0,0 @@ -{ - "vertex": "minecraft:core/terrain", - "fragment": "minecraft:core/terrain", - "defines": { - "values": { - "ALPHA_CUTOUT": "0.1" - } - }, - "samplers": [ - { "name": "Sampler0" }, - { "name": "Sampler2" } - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ModelOffset", "type": "float", "count": 3, "values": [ 0.0, 0.0, 0.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] }, - { "name": "FogStart", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "FogEnd", "type": "float", "count": 1, "values": [ 1.0 ] }, - { "name": "FogColor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 0.0, 0.0 ] }, - { "name": "FogShape", "type": "int", "count": 1, "values": [ 0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_water_mask.json b/assets/minecraft/shaders/core/rendertype_water_mask.json deleted file mode 100644 index 9cb3f074..00000000 --- a/assets/minecraft/shaders/core/rendertype_water_mask.json +++ /dev/null @@ -1,11 +0,0 @@ -{ - "vertex": "minecraft:core/rendertype_water_mask", - "fragment": "minecraft:core/rendertype_water_mask", - "samplers": [ - ], - "uniforms": [ - { "name": "ModelViewMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "ColorModulator", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/core/rendertype_world_border.fsh b/assets/minecraft/shaders/core/rendertype_world_border.fsh new file mode 100644 index 00000000..ded49d39 --- /dev/null +++ b/assets/minecraft/shaders/core/rendertype_world_border.fsh @@ -0,0 +1,17 @@ +#version 150 + +uniform sampler2D Sampler0; + +uniform vec4 ColorModulator; + +in vec2 texCoord0; + +out vec4 fragColor; + +void main() { + vec4 color = texture(Sampler0, texCoord0); + if (color.a == 0.0) { + discard; + } + fragColor = color * ColorModulator; +} diff --git a/assets/minecraft/shaders/core/rendertype_world_border.vsh b/assets/minecraft/shaders/core/rendertype_world_border.vsh new file mode 100644 index 00000000..61d7f05c --- /dev/null +++ b/assets/minecraft/shaders/core/rendertype_world_border.vsh @@ -0,0 +1,18 @@ +#version 150 + +in vec3 Position; +in vec2 UV0; + +uniform mat4 TextureMat; +uniform mat4 ModelViewMat; +uniform mat4 ProjMat; +uniform vec3 ModelOffset; + +out vec2 texCoord0; + +void main() { + vec3 pos = Position + ModelOffset; + gl_Position = ProjMat * ModelViewMat * vec4(pos, 1.0); + + texCoord0 = (TextureMat * vec4(UV0, 0.0, 1.0)).xy; +} diff --git a/assets/minecraft/shaders/post/bits.fsh b/assets/minecraft/shaders/post/bits.fsh index 754f8bfc..65338e84 100644 --- a/assets/minecraft/shaders/post/bits.fsh +++ b/assets/minecraft/shaders/post/bits.fsh @@ -8,11 +8,12 @@ in vec2 oneTexel; uniform vec2 InSize; uniform float Resolution; -uniform float Saturation; uniform float MosaicSize; out vec4 fragColor; +const float Saturation = 1.5; + void main() { vec2 mosaicInSize = InSize / MosaicSize; vec2 fractPix = fract(texCoord * mosaicInSize) / mosaicInSize; diff --git a/assets/minecraft/shaders/post/bits.json b/assets/minecraft/shaders/post/bits.json deleted file mode 100644 index 54f9e0b5..00000000 --- a/assets/minecraft/shaders/post/bits.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "vertex": "minecraft:post/sobel", - "fragment": "minecraft:post/bits", - "samplers": [ - { "name": "InSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "InSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "Resolution", "type": "float", "count": 1, "values": [ 4.0 ] }, - { "name": "Saturation", "type": "float", "count": 1, "values": [ 1.5 ] }, - { "name": "MosaicSize", "type": "float", "count": 1, "values": [ 8.0 ] } - ] -} diff --git a/assets/minecraft/shaders/post/blit.json b/assets/minecraft/shaders/post/blit.json deleted file mode 100644 index 9ea94a61..00000000 --- a/assets/minecraft/shaders/post/blit.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:post/blit", - "fragment": "minecraft:post/blit", - "samplers": [ - { "name": "InSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "ColorModulate", "type": "float", "count": 4, "values": [ 1.0, 1.0, 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/post/blit.vsh b/assets/minecraft/shaders/post/blit.vsh index 443e1f34..b7f943f5 100644 --- a/assets/minecraft/shaders/post/blit.vsh +++ b/assets/minecraft/shaders/post/blit.vsh @@ -8,8 +8,8 @@ uniform vec2 OutSize; out vec2 texCoord; void main(){ - vec4 outPos = ProjMat * vec4(Position.xy, 0.0, 1.0); + vec4 outPos = ProjMat * vec4(Position.xy * OutSize, 0.0, 1.0); gl_Position = vec4(outPos.xy, 0.2, 1.0); - texCoord = Position.xy / OutSize; + texCoord = Position.xy; } diff --git a/assets/minecraft/shaders/post/blur.vsh b/assets/minecraft/shaders/post/blur.vsh index 5917d86b..31aadb4a 100644 --- a/assets/minecraft/shaders/post/blur.vsh +++ b/assets/minecraft/shaders/post/blur.vsh @@ -11,11 +11,11 @@ out vec2 texCoord; out vec2 sampleStep; void main() { - vec4 outPos = ProjMat * vec4(Position.xy, 0.0, 1.0); + vec4 outPos = ProjMat * vec4(Position.xy * OutSize, 0.0, 1.0); gl_Position = vec4(outPos.xy, 0.2, 1.0); vec2 oneTexel = 1.0 / InSize; sampleStep = oneTexel * BlurDir; - texCoord = Position.xy / OutSize; + texCoord = Position.xy; } diff --git a/assets/minecraft/shaders/post/box_blur.fsh b/assets/minecraft/shaders/post/box_blur.fsh index 381e1e84..32780bbc 100644 --- a/assets/minecraft/shaders/post/box_blur.fsh +++ b/assets/minecraft/shaders/post/box_blur.fsh @@ -6,7 +6,6 @@ in vec2 texCoord; in vec2 sampleStep; uniform float Radius; -uniform float RadiusMultiplier; out vec4 fragColor; @@ -15,7 +14,7 @@ out vec4 fragColor; // In the end we sample the last pixel with a half weight, since the amount of pixels to sample is always odd (actualRadius * 2 + 1). void main() { vec4 blurred = vec4(0.0); - float actualRadius = round(Radius * RadiusMultiplier); + float actualRadius = round(Radius); for (float a = -actualRadius + 0.5; a <= actualRadius; a += 2.0) { blurred += texture(InSampler, texCoord + sampleStep * a); } diff --git a/assets/minecraft/shaders/post/box_blur.json b/assets/minecraft/shaders/post/box_blur.json deleted file mode 100644 index c2d389f2..00000000 --- a/assets/minecraft/shaders/post/box_blur.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "vertex": "minecraft:post/blur", - "fragment": "minecraft:post/box_blur", - "samplers": [ - { "name": "InSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "InSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "BlurDir", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "Radius", "type": "float", "count": 1, "values": [ 5.0 ] }, - { "name": "RadiusMultiplier", "type": "float", "count": 1, "values": [ 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/post/color_convolve.fsh b/assets/minecraft/shaders/post/color_convolve.fsh index 329e1e55..c8de40ac 100644 --- a/assets/minecraft/shaders/post/color_convolve.fsh +++ b/assets/minecraft/shaders/post/color_convolve.fsh @@ -4,16 +4,14 @@ uniform sampler2D InSampler; in vec2 texCoord; in vec2 oneTexel; - uniform vec2 InSize; -uniform vec3 Gray; uniform vec3 RedMatrix; uniform vec3 GreenMatrix; uniform vec3 BlueMatrix; -uniform vec3 Offset; -uniform vec3 ColorScale; -uniform float Saturation; + +const vec3 Gray = vec3(0.3, 0.59, 0.11); +const float Saturation = 1.8; out vec4 fragColor; @@ -26,9 +24,6 @@ void main() { float BlueValue = dot(InTexel.rgb, BlueMatrix); vec3 OutColor = vec3(RedValue, GreenValue, BlueValue); - // Offset & Scale - OutColor = (OutColor * ColorScale) + Offset; - // Saturation float Luma = dot(OutColor, Gray); vec3 Chroma = OutColor - Luma; diff --git a/assets/minecraft/shaders/post/color_convolve.json b/assets/minecraft/shaders/post/color_convolve.json deleted file mode 100644 index 5ed0aeb9..00000000 --- a/assets/minecraft/shaders/post/color_convolve.json +++ /dev/null @@ -1,19 +0,0 @@ -{ - "vertex": "minecraft:post/sobel", - "fragment": "minecraft:post/color_convolve", - "samplers": [ - { "name": "InSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "InSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "Gray", "type": "float", "count": 3, "values": [ 0.3, 0.59, 0.11 ] }, - { "name": "RedMatrix", "type": "float", "count": 3, "values": [ 1.0, 0.0, 0.0 ] }, - { "name": "GreenMatrix", "type": "float", "count": 3, "values": [ 0.0, 1.0, 0.0 ] }, - { "name": "BlueMatrix", "type": "float", "count": 3, "values": [ 0.0, 0.0, 1.0 ] }, - { "name": "Offset", "type": "float", "count": 3, "values": [ 0.0, 0.0, 0.0 ] }, - { "name": "ColorScale", "type": "float", "count": 3, "values": [ 1.0, 1.0, 1.0 ] }, - { "name": "Saturation", "type": "float", "count": 1, "values": [ 1.8 ] } - ] -} diff --git a/assets/minecraft/shaders/post/entity_outline.json b/assets/minecraft/shaders/post/entity_outline.json deleted file mode 100644 index a60098f0..00000000 --- a/assets/minecraft/shaders/post/entity_outline.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "vertex": "minecraft:post/sobel", - "fragment": "minecraft:post/entity_sobel", - "samplers": [ - { "name": "InSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "InSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/post/entity_outline_box_blur.json b/assets/minecraft/shaders/post/entity_outline_box_blur.json deleted file mode 100644 index d46d1520..00000000 --- a/assets/minecraft/shaders/post/entity_outline_box_blur.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "blend": { - "func": "add", - "srcrgb": "one", - "dstrgb": "zero" - }, - "vertex": "minecraft:post/blur", - "fragment": "minecraft:post/entity_outline_box_blur", - "samplers": [ - { "name": "InSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "InSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "BlurDir", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/post/invert.json b/assets/minecraft/shaders/post/invert.json deleted file mode 100644 index e3ef44e9..00000000 --- a/assets/minecraft/shaders/post/invert.json +++ /dev/null @@ -1,13 +0,0 @@ -{ - "vertex": "minecraft:post/blit", - "fragment": "minecraft:post/invert", - "samplers": [ - { "name": "InSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "InSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "InverseAmount", "type": "float", "count": 1, "values": [ 0.0 ] } - ] -} diff --git a/assets/minecraft/shaders/post/invert.vsh b/assets/minecraft/shaders/post/invert.vsh index f30f3a83..c4fb025c 100644 --- a/assets/minecraft/shaders/post/invert.vsh +++ b/assets/minecraft/shaders/post/invert.vsh @@ -9,11 +9,11 @@ uniform vec2 OutSize; out vec2 texCoord; void main(){ - vec4 outPos = ProjMat * vec4(Position.xy, 0.0, 1.0); + vec4 outPos = ProjMat * vec4(Position.xy * OutSize, 0.0, 1.0); gl_Position = vec4(outPos.xy, 0.2, 1.0); vec2 sizeRatio = OutSize / InSize; - texCoord = Position.xy / OutSize; + texCoord = Position.xy; texCoord.x = texCoord.x * sizeRatio.x; texCoord.y = texCoord.y * sizeRatio.y; texCoord.y = sizeRatio.y - texCoord.y; diff --git a/assets/minecraft/shaders/post/rotscale.vsh b/assets/minecraft/shaders/post/rotscale.vsh index 7ca34de5..599ca499 100644 --- a/assets/minecraft/shaders/post/rotscale.vsh +++ b/assets/minecraft/shaders/post/rotscale.vsh @@ -14,10 +14,10 @@ out vec2 texCoord; out vec2 scaledCoord; void main(){ - vec4 outPos = ProjMat * vec4(Position.xy, 0.0, 1.0); + vec4 outPos = ProjMat * vec4(Position.xy * OutSize, 0.0, 1.0); gl_Position = vec4(outPos.xy, 0.2, 1.0); - texCoord = Position.xy / OutSize; + texCoord = Position.xy; float Deg2Rad = 0.0174532925; float InRadians = InRotation * Deg2Rad; diff --git a/assets/minecraft/shaders/post/screenquad.vsh b/assets/minecraft/shaders/post/screenquad.vsh index 9dfe91cd..c510ceed 100644 --- a/assets/minecraft/shaders/post/screenquad.vsh +++ b/assets/minecraft/shaders/post/screenquad.vsh @@ -8,7 +8,7 @@ uniform vec2 OutSize; out vec2 texCoord; void main() { - vec4 outPos = ProjMat * vec4(Position.xy, 0.0, 1.0); + vec4 outPos = ProjMat * vec4(Position.xy * OutSize, 0.0, 1.0); gl_Position = vec4(outPos.xy, 0.2, 1.0); - texCoord = Position.xy / OutSize; + texCoord = Position.xy; } diff --git a/assets/minecraft/shaders/post/sobel.vsh b/assets/minecraft/shaders/post/sobel.vsh index 99e97e06..65dd8581 100644 --- a/assets/minecraft/shaders/post/sobel.vsh +++ b/assets/minecraft/shaders/post/sobel.vsh @@ -10,10 +10,10 @@ out vec2 texCoord; out vec2 oneTexel; void main(){ - vec4 outPos = ProjMat * vec4(Position.xy, 0.0, 1.0); + vec4 outPos = ProjMat * vec4(Position.xy * OutSize, 0.0, 1.0); gl_Position = vec4(outPos.xy, 0.2, 1.0); oneTexel = 1.0 / InSize; - texCoord = Position.xy / OutSize; + texCoord = Position.xy; } diff --git a/assets/minecraft/shaders/post/spider.json b/assets/minecraft/shaders/post/spider.json deleted file mode 100644 index 1999cae7..00000000 --- a/assets/minecraft/shaders/post/spider.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "vertex": "minecraft:post/rotscale", - "fragment": "minecraft:post/spiderclip", - "samplers": [ - { "name": "InSampler" }, - { "name": "BlurSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "InSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "InScale", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] }, - { "name": "InOffset", "type": "float", "count": 2, "values": [ 0.0, 0.0 ] }, - { "name": "InRotation", "type": "float", "count": 1, "values": [ 0.0 ] }, - { "name": "Scissor", "type": "float", "count": 4, "values": [ 0.0, 0.0, 1.0, 1.0 ] }, - { "name": "Vignette", "type": "float", "count": 4, "values": [ 0.0, 0.0, 1.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/shaders/post/transparency.json b/assets/minecraft/shaders/post/transparency.json deleted file mode 100644 index 8f5b68ce..00000000 --- a/assets/minecraft/shaders/post/transparency.json +++ /dev/null @@ -1,22 +0,0 @@ -{ - "vertex": "minecraft:post/screenquad", - "fragment": "minecraft:post/transparency", - "samplers": [ - { "name": "MainSampler" }, - { "name": "MainDepthSampler" }, - { "name": "TranslucentSampler" }, - { "name": "TranslucentDepthSampler" }, - { "name": "ItemEntitySampler" }, - { "name": "ItemEntityDepthSampler" }, - { "name": "ParticlesSampler" }, - { "name": "ParticlesDepthSampler" }, - { "name": "CloudsSampler" }, - { "name": "CloudsDepthSampler" }, - { "name": "WeatherSampler" }, - { "name": "WeatherDepthSampler" } - ], - "uniforms": [ - { "name": "ProjMat", "type": "matrix4x4", "count": 16, "values": [ 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0, 0.0, 0.0, 0.0, 0.0, 1.0 ] }, - { "name": "OutSize", "type": "float", "count": 2, "values": [ 1.0, 1.0 ] } - ] -} diff --git a/assets/minecraft/textures/block/bush.png b/assets/minecraft/textures/block/bush.png new file mode 100644 index 00000000..7d8d0577 --- /dev/null +++ b/assets/minecraft/textures/block/bush.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4749dab15dd8baccfb3eb295f0a7241175e02a8ec66c6ce4601337147974812f +size 198 diff --git a/assets/minecraft/textures/block/cactus_flower.png b/assets/minecraft/textures/block/cactus_flower.png new file mode 100644 index 00000000..5416813e --- /dev/null +++ b/assets/minecraft/textures/block/cactus_flower.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ce712339cfeb510319c8f313bdb77fe42912b7c87eeab6e6faa1f70c74ace512 +size 182 diff --git a/assets/minecraft/textures/block/creaking_heart_active.png b/assets/minecraft/textures/block/creaking_heart_awake.png similarity index 100% rename from assets/minecraft/textures/block/creaking_heart_active.png rename to assets/minecraft/textures/block/creaking_heart_awake.png diff --git a/assets/minecraft/textures/block/creaking_heart_dormant.png b/assets/minecraft/textures/block/creaking_heart_dormant.png new file mode 100644 index 00000000..74e29f34 --- /dev/null +++ b/assets/minecraft/textures/block/creaking_heart_dormant.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:541721401cf7cdb6c001b66ead22afce92527a934ed23eb15b8c8f8af1509765 +size 236 diff --git a/assets/minecraft/textures/block/creaking_heart_top_active.png b/assets/minecraft/textures/block/creaking_heart_top_awake.png similarity index 100% rename from assets/minecraft/textures/block/creaking_heart_top_active.png rename to assets/minecraft/textures/block/creaking_heart_top_awake.png diff --git a/assets/minecraft/textures/block/creaking_heart_top_dormant.png b/assets/minecraft/textures/block/creaking_heart_top_dormant.png new file mode 100644 index 00000000..17ac5a9d --- /dev/null +++ b/assets/minecraft/textures/block/creaking_heart_top_dormant.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:607ef7939ef2445fb508f40d23d1dab3774dde91f3acd1447045be47153d9660 +size 233 diff --git a/assets/minecraft/textures/block/firefly_bush.png b/assets/minecraft/textures/block/firefly_bush.png new file mode 100644 index 00000000..153c8fe4 --- /dev/null +++ b/assets/minecraft/textures/block/firefly_bush.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c8561248bf33ef1dea7ed84a16b3623aa7a974a707c06b3b2a161a122cbe1600 +size 224 diff --git a/assets/minecraft/textures/block/firefly_bush_emissive.png b/assets/minecraft/textures/block/firefly_bush_emissive.png new file mode 100644 index 00000000..3218f922 --- /dev/null +++ b/assets/minecraft/textures/block/firefly_bush_emissive.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9519a8118504163df75438045befeaa440778bbb7c91f38066729be326358399 +size 188 diff --git a/assets/minecraft/textures/block/firefly_bush_emissive.png.mcmeta b/assets/minecraft/textures/block/firefly_bush_emissive.png.mcmeta new file mode 100644 index 00000000..8e55e43b --- /dev/null +++ b/assets/minecraft/textures/block/firefly_bush_emissive.png.mcmeta @@ -0,0 +1,5 @@ +{ + "animation": { + "frametime": 3 + } +} diff --git a/assets/minecraft/textures/block/leaf_litter.png b/assets/minecraft/textures/block/leaf_litter.png new file mode 100644 index 00000000..fd6f8452 --- /dev/null +++ b/assets/minecraft/textures/block/leaf_litter.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:671d40e6b84d5bade73eb6738e358ead56b8cc5e5f2e67592bc6ee32e05db885 +size 251 diff --git a/assets/minecraft/textures/block/short_dry_grass.png b/assets/minecraft/textures/block/short_dry_grass.png new file mode 100644 index 00000000..e8556739 --- /dev/null +++ b/assets/minecraft/textures/block/short_dry_grass.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e14ad13ebef278a19400829c319ea0f73f742fa806fd4f5edd3eca5588ce1057 +size 155 diff --git a/assets/minecraft/textures/block/tall_dry_grass.png b/assets/minecraft/textures/block/tall_dry_grass.png new file mode 100644 index 00000000..fc628165 --- /dev/null +++ b/assets/minecraft/textures/block/tall_dry_grass.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:720b8a49865f7d2f700a9a30317090cf8f1614790a034b96cb7a1aefe62d9a5d +size 189 diff --git a/assets/minecraft/textures/block/test_block_accept.png b/assets/minecraft/textures/block/test_block_accept.png new file mode 100644 index 00000000..0e27a3e0 --- /dev/null +++ b/assets/minecraft/textures/block/test_block_accept.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b5d6a5c2cf864db7b3eccd9816c47d122fc59b10c6bb55cb9432346c8c8a0cb0 +size 253 diff --git a/assets/minecraft/textures/block/test_block_fail.png b/assets/minecraft/textures/block/test_block_fail.png new file mode 100644 index 00000000..a7a28e38 --- /dev/null +++ b/assets/minecraft/textures/block/test_block_fail.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:47daec1cdb03a50a5821d068f5649fa07dadc740fef71e9b4d6cf3dd6956f370 +size 253 diff --git a/assets/minecraft/textures/block/test_block_log.png b/assets/minecraft/textures/block/test_block_log.png new file mode 100644 index 00000000..e90fe0dc --- /dev/null +++ b/assets/minecraft/textures/block/test_block_log.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0e719b222e49f642d09d64c2cb2d885b3f0c103f877dae07c59dbbbe4653b13d +size 253 diff --git a/assets/minecraft/textures/block/test_block_start.png b/assets/minecraft/textures/block/test_block_start.png new file mode 100644 index 00000000..c83b812f --- /dev/null +++ b/assets/minecraft/textures/block/test_block_start.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a36d144eabc272bbc6c31a18a656d6561e71836d4587ad04d382a536ca95e162 +size 260 diff --git a/assets/minecraft/textures/block/test_instance_block.png b/assets/minecraft/textures/block/test_instance_block.png new file mode 100644 index 00000000..725e2d4e --- /dev/null +++ b/assets/minecraft/textures/block/test_instance_block.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e762c8b71a04f0e4269eb6ababfa9be90086a1d164fc0828619f37469f6a6a77 +size 244 diff --git a/assets/minecraft/textures/block/wildflowers.png b/assets/minecraft/textures/block/wildflowers.png new file mode 100644 index 00000000..ed81c2cb --- /dev/null +++ b/assets/minecraft/textures/block/wildflowers.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:229760ea01b4ed04469c32fe16d04a966ca6e3df9616f4eead5126a6138d2c7f +size 192 diff --git a/assets/minecraft/textures/block/wildflowers_stem.png b/assets/minecraft/textures/block/wildflowers_stem.png new file mode 100644 index 00000000..3438db93 --- /dev/null +++ b/assets/minecraft/textures/block/wildflowers_stem.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:86622b67af968e48c78539b8d9d958123890af17c5a03f28348015d6f10b42f5 +size 80 diff --git a/assets/minecraft/textures/colormap/dry_foliage.png b/assets/minecraft/textures/colormap/dry_foliage.png new file mode 100644 index 00000000..72cacff4 --- /dev/null +++ b/assets/minecraft/textures/colormap/dry_foliage.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:daf58d3c01ebdca88a7e8062f3c5d9f54da0ba9347c110aa69492ffed68cf40a +size 8979 diff --git a/assets/minecraft/textures/entity/camel/camel.png b/assets/minecraft/textures/entity/camel/camel.png index 32b567a4..86550d5b 100644 --- a/assets/minecraft/textures/entity/camel/camel.png +++ b/assets/minecraft/textures/entity/camel/camel.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cc9c69ed055f3c98da53bb1f0c8093d58e3775bbbd2ea8217287394d56879487 -size 2218 +oid sha256:c8364d5bb6b667c3e4fe8364aea1d707dcb93c93b9d45c942e619b3130a3451a +size 1752 diff --git a/assets/minecraft/textures/entity/chicken/cold_chicken.png b/assets/minecraft/textures/entity/chicken/cold_chicken.png new file mode 100644 index 00000000..32772094 --- /dev/null +++ b/assets/minecraft/textures/entity/chicken/cold_chicken.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bc5c80b547f5a1c0b70ef19c51543f5fb02853e4d45cdfca9407dd925bb50761 +size 502 diff --git a/assets/minecraft/textures/entity/chicken.png b/assets/minecraft/textures/entity/chicken/temperate_chicken.png similarity index 100% rename from assets/minecraft/textures/entity/chicken.png rename to assets/minecraft/textures/entity/chicken/temperate_chicken.png diff --git a/assets/minecraft/textures/entity/chicken/warm_chicken.png b/assets/minecraft/textures/entity/chicken/warm_chicken.png new file mode 100644 index 00000000..aea49bc7 --- /dev/null +++ b/assets/minecraft/textures/entity/chicken/warm_chicken.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5643d6df418294ee65c5f1d7970927fd563d855c2ab534723fee946b69273f0b +size 414 diff --git a/assets/minecraft/textures/entity/cow/brown_mooshroom.png b/assets/minecraft/textures/entity/cow/brown_mooshroom.png index 1c8a5add..c8918932 100644 --- a/assets/minecraft/textures/entity/cow/brown_mooshroom.png +++ b/assets/minecraft/textures/entity/cow/brown_mooshroom.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f82e60437c2d9e3d8b11664358e848030fef70143343ac3f48da260a16242208 -size 835 +oid sha256:4dd50e641d3c8132c6b0d7575ff4db4f3c2d9e1db9d5442414d91a9dcd924ae2 +size 829 diff --git a/assets/minecraft/textures/entity/cow/cold_cow.png b/assets/minecraft/textures/entity/cow/cold_cow.png new file mode 100644 index 00000000..3c6957ad --- /dev/null +++ b/assets/minecraft/textures/entity/cow/cold_cow.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:45282919f7b5b2b1f074a2036882e8d34d55c72ae2ecb313ad949ba6d750abc8 +size 977 diff --git a/assets/minecraft/textures/entity/cow/cow.png b/assets/minecraft/textures/entity/cow/cow.png deleted file mode 100644 index 12321bbe..00000000 --- a/assets/minecraft/textures/entity/cow/cow.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:47ae8e77011e8b86a64047388a60bd8cfc9bd071301d6072a554c2134065996a -size 866 diff --git a/assets/minecraft/textures/entity/cow/red_mooshroom.png b/assets/minecraft/textures/entity/cow/red_mooshroom.png index 79956061..558a4524 100644 --- a/assets/minecraft/textures/entity/cow/red_mooshroom.png +++ b/assets/minecraft/textures/entity/cow/red_mooshroom.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:689cd82d0783b06648624bc241cb223d5bbcbb4410806ff6f97875608bec5224 -size 853 +oid sha256:f06ac87b18f499925614ec48498f727c4f175ae389549dcf44ef855b3de8485c +size 861 diff --git a/assets/minecraft/textures/entity/cow/temperate_cow.png b/assets/minecraft/textures/entity/cow/temperate_cow.png new file mode 100644 index 00000000..d0d597bf --- /dev/null +++ b/assets/minecraft/textures/entity/cow/temperate_cow.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:def74de776f7f28bd199dfc765bd0fabda18ce0339e70355f52d2dce42b0f93a +size 933 diff --git a/assets/minecraft/textures/entity/cow/warm_cow.png b/assets/minecraft/textures/entity/cow/warm_cow.png new file mode 100644 index 00000000..e6d1d3d4 --- /dev/null +++ b/assets/minecraft/textures/entity/cow/warm_cow.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d64a17aecc2d0dd37b5367ca89e5163ea70788052a3c00992bd6fc021f569ca0 +size 709 diff --git a/assets/minecraft/textures/entity/equipment/camel_saddle/saddle.png b/assets/minecraft/textures/entity/equipment/camel_saddle/saddle.png new file mode 100644 index 00000000..25c00ae9 --- /dev/null +++ b/assets/minecraft/textures/entity/equipment/camel_saddle/saddle.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e779d363b44eb73c4f3f3a27520b7f26a2cb2d1512aeb0f371f58fd3c82491bb +size 587 diff --git a/assets/minecraft/textures/entity/equipment/donkey_saddle/saddle.png b/assets/minecraft/textures/entity/equipment/donkey_saddle/saddle.png new file mode 100644 index 00000000..08651d51 --- /dev/null +++ b/assets/minecraft/textures/entity/equipment/donkey_saddle/saddle.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4eca0e61839969413e6ff9cdadfca3eb909779ff13abe18e4c4fab6780ae91fc +size 313 diff --git a/assets/minecraft/textures/entity/equipment/horse_saddle/saddle.png b/assets/minecraft/textures/entity/equipment/horse_saddle/saddle.png new file mode 100644 index 00000000..08651d51 --- /dev/null +++ b/assets/minecraft/textures/entity/equipment/horse_saddle/saddle.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4eca0e61839969413e6ff9cdadfca3eb909779ff13abe18e4c4fab6780ae91fc +size 313 diff --git a/assets/minecraft/textures/entity/equipment/mule_saddle/saddle.png b/assets/minecraft/textures/entity/equipment/mule_saddle/saddle.png new file mode 100644 index 00000000..08651d51 --- /dev/null +++ b/assets/minecraft/textures/entity/equipment/mule_saddle/saddle.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4eca0e61839969413e6ff9cdadfca3eb909779ff13abe18e4c4fab6780ae91fc +size 313 diff --git a/assets/minecraft/textures/entity/equipment/pig_saddle/saddle.png b/assets/minecraft/textures/entity/equipment/pig_saddle/saddle.png new file mode 100644 index 00000000..50c22002 --- /dev/null +++ b/assets/minecraft/textures/entity/equipment/pig_saddle/saddle.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:773087a4e77b29ccf8a0b98029f38e2aff07efad7720e5f21abdef5fd3b50177 +size 221 diff --git a/assets/minecraft/textures/entity/equipment/skeleton_horse_saddle/saddle.png b/assets/minecraft/textures/entity/equipment/skeleton_horse_saddle/saddle.png new file mode 100644 index 00000000..08651d51 --- /dev/null +++ b/assets/minecraft/textures/entity/equipment/skeleton_horse_saddle/saddle.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4eca0e61839969413e6ff9cdadfca3eb909779ff13abe18e4c4fab6780ae91fc +size 313 diff --git a/assets/minecraft/textures/entity/strider/strider_saddle.png b/assets/minecraft/textures/entity/equipment/strider_saddle/saddle.png similarity index 100% rename from assets/minecraft/textures/entity/strider/strider_saddle.png rename to assets/minecraft/textures/entity/equipment/strider_saddle/saddle.png diff --git a/assets/minecraft/textures/entity/equipment/zombie_horse_saddle/saddle.png b/assets/minecraft/textures/entity/equipment/zombie_horse_saddle/saddle.png new file mode 100644 index 00000000..78202ffe --- /dev/null +++ b/assets/minecraft/textures/entity/equipment/zombie_horse_saddle/saddle.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:99b6e167497b0000e6e2e1558e192ae25a2956fb6deb0b49f6bf9ee49d05ab24 +size 303 diff --git a/assets/minecraft/textures/entity/horse/donkey.png b/assets/minecraft/textures/entity/horse/donkey.png index a37998d2..6cf9d9f9 100644 --- a/assets/minecraft/textures/entity/horse/donkey.png +++ b/assets/minecraft/textures/entity/horse/donkey.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ac25979cab02ad1839113b97f41a98656fe8494e07c93d52eae7339bed2969ff -size 1411 +oid sha256:d834e6a98697f8b7c2a78ad1f648aa91696f6bec1b653a1edb918f13bbc666ca +size 1194 diff --git a/assets/minecraft/textures/entity/horse/horse_black.png b/assets/minecraft/textures/entity/horse/horse_black.png index 0dae766f..847ade87 100644 --- a/assets/minecraft/textures/entity/horse/horse_black.png +++ b/assets/minecraft/textures/entity/horse/horse_black.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:145403abe62e528b9e1953bc05237596f6c38b1b2bb90d6be98f4a8fb2870094 -size 1242 +oid sha256:b187fa206d78fc85c6f645e97a27f0c16b1c50bfdaf0bd3cc1965a329a4470a2 +size 910 diff --git a/assets/minecraft/textures/entity/horse/horse_brown.png b/assets/minecraft/textures/entity/horse/horse_brown.png index 8502c960..14db5854 100644 --- a/assets/minecraft/textures/entity/horse/horse_brown.png +++ b/assets/minecraft/textures/entity/horse/horse_brown.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:23f01fe3c03bb7a2023b8107cc0779a3ae1ac3ca6118fcf523df5549868903ac -size 1363 +oid sha256:3930cbd4620439e8f83c674f1729f49ec4f21205de5205a96d90bcf86e092830 +size 998 diff --git a/assets/minecraft/textures/entity/horse/horse_chestnut.png b/assets/minecraft/textures/entity/horse/horse_chestnut.png index 20625678..2a63e12b 100644 --- a/assets/minecraft/textures/entity/horse/horse_chestnut.png +++ b/assets/minecraft/textures/entity/horse/horse_chestnut.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9cf1db801e5581cac698f82b5cd060c2eb89464d85ffdfee75b8f865439f81ec -size 1425 +oid sha256:8fac7f1ae4212dca54f21a1795b239a4f6dcbe2d487b956bfc2e653393194ecd +size 1059 diff --git a/assets/minecraft/textures/entity/horse/horse_creamy.png b/assets/minecraft/textures/entity/horse/horse_creamy.png index 6c0935bf..e194fec1 100644 --- a/assets/minecraft/textures/entity/horse/horse_creamy.png +++ b/assets/minecraft/textures/entity/horse/horse_creamy.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:047c520b46fa3c6dfcdac68a140ce4fc4fde01f56beb44efa2fb631dabc08cc8 -size 1470 +oid sha256:109260e147deb23bb1867d32dee6ceda6c419ad06ca0319a09598b500ed167ff +size 1116 diff --git a/assets/minecraft/textures/entity/horse/horse_darkbrown.png b/assets/minecraft/textures/entity/horse/horse_darkbrown.png index 10174176..f9622988 100644 --- a/assets/minecraft/textures/entity/horse/horse_darkbrown.png +++ b/assets/minecraft/textures/entity/horse/horse_darkbrown.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:54c82c1291d63e65a87cbbfd4163c61106d92e98c1a4ad8a7e46b59f4c095595 -size 1243 +oid sha256:9df50d70aaf8a4b26456d7e7e1ad31e82dbc03d2c19b6a4fabfd3512baac64bf +size 913 diff --git a/assets/minecraft/textures/entity/horse/horse_gray.png b/assets/minecraft/textures/entity/horse/horse_gray.png index b77ff81a..74c0da3d 100644 --- a/assets/minecraft/textures/entity/horse/horse_gray.png +++ b/assets/minecraft/textures/entity/horse/horse_gray.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:09a683fd8c6d1b3aa227fd08c66ee394be63868b590c54476ea21853cf06417c -size 1148 +oid sha256:b4196f003b5377a84affd435bfaa247d9bbe497f82b091560a28c548b263e4bf +size 806 diff --git a/assets/minecraft/textures/entity/horse/horse_skeleton.png b/assets/minecraft/textures/entity/horse/horse_skeleton.png index 3db4a359..f31d914e 100644 --- a/assets/minecraft/textures/entity/horse/horse_skeleton.png +++ b/assets/minecraft/textures/entity/horse/horse_skeleton.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4ce6d2ccb97c63565ff6e23df46b10876811e847eee6a2d5e080350cc4f48ac2 -size 1102 +oid sha256:6603d27caae633947f6a0a0b8311e9659752f7343b0f97727ca10fa63693bd3d +size 762 diff --git a/assets/minecraft/textures/entity/horse/horse_white.png b/assets/minecraft/textures/entity/horse/horse_white.png index 87e87c59..6102245c 100644 --- a/assets/minecraft/textures/entity/horse/horse_white.png +++ b/assets/minecraft/textures/entity/horse/horse_white.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:43c3c9e5d5b92238590d72ac6d44e3c4b134207c9399641ffa4214495b8c5b2c -size 2454 +oid sha256:48db71af3dc8f11505afa2c3ad594e6cb5894a04f453869982b6f19bdaf27157 +size 987 diff --git a/assets/minecraft/textures/entity/horse/horse_zombie.png b/assets/minecraft/textures/entity/horse/horse_zombie.png index 611a6705..a6feb1fd 100644 --- a/assets/minecraft/textures/entity/horse/horse_zombie.png +++ b/assets/minecraft/textures/entity/horse/horse_zombie.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:80047f48572639faa015b9a9733eeb2cbe55e592b15ec0609858007c958e97f4 -size 1519 +oid sha256:1417f923875027f42720c4116a2d1d81ea1d16fc44efede100853d5cca9ecc7a +size 1116 diff --git a/assets/minecraft/textures/entity/horse/mule.png b/assets/minecraft/textures/entity/horse/mule.png index 926191a3..f31af875 100644 --- a/assets/minecraft/textures/entity/horse/mule.png +++ b/assets/minecraft/textures/entity/horse/mule.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:da3558c068899cc03743f8aa33aa31c374048bb0f5618e78b2d180b998b270ee -size 1403 +oid sha256:4b868118075c0a93621a48c68f438dff87f3911f6932442eb7fc99e588852da4 +size 1181 diff --git a/assets/minecraft/textures/entity/pig/cold_pig.png b/assets/minecraft/textures/entity/pig/cold_pig.png new file mode 100644 index 00000000..8f94322b --- /dev/null +++ b/assets/minecraft/textures/entity/pig/cold_pig.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f9a30605143d055d198722ef96766fc339e179dd3977f4e8e3c3b61a8a832b4 +size 656 diff --git a/assets/minecraft/textures/entity/pig/pig.png b/assets/minecraft/textures/entity/pig/pig.png deleted file mode 100644 index 560a7f1b..00000000 --- a/assets/minecraft/textures/entity/pig/pig.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:8dd8df187e9f0014d39fa1eddd7f96e1dcefdb88c9d019d4b16c3fefe8603305 -size 567 diff --git a/assets/minecraft/textures/entity/pig/pig_saddle.png b/assets/minecraft/textures/entity/pig/pig_saddle.png deleted file mode 100644 index 76cf3d78..00000000 --- a/assets/minecraft/textures/entity/pig/pig_saddle.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:9d6ef196a11c6f3ac59a25706fc851fcff40a12592887c37e8c7d901c798b020 -size 219 diff --git a/assets/minecraft/textures/entity/pig/temperate_pig.png b/assets/minecraft/textures/entity/pig/temperate_pig.png new file mode 100644 index 00000000..55d5bb2d --- /dev/null +++ b/assets/minecraft/textures/entity/pig/temperate_pig.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4e2891d9e7d7ac592c911a43c419e9bc6c91918fad3c45a1e8db2021b5553f0d +size 565 diff --git a/assets/minecraft/textures/entity/pig/warm_pig.png b/assets/minecraft/textures/entity/pig/warm_pig.png new file mode 100644 index 00000000..2423d47d --- /dev/null +++ b/assets/minecraft/textures/entity/pig/warm_pig.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e346928596596213712f5868ab2aa81d4ac89bc54cb62fc9e67c8d4a0a0642ef +size 573 diff --git a/assets/minecraft/textures/entity/sheep/sheep_fur.png b/assets/minecraft/textures/entity/sheep/sheep_fur.png deleted file mode 100644 index 089d02ba..00000000 --- a/assets/minecraft/textures/entity/sheep/sheep_fur.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:4bb089b142bd96ef829eb1e77a09cc579e27f7a54520e4cdb9917bfd811e329d -size 417 diff --git a/assets/minecraft/textures/entity/sheep/sheep_wool.png b/assets/minecraft/textures/entity/sheep/sheep_wool.png new file mode 100644 index 00000000..1fda2e01 --- /dev/null +++ b/assets/minecraft/textures/entity/sheep/sheep_wool.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4f76a7d14c8248288e7ad1bc73ea76bd509c19c828dd02268453406fd59d961c +size 414 diff --git a/assets/minecraft/textures/entity/sheep/sheep_wool_undercoat.png b/assets/minecraft/textures/entity/sheep/sheep_wool_undercoat.png new file mode 100644 index 00000000..e64865b7 --- /dev/null +++ b/assets/minecraft/textures/entity/sheep/sheep_wool_undercoat.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c954e67d69eace6cb1ffe431fda7591264f1b7c32bc2925b44ba606851e0b8b5 +size 414 diff --git a/assets/minecraft/textures/item/allay_spawn_egg.png b/assets/minecraft/textures/item/allay_spawn_egg.png new file mode 100644 index 00000000..b5e468b2 --- /dev/null +++ b/assets/minecraft/textures/item/allay_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f4534adf0c917e2542c56a10315e10eb77e3362a95700858b445278392e9b532 +size 237 diff --git a/assets/minecraft/textures/item/armadillo_spawn_egg.png b/assets/minecraft/textures/item/armadillo_spawn_egg.png new file mode 100644 index 00000000..a972094e --- /dev/null +++ b/assets/minecraft/textures/item/armadillo_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0b4be11ad86e4b266dac8b9080a38532b3ab8590d315338520e473e40c2f0450 +size 236 diff --git a/assets/minecraft/textures/item/axolotl_spawn_egg.png b/assets/minecraft/textures/item/axolotl_spawn_egg.png new file mode 100644 index 00000000..04def43f --- /dev/null +++ b/assets/minecraft/textures/item/axolotl_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a643dfe68e94abe248a3e85625d3326cdf498c1cf90090fb2bec4106d6ce4185 +size 208 diff --git a/assets/minecraft/textures/item/bat_spawn_egg.png b/assets/minecraft/textures/item/bat_spawn_egg.png new file mode 100644 index 00000000..cbfdba47 --- /dev/null +++ b/assets/minecraft/textures/item/bat_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:77de7634170e355513940358ccb6ae56a3866ff85a8476d7539082a8c6854d53 +size 231 diff --git a/assets/minecraft/textures/item/bee_spawn_egg.png b/assets/minecraft/textures/item/bee_spawn_egg.png new file mode 100644 index 00000000..25019e4d --- /dev/null +++ b/assets/minecraft/textures/item/bee_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:98adc405bbddfdf313fc464010163e20fac69805df7f8990893a624b8858a08b +size 223 diff --git a/assets/minecraft/textures/item/blaze_spawn_egg.png b/assets/minecraft/textures/item/blaze_spawn_egg.png new file mode 100644 index 00000000..4fb409ea --- /dev/null +++ b/assets/minecraft/textures/item/blaze_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6b58eea7f036473fb503bf5645bcd562b2cd4e10367080aca3fb4f97ba3c6604 +size 248 diff --git a/assets/minecraft/textures/item/blue_egg.png b/assets/minecraft/textures/item/blue_egg.png new file mode 100644 index 00000000..bb9a6b1f --- /dev/null +++ b/assets/minecraft/textures/item/blue_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:513e1b9d7e57d9ffdd0a053f3ccf617dc9cab0dbd2f4956a83ba81b118b4dfcb +size 176 diff --git a/assets/minecraft/textures/item/bogged_spawn_egg.png b/assets/minecraft/textures/item/bogged_spawn_egg.png new file mode 100644 index 00000000..024052f7 --- /dev/null +++ b/assets/minecraft/textures/item/bogged_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f770c421598453842a424cfed6121264f63f8aa3718c6d5e6e541ca685fae511 +size 272 diff --git a/assets/minecraft/textures/item/breeze_spawn_egg.png b/assets/minecraft/textures/item/breeze_spawn_egg.png new file mode 100644 index 00000000..28db48ad --- /dev/null +++ b/assets/minecraft/textures/item/breeze_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0bcdca3c772bbaf014e26813017a940666456b4037d39c11a7921bb8f4d0d803 +size 250 diff --git a/assets/minecraft/textures/item/brown_egg.png b/assets/minecraft/textures/item/brown_egg.png new file mode 100644 index 00000000..ff12fdc4 --- /dev/null +++ b/assets/minecraft/textures/item/brown_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0e8b89d49ae64f218cfe5266954791694b1c8c0a29aefa1dd1692c0303ac4ee6 +size 176 diff --git a/assets/minecraft/textures/item/camel_spawn_egg.png b/assets/minecraft/textures/item/camel_spawn_egg.png new file mode 100644 index 00000000..8e0c453f --- /dev/null +++ b/assets/minecraft/textures/item/camel_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:26bb0ae9cb7c27fe284c676f1c78baa5be0c58a66bd73df35061706c74b0bc23 +size 254 diff --git a/assets/minecraft/textures/item/cat_spawn_egg.png b/assets/minecraft/textures/item/cat_spawn_egg.png new file mode 100644 index 00000000..2ba19918 --- /dev/null +++ b/assets/minecraft/textures/item/cat_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2ba9b5888b0087c0cb32cd6ea4999022a55ac8429e813e5f2e420ebbed2198b4 +size 201 diff --git a/assets/minecraft/textures/item/cave_spider_spawn_egg.png b/assets/minecraft/textures/item/cave_spider_spawn_egg.png new file mode 100644 index 00000000..290dea5a --- /dev/null +++ b/assets/minecraft/textures/item/cave_spider_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:feee12d692d516ac3c1a9ac8deebccd9a5c6d7acb4be7db34742c157dc796b56 +size 229 diff --git a/assets/minecraft/textures/item/chicken_spawn_egg.png b/assets/minecraft/textures/item/chicken_spawn_egg.png new file mode 100644 index 00000000..3f52de8b --- /dev/null +++ b/assets/minecraft/textures/item/chicken_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:97c478f0cc229dbdead7975785a54a20d532321c5789364c03c3b64a21fdc047 +size 199 diff --git a/assets/minecraft/textures/item/cod_spawn_egg.png b/assets/minecraft/textures/item/cod_spawn_egg.png new file mode 100644 index 00000000..12aa81c7 --- /dev/null +++ b/assets/minecraft/textures/item/cod_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:29a94226feabdad20e65369b2290e9fc2016c3b9897b2f0ebecce918a3ea959f +size 219 diff --git a/assets/minecraft/textures/item/cow_spawn_egg.png b/assets/minecraft/textures/item/cow_spawn_egg.png new file mode 100644 index 00000000..37fa3a4c --- /dev/null +++ b/assets/minecraft/textures/item/cow_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dfedb3c84c51e23eba0d9dabd5030271af51b0a438373987c0ff5beddc90b58c +size 261 diff --git a/assets/minecraft/textures/item/creaking_spawn_egg.png b/assets/minecraft/textures/item/creaking_spawn_egg.png new file mode 100644 index 00000000..a8e3cfcc --- /dev/null +++ b/assets/minecraft/textures/item/creaking_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:1994cc7868d542f46e4c3ac1d01af6d3de5931786b2870fad3ab2ef7d4f0019c +size 258 diff --git a/assets/minecraft/textures/item/creeper_spawn_egg.png b/assets/minecraft/textures/item/creeper_spawn_egg.png new file mode 100644 index 00000000..be2fa5a6 --- /dev/null +++ b/assets/minecraft/textures/item/creeper_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2283799812c0b0931e5a566a09f805d4a041eb06fb3ed8d0580dd236e140c5a9 +size 236 diff --git a/assets/minecraft/textures/item/dolphin_spawn_egg.png b/assets/minecraft/textures/item/dolphin_spawn_egg.png new file mode 100644 index 00000000..f361b818 --- /dev/null +++ b/assets/minecraft/textures/item/dolphin_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:034a57dc91d7feb43c94178be6c2a4779be2920155d51e920ef04aa9c25c8489 +size 251 diff --git a/assets/minecraft/textures/item/donkey_spawn_egg.png b/assets/minecraft/textures/item/donkey_spawn_egg.png new file mode 100644 index 00000000..9d063f8b --- /dev/null +++ b/assets/minecraft/textures/item/donkey_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e1d4b8d3aacd6a9605fc7f0fbd4159ebd21a816b99725bdae010d7aaceb6188a +size 267 diff --git a/assets/minecraft/textures/item/drowned_spawn_egg.png b/assets/minecraft/textures/item/drowned_spawn_egg.png new file mode 100644 index 00000000..0ba70fd8 --- /dev/null +++ b/assets/minecraft/textures/item/drowned_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c32f60dcae3127f8d697fc241cc3aca9a86335ee1bc364302487c6d7004f1328 +size 247 diff --git a/assets/minecraft/textures/item/elder_guardian_spawn_egg.png b/assets/minecraft/textures/item/elder_guardian_spawn_egg.png new file mode 100644 index 00000000..959f3b29 --- /dev/null +++ b/assets/minecraft/textures/item/elder_guardian_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:543c855aabb79164e05fc78cdf19e2fd3ce81003144f078ce82e20cfcf4b7c1d +size 268 diff --git a/assets/minecraft/textures/item/ender_dragon_spawn_egg.png b/assets/minecraft/textures/item/ender_dragon_spawn_egg.png new file mode 100644 index 00000000..b5e847b9 --- /dev/null +++ b/assets/minecraft/textures/item/ender_dragon_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8ee2291325ee273642a6114ecab2f92562d156f730b981bb0c600d7c52358cd2 +size 269 diff --git a/assets/minecraft/textures/item/enderman_spawn_egg.png b/assets/minecraft/textures/item/enderman_spawn_egg.png new file mode 100644 index 00000000..56631136 --- /dev/null +++ b/assets/minecraft/textures/item/enderman_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:60d0fea60abea2aab1d9c6670153699586d63c77a336212768299e1f5aa36ef2 +size 258 diff --git a/assets/minecraft/textures/item/endermite_spawn_egg.png b/assets/minecraft/textures/item/endermite_spawn_egg.png new file mode 100644 index 00000000..7e87eef7 --- /dev/null +++ b/assets/minecraft/textures/item/endermite_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:94d1a49d87c2a1c955633390633c3c539a02931e84a111f18d2f4fcf1c7ba153 +size 205 diff --git a/assets/minecraft/textures/item/evoker_spawn_egg.png b/assets/minecraft/textures/item/evoker_spawn_egg.png new file mode 100644 index 00000000..030fa476 --- /dev/null +++ b/assets/minecraft/textures/item/evoker_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:222b6972c64970ebf1e3afa749d8bf24e17b0f5331512f348d3a585fbf331a95 +size 258 diff --git a/assets/minecraft/textures/item/firefly_bush.png b/assets/minecraft/textures/item/firefly_bush.png new file mode 100644 index 00000000..f9b9015f --- /dev/null +++ b/assets/minecraft/textures/item/firefly_bush.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f3b6d7188b43667e73c290eaf0f3e692edc6dc13249d92008f4a0ec1348ef239 +size 227 diff --git a/assets/minecraft/textures/item/fox_spawn_egg.png b/assets/minecraft/textures/item/fox_spawn_egg.png new file mode 100644 index 00000000..c234785f --- /dev/null +++ b/assets/minecraft/textures/item/fox_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:48d2929623398b7ffce53489a9fb8a5a874d50022309f21c797ee6f1dbfdd1e3 +size 218 diff --git a/assets/minecraft/textures/item/frog_spawn_egg.png b/assets/minecraft/textures/item/frog_spawn_egg.png new file mode 100644 index 00000000..c6e5d976 --- /dev/null +++ b/assets/minecraft/textures/item/frog_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3cec76cd48e6285d3c12de129e29fed43914d1aaf3258bc1aa33de1d55266aa1 +size 204 diff --git a/assets/minecraft/textures/item/ghast_spawn_egg.png b/assets/minecraft/textures/item/ghast_spawn_egg.png new file mode 100644 index 00000000..09fb58a7 --- /dev/null +++ b/assets/minecraft/textures/item/ghast_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:445b71f617703d755b4b78639014f29ed8acc845834791d239a1138d1082e2db +size 207 diff --git a/assets/minecraft/textures/item/glow_squid_spawn_egg.png b/assets/minecraft/textures/item/glow_squid_spawn_egg.png new file mode 100644 index 00000000..009e5a60 --- /dev/null +++ b/assets/minecraft/textures/item/glow_squid_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:35ec4c9d75040570e153b8c22bd9d2642567be32c076448138f550be3474ae62 +size 253 diff --git a/assets/minecraft/textures/item/goat_spawn_egg.png b/assets/minecraft/textures/item/goat_spawn_egg.png new file mode 100644 index 00000000..bcf7d017 --- /dev/null +++ b/assets/minecraft/textures/item/goat_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:dfff74c1d086f7d9a8abcedbe12558711c1971e7f80ded59a83eeefb3e7daec0 +size 242 diff --git a/assets/minecraft/textures/item/guardian_spawn_egg.png b/assets/minecraft/textures/item/guardian_spawn_egg.png new file mode 100644 index 00000000..0296cd8b --- /dev/null +++ b/assets/minecraft/textures/item/guardian_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2e33aa2a5c81a75e79549cce02bbf054f1ee2adf9a8afc5d3c970d1986d2b99e +size 255 diff --git a/assets/minecraft/textures/item/hoglin_spawn_egg.png b/assets/minecraft/textures/item/hoglin_spawn_egg.png new file mode 100644 index 00000000..014768aa --- /dev/null +++ b/assets/minecraft/textures/item/hoglin_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e6c3ad682fbf4220578f58ec962238182853d729b9ee2e833e76992b32ea5a7c +size 269 diff --git a/assets/minecraft/textures/item/horse_spawn_egg.png b/assets/minecraft/textures/item/horse_spawn_egg.png new file mode 100644 index 00000000..54469c62 --- /dev/null +++ b/assets/minecraft/textures/item/horse_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:81c74186b55759ce647e2515935ad9e9153bb8a0e18bce373dc540ddf48ebb7d +size 269 diff --git a/assets/minecraft/textures/item/husk_spawn_egg.png b/assets/minecraft/textures/item/husk_spawn_egg.png new file mode 100644 index 00000000..6c2134ab --- /dev/null +++ b/assets/minecraft/textures/item/husk_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5a188ad79c566a9ada8de8399785146efe6eb0339d55d64c508d223becc5c5c0 +size 249 diff --git a/assets/minecraft/textures/item/iron_golem_spawn_egg.png b/assets/minecraft/textures/item/iron_golem_spawn_egg.png new file mode 100644 index 00000000..69c10b97 --- /dev/null +++ b/assets/minecraft/textures/item/iron_golem_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6f269e010c8cf5d3657ede43a8c5d79df4df5d3b77bdd6e0a0bd079f4216f405 +size 297 diff --git a/assets/minecraft/textures/item/leaf_litter.png b/assets/minecraft/textures/item/leaf_litter.png new file mode 100644 index 00000000..fdba83e9 --- /dev/null +++ b/assets/minecraft/textures/item/leaf_litter.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c205b6f8698b961fc54e4fa4df6d42a813840cd7fc07ff033a3f5ea65e534a8c +size 273 diff --git a/assets/minecraft/textures/item/llama_spawn_egg.png b/assets/minecraft/textures/item/llama_spawn_egg.png new file mode 100644 index 00000000..b2d51923 --- /dev/null +++ b/assets/minecraft/textures/item/llama_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6e1eb88d7ad03ee8664e2d7f1be3fc45f12f21eb84b4296a8dd7c74f3a50f14e +size 223 diff --git a/assets/minecraft/textures/item/magma_cube_spawn_egg.png b/assets/minecraft/textures/item/magma_cube_spawn_egg.png new file mode 100644 index 00000000..b9050c8d --- /dev/null +++ b/assets/minecraft/textures/item/magma_cube_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:2213be1fe21507a22d5ab580fb1da9ab70c2f63c9a35fdc824bea802165578cf +size 265 diff --git a/assets/minecraft/textures/item/mooshroom_spawn_egg.png b/assets/minecraft/textures/item/mooshroom_spawn_egg.png new file mode 100644 index 00000000..42c2b1a1 --- /dev/null +++ b/assets/minecraft/textures/item/mooshroom_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3c7f03cce335163fe3e39e02218398659970d1a6a4aeba73e9c7d1d993987899 +size 268 diff --git a/assets/minecraft/textures/item/mule_spawn_egg.png b/assets/minecraft/textures/item/mule_spawn_egg.png new file mode 100644 index 00000000..f7e04049 --- /dev/null +++ b/assets/minecraft/textures/item/mule_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b3124dca18f54698644298d2eb60f32d771a4bc2b39ed459579be19e98c9a706 +size 266 diff --git a/assets/minecraft/textures/item/ocelot_spawn_egg.png b/assets/minecraft/textures/item/ocelot_spawn_egg.png new file mode 100644 index 00000000..9da97043 --- /dev/null +++ b/assets/minecraft/textures/item/ocelot_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:89b52eb8feec7bbe1244115ef3db70f85cc01ca751b8013a6974555ee94e27d0 +size 199 diff --git a/assets/minecraft/textures/item/panda_spawn_egg.png b/assets/minecraft/textures/item/panda_spawn_egg.png new file mode 100644 index 00000000..fe11a05e --- /dev/null +++ b/assets/minecraft/textures/item/panda_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:75a6f6c61e1f3792127a2275b11aa5a4c90beeace2ec3137ee9f1db15158e4e9 +size 267 diff --git a/assets/minecraft/textures/item/parrot_spawn_egg.png b/assets/minecraft/textures/item/parrot_spawn_egg.png new file mode 100644 index 00000000..a350c7cf --- /dev/null +++ b/assets/minecraft/textures/item/parrot_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7d4c9e57d9a8d801937a0539652c8ee2544e70ac8f4d2bf7c4b345cd8749ebd7 +size 231 diff --git a/assets/minecraft/textures/item/phantom_spawn_egg.png b/assets/minecraft/textures/item/phantom_spawn_egg.png new file mode 100644 index 00000000..5fe086bc --- /dev/null +++ b/assets/minecraft/textures/item/phantom_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7a8df3e4dc448442cb12e6cc49a5fe7f0a980dc0b51241987a34cd431537b613 +size 233 diff --git a/assets/minecraft/textures/item/pig_spawn_egg.png b/assets/minecraft/textures/item/pig_spawn_egg.png new file mode 100644 index 00000000..6d9b2ea2 --- /dev/null +++ b/assets/minecraft/textures/item/pig_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:5ae86040bb313c13e2545bb2611cdf8ea40d4ed2b447c88a4396e170ac74acfa +size 201 diff --git a/assets/minecraft/textures/item/piglin_brute_spawn_egg.png b/assets/minecraft/textures/item/piglin_brute_spawn_egg.png new file mode 100644 index 00000000..08e7d987 --- /dev/null +++ b/assets/minecraft/textures/item/piglin_brute_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f0b4df628900aa05a048190c2c0216bfcfd73c9b33b2be7dac9f012c43000af6 +size 291 diff --git a/assets/minecraft/textures/item/piglin_spawn_egg.png b/assets/minecraft/textures/item/piglin_spawn_egg.png new file mode 100644 index 00000000..186c362f --- /dev/null +++ b/assets/minecraft/textures/item/piglin_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:53c292b6c54f402e3b03184ec4c61472ff0bf7050b878b3eb1d203df59ae47d4 +size 267 diff --git a/assets/minecraft/textures/item/pillager_spawn_egg.png b/assets/minecraft/textures/item/pillager_spawn_egg.png new file mode 100644 index 00000000..44ab02fb --- /dev/null +++ b/assets/minecraft/textures/item/pillager_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e570952d3aa129e37d9a9e0964fea9b63ce37de31e04cb04d2c49354a1a47ca0 +size 262 diff --git a/assets/minecraft/textures/item/polar_bear_spawn_egg.png b/assets/minecraft/textures/item/polar_bear_spawn_egg.png new file mode 100644 index 00000000..e63d0792 --- /dev/null +++ b/assets/minecraft/textures/item/polar_bear_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:09b559f500c3239a54a8a7a03ec91e54c638adf248927186124b7aaebde3161c +size 224 diff --git a/assets/minecraft/textures/item/pufferfish_spawn_egg.png b/assets/minecraft/textures/item/pufferfish_spawn_egg.png new file mode 100644 index 00000000..cc04c3bf --- /dev/null +++ b/assets/minecraft/textures/item/pufferfish_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3d2ecb04a6471e238339920002ff2f68272511285410b96bc31df755687e8ffd +size 272 diff --git a/assets/minecraft/textures/item/rabbit_spawn_egg.png b/assets/minecraft/textures/item/rabbit_spawn_egg.png new file mode 100644 index 00000000..549343bc --- /dev/null +++ b/assets/minecraft/textures/item/rabbit_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:497f068d34ce25c3ae31500726053f4c3f459156798501d8aa4e636175651603 +size 219 diff --git a/assets/minecraft/textures/item/ravager_spawn_egg.png b/assets/minecraft/textures/item/ravager_spawn_egg.png new file mode 100644 index 00000000..911c4013 --- /dev/null +++ b/assets/minecraft/textures/item/ravager_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b67c0d1215504411d3546bd411f956407d41028543afac46a06abb991d3ee5c2 +size 276 diff --git a/assets/minecraft/textures/item/salmon_spawn_egg.png b/assets/minecraft/textures/item/salmon_spawn_egg.png new file mode 100644 index 00000000..b15120bf --- /dev/null +++ b/assets/minecraft/textures/item/salmon_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:808f0b3f83e645f54d6b484afaf06d143b457ed69176a039ce2b25c89af1c9b3 +size 268 diff --git a/assets/minecraft/textures/item/sheep_spawn_egg.png b/assets/minecraft/textures/item/sheep_spawn_egg.png new file mode 100644 index 00000000..ba16547b --- /dev/null +++ b/assets/minecraft/textures/item/sheep_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:00489967e2c351927b5b9f77fb7cbc1a1e0bc5681556c612ef21a1de0b731bf3 +size 232 diff --git a/assets/minecraft/textures/item/shulker_spawn_egg.png b/assets/minecraft/textures/item/shulker_spawn_egg.png new file mode 100644 index 00000000..7158be28 --- /dev/null +++ b/assets/minecraft/textures/item/shulker_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:64bac5108a8304b3d2b1a965802bf47db3d9d2e6c5039e54c8879c2d630ef50c +size 213 diff --git a/assets/minecraft/textures/item/silverfish_spawn_egg.png b/assets/minecraft/textures/item/silverfish_spawn_egg.png new file mode 100644 index 00000000..8264f7a8 --- /dev/null +++ b/assets/minecraft/textures/item/silverfish_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a86e7965931498a38d748af9dd868b0fc39c76ccaad4411f55c2741f69665dee +size 260 diff --git a/assets/minecraft/textures/item/skeleton_horse_spawn_egg.png b/assets/minecraft/textures/item/skeleton_horse_spawn_egg.png new file mode 100644 index 00000000..891063c2 --- /dev/null +++ b/assets/minecraft/textures/item/skeleton_horse_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0477a9e8747eaf64a481e6ea529a10b635dbb0c8306c16e3d096cb5ac375ca02 +size 231 diff --git a/assets/minecraft/textures/item/skeleton_spawn_egg.png b/assets/minecraft/textures/item/skeleton_spawn_egg.png new file mode 100644 index 00000000..04ae1120 --- /dev/null +++ b/assets/minecraft/textures/item/skeleton_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b5075baf4259864f65699f1b363b95300ec70ef9254fb163f1a368a7ee52a736 +size 209 diff --git a/assets/minecraft/textures/item/slime_spawn_egg.png b/assets/minecraft/textures/item/slime_spawn_egg.png new file mode 100644 index 00000000..dbdd7852 --- /dev/null +++ b/assets/minecraft/textures/item/slime_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:cd4a8f63547d62633f251f4611bef9fead987e0e3308b465db0474c0856552e9 +size 208 diff --git a/assets/minecraft/textures/item/sniffer_spawn_egg.png b/assets/minecraft/textures/item/sniffer_spawn_egg.png new file mode 100644 index 00000000..77a7fe3c --- /dev/null +++ b/assets/minecraft/textures/item/sniffer_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3e3d4eb2af771f88c35c00f70d55da6ef421eceb0c6a01318308ab33327b4e43 +size 272 diff --git a/assets/minecraft/textures/item/snow_golem_spawn_egg.png b/assets/minecraft/textures/item/snow_golem_spawn_egg.png new file mode 100644 index 00000000..7a85c214 --- /dev/null +++ b/assets/minecraft/textures/item/snow_golem_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:377ac75349e6746acdecee9b791a4ac9c82f08d75098aec1dcfe543eeba9c8b9 +size 262 diff --git a/assets/minecraft/textures/item/spawn_egg.png b/assets/minecraft/textures/item/spawn_egg.png deleted file mode 100644 index 180f1bfd..00000000 --- a/assets/minecraft/textures/item/spawn_egg.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:f6b985a0094408770f4b0ba919c2cb6365c6e8b65080334b33617518be2089c1 -size 266 diff --git a/assets/minecraft/textures/item/spawn_egg_overlay.png b/assets/minecraft/textures/item/spawn_egg_overlay.png deleted file mode 100644 index de7cb17d..00000000 --- a/assets/minecraft/textures/item/spawn_egg_overlay.png +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:df0075d5081a1f49f0f4de1e1f004764446ecb3233416f7cd027c58823190747 -size 402 diff --git a/assets/minecraft/textures/item/spider_spawn_egg.png b/assets/minecraft/textures/item/spider_spawn_egg.png new file mode 100644 index 00000000..df445c5a --- /dev/null +++ b/assets/minecraft/textures/item/spider_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:45a01717c134362db5a2bbd8e25bf12480453a2849ceeb24d3d815687df4f996 +size 236 diff --git a/assets/minecraft/textures/item/squid_spawn_egg.png b/assets/minecraft/textures/item/squid_spawn_egg.png new file mode 100644 index 00000000..6a828f3a --- /dev/null +++ b/assets/minecraft/textures/item/squid_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a4b9b3a5f2f5504e42b85a99e3d4e74820934d83a85d7af25b208c27251b8c55 +size 240 diff --git a/assets/minecraft/textures/item/stray_spawn_egg.png b/assets/minecraft/textures/item/stray_spawn_egg.png new file mode 100644 index 00000000..078dc51c --- /dev/null +++ b/assets/minecraft/textures/item/stray_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9d5e3fdcff2fe213baec93e4aed9974fcfc746c396ff3da90bab8e07d6f7f037 +size 240 diff --git a/assets/minecraft/textures/item/strider_spawn_egg.png b/assets/minecraft/textures/item/strider_spawn_egg.png new file mode 100644 index 00000000..8bb37804 --- /dev/null +++ b/assets/minecraft/textures/item/strider_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f65f8a015fe2b2380c44dfc328ea666674359602516ad04f4129d5c222cffc6d +size 265 diff --git a/assets/minecraft/textures/item/tadpole_spawn_egg.png b/assets/minecraft/textures/item/tadpole_spawn_egg.png new file mode 100644 index 00000000..8a2192f1 --- /dev/null +++ b/assets/minecraft/textures/item/tadpole_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:557a75a1d8f24c3033b45d337918c105bb8c70bc89f7c4bc58b97d99d94a7f8c +size 224 diff --git a/assets/minecraft/textures/item/trader_llama_spawn_egg.png b/assets/minecraft/textures/item/trader_llama_spawn_egg.png new file mode 100644 index 00000000..eb90a953 --- /dev/null +++ b/assets/minecraft/textures/item/trader_llama_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:56b5a3c8d90225012bc7e67fb2d4c76d38e5c6735992f09969bf4e2e33f13d05 +size 262 diff --git a/assets/minecraft/textures/item/tropical_fish_spawn_egg.png b/assets/minecraft/textures/item/tropical_fish_spawn_egg.png new file mode 100644 index 00000000..537ba46c --- /dev/null +++ b/assets/minecraft/textures/item/tropical_fish_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:c0093fe3958eb7ee063b66d0b3cdc609fc2569d98743e63cb2710ad5af3c0fc8 +size 255 diff --git a/assets/minecraft/textures/item/turtle_spawn_egg.png b/assets/minecraft/textures/item/turtle_spawn_egg.png new file mode 100644 index 00000000..29c2f70b --- /dev/null +++ b/assets/minecraft/textures/item/turtle_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6c99f416648419cc5109c29b06bc6ea48f5e6b1782d26cb71c3305c22538c96b +size 234 diff --git a/assets/minecraft/textures/item/vex_spawn_egg.png b/assets/minecraft/textures/item/vex_spawn_egg.png new file mode 100644 index 00000000..d35b6826 --- /dev/null +++ b/assets/minecraft/textures/item/vex_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:811472304ac3fd3c44fb4e0071f1c6a0829103666428416c88e448231bcad64c +size 243 diff --git a/assets/minecraft/textures/item/villager_spawn_egg.png b/assets/minecraft/textures/item/villager_spawn_egg.png new file mode 100644 index 00000000..450b01bb --- /dev/null +++ b/assets/minecraft/textures/item/villager_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b5f5efd1d6c8e4c4ab577a2586eaac4cf95c47fe053da03bf26a8573749718cb +size 228 diff --git a/assets/minecraft/textures/item/vindicator_spawn_egg.png b/assets/minecraft/textures/item/vindicator_spawn_egg.png new file mode 100644 index 00000000..d2e51e73 --- /dev/null +++ b/assets/minecraft/textures/item/vindicator_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:7a04b98a84248c658d028fa00fef8bf91c1f6e617bd260ad7b13b5bc95689670 +size 247 diff --git a/assets/minecraft/textures/item/wandering_trader_spawn_egg.png b/assets/minecraft/textures/item/wandering_trader_spawn_egg.png new file mode 100644 index 00000000..ad1e278d --- /dev/null +++ b/assets/minecraft/textures/item/wandering_trader_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0366be3234cf03fa7ebd9d2007bac086350a72d9cb8a12abb66e1d591a674d83 +size 279 diff --git a/assets/minecraft/textures/item/warden_spawn_egg.png b/assets/minecraft/textures/item/warden_spawn_egg.png new file mode 100644 index 00000000..e7e50629 --- /dev/null +++ b/assets/minecraft/textures/item/warden_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8123e3bd155dc18e320c80451836e43c8639683a7d9360986f197254204a876a +size 272 diff --git a/assets/minecraft/textures/item/wildflowers.png b/assets/minecraft/textures/item/wildflowers.png new file mode 100644 index 00000000..6e4669ea --- /dev/null +++ b/assets/minecraft/textures/item/wildflowers.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e5082cc0923298aa031aac59c6238dbb1b1e80160949c89f6b92236575b3987a +size 201 diff --git a/assets/minecraft/textures/item/witch_spawn_egg.png b/assets/minecraft/textures/item/witch_spawn_egg.png new file mode 100644 index 00000000..e06c216d --- /dev/null +++ b/assets/minecraft/textures/item/witch_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:64b45ddac963a62da25e73910117ff741c73793cc5b486efeb6f5dfcce20f203 +size 277 diff --git a/assets/minecraft/textures/item/wither_skeleton_spawn_egg.png b/assets/minecraft/textures/item/wither_skeleton_spawn_egg.png new file mode 100644 index 00000000..ef5f0c3c --- /dev/null +++ b/assets/minecraft/textures/item/wither_skeleton_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b3b161c33007dd26220b8be6dcec9b7b13a5b6b98c2f6c52af72e5400d6ccfb +size 216 diff --git a/assets/minecraft/textures/item/wither_spawn_egg.png b/assets/minecraft/textures/item/wither_spawn_egg.png new file mode 100644 index 00000000..8a16e0e6 --- /dev/null +++ b/assets/minecraft/textures/item/wither_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:4c33dba205369d447ef224d6fa520f998b0188acc721ba70b493eb85031170a5 +size 233 diff --git a/assets/minecraft/textures/item/wolf_spawn_egg.png b/assets/minecraft/textures/item/wolf_spawn_egg.png new file mode 100644 index 00000000..883230e6 --- /dev/null +++ b/assets/minecraft/textures/item/wolf_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e11bf54810132fec84e45511a3567dd97e029c1bb655d6c5e5ba77945c49129b +size 241 diff --git a/assets/minecraft/textures/item/zoglin_spawn_egg.png b/assets/minecraft/textures/item/zoglin_spawn_egg.png new file mode 100644 index 00000000..e560e6f1 --- /dev/null +++ b/assets/minecraft/textures/item/zoglin_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:bba948f53316aa2d24d54d736e611e796bc968c48da72c5890e0f86addff410c +size 337 diff --git a/assets/minecraft/textures/item/zombie_horse_spawn_egg.png b/assets/minecraft/textures/item/zombie_horse_spawn_egg.png new file mode 100644 index 00000000..d7039361 --- /dev/null +++ b/assets/minecraft/textures/item/zombie_horse_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:954e802a6a177f9fb22a7c54b0824ea05080e8a0b621fd3768a8a3dc35966074 +size 259 diff --git a/assets/minecraft/textures/item/zombie_spawn_egg.png b/assets/minecraft/textures/item/zombie_spawn_egg.png new file mode 100644 index 00000000..450c9214 --- /dev/null +++ b/assets/minecraft/textures/item/zombie_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3dc67c80c9d13874d9863b7249af585829cc9610bd6c377704ab97e643da34eb +size 235 diff --git a/assets/minecraft/textures/item/zombie_villager_spawn_egg.png b/assets/minecraft/textures/item/zombie_villager_spawn_egg.png new file mode 100644 index 00000000..b00eb576 --- /dev/null +++ b/assets/minecraft/textures/item/zombie_villager_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:88906bcece7e0c8e2a3132149e3775a4928a213aa22a592df3b9cc91aed93981 +size 235 diff --git a/assets/minecraft/textures/item/zombified_piglin_spawn_egg.png b/assets/minecraft/textures/item/zombified_piglin_spawn_egg.png new file mode 100644 index 00000000..ed01dcf5 --- /dev/null +++ b/assets/minecraft/textures/item/zombified_piglin_spawn_egg.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:513a7b61259a40b806757f8ec163d5c24be5e3f0fdabf6cf941bd61fb16bbf12 +size 297 diff --git a/assets/minecraft/textures/misc/enchanted_glint_entity.png b/assets/minecraft/textures/misc/enchanted_glint_armor.png similarity index 100% rename from assets/minecraft/textures/misc/enchanted_glint_entity.png rename to assets/minecraft/textures/misc/enchanted_glint_armor.png diff --git a/assets/minecraft/textures/misc/enchanted_glint_entity.png.mcmeta b/assets/minecraft/textures/misc/enchanted_glint_armor.png.mcmeta similarity index 100% rename from assets/minecraft/textures/misc/enchanted_glint_entity.png.mcmeta rename to assets/minecraft/textures/misc/enchanted_glint_armor.png.mcmeta diff --git a/assets/minecraft/textures/particle/firefly.png b/assets/minecraft/textures/particle/firefly.png new file mode 100644 index 00000000..e4ef4763 --- /dev/null +++ b/assets/minecraft/textures/particle/firefly.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:e13ccf41823ca16b8abeed793b3c39e1936a4fb2f24349f888ea86de7ce0cfbb +size 73 diff --git a/assets/minecraft/textures/particle/leaf_0.png b/assets/minecraft/textures/particle/leaf_0.png new file mode 100644 index 00000000..9aeeaeb7 --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_0.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:9b12e8934f96e2eb37a173f378621bdff9039d5a0f4c06ce52e051a53b87708d +size 90 diff --git a/assets/minecraft/textures/particle/leaf_1.png b/assets/minecraft/textures/particle/leaf_1.png new file mode 100644 index 00000000..6e48b512 --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_1.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:32196809dad8e56155d211470301bdf37381171278e990ee436e2e7d5f3a9ef6 +size 92 diff --git a/assets/minecraft/textures/particle/leaf_10.png b/assets/minecraft/textures/particle/leaf_10.png new file mode 100644 index 00000000..1fc5d7bc --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_10.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:8886f315a6e9bb5dc75f590c4856d59a3c00ce27b34b9960f80f36381606710a +size 94 diff --git a/assets/minecraft/textures/particle/leaf_11.png b/assets/minecraft/textures/particle/leaf_11.png new file mode 100644 index 00000000..b319100f --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_11.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ceea23d422ae250074ff19506d17a1162a9364142961b6225da524a7345319b9 +size 93 diff --git a/assets/minecraft/textures/particle/leaf_2.png b/assets/minecraft/textures/particle/leaf_2.png new file mode 100644 index 00000000..b8abf967 --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_2.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:a233a2f58755d28eb64f6e0a43d1a68ac4ef45932d6425c06019e422b4fbd8ff +size 94 diff --git a/assets/minecraft/textures/particle/leaf_3.png b/assets/minecraft/textures/particle/leaf_3.png new file mode 100644 index 00000000..db0b41f6 --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_3.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:852122041345064c49c2ca49100f8e18f6578c1e6bbc8624267c779ddb9ee950 +size 93 diff --git a/assets/minecraft/textures/particle/leaf_4.png b/assets/minecraft/textures/particle/leaf_4.png new file mode 100644 index 00000000..38534a0e --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_4.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20fea4ec7d5e6d2f96b8be1256b0cfe0d3b965cbdbe76da6b0fbeccd0fa1eddd +size 90 diff --git a/assets/minecraft/textures/particle/leaf_5.png b/assets/minecraft/textures/particle/leaf_5.png new file mode 100644 index 00000000..a34c773c --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_5.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:673031686a603b9f3a769006fecad747e06729e66f2eb8ee87212053d5c37860 +size 92 diff --git a/assets/minecraft/textures/particle/leaf_6.png b/assets/minecraft/textures/particle/leaf_6.png new file mode 100644 index 00000000..2e065738 --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_6.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:b69f4a6473226248c010b4dad63e7d036bb59a140ee18f614b843e655e725bbf +size 94 diff --git a/assets/minecraft/textures/particle/leaf_7.png b/assets/minecraft/textures/particle/leaf_7.png new file mode 100644 index 00000000..6e80e038 --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_7.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:3b4084542edd97aacd8d48d4ba31a20258bb8610faaf956f64b3d6137eb3c75c +size 93 diff --git a/assets/minecraft/textures/particle/leaf_8.png b/assets/minecraft/textures/particle/leaf_8.png new file mode 100644 index 00000000..51ab25cb --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_8.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:f53ff0892ec2f42a3e035ca43aa2289283895f23b0d6523f0c12dc1e7da65896 +size 90 diff --git a/assets/minecraft/textures/particle/leaf_9.png b/assets/minecraft/textures/particle/leaf_9.png new file mode 100644 index 00000000..d45ee348 --- /dev/null +++ b/assets/minecraft/textures/particle/leaf_9.png @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:ba90e27854b52f3ae0a3b41b69a3e0f3e15e5a17e8aedbcdbd2379334677cfa1 +size 92 diff --git a/com/mojang/blaze3d/GpuOutOfMemoryException.java b/com/mojang/blaze3d/GpuOutOfMemoryException.java new file mode 100644 index 00000000..b286d8a3 --- /dev/null +++ b/com/mojang/blaze3d/GpuOutOfMemoryException.java @@ -0,0 +1,11 @@ +package com.mojang.blaze3d; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +public class GpuOutOfMemoryException extends RuntimeException { + public GpuOutOfMemoryException(String message) { + super(message); + } +} diff --git a/com/mojang/blaze3d/TracyFrameCapture.java b/com/mojang/blaze3d/TracyFrameCapture.java index 979b0c2a..a230141e 100644 --- a/com/mojang/blaze3d/TracyFrameCapture.java +++ b/com/mojang/blaze3d/TracyFrameCapture.java @@ -3,13 +3,18 @@ package com.mojang.blaze3d; import com.mojang.blaze3d.buffers.BufferType; import com.mojang.blaze3d.buffers.BufferUsage; import com.mojang.blaze3d.buffers.GpuBuffer; -import com.mojang.blaze3d.buffers.GpuFence; import com.mojang.blaze3d.pipeline.RenderTarget; -import com.mojang.blaze3d.pipeline.TextureTarget; -import com.mojang.blaze3d.platform.GlStateManager; +import com.mojang.blaze3d.systems.CommandEncoder; +import com.mojang.blaze3d.systems.RenderPass; +import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.textures.TextureFormat; +import com.mojang.blaze3d.vertex.VertexFormat; import com.mojang.jtracy.TracyClient; +import java.util.OptionalInt; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.RenderPipelines; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) @@ -21,12 +26,13 @@ public class TracyFrameCapture implements AutoCloseable { private int targetHeight; private int width; private int height; - private final RenderTarget frameBuffer = new TextureTarget(320, 180, false); - private final GpuBuffer pixelbuffer = new GpuBuffer(BufferType.PIXEL_PACK, BufferUsage.STREAM_READ, 0); @Nullable - private GpuFence fence; + private GpuTexture frameBuffer; + @Nullable + private GpuBuffer pixelbuffer; private int lastCaptureDelay; private boolean capturedThisFrame; + private TracyFrameCapture.Status status = TracyFrameCapture.Status.WAITING_FOR_CAPTURE; private void resize(int width, int height) { float f = (float)width / height; @@ -45,17 +51,26 @@ public class TracyFrameCapture implements AutoCloseable { if (this.width != width || this.height != height) { this.width = width; this.height = height; - this.frameBuffer.resize(width, height); - this.pixelbuffer.resize(width * height * 4); - if (this.fence != null) { - this.fence.close(); - this.fence = null; + if (this.frameBuffer != null) { + this.frameBuffer.close(); } + + this.frameBuffer = RenderSystem.getDevice().createTexture("Tracy Frame Capture", TextureFormat.RGBA8, width, height, 1); + if (this.pixelbuffer != null) { + this.pixelbuffer.close(); + } + + this.pixelbuffer = RenderSystem.getDevice() + .createBuffer(() -> "Tracy Frame Capture buffer", BufferType.PIXEL_PACK, BufferUsage.STREAM_READ, width * height * 4); } } public void capture(RenderTarget renderTarget) { - if (this.fence == null && !this.capturedThisFrame) { + if (this.status == TracyFrameCapture.Status.WAITING_FOR_CAPTURE + && !this.capturedThisFrame + && renderTarget.getColorTexture() != null + && this.pixelbuffer != null + && this.frameBuffer != null) { this.capturedThisFrame = true; if (renderTarget.width != this.targetWidth || renderTarget.height != this.targetHeight) { this.targetWidth = renderTarget.width; @@ -63,30 +78,30 @@ public class TracyFrameCapture implements AutoCloseable { this.resize(this.targetWidth, this.targetHeight); } - GlStateManager._glBindFramebuffer(36009, this.frameBuffer.frameBufferId); - GlStateManager._glBindFramebuffer(36008, renderTarget.frameBufferId); - GlStateManager._glBlitFrameBuffer(0, 0, renderTarget.width, renderTarget.height, 0, 0, this.width, this.height, 16384, 9729); - GlStateManager._glBindFramebuffer(36008, 0); - GlStateManager._glBindFramebuffer(36009, 0); - this.pixelbuffer.bind(); - GlStateManager._glBindFramebuffer(36008, this.frameBuffer.frameBufferId); - GlStateManager._readPixels(0, 0, this.width, this.height, 6408, 5121, 0L); - GlStateManager._glBindFramebuffer(36008, 0); - this.fence = new GpuFence(); + this.status = TracyFrameCapture.Status.WAITING_FOR_COPY; + CommandEncoder commandEncoder = RenderSystem.getDevice().createCommandEncoder(); + RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(VertexFormat.Mode.QUADS); + GpuBuffer gpuBuffer = autoStorageIndexBuffer.getBuffer(6); + + try (RenderPass renderPass = RenderSystem.getDevice().createCommandEncoder().createRenderPass(this.frameBuffer, OptionalInt.empty())) { + renderPass.setPipeline(RenderPipelines.TRACY_BLIT); + renderPass.setVertexBuffer(0, RenderSystem.getQuadVertexBuffer()); + renderPass.setIndexBuffer(gpuBuffer, autoStorageIndexBuffer.type()); + renderPass.bindSampler("InSampler", renderTarget.getColorTexture()); + renderPass.drawIndexed(0, 6); + } + + commandEncoder.copyTextureToBuffer(this.frameBuffer, this.pixelbuffer, 0, () -> this.status = TracyFrameCapture.Status.WAITING_FOR_UPLOAD, 0); this.lastCaptureDelay = 0; } } public void upload() { - if (this.fence != null) { - if (this.fence.awaitCompletion(0L)) { - this.fence = null; + if (this.status == TracyFrameCapture.Status.WAITING_FOR_UPLOAD && this.pixelbuffer != null) { + this.status = TracyFrameCapture.Status.WAITING_FOR_CAPTURE; - try (GpuBuffer.ReadView readView = this.pixelbuffer.read()) { - if (readView != null) { - TracyClient.frameImage(readView.data(), this.width, this.height, this.lastCaptureDelay, true); - } - } + try (GpuBuffer.ReadView readView = RenderSystem.getDevice().createCommandEncoder().readBuffer(this.pixelbuffer)) { + TracyClient.frameImage(readView.data(), this.width, this.height, this.lastCaptureDelay, true); } } } @@ -98,12 +113,19 @@ public class TracyFrameCapture implements AutoCloseable { } public void close() { - if (this.fence != null) { - this.fence.close(); - this.fence = null; + if (this.frameBuffer != null) { + this.frameBuffer.close(); } - this.pixelbuffer.close(); - this.frameBuffer.destroyBuffers(); + if (this.pixelbuffer != null) { + this.pixelbuffer.close(); + } + } + + @Environment(EnvType.CLIENT) + static enum Status { + WAITING_FOR_CAPTURE, + WAITING_FOR_COPY, + WAITING_FOR_UPLOAD; } } diff --git a/com/mojang/blaze3d/audio/Library.java b/com/mojang/blaze3d/audio/Library.java index beae77f2..ca7c7da7 100644 --- a/com/mojang/blaze3d/audio/Library.java +++ b/com/mojang/blaze3d/audio/Library.java @@ -22,7 +22,6 @@ import org.lwjgl.openal.ALC11; import org.lwjgl.openal.ALCCapabilities; import org.lwjgl.openal.ALCapabilities; import org.lwjgl.openal.ALUtil; -import org.lwjgl.openal.SOFTHRTF; import org.lwjgl.system.MemoryStack; import org.slf4j.Logger; @@ -86,10 +85,8 @@ public class Library { } else if (!aLCCapabilities.OpenALC11) { throw new IllegalStateException("OpenAL 1.1 not supported"); } else { - this.setHrtf(aLCCapabilities.ALC_SOFT_HRTF && enableHrtf); - try (MemoryStack memoryStack = MemoryStack.stackPush()) { - IntBuffer intBuffer = memoryStack.callocInt(3).put(6554).put(1).put(0).flip(); + IntBuffer intBuffer = this.createAttributes(memoryStack, aLCCapabilities.ALC_SOFT_HRTF && enableHrtf); this.context = ALC10.alcCreateContext(this.currentDevice, intBuffer); } @@ -120,21 +117,17 @@ public class Library { } } - /** - * Sets the HRTF (head-related transfer function) for spatial audio, if it is supported by the current device. - * - * @param enableHrtf Whether to enable HRTF. - */ - private void setHrtf(boolean enableHrtf) { - int i = ALC10.alcGetInteger(this.currentDevice, 6548); - if (i > 0) { - try (MemoryStack memoryStack = MemoryStack.stackPush()) { - IntBuffer intBuffer = memoryStack.callocInt(10).put(6546).put(enableHrtf ? 1 : 0).put(6550).put(0).put(0).flip(); - if (!SOFTHRTF.alcResetDeviceSOFT(this.currentDevice, intBuffer)) { - LOGGER.warn("Failed to reset device: {}", ALC10.alcGetString(this.currentDevice, ALC10.alcGetError(this.currentDevice))); - } - } + private IntBuffer createAttributes(MemoryStack memoryStack, boolean enableHrtf) { + int i = 5; + IntBuffer intBuffer = memoryStack.callocInt(11); + int j = ALC10.alcGetInteger(this.currentDevice, 6548); + if (j > 0) { + intBuffer.put(6546).put(enableHrtf ? 1 : 0); + intBuffer.put(6550).put(0); } + + intBuffer.put(6554).put(1); + return intBuffer.put(0).flip(); } /** diff --git a/com/mojang/blaze3d/buffers/BufferType.java b/com/mojang/blaze3d/buffers/BufferType.java index 0c60f932..34539b9e 100644 --- a/com/mojang/blaze3d/buffers/BufferType.java +++ b/com/mojang/blaze3d/buffers/BufferType.java @@ -1,21 +1,17 @@ package com.mojang.blaze3d.buffers; +import com.mojang.blaze3d.DontObfuscate; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @Environment(EnvType.CLIENT) +@DontObfuscate public enum BufferType { - VERTICES(34962), - INDICES(34963), - PIXEL_PACK(35051), - COPY_READ(36662), - COPY_WRITE(36663), - PIXEL_UNPACK(35052), - UNIFORM(35345); - - final int id; - - private BufferType(final int id) { - this.id = id; - } + VERTICES, + INDICES, + PIXEL_PACK, + COPY_READ, + COPY_WRITE, + PIXEL_UNPACK, + UNIFORM; } diff --git a/com/mojang/blaze3d/buffers/BufferUsage.java b/com/mojang/blaze3d/buffers/BufferUsage.java index a140bd0a..db4d1de6 100644 --- a/com/mojang/blaze3d/buffers/BufferUsage.java +++ b/com/mojang/blaze3d/buffers/BufferUsage.java @@ -1,27 +1,35 @@ package com.mojang.blaze3d.buffers; +import com.mojang.blaze3d.DontObfuscate; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @Environment(EnvType.CLIENT) +@DontObfuscate public enum BufferUsage { - DYNAMIC_WRITE(35048, false, true), - STATIC_WRITE(35044, false, true), - STREAM_WRITE(35040, false, true), - STATIC_READ(35045, true, false), - DYNAMIC_READ(35049, true, false), - STREAM_READ(35041, true, false), - DYNAMIC_COPY(35050, false, false), - STATIC_COPY(35046, false, false), - STREAM_COPY(35042, false, false); + DYNAMIC_WRITE(false, true), + STATIC_WRITE(false, true), + STREAM_WRITE(false, true), + STATIC_READ(true, false), + DYNAMIC_READ(true, false), + STREAM_READ(true, false), + DYNAMIC_COPY(false, false), + STATIC_COPY(false, false), + STREAM_COPY(false, false); - final int id; final boolean readable; final boolean writable; - private BufferUsage(final int id, final boolean readable, final boolean writable) { - this.id = id; - this.readable = readable; - this.writable = writable; + private BufferUsage(final boolean bl, final boolean bl2) { + this.readable = bl; + this.writable = bl2; + } + + public boolean isReadable() { + return this.readable; + } + + public boolean isWritable() { + return this.writable; } } diff --git a/com/mojang/blaze3d/buffers/GpuBuffer.java b/com/mojang/blaze3d/buffers/GpuBuffer.java index 6ee096a5..ab22827a 100644 --- a/com/mojang/blaze3d/buffers/GpuBuffer.java +++ b/com/mojang/blaze3d/buffers/GpuBuffer.java @@ -1,136 +1,44 @@ package com.mojang.blaze3d.buffers; -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.jtracy.MemoryPool; -import com.mojang.jtracy.TracyClient; +import com.mojang.blaze3d.DontObfuscate; import java.nio.ByteBuffer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) -public class GpuBuffer implements AutoCloseable { - private static final MemoryPool MEMORY_POOl = TracyClient.createMemoryPool("GPU Buffers"); +@DontObfuscate +public abstract class GpuBuffer implements AutoCloseable { private final BufferType type; private final BufferUsage usage; - private boolean closed; - private boolean initialized = false; - public final int handle; public int size; - public GpuBuffer(BufferType type, BufferUsage usage, int size) { - this.type = type; - this.size = size; - this.usage = usage; - this.handle = GlStateManager._glGenBuffers(); + public GpuBuffer(BufferType bufferType, BufferUsage bufferUsage, int i) { + this.type = bufferType; + this.size = i; + this.usage = bufferUsage; } - public GpuBuffer(BufferType type, BufferUsage usage, ByteBuffer buffer) { - this(type, usage, buffer.remaining()); - this.write(buffer, 0); + public int size() { + return this.size; } - public void resize(int size) { - if (this.closed) { - throw new IllegalStateException("Buffer already closed"); - } else { - if (this.initialized) { - MEMORY_POOl.free(this.handle); - } - - this.size = size; - if (this.usage.writable) { - this.initialized = false; - } else { - this.bind(); - GlStateManager._glBufferData(this.type.id, size, this.usage.id); - MEMORY_POOl.malloc(this.handle, size); - this.initialized = true; - } - } + public BufferType type() { + return this.type; } - public void write(ByteBuffer buffer, int offset) { - if (this.closed) { - throw new IllegalStateException("Buffer already closed"); - } else if (!this.usage.writable) { - throw new IllegalStateException("Buffer is not writable"); - } else { - int i = buffer.remaining(); - if (i + offset > this.size) { - throw new IllegalArgumentException( - "Cannot write more data than this buffer can hold (attempting to write " + i + " bytes at offset " + offset + " to " + this.size + " size buffer)" - ); - } else { - this.bind(); - if (this.initialized) { - GlStateManager._glBufferSubData(this.type.id, offset, buffer); - } else if (offset == 0 && i == this.size) { - GlStateManager._glBufferData(this.type.id, buffer, this.usage.id); - MEMORY_POOl.malloc(this.handle, this.size); - this.initialized = true; - } else { - GlStateManager._glBufferData(this.type.id, this.size, this.usage.id); - GlStateManager._glBufferSubData(this.type.id, offset, buffer); - MEMORY_POOl.malloc(this.handle, this.size); - this.initialized = true; - } - } - } + public BufferUsage usage() { + return this.usage; } - @Nullable - public GpuBuffer.ReadView read() { - return this.read(0, this.size); - } + public abstract boolean isClosed(); - @Nullable - public GpuBuffer.ReadView read(int offset, int length) { - if (this.closed) { - throw new IllegalStateException("Buffer already closed"); - } else if (!this.usage.readable) { - throw new IllegalStateException("Buffer is not readable"); - } else if (offset + length > this.size) { - throw new IllegalArgumentException( - "Cannot read more data than this buffer can hold (attempting to read " + length + " bytes at offset " + offset + " from " + this.size + " size buffer)" - ); - } else { - this.bind(); - ByteBuffer byteBuffer = GlStateManager._glMapBufferRange(this.type.id, offset, length, 1); - return byteBuffer == null ? null : new GpuBuffer.ReadView(this.type.id, byteBuffer); - } - } - - public void close() { - if (!this.closed) { - this.closed = true; - GlStateManager._glDeleteBuffers(this.handle); - if (this.initialized) { - MEMORY_POOl.free(this.handle); - } - } - } - - public void bind() { - GlStateManager._glBindBuffer(this.type.id, this.handle); - } + public abstract void close(); @Environment(EnvType.CLIENT) - public static class ReadView implements AutoCloseable { - private final int target; - private final ByteBuffer data; + @DontObfuscate + public interface ReadView extends AutoCloseable { + ByteBuffer data(); - protected ReadView(int target, ByteBuffer data) { - this.target = target; - this.data = data; - } - - public ByteBuffer data() { - return this.data; - } - - public void close() { - GlStateManager._glUnmapBuffer(this.target); - } + void close(); } } diff --git a/com/mojang/blaze3d/buffers/GpuFence.java b/com/mojang/blaze3d/buffers/GpuFence.java index 55fdbd20..708688ba 100644 --- a/com/mojang/blaze3d/buffers/GpuFence.java +++ b/com/mojang/blaze3d/buffers/GpuFence.java @@ -1,10 +1,12 @@ package com.mojang.blaze3d.buffers; -import com.mojang.blaze3d.platform.GlStateManager; +import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.opengl.GlStateManager; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @Environment(EnvType.CLIENT) +@DontObfuscate public class GpuFence implements AutoCloseable { private long handle = GlStateManager._glFenceSync(37143, 0); @@ -15,11 +17,11 @@ public class GpuFence implements AutoCloseable { } } - public boolean awaitCompletion(long timeout) { + public boolean awaitCompletion(long l) { if (this.handle == 0L) { return true; } else { - int i = GlStateManager._glClientWaitSync(this.handle, 0, timeout); + int i = GlStateManager._glClientWaitSync(this.handle, 0, l); if (i == 37147) { return false; } else if (i == 37149) { diff --git a/com/mojang/blaze3d/font/SheetGlyphInfo.java b/com/mojang/blaze3d/font/SheetGlyphInfo.java index 289cf864..958d7499 100644 --- a/com/mojang/blaze3d/font/SheetGlyphInfo.java +++ b/com/mojang/blaze3d/font/SheetGlyphInfo.java @@ -1,5 +1,6 @@ package com.mojang.blaze3d.font; +import com.mojang.blaze3d.textures.GpuTexture; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -9,7 +10,7 @@ public interface SheetGlyphInfo { int getPixelHeight(); - void upload(int xOffset, int yOffset); + void upload(int x, int y, GpuTexture texture); boolean isColored(); diff --git a/com/mojang/blaze3d/opengl/AbstractUniform.java b/com/mojang/blaze3d/opengl/AbstractUniform.java new file mode 100644 index 00000000..2328e30c --- /dev/null +++ b/com/mojang/blaze3d/opengl/AbstractUniform.java @@ -0,0 +1,49 @@ +package com.mojang.blaze3d.opengl; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.joml.Matrix4f; +import org.joml.Vector3f; +import org.joml.Vector4f; + +@Environment(EnvType.CLIENT) +public class AbstractUniform { + public void set(float value) { + } + + public void set(float value1, float value2) { + } + + public void set(float value1, float value2, float value3) { + } + + public void set(float value1, float value2, float value3, float value4) { + } + + public void set(int value) { + } + + public void set(int value1, int value2) { + } + + public void set(int value1, int value2, int value3) { + } + + public void set(int value1, int value2, int value3, int value4) { + } + + public void set(float[] values) { + } + + public void set(int[] values) { + } + + public void set(Vector3f values) { + } + + public void set(Vector4f values) { + } + + public void set(Matrix4f values) { + } +} diff --git a/com/mojang/blaze3d/opengl/DirectStateAccess.java b/com/mojang/blaze3d/opengl/DirectStateAccess.java new file mode 100644 index 00000000..a9982e63 --- /dev/null +++ b/com/mojang/blaze3d/opengl/DirectStateAccess.java @@ -0,0 +1,84 @@ +package com.mojang.blaze3d.opengl; + +import java.util.Set; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.lwjgl.opengl.ARBDirectStateAccess; +import org.lwjgl.opengl.GLCapabilities; + +@Environment(EnvType.CLIENT) +public abstract class DirectStateAccess { + public static DirectStateAccess create(GLCapabilities capabilities, Set enabledExtensions) { + if (capabilities.GL_ARB_direct_state_access && GlDevice.USE_GL_ARB_direct_state_access) { + enabledExtensions.add("GL_ARB_direct_state_access"); + return new DirectStateAccess.Core(); + } else { + return new DirectStateAccess.Emulated(); + } + } + + abstract int createFrameBufferObject(); + + abstract void bindFrameBufferTextures(int frameBuffer, int colorTexture, int depthTexture, int level, int target); + + abstract void blitFrameBuffers( + int readFrameBuffer, int drawFrameBuffer, int srcX0, int srcY0, int srcX1, int srcY1, int destX0, int destY0, int destX1, int destY1, int mask, int filter + ); + + @Environment(EnvType.CLIENT) + static class Core extends DirectStateAccess { + @Override + public int createFrameBufferObject() { + return ARBDirectStateAccess.glCreateFramebuffers(); + } + + @Override + public void bindFrameBufferTextures(int frameBuffer, int colorTexture, int depthTexture, int level, int target) { + ARBDirectStateAccess.glNamedFramebufferTexture(frameBuffer, 36064, colorTexture, level); + ARBDirectStateAccess.glNamedFramebufferTexture(frameBuffer, 36096, depthTexture, level); + if (target != 0) { + GlStateManager._glBindFramebuffer(target, frameBuffer); + } + } + + @Override + public void blitFrameBuffers( + int readFrameBuffer, int drawFrameBuffer, int srcX0, int srcY0, int srcX1, int srcY1, int destX0, int destY0, int destX1, int destY1, int mask, int filter + ) { + ARBDirectStateAccess.glBlitNamedFramebuffer(readFrameBuffer, drawFrameBuffer, srcX0, srcY0, srcX1, srcY1, destX0, destY0, destX1, destY1, mask, filter); + } + } + + @Environment(EnvType.CLIENT) + static class Emulated extends DirectStateAccess { + @Override + public int createFrameBufferObject() { + return GlStateManager.glGenFramebuffers(); + } + + @Override + public void bindFrameBufferTextures(int frameBuffer, int colorTexture, int depthTexture, int level, int target) { + int i = target == 0 ? '販' : target; + int j = GlStateManager.getFrameBuffer(i); + GlStateManager._glBindFramebuffer(i, frameBuffer); + GlStateManager._glFramebufferTexture2D(i, 36064, 3553, colorTexture, level); + GlStateManager._glFramebufferTexture2D(i, 36096, 3553, depthTexture, level); + if (target == 0) { + GlStateManager._glBindFramebuffer(i, j); + } + } + + @Override + public void blitFrameBuffers( + int readFrameBuffer, int drawFrameBuffer, int srcX0, int srcY0, int srcX1, int srcY1, int destX0, int destY0, int destX1, int destY1, int mask, int filter + ) { + int i = GlStateManager.getFrameBuffer(36008); + int j = GlStateManager.getFrameBuffer(36009); + GlStateManager._glBindFramebuffer(36008, readFrameBuffer); + GlStateManager._glBindFramebuffer(36009, drawFrameBuffer); + GlStateManager._glBlitFrameBuffer(srcX0, srcY0, srcX1, srcY1, destX0, destY0, destX1, destY1, mask, filter); + GlStateManager._glBindFramebuffer(36008, i); + GlStateManager._glBindFramebuffer(36009, j); + } + } +} diff --git a/com/mojang/blaze3d/opengl/GlBuffer.java b/com/mojang/blaze3d/opengl/GlBuffer.java new file mode 100644 index 00000000..9eb4c848 --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlBuffer.java @@ -0,0 +1,79 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.jtracy.MemoryPool; +import com.mojang.jtracy.TracyClient; +import java.nio.ByteBuffer; +import java.util.function.Supplier; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public class GlBuffer extends GpuBuffer { + protected static final MemoryPool MEMORY_POOl = TracyClient.createMemoryPool("GPU Buffers"); + protected boolean closed; + protected boolean initialized = false; + @Nullable + protected final Supplier label; + protected final int handle; + + protected GlBuffer(GlDebugLabel debugLabel, @Nullable Supplier label, BufferType type, BufferUsage usage, int size, int handle) { + super(type, usage, size); + this.label = label; + this.handle = handle; + if (usage.isReadable()) { + GlStateManager._glBindBuffer(GlConst.toGl(type), handle); + GlStateManager._glBufferData(GlConst.toGl(type), size, GlConst.toGl(usage)); + MEMORY_POOl.malloc(handle, size); + this.initialized = true; + debugLabel.applyLabel(this); + } + } + + protected void ensureBufferExists() { + if (!this.initialized) { + GlStateManager._glBindBuffer(GlConst.toGl(this.type()), this.handle); + GlStateManager._glBindBuffer(GlConst.toGl(this.type()), 0); + } + } + + @Override + public boolean isClosed() { + return this.closed; + } + + @Override + public void close() { + if (!this.closed) { + this.closed = true; + GlStateManager._glDeleteBuffers(this.handle); + if (this.initialized) { + MEMORY_POOl.free(this.handle); + } + } + } + + @Environment(EnvType.CLIENT) + public static class ReadView implements GpuBuffer.ReadView { + private final int target; + private final ByteBuffer data; + + protected ReadView(int target, ByteBuffer data) { + this.target = target; + this.data = data; + } + + @Override + public ByteBuffer data() { + return this.data; + } + + @Override + public void close() { + GlStateManager._glUnmapBuffer(this.target); + } + } +} diff --git a/com/mojang/blaze3d/opengl/GlCommandEncoder.java b/com/mojang/blaze3d/opengl/GlCommandEncoder.java new file mode 100644 index 00000000..e8c1ccd5 --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlCommandEncoder.java @@ -0,0 +1,712 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.BlendFunction; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.platform.DepthTestFunction; +import com.mojang.blaze3d.platform.NativeImage; +import com.mojang.blaze3d.platform.Window; +import com.mojang.blaze3d.systems.CommandEncoder; +import com.mojang.blaze3d.systems.RenderPass; +import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.vertex.VertexFormat; +import com.mojang.logging.LogUtils; +import it.unimi.dsi.fastutil.ints.IntList; +import java.nio.ByteBuffer; +import java.nio.IntBuffer; +import java.util.Collection; +import java.util.OptionalDouble; +import java.util.OptionalInt; +import java.util.function.Consumer; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.Minecraft; +import net.minecraft.util.ARGB; +import org.jetbrains.annotations.Nullable; +import org.lwjgl.opengl.GL11; +import org.slf4j.Logger; + +@Environment(EnvType.CLIENT) +public class GlCommandEncoder implements CommandEncoder { + private static final Logger LOGGER = LogUtils.getLogger(); + private final GlDevice device; + private final int readFbo; + private final int drawFbo; + @Nullable + private RenderPipeline lastPipeline; + private boolean inRenderPass; + @Nullable + private GlProgram lastProgram; + + protected GlCommandEncoder(GlDevice device) { + this.device = device; + this.readFbo = device.directStateAccess().createFrameBufferObject(); + this.drawFbo = device.directStateAccess().createFrameBufferObject(); + } + + @Override + public RenderPass createRenderPass(GpuTexture gpuTexture, OptionalInt optionalInt) { + return this.createRenderPass(gpuTexture, optionalInt, null, OptionalDouble.empty()); + } + + @Override + public RenderPass createRenderPass(GpuTexture gpuTexture, OptionalInt optionalInt, @Nullable GpuTexture gpuTexture2, OptionalDouble optionalDouble) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before creating a new one!"); + } else { + if (optionalDouble.isPresent() && gpuTexture2 == null) { + LOGGER.warn("Depth clear value was provided but no depth texture is being used"); + } + + if (gpuTexture.isClosed()) { + throw new IllegalStateException("Color texture is closed"); + } else if (gpuTexture2 != null && gpuTexture2.isClosed()) { + throw new IllegalStateException("Depth texture is closed"); + } else { + this.inRenderPass = true; + int i = ((GlTexture)gpuTexture).getFbo(this.device.directStateAccess(), gpuTexture2); + GlStateManager._glBindFramebuffer(36160, i); + int j = 0; + if (optionalInt.isPresent()) { + int k = optionalInt.getAsInt(); + GL11.glClearColor(ARGB.redFloat(k), ARGB.greenFloat(k), ARGB.blueFloat(k), ARGB.alphaFloat(k)); + j |= 16384; + } + + if (gpuTexture2 != null && optionalDouble.isPresent()) { + GL11.glClearDepth(optionalDouble.getAsDouble()); + j |= 256; + } + + if (j != 0) { + GlStateManager._disableScissorTest(); + GlStateManager._depthMask(true); + GlStateManager._colorMask(true, true, true, true); + GlStateManager._clear(j); + } + + GlStateManager._viewport(0, 0, gpuTexture.getWidth(0), gpuTexture.getHeight(0)); + this.lastPipeline = null; + return new GlRenderPass(this, gpuTexture2 != null); + } + } + } + + @Override + public void clearColorTexture(GpuTexture gpuTexture, int i) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before creating a new one!"); + } else if (!gpuTexture.getFormat().hasColorAspect()) { + throw new IllegalStateException("Trying to clear a non-color texture as color"); + } else if (gpuTexture.isClosed()) { + throw new IllegalStateException("Color texture is closed"); + } else { + this.device.directStateAccess().bindFrameBufferTextures(this.drawFbo, ((GlTexture)gpuTexture).id, 0, 0, 36160); + GL11.glClearColor(ARGB.redFloat(i), ARGB.greenFloat(i), ARGB.blueFloat(i), ARGB.alphaFloat(i)); + GlStateManager._disableScissorTest(); + GlStateManager._colorMask(true, true, true, true); + GlStateManager._clear(16384); + GlStateManager._glFramebufferTexture2D(36160, 36064, 3553, 0, 0); + GlStateManager._glBindFramebuffer(36160, 0); + } + } + + @Override + public void clearColorAndDepthTextures(GpuTexture gpuTexture, int i, GpuTexture gpuTexture2, double d) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before creating a new one!"); + } else if (!gpuTexture.getFormat().hasColorAspect()) { + throw new IllegalStateException("Trying to clear a non-color texture as color"); + } else if (!gpuTexture2.getFormat().hasDepthAspect()) { + throw new IllegalStateException("Trying to clear a non-depth texture as depth"); + } else if (gpuTexture.isClosed()) { + throw new IllegalStateException("Color texture is closed"); + } else if (gpuTexture2.isClosed()) { + throw new IllegalStateException("Depth texture is closed"); + } else { + int j = ((GlTexture)gpuTexture).getFbo(this.device.directStateAccess(), gpuTexture2); + GlStateManager._glBindFramebuffer(36160, j); + GlStateManager._disableScissorTest(); + GL11.glClearDepth(d); + GL11.glClearColor(ARGB.redFloat(i), ARGB.greenFloat(i), ARGB.blueFloat(i), ARGB.alphaFloat(i)); + GlStateManager._depthMask(true); + GlStateManager._colorMask(true, true, true, true); + GlStateManager._clear(16640); + GlStateManager._glBindFramebuffer(36160, 0); + } + } + + @Override + public void clearDepthTexture(GpuTexture gpuTexture, double d) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before creating a new one!"); + } else if (!gpuTexture.getFormat().hasDepthAspect()) { + throw new IllegalStateException("Trying to clear a non-depth texture as depth"); + } else if (gpuTexture.isClosed()) { + throw new IllegalStateException("Depth texture is closed"); + } else { + this.device.directStateAccess().bindFrameBufferTextures(this.drawFbo, 0, ((GlTexture)gpuTexture).id, 0, 36160); + GL11.glDrawBuffer(0); + GL11.glClearDepth(d); + GlStateManager._depthMask(true); + GlStateManager._disableScissorTest(); + GlStateManager._clear(256); + GL11.glDrawBuffer(36064); + GlStateManager._glFramebufferTexture2D(36160, 36096, 3553, 0, 0); + GlStateManager._glBindFramebuffer(36160, 0); + } + } + + @Override + public void writeToBuffer(GpuBuffer gpuBuffer, ByteBuffer byteBuffer, int i) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before performing additional commands"); + } else { + GlBuffer glBuffer = (GlBuffer)gpuBuffer; + if (glBuffer.closed) { + throw new IllegalStateException("Buffer already closed"); + } else if (!glBuffer.usage().isWritable()) { + throw new IllegalStateException("Buffer is not writable"); + } else { + int j = byteBuffer.remaining(); + if (j + i > glBuffer.size) { + throw new IllegalArgumentException( + "Cannot write more data than this buffer can hold (attempting to write " + j + " bytes at offset " + i + " to " + glBuffer.size + " size buffer)" + ); + } else { + GlStateManager._glBindBuffer(GlConst.toGl(glBuffer.type()), glBuffer.handle); + if (glBuffer.initialized) { + GlStateManager._glBufferSubData(GlConst.toGl(glBuffer.type()), i, byteBuffer); + } else if (i == 0 && j == glBuffer.size) { + GlStateManager._glBufferData(GlConst.toGl(glBuffer.type()), byteBuffer, GlConst.toGl(glBuffer.usage())); + GlBuffer.MEMORY_POOl.malloc(glBuffer.handle, glBuffer.size); + glBuffer.initialized = true; + this.device.debugLabels().applyLabel(glBuffer); + } else { + GlStateManager._glBufferData(GlConst.toGl(glBuffer.type()), glBuffer.size, GlConst.toGl(glBuffer.usage())); + GlStateManager._glBufferSubData(GlConst.toGl(glBuffer.type()), i, byteBuffer); + GlBuffer.MEMORY_POOl.malloc(glBuffer.handle, glBuffer.size); + glBuffer.initialized = true; + this.device.debugLabels().applyLabel(glBuffer); + } + } + } + } + } + + @Override + public GpuBuffer.ReadView readBuffer(GpuBuffer gpuBuffer) { + return this.readBuffer(gpuBuffer, 0, gpuBuffer.size()); + } + + @Override + public GpuBuffer.ReadView readBuffer(GpuBuffer gpuBuffer, int i, int j) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before performing additional commands"); + } else { + GlBuffer glBuffer = (GlBuffer)gpuBuffer; + if (glBuffer.closed) { + throw new IllegalStateException("Buffer already closed"); + } else if (!glBuffer.usage().isReadable()) { + throw new IllegalStateException("Buffer is not readable"); + } else if (i + j > glBuffer.size) { + throw new IllegalArgumentException( + "Cannot read more data than this buffer can hold (attempting to read " + j + " bytes at offset " + i + " from " + glBuffer.size + " size buffer)" + ); + } else { + GlStateManager.clearGlErrors(); + GlStateManager._glBindBuffer(GlConst.toGl(glBuffer.type()), glBuffer.handle); + ByteBuffer byteBuffer = GlStateManager._glMapBufferRange(GlConst.toGl(glBuffer.type()), i, j, 1); + if (byteBuffer == null) { + throw new IllegalStateException("Can't read buffer, opengl error " + GlStateManager._getError()); + } else { + return new GlBuffer.ReadView(GlConst.toGl(glBuffer.type()), byteBuffer); + } + } + } + } + + @Override + public void writeToTexture(GpuTexture gpuTexture, NativeImage nativeImage) { + int i = gpuTexture.getWidth(0); + int j = gpuTexture.getHeight(0); + if (nativeImage.getWidth() != i || nativeImage.getHeight() != j) { + throw new IllegalArgumentException( + "Cannot replace texture of size " + i + "x" + j + " with image of size " + nativeImage.getWidth() + "x" + nativeImage.getHeight() + ); + } else if (gpuTexture.isClosed()) { + throw new IllegalStateException("Destination texture is closed"); + } else { + this.writeToTexture(gpuTexture, nativeImage, 0, 0, 0, i, j, 0, 0); + } + } + + @Override + public void writeToTexture(GpuTexture gpuTexture, NativeImage nativeImage, int i, int j, int k, int l, int m, int n, int o) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before performing additional commands"); + } else if (i >= 0 && i < gpuTexture.getMipLevels()) { + if (n + l > nativeImage.getWidth() || o + m > nativeImage.getHeight()) { + throw new IllegalArgumentException( + "Copy source (" + + nativeImage.getWidth() + + "x" + + nativeImage.getHeight() + + ") is not large enough to read a rectangle of " + + l + + "x" + + m + + " from " + + n + + "x" + + o + ); + } else if (j + l > gpuTexture.getWidth(i) || k + m > gpuTexture.getHeight(i)) { + throw new IllegalArgumentException( + "Dest texture (" + l + "x" + m + ") is not large enough to write a rectangle of " + l + "x" + m + " at " + j + "x" + k + " (at mip level " + i + ")" + ); + } else if (gpuTexture.isClosed()) { + throw new IllegalStateException("Destination texture is closed"); + } else { + GlStateManager._bindTexture(((GlTexture)gpuTexture).id); + GlStateManager._pixelStore(3314, nativeImage.getWidth()); + GlStateManager._pixelStore(3316, n); + GlStateManager._pixelStore(3315, o); + GlStateManager._pixelStore(3317, nativeImage.format().components()); + GlStateManager._texSubImage2D(3553, i, j, k, l, m, GlConst.toGl(nativeImage.format()), 5121, nativeImage.getPointer()); + } + } else { + throw new IllegalArgumentException("Invalid mipLevel " + i + ", must be >= 0 and < " + gpuTexture.getMipLevels()); + } + } + + @Override + public void writeToTexture(GpuTexture gpuTexture, IntBuffer intBuffer, NativeImage.Format format, int i, int j, int k, int l, int m) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before performing additional commands"); + } else if (i >= 0 && i < gpuTexture.getMipLevels()) { + if (l * m > intBuffer.remaining()) { + throw new IllegalArgumentException( + "Copy would overrun the source buffer (remaining length of " + intBuffer.remaining() + ", but copy is " + l + "x" + m + ")" + ); + } else if (j + l > gpuTexture.getWidth(i) || k + m > gpuTexture.getHeight(i)) { + throw new IllegalArgumentException( + "Dest texture (" + + gpuTexture.getWidth(i) + + "x" + + gpuTexture.getHeight(i) + + ") is not large enough to write a rectangle of " + + l + + "x" + + m + + " at " + + j + + "x" + + k + ); + } else if (gpuTexture.isClosed()) { + throw new IllegalStateException("Destination texture is closed"); + } else { + GlStateManager._bindTexture(((GlTexture)gpuTexture).id); + GlStateManager._pixelStore(3314, l); + GlStateManager._pixelStore(3316, 0); + GlStateManager._pixelStore(3315, 0); + GlStateManager._pixelStore(3317, format.components()); + GlStateManager._texSubImage2D(3553, i, j, k, l, m, GlConst.toGl(format), 5121, intBuffer); + } + } else { + throw new IllegalArgumentException("Invalid mipLevel, must be >= 0 and < " + gpuTexture.getMipLevels()); + } + } + + @Override + public void copyTextureToBuffer(GpuTexture gpuTexture, GpuBuffer gpuBuffer, int i, Runnable runnable, int j) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before performing additional commands"); + } else { + this.copyTextureToBuffer(gpuTexture, gpuBuffer, i, runnable, j, 0, 0, gpuTexture.getWidth(j), gpuTexture.getHeight(j)); + } + } + + @Override + public void copyTextureToBuffer(GpuTexture gpuTexture, GpuBuffer gpuBuffer, int i, Runnable runnable, int j, int k, int l, int m, int n) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before performing additional commands"); + } else if (j >= 0 && j < gpuTexture.getMipLevels()) { + if (gpuTexture.getWidth(j) * gpuTexture.getHeight(j) * gpuTexture.getFormat().pixelSize() + i > gpuBuffer.size()) { + throw new IllegalArgumentException( + "Buffer of size " + + gpuBuffer.size() + + " is not large enough to hold " + + m + + "x" + + n + + " pixels (" + + gpuTexture.getFormat().pixelSize() + + " bytes each) starting from offset " + + i + ); + } else if (gpuBuffer.type() != BufferType.PIXEL_PACK) { + throw new IllegalArgumentException("Buffer of type " + gpuBuffer.type() + " cannot be used to retrieve a texture"); + } else if (k + m > gpuTexture.getWidth(j) || l + n > gpuTexture.getHeight(j)) { + throw new IllegalArgumentException( + "Copy source texture (" + + gpuTexture.getWidth(j) + + "x" + + gpuTexture.getHeight(j) + + ") is not large enough to read a rectangle of " + + m + + "x" + + n + + " from " + + k + + "," + + l + ); + } else if (gpuTexture.isClosed()) { + throw new IllegalStateException("Source texture is closed"); + } else if (gpuBuffer.isClosed()) { + throw new IllegalStateException("Destination buffer is closed"); + } else { + GlStateManager.clearGlErrors(); + this.device.directStateAccess().bindFrameBufferTextures(this.readFbo, ((GlTexture)gpuTexture).glId(), 0, j, 36008); + GlStateManager._glBindBuffer(GlConst.toGl(gpuBuffer.type()), ((GlBuffer)gpuBuffer).handle); + GlStateManager._pixelStore(3330, m); + GlStateManager._readPixels(k, l, m, n, GlConst.toGlExternalId(gpuTexture.getFormat()), GlConst.toGlType(gpuTexture.getFormat()), i); + RenderSystem.queueFencedTask(runnable); + GlStateManager._glFramebufferTexture2D(36008, 36064, 3553, 0, j); + GlStateManager._glBindFramebuffer(36008, 0); + GlStateManager._glBindBuffer(GlConst.toGl(gpuBuffer.type()), 0); + int o = GlStateManager._getError(); + if (o != 0) { + throw new IllegalStateException("Couldn't perform copyTobuffer for texture " + gpuTexture.getLabel() + ": GL error " + o); + } + } + } else { + throw new IllegalArgumentException("Invalid mipLevel " + j + ", must be >= 0 and < " + gpuTexture.getMipLevels()); + } + } + + @Override + public void copyTextureToTexture(GpuTexture gpuTexture, GpuTexture gpuTexture2, int i, int j, int k, int l, int m, int n, int o) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before performing additional commands"); + } else if (i >= 0 && i < gpuTexture.getMipLevels() && i < gpuTexture2.getMipLevels()) { + if (j + n > gpuTexture2.getWidth(i) || k + o > gpuTexture2.getHeight(i)) { + throw new IllegalArgumentException( + "Dest texture (" + + gpuTexture2.getWidth(i) + + "x" + + gpuTexture2.getHeight(i) + + ") is not large enough to write a rectangle of " + + n + + "x" + + o + + " at " + + j + + "x" + + k + ); + } else if (l + n > gpuTexture.getWidth(i) || m + o > gpuTexture.getHeight(i)) { + throw new IllegalArgumentException( + "Source texture (" + + gpuTexture.getWidth(i) + + "x" + + gpuTexture.getHeight(i) + + ") is not large enough to read a rectangle of " + + n + + "x" + + o + + " at " + + l + + "x" + + m + ); + } else if (gpuTexture.isClosed()) { + throw new IllegalStateException("Source texture is closed"); + } else if (gpuTexture2.isClosed()) { + throw new IllegalStateException("Destination texture is closed"); + } else { + GlStateManager.clearGlErrors(); + GlStateManager._disableScissorTest(); + boolean bl = gpuTexture.getFormat().hasDepthAspect(); + int p = ((GlTexture)gpuTexture).glId(); + int q = ((GlTexture)gpuTexture2).glId(); + this.device.directStateAccess().bindFrameBufferTextures(this.readFbo, bl ? 0 : p, bl ? p : 0, 0, 0); + this.device.directStateAccess().bindFrameBufferTextures(this.drawFbo, bl ? 0 : q, bl ? q : 0, 0, 0); + this.device.directStateAccess().blitFrameBuffers(this.readFbo, this.drawFbo, l, m, n, o, j, k, n, o, bl ? 256 : 16384, 9728); + int r = GlStateManager._getError(); + if (r != 0) { + throw new IllegalStateException( + "Couldn't perform copyToTexture for texture " + gpuTexture.getLabel() + " to " + gpuTexture2.getLabel() + ": GL error " + r + ); + } + } + } else { + throw new IllegalArgumentException("Invalid mipLevel " + i + ", must be >= 0 and < " + gpuTexture.getMipLevels() + " and < " + gpuTexture2.getMipLevels()); + } + } + + @Override + public void presentTexture(GpuTexture gpuTexture) { + if (this.inRenderPass) { + throw new IllegalStateException("Close the existing render pass before performing additional commands"); + } else if (!gpuTexture.getFormat().hasColorAspect()) { + throw new IllegalStateException("Cannot present a non-color texture!"); + } else { + GlStateManager._disableScissorTest(); + GlStateManager._viewport(0, 0, gpuTexture.getWidth(0), gpuTexture.getHeight(0)); + GlStateManager._depthMask(true); + GlStateManager._colorMask(true, true, true, true); + this.device.directStateAccess().bindFrameBufferTextures(this.drawFbo, ((GlTexture)gpuTexture).glId(), 0, 0, 0); + this.device + .directStateAccess() + .blitFrameBuffers( + this.drawFbo, 0, 0, 0, gpuTexture.getWidth(0), gpuTexture.getHeight(0), 0, 0, gpuTexture.getWidth(0), gpuTexture.getHeight(0), 16384, 9728 + ); + } + } + + protected void executeDrawMultiple( + GlRenderPass renderPass, Collection draws, @Nullable GpuBuffer buffer, @Nullable VertexFormat.IndexType indexType + ) { + if (this.trySetup(renderPass)) { + if (indexType == null) { + indexType = VertexFormat.IndexType.SHORT; + } + + for (RenderPass.Draw draw : draws) { + VertexFormat.IndexType indexType2 = draw.indexType() == null ? indexType : draw.indexType(); + renderPass.setIndexBuffer(draw.indexBuffer() == null ? buffer : draw.indexBuffer(), indexType2); + renderPass.setVertexBuffer(draw.slot(), draw.vertexBuffer()); + if (GlRenderPass.VALIDATION) { + if (renderPass.indexBuffer == null) { + throw new IllegalStateException("Missing index buffer"); + } + + if (renderPass.indexBuffer.isClosed()) { + throw new IllegalStateException("Index buffer has been closed!"); + } + + if (renderPass.vertexBuffers[0] == null) { + throw new IllegalStateException("Missing vertex buffer at slot 0"); + } + + if (renderPass.vertexBuffers[0].isClosed()) { + throw new IllegalStateException("Vertex buffer at slot 0 has been closed!"); + } + } + + Consumer consumer = draw.uniformUploaderConsumer(); + if (consumer != null) { + consumer.accept((RenderPass.UniformUploader)(string, fs) -> { + Uniform uniform = renderPass.pipeline.program().getUniform(string); + if (uniform != null) { + uniform.set(fs); + uniform.upload(); + } + }); + } + + this.drawFromBuffers(renderPass, draw.firstIndex(), draw.indexCount(), indexType2, renderPass.pipeline); + } + } + } + + protected void executeDraw(GlRenderPass renderPass, int firstIndex, int indexCount, @Nullable VertexFormat.IndexType indexType) { + if (this.trySetup(renderPass)) { + if (GlRenderPass.VALIDATION) { + if (indexType != null) { + if (renderPass.indexBuffer == null) { + throw new IllegalStateException("Missing index buffer"); + } + + if (renderPass.indexBuffer.isClosed()) { + throw new IllegalStateException("Index buffer has been closed!"); + } + } + + if (renderPass.vertexBuffers[0] == null) { + throw new IllegalStateException("Missing vertex buffer at slot 0"); + } + + if (renderPass.vertexBuffers[0].isClosed()) { + throw new IllegalStateException("Vertex buffer at slot 0 has been closed!"); + } + } + + this.drawFromBuffers(renderPass, firstIndex, indexCount, indexType, renderPass.pipeline); + } + } + + private void drawFromBuffers(GlRenderPass renderPass, int firstIndex, int indexCount, @Nullable VertexFormat.IndexType indexType, GlRenderPipeline pipeline) { + this.device.vertexArrayCache().bindVertexArray(pipeline.info().getVertexFormat(), (GlBuffer)renderPass.vertexBuffers[0]); + if (indexType != null) { + GlStateManager._glBindBuffer(34963, ((GlBuffer)renderPass.indexBuffer).handle); + GlStateManager._drawElements(GlConst.toGl(pipeline.info().getVertexFormatMode()), indexCount, GlConst.toGl(indexType), (long)firstIndex * indexType.bytes); + } else { + GlStateManager._drawArrays(GlConst.toGl(pipeline.info().getVertexFormatMode()), firstIndex, indexCount); + } + } + + private boolean trySetup(GlRenderPass renderPass) { + if (GlRenderPass.VALIDATION) { + if (renderPass.pipeline == null) { + throw new IllegalStateException("Can't draw without a render pipeline"); + } + + if (renderPass.pipeline.program() == GlProgram.INVALID_PROGRAM) { + throw new IllegalStateException("Pipeline contains invalid shader program"); + } + + for (RenderPipeline.UniformDescription uniformDescription : renderPass.pipeline.info().getUniforms()) { + Object object = renderPass.uniforms.get(uniformDescription.name()); + if (object == null && !GlProgram.BUILT_IN_UNIFORMS.contains(uniformDescription.name())) { + throw new IllegalStateException("Missing uniform " + uniformDescription.name() + " (should be " + uniformDescription.type() + ")"); + } + } + + for (String string : renderPass.pipeline.program().getSamplers()) { + if (!renderPass.samplers.containsKey(string)) { + throw new IllegalStateException("Missing sampler " + string); + } + + if (((GpuTexture)renderPass.samplers.get(string)).isClosed()) { + throw new IllegalStateException("Sampler " + string + " has been closed!"); + } + } + + if (renderPass.pipeline.info().wantsDepthTexture() && !renderPass.hasDepthTexture()) { + LOGGER.warn("Render pipeline {} wants a depth texture but none was provided - this is probably a bug", renderPass.pipeline.info().getLocation()); + } + } else if (renderPass.pipeline == null || renderPass.pipeline.program() == GlProgram.INVALID_PROGRAM) { + return false; + } + + RenderPipeline renderPipeline = renderPass.pipeline.info(); + GlProgram glProgram = renderPass.pipeline.program(); + + for (Uniform uniform : glProgram.getUniforms()) { + if (renderPass.dirtyUniforms.contains(uniform.getName())) { + Object object2 = renderPass.uniforms.get(uniform.getName()); + if (object2 instanceof int[]) { + glProgram.safeGetUniform(uniform.getName()).set((int[])object2); + } else if (object2 instanceof float[]) { + glProgram.safeGetUniform(uniform.getName()).set((float[])object2); + } else if (object2 != null) { + throw new IllegalStateException("Unknown uniform type - expected " + uniform.getType() + ", found " + object2); + } + } + } + + renderPass.dirtyUniforms.clear(); + this.applyPipelineState(renderPipeline); + boolean bl = this.lastProgram != glProgram; + if (bl) { + GlStateManager._glUseProgram(glProgram.getProgramId()); + this.lastProgram = glProgram; + } + + IntList intList = glProgram.getSamplerLocations(); + + for (int i = 0; i < glProgram.getSamplers().size(); i++) { + String string2 = (String)glProgram.getSamplers().get(i); + GlTexture glTexture = (GlTexture)renderPass.samplers.get(string2); + if (glTexture != null) { + if (bl || renderPass.dirtySamplers.contains(string2)) { + int j = intList.getInt(i); + Uniform.uploadInteger(j, i); + GlStateManager._activeTexture(33984 + i); + } + + GlStateManager._bindTexture(glTexture.glId()); + glTexture.flushModeChanges(); + } + } + + Window window = Minecraft.getInstance() == null ? null : Minecraft.getInstance().getWindow(); + glProgram.setDefaultUniforms( + renderPipeline.getVertexFormatMode(), + RenderSystem.getModelViewMatrix(), + RenderSystem.getProjectionMatrix(), + window == null ? 0.0F : window.getWidth(), + window == null ? 0.0F : window.getHeight() + ); + + for (Uniform uniform2 : glProgram.getUniforms()) { + uniform2.upload(); + } + + if (renderPass.scissorState.isEnabled()) { + GlStateManager._enableScissorTest(); + GlStateManager._scissorBox( + renderPass.scissorState.getX(), renderPass.scissorState.getY(), renderPass.scissorState.getWidth(), renderPass.scissorState.getHeight() + ); + } else { + GlStateManager._disableScissorTest(); + } + + return true; + } + + private void applyPipelineState(RenderPipeline pipeline) { + if (this.lastPipeline != pipeline) { + this.lastPipeline = pipeline; + if (pipeline.getDepthTestFunction() != DepthTestFunction.NO_DEPTH_TEST) { + GlStateManager._enableDepthTest(); + GlStateManager._depthFunc(GlConst.toGl(pipeline.getDepthTestFunction())); + } else { + GlStateManager._disableDepthTest(); + } + + if (pipeline.isCull()) { + GlStateManager._enableCull(); + } else { + GlStateManager._disableCull(); + } + + if (pipeline.getBlendFunction().isPresent()) { + GlStateManager._enableBlend(); + BlendFunction blendFunction = (BlendFunction)pipeline.getBlendFunction().get(); + GlStateManager._blendFuncSeparate( + GlConst.toGl(blendFunction.sourceColor()), + GlConst.toGl(blendFunction.destColor()), + GlConst.toGl(blendFunction.sourceAlpha()), + GlConst.toGl(blendFunction.destAlpha()) + ); + } else { + GlStateManager._disableBlend(); + } + + GlStateManager._polygonMode(1032, GlConst.toGl(pipeline.getPolygonMode())); + GlStateManager._depthMask(pipeline.isWriteDepth()); + GlStateManager._colorMask(pipeline.isWriteColor(), pipeline.isWriteColor(), pipeline.isWriteColor(), pipeline.isWriteAlpha()); + if (pipeline.getDepthBiasConstant() == 0.0F && pipeline.getDepthBiasScaleFactor() == 0.0F) { + GlStateManager._disablePolygonOffset(); + } else { + GlStateManager._polygonOffset(pipeline.getDepthBiasScaleFactor(), pipeline.getDepthBiasConstant()); + GlStateManager._enablePolygonOffset(); + } + + switch (pipeline.getColorLogic()) { + case NONE: + GlStateManager._disableColorLogicOp(); + break; + case OR_REVERSE: + GlStateManager._enableColorLogicOp(); + GlStateManager._logicOp(5387); + } + } + } + + public void finishRenderPass() { + this.inRenderPass = false; + GlStateManager._glBindFramebuffer(36160, 0); + } + + protected GlDevice getDevice() { + return this.device; + } +} diff --git a/com/mojang/blaze3d/platform/GlConst.java b/com/mojang/blaze3d/opengl/GlConst.java similarity index 56% rename from com/mojang/blaze3d/platform/GlConst.java rename to com/mojang/blaze3d/opengl/GlConst.java index 34d6bb33..9b49f085 100644 --- a/com/mojang/blaze3d/platform/GlConst.java +++ b/com/mojang/blaze3d/opengl/GlConst.java @@ -1,6 +1,18 @@ -package com.mojang.blaze3d.platform; +package com.mojang.blaze3d.opengl; import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.platform.DepthTestFunction; +import com.mojang.blaze3d.platform.DestFactor; +import com.mojang.blaze3d.platform.NativeImage; +import com.mojang.blaze3d.platform.PolygonMode; +import com.mojang.blaze3d.platform.SourceFactor; +import com.mojang.blaze3d.shaders.ShaderType; +import com.mojang.blaze3d.textures.AddressMode; +import com.mojang.blaze3d.textures.TextureFormat; +import com.mojang.blaze3d.vertex.VertexFormat; +import com.mojang.blaze3d.vertex.VertexFormatElement; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -22,6 +34,7 @@ public class GlConst { public static final int GL_MAP_READ_BIT = 1; public static final int GL_EQUAL = 514; public static final int GL_LEQUAL = 515; + public static final int GL_LESS = 513; public static final int GL_GREATER = 516; public static final int GL_GEQUAL = 518; public static final int GL_ALWAYS = 519; @@ -89,6 +102,7 @@ public class GlConst { public static final int GL_UNPACK_SKIP_PIXELS = 3316; public static final int GL_UNPACK_ALIGNMENT = 3317; public static final int GL_PACK_ALIGNMENT = 3333; + public static final int GL_PACK_ROW_LENGTH = 3330; public static final int GL_MAX_TEXTURE_SIZE = 3379; public static final int GL_TEXTURE_2D = 3553; public static final int GL_DEPTH_COMPONENT = 6402; @@ -122,6 +136,168 @@ public class GlConst { public static final int GL_ALPHA_BIAS = 3357; public static final int GL_RGB = 6407; public static final int GL_RG = 33319; + public static final int GL_R8 = 33321; public static final int GL_RED = 6403; public static final int GL_OUT_OF_MEMORY = 1285; + + public static int toGl(DepthTestFunction depthTestFunction) { + return switch (depthTestFunction) { + case NO_DEPTH_TEST -> 519; + case EQUAL_DEPTH_TEST -> 514; + case LESS_DEPTH_TEST -> 513; + case GREATER_DEPTH_TEST -> 516; + default -> 515; + }; + } + + public static int toGl(PolygonMode polygonMode) { + return switch (polygonMode) { + case WIREFRAME -> 6913; + default -> 6914; + }; + } + + public static int toGl(DestFactor destFactor) { + return switch (destFactor) { + case CONSTANT_ALPHA -> 32771; + case CONSTANT_COLOR -> 32769; + case DST_ALPHA -> 772; + case DST_COLOR -> 774; + case ONE -> 1; + case ONE_MINUS_CONSTANT_ALPHA -> 32772; + case ONE_MINUS_CONSTANT_COLOR -> 32770; + case ONE_MINUS_DST_ALPHA -> 773; + case ONE_MINUS_DST_COLOR -> 775; + case ONE_MINUS_SRC_ALPHA -> 771; + case ONE_MINUS_SRC_COLOR -> 769; + case SRC_ALPHA -> 770; + case SRC_COLOR -> 768; + case ZERO -> 0; + }; + } + + public static int toGl(SourceFactor sourceFactor) { + return switch (sourceFactor) { + case CONSTANT_ALPHA -> 32771; + case CONSTANT_COLOR -> 32769; + case DST_ALPHA -> 772; + case DST_COLOR -> 774; + case ONE -> 1; + case ONE_MINUS_CONSTANT_ALPHA -> 32772; + case ONE_MINUS_CONSTANT_COLOR -> 32770; + case ONE_MINUS_DST_ALPHA -> 773; + case ONE_MINUS_DST_COLOR -> 775; + case ONE_MINUS_SRC_ALPHA -> 771; + case ONE_MINUS_SRC_COLOR -> 769; + case SRC_ALPHA -> 770; + case SRC_ALPHA_SATURATE -> 776; + case SRC_COLOR -> 768; + case ZERO -> 0; + }; + } + + public static int toGl(BufferType bufferType) { + return switch (bufferType) { + case VERTICES -> 34962; + case INDICES -> 34963; + case PIXEL_PACK -> 35051; + case COPY_READ -> 36662; + case COPY_WRITE -> 36663; + case PIXEL_UNPACK -> 35052; + case UNIFORM -> 35345; + }; + } + + public static int toGl(VertexFormat.Mode mode) { + return switch (mode) { + case LINES -> 4; + case LINE_STRIP -> 5; + case DEBUG_LINES -> 1; + case DEBUG_LINE_STRIP -> 3; + case TRIANGLES -> 4; + case TRIANGLE_STRIP -> 5; + case TRIANGLE_FAN -> 6; + case QUADS -> 4; + }; + } + + public static int toGl(VertexFormat.IndexType indexType) { + return switch (indexType) { + case SHORT -> 5123; + case INT -> 5125; + }; + } + + public static int toGl(NativeImage.Format format) { + return switch (format) { + case RGBA -> 6408; + case RGB -> 6407; + case LUMINANCE_ALPHA -> 33319; + case LUMINANCE -> 6403; + }; + } + + public static int toGl(BufferUsage bufferUsage) { + return switch (bufferUsage) { + case DYNAMIC_WRITE -> 35048; + case STATIC_WRITE -> 35044; + case STREAM_WRITE -> 35040; + case STATIC_READ -> 35045; + case DYNAMIC_READ -> 35049; + case STREAM_READ -> 35041; + case DYNAMIC_COPY -> 35050; + case STATIC_COPY -> 35046; + case STREAM_COPY -> 35042; + }; + } + + public static int toGl(AddressMode addressMode) { + return switch (addressMode) { + case REPEAT -> 10497; + case CLAMP_TO_EDGE -> 33071; + }; + } + + public static int toGl(VertexFormatElement.Type type) { + return switch (type) { + case FLOAT -> 5126; + case UBYTE -> 5121; + case BYTE -> 5120; + case USHORT -> 5123; + case SHORT -> 5122; + case UINT -> 5125; + case INT -> 5124; + }; + } + + public static int toGlInternalId(TextureFormat textureFormat) { + return switch (textureFormat) { + case RGBA8 -> 32856; + case RED8 -> 33321; + case DEPTH32 -> 33191; + }; + } + + public static int toGlExternalId(TextureFormat textureFormat) { + return switch (textureFormat) { + case RGBA8 -> 6408; + case RED8 -> 6403; + case DEPTH32 -> 6402; + }; + } + + public static int toGlType(TextureFormat textureFormat) { + return switch (textureFormat) { + case RGBA8 -> 5121; + case RED8 -> 5121; + case DEPTH32 -> 5126; + }; + } + + public static int toGl(ShaderType shaderType) { + return switch (shaderType) { + case VERTEX -> 35633; + case FRAGMENT -> 35632; + }; + } } diff --git a/com/mojang/blaze3d/platform/GlDebug.java b/com/mojang/blaze3d/opengl/GlDebug.java similarity index 66% rename from com/mojang/blaze3d/platform/GlDebug.java rename to com/mojang/blaze3d/opengl/GlDebug.java index 22bad349..89392c74 100644 --- a/com/mojang/blaze3d/platform/GlDebug.java +++ b/com/mojang/blaze3d/opengl/GlDebug.java @@ -1,11 +1,14 @@ -package com.mojang.blaze3d.platform; +package com.mojang.blaze3d.opengl; import com.google.common.collect.EvictingQueue; import com.google.common.collect.ImmutableList; import com.google.common.collect.Lists; +import com.mojang.blaze3d.platform.DebugMemoryUntracker; +import com.mojang.blaze3d.platform.GLX; import com.mojang.logging.LogUtils; import java.util.List; import java.util.Queue; +import java.util.Set; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import org.jetbrains.annotations.Nullable; @@ -22,12 +25,11 @@ import org.slf4j.Logger; public class GlDebug { private static final Logger LOGGER = LogUtils.getLogger(); private static final int CIRCULAR_LOG_SIZE = 10; - private static final Queue MESSAGE_BUFFER = EvictingQueue.create(10); + private final Queue MESSAGE_BUFFER = EvictingQueue.create(10); @Nullable - private static volatile GlDebug.LogEntry lastEntry; + private volatile GlDebug.LogEntry lastEntry; private static final List DEBUG_LEVELS = ImmutableList.of(37190, 37191, 37192, 33387); private static final List DEBUG_LEVELS_ARB = ImmutableList.of(37190, 37191, 37192); - private static boolean debugEnabled; private static String printUnknownToken(int token) { return "Unknown (0x" + Integer.toHexString(token).toUpperCase() + ")"; @@ -73,8 +75,8 @@ public class GlDebug { } } - public static String severityToString(int severity) { - switch (severity) { + public static String severityToString(int type) { + switch (type) { case 33387: return "NOTIFICATION"; case 37190: @@ -84,41 +86,32 @@ public class GlDebug { case 37192: return "LOW"; default: - return printUnknownToken(severity); + return printUnknownToken(type); } } - /** - * @param source The GLenum source represented as an ordinal integer. - * @param type The GLenum type represented as an ordinal integer. - * @param id The unbounded integer id of the message callback. - * @param severity The GLenum severity represented as an ordinal integer. - * @param messageLength The {@link org.lwjgl.opengl.GLDebugMessageCallback} length argument. - * @param message The {@link org.lwjgl.opengl.GLDebugMessageCallback} message argument - * @param userParam A user supplied pointer that will be passed on each invocation of callback. - */ - private static void printDebugLog(int source, int type, int id, int severity, int messageLength, long message, long userParam) { - String string = GLDebugMessageCallback.getMessage(messageLength, message); + private void printDebugLog(int source, int type, int id, int severity, int length, long message, long userProgram) { + String string = GLDebugMessageCallback.getMessage(length, message); GlDebug.LogEntry logEntry; - synchronized (MESSAGE_BUFFER) { - logEntry = lastEntry; + synchronized (this.MESSAGE_BUFFER) { + logEntry = this.lastEntry; if (logEntry != null && logEntry.isSame(source, type, id, severity, string)) { logEntry.count++; } else { logEntry = new GlDebug.LogEntry(source, type, id, severity, string); - MESSAGE_BUFFER.add(logEntry); - lastEntry = logEntry; + this.MESSAGE_BUFFER.add(logEntry); + this.lastEntry = logEntry; } } LOGGER.info("OpenGL debug message: {}", logEntry); } - public static List getLastOpenGlDebugMessages() { - synchronized (MESSAGE_BUFFER) { - List list = Lists.newArrayListWithCapacity(MESSAGE_BUFFER.size()); + public List getLastOpenGlDebugMessages() { + synchronized (this.MESSAGE_BUFFER) { + List list = Lists.newArrayListWithCapacity(this.MESSAGE_BUFFER.size()); - for (GlDebug.LogEntry logEntry : MESSAGE_BUFFER) { + for (GlDebug.LogEntry logEntry : this.MESSAGE_BUFFER) { list.add(logEntry + " x " + logEntry.count); } @@ -126,38 +119,43 @@ public class GlDebug { } } - public static boolean isDebugEnabled() { - return debugEnabled; - } - - public static void enableDebugCallback(int debugVerbosity, boolean synchronous) { - if (debugVerbosity > 0) { + @Nullable + public static GlDebug enableDebugCallback(int vebosity, boolean sychronous, Set enabledExtensions) { + if (vebosity <= 0) { + return null; + } else { GLCapabilities gLCapabilities = GL.getCapabilities(); - if (gLCapabilities.GL_KHR_debug) { - debugEnabled = true; + if (gLCapabilities.GL_KHR_debug && GlDevice.USE_GL_KHR_debug) { + GlDebug glDebug = new GlDebug(); + enabledExtensions.add("GL_KHR_debug"); GL11.glEnable(37600); - if (synchronous) { + if (sychronous) { GL11.glEnable(33346); } for (int i = 0; i < DEBUG_LEVELS.size(); i++) { - boolean bl = i < debugVerbosity; + boolean bl = i < vebosity; KHRDebug.glDebugMessageControl(4352, 4352, (Integer)DEBUG_LEVELS.get(i), (int[])null, bl); } - KHRDebug.glDebugMessageCallback(GLX.make(GLDebugMessageCallback.create(GlDebug::printDebugLog), DebugMemoryUntracker::untrack), 0L); - } else if (gLCapabilities.GL_ARB_debug_output) { - debugEnabled = true; - if (synchronous) { + KHRDebug.glDebugMessageCallback(GLX.make(GLDebugMessageCallback.create(glDebug::printDebugLog), DebugMemoryUntracker::untrack), 0L); + return glDebug; + } else if (gLCapabilities.GL_ARB_debug_output && GlDevice.USE_GL_ARB_debug_output) { + GlDebug glDebug = new GlDebug(); + enabledExtensions.add("GL_ARB_debug_output"); + if (sychronous) { GL11.glEnable(33346); } for (int i = 0; i < DEBUG_LEVELS_ARB.size(); i++) { - boolean bl = i < debugVerbosity; + boolean bl = i < vebosity; ARBDebugOutput.glDebugMessageControlARB(4352, 4352, (Integer)DEBUG_LEVELS_ARB.get(i), (int[])null, bl); } - ARBDebugOutput.glDebugMessageCallbackARB(GLX.make(GLDebugMessageARBCallback.create(GlDebug::printDebugLog), DebugMemoryUntracker::untrack), 0L); + ARBDebugOutput.glDebugMessageCallbackARB(GLX.make(GLDebugMessageARBCallback.create(glDebug::printDebugLog), DebugMemoryUntracker::untrack), 0L); + return glDebug; + } else { + return null; } } } diff --git a/com/mojang/blaze3d/opengl/GlDebugLabel.java b/com/mojang/blaze3d/opengl/GlDebugLabel.java new file mode 100644 index 00000000..40f09f58 --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlDebugLabel.java @@ -0,0 +1,135 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.logging.LogUtils; +import java.util.Set; +import java.util.function.Supplier; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.util.StringUtil; +import org.lwjgl.opengl.EXTDebugLabel; +import org.lwjgl.opengl.GL11; +import org.lwjgl.opengl.GLCapabilities; +import org.lwjgl.opengl.KHRDebug; +import org.slf4j.Logger; + +@Environment(EnvType.CLIENT) +public abstract class GlDebugLabel { + private static final Logger LOGGER = LogUtils.getLogger(); + + public void applyLabel(GlBuffer buffer) { + } + + public void applyLabel(GlTexture texture) { + } + + public void applyLabel(GlShaderModule shaderModule) { + } + + public void applyLabel(GlProgram program) { + } + + public void applyLabel(VertexArrayCache.VertexArray vertexArray) { + } + + public static GlDebugLabel create(GLCapabilities capabilities, boolean renderDebugLabels, Set enabledExtensions) { + if (renderDebugLabels) { + if (capabilities.GL_KHR_debug && GlDevice.USE_GL_KHR_debug) { + enabledExtensions.add("GL_KHR_debug"); + return new GlDebugLabel.Core(); + } + + if (capabilities.GL_EXT_debug_label && GlDevice.USE_GL_EXT_debug_label) { + enabledExtensions.add("GL_EXT_debug_label"); + return new GlDebugLabel.Ext(); + } + + LOGGER.warn("Debug labels unavailable: neither KHR_debug nor EXT_debug_label are supported"); + } + + return new GlDebugLabel.Empty(); + } + + public boolean exists() { + return false; + } + + @Environment(EnvType.CLIENT) + static class Core extends GlDebugLabel { + private final int maxLabelLength = GL11.glGetInteger(33512); + + @Override + public void applyLabel(GlBuffer buffer) { + buffer.ensureBufferExists(); + Supplier supplier = buffer.label; + if (supplier != null) { + KHRDebug.glObjectLabel(33504, buffer.handle, StringUtil.truncateStringIfNecessary((String)supplier.get(), this.maxLabelLength, true)); + } + } + + @Override + public void applyLabel(GlTexture texture) { + KHRDebug.glObjectLabel(5890, texture.id, StringUtil.truncateStringIfNecessary(texture.getLabel(), this.maxLabelLength, true)); + } + + @Override + public void applyLabel(GlShaderModule shaderModule) { + KHRDebug.glObjectLabel(33505, shaderModule.getShaderId(), StringUtil.truncateStringIfNecessary(shaderModule.getDebugLabel(), this.maxLabelLength, true)); + } + + @Override + public void applyLabel(GlProgram program) { + KHRDebug.glObjectLabel(33506, program.getProgramId(), StringUtil.truncateStringIfNecessary(program.getDebugLabel(), this.maxLabelLength, true)); + } + + @Override + public void applyLabel(VertexArrayCache.VertexArray vertexArray) { + KHRDebug.glObjectLabel(32884, vertexArray.id, StringUtil.truncateStringIfNecessary(vertexArray.format.toString(), this.maxLabelLength, true)); + } + + @Override + public boolean exists() { + return true; + } + } + + @Environment(EnvType.CLIENT) + static class Empty extends GlDebugLabel { + } + + @Environment(EnvType.CLIENT) + static class Ext extends GlDebugLabel { + @Override + public void applyLabel(GlBuffer buffer) { + buffer.ensureBufferExists(); + Supplier supplier = buffer.label; + if (supplier != null) { + EXTDebugLabel.glLabelObjectEXT(37201, buffer.handle, StringUtil.truncateStringIfNecessary((String)supplier.get(), 256, true)); + } + } + + @Override + public void applyLabel(GlTexture texture) { + EXTDebugLabel.glLabelObjectEXT(5890, texture.id, StringUtil.truncateStringIfNecessary(texture.getLabel(), 256, true)); + } + + @Override + public void applyLabel(GlShaderModule shaderModule) { + EXTDebugLabel.glLabelObjectEXT(35656, shaderModule.getShaderId(), StringUtil.truncateStringIfNecessary(shaderModule.getDebugLabel(), 256, true)); + } + + @Override + public void applyLabel(GlProgram program) { + EXTDebugLabel.glLabelObjectEXT(35648, program.getProgramId(), StringUtil.truncateStringIfNecessary(program.getDebugLabel(), 256, true)); + } + + @Override + public void applyLabel(VertexArrayCache.VertexArray vertexArray) { + EXTDebugLabel.glLabelObjectEXT(32884, vertexArray.id, StringUtil.truncateStringIfNecessary(vertexArray.format.toString(), 256, true)); + } + + @Override + public boolean exists() { + return true; + } + } +} diff --git a/com/mojang/blaze3d/opengl/GlDevice.java b/com/mojang/blaze3d/opengl/GlDevice.java new file mode 100644 index 00000000..9f04dcb6 --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlDevice.java @@ -0,0 +1,312 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.GpuOutOfMemoryException; +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.preprocessor.GlslPreprocessor; +import com.mojang.blaze3d.shaders.ShaderType; +import com.mojang.blaze3d.systems.CommandEncoder; +import com.mojang.blaze3d.systems.GpuDevice; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.textures.TextureFormat; +import com.mojang.logging.LogUtils; +import java.nio.ByteBuffer; +import java.util.ArrayList; +import java.util.Collections; +import java.util.HashMap; +import java.util.HashSet; +import java.util.IdentityHashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import java.util.function.BiFunction; +import java.util.function.Supplier; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.ShaderDefines; +import net.minecraft.client.renderer.ShaderManager; +import net.minecraft.resources.ResourceLocation; +import org.apache.commons.lang3.StringUtils; +import org.jetbrains.annotations.Nullable; +import org.lwjgl.glfw.GLFW; +import org.lwjgl.opengl.GL; +import org.lwjgl.opengl.GLCapabilities; +import org.slf4j.Logger; + +@Environment(EnvType.CLIENT) +public class GlDevice implements GpuDevice { + private static final Logger LOGGER = LogUtils.getLogger(); + protected static boolean USE_GL_ARB_vertex_attrib_binding = true; + protected static boolean USE_GL_KHR_debug = true; + protected static boolean USE_GL_EXT_debug_label = true; + protected static boolean USE_GL_ARB_debug_output = true; + protected static boolean USE_GL_ARB_direct_state_access = true; + private final CommandEncoder encoder; + @Nullable + private final GlDebug debugLog; + private final GlDebugLabel debugLabels; + private final int maxSupportedTextureSize; + private final DirectStateAccess directStateAccess; + private final BiFunction defaultShaderSource; + private final Map pipelineCache = new IdentityHashMap(); + private final Map shaderCache = new HashMap(); + private final VertexArrayCache vertexArrayCache; + private final Set enabledExtensions = new HashSet(); + + public GlDevice( + long window, int debugVerbosity, boolean synchronous, BiFunction defaultShaderSource, boolean renderDebugLabels + ) { + GLFW.glfwMakeContextCurrent(window); + GLCapabilities gLCapabilities = GL.createCapabilities(); + int i = getMaxSupportedTextureSize(); + GLFW.glfwSetWindowSizeLimits(window, -1, -1, i, i); + this.debugLog = GlDebug.enableDebugCallback(debugVerbosity, synchronous, this.enabledExtensions); + this.debugLabels = GlDebugLabel.create(gLCapabilities, renderDebugLabels, this.enabledExtensions); + this.vertexArrayCache = VertexArrayCache.create(gLCapabilities, this.debugLabels, this.enabledExtensions); + this.directStateAccess = DirectStateAccess.create(gLCapabilities, this.enabledExtensions); + this.maxSupportedTextureSize = i; + this.defaultShaderSource = defaultShaderSource; + this.encoder = new GlCommandEncoder(this); + } + + public GlDebugLabel debugLabels() { + return this.debugLabels; + } + + @Override + public CommandEncoder createCommandEncoder() { + return this.encoder; + } + + @Override + public GpuTexture createTexture(@Nullable Supplier supplier, TextureFormat textureFormat, int i, int j, int k) { + return this.createTexture(this.debugLabels.exists() && supplier != null ? (String)supplier.get() : null, textureFormat, i, j, k); + } + + @Override + public GpuTexture createTexture(@Nullable String string, TextureFormat textureFormat, int i, int j, int k) { + if (k < 1) { + throw new IllegalArgumentException("mipLevels must be at least 1"); + } else { + GlStateManager.clearGlErrors(); + int l = GlStateManager._genTexture(); + if (string == null) { + string = String.valueOf(l); + } + + GlStateManager._bindTexture(l); + GlStateManager._texParameter(3553, 33085, k - 1); + GlStateManager._texParameter(3553, 33082, 0); + GlStateManager._texParameter(3553, 33083, k - 1); + if (textureFormat.hasDepthAspect()) { + GlStateManager._texParameter(3553, 34892, 0); + } + + for (int m = 0; m < k; m++) { + GlStateManager._texImage2D( + 3553, m, GlConst.toGlInternalId(textureFormat), i >> m, j >> m, 0, GlConst.toGlExternalId(textureFormat), GlConst.toGlType(textureFormat), null + ); + } + + int m = GlStateManager._getError(); + if (m == 1285) { + throw new GpuOutOfMemoryException("Could not allocate texture of " + i + "x" + j + " for " + string); + } else if (m != 0) { + throw new IllegalStateException("OpenGL error " + m); + } else { + GlTexture glTexture = new GlTexture(string, textureFormat, i, j, k, l); + this.debugLabels.applyLabel(glTexture); + return glTexture; + } + } + } + + @Override + public GpuBuffer createBuffer(@Nullable Supplier supplier, BufferType bufferType, BufferUsage bufferUsage, int i) { + if (i <= 0) { + throw new IllegalArgumentException("Buffer size must be greater than zero"); + } else { + return new GlBuffer(this.debugLabels, supplier, bufferType, bufferUsage, i, GlStateManager._glGenBuffers()); + } + } + + @Override + public GpuBuffer createBuffer(@Nullable Supplier supplier, BufferType bufferType, BufferUsage bufferUsage, ByteBuffer byteBuffer) { + if (!byteBuffer.hasRemaining()) { + throw new IllegalArgumentException("Buffer source must not be empty"); + } else { + GlBuffer glBuffer = new GlBuffer(this.debugLabels, supplier, bufferType, bufferUsage, byteBuffer.remaining(), GlStateManager._glGenBuffers()); + this.encoder.writeToBuffer(glBuffer, byteBuffer, 0); + return glBuffer; + } + } + + @Override + public String getImplementationInformation() { + return GLFW.glfwGetCurrentContext() == 0L + ? "NO CONTEXT" + : GlStateManager._getString(7937) + " GL version " + GlStateManager._getString(7938) + ", " + GlStateManager._getString(7936); + } + + @Override + public List getLastDebugMessages() { + return this.debugLog == null ? Collections.emptyList() : this.debugLog.getLastOpenGlDebugMessages(); + } + + @Override + public boolean isDebuggingEnabled() { + return this.debugLog != null; + } + + @Override + public String getRenderer() { + return GlStateManager._getString(7937); + } + + @Override + public String getVendor() { + return GlStateManager._getString(7936); + } + + @Override + public String getBackendName() { + return "OpenGL"; + } + + @Override + public String getVersion() { + return GlStateManager._getString(7938); + } + + private static int getMaxSupportedTextureSize() { + int i = GlStateManager._getInteger(3379); + + for (int j = Math.max(32768, i); j >= 1024; j >>= 1) { + GlStateManager._texImage2D(32868, 0, 6408, j, j, 0, 6408, 5121, null); + int k = GlStateManager._getTexLevelParameter(32868, 0, 4096); + if (k != 0) { + return j; + } + } + + int jx = Math.max(i, 1024); + LOGGER.info("Failed to determine maximum texture size by probing, trying GL_MAX_TEXTURE_SIZE = {}", jx); + return jx; + } + + @Override + public int getMaxTextureSize() { + return this.maxSupportedTextureSize; + } + + @Override + public void clearPipelineCache() { + for (GlRenderPipeline glRenderPipeline : this.pipelineCache.values()) { + if (glRenderPipeline.program() != GlProgram.INVALID_PROGRAM) { + glRenderPipeline.program().close(); + } + } + + this.pipelineCache.clear(); + + for (GlShaderModule glShaderModule : this.shaderCache.values()) { + if (glShaderModule != GlShaderModule.INVALID_SHADER) { + glShaderModule.close(); + } + } + + this.shaderCache.clear(); + } + + @Override + public List getEnabledExtensions() { + return new ArrayList(this.enabledExtensions); + } + + @Override + public void close() { + this.clearPipelineCache(); + } + + public DirectStateAccess directStateAccess() { + return this.directStateAccess; + } + + protected GlRenderPipeline getOrCompilePipeline(RenderPipeline pipeline) { + return (GlRenderPipeline)this.pipelineCache.computeIfAbsent(pipeline, renderPipeline2 -> this.compilePipeline(pipeline, this.defaultShaderSource)); + } + + protected GlShaderModule getOrCompileShader( + ResourceLocation shader, ShaderType type, ShaderDefines defines, BiFunction shaderSource + ) { + GlDevice.ShaderCompilationKey shaderCompilationKey = new GlDevice.ShaderCompilationKey(shader, type, defines); + return (GlShaderModule)this.shaderCache + .computeIfAbsent(shaderCompilationKey, shaderCompilationKey2 -> this.compileShader(shaderCompilationKey, shaderSource)); + } + + public GlRenderPipeline precompilePipeline(RenderPipeline renderPipeline, @Nullable BiFunction biFunction) { + BiFunction biFunction2 = biFunction == null ? this.defaultShaderSource : biFunction; + return (GlRenderPipeline)this.pipelineCache.computeIfAbsent(renderPipeline, renderPipeline2 -> this.compilePipeline(renderPipeline, biFunction2)); + } + + private GlShaderModule compileShader(GlDevice.ShaderCompilationKey key, BiFunction shaderSource) { + String string = (String)shaderSource.apply(key.id, key.type); + if (string == null) { + LOGGER.error("Couldn't find source for {} shader ({})", key.type, key.id); + return GlShaderModule.INVALID_SHADER; + } else { + String string2 = GlslPreprocessor.injectDefines(string, key.defines); + int i = GlStateManager.glCreateShader(GlConst.toGl(key.type)); + GlStateManager.glShaderSource(i, string2); + GlStateManager.glCompileShader(i); + if (GlStateManager.glGetShaderi(i, 35713) == 0) { + String string3 = StringUtils.trim(GlStateManager.glGetShaderInfoLog(i, 32768)); + LOGGER.error("Couldn't compile {} shader ({}): {}", key.type.getName(), key.id, string3); + return GlShaderModule.INVALID_SHADER; + } else { + GlShaderModule glShaderModule = new GlShaderModule(i, key.id, key.type); + this.debugLabels.applyLabel(glShaderModule); + return glShaderModule; + } + } + } + + private GlRenderPipeline compilePipeline(RenderPipeline pipeline, BiFunction shaderSource) { + GlShaderModule glShaderModule = this.getOrCompileShader(pipeline.getVertexShader(), ShaderType.VERTEX, pipeline.getShaderDefines(), shaderSource); + GlShaderModule glShaderModule2 = this.getOrCompileShader(pipeline.getFragmentShader(), ShaderType.FRAGMENT, pipeline.getShaderDefines(), shaderSource); + if (glShaderModule == GlShaderModule.INVALID_SHADER) { + LOGGER.error("Couldn't compile pipeline {}: vertex shader {} was invalid", pipeline.getLocation(), pipeline.getVertexShader()); + return new GlRenderPipeline(pipeline, GlProgram.INVALID_PROGRAM); + } else if (glShaderModule2 == GlShaderModule.INVALID_SHADER) { + LOGGER.error("Couldn't compile pipeline {}: fragment shader {} was invalid", pipeline.getLocation(), pipeline.getFragmentShader()); + return new GlRenderPipeline(pipeline, GlProgram.INVALID_PROGRAM); + } else { + GlProgram glProgram; + try { + glProgram = GlProgram.link(glShaderModule, glShaderModule2, pipeline.getVertexFormat(), pipeline.getLocation().toString()); + } catch (ShaderManager.CompilationException var7) { + LOGGER.error("Couldn't compile program for pipeline {}: {}", pipeline.getLocation(), var7); + return new GlRenderPipeline(pipeline, GlProgram.INVALID_PROGRAM); + } + + glProgram.setupUniforms(pipeline.getUniforms(), pipeline.getSamplers()); + this.debugLabels.applyLabel(glProgram); + return new GlRenderPipeline(pipeline, glProgram); + } + } + + public VertexArrayCache vertexArrayCache() { + return this.vertexArrayCache; + } + + @Environment(EnvType.CLIENT) + record ShaderCompilationKey(ResourceLocation id, ShaderType type, ShaderDefines defines) { + + public String toString() { + String string = this.id + " (" + this.type + ")"; + return !this.defines.isEmpty() ? string + " with " + this.defines : string; + } + } +} diff --git a/com/mojang/blaze3d/opengl/GlProgram.java b/com/mojang/blaze3d/opengl/GlProgram.java new file mode 100644 index 00000000..26b9b501 --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlProgram.java @@ -0,0 +1,335 @@ +package com.mojang.blaze3d.opengl; + +import com.google.common.collect.Sets; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.shaders.UniformType; +import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.vertex.VertexFormat; +import com.mojang.logging.LogUtils; +import it.unimi.dsi.fastutil.ints.IntArrayList; +import it.unimi.dsi.fastutil.ints.IntList; +import it.unimi.dsi.fastutil.objects.Object2ObjectMap; +import it.unimi.dsi.fastutil.objects.Object2ObjectOpenHashMap; +import java.nio.IntBuffer; +import java.util.ArrayList; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.FogParameters; +import net.minecraft.client.renderer.ShaderManager; +import org.jetbrains.annotations.Nullable; +import org.jetbrains.annotations.VisibleForTesting; +import org.joml.Matrix4f; +import org.joml.Vector3f; +import org.lwjgl.opengl.GL20; +import org.lwjgl.system.MemoryStack; +import org.slf4j.Logger; + +@Environment(EnvType.CLIENT) +public class GlProgram implements AutoCloseable { + private static final Logger LOGGER = LogUtils.getLogger(); + public static Set BUILT_IN_UNIFORMS = Sets.newHashSet( + "ModelViewMat", + "ProjMat", + "TextureMat", + "ScreenSize", + "ColorModulator", + "Light0_Direction", + "Light1_Direction", + "GlintAlpha", + "FogStart", + "FogEnd", + "FogColor", + "FogShape", + "LineWidth", + "GameTime", + "ModelOffset" + ); + public static GlProgram INVALID_PROGRAM = new GlProgram(-1, "invalid"); + private static final AbstractUniform DUMMY_UNIFORM = new AbstractUniform(); + private final List samplers = new ArrayList(); + private final Object2ObjectMap samplerTextures = new Object2ObjectOpenHashMap<>(); + private final IntList samplerLocations = new IntArrayList(); + private final List uniforms = new ArrayList(); + private final Map uniformsByName = new HashMap(); + private final int programId; + private final String debugLabel; + @Nullable + public Uniform MODEL_VIEW_MATRIX; + @Nullable + public Uniform PROJECTION_MATRIX; + @Nullable + public Uniform TEXTURE_MATRIX; + @Nullable + public Uniform SCREEN_SIZE; + @Nullable + public Uniform COLOR_MODULATOR; + @Nullable + public Uniform LIGHT0_DIRECTION; + @Nullable + public Uniform LIGHT1_DIRECTION; + @Nullable + public Uniform GLINT_ALPHA; + @Nullable + public Uniform FOG_START; + @Nullable + public Uniform FOG_END; + @Nullable + public Uniform FOG_COLOR; + @Nullable + public Uniform FOG_SHAPE; + @Nullable + public Uniform LINE_WIDTH; + @Nullable + public Uniform GAME_TIME; + @Nullable + public Uniform MODEL_OFFSET; + + private GlProgram(int programId, String debugLabel) { + this.programId = programId; + this.debugLabel = debugLabel; + } + + public static GlProgram link(GlShaderModule vertexShader, GlShaderModule fragmentShader, VertexFormat vertexFormat, String debugLabel) throws ShaderManager.CompilationException { + int i = GlStateManager.glCreateProgram(); + if (i <= 0) { + throw new ShaderManager.CompilationException("Could not create shader program (returned program ID " + i + ")"); + } else { + int j = 0; + + for (String string : vertexFormat.getElementAttributeNames()) { + GlStateManager._glBindAttribLocation(i, j, string); + j++; + } + + GlStateManager.glAttachShader(i, vertexShader.getShaderId()); + GlStateManager.glAttachShader(i, fragmentShader.getShaderId()); + GlStateManager.glLinkProgram(i); + int k = GlStateManager.glGetProgrami(i, 35714); + if (k == 0) { + String string = GlStateManager.glGetProgramInfoLog(i, 32768); + throw new ShaderManager.CompilationException( + "Error encountered when linking program containing VS " + vertexShader.getId() + " and FS " + fragmentShader.getId() + ". Log output: " + string + ); + } else { + return new GlProgram(i, debugLabel); + } + } + } + + public void setupUniforms(List uniforms, List samplers) { + RenderSystem.assertOnRenderThread(); + + for (RenderPipeline.UniformDescription uniformDescription : uniforms) { + String string = uniformDescription.name(); + int i = Uniform.glGetUniformLocation(this.programId, string); + if (i != -1) { + Uniform uniform = this.createUniform(uniformDescription); + uniform.setLocation(i); + this.uniforms.add(uniform); + this.uniformsByName.put(string, uniform); + } + } + + for (String string2 : samplers) { + int j = Uniform.glGetUniformLocation(this.programId, string2); + if (j == -1) { + LOGGER.warn("{} shader program does not use sampler {} defined in the pipeline. This might be a bug.", this.debugLabel, string2); + } else { + this.samplers.add(string2); + this.samplerLocations.add(j); + } + } + + int k = GlStateManager.glGetProgrami(this.programId, 35718); + + try (MemoryStack memoryStack = MemoryStack.stackPush()) { + IntBuffer intBuffer = memoryStack.mallocInt(1); + IntBuffer intBuffer2 = memoryStack.mallocInt(1); + + for (int l = 0; l < k; l++) { + String string3 = GL20.glGetActiveUniform(this.programId, l, intBuffer, intBuffer2); + UniformType uniformType = getTypeFromGl(intBuffer2.get(0)); + if (!this.uniformsByName.containsKey(string3) && !samplers.contains(string3)) { + if (uniformType != null) { + LOGGER.info("Found unknown but potentially supported uniform {} in {}", string3, this.debugLabel); + Uniform uniform2 = new Uniform(string3, uniformType); + uniform2.setLocation(l); + this.uniforms.add(uniform2); + this.uniformsByName.put(string3, uniform2); + } else { + LOGGER.warn("Found unknown and unsupported uniform {} in {}", string3, this.debugLabel); + } + } + } + } + + this.MODEL_VIEW_MATRIX = this.getUniform("ModelViewMat"); + this.PROJECTION_MATRIX = this.getUniform("ProjMat"); + this.TEXTURE_MATRIX = this.getUniform("TextureMat"); + this.SCREEN_SIZE = this.getUniform("ScreenSize"); + this.COLOR_MODULATOR = this.getUniform("ColorModulator"); + this.LIGHT0_DIRECTION = this.getUniform("Light0_Direction"); + this.LIGHT1_DIRECTION = this.getUniform("Light1_Direction"); + this.GLINT_ALPHA = this.getUniform("GlintAlpha"); + this.FOG_START = this.getUniform("FogStart"); + this.FOG_END = this.getUniform("FogEnd"); + this.FOG_COLOR = this.getUniform("FogColor"); + this.FOG_SHAPE = this.getUniform("FogShape"); + this.LINE_WIDTH = this.getUniform("LineWidth"); + this.GAME_TIME = this.getUniform("GameTime"); + this.MODEL_OFFSET = this.getUniform("ModelOffset"); + } + + private Uniform createUniform(RenderPipeline.UniformDescription description) { + return new Uniform(description.name(), description.type()); + } + + public void close() { + this.uniforms.forEach(Uniform::close); + GlStateManager.glDeleteProgram(this.programId); + } + + public void clear() { + RenderSystem.assertOnRenderThread(); + GlStateManager._glUseProgram(0); + int i = GlStateManager._getActiveTexture(); + + for (int j = 0; j < this.samplerLocations.size(); j++) { + String string = (String)this.samplers.get(j); + if (!this.samplerTextures.containsKey(string)) { + GlStateManager._activeTexture(33984 + j); + GlStateManager._bindTexture(0); + } + } + + GlStateManager._activeTexture(i); + } + + @Nullable + public Uniform getUniform(String name) { + RenderSystem.assertOnRenderThread(); + return (Uniform)this.uniformsByName.get(name); + } + + public AbstractUniform safeGetUniform(String name) { + Uniform uniform = this.getUniform(name); + return (AbstractUniform)(uniform == null ? DUMMY_UNIFORM : uniform); + } + + public void bindSampler(String name, @Nullable GpuTexture texture) { + this.samplerTextures.put(name, texture); + } + + public void setDefaultUniforms(VertexFormat.Mode mode, Matrix4f modelViewMatrix, Matrix4f projectionMatrix, float screenWidth, float screenHeight) { + for (int i = 0; i < 12; i++) { + GpuTexture gpuTexture = RenderSystem.getShaderTexture(i); + this.bindSampler("Sampler" + i, gpuTexture); + } + + if (this.MODEL_VIEW_MATRIX != null) { + this.MODEL_VIEW_MATRIX.set(modelViewMatrix); + } + + if (this.PROJECTION_MATRIX != null) { + this.PROJECTION_MATRIX.set(projectionMatrix); + } + + if (this.COLOR_MODULATOR != null) { + this.COLOR_MODULATOR.set(RenderSystem.getShaderColor()); + } + + if (this.GLINT_ALPHA != null) { + this.GLINT_ALPHA.set(RenderSystem.getShaderGlintAlpha()); + } + + FogParameters fogParameters = RenderSystem.getShaderFog(); + if (this.FOG_START != null) { + this.FOG_START.set(fogParameters.start()); + } + + if (this.FOG_END != null) { + this.FOG_END.set(fogParameters.end()); + } + + if (this.FOG_COLOR != null) { + this.FOG_COLOR.set(fogParameters.red(), fogParameters.green(), fogParameters.blue(), fogParameters.alpha()); + } + + if (this.FOG_SHAPE != null) { + this.FOG_SHAPE.set(fogParameters.shape().getIndex()); + } + + if (this.TEXTURE_MATRIX != null) { + this.TEXTURE_MATRIX.set(RenderSystem.getTextureMatrix()); + } + + if (this.GAME_TIME != null) { + this.GAME_TIME.set(RenderSystem.getShaderGameTime()); + } + + if (this.MODEL_OFFSET != null) { + this.MODEL_OFFSET.set(RenderSystem.getModelOffset()); + } + + if (this.SCREEN_SIZE != null) { + this.SCREEN_SIZE.set(screenWidth, screenHeight); + } + + if (this.LINE_WIDTH != null && (mode == VertexFormat.Mode.LINES || mode == VertexFormat.Mode.LINE_STRIP)) { + this.LINE_WIDTH.set(RenderSystem.getShaderLineWidth()); + } + + Vector3f[] vector3fs = RenderSystem.getShaderLights(); + if (this.LIGHT0_DIRECTION != null) { + this.LIGHT0_DIRECTION.set(vector3fs[0]); + } + + if (this.LIGHT1_DIRECTION != null) { + this.LIGHT1_DIRECTION.set(vector3fs[1]); + } + } + + @VisibleForTesting + public int getProgramId() { + return this.programId; + } + + public String toString() { + return this.debugLabel; + } + + public String getDebugLabel() { + return this.debugLabel; + } + + public IntList getSamplerLocations() { + return this.samplerLocations; + } + + public List getSamplers() { + return this.samplers; + } + + public List getUniforms() { + return this.uniforms; + } + + @Nullable + private static UniformType getTypeFromGl(int type) { + return switch (type) { + case 5124 -> UniformType.INT; + case 5126 -> UniformType.FLOAT; + case 35664 -> UniformType.VEC2; + case 35665 -> UniformType.VEC3; + case 35666 -> UniformType.VEC4; + case 35668 -> UniformType.IVEC3; + case 35676 -> UniformType.MATRIX4X4; + default -> null; + }; + } +} diff --git a/com/mojang/blaze3d/opengl/GlRenderPass.java b/com/mojang/blaze3d/opengl/GlRenderPass.java new file mode 100644 index 00000000..b98c6067 --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlRenderPass.java @@ -0,0 +1,145 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.systems.RenderPass; +import com.mojang.blaze3d.systems.ScissorState; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.vertex.VertexFormat; +import java.util.Collection; +import java.util.HashMap; +import java.util.HashSet; +import java.util.Set; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.SharedConstants; +import org.jetbrains.annotations.Nullable; +import org.joml.Matrix4f; + +@Environment(EnvType.CLIENT) +public class GlRenderPass implements RenderPass { + protected static final int MAX_VERTEX_BUFFERS = 1; + public static final boolean VALIDATION = SharedConstants.IS_RUNNING_IN_IDE; + private final GlCommandEncoder encoder; + private final boolean hasDepthTexture; + private boolean closed; + @Nullable + protected GlRenderPipeline pipeline; + protected final GpuBuffer[] vertexBuffers = new GpuBuffer[1]; + @Nullable + protected GpuBuffer indexBuffer; + protected VertexFormat.IndexType indexType = VertexFormat.IndexType.INT; + protected final ScissorState scissorState = new ScissorState(); + protected final HashMap uniforms = new HashMap(); + protected final HashMap samplers = new HashMap(); + protected final Set dirtyUniforms = new HashSet(); + protected final Set dirtySamplers = new HashSet(); + + public GlRenderPass(GlCommandEncoder encoder, boolean hasDepthTexture) { + this.encoder = encoder; + this.hasDepthTexture = hasDepthTexture; + } + + public boolean hasDepthTexture() { + return this.hasDepthTexture; + } + + @Override + public void setPipeline(RenderPipeline renderPipeline) { + if (this.pipeline == null || this.pipeline.info() != renderPipeline) { + this.dirtyUniforms.addAll(this.uniforms.keySet()); + this.dirtySamplers.addAll(this.samplers.keySet()); + } + + this.pipeline = this.encoder.getDevice().getOrCompilePipeline(renderPipeline); + } + + @Override + public void bindSampler(String string, GpuTexture gpuTexture) { + this.samplers.put(string, gpuTexture); + this.dirtySamplers.add(string); + } + + @Override + public void setUniform(String string, int... is) { + this.uniforms.put(string, is); + this.dirtyUniforms.add(string); + } + + @Override + public void setUniform(String string, float... fs) { + this.uniforms.put(string, fs); + this.dirtyUniforms.add(string); + } + + @Override + public void setUniform(String string, Matrix4f matrix4f) { + this.uniforms.put(string, matrix4f.get(new float[16])); + this.dirtyUniforms.add(string); + } + + @Override + public void enableScissor(ScissorState scissorState) { + this.scissorState.copyFrom(scissorState); + } + + @Override + public void enableScissor(int i, int j, int k, int l) { + this.scissorState.enable(i, j, k, l); + } + + @Override + public void disableScissor() { + this.scissorState.disable(); + } + + @Override + public void setVertexBuffer(int i, GpuBuffer gpuBuffer) { + if (i >= 0 && i < 1) { + this.vertexBuffers[i] = gpuBuffer; + } else { + throw new IllegalArgumentException("Vertex buffer slot is out of range: " + i); + } + } + + @Override + public void setIndexBuffer(@Nullable GpuBuffer gpuBuffer, VertexFormat.IndexType indexType) { + this.indexBuffer = gpuBuffer; + this.indexType = indexType; + } + + @Override + public void drawIndexed(int i, int j) { + if (this.closed) { + throw new IllegalStateException("Can't use a closed render pass"); + } else { + this.encoder.executeDraw(this, i, j, this.indexType); + } + } + + @Override + public void drawMultipleIndexed(Collection collection, @Nullable GpuBuffer gpuBuffer, @Nullable VertexFormat.IndexType indexType) { + if (this.closed) { + throw new IllegalStateException("Can't use a closed render pass"); + } else { + this.encoder.executeDrawMultiple(this, collection, gpuBuffer, indexType); + } + } + + @Override + public void draw(int i, int j) { + if (this.closed) { + throw new IllegalStateException("Can't use a closed render pass"); + } else { + this.encoder.executeDraw(this, i, j, null); + } + } + + @Override + public void close() { + if (!this.closed) { + this.closed = true; + this.encoder.finishRenderPass(); + } + } +} diff --git a/com/mojang/blaze3d/opengl/GlRenderPipeline.java b/com/mojang/blaze3d/opengl/GlRenderPipeline.java new file mode 100644 index 00000000..7db5639a --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlRenderPipeline.java @@ -0,0 +1,19 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.pipeline.CompiledRenderPipeline; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +public record GlRenderPipeline(RenderPipeline info, GlProgram program) implements CompiledRenderPipeline { + @Override + public boolean containsUniform(String string) { + return this.program.getUniform(string) != null; + } + + @Override + public boolean isValid() { + return this.program != GlProgram.INVALID_PROGRAM; + } +} diff --git a/com/mojang/blaze3d/opengl/GlShaderModule.java b/com/mojang/blaze3d/opengl/GlShaderModule.java new file mode 100644 index 00000000..12b8afdf --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlShaderModule.java @@ -0,0 +1,59 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.shaders.ShaderType; +import com.mojang.blaze3d.systems.RenderSystem; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.ShaderManager; +import net.minecraft.resources.ResourceLocation; +import org.apache.commons.lang3.StringUtils; + +@Environment(EnvType.CLIENT) +public class GlShaderModule implements AutoCloseable { + private static final int NOT_ALLOCATED = -1; + public static final GlShaderModule INVALID_SHADER = new GlShaderModule(-1, ResourceLocation.withDefaultNamespace("invalid"), ShaderType.VERTEX); + private final ResourceLocation id; + private int shaderId; + private final ShaderType type; + + public GlShaderModule(int shaderId, ResourceLocation id, ShaderType type) { + this.id = id; + this.shaderId = shaderId; + this.type = type; + } + + public static GlShaderModule compile(ResourceLocation id, ShaderType type, String source) throws ShaderManager.CompilationException { + RenderSystem.assertOnRenderThread(); + int i = GlStateManager.glCreateShader(GlConst.toGl(type)); + GlStateManager.glShaderSource(i, source); + GlStateManager.glCompileShader(i); + if (GlStateManager.glGetShaderi(i, 35713) == 0) { + String string = StringUtils.trim(GlStateManager.glGetShaderInfoLog(i, 32768)); + throw new ShaderManager.CompilationException("Couldn't compile " + type.getName() + " shader (" + id + ") : " + string); + } else { + return new GlShaderModule(i, id, type); + } + } + + public void close() { + if (this.shaderId == -1) { + throw new IllegalStateException("Already closed"); + } else { + RenderSystem.assertOnRenderThread(); + GlStateManager.glDeleteShader(this.shaderId); + this.shaderId = -1; + } + } + + public ResourceLocation getId() { + return this.id; + } + + public int getShaderId() { + return this.shaderId; + } + + public String getDebugLabel() { + return this.type.idConverter().idToFile(this.id).toString(); + } +} diff --git a/com/mojang/blaze3d/platform/GlStateManager.java b/com/mojang/blaze3d/opengl/GlStateManager.java similarity index 59% rename from com/mojang/blaze3d/platform/GlStateManager.java rename to com/mojang/blaze3d/opengl/GlStateManager.java index 37d05692..f53ba0d8 100644 --- a/com/mojang/blaze3d/platform/GlStateManager.java +++ b/com/mojang/blaze3d/opengl/GlStateManager.java @@ -1,21 +1,19 @@ -package com.mojang.blaze3d.platform; +package com.mojang.blaze3d.opengl; import com.google.common.base.Charsets; import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.platform.MacosUtil; import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.jtracy.Plot; import com.mojang.jtracy.TracyClient; import java.nio.ByteBuffer; import java.nio.FloatBuffer; import java.nio.IntBuffer; -import java.util.function.Consumer; import java.util.stream.IntStream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.Util; import org.jetbrains.annotations.Nullable; -import org.joml.Matrix4f; -import org.joml.Vector3f; import org.lwjgl.PointerBuffer; import org.lwjgl.opengl.GL11; import org.lwjgl.opengl.GL13; @@ -37,49 +35,47 @@ public class GlStateManager { private static int numTextures = 0; private static final Plot PLOT_BUFFERS = TracyClient.createPlot("GPU Buffers"); private static int numBuffers = 0; - public static final int TEXTURE_COUNT = 12; private static final GlStateManager.BlendState BLEND = new GlStateManager.BlendState(); private static final GlStateManager.DepthState DEPTH = new GlStateManager.DepthState(); private static final GlStateManager.CullState CULL = new GlStateManager.CullState(); private static final GlStateManager.PolygonOffsetState POLY_OFFSET = new GlStateManager.PolygonOffsetState(); private static final GlStateManager.ColorLogicState COLOR_LOGIC = new GlStateManager.ColorLogicState(); - private static final GlStateManager.StencilState STENCIL = new GlStateManager.StencilState(); private static final GlStateManager.ScissorState SCISSOR = new GlStateManager.ScissorState(); - private static final GlStateManager.FramebufferState READ_FRAMEBUFFER = new GlStateManager.FramebufferState(); - private static final GlStateManager.FramebufferState DRAW_FRAMEBUFFER = new GlStateManager.FramebufferState(); private static int activeTexture; private static final GlStateManager.TextureState[] TEXTURES = (GlStateManager.TextureState[])IntStream.range(0, 12) .mapToObj(i -> new GlStateManager.TextureState()) .toArray(GlStateManager.TextureState[]::new); private static final GlStateManager.ColorMask COLOR_MASK = new GlStateManager.ColorMask(); + private static int readFbo; + private static int writeFbo; public static void _disableScissorTest() { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); SCISSOR.mode.disable(); } public static void _enableScissorTest() { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); SCISSOR.mode.enable(); } public static void _scissorBox(int i, int j, int k, int l) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL20.glScissor(i, j, k, l); } public static void _disableDepthTest() { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); DEPTH.mode.disable(); } public static void _enableDepthTest() { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); DEPTH.mode.enable(); } public static void _depthFunc(int i) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); if (i != DEPTH.func) { DEPTH.func = i; GL11.glDepthFunc(i); @@ -104,15 +100,6 @@ public class GlStateManager { BLEND.mode.enable(); } - public static void _blendFunc(int i, int j) { - RenderSystem.assertOnRenderThread(); - if (i != BLEND.srcRgb || j != BLEND.dstRgb) { - BLEND.srcRgb = i; - BLEND.dstRgb = j; - GL11.glBlendFunc(i, j); - } - } - public static void _blendFuncSeparate(int i, int j, int k, int l) { RenderSystem.assertOnRenderThread(); if (i != BLEND.srcRgb || j != BLEND.dstRgb || k != BLEND.srcAlpha || l != BLEND.dstAlpha) { @@ -124,11 +111,6 @@ public class GlStateManager { } } - public static void _blendEquation(int i) { - RenderSystem.assertOnRenderThread(); - GL14.glBlendEquation(i); - } - public static int glGetProgrami(int i, int j) { RenderSystem.assertOnRenderThread(); return GL20.glGetProgrami(i, j); @@ -216,11 +198,6 @@ public class GlStateManager { GL20.glUniform1fv(i, floatBuffer); } - public static void _glUniform2(int i, IntBuffer intBuffer) { - RenderSystem.assertOnRenderThread(); - GL20.glUniform2iv(i, intBuffer); - } - public static void _glUniform2(int i, FloatBuffer floatBuffer) { RenderSystem.assertOnRenderThread(); GL20.glUniform2fv(i, floatBuffer); @@ -236,34 +213,14 @@ public class GlStateManager { GL20.glUniform3fv(i, floatBuffer); } - public static void _glUniform4(int i, IntBuffer intBuffer) { - RenderSystem.assertOnRenderThread(); - GL20.glUniform4iv(i, intBuffer); - } - public static void _glUniform4(int i, FloatBuffer floatBuffer) { RenderSystem.assertOnRenderThread(); GL20.glUniform4fv(i, floatBuffer); } - public static void _glUniformMatrix2(int i, boolean bl, FloatBuffer floatBuffer) { + public static void _glUniformMatrix4(int i, FloatBuffer floatBuffer) { RenderSystem.assertOnRenderThread(); - GL20.glUniformMatrix2fv(i, bl, floatBuffer); - } - - public static void _glUniformMatrix3(int i, boolean bl, FloatBuffer floatBuffer) { - RenderSystem.assertOnRenderThread(); - GL20.glUniformMatrix3fv(i, bl, floatBuffer); - } - - public static void _glUniformMatrix4(int i, boolean bl, FloatBuffer floatBuffer) { - RenderSystem.assertOnRenderThread(); - GL20.glUniformMatrix4fv(i, bl, floatBuffer); - } - - public static int _glGetAttribLocation(int i, CharSequence charSequence) { - RenderSystem.assertOnRenderThread(); - return GL20.glGetAttribLocation(i, charSequence); + GL20.glUniformMatrix4fv(i, false, floatBuffer); } public static void _glBindAttribLocation(int i, int j, CharSequence charSequence) { @@ -272,56 +229,50 @@ public class GlStateManager { } public static int _glGenBuffers() { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); numBuffers++; PLOT_BUFFERS.setValue(numBuffers); return GL15.glGenBuffers(); } public static int _glGenVertexArrays() { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); return GL30.glGenVertexArrays(); } public static void _glBindBuffer(int i, int j) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL15.glBindBuffer(i, j); } public static void _glBindVertexArray(int i) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL30.glBindVertexArray(i); } public static void _glBufferData(int i, ByteBuffer byteBuffer, int j) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL15.glBufferData(i, byteBuffer, j); } public static void _glBufferSubData(int i, int j, ByteBuffer byteBuffer) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL15.glBufferSubData(i, (long)j, byteBuffer); } public static void _glBufferData(int i, long l, int j) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL15.glBufferData(i, l, j); } - @Nullable - public static ByteBuffer _glMapBuffer(int i, int j) { - RenderSystem.assertOnRenderThreadOrInit(); - return GL15.glMapBuffer(i, j); - } - @Nullable public static ByteBuffer _glMapBufferRange(int i, int j, int k, int l) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); return GL30.glMapBufferRange(i, j, k, l); } public static void _glUnmapBuffer(int i) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL15.glUnmapBuffer(i); } @@ -338,83 +289,44 @@ public class GlStateManager { GL15.glDeleteBuffers(i); } - public static void _glCopyTexSubImage2D(int i, int j, int k, int l, int m, int n, int o, int p) { - RenderSystem.assertOnRenderThreadOrInit(); - GL20.glCopyTexSubImage2D(i, j, k, l, m, n, o, p); - } - - public static void _glDeleteVertexArrays(int i) { - RenderSystem.assertOnRenderThread(); - GL30.glDeleteVertexArrays(i); - } - public static void _glBindFramebuffer(int i, int j) { - RenderSystem.assertOnRenderThreadOrInit(); + if ((i == 36008 || i == 36160) && readFbo != j) { + GL30.glBindFramebuffer(36008, j); + readFbo = j; + } - boolean bl = switch (i) { - case 36008 -> READ_FRAMEBUFFER.update(j); - case 36009 -> DRAW_FRAMEBUFFER.update(j); - case 36160 -> READ_FRAMEBUFFER.update(j) | DRAW_FRAMEBUFFER.update(j); - default -> true; - }; - if (bl) { - GL30.glBindFramebuffer(i, j); + if ((i == 36009 || i == 36160) && writeFbo != j) { + GL30.glBindFramebuffer(36009, j); + writeFbo = j; + } + } + + public static int getFrameBuffer(int i) { + if (i == 36008) { + return readFbo; + } else { + return i == 36009 ? writeFbo : 0; } } public static void _glBlitFrameBuffer(int i, int j, int k, int l, int m, int n, int o, int p, int q, int r) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL30.glBlitFramebuffer(i, j, k, l, m, n, o, p, q, r); } - public static void _glBindRenderbuffer(int i, int j) { - RenderSystem.assertOnRenderThreadOrInit(); - GL30.glBindRenderbuffer(i, j); - } - - public static void _glDeleteRenderbuffers(int i) { - RenderSystem.assertOnRenderThreadOrInit(); - GL30.glDeleteRenderbuffers(i); - } - public static void _glDeleteFramebuffers(int i) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL30.glDeleteFramebuffers(i); } public static int glGenFramebuffers() { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); return GL30.glGenFramebuffers(); } - public static int glGenRenderbuffers() { - RenderSystem.assertOnRenderThreadOrInit(); - return GL30.glGenRenderbuffers(); - } - - public static void _glRenderbufferStorage(int i, int j, int k, int l) { - RenderSystem.assertOnRenderThreadOrInit(); - GL30.glRenderbufferStorage(i, j, k, l); - } - - public static void _glFramebufferRenderbuffer(int i, int j, int k, int l) { - RenderSystem.assertOnRenderThreadOrInit(); - GL30.glFramebufferRenderbuffer(i, j, k, l); - } - - public static int glCheckFramebufferStatus(int i) { - RenderSystem.assertOnRenderThreadOrInit(); - return GL30.glCheckFramebufferStatus(i); - } - public static void _glFramebufferTexture2D(int i, int j, int k, int l, int m) { - RenderSystem.assertOnRenderThreadOrInit(); - GL30.glFramebufferTexture2D(i, j, k, l, m); - } - - public static int getBoundFramebuffer() { RenderSystem.assertOnRenderThread(); - return _getInteger(36006); + GL30.glFramebufferTexture2D(i, j, k, l, m); } public static void glActiveTexture(int i) { @@ -437,26 +349,6 @@ public class GlStateManager { return GL20.glGetProgramInfoLog(i, j); } - public static void setupLevelDiffuseLighting(Vector3f vector3f, Vector3f vector3f2, Matrix4f matrix4f) { - RenderSystem.assertOnRenderThread(); - RenderSystem.setShaderLights(matrix4f.transformDirection(vector3f, new Vector3f()), matrix4f.transformDirection(vector3f2, new Vector3f())); - } - - public static void setupGuiFlatDiffuseLighting(Vector3f vector3f, Vector3f vector3f2) { - RenderSystem.assertOnRenderThread(); - Matrix4f matrix4f = new Matrix4f().rotationY((float) (-Math.PI / 8)).rotateX((float) (Math.PI * 3.0 / 4.0)); - setupLevelDiffuseLighting(vector3f, vector3f2, matrix4f); - } - - public static void setupGui3DDiffuseLighting(Vector3f vector3f, Vector3f vector3f2) { - RenderSystem.assertOnRenderThread(); - Matrix4f matrix4f = new Matrix4f() - .scaling(1.0F, -1.0F, 1.0F) - .rotateYXZ(1.0821041F, 3.2375858F, 0.0F) - .rotateYXZ((float) (-Math.PI / 8), (float) (Math.PI * 3.0 / 4.0), 0.0F); - setupLevelDiffuseLighting(vector3f, vector3f2, matrix4f); - } - public static void _enableCull() { RenderSystem.assertOnRenderThread(); CULL.enable.enable(); @@ -517,13 +409,8 @@ public class GlStateManager { } } - public static void _texParameter(int i, int j, float f) { - RenderSystem.assertOnRenderThreadOrInit(); - GL11.glTexParameterf(i, j, f); - } - public static void _texParameter(int i, int j, int k) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL11.glTexParameteri(i, j, k); } @@ -532,21 +419,14 @@ public class GlStateManager { } public static int _genTexture() { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); numTextures++; PLOT_TEXTURES.setValue(numTextures); return GL11.glGenTextures(); } - public static void _genTextures(int[] is) { - RenderSystem.assertOnRenderThreadOrInit(); - numTextures += is.length; - PLOT_TEXTURES.setValue(numTextures); - GL11.glGenTextures(is); - } - public static void _deleteTexture(int i) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL11.glDeleteTextures(i); for (GlStateManager.TextureState textureState : TEXTURES) { @@ -559,24 +439,8 @@ public class GlStateManager { PLOT_TEXTURES.setValue(numTextures); } - public static void _deleteTextures(int[] is) { - RenderSystem.assertOnRenderThreadOrInit(); - - for (GlStateManager.TextureState textureState : TEXTURES) { - for (int i : is) { - if (textureState.binding == i) { - textureState.binding = -1; - } - } - } - - GL11.glDeleteTextures(is); - numTextures -= is.length; - PLOT_TEXTURES.setValue(numTextures); - } - public static void _bindTexture(int i) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); if (i != TEXTURES[activeTexture].binding) { TEXTURES[activeTexture].binding = i; GL11.glBindTexture(3553, i); @@ -588,47 +452,21 @@ public class GlStateManager { } public static void _texImage2D(int i, int j, int k, int l, int m, int n, int o, int p, @Nullable IntBuffer intBuffer) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL11.glTexImage2D(i, j, k, l, m, n, o, p, intBuffer); } public static void _texSubImage2D(int i, int j, int k, int l, int m, int n, int o, int p, long q) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL11.glTexSubImage2D(i, j, k, l, m, n, o, p, q); } - public static void upload(int i, int j, int k, int l, int m, NativeImage.Format format, IntBuffer intBuffer, Consumer consumer) { - if (!RenderSystem.isOnRenderThreadOrInit()) { - RenderSystem.recordRenderCall(() -> _upload(i, j, k, l, m, format, intBuffer, consumer)); - } else { - _upload(i, j, k, l, m, format, intBuffer, consumer); - } - } - - private static void _upload(int i, int j, int k, int l, int m, NativeImage.Format format, IntBuffer intBuffer, Consumer consumer) { - try { - RenderSystem.assertOnRenderThreadOrInit(); - _pixelStore(3314, l); - _pixelStore(3316, 0); - _pixelStore(3315, 0); - format.setUnpackPixelStoreState(); - GL11.glTexSubImage2D(3553, i, j, k, l, m, format.glFormat(), 5121, intBuffer); - } finally { - consumer.accept(intBuffer); - } - } - - public static void _getTexImage(int i, int j, int k, int l, long m) { + public static void _texSubImage2D(int i, int j, int k, int l, int m, int n, int o, int p, IntBuffer intBuffer) { RenderSystem.assertOnRenderThread(); - GL11.glGetTexImage(i, j, k, l, m); + GL11.glTexSubImage2D(i, j, k, l, m, n, o, p, intBuffer); } public static void _viewport(int i, int j, int k, int l) { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager.Viewport.INSTANCE.x = i; - GlStateManager.Viewport.INSTANCE.y = j; - GlStateManager.Viewport.INSTANCE.width = k; - GlStateManager.Viewport.INSTANCE.height = l; GL11.glViewport(i, j, k, l); } @@ -643,62 +481,14 @@ public class GlStateManager { } } - public static void _stencilFunc(int i, int j, int k) { - RenderSystem.assertOnRenderThread(); - if (i != STENCIL.func.func || i != STENCIL.func.ref || i != STENCIL.func.mask) { - STENCIL.func.func = i; - STENCIL.func.ref = j; - STENCIL.func.mask = k; - GL11.glStencilFunc(i, j, k); - } - } - - public static void _stencilMask(int i) { - RenderSystem.assertOnRenderThread(); - if (i != STENCIL.mask) { - STENCIL.mask = i; - GL11.glStencilMask(i); - } - } - - public static void _stencilOp(int i, int j, int k) { - RenderSystem.assertOnRenderThread(); - if (i != STENCIL.fail || j != STENCIL.zfail || k != STENCIL.zpass) { - STENCIL.fail = i; - STENCIL.zfail = j; - STENCIL.zpass = k; - GL11.glStencilOp(i, j, k); - } - } - - public static void _clearDepth(double d) { - RenderSystem.assertOnRenderThreadOrInit(); - GL11.glClearDepth(d); - } - - public static void _clearColor(float f, float g, float h, float i) { - RenderSystem.assertOnRenderThreadOrInit(); - GL11.glClearColor(f, g, h, i); - } - - public static void _clearStencil(int i) { - RenderSystem.assertOnRenderThread(); - GL11.glClearStencil(i); - } - public static void _clear(int i) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL11.glClear(i); if (MacosUtil.IS_MACOS) { _getError(); } } - public static void _glDrawPixels(int i, int j, int k, int l, long m) { - RenderSystem.assertOnRenderThread(); - GL11.glDrawPixels(i, j, k, l, m); - } - public static void _vertexAttribPointer(int i, int j, int k, boolean bl, int l, long m) { RenderSystem.assertOnRenderThread(); GL20.glVertexAttribPointer(i, j, k, bl, l, m); @@ -714,24 +504,19 @@ public class GlStateManager { GL20.glEnableVertexAttribArray(i); } - public static void _disableVertexAttribArray(int i) { - RenderSystem.assertOnRenderThread(); - GL20.glDisableVertexAttribArray(i); - } - public static void _drawElements(int i, int j, int k, long l) { RenderSystem.assertOnRenderThread(); GL11.glDrawElements(i, j, k, l); } - public static void _pixelStore(int i, int j) { - RenderSystem.assertOnRenderThreadOrInit(); - GL11.glPixelStorei(i, j); + public static void _drawArrays(int i, int j, int k) { + RenderSystem.assertOnRenderThread(); + GL11.glDrawArrays(i, j, k); } - public static void _readPixels(int i, int j, int k, int l, int m, int n, ByteBuffer byteBuffer) { + public static void _pixelStore(int i, int j) { RenderSystem.assertOnRenderThread(); - GL11.glReadPixels(i, j, k, l, m, n, byteBuffer); + GL11.glPixelStorei(i, j); } public static void _readPixels(int i, int j, int k, int l, int m, int n, long o) { @@ -744,28 +529,35 @@ public class GlStateManager { return GL11.glGetError(); } + public static void clearGlErrors() { + RenderSystem.assertOnRenderThread(); + + while (GL11.glGetError() != 0) { + } + } + public static String _getString(int i) { RenderSystem.assertOnRenderThread(); return GL11.glGetString(i); } public static int _getInteger(int i) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); return GL11.glGetInteger(i); } public static long _glFenceSync(int i, int j) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); return GL32.glFenceSync(i, j); } public static int _glClientWaitSync(long l, int i, long m) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); return GL32.glClientWaitSync(l, i, m); } public static void _glDeleteSync(long l) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); GL32.glDeleteSync(l); } @@ -796,7 +588,7 @@ public class GlStateManager { } public void setEnabled(boolean enabled) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); if (enabled != this.enabled) { this.enabled = enabled; if (enabled) { @@ -825,7 +617,6 @@ public class GlStateManager { @Environment(EnvType.CLIENT) static class CullState { public final GlStateManager.BooleanState enable = new GlStateManager.BooleanState(2884); - public int mode = 1029; } @Environment(EnvType.CLIENT) @@ -835,75 +626,9 @@ public class GlStateManager { public int func = 513; } - @Environment(EnvType.CLIENT) - @DontObfuscate - public static enum DestFactor { - CONSTANT_ALPHA(32771), - CONSTANT_COLOR(32769), - DST_ALPHA(772), - DST_COLOR(774), - ONE(1), - ONE_MINUS_CONSTANT_ALPHA(32772), - ONE_MINUS_CONSTANT_COLOR(32770), - ONE_MINUS_DST_ALPHA(773), - ONE_MINUS_DST_COLOR(775), - ONE_MINUS_SRC_ALPHA(771), - ONE_MINUS_SRC_COLOR(769), - SRC_ALPHA(770), - SRC_COLOR(768), - ZERO(0); - - public final int value; - - private DestFactor(final int value) { - this.value = value; - } - } - - @Environment(EnvType.CLIENT) - static class FramebufferState { - public int binding; - - public boolean update(int binding) { - if (binding != this.binding) { - this.binding = binding; - return true; - } else { - return false; - } - } - } - - @Environment(EnvType.CLIENT) - public static enum LogicOp { - AND(5377), - AND_INVERTED(5380), - AND_REVERSE(5378), - CLEAR(5376), - COPY(5379), - COPY_INVERTED(5388), - EQUIV(5385), - INVERT(5386), - NAND(5390), - NOOP(5381), - NOR(5384), - OR(5383), - OR_INVERTED(5389), - OR_REVERSE(5387), - SET(5391), - XOR(5382); - - public final int value; - - private LogicOp(final int value) { - this.value = value; - } - } - @Environment(EnvType.CLIENT) static class PolygonOffsetState { public final GlStateManager.BooleanState fill = new GlStateManager.BooleanState(32823); - public final GlStateManager.BooleanState line = new GlStateManager.BooleanState(10754); public float factor; public float units; } @@ -913,76 +638,8 @@ public class GlStateManager { public final GlStateManager.BooleanState mode = new GlStateManager.BooleanState(3089); } - @Environment(EnvType.CLIENT) - @DontObfuscate - public static enum SourceFactor { - CONSTANT_ALPHA(32771), - CONSTANT_COLOR(32769), - DST_ALPHA(772), - DST_COLOR(774), - ONE(1), - ONE_MINUS_CONSTANT_ALPHA(32772), - ONE_MINUS_CONSTANT_COLOR(32770), - ONE_MINUS_DST_ALPHA(773), - ONE_MINUS_DST_COLOR(775), - ONE_MINUS_SRC_ALPHA(771), - ONE_MINUS_SRC_COLOR(769), - SRC_ALPHA(770), - SRC_ALPHA_SATURATE(776), - SRC_COLOR(768), - ZERO(0); - - public final int value; - - private SourceFactor(final int value) { - this.value = value; - } - } - - @Environment(EnvType.CLIENT) - static class StencilFunc { - public int func = 519; - public int ref; - public int mask = -1; - } - - @Environment(EnvType.CLIENT) - static class StencilState { - public final GlStateManager.StencilFunc func = new GlStateManager.StencilFunc(); - public int mask = -1; - public int fail = 7680; - public int zfail = 7680; - public int zpass = 7680; - } - @Environment(EnvType.CLIENT) static class TextureState { public int binding; } - - @Environment(EnvType.CLIENT) - public static enum Viewport { - INSTANCE; - - protected int x; - protected int y; - protected int width; - protected int height; - - public static int x() { - return INSTANCE.x; - } - - public static int y() { - return INSTANCE.y; - } - - public static int width() { - return INSTANCE.width; - } - - public static int height() { - return INSTANCE.height; - } - } } diff --git a/com/mojang/blaze3d/opengl/GlTexture.java b/com/mojang/blaze3d/opengl/GlTexture.java new file mode 100644 index 00000000..0135c300 --- /dev/null +++ b/com/mojang/blaze3d/opengl/GlTexture.java @@ -0,0 +1,94 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.textures.AddressMode; +import com.mojang.blaze3d.textures.FilterMode; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.textures.TextureFormat; +import it.unimi.dsi.fastutil.ints.Int2IntFunction; +import it.unimi.dsi.fastutil.ints.Int2IntMap; +import it.unimi.dsi.fastutil.ints.Int2IntOpenHashMap; +import it.unimi.dsi.fastutil.ints.IntIterator; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public class GlTexture extends GpuTexture { + protected final int id; + private final Int2IntMap fboCache = new Int2IntOpenHashMap(); + protected boolean closed; + protected boolean modesDirty = true; + + protected GlTexture(String label, TextureFormat format, int width, int height, int mipLevels, int id) { + super(label, format, width, height, mipLevels); + this.id = id; + } + + @Override + public void close() { + if (!this.closed) { + this.closed = true; + GlStateManager._deleteTexture(this.id); + IntIterator var1 = this.fboCache.values().iterator(); + + while (var1.hasNext()) { + int i = (Integer)var1.next(); + GlStateManager._glDeleteFramebuffers(i); + } + } + } + + @Override + public boolean isClosed() { + return this.closed; + } + + public int getFbo(DirectStateAccess directStateAccess, @Nullable GpuTexture texture) { + int i = texture == null ? 0 : ((GlTexture)texture).id; + return this.fboCache.computeIfAbsent(i, (Int2IntFunction)(j -> { + int k = directStateAccess.createFrameBufferObject(); + directStateAccess.bindFrameBufferTextures(k, this.id, i, 0, 0); + return k; + })); + } + + public void flushModeChanges() { + if (this.modesDirty) { + GlStateManager._texParameter(3553, 10242, GlConst.toGl(this.addressModeU)); + GlStateManager._texParameter(3553, 10243, GlConst.toGl(this.addressModeV)); + switch (this.minFilter) { + case NEAREST: + GlStateManager._texParameter(3553, 10241, this.useMipmaps ? 9986 : 9728); + break; + case LINEAR: + GlStateManager._texParameter(3553, 10241, this.useMipmaps ? 9987 : 9729); + } + + switch (this.magFilter) { + case NEAREST: + GlStateManager._texParameter(3553, 10240, 9728); + break; + case LINEAR: + GlStateManager._texParameter(3553, 10240, 9729); + } + + this.modesDirty = false; + } + } + + public int glId() { + return this.id; + } + + @Override + public void setAddressMode(AddressMode addressMode, AddressMode addressMode2) { + super.setAddressMode(addressMode, addressMode2); + this.modesDirty = true; + } + + @Override + public void setTextureFilter(FilterMode filterMode, FilterMode filterMode2, boolean bl) { + super.setTextureFilter(filterMode, filterMode2, bl); + this.modesDirty = true; + } +} diff --git a/com/mojang/blaze3d/opengl/Uniform.java b/com/mojang/blaze3d/opengl/Uniform.java new file mode 100644 index 00000000..f7e8c25f --- /dev/null +++ b/com/mojang/blaze3d/opengl/Uniform.java @@ -0,0 +1,189 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.shaders.UniformType; +import com.mojang.logging.LogUtils; +import java.nio.FloatBuffer; +import java.nio.IntBuffer; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.joml.Matrix4f; +import org.joml.Vector3f; +import org.lwjgl.system.MemoryUtil; +import org.slf4j.Logger; + +@Environment(EnvType.CLIENT) +public class Uniform extends AbstractUniform implements AutoCloseable { + private static final Logger LOGGER = LogUtils.getLogger(); + private int location; + private final UniformType type; + private final IntBuffer intValues; + private final FloatBuffer floatValues; + private final String name; + private boolean dirty; + + public Uniform(String name, UniformType type) { + this.name = name; + this.type = type; + if (type.isIntStorage()) { + this.intValues = MemoryUtil.memAllocInt(type.count()); + this.floatValues = null; + } else { + this.intValues = null; + this.floatValues = MemoryUtil.memAllocFloat(type.count()); + } + + this.location = -1; + } + + public static int glGetUniformLocation(int program, CharSequence name) { + return GlStateManager._glGetUniformLocation(program, name); + } + + public static void uploadInteger(int location, int value) { + GlStateManager._glUniform1i(location, value); + } + + public void close() { + if (this.intValues != null) { + MemoryUtil.memFree(this.intValues); + } + + if (this.floatValues != null) { + MemoryUtil.memFree(this.floatValues); + } + } + + public void setLocation(int location) { + this.location = location; + } + + public String getName() { + return this.name; + } + + public UniformType getType() { + return this.type; + } + + @Override + public final void set(float value) { + this.floatValues.position(0); + this.floatValues.put(0, value); + this.dirty = true; + } + + @Override + public final void set(float value1, float value2) { + this.floatValues.position(0); + this.floatValues.put(0, value1); + this.floatValues.put(1, value2); + this.dirty = true; + } + + @Override + public final void set(float value1, float value2, float value3) { + this.floatValues.position(0); + this.floatValues.put(0, value1); + this.floatValues.put(1, value2); + this.floatValues.put(2, value3); + this.dirty = true; + } + + @Override + public final void set(Vector3f values) { + this.floatValues.position(0); + values.get(this.floatValues); + this.dirty = true; + } + + @Override + public final void set(float value1, float value2, float value3, float value4) { + this.floatValues.position(0); + this.floatValues.put(value1); + this.floatValues.put(value2); + this.floatValues.put(value3); + this.floatValues.put(value4); + this.floatValues.flip(); + this.dirty = true; + } + + @Override + public final void set(int value) { + this.intValues.position(0); + this.intValues.put(0, value); + this.dirty = true; + } + + @Override + public final void set(int value1, int value2, int value3) { + this.intValues.position(0); + this.intValues.put(0, value1); + this.intValues.put(1, value2); + this.intValues.put(2, value3); + this.dirty = true; + } + + @Override + public final void set(float[] values) { + if (values.length < this.type.count()) { + LOGGER.warn("Uniform.set called with a too-small value array (expected {}, got {}). Ignoring.", this.type.count(), values.length); + } else { + this.floatValues.position(0); + this.floatValues.put(values); + this.floatValues.position(0); + this.dirty = true; + } + } + + @Override + public final void set(int[] values) { + if (values.length < this.type.count()) { + LOGGER.warn("Uniform.set called with a too-small value array (expected {}, got {}). Ignoring.", this.type.count(), values.length); + } else { + this.intValues.position(0); + this.intValues.put(values); + this.intValues.position(0); + this.dirty = true; + } + } + + @Override + public final void set(Matrix4f values) { + this.floatValues.position(0); + values.get(this.floatValues); + this.dirty = true; + } + + public void upload() { + if (this.dirty) { + if (this.type.isIntStorage()) { + switch (this.type) { + case INT: + GlStateManager._glUniform1(this.location, this.intValues); + break; + case IVEC3: + GlStateManager._glUniform3(this.location, this.intValues); + } + } else { + switch (this.type) { + case FLOAT: + GlStateManager._glUniform1(this.location, this.floatValues); + break; + case VEC2: + GlStateManager._glUniform2(this.location, this.floatValues); + break; + case VEC3: + GlStateManager._glUniform3(this.location, this.floatValues); + break; + case VEC4: + GlStateManager._glUniform4(this.location, this.floatValues); + break; + case MATRIX4X4: + GlStateManager._glUniformMatrix4(this.location, this.floatValues); + } + } + + this.dirty = false; + } + } +} diff --git a/com/mojang/blaze3d/opengl/VertexArrayCache.java b/com/mojang/blaze3d/opengl/VertexArrayCache.java new file mode 100644 index 00000000..f7c25b9c --- /dev/null +++ b/com/mojang/blaze3d/opengl/VertexArrayCache.java @@ -0,0 +1,175 @@ +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.vertex.VertexFormat; +import com.mojang.blaze3d.vertex.VertexFormatElement; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import java.util.Set; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; +import org.lwjgl.opengl.ARBVertexAttribBinding; +import org.lwjgl.opengl.GLCapabilities; + +@Environment(EnvType.CLIENT) +public abstract class VertexArrayCache { + public static VertexArrayCache create(GLCapabilities capabilities, GlDebugLabel debugLabel, Set enabledExtensions) { + if (capabilities.GL_ARB_vertex_attrib_binding && GlDevice.USE_GL_ARB_vertex_attrib_binding) { + enabledExtensions.add("GL_ARB_vertex_attrib_binding"); + return new VertexArrayCache.Separate(debugLabel); + } else { + return new VertexArrayCache.Emulated(debugLabel); + } + } + + public abstract void bindVertexArray(VertexFormat format, GlBuffer buffer); + + @Environment(EnvType.CLIENT) + static class Emulated extends VertexArrayCache { + private final Map cache = new HashMap(); + private final GlDebugLabel debugLabels; + + public Emulated(GlDebugLabel debugLabels) { + this.debugLabels = debugLabels; + } + + @Override + public void bindVertexArray(VertexFormat format, GlBuffer buffer) { + VertexArrayCache.VertexArray vertexArray = (VertexArrayCache.VertexArray)this.cache.get(format); + if (vertexArray == null) { + int i = GlStateManager._glGenVertexArrays(); + GlStateManager._glBindVertexArray(i); + GlStateManager._glBindBuffer(34962, buffer.handle); + setupCombinedAttributes(format, true); + VertexArrayCache.VertexArray vertexArray2 = new VertexArrayCache.VertexArray(i, format, buffer); + this.debugLabels.applyLabel(vertexArray2); + this.cache.put(format, vertexArray2); + } else { + GlStateManager._glBindVertexArray(vertexArray.id); + if (vertexArray.lastVertexBuffer != buffer) { + GlStateManager._glBindBuffer(34962, buffer.handle); + vertexArray.lastVertexBuffer = buffer; + setupCombinedAttributes(format, false); + } + } + } + + private static void setupCombinedAttributes(VertexFormat vertexFormat, boolean enabled) { + int i = vertexFormat.getVertexSize(); + List list = vertexFormat.getElements(); + + for (int j = 0; j < list.size(); j++) { + VertexFormatElement vertexFormatElement = (VertexFormatElement)list.get(j); + if (enabled) { + GlStateManager._enableVertexAttribArray(j); + } + + switch (vertexFormatElement.usage()) { + case POSITION: + case GENERIC: + GlStateManager._vertexAttribPointer( + j, vertexFormatElement.count(), GlConst.toGl(vertexFormatElement.type()), false, i, vertexFormat.getOffset(vertexFormatElement) + ); + break; + case NORMAL: + case COLOR: + GlStateManager._vertexAttribPointer( + j, vertexFormatElement.count(), GlConst.toGl(vertexFormatElement.type()), true, i, vertexFormat.getOffset(vertexFormatElement) + ); + break; + case UV: + if (vertexFormatElement.type() == VertexFormatElement.Type.FLOAT) { + GlStateManager._vertexAttribPointer( + j, vertexFormatElement.count(), GlConst.toGl(vertexFormatElement.type()), false, i, vertexFormat.getOffset(vertexFormatElement) + ); + } else { + GlStateManager._vertexAttribIPointer( + j, vertexFormatElement.count(), GlConst.toGl(vertexFormatElement.type()), i, vertexFormat.getOffset(vertexFormatElement) + ); + } + } + } + } + } + + @Environment(EnvType.CLIENT) + static class Separate extends VertexArrayCache { + private final Map cache = new HashMap(); + private final GlDebugLabel debugLabels; + + public Separate(GlDebugLabel debugLabels) { + this.debugLabels = debugLabels; + } + + @Override + public void bindVertexArray(VertexFormat format, GlBuffer buffer) { + VertexArrayCache.VertexArray vertexArray = (VertexArrayCache.VertexArray)this.cache.get(format); + if (vertexArray == null) { + int i = GlStateManager._glGenVertexArrays(); + GlStateManager._glBindVertexArray(i); + ARBVertexAttribBinding.glBindVertexBuffer(0, buffer.handle, 0L, format.getVertexSize()); + List list = format.getElements(); + + for (int j = 0; j < list.size(); j++) { + VertexFormatElement vertexFormatElement = (VertexFormatElement)list.get(j); + GlStateManager._enableVertexAttribArray(j); + switch (vertexFormatElement.usage()) { + case POSITION: + case GENERIC: + ARBVertexAttribBinding.glVertexAttribFormat( + j, vertexFormatElement.count(), GlConst.toGl(vertexFormatElement.type()), false, format.getOffset(vertexFormatElement) + ); + break; + case NORMAL: + case COLOR: + ARBVertexAttribBinding.glVertexAttribFormat( + j, vertexFormatElement.count(), GlConst.toGl(vertexFormatElement.type()), true, format.getOffset(vertexFormatElement) + ); + break; + case UV: + if (vertexFormatElement.type() == VertexFormatElement.Type.FLOAT) { + ARBVertexAttribBinding.glVertexAttribFormat( + j, vertexFormatElement.count(), GlConst.toGl(vertexFormatElement.type()), false, format.getOffset(vertexFormatElement) + ); + } else { + ARBVertexAttribBinding.glVertexAttribIFormat( + j, vertexFormatElement.count(), GlConst.toGl(vertexFormatElement.type()), format.getOffset(vertexFormatElement) + ); + } + } + + ARBVertexAttribBinding.glVertexAttribBinding(j, 0); + } + + VertexArrayCache.VertexArray vertexArray2 = new VertexArrayCache.VertexArray(i, format, buffer); + this.debugLabels.applyLabel(vertexArray2); + this.cache.put(format, vertexArray2); + } else { + GlStateManager._glBindVertexArray(vertexArray.id); + if (vertexArray.lastVertexBuffer != buffer) { + if (vertexArray.lastVertexBuffer != null && vertexArray.lastVertexBuffer.handle == buffer.handle) { + ARBVertexAttribBinding.glBindVertexBuffer(0, 0, 0L, 0); + } + + ARBVertexAttribBinding.glBindVertexBuffer(0, buffer.handle, 0L, format.getVertexSize()); + vertexArray.lastVertexBuffer = buffer; + } + } + } + } + + @Environment(EnvType.CLIENT) + public static class VertexArray { + final int id; + final VertexFormat format; + @Nullable + GlBuffer lastVertexBuffer; + + VertexArray(int id, VertexFormat format, @Nullable GlBuffer lastVertexBuffer) { + this.id = id; + this.format = format; + this.lastVertexBuffer = lastVertexBuffer; + } + } +} diff --git a/com/mojang/blaze3d/opengl/package-info.java b/com/mojang/blaze3d/opengl/package-info.java new file mode 100644 index 00000000..39bdd525 --- /dev/null +++ b/com/mojang/blaze3d/opengl/package-info.java @@ -0,0 +1,11 @@ +@ParametersAreNonnullByDefault +@MethodsReturnNonnullByDefault +@FieldsAreNonnullByDefault +@Environment(EnvType.CLIENT) +package com.mojang.blaze3d.opengl; + +import com.mojang.blaze3d.FieldsAreNonnullByDefault; +import com.mojang.blaze3d.MethodsReturnNonnullByDefault; +import javax.annotation.ParametersAreNonnullByDefault; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; diff --git a/com/mojang/blaze3d/pipeline/BlendFunction.java b/com/mojang/blaze3d/pipeline/BlendFunction.java new file mode 100644 index 00000000..a8b7ccbd --- /dev/null +++ b/com/mojang/blaze3d/pipeline/BlendFunction.java @@ -0,0 +1,27 @@ +package com.mojang.blaze3d.pipeline; + +import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.platform.DestFactor; +import com.mojang.blaze3d.platform.SourceFactor; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public record BlendFunction(SourceFactor sourceColor, DestFactor destColor, SourceFactor sourceAlpha, DestFactor destAlpha) { + public static final BlendFunction LIGHTNING = new BlendFunction(SourceFactor.SRC_ALPHA, DestFactor.ONE); + public static final BlendFunction GLINT = new BlendFunction(SourceFactor.SRC_COLOR, DestFactor.ONE, SourceFactor.ZERO, DestFactor.ONE); + public static final BlendFunction OVERLAY = new BlendFunction(SourceFactor.SRC_ALPHA, DestFactor.ONE, SourceFactor.ONE, DestFactor.ZERO); + public static final BlendFunction TRANSLUCENT = new BlendFunction( + SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA, SourceFactor.ONE, DestFactor.ONE_MINUS_SRC_ALPHA + ); + public static final BlendFunction ADDITIVE = new BlendFunction(SourceFactor.ONE, DestFactor.ONE); + public static final BlendFunction PANORAMA = new BlendFunction(SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA, SourceFactor.ONE, DestFactor.ZERO); + public static final BlendFunction ENTITY_OUTLINE_BLIT = new BlendFunction( + SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA, SourceFactor.ZERO, DestFactor.ONE + ); + + public BlendFunction(SourceFactor sourceFactor, DestFactor destFactor) { + this(sourceFactor, destFactor, sourceFactor, destFactor); + } +} diff --git a/com/mojang/blaze3d/pipeline/CompiledRenderPipeline.java b/com/mojang/blaze3d/pipeline/CompiledRenderPipeline.java new file mode 100644 index 00000000..1b3861c0 --- /dev/null +++ b/com/mojang/blaze3d/pipeline/CompiledRenderPipeline.java @@ -0,0 +1,13 @@ +package com.mojang.blaze3d.pipeline; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public interface CompiledRenderPipeline { + boolean containsUniform(String string); + + boolean isValid(); +} diff --git a/com/mojang/blaze3d/pipeline/MainTarget.java b/com/mojang/blaze3d/pipeline/MainTarget.java index b7f173e8..d5a77a23 100644 --- a/com/mojang/blaze3d/pipeline/MainTarget.java +++ b/com/mojang/blaze3d/pipeline/MainTarget.java @@ -1,13 +1,17 @@ package com.mojang.blaze3d.pipeline; import com.google.common.collect.ImmutableList; -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.platform.TextureUtil; +import com.mojang.blaze3d.GpuOutOfMemoryException; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.AddressMode; +import com.mojang.blaze3d.textures.FilterMode; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.textures.TextureFormat; import java.util.List; import java.util.Objects; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class MainTarget extends RenderTarget { @@ -16,87 +20,71 @@ public class MainTarget extends RenderTarget { static final MainTarget.Dimension DEFAULT_DIMENSIONS = new MainTarget.Dimension(854, 480); public MainTarget(int width, int height) { - super(true); + super("Main", true); this.createFrameBuffer(width, height); } private void createFrameBuffer(int width, int height) { MainTarget.Dimension dimension = this.allocateAttachments(width, height); - this.frameBufferId = GlStateManager.glGenFramebuffers(); - GlStateManager._glBindFramebuffer(36160, this.frameBufferId); - GlStateManager._bindTexture(this.colorTextureId); - GlStateManager._texParameter(3553, 10241, 9728); - GlStateManager._texParameter(3553, 10240, 9728); - GlStateManager._texParameter(3553, 10242, 33071); - GlStateManager._texParameter(3553, 10243, 33071); - GlStateManager._glFramebufferTexture2D(36160, 36064, 3553, this.colorTextureId, 0); - GlStateManager._bindTexture(this.depthBufferId); - GlStateManager._texParameter(3553, 34892, 0); - GlStateManager._texParameter(3553, 10241, 9728); - GlStateManager._texParameter(3553, 10240, 9728); - GlStateManager._texParameter(3553, 10242, 33071); - GlStateManager._texParameter(3553, 10243, 33071); - GlStateManager._glFramebufferTexture2D(36160, 36096, 3553, this.depthBufferId, 0); - GlStateManager._bindTexture(0); - this.viewWidth = dimension.width; - this.viewHeight = dimension.height; - this.width = dimension.width; - this.height = dimension.height; - this.checkStatus(); - GlStateManager._glBindFramebuffer(36160, 0); + if (this.colorTexture != null && this.depthTexture != null) { + this.colorTexture.setTextureFilter(FilterMode.NEAREST, false); + this.colorTexture.setAddressMode(AddressMode.CLAMP_TO_EDGE); + this.colorTexture.setTextureFilter(FilterMode.NEAREST, false); + this.colorTexture.setAddressMode(AddressMode.CLAMP_TO_EDGE); + this.viewWidth = dimension.width; + this.viewHeight = dimension.height; + this.width = dimension.width; + this.height = dimension.height; + } else { + throw new IllegalStateException("Missing color and/or depth textures"); + } } private MainTarget.Dimension allocateAttachments(int width, int height) { - RenderSystem.assertOnRenderThreadOrInit(); - this.colorTextureId = TextureUtil.generateTextureId(); - this.depthBufferId = TextureUtil.generateTextureId(); - MainTarget.AttachmentState attachmentState = MainTarget.AttachmentState.NONE; + RenderSystem.assertOnRenderThread(); for (MainTarget.Dimension dimension : MainTarget.Dimension.listWithFallback(width, height)) { - attachmentState = MainTarget.AttachmentState.NONE; - if (this.allocateColorAttachment(dimension)) { - attachmentState = attachmentState.with(MainTarget.AttachmentState.COLOR); + if (this.colorTexture != null) { + this.colorTexture.close(); + this.colorTexture = null; } - if (this.allocateDepthAttachment(dimension)) { - attachmentState = attachmentState.with(MainTarget.AttachmentState.DEPTH); + if (this.depthTexture != null) { + this.depthTexture.close(); + this.depthTexture = null; } - if (attachmentState == MainTarget.AttachmentState.COLOR_DEPTH) { + this.colorTexture = this.allocateColorAttachment(dimension); + this.depthTexture = this.allocateDepthAttachment(dimension); + if (this.colorTexture != null && this.depthTexture != null) { return dimension; } } - throw new RuntimeException("Unrecoverable GL_OUT_OF_MEMORY (allocated attachments = " + attachmentState.name() + ")"); + throw new RuntimeException( + "Unrecoverable GL_OUT_OF_MEMORY (" + + (this.colorTexture == null ? "missing color" : "have color") + + ", " + + (this.depthTexture == null ? "missing depth" : "have depth") + + ")" + ); } - private boolean allocateColorAttachment(MainTarget.Dimension dimension) { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._getError(); - GlStateManager._bindTexture(this.colorTextureId); - GlStateManager._texImage2D(3553, 0, 32856, dimension.width, dimension.height, 0, 6408, 5121, null); - return GlStateManager._getError() != 1285; + @Nullable + private GpuTexture allocateColorAttachment(MainTarget.Dimension dimension) { + try { + return RenderSystem.getDevice().createTexture(() -> this.label + " / Color", TextureFormat.RGBA8, dimension.width, dimension.height, 1); + } catch (GpuOutOfMemoryException var3) { + return null; + } } - private boolean allocateDepthAttachment(MainTarget.Dimension dimension) { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._getError(); - GlStateManager._bindTexture(this.depthBufferId); - GlStateManager._texImage2D(3553, 0, 6402, dimension.width, dimension.height, 0, 6402, 5126, null); - return GlStateManager._getError() != 1285; - } - - @Environment(EnvType.CLIENT) - static enum AttachmentState { - NONE, - COLOR, - DEPTH, - COLOR_DEPTH; - - private static final MainTarget.AttachmentState[] VALUES = values(); - - MainTarget.AttachmentState with(MainTarget.AttachmentState otherState) { - return VALUES[this.ordinal() | otherState.ordinal()]; + @Nullable + private GpuTexture allocateDepthAttachment(MainTarget.Dimension dimension) { + try { + return RenderSystem.getDevice().createTexture(() -> this.label + " / Depth", TextureFormat.DEPTH32, dimension.width, dimension.height, 1); + } catch (GpuOutOfMemoryException var3) { + return null; } } @@ -111,8 +99,8 @@ public class MainTarget extends RenderTarget { } static List listWithFallback(int width, int height) { - RenderSystem.assertOnRenderThreadOrInit(); - int i = RenderSystem.maxSupportedTextureSize(); + RenderSystem.assertOnRenderThread(); + int i = RenderSystem.getDevice().getMaxTextureSize(); return width > 0 && width <= i && height > 0 && height <= i ? ImmutableList.of(new MainTarget.Dimension(width, height), MainTarget.DEFAULT_DIMENSIONS) : ImmutableList.of(MainTarget.DEFAULT_DIMENSIONS); diff --git a/com/mojang/blaze3d/pipeline/RenderCall.java b/com/mojang/blaze3d/pipeline/RenderCall.java deleted file mode 100644 index 957fcc11..00000000 --- a/com/mojang/blaze3d/pipeline/RenderCall.java +++ /dev/null @@ -1,9 +0,0 @@ -package com.mojang.blaze3d.pipeline; - -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; - -@Environment(EnvType.CLIENT) -public interface RenderCall { - void execute(); -} diff --git a/com/mojang/blaze3d/pipeline/RenderPipeline.java b/com/mojang/blaze3d/pipeline/RenderPipeline.java new file mode 100644 index 00000000..a5ca7f89 --- /dev/null +++ b/com/mojang/blaze3d/pipeline/RenderPipeline.java @@ -0,0 +1,488 @@ +package com.mojang.blaze3d.pipeline; + +import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.platform.DepthTestFunction; +import com.mojang.blaze3d.platform.LogicOp; +import com.mojang.blaze3d.platform.PolygonMode; +import com.mojang.blaze3d.shaders.UniformType; +import com.mojang.blaze3d.vertex.VertexFormat; +import java.util.ArrayList; +import java.util.Collection; +import java.util.Collections; +import java.util.List; +import java.util.Optional; +import java.util.Map.Entry; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.ShaderDefines; +import net.minecraft.resources.ResourceLocation; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public class RenderPipeline { + private final ResourceLocation location; + private final ResourceLocation vertexShader; + private final ResourceLocation fragmentShader; + private final ShaderDefines shaderDefines; + private final List samplers; + private final List uniforms; + private final DepthTestFunction depthTestFunction; + private final PolygonMode polygonMode; + private final boolean cull; + private final LogicOp colorLogic; + private final Optional blendFunction; + private final boolean writeColor; + private final boolean writeAlpha; + private final boolean writeDepth; + private final VertexFormat vertexFormat; + private final VertexFormat.Mode vertexFormatMode; + private final float depthBiasScaleFactor; + private final float depthBiasConstant; + + protected RenderPipeline( + ResourceLocation resourceLocation, + ResourceLocation resourceLocation2, + ResourceLocation resourceLocation3, + ShaderDefines shaderDefines, + List list, + List list2, + Optional optional, + DepthTestFunction depthTestFunction, + PolygonMode polygonMode, + boolean bl, + boolean bl2, + boolean bl3, + boolean bl4, + LogicOp logicOp, + VertexFormat vertexFormat, + VertexFormat.Mode mode, + float f, + float g + ) { + this.location = resourceLocation; + this.vertexShader = resourceLocation2; + this.fragmentShader = resourceLocation3; + this.shaderDefines = shaderDefines; + this.samplers = list; + this.uniforms = list2; + this.depthTestFunction = depthTestFunction; + this.polygonMode = polygonMode; + this.cull = bl; + this.blendFunction = optional; + this.writeColor = bl2; + this.writeAlpha = bl3; + this.writeDepth = bl4; + this.colorLogic = logicOp; + this.vertexFormat = vertexFormat; + this.vertexFormatMode = mode; + this.depthBiasScaleFactor = f; + this.depthBiasConstant = g; + } + + public String toString() { + return this.location.toString(); + } + + public DepthTestFunction getDepthTestFunction() { + return this.depthTestFunction; + } + + public PolygonMode getPolygonMode() { + return this.polygonMode; + } + + public boolean isCull() { + return this.cull; + } + + public LogicOp getColorLogic() { + return this.colorLogic; + } + + public Optional getBlendFunction() { + return this.blendFunction; + } + + public boolean isWriteColor() { + return this.writeColor; + } + + public boolean isWriteAlpha() { + return this.writeAlpha; + } + + public boolean isWriteDepth() { + return this.writeDepth; + } + + public float getDepthBiasScaleFactor() { + return this.depthBiasScaleFactor; + } + + public float getDepthBiasConstant() { + return this.depthBiasConstant; + } + + public ResourceLocation getLocation() { + return this.location; + } + + public VertexFormat getVertexFormat() { + return this.vertexFormat; + } + + public VertexFormat.Mode getVertexFormatMode() { + return this.vertexFormatMode; + } + + public ResourceLocation getVertexShader() { + return this.vertexShader; + } + + public ResourceLocation getFragmentShader() { + return this.fragmentShader; + } + + public ShaderDefines getShaderDefines() { + return this.shaderDefines; + } + + public List getSamplers() { + return this.samplers; + } + + public List getUniforms() { + return this.uniforms; + } + + public boolean wantsDepthTexture() { + return this.depthTestFunction != DepthTestFunction.NO_DEPTH_TEST || this.depthBiasConstant != 0.0F || this.depthBiasScaleFactor != 0.0F || this.writeDepth; + } + + public static RenderPipeline.Builder builder(RenderPipeline.Snippet... snippets) { + RenderPipeline.Builder builder = new RenderPipeline.Builder(); + + for (RenderPipeline.Snippet snippet : snippets) { + builder.withSnippet(snippet); + } + + return builder; + } + + @Environment(EnvType.CLIENT) + @DontObfuscate + public static class Builder { + private Optional location = Optional.empty(); + private Optional fragmentShader = Optional.empty(); + private Optional vertexShader = Optional.empty(); + private Optional definesBuilder = Optional.empty(); + private Optional> samplers = Optional.empty(); + private Optional> uniforms = Optional.empty(); + private Optional depthTestFunction = Optional.empty(); + private Optional polygonMode = Optional.empty(); + private Optional cull = Optional.empty(); + private Optional writeColor = Optional.empty(); + private Optional writeAlpha = Optional.empty(); + private Optional writeDepth = Optional.empty(); + private Optional colorLogic = Optional.empty(); + private Optional blendFunction = Optional.empty(); + private Optional vertexFormat = Optional.empty(); + private Optional vertexFormatMode = Optional.empty(); + private float depthBiasScaleFactor; + private float depthBiasConstant; + + Builder() { + } + + public RenderPipeline.Builder withLocation(String string) { + this.location = Optional.of(ResourceLocation.withDefaultNamespace(string)); + return this; + } + + public RenderPipeline.Builder withLocation(ResourceLocation resourceLocation) { + this.location = Optional.of(resourceLocation); + return this; + } + + public RenderPipeline.Builder withFragmentShader(String string) { + this.fragmentShader = Optional.of(ResourceLocation.withDefaultNamespace(string)); + return this; + } + + public RenderPipeline.Builder withFragmentShader(ResourceLocation resourceLocation) { + this.fragmentShader = Optional.of(resourceLocation); + return this; + } + + public RenderPipeline.Builder withVertexShader(String string) { + this.vertexShader = Optional.of(ResourceLocation.withDefaultNamespace(string)); + return this; + } + + public RenderPipeline.Builder withVertexShader(ResourceLocation resourceLocation) { + this.vertexShader = Optional.of(resourceLocation); + return this; + } + + public RenderPipeline.Builder withShaderDefine(String string) { + if (this.definesBuilder.isEmpty()) { + this.definesBuilder = Optional.of(ShaderDefines.builder()); + } + + ((ShaderDefines.Builder)this.definesBuilder.get()).define(string); + return this; + } + + public RenderPipeline.Builder withShaderDefine(String string, int i) { + if (this.definesBuilder.isEmpty()) { + this.definesBuilder = Optional.of(ShaderDefines.builder()); + } + + ((ShaderDefines.Builder)this.definesBuilder.get()).define(string, i); + return this; + } + + public RenderPipeline.Builder withShaderDefine(String string, float f) { + if (this.definesBuilder.isEmpty()) { + this.definesBuilder = Optional.of(ShaderDefines.builder()); + } + + ((ShaderDefines.Builder)this.definesBuilder.get()).define(string, f); + return this; + } + + public RenderPipeline.Builder withSampler(String string) { + if (this.samplers.isEmpty()) { + this.samplers = Optional.of(new ArrayList()); + } + + ((List)this.samplers.get()).add(string); + return this; + } + + public RenderPipeline.Builder withUniform(String string, UniformType uniformType) { + if (this.uniforms.isEmpty()) { + this.uniforms = Optional.of(new ArrayList()); + } + + ((List)this.uniforms.get()).add(new RenderPipeline.UniformDescription(string, uniformType)); + return this; + } + + public RenderPipeline.Builder withDepthTestFunction(DepthTestFunction depthTestFunction) { + this.depthTestFunction = Optional.of(depthTestFunction); + return this; + } + + public RenderPipeline.Builder withPolygonMode(PolygonMode polygonMode) { + this.polygonMode = Optional.of(polygonMode); + return this; + } + + public RenderPipeline.Builder withCull(boolean bl) { + this.cull = Optional.of(bl); + return this; + } + + public RenderPipeline.Builder withBlend(BlendFunction blendFunction) { + this.blendFunction = Optional.of(blendFunction); + return this; + } + + public RenderPipeline.Builder withoutBlend() { + this.blendFunction = Optional.empty(); + return this; + } + + public RenderPipeline.Builder withColorWrite(boolean bl) { + this.writeColor = Optional.of(bl); + this.writeAlpha = Optional.of(bl); + return this; + } + + public RenderPipeline.Builder withColorWrite(boolean bl, boolean bl2) { + this.writeColor = Optional.of(bl); + this.writeAlpha = Optional.of(bl2); + return this; + } + + public RenderPipeline.Builder withDepthWrite(boolean bl) { + this.writeDepth = Optional.of(bl); + return this; + } + + public RenderPipeline.Builder withColorLogic(LogicOp logicOp) { + this.colorLogic = Optional.of(logicOp); + return this; + } + + public RenderPipeline.Builder withVertexFormat(VertexFormat vertexFormat, VertexFormat.Mode mode) { + this.vertexFormat = Optional.of(vertexFormat); + this.vertexFormatMode = Optional.of(mode); + return this; + } + + public RenderPipeline.Builder withDepthBias(float f, float g) { + this.depthBiasScaleFactor = f; + this.depthBiasConstant = g; + return this; + } + + void withSnippet(RenderPipeline.Snippet snippet) { + if (snippet.vertexShader.isPresent()) { + this.vertexShader = snippet.vertexShader; + } + + if (snippet.fragmentShader.isPresent()) { + this.fragmentShader = snippet.fragmentShader; + } + + if (snippet.shaderDefines.isPresent()) { + if (this.definesBuilder.isEmpty()) { + this.definesBuilder = Optional.of(ShaderDefines.builder()); + } + + ShaderDefines shaderDefines = (ShaderDefines)snippet.shaderDefines.get(); + + for (Entry entry : shaderDefines.values().entrySet()) { + ((ShaderDefines.Builder)this.definesBuilder.get()).define((String)entry.getKey(), (String)entry.getValue()); + } + + for (String string : shaderDefines.flags()) { + ((ShaderDefines.Builder)this.definesBuilder.get()).define(string); + } + } + + snippet.samplers.ifPresent(list -> { + if (this.samplers.isPresent()) { + ((List)this.samplers.get()).addAll(list); + } else { + this.samplers = Optional.of(new ArrayList(list)); + } + }); + snippet.uniforms.ifPresent(list -> { + if (this.uniforms.isPresent()) { + ((List)this.uniforms.get()).addAll(list); + } else { + this.uniforms = Optional.of(new ArrayList(list)); + } + }); + if (snippet.depthTestFunction.isPresent()) { + this.depthTestFunction = snippet.depthTestFunction; + } + + if (snippet.cull.isPresent()) { + this.cull = snippet.cull; + } + + if (snippet.writeColor.isPresent()) { + this.writeColor = snippet.writeColor; + } + + if (snippet.writeAlpha.isPresent()) { + this.writeAlpha = snippet.writeAlpha; + } + + if (snippet.writeDepth.isPresent()) { + this.writeDepth = snippet.writeDepth; + } + + if (snippet.colorLogic.isPresent()) { + this.colorLogic = snippet.colorLogic; + } + + if (snippet.blendFunction.isPresent()) { + this.blendFunction = snippet.blendFunction; + } + + if (snippet.vertexFormat.isPresent()) { + this.vertexFormat = snippet.vertexFormat; + } + + if (snippet.vertexFormatMode.isPresent()) { + this.vertexFormatMode = snippet.vertexFormatMode; + } + } + + public RenderPipeline.Snippet buildSnippet() { + return new RenderPipeline.Snippet( + this.vertexShader, + this.fragmentShader, + this.definesBuilder.map(ShaderDefines.Builder::build), + this.samplers.map(Collections::unmodifiableList), + this.uniforms.map(Collections::unmodifiableList), + this.blendFunction, + this.depthTestFunction, + this.polygonMode, + this.cull, + this.writeColor, + this.writeAlpha, + this.writeDepth, + this.colorLogic, + this.vertexFormat, + this.vertexFormatMode + ); + } + + public RenderPipeline build() { + if (this.location.isEmpty()) { + throw new IllegalStateException("Missing location"); + } else if (this.vertexShader.isEmpty()) { + throw new IllegalStateException("Missing vertex shader"); + } else if (this.fragmentShader.isEmpty()) { + throw new IllegalStateException("Missing fragment shader"); + } else if (this.vertexFormat.isEmpty()) { + throw new IllegalStateException("Missing vertex buffer format"); + } else if (this.vertexFormatMode.isEmpty()) { + throw new IllegalStateException("Missing vertex mode"); + } else { + return new RenderPipeline( + (ResourceLocation)this.location.get(), + (ResourceLocation)this.vertexShader.get(), + (ResourceLocation)this.fragmentShader.get(), + ((ShaderDefines.Builder)this.definesBuilder.orElse(ShaderDefines.builder())).build(), + List.copyOf((Collection)this.samplers.orElse(new ArrayList())), + (List)this.uniforms.orElse(Collections.emptyList()), + this.blendFunction, + (DepthTestFunction)this.depthTestFunction.orElse(DepthTestFunction.LEQUAL_DEPTH_TEST), + (PolygonMode)this.polygonMode.orElse(PolygonMode.FILL), + (Boolean)this.cull.orElse(true), + (Boolean)this.writeColor.orElse(true), + (Boolean)this.writeAlpha.orElse(true), + (Boolean)this.writeDepth.orElse(true), + (LogicOp)this.colorLogic.orElse(LogicOp.NONE), + (VertexFormat)this.vertexFormat.get(), + (VertexFormat.Mode)this.vertexFormatMode.get(), + this.depthBiasScaleFactor, + this.depthBiasConstant + ); + } + } + } + + @Environment(EnvType.CLIENT) + @DontObfuscate + public record Snippet( + Optional vertexShader, + Optional fragmentShader, + Optional shaderDefines, + Optional> samplers, + Optional> uniforms, + Optional blendFunction, + Optional depthTestFunction, + Optional polygonMode, + Optional cull, + Optional writeColor, + Optional writeAlpha, + Optional writeDepth, + Optional colorLogic, + Optional vertexFormat, + Optional vertexFormatMode + ) { + } + + @Environment(EnvType.CLIENT) + @DontObfuscate + public record UniformDescription(String name, UniformType type) { + } +} diff --git a/com/mojang/blaze3d/pipeline/RenderTarget.java b/com/mojang/blaze3d/pipeline/RenderTarget.java index d5c183f9..585d1347 100644 --- a/com/mojang/blaze3d/pipeline/RenderTarget.java +++ b/com/mojang/blaze3d/pipeline/RenderTarget.java @@ -1,235 +1,136 @@ package com.mojang.blaze3d.pipeline; -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.platform.TextureUtil; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.blaze3d.systems.RenderSystem; -import com.mojang.blaze3d.vertex.BufferBuilder; -import com.mojang.blaze3d.vertex.BufferUploader; -import com.mojang.blaze3d.vertex.DefaultVertexFormat; +import com.mojang.blaze3d.textures.AddressMode; +import com.mojang.blaze3d.textures.FilterMode; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.textures.TextureFormat; import com.mojang.blaze3d.vertex.VertexFormat; -import java.util.Objects; +import java.util.OptionalInt; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.Util; -import net.minecraft.client.renderer.CompiledShaderProgram; -import net.minecraft.client.renderer.CoreShaders; +import net.minecraft.client.renderer.RenderPipelines; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public abstract class RenderTarget { - private static final int RED_CHANNEL = 0; - private static final int GREEN_CHANNEL = 1; - private static final int BLUE_CHANNEL = 2; - private static final int ALPHA_CHANNEL = 3; + private static int UNNAMED_RENDER_TARGETS = 0; public int width; public int height; public int viewWidth; public int viewHeight; + protected final String label; public final boolean useDepth; - public int frameBufferId; - protected int colorTextureId; - protected int depthBufferId; - private final float[] clearChannels = Util.make(() -> new float[]{1.0F, 1.0F, 1.0F, 0.0F}); - public int filterMode; + @Nullable + protected GpuTexture colorTexture; + @Nullable + protected GpuTexture depthTexture; + public FilterMode filterMode; - public RenderTarget(boolean useDepth) { + public RenderTarget(@Nullable String name, boolean useDepth) { + this.label = name == null ? "FBO " + UNNAMED_RENDER_TARGETS++ : name; this.useDepth = useDepth; - this.frameBufferId = -1; - this.colorTextureId = -1; - this.depthBufferId = -1; } public void resize(int width, int height) { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._enableDepthTest(); - if (this.frameBufferId >= 0) { - this.destroyBuffers(); - } - + RenderSystem.assertOnRenderThread(); + this.destroyBuffers(); this.createBuffers(width, height); - GlStateManager._glBindFramebuffer(36160, 0); } public void destroyBuffers() { - RenderSystem.assertOnRenderThreadOrInit(); - this.unbindRead(); - this.unbindWrite(); - if (this.depthBufferId > -1) { - TextureUtil.releaseTextureId(this.depthBufferId); - this.depthBufferId = -1; + RenderSystem.assertOnRenderThread(); + if (this.depthTexture != null) { + this.depthTexture.close(); + this.depthTexture = null; } - if (this.colorTextureId > -1) { - TextureUtil.releaseTextureId(this.colorTextureId); - this.colorTextureId = -1; - } - - if (this.frameBufferId > -1) { - GlStateManager._glBindFramebuffer(36160, 0); - GlStateManager._glDeleteFramebuffers(this.frameBufferId); - this.frameBufferId = -1; + if (this.colorTexture != null) { + this.colorTexture.close(); + this.colorTexture = null; } } public void copyDepthFrom(RenderTarget otherTarget) { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._glBindFramebuffer(36008, otherTarget.frameBufferId); - GlStateManager._glBindFramebuffer(36009, this.frameBufferId); - GlStateManager._glBlitFrameBuffer(0, 0, otherTarget.width, otherTarget.height, 0, 0, this.width, this.height, 256, 9728); - GlStateManager._glBindFramebuffer(36160, 0); + RenderSystem.assertOnRenderThread(); + if (this.depthTexture == null) { + throw new IllegalStateException("Trying to copy depth texture to a RenderTarget without a depth texture"); + } else if (otherTarget.depthTexture == null) { + throw new IllegalStateException("Trying to copy depth texture from a RenderTarget without a depth texture"); + } else { + RenderSystem.getDevice().createCommandEncoder().copyTextureToTexture(otherTarget.depthTexture, this.depthTexture, 0, 0, 0, 0, 0, this.width, this.height); + } } public void createBuffers(int width, int height) { - RenderSystem.assertOnRenderThreadOrInit(); - int i = RenderSystem.maxSupportedTextureSize(); + RenderSystem.assertOnRenderThread(); + int i = RenderSystem.getDevice().getMaxTextureSize(); if (width > 0 && width <= i && height > 0 && height <= i) { this.viewWidth = width; this.viewHeight = height; this.width = width; this.height = height; - this.frameBufferId = GlStateManager.glGenFramebuffers(); - this.colorTextureId = TextureUtil.generateTextureId(); if (this.useDepth) { - this.depthBufferId = TextureUtil.generateTextureId(); - GlStateManager._bindTexture(this.depthBufferId); - GlStateManager._texParameter(3553, 10241, 9728); - GlStateManager._texParameter(3553, 10240, 9728); - GlStateManager._texParameter(3553, 34892, 0); - GlStateManager._texParameter(3553, 10242, 33071); - GlStateManager._texParameter(3553, 10243, 33071); - GlStateManager._texImage2D(3553, 0, 6402, this.width, this.height, 0, 6402, 5126, null); + this.depthTexture = RenderSystem.getDevice().createTexture(() -> this.label + " / Depth", TextureFormat.DEPTH32, width, height, 1); + this.depthTexture.setTextureFilter(FilterMode.NEAREST, false); + this.depthTexture.setAddressMode(AddressMode.CLAMP_TO_EDGE); } - this.setFilterMode(9728, true); - GlStateManager._bindTexture(this.colorTextureId); - GlStateManager._texParameter(3553, 10242, 33071); - GlStateManager._texParameter(3553, 10243, 33071); - GlStateManager._texImage2D(3553, 0, 32856, this.width, this.height, 0, 6408, 5121, null); - GlStateManager._glBindFramebuffer(36160, this.frameBufferId); - GlStateManager._glFramebufferTexture2D(36160, 36064, 3553, this.colorTextureId, 0); - if (this.useDepth) { - GlStateManager._glFramebufferTexture2D(36160, 36096, 3553, this.depthBufferId, 0); - } - - this.checkStatus(); - this.clear(); - this.unbindRead(); + this.colorTexture = RenderSystem.getDevice().createTexture(() -> this.label + " / Color", TextureFormat.RGBA8, width, height, 1); + this.colorTexture.setAddressMode(AddressMode.CLAMP_TO_EDGE); + this.setFilterMode(FilterMode.NEAREST, true); } else { throw new IllegalArgumentException("Window " + width + "x" + height + " size out of bounds (max. size: " + i + ")"); } } - public void setFilterMode(int filterMode) { + public void setFilterMode(FilterMode filterMode) { this.setFilterMode(filterMode, false); } - private void setFilterMode(int filterMode, boolean force) { - RenderSystem.assertOnRenderThreadOrInit(); - if (force || filterMode != this.filterMode) { - this.filterMode = filterMode; - GlStateManager._bindTexture(this.colorTextureId); - GlStateManager._texParameter(3553, 10241, filterMode); - GlStateManager._texParameter(3553, 10240, filterMode); - GlStateManager._bindTexture(0); - } - } - - public void checkStatus() { - RenderSystem.assertOnRenderThreadOrInit(); - int i = GlStateManager.glCheckFramebufferStatus(36160); - if (i != 36053) { - if (i == 36054) { - throw new RuntimeException("GL_FRAMEBUFFER_INCOMPLETE_ATTACHMENT"); - } else if (i == 36055) { - throw new RuntimeException("GL_FRAMEBUFFER_INCOMPLETE_MISSING_ATTACHMENT"); - } else if (i == 36059) { - throw new RuntimeException("GL_FRAMEBUFFER_INCOMPLETE_DRAW_BUFFER"); - } else if (i == 36060) { - throw new RuntimeException("GL_FRAMEBUFFER_INCOMPLETE_READ_BUFFER"); - } else if (i == 36061) { - throw new RuntimeException("GL_FRAMEBUFFER_UNSUPPORTED"); - } else if (i == 1285) { - throw new RuntimeException("GL_OUT_OF_MEMORY"); - } else { - throw new RuntimeException("glCheckFramebufferStatus returned unknown status:" + i); + private void setFilterMode(FilterMode filterMode, boolean force) { + if (this.colorTexture == null) { + throw new IllegalStateException("Can't change filter mode, color texture doesn't exist yet"); + } else { + if (force || filterMode != this.filterMode) { + this.filterMode = filterMode; + this.colorTexture.setTextureFilter(filterMode, false); } } } - public void bindRead() { - RenderSystem.assertOnRenderThread(); - GlStateManager._bindTexture(this.colorTextureId); - } - - public void unbindRead() { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._bindTexture(0); - } - - public void bindWrite(boolean setViewport) { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._glBindFramebuffer(36160, this.frameBufferId); - if (setViewport) { - GlStateManager._viewport(0, 0, this.viewWidth, this.viewHeight); + public void blitToScreen() { + if (this.colorTexture == null) { + throw new IllegalStateException("Can't blit to screen, color texture doesn't exist yet"); + } else { + RenderSystem.getDevice().createCommandEncoder().presentTexture(this.colorTexture); } } - public void unbindWrite() { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._glBindFramebuffer(36160, 0); - } - - public void setClearColor(float red, float green, float blue, float alpha) { - this.clearChannels[0] = red; - this.clearChannels[1] = green; - this.clearChannels[2] = blue; - this.clearChannels[3] = alpha; - } - - public void blitToScreen(int width, int height) { - GlStateManager._glBindFramebuffer(36008, this.frameBufferId); - GlStateManager._glBlitFrameBuffer(0, 0, this.width, this.height, 0, 0, width, height, 16384, 9728); - GlStateManager._glBindFramebuffer(36008, 0); - } - - public void blitAndBlendToScreen(int width, int height) { + public void blitAndBlendToTexture(GpuTexture texture) { RenderSystem.assertOnRenderThread(); - GlStateManager._colorMask(true, true, true, false); - GlStateManager._disableDepthTest(); - GlStateManager._depthMask(false); - GlStateManager._viewport(0, 0, width, height); - CompiledShaderProgram compiledShaderProgram = (CompiledShaderProgram)Objects.requireNonNull( - RenderSystem.setShader(CoreShaders.BLIT_SCREEN), "Blit shader not loaded" - ); - compiledShaderProgram.bindSampler("InSampler", this.colorTextureId); - BufferBuilder bufferBuilder = RenderSystem.renderThreadTesselator().begin(VertexFormat.Mode.QUADS, DefaultVertexFormat.BLIT_SCREEN); - bufferBuilder.addVertex(0.0F, 0.0F, 0.0F); - bufferBuilder.addVertex(1.0F, 0.0F, 0.0F); - bufferBuilder.addVertex(1.0F, 1.0F, 0.0F); - bufferBuilder.addVertex(0.0F, 1.0F, 0.0F); - BufferUploader.drawWithShader(bufferBuilder.buildOrThrow()); - GlStateManager._depthMask(true); - GlStateManager._colorMask(true, true, true, true); - } + RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(VertexFormat.Mode.QUADS); + GpuBuffer gpuBuffer = autoStorageIndexBuffer.getBuffer(6); + GpuBuffer gpuBuffer2 = RenderSystem.getQuadVertexBuffer(); - public void clear() { - RenderSystem.assertOnRenderThreadOrInit(); - this.bindWrite(true); - GlStateManager._clearColor(this.clearChannels[0], this.clearChannels[1], this.clearChannels[2], this.clearChannels[3]); - int i = 16384; - if (this.useDepth) { - GlStateManager._clearDepth(1.0); - i |= 256; + try (RenderPass renderPass = RenderSystem.getDevice().createCommandEncoder().createRenderPass(texture, OptionalInt.empty())) { + renderPass.setPipeline(RenderPipelines.ENTITY_OUTLINE_BLIT); + renderPass.setVertexBuffer(0, gpuBuffer2); + renderPass.setIndexBuffer(gpuBuffer, autoStorageIndexBuffer.type()); + renderPass.bindSampler("InSampler", this.colorTexture); + renderPass.drawIndexed(0, 6); } - - GlStateManager._clear(i); - this.unbindWrite(); } - public int getColorTextureId() { - return this.colorTextureId; + @Nullable + public GpuTexture getColorTexture() { + return this.colorTexture; } - public int getDepthTextureId() { - return this.depthBufferId; + @Nullable + public GpuTexture getDepthTexture() { + return this.depthTexture; } } diff --git a/com/mojang/blaze3d/pipeline/TextureTarget.java b/com/mojang/blaze3d/pipeline/TextureTarget.java index fbd5c34a..9a197c93 100644 --- a/com/mojang/blaze3d/pipeline/TextureTarget.java +++ b/com/mojang/blaze3d/pipeline/TextureTarget.java @@ -3,12 +3,13 @@ package com.mojang.blaze3d.pipeline; import com.mojang.blaze3d.systems.RenderSystem; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class TextureTarget extends RenderTarget { - public TextureTarget(int width, int height, boolean useDepth) { - super(useDepth); - RenderSystem.assertOnRenderThreadOrInit(); + public TextureTarget(@Nullable String name, int width, int height, boolean useDepth) { + super(name, useDepth); + RenderSystem.assertOnRenderThread(); this.resize(width, height); } } diff --git a/com/mojang/blaze3d/platform/DepthTestFunction.java b/com/mojang/blaze3d/platform/DepthTestFunction.java new file mode 100644 index 00000000..d90b0ab1 --- /dev/null +++ b/com/mojang/blaze3d/platform/DepthTestFunction.java @@ -0,0 +1,15 @@ +package com.mojang.blaze3d.platform; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum DepthTestFunction { + NO_DEPTH_TEST, + EQUAL_DEPTH_TEST, + LEQUAL_DEPTH_TEST, + LESS_DEPTH_TEST, + GREATER_DEPTH_TEST; +} diff --git a/com/mojang/blaze3d/platform/DestFactor.java b/com/mojang/blaze3d/platform/DestFactor.java new file mode 100644 index 00000000..5d9b6ab4 --- /dev/null +++ b/com/mojang/blaze3d/platform/DestFactor.java @@ -0,0 +1,24 @@ +package com.mojang.blaze3d.platform; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum DestFactor { + CONSTANT_ALPHA, + CONSTANT_COLOR, + DST_ALPHA, + DST_COLOR, + ONE, + ONE_MINUS_CONSTANT_ALPHA, + ONE_MINUS_CONSTANT_COLOR, + ONE_MINUS_DST_ALPHA, + ONE_MINUS_DST_COLOR, + ONE_MINUS_SRC_ALPHA, + ONE_MINUS_SRC_COLOR, + SRC_ALPHA, + SRC_COLOR, + ZERO; +} diff --git a/com/mojang/blaze3d/platform/DisplayData.java b/com/mojang/blaze3d/platform/DisplayData.java index b1db3451..bc445ee2 100644 --- a/com/mojang/blaze3d/platform/DisplayData.java +++ b/com/mojang/blaze3d/platform/DisplayData.java @@ -5,18 +5,12 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @Environment(EnvType.CLIENT) -public class DisplayData { - public final int width; - public final int height; - public final OptionalInt fullscreenWidth; - public final OptionalInt fullscreenHeight; - public final boolean isFullscreen; +public record DisplayData(int width, int height, OptionalInt fullscreenWidth, OptionalInt fullscreenHeight, boolean isFullscreen) { + public DisplayData withSize(int width, int height) { + return new DisplayData(width, height, this.fullscreenWidth, this.fullscreenHeight, this.isFullscreen); + } - public DisplayData(int width, int height, OptionalInt fullscreenWidth, OptionalInt fullscreenHeight, boolean isFullscreen) { - this.width = width; - this.height = height; - this.fullscreenWidth = fullscreenWidth; - this.fullscreenHeight = fullscreenHeight; - this.isFullscreen = isFullscreen; + public DisplayData withFullscreen(boolean fullscreen) { + return new DisplayData(this.width, this.height, this.fullscreenWidth, this.fullscreenHeight, fullscreen); } } diff --git a/com/mojang/blaze3d/platform/FramerateLimitTracker.java b/com/mojang/blaze3d/platform/FramerateLimitTracker.java index acbc459d..24d31888 100644 --- a/com/mojang/blaze3d/platform/FramerateLimitTracker.java +++ b/com/mojang/blaze3d/platform/FramerateLimitTracker.java @@ -27,25 +27,43 @@ public class FramerateLimitTracker { } public int getFramerateLimit() { + return switch (this.getThrottleReason()) { + case NONE -> this.framerateLimit; + case WINDOW_ICONIFIED -> 10; + case LONG_AFK -> 10; + case SHORT_AFK -> Math.min(this.framerateLimit, 30); + case OUT_OF_LEVEL_MENU -> 60; + }; + } + + public FramerateLimitTracker.FramerateThrottleReason getThrottleReason() { InactivityFpsLimit inactivityFpsLimit = this.options.inactivityFpsLimit().get(); if (this.minecraft.getWindow().isIconified()) { - return 10; + return FramerateLimitTracker.FramerateThrottleReason.WINDOW_ICONIFIED; } else { if (inactivityFpsLimit == InactivityFpsLimit.AFK) { long l = Util.getMillis() - this.latestInputTime; if (l > 600000L) { - return 10; + return FramerateLimitTracker.FramerateThrottleReason.LONG_AFK; } if (l > 60000L) { - return Math.min(this.framerateLimit, 30); + return FramerateLimitTracker.FramerateThrottleReason.SHORT_AFK; } } - return this.minecraft.level != null || this.minecraft.screen == null && this.minecraft.getOverlay() == null ? this.framerateLimit : 60; + return this.minecraft.level != null || this.minecraft.screen == null && this.minecraft.getOverlay() == null + ? FramerateLimitTracker.FramerateThrottleReason.NONE + : FramerateLimitTracker.FramerateThrottleReason.OUT_OF_LEVEL_MENU; } } + public boolean isHeavilyThrottled() { + FramerateLimitTracker.FramerateThrottleReason framerateThrottleReason = this.getThrottleReason(); + return framerateThrottleReason == FramerateLimitTracker.FramerateThrottleReason.WINDOW_ICONIFIED + || framerateThrottleReason == FramerateLimitTracker.FramerateThrottleReason.LONG_AFK; + } + public void setFramerateLimit(int framerateLimit) { this.framerateLimit = framerateLimit; } @@ -53,4 +71,13 @@ public class FramerateLimitTracker { public void onInputReceived() { this.latestInputTime = Util.getMillis(); } + + @Environment(EnvType.CLIENT) + public static enum FramerateThrottleReason { + NONE, + WINDOW_ICONIFIED, + LONG_AFK, + SHORT_AFK, + OUT_OF_LEVEL_MENU; + } } diff --git a/com/mojang/blaze3d/platform/GLX.java b/com/mojang/blaze3d/platform/GLX.java index d81e7dae..57aec956 100644 --- a/com/mojang/blaze3d/platform/GLX.java +++ b/com/mojang/blaze3d/platform/GLX.java @@ -4,11 +4,6 @@ import com.google.common.base.Joiner; import com.google.common.collect.Lists; import com.mojang.blaze3d.DontObfuscate; import com.mojang.blaze3d.systems.RenderSystem; -import com.mojang.blaze3d.vertex.BufferBuilder; -import com.mojang.blaze3d.vertex.BufferUploader; -import com.mojang.blaze3d.vertex.DefaultVertexFormat; -import com.mojang.blaze3d.vertex.Tesselator; -import com.mojang.blaze3d.vertex.VertexFormat; import com.mojang.logging.LogUtils; import java.util.List; import java.util.Locale; @@ -17,7 +12,7 @@ import java.util.function.LongSupplier; import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.CoreShaders; +import org.jetbrains.annotations.Nullable; import org.lwjgl.Version; import org.lwjgl.glfw.GLFW; import org.lwjgl.glfw.GLFWErrorCallback; @@ -32,15 +27,9 @@ import oshi.hardware.CentralProcessor; @DontObfuscate public class GLX { private static final Logger LOGGER = LogUtils.getLogger(); + @Nullable private static String cpuInfo; - public static String getOpenGLVersionString() { - RenderSystem.assertOnRenderThread(); - return GLFW.glfwGetCurrentContext() == 0L - ? "NO CONTEXT" - : GlStateManager._getString(7937) + " GL version " + GlStateManager._getString(7938) + ", " + GlStateManager._getString(7936); - } - public static int _getRefreshRate(Window window) { RenderSystem.assertOnRenderThread(); long l = GLFW.glfwGetWindowMonitor(window.getWindow()); @@ -90,68 +79,19 @@ public class GLX { return GLFW.glfwWindowShouldClose(window.getWindow()); } - public static void _init(int i, boolean bl) { - try { - CentralProcessor centralProcessor = new SystemInfo().getHardware().getProcessor(); - cpuInfo = String.format(Locale.ROOT, "%dx %s", centralProcessor.getLogicalProcessorCount(), centralProcessor.getProcessorIdentifier().getName()) - .replaceAll("\\s+", " "); - } catch (Throwable var3) { - } - - GlDebug.enableDebugCallback(i, bl); - } - public static String _getCpuInfo() { - return cpuInfo == null ? "" : cpuInfo; - } + if (cpuInfo == null) { + cpuInfo = ""; - public static void _renderCrosshair(int i, boolean bl, boolean bl2, boolean bl3) { - if (bl || bl2 || bl3) { - RenderSystem.assertOnRenderThread(); - GlStateManager._depthMask(false); - GlStateManager._disableCull(); - RenderSystem.setShader(CoreShaders.RENDERTYPE_LINES); - Tesselator tesselator = RenderSystem.renderThreadTesselator(); - BufferBuilder bufferBuilder = tesselator.begin(VertexFormat.Mode.LINES, DefaultVertexFormat.POSITION_COLOR_NORMAL); - RenderSystem.lineWidth(4.0F); - if (bl) { - bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-16777216).setNormal(1.0F, 0.0F, 0.0F); - bufferBuilder.addVertex(i, 0.0F, 0.0F).setColor(-16777216).setNormal(1.0F, 0.0F, 0.0F); + try { + CentralProcessor centralProcessor = new SystemInfo().getHardware().getProcessor(); + cpuInfo = String.format(Locale.ROOT, "%dx %s", centralProcessor.getLogicalProcessorCount(), centralProcessor.getProcessorIdentifier().getName()) + .replaceAll("\\s+", " "); + } catch (Throwable var1) { } - - if (bl2) { - bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-16777216).setNormal(0.0F, 1.0F, 0.0F); - bufferBuilder.addVertex(0.0F, i, 0.0F).setColor(-16777216).setNormal(0.0F, 1.0F, 0.0F); - } - - if (bl3) { - bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-16777216).setNormal(0.0F, 0.0F, 1.0F); - bufferBuilder.addVertex(0.0F, 0.0F, i).setColor(-16777216).setNormal(0.0F, 0.0F, 1.0F); - } - - BufferUploader.drawWithShader(bufferBuilder.buildOrThrow()); - RenderSystem.lineWidth(2.0F); - bufferBuilder = tesselator.begin(VertexFormat.Mode.LINES, DefaultVertexFormat.POSITION_COLOR_NORMAL); - if (bl) { - bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-65536).setNormal(1.0F, 0.0F, 0.0F); - bufferBuilder.addVertex(i, 0.0F, 0.0F).setColor(-65536).setNormal(1.0F, 0.0F, 0.0F); - } - - if (bl2) { - bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-16711936).setNormal(0.0F, 1.0F, 0.0F); - bufferBuilder.addVertex(0.0F, i, 0.0F).setColor(-16711936).setNormal(0.0F, 1.0F, 0.0F); - } - - if (bl3) { - bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-8421377).setNormal(0.0F, 0.0F, 1.0F); - bufferBuilder.addVertex(0.0F, 0.0F, i).setColor(-8421377).setNormal(0.0F, 0.0F, 1.0F); - } - - BufferUploader.drawWithShader(bufferBuilder.buildOrThrow()); - RenderSystem.lineWidth(1.0F); - GlStateManager._enableCull(); - GlStateManager._depthMask(true); } + + return cpuInfo; } public static T make(Supplier supplier) { diff --git a/com/mojang/blaze3d/platform/GlUtil.java b/com/mojang/blaze3d/platform/GlUtil.java deleted file mode 100644 index 024ab096..00000000 --- a/com/mojang/blaze3d/platform/GlUtil.java +++ /dev/null @@ -1,34 +0,0 @@ -package com.mojang.blaze3d.platform; - -import java.nio.Buffer; -import java.nio.ByteBuffer; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import org.lwjgl.system.MemoryUtil; - -@Environment(EnvType.CLIENT) -public class GlUtil { - public static ByteBuffer allocateMemory(int size) { - return MemoryUtil.memAlloc(size); - } - - public static void freeMemory(Buffer buffer) { - MemoryUtil.memFree(buffer); - } - - public static String getVendor() { - return GlStateManager._getString(7936); - } - - public static String getCpuInfo() { - return GLX._getCpuInfo(); - } - - public static String getRenderer() { - return GlStateManager._getString(7937); - } - - public static String getOpenGLVersion() { - return GlStateManager._getString(7938); - } -} diff --git a/com/mojang/blaze3d/platform/LogicOp.java b/com/mojang/blaze3d/platform/LogicOp.java new file mode 100644 index 00000000..5007400b --- /dev/null +++ b/com/mojang/blaze3d/platform/LogicOp.java @@ -0,0 +1,12 @@ +package com.mojang.blaze3d.platform; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum LogicOp { + NONE, + OR_REVERSE; +} diff --git a/com/mojang/blaze3d/platform/NativeImage.java b/com/mojang/blaze3d/platform/NativeImage.java index 543f2120..00229d9f 100644 --- a/com/mojang/blaze3d/platform/NativeImage.java +++ b/com/mojang/blaze3d/platform/NativeImage.java @@ -1,6 +1,5 @@ package com.mojang.blaze3d.platform; -import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.jtracy.MemoryPool; import com.mojang.jtracy.TracyClient; import com.mojang.logging.LogUtils; @@ -77,7 +76,7 @@ public final class NativeImage implements AutoCloseable { } } - private NativeImage(NativeImage.Format format, int width, int height, boolean useStbFree, long pixels) { + public NativeImage(NativeImage.Format format, int width, int height, boolean useStbFree, long pixels) { if (width > 0 && height > 0) { this.format = format; this.width = width; @@ -228,7 +227,7 @@ public final class NativeImage implements AutoCloseable { return ARGB.fromABGR(this.getPixelABGR(x, y)); } - private void setPixelABGR(int x, int y, int color) { + public void setPixelABGR(int x, int y, int color) { if (this.format != NativeImage.Format.RGBA) { throw new IllegalArgumentException(String.format(Locale.ROOT, "setPixelRGBA only works on RGBA images; have %s", this.format)); } else if (this.isOutsideBounds(x, y)) { @@ -264,22 +263,6 @@ public final class NativeImage implements AutoCloseable { } } - public void applyToAllPixels(IntUnaryOperator function) { - if (this.format != NativeImage.Format.RGBA) { - throw new IllegalArgumentException(String.format(Locale.ROOT, "function application only works on RGBA images; have %s", this.format)); - } else { - this.checkAllocated(); - int i = this.width * this.height; - IntBuffer intBuffer = MemoryUtil.memIntBuffer(this.pixels, i); - - for (int j = 0; j < i; j++) { - int k = ARGB.fromABGR(intBuffer.get(j)); - int l = function.applyAsInt(k); - intBuffer.put(j, ARGB.toABGR(l)); - } - } - } - public int[] getPixelsABGR() { if (this.format != NativeImage.Format.RGBA) { throw new IllegalArgumentException(String.format(Locale.ROOT, "getPixels only works on RGBA images; have %s", this.format)); @@ -330,70 +313,6 @@ public final class NativeImage implements AutoCloseable { } } - public void upload(int level, int xOffset, int yOffset, boolean mipmap) { - this.upload(level, xOffset, yOffset, 0, 0, this.width, this.height, mipmap); - } - - public void upload(int level, int xOffset, int yOffset, int unpackSkipPixels, int unpackSkipRows, int width, int height, boolean autoClose) { - if (!RenderSystem.isOnRenderThreadOrInit()) { - RenderSystem.recordRenderCall(() -> this._upload(level, xOffset, yOffset, unpackSkipPixels, unpackSkipRows, width, height, autoClose)); - } else { - this._upload(level, xOffset, yOffset, unpackSkipPixels, unpackSkipRows, width, height, autoClose); - } - } - - private void _upload(int level, int xOffset, int yOffset, int unpackSkipPixels, int unpackSkipRows, int width, int height, boolean autoClose) { - try { - RenderSystem.assertOnRenderThreadOrInit(); - this.checkAllocated(); - if (width == this.getWidth()) { - GlStateManager._pixelStore(3314, 0); - } else { - GlStateManager._pixelStore(3314, this.getWidth()); - } - - GlStateManager._pixelStore(3316, unpackSkipPixels); - GlStateManager._pixelStore(3315, unpackSkipRows); - this.format.setUnpackPixelStoreState(); - GlStateManager._texSubImage2D(3553, level, xOffset, yOffset, width, height, this.format.glFormat(), 5121, this.pixels); - } finally { - if (autoClose) { - this.close(); - } - } - } - - public void downloadTexture(int level, boolean opaque) { - RenderSystem.assertOnRenderThread(); - this.checkAllocated(); - this.format.setPackPixelStoreState(); - GlStateManager._getTexImage(3553, level, this.format.glFormat(), 5121, this.pixels); - if (opaque && this.format.hasAlpha()) { - for (int i = 0; i < this.getHeight(); i++) { - for (int j = 0; j < this.getWidth(); j++) { - this.setPixelABGR(j, i, this.getPixelABGR(j, i) | 255 << this.format.alphaOffset()); - } - } - } - } - - public void downloadDepthBuffer(float unused) { - RenderSystem.assertOnRenderThread(); - if (this.format.components() != 1) { - throw new IllegalStateException("Depth buffer must be stored in NativeImage with 1 component."); - } else { - this.checkAllocated(); - this.format.setPackPixelStoreState(); - GlStateManager._readPixels(0, 0, this.width, this.height, 6402, 5121, this.pixels); - } - } - - public void drawPixels() { - RenderSystem.assertOnRenderThread(); - this.format.setUnpackPixelStoreState(); - GlStateManager._glDrawPixels(this.width, this.height, this.format.glFormat(), 5121, this.pixels); - } - public void writeToFile(File file) throws IOException { this.writeToFile(file.toPath()); } @@ -520,25 +439,6 @@ public final class NativeImage implements AutoCloseable { } } - public void flipY() { - this.checkAllocated(); - int i = this.format.components(); - int j = this.getWidth() * i; - long l = MemoryUtil.nmemAlloc(j); - - try { - for (int k = 0; k < this.getHeight() / 2; k++) { - int m = k * this.getWidth() * i; - int n = (this.getHeight() - 1 - k) * this.getWidth() * i; - MemoryUtil.memCopy(this.pixels + m, l, j); - MemoryUtil.memCopy(this.pixels + n, this.pixels + m, j); - MemoryUtil.memCopy(l, this.pixels + n, j); - } - } finally { - MemoryUtil.nmemFree(l); - } - } - public void resizeSubRectTo(int x, int y, int width, int height, NativeImage image) { this.checkAllocated(); if (image.format() != this.format) { @@ -555,15 +455,18 @@ public final class NativeImage implements AutoCloseable { DebugMemoryUntracker.untrack(this.pixels); } + public long getPointer() { + return this.pixels; + } + @Environment(EnvType.CLIENT) public static enum Format { - RGBA(4, 6408, true, true, true, false, true, 0, 8, 16, 255, 24, true), - RGB(3, 6407, true, true, true, false, false, 0, 8, 16, 255, 255, true), - LUMINANCE_ALPHA(2, 33319, false, false, false, true, true, 255, 255, 255, 0, 8, true), - LUMINANCE(1, 6403, false, false, false, true, false, 0, 0, 0, 0, 255, true); + RGBA(4, true, true, true, false, true, 0, 8, 16, 255, 24, true), + RGB(3, true, true, true, false, false, 0, 8, 16, 255, 255, true), + LUMINANCE_ALPHA(2, false, false, false, true, true, 255, 255, 255, 0, 8, true), + LUMINANCE(1, false, false, false, true, false, 0, 0, 0, 0, 255, true); final int components; - private final int glFormat; private final boolean hasRed; private final boolean hasGreen; private final boolean hasBlue; @@ -578,7 +481,6 @@ public final class NativeImage implements AutoCloseable { private Format( final int components, - final int glFormat, final boolean hasRed, final boolean hasGreen, final boolean hasBlue, @@ -592,7 +494,6 @@ public final class NativeImage implements AutoCloseable { final boolean supportedByStb ) { this.components = components; - this.glFormat = glFormat; this.hasRed = hasRed; this.hasGreen = hasGreen; this.hasBlue = hasBlue; @@ -610,20 +511,6 @@ public final class NativeImage implements AutoCloseable { return this.components; } - public void setPackPixelStoreState() { - RenderSystem.assertOnRenderThread(); - GlStateManager._pixelStore(3333, this.components()); - } - - public void setUnpackPixelStoreState() { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._pixelStore(3317, this.components()); - } - - public int glFormat() { - return this.glFormat; - } - public boolean hasRed() { return this.hasRed; } @@ -715,24 +602,6 @@ public final class NativeImage implements AutoCloseable { } } - @Environment(EnvType.CLIENT) - public static enum InternalGlFormat { - RGBA(6408), - RGB(6407), - RG(33319), - RED(6403); - - private final int glFormat; - - private InternalGlFormat(final int glFormat) { - this.glFormat = glFormat; - } - - public int glFormat() { - return this.glFormat; - } - } - @Environment(EnvType.CLIENT) static class WriteCallback extends STBIWriteCallback { private final WritableByteChannel output; diff --git a/com/mojang/blaze3d/platform/PolygonMode.java b/com/mojang/blaze3d/platform/PolygonMode.java new file mode 100644 index 00000000..5e74c6f9 --- /dev/null +++ b/com/mojang/blaze3d/platform/PolygonMode.java @@ -0,0 +1,12 @@ +package com.mojang.blaze3d.platform; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum PolygonMode { + FILL, + WIREFRAME; +} diff --git a/com/mojang/blaze3d/platform/SourceFactor.java b/com/mojang/blaze3d/platform/SourceFactor.java new file mode 100644 index 00000000..62d321a9 --- /dev/null +++ b/com/mojang/blaze3d/platform/SourceFactor.java @@ -0,0 +1,25 @@ +package com.mojang.blaze3d.platform; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum SourceFactor { + CONSTANT_ALPHA, + CONSTANT_COLOR, + DST_ALPHA, + DST_COLOR, + ONE, + ONE_MINUS_CONSTANT_ALPHA, + ONE_MINUS_CONSTANT_COLOR, + ONE_MINUS_DST_ALPHA, + ONE_MINUS_DST_COLOR, + ONE_MINUS_SRC_ALPHA, + ONE_MINUS_SRC_COLOR, + SRC_ALPHA, + SRC_ALPHA_SATURATE, + SRC_COLOR, + ZERO; +} diff --git a/com/mojang/blaze3d/platform/TextureUtil.java b/com/mojang/blaze3d/platform/TextureUtil.java index 9c8983bc..1d5b8cf7 100644 --- a/com/mojang/blaze3d/platform/TextureUtil.java +++ b/com/mojang/blaze3d/platform/TextureUtil.java @@ -1,7 +1,12 @@ package com.mojang.blaze3d.platform; import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.systems.CommandEncoder; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.logging.LogUtils; import java.io.IOException; import java.io.InputStream; @@ -10,12 +15,10 @@ import java.nio.channels.Channels; import java.nio.channels.ReadableByteChannel; import java.nio.channels.SeekableByteChannel; import java.nio.file.Path; -import java.util.concurrent.ThreadLocalRandom; +import java.util.concurrent.atomic.AtomicInteger; import java.util.function.IntUnaryOperator; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.SharedConstants; -import org.jetbrains.annotations.Nullable; import org.lwjgl.system.MemoryUtil; import org.slf4j.Logger; @@ -26,56 +29,6 @@ public class TextureUtil { public static final int MIN_MIPMAP_LEVEL = 0; private static final int DEFAULT_IMAGE_BUFFER_SIZE = 8192; - public static int generateTextureId() { - RenderSystem.assertOnRenderThreadOrInit(); - if (SharedConstants.IS_RUNNING_IN_IDE) { - int[] is = new int[ThreadLocalRandom.current().nextInt(15) + 1]; - GlStateManager._genTextures(is); - int i = GlStateManager._genTexture(); - GlStateManager._deleteTextures(is); - return i; - } else { - return GlStateManager._genTexture(); - } - } - - public static void releaseTextureId(int i) { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._deleteTexture(i); - } - - public static void prepareImage(int i, int j, int k) { - prepareImage(NativeImage.InternalGlFormat.RGBA, i, 0, j, k); - } - - public static void prepareImage(NativeImage.InternalGlFormat internalGlFormat, int i, int j, int k) { - prepareImage(internalGlFormat, i, 0, j, k); - } - - public static void prepareImage(int i, int j, int k, int l) { - prepareImage(NativeImage.InternalGlFormat.RGBA, i, j, k, l); - } - - public static void prepareImage(NativeImage.InternalGlFormat internalGlFormat, int i, int j, int k, int l) { - RenderSystem.assertOnRenderThreadOrInit(); - bind(i); - if (j >= 0) { - GlStateManager._texParameter(3553, 33085, j); - GlStateManager._texParameter(3553, 33082, 0); - GlStateManager._texParameter(3553, 33083, j); - GlStateManager._texParameter(3553, 34049, 0.0F); - } - - for (int m = 0; m <= j; m++) { - GlStateManager._texImage2D(3553, m, internalGlFormat.glFormat(), k >> m, l >> m, 0, 6408, 5121, null); - } - } - - private static void bind(int i) { - RenderSystem.assertOnRenderThreadOrInit(); - GlStateManager._bindTexture(i); - } - public static ByteBuffer readResource(InputStream inputStream) throws IOException { ReadableByteChannel readableByteChannel = Channels.newChannel(inputStream); return readableByteChannel instanceof SeekableByteChannel seekableByteChannel @@ -100,30 +53,55 @@ public class TextureUtil { } } - public static void writeAsPNG(Path path, String string, int i, int j, int k, int l) { - writeAsPNG(path, string, i, j, k, l, null); - } - - public static void writeAsPNG(Path path, String string, int i, int j, int k, int l, @Nullable IntUnaryOperator intUnaryOperator) { + public static void writeAsPNG(Path path, String string, GpuTexture gpuTexture, int i, IntUnaryOperator intUnaryOperator) { RenderSystem.assertOnRenderThread(); - bind(i); + int j = 0; - for (int m = 0; m <= j; m++) { - int n = k >> m; - int o = l >> m; + for (int k = 0; k <= i; k++) { + j += gpuTexture.getFormat().pixelSize() * gpuTexture.getWidth(k) * gpuTexture.getHeight(k); + } - try (NativeImage nativeImage = new NativeImage(n, o, false)) { - nativeImage.downloadTexture(m, false); - if (intUnaryOperator != null) { - nativeImage.applyToAllPixels(intUnaryOperator); + GpuBuffer gpuBuffer = RenderSystem.getDevice().createBuffer(() -> "Texture output buffer", BufferType.PIXEL_PACK, BufferUsage.STATIC_READ, j); + CommandEncoder commandEncoder = RenderSystem.getDevice().createCommandEncoder(); + Runnable runnable = () -> { + try (GpuBuffer.ReadView readView = commandEncoder.readBuffer(gpuBuffer)) { + int jx = 0; + + for (int k = 0; k <= i; k++) { + int lx = gpuTexture.getWidth(k); + int mx = gpuTexture.getHeight(k); + + try (NativeImage nativeImage = new NativeImage(lx, mx, false)) { + for (int n = 0; n < mx; n++) { + for (int o = 0; o < lx; o++) { + int p = readView.data().getInt(jx + (o + n * lx) * gpuTexture.getFormat().pixelSize()); + nativeImage.setPixelABGR(o, n, intUnaryOperator.applyAsInt(p)); + } + } + + Path path2 = path.resolve(string + "_" + k + ".png"); + nativeImage.writeToFile(path2); + LOGGER.debug("Exported png to: {}", path2.toAbsolutePath()); + } catch (IOException var19) { + LOGGER.debug("Unable to write: ", (Throwable)var19); + } + + jx += gpuTexture.getFormat().pixelSize() * lx * mx; } - - Path path2 = path.resolve(string + "_" + m + ".png"); - nativeImage.writeToFile(path2); - LOGGER.debug("Exported png to: {}", path2.toAbsolutePath()); - } catch (IOException var15) { - LOGGER.debug("Unable to write: ", (Throwable)var15); } + + gpuBuffer.close(); + }; + AtomicInteger atomicInteger = new AtomicInteger(); + int l = 0; + + for (int m = 0; m <= i; m++) { + commandEncoder.copyTextureToBuffer(gpuTexture, gpuBuffer, l, () -> { + if (atomicInteger.getAndIncrement() == i) { + runnable.run(); + } + }, m); + l += gpuTexture.getFormat().pixelSize() * gpuTexture.getWidth(m) * gpuTexture.getHeight(m); } } diff --git a/com/mojang/blaze3d/platform/Window.java b/com/mojang/blaze3d/platform/Window.java index 84ab6fb3..4b59d992 100644 --- a/com/mojang/blaze3d/platform/Window.java +++ b/com/mojang/blaze3d/platform/Window.java @@ -27,7 +27,6 @@ import org.lwjgl.glfw.GLFWErrorCallback; import org.lwjgl.glfw.GLFWImage; import org.lwjgl.glfw.GLFWWindowCloseCallback; import org.lwjgl.glfw.GLFWImage.Buffer; -import org.lwjgl.opengl.GL; import org.lwjgl.system.MemoryStack; import org.lwjgl.system.MemoryUtil; import org.lwjgl.util.tinyfd.TinyFileDialogs; @@ -74,16 +73,18 @@ public final class Window implements AutoCloseable { Optional optional = VideoMode.read(preferredFullscreenVideoMode); if (optional.isPresent()) { this.preferredFullscreenVideoMode = optional; - } else if (displayData.fullscreenWidth.isPresent() && displayData.fullscreenHeight.isPresent()) { - this.preferredFullscreenVideoMode = Optional.of(new VideoMode(displayData.fullscreenWidth.getAsInt(), displayData.fullscreenHeight.getAsInt(), 8, 8, 8, 60)); + } else if (displayData.fullscreenWidth().isPresent() && displayData.fullscreenHeight().isPresent()) { + this.preferredFullscreenVideoMode = Optional.of( + new VideoMode(displayData.fullscreenWidth().getAsInt(), displayData.fullscreenHeight().getAsInt(), 8, 8, 8, 60) + ); } else { this.preferredFullscreenVideoMode = Optional.empty(); } - this.actuallyFullscreen = this.fullscreen = displayData.isFullscreen; + this.actuallyFullscreen = this.fullscreen = displayData.isFullscreen(); Monitor monitor = screenManager.getMonitor(GLFW.glfwGetPrimaryMonitor()); - this.windowedWidth = this.width = displayData.width > 0 ? displayData.width : 1; - this.windowedHeight = this.height = displayData.height > 0 ? displayData.height : 1; + this.windowedWidth = this.width = Math.max(displayData.width(), 1); + this.windowedHeight = this.height = Math.max(displayData.height(), 1); GLFW.glfwDefaultWindowHints(); GLFW.glfwWindowHint(139265, 196609); GLFW.glfwWindowHint(139275, 221185); @@ -104,10 +105,6 @@ public final class Window implements AutoCloseable { this.windowedY = this.y = js[0]; } - GLFW.glfwMakeContextCurrent(this.window); - GL.createCapabilities(); - int i = RenderSystem.maxSupportedTextureSize(); - GLFW.glfwSetWindowSizeLimits(this.window, -1, -1, i, i); this.setMode(); this.refreshFramebufferSize(); GLFW.glfwSetFramebufferSizeCallback(this.window, this::onFramebufferResize); @@ -223,7 +220,7 @@ public final class Window implements AutoCloseable { } public void updateVsync(boolean vsync) { - RenderSystem.assertOnRenderThreadOrInit(); + RenderSystem.assertOnRenderThread(); this.vsync = vsync; GLFW.glfwSwapInterval(vsync ? 1 : 0); } diff --git a/com/mojang/blaze3d/resource/CrossFrameResourcePool.java b/com/mojang/blaze3d/resource/CrossFrameResourcePool.java index 1025b040..861b434c 100644 --- a/com/mojang/blaze3d/resource/CrossFrameResourcePool.java +++ b/com/mojang/blaze3d/resource/CrossFrameResourcePool.java @@ -31,11 +31,17 @@ public class CrossFrameResourcePool implements GraphicsResourceAllocator, AutoCl @Override public T acquire(ResourceDescriptor descriptor) { + T object = this.acquireWithoutPreparing(descriptor); + descriptor.prepare(object); + return object; + } + + private T acquireWithoutPreparing(ResourceDescriptor descriptor) { Iterator> iterator = this.pool.iterator(); while (iterator.hasNext()) { CrossFrameResourcePool.ResourceEntry resourceEntry = (CrossFrameResourcePool.ResourceEntry)iterator.next(); - if (resourceEntry.descriptor.equals(descriptor)) { + if (descriptor.canUsePhysicalResource(resourceEntry.descriptor)) { iterator.remove(); return (T)resourceEntry.value; } diff --git a/com/mojang/blaze3d/resource/GraphicsResourceAllocator.java b/com/mojang/blaze3d/resource/GraphicsResourceAllocator.java index 6aa18907..39bc36a6 100644 --- a/com/mojang/blaze3d/resource/GraphicsResourceAllocator.java +++ b/com/mojang/blaze3d/resource/GraphicsResourceAllocator.java @@ -8,7 +8,9 @@ public interface GraphicsResourceAllocator { GraphicsResourceAllocator UNPOOLED = new GraphicsResourceAllocator() { @Override public T acquire(ResourceDescriptor descriptor) { - return descriptor.allocate(); + T object = descriptor.allocate(); + descriptor.prepare(object); + return object; } @Override diff --git a/com/mojang/blaze3d/resource/RenderTargetDescriptor.java b/com/mojang/blaze3d/resource/RenderTargetDescriptor.java index 6faea1da..fdefec2e 100644 --- a/com/mojang/blaze3d/resource/RenderTargetDescriptor.java +++ b/com/mojang/blaze3d/resource/RenderTargetDescriptor.java @@ -2,16 +2,34 @@ package com.mojang.blaze3d.resource; import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.pipeline.TextureTarget; +import com.mojang.blaze3d.systems.RenderSystem; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @Environment(EnvType.CLIENT) -public record RenderTargetDescriptor(int width, int height, boolean useDepth) implements ResourceDescriptor { +public record RenderTargetDescriptor(int width, int height, boolean useDepth, int clearColor) implements ResourceDescriptor { public RenderTarget allocate() { - return new TextureTarget(this.width, this.height, this.useDepth); + return new TextureTarget(null, this.width, this.height, this.useDepth); + } + + public void prepare(RenderTarget renderTarget) { + if (this.useDepth) { + RenderSystem.getDevice() + .createCommandEncoder() + .clearColorAndDepthTextures(renderTarget.getColorTexture(), this.clearColor, renderTarget.getDepthTexture(), 1.0); + } else { + RenderSystem.getDevice().createCommandEncoder().clearColorTexture(renderTarget.getColorTexture(), this.clearColor); + } } public void free(RenderTarget renderTarget) { renderTarget.destroyBuffers(); } + + @Override + public boolean canUsePhysicalResource(ResourceDescriptor descriptor) { + return !(descriptor instanceof RenderTargetDescriptor renderTargetDescriptor) + ? false + : this.width == renderTargetDescriptor.width && this.height == renderTargetDescriptor.height && this.useDepth == renderTargetDescriptor.useDepth; + } } diff --git a/com/mojang/blaze3d/resource/ResourceDescriptor.java b/com/mojang/blaze3d/resource/ResourceDescriptor.java index 87d00c4d..c79a5b3b 100644 --- a/com/mojang/blaze3d/resource/ResourceDescriptor.java +++ b/com/mojang/blaze3d/resource/ResourceDescriptor.java @@ -7,5 +7,12 @@ import net.fabricmc.api.Environment; public interface ResourceDescriptor { T allocate(); + default void prepare(T target) { + } + void free(T target); + + default boolean canUsePhysicalResource(ResourceDescriptor descriptor) { + return this.equals(descriptor); + } } diff --git a/com/mojang/blaze3d/shaders/AbstractUniform.java b/com/mojang/blaze3d/shaders/AbstractUniform.java deleted file mode 100644 index 9f4c00c6..00000000 --- a/com/mojang/blaze3d/shaders/AbstractUniform.java +++ /dev/null @@ -1,100 +0,0 @@ -package com.mojang.blaze3d.shaders; - -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import org.joml.Matrix3f; -import org.joml.Matrix4f; -import org.joml.Vector3f; -import org.joml.Vector4f; - -@Environment(EnvType.CLIENT) -public class AbstractUniform { - public void set(float x) { - } - - public void set(float x, float y) { - } - - public void set(float x, float y, float z) { - } - - public void set(float x, float y, float z, float w) { - } - - public void setSafe(float x, float y, float z, float w) { - } - - public void setSafe(int x, int y, int z, int w) { - } - - public void set(int x) { - } - - public void set(int x, int y) { - } - - public void set(int x, int y, int z) { - } - - public void set(int x, int y, int z, int w) { - } - - public void set(float[] valueArray) { - } - - public void set(Vector3f vector) { - } - - public void set(Vector4f vector) { - } - - public void setMat2x2(float m00, float m01, float m10, float m11) { - } - - public void setMat2x3(float m00, float m01, float m02, float m10, float m11, float m12) { - } - - public void setMat2x4(float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13) { - } - - public void setMat3x2(float m00, float m01, float m10, float m11, float m20, float m21) { - } - - public void setMat3x3(float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22) { - } - - public void setMat3x4(float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13, float m20, float m21, float m22, float m23) { - } - - public void setMat4x2(float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13) { - } - - public void setMat4x3(float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13, float m20, float m21, float m22, float m23) { - } - - public void setMat4x4( - float m00, - float m01, - float m02, - float m03, - float m10, - float m11, - float m12, - float m13, - float m20, - float m21, - float m22, - float m23, - float m30, - float m31, - float m32, - float m33 - ) { - } - - public void set(Matrix4f matrix) { - } - - public void set(Matrix3f matrix) { - } -} diff --git a/com/mojang/blaze3d/shaders/CompiledShader.java b/com/mojang/blaze3d/shaders/CompiledShader.java deleted file mode 100644 index d63c6cfe..00000000 --- a/com/mojang/blaze3d/shaders/CompiledShader.java +++ /dev/null @@ -1,94 +0,0 @@ -package com.mojang.blaze3d.shaders; - -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.systems.RenderSystem; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.ShaderManager; -import net.minecraft.resources.FileToIdConverter; -import net.minecraft.resources.ResourceLocation; -import org.apache.commons.lang3.StringUtils; -import org.jetbrains.annotations.Nullable; - -@Environment(EnvType.CLIENT) -public class CompiledShader implements AutoCloseable { - private static final int NOT_ALLOCATED = -1; - private final ResourceLocation id; - private int shaderId; - - private CompiledShader(int shaderId, ResourceLocation id) { - this.id = id; - this.shaderId = shaderId; - } - - public static CompiledShader compile(ResourceLocation shaderId, CompiledShader.Type type, String source) throws ShaderManager.CompilationException { - RenderSystem.assertOnRenderThread(); - int i = GlStateManager.glCreateShader(type.glType()); - GlStateManager.glShaderSource(i, source); - GlStateManager.glCompileShader(i); - if (GlStateManager.glGetShaderi(i, 35713) == 0) { - String string = StringUtils.trim(GlStateManager.glGetShaderInfoLog(i, 32768)); - throw new ShaderManager.CompilationException("Couldn't compile " + type.getName() + " shader (" + shaderId + ") : " + string); - } else { - return new CompiledShader(i, shaderId); - } - } - - public void close() { - if (this.shaderId == -1) { - throw new IllegalStateException("Already closed"); - } else { - RenderSystem.assertOnRenderThread(); - GlStateManager.glDeleteShader(this.shaderId); - this.shaderId = -1; - } - } - - public ResourceLocation getId() { - return this.id; - } - - public int getShaderId() { - return this.shaderId; - } - - @Environment(EnvType.CLIENT) - public static enum Type { - VERTEX("vertex", ".vsh", 35633), - FRAGMENT("fragment", ".fsh", 35632); - - private static final CompiledShader.Type[] TYPES = values(); - private final String name; - private final String extension; - private final int glType; - - private Type(final String name, final String extension, final int glType) { - this.name = name; - this.extension = extension; - this.glType = glType; - } - - @Nullable - public static CompiledShader.Type byLocation(ResourceLocation location) { - for (CompiledShader.Type type : TYPES) { - if (location.getPath().endsWith(type.extension)) { - return type; - } - } - - return null; - } - - public String getName() { - return this.name; - } - - public int glType() { - return this.glType; - } - - public FileToIdConverter idConverter() { - return new FileToIdConverter("shaders", this.extension); - } - } -} diff --git a/com/mojang/blaze3d/shaders/ShaderType.java b/com/mojang/blaze3d/shaders/ShaderType.java new file mode 100644 index 00000000..9bded7ff --- /dev/null +++ b/com/mojang/blaze3d/shaders/ShaderType.java @@ -0,0 +1,43 @@ +package com.mojang.blaze3d.shaders; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.resources.FileToIdConverter; +import net.minecraft.resources.ResourceLocation; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum ShaderType { + VERTEX("vertex", ".vsh"), + FRAGMENT("fragment", ".fsh"); + + private static final ShaderType[] TYPES = values(); + private final String name; + private final String extension; + + private ShaderType(final String string2, final String string3) { + this.name = string2; + this.extension = string3; + } + + @Nullable + public static ShaderType byLocation(ResourceLocation resourceLocation) { + for (ShaderType shaderType : TYPES) { + if (resourceLocation.getPath().endsWith(shaderType.extension)) { + return shaderType; + } + } + + return null; + } + + public String getName() { + return this.name; + } + + public FileToIdConverter idConverter() { + return new FileToIdConverter("shaders", this.extension); + } +} diff --git a/com/mojang/blaze3d/shaders/Uniform.java b/com/mojang/blaze3d/shaders/Uniform.java deleted file mode 100644 index 4e856075..00000000 --- a/com/mojang/blaze3d/shaders/Uniform.java +++ /dev/null @@ -1,527 +0,0 @@ -package com.mojang.blaze3d.shaders; - -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.systems.RenderSystem; -import com.mojang.logging.LogUtils; -import java.nio.FloatBuffer; -import java.nio.IntBuffer; -import java.util.Arrays; -import java.util.List; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import org.joml.Matrix3f; -import org.joml.Matrix4f; -import org.joml.Vector3f; -import org.joml.Vector4f; -import org.lwjgl.system.MemoryUtil; -import org.slf4j.Logger; - -@Environment(EnvType.CLIENT) -public class Uniform extends AbstractUniform implements AutoCloseable { - private static final Logger LOGGER = LogUtils.getLogger(); - public static final int UT_INT1 = 0; - public static final int UT_INT2 = 1; - public static final int UT_INT3 = 2; - public static final int UT_INT4 = 3; - public static final int UT_FLOAT1 = 4; - public static final int UT_FLOAT2 = 5; - public static final int UT_FLOAT3 = 6; - public static final int UT_FLOAT4 = 7; - public static final int UT_MAT2 = 8; - public static final int UT_MAT3 = 9; - public static final int UT_MAT4 = 10; - private static final boolean TRANSPOSE_MATRICIES = false; - private int location; - private final int count; - private final int type; - private final IntBuffer intValues; - private final FloatBuffer floatValues; - private final String name; - - public Uniform(String name, int type, int count) { - this.name = name; - this.count = count; - this.type = type; - if (type <= 3) { - this.intValues = MemoryUtil.memAllocInt(count); - this.floatValues = null; - } else { - this.intValues = null; - this.floatValues = MemoryUtil.memAllocFloat(count); - } - - this.location = -1; - this.markDirty(); - } - - public static int glGetUniformLocation(int program, CharSequence name) { - return GlStateManager._glGetUniformLocation(program, name); - } - - public static void uploadInteger(int location, int value) { - RenderSystem.glUniform1i(location, value); - } - - public void setFromConfig(net.minecraft.client.renderer.ShaderProgramConfig.Uniform uniform) { - this.setFromConfig(uniform.values(), uniform.count()); - } - - public void setFromConfig(List values, int count) { - float[] fs = new float[Math.max(count, 16)]; - if (values.size() == 1) { - Arrays.fill(fs, (Float)values.getFirst()); - } else { - for (int i = 0; i < values.size(); i++) { - fs[i] = (Float)values.get(i); - } - } - - if (this.type <= 3) { - this.setSafe((int)fs[0], (int)fs[1], (int)fs[2], (int)fs[3]); - } else if (this.type <= 7) { - this.setSafe(fs[0], fs[1], fs[2], fs[3]); - } else { - this.set(Arrays.copyOfRange(fs, 0, count)); - } - } - - public void close() { - if (this.intValues != null) { - MemoryUtil.memFree(this.intValues); - } - - if (this.floatValues != null) { - MemoryUtil.memFree(this.floatValues); - } - } - - private void markDirty() { - } - - public static int getTypeFromString(String typeName) { - int i = -1; - if ("int".equals(typeName)) { - i = 0; - } else if ("float".equals(typeName)) { - i = 4; - } else if (typeName.startsWith("matrix")) { - if (typeName.endsWith("2x2")) { - i = 8; - } else if (typeName.endsWith("3x3")) { - i = 9; - } else if (typeName.endsWith("4x4")) { - i = 10; - } - } - - return i; - } - - public void setLocation(int location) { - this.location = location; - } - - public String getName() { - return this.name; - } - - @Override - public final void set(float x) { - this.floatValues.position(0); - this.floatValues.put(0, x); - this.markDirty(); - } - - @Override - public final void set(float x, float y) { - this.floatValues.position(0); - this.floatValues.put(0, x); - this.floatValues.put(1, y); - this.markDirty(); - } - - public final void set(int index, float value) { - this.floatValues.position(0); - this.floatValues.put(index, value); - this.markDirty(); - } - - @Override - public final void set(float x, float y, float z) { - this.floatValues.position(0); - this.floatValues.put(0, x); - this.floatValues.put(1, y); - this.floatValues.put(2, z); - this.markDirty(); - } - - @Override - public final void set(Vector3f vector) { - this.floatValues.position(0); - vector.get(this.floatValues); - this.markDirty(); - } - - @Override - public final void set(float x, float y, float z, float w) { - this.floatValues.position(0); - this.floatValues.put(x); - this.floatValues.put(y); - this.floatValues.put(z); - this.floatValues.put(w); - this.floatValues.flip(); - this.markDirty(); - } - - @Override - public final void set(Vector4f vector) { - this.floatValues.position(0); - vector.get(this.floatValues); - this.markDirty(); - } - - @Override - public final void setSafe(float x, float y, float z, float w) { - this.floatValues.position(0); - if (this.type >= 4) { - this.floatValues.put(0, x); - } - - if (this.type >= 5) { - this.floatValues.put(1, y); - } - - if (this.type >= 6) { - this.floatValues.put(2, z); - } - - if (this.type >= 7) { - this.floatValues.put(3, w); - } - - this.markDirty(); - } - - @Override - public final void setSafe(int x, int y, int z, int w) { - this.intValues.position(0); - if (this.type >= 0) { - this.intValues.put(0, x); - } - - if (this.type >= 1) { - this.intValues.put(1, y); - } - - if (this.type >= 2) { - this.intValues.put(2, z); - } - - if (this.type >= 3) { - this.intValues.put(3, w); - } - - this.markDirty(); - } - - @Override - public final void set(int x) { - this.intValues.position(0); - this.intValues.put(0, x); - this.markDirty(); - } - - @Override - public final void set(int x, int y) { - this.intValues.position(0); - this.intValues.put(0, x); - this.intValues.put(1, y); - this.markDirty(); - } - - @Override - public final void set(int x, int y, int z) { - this.intValues.position(0); - this.intValues.put(0, x); - this.intValues.put(1, y); - this.intValues.put(2, z); - this.markDirty(); - } - - @Override - public final void set(int x, int y, int z, int w) { - this.intValues.position(0); - this.intValues.put(0, x); - this.intValues.put(1, y); - this.intValues.put(2, z); - this.intValues.put(3, w); - this.markDirty(); - } - - @Override - public final void set(float[] valueArray) { - if (valueArray.length < this.count) { - LOGGER.warn("Uniform.set called with a too-small value array (expected {}, got {}). Ignoring.", this.count, valueArray.length); - } else { - this.floatValues.position(0); - this.floatValues.put(valueArray); - this.floatValues.position(0); - this.markDirty(); - } - } - - @Override - public final void setMat2x2(float m00, float m01, float m10, float m11) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m10); - this.floatValues.put(3, m11); - this.markDirty(); - } - - @Override - public final void setMat2x3(float m00, float m01, float m02, float m10, float m11, float m12) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m02); - this.floatValues.put(3, m10); - this.floatValues.put(4, m11); - this.floatValues.put(5, m12); - this.markDirty(); - } - - @Override - public final void setMat2x4(float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m02); - this.floatValues.put(3, m03); - this.floatValues.put(4, m10); - this.floatValues.put(5, m11); - this.floatValues.put(6, m12); - this.floatValues.put(7, m13); - this.markDirty(); - } - - @Override - public final void setMat3x2(float m00, float m01, float m10, float m11, float m20, float m21) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m10); - this.floatValues.put(3, m11); - this.floatValues.put(4, m20); - this.floatValues.put(5, m21); - this.markDirty(); - } - - @Override - public final void setMat3x3(float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m02); - this.floatValues.put(3, m10); - this.floatValues.put(4, m11); - this.floatValues.put(5, m12); - this.floatValues.put(6, m20); - this.floatValues.put(7, m21); - this.floatValues.put(8, m22); - this.markDirty(); - } - - @Override - public final void setMat3x4(float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13, float m20, float m21, float m22, float m23) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m02); - this.floatValues.put(3, m03); - this.floatValues.put(4, m10); - this.floatValues.put(5, m11); - this.floatValues.put(6, m12); - this.floatValues.put(7, m13); - this.floatValues.put(8, m20); - this.floatValues.put(9, m21); - this.floatValues.put(10, m22); - this.floatValues.put(11, m23); - this.markDirty(); - } - - @Override - public final void setMat4x2(float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m02); - this.floatValues.put(3, m03); - this.floatValues.put(4, m10); - this.floatValues.put(5, m11); - this.floatValues.put(6, m12); - this.floatValues.put(7, m13); - this.markDirty(); - } - - @Override - public final void setMat4x3(float m00, float m01, float m02, float m03, float m10, float m11, float m12, float m13, float m20, float m21, float m22, float m23) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m02); - this.floatValues.put(3, m03); - this.floatValues.put(4, m10); - this.floatValues.put(5, m11); - this.floatValues.put(6, m12); - this.floatValues.put(7, m13); - this.floatValues.put(8, m20); - this.floatValues.put(9, m21); - this.floatValues.put(10, m22); - this.floatValues.put(11, m23); - this.markDirty(); - } - - @Override - public final void setMat4x4( - float m00, - float m01, - float m02, - float m03, - float m10, - float m11, - float m12, - float m13, - float m20, - float m21, - float m22, - float m23, - float m30, - float m31, - float m32, - float m33 - ) { - this.floatValues.position(0); - this.floatValues.put(0, m00); - this.floatValues.put(1, m01); - this.floatValues.put(2, m02); - this.floatValues.put(3, m03); - this.floatValues.put(4, m10); - this.floatValues.put(5, m11); - this.floatValues.put(6, m12); - this.floatValues.put(7, m13); - this.floatValues.put(8, m20); - this.floatValues.put(9, m21); - this.floatValues.put(10, m22); - this.floatValues.put(11, m23); - this.floatValues.put(12, m30); - this.floatValues.put(13, m31); - this.floatValues.put(14, m32); - this.floatValues.put(15, m33); - this.markDirty(); - } - - @Override - public final void set(Matrix4f matrix) { - this.floatValues.position(0); - matrix.get(this.floatValues); - this.markDirty(); - } - - @Override - public final void set(Matrix3f matrix) { - this.floatValues.position(0); - matrix.get(this.floatValues); - this.markDirty(); - } - - public void upload() { - if (this.type <= 3) { - this.uploadAsInteger(); - } else if (this.type <= 7) { - this.uploadAsFloat(); - } else { - if (this.type > 10) { - LOGGER.warn("Uniform.upload called, but type value ({}) is not a valid type. Ignoring.", this.type); - return; - } - - this.uploadAsMatrix(); - } - } - - private void uploadAsInteger() { - this.intValues.rewind(); - switch (this.type) { - case 0: - RenderSystem.glUniform1(this.location, this.intValues); - break; - case 1: - RenderSystem.glUniform2(this.location, this.intValues); - break; - case 2: - RenderSystem.glUniform3(this.location, this.intValues); - break; - case 3: - RenderSystem.glUniform4(this.location, this.intValues); - break; - default: - LOGGER.warn("Uniform.upload called, but count value ({}) is not in the range of 1 to 4. Ignoring.", this.count); - } - } - - private void uploadAsFloat() { - this.floatValues.rewind(); - switch (this.type) { - case 4: - RenderSystem.glUniform1(this.location, this.floatValues); - break; - case 5: - RenderSystem.glUniform2(this.location, this.floatValues); - break; - case 6: - RenderSystem.glUniform3(this.location, this.floatValues); - break; - case 7: - RenderSystem.glUniform4(this.location, this.floatValues); - break; - default: - LOGGER.warn("Uniform.upload called, but count value ({}) is not in the range of 1 to 4. Ignoring.", this.count); - } - } - - private void uploadAsMatrix() { - this.floatValues.clear(); - switch (this.type) { - case 8: - RenderSystem.glUniformMatrix2(this.location, false, this.floatValues); - break; - case 9: - RenderSystem.glUniformMatrix3(this.location, false, this.floatValues); - break; - case 10: - RenderSystem.glUniformMatrix4(this.location, false, this.floatValues); - } - } - - public int getLocation() { - return this.location; - } - - public int getCount() { - return this.count; - } - - public int getType() { - return this.type; - } - - public IntBuffer getIntBuffer() { - return this.intValues; - } - - public FloatBuffer getFloatBuffer() { - return this.floatValues; - } -} diff --git a/com/mojang/blaze3d/shaders/UniformType.java b/com/mojang/blaze3d/shaders/UniformType.java new file mode 100644 index 00000000..130cf961 --- /dev/null +++ b/com/mojang/blaze3d/shaders/UniformType.java @@ -0,0 +1,42 @@ +package com.mojang.blaze3d.shaders; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.util.StringRepresentable; + +@Environment(EnvType.CLIENT) +public enum UniformType implements StringRepresentable { + INT(1, "int"), + IVEC3(3, "ivec3"), + FLOAT(1, "float"), + VEC2(2, "vec2"), + VEC3(3, "vec3"), + VEC4(4, "vec4"), + MATRIX4X4(16, "matrix4x4"); + + public static final StringRepresentable.EnumCodec CODEC = StringRepresentable.fromEnum(UniformType::values); + final int count; + final String name; + + private UniformType(final int count, final String name) { + this.count = count; + this.name = name; + } + + public int count() { + return this.count; + } + + public boolean isIntStorage() { + return this == INT || this == IVEC3; + } + + @Override + public String getSerializedName() { + return this.name; + } + + public int getCount() { + return this.count; + } +} diff --git a/com/mojang/blaze3d/systems/CommandEncoder.java b/com/mojang/blaze3d/systems/CommandEncoder.java new file mode 100644 index 00000000..9461ad0d --- /dev/null +++ b/com/mojang/blaze3d/systems/CommandEncoder.java @@ -0,0 +1,47 @@ +package com.mojang.blaze3d.systems; + +import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.platform.NativeImage; +import com.mojang.blaze3d.textures.GpuTexture; +import java.nio.ByteBuffer; +import java.nio.IntBuffer; +import java.util.OptionalDouble; +import java.util.OptionalInt; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public interface CommandEncoder { + RenderPass createRenderPass(GpuTexture gpuTexture, OptionalInt optionalInt); + + RenderPass createRenderPass(GpuTexture gpuTexture, OptionalInt optionalInt, @Nullable GpuTexture gpuTexture2, OptionalDouble optionalDouble); + + void clearColorTexture(GpuTexture gpuTexture, int i); + + void clearColorAndDepthTextures(GpuTexture gpuTexture, int i, GpuTexture gpuTexture2, double d); + + void clearDepthTexture(GpuTexture gpuTexture, double d); + + void writeToBuffer(GpuBuffer gpuBuffer, ByteBuffer byteBuffer, int i); + + GpuBuffer.ReadView readBuffer(GpuBuffer gpuBuffer); + + GpuBuffer.ReadView readBuffer(GpuBuffer gpuBuffer, int i, int j); + + void writeToTexture(GpuTexture gpuTexture, NativeImage nativeImage); + + void writeToTexture(GpuTexture gpuTexture, NativeImage nativeImage, int i, int j, int k, int l, int m, int n, int o); + + void writeToTexture(GpuTexture gpuTexture, IntBuffer intBuffer, NativeImage.Format format, int i, int j, int k, int l, int m); + + void copyTextureToBuffer(GpuTexture gpuTexture, GpuBuffer gpuBuffer, int i, Runnable runnable, int j); + + void copyTextureToBuffer(GpuTexture gpuTexture, GpuBuffer gpuBuffer, int i, Runnable runnable, int j, int k, int l, int m, int n); + + void copyTextureToTexture(GpuTexture gpuTexture, GpuTexture gpuTexture2, int i, int j, int k, int l, int m, int n, int o); + + void presentTexture(GpuTexture gpuTexture); +} diff --git a/com/mojang/blaze3d/systems/GpuDevice.java b/com/mojang/blaze3d/systems/GpuDevice.java new file mode 100644 index 00000000..b4263729 --- /dev/null +++ b/com/mojang/blaze3d/systems/GpuDevice.java @@ -0,0 +1,61 @@ +package com.mojang.blaze3d.systems; + +import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.CompiledRenderPipeline; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.shaders.ShaderType; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.textures.TextureFormat; +import java.nio.ByteBuffer; +import java.util.List; +import java.util.function.BiFunction; +import java.util.function.Supplier; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.resources.ResourceLocation; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public interface GpuDevice { + CommandEncoder createCommandEncoder(); + + GpuTexture createTexture(@Nullable Supplier supplier, TextureFormat textureFormat, int i, int j, int k); + + GpuTexture createTexture(@Nullable String string, TextureFormat textureFormat, int i, int j, int k); + + GpuBuffer createBuffer(@Nullable Supplier supplier, BufferType bufferType, BufferUsage bufferUsage, int i); + + GpuBuffer createBuffer(@Nullable Supplier supplier, BufferType bufferType, BufferUsage bufferUsage, ByteBuffer byteBuffer); + + String getImplementationInformation(); + + List getLastDebugMessages(); + + boolean isDebuggingEnabled(); + + String getVendor(); + + String getBackendName(); + + String getVersion(); + + String getRenderer(); + + int getMaxTextureSize(); + + default CompiledRenderPipeline precompilePipeline(RenderPipeline renderPipeline) { + return this.precompilePipeline(renderPipeline, null); + } + + CompiledRenderPipeline precompilePipeline(RenderPipeline renderPipeline, @Nullable BiFunction biFunction); + + void clearPipelineCache(); + + List getEnabledExtensions(); + + void close(); +} diff --git a/com/mojang/blaze3d/systems/RenderPass.java b/com/mojang/blaze3d/systems/RenderPass.java new file mode 100644 index 00000000..66877a1c --- /dev/null +++ b/com/mojang/blaze3d/systems/RenderPass.java @@ -0,0 +1,65 @@ +package com.mojang.blaze3d.systems; + +import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.vertex.VertexFormat; +import java.util.Collection; +import java.util.function.Consumer; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; +import org.joml.Matrix4f; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public interface RenderPass extends AutoCloseable { + void setPipeline(RenderPipeline renderPipeline); + + void bindSampler(String string, GpuTexture gpuTexture); + + void setUniform(String string, int... is); + + void setUniform(String string, float... fs); + + void setUniform(String string, Matrix4f matrix4f); + + void enableScissor(ScissorState scissorState); + + void enableScissor(int i, int j, int k, int l); + + void disableScissor(); + + void setVertexBuffer(int i, GpuBuffer gpuBuffer); + + void setIndexBuffer(GpuBuffer gpuBuffer, VertexFormat.IndexType indexType); + + void drawIndexed(int i, int j); + + void drawMultipleIndexed(Collection collection, @Nullable GpuBuffer gpuBuffer, @Nullable VertexFormat.IndexType indexType); + + void draw(int i, int j); + + void close(); + + @Environment(EnvType.CLIENT) + public record Draw( + int slot, + GpuBuffer vertexBuffer, + @Nullable GpuBuffer indexBuffer, + @Nullable VertexFormat.IndexType indexType, + int firstIndex, + int indexCount, + @Nullable Consumer uniformUploaderConsumer + ) { + public Draw(int slot, GpuBuffer vertexBuffer, GpuBuffer indexBuffer, VertexFormat.IndexType indexType, int firstIndex, int indexCount) { + this(slot, vertexBuffer, indexBuffer, indexType, firstIndex, indexCount, null); + } + } + + @Environment(EnvType.CLIENT) + public interface UniformUploader { + void upload(String string, float... fs); + } +} diff --git a/com/mojang/blaze3d/systems/RenderSystem.java b/com/mojang/blaze3d/systems/RenderSystem.java index 970d0be8..0e81ea35 100644 --- a/com/mojang/blaze3d/systems/RenderSystem.java +++ b/com/mojang/blaze3d/systems/RenderSystem.java @@ -1,42 +1,36 @@ package com.mojang.blaze3d.systems; -import com.google.common.collect.Queues; import com.mojang.blaze3d.DontObfuscate; import com.mojang.blaze3d.ProjectionType; import com.mojang.blaze3d.TracyFrameCapture; import com.mojang.blaze3d.buffers.BufferType; import com.mojang.blaze3d.buffers.BufferUsage; import com.mojang.blaze3d.buffers.GpuBuffer; -import com.mojang.blaze3d.pipeline.RenderCall; +import com.mojang.blaze3d.buffers.GpuFence; +import com.mojang.blaze3d.opengl.GlDevice; import com.mojang.blaze3d.platform.GLX; -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.platform.GlStateManager.DestFactor; -import com.mojang.blaze3d.platform.GlStateManager.LogicOp; -import com.mojang.blaze3d.platform.GlStateManager.SourceFactor; +import com.mojang.blaze3d.shaders.ShaderType; import com.mojang.blaze3d.systems.RenderSystem.AutoStorageIndexBuffer.IndexGenerator; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.vertex.BufferBuilder; +import com.mojang.blaze3d.vertex.ByteBufferBuilder; +import com.mojang.blaze3d.vertex.DefaultVertexFormat; +import com.mojang.blaze3d.vertex.MeshData; import com.mojang.blaze3d.vertex.Tesselator; -import com.mojang.blaze3d.vertex.VertexFormat.IndexType; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; +import com.mojang.blaze3d.vertex.VertexFormat; import com.mojang.logging.LogUtils; import java.nio.ByteBuffer; -import java.nio.FloatBuffer; -import java.nio.IntBuffer; import java.util.Locale; -import java.util.concurrent.ConcurrentLinkedQueue; import java.util.concurrent.atomic.AtomicBoolean; import java.util.concurrent.atomic.AtomicLong; -import java.util.function.Consumer; +import java.util.function.BiFunction; import java.util.function.IntConsumer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.Util; -import net.minecraft.client.Minecraft; -import net.minecraft.client.renderer.CompiledShaderProgram; import net.minecraft.client.renderer.FogParameters; -import net.minecraft.client.renderer.ShaderProgram; -import net.minecraft.client.renderer.texture.AbstractTexture; -import net.minecraft.client.renderer.texture.TextureManager; import net.minecraft.resources.ResourceLocation; +import net.minecraft.util.ArrayListDeque; import net.minecraft.util.Mth; import net.minecraft.util.TimeSource.NanoTimeSource; import org.jetbrains.annotations.Nullable; @@ -51,26 +45,25 @@ import org.slf4j.Logger; @Environment(EnvType.CLIENT) @DontObfuscate public class RenderSystem { + public static final ScissorState SCISSOR_STATE = new ScissorState(); static final Logger LOGGER = LogUtils.getLogger(); - private static final ConcurrentLinkedQueue recordingQueue = Queues.newConcurrentLinkedQueue(); - private static final Tesselator RENDER_THREAD_TESSELATOR = new Tesselator(1536); - private static final int MINIMUM_ATLAS_TEXTURE_SIZE = 1024; + public static final int MINIMUM_ATLAS_TEXTURE_SIZE = 1024; @Nullable private static Thread renderThread; - private static int MAX_SUPPORTED_TEXTURE_SIZE = -1; - private static boolean isInInit; + @Nullable + private static GpuDevice DEVICE; private static double lastDrawTime = Double.MIN_VALUE; private static final RenderSystem.AutoStorageIndexBuffer sharedSequential = new RenderSystem.AutoStorageIndexBuffer(1, 1, IntConsumer::accept); private static final RenderSystem.AutoStorageIndexBuffer sharedSequentialQuad = new RenderSystem.AutoStorageIndexBuffer(4, 6, (intConsumer, i) -> { - intConsumer.accept(i + 0); + intConsumer.accept(i); intConsumer.accept(i + 1); intConsumer.accept(i + 2); intConsumer.accept(i + 2); intConsumer.accept(i + 3); - intConsumer.accept(i + 0); + intConsumer.accept(i); }); private static final RenderSystem.AutoStorageIndexBuffer sharedSequentialLines = new RenderSystem.AutoStorageIndexBuffer(4, 6, (intConsumer, i) -> { - intConsumer.accept(i + 0); + intConsumer.accept(i); intConsumer.accept(i + 1); intConsumer.accept(i + 2); intConsumer.accept(i + 3); @@ -83,18 +76,21 @@ public class RenderSystem { private static ProjectionType savedProjectionType = ProjectionType.PERSPECTIVE; private static final Matrix4fStack modelViewStack = new Matrix4fStack(16); private static Matrix4f textureMatrix = new Matrix4f(); - private static final int[] shaderTextures = new int[12]; + public static final int TEXTURE_COUNT = 12; + private static final GpuTexture[] shaderTextures = new GpuTexture[12]; private static final float[] shaderColor = new float[]{1.0F, 1.0F, 1.0F, 1.0F}; private static float shaderGlintAlpha = 1.0F; private static FogParameters shaderFog = FogParameters.NO_FOG; private static final Vector3f[] shaderLightDirections = new Vector3f[2]; private static float shaderGameTime; + private static final Vector3f modelOffset = new Vector3f(); private static float shaderLineWidth = 1.0F; private static String apiDescription = "Unknown"; - @Nullable - private static CompiledShaderProgram shader; private static final AtomicLong pollEventsWaitStart = new AtomicLong(); private static final AtomicBoolean pollingEvents = new AtomicBoolean(false); + @Nullable + private static GpuBuffer QUAD_VERTEX_BUFFER; + private static final ArrayListDeque PENDING_FENCES = new ArrayListDeque<>(); public static void initRenderThread() { if (renderThread != null) { @@ -108,16 +104,6 @@ public class RenderSystem { return Thread.currentThread() == renderThread; } - public static boolean isOnRenderThreadOrInit() { - return isInInit || isOnRenderThread(); - } - - public static void assertOnRenderThreadOrInit() { - if (!isInInit && !isOnRenderThread()) { - throw constructThreadException(); - } - } - public static void assertOnRenderThread() { if (!isOnRenderThread()) { throw constructThreadException(); @@ -128,10 +114,6 @@ public class RenderSystem { return new IllegalStateException("Rendersystem called from wrong thread"); } - public static void recordRenderCall(RenderCall renderCall) { - recordingQueue.add(renderCall); - } - private static void pollEvents() { pollEventsWaitStart.set(Util.getMillis()); pollingEvents.set(true); @@ -145,7 +127,6 @@ public class RenderSystem { public static void flipFrame(long l, @Nullable TracyFrameCapture tracyFrameCapture) { pollEvents(); - replayQueue(); Tesselator.getInstance().clear(); GLFW.glfwSwapBuffers(l); if (tracyFrameCapture != null) { @@ -155,13 +136,6 @@ public class RenderSystem { pollEvents(); } - public static void replayQueue() { - while (!recordingQueue.isEmpty()) { - RenderCall renderCall = (RenderCall)recordingQueue.poll(); - renderCall.execute(); - } - } - public static void limitDisplayFPS(int i) { double d = lastDrawTime + 1.0 / i; @@ -173,174 +147,12 @@ public class RenderSystem { lastDrawTime = e; } - public static void disableDepthTest() { - assertOnRenderThread(); - GlStateManager._disableDepthTest(); - } - - public static void enableDepthTest() { - GlStateManager._enableDepthTest(); - } - public static void enableScissor(int i, int j, int k, int l) { - GlStateManager._enableScissorTest(); - GlStateManager._scissorBox(i, j, k, l); + SCISSOR_STATE.enable(i, j, k, l); } public static void disableScissor() { - GlStateManager._disableScissorTest(); - } - - public static void depthFunc(int i) { - assertOnRenderThread(); - GlStateManager._depthFunc(i); - } - - public static void depthMask(boolean bl) { - assertOnRenderThread(); - GlStateManager._depthMask(bl); - } - - public static void enableBlend() { - assertOnRenderThread(); - GlStateManager._enableBlend(); - } - - public static void disableBlend() { - assertOnRenderThread(); - GlStateManager._disableBlend(); - } - - public static void blendFunc(SourceFactor sourceFactor, DestFactor destFactor) { - assertOnRenderThread(); - GlStateManager._blendFunc(sourceFactor.value, destFactor.value); - } - - public static void blendFunc(int i, int j) { - assertOnRenderThread(); - GlStateManager._blendFunc(i, j); - } - - public static void blendFuncSeparate(SourceFactor sourceFactor, DestFactor destFactor, SourceFactor sourceFactor2, DestFactor destFactor2) { - assertOnRenderThread(); - GlStateManager._blendFuncSeparate(sourceFactor.value, destFactor.value, sourceFactor2.value, destFactor2.value); - } - - public static void blendFuncSeparate(int i, int j, int k, int l) { - assertOnRenderThread(); - GlStateManager._blendFuncSeparate(i, j, k, l); - } - - public static void blendEquation(int i) { - assertOnRenderThread(); - GlStateManager._blendEquation(i); - } - - public static void enableCull() { - assertOnRenderThread(); - GlStateManager._enableCull(); - } - - public static void disableCull() { - assertOnRenderThread(); - GlStateManager._disableCull(); - } - - public static void polygonMode(int i, int j) { - assertOnRenderThread(); - GlStateManager._polygonMode(i, j); - } - - public static void enablePolygonOffset() { - assertOnRenderThread(); - GlStateManager._enablePolygonOffset(); - } - - public static void disablePolygonOffset() { - assertOnRenderThread(); - GlStateManager._disablePolygonOffset(); - } - - public static void polygonOffset(float f, float g) { - assertOnRenderThread(); - GlStateManager._polygonOffset(f, g); - } - - public static void enableColorLogicOp() { - assertOnRenderThread(); - GlStateManager._enableColorLogicOp(); - } - - public static void disableColorLogicOp() { - assertOnRenderThread(); - GlStateManager._disableColorLogicOp(); - } - - public static void logicOp(LogicOp logicOp) { - assertOnRenderThread(); - GlStateManager._logicOp(logicOp.value); - } - - public static void activeTexture(int i) { - assertOnRenderThread(); - GlStateManager._activeTexture(i); - } - - public static void texParameter(int i, int j, int k) { - GlStateManager._texParameter(i, j, k); - } - - public static void deleteTexture(int i) { - GlStateManager._deleteTexture(i); - } - - public static void bindTextureForSetup(int i) { - bindTexture(i); - } - - public static void bindTexture(int i) { - GlStateManager._bindTexture(i); - } - - public static void viewport(int i, int j, int k, int l) { - GlStateManager._viewport(i, j, k, l); - } - - public static void colorMask(boolean bl, boolean bl2, boolean bl3, boolean bl4) { - assertOnRenderThread(); - GlStateManager._colorMask(bl, bl2, bl3, bl4); - } - - public static void stencilFunc(int i, int j, int k) { - assertOnRenderThread(); - GlStateManager._stencilFunc(i, j, k); - } - - public static void stencilMask(int i) { - assertOnRenderThread(); - GlStateManager._stencilMask(i); - } - - public static void stencilOp(int i, int j, int k) { - assertOnRenderThread(); - GlStateManager._stencilOp(i, j, k); - } - - public static void clearDepth(double d) { - GlStateManager._clearDepth(d); - } - - public static void clearColor(float f, float g, float h, float i) { - GlStateManager._clearColor(f, g, h, i); - } - - public static void clearStencil(int i) { - assertOnRenderThread(); - GlStateManager._clearStencil(i); - } - - public static void clear(int i) { - GlStateManager._clear(i); + SCISSOR_STATE.disable(); } public static void setShaderFog(FogParameters fogParameters) { @@ -373,15 +185,8 @@ public class RenderSystem { shaderLightDirections[1] = vector3f2; } - public static void setupShaderLights(CompiledShaderProgram compiledShaderProgram) { - assertOnRenderThread(); - if (compiledShaderProgram.LIGHT0_DIRECTION != null) { - compiledShaderProgram.LIGHT0_DIRECTION.set(shaderLightDirections[0]); - } - - if (compiledShaderProgram.LIGHT1_DIRECTION != null) { - compiledShaderProgram.LIGHT1_DIRECTION.set(shaderLightDirections[1]); - } + public static Vector3f[] getShaderLights() { + return shaderLightDirections; } public static void setShaderColor(float f, float g, float h, float i) { @@ -397,11 +202,6 @@ public class RenderSystem { return shaderColor; } - public static void drawElements(int i, int j, int k) { - assertOnRenderThread(); - GlStateManager._drawElements(i, j, k, 0L); - } - public static void lineWidth(float f) { assertOnRenderThread(); shaderLineWidth = f; @@ -412,20 +212,6 @@ public class RenderSystem { return shaderLineWidth; } - public static void pixelStore(int i, int j) { - GlStateManager._pixelStore(i, j); - } - - public static void readPixels(int i, int j, int k, int l, int m, int n, ByteBuffer byteBuffer) { - assertOnRenderThread(); - GlStateManager._readPixels(i, j, k, l, m, n, byteBuffer); - } - - public static void getString(int i, Consumer consumer) { - assertOnRenderThread(); - consumer.accept(GlStateManager._getString(i)); - } - public static String getBackendDescription() { return String.format(Locale.ROOT, "LWJGL version %s", GLX._getLWJGLVersion()); } @@ -438,148 +224,42 @@ public class RenderSystem { return GLX._initGlfw()::getAsLong; } - public static void initRenderer(int i, boolean bl) { - GLX._init(i, bl); - apiDescription = GLX.getOpenGLVersionString(); + public static void initRenderer(long l, int i, boolean bl, BiFunction biFunction, boolean bl2) { + DEVICE = new GlDevice(l, i, bl, biFunction, bl2); + apiDescription = getDevice().getImplementationInformation(); + + try (ByteBufferBuilder byteBufferBuilder = new ByteBufferBuilder(DefaultVertexFormat.POSITION.getVertexSize() * 4)) { + BufferBuilder bufferBuilder = new BufferBuilder(byteBufferBuilder, VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION); + bufferBuilder.addVertex(0.0F, 0.0F, 0.0F); + bufferBuilder.addVertex(1.0F, 0.0F, 0.0F); + bufferBuilder.addVertex(1.0F, 1.0F, 0.0F); + bufferBuilder.addVertex(0.0F, 1.0F, 0.0F); + + try (MeshData meshData = bufferBuilder.buildOrThrow()) { + QUAD_VERTEX_BUFFER = getDevice().createBuffer(() -> "Quad", BufferType.VERTICES, BufferUsage.STATIC_WRITE, meshData.vertexBuffer()); + } + } } public static void setErrorCallback(GLFWErrorCallbackI gLFWErrorCallbackI) { GLX._setGlfwErrorCallback(gLFWErrorCallbackI); } - public static void renderCrosshair(int i) { - assertOnRenderThread(); - GLX._renderCrosshair(i, true, true, true); - } - - public static String getCapsString() { - assertOnRenderThread(); - return "Using framebuffer using OpenGL 3.2"; - } - - public static void setupDefaultState(int i, int j, int k, int l) { - GlStateManager._clearDepth(1.0); - GlStateManager._enableDepthTest(); - GlStateManager._depthFunc(515); + public static void setupDefaultState() { projectionMatrix.identity(); savedProjectionMatrix.identity(); modelViewStack.clear(); textureMatrix.identity(); - GlStateManager._viewport(i, j, k, l); } - public static int maxSupportedTextureSize() { - if (MAX_SUPPORTED_TEXTURE_SIZE == -1) { - assertOnRenderThreadOrInit(); - int i = GlStateManager._getInteger(3379); - - for (int j = Math.max(32768, i); j >= 1024; j >>= 1) { - GlStateManager._texImage2D(32868, 0, 6408, j, j, 0, 6408, 5121, null); - int k = GlStateManager._getTexLevelParameter(32868, 0, 4096); - if (k != 0) { - MAX_SUPPORTED_TEXTURE_SIZE = j; - return j; - } - } - - MAX_SUPPORTED_TEXTURE_SIZE = Math.max(i, 1024); - LOGGER.info("Failed to determine maximum texture size by probing, trying GL_MAX_TEXTURE_SIZE = {}", MAX_SUPPORTED_TEXTURE_SIZE); - } - - return MAX_SUPPORTED_TEXTURE_SIZE; - } - - public static void glBindBuffer(int i, int j) { - GlStateManager._glBindBuffer(i, j); - } - - public static void glBindVertexArray(int i) { - GlStateManager._glBindVertexArray(i); - } - - public static void glBufferData(int i, ByteBuffer byteBuffer, int j) { - assertOnRenderThreadOrInit(); - GlStateManager._glBufferData(i, byteBuffer, j); - } - - public static void glDeleteBuffers(int i) { + public static void setupOverlayColor(@Nullable GpuTexture gpuTexture) { assertOnRenderThread(); - GlStateManager._glDeleteBuffers(i); - } - - public static void glDeleteVertexArrays(int i) { - assertOnRenderThread(); - GlStateManager._glDeleteVertexArrays(i); - } - - public static void glUniform1i(int i, int j) { - assertOnRenderThread(); - GlStateManager._glUniform1i(i, j); - } - - public static void glUniform1(int i, IntBuffer intBuffer) { - assertOnRenderThread(); - GlStateManager._glUniform1(i, intBuffer); - } - - public static void glUniform2(int i, IntBuffer intBuffer) { - assertOnRenderThread(); - GlStateManager._glUniform2(i, intBuffer); - } - - public static void glUniform3(int i, IntBuffer intBuffer) { - assertOnRenderThread(); - GlStateManager._glUniform3(i, intBuffer); - } - - public static void glUniform4(int i, IntBuffer intBuffer) { - assertOnRenderThread(); - GlStateManager._glUniform4(i, intBuffer); - } - - public static void glUniform1(int i, FloatBuffer floatBuffer) { - assertOnRenderThread(); - GlStateManager._glUniform1(i, floatBuffer); - } - - public static void glUniform2(int i, FloatBuffer floatBuffer) { - assertOnRenderThread(); - GlStateManager._glUniform2(i, floatBuffer); - } - - public static void glUniform3(int i, FloatBuffer floatBuffer) { - assertOnRenderThread(); - GlStateManager._glUniform3(i, floatBuffer); - } - - public static void glUniform4(int i, FloatBuffer floatBuffer) { - assertOnRenderThread(); - GlStateManager._glUniform4(i, floatBuffer); - } - - public static void glUniformMatrix2(int i, boolean bl, FloatBuffer floatBuffer) { - assertOnRenderThread(); - GlStateManager._glUniformMatrix2(i, bl, floatBuffer); - } - - public static void glUniformMatrix3(int i, boolean bl, FloatBuffer floatBuffer) { - assertOnRenderThread(); - GlStateManager._glUniformMatrix3(i, bl, floatBuffer); - } - - public static void glUniformMatrix4(int i, boolean bl, FloatBuffer floatBuffer) { - assertOnRenderThread(); - GlStateManager._glUniformMatrix4(i, bl, floatBuffer); - } - - public static void setupOverlayColor(int i, int j) { - assertOnRenderThread(); - setShaderTexture(1, i); + setShaderTexture(1, gpuTexture); } public static void teardownOverlayColor() { assertOnRenderThread(); - setShaderTexture(1, 0); + setShaderTexture(1, null); } public static void setupLevelDiffuseLighting(Vector3f vector3f, Vector3f vector3f2) { @@ -589,81 +269,30 @@ public class RenderSystem { public static void setupGuiFlatDiffuseLighting(Vector3f vector3f, Vector3f vector3f2) { assertOnRenderThread(); - GlStateManager.setupGuiFlatDiffuseLighting(vector3f, vector3f2); + Matrix4f matrix4f = new Matrix4f().rotationY((float) (-Math.PI / 8)).rotateX((float) (Math.PI * 3.0 / 4.0)); + setShaderLights(matrix4f.transformDirection(vector3f, new Vector3f()), matrix4f.transformDirection(vector3f2, new Vector3f())); } public static void setupGui3DDiffuseLighting(Vector3f vector3f, Vector3f vector3f2) { assertOnRenderThread(); - GlStateManager.setupGui3DDiffuseLighting(vector3f, vector3f2); + Matrix4f matrix4f = new Matrix4f() + .scaling(1.0F, -1.0F, 1.0F) + .rotateYXZ(1.0821041F, 3.2375858F, 0.0F) + .rotateYXZ((float) (-Math.PI / 8), (float) (Math.PI * 3.0 / 4.0), 0.0F); + setShaderLights(matrix4f.transformDirection(vector3f, new Vector3f()), matrix4f.transformDirection(vector3f2, new Vector3f())); } - public static void beginInitialization() { - isInInit = true; - } - - public static void finishInitialization() { - isInInit = false; - if (!recordingQueue.isEmpty()) { - replayQueue(); - } - - if (!recordingQueue.isEmpty()) { - throw new IllegalStateException("Recorded to render queue during initialization"); - } - } - - public static Tesselator renderThreadTesselator() { + public static void setShaderTexture(int i, @Nullable GpuTexture gpuTexture) { assertOnRenderThread(); - return RENDER_THREAD_TESSELATOR; - } - - public static void defaultBlendFunc() { - blendFuncSeparate(SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA, SourceFactor.ONE, DestFactor.ZERO); + if (i >= 0 && i < shaderTextures.length) { + shaderTextures[i] = gpuTexture; + } } @Nullable - public static CompiledShaderProgram setShader(ShaderProgram shaderProgram) { + public static GpuTexture getShaderTexture(int i) { assertOnRenderThread(); - CompiledShaderProgram compiledShaderProgram = Minecraft.getInstance().getShaderManager().getProgram(shaderProgram); - shader = compiledShaderProgram; - return compiledShaderProgram; - } - - public static void setShader(CompiledShaderProgram compiledShaderProgram) { - assertOnRenderThread(); - shader = compiledShaderProgram; - } - - public static void clearShader() { - assertOnRenderThread(); - shader = null; - } - - @Nullable - public static CompiledShaderProgram getShader() { - assertOnRenderThread(); - return shader; - } - - public static void setShaderTexture(int i, ResourceLocation resourceLocation) { - assertOnRenderThread(); - if (i >= 0 && i < shaderTextures.length) { - TextureManager textureManager = Minecraft.getInstance().getTextureManager(); - AbstractTexture abstractTexture = textureManager.getTexture(resourceLocation); - shaderTextures[i] = abstractTexture.getId(); - } - } - - public static void setShaderTexture(int i, int j) { - assertOnRenderThread(); - if (i >= 0 && i < shaderTextures.length) { - shaderTextures[i] = j; - } - } - - public static int getShaderTexture(int i) { - assertOnRenderThread(); - return i >= 0 && i < shaderTextures.length ? shaderTextures[i] : 0; + return i >= 0 && i < shaderTextures.length ? shaderTextures[i] : null; } public static void setProjectionMatrix(Matrix4f matrix4f, ProjectionType projectionType) { @@ -714,7 +343,7 @@ public class RenderSystem { return textureMatrix; } - public static RenderSystem.AutoStorageIndexBuffer getSequentialBuffer(Mode mode) { + public static RenderSystem.AutoStorageIndexBuffer getSequentialBuffer(VertexFormat.Mode mode) { assertOnRenderThread(); return switch (mode) { @@ -739,6 +368,62 @@ public class RenderSystem { return projectionType; } + public static GpuBuffer getQuadVertexBuffer() { + if (QUAD_VERTEX_BUFFER == null) { + throw new IllegalStateException("Can't getQuadVertexBuffer() before renderer was initialized"); + } else { + return QUAD_VERTEX_BUFFER; + } + } + + public static void setModelOffset(float f, float g, float h) { + assertOnRenderThread(); + modelOffset.set(f, g, h); + } + + public static void resetModelOffset() { + assertOnRenderThread(); + modelOffset.set(0.0F, 0.0F, 0.0F); + } + + public static Vector3f getModelOffset() { + assertOnRenderThread(); + return modelOffset; + } + + public static void queueFencedTask(Runnable runnable) { + PENDING_FENCES.addLast(new RenderSystem.GpuAsyncTask(runnable, new GpuFence())); + } + + public static void executePendingTasks() { + for (RenderSystem.GpuAsyncTask gpuAsyncTask = PENDING_FENCES.peekFirst(); gpuAsyncTask != null; gpuAsyncTask = PENDING_FENCES.peekFirst()) { + if (!gpuAsyncTask.fence.awaitCompletion(0L)) { + return; + } + + try { + gpuAsyncTask.callback.run(); + } finally { + gpuAsyncTask.fence.close(); + } + + PENDING_FENCES.removeFirst(); + } + } + + public static GpuDevice getDevice() { + if (DEVICE == null) { + throw new IllegalStateException("Can't getDevice() before it was initialized"); + } else { + return DEVICE; + } + } + + @Nullable + public static GpuDevice tryGetDevice() { + return DEVICE; + } + @Environment(EnvType.CLIENT) public static final class AutoStorageIndexBuffer { private final int vertexStride; @@ -746,7 +431,7 @@ public class RenderSystem { private final IndexGenerator generator; @Nullable private GpuBuffer buffer; - private IndexType type = IndexType.SHORT; + private VertexFormat.IndexType type = VertexFormat.IndexType.SHORT; private int indexCount; AutoStorageIndexBuffer(int vertexStride, int indexStride, IndexGenerator generator) { @@ -759,13 +444,9 @@ public class RenderSystem { return index <= this.indexCount; } - public void bind(int index) { - if (this.buffer == null) { - this.buffer = new GpuBuffer(BufferType.INDICES, BufferUsage.DYNAMIC_WRITE, 0); - } - - this.buffer.bind(); + public GpuBuffer getBuffer(int index) { this.ensureStorage(index); + return this.buffer; } private void ensureStorage(int neededIndexCount) { @@ -774,7 +455,7 @@ public class RenderSystem { RenderSystem.LOGGER.debug("Growing IndexBuffer: Old limit {}, new limit {}.", this.indexCount, neededIndexCount); int i = neededIndexCount / this.indexStride; int j = i * this.vertexStride; - IndexType indexType = IndexType.least(j); + VertexFormat.IndexType indexType = VertexFormat.IndexType.least(j); int k = Mth.roundToward(neededIndexCount * indexType.bytes, 4); ByteBuffer byteBuffer = MemoryUtil.memAlloc(k); @@ -787,8 +468,11 @@ public class RenderSystem { } byteBuffer.flip(); - this.buffer.resize(k); - this.buffer.write(byteBuffer, 0); + if (this.buffer != null) { + this.buffer.close(); + } + + this.buffer = RenderSystem.getDevice().createBuffer(() -> "Auto Storage index buffer", BufferType.INDICES, BufferUsage.DYNAMIC_WRITE, byteBuffer); } finally { MemoryUtil.memFree(byteBuffer); } @@ -807,8 +491,12 @@ public class RenderSystem { } } - public IndexType type() { + public VertexFormat.IndexType type() { return this.type; } } + + @Environment(EnvType.CLIENT) + record GpuAsyncTask(Runnable callback, GpuFence fence) { + } } diff --git a/com/mojang/blaze3d/systems/ScissorState.java b/com/mojang/blaze3d/systems/ScissorState.java new file mode 100644 index 00000000..05c0127f --- /dev/null +++ b/com/mojang/blaze3d/systems/ScissorState.java @@ -0,0 +1,55 @@ +package com.mojang.blaze3d.systems; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public class ScissorState { + private boolean enabled; + private int x; + private int y; + private int width; + private int height; + + public void enable(int i, int j, int k, int l) { + this.enabled = true; + this.x = i; + this.y = j; + this.width = k; + this.height = l; + } + + public void disable() { + this.enabled = false; + } + + public boolean isEnabled() { + return this.enabled; + } + + public int getX() { + return this.x; + } + + public int getY() { + return this.y; + } + + public int getWidth() { + return this.width; + } + + public int getHeight() { + return this.height; + } + + public void copyFrom(ScissorState scissorState) { + this.enabled = scissorState.enabled; + this.x = scissorState.x; + this.y = scissorState.y; + this.width = scissorState.width; + this.height = scissorState.height; + } +} diff --git a/com/mojang/blaze3d/textures/AddressMode.java b/com/mojang/blaze3d/textures/AddressMode.java new file mode 100644 index 00000000..d0e7ab2a --- /dev/null +++ b/com/mojang/blaze3d/textures/AddressMode.java @@ -0,0 +1,12 @@ +package com.mojang.blaze3d.textures; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum AddressMode { + REPEAT, + CLAMP_TO_EDGE; +} diff --git a/com/mojang/blaze3d/textures/FilterMode.java b/com/mojang/blaze3d/textures/FilterMode.java new file mode 100644 index 00000000..31be850d --- /dev/null +++ b/com/mojang/blaze3d/textures/FilterMode.java @@ -0,0 +1,12 @@ +package com.mojang.blaze3d.textures; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum FilterMode { + NEAREST, + LINEAR; +} diff --git a/com/mojang/blaze3d/textures/GpuTexture.java b/com/mojang/blaze3d/textures/GpuTexture.java new file mode 100644 index 00000000..fc4c75f8 --- /dev/null +++ b/com/mojang/blaze3d/textures/GpuTexture.java @@ -0,0 +1,71 @@ +package com.mojang.blaze3d.textures; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public abstract class GpuTexture implements AutoCloseable { + private final TextureFormat format; + private final int width; + private final int height; + private final int mipLevels; + private final String label; + protected AddressMode addressModeU = AddressMode.REPEAT; + protected AddressMode addressModeV = AddressMode.REPEAT; + protected FilterMode minFilter = FilterMode.NEAREST; + protected FilterMode magFilter = FilterMode.LINEAR; + protected boolean useMipmaps = true; + + public GpuTexture(String string, TextureFormat textureFormat, int i, int j, int k) { + this.label = string; + this.format = textureFormat; + this.width = i; + this.height = j; + this.mipLevels = k; + } + + public int getWidth(int i) { + return this.width >> i; + } + + public int getHeight(int i) { + return this.height >> i; + } + + public int getMipLevels() { + return this.mipLevels; + } + + public TextureFormat getFormat() { + return this.format; + } + + public void setAddressMode(AddressMode addressMode) { + this.setAddressMode(addressMode, addressMode); + } + + public void setAddressMode(AddressMode addressMode, AddressMode addressMode2) { + this.addressModeU = addressMode; + this.addressModeV = addressMode2; + } + + public void setTextureFilter(FilterMode filterMode, boolean bl) { + this.setTextureFilter(filterMode, filterMode, bl); + } + + public void setTextureFilter(FilterMode filterMode, FilterMode filterMode2, boolean bl) { + this.minFilter = filterMode; + this.magFilter = filterMode2; + this.useMipmaps = bl; + } + + public String getLabel() { + return this.label; + } + + public abstract void close(); + + public abstract boolean isClosed(); +} diff --git a/com/mojang/blaze3d/textures/TextureFormat.java b/com/mojang/blaze3d/textures/TextureFormat.java new file mode 100644 index 00000000..bbd7722b --- /dev/null +++ b/com/mojang/blaze3d/textures/TextureFormat.java @@ -0,0 +1,31 @@ +package com.mojang.blaze3d.textures; + +import com.mojang.blaze3d.DontObfuscate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +@DontObfuscate +public enum TextureFormat { + RGBA8(4), + RED8(1), + DEPTH32(4); + + private final int pixelSize; + + private TextureFormat(final int j) { + this.pixelSize = j; + } + + public int pixelSize() { + return this.pixelSize; + } + + public boolean hasColorAspect() { + return this == RGBA8 || this == RED8; + } + + public boolean hasDepthAspect() { + return this == DEPTH32; + } +} diff --git a/com/mojang/blaze3d/textures/package-info.java b/com/mojang/blaze3d/textures/package-info.java new file mode 100644 index 00000000..1b8fc399 --- /dev/null +++ b/com/mojang/blaze3d/textures/package-info.java @@ -0,0 +1,11 @@ +@ParametersAreNonnullByDefault +@MethodsReturnNonnullByDefault +@FieldsAreNonnullByDefault +@Environment(EnvType.CLIENT) +package com.mojang.blaze3d.textures; + +import com.mojang.blaze3d.FieldsAreNonnullByDefault; +import com.mojang.blaze3d.MethodsReturnNonnullByDefault; +import javax.annotation.ParametersAreNonnullByDefault; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; diff --git a/com/mojang/blaze3d/vertex/BufferBuilder.java b/com/mojang/blaze3d/vertex/BufferBuilder.java index 9b68680e..805dbf09 100644 --- a/com/mojang/blaze3d/vertex/BufferBuilder.java +++ b/com/mojang/blaze3d/vertex/BufferBuilder.java @@ -2,8 +2,6 @@ package com.mojang.blaze3d.vertex; import com.mojang.blaze3d.vertex.ByteBufferBuilder.Result; import com.mojang.blaze3d.vertex.MeshData.DrawState; -import com.mojang.blaze3d.vertex.VertexFormat.IndexType; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; import java.nio.ByteOrder; import java.util.stream.Collectors; import net.fabricmc.api.EnvType; @@ -22,7 +20,7 @@ public class BufferBuilder implements VertexConsumer { private long vertexPointer = -1L; private int vertices; private final VertexFormat format; - private final Mode mode; + private final VertexFormat.Mode mode; private final boolean fastFormat; private final boolean fullFormat; private final int vertexSize; @@ -31,7 +29,7 @@ public class BufferBuilder implements VertexConsumer { private int elementsToFill; private boolean building = true; - public BufferBuilder(ByteBufferBuilder buffer, Mode mode, VertexFormat format) { + public BufferBuilder(ByteBufferBuilder buffer, VertexFormat.Mode mode, VertexFormat format) { if (!format.contains(VertexFormatElement.POSITION)) { throw new IllegalArgumentException("Cannot build mesh with no position element"); } else { @@ -83,7 +81,7 @@ public class BufferBuilder implements VertexConsumer { return null; } else { int i = this.mode.indexCount(this.vertices); - IndexType indexType = IndexType.least(this.vertices); + VertexFormat.IndexType indexType = VertexFormat.IndexType.least(this.vertices); return new MeshData(result, new DrawState(this.format, this.vertices, i, this.mode, indexType)); } } @@ -120,7 +118,7 @@ public class BufferBuilder implements VertexConsumer { String string = (String)VertexFormatElement.elementsFromMask(this.elementsToFill).map(this.format::getElementName).collect(Collectors.joining(", ")); throw new IllegalStateException("Missing elements in vertex: " + string); } else { - if (this.mode == Mode.LINES || this.mode == Mode.LINE_STRIP) { + if (this.mode == VertexFormat.Mode.LINES || this.mode == VertexFormat.Mode.LINE_STRIP) { long l = this.buffer.reserve(this.vertexSize); MemoryUtil.memCopy(l - this.vertexSize, l, this.vertexSize); this.vertices++; diff --git a/com/mojang/blaze3d/vertex/BufferUploader.java b/com/mojang/blaze3d/vertex/BufferUploader.java deleted file mode 100644 index 632117a4..00000000 --- a/com/mojang/blaze3d/vertex/BufferUploader.java +++ /dev/null @@ -1,54 +0,0 @@ -package com.mojang.blaze3d.vertex; - -import com.mojang.blaze3d.systems.RenderSystem; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import org.jetbrains.annotations.Nullable; - -@Environment(EnvType.CLIENT) -public class BufferUploader { - @Nullable - private static VertexBuffer lastImmediateBuffer; - - public static void reset() { - if (lastImmediateBuffer != null) { - invalidate(); - VertexBuffer.unbind(); - } - } - - public static void invalidate() { - lastImmediateBuffer = null; - } - - public static void drawWithShader(MeshData meshData) { - RenderSystem.assertOnRenderThread(); - VertexBuffer vertexBuffer = upload(meshData); - vertexBuffer.drawWithShader(RenderSystem.getModelViewMatrix(), RenderSystem.getProjectionMatrix(), RenderSystem.getShader()); - } - - public static void draw(MeshData meshData) { - RenderSystem.assertOnRenderThread(); - VertexBuffer vertexBuffer = upload(meshData); - vertexBuffer.draw(); - } - - private static VertexBuffer upload(MeshData meshData) { - VertexBuffer vertexBuffer = bindImmediateBuffer(meshData.drawState().format()); - vertexBuffer.upload(meshData); - return vertexBuffer; - } - - private static VertexBuffer bindImmediateBuffer(VertexFormat format) { - VertexBuffer vertexBuffer = format.getImmediateDrawVertexBuffer(); - bindImmediateBuffer(vertexBuffer); - return vertexBuffer; - } - - private static void bindImmediateBuffer(VertexBuffer buffer) { - if (buffer != lastImmediateBuffer) { - buffer.bind(); - lastImmediateBuffer = buffer; - } - } -} diff --git a/com/mojang/blaze3d/vertex/PoseStack.java b/com/mojang/blaze3d/vertex/PoseStack.java index 0a5ce50e..ebd42a4f 100644 --- a/com/mojang/blaze3d/vertex/PoseStack.java +++ b/com/mojang/blaze3d/vertex/PoseStack.java @@ -1,32 +1,34 @@ package com.mojang.blaze3d.vertex; -import com.google.common.collect.Queues; import com.mojang.math.MatrixUtil; -import java.util.Deque; +import java.util.ArrayList; +import java.util.List; +import java.util.NoSuchElementException; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.Util; import net.minecraft.world.phys.Vec3; import org.joml.Matrix3f; import org.joml.Matrix4f; -import org.joml.Quaternionf; +import org.joml.Matrix4fc; +import org.joml.Quaternionfc; import org.joml.Vector3f; +import org.joml.Vector3fc; @Environment(EnvType.CLIENT) public class PoseStack { - private final Deque poseStack = Util.make(Queues.newArrayDeque(), arrayDeque -> { - Matrix4f matrix4f = new Matrix4f(); - Matrix3f matrix3f = new Matrix3f(); - arrayDeque.add(new PoseStack.Pose(matrix4f, matrix3f)); - }); + private final List poses = new ArrayList(16); + private int lastIndex; + + public PoseStack() { + this.poses.add(new PoseStack.Pose()); + } public void translate(double x, double y, double z) { this.translate((float)x, (float)y, (float)z); } public void translate(float x, float y, float z) { - PoseStack.Pose pose = (PoseStack.Pose)this.poseStack.getLast(); - pose.pose.translate(x, y, z); + this.last().translate(x, y, z); } public void translate(Vec3 vector) { @@ -34,87 +36,68 @@ public class PoseStack { } public void scale(float x, float y, float z) { - PoseStack.Pose pose = (PoseStack.Pose)this.poseStack.getLast(); - pose.pose.scale(x, y, z); - if (Math.abs(x) == Math.abs(y) && Math.abs(y) == Math.abs(z)) { - if (x < 0.0F || y < 0.0F || z < 0.0F) { - pose.normal.scale(Math.signum(x), Math.signum(y), Math.signum(z)); - } - } else { - pose.normal.scale(1.0F / x, 1.0F / y, 1.0F / z); - pose.trustedNormals = false; - } + this.last().scale(x, y, z); } - public void mulPose(Quaternionf quaternion) { - PoseStack.Pose pose = (PoseStack.Pose)this.poseStack.getLast(); - pose.pose.rotate(quaternion); - pose.normal.rotate(quaternion); + public void mulPose(Quaternionfc pose) { + this.last().rotate(pose); } - public void rotateAround(Quaternionf quaternion, float x, float y, float z) { - PoseStack.Pose pose = (PoseStack.Pose)this.poseStack.getLast(); - pose.pose.rotateAround(quaternion, x, y, z); - pose.normal.rotate(quaternion); + public void rotateAround(Quaternionfc quaternion, float x, float y, float z) { + this.last().rotateAround(quaternion, x, y, z); } public void pushPose() { - this.poseStack.addLast(new PoseStack.Pose((PoseStack.Pose)this.poseStack.getLast())); + PoseStack.Pose pose = this.last(); + this.lastIndex++; + if (this.lastIndex >= this.poses.size()) { + this.poses.add(pose.copy()); + } else { + ((PoseStack.Pose)this.poses.get(this.lastIndex)).set(pose); + } } public void popPose() { - this.poseStack.removeLast(); + if (this.lastIndex == 0) { + throw new NoSuchElementException(); + } else { + this.lastIndex--; + } } public PoseStack.Pose last() { - return (PoseStack.Pose)this.poseStack.getLast(); + return (PoseStack.Pose)this.poses.get(this.lastIndex); } - public boolean clear() { - return this.poseStack.size() == 1; + public boolean isEmpty() { + return this.lastIndex == 0; } public void setIdentity() { - PoseStack.Pose pose = (PoseStack.Pose)this.poseStack.getLast(); - pose.pose.identity(); - pose.normal.identity(); - pose.trustedNormals = true; + this.last().setIdentity(); } - public void mulPose(Matrix4f pose) { - PoseStack.Pose pose2 = (PoseStack.Pose)this.poseStack.getLast(); - pose2.pose.mul(pose); - if (!MatrixUtil.isPureTranslation(pose)) { - if (MatrixUtil.isOrthonormal(pose)) { - pose2.normal.mul(new Matrix3f(pose)); - } else { - pose2.computeNormalMatrix(); - } - } + public void mulPose(Matrix4fc pose) { + this.last().mulPose(pose); } @Environment(EnvType.CLIENT) public static final class Pose { - final Matrix4f pose; - final Matrix3f normal; - boolean trustedNormals = true; + private final Matrix4f pose = new Matrix4f(); + private final Matrix3f normal = new Matrix3f(); + private boolean trustedNormals = true; - Pose(Matrix4f pose, Matrix3f normal) { - this.pose = pose; - this.normal = normal; - } - - Pose(PoseStack.Pose pose) { - this.pose = new Matrix4f(pose.pose); - this.normal = new Matrix3f(pose.normal); - this.trustedNormals = pose.trustedNormals; - } - - void computeNormalMatrix() { + private void computeNormalMatrix() { this.normal.set(this.pose).invert().transpose(); this.trustedNormals = false; } + void set(PoseStack.Pose pose) { + this.pose.set(pose.pose); + this.normal.set(pose.normal); + this.trustedNormals = pose.trustedNormals; + } + public Matrix4f pose() { return this.pose; } @@ -123,8 +106,8 @@ public class PoseStack { return this.normal; } - public Vector3f transformNormal(Vector3f vector, Vector3f destination) { - return this.transformNormal(vector.x, vector.y, vector.z, destination); + public Vector3f transformNormal(Vector3fc pos, Vector3f destination) { + return this.transformNormal(pos.x(), pos.y(), pos.z(), destination); } public Vector3f transformNormal(float x, float y, float z, Vector3f destination) { @@ -132,8 +115,53 @@ public class PoseStack { return this.trustedNormals ? vector3f : vector3f.normalize(); } + public Matrix4f translate(float x, float y, float z) { + return this.pose.translate(x, y, z); + } + + public void scale(float x, float y, float z) { + this.pose.scale(x, y, z); + if (Math.abs(x) == Math.abs(y) && Math.abs(y) == Math.abs(z)) { + if (x < 0.0F || y < 0.0F || z < 0.0F) { + this.normal.scale(Math.signum(x), Math.signum(y), Math.signum(z)); + } + } else { + this.normal.scale(1.0F / x, 1.0F / y, 1.0F / z); + this.trustedNormals = false; + } + } + + public void rotate(Quaternionfc pose) { + this.pose.rotate(pose); + this.normal.rotate(pose); + } + + public void rotateAround(Quaternionfc pose, float x, float y, float z) { + this.pose.rotateAround(pose, x, y, z); + this.normal.rotate(pose); + } + + public void setIdentity() { + this.pose.identity(); + this.normal.identity(); + this.trustedNormals = true; + } + + public void mulPose(Matrix4fc pose) { + this.pose.mul(pose); + if (!MatrixUtil.isPureTranslation(pose)) { + if (MatrixUtil.isOrthonormal(pose)) { + this.normal.mul(new Matrix3f(pose)); + } else { + this.computeNormalMatrix(); + } + } + } + public PoseStack.Pose copy() { - return new PoseStack.Pose(this); + PoseStack.Pose pose = new PoseStack.Pose(); + pose.set(this); + return pose; } } } diff --git a/com/mojang/blaze3d/vertex/SheetedDecalTextureGenerator.java b/com/mojang/blaze3d/vertex/SheetedDecalTextureGenerator.java index cf49a6f1..56a18b92 100644 --- a/com/mojang/blaze3d/vertex/SheetedDecalTextureGenerator.java +++ b/com/mojang/blaze3d/vertex/SheetedDecalTextureGenerator.java @@ -1,6 +1,5 @@ package com.mojang.blaze3d.vertex; -import com.mojang.blaze3d.vertex.PoseStack.Pose; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.core.Direction; @@ -20,7 +19,7 @@ public class SheetedDecalTextureGenerator implements VertexConsumer { private float y; private float z; - public SheetedDecalTextureGenerator(VertexConsumer delegate, Pose pose, float textureScale) { + public SheetedDecalTextureGenerator(VertexConsumer delegate, PoseStack.Pose pose, float textureScale) { this.delegate = delegate; this.cameraInversePose = new Matrix4f(pose.pose()).invert(); this.normalInversePose = new Matrix3f(pose.normal()).invert(); diff --git a/com/mojang/blaze3d/vertex/VertexBuffer.java b/com/mojang/blaze3d/vertex/VertexBuffer.java deleted file mode 100644 index b6573a7c..00000000 --- a/com/mojang/blaze3d/vertex/VertexBuffer.java +++ /dev/null @@ -1,234 +0,0 @@ -package com.mojang.blaze3d.vertex; - -import com.mojang.blaze3d.buffers.BufferType; -import com.mojang.blaze3d.buffers.BufferUsage; -import com.mojang.blaze3d.buffers.GpuBuffer; -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.systems.RenderSystem; -import com.mojang.blaze3d.vertex.ByteBufferBuilder.Result; -import com.mojang.blaze3d.vertex.MeshData.DrawState; -import com.mojang.blaze3d.vertex.VertexFormat.IndexType; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; -import java.nio.ByteBuffer; -import java.util.function.Consumer; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.Minecraft; -import net.minecraft.client.renderer.CompiledShaderProgram; -import net.minecraft.client.renderer.RenderType; -import org.jetbrains.annotations.Nullable; -import org.joml.Matrix4f; - -@Environment(EnvType.CLIENT) -public class VertexBuffer implements AutoCloseable { - private final BufferUsage usage; - private final GpuBuffer vertexBuffer; - @Nullable - private GpuBuffer indexBuffer = null; - private int arrayObjectId; - @Nullable - private VertexFormat format; - @Nullable - private RenderSystem.AutoStorageIndexBuffer sequentialIndices; - private IndexType indexType; - private int indexCount; - private Mode mode; - - public VertexBuffer(BufferUsage usage) { - this.usage = usage; - RenderSystem.assertOnRenderThread(); - this.vertexBuffer = new GpuBuffer(BufferType.VERTICES, usage, 0); - this.arrayObjectId = GlStateManager._glGenVertexArrays(); - } - - public static VertexBuffer uploadStatic(Mode mode, VertexFormat format, Consumer builder) { - BufferBuilder bufferBuilder = Tesselator.getInstance().begin(mode, format); - builder.accept(bufferBuilder); - VertexBuffer vertexBuffer = new VertexBuffer(BufferUsage.STATIC_WRITE); - vertexBuffer.bind(); - vertexBuffer.upload(bufferBuilder.buildOrThrow()); - unbind(); - return vertexBuffer; - } - - public void upload(MeshData meshData) { - MeshData var2 = meshData; - - label40: { - try { - if (this.isInvalid()) { - break label40; - } - - RenderSystem.assertOnRenderThread(); - DrawState drawState = meshData.drawState(); - this.format = this.uploadVertexBuffer(drawState, meshData.vertexBuffer()); - this.sequentialIndices = this.uploadIndexBuffer(drawState, meshData.indexBuffer()); - this.indexCount = drawState.indexCount(); - this.indexType = drawState.indexType(); - this.mode = drawState.mode(); - } catch (Throwable var6) { - if (meshData != null) { - try { - var2.close(); - } catch (Throwable var5) { - var6.addSuppressed(var5); - } - } - - throw var6; - } - - if (meshData != null) { - meshData.close(); - } - - return; - } - - if (meshData != null) { - meshData.close(); - } - } - - public void uploadIndexBuffer(Result result) { - Result var2 = result; - - label46: { - try { - if (this.isInvalid()) { - break label46; - } - - RenderSystem.assertOnRenderThread(); - if (this.indexBuffer != null) { - this.indexBuffer.close(); - } - - this.indexBuffer = new GpuBuffer(BufferType.INDICES, this.usage, result.byteBuffer()); - this.sequentialIndices = null; - } catch (Throwable var6) { - if (result != null) { - try { - var2.close(); - } catch (Throwable var5) { - var6.addSuppressed(var5); - } - } - - throw var6; - } - - if (result != null) { - result.close(); - } - - return; - } - - if (result != null) { - result.close(); - } - } - - private VertexFormat uploadVertexBuffer(DrawState drawState, @Nullable ByteBuffer buffer) { - boolean bl = false; - if (!drawState.format().equals(this.format)) { - if (this.format != null) { - this.format.clearBufferState(); - } - - this.vertexBuffer.bind(); - drawState.format().setupBufferState(); - bl = true; - } - - if (buffer != null) { - if (!bl) { - this.vertexBuffer.bind(); - } - - this.vertexBuffer.resize(buffer.remaining()); - this.vertexBuffer.write(buffer, 0); - } - - return drawState.format(); - } - - @Nullable - private RenderSystem.AutoStorageIndexBuffer uploadIndexBuffer(DrawState drawState, @Nullable ByteBuffer buffer) { - if (buffer != null) { - if (this.indexBuffer != null) { - this.indexBuffer.close(); - } - - this.indexBuffer = new GpuBuffer(BufferType.INDICES, this.usage, buffer); - return null; - } else { - RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(drawState.mode()); - if (autoStorageIndexBuffer != this.sequentialIndices || !autoStorageIndexBuffer.hasStorage(drawState.indexCount())) { - autoStorageIndexBuffer.bind(drawState.indexCount()); - } - - return autoStorageIndexBuffer; - } - } - - public void bind() { - BufferUploader.invalidate(); - GlStateManager._glBindVertexArray(this.arrayObjectId); - } - - public static void unbind() { - BufferUploader.invalidate(); - GlStateManager._glBindVertexArray(0); - } - - public void draw() { - RenderSystem.drawElements(this.mode.asGLMode, this.indexCount, this.getIndexType().asGLType); - } - - private IndexType getIndexType() { - RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = this.sequentialIndices; - return autoStorageIndexBuffer != null ? autoStorageIndexBuffer.type() : this.indexType; - } - - public void drawWithShader(Matrix4f frustumMatrix, Matrix4f projectionMatrix, @Nullable CompiledShaderProgram shader) { - if (shader != null) { - RenderSystem.assertOnRenderThread(); - shader.setDefaultUniforms(this.mode, frustumMatrix, projectionMatrix, Minecraft.getInstance().getWindow()); - shader.apply(); - this.draw(); - shader.clear(); - } - } - - public void drawWithRenderType(RenderType renderType) { - renderType.setupRenderState(); - this.bind(); - this.drawWithShader(RenderSystem.getModelViewMatrix(), RenderSystem.getProjectionMatrix(), RenderSystem.getShader()); - unbind(); - renderType.clearRenderState(); - } - - public void close() { - this.vertexBuffer.close(); - if (this.indexBuffer != null) { - this.indexBuffer.close(); - this.indexBuffer = null; - } - - if (this.arrayObjectId >= 0) { - RenderSystem.glDeleteVertexArrays(this.arrayObjectId); - this.arrayObjectId = -1; - } - } - - public VertexFormat getFormat() { - return this.format; - } - - public boolean isInvalid() { - return this.arrayObjectId == -1; - } -} diff --git a/com/mojang/blaze3d/vertex/VertexConsumer.java b/com/mojang/blaze3d/vertex/VertexConsumer.java index 69363e5f..f8593b83 100644 --- a/com/mojang/blaze3d/vertex/VertexConsumer.java +++ b/com/mojang/blaze3d/vertex/VertexConsumer.java @@ -1,16 +1,15 @@ package com.mojang.blaze3d.vertex; -import com.mojang.blaze3d.vertex.PoseStack.Pose; import java.nio.ByteBuffer; import java.nio.IntBuffer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.LightTexture; import net.minecraft.client.renderer.block.model.BakedQuad; -import net.minecraft.core.Vec3i; import net.minecraft.util.ARGB; import org.joml.Matrix4f; import org.joml.Vector3f; +import org.joml.Vector3fc; import org.lwjgl.system.MemoryStack; @Environment(EnvType.CLIENT) @@ -56,7 +55,7 @@ public interface VertexConsumer { return this.setUv1(packedOverlay & 65535, packedOverlay >> 16 & 65535); } - default void putBulkData(Pose pose, BakedQuad quad, float red, float green, float blue, float alpha, int packedLight, int packedOverlay) { + default void putBulkData(PoseStack.Pose pose, BakedQuad quad, float red, float green, float blue, float alpha, int packedLight, int packedOverlay) { this.putBulkData( pose, quad, @@ -72,16 +71,25 @@ public interface VertexConsumer { } default void putBulkData( - Pose pose, BakedQuad quad, float[] brightness, float red, float green, float blue, float alpha, int[] lightmap, int packedOverlay, boolean readExistingColor + PoseStack.Pose pose, + BakedQuad quad, + float[] brightness, + float red, + float green, + float blue, + float alpha, + int[] lightmap, + int packedOverlay, + boolean readExistingColor ) { - int[] is = quad.getVertices(); - Vec3i vec3i = quad.getDirection().getUnitVec3i(); + int[] is = quad.vertices(); + Vector3fc vector3fc = quad.direction().getUnitVec3f(); Matrix4f matrix4f = pose.pose(); - Vector3f vector3f = pose.transformNormal(vec3i.getX(), vec3i.getY(), vec3i.getZ(), new Vector3f()); + Vector3f vector3f = pose.transformNormal(vector3fc, new Vector3f()); int i = 8; int j = is.length / 8; int k = (int)(alpha * 255.0F); - int l = quad.getLightEmission(); + int l = quad.lightEmission(); try (MemoryStack memoryStack = MemoryStack.stackPush()) { ByteBuffer byteBuffer = memoryStack.malloc(DefaultVertexFormat.BLOCK.getVertexSize()); @@ -123,11 +131,11 @@ public interface VertexConsumer { return this.addVertex(pos.x(), pos.y(), pos.z()); } - default VertexConsumer addVertex(Pose pose, Vector3f pos) { + default VertexConsumer addVertex(PoseStack.Pose pose, Vector3f pos) { return this.addVertex(pose, pos.x(), pos.y(), pos.z()); } - default VertexConsumer addVertex(Pose pose, float x, float y, float z) { + default VertexConsumer addVertex(PoseStack.Pose pose, float x, float y, float z) { return this.addVertex(pose.pose(), x, y, z); } @@ -136,12 +144,12 @@ public interface VertexConsumer { return this.addVertex(vector3f.x(), vector3f.y(), vector3f.z()); } - default VertexConsumer setNormal(Pose pose, float normalX, float normalY, float normalZ) { + default VertexConsumer setNormal(PoseStack.Pose pose, float normalX, float normalY, float normalZ) { Vector3f vector3f = pose.transformNormal(normalX, normalY, normalZ, new Vector3f()); return this.setNormal(vector3f.x(), vector3f.y(), vector3f.z()); } - default VertexConsumer setNormal(Pose pose, Vector3f normalVector) { + default VertexConsumer setNormal(PoseStack.Pose pose, Vector3f normalVector) { return this.setNormal(pose, normalVector.x(), normalVector.y(), normalVector.z()); } } diff --git a/com/mojang/blaze3d/vertex/VertexFormat.java b/com/mojang/blaze3d/vertex/VertexFormat.java index cac51237..54b31292 100644 --- a/com/mojang/blaze3d/vertex/VertexFormat.java +++ b/com/mojang/blaze3d/vertex/VertexFormat.java @@ -2,11 +2,16 @@ package com.mojang.blaze3d.vertex; import com.google.common.collect.ImmutableList; import com.google.common.collect.ImmutableMap; +import com.mojang.blaze3d.DontObfuscate; +import com.mojang.blaze3d.buffers.BufferType; import com.mojang.blaze3d.buffers.BufferUsage; -import com.mojang.blaze3d.platform.GlStateManager; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.systems.CommandEncoder; +import com.mojang.blaze3d.systems.GpuDevice; import com.mojang.blaze3d.systems.RenderSystem; import it.unimi.dsi.fastutil.ints.IntArrayList; import it.unimi.dsi.fastutil.ints.IntList; +import java.nio.ByteBuffer; import java.util.Arrays; import java.util.List; import net.fabricmc.api.EnvType; @@ -14,6 +19,7 @@ import net.fabricmc.api.Environment; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) +@DontObfuscate public class VertexFormat { public static final int UNKNOWN_ELEMENT = -1; private final List elements; @@ -22,18 +28,20 @@ public class VertexFormat { private final int elementsMask; private final int[] offsetsByElement = new int[32]; @Nullable - private VertexBuffer immediateDrawVertexBuffer; + private GpuBuffer immediateDrawVertexBuffer; + @Nullable + private GpuBuffer immediateDrawIndexBuffer; - VertexFormat(List elements, List names, IntList offsets, int vertexSize) { - this.elements = elements; - this.names = names; - this.vertexSize = vertexSize; - this.elementsMask = elements.stream().mapToInt(VertexFormatElement::mask).reduce(0, (ix, jx) -> ix | jx); + VertexFormat(List list, List list2, IntList intList, int i) { + this.elements = list; + this.names = list2; + this.vertexSize = i; + this.elementsMask = list.stream().mapToInt(VertexFormatElement::mask).reduce(0, (ix, jx) -> ix | jx); - for (int i = 0; i < this.offsetsByElement.length; i++) { - VertexFormatElement vertexFormatElement = VertexFormatElement.byId(i); - int j = vertexFormatElement != null ? elements.indexOf(vertexFormatElement) : -1; - this.offsetsByElement[i] = j != -1 ? offsets.getInt(j) : -1; + for (int j = 0; j < this.offsetsByElement.length; j++) { + VertexFormatElement vertexFormatElement = VertexFormatElement.byId(j); + int k = vertexFormatElement != null ? list.indexOf(vertexFormatElement) : -1; + this.offsetsByElement[j] = k != -1 ? intList.getInt(k) : -1; } } @@ -41,15 +49,6 @@ public class VertexFormat { return new VertexFormat.Builder(); } - public void bindAttributes(int program) { - int i = 0; - - for (String string : this.getElementAttributeNames()) { - GlStateManager._glBindAttribLocation(program, i, string); - i++; - } - } - public String toString() { return "VertexFormat" + this.names; } @@ -70,22 +69,22 @@ public class VertexFormat { return this.offsetsByElement; } - public int getOffset(VertexFormatElement element) { - return this.offsetsByElement[element.id()]; + public int getOffset(VertexFormatElement vertexFormatElement) { + return this.offsetsByElement[vertexFormatElement.id()]; } - public boolean contains(VertexFormatElement element) { - return (this.elementsMask & element.mask()) != 0; + public boolean contains(VertexFormatElement vertexFormatElement) { + return (this.elementsMask & vertexFormatElement.mask()) != 0; } public int getElementsMask() { return this.elementsMask; } - public String getElementName(VertexFormatElement element) { - int i = this.elements.indexOf(element); + public String getElementName(VertexFormatElement vertexFormatElement) { + int i = this.elements.indexOf(vertexFormatElement); if (i == -1) { - throw new IllegalArgumentException(element + " is not contained in format"); + throw new IllegalArgumentException(vertexFormatElement + " is not contained in format"); } else { return (String)this.names.get(i); } @@ -105,35 +104,48 @@ public class VertexFormat { return this.elementsMask * 31 + Arrays.hashCode(this.offsetsByElement); } - public void setupBufferState() { - RenderSystem.assertOnRenderThread(); - int i = this.getVertexSize(); - - for (int j = 0; j < this.elements.size(); j++) { - GlStateManager._enableVertexAttribArray(j); - VertexFormatElement vertexFormatElement = (VertexFormatElement)this.elements.get(j); - vertexFormatElement.setupBufferState(j, this.getOffset(vertexFormatElement), i); + public GpuBuffer uploadImmediateVertexBuffer(ByteBuffer byteBuffer) { + GpuDevice gpuDevice = RenderSystem.getDevice(); + if (this.immediateDrawVertexBuffer == null) { + this.immediateDrawVertexBuffer = gpuDevice.createBuffer( + () -> "Immediate vertex buffer for " + this, BufferType.VERTICES, BufferUsage.DYNAMIC_WRITE, byteBuffer + ); + } else { + CommandEncoder commandEncoder = gpuDevice.createCommandEncoder(); + if (this.immediateDrawVertexBuffer.size() < byteBuffer.remaining()) { + this.immediateDrawVertexBuffer.close(); + this.immediateDrawVertexBuffer = gpuDevice.createBuffer( + () -> "Immediate vertex buffer for " + this, BufferType.VERTICES, BufferUsage.DYNAMIC_WRITE, byteBuffer + ); + } else { + commandEncoder.writeToBuffer(this.immediateDrawVertexBuffer, byteBuffer, 0); + } } + + return this.immediateDrawVertexBuffer; } - public void clearBufferState() { - RenderSystem.assertOnRenderThread(); - - for (int i = 0; i < this.elements.size(); i++) { - GlStateManager._disableVertexAttribArray(i); - } - } - - public VertexBuffer getImmediateDrawVertexBuffer() { - VertexBuffer vertexBuffer = this.immediateDrawVertexBuffer; - if (vertexBuffer == null) { - this.immediateDrawVertexBuffer = vertexBuffer = new VertexBuffer(BufferUsage.DYNAMIC_WRITE); + public GpuBuffer uploadImmediateIndexBuffer(ByteBuffer byteBuffer) { + GpuDevice gpuDevice = RenderSystem.getDevice(); + if (this.immediateDrawIndexBuffer == null) { + this.immediateDrawIndexBuffer = RenderSystem.getDevice() + .createBuffer(() -> "Immediate index buffer for " + this, BufferType.INDICES, BufferUsage.DYNAMIC_WRITE, byteBuffer); + } else { + CommandEncoder commandEncoder = gpuDevice.createCommandEncoder(); + if (this.immediateDrawIndexBuffer.size() < byteBuffer.remaining()) { + this.immediateDrawIndexBuffer.close(); + this.immediateDrawIndexBuffer = RenderSystem.getDevice() + .createBuffer(() -> "Immediate index buffer for " + this, BufferType.INDICES, BufferUsage.DYNAMIC_WRITE, byteBuffer); + } else { + commandEncoder.writeToBuffer(this.immediateDrawIndexBuffer, byteBuffer, 0); + } } - return vertexBuffer; + return this.immediateDrawIndexBuffer; } @Environment(EnvType.CLIENT) + @DontObfuscate public static class Builder { private final ImmutableMap.Builder elements = ImmutableMap.builder(); private final IntList offsets = new IntArrayList(); @@ -142,15 +154,15 @@ public class VertexFormat { Builder() { } - public VertexFormat.Builder add(String name, VertexFormatElement element) { - this.elements.put(name, element); + public VertexFormat.Builder add(String string, VertexFormatElement vertexFormatElement) { + this.elements.put(string, vertexFormatElement); this.offsets.add(this.offset); - this.offset = this.offset + element.byteSize(); + this.offset = this.offset + vertexFormatElement.byteSize(); return this; } - public VertexFormat.Builder padding(int padding) { - this.offset += padding; + public VertexFormat.Builder padding(int i) { + this.offset += i; return this; } @@ -164,14 +176,12 @@ public class VertexFormat { @Environment(EnvType.CLIENT) public static enum IndexType { - SHORT(5123, 2), - INT(5125, 4); + SHORT(2), + INT(4); - public final int asGLType; public final int bytes; - private IndexType(final int asGLType, final int bytes) { - this.asGLType = asGLType; + private IndexType(final int bytes) { this.bytes = bytes; } @@ -182,22 +192,20 @@ public class VertexFormat { @Environment(EnvType.CLIENT) public static enum Mode { - LINES(4, 2, 2, false), - LINE_STRIP(5, 2, 1, true), - DEBUG_LINES(1, 2, 2, false), - DEBUG_LINE_STRIP(3, 2, 1, true), - TRIANGLES(4, 3, 3, false), - TRIANGLE_STRIP(5, 3, 1, true), - TRIANGLE_FAN(6, 3, 1, true), - QUADS(4, 4, 4, false); + LINES(2, 2, false), + LINE_STRIP(2, 1, true), + DEBUG_LINES(2, 2, false), + DEBUG_LINE_STRIP(2, 1, true), + TRIANGLES(3, 3, false), + TRIANGLE_STRIP(3, 1, true), + TRIANGLE_FAN(3, 1, true), + QUADS(4, 4, false); - public final int asGLMode; public final int primitiveLength; public final int primitiveStride; public final boolean connectedPrimitives; - private Mode(final int asGLMode, final int primitiveLength, final int primitiveStride, final boolean connectedPrimitives) { - this.asGLMode = asGLMode; + private Mode(final int primitiveLength, final int primitiveStride, final boolean connectedPrimitives) { this.primitiveLength = primitiveLength; this.primitiveStride = primitiveStride; this.connectedPrimitives = connectedPrimitives; diff --git a/com/mojang/blaze3d/vertex/VertexFormatElement.java b/com/mojang/blaze3d/vertex/VertexFormatElement.java index bcbaa792..842e17ac 100644 --- a/com/mojang/blaze3d/vertex/VertexFormatElement.java +++ b/com/mojang/blaze3d/vertex/VertexFormatElement.java @@ -1,6 +1,6 @@ package com.mojang.blaze3d.vertex; -import com.mojang.blaze3d.platform.GlStateManager; +import com.mojang.blaze3d.DontObfuscate; import java.util.ArrayList; import java.util.List; import java.util.stream.Stream; @@ -9,6 +9,7 @@ import net.fabricmc.api.Environment; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) +@DontObfuscate public record VertexFormatElement(int id, int index, VertexFormatElement.Type type, VertexFormatElement.Usage usage, int count) { public static final int MAX_COUNT = 32; private static final VertexFormatElement[] BY_ID = new VertexFormatElement[32]; @@ -35,19 +36,19 @@ public record VertexFormatElement(int id, int index, VertexFormatElement.Type ty } } - public static VertexFormatElement register(int id, int index, VertexFormatElement.Type type, VertexFormatElement.Usage usage, int count) { - VertexFormatElement vertexFormatElement = new VertexFormatElement(id, index, type, usage, count); - if (BY_ID[id] != null) { - throw new IllegalArgumentException("Duplicate element registration for: " + id); + public static VertexFormatElement register(int i, int j, VertexFormatElement.Type type, VertexFormatElement.Usage usage, int k) { + VertexFormatElement vertexFormatElement = new VertexFormatElement(i, j, type, usage, k); + if (BY_ID[i] != null) { + throw new IllegalArgumentException("Duplicate element registration for: " + i); } else { - BY_ID[id] = vertexFormatElement; + BY_ID[i] = vertexFormatElement; ELEMENTS.add(vertexFormatElement); return vertexFormatElement; } } - private boolean supportsUsage(int index, VertexFormatElement.Usage usage) { - return index == 0 || usage == VertexFormatElement.Usage.UV; + private boolean supportsUsage(int i, VertexFormatElement.Usage usage) { + return i == 0 || usage == VertexFormatElement.Usage.UV; } public String toString() { @@ -62,82 +63,60 @@ public record VertexFormatElement(int id, int index, VertexFormatElement.Type ty return this.type.size() * this.count; } - public void setupBufferState(int stateIndex, long offset, int stride) { - this.usage.setupState.setupBufferState(this.count, this.type.glType(), stride, offset, stateIndex); - } - @Nullable - public static VertexFormatElement byId(int id) { - return BY_ID[id]; + public static VertexFormatElement byId(int i) { + return BY_ID[i]; } - public static Stream elementsFromMask(int mask) { - return ELEMENTS.stream().filter(vertexFormatElement -> vertexFormatElement != null && (mask & vertexFormatElement.mask()) != 0); + public static Stream elementsFromMask(int i) { + return ELEMENTS.stream().filter(vertexFormatElement -> vertexFormatElement != null && (i & vertexFormatElement.mask()) != 0); } @Environment(EnvType.CLIENT) + @DontObfuscate public static enum Type { - FLOAT(4, "Float", 5126), - UBYTE(1, "Unsigned Byte", 5121), - BYTE(1, "Byte", 5120), - USHORT(2, "Unsigned Short", 5123), - SHORT(2, "Short", 5122), - UINT(4, "Unsigned Int", 5125), - INT(4, "Int", 5124); + FLOAT(4, "Float"), + UBYTE(1, "Unsigned Byte"), + BYTE(1, "Byte"), + USHORT(2, "Unsigned Short"), + SHORT(2, "Short"), + UINT(4, "Unsigned Int"), + INT(4, "Int"); private final int size; private final String name; - private final int glType; - private Type(final int size, final String name, final int glType) { - this.size = size; - this.name = name; - this.glType = glType; + private Type(final int j, final String string2) { + this.size = j; + this.name = string2; } public int size() { return this.size; } - public int glType() { - return this.glType; - } - public String toString() { return this.name; } } @Environment(EnvType.CLIENT) + @DontObfuscate public static enum Usage { - POSITION("Position", (i, j, k, l, m) -> GlStateManager._vertexAttribPointer(m, i, j, false, k, l)), - NORMAL("Normal", (i, j, k, l, m) -> GlStateManager._vertexAttribPointer(m, i, j, true, k, l)), - COLOR("Vertex Color", (i, j, k, l, m) -> GlStateManager._vertexAttribPointer(m, i, j, true, k, l)), - UV("UV", (i, j, k, l, m) -> { - if (j == 5126) { - GlStateManager._vertexAttribPointer(m, i, j, false, k, l); - } else { - GlStateManager._vertexAttribIPointer(m, i, j, k, l); - } - }), - GENERIC("Generic", (i, j, k, l, m) -> GlStateManager._vertexAttribPointer(m, i, j, false, k, l)); + POSITION("Position"), + NORMAL("Normal"), + COLOR("Vertex Color"), + UV("UV"), + GENERIC("Generic"); private final String name; - final VertexFormatElement.Usage.SetupState setupState; - private Usage(final String name, final VertexFormatElement.Usage.SetupState setupState) { - this.name = name; - this.setupState = setupState; + private Usage(final String string2) { + this.name = string2; } public String toString() { return this.name; } - - @FunctionalInterface - @Environment(EnvType.CLIENT) - interface SetupState { - void setupBufferState(int i, int j, int k, long l, int m); - } } } diff --git a/com/mojang/math/MatrixUtil.java b/com/mojang/math/MatrixUtil.java index 4766d9b0..72f37228 100644 --- a/com/mojang/math/MatrixUtil.java +++ b/com/mojang/math/MatrixUtil.java @@ -4,6 +4,7 @@ import org.apache.commons.lang3.tuple.Triple; import org.joml.Math; import org.joml.Matrix3f; import org.joml.Matrix4f; +import org.joml.Matrix4fc; import org.joml.Quaternionf; import org.joml.Vector3f; @@ -147,15 +148,30 @@ public class MatrixUtil { return Triple.of(quaternionf2, vector3f, quaternionf.conjugate()); } - public static boolean isIdentity(Matrix4f matrix) { - return (matrix.properties() & 4) != 0; + private static boolean checkPropertyRaw(Matrix4fc matrix, int property) { + return (matrix.properties() & property) != 0; } - public static boolean isPureTranslation(Matrix4f matrix) { - return (matrix.properties() & 8) != 0; + public static boolean checkProperty(Matrix4fc matrix, int property) { + if (checkPropertyRaw(matrix, property)) { + return true; + } else if (matrix instanceof Matrix4f matrix4f) { + matrix4f.determineProperties(); + return checkPropertyRaw(matrix, property); + } else { + return false; + } } - public static boolean isOrthonormal(Matrix4f matrix) { - return (matrix.properties() & 16) != 0; + public static boolean isIdentity(Matrix4fc matrix) { + return checkProperty(matrix, 4); + } + + public static boolean isPureTranslation(Matrix4fc matrix) { + return checkProperty(matrix, 8); + } + + public static boolean isOrthonormal(Matrix4fc matrix) { + return checkProperty(matrix, 16); } } diff --git a/com/mojang/math/OctahedralGroup.java b/com/mojang/math/OctahedralGroup.java index 2bfa03d3..74d1d685 100644 --- a/com/mojang/math/OctahedralGroup.java +++ b/com/mojang/math/OctahedralGroup.java @@ -1,6 +1,5 @@ package com.mojang.math; -import com.google.common.collect.Maps; import com.mojang.datafixers.util.Pair; import it.unimi.dsi.fastutil.booleans.BooleanArrayList; import it.unimi.dsi.fastutil.booleans.BooleanList; @@ -13,6 +12,7 @@ import net.minecraft.core.FrontAndTop; import net.minecraft.util.StringRepresentable; import org.jetbrains.annotations.Nullable; import org.joml.Matrix3f; +import org.joml.Matrix3fc; public enum OctahedralGroup implements StringRepresentable { IDENTITY("identity", SymmetricGroup3.P123, false, false, false), @@ -64,7 +64,8 @@ public enum OctahedralGroup implements StringRepresentable { ROT_90_REF_Z_NEG("rot_90_ref_z_neg", SymmetricGroup3.P213, false, true, true), ROT_90_REF_Z_POS("rot_90_ref_z_pos", SymmetricGroup3.P213, true, false, true); - private final Matrix3f transformation; + private static final Direction.Axis[] AXES = Direction.Axis.values(); + private final Matrix3fc transformation; private final String name; @Nullable private Map rotatedDirections; @@ -72,7 +73,7 @@ public enum OctahedralGroup implements StringRepresentable { private final boolean invertY; private final boolean invertZ; private final SymmetricGroup3 permutation; - private static final OctahedralGroup[][] cayleyTable = Util.make( + private static final OctahedralGroup[][] CAYLEY_TABLE = Util.make( new OctahedralGroup[values().length][values().length], octahedralGroups -> { Map, OctahedralGroup> map = (Map, OctahedralGroup>)Arrays.stream(values()) @@ -96,7 +97,7 @@ public enum OctahedralGroup implements StringRepresentable { } } ); - private static final OctahedralGroup[] inverseTable = (OctahedralGroup[])Arrays.stream(values()) + private static final OctahedralGroup[] INVERSE_TABLE = (OctahedralGroup[])Arrays.stream(values()) .map( octahedralGroup -> (OctahedralGroup)Arrays.stream(values()) .filter(octahedralGroup2 -> octahedralGroup.compose(octahedralGroup2) == IDENTITY) @@ -104,6 +105,23 @@ public enum OctahedralGroup implements StringRepresentable { .get() ) .toArray(OctahedralGroup[]::new); + private static final OctahedralGroup[][] XY_TABLE = Util.make(new OctahedralGroup[Quadrant.values().length][Quadrant.values().length], octahedralGroups -> { + for (Quadrant quadrant : Quadrant.values()) { + for (Quadrant quadrant2 : Quadrant.values()) { + OctahedralGroup octahedralGroup = IDENTITY; + + for (int i = 0; i < quadrant2.shift; i++) { + octahedralGroup = octahedralGroup.compose(ROT_90_Y_NEG); + } + + for (int i = 0; i < quadrant.shift; i++) { + octahedralGroup = octahedralGroup.compose(ROT_90_X_NEG); + } + + octahedralGroups[quadrant.ordinal()][quadrant2.ordinal()] = octahedralGroup; + } + } + }); private OctahedralGroup(final String name, final SymmetricGroup3 permutation, final boolean invertX, final boolean invertY, final boolean invertZ) { this.name = name; @@ -111,8 +129,9 @@ public enum OctahedralGroup implements StringRepresentable { this.invertY = invertY; this.invertZ = invertZ; this.permutation = permutation; - this.transformation = new Matrix3f().scaling(invertX ? -1.0F : 1.0F, invertY ? -1.0F : 1.0F, invertZ ? -1.0F : 1.0F); - this.transformation.mul(permutation.transformation()); + Matrix3f matrix3f = new Matrix3f().scaling(invertX ? -1.0F : 1.0F, invertY ? -1.0F : 1.0F, invertZ ? -1.0F : 1.0F); + matrix3f.mul(permutation.transformation()); + this.transformation = matrix3f; } private BooleanList packInversions() { @@ -120,15 +139,15 @@ public enum OctahedralGroup implements StringRepresentable { } public OctahedralGroup compose(OctahedralGroup other) { - return cayleyTable[this.ordinal()][other.ordinal()]; + return CAYLEY_TABLE[this.ordinal()][other.ordinal()]; } public OctahedralGroup inverse() { - return inverseTable[this.ordinal()]; + return INVERSE_TABLE[this.ordinal()]; } - public Matrix3f transformation() { - return new Matrix3f(this.transformation); + public Matrix3fc transformation() { + return this.transformation; } public String toString() { @@ -142,35 +161,35 @@ public enum OctahedralGroup implements StringRepresentable { public Direction rotate(Direction direction) { if (this.rotatedDirections == null) { - this.rotatedDirections = Maps.newEnumMap(Direction.class); - Direction.Axis[] axiss = Direction.Axis.values(); - - for (Direction direction2 : Direction.values()) { - Direction.Axis axis = direction2.getAxis(); - Direction.AxisDirection axisDirection = direction2.getAxisDirection(); - Direction.Axis axis2 = axiss[this.permutation.permutation(axis.ordinal())]; + this.rotatedDirections = Util.makeEnumMap(Direction.class, directionx -> { + Direction.Axis axis = directionx.getAxis(); + Direction.AxisDirection axisDirection = directionx.getAxisDirection(); + Direction.Axis axis2 = this.permute(axis); Direction.AxisDirection axisDirection2 = this.inverts(axis2) ? axisDirection.opposite() : axisDirection; - Direction direction3 = Direction.fromAxisAndDirection(axis2, axisDirection2); - this.rotatedDirections.put(direction2, direction3); - } + return Direction.fromAxisAndDirection(axis2, axisDirection2); + }); } return (Direction)this.rotatedDirections.get(direction); } public boolean inverts(Direction.Axis axis) { - switch (axis) { - case X: - return this.invertX; - case Y: - return this.invertY; - case Z: - default: - return this.invertZ; - } + return switch (axis) { + case X -> this.invertX; + case Y -> this.invertY; + case Z -> this.invertZ; + }; + } + + public Direction.Axis permute(Direction.Axis axis) { + return AXES[this.permutation.permutation(axis.ordinal())]; } public FrontAndTop rotate(FrontAndTop frontAndTop) { return FrontAndTop.fromFrontAndTop(this.rotate(frontAndTop.front()), this.rotate(frontAndTop.top())); } + + public static OctahedralGroup fromXYAngles(Quadrant x, Quadrant y) { + return XY_TABLE[x.ordinal()][y.ordinal()]; + } } diff --git a/com/mojang/math/Quadrant.java b/com/mojang/math/Quadrant.java new file mode 100644 index 00000000..1d38a8a3 --- /dev/null +++ b/com/mojang/math/Quadrant.java @@ -0,0 +1,50 @@ +package com.mojang.math; + +import com.google.gson.JsonParseException; +import com.mojang.serialization.Codec; +import com.mojang.serialization.DataResult; +import net.minecraft.util.Mth; + +public enum Quadrant { + R0(0), + R90(1), + R180(2), + R270(3); + + public static final Codec CODEC = Codec.INT.comapFlatMap(integer -> { + return switch (Mth.positiveModulo(integer, 360)) { + case 0 -> DataResult.success(R0); + case 90 -> DataResult.success(R90); + case 180 -> DataResult.success(R180); + case 270 -> DataResult.success(R270); + default -> DataResult.error(() -> "Invalid rotation " + integer + " found, only 0/90/180/270 allowed"); + }; + }, quadrant -> { + return switch (quadrant) { + case R0 -> 0; + case R90 -> 90; + case R180 -> 180; + case R270 -> 270; + }; + }); + public final int shift; + + private Quadrant(final int shift) { + this.shift = shift; + } + + @Deprecated + public static Quadrant parseJson(int rotation) { + return switch (Mth.positiveModulo(rotation, 360)) { + case 0 -> R0; + case 90 -> R90; + case 180 -> R180; + case 270 -> R270; + default -> throw new JsonParseException("Invalid rotation " + rotation + " found, only 0/90/180/270 allowed"); + }; + } + + public int rotateVertexIndex(int shift) { + return (shift + this.shift) % 4; + } +} diff --git a/com/mojang/math/SymmetricGroup3.java b/com/mojang/math/SymmetricGroup3.java index d5c66800..68766a57 100644 --- a/com/mojang/math/SymmetricGroup3.java +++ b/com/mojang/math/SymmetricGroup3.java @@ -3,6 +3,7 @@ package com.mojang.math; import java.util.Arrays; import net.minecraft.Util; import org.joml.Matrix3f; +import org.joml.Matrix3fc; /** * The symmetric group S3, also known as all the permutation orders of three elements. @@ -16,9 +17,9 @@ public enum SymmetricGroup3 { P321(2, 1, 0); private final int[] permutation; - private final Matrix3f transformation; + private final Matrix3fc transformation; private static final int ORDER = 3; - private static final SymmetricGroup3[][] cayleyTable = Util.make( + private static final SymmetricGroup3[][] CAYLEY_TABLE = Util.make( new SymmetricGroup3[values().length][values().length], symmetricGroup3s -> { for (SymmetricGroup3 symmetricGroup3 : values()) { @@ -41,21 +42,22 @@ public enum SymmetricGroup3 { private SymmetricGroup3(final int first, final int second, final int third) { this.permutation = new int[]{first, second, third}; - this.transformation = new Matrix3f(); - this.transformation.set(this.permutation(0), 0, 1.0F); - this.transformation.set(this.permutation(1), 1, 1.0F); - this.transformation.set(this.permutation(2), 2, 1.0F); + Matrix3f matrix3f = new Matrix3f().zero(); + matrix3f.set(this.permutation(0), 0, 1.0F); + matrix3f.set(this.permutation(1), 1, 1.0F); + matrix3f.set(this.permutation(2), 2, 1.0F); + this.transformation = matrix3f; } public SymmetricGroup3 compose(SymmetricGroup3 other) { - return cayleyTable[this.ordinal()][other.ordinal()]; + return CAYLEY_TABLE[this.ordinal()][other.ordinal()]; } public int permutation(int element) { return this.permutation[element]; } - public Matrix3f transformation() { + public Matrix3fc transformation() { return this.transformation; } } diff --git a/com/mojang/math/Transformation.java b/com/mojang/math/Transformation.java index a8e399c0..8621a995 100644 --- a/com/mojang/math/Transformation.java +++ b/com/mojang/math/Transformation.java @@ -9,11 +9,12 @@ import org.apache.commons.lang3.tuple.Triple; import org.jetbrains.annotations.Nullable; import org.joml.Matrix3f; import org.joml.Matrix4f; +import org.joml.Matrix4fc; import org.joml.Quaternionf; import org.joml.Vector3f; public final class Transformation { - private final Matrix4f matrix; + private final Matrix4fc matrix; public static final Codec CODEC = RecordCodecBuilder.create( instance -> instance.group( ExtraCodecs.VECTOR3F.fieldOf("translation").forGetter(transformation -> transformation.translation), @@ -45,7 +46,7 @@ public final class Transformation { return transformation; }); - public Transformation(@Nullable Matrix4f matrix) { + public Transformation(@Nullable Matrix4fc matrix) { if (matrix == null) { this.matrix = new Matrix4f(); } else { @@ -67,7 +68,7 @@ public final class Transformation { } public Transformation compose(Transformation other) { - Matrix4f matrix4f = this.getMatrix(); + Matrix4f matrix4f = this.getMatrixCopy(); matrix4f.mul(other.getMatrix()); return new Transformation(matrix4f); } @@ -77,7 +78,7 @@ public final class Transformation { if (this == IDENTITY) { return this; } else { - Matrix4f matrix4f = this.getMatrix().invert(); + Matrix4f matrix4f = this.getMatrixCopy().invertAffine(); return matrix4f.isFinite() ? new Transformation(matrix4f) : null; } } @@ -117,7 +118,11 @@ public final class Transformation { return matrix4f; } - public Matrix4f getMatrix() { + public Matrix4fc getMatrix() { + return this.matrix; + } + + public Matrix4f getMatrixCopy() { return new Matrix4f(this.matrix); } diff --git a/com/mojang/realmsclient/RealmsAvailability.java b/com/mojang/realmsclient/RealmsAvailability.java index 9d54a067..6291eacf 100644 --- a/com/mojang/realmsclient/RealmsAvailability.java +++ b/com/mojang/realmsclient/RealmsAvailability.java @@ -43,7 +43,7 @@ public class RealmsAvailability { ? CompletableFuture.completedFuture(new RealmsAvailability.Result(RealmsAvailability.Type.AUTHENTICATION_ERROR)) : CompletableFuture.supplyAsync( () -> { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { if (realmsClient.clientCompatible() != RealmsClient.CompatibleVersionResponse.COMPATIBLE) { diff --git a/com/mojang/realmsclient/RealmsMainScreen.java b/com/mojang/realmsclient/RealmsMainScreen.java index 443707e2..26414b7b 100644 --- a/com/mojang/realmsclient/RealmsMainScreen.java +++ b/com/mojang/realmsclient/RealmsMainScreen.java @@ -5,7 +5,6 @@ import com.google.common.util.concurrent.RateLimiter; import com.mojang.authlib.yggdrasil.ProfileResult; import com.mojang.logging.LogUtils; import com.mojang.math.Axis; -import com.mojang.realmsclient.RealmsAvailability.Result; import com.mojang.realmsclient.client.Ping; import com.mojang.realmsclient.client.RealmsClient; import com.mojang.realmsclient.dto.PingResult; @@ -64,6 +63,7 @@ import net.minecraft.client.gui.components.PopupScreen; import net.minecraft.client.gui.components.Tooltip; import net.minecraft.client.gui.components.WidgetSprites; import net.minecraft.client.gui.components.WidgetTooltipHolder; +import net.minecraft.client.gui.components.Button.OnPress; import net.minecraft.client.gui.components.SpriteIconButton.CenteredIcon; import net.minecraft.client.gui.layouts.FrameLayout; import net.minecraft.client.gui.layouts.GridLayout; @@ -143,7 +143,7 @@ public class RealmsMainScreen extends RealmsScreen { private static final int ITEM_HEIGHT = 36; private static final boolean SNAPSHOT = !SharedConstants.getCurrentVersion().isStable(); private static boolean snapshotToggle = SNAPSHOT; - private final CompletableFuture availability = RealmsAvailability.get(); + private final CompletableFuture availability = RealmsAvailability.get(); @Nullable private Subscription dataSubscription; private final Set handledSeenNotifications = new HashSet(); @@ -205,7 +205,7 @@ public class RealmsMainScreen extends RealmsScreen { this.leaveButton = Button.builder(LEAVE_SERVER_TEXT, button -> this.leaveClicked(this.getSelectedServer())).width(100).build(); this.addRealmButton = Button.builder(Component.translatable("mco.selectServer.purchase"), button -> this.openTrialAvailablePopup()).size(100, 20).build(); this.backButton = Button.builder(CommonComponents.GUI_BACK, button -> this.onClose()).width(100).build(); - if (RealmsClient.ENVIRONMENT == com.mojang.realmsclient.client.RealmsClient.Environment.STAGE) { + if (RealmsClient.ENVIRONMENT == RealmsClient.Environment.STAGE) { this.addRenderableWidget( CycleButton.booleanBuilder(Component.literal("Snapshot"), Component.literal("Release")) .create(5, 5, 100, 20, Component.literal("Realm"), (cycleButton, boolean_) -> { @@ -452,7 +452,7 @@ public class RealmsMainScreen extends RealmsScreen { Minecraft minecraft = Minecraft.getInstance(); CompletableFuture.supplyAsync(() -> { try { - return call.request(RealmsClient.create(minecraft)); + return call.request(RealmsClient.getOrCreate(minecraft)); } catch (RealmsServiceException var3) { throw new RuntimeException(var3); } @@ -471,7 +471,7 @@ public class RealmsMainScreen extends RealmsScreen { private void pingRegions() { new Thread(() -> { List list = Ping.pingAllRegions(); - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); PingResult pingResult = new PingResult(); pingResult.pingResults = list; pingResult.realmIds = this.getOwnedNonExpiredRealmIds(); @@ -526,7 +526,7 @@ public class RealmsMainScreen extends RealmsScreen { (new Thread("Realms-leave-server") { public void run() { try { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); realmsClient.uninviteMyselfFrom(server.id); RealmsMainScreen.this.minecraft.execute(RealmsMainScreen::refreshServerList); } catch (RealmsServiceException var2) { @@ -812,7 +812,7 @@ public class RealmsMainScreen extends RealmsScreen { ResourceLocation.withDefaultNamespace("widget/cross_button"), ResourceLocation.withDefaultNamespace("widget/cross_button_highlighted") ); - protected CrossButton(Button.OnPress onPress, Component message) { + protected CrossButton(OnPress onPress, Component message) { super(0, 0, 14, 14, SPRITES, onPress); this.setTooltip(Tooltip.create(message)); } @@ -969,7 +969,7 @@ public class RealmsMainScreen extends RealmsScreen { private static final int SPRITE_SIZE = 14; private int notificationCount; - public NotificationButton(Component message, ResourceLocation sprite, Button.OnPress onPress) { + public NotificationButton(Component message, ResourceLocation sprite, OnPress onPress) { super(20, 20, message, 14, 14, sprite, onPress, null); } diff --git a/com/mojang/realmsclient/client/RealmsClient.java b/com/mojang/realmsclient/client/RealmsClient.java index 9c524a0f..315856bb 100644 --- a/com/mojang/realmsclient/client/RealmsClient.java +++ b/com/mojang/realmsclient/client/RealmsClient.java @@ -1,6 +1,8 @@ package com.mojang.realmsclient.client; import com.google.gson.JsonArray; +import com.google.gson.JsonElement; +import com.google.gson.JsonParser; import com.mojang.logging.LogUtils; import com.mojang.realmsclient.RealmsMainScreen; import com.mojang.realmsclient.client.RealmsError.AuthenticationError; @@ -26,6 +28,7 @@ import com.mojang.realmsclient.dto.Subscription; import com.mojang.realmsclient.dto.UploadInfo; import com.mojang.realmsclient.dto.WorldDownload; import com.mojang.realmsclient.dto.WorldTemplatePaginatedList; +import com.mojang.realmsclient.dto.RealmsServer.WorldType; import com.mojang.realmsclient.exception.RealmsHttpException; import com.mojang.realmsclient.exception.RealmsServiceException; import com.mojang.realmsclient.exception.RetryCallException; @@ -38,8 +41,11 @@ import java.util.Locale; import java.util.Optional; import java.util.Set; import java.util.UUID; +import java.util.concurrent.CompletableFuture; +import java.util.stream.Collectors; import net.fabricmc.api.EnvType; import net.minecraft.SharedConstants; +import net.minecraft.Util; import net.minecraft.client.Minecraft; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -51,6 +57,9 @@ public class RealmsClient { .flatMap(RealmsClient.Environment::byName) .orElse(RealmsClient.Environment.PRODUCTION); private static final Logger LOGGER = LogUtils.getLogger(); + @Nullable + private static volatile RealmsClient realmsClientInstance = null; + private final CompletableFuture> featureFlags; private final String sessionId; private final String username; private final Minecraft minecraft; @@ -63,6 +72,7 @@ public class RealmsClient { private static final String REGIONS_RESOURCE = "regions/ping/stat"; private static final String TRIALS_RESOURCE = "trial"; private static final String NOTIFICATIONS_RESOURCE = "notifications"; + private static final String FEATURE_FLAGS_RESOURCE = "feature/v1"; private static final String PATH_LIST_ALL_REALMS = "/listUserWorldsOfType/any"; private static final String PATH_CREATE_SNAPSHOT_REALM = "/$PARENT_WORLD_ID/createPrereleaseRealm"; private static final String PATH_SNAPSHOT_ELIGIBLE_REALMS = "/listPrereleaseEligibleWorlds"; @@ -99,22 +109,59 @@ public class RealmsClient { private static final String PATH_DISMISS_NOTIFICATIONS = "/dismiss"; private static final GuardedSerializer GSON = new GuardedSerializer(); - public static RealmsClient create() { + public static RealmsClient getOrCreate() { Minecraft minecraft = Minecraft.getInstance(); - return create(minecraft); + return getOrCreate(minecraft); } - public static RealmsClient create(Minecraft minecraft) { + public static RealmsClient getOrCreate(Minecraft minecraft) { String string = minecraft.getUser().getName(); String string2 = minecraft.getUser().getSessionId(); - return new RealmsClient(string2, string, minecraft); + RealmsClient realmsClient = realmsClientInstance; + if (realmsClient != null) { + return realmsClient; + } else { + synchronized (RealmsClient.class) { + RealmsClient realmsClient2 = realmsClientInstance; + if (realmsClient2 != null) { + return realmsClient2; + } else { + realmsClient2 = new RealmsClient(string2, string, minecraft); + realmsClientInstance = realmsClient2; + return realmsClient2; + } + } + } } - public RealmsClient(String sessionId, String username, Minecraft minecraft) { + private RealmsClient(String sessionId, String username, Minecraft minecraft) { this.sessionId = sessionId; this.username = username; this.minecraft = minecraft; RealmsClientConfig.setProxy(minecraft.getProxy()); + this.featureFlags = CompletableFuture.supplyAsync(this::fetchFeatureFlags, Util.nonCriticalIoPool()); + } + + public Set getFeatureFlags() { + return (Set)this.featureFlags.join(); + } + + private Set fetchFeatureFlags() { + String string = url("feature/v1", null, false); + + try { + String string2 = this.execute(Request.get(string, 5000, 10000)); + JsonArray jsonArray = JsonParser.parseString(string2).getAsJsonArray(); + Set set = (Set)jsonArray.asList().stream().map(JsonElement::getAsString).collect(Collectors.toSet()); + LOGGER.debug("Fetched Realms feature flags: {}", set); + return set; + } catch (RealmsServiceException var5) { + LOGGER.error("Failed to fetch Realms feature flags", (Throwable)var5); + } catch (Exception var6) { + LOGGER.error("Could not parse Realms feature flags", (Throwable)var6); + } + + return Set.of(); } public RealmsServerList listRealms() throws RealmsServiceException { @@ -264,7 +311,7 @@ public class RealmsClient { this.execute(Request.put(string, "", 40000, 600000)); } - public WorldTemplatePaginatedList fetchWorldTemplates(int page, int pageSize, RealmsServer.WorldType worldType) throws RealmsServiceException { + public WorldTemplatePaginatedList fetchWorldTemplates(int page, int pageSize, WorldType worldType) throws RealmsServiceException { String string = this.url( "worlds" + "/templates/$WORLD_TYPE".replace("$WORLD_TYPE", worldType.toString()), String.format(Locale.ROOT, "page=%d&pageSize=%d", page, pageSize) ); @@ -388,13 +435,17 @@ public class RealmsClient { this.execute(Request.delete(string)); } - private String url(String path) { + private String url(String path) throws RealmsServiceException { return this.url(path, null); } - private String url(String path, @Nullable String query) { + private String url(String path, @Nullable String query) throws RealmsServiceException { + return url(path, query, this.getFeatureFlags().contains("realms_in_aks")); + } + + private static String url(String path, @Nullable String query, boolean useAlternativeUrl) { try { - return new URI(ENVIRONMENT.protocol, ENVIRONMENT.baseUrl, "/" + path, query, null).toASCIIString(); + return new URI(ENVIRONMENT.protocol, useAlternativeUrl ? ENVIRONMENT.alternativeUrl : ENVIRONMENT.baseUrl, "/" + path, query, null).toASCIIString(); } catch (URISyntaxException var4) { throw new IllegalArgumentException(path, var4); } @@ -438,15 +489,17 @@ public class RealmsClient { @net.fabricmc.api.Environment(EnvType.CLIENT) public static enum Environment { - PRODUCTION("pc.realms.minecraft.net", "https"), - STAGE("pc-stage.realms.minecraft.net", "https"), - LOCAL("localhost:8080", "http"); + PRODUCTION("pc.realms.minecraft.net", "java.frontendlegacy.realms.minecraft-services.net", "https"), + STAGE("pc-stage.realms.minecraft.net", "java.frontendlegacy.stage-c2a40e62.realms.minecraft-services.net", "https"), + LOCAL("localhost:8080", "localhost:8080", "http"); public final String baseUrl; + public final String alternativeUrl; public final String protocol; - private Environment(final String baseUrl, final String protocol) { + private Environment(final String baseUrl, final String alternativeUrl, final String protocol) { this.baseUrl = baseUrl; + this.alternativeUrl = alternativeUrl; this.protocol = protocol; } diff --git a/com/mojang/realmsclient/client/worldupload/RealmsCreateWorldFlow.java b/com/mojang/realmsclient/client/worldupload/RealmsCreateWorldFlow.java index c834a42b..e28dd3bc 100644 --- a/com/mojang/realmsclient/client/worldupload/RealmsCreateWorldFlow.java +++ b/com/mojang/realmsclient/client/worldupload/RealmsCreateWorldFlow.java @@ -49,7 +49,7 @@ public class RealmsCreateWorldFlow { } RealmsWorldOptions realmsWorldOptions = RealmsWorldOptions.createFromSettings( - primaryLevelData.getLevelSettings(), SharedConstants.getCurrentVersion().getName() + primaryLevelData.getLevelSettings(), primaryLevelData.getLevelSettings().allowCommands(), SharedConstants.getCurrentVersion().getName() ); RealmsWorldUpload realmsWorldUpload = new RealmsWorldUpload( path2, realmsWorldOptions, minecraft.getUser(), server.id, slot, RealmsWorldUploadStatusTracker.noOp() diff --git a/com/mojang/realmsclient/client/worldupload/RealmsWorldUpload.java b/com/mojang/realmsclient/client/worldupload/RealmsWorldUpload.java index 0d52d6a5..251a7f75 100644 --- a/com/mojang/realmsclient/client/worldupload/RealmsWorldUpload.java +++ b/com/mojang/realmsclient/client/worldupload/RealmsWorldUpload.java @@ -26,7 +26,7 @@ import org.slf4j.Logger; public class RealmsWorldUpload { private static final Logger LOGGER = LogUtils.getLogger(); public static final int UPLOAD_RETRIES = 20; - private final RealmsClient client = RealmsClient.create(); + private final RealmsClient client = RealmsClient.getOrCreate(); private final Path worldFolder; private final RealmsWorldOptions worldOptions; private final User user; diff --git a/com/mojang/realmsclient/dto/RealmsWorldOptions.java b/com/mojang/realmsclient/dto/RealmsWorldOptions.java index 949987e9..3856049a 100644 --- a/com/mojang/realmsclient/dto/RealmsWorldOptions.java +++ b/com/mojang/realmsclient/dto/RealmsWorldOptions.java @@ -1,6 +1,7 @@ package com.mojang.realmsclient.dto; import com.google.gson.JsonObject; +import com.mojang.realmsclient.dto.RealmsServer.Compatibility; import com.mojang.realmsclient.util.JsonUtils; import java.util.Objects; import net.fabricmc.api.EnvType; @@ -24,7 +25,7 @@ public class RealmsWorldOptions extends ValueObject { public final boolean hardcore; private final String slotName; public final String version; - public final RealmsServer.Compatibility compatibility; + public final Compatibility compatibility; public long templateId; @Nullable public String templateImage; @@ -39,7 +40,7 @@ public class RealmsWorldOptions extends ValueObject { private static final boolean DEFAULT_HARDCORE_MODE = false; private static final String DEFAULT_SLOT_NAME = ""; private static final String DEFAULT_VERSION = ""; - private static final RealmsServer.Compatibility DEFAULT_COMPATIBILITY = RealmsServer.Compatibility.UNVERIFIABLE; + private static final Compatibility DEFAULT_COMPATIBILITY = Compatibility.UNVERIFIABLE; private static final long DEFAULT_TEMPLATE_ID = -1L; private static final String DEFAULT_TEMPLATE_IMAGE = null; @@ -54,7 +55,7 @@ public class RealmsWorldOptions extends ValueObject { boolean forceGameMode, String slotName, String version, - RealmsServer.Compatibility compatibility + Compatibility compatibility ) { this.pvp = pvp; this.spawnMonsters = spawnMonsters; @@ -73,12 +74,14 @@ public class RealmsWorldOptions extends ValueObject { return new RealmsWorldOptions(true, true, 0, false, 2, 0, false, false, "", "", DEFAULT_COMPATIBILITY); } - public static RealmsWorldOptions createDefaultsWith(GameType gameMode, Difficulty difficulty, boolean hardcore, String version, String slotName) { - return new RealmsWorldOptions(true, true, 0, false, difficulty.getId(), gameMode.getId(), hardcore, false, slotName, version, DEFAULT_COMPATIBILITY); + public static RealmsWorldOptions createDefaultsWith( + GameType gameType, boolean commandBlocks, Difficulty difficulty, boolean hardcore, String version, String slotName + ) { + return new RealmsWorldOptions(true, true, 0, commandBlocks, difficulty.getId(), gameType.getId(), hardcore, false, slotName, version, DEFAULT_COMPATIBILITY); } - public static RealmsWorldOptions createFromSettings(LevelSettings settings, String version) { - return createDefaultsWith(settings.gameType(), settings.difficulty(), settings.hardcore(), version, settings.levelName()); + public static RealmsWorldOptions createFromSettings(LevelSettings levelSettings, boolean commandBlocks, String version) { + return createDefaultsWith(levelSettings.gameType(), commandBlocks, levelSettings.difficulty(), levelSettings.hardcore(), version, levelSettings.levelName()); } public static RealmsWorldOptions createEmptyDefaults() { @@ -103,7 +106,7 @@ public class RealmsWorldOptions extends ValueObject { JsonUtils.getBooleanOr("forceGameMode", json, false), JsonUtils.getRequiredStringOr("slotName", json, ""), JsonUtils.getRequiredStringOr("version", json, ""), - RealmsServer.getCompatibility(JsonUtils.getRequiredStringOr("compatibility", json, RealmsServer.Compatibility.UNVERIFIABLE.name())) + RealmsServer.getCompatibility(JsonUtils.getRequiredStringOr("compatibility", json, Compatibility.UNVERIFIABLE.name())) ); realmsWorldOptions.templateId = JsonUtils.getLongOr("worldTemplateId", json, -1L); realmsWorldOptions.templateImage = JsonUtils.getStringOr("worldTemplateImage", json, DEFAULT_TEMPLATE_IMAGE); diff --git a/com/mojang/realmsclient/gui/screens/AddRealmPopupScreen.java b/com/mojang/realmsclient/gui/screens/AddRealmPopupScreen.java index e323d6da..8045646a 100644 --- a/com/mojang/realmsclient/gui/screens/AddRealmPopupScreen.java +++ b/com/mojang/realmsclient/gui/screens/AddRealmPopupScreen.java @@ -1,5 +1,6 @@ package com.mojang.realmsclient.gui.screens; +import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.systems.RenderSystem; import java.util.Collection; import java.util.List; @@ -126,7 +127,8 @@ public class AddRealmPopupScreen extends RealmsScreen { public void renderBackground(GuiGraphics guiGraphics, int mouseX, int mouseY, float partialTick) { this.backgroundScreen.render(guiGraphics, -1, -1, partialTick); guiGraphics.flush(); - RenderSystem.clear(256); + RenderTarget renderTarget = this.minecraft.getMainRenderTarget(); + RenderSystem.getDevice().createCommandEncoder().clearDepthTexture(renderTarget.getDepthTexture(), 1.0); this.clearTooltipForNextRenderPass(); this.renderTransparentBackground(guiGraphics); guiGraphics.blitSprite(RenderType::guiTextured, BACKGROUND_SPRITE, this.left(), this.top(), 320, 172); diff --git a/com/mojang/realmsclient/gui/screens/RealmsBackupScreen.java b/com/mojang/realmsclient/gui/screens/RealmsBackupScreen.java index 76c1ad42..78bdb234 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsBackupScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsBackupScreen.java @@ -96,7 +96,7 @@ public class RealmsBackupScreen extends RealmsScreen { private void fetchRealmsBackups() { (new Thread("Realms-fetch-backups") { public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { List list = realmsClient.backupsFor(RealmsBackupScreen.this.serverData.id).backups; diff --git a/com/mojang/realmsclient/gui/screens/RealmsBrokenWorldScreen.java b/com/mojang/realmsclient/gui/screens/RealmsBrokenWorldScreen.java index b2e1adc6..685b80e7 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsBrokenWorldScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsBrokenWorldScreen.java @@ -164,7 +164,7 @@ public class RealmsBrokenWorldScreen extends RealmsScreen { private void fetchServerData(long serverId) { new Thread(() -> { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { this.serverData = realmsClient.getOwnRealm(serverId); @@ -179,7 +179,7 @@ public class RealmsBrokenWorldScreen extends RealmsScreen { public void doSwitchOrReset() { new Thread( () -> { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); if (this.serverData.state == State.CLOSED) { this.minecraft .execute(() -> this.minecraft.setScreen(new RealmsLongRunningMcoTaskScreen(this, new OpenServerTask(this.serverData, this, true, this.minecraft)))); @@ -198,7 +198,7 @@ public class RealmsBrokenWorldScreen extends RealmsScreen { } private void downloadWorld(int slotIndex) { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { WorldDownload worldDownload = realmsClient.requestDownloadInfo(this.serverData.id, slotIndex); diff --git a/com/mojang/realmsclient/gui/screens/RealmsConfigureWorldScreen.java b/com/mojang/realmsclient/gui/screens/RealmsConfigureWorldScreen.java index d6fbdefd..e2495370 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsConfigureWorldScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsConfigureWorldScreen.java @@ -250,7 +250,7 @@ public class RealmsConfigureWorldScreen extends RealmsScreen { public void fetchServerData(long serverId) { new Thread(() -> { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { RealmsServer realmsServer = realmsClient.getOwnRealm(serverId); @@ -400,7 +400,7 @@ public class RealmsConfigureWorldScreen extends RealmsScreen { RealmsWorldOptions realmsWorldOptions = (RealmsWorldOptions)this.serverData.slots.get(this.serverData.activeSlot); worldOptions.templateId = realmsWorldOptions.templateId; worldOptions.templateImage = realmsWorldOptions.templateImage; - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { realmsClient.updateSlot(this.serverData.id, this.serverData.activeSlot, worldOptions); @@ -419,7 +419,7 @@ public class RealmsConfigureWorldScreen extends RealmsScreen { public void saveSettings(String key, String value) { String string = StringUtil.isBlank(value) ? "" : value; - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { realmsClient.update(this.serverData.id, key, string); diff --git a/com/mojang/realmsclient/gui/screens/RealmsCreateRealmScreen.java b/com/mojang/realmsclient/gui/screens/RealmsCreateRealmScreen.java index 85a52ad8..78fecb6e 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsCreateRealmScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsCreateRealmScreen.java @@ -35,10 +35,10 @@ public class RealmsCreateRealmScreen extends RealmsScreen { private EditBox descriptionBox; private final Runnable createWorldRunnable; - public RealmsCreateRealmScreen(RealmsMainScreen lastScreen, RealmsServer server, boolean isSnapshot) { + public RealmsCreateRealmScreen(RealmsMainScreen lastScreen, RealmsServer server, boolean isSnapshor) { super(CREATE_REALM_TEXT); this.lastScreen = lastScreen; - this.createWorldRunnable = () -> this.createWorld(server, isSnapshot); + this.createWorldRunnable = () -> this.createWorld(server, isSnapshor); } @Override @@ -101,7 +101,7 @@ public class RealmsCreateRealmScreen extends RealmsScreen { } private static RealmsServer createSnapshotRealm(RealmsServer server) { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { return realmsClient.createSnapshotRealm(server.id); diff --git a/com/mojang/realmsclient/gui/screens/RealmsInviteScreen.java b/com/mojang/realmsclient/gui/screens/RealmsInviteScreen.java index a151686f..29ddbf30 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsInviteScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsInviteScreen.java @@ -80,7 +80,7 @@ public class RealmsInviteScreen extends RealmsScreen { this.showMessage(INVITING_PLAYER_TEXT); CompletableFuture.supplyAsync(() -> { try { - return RealmsClient.create().invite(l, string); + return RealmsClient.getOrCreate().invite(l, string); } catch (Exception var4) { LOGGER.error("Couldn't invite user"); return null; diff --git a/com/mojang/realmsclient/gui/screens/RealmsNotificationsScreen.java b/com/mojang/realmsclient/gui/screens/RealmsNotificationsScreen.java index 94c56d96..1511eb4a 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsNotificationsScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsNotificationsScreen.java @@ -1,7 +1,6 @@ package com.mojang.realmsclient.gui.screens; import com.mojang.realmsclient.RealmsAvailability; -import com.mojang.realmsclient.RealmsAvailability.Type; import com.mojang.realmsclient.dto.RealmsNotification; import com.mojang.realmsclient.gui.RealmsDataFetcher; import com.mojang.realmsclient.gui.task.DataFetcher.Subscription; @@ -23,7 +22,7 @@ public class RealmsNotificationsScreen extends RealmsScreen { private static final ResourceLocation NEWS_SPRITE = ResourceLocation.withDefaultNamespace("icon/news"); private static final ResourceLocation INVITE_SPRITE = ResourceLocation.withDefaultNamespace("icon/invite"); private static final ResourceLocation TRIAL_AVAILABLE_SPRITE = ResourceLocation.withDefaultNamespace("icon/trial_available"); - private final CompletableFuture validClient = RealmsAvailability.get().thenApply(result -> result.type() == Type.SUCCESS); + private final CompletableFuture validClient = RealmsAvailability.get().thenApply(result -> result.type() == RealmsAvailability.Type.SUCCESS); @Nullable private Subscription realmsDataSubscription; @Nullable diff --git a/com/mojang/realmsclient/gui/screens/RealmsPendingInvitesScreen.java b/com/mojang/realmsclient/gui/screens/RealmsPendingInvitesScreen.java index 9d91a16e..bb1ef1c5 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsPendingInvitesScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsPendingInvitesScreen.java @@ -41,7 +41,7 @@ public class RealmsPendingInvitesScreen extends RealmsScreen { private final Screen lastScreen; private final CompletableFuture> pendingInvites = CompletableFuture.supplyAsync(() -> { try { - return RealmsClient.create().pendingInvites().pendingInvites; + return RealmsClient.getOrCreate().pendingInvites().pendingInvites; } catch (RealmsServiceException var1) { LOGGER.error("Couldn't list invites", (Throwable)var1); return List.of(); @@ -90,7 +90,7 @@ public class RealmsPendingInvitesScreen extends RealmsScreen { String string = entry.pendingInvite.invitationId; CompletableFuture.supplyAsync(() -> { try { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); if (accept) { realmsClient.acceptInvitation(string); } else { diff --git a/com/mojang/realmsclient/gui/screens/RealmsPlayerScreen.java b/com/mojang/realmsclient/gui/screens/RealmsPlayerScreen.java index 6be08c36..c01f73ba 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsPlayerScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsPlayerScreen.java @@ -151,7 +151,7 @@ public class RealmsPlayerScreen extends RealmsScreen { } private void op(int index) { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); UUID uUID = ((PlayerInfo)RealmsPlayerScreen.this.serverData.players.get(index)).getUuid(); try { @@ -161,10 +161,11 @@ public class RealmsPlayerScreen extends RealmsScreen { } this.updateOpButtons(); + this.setFocused(this.removeOpButton); } private void deop(int index) { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); UUID uUID = ((PlayerInfo)RealmsPlayerScreen.this.serverData.players.get(index)).getUuid(); try { @@ -174,6 +175,7 @@ public class RealmsPlayerScreen extends RealmsScreen { } this.updateOpButtons(); + this.setFocused(this.makeOpButton); } private void uninvite(int index) { @@ -181,7 +183,7 @@ public class RealmsPlayerScreen extends RealmsScreen { PlayerInfo playerInfo = (PlayerInfo)RealmsPlayerScreen.this.serverData.players.get(index); RealmsConfirmScreen realmsConfirmScreen = new RealmsConfirmScreen(bl -> { if (bl) { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { realmsClient.uninvite(RealmsPlayerScreen.this.serverData.id, playerInfo.getUuid()); diff --git a/com/mojang/realmsclient/gui/screens/RealmsResetWorldScreen.java b/com/mojang/realmsclient/gui/screens/RealmsResetWorldScreen.java index 0f996ef7..c1b7447d 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsResetWorldScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsResetWorldScreen.java @@ -22,6 +22,7 @@ import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.gui.components.AbstractWidget; import net.minecraft.client.gui.components.Button; import net.minecraft.client.gui.components.StringWidget; +import net.minecraft.client.gui.components.Button.OnPress; import net.minecraft.client.gui.layouts.GridLayout; import net.minecraft.client.gui.layouts.HeaderAndFooterLayout; import net.minecraft.client.gui.layouts.LayoutSettings; @@ -144,7 +145,7 @@ public class RealmsResetWorldScreen extends RealmsScreen { linearLayout.addChild(new StringWidget(this.subtitle, this.font).setColor(this.subtitleColor), LayoutSettings::alignHorizontallyCenter); (new Thread("Realms-reset-world-fetcher") { public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { WorldTemplatePaginatedList worldTemplatePaginatedList = realmsClient.fetchWorldTemplates(1, 10, WorldType.NORMAL); @@ -271,7 +272,7 @@ public class RealmsResetWorldScreen extends RealmsScreen { private static final int IMAGE_SIZE = 56; private final ResourceLocation image; - FrameButton(final Font font, final Component message, final ResourceLocation image, final Button.OnPress onPress) { + FrameButton(final Font font, final Component message, final ResourceLocation image, final OnPress onPress) { super(0, 0, 60, 60 + 9, message, onPress, DEFAULT_NARRATION); this.image = image; } diff --git a/com/mojang/realmsclient/gui/screens/RealmsSelectFileToUploadScreen.java b/com/mojang/realmsclient/gui/screens/RealmsSelectFileToUploadScreen.java index e9b83913..25e917ad 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsSelectFileToUploadScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsSelectFileToUploadScreen.java @@ -18,8 +18,8 @@ import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.realms.RealmsLabel; import net.minecraft.realms.RealmsScreen; +import net.minecraft.world.level.storage.LevelStorageSource; import net.minecraft.world.level.storage.LevelSummary; -import net.minecraft.world.level.storage.LevelStorageSource.LevelCandidates; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -29,8 +29,6 @@ public class RealmsSelectFileToUploadScreen extends RealmsScreen { public static final Component TITLE = Component.translatable("mco.upload.select.world.title"); private static final Component UNABLE_TO_LOAD_WORLD = Component.translatable("selectWorld.unable_to_load"); static final Component WORLD_TEXT = Component.translatable("selectWorld.world"); - private static final Component HARDCORE_TEXT = Component.translatable("mco.upload.hardcore").withColor(-65536); - private static final Component COMMANDS_TEXT = Component.translatable("selectWorld.commands"); private static final DateFormat DATE_FORMAT = new SimpleDateFormat(); @Nullable private final RealmCreationTask realmCreationTask; @@ -51,7 +49,7 @@ public class RealmsSelectFileToUploadScreen extends RealmsScreen { } private void loadLevelList() { - LevelCandidates levelCandidates = this.minecraft.getLevelSource().findLevelCandidates(); + LevelStorageSource.LevelCandidates levelCandidates = this.minecraft.getLevelSource().findLevelCandidates(); this.levelList = (List)((List)this.minecraft.getLevelSource().loadLevelSummaries(levelCandidates).join()) .stream() .filter(LevelSummary::canUpload) @@ -93,7 +91,7 @@ public class RealmsSelectFileToUploadScreen extends RealmsScreen { } private void upload() { - if (this.selectedWorld != -1 && !((LevelSummary)this.levelList.get(this.selectedWorld)).isHardcore()) { + if (this.selectedWorld != -1) { LevelSummary levelSummary = (LevelSummary)this.levelList.get(this.selectedWorld); this.minecraft.setScreen(new RealmsUploadScreen(this.realmCreationTask, this.realmId, this.slotId, this.lastScreen, levelSummary)); } @@ -192,8 +190,7 @@ public class RealmsSelectFileToUploadScreen extends RealmsScreen { super.setSelected(entry); RealmsSelectFileToUploadScreen.this.selectedWorld = this.children().indexOf(entry); RealmsSelectFileToUploadScreen.this.uploadButton.active = RealmsSelectFileToUploadScreen.this.selectedWorld >= 0 - && RealmsSelectFileToUploadScreen.this.selectedWorld < this.getItemCount() - && !((LevelSummary)RealmsSelectFileToUploadScreen.this.levelList.get(RealmsSelectFileToUploadScreen.this.selectedWorld)).isHardcore(); + && RealmsSelectFileToUploadScreen.this.selectedWorld < this.getItemCount(); } @Override diff --git a/com/mojang/realmsclient/gui/screens/RealmsSelectWorldTemplateScreen.java b/com/mojang/realmsclient/gui/screens/RealmsSelectWorldTemplateScreen.java index ac4b33e2..70b46687 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsSelectWorldTemplateScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsSelectWorldTemplateScreen.java @@ -156,7 +156,7 @@ public class RealmsSelectWorldTemplateScreen extends RealmsScreen { (new Thread("realms-template-fetcher") { public void run() { WorldTemplatePaginatedList worldTemplatePaginatedList = output; - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); while (worldTemplatePaginatedList != null) { Either either = RealmsSelectWorldTemplateScreen.this.fetchTemplates(worldTemplatePaginatedList, realmsClient); diff --git a/com/mojang/realmsclient/gui/screens/RealmsSlotOptionsScreen.java b/com/mojang/realmsclient/gui/screens/RealmsSlotOptionsScreen.java index bd2da02b..d8eb8128 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsSlotOptionsScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsSlotOptionsScreen.java @@ -12,6 +12,7 @@ import net.minecraft.client.gui.components.AbstractSliderButton; import net.minecraft.client.gui.components.Button; import net.minecraft.client.gui.components.CycleButton; import net.minecraft.client.gui.components.EditBox; +import net.minecraft.client.gui.components.CycleButton.OnValueChange; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.realms.RealmsLabel; @@ -108,7 +109,6 @@ public class RealmsSlotOptionsScreen extends RealmsScreen { this.nameEdit = this.addWidget( new EditBox(this.minecraft.font, this.column1X, row(1), this.columnWidth, 20, null, Component.translatable("mco.configure.world.edit.slot.name")) ); - this.nameEdit.setMaxLength(10); this.nameEdit.setValue(this.worldName); this.nameEdit.setResponder(this::setWorldName); CycleButton cycleButton = this.addRenderableWidget( @@ -185,7 +185,7 @@ public class RealmsSlotOptionsScreen extends RealmsScreen { this.addRenderableWidget(Button.builder(CommonComponents.GUI_CANCEL, button -> this.onClose()).bounds(i, row(13), this.columnWidth, 20).build()); } - private CycleButton.OnValueChange confirmDangerousOption(Component question, Consumer onPress) { + private OnValueChange confirmDangerousOption(Component question, Consumer onPress) { return (cycleButton, boolean_) -> { if (boolean_) { onPress.accept(true); diff --git a/com/mojang/realmsclient/gui/screens/RealmsSubscriptionInfoScreen.java b/com/mojang/realmsclient/gui/screens/RealmsSubscriptionInfoScreen.java index 908a4810..ce164769 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsSubscriptionInfoScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsSubscriptionInfoScreen.java @@ -95,7 +95,7 @@ public class RealmsSubscriptionInfoScreen extends RealmsScreen { (new Thread("Realms-delete-realm") { public void run() { try { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); realmsClient.deleteRealm(RealmsSubscriptionInfoScreen.this.serverData.id); } catch (RealmsServiceException var2) { RealmsSubscriptionInfoScreen.LOGGER.error("Couldn't delete world", (Throwable)var2); @@ -110,7 +110,7 @@ public class RealmsSubscriptionInfoScreen extends RealmsScreen { } private void getSubscription(long serverId) { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { Subscription subscription = realmsClient.subscriptionFor(serverId); diff --git a/com/mojang/realmsclient/gui/screens/RealmsTermsScreen.java b/com/mojang/realmsclient/gui/screens/RealmsTermsScreen.java index 3b5625e6..1f47b4c4 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsTermsScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsTermsScreen.java @@ -64,7 +64,7 @@ public class RealmsTermsScreen extends RealmsScreen { } private void agreedToTos() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { realmsClient.agreeToTos(); diff --git a/com/mojang/realmsclient/gui/screens/RealmsUploadScreen.java b/com/mojang/realmsclient/gui/screens/RealmsUploadScreen.java index ab9f8179..1ab7c905 100644 --- a/com/mojang/realmsclient/gui/screens/RealmsUploadScreen.java +++ b/com/mojang/realmsclient/gui/screens/RealmsUploadScreen.java @@ -225,7 +225,7 @@ public class RealmsUploadScreen extends RealmsScreen implements RealmsWorldUploa private void upload() { Path path = this.minecraft.gameDirectory.toPath().resolve("saves").resolve(this.selectedLevel.getLevelId()); RealmsWorldOptions realmsWorldOptions = RealmsWorldOptions.createFromSettings( - this.selectedLevel.getSettings(), this.selectedLevel.levelVersion().minecraftVersionName() + this.selectedLevel.getSettings(), true, this.selectedLevel.levelVersion().minecraftVersionName() ); RealmsWorldUpload realmsWorldUpload = new RealmsWorldUpload(path, realmsWorldOptions, this.minecraft.getUser(), this.realmId, this.slotId, this); if (!this.currentUpload.compareAndSet(null, realmsWorldUpload)) { diff --git a/com/mojang/realmsclient/util/RealmsTextureManager.java b/com/mojang/realmsclient/util/RealmsTextureManager.java index 94cd6a2a..dbb19779 100644 --- a/com/mojang/realmsclient/util/RealmsTextureManager.java +++ b/com/mojang/realmsclient/util/RealmsTextureManager.java @@ -39,7 +39,7 @@ public class RealmsTextureManager { return resourceLocation; } else { ResourceLocation resourceLocation = ResourceLocation.fromNamespaceAndPath("realms", "dynamic/" + key); - Minecraft.getInstance().getTextureManager().register(resourceLocation, new DynamicTexture(nativeImage)); + Minecraft.getInstance().getTextureManager().register(resourceLocation, new DynamicTexture(resourceLocation::toString, nativeImage)); TEXTURES.put(key, new RealmsTextureManager.RealmsTexture(image, resourceLocation)); return resourceLocation; } diff --git a/com/mojang/realmsclient/util/task/CloseServerTask.java b/com/mojang/realmsclient/util/task/CloseServerTask.java index 164c1b63..14264519 100644 --- a/com/mojang/realmsclient/util/task/CloseServerTask.java +++ b/com/mojang/realmsclient/util/task/CloseServerTask.java @@ -3,6 +3,7 @@ package com.mojang.realmsclient.util.task; import com.mojang.logging.LogUtils; import com.mojang.realmsclient.client.RealmsClient; import com.mojang.realmsclient.dto.RealmsServer; +import com.mojang.realmsclient.dto.RealmsServer.State; import com.mojang.realmsclient.exception.RetryCallException; import com.mojang.realmsclient.gui.screens.RealmsConfigureWorldScreen; import net.fabricmc.api.EnvType; @@ -23,7 +24,7 @@ public class CloseServerTask extends LongRunningTask { } public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); for (int i = 0; i < 25; i++) { if (this.aborted()) { @@ -34,7 +35,7 @@ public class CloseServerTask extends LongRunningTask { boolean bl = realmsClient.close(this.serverData.id); if (bl) { this.configureScreen.stateChanged(); - this.serverData.state = RealmsServer.State.CLOSED; + this.serverData.state = State.CLOSED; setScreen(this.configureScreen); break; } diff --git a/com/mojang/realmsclient/util/task/DownloadTask.java b/com/mojang/realmsclient/util/task/DownloadTask.java index 4ed2fb5f..ba4406f4 100644 --- a/com/mojang/realmsclient/util/task/DownloadTask.java +++ b/com/mojang/realmsclient/util/task/DownloadTask.java @@ -30,7 +30,7 @@ public class DownloadTask extends LongRunningTask { } public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); int i = 0; while (i < 25) { diff --git a/com/mojang/realmsclient/util/task/GetServerDetailsTask.java b/com/mojang/realmsclient/util/task/GetServerDetailsTask.java index a0c179f6..fa82fc16 100644 --- a/com/mojang/realmsclient/util/task/GetServerDetailsTask.java +++ b/com/mojang/realmsclient/util/task/GetServerDetailsTask.java @@ -104,7 +104,7 @@ public class GetServerDetailsTask extends LongRunningTask { } private RealmsServerAddress fetchServerAddress() throws RealmsServiceException, TimeoutException, CancellationException { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); for (int i = 0; i < 40; i++) { if (this.aborted()) { diff --git a/com/mojang/realmsclient/util/task/OpenServerTask.java b/com/mojang/realmsclient/util/task/OpenServerTask.java index b060f304..37a489c8 100644 --- a/com/mojang/realmsclient/util/task/OpenServerTask.java +++ b/com/mojang/realmsclient/util/task/OpenServerTask.java @@ -4,6 +4,7 @@ import com.mojang.logging.LogUtils; import com.mojang.realmsclient.RealmsMainScreen; import com.mojang.realmsclient.client.RealmsClient; import com.mojang.realmsclient.dto.RealmsServer; +import com.mojang.realmsclient.dto.RealmsServer.State; import com.mojang.realmsclient.exception.RetryCallException; import com.mojang.realmsclient.gui.screens.RealmsConfigureWorldScreen; import net.fabricmc.api.EnvType; @@ -30,7 +31,7 @@ public class OpenServerTask extends LongRunningTask { } public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); for (int i = 0; i < 25; i++) { if (this.aborted()) { @@ -45,7 +46,7 @@ public class OpenServerTask extends LongRunningTask { ((RealmsConfigureWorldScreen)this.returnScreen).stateChanged(); } - this.serverData.state = RealmsServer.State.OPEN; + this.serverData.state = State.OPEN; if (this.join) { RealmsMainScreen.play(this.serverData, this.returnScreen); } else { diff --git a/com/mojang/realmsclient/util/task/RealmCreationTask.java b/com/mojang/realmsclient/util/task/RealmCreationTask.java index 27470ffe..47250a72 100644 --- a/com/mojang/realmsclient/util/task/RealmCreationTask.java +++ b/com/mojang/realmsclient/util/task/RealmCreationTask.java @@ -23,7 +23,7 @@ public class RealmCreationTask extends LongRunningTask { } public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); try { realmsClient.initializeRealm(this.realmId, this.name, this.motd); diff --git a/com/mojang/realmsclient/util/task/ResettingWorldTask.java b/com/mojang/realmsclient/util/task/ResettingWorldTask.java index 27125dd9..c849bd97 100644 --- a/com/mojang/realmsclient/util/task/ResettingWorldTask.java +++ b/com/mojang/realmsclient/util/task/ResettingWorldTask.java @@ -25,7 +25,7 @@ public abstract class ResettingWorldTask extends LongRunningTask { protected abstract void sendResetRequest(RealmsClient client, long serverId) throws RealmsServiceException; public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); int i = 0; while (i < 25) { diff --git a/com/mojang/realmsclient/util/task/RestoreTask.java b/com/mojang/realmsclient/util/task/RestoreTask.java index a25ca9a7..9863d94b 100644 --- a/com/mojang/realmsclient/util/task/RestoreTask.java +++ b/com/mojang/realmsclient/util/task/RestoreTask.java @@ -27,7 +27,7 @@ public class RestoreTask extends LongRunningTask { } public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); int i = 0; while (i < 25) { diff --git a/com/mojang/realmsclient/util/task/SwitchMinigameTask.java b/com/mojang/realmsclient/util/task/SwitchMinigameTask.java index f4ccd121..0fa6cc89 100644 --- a/com/mojang/realmsclient/util/task/SwitchMinigameTask.java +++ b/com/mojang/realmsclient/util/task/SwitchMinigameTask.java @@ -25,7 +25,7 @@ public class SwitchMinigameTask extends LongRunningTask { } public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); for (int i = 0; i < 25; i++) { try { diff --git a/com/mojang/realmsclient/util/task/SwitchSlotTask.java b/com/mojang/realmsclient/util/task/SwitchSlotTask.java index 9ac03d4c..e8cd7859 100644 --- a/com/mojang/realmsclient/util/task/SwitchSlotTask.java +++ b/com/mojang/realmsclient/util/task/SwitchSlotTask.java @@ -23,7 +23,7 @@ public class SwitchSlotTask extends LongRunningTask { } public void run() { - RealmsClient realmsClient = RealmsClient.create(); + RealmsClient realmsClient = RealmsClient.getOrCreate(); for (int i = 0; i < 25; i++) { try { diff --git a/data/minecraft/advancement/adventure/adventuring_time.json b/data/minecraft/advancement/adventure/adventuring_time.json index 5e301dc3..46fcc672 100644 --- a/data/minecraft/advancement/adventure/adventuring_time.json +++ b/data/minecraft/advancement/adventure/adventuring_time.json @@ -970,6 +970,9 @@ [ "minecraft:dark_forest" ], + [ + "minecraft:pale_garden" + ], [ "minecraft:savanna_plateau" ], @@ -1027,9 +1030,6 @@ [ "minecraft:cherry_grove" ], - [ - "minecraft:pale_garden" - ], [ "minecraft:frozen_peaks" ], diff --git a/data/minecraft/advancement/adventure/hero_of_the_village.json b/data/minecraft/advancement/adventure/hero_of_the_village.json index 1380cf76..7c7f7e09 100644 --- a/data/minecraft/advancement/adventure/hero_of_the_village.json +++ b/data/minecraft/advancement/adventure/hero_of_the_village.json @@ -47,9 +47,15 @@ "pattern": "minecraft:border" } ], - "minecraft:hide_additional_tooltip": {}, - "minecraft:item_name": "{\"translate\":\"block.minecraft.ominous_banner\"}", - "minecraft:rarity": "uncommon" + "minecraft:item_name": { + "translate": "block.minecraft.ominous_banner" + }, + "minecraft:rarity": "uncommon", + "minecraft:tooltip_display": { + "hidden_components": [ + "minecraft:banner_patterns" + ] + } }, "count": 1, "id": "minecraft:white_banner" diff --git a/data/minecraft/advancement/adventure/root.json b/data/minecraft/advancement/adventure/root.json index a6b28551..2031f8d7 100644 --- a/data/minecraft/advancement/adventure/root.json +++ b/data/minecraft/advancement/adventure/root.json @@ -9,7 +9,7 @@ }, "display": { "announce_to_chat": false, - "background": "minecraft:textures/gui/advancements/backgrounds/adventure.png", + "background": "minecraft:gui/advancements/backgrounds/adventure", "description": { "translate": "advancements.adventure.root.description" }, diff --git a/data/minecraft/advancement/nether/use_lodestone.json b/data/minecraft/advancement/adventure/use_lodestone.json similarity index 80% rename from data/minecraft/advancement/nether/use_lodestone.json rename to data/minecraft/advancement/adventure/use_lodestone.json index dfa084db..43c871f0 100644 --- a/data/minecraft/advancement/nether/use_lodestone.json +++ b/data/minecraft/advancement/adventure/use_lodestone.json @@ -1,5 +1,5 @@ { - "parent": "minecraft:nether/obtain_ancient_debris", + "parent": "minecraft:adventure/root", "criteria": { "use_lodestone": { "conditions": { @@ -25,14 +25,14 @@ }, "display": { "description": { - "translate": "advancements.nether.use_lodestone.description" + "translate": "advancements.adventure.use_lodestone.description" }, "icon": { "count": 1, "id": "minecraft:lodestone" }, "title": { - "translate": "advancements.nether.use_lodestone.title" + "translate": "advancements.adventure.use_lodestone.title" } }, "requirements": [ diff --git a/data/minecraft/advancement/adventure/voluntary_exile.json b/data/minecraft/advancement/adventure/voluntary_exile.json index 20b1b0a1..ab42e819 100644 --- a/data/minecraft/advancement/adventure/voluntary_exile.json +++ b/data/minecraft/advancement/adventure/voluntary_exile.json @@ -46,7 +46,9 @@ "pattern": "minecraft:border" } ], - "minecraft:item_name": "{\"translate\":\"block.minecraft.ominous_banner\"}" + "minecraft:item_name": { + "translate": "block.minecraft.ominous_banner" + } }, "items": "minecraft:white_banner" } @@ -99,9 +101,15 @@ "pattern": "minecraft:border" } ], - "minecraft:hide_additional_tooltip": {}, - "minecraft:item_name": "{\"translate\":\"block.minecraft.ominous_banner\"}", - "minecraft:rarity": "uncommon" + "minecraft:item_name": { + "translate": "block.minecraft.ominous_banner" + }, + "minecraft:rarity": "uncommon", + "minecraft:tooltip_display": { + "hidden_components": [ + "minecraft:banner_patterns" + ] + } }, "count": 1, "id": "minecraft:white_banner" diff --git a/data/minecraft/advancement/end/root.json b/data/minecraft/advancement/end/root.json index 9d788a5d..809e7c3f 100644 --- a/data/minecraft/advancement/end/root.json +++ b/data/minecraft/advancement/end/root.json @@ -9,7 +9,7 @@ }, "display": { "announce_to_chat": false, - "background": "minecraft:textures/gui/advancements/backgrounds/end.png", + "background": "minecraft:gui/advancements/backgrounds/end", "description": { "translate": "advancements.end.root.description" }, diff --git a/data/minecraft/advancement/husbandry/complete_catalogue.json b/data/minecraft/advancement/husbandry/complete_catalogue.json index 31749d55..94767cc8 100644 --- a/data/minecraft/advancement/husbandry/complete_catalogue.json +++ b/data/minecraft/advancement/husbandry/complete_catalogue.json @@ -8,9 +8,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:all_black" + "components": { + "minecraft:cat/variant": "minecraft:all_black" } } } @@ -25,9 +24,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:black" + "components": { + "minecraft:cat/variant": "minecraft:black" } } } @@ -42,9 +40,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:british_shorthair" + "components": { + "minecraft:cat/variant": "minecraft:british_shorthair" } } } @@ -59,9 +56,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:calico" + "components": { + "minecraft:cat/variant": "minecraft:calico" } } } @@ -76,9 +72,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:jellie" + "components": { + "minecraft:cat/variant": "minecraft:jellie" } } } @@ -93,9 +88,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:persian" + "components": { + "minecraft:cat/variant": "minecraft:persian" } } } @@ -110,9 +104,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:ragdoll" + "components": { + "minecraft:cat/variant": "minecraft:ragdoll" } } } @@ -127,9 +120,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:red" + "components": { + "minecraft:cat/variant": "minecraft:red" } } } @@ -144,9 +136,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:siamese" + "components": { + "minecraft:cat/variant": "minecraft:siamese" } } } @@ -161,9 +152,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:tabby" + "components": { + "minecraft:cat/variant": "minecraft:tabby" } } } @@ -178,9 +168,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:cat", - "variant": "minecraft:white" + "components": { + "minecraft:cat/variant": "minecraft:white" } } } diff --git a/data/minecraft/advancement/husbandry/leash_all_frog_variants.json b/data/minecraft/advancement/husbandry/leash_all_frog_variants.json index 52a2ded0..ad618421 100644 --- a/data/minecraft/advancement/husbandry/leash_all_frog_variants.json +++ b/data/minecraft/advancement/husbandry/leash_all_frog_variants.json @@ -9,9 +9,8 @@ "entity": "this", "predicate": { "type": "minecraft:frog", - "type_specific": { - "type": "minecraft:frog", - "variant": "minecraft:cold" + "components": { + "minecraft:frog/variant": "minecraft:cold" } } } @@ -30,9 +29,8 @@ "entity": "this", "predicate": { "type": "minecraft:frog", - "type_specific": { - "type": "minecraft:frog", - "variant": "minecraft:temperate" + "components": { + "minecraft:frog/variant": "minecraft:temperate" } } } @@ -51,9 +49,8 @@ "entity": "this", "predicate": { "type": "minecraft:frog", - "type_specific": { - "type": "minecraft:frog", - "variant": "minecraft:warm" + "components": { + "minecraft:frog/variant": "minecraft:warm" } } } @@ -78,14 +75,14 @@ } }, "requirements": [ + [ + "minecraft:cold" + ], [ "minecraft:temperate" ], [ "minecraft:warm" - ], - [ - "minecraft:cold" ] ], "sends_telemetry_event": true diff --git a/data/minecraft/advancement/husbandry/root.json b/data/minecraft/advancement/husbandry/root.json index 4061aa9b..5dc3be4d 100644 --- a/data/minecraft/advancement/husbandry/root.json +++ b/data/minecraft/advancement/husbandry/root.json @@ -6,7 +6,7 @@ }, "display": { "announce_to_chat": false, - "background": "minecraft:textures/gui/advancements/backgrounds/husbandry.png", + "background": "minecraft:gui/advancements/backgrounds/husbandry", "description": { "translate": "advancements.husbandry.root.description" }, diff --git a/data/minecraft/advancement/husbandry/whole_pack.json b/data/minecraft/advancement/husbandry/whole_pack.json index 26a20d57..c0a5a589 100644 --- a/data/minecraft/advancement/husbandry/whole_pack.json +++ b/data/minecraft/advancement/husbandry/whole_pack.json @@ -8,9 +8,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:ashen" + "components": { + "minecraft:wolf/variant": "minecraft:ashen" } } } @@ -25,9 +24,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:black" + "components": { + "minecraft:wolf/variant": "minecraft:black" } } } @@ -42,9 +40,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:chestnut" + "components": { + "minecraft:wolf/variant": "minecraft:chestnut" } } } @@ -59,9 +56,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:pale" + "components": { + "minecraft:wolf/variant": "minecraft:pale" } } } @@ -76,9 +72,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:rusty" + "components": { + "minecraft:wolf/variant": "minecraft:rusty" } } } @@ -93,9 +88,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:snowy" + "components": { + "minecraft:wolf/variant": "minecraft:snowy" } } } @@ -110,9 +104,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:spotted" + "components": { + "minecraft:wolf/variant": "minecraft:spotted" } } } @@ -127,9 +120,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:striped" + "components": { + "minecraft:wolf/variant": "minecraft:striped" } } } @@ -144,9 +136,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:wolf", - "variant": "minecraft:woods" + "components": { + "minecraft:wolf/variant": "minecraft:woods" } } } diff --git a/data/minecraft/advancement/nether/root.json b/data/minecraft/advancement/nether/root.json index 6ef424ea..5b6074a2 100644 --- a/data/minecraft/advancement/nether/root.json +++ b/data/minecraft/advancement/nether/root.json @@ -9,7 +9,7 @@ }, "display": { "announce_to_chat": false, - "background": "minecraft:textures/gui/advancements/backgrounds/nether.png", + "background": "minecraft:gui/advancements/backgrounds/nether", "description": { "translate": "advancements.nether.root.description" }, diff --git a/data/minecraft/advancement/recipes/decorations/lodestone.json b/data/minecraft/advancement/recipes/decorations/lodestone.json index 3ccf8e6e..de00977e 100644 --- a/data/minecraft/advancement/recipes/decorations/lodestone.json +++ b/data/minecraft/advancement/recipes/decorations/lodestone.json @@ -1,11 +1,21 @@ { "parent": "minecraft:recipes/root", "criteria": { - "has_netherite_ingot": { + "has_iron_ingot": { "conditions": { "items": [ { - "items": "minecraft:netherite_ingot" + "items": "minecraft:iron_ingot" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_lodestone": { + "conditions": { + "items": [ + { + "items": "minecraft:lodestone" } ] }, @@ -21,7 +31,8 @@ "requirements": [ [ "has_the_recipe", - "has_netherite_ingot" + "has_iron_ingot", + "has_lodestone" ] ], "rewards": { diff --git a/data/minecraft/advancement/recipes/food/cake.json b/data/minecraft/advancement/recipes/food/cake.json index 1eaf9249..beb3219d 100644 --- a/data/minecraft/advancement/recipes/food/cake.json +++ b/data/minecraft/advancement/recipes/food/cake.json @@ -5,7 +5,7 @@ "conditions": { "items": [ { - "items": "minecraft:egg" + "items": "#minecraft:eggs" } ] }, diff --git a/data/minecraft/advancement/recipes/misc/leaf_litter.json b/data/minecraft/advancement/recipes/misc/leaf_litter.json new file mode 100644 index 00000000..c6b83cb4 --- /dev/null +++ b/data/minecraft/advancement/recipes/misc/leaf_litter.json @@ -0,0 +1,32 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_leaves": { + "conditions": { + "items": [ + { + "items": "#minecraft:leaves" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "minecraft:leaf_litter" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_the_recipe", + "has_leaves" + ] + ], + "rewards": { + "recipes": [ + "minecraft:leaf_litter" + ] + } +} \ No newline at end of file diff --git a/data/minecraft/advancement/recipes/misc/pink_dye_from_cactus_flower.json b/data/minecraft/advancement/recipes/misc/pink_dye_from_cactus_flower.json new file mode 100644 index 00000000..37b918ae --- /dev/null +++ b/data/minecraft/advancement/recipes/misc/pink_dye_from_cactus_flower.json @@ -0,0 +1,32 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_cactus_flower": { + "conditions": { + "items": [ + { + "items": "minecraft:cactus_flower" + } + ] + }, + "trigger": "minecraft:inventory_changed" + }, + "has_the_recipe": { + "conditions": { + "recipe": "minecraft:pink_dye_from_cactus_flower" + }, + "trigger": "minecraft:recipe_unlocked" + } + }, + "requirements": [ + [ + "has_the_recipe", + "has_cactus_flower" + ] + ], + "rewards": { + "recipes": [ + "minecraft:pink_dye_from_cactus_flower" + ] + } +} \ No newline at end of file diff --git a/data/minecraft/advancement/recipes/misc/yellow_dye_from_wildflowers.json b/data/minecraft/advancement/recipes/misc/yellow_dye_from_wildflowers.json new file mode 100644 index 00000000..872f6c51 --- /dev/null +++ b/data/minecraft/advancement/recipes/misc/yellow_dye_from_wildflowers.json @@ -0,0 +1,32 @@ +{ + "parent": "minecraft:recipes/root", + "criteria": { + "has_the_recipe": { + "conditions": { + "recipe": "minecraft:yellow_dye_from_wildflowers" + }, + "trigger": "minecraft:recipe_unlocked" + }, + "has_wildflowers": { + "conditions": { + "items": [ + { + "items": "minecraft:wildflowers" + } + ] + }, + "trigger": "minecraft:inventory_changed" + } + }, + "requirements": [ + [ + "has_the_recipe", + "has_wildflowers" + ] + ], + "rewards": { + "recipes": [ + "minecraft:yellow_dye_from_wildflowers" + ] + } +} \ No newline at end of file diff --git a/data/minecraft/advancement/story/root.json b/data/minecraft/advancement/story/root.json index 0526a2bf..1be297f6 100644 --- a/data/minecraft/advancement/story/root.json +++ b/data/minecraft/advancement/story/root.json @@ -13,7 +13,7 @@ }, "display": { "announce_to_chat": false, - "background": "minecraft:textures/gui/advancements/backgrounds/stone.png", + "background": "minecraft:gui/advancements/backgrounds/stone", "description": { "translate": "advancements.story.root.description" }, diff --git a/data/minecraft/cat_variant/all_black.json b/data/minecraft/cat_variant/all_black.json new file mode 100644 index 00000000..c4446236 --- /dev/null +++ b/data/minecraft/cat_variant/all_black.json @@ -0,0 +1,21 @@ +{ + "asset_id": "minecraft:entity/cat/all_black", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:structure", + "structures": "#minecraft:cats_spawn_as_black" + }, + "priority": 1 + }, + { + "condition": { + "type": "minecraft:moon_brightness", + "range": { + "min": 0.9 + } + }, + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/black.json b/data/minecraft/cat_variant/black.json new file mode 100644 index 00000000..32f6664a --- /dev/null +++ b/data/minecraft/cat_variant/black.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/black", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/british_shorthair.json b/data/minecraft/cat_variant/british_shorthair.json new file mode 100644 index 00000000..a65e0be1 --- /dev/null +++ b/data/minecraft/cat_variant/british_shorthair.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/british_shorthair", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/calico.json b/data/minecraft/cat_variant/calico.json new file mode 100644 index 00000000..1e8eca7e --- /dev/null +++ b/data/minecraft/cat_variant/calico.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/calico", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/jellie.json b/data/minecraft/cat_variant/jellie.json new file mode 100644 index 00000000..86d9e4a1 --- /dev/null +++ b/data/minecraft/cat_variant/jellie.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/jellie", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/persian.json b/data/minecraft/cat_variant/persian.json new file mode 100644 index 00000000..fa4b3c5b --- /dev/null +++ b/data/minecraft/cat_variant/persian.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/persian", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/ragdoll.json b/data/minecraft/cat_variant/ragdoll.json new file mode 100644 index 00000000..2b98489a --- /dev/null +++ b/data/minecraft/cat_variant/ragdoll.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/ragdoll", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/red.json b/data/minecraft/cat_variant/red.json new file mode 100644 index 00000000..cf2ec42b --- /dev/null +++ b/data/minecraft/cat_variant/red.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/red", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/siamese.json b/data/minecraft/cat_variant/siamese.json new file mode 100644 index 00000000..1449d8b3 --- /dev/null +++ b/data/minecraft/cat_variant/siamese.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/siamese", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/tabby.json b/data/minecraft/cat_variant/tabby.json new file mode 100644 index 00000000..640eeb72 --- /dev/null +++ b/data/minecraft/cat_variant/tabby.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/tabby", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cat_variant/white.json b/data/minecraft/cat_variant/white.json new file mode 100644 index 00000000..ef736feb --- /dev/null +++ b/data/minecraft/cat_variant/white.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cat/white", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/chicken_variant/cold.json b/data/minecraft/chicken_variant/cold.json new file mode 100644 index 00000000..6f259ff7 --- /dev/null +++ b/data/minecraft/chicken_variant/cold.json @@ -0,0 +1,13 @@ +{ + "asset_id": "minecraft:entity/chicken/cold_chicken", + "model": "cold", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:spawns_cold_variant_farm_animals" + }, + "priority": 1 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/chicken_variant/temperate.json b/data/minecraft/chicken_variant/temperate.json new file mode 100644 index 00000000..703a10cf --- /dev/null +++ b/data/minecraft/chicken_variant/temperate.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/chicken/temperate_chicken", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/chicken_variant/warm.json b/data/minecraft/chicken_variant/warm.json new file mode 100644 index 00000000..49fc1c7f --- /dev/null +++ b/data/minecraft/chicken_variant/warm.json @@ -0,0 +1,12 @@ +{ + "asset_id": "minecraft:entity/chicken/warm_chicken", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:spawns_warm_variant_farm_animals" + }, + "priority": 1 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cow_variant/cold.json b/data/minecraft/cow_variant/cold.json new file mode 100644 index 00000000..e5cfffd7 --- /dev/null +++ b/data/minecraft/cow_variant/cold.json @@ -0,0 +1,13 @@ +{ + "asset_id": "minecraft:entity/cow/cold_cow", + "model": "cold", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:spawns_cold_variant_farm_animals" + }, + "priority": 1 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cow_variant/temperate.json b/data/minecraft/cow_variant/temperate.json new file mode 100644 index 00000000..fea2f406 --- /dev/null +++ b/data/minecraft/cow_variant/temperate.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/cow/temperate_cow", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/cow_variant/warm.json b/data/minecraft/cow_variant/warm.json new file mode 100644 index 00000000..67e49298 --- /dev/null +++ b/data/minecraft/cow_variant/warm.json @@ -0,0 +1,13 @@ +{ + "asset_id": "minecraft:entity/cow/warm_cow", + "model": "warm", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:spawns_warm_variant_farm_animals" + }, + "priority": 1 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/datapacks/minecart_improvements/pack.mcmeta b/data/minecraft/datapacks/minecart_improvements/pack.mcmeta index 22d5b922..4252c522 100644 --- a/data/minecraft/datapacks/minecart_improvements/pack.mcmeta +++ b/data/minecraft/datapacks/minecart_improvements/pack.mcmeta @@ -8,6 +8,6 @@ "description": { "translate": "dataPack.minecart_improvements.description" }, - "pack_format": 61 + "pack_format": 71 } } \ No newline at end of file diff --git a/data/minecraft/datapacks/redstone_experiments/pack.mcmeta b/data/minecraft/datapacks/redstone_experiments/pack.mcmeta index 4a3248be..7a9a5460 100644 --- a/data/minecraft/datapacks/redstone_experiments/pack.mcmeta +++ b/data/minecraft/datapacks/redstone_experiments/pack.mcmeta @@ -8,6 +8,6 @@ "description": { "translate": "dataPack.redstone_experiments.description" }, - "pack_format": 61 + "pack_format": 71 } } \ No newline at end of file diff --git a/data/minecraft/datapacks/trade_rebalance/pack.mcmeta b/data/minecraft/datapacks/trade_rebalance/pack.mcmeta index 653aff19..67223954 100644 --- a/data/minecraft/datapacks/trade_rebalance/pack.mcmeta +++ b/data/minecraft/datapacks/trade_rebalance/pack.mcmeta @@ -8,6 +8,6 @@ "description": { "translate": "dataPack.trade_rebalance.description" }, - "pack_format": 61 + "pack_format": 71 } } \ No newline at end of file diff --git a/data/minecraft/frog_variant/cold.json b/data/minecraft/frog_variant/cold.json new file mode 100644 index 00000000..b38ca55f --- /dev/null +++ b/data/minecraft/frog_variant/cold.json @@ -0,0 +1,12 @@ +{ + "asset_id": "minecraft:entity/frog/cold_frog", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:spawns_cold_variant_frogs" + }, + "priority": 1 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/frog_variant/temperate.json b/data/minecraft/frog_variant/temperate.json new file mode 100644 index 00000000..0211c65d --- /dev/null +++ b/data/minecraft/frog_variant/temperate.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/frog/temperate_frog", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/frog_variant/warm.json b/data/minecraft/frog_variant/warm.json new file mode 100644 index 00000000..40c8adec --- /dev/null +++ b/data/minecraft/frog_variant/warm.json @@ -0,0 +1,12 @@ +{ + "asset_id": "minecraft:entity/frog/warm_frog", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:spawns_warm_variant_frogs" + }, + "priority": 1 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/loot_table/blocks/black_banner.json b/data/minecraft/loot_table/blocks/black_banner.json index 58bb186e..e4e07eaa 100644 --- a/data/minecraft/loot_table/blocks/black_banner.json +++ b/data/minecraft/loot_table/blocks/black_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/blue_banner.json b/data/minecraft/loot_table/blocks/blue_banner.json index c5579a8a..1afc9d7f 100644 --- a/data/minecraft/loot_table/blocks/blue_banner.json +++ b/data/minecraft/loot_table/blocks/blue_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/brown_banner.json b/data/minecraft/loot_table/blocks/brown_banner.json index 36beb1fc..77eee1c6 100644 --- a/data/minecraft/loot_table/blocks/brown_banner.json +++ b/data/minecraft/loot_table/blocks/brown_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/bush.json b/data/minecraft/loot_table/blocks/bush.json new file mode 100644 index 00000000..7c465247 --- /dev/null +++ b/data/minecraft/loot_table/blocks/bush.json @@ -0,0 +1,44 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:any_of", + "terms": [ + { + "condition": "minecraft:match_tool", + "predicate": { + "items": "minecraft:shears" + } + }, + { + "condition": "minecraft:match_tool", + "predicate": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantments": "minecraft:silk_touch", + "levels": { + "min": 1 + } + } + ] + } + } + } + ] + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "minecraft:bush" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "minecraft:blocks/bush" +} \ No newline at end of file diff --git a/data/minecraft/loot_table/blocks/cactus_flower.json b/data/minecraft/loot_table/blocks/cactus_flower.json new file mode 100644 index 00000000..087ade13 --- /dev/null +++ b/data/minecraft/loot_table/blocks/cactus_flower.json @@ -0,0 +1,21 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "minecraft:cactus_flower" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "minecraft:blocks/cactus_flower" +} \ No newline at end of file diff --git a/data/minecraft/loot_table/blocks/cyan_banner.json b/data/minecraft/loot_table/blocks/cyan_banner.json index 45c30619..8e063f58 100644 --- a/data/minecraft/loot_table/blocks/cyan_banner.json +++ b/data/minecraft/loot_table/blocks/cyan_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/firefly_bush.json b/data/minecraft/loot_table/blocks/firefly_bush.json new file mode 100644 index 00000000..d0b166e7 --- /dev/null +++ b/data/minecraft/loot_table/blocks/firefly_bush.json @@ -0,0 +1,21 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:survives_explosion" + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "minecraft:firefly_bush" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "minecraft:blocks/firefly_bush" +} \ No newline at end of file diff --git a/data/minecraft/loot_table/blocks/gray_banner.json b/data/minecraft/loot_table/blocks/gray_banner.json index bde4a17a..5aad6ec0 100644 --- a/data/minecraft/loot_table/blocks/gray_banner.json +++ b/data/minecraft/loot_table/blocks/gray_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/green_banner.json b/data/minecraft/loot_table/blocks/green_banner.json index f58d0453..ae4f34d9 100644 --- a/data/minecraft/loot_table/blocks/green_banner.json +++ b/data/minecraft/loot_table/blocks/green_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/leaf_litter.json b/data/minecraft/loot_table/blocks/leaf_litter.json new file mode 100644 index 00000000..20da2508 --- /dev/null +++ b/data/minecraft/loot_table/blocks/leaf_litter.json @@ -0,0 +1,77 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "conditions": [ + { + "block": "minecraft:leaf_litter", + "condition": "minecraft:block_state_property", + "properties": { + "segment_amount": "1" + } + } + ], + "count": 1.0, + "function": "minecraft:set_count" + }, + { + "add": false, + "conditions": [ + { + "block": "minecraft:leaf_litter", + "condition": "minecraft:block_state_property", + "properties": { + "segment_amount": "2" + } + } + ], + "count": 2.0, + "function": "minecraft:set_count" + }, + { + "add": false, + "conditions": [ + { + "block": "minecraft:leaf_litter", + "condition": "minecraft:block_state_property", + "properties": { + "segment_amount": "3" + } + } + ], + "count": 3.0, + "function": "minecraft:set_count" + }, + { + "add": false, + "conditions": [ + { + "block": "minecraft:leaf_litter", + "condition": "minecraft:block_state_property", + "properties": { + "segment_amount": "4" + } + } + ], + "count": 4.0, + "function": "minecraft:set_count" + }, + { + "function": "minecraft:explosion_decay" + } + ], + "name": "minecraft:leaf_litter" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "minecraft:blocks/leaf_litter" +} \ No newline at end of file diff --git a/data/minecraft/loot_table/blocks/light_blue_banner.json b/data/minecraft/loot_table/blocks/light_blue_banner.json index 0c56fa54..457eb95d 100644 --- a/data/minecraft/loot_table/blocks/light_blue_banner.json +++ b/data/minecraft/loot_table/blocks/light_blue_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/light_gray_banner.json b/data/minecraft/loot_table/blocks/light_gray_banner.json index 9ca07510..c03d0d55 100644 --- a/data/minecraft/loot_table/blocks/light_gray_banner.json +++ b/data/minecraft/loot_table/blocks/light_gray_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/lime_banner.json b/data/minecraft/loot_table/blocks/lime_banner.json index 22be4355..5824e8b3 100644 --- a/data/minecraft/loot_table/blocks/lime_banner.json +++ b/data/minecraft/loot_table/blocks/lime_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/magenta_banner.json b/data/minecraft/loot_table/blocks/magenta_banner.json index 3c293a83..458a4fe0 100644 --- a/data/minecraft/loot_table/blocks/magenta_banner.json +++ b/data/minecraft/loot_table/blocks/magenta_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/orange_banner.json b/data/minecraft/loot_table/blocks/orange_banner.json index d47a7827..4f1d0b77 100644 --- a/data/minecraft/loot_table/blocks/orange_banner.json +++ b/data/minecraft/loot_table/blocks/orange_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/pink_banner.json b/data/minecraft/loot_table/blocks/pink_banner.json index 6d5c95c4..c46b2b28 100644 --- a/data/minecraft/loot_table/blocks/pink_banner.json +++ b/data/minecraft/loot_table/blocks/pink_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/purple_banner.json b/data/minecraft/loot_table/blocks/purple_banner.json index e0d11afb..6435da02 100644 --- a/data/minecraft/loot_table/blocks/purple_banner.json +++ b/data/minecraft/loot_table/blocks/purple_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/red_banner.json b/data/minecraft/loot_table/blocks/red_banner.json index dcc1323c..9cd58ad2 100644 --- a/data/minecraft/loot_table/blocks/red_banner.json +++ b/data/minecraft/loot_table/blocks/red_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/resin_brick_slab.json b/data/minecraft/loot_table/blocks/resin_brick_slab.json index 0c50e3e8..7b85e6d6 100644 --- a/data/minecraft/loot_table/blocks/resin_brick_slab.json +++ b/data/minecraft/loot_table/blocks/resin_brick_slab.json @@ -3,14 +3,28 @@ "pools": [ { "bonus_rolls": 0.0, - "conditions": [ - { - "condition": "minecraft:survives_explosion" - } - ], "entries": [ { "type": "minecraft:item", + "functions": [ + { + "add": false, + "conditions": [ + { + "block": "minecraft:resin_brick_slab", + "condition": "minecraft:block_state_property", + "properties": { + "type": "double" + } + } + ], + "count": 2.0, + "function": "minecraft:set_count" + }, + { + "function": "minecraft:explosion_decay" + } + ], "name": "minecraft:resin_brick_slab" } ], diff --git a/data/minecraft/loot_table/blocks/short_dry_grass.json b/data/minecraft/loot_table/blocks/short_dry_grass.json new file mode 100644 index 00000000..e19e59db --- /dev/null +++ b/data/minecraft/loot_table/blocks/short_dry_grass.json @@ -0,0 +1,44 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:any_of", + "terms": [ + { + "condition": "minecraft:match_tool", + "predicate": { + "items": "minecraft:shears" + } + }, + { + "condition": "minecraft:match_tool", + "predicate": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantments": "minecraft:silk_touch", + "levels": { + "min": 1 + } + } + ] + } + } + } + ] + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "minecraft:short_dry_grass" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "minecraft:blocks/short_dry_grass" +} \ No newline at end of file diff --git a/data/minecraft/loot_table/blocks/tall_dry_grass.json b/data/minecraft/loot_table/blocks/tall_dry_grass.json new file mode 100644 index 00000000..7055b9e3 --- /dev/null +++ b/data/minecraft/loot_table/blocks/tall_dry_grass.json @@ -0,0 +1,44 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "conditions": [ + { + "condition": "minecraft:any_of", + "terms": [ + { + "condition": "minecraft:match_tool", + "predicate": { + "items": "minecraft:shears" + } + }, + { + "condition": "minecraft:match_tool", + "predicate": { + "predicates": { + "minecraft:enchantments": [ + { + "enchantments": "minecraft:silk_touch", + "levels": { + "min": 1 + } + } + ] + } + } + } + ] + } + ], + "entries": [ + { + "type": "minecraft:item", + "name": "minecraft:tall_dry_grass" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "minecraft:blocks/tall_dry_grass" +} \ No newline at end of file diff --git a/data/minecraft/loot_table/blocks/white_banner.json b/data/minecraft/loot_table/blocks/white_banner.json index f6f334c2..d6b17c66 100644 --- a/data/minecraft/loot_table/blocks/white_banner.json +++ b/data/minecraft/loot_table/blocks/white_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/blocks/wildflowers.json b/data/minecraft/loot_table/blocks/wildflowers.json new file mode 100644 index 00000000..69787c38 --- /dev/null +++ b/data/minecraft/loot_table/blocks/wildflowers.json @@ -0,0 +1,77 @@ +{ + "type": "minecraft:block", + "pools": [ + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "conditions": [ + { + "block": "minecraft:wildflowers", + "condition": "minecraft:block_state_property", + "properties": { + "flower_amount": "1" + } + } + ], + "count": 1.0, + "function": "minecraft:set_count" + }, + { + "add": false, + "conditions": [ + { + "block": "minecraft:wildflowers", + "condition": "minecraft:block_state_property", + "properties": { + "flower_amount": "2" + } + } + ], + "count": 2.0, + "function": "minecraft:set_count" + }, + { + "add": false, + "conditions": [ + { + "block": "minecraft:wildflowers", + "condition": "minecraft:block_state_property", + "properties": { + "flower_amount": "3" + } + } + ], + "count": 3.0, + "function": "minecraft:set_count" + }, + { + "add": false, + "conditions": [ + { + "block": "minecraft:wildflowers", + "condition": "minecraft:block_state_property", + "properties": { + "flower_amount": "4" + } + } + ], + "count": 4.0, + "function": "minecraft:set_count" + }, + { + "function": "minecraft:explosion_decay" + } + ], + "name": "minecraft:wildflowers" + } + ], + "rolls": 1.0 + } + ], + "random_sequence": "minecraft:blocks/wildflowers" +} \ No newline at end of file diff --git a/data/minecraft/loot_table/blocks/yellow_banner.json b/data/minecraft/loot_table/blocks/yellow_banner.json index 7db122bd..9b36ed28 100644 --- a/data/minecraft/loot_table/blocks/yellow_banner.json +++ b/data/minecraft/loot_table/blocks/yellow_banner.json @@ -17,7 +17,7 @@ "include": [ "minecraft:custom_name", "minecraft:item_name", - "minecraft:hide_additional_tooltip", + "minecraft:tooltip_display", "minecraft:banner_patterns", "minecraft:rarity" ], diff --git a/data/minecraft/loot_table/chests/ruined_portal.json b/data/minecraft/loot_table/chests/ruined_portal.json index f2070e3b..671ecb07 100644 --- a/data/minecraft/loot_table/chests/ruined_portal.json +++ b/data/minecraft/loot_table/chests/ruined_portal.json @@ -274,6 +274,31 @@ "max": 8.0, "min": 4.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:empty" + }, + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": { + "type": "minecraft:uniform", + "max": 2.0, + "min": 1.0 + }, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:lodestone", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/ruined_portal" diff --git a/data/minecraft/loot_table/chests/village/village_cartographer.json b/data/minecraft/loot_table/chests/village/village_cartographer.json index a13fa35c..06a3d7b8 100644 --- a/data/minecraft/loot_table/chests/village/village_cartographer.json +++ b/data/minecraft/loot_table/chests/village/village_cartographer.json @@ -79,6 +79,27 @@ "max": 5.0, "min": 1.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": 1.0, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:bundle" + }, + { + "type": "minecraft:empty", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/village/village_cartographer" diff --git a/data/minecraft/loot_table/chests/village/village_desert_house.json b/data/minecraft/loot_table/chests/village/village_desert_house.json index 7c46181d..d18930c4 100644 --- a/data/minecraft/loot_table/chests/village/village_desert_house.json +++ b/data/minecraft/loot_table/chests/village/village_desert_house.json @@ -101,6 +101,27 @@ "max": 8.0, "min": 3.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": 1.0, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:bundle" + }, + { + "type": "minecraft:empty", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/village/village_desert_house" diff --git a/data/minecraft/loot_table/chests/village/village_plains_house.json b/data/minecraft/loot_table/chests/village/village_plains_house.json index d5839ba1..282170d9 100644 --- a/data/minecraft/loot_table/chests/village/village_plains_house.json +++ b/data/minecraft/loot_table/chests/village/village_plains_house.json @@ -122,6 +122,27 @@ "max": 8.0, "min": 3.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": 1.0, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:bundle" + }, + { + "type": "minecraft:empty", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/village/village_plains_house" diff --git a/data/minecraft/loot_table/chests/village/village_savanna_house.json b/data/minecraft/loot_table/chests/village/village_savanna_house.json index 156bbf26..2f7e410c 100644 --- a/data/minecraft/loot_table/chests/village/village_savanna_house.json +++ b/data/minecraft/loot_table/chests/village/village_savanna_house.json @@ -122,6 +122,27 @@ "max": 8.0, "min": 3.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": 1.0, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:bundle" + }, + { + "type": "minecraft:empty", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/village/village_savanna_house" diff --git a/data/minecraft/loot_table/chests/village/village_snowy_house.json b/data/minecraft/loot_table/chests/village/village_snowy_house.json index 9f554ad1..c044db9a 100644 --- a/data/minecraft/loot_table/chests/village/village_snowy_house.json +++ b/data/minecraft/loot_table/chests/village/village_snowy_house.json @@ -122,6 +122,27 @@ "max": 8.0, "min": 3.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": 1.0, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:bundle" + }, + { + "type": "minecraft:empty", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/village/village_snowy_house" diff --git a/data/minecraft/loot_table/chests/village/village_taiga_house.json b/data/minecraft/loot_table/chests/village/village_taiga_house.json index 3793b162..ee9225da 100644 --- a/data/minecraft/loot_table/chests/village/village_taiga_house.json +++ b/data/minecraft/loot_table/chests/village/village_taiga_house.json @@ -155,6 +155,27 @@ "max": 8.0, "min": 3.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": 1.0, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:bundle" + }, + { + "type": "minecraft:empty", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/village/village_taiga_house" diff --git a/data/minecraft/loot_table/chests/village/village_tannery.json b/data/minecraft/loot_table/chests/village/village_tannery.json index 26c09584..d6140128 100644 --- a/data/minecraft/loot_table/chests/village/village_tannery.json +++ b/data/minecraft/loot_table/chests/village/village_tannery.json @@ -80,6 +80,27 @@ "max": 5.0, "min": 1.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": 1.0, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:bundle" + }, + { + "type": "minecraft:empty", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/village/village_tannery" diff --git a/data/minecraft/loot_table/chests/village/village_weaponsmith.json b/data/minecraft/loot_table/chests/village/village_weaponsmith.json index 195648aa..76b9fabe 100644 --- a/data/minecraft/loot_table/chests/village/village_weaponsmith.json +++ b/data/minecraft/loot_table/chests/village/village_weaponsmith.json @@ -169,6 +169,27 @@ "max": 8.0, "min": 3.0 } + }, + { + "bonus_rolls": 0.0, + "entries": [ + { + "type": "minecraft:item", + "functions": [ + { + "add": false, + "count": 1.0, + "function": "minecraft:set_count" + } + ], + "name": "minecraft:bundle" + }, + { + "type": "minecraft:empty", + "weight": 2 + } + ], + "rolls": 1.0 } ], "random_sequence": "minecraft:chests/village/village_weaponsmith" diff --git a/data/minecraft/loot_table/entities/magma_cube.json b/data/minecraft/loot_table/entities/magma_cube.json index d560ee8b..56038643 100644 --- a/data/minecraft/loot_table/entities/magma_cube.json +++ b/data/minecraft/loot_table/entities/magma_cube.json @@ -61,9 +61,8 @@ "predicate": { "source_entity": { "type": "minecraft:frog", - "type_specific": { - "type": "minecraft:frog", - "variant": "minecraft:warm" + "components": { + "minecraft:frog/variant": "minecraft:warm" } } } @@ -86,9 +85,8 @@ "predicate": { "source_entity": { "type": "minecraft:frog", - "type_specific": { - "type": "minecraft:frog", - "variant": "minecraft:cold" + "components": { + "minecraft:frog/variant": "minecraft:cold" } } } @@ -111,9 +109,8 @@ "predicate": { "source_entity": { "type": "minecraft:frog", - "type_specific": { - "type": "minecraft:frog", - "variant": "minecraft:temperate" + "components": { + "minecraft:frog/variant": "minecraft:temperate" } } } diff --git a/data/minecraft/loot_table/entities/sheep.json b/data/minecraft/loot_table/entities/sheep.json index fa39ae74..5b8069f4 100644 --- a/data/minecraft/loot_table/entities/sheep.json +++ b/data/minecraft/loot_table/entities/sheep.json @@ -80,9 +80,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "white" + }, "type_specific": { "type": "minecraft:sheep", - "color": "white", "sheared": false } } @@ -97,9 +99,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "orange" + }, "type_specific": { "type": "minecraft:sheep", - "color": "orange", "sheared": false } } @@ -114,9 +118,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "magenta" + }, "type_specific": { "type": "minecraft:sheep", - "color": "magenta", "sheared": false } } @@ -131,9 +137,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "light_blue" + }, "type_specific": { "type": "minecraft:sheep", - "color": "light_blue", "sheared": false } } @@ -148,9 +156,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "yellow" + }, "type_specific": { "type": "minecraft:sheep", - "color": "yellow", "sheared": false } } @@ -165,9 +175,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "lime" + }, "type_specific": { "type": "minecraft:sheep", - "color": "lime", "sheared": false } } @@ -182,9 +194,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "pink" + }, "type_specific": { "type": "minecraft:sheep", - "color": "pink", "sheared": false } } @@ -199,9 +213,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "gray" + }, "type_specific": { "type": "minecraft:sheep", - "color": "gray", "sheared": false } } @@ -216,9 +232,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "light_gray" + }, "type_specific": { "type": "minecraft:sheep", - "color": "light_gray", "sheared": false } } @@ -233,9 +251,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "cyan" + }, "type_specific": { "type": "minecraft:sheep", - "color": "cyan", "sheared": false } } @@ -250,9 +270,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "purple" + }, "type_specific": { "type": "minecraft:sheep", - "color": "purple", "sheared": false } } @@ -267,9 +289,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "blue" + }, "type_specific": { "type": "minecraft:sheep", - "color": "blue", "sheared": false } } @@ -284,9 +308,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "brown" + }, "type_specific": { "type": "minecraft:sheep", - "color": "brown", "sheared": false } } @@ -301,9 +327,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "green" + }, "type_specific": { "type": "minecraft:sheep", - "color": "green", "sheared": false } } @@ -318,9 +346,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "red" + }, "type_specific": { "type": "minecraft:sheep", - "color": "red", "sheared": false } } @@ -335,9 +365,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "black" + }, "type_specific": { "type": "minecraft:sheep", - "color": "black", "sheared": false } } diff --git a/data/minecraft/loot_table/gameplay/chicken_lay.json b/data/minecraft/loot_table/gameplay/chicken_lay.json index 7c5b849d..1cbcbc49 100644 --- a/data/minecraft/loot_table/gameplay/chicken_lay.json +++ b/data/minecraft/loot_table/gameplay/chicken_lay.json @@ -5,8 +5,54 @@ "bonus_rolls": 0.0, "entries": [ { - "type": "minecraft:item", - "name": "minecraft:egg" + "type": "minecraft:alternatives", + "children": [ + { + "type": "minecraft:item", + "conditions": [ + { + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "components": { + "minecraft:chicken/variant": "minecraft:temperate" + } + } + } + ], + "name": "minecraft:egg" + }, + { + "type": "minecraft:item", + "conditions": [ + { + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "components": { + "minecraft:chicken/variant": "minecraft:warm" + } + } + } + ], + "name": "minecraft:brown_egg" + }, + { + "type": "minecraft:item", + "conditions": [ + { + "condition": "minecraft:entity_properties", + "entity": "this", + "predicate": { + "components": { + "minecraft:chicken/variant": "minecraft:cold" + } + } + } + ], + "name": "minecraft:blue_egg" + } + ] } ], "rolls": 1.0 diff --git a/data/minecraft/loot_table/shearing/mooshroom.json b/data/minecraft/loot_table/shearing/mooshroom.json index 85a56808..0c2c6225 100644 --- a/data/minecraft/loot_table/shearing/mooshroom.json +++ b/data/minecraft/loot_table/shearing/mooshroom.json @@ -14,9 +14,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:mooshroom", - "variant": "red" + "components": { + "minecraft:mooshroom/variant": "red" } } } @@ -30,9 +29,8 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { - "type_specific": { - "type": "minecraft:mooshroom", - "variant": "brown" + "components": { + "minecraft:mooshroom/variant": "brown" } } } diff --git a/data/minecraft/loot_table/shearing/sheep.json b/data/minecraft/loot_table/shearing/sheep.json index 684a083a..dfb6a5ba 100644 --- a/data/minecraft/loot_table/shearing/sheep.json +++ b/data/minecraft/loot_table/shearing/sheep.json @@ -14,9 +14,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "white" + }, "type_specific": { "type": "minecraft:sheep", - "color": "white", "sheared": false } } @@ -31,9 +33,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "orange" + }, "type_specific": { "type": "minecraft:sheep", - "color": "orange", "sheared": false } } @@ -48,9 +52,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "magenta" + }, "type_specific": { "type": "minecraft:sheep", - "color": "magenta", "sheared": false } } @@ -65,9 +71,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "light_blue" + }, "type_specific": { "type": "minecraft:sheep", - "color": "light_blue", "sheared": false } } @@ -82,9 +90,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "yellow" + }, "type_specific": { "type": "minecraft:sheep", - "color": "yellow", "sheared": false } } @@ -99,9 +109,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "lime" + }, "type_specific": { "type": "minecraft:sheep", - "color": "lime", "sheared": false } } @@ -116,9 +128,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "pink" + }, "type_specific": { "type": "minecraft:sheep", - "color": "pink", "sheared": false } } @@ -133,9 +147,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "gray" + }, "type_specific": { "type": "minecraft:sheep", - "color": "gray", "sheared": false } } @@ -150,9 +166,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "light_gray" + }, "type_specific": { "type": "minecraft:sheep", - "color": "light_gray", "sheared": false } } @@ -167,9 +185,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "cyan" + }, "type_specific": { "type": "minecraft:sheep", - "color": "cyan", "sheared": false } } @@ -184,9 +204,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "purple" + }, "type_specific": { "type": "minecraft:sheep", - "color": "purple", "sheared": false } } @@ -201,9 +223,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "blue" + }, "type_specific": { "type": "minecraft:sheep", - "color": "blue", "sheared": false } } @@ -218,9 +242,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "brown" + }, "type_specific": { "type": "minecraft:sheep", - "color": "brown", "sheared": false } } @@ -235,9 +261,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "green" + }, "type_specific": { "type": "minecraft:sheep", - "color": "green", "sheared": false } } @@ -252,9 +280,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "red" + }, "type_specific": { "type": "minecraft:sheep", - "color": "red", "sheared": false } } @@ -269,9 +299,11 @@ "condition": "minecraft:entity_properties", "entity": "this", "predicate": { + "components": { + "minecraft:sheep/color": "black" + }, "type_specific": { "type": "minecraft:sheep", - "color": "black", "sheared": false } } diff --git a/data/minecraft/pig_variant/cold.json b/data/minecraft/pig_variant/cold.json new file mode 100644 index 00000000..d6045cb6 --- /dev/null +++ b/data/minecraft/pig_variant/cold.json @@ -0,0 +1,13 @@ +{ + "asset_id": "minecraft:entity/pig/cold_pig", + "model": "cold", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:spawns_cold_variant_farm_animals" + }, + "priority": 1 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/pig_variant/temperate.json b/data/minecraft/pig_variant/temperate.json new file mode 100644 index 00000000..4b769b17 --- /dev/null +++ b/data/minecraft/pig_variant/temperate.json @@ -0,0 +1,8 @@ +{ + "asset_id": "minecraft:entity/pig/temperate_pig", + "spawn_conditions": [ + { + "priority": 0 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/pig_variant/warm.json b/data/minecraft/pig_variant/warm.json new file mode 100644 index 00000000..abddfc3e --- /dev/null +++ b/data/minecraft/pig_variant/warm.json @@ -0,0 +1,12 @@ +{ + "asset_id": "minecraft:entity/pig/warm_pig", + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:spawns_warm_variant_farm_animals" + }, + "priority": 1 + } + ] +} \ No newline at end of file diff --git a/data/minecraft/recipe/black_bundle.json b/data/minecraft/recipe/black_bundle.json index ef2f7f28..fa0cafcc 100644 --- a/data/minecraft/recipe/black_bundle.json +++ b/data/minecraft/recipe/black_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:black_dye", - "result": "minecraft:black_bundle" + "result": { + "id": "minecraft:black_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/black_shulker_box.json b/data/minecraft/recipe/black_shulker_box.json index ece44b36..d093da54 100644 --- a/data/minecraft/recipe/black_shulker_box.json +++ b/data/minecraft/recipe/black_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:black_dye", - "result": "minecraft:black_shulker_box" + "result": { + "id": "minecraft:black_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/blue_bundle.json b/data/minecraft/recipe/blue_bundle.json index 3269a4cb..5f3f5e34 100644 --- a/data/minecraft/recipe/blue_bundle.json +++ b/data/minecraft/recipe/blue_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:blue_dye", - "result": "minecraft:blue_bundle" + "result": { + "id": "minecraft:blue_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/blue_shulker_box.json b/data/minecraft/recipe/blue_shulker_box.json index 1d4637f6..98749939 100644 --- a/data/minecraft/recipe/blue_shulker_box.json +++ b/data/minecraft/recipe/blue_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:blue_dye", - "result": "minecraft:blue_shulker_box" + "result": { + "id": "minecraft:blue_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/bolt_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/bolt_armor_trim_smithing_template_smithing_trim.json index e50e010c..357d46bc 100644 --- a/data/minecraft/recipe/bolt_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/bolt_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:bolt", "template": "minecraft:bolt_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/brown_bundle.json b/data/minecraft/recipe/brown_bundle.json index dfa2a323..2a8358aa 100644 --- a/data/minecraft/recipe/brown_bundle.json +++ b/data/minecraft/recipe/brown_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:brown_dye", - "result": "minecraft:brown_bundle" + "result": { + "id": "minecraft:brown_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/brown_shulker_box.json b/data/minecraft/recipe/brown_shulker_box.json index 344c6fc0..8f147e80 100644 --- a/data/minecraft/recipe/brown_shulker_box.json +++ b/data/minecraft/recipe/brown_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:brown_dye", - "result": "minecraft:brown_shulker_box" + "result": { + "id": "minecraft:brown_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/cake.json b/data/minecraft/recipe/cake.json index b840c821..db05e94e 100644 --- a/data/minecraft/recipe/cake.json +++ b/data/minecraft/recipe/cake.json @@ -5,7 +5,7 @@ "A": "minecraft:milk_bucket", "B": "minecraft:sugar", "C": "minecraft:wheat", - "E": "minecraft:egg" + "E": "#minecraft:eggs" }, "pattern": [ "AAA", diff --git a/data/minecraft/recipe/coast_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/coast_armor_trim_smithing_template_smithing_trim.json index 844df515..8097b2e5 100644 --- a/data/minecraft/recipe/coast_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/coast_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:coast", "template": "minecraft:coast_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/cyan_bundle.json b/data/minecraft/recipe/cyan_bundle.json index 0f1c52ab..ed87c31d 100644 --- a/data/minecraft/recipe/cyan_bundle.json +++ b/data/minecraft/recipe/cyan_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:cyan_dye", - "result": "minecraft:cyan_bundle" + "result": { + "id": "minecraft:cyan_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/cyan_shulker_box.json b/data/minecraft/recipe/cyan_shulker_box.json index c45dbb68..1a461cd7 100644 --- a/data/minecraft/recipe/cyan_shulker_box.json +++ b/data/minecraft/recipe/cyan_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:cyan_dye", - "result": "minecraft:cyan_shulker_box" + "result": { + "id": "minecraft:cyan_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/dune_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/dune_armor_trim_smithing_template_smithing_trim.json index 264a25f8..4abdad1e 100644 --- a/data/minecraft/recipe/dune_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/dune_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:dune", "template": "minecraft:dune_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/eye_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/eye_armor_trim_smithing_template_smithing_trim.json index a7d5d3e8..2a770833 100644 --- a/data/minecraft/recipe/eye_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/eye_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:eye", "template": "minecraft:eye_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/flow_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/flow_armor_trim_smithing_template_smithing_trim.json index aa07def2..9dffe801 100644 --- a/data/minecraft/recipe/flow_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/flow_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:flow", "template": "minecraft:flow_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/gray_bundle.json b/data/minecraft/recipe/gray_bundle.json index 4220bb8b..f988d547 100644 --- a/data/minecraft/recipe/gray_bundle.json +++ b/data/minecraft/recipe/gray_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:gray_dye", - "result": "minecraft:gray_bundle" + "result": { + "id": "minecraft:gray_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/gray_dye.json b/data/minecraft/recipe/gray_dye.json index 91fa51bd..4f57d7bc 100644 --- a/data/minecraft/recipe/gray_dye.json +++ b/data/minecraft/recipe/gray_dye.json @@ -1,6 +1,7 @@ { "type": "minecraft:crafting_shapeless", "category": "misc", + "group": "gray_dye", "ingredients": [ "minecraft:black_dye", "minecraft:white_dye" diff --git a/data/minecraft/recipe/gray_shulker_box.json b/data/minecraft/recipe/gray_shulker_box.json index d3eccbb0..731a0b68 100644 --- a/data/minecraft/recipe/gray_shulker_box.json +++ b/data/minecraft/recipe/gray_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:gray_dye", - "result": "minecraft:gray_shulker_box" + "result": { + "id": "minecraft:gray_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/green_bundle.json b/data/minecraft/recipe/green_bundle.json index f2cf2689..0872554a 100644 --- a/data/minecraft/recipe/green_bundle.json +++ b/data/minecraft/recipe/green_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:green_dye", - "result": "minecraft:green_bundle" + "result": { + "id": "minecraft:green_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/green_shulker_box.json b/data/minecraft/recipe/green_shulker_box.json index cc9b6d72..f8fca9c7 100644 --- a/data/minecraft/recipe/green_shulker_box.json +++ b/data/minecraft/recipe/green_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:green_dye", - "result": "minecraft:green_shulker_box" + "result": { + "id": "minecraft:green_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/host_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/host_armor_trim_smithing_template_smithing_trim.json index 0609cebb..b1933cfb 100644 --- a/data/minecraft/recipe/host_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/host_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:host", "template": "minecraft:host_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/leaf_litter.json b/data/minecraft/recipe/leaf_litter.json new file mode 100644 index 00000000..d5263e5f --- /dev/null +++ b/data/minecraft/recipe/leaf_litter.json @@ -0,0 +1,10 @@ +{ + "type": "minecraft:smelting", + "category": "blocks", + "cookingtime": 200, + "experience": 0.1, + "ingredient": "#minecraft:leaves", + "result": { + "id": "minecraft:leaf_litter" + } +} \ No newline at end of file diff --git a/data/minecraft/recipe/light_blue_bundle.json b/data/minecraft/recipe/light_blue_bundle.json index a0a105d9..67e762c0 100644 --- a/data/minecraft/recipe/light_blue_bundle.json +++ b/data/minecraft/recipe/light_blue_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:light_blue_dye", - "result": "minecraft:light_blue_bundle" + "result": { + "id": "minecraft:light_blue_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/light_blue_shulker_box.json b/data/minecraft/recipe/light_blue_shulker_box.json index 53604ac0..28f79584 100644 --- a/data/minecraft/recipe/light_blue_shulker_box.json +++ b/data/minecraft/recipe/light_blue_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:light_blue_dye", - "result": "minecraft:light_blue_shulker_box" + "result": { + "id": "minecraft:light_blue_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/light_gray_bundle.json b/data/minecraft/recipe/light_gray_bundle.json index 6e416c06..7f4f6585 100644 --- a/data/minecraft/recipe/light_gray_bundle.json +++ b/data/minecraft/recipe/light_gray_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:light_gray_dye", - "result": "minecraft:light_gray_bundle" + "result": { + "id": "minecraft:light_gray_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/light_gray_shulker_box.json b/data/minecraft/recipe/light_gray_shulker_box.json index 3921cf87..d82ad3b7 100644 --- a/data/minecraft/recipe/light_gray_shulker_box.json +++ b/data/minecraft/recipe/light_gray_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:light_gray_dye", - "result": "minecraft:light_gray_shulker_box" + "result": { + "id": "minecraft:light_gray_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/lime_bundle.json b/data/minecraft/recipe/lime_bundle.json index 6c1a2969..8252846b 100644 --- a/data/minecraft/recipe/lime_bundle.json +++ b/data/minecraft/recipe/lime_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:lime_dye", - "result": "minecraft:lime_bundle" + "result": { + "id": "minecraft:lime_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/lime_shulker_box.json b/data/minecraft/recipe/lime_shulker_box.json index 5ca80d9c..eff96ea7 100644 --- a/data/minecraft/recipe/lime_shulker_box.json +++ b/data/minecraft/recipe/lime_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:lime_dye", - "result": "minecraft:lime_shulker_box" + "result": { + "id": "minecraft:lime_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/lodestone.json b/data/minecraft/recipe/lodestone.json index a83c3091..d3c1bb99 100644 --- a/data/minecraft/recipe/lodestone.json +++ b/data/minecraft/recipe/lodestone.json @@ -2,7 +2,7 @@ "type": "minecraft:crafting_shaped", "category": "misc", "key": { - "#": "minecraft:netherite_ingot", + "#": "minecraft:iron_ingot", "S": "minecraft:chiseled_stone_bricks" }, "pattern": [ diff --git a/data/minecraft/recipe/magenta_bundle.json b/data/minecraft/recipe/magenta_bundle.json index 4283ad14..f63d30a1 100644 --- a/data/minecraft/recipe/magenta_bundle.json +++ b/data/minecraft/recipe/magenta_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:magenta_dye", - "result": "minecraft:magenta_bundle" + "result": { + "id": "minecraft:magenta_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/magenta_shulker_box.json b/data/minecraft/recipe/magenta_shulker_box.json index f3542475..ae4337cc 100644 --- a/data/minecraft/recipe/magenta_shulker_box.json +++ b/data/minecraft/recipe/magenta_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:magenta_dye", - "result": "minecraft:magenta_shulker_box" + "result": { + "id": "minecraft:magenta_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/netherite_axe_smithing.json b/data/minecraft/recipe/netherite_axe_smithing.json index 29c79980..99903fa9 100644 --- a/data/minecraft/recipe/netherite_axe_smithing.json +++ b/data/minecraft/recipe/netherite_axe_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_axe", "result": { - "count": 1, "id": "minecraft:netherite_axe" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/netherite_boots_smithing.json b/data/minecraft/recipe/netherite_boots_smithing.json index da3c3f16..9c13806b 100644 --- a/data/minecraft/recipe/netherite_boots_smithing.json +++ b/data/minecraft/recipe/netherite_boots_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_boots", "result": { - "count": 1, "id": "minecraft:netherite_boots" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/netherite_chestplate_smithing.json b/data/minecraft/recipe/netherite_chestplate_smithing.json index 75c82ec2..5de05c02 100644 --- a/data/minecraft/recipe/netherite_chestplate_smithing.json +++ b/data/minecraft/recipe/netherite_chestplate_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_chestplate", "result": { - "count": 1, "id": "minecraft:netherite_chestplate" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/netherite_helmet_smithing.json b/data/minecraft/recipe/netherite_helmet_smithing.json index 23eff34f..50e7927c 100644 --- a/data/minecraft/recipe/netherite_helmet_smithing.json +++ b/data/minecraft/recipe/netherite_helmet_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_helmet", "result": { - "count": 1, "id": "minecraft:netherite_helmet" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/netherite_hoe_smithing.json b/data/minecraft/recipe/netherite_hoe_smithing.json index 702edabe..2fdc9a18 100644 --- a/data/minecraft/recipe/netherite_hoe_smithing.json +++ b/data/minecraft/recipe/netherite_hoe_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_hoe", "result": { - "count": 1, "id": "minecraft:netherite_hoe" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/netherite_leggings_smithing.json b/data/minecraft/recipe/netherite_leggings_smithing.json index c1400d30..e315e1a2 100644 --- a/data/minecraft/recipe/netherite_leggings_smithing.json +++ b/data/minecraft/recipe/netherite_leggings_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_leggings", "result": { - "count": 1, "id": "minecraft:netherite_leggings" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/netherite_pickaxe_smithing.json b/data/minecraft/recipe/netherite_pickaxe_smithing.json index 60b64e89..3193a208 100644 --- a/data/minecraft/recipe/netherite_pickaxe_smithing.json +++ b/data/minecraft/recipe/netherite_pickaxe_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_pickaxe", "result": { - "count": 1, "id": "minecraft:netherite_pickaxe" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/netherite_shovel_smithing.json b/data/minecraft/recipe/netherite_shovel_smithing.json index 01ce41ed..59ad7518 100644 --- a/data/minecraft/recipe/netherite_shovel_smithing.json +++ b/data/minecraft/recipe/netherite_shovel_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_shovel", "result": { - "count": 1, "id": "minecraft:netherite_shovel" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/netherite_sword_smithing.json b/data/minecraft/recipe/netherite_sword_smithing.json index 86a8e7ab..45ce0fb1 100644 --- a/data/minecraft/recipe/netherite_sword_smithing.json +++ b/data/minecraft/recipe/netherite_sword_smithing.json @@ -3,7 +3,6 @@ "addition": "#minecraft:netherite_tool_materials", "base": "minecraft:diamond_sword", "result": { - "count": 1, "id": "minecraft:netherite_sword" }, "template": "minecraft:netherite_upgrade_smithing_template" diff --git a/data/minecraft/recipe/orange_bundle.json b/data/minecraft/recipe/orange_bundle.json index 4aa80ccc..4c70b6c8 100644 --- a/data/minecraft/recipe/orange_bundle.json +++ b/data/minecraft/recipe/orange_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:orange_dye", - "result": "minecraft:orange_bundle" + "result": { + "id": "minecraft:orange_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/orange_shulker_box.json b/data/minecraft/recipe/orange_shulker_box.json index 203f8eeb..64a1aabf 100644 --- a/data/minecraft/recipe/orange_shulker_box.json +++ b/data/minecraft/recipe/orange_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:orange_dye", - "result": "minecraft:orange_shulker_box" + "result": { + "id": "minecraft:orange_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/pink_bundle.json b/data/minecraft/recipe/pink_bundle.json index f08dafbb..4a815ba7 100644 --- a/data/minecraft/recipe/pink_bundle.json +++ b/data/minecraft/recipe/pink_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:pink_dye", - "result": "minecraft:pink_bundle" + "result": { + "id": "minecraft:pink_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/pink_dye_from_cactus_flower.json b/data/minecraft/recipe/pink_dye_from_cactus_flower.json new file mode 100644 index 00000000..4d40f861 --- /dev/null +++ b/data/minecraft/recipe/pink_dye_from_cactus_flower.json @@ -0,0 +1,12 @@ +{ + "type": "minecraft:crafting_shapeless", + "category": "misc", + "group": "pink_dye", + "ingredients": [ + "minecraft:cactus_flower" + ], + "result": { + "count": 1, + "id": "minecraft:pink_dye" + } +} \ No newline at end of file diff --git a/data/minecraft/recipe/pink_shulker_box.json b/data/minecraft/recipe/pink_shulker_box.json index 3916f886..87eb1b7d 100644 --- a/data/minecraft/recipe/pink_shulker_box.json +++ b/data/minecraft/recipe/pink_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:pink_dye", - "result": "minecraft:pink_shulker_box" + "result": { + "id": "minecraft:pink_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/pumpkin_pie.json b/data/minecraft/recipe/pumpkin_pie.json index 2f1064c4..715db8e6 100644 --- a/data/minecraft/recipe/pumpkin_pie.json +++ b/data/minecraft/recipe/pumpkin_pie.json @@ -4,7 +4,7 @@ "ingredients": [ "minecraft:pumpkin", "minecraft:sugar", - "minecraft:egg" + "#minecraft:eggs" ], "result": { "count": 1, diff --git a/data/minecraft/recipe/purple_bundle.json b/data/minecraft/recipe/purple_bundle.json index 41875b1e..15358b5d 100644 --- a/data/minecraft/recipe/purple_bundle.json +++ b/data/minecraft/recipe/purple_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:purple_dye", - "result": "minecraft:purple_bundle" + "result": { + "id": "minecraft:purple_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/purple_shulker_box.json b/data/minecraft/recipe/purple_shulker_box.json index 1fdcc2af..ac38ec61 100644 --- a/data/minecraft/recipe/purple_shulker_box.json +++ b/data/minecraft/recipe/purple_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:purple_dye", - "result": "minecraft:purple_shulker_box" + "result": { + "id": "minecraft:purple_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/raiser_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/raiser_armor_trim_smithing_template_smithing_trim.json index 1ad65dd0..7b931038 100644 --- a/data/minecraft/recipe/raiser_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/raiser_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:raiser", "template": "minecraft:raiser_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/red_bundle.json b/data/minecraft/recipe/red_bundle.json index 8f066354..24c2f1b5 100644 --- a/data/minecraft/recipe/red_bundle.json +++ b/data/minecraft/recipe/red_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:red_dye", - "result": "minecraft:red_bundle" + "result": { + "id": "minecraft:red_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/red_shulker_box.json b/data/minecraft/recipe/red_shulker_box.json index 7ffeeefa..35d35f1e 100644 --- a/data/minecraft/recipe/red_shulker_box.json +++ b/data/minecraft/recipe/red_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:red_dye", - "result": "minecraft:red_shulker_box" + "result": { + "id": "minecraft:red_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/rib_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/rib_armor_trim_smithing_template_smithing_trim.json index cb18a0e3..6ca6e350 100644 --- a/data/minecraft/recipe/rib_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/rib_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:rib", "template": "minecraft:rib_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/sentry_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/sentry_armor_trim_smithing_template_smithing_trim.json index a3472bdf..9a5a14a8 100644 --- a/data/minecraft/recipe/sentry_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/sentry_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:sentry", "template": "minecraft:sentry_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/shaper_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/shaper_armor_trim_smithing_template_smithing_trim.json index 2f9b1ab6..9941c188 100644 --- a/data/minecraft/recipe/shaper_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/shaper_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:shaper", "template": "minecraft:shaper_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/silence_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/silence_armor_trim_smithing_template_smithing_trim.json index 8917ace5..33711f0f 100644 --- a/data/minecraft/recipe/silence_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/silence_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:silence", "template": "minecraft:silence_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/snout_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/snout_armor_trim_smithing_template_smithing_trim.json index 88d0dd13..fef00c3a 100644 --- a/data/minecraft/recipe/snout_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/snout_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:snout", "template": "minecraft:snout_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/spire_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/spire_armor_trim_smithing_template_smithing_trim.json index 628e1720..2fd3e875 100644 --- a/data/minecraft/recipe/spire_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/spire_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:spire", "template": "minecraft:spire_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/tide_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/tide_armor_trim_smithing_template_smithing_trim.json index f34049a3..6eca0d9b 100644 --- a/data/minecraft/recipe/tide_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/tide_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:tide", "template": "minecraft:tide_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/vex_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/vex_armor_trim_smithing_template_smithing_trim.json index f54e11a5..fc4bb7c0 100644 --- a/data/minecraft/recipe/vex_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/vex_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:vex", "template": "minecraft:vex_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/ward_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/ward_armor_trim_smithing_template_smithing_trim.json index 4da4029c..4dae63a1 100644 --- a/data/minecraft/recipe/ward_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/ward_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:ward", "template": "minecraft:ward_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/wayfinder_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/wayfinder_armor_trim_smithing_template_smithing_trim.json index 073870fc..465d06f2 100644 --- a/data/minecraft/recipe/wayfinder_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/wayfinder_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:wayfinder", "template": "minecraft:wayfinder_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/white_bundle.json b/data/minecraft/recipe/white_bundle.json index 7a533375..69880b90 100644 --- a/data/minecraft/recipe/white_bundle.json +++ b/data/minecraft/recipe/white_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:white_dye", - "result": "minecraft:white_bundle" + "result": { + "id": "minecraft:white_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/white_shulker_box.json b/data/minecraft/recipe/white_shulker_box.json index 5c7cbd79..210af526 100644 --- a/data/minecraft/recipe/white_shulker_box.json +++ b/data/minecraft/recipe/white_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:white_dye", - "result": "minecraft:white_shulker_box" + "result": { + "id": "minecraft:white_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/wild_armor_trim_smithing_template_smithing_trim.json b/data/minecraft/recipe/wild_armor_trim_smithing_template_smithing_trim.json index 14d650ea..ad95528d 100644 --- a/data/minecraft/recipe/wild_armor_trim_smithing_template_smithing_trim.json +++ b/data/minecraft/recipe/wild_armor_trim_smithing_template_smithing_trim.json @@ -2,5 +2,6 @@ "type": "minecraft:smithing_trim", "addition": "#minecraft:trim_materials", "base": "#minecraft:trimmable_armor", + "pattern": "minecraft:wild", "template": "minecraft:wild_armor_trim_smithing_template" } \ No newline at end of file diff --git a/data/minecraft/recipe/yellow_bundle.json b/data/minecraft/recipe/yellow_bundle.json index 47536709..9519bb8a 100644 --- a/data/minecraft/recipe/yellow_bundle.json +++ b/data/minecraft/recipe/yellow_bundle.json @@ -4,5 +4,7 @@ "group": "bundle_dye", "input": "#minecraft:bundles", "material": "minecraft:yellow_dye", - "result": "minecraft:yellow_bundle" + "result": { + "id": "minecraft:yellow_bundle" + } } \ No newline at end of file diff --git a/data/minecraft/recipe/yellow_dye_from_wildflowers.json b/data/minecraft/recipe/yellow_dye_from_wildflowers.json new file mode 100644 index 00000000..29f2d836 --- /dev/null +++ b/data/minecraft/recipe/yellow_dye_from_wildflowers.json @@ -0,0 +1,12 @@ +{ + "type": "minecraft:crafting_shapeless", + "category": "misc", + "group": "yellow_dye", + "ingredients": [ + "minecraft:wildflowers" + ], + "result": { + "count": 1, + "id": "minecraft:yellow_dye" + } +} \ No newline at end of file diff --git a/data/minecraft/recipe/yellow_shulker_box.json b/data/minecraft/recipe/yellow_shulker_box.json index 0506c068..2f07a34f 100644 --- a/data/minecraft/recipe/yellow_shulker_box.json +++ b/data/minecraft/recipe/yellow_shulker_box.json @@ -4,5 +4,7 @@ "group": "shulker_box_dye", "input": "#minecraft:shulker_boxes", "material": "minecraft:yellow_dye", - "result": "minecraft:yellow_shulker_box" + "result": { + "id": "minecraft:yellow_shulker_box" + } } \ No newline at end of file diff --git a/data/minecraft/structure/ancient_city/city/entrance/entrance_connector.nbt b/data/minecraft/structure/ancient_city/city/entrance/entrance_connector.nbt index 86f0f9d2..a9bc2879 100644 --- a/data/minecraft/structure/ancient_city/city/entrance/entrance_connector.nbt +++ b/data/minecraft/structure/ancient_city/city/entrance/entrance_connector.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:823a2ddb5e368e114803eb9f00b0cb74d1882b776034a385f6884ea3af0a8ce7 -size 9415 +oid sha256:ee0fa7b8b4176657971c4f905da4854be8315a285b69ee5c31cfd5808d8f80fd +size 9417 diff --git a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_1.nbt b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_1.nbt index 365d5e3d..07cb40ba 100644 --- a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_1.nbt +++ b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:23ccd853597bb2375e0149e4651b549d11e7ce8a96aaa5a1ff67b3ce177d0887 -size 9751 +oid sha256:0d3f4d080ff2c90cdee9d7db9c1776821c67992e44e399a0972b2c49f7c73329 +size 9752 diff --git a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_2.nbt b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_2.nbt index a354ae22..3352274f 100644 --- a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_2.nbt +++ b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2e9cda58ad4bc88670d5962661c7903a57839e721e60e8518b6836d5e16d4b8a -size 13777 +oid sha256:0f6f566b21bf3654b87ad476a5541c4b63120874a782d0bad2507843b70b9336 +size 13778 diff --git a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_3.nbt b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_3.nbt index 544bec90..3ad59a96 100644 --- a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_3.nbt +++ b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f2ba2b3c69ae0de97d818e8b61a8246e62aeaab7a9fc21a7b527296715b1a54 -size 12152 +oid sha256:5f238dd1a12be504f21ae653d64312fbd4371541b0a6d94861ed6729839b17d4 +size 12154 diff --git a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_4.nbt b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_4.nbt index 6e46196f..0654fedb 100644 --- a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_4.nbt +++ b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fdb71e2d694c1292f55735046ae0c11e47707657307a62d8c6b46400b2a66ca6 -size 11786 +oid sha256:7039093b5f35dfee9cd932bbea02681bceeeb0f8578ff90d184f559964ca2906 +size 11789 diff --git a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_5.nbt b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_5.nbt index 67e4bf3e..1c7de10a 100644 --- a/data/minecraft/structure/ancient_city/city/entrance/entrance_path_5.nbt +++ b/data/minecraft/structure/ancient_city/city/entrance/entrance_path_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0d82b042122ae4a5d98274e1233580ce155f211b1d9db12d5674a0fdd6fbd112 -size 9067 +oid sha256:fc2c03b145ef26c7ec0852cb5cf44ce5e4bf8836824c015e16f63c8f40029cc6 +size 9069 diff --git a/data/minecraft/structure/ancient_city/city_center/city_center_1.nbt b/data/minecraft/structure/ancient_city/city_center/city_center_1.nbt index 1058dd3e..facc54fe 100644 --- a/data/minecraft/structure/ancient_city/city_center/city_center_1.nbt +++ b/data/minecraft/structure/ancient_city/city_center/city_center_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7888e4014fb4d51e7658958426d7d8f9490b15e257c8f9a4cd0ddb8f0ed3e751 -size 26259 +oid sha256:8c723283f0cb821497dc9d8d1c811378544e101106ef3453b0a445b3337a4467 +size 26261 diff --git a/data/minecraft/structure/ancient_city/city_center/city_center_2.nbt b/data/minecraft/structure/ancient_city/city_center/city_center_2.nbt index dd0aacc8..35b38b5a 100644 --- a/data/minecraft/structure/ancient_city/city_center/city_center_2.nbt +++ b/data/minecraft/structure/ancient_city/city_center/city_center_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:959d03cb955e168dc3c875bf0df55332f6075b3422c4cfb0d0d6b030d23d3c59 -size 26676 +oid sha256:33635c52b80ca60a97fafab1bc56fc22194ca44139d3b7ba87404382ce57692d +size 26678 diff --git a/data/minecraft/structure/ancient_city/city_center/city_center_3.nbt b/data/minecraft/structure/ancient_city/city_center/city_center_3.nbt index 92c7db22..b4ad2168 100644 --- a/data/minecraft/structure/ancient_city/city_center/city_center_3.nbt +++ b/data/minecraft/structure/ancient_city/city_center/city_center_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:92d00cec6098df181975d7422721150a47356564fdcf677255848d421560aa4e +oid sha256:e366f629275c98646f9a8375bc3db96d1201785c077d372e552bcb7d9fd05ace size 26122 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/bottom_1.nbt b/data/minecraft/structure/ancient_city/city_center/walls/bottom_1.nbt index 7299a5f7..9a5fad52 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/bottom_1.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/bottom_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f3d4e77e601cf2918da46d66833d39f4278d1f362f3672724698332d3f2a7e1f -size 7472 +oid sha256:69e52e8e99199837dd980e3df61093cf1fe86941a6ba171c449b9c7bd7bdba4e +size 7473 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/bottom_2.nbt b/data/minecraft/structure/ancient_city/city_center/walls/bottom_2.nbt index 448c0cbc..a7b19e1f 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/bottom_2.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/bottom_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:40d66aab8b7e975f2d704938ebf8452c05daf3d8117328cb50c6f27729e5fb1e -size 7001 +oid sha256:94078cabc273db04ab20b5e65c275d213e720ee97af16e0eeb527b87f7b1806b +size 7002 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/bottom_left_corner.nbt b/data/minecraft/structure/ancient_city/city_center/walls/bottom_left_corner.nbt index fa856088..50f484f5 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/bottom_left_corner.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/bottom_left_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d121001109f2dae19085e98d04d15b57f6f441fc2ee67e33b2736a81887c928a -size 2611 +oid sha256:f9133f57d994d4af77538bf371c37ac3bc04b181ba671a7a936c4efd26609ad6 +size 2612 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner.nbt b/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner.nbt index 82ef139c..80f9a382 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:110f413260a34b9379cfd2dd0ba610a075ca35e9aab43ead965d4428bc189ef2 -size 3047 +oid sha256:8ce289950d788eac13a9cc58adaf61ef1580f2b7beb1261ccfa9be6a63590613 +size 3048 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner_1.nbt b/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner_1.nbt index 3fa8f597..96e8fd69 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner_1.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:779b296455f9e918a378e2a38fa8b7090176bf971abe6738c51f4ead019dd719 -size 2596 +oid sha256:eba3507d4d5b4bae4fc583c8c06b22fc0202f2a097631c87ae18f6c9c428618d +size 2597 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner_2.nbt b/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner_2.nbt index 7ae5a889..28c3eed5 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner_2.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/bottom_right_corner_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:90d23d66e97e5c01106b1e52342fbe387da700a83e043e4cb2e2591f7b2aadcd -size 2667 +oid sha256:ed6dc2edad44446959f52f6d3ceba5f8d48fae950292c40e7094999a56cb5836 +size 2668 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/left.nbt b/data/minecraft/structure/ancient_city/city_center/walls/left.nbt index c6f37bb7..003cd6b6 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/left.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/left.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:18c2bcd95cd325ff0b9276d4a77d62c9e43c48a28e873e7f2a9c98695b227484 -size 3182 +oid sha256:4fe65739864227b640fa28a720ef415f53258410c8037da3d77f6add16c35175 +size 3183 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/right.nbt b/data/minecraft/structure/ancient_city/city_center/walls/right.nbt index dc40ea08..cca00da8 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/right.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/right.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b6f7f0b11946c9e4c6096bc3db6b7272dd09da0fdba3c7488dc609322277b2db -size 3177 +oid sha256:6f48ddb70a8c75e76f1cc17cc27c283649aa85bce35c5003054deeb58b90a9dd +size 3178 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/top.nbt b/data/minecraft/structure/ancient_city/city_center/walls/top.nbt index bcc21300..e1fdf2ca 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/top.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/top.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:45abba184f9e7f9b5c923324ede9540fd4d13fac2e947a9516c772269028b9a1 -size 7118 +oid sha256:4eac1799b7c8ce71a121e2f473d974576805b8cca517fbf4d7f1957e4c837b6b +size 7120 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/top_left_corner.nbt b/data/minecraft/structure/ancient_city/city_center/walls/top_left_corner.nbt index 43249bdb..8a23f92a 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/top_left_corner.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/top_left_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fca0d27b58c083ab8cee3fe03998653f32e7ae76ee88df383fafc31f8405bd90 -size 2597 +oid sha256:8b96c6f181847d5f7b64fd460607c1bdc4e0e7be9b5d83ab0fd25ee1fadb71ce +size 2598 diff --git a/data/minecraft/structure/ancient_city/city_center/walls/top_right_corner.nbt b/data/minecraft/structure/ancient_city/city_center/walls/top_right_corner.nbt index 9f6a0969..11f824c5 100644 --- a/data/minecraft/structure/ancient_city/city_center/walls/top_right_corner.nbt +++ b/data/minecraft/structure/ancient_city/city_center/walls/top_right_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3963266d7580b9b7ac675ce300c9d35a751916b1b5ea97e84a5b2333c8742689 -size 2643 +oid sha256:fb052e8d20aea7b2deca6296d26e0e229c2d4b3c23e7fbd60d0a29d9fbdc5c0e +size 2644 diff --git a/data/minecraft/structure/ancient_city/structures/barracks.nbt b/data/minecraft/structure/ancient_city/structures/barracks.nbt index a5afa272..7f8ff304 100644 --- a/data/minecraft/structure/ancient_city/structures/barracks.nbt +++ b/data/minecraft/structure/ancient_city/structures/barracks.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d5af96d34a63407cbdda0cd0c8c2b878899d8e944cc054e852e4353cb8a75aaa -size 5633 +oid sha256:4540518c61767941fe1c924f092263c2803e276826adcdad8e4dcd0c31365af8 +size 5634 diff --git a/data/minecraft/structure/ancient_city/structures/camp_1.nbt b/data/minecraft/structure/ancient_city/structures/camp_1.nbt index 4e37d284..f80bde0d 100644 --- a/data/minecraft/structure/ancient_city/structures/camp_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/camp_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f8003cdb17ec3537ddb74b46408a763626d5ad284b5aa6419a11ee7dfd1a10b9 +oid sha256:f5c527e9ae11f095e46e4bf9ff75ff21cedbdedf691a395ce428a7f7f4bc7213 size 1165 diff --git a/data/minecraft/structure/ancient_city/structures/camp_2.nbt b/data/minecraft/structure/ancient_city/structures/camp_2.nbt index 3031ce22..a74deaed 100644 --- a/data/minecraft/structure/ancient_city/structures/camp_2.nbt +++ b/data/minecraft/structure/ancient_city/structures/camp_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d9b646e951eb83117f052add8f5dac4b007411d9bb7e74975469403100b505ac -size 1272 +oid sha256:effa8ed94fa63e5d4a7ab478aa046909ccc6018a58e4b85fbee326781fd56178 +size 1274 diff --git a/data/minecraft/structure/ancient_city/structures/camp_3.nbt b/data/minecraft/structure/ancient_city/structures/camp_3.nbt index 18266861..3b756bc9 100644 --- a/data/minecraft/structure/ancient_city/structures/camp_3.nbt +++ b/data/minecraft/structure/ancient_city/structures/camp_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:23eb7c40bee473fac6dba13a2eeab1afd956b3eb09a133e9ff79959874e5642d -size 1015 +oid sha256:8ece7845e9cd5a24a189ca02b86f530fdc09ac860ec6e76d8c0dcdcfba60bfc4 +size 1017 diff --git a/data/minecraft/structure/ancient_city/structures/chamber_1.nbt b/data/minecraft/structure/ancient_city/structures/chamber_1.nbt index bbc3562f..c5478d04 100644 --- a/data/minecraft/structure/ancient_city/structures/chamber_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/chamber_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6e3dc78b5240f1298a2372b40f7db47663f058c3ccaf9794faaf3d25b2819dd6 -size 2535 +oid sha256:a43ad780063fb51a93ba8eb678ed2986baad6d37ec09f63fb1a8577bffcf151b +size 2536 diff --git a/data/minecraft/structure/ancient_city/structures/chamber_2.nbt b/data/minecraft/structure/ancient_city/structures/chamber_2.nbt index 32cedc94..3a13e502 100644 --- a/data/minecraft/structure/ancient_city/structures/chamber_2.nbt +++ b/data/minecraft/structure/ancient_city/structures/chamber_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:030e087e477f453eda22bbd5d84063e0912f8b18b7680e2727e6c3a80915d60a -size 1311 +oid sha256:01c4f5766ea37568f343de8a6a55f8c4bd3ee124998cd43b28bd8a3b204ac420 +size 1312 diff --git a/data/minecraft/structure/ancient_city/structures/chamber_3.nbt b/data/minecraft/structure/ancient_city/structures/chamber_3.nbt index be9b4d4c..d22455bf 100644 --- a/data/minecraft/structure/ancient_city/structures/chamber_3.nbt +++ b/data/minecraft/structure/ancient_city/structures/chamber_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:37824bdcb8647628a786cf8dcc298b5c4c06659f47e95442c543b56cc75eed54 -size 1100 +oid sha256:0d91d870ef88b2819562405aa9feb5a20565a28c59c93d112c76ea638e470269 +size 1101 diff --git a/data/minecraft/structure/ancient_city/structures/ice_box_1.nbt b/data/minecraft/structure/ancient_city/structures/ice_box_1.nbt index 08ce1d22..854fe2e4 100644 --- a/data/minecraft/structure/ancient_city/structures/ice_box_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/ice_box_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dc9a8e771975d02d23c7400134b40c4dc4b4447bd49585bbad4ac04e3f1e2fe2 -size 3907 +oid sha256:c043032b6920fd60cefe64b27cbb72647a5a03a2cccb5a9caa3ca6b6cafd0f3a +size 3908 diff --git a/data/minecraft/structure/ancient_city/structures/large_pillar_1.nbt b/data/minecraft/structure/ancient_city/structures/large_pillar_1.nbt index b823e326..91b01d60 100644 --- a/data/minecraft/structure/ancient_city/structures/large_pillar_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/large_pillar_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:565d4d0b7f0ffa8ca23c47bae9dfd6f8a947fafbfc95ec2b0494f010149eafe9 -size 1476 +oid sha256:1a44ffc00cde5b80a27eae33851f193780aee51f6840e23f399457656815455f +size 1477 diff --git a/data/minecraft/structure/ancient_city/structures/large_ruin_1.nbt b/data/minecraft/structure/ancient_city/structures/large_ruin_1.nbt index ed442200..45c4c461 100644 --- a/data/minecraft/structure/ancient_city/structures/large_ruin_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/large_ruin_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:70f64505d423d3c319042df588098733437b3a3c356054ce075476e0a7482dcc -size 396 +oid sha256:933c4ad7dace77403e7d1f89f24d5df2a08dd481c1cc25441e158f01e7c2beea +size 398 diff --git a/data/minecraft/structure/ancient_city/structures/medium_pillar_1.nbt b/data/minecraft/structure/ancient_city/structures/medium_pillar_1.nbt index 88a7ad23..d9269d15 100644 --- a/data/minecraft/structure/ancient_city/structures/medium_pillar_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/medium_pillar_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:36100fcfcdeacd91142d1a393f8a32aaece692d677d2537853f057670c65f144 -size 959 +oid sha256:56fc7422345bab3ce32eea7b615ef9f290a290233cc5a25d2456b87b5f8941ff +size 960 diff --git a/data/minecraft/structure/ancient_city/structures/medium_ruin_1.nbt b/data/minecraft/structure/ancient_city/structures/medium_ruin_1.nbt index 62d9fe0e..c3d71a82 100644 --- a/data/minecraft/structure/ancient_city/structures/medium_ruin_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/medium_ruin_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4b8e5f8dcf2a4a25d0fcd142da9e8c8dedd9b9dd90b8d605d8a7c715cea832dd -size 326 +oid sha256:6b5acdfebc43a1b35a2e9d55724cd1dbfa286a6980c02cffd7856771616f975c +size 327 diff --git a/data/minecraft/structure/ancient_city/structures/medium_ruin_2.nbt b/data/minecraft/structure/ancient_city/structures/medium_ruin_2.nbt index a264ed81..d8191e8c 100644 --- a/data/minecraft/structure/ancient_city/structures/medium_ruin_2.nbt +++ b/data/minecraft/structure/ancient_city/structures/medium_ruin_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:993099d30a0a7465910e56242c1b26188d41895a881d9a3342a3580b3a29a2ce -size 352 +oid sha256:eda44c0455b4c1ee349285749a95ecf7104c08c9261c56dbf94b3048cd4ee85d +size 353 diff --git a/data/minecraft/structure/ancient_city/structures/sauna_1.nbt b/data/minecraft/structure/ancient_city/structures/sauna_1.nbt index cc03323c..5241bfb2 100644 --- a/data/minecraft/structure/ancient_city/structures/sauna_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/sauna_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:77d0a4ebe772d2528cc4ab35d2a75133ff7549b6c5c3ee31c25556ca0979139d -size 6957 +oid sha256:769a317936314d2fc3472b6c75b04a77e665b2115426a7b20c5ab3271315e7d3 +size 6958 diff --git a/data/minecraft/structure/ancient_city/structures/small_ruin_1.nbt b/data/minecraft/structure/ancient_city/structures/small_ruin_1.nbt index fba30423..8183c597 100644 --- a/data/minecraft/structure/ancient_city/structures/small_ruin_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/small_ruin_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e344cab82a07330f7a98656f4046215561a64b0a8713f5a38ff4efc65a80bbf -size 313 +oid sha256:15cc556b3d3b875d177af3791ad566a32aa1254e2e6380102845826c1b8ce35f +size 315 diff --git a/data/minecraft/structure/ancient_city/structures/small_ruin_2.nbt b/data/minecraft/structure/ancient_city/structures/small_ruin_2.nbt index cb734849..b9170f29 100644 --- a/data/minecraft/structure/ancient_city/structures/small_ruin_2.nbt +++ b/data/minecraft/structure/ancient_city/structures/small_ruin_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4ee5235f0959a3c8b23e093569b33bae8dfdfb46c58393b9029503af18a6eca4 -size 309 +oid sha256:4243646a68fea4468eb66e19551cd501d6ae9ed208cf3d6c4f28354b811b1cfd +size 310 diff --git a/data/minecraft/structure/ancient_city/structures/small_statue.nbt b/data/minecraft/structure/ancient_city/structures/small_statue.nbt index 2b2e4be1..11c21100 100644 --- a/data/minecraft/structure/ancient_city/structures/small_statue.nbt +++ b/data/minecraft/structure/ancient_city/structures/small_statue.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6ce98efd5acb5c2c3a83b4df2fc656825b5b27bb96cd558f393682f078538bc1 -size 891 +oid sha256:25556cf041678538a187a71e45c4fdf22bd53e1b798c33e5a78b300942878497 +size 893 diff --git a/data/minecraft/structure/ancient_city/structures/tall_ruin_1.nbt b/data/minecraft/structure/ancient_city/structures/tall_ruin_1.nbt index 46c2ab7d..c6a5dfa1 100644 --- a/data/minecraft/structure/ancient_city/structures/tall_ruin_1.nbt +++ b/data/minecraft/structure/ancient_city/structures/tall_ruin_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:02b23969284d1b223290dfb8f0c82116f611d2bd32795d21a710a6625f9f4fb1 -size 2792 +oid sha256:25be6dfe191366da2087f4f068263298fe6d33f01bc55f9c2a82df5c54f01b10 +size 2794 diff --git a/data/minecraft/structure/ancient_city/structures/tall_ruin_2.nbt b/data/minecraft/structure/ancient_city/structures/tall_ruin_2.nbt index d521a1f2..4fe47d41 100644 --- a/data/minecraft/structure/ancient_city/structures/tall_ruin_2.nbt +++ b/data/minecraft/structure/ancient_city/structures/tall_ruin_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:96794e34297fdbb76273ecb69e7f6f28e0cc370ae2426d40109183c43533ce58 -size 3486 +oid sha256:ce6c30cf98a73caee2ee358000e4e1dbbee45c4387365c40073538d0800edaa3 +size 3487 diff --git a/data/minecraft/structure/ancient_city/structures/tall_ruin_3.nbt b/data/minecraft/structure/ancient_city/structures/tall_ruin_3.nbt index 6fdc4f18..8636ce09 100644 --- a/data/minecraft/structure/ancient_city/structures/tall_ruin_3.nbt +++ b/data/minecraft/structure/ancient_city/structures/tall_ruin_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bd2dcd6cc9e4283d5ab6729586b2d6d8da4481e56ae133aa633c14cb8069dd8d -size 1521 +oid sha256:7cfcb7276ba2ca080e2d9d7f716b0cd6b97108459b11e1aa2e937256115e9e34 +size 1523 diff --git a/data/minecraft/structure/ancient_city/structures/tall_ruin_4.nbt b/data/minecraft/structure/ancient_city/structures/tall_ruin_4.nbt index af36eebc..7e868b52 100644 --- a/data/minecraft/structure/ancient_city/structures/tall_ruin_4.nbt +++ b/data/minecraft/structure/ancient_city/structures/tall_ruin_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c580d8648d523a919fff9458595f45f0ff586ba44a9c5593d44861b5791384f1 -size 2295 +oid sha256:534afbf9e58d128c06d7fa80a4998188a7a4219197d57f6ca6b143179e9c3c99 +size 2297 diff --git a/data/minecraft/structure/ancient_city/walls/intact_corner_wall_1.nbt b/data/minecraft/structure/ancient_city/walls/intact_corner_wall_1.nbt index fd381614..cc40f206 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_corner_wall_1.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_corner_wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:eabc111d53b090bc74f3bab6374f1ae9554b765f6573ab74a19765bd942329cd -size 3836 +oid sha256:2b5ff101dcb81871374ab581da95de2a58360d72cfd9246795bfb384d8694106 +size 3838 diff --git a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_1.nbt b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_1.nbt index de1f83eb..7acf762b 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_1.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f66497a243142ac646617d69e9b397a32285febd3084b637eef6fbc6695c5947 -size 2026 +oid sha256:531cf18f6b1ee9813bddc0fbd399a33819f4a393163b0a051f9a5662479fcaaa +size 2027 diff --git a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_2.nbt b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_2.nbt index 00a37005..b7fadaf1 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_2.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3428ba502df1144e517fb6190b71257ba6d6c32fd1106fb3a66dfc96ed4ddff0 -size 2006 +oid sha256:eb3bc45f5e95603c51a8bd4f6e12311a633e8b5dc8b828804b1a9bf47869e2d8 +size 2007 diff --git a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_bridge.nbt b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_bridge.nbt index cfe873cd..d991df7a 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_bridge.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_bridge.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:712886bddcbafc3e900ed2c0f1d4f8b3ac288689409d7be1e70fbb8541c8bad3 -size 2720 +oid sha256:819864325016eb3fcc00922ecc89e2c297f9d3b373208419a7247b689ca2a891 +size 2721 diff --git a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_passage_1.nbt b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_passage_1.nbt index c050b982..7369bf9a 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_passage_1.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_passage_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c8a4428a6367611f5ad78672a6b40246cfe69bd09231694f4a730cfb5b316105 -size 1661 +oid sha256:54502f7825dcc976b930f8f647b4ae5d08819aefe3bc100731b513b184483a20 +size 1662 diff --git a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_1.nbt b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_1.nbt index 42b0ab8a..2a5a3a43 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_1.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:147e37200643d8357fcd2c0ad07f88f3a92f0bf1e4dba40c447450648f822425 -size 2118 +oid sha256:52f8b193f0ff952d07330c06bc06ebb53dcafa05fb1c770d299eb7ca6b83fbd0 +size 2119 diff --git a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_2.nbt b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_2.nbt index 6274ed1c..ec85d51f 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_2.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:241d38f5ee0ecafe53882a664370bb8b6bcd219336e56dcc142d996c64876ae6 -size 2169 +oid sha256:3ccd3bfd8bd429aeb0c3659003fe857deb5827be30706a200429d9d3cd5697e9 +size 2170 diff --git a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_3.nbt b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_3.nbt index 3e001718..d8d74606 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_3.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:16da322f96373ce4a50adbcf06971d9af7b8abe33d91ac470b1c29e2d7d9fa62 -size 2155 +oid sha256:439dc54d299e2e4f31809bdd401167174f653bb3c0575d8219a46fd3a5dfb52a +size 2157 diff --git a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_4.nbt b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_4.nbt index c143c257..3f356226 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_4.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_horizontal_wall_stairs_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6ac835ec10951c46390f79dc0549e6bd1044c59ff4ab784ca4d5de1e3f50a31c -size 2054 +oid sha256:c4e827dc73e13ce87640842a91eb0c82564eea2f64e775ddb1ea1ecf818f8af5 +size 2055 diff --git a/data/minecraft/structure/ancient_city/walls/intact_intersection_wall_1.nbt b/data/minecraft/structure/ancient_city/walls/intact_intersection_wall_1.nbt index f877a20f..a4d776af 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_intersection_wall_1.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_intersection_wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d37b7ae5be0b8286bb4c1143e27198979563ba3495de83133a82a5116a5ca830 -size 3125 +oid sha256:63edbc16982c730a2251699361dd11288476ccdb740237ac06c82fb7cbc36ffa +size 3126 diff --git a/data/minecraft/structure/ancient_city/walls/intact_lshape_wall_1.nbt b/data/minecraft/structure/ancient_city/walls/intact_lshape_wall_1.nbt index 33e7d458..32aeaba8 100644 --- a/data/minecraft/structure/ancient_city/walls/intact_lshape_wall_1.nbt +++ b/data/minecraft/structure/ancient_city/walls/intact_lshape_wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f7eece610e12114fa5beb4f051bc3cb77e2db5589496caa7a5c92a5b48cb049b -size 2383 +oid sha256:2289f0fa7d4be96cd905d62cdc514f9dda407697375c8dfff3e31eb0346de1b1 +size 2385 diff --git a/data/minecraft/structure/ancient_city/walls/ruined_corner_wall_1.nbt b/data/minecraft/structure/ancient_city/walls/ruined_corner_wall_1.nbt index 1761b583..5be6a7e6 100644 --- a/data/minecraft/structure/ancient_city/walls/ruined_corner_wall_1.nbt +++ b/data/minecraft/structure/ancient_city/walls/ruined_corner_wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:71325405b85062af94c9fd5379ff27aa85ca8b8eac21c3131ad99ea6e34f23d0 -size 4170 +oid sha256:dde81b0f18792cfef86a856e64a7c791e6c734280cd4083f0fa047c014be53e7 +size 4171 diff --git a/data/minecraft/structure/ancient_city/walls/ruined_corner_wall_2.nbt b/data/minecraft/structure/ancient_city/walls/ruined_corner_wall_2.nbt index 5c771c88..53524066 100644 --- a/data/minecraft/structure/ancient_city/walls/ruined_corner_wall_2.nbt +++ b/data/minecraft/structure/ancient_city/walls/ruined_corner_wall_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f76fbe15d8e318652e7febcb58d0b5b45c1de7eb6b8e25f88cb5440f2ecc219c -size 3303 +oid sha256:b7e2f13d7560e7de1183bc206da8eba8a8991f4ae05f28af74cf0c404e37429a +size 3305 diff --git a/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_1.nbt b/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_1.nbt index fc44a370..735e5d40 100644 --- a/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_1.nbt +++ b/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ffc5dcf7ec1c300a2523d0f29b8a4aeb75e3ae3cb96bad90e4b3116d28397083 -size 1490 +oid sha256:f83b84c0f10f1a548c8345c0c57b3919398da8a58b332ed04b2824fe4b7b2a5a +size 1491 diff --git a/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_2.nbt b/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_2.nbt index 00745f63..5502f0f0 100644 --- a/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_2.nbt +++ b/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4db621a08f95bf214bf7588b9f531e785d76b4c62a76610894eb63dd0b6c0ed6 -size 1975 +oid sha256:9ff1e2c5ad32d4ee6213e0efc611846a21ab9354b5d63176ccea4c0c06cb29c7 +size 1976 diff --git a/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_3.nbt b/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_3.nbt index b69d92df..f2f12aad 100644 --- a/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_3.nbt +++ b/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bac72a124f2ce911b7f3b4bebf53c721516eac3909e46bda7166664557b02694 -size 1385 +oid sha256:26f8477e011b1a47d91d4f476775edad99f985d12f6097266224a6378c93e33e +size 1386 diff --git a/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_4.nbt b/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_4.nbt index d56eb8e0..23d3eb21 100644 --- a/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_4.nbt +++ b/data/minecraft/structure/ancient_city/walls/ruined_horizontal_wall_stairs_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4eea175b6d53251c83b8e3dd72757b0262e980a7e95d086fdd2854c7cba49c82 -size 1340 +oid sha256:3680337be9682818cd0065ac2180036e99108ee59b04fb21d5a748735ea3be08 +size 1341 diff --git a/data/minecraft/structure/bastion/blocks/air.nbt b/data/minecraft/structure/bastion/blocks/air.nbt index 907f6a9b..2bed24fe 100644 --- a/data/minecraft/structure/bastion/blocks/air.nbt +++ b/data/minecraft/structure/bastion/blocks/air.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f93c8a32c888d484f07de30eff54c1bcf74f6e2f878591c776553132045fcc4d -size 227 +oid sha256:1aec5b7ac1036bca3095a6975dc372ac40e090d676fe44283e1486a66a371d11 +size 228 diff --git a/data/minecraft/structure/bastion/blocks/gold.nbt b/data/minecraft/structure/bastion/blocks/gold.nbt index 5f6cd50c..1730f3e7 100644 --- a/data/minecraft/structure/bastion/blocks/gold.nbt +++ b/data/minecraft/structure/bastion/blocks/gold.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:24c908fa0fd8544936d230e44c2f169b2bc0cf91b8dcf580d5adb10d6c6ca6d9 -size 232 +oid sha256:0ac4e8087eb0c2fcb63b270b39d47693c16b2dbe155eaaa641fa4cdf392c4912 +size 233 diff --git a/data/minecraft/structure/bastion/bridge/bridge_pieces/bridge.nbt b/data/minecraft/structure/bastion/bridge/bridge_pieces/bridge.nbt index 85191df6..deea80bd 100644 --- a/data/minecraft/structure/bastion/bridge/bridge_pieces/bridge.nbt +++ b/data/minecraft/structure/bastion/bridge/bridge_pieces/bridge.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3e5aa0d91aa215e5ac912cd1db54d9a6f593857dc9c2367abbbb97fd9061e69f -size 15685 +oid sha256:0b4908a2f3a45e6ea97ed3da3a8eed53264ff45c1719231bbfaf1d92ec94b9df +size 15687 diff --git a/data/minecraft/structure/bastion/bridge/connectors/back_bridge_bottom.nbt b/data/minecraft/structure/bastion/bridge/connectors/back_bridge_bottom.nbt index 7f9fb78d..e7877511 100644 --- a/data/minecraft/structure/bastion/bridge/connectors/back_bridge_bottom.nbt +++ b/data/minecraft/structure/bastion/bridge/connectors/back_bridge_bottom.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d073fa65a473d8527e05a17dd2b2b9b74b77d37ccd6533a833638f41c50d2d02 -size 1427 +oid sha256:9dfeeb903aa1eac05f3d4eb460a8d8fcd5bd5a7777280752f1503d593e92d4be +size 1428 diff --git a/data/minecraft/structure/bastion/bridge/connectors/back_bridge_top.nbt b/data/minecraft/structure/bastion/bridge/connectors/back_bridge_top.nbt index fd492a03..341a09bb 100644 --- a/data/minecraft/structure/bastion/bridge/connectors/back_bridge_top.nbt +++ b/data/minecraft/structure/bastion/bridge/connectors/back_bridge_top.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:966450b0ffe023b78498a2195aa758c37d9d29d6a76e27d088eb95a80e0aa09f -size 1374 +oid sha256:fa6491fcc720d767cbe2f34b71eef992aa1bd45fd711d5f6244290423ec92151 +size 1375 diff --git a/data/minecraft/structure/bastion/bridge/legs/leg_0.nbt b/data/minecraft/structure/bastion/bridge/legs/leg_0.nbt index abca39ee..3316a67f 100644 --- a/data/minecraft/structure/bastion/bridge/legs/leg_0.nbt +++ b/data/minecraft/structure/bastion/bridge/legs/leg_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4b823385d7a57a63490b7f77edfd9c15c15307fa3cbc3f937925ceb7b99cb446 -size 707 +oid sha256:a57d734a88735370dcf3eb568a60f58b6a598020090d57c45013b6034a8bc055 +size 708 diff --git a/data/minecraft/structure/bastion/bridge/legs/leg_1.nbt b/data/minecraft/structure/bastion/bridge/legs/leg_1.nbt index ac63f8eb..658088e9 100644 --- a/data/minecraft/structure/bastion/bridge/legs/leg_1.nbt +++ b/data/minecraft/structure/bastion/bridge/legs/leg_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:61e39169fbaca13f6773e936a5c518c7b5fd301c00013277927a9b616191548d -size 738 +oid sha256:dd95099df065bebccc53cf3ac48f3e45a3630167480a9ea292b77626d7b3552e +size 739 diff --git a/data/minecraft/structure/bastion/bridge/rampart_plates/plate_0.nbt b/data/minecraft/structure/bastion/bridge/rampart_plates/plate_0.nbt index e05399f8..675ebc3f 100644 --- a/data/minecraft/structure/bastion/bridge/rampart_plates/plate_0.nbt +++ b/data/minecraft/structure/bastion/bridge/rampart_plates/plate_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ba9025b662e686e754a5ef05510fee4e6694722d86cf7d2ebbef57e7c1541d4d -size 2054 +oid sha256:a7aa884769bff6ac1b5de04fe5becb2b1e8945bf16f8a380670abb4f7eee0167 +size 2055 diff --git a/data/minecraft/structure/bastion/bridge/ramparts/rampart_0.nbt b/data/minecraft/structure/bastion/bridge/ramparts/rampart_0.nbt index be99a47e..b5afe57b 100644 --- a/data/minecraft/structure/bastion/bridge/ramparts/rampart_0.nbt +++ b/data/minecraft/structure/bastion/bridge/ramparts/rampart_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e8873d1c06400ba3c8cbb87a0a9dddfe8ae09758a004d59b221df88b8606d329 -size 12578 +oid sha256:938ac11c4528667884f3627a126f1f7619ba00e1f53dae3b21a88506bad8f8b0 +size 12580 diff --git a/data/minecraft/structure/bastion/bridge/ramparts/rampart_1.nbt b/data/minecraft/structure/bastion/bridge/ramparts/rampart_1.nbt index f1e30c10..67c5419b 100644 --- a/data/minecraft/structure/bastion/bridge/ramparts/rampart_1.nbt +++ b/data/minecraft/structure/bastion/bridge/ramparts/rampart_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d643b43cb6d0d91b8a083578ee4f44b4f9c7ce86fb1d043bfaaeba0a7d8830e6 -size 19409 +oid sha256:3be3273a36689907eda363401de27947579bd1ed0f723e53ac8eb14984ea1445 +size 19410 diff --git a/data/minecraft/structure/bastion/bridge/starting_pieces/entrance.nbt b/data/minecraft/structure/bastion/bridge/starting_pieces/entrance.nbt index 15c34221..6eb4f19a 100644 --- a/data/minecraft/structure/bastion/bridge/starting_pieces/entrance.nbt +++ b/data/minecraft/structure/bastion/bridge/starting_pieces/entrance.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c37a2d1c63b54f5c9cdbc5a7f607973c8243932347c98bd0ddc65ece018215e9 -size 41137 +oid sha256:d730d1eaafd8d59168e579879862ee5054fd04093004aa0519f322c21df4b020 +size 41138 diff --git a/data/minecraft/structure/bastion/bridge/starting_pieces/entrance_base.nbt b/data/minecraft/structure/bastion/bridge/starting_pieces/entrance_base.nbt index 40641c18..b9e3a413 100644 --- a/data/minecraft/structure/bastion/bridge/starting_pieces/entrance_base.nbt +++ b/data/minecraft/structure/bastion/bridge/starting_pieces/entrance_base.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0caef26a9caf79a80ce0cb3aef2f8310cb3266cadb6555290bd42c912408a8f9 -size 45584 +oid sha256:f8b0760a6afd42907831f52d2063940d14e193e01dd51f932f369aa905b05840 +size 45585 diff --git a/data/minecraft/structure/bastion/bridge/starting_pieces/entrance_face.nbt b/data/minecraft/structure/bastion/bridge/starting_pieces/entrance_face.nbt index 7ca65598..47002ff9 100644 --- a/data/minecraft/structure/bastion/bridge/starting_pieces/entrance_face.nbt +++ b/data/minecraft/structure/bastion/bridge/starting_pieces/entrance_face.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:79b66892610d47f1f5ba0dc8cf33b0909f02436450c3164e11c2fa6fa95c8853 -size 2738 +oid sha256:21e79f03ed40b160bf83bb327b925dbb0891699ff9dfb75258a8b2997a7a1879 +size 2739 diff --git a/data/minecraft/structure/bastion/bridge/walls/wall_base_0.nbt b/data/minecraft/structure/bastion/bridge/walls/wall_base_0.nbt index d4d93b45..f77143b2 100644 --- a/data/minecraft/structure/bastion/bridge/walls/wall_base_0.nbt +++ b/data/minecraft/structure/bastion/bridge/walls/wall_base_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9c81199788d107781377b9b8a302a576c09bf295d52eac85e550405a61039fbe -size 17431 +oid sha256:1af548531081e5e3cea7efc6529e8a64c0bacd546a185ee4d01c0e8815b8bc90 +size 17432 diff --git a/data/minecraft/structure/bastion/bridge/walls/wall_base_1.nbt b/data/minecraft/structure/bastion/bridge/walls/wall_base_1.nbt index ce1e6a17..95403bf7 100644 --- a/data/minecraft/structure/bastion/bridge/walls/wall_base_1.nbt +++ b/data/minecraft/structure/bastion/bridge/walls/wall_base_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:47024f55446364131e5d6eb770318895fb752ab2e5f5e15bdd66535bcd1ec052 -size 17258 +oid sha256:5a08d918ef900b4ccb80025f8be322a4c2e63f5f6fffbe97f934a340d7c9e290 +size 17260 diff --git a/data/minecraft/structure/bastion/hoglin_stable/air_base.nbt b/data/minecraft/structure/bastion/hoglin_stable/air_base.nbt index f5809011..6115e3f7 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/air_base.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/air_base.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:efb8bb5e956e15ff26259d68715388709464cc079f6c1a083ac06956e453f2c0 -size 80382 +oid sha256:96946897fb784ec66d70fc1c00ddaf102e1681aaaf28c2f2e06d3da00b9f7e66 +size 80384 diff --git a/data/minecraft/structure/bastion/hoglin_stable/connectors/end_post_connector.nbt b/data/minecraft/structure/bastion/hoglin_stable/connectors/end_post_connector.nbt index 270d1b38..ff8e698c 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/connectors/end_post_connector.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/connectors/end_post_connector.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d953cc73865962ff43dcddf3a7f95b538d0117242a1042601d9776922905804 -size 287 +oid sha256:14c2a5cb9967a2f98918a7f247f6bbafa6e6acbb0bf4bf35dcffc85f6205fa84 +size 288 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_0.nbt index c56d88c9..c0adfe98 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:965d2b5f052ffd2cf6e1a8cfc8e46eca08cf4b28fc9b585304788defe9e58832 -size 1878 +oid sha256:0a967416a384f024982424bf0f25cceb8c2eb944d4588e6ddcce6f6d9591eb25 +size 1880 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_1.nbt index 466b4b81..87a19724 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6822668bbafe03234691f5a805f9e84227ded17ab174277a1cbd3c3f5261a062 -size 2076 +oid sha256:5fbd152b7bb57393fed5d07b380c2be9d5d1c810ee4da45316f3497f6be4f4ff +size 2077 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_2.nbt index 958b82a4..590f3983 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8bb559721f41b8a7e3b8a294afaca2f677d9c0e55b4d7c2937ed1b251c57959d -size 2351 +oid sha256:267c2d75ad0e73e33c6d96bff79eb7fb2c19b21bf175fce7030d66c7beff9467 +size 2353 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_3.nbt index 0ede1cb2..75f98a25 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7bb74a77b458e8f10efc7e58e2fccbe541fefef89a9cc84bcc07f5ba934b6ebc -size 2398 +oid sha256:43caa18a6872b397cf064ecb508cda8c655439e0f9f86151e1c7e7e71ad553c3 +size 2400 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_4.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_4.nbt index 84733fc9..5741bd4e 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_4.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/inner_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5cd2a16e44dcc7146a9e4906096da63212e9de79fabb883507b57e02cca43374 -size 2145 +oid sha256:44facb69403ddc6bfc17c87962a2c7d662aad3bc82b8e9135944371d2faf7f67 +size 2146 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_0.nbt index 74067ec2..2348d78a 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fcfcf69a57c5df41e45aa49b552da830351c132d3f37c2b7f6e83bdc8bf30a2e -size 1964 +oid sha256:08b0dfdda697f8bb474efeb93b8c29680121bedfac210a3f3a9e193b105477f2 +size 1966 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_1.nbt index 52a7e263..31e95e0f 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6e049096dc2c2badfd6a74421e87993b165ba3403adab45c2c4cd6cdf32576ff -size 2317 +oid sha256:e9bc200f2875b204354373bf3bda1130655fcd1977db8f0f38b5f4f5c8a91f81 +size 2318 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_2.nbt index f6dd4e96..c521419a 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d6032f5a180e9a3cfdc116628f63d194160cc89c324f12242a713aa20d235b1 -size 2555 +oid sha256:4f8195e38abe39b55b69c9fce79bc52367064984b728d8428c0eff98c5ab20ec +size 2556 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_3.nbt index 3e2c8c71..4addf619 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1d1390d0c1e791a4894591c371c5e263bef7795f61c4609c6aad031a359c0029 -size 2452 +oid sha256:5f96c07847b57221f5590a505746426069a9dfc2b7ebef722cefba47176af982 +size 2454 diff --git a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_4.nbt b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_4.nbt index 3bc80d7a..6e42dba2 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_4.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/large_stables/outer_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4b5a24318c5af4f10e0fda5d76fb87552902cd47d802138186617582e2726a77 -size 2397 +oid sha256:30c3e550a47bc0bba15e935bc112fab9bd26d18ad55c1eb7c31ecbfd2f9d6dc4 +size 2398 diff --git a/data/minecraft/structure/bastion/hoglin_stable/posts/end_post.nbt b/data/minecraft/structure/bastion/hoglin_stable/posts/end_post.nbt index 9ef5a91a..47cb460b 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/posts/end_post.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/posts/end_post.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a178a297b471e47f0c3c4be0d821111631300bd089ff7c237af7a0f0eb54c6cb -size 529 +oid sha256:b1b63dbc4e20d8f12bef83cd4e65a294fa02bfcbaad7e0652922057779ad57e0 +size 530 diff --git a/data/minecraft/structure/bastion/hoglin_stable/posts/stair_post.nbt b/data/minecraft/structure/bastion/hoglin_stable/posts/stair_post.nbt index f041d8b9..559509a0 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/posts/stair_post.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/posts/stair_post.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dc16ed051b723069f74ad9ba08916f9244608c77dd976e39cf8ae56dc1cd7364 -size 1166 +oid sha256:9cd43fa2fbb0e511176849537170b53bac23d1ce55ae9ac4252fa96b172aaf3b +size 1168 diff --git a/data/minecraft/structure/bastion/hoglin_stable/rampart_plates/rampart_plate_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/rampart_plates/rampart_plate_1.nbt index 7ab29299..6e545c13 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/rampart_plates/rampart_plate_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/rampart_plates/rampart_plate_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:15620370087f39f218e995478c9c0c2aa1c6e713738ea3c11b5fce1ee86d4295 -size 2178 +oid sha256:6c761c3e03e102310ff5ff607a78199f56a192eaeb1eb596b203b3ac477d13ff +size 2179 diff --git a/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_1.nbt index 08f28c85..2751cb99 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c463accc6cd932fb065acdd1b2568b77de5ccabcbacb409a36d157785401a46 -size 19109 +oid sha256:347a18dbfed89ba1a1fddc8bb08d2a6067a85ae4b69e1f82e9cfe4d9b1cc7cd9 +size 19111 diff --git a/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_2.nbt index a8f92d1a..108300d5 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:06351642f0bb6371e869b5b57f159fe367a7ca46a47fb7edc9942779cee3e221 -size 12206 +oid sha256:ee01ef99955d6b60595c685e4664f4cf38780347506953b501bad67054ad7b86 +size 12208 diff --git a/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_3.nbt index 762b963d..a5e1ad90 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/ramparts/ramparts_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:297cf29156d466ae2220da61d10e70ed58ed5e7650a09d793774cafada726959 -size 6389 +oid sha256:cd0abd57fa5ef4353cc225c5dde9483c3124c12a0cfea0b3b537399c058e21d3 +size 6391 diff --git a/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_0.nbt index 8dcf66d0..74c9cf68 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1342f06cbe3b94bf78487c8ade45701a778ce5fc5c96c0aa3b575580addd8ae9 -size 1896 +oid sha256:f4a3fa82feeb51ae3cef85cdfba81ea1d77714f8a733ec82ab0985a66b37e75e +size 1898 diff --git a/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_1.nbt index 99d205fd..8e6e9bbf 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7e39f5a4788295c7dd89f4124c1e427f2b6344155a7efd26d1cad67ab6294ba0 -size 1979 +oid sha256:169faba3ca2ab85760303743db6fb813b512081e163d07ea39e781a72231e343 +size 1980 diff --git a/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_2.nbt index 9da824b9..3117436b 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7cc8dde80548c771e27c98704751edc3d75a50ade486e5cfc0422f8363027ec8 -size 2210 +oid sha256:7c96eead0e023ff9a810baee6d56ebb4991fd80837a438bb3450a2d281e16ae5 +size 2211 diff --git a/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_3.nbt index 07b1cbee..a447c557 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/small_stables/inner_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:041d606a423573fb06a808c1b3de754e41a414b246292e99fce5b777a4488d79 -size 1679 +oid sha256:f1b79ea257db895b5cf5429d1834adb529bbf4c2c408a3f94e63f8e4909034d2 +size 1681 diff --git a/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_0.nbt index f047cf90..4d1c3ac8 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0014a6e3bd79adff2136fc1aa4d4f183b6c217469fa29a7564641014a3903870 -size 2137 +oid sha256:fd1cb6a9ad6cf496d6ddf38a350745d2baf858c675c91f5ecc2d4f62d10ee01d +size 2136 diff --git a/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_1.nbt index 6f11eee9..c87ea139 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:729ad227cb3bd0187578df0bd154fa5a6cc17a2a8b21e5e30f0869b49f960771 -size 2063 +oid sha256:52fa15cb9b36be037eae273ffd848db47437251fe8c59c2988fbdaaad4c100a4 +size 2064 diff --git a/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_2.nbt index 592ca007..5763278b 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cc7eb66352d0e5c61bfb43e8d4df026a7a40fd897fe97ea3ba00110f27d4ac11 -size 2149 +oid sha256:0122bc552ce7878d9b73a1774f2ef8e06a262a02e2f4469c2e404025693b8ef3 +size 2148 diff --git a/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_3.nbt index 8b2f4ab4..7995ed1f 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/small_stables/outer_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2ecfd1d9eb48c4285bf97e643df831439e7bf15175716d71553c01a7240464c6 -size 1849 +oid sha256:fe4e0e6ba7ea120913a4ba5f433b6e1fc8091673b1183f1b42c989c5271f62a3 +size 1850 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_0.nbt index 09cbcd91..0d7bb29a 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4e4d40e0127156c32650902c1dc25e0d7c3373b704f857dfe5548f31d2ccf9b6 -size 4465 +oid sha256:d7b03e73f834b71023b8021b127cb1d59ab62447161ea472d1791fa40f9ab42c +size 4466 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_1.nbt index ec7f86e3..3ebce9b1 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dbb5151c35e0b4762775c062f62e9afb35fe77a9dfeb1ea8dd2787a34d21405e -size 4274 +oid sha256:8edc308248965c320f1529e769d7275073f10b334fa5c50a79bd20cd19359a7b +size 4275 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_2.nbt index 7d74d3e7..e72bd101 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0cfca130a9bbf5b3eb11834f1f85befcc16d23a4bdf6ede9b4dc061d3ea1c789 -size 4336 +oid sha256:add3151ec8dee1d69646ea8e4ec623a53bdbd4810c048dde20a03ab27fb516b9 +size 4338 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_3.nbt index ce199c66..ff5ddac9 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f6fa23f81a9738a53c0c18e941082746c45a4801803a58879d55da1d6285f498 -size 4497 +oid sha256:1a802f29d49889324e72f742f2003601d13567de3a4d0584eb6486d87ee4c651 +size 4498 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_4.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_4.nbt index f2057351..2a178fba 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_4.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_1_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:59b94a0bc6a7508a750f089da8b46ee95a4a457cea3c0e6969ebb08a86d87339 -size 4438 +oid sha256:73ef017dc54649ee7c3296ca778df5519efa094023a384dbede841c951931365 +size 4439 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_0.nbt index 83e00316..a7762b66 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4e24b7cb01afb368c66f774bda21b084d00f2691693a2c9058dcf41354daec2e -size 4413 +oid sha256:6ca296955e16994a5773cda073f714a1b0b6f1083fcd1aef387f5c906946353e +size 4414 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_1.nbt index 33c3fac6..b4e9528d 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2368d3978bf9c6d1ae4f8216fb874887fdb1deb346462e697122d89d469e1446 -size 4333 +oid sha256:60bc62fc154309d9b450a78ece00a56ca51c1d3755f8a058593d055268443248 +size 4334 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_2.nbt index d559e75f..d956c077 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:81d843800586a6dd7c532a1c07892593a6a2d7176861454340661253d20a25c6 -size 4118 +oid sha256:f4482fdf0190e5fbcfeaa755c57ac8df1d1c74cdb1b5da1991b872d22a885121 +size 4119 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_3.nbt index d67da3b5..f7cf7436 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d5a5d3266c77ac57ff38efbbd29e7e401ec44011514cd88934b9b5344d8afc10 -size 3301 +oid sha256:9a3de4a4ab3ca0806d61ec314351474d853cc3ea4d3500ead383b6584c659471 +size 3303 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_4.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_4.nbt index 46745e26..06477fb9 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_4.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_2_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7947d0ea0abf7defe887581e33c0d6f3804dd30fabdb9daaa443886722da6c19 -size 4378 +oid sha256:12a544b7f668618a1ab1b51621e6b24b830aae2d5c68e74039b9e980a83ce4a8 +size 4379 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_0.nbt index 08bd9d8d..bf4c697c 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a836db9a5e0af535dd005a95085ea2aa9d3acecd1f9d6b5cec5e3dcd23ade211 -size 4019 +oid sha256:5b51dfd962cfb38cfc2407705c24343e5c9b05e72da33365ba3be310556f42be +size 4021 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_1.nbt index 91534faf..4a3c0438 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:eda3b1d5cca5138cbe59572ec5d47569ab0f2166255308b5fb7a0e0b47e9aec8 -size 4004 +oid sha256:dba1e769710ce3bb22043a60eaff1aa4020fccd3487bfd337b33d54da2093208 +size 4005 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_2.nbt index 2e737e6f..af4b231a 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:922c799ec52e0812c373f1a94f07d427b01352b23fd5b0dded5fff2855dd6257 -size 4208 +oid sha256:649d32106dcea031e74fefd623323e6b00ff467bb131e03b18b7e28ce2eb6f3f +size 4210 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_3.nbt index e198c654..f5ff98a7 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:26f15dadc4dcfb163221cc2f331aecc747e561e0f1a1cd80d7e770f76f03e6e5 -size 4321 +oid sha256:1a53a187c812c0417aca0324d7c66f9a7d78697728e142064128a76b374950e2 +size 4322 diff --git a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_4.nbt b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_4.nbt index 9f4dd35f..01015038 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_4.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/stairs/stairs_3_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c1ae72530436521f4352a6000a98ee59de465898625aab49f025c03b7aca508d -size 2778 +oid sha256:b9bb53bd82c2dfb3410dc1d4f545cc662c5938aa8b1d75dc1d4a30386331cca8 +size 2779 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_0_mirrored.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_0_mirrored.nbt index 80752e61..ba86b1fa 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_0_mirrored.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_0_mirrored.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cd1c207d0d42902f88fd20e56a3306e1756bed0a7d1c4d00a6ec70ca16fc3035 -size 4611 +oid sha256:705c493cc8f8c6d6fd3877b4a62fe6fb51dfb94a252a4b571a8f4080b64bacea +size 4612 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_1_mirrored.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_1_mirrored.nbt index 0c598b5d..d4bdc6b5 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_1_mirrored.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_1_mirrored.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7fc242ffb5f8bc7f5e9b1668d3fda4e95ab08088ded7398f5a07723d4e971fda -size 4626 +oid sha256:9cf271e15cb7296b25130f5f000bccf2745d6c0add65f82c7b651679d75a86b5 +size 4627 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_2_mirrored.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_2_mirrored.nbt index 17dbd105..49571da7 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_2_mirrored.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_2_mirrored.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b76b303b6b19d703ca476ca72885be3bbbe1c317640bc79c5336f7f4b2cb2d8c -size 4542 +oid sha256:d087b1741320f401f710aef3b6de76818031eb5102f5bcb2f4255ef15a6a2a71 +size 4544 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_3_mirrored.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_3_mirrored.nbt index 346af0c6..536f5d82 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_3_mirrored.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_3_mirrored.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b709c1b852d3159dbfd22731a68636a9af5d74ff8263dc6daae02401889fb73f -size 4740 +oid sha256:3ca157286b50ad49110f62c1074910e3d8e32f9045e1fc49afafa18e2a667ff0 +size 4742 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_4_mirrored.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_4_mirrored.nbt index d10ae414..99017157 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_4_mirrored.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/stairs_4_mirrored.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2de91b504debc09903360479fa502c2d078ec1230db918492398c0480ca9154a -size 4590 +oid sha256:ee85e8f17dd5570475a1b36be7d3fb6e7425ab3791a7749194b3898bc81b8002 +size 4591 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_0.nbt index acd3c563..0ffeca3d 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e602b7c2ce7177ff588cf7b2eec7127b527468d39891206401c914a88b52f17f -size 4626 +oid sha256:f67d0e6a38f7e8f31befc5e9335d8e0ac54760b58c87eaf77ca5af970964f46e +size 4628 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_1.nbt index 082b96e3..3eb996c5 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:503485f584873c89f6e9904b250f8b2c6261f77d6590323234aa24334d642400 -size 4909 +oid sha256:70ea1e3da9135e7884eaef78d90afe4a049712e5976baa71619bc590f99e2b67 +size 4911 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_2.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_2.nbt index 80e3eb11..1a607cef 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_2.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f39aa37d1265b29f6146b285c510d1f0a89584b739b172e54c528370489e65ec -size 4909 +oid sha256:0df504e9e25a49a634a0588b79e1a5b04d967a07297cb6faf0e8f3097187a34f +size 4910 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_3.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_3.nbt index 992daada..944499b0 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_3.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0c6e2c349fd750e3c476693ad40fd84a3f4777c671519122501a015a3e6cbca7 -size 4915 +oid sha256:7b23bfe3e0016f43e8b6ff2af83e631766f1ee09d994c6902df40b6bc8b9c2e2 +size 4917 diff --git a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_4.nbt b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_4.nbt index 9249a5ad..92cfba5b 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_4.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/starting_pieces/starting_stairs_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2ed5a9590ff2737bfac95f359944ca79b75c14cf6f24a6757080c7f23da4d6b8 -size 4584 +oid sha256:6cdff82d90794fb3587c90eb3dc2280409ca60732c2766bcb6dde42814817c6a +size 4586 diff --git a/data/minecraft/structure/bastion/hoglin_stable/walls/side_wall_0.nbt b/data/minecraft/structure/bastion/hoglin_stable/walls/side_wall_0.nbt index b3d0681e..0e7a128c 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/walls/side_wall_0.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/walls/side_wall_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:35eb431428f128e966fcdb8b4d61a1ac98ff81aaf7550ca39743591d39ea7ae2 -size 16616 +oid sha256:e7ff531a290cb3b8355ef81f8cb18770ba33bc76a6f09ada0b15dd826ed253bc +size 16618 diff --git a/data/minecraft/structure/bastion/hoglin_stable/walls/side_wall_1.nbt b/data/minecraft/structure/bastion/hoglin_stable/walls/side_wall_1.nbt index 9994176f..031a7801 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/walls/side_wall_1.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/walls/side_wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e2f73c3bf3a202105911a237a8adc42ca3a05b67166b1989e1c6bfe72cefd93f -size 17026 +oid sha256:ed6a060daf94cabb12309c9b921aaf0a8f5bd172783a9f1e9d3709eea9af26ab +size 17027 diff --git a/data/minecraft/structure/bastion/hoglin_stable/walls/wall_base.nbt b/data/minecraft/structure/bastion/hoglin_stable/walls/wall_base.nbt index 41604d5f..78a154b7 100644 --- a/data/minecraft/structure/bastion/hoglin_stable/walls/wall_base.nbt +++ b/data/minecraft/structure/bastion/hoglin_stable/walls/wall_base.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ac77b718612b1318c6fb5935cd968abcb9bdafff85447ad838651ee02ed07d6c +oid sha256:7268ad310241d969f51a97b4920d80c41d359555a80c78a6714f5c4d2b0b44fa size 16415 diff --git a/data/minecraft/structure/bastion/mobs/crossbow_piglin.nbt b/data/minecraft/structure/bastion/mobs/crossbow_piglin.nbt index 285409bc..ff4ef823 100644 --- a/data/minecraft/structure/bastion/mobs/crossbow_piglin.nbt +++ b/data/minecraft/structure/bastion/mobs/crossbow_piglin.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f10641951b43d745a3ff0bb707bcd5621efb3f9c34b758ae751f5f243098fa3a -size 695 +oid sha256:4531806e9eb81df1c71f483863bf5cd95acc1227c1119d63f5a2a77c9826d14d +size 684 diff --git a/data/minecraft/structure/bastion/mobs/empty.nbt b/data/minecraft/structure/bastion/mobs/empty.nbt index 202b1db2..10936a2c 100644 --- a/data/minecraft/structure/bastion/mobs/empty.nbt +++ b/data/minecraft/structure/bastion/mobs/empty.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e412d41750ee3eef44731f59174fd011c28e08e347e78966a375760665c1ace1 -size 228 +oid sha256:441c8f6637bd9d7bb01bd8b54d23df27c332b7687e749a8c342c1cc6928f5377 +size 229 diff --git a/data/minecraft/structure/bastion/mobs/hoglin.nbt b/data/minecraft/structure/bastion/mobs/hoglin.nbt index 2ea9c618..5d4cb3a7 100644 --- a/data/minecraft/structure/bastion/mobs/hoglin.nbt +++ b/data/minecraft/structure/bastion/mobs/hoglin.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d59f3600c15dfcffda4f1e498f51ed56a4b63ecac06fc9eb51b587da4ef0d05e -size 738 +oid sha256:f6daf9734d073c4908095e2addf320ac087078a46735ce11896850b4fd4e935b +size 705 diff --git a/data/minecraft/structure/bastion/mobs/melee_piglin.nbt b/data/minecraft/structure/bastion/mobs/melee_piglin.nbt index d4eed86c..75fef413 100644 --- a/data/minecraft/structure/bastion/mobs/melee_piglin.nbt +++ b/data/minecraft/structure/bastion/mobs/melee_piglin.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5e0afe78516c84e1ee0fa87076d6e68ad13d62794acba505a7664e1e15c46d44 -size 682 +oid sha256:3494959301901330a3014860bba32493d31de8e4d86c050f158a10e010679152 +size 651 diff --git a/data/minecraft/structure/bastion/mobs/melee_piglin_always.nbt b/data/minecraft/structure/bastion/mobs/melee_piglin_always.nbt index a4616e2c..10b299f4 100644 --- a/data/minecraft/structure/bastion/mobs/melee_piglin_always.nbt +++ b/data/minecraft/structure/bastion/mobs/melee_piglin_always.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5e9dbf0b856e8ed0423dd4ab23b464ae648f731d7d04f4b88458d2829a57f9b7 -size 674 +oid sha256:751baed480fcfb5b8f6ba5ebd3c8f89e229a054a375ef699aa9c69dd88f8fa34 +size 643 diff --git a/data/minecraft/structure/bastion/mobs/sword_piglin.nbt b/data/minecraft/structure/bastion/mobs/sword_piglin.nbt index 3db1060d..9506a1a9 100644 --- a/data/minecraft/structure/bastion/mobs/sword_piglin.nbt +++ b/data/minecraft/structure/bastion/mobs/sword_piglin.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:46c50fc1c9df5d717baae01dca48764c02f7bee63b134941e18b2ca686e43f59 -size 701 +oid sha256:303c2a9cca36c9550b7c5f3c7cad337cfb62252e57bcc89ca9b95002d0421b11 +size 690 diff --git a/data/minecraft/structure/bastion/treasure/bases/centers/center_0.nbt b/data/minecraft/structure/bastion/treasure/bases/centers/center_0.nbt index 2af23529..0933c651 100644 --- a/data/minecraft/structure/bastion/treasure/bases/centers/center_0.nbt +++ b/data/minecraft/structure/bastion/treasure/bases/centers/center_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:65df56ca7141814454364652f90c6711b8785561a62ba0d98d5a05bc8d1ae106 -size 1024 +oid sha256:d4c29745e94c05c7cd0e39d3b8bd745baceae5e84638b574d7c715b4c18f67a2 +size 1025 diff --git a/data/minecraft/structure/bastion/treasure/bases/centers/center_1.nbt b/data/minecraft/structure/bastion/treasure/bases/centers/center_1.nbt index 7c6ae5ae..ce2ab35a 100644 --- a/data/minecraft/structure/bastion/treasure/bases/centers/center_1.nbt +++ b/data/minecraft/structure/bastion/treasure/bases/centers/center_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:65d09038d9d84a086217a7dd92bc5e4720de8d2976aab49a33ba3700c4a9a576 -size 959 +oid sha256:456677c73d91419c85455f60888cba68e326b929b5fda6754395b26216a27aa3 +size 961 diff --git a/data/minecraft/structure/bastion/treasure/bases/centers/center_2.nbt b/data/minecraft/structure/bastion/treasure/bases/centers/center_2.nbt index f121283b..c1eb040f 100644 --- a/data/minecraft/structure/bastion/treasure/bases/centers/center_2.nbt +++ b/data/minecraft/structure/bastion/treasure/bases/centers/center_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8d23677f327f13796b8d68d1cfcb37e17d60838d65e470bd654a90af9d443783 -size 1075 +oid sha256:f833314b479a56a4312d86188567c9bdc2a6f346e1542c75fc034aa7d473a94c +size 1076 diff --git a/data/minecraft/structure/bastion/treasure/bases/centers/center_3.nbt b/data/minecraft/structure/bastion/treasure/bases/centers/center_3.nbt index dcb23b15..6d0f6e7f 100644 --- a/data/minecraft/structure/bastion/treasure/bases/centers/center_3.nbt +++ b/data/minecraft/structure/bastion/treasure/bases/centers/center_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3233e80e538305627a5795a47b10f02cee821f002757e6e56d4e5093e531b256 -size 735 +oid sha256:48457c034deaa1664010e500c30e64ed18bd6380293db23c3e151a5b0050ed29 +size 737 diff --git a/data/minecraft/structure/bastion/treasure/bases/lava_basin.nbt b/data/minecraft/structure/bastion/treasure/bases/lava_basin.nbt index 1dcd22a0..ced8eee0 100644 --- a/data/minecraft/structure/bastion/treasure/bases/lava_basin.nbt +++ b/data/minecraft/structure/bastion/treasure/bases/lava_basin.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b04d2f1db93a741ddaa04c4defc34e751d5ff331684fc57eb29d7f794378c2e7 -size 6584 +oid sha256:8aa6fa6939a5dce6f46b5ca549bdbc4a28a711bd4f57a439c69bcf5835c45bb3 +size 6585 diff --git a/data/minecraft/structure/bastion/treasure/big_air_full.nbt b/data/minecraft/structure/bastion/treasure/big_air_full.nbt index 2344be3f..042556c5 100644 --- a/data/minecraft/structure/bastion/treasure/big_air_full.nbt +++ b/data/minecraft/structure/bastion/treasure/big_air_full.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6636335831a68c0061cdd49b13c105b1e28b435d31074dd4ed3b42943d300c3f -size 69672 +oid sha256:6c162614d50e97df8fa78085c94f5fb1a7095ce3ce5acf1a0d505b38aac5e464 +size 69674 diff --git a/data/minecraft/structure/bastion/treasure/brains/center_brain.nbt b/data/minecraft/structure/bastion/treasure/brains/center_brain.nbt index 4853e1f7..3dec0fcc 100644 --- a/data/minecraft/structure/bastion/treasure/brains/center_brain.nbt +++ b/data/minecraft/structure/bastion/treasure/brains/center_brain.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:58ab80a74ffc88b5629915ea9b04e178bc5f2a706282e93f68432839fdcc1c77 -size 415 +oid sha256:8a837a2d1d18328fc8b0872389ed6c55503c08b40a40bedc4ba433feb2ce9631 +size 416 diff --git a/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_middle.nbt b/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_middle.nbt index d618ec99..a8f82074 100644 --- a/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_middle.nbt +++ b/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_middle.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:500a087d47396571496a52eb3935691c1490bfaf5eb6844da290ce0c57b38cb3 -size 286 +oid sha256:f287da8e876b13a045598f74526b78d09cbb283bbfd6524d7c7953776a042482 +size 288 diff --git a/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_top.nbt b/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_top.nbt index fce42b7c..c8c6081d 100644 --- a/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_top.nbt +++ b/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_top.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6eacc92e816fd502d49769ada649db4969b1003ef05fde8f061ae4f8e602b54c -size 286 +oid sha256:9bdd9ee43ca56e98c9ebbbe7ef32c8ac93eca7f2ceb8a5053988f332d939979e +size 287 diff --git a/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_top_entrance.nbt b/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_top_entrance.nbt index a905bcbd..6b2eb681 100644 --- a/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_top_entrance.nbt +++ b/data/minecraft/structure/bastion/treasure/connectors/center_to_wall_top_entrance.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a0017dad7eebd404963f911b5a216f4658a6a02876192d1ec11fa9882bc3f5f7 -size 291 +oid sha256:b07e4f0a120e2ae453d9b60edf82ceebb8eb97c4a9fac752326e6237ff4fc2a6 +size 292 diff --git a/data/minecraft/structure/bastion/treasure/corners/bottom/corner_0.nbt b/data/minecraft/structure/bastion/treasure/corners/bottom/corner_0.nbt index c0841abe..9642e6ec 100644 --- a/data/minecraft/structure/bastion/treasure/corners/bottom/corner_0.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/bottom/corner_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ae3ab5639fe964f7062dfb8bd983552826c5e6a277ca13ae2b2b0cf74d809fce -size 1684 +oid sha256:1db1c88ff3850e5d7d150b69dc6e6c259d0da2bdda94967c1f1f37adc7a4cc19 +size 1685 diff --git a/data/minecraft/structure/bastion/treasure/corners/bottom/corner_1.nbt b/data/minecraft/structure/bastion/treasure/corners/bottom/corner_1.nbt index 56c87725..8c998c5a 100644 --- a/data/minecraft/structure/bastion/treasure/corners/bottom/corner_1.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/bottom/corner_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:32de1ca14eefc92401ddb603c8e35542bcd1479dbc1cfbb99a608c9f6661806e +oid sha256:e9c3bb7c08e483ef75f8d84411798a52bd3e2fc22d13e0aafeffb5e76932042b size 1680 diff --git a/data/minecraft/structure/bastion/treasure/corners/edges/bottom.nbt b/data/minecraft/structure/bastion/treasure/corners/edges/bottom.nbt index f82da70c..594e5560 100644 --- a/data/minecraft/structure/bastion/treasure/corners/edges/bottom.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/edges/bottom.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:efac02b5292f1a730414b5cdfedb4c7599d1239a8f71053827da1f8475cf5b55 -size 450 +oid sha256:4f981d96e09e42210688f8e858bfcc43a576952489d49e5ba3f32706b35b34f5 +size 451 diff --git a/data/minecraft/structure/bastion/treasure/corners/edges/middle.nbt b/data/minecraft/structure/bastion/treasure/corners/edges/middle.nbt index 6cb9a61a..9142d59d 100644 --- a/data/minecraft/structure/bastion/treasure/corners/edges/middle.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/edges/middle.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a100c6fb9643a9aa595c11242003ec2b2cbe0befebfd83ae015ea4a6966a5d7e -size 438 +oid sha256:ee374b861e94a7bfce94273c26c14fe0a80f73ca332814cb962fa1e61fb6a6ca +size 440 diff --git a/data/minecraft/structure/bastion/treasure/corners/edges/top.nbt b/data/minecraft/structure/bastion/treasure/corners/edges/top.nbt index ccfecc4d..77cabd53 100644 --- a/data/minecraft/structure/bastion/treasure/corners/edges/top.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/edges/top.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ef08fdc5b2c9b849c3b27e90a5fb7c0db5e9a73deb309206281f187ee67e6c3e -size 456 +oid sha256:df5592b67339d7a05cd53251d867a86bb59c567f38cdffcb9b204561770cee1e +size 457 diff --git a/data/minecraft/structure/bastion/treasure/corners/middle/corner_0.nbt b/data/minecraft/structure/bastion/treasure/corners/middle/corner_0.nbt index 7f9cae00..93849a78 100644 --- a/data/minecraft/structure/bastion/treasure/corners/middle/corner_0.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/middle/corner_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1325ff8db027f34b7cbe610e52f44b3834c7063824243bc034b18eb138be1bc5 -size 1585 +oid sha256:4e26ab019be5a9c9f43d5c233ca21cdd9ab3c5da0791f6caf78405aecea3daf5 +size 1586 diff --git a/data/minecraft/structure/bastion/treasure/corners/middle/corner_1.nbt b/data/minecraft/structure/bastion/treasure/corners/middle/corner_1.nbt index 31acd4f5..c166b23f 100644 --- a/data/minecraft/structure/bastion/treasure/corners/middle/corner_1.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/middle/corner_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6049fe3db91469cd8b3dc998e5cbb7746eca20d83cbf461a4d83ac172d5a26ed -size 1538 +oid sha256:c6bcd90ecbb75b449d13d9739c9fcf6c93ab53e9ee392f8654cc554c0783b75c +size 1539 diff --git a/data/minecraft/structure/bastion/treasure/corners/top/corner_0.nbt b/data/minecraft/structure/bastion/treasure/corners/top/corner_0.nbt index 5b09e6fd..6d0ea1a4 100644 --- a/data/minecraft/structure/bastion/treasure/corners/top/corner_0.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/top/corner_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:89cff2cdebeb79c5d0c8ad7f00386acbc0931adc0f0c4f64571ed70503205884 -size 1552 +oid sha256:c0e78890d1d117afb63a2068b653f6dc6ffad31d43b1160adb7e535349990123 +size 1553 diff --git a/data/minecraft/structure/bastion/treasure/corners/top/corner_1.nbt b/data/minecraft/structure/bastion/treasure/corners/top/corner_1.nbt index 90f458b2..6842b4ff 100644 --- a/data/minecraft/structure/bastion/treasure/corners/top/corner_1.nbt +++ b/data/minecraft/structure/bastion/treasure/corners/top/corner_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f35e0dc73fbbc07bb9296321f2c71b7da5a2c30f6a70f543b36ec9d9228982d -size 1572 +oid sha256:f2c7aa7175a46002f4818b00db0e3c059db98e168cb4086468292919e4695c6e +size 1573 diff --git a/data/minecraft/structure/bastion/treasure/entrances/entrance_0.nbt b/data/minecraft/structure/bastion/treasure/entrances/entrance_0.nbt index 1f6d7beb..468b20e8 100644 --- a/data/minecraft/structure/bastion/treasure/entrances/entrance_0.nbt +++ b/data/minecraft/structure/bastion/treasure/entrances/entrance_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a47b1630834b2b0f6ff5076465d7a30c73d8efdf71915fcba6e40ae5cf53306d -size 11196 +oid sha256:d04449ccaefab611105970eb6225e6b8ea4649a306ea50b9d9b7eb73de730a75 +size 11197 diff --git a/data/minecraft/structure/bastion/treasure/extensions/empty.nbt b/data/minecraft/structure/bastion/treasure/extensions/empty.nbt index 1c133cae..92eca3ab 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/empty.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/empty.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e7f04faf08a9f025f4fe6b9c392b533dd67b4a17563a3f105dec49a1a71ec87 -size 232 +oid sha256:ef4aff2a710e0e64829b10a9d43d45f4329b27affbac55a61c10c91726919855 +size 233 diff --git a/data/minecraft/structure/bastion/treasure/extensions/fire_room.nbt b/data/minecraft/structure/bastion/treasure/extensions/fire_room.nbt index 110d44cb..812ff290 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/fire_room.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/fire_room.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:642d83c71c50aa6e38b84b609fba657abeb9fb92cfe86812ef6b782a9d5a57f7 -size 1865 +oid sha256:161a95eabfa107b128820933b1cdbb1a418945edc081ece633df41998becdf90 +size 1867 diff --git a/data/minecraft/structure/bastion/treasure/extensions/house_0.nbt b/data/minecraft/structure/bastion/treasure/extensions/house_0.nbt index 757bf736..a2d618b8 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/house_0.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/house_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4c2a0f24ca7f11cc68a1bc5ecf862ecaa4d64dbc6101f8d33506cfcf2c186c6a -size 2076 +oid sha256:293849fe896f06bdc053867c0a56fd9556766752915d48b98dc44826c0c7a056 +size 2078 diff --git a/data/minecraft/structure/bastion/treasure/extensions/house_1.nbt b/data/minecraft/structure/bastion/treasure/extensions/house_1.nbt index 3f74380d..b23dae89 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/house_1.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:66860944b13efee264e6e586d8a5f0eef449f093b4d377e1b8ba5b84c9669fdf -size 2158 +oid sha256:0faaf2792ce4ed90778be6e123b6ca592b14cc21cbdba8af6e20e99a2ce06dac +size 2160 diff --git a/data/minecraft/structure/bastion/treasure/extensions/large_bridge_0.nbt b/data/minecraft/structure/bastion/treasure/extensions/large_bridge_0.nbt index 38affa6e..0398ea0b 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/large_bridge_0.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/large_bridge_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b4c97119244eafa32b50bc26f519ab152c38d4a7bb6c7e7071535b61064c6ebe -size 454 +oid sha256:2d2b73318067adeb3a03de6a57d8ec129b41e92d36539bc3a8a05a1a18e42f95 +size 455 diff --git a/data/minecraft/structure/bastion/treasure/extensions/large_bridge_1.nbt b/data/minecraft/structure/bastion/treasure/extensions/large_bridge_1.nbt index 4c82e2e2..0f7be9e8 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/large_bridge_1.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/large_bridge_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:90691991efeddf2f14c85971f6b08c95a64fd22aa3fc02301019de99f840094e -size 417 +oid sha256:bebd4a59c91d0b9172960698910f4513ba6ff02c02cc0c5b76a3351ba1d69a73 +size 418 diff --git a/data/minecraft/structure/bastion/treasure/extensions/large_bridge_2.nbt b/data/minecraft/structure/bastion/treasure/extensions/large_bridge_2.nbt index 1bf2d040..1dfcaf52 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/large_bridge_2.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/large_bridge_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d7798bd7d7d381e84c4ce42bed366799772695a4a47adea35d3f27a71fee6496 -size 538 +oid sha256:5dad75d7504b8105c18879c0ab59fcaffaf00b01fbe8695c19c51158f970e616 +size 539 diff --git a/data/minecraft/structure/bastion/treasure/extensions/large_bridge_3.nbt b/data/minecraft/structure/bastion/treasure/extensions/large_bridge_3.nbt index 7cc254f9..9261b716 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/large_bridge_3.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/large_bridge_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:864375acae730747dd8e1dbc2ef1d7b1f8c5bd72974a704909b3d642cecb28c1 -size 615 +oid sha256:674d0bba22ff08c145aca9d0d895b79f3011d607b06f027bab633c8e2077e145 +size 616 diff --git a/data/minecraft/structure/bastion/treasure/extensions/roofed_bridge.nbt b/data/minecraft/structure/bastion/treasure/extensions/roofed_bridge.nbt index 15a9fbe1..4028f326 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/roofed_bridge.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/roofed_bridge.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:803dd62f1d8eb45023c976554a0b5d1f0f78fca1d67959b8eb9c4c64a54ce141 -size 641 +oid sha256:907682c1131eb7a471cc4dc631c3d96a356fd1c86bf0d35e2ec126e4fa5dbbf7 +size 642 diff --git a/data/minecraft/structure/bastion/treasure/extensions/small_bridge_0.nbt b/data/minecraft/structure/bastion/treasure/extensions/small_bridge_0.nbt index a54fe457..8368375b 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/small_bridge_0.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/small_bridge_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:623551b64b8bbe5f16e29e9280de743e45b0b82205c03ca13ce802d19739b151 -size 319 +oid sha256:e01ee7e5aa269825bb89d14a0818e2146172125a2c03b574ad4fe57e477f986f +size 320 diff --git a/data/minecraft/structure/bastion/treasure/extensions/small_bridge_1.nbt b/data/minecraft/structure/bastion/treasure/extensions/small_bridge_1.nbt index 5a1ee914..1b24bc65 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/small_bridge_1.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/small_bridge_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e211ea5b7be2f5b6a8f7f3946e1de11ee6aa6ab3331365696eefdde6e76aa347 -size 389 +oid sha256:3c723861fdd55426bb4397930370a4cd0be7023c2ce8328f465e2e83336c78bd +size 390 diff --git a/data/minecraft/structure/bastion/treasure/extensions/small_bridge_2.nbt b/data/minecraft/structure/bastion/treasure/extensions/small_bridge_2.nbt index 4e1ad7df..4c45bc3e 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/small_bridge_2.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/small_bridge_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e6f453881646219422962a5e7419699d699315b6fc778bc3ba541400e2f5e326 -size 348 +oid sha256:da3a01008481f31145aba8282e200c35515f6835056aaf4c37c3bb60a4572dbd +size 349 diff --git a/data/minecraft/structure/bastion/treasure/extensions/small_bridge_3.nbt b/data/minecraft/structure/bastion/treasure/extensions/small_bridge_3.nbt index e39c96ba..45eb4de6 100644 --- a/data/minecraft/structure/bastion/treasure/extensions/small_bridge_3.nbt +++ b/data/minecraft/structure/bastion/treasure/extensions/small_bridge_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e85ab261979a6eedc148a9cfdc88ad4c055f2ce491abbdaa49808d82336443a1 -size 479 +oid sha256:7e03371c05a93936b11fa10e8594efb7e991ff59b00354d27ce5893f0020357c +size 480 diff --git a/data/minecraft/structure/bastion/treasure/ramparts/bottom_wall_0.nbt b/data/minecraft/structure/bastion/treasure/ramparts/bottom_wall_0.nbt index 4ad29ddf..1233ed32 100644 --- a/data/minecraft/structure/bastion/treasure/ramparts/bottom_wall_0.nbt +++ b/data/minecraft/structure/bastion/treasure/ramparts/bottom_wall_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5667afbd8f8fad677671a902c231ed87f9c6d845cbd15f9680978fe33e73bd9e -size 11780 +oid sha256:7deef3ba0020b40dc9f8fb0cf073d060efee8f32f7e1c2b37341ebeb1938901d +size 11781 diff --git a/data/minecraft/structure/bastion/treasure/ramparts/lava_basin_main.nbt b/data/minecraft/structure/bastion/treasure/ramparts/lava_basin_main.nbt index dce0138f..6476888c 100644 --- a/data/minecraft/structure/bastion/treasure/ramparts/lava_basin_main.nbt +++ b/data/minecraft/structure/bastion/treasure/ramparts/lava_basin_main.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d149f3914d9418f822f1d07e219451266a6f825ecbb0ea15f16b5291aca127c7 -size 24168 +oid sha256:44d1309e93626a973ff3f53c77b54603f66ce1adbd38f742720488276e728ede +size 24169 diff --git a/data/minecraft/structure/bastion/treasure/ramparts/lava_basin_side.nbt b/data/minecraft/structure/bastion/treasure/ramparts/lava_basin_side.nbt index 85648745..e1d8c83e 100644 --- a/data/minecraft/structure/bastion/treasure/ramparts/lava_basin_side.nbt +++ b/data/minecraft/structure/bastion/treasure/ramparts/lava_basin_side.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f18c95c16cd38733e3a28805f9a0aa44742407ab37e0d694094a555e63548e7f -size 23968 +oid sha256:62a1f786236c2925dcad756277de4a2b78c53ca0ff097b90a61fd28fede36a64 +size 23969 diff --git a/data/minecraft/structure/bastion/treasure/ramparts/mid_wall_main.nbt b/data/minecraft/structure/bastion/treasure/ramparts/mid_wall_main.nbt index 6ce6ebac..41d972d1 100644 --- a/data/minecraft/structure/bastion/treasure/ramparts/mid_wall_main.nbt +++ b/data/minecraft/structure/bastion/treasure/ramparts/mid_wall_main.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:355c43639fdbc05635f886c3af392dc6f6bcbb57ba43860aadbea5796a86d99c -size 18998 +oid sha256:36620ea022072bc99dd4053b27ab435e2d249e34de6f27f4b96cd8852c0650e6 +size 18999 diff --git a/data/minecraft/structure/bastion/treasure/ramparts/mid_wall_side.nbt b/data/minecraft/structure/bastion/treasure/ramparts/mid_wall_side.nbt index ed06b254..57555934 100644 --- a/data/minecraft/structure/bastion/treasure/ramparts/mid_wall_side.nbt +++ b/data/minecraft/structure/bastion/treasure/ramparts/mid_wall_side.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6bd8272928ed1b1383cbf4cf1aaf114df7f0ac7fa652ddd41cebca0a930c7ad2 -size 18146 +oid sha256:c26c0c297e8e35273196a2b94cada2f35a4f6c9b51d9903316070d7250355155 +size 18147 diff --git a/data/minecraft/structure/bastion/treasure/ramparts/top_wall.nbt b/data/minecraft/structure/bastion/treasure/ramparts/top_wall.nbt index fd33db34..bb9325ae 100644 --- a/data/minecraft/structure/bastion/treasure/ramparts/top_wall.nbt +++ b/data/minecraft/structure/bastion/treasure/ramparts/top_wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f7d3144597e7411b1bdfe51fb2c9087109101c2283945a48f1c931e1b075e6c -size 9860 +oid sha256:4c09407fb1ccc3abf5d2b97d2371e791b76e2f9599d50a6bed6ed3ade891a60a +size 9861 diff --git a/data/minecraft/structure/bastion/treasure/roofs/center_roof.nbt b/data/minecraft/structure/bastion/treasure/roofs/center_roof.nbt index 85aa77fc..d54290bd 100644 --- a/data/minecraft/structure/bastion/treasure/roofs/center_roof.nbt +++ b/data/minecraft/structure/bastion/treasure/roofs/center_roof.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:46bfe4f34e03501bf8c7e858dfdbcc4136fba06afdd234fba1be1118300438c2 -size 3447 +oid sha256:6240a76b7a16875836ff70493c257e5af31f7913996d8ad02fcfb57420c4e150 +size 3448 diff --git a/data/minecraft/structure/bastion/treasure/roofs/corner_roof.nbt b/data/minecraft/structure/bastion/treasure/roofs/corner_roof.nbt index 558ceb4d..9750048e 100644 --- a/data/minecraft/structure/bastion/treasure/roofs/corner_roof.nbt +++ b/data/minecraft/structure/bastion/treasure/roofs/corner_roof.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:21c3128d58e2deaa78ef762877b57842c76bf4d863e22054622553de66d08a16 -size 424 +oid sha256:b227874f6f823ff7a2b595eca2a3d67890049c074b0ccfc0e8bb688b8c4da5de +size 425 diff --git a/data/minecraft/structure/bastion/treasure/roofs/wall_roof.nbt b/data/minecraft/structure/bastion/treasure/roofs/wall_roof.nbt index f4a085ee..e1ef66a7 100644 --- a/data/minecraft/structure/bastion/treasure/roofs/wall_roof.nbt +++ b/data/minecraft/structure/bastion/treasure/roofs/wall_roof.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b6373766543575201120e9b6255e2d46d419194f4a0fd8ecef6ba8bead536d20 +oid sha256:d58b1b93135af90fed349b27594cad51ff297b939e0632ebba534c87f2f2a432 size 991 diff --git a/data/minecraft/structure/bastion/treasure/stairs/lower_stairs.nbt b/data/minecraft/structure/bastion/treasure/stairs/lower_stairs.nbt index 0d072ad0..4159596e 100644 --- a/data/minecraft/structure/bastion/treasure/stairs/lower_stairs.nbt +++ b/data/minecraft/structure/bastion/treasure/stairs/lower_stairs.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5977b994bcd6a62019b65e55afee4b81da6a087ecdd37121b5c72c3138cef67d -size 445 +oid sha256:931d5a97e389c103f20a57c40d141ad44012e9be5f8c5a808d7e89833e0f13b3 +size 447 diff --git a/data/minecraft/structure/bastion/treasure/walls/bottom/wall_0.nbt b/data/minecraft/structure/bastion/treasure/walls/bottom/wall_0.nbt index a5499914..2176ac3a 100644 --- a/data/minecraft/structure/bastion/treasure/walls/bottom/wall_0.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/bottom/wall_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:de2e71ed8221d47308115e332d0379c9a42c673756b03d42fb052cbd4408ea8e -size 6611 +oid sha256:13df1fcdb021e97fa8889500061eb1b715f334b075cdc60a66571029123ffbee +size 6613 diff --git a/data/minecraft/structure/bastion/treasure/walls/bottom/wall_1.nbt b/data/minecraft/structure/bastion/treasure/walls/bottom/wall_1.nbt index b3dde151..fb44b051 100644 --- a/data/minecraft/structure/bastion/treasure/walls/bottom/wall_1.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/bottom/wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0fa73c0ef1e17c6ab5439a05d5e2fdb2d1ddaa27ad7afe0fe82183482ca557b6 -size 6499 +oid sha256:ff7f71307354415512fd3c891214532f9b8b47e981e477e04a96983f0c5a4806 +size 6500 diff --git a/data/minecraft/structure/bastion/treasure/walls/bottom/wall_2.nbt b/data/minecraft/structure/bastion/treasure/walls/bottom/wall_2.nbt index 51974509..eb912b97 100644 --- a/data/minecraft/structure/bastion/treasure/walls/bottom/wall_2.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/bottom/wall_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a004390b206a8c30a6c6c3c7b4987f2bec3cc30f76ccf496d1ba15a5b7df961a -size 6442 +oid sha256:07cb216a5eafbcdfc07e856a981e6a5eeaaab9aac5ed854a57a90b954353ec0b +size 6443 diff --git a/data/minecraft/structure/bastion/treasure/walls/bottom/wall_3.nbt b/data/minecraft/structure/bastion/treasure/walls/bottom/wall_3.nbt index efb79c0c..93a91242 100644 --- a/data/minecraft/structure/bastion/treasure/walls/bottom/wall_3.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/bottom/wall_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c0ca74e37c70907c9bb7a89297e1b658b98b48267759eb778b24781b9bd255f6 -size 6489 +oid sha256:420e473738bce9c695c12550bcdd30de8b85c3f4ba5b6d5929aa0effeea311f1 +size 6491 diff --git a/data/minecraft/structure/bastion/treasure/walls/entrance_wall.nbt b/data/minecraft/structure/bastion/treasure/walls/entrance_wall.nbt index c725638b..6f8f6fae 100644 --- a/data/minecraft/structure/bastion/treasure/walls/entrance_wall.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/entrance_wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d6eaca758f55c7575d719eb28b9cfccfa01a8806613ecb2f8b7841ebecad9597 -size 2678 +oid sha256:d60769a303afd0d941fe4fcdf3fd6b34a3bd6b402161f16434572d9e9500f56c +size 2679 diff --git a/data/minecraft/structure/bastion/treasure/walls/lava_wall.nbt b/data/minecraft/structure/bastion/treasure/walls/lava_wall.nbt index 8b0d9566..8ae9501a 100644 --- a/data/minecraft/structure/bastion/treasure/walls/lava_wall.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/lava_wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f6ec769d2205e2cf43a2ab6b23f75e2627b1565a2caac29c159c97491a8adb3b -size 2798 +oid sha256:04ca8e0d2210a9b78018c3a6d818fbee7c0107d32801acd34174b6a2fa0584a1 +size 2799 diff --git a/data/minecraft/structure/bastion/treasure/walls/mid/wall_0.nbt b/data/minecraft/structure/bastion/treasure/walls/mid/wall_0.nbt index 9965b5a1..29791372 100644 --- a/data/minecraft/structure/bastion/treasure/walls/mid/wall_0.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/mid/wall_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0d2dc34c0643b18b6055ef8ccab6d9dd968ceddb8fb810e74460e555498cb0b8 -size 6296 +oid sha256:959f7f86be59181f16ff78e3292e2bee1031c41ebe1ca647b0be47ae4f09561e +size 6297 diff --git a/data/minecraft/structure/bastion/treasure/walls/mid/wall_1.nbt b/data/minecraft/structure/bastion/treasure/walls/mid/wall_1.nbt index 8bc7c0a4..b83d8f49 100644 --- a/data/minecraft/structure/bastion/treasure/walls/mid/wall_1.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/mid/wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ed05646e6445e4d94a063fe183dd02e6369a07a9009251181a3c26ac6868e384 -size 6152 +oid sha256:5b6f9e325425db947d23ae362436a6d3038a6c50ceacc876f595359505d1777f +size 6153 diff --git a/data/minecraft/structure/bastion/treasure/walls/mid/wall_2.nbt b/data/minecraft/structure/bastion/treasure/walls/mid/wall_2.nbt index 6982b055..7c53b99e 100644 --- a/data/minecraft/structure/bastion/treasure/walls/mid/wall_2.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/mid/wall_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:276d633bd6dfee1116697bf2211097cd0ddefbdc1ac7781838eee4c5bb75fa65 +oid sha256:7ef9393b82968026027a5ce24b7f293e054cb0dace94cee9920d7103a10c0284 size 6174 diff --git a/data/minecraft/structure/bastion/treasure/walls/outer/bottom_corner.nbt b/data/minecraft/structure/bastion/treasure/walls/outer/bottom_corner.nbt index 70022bcf..0638fa62 100644 --- a/data/minecraft/structure/bastion/treasure/walls/outer/bottom_corner.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/outer/bottom_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f1d395a6aeda04bff46d75623869edf1e81a9fd789601d54ae49053f07484838 -size 780 +oid sha256:76f36715b74a4df2197e2dcf07ced33c0d11887828688551fe691fbb16879a14 +size 781 diff --git a/data/minecraft/structure/bastion/treasure/walls/outer/medium_outer_wall.nbt b/data/minecraft/structure/bastion/treasure/walls/outer/medium_outer_wall.nbt index 8da1acb7..5347b864 100644 --- a/data/minecraft/structure/bastion/treasure/walls/outer/medium_outer_wall.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/outer/medium_outer_wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:851603196172d531995877168ffb707c15a15377b4079cd71d638ef1de2251d2 +oid sha256:1580d5287c39f72bc147bc1903a429b82de5881be56d849ecadadbc6ab833f5f size 2333 diff --git a/data/minecraft/structure/bastion/treasure/walls/outer/mid_corner.nbt b/data/minecraft/structure/bastion/treasure/walls/outer/mid_corner.nbt index 4690718e..814859d2 100644 --- a/data/minecraft/structure/bastion/treasure/walls/outer/mid_corner.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/outer/mid_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:347ffedc51f17edbcd7de2923658323645c9bec8b03542ca5a092ab71dad51ea -size 713 +oid sha256:06aa94c664dbf982063cb9ddeb169d8fb4ba6ec82adfa3d0aa218fc21d7f4ce9 +size 714 diff --git a/data/minecraft/structure/bastion/treasure/walls/outer/outer_wall.nbt b/data/minecraft/structure/bastion/treasure/walls/outer/outer_wall.nbt index da1e30ec..82806e98 100644 --- a/data/minecraft/structure/bastion/treasure/walls/outer/outer_wall.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/outer/outer_wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:43607212a2ee82c866d86475038cd19289d82b4fe213c5b28294fcc899942087 -size 2204 +oid sha256:06e328ecdd3e3b0be43fe2bd95777d3044f2f6f06ffee6c6c5e951ec68c88f23 +size 2206 diff --git a/data/minecraft/structure/bastion/treasure/walls/outer/tall_outer_wall.nbt b/data/minecraft/structure/bastion/treasure/walls/outer/tall_outer_wall.nbt index eecc19a2..59317635 100644 --- a/data/minecraft/structure/bastion/treasure/walls/outer/tall_outer_wall.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/outer/tall_outer_wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e57ea31a95b6f2d416004ef60aa0ec73bfdcab611db93ecf826cb7af974917b7 -size 2448 +oid sha256:6df5fa67c7338a7ec56c0a5d27cb0d544a86f67e239b7a31c4eb2027a9331e97 +size 2449 diff --git a/data/minecraft/structure/bastion/treasure/walls/outer/top_corner.nbt b/data/minecraft/structure/bastion/treasure/walls/outer/top_corner.nbt index 4e074a93..6fcfdf00 100644 --- a/data/minecraft/structure/bastion/treasure/walls/outer/top_corner.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/outer/top_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:163dfbe00a2707ff12b159d9fad0f4b824a05f988e3dc7165a499124e05308d9 -size 805 +oid sha256:d16644e4d63090a0d0c8fa4085f7736436287ce7f02c72a42fb40a34b1130379 +size 806 diff --git a/data/minecraft/structure/bastion/treasure/walls/top/main_entrance.nbt b/data/minecraft/structure/bastion/treasure/walls/top/main_entrance.nbt index 9e619cfb..74d6a7ac 100644 --- a/data/minecraft/structure/bastion/treasure/walls/top/main_entrance.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/top/main_entrance.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2c0c049202b75f31dd02f726a6ea2a6304d6caf5acc9b04ff1568ea61fa867ed -size 6219 +oid sha256:cd50209261255d9ebcc714c583888402842c49281381575fb286e8b5f50c8069 +size 6220 diff --git a/data/minecraft/structure/bastion/treasure/walls/top/wall_0.nbt b/data/minecraft/structure/bastion/treasure/walls/top/wall_0.nbt index dc1db813..de88a67c 100644 --- a/data/minecraft/structure/bastion/treasure/walls/top/wall_0.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/top/wall_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:73372a7aa32eeb2095567953113cc7379f309667d5cad8c4d1fcdcf23d5a20f3 -size 6225 +oid sha256:c9d9dbdf4e549dc4b94dae4acea385e718247b32935c77fdf5f289bb6e51f475 +size 6226 diff --git a/data/minecraft/structure/bastion/treasure/walls/top/wall_1.nbt b/data/minecraft/structure/bastion/treasure/walls/top/wall_1.nbt index a990cabe..49fe80cd 100644 --- a/data/minecraft/structure/bastion/treasure/walls/top/wall_1.nbt +++ b/data/minecraft/structure/bastion/treasure/walls/top/wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6de3d6c5a535715d953408c9d9a93bddf4864df7cdc815c6dee4b44298314fc0 -size 6217 +oid sha256:0b2ec7ed04f9edecf9d2057985c93afb66f1567b706ebdda8359948d3aa14425 +size 6219 diff --git a/data/minecraft/structure/bastion/units/air_base.nbt b/data/minecraft/structure/bastion/units/air_base.nbt index e7f8c013..36074284 100644 --- a/data/minecraft/structure/bastion/units/air_base.nbt +++ b/data/minecraft/structure/bastion/units/air_base.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8efd04fdfd2c2bd073bf5dcf2c126c4155ef00912ac1d0b7e3d8a90ef0eef74e -size 63631 +oid sha256:b1eb892bddc94b79c67fa1a011302668fc4a4b6d7a81bc1dd70606d287d321bd +size 63633 diff --git a/data/minecraft/structure/bastion/units/center_pieces/center_0.nbt b/data/minecraft/structure/bastion/units/center_pieces/center_0.nbt index 630ba63f..4161dcf7 100644 --- a/data/minecraft/structure/bastion/units/center_pieces/center_0.nbt +++ b/data/minecraft/structure/bastion/units/center_pieces/center_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1727560b5058c438d96bdc6b4365fb549c061bd29a3f6783a338cdfaa43b9394 -size 3082 +oid sha256:ab8b4a8ee187945f8010ba1fa1ae5e2e7c08180912718176cb82ac3c26b3107a +size 3083 diff --git a/data/minecraft/structure/bastion/units/center_pieces/center_1.nbt b/data/minecraft/structure/bastion/units/center_pieces/center_1.nbt index 88ca3b21..736cc240 100644 --- a/data/minecraft/structure/bastion/units/center_pieces/center_1.nbt +++ b/data/minecraft/structure/bastion/units/center_pieces/center_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cfd0fb586fad6a46fc392731d147d191ca0f4d644fc1c191a343a73662237668 -size 3292 +oid sha256:d796a5a117de448bd016b98fa4167ffadb2dc9c4d6e1af97be238654b7cca33d +size 3293 diff --git a/data/minecraft/structure/bastion/units/center_pieces/center_2.nbt b/data/minecraft/structure/bastion/units/center_pieces/center_2.nbt index 0e48c26b..431246ba 100644 --- a/data/minecraft/structure/bastion/units/center_pieces/center_2.nbt +++ b/data/minecraft/structure/bastion/units/center_pieces/center_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c6fe69409c5b3defe9c1a59277908aba4f5ed99ad72745e699f0d4f6df9075ff -size 3358 +oid sha256:05973ff26dd00268cc8804ca9d7f93641aa610daafbeb1dd54cf234719718075 +size 3359 diff --git a/data/minecraft/structure/bastion/units/edges/edge_0.nbt b/data/minecraft/structure/bastion/units/edges/edge_0.nbt index 22b8a91e..284a0b40 100644 --- a/data/minecraft/structure/bastion/units/edges/edge_0.nbt +++ b/data/minecraft/structure/bastion/units/edges/edge_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3af1754348206527c6791a3c79caf9b58f0bd226afa0e7e5a0968442399ca393 -size 2381 +oid sha256:f89066c8b67a41a0227b563cf4d4bed438e2310766df3e227b2ac37871f4867b +size 2382 diff --git a/data/minecraft/structure/bastion/units/fillers/stage_0.nbt b/data/minecraft/structure/bastion/units/fillers/stage_0.nbt index b78f2841..a07ae499 100644 --- a/data/minecraft/structure/bastion/units/fillers/stage_0.nbt +++ b/data/minecraft/structure/bastion/units/fillers/stage_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c22c6d840d487f06c404cdfee74f1367f9261104b97ab0e872fc2c388b17a85b -size 2453 +oid sha256:1300cc619834d4e491484700168044fd862a8f01a8a35fa49e3c89b69bbc0a23 +size 2454 diff --git a/data/minecraft/structure/bastion/units/pathways/pathway_0.nbt b/data/minecraft/structure/bastion/units/pathways/pathway_0.nbt index c83b10cc..0a865090 100644 --- a/data/minecraft/structure/bastion/units/pathways/pathway_0.nbt +++ b/data/minecraft/structure/bastion/units/pathways/pathway_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:29c64a75f34a49f34d9c527c0e40c88f1e6e38c0678ee2743b1ac3f2fa1737f8 -size 354 +oid sha256:6491030165b17c5620dcd2cd96194c8772e3ecbdb53629b9585b0c2a781e96d2 +size 355 diff --git a/data/minecraft/structure/bastion/units/pathways/pathway_wall_0.nbt b/data/minecraft/structure/bastion/units/pathways/pathway_wall_0.nbt index 970268bd..98f008e4 100644 --- a/data/minecraft/structure/bastion/units/pathways/pathway_wall_0.nbt +++ b/data/minecraft/structure/bastion/units/pathways/pathway_wall_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9ead8d1f254f8628d7e8568ca99c9f4c8eb81ad9a162a931ed364bd7cbdbcb21 -size 353 +oid sha256:bf313a4f86dd2980164280f654bddefda3be8d35b7993f5473a72b92ee37c512 +size 355 diff --git a/data/minecraft/structure/bastion/units/rampart_plates/plate_0.nbt b/data/minecraft/structure/bastion/units/rampart_plates/plate_0.nbt index 9b0cd8cd..8fd5b8bb 100644 --- a/data/minecraft/structure/bastion/units/rampart_plates/plate_0.nbt +++ b/data/minecraft/structure/bastion/units/rampart_plates/plate_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5a15ed4ffe5fe2729b85589e2f67e4e47ee62b567d59a05ee70a348c6b7f9438 -size 3656 +oid sha256:0e4d8ecce7cdc4623b6a97d2187f575ee8f2c424fa0907b887be6e329ee90c08 +size 3657 diff --git a/data/minecraft/structure/bastion/units/ramparts/ramparts_0.nbt b/data/minecraft/structure/bastion/units/ramparts/ramparts_0.nbt index 0d66b0c5..f7a2f378 100644 --- a/data/minecraft/structure/bastion/units/ramparts/ramparts_0.nbt +++ b/data/minecraft/structure/bastion/units/ramparts/ramparts_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4a1d29dcc226596ccd412c34c9474bbdd163560e07a01cf7e3a8a2dc105a569b +oid sha256:745bd9161756423d1c76b86a98afec9d8dec216b01ca6feafe4465337927ad62 size 23660 diff --git a/data/minecraft/structure/bastion/units/ramparts/ramparts_1.nbt b/data/minecraft/structure/bastion/units/ramparts/ramparts_1.nbt index 89001a8c..2b4353b3 100644 --- a/data/minecraft/structure/bastion/units/ramparts/ramparts_1.nbt +++ b/data/minecraft/structure/bastion/units/ramparts/ramparts_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:398a1cd58636ee512c4680c121c2cba80ba3d6e59131b07c0ea38c6727bd989c -size 11770 +oid sha256:494598a4b4e5d214187f7d2c5d2a3fa46ba8f90fd7731b2adbd520ee5ae95319 +size 11771 diff --git a/data/minecraft/structure/bastion/units/ramparts/ramparts_2.nbt b/data/minecraft/structure/bastion/units/ramparts/ramparts_2.nbt index 4fbd385b..c83a0f0d 100644 --- a/data/minecraft/structure/bastion/units/ramparts/ramparts_2.nbt +++ b/data/minecraft/structure/bastion/units/ramparts/ramparts_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e848fc7828cee35c94a3b94ef141aa81be5920ccd9f763c2f120b16457516b5e -size 6941 +oid sha256:e266270810fa72176f8e5bfe4c99f1786e69e0a883e27a9a46a7f170823d57ee +size 6942 diff --git a/data/minecraft/structure/bastion/units/stages/rot/stage_1_0.nbt b/data/minecraft/structure/bastion/units/stages/rot/stage_1_0.nbt index 15809db5..7acf24a3 100644 --- a/data/minecraft/structure/bastion/units/stages/rot/stage_1_0.nbt +++ b/data/minecraft/structure/bastion/units/stages/rot/stage_1_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:147cd9a4b8a731e77b0d62a8a0f86621fc2c75d73e632d49c43550c4d73bec4e -size 2400 +oid sha256:48287b1f3746e0c5cc5051e36e20a20560df9eefe9681afb6e2e2c5c49729115 +size 2401 diff --git a/data/minecraft/structure/bastion/units/stages/stage_0_0.nbt b/data/minecraft/structure/bastion/units/stages/stage_0_0.nbt index f69fe3cd..88cffbb0 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_0_0.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_0_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:22996e55c911f9025d720fb44dd1e52ddb86d706308d3408b74b0565ff1183f5 -size 2548 +oid sha256:aa689d40304cd7e83afa8d115e020e4637f8890ac61404d4aeef516497fe0d57 +size 2549 diff --git a/data/minecraft/structure/bastion/units/stages/stage_0_1.nbt b/data/minecraft/structure/bastion/units/stages/stage_0_1.nbt index 54ed299a..b84a94a4 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_0_1.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_0_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b1e5f2cae28a0c7c8e7f60a5f1339039d95ba898b3f413bf30b17bb5f1fda4a8 -size 2612 +oid sha256:d08fd74605ed363cccadd51e2a11eb8f3cc5866a72020f3b614da30995496bee +size 2613 diff --git a/data/minecraft/structure/bastion/units/stages/stage_0_2.nbt b/data/minecraft/structure/bastion/units/stages/stage_0_2.nbt index 95c91226..a01a44f7 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_0_2.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_0_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:497f8ab1127b47de7724731e59ec719251d16130023e55cbed59b0d5e419531f -size 2703 +oid sha256:0ca7ce8f5c16b1dcc191edb91eee9ea5b46a0c10570b123c0e7fdf00054c3ebc +size 2705 diff --git a/data/minecraft/structure/bastion/units/stages/stage_0_3.nbt b/data/minecraft/structure/bastion/units/stages/stage_0_3.nbt index a0c152ce..b5e84d7d 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_0_3.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_0_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b865aa8f857e931b9ef67f4c23c34d9d9c7648d502590f9a3053a6c2ae89b2f9 -size 2505 +oid sha256:3fd7df08d0785b3d0149e3754b27a3623f9eb89515bedfd7894bc6a0c1004332 +size 2506 diff --git a/data/minecraft/structure/bastion/units/stages/stage_1_0.nbt b/data/minecraft/structure/bastion/units/stages/stage_1_0.nbt index b23d6169..da644d21 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_1_0.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_1_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6a3e4e14beb5ab08694ef52da38af0a5ee6d97b5f92eeda4b02e6dd8e87e8eb7 -size 2441 +oid sha256:7923d5745fd9699976cabb2c59385d0acf4931baa86f246d8d6b4833680466e7 +size 2442 diff --git a/data/minecraft/structure/bastion/units/stages/stage_1_1.nbt b/data/minecraft/structure/bastion/units/stages/stage_1_1.nbt index a15c439c..9a5d986a 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_1_1.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_1_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:742f7f1e4ca7027352a55fbb2ce14543174ca807c744f90f7d1a062960cf87d2 -size 2420 +oid sha256:206620e7e57bfd058a714dd8152cf15451ea4f0e5ebf87b8399eda430711a4db +size 2421 diff --git a/data/minecraft/structure/bastion/units/stages/stage_1_2.nbt b/data/minecraft/structure/bastion/units/stages/stage_1_2.nbt index 39fc3d31..e8b33350 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_1_2.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_1_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0eed4168e4f3ac3a318b092c5de17e0d117a4cbfbafc53d05a3055091d7a2a7b -size 2509 +oid sha256:f8b1cf8791d74b8fed85b8ac4757abcfb07e89e0385264155b292b6a91416b5c +size 2510 diff --git a/data/minecraft/structure/bastion/units/stages/stage_1_3.nbt b/data/minecraft/structure/bastion/units/stages/stage_1_3.nbt index e5b2f548..94e93f74 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_1_3.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_1_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0e1527a1a5f853e75a57670af8920e2aa7dc33ca1bda803a18792024a1c5d36b -size 2485 +oid sha256:a127ad91c56d36808c25e988162d6e7e064944059050462f1fb8a91c5975d578 +size 2486 diff --git a/data/minecraft/structure/bastion/units/stages/stage_2_0.nbt b/data/minecraft/structure/bastion/units/stages/stage_2_0.nbt index a11a5a25..4c5f2e6c 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_2_0.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_2_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0a5805791f7b63c15c0e1459191892ef398126da07f79d8925afc4fb7381f05f -size 2422 +oid sha256:f0e8474e662a84540ce82a4c4d2474bbb5997ae8ed6d564e27027fa0d4a19031 +size 2423 diff --git a/data/minecraft/structure/bastion/units/stages/stage_2_1.nbt b/data/minecraft/structure/bastion/units/stages/stage_2_1.nbt index 3ab5f1d0..d087931c 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_2_1.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_2_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c488b447cd3c5082454c70270498f5da01b028fca659f8c5faa8114c00f512ae -size 2459 +oid sha256:261f9362ed18a8669fdc1650d9f12ae8dc2204280e0c40e801c3e65bdbffa67e +size 2461 diff --git a/data/minecraft/structure/bastion/units/stages/stage_3_0.nbt b/data/minecraft/structure/bastion/units/stages/stage_3_0.nbt index b63998a4..7f69b564 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_3_0.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_3_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4ca9b6afedb034bab7cbae1bf43f838b103a87b511d36c42346c3be93b1b60f4 -size 632 +oid sha256:9fd0b70d7b857eff72621459e79f364e08ec09c135dbd1146641da5458ef85ac +size 633 diff --git a/data/minecraft/structure/bastion/units/stages/stage_3_1.nbt b/data/minecraft/structure/bastion/units/stages/stage_3_1.nbt index 70230e38..42dd9065 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_3_1.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_3_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7527a5e730663c5983944886f4b0723c27023c7a92df25d954b4a7a23e4c31f2 -size 689 +oid sha256:ac9c2b36496ccd90ed1eeaf51d57bb9ae740e3761966c47ccf37873ef81e9699 +size 690 diff --git a/data/minecraft/structure/bastion/units/stages/stage_3_2.nbt b/data/minecraft/structure/bastion/units/stages/stage_3_2.nbt index 00909102..da400a0f 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_3_2.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_3_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e238b8285e0cac7d0827899775cd94abb1bc6c820196999b8249dc51389ad23 -size 628 +oid sha256:3e8146b7b4417642b6e648302757c2b4c68e0b9712a701b45738ac1239fd7388 +size 629 diff --git a/data/minecraft/structure/bastion/units/stages/stage_3_3.nbt b/data/minecraft/structure/bastion/units/stages/stage_3_3.nbt index 5d66bced..8e66d3df 100644 --- a/data/minecraft/structure/bastion/units/stages/stage_3_3.nbt +++ b/data/minecraft/structure/bastion/units/stages/stage_3_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:43d643a7b140fc951492122afa76d865a256875927fc868d0d94ecb43a9b4ecb -size 655 +oid sha256:f76af5ca523b040112960c0a505b3ece77e5992159e790511ce6a8caaeece986 +size 656 diff --git a/data/minecraft/structure/bastion/units/wall_units/edge_0_large.nbt b/data/minecraft/structure/bastion/units/wall_units/edge_0_large.nbt index e7a48970..77dff64d 100644 --- a/data/minecraft/structure/bastion/units/wall_units/edge_0_large.nbt +++ b/data/minecraft/structure/bastion/units/wall_units/edge_0_large.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:45020723f656784a902a76139c41b5998f6df288f86367771c1c52c411ff9fa5 -size 2821 +oid sha256:3bb8fe7dbf20c95cfbdef81d266f4d61ff4a6e012cac2bb2eb4c60455c4e96df +size 2822 diff --git a/data/minecraft/structure/bastion/units/wall_units/unit_0.nbt b/data/minecraft/structure/bastion/units/wall_units/unit_0.nbt index d6b77261..313e43b6 100644 --- a/data/minecraft/structure/bastion/units/wall_units/unit_0.nbt +++ b/data/minecraft/structure/bastion/units/wall_units/unit_0.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c27a5080ec7a86fa5edfc004642df0b71bb982f8f485efd8c66455ea40b93a4f -size 2499 +oid sha256:2fa14f1ca19141fce88a0dcb3ef405a0a38a510864275c0614a23fb0c75c6e1e +size 2500 diff --git a/data/minecraft/structure/bastion/units/walls/connected_wall.nbt b/data/minecraft/structure/bastion/units/walls/connected_wall.nbt index 90e80d6a..94d91ea0 100644 --- a/data/minecraft/structure/bastion/units/walls/connected_wall.nbt +++ b/data/minecraft/structure/bastion/units/walls/connected_wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:447c0a3b847b96ae609d9df9ffb5cdcf67182183d185f068b654bfcbf863962d -size 15616 +oid sha256:6dc8eb6a234a3b03e2d392d470784185a2c6af51c1f23466313a42d821d7f08e +size 15617 diff --git a/data/minecraft/structure/bastion/units/walls/wall_base.nbt b/data/minecraft/structure/bastion/units/walls/wall_base.nbt index 06478d2b..7231189a 100644 --- a/data/minecraft/structure/bastion/units/walls/wall_base.nbt +++ b/data/minecraft/structure/bastion/units/walls/wall_base.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1e5907afd081aed2e6e4a88e379e858fd4886c1940efd0e09be3692af4b563d2 -size 16903 +oid sha256:ba9597ee197d511ddc2126906822a4d8e0bb1c575f8cf0f225b519cb97c9fc9e +size 16904 diff --git a/data/minecraft/structure/empty.nbt b/data/minecraft/structure/empty.nbt new file mode 100644 index 00000000..b6c1aec9 --- /dev/null +++ b/data/minecraft/structure/empty.nbt @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:20e3954591985dd1a07905e837d8f87a6b32c431c03add42c79aa133b7fa3acc +size 125 diff --git a/data/minecraft/structure/end_city/base_floor.nbt b/data/minecraft/structure/end_city/base_floor.nbt index 7beee710..0109c8e9 100644 --- a/data/minecraft/structure/end_city/base_floor.nbt +++ b/data/minecraft/structure/end_city/base_floor.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d33bebb178493b32d77266ca96890bf78155ebc19f8ea21ee2eabf39edef9c1b -size 1686 +oid sha256:346bfce557fb954deb66d6a86cf54a074b82b33c999fa10b0c69af03b374d613 +size 1687 diff --git a/data/minecraft/structure/end_city/base_roof.nbt b/data/minecraft/structure/end_city/base_roof.nbt index 0dadf555..83be8023 100644 --- a/data/minecraft/structure/end_city/base_roof.nbt +++ b/data/minecraft/structure/end_city/base_roof.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:951a1124ae92d8b483395df2befeb125dd5e6a693075e91df4eea0f34ce5f0b2 -size 1179 +oid sha256:b3baed4b258f7c839fe54cb16f4073a0fec44dec33a9cd1df0380907032addf1 +size 1180 diff --git a/data/minecraft/structure/end_city/bridge_end.nbt b/data/minecraft/structure/end_city/bridge_end.nbt index 9ff84ae8..910a0489 100644 --- a/data/minecraft/structure/end_city/bridge_end.nbt +++ b/data/minecraft/structure/end_city/bridge_end.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2bc3e45a0f966769c8beb362a74e337b0631b938fd94c9fce2eca9545c4e4d78 -size 474 +oid sha256:13e527f87c4e80dcf5e0ea601f655249e816cb17fb7609c2bc46ce3fd623eb04 +size 475 diff --git a/data/minecraft/structure/end_city/bridge_gentle_stairs.nbt b/data/minecraft/structure/end_city/bridge_gentle_stairs.nbt index 7af5e6e7..21295946 100644 --- a/data/minecraft/structure/end_city/bridge_gentle_stairs.nbt +++ b/data/minecraft/structure/end_city/bridge_gentle_stairs.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:594ea8d5ecaaf71b198b7075e7d40e0d88b8f35d5df921d1de47d1b3b2f2a91e -size 1141 +oid sha256:10b9569847e12c5f7a03f8188b12240f04c2d0f05149ffcce2a793fb7015c2e1 +size 1143 diff --git a/data/minecraft/structure/end_city/bridge_piece.nbt b/data/minecraft/structure/end_city/bridge_piece.nbt index 86e8d95d..b9a4c8a3 100644 --- a/data/minecraft/structure/end_city/bridge_piece.nbt +++ b/data/minecraft/structure/end_city/bridge_piece.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:239717279dbdfa0ce5d65c70902abd27ba76b586c8efcabd3c8170c6e0d9f8aa -size 598 +oid sha256:03ff1b030765ae5515cc1f76d9d8aaaa993e571e4da965c3169343a2e8120232 +size 599 diff --git a/data/minecraft/structure/end_city/bridge_steep_stairs.nbt b/data/minecraft/structure/end_city/bridge_steep_stairs.nbt index 12b29479..c7581ddd 100644 --- a/data/minecraft/structure/end_city/bridge_steep_stairs.nbt +++ b/data/minecraft/structure/end_city/bridge_steep_stairs.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4a981289e38ece609015acefa9a9529491ad2de3c17bd1c9be308c5276fe1df2 -size 713 +oid sha256:a54933c9e11e5855d11c21ab2958e5e165b1063611f09faa9d8f8f8e5a7767a6 +size 714 diff --git a/data/minecraft/structure/end_city/fat_tower_base.nbt b/data/minecraft/structure/end_city/fat_tower_base.nbt index 23d011dc..47a852c4 100644 --- a/data/minecraft/structure/end_city/fat_tower_base.nbt +++ b/data/minecraft/structure/end_city/fat_tower_base.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9d30d19f349c4b772f1dea9fc10617af23f24d907829ef7eceed195d92b34d3f -size 2337 +oid sha256:c023918a5ce6f700544285133fad412b08c758d811bccec5591e869ebb2e93d4 +size 2338 diff --git a/data/minecraft/structure/end_city/fat_tower_middle.nbt b/data/minecraft/structure/end_city/fat_tower_middle.nbt index 6d9c6cdb..c7353e5f 100644 --- a/data/minecraft/structure/end_city/fat_tower_middle.nbt +++ b/data/minecraft/structure/end_city/fat_tower_middle.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:956951f0b0829696ea9767987fd11df2e5510febd5fc2cb537f83fa3d1b83363 -size 4467 +oid sha256:0e37900c1b075d98e69505e9635c4856481e3c8b1f751d0daf5e19115ab55769 +size 4468 diff --git a/data/minecraft/structure/end_city/fat_tower_top.nbt b/data/minecraft/structure/end_city/fat_tower_top.nbt index 642c0f5c..14438ab5 100644 --- a/data/minecraft/structure/end_city/fat_tower_top.nbt +++ b/data/minecraft/structure/end_city/fat_tower_top.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5cfd0131aa1c7679aeab6e2d74ac796629e0bcbd1beb058d082534438a1b651e -size 5958 +oid sha256:61c1ac5d569a6422caf50a6b20da2273591e6c47bfd4a418e23d210678080bbf +size 5960 diff --git a/data/minecraft/structure/end_city/second_floor_1.nbt b/data/minecraft/structure/end_city/second_floor_1.nbt index aeb5349d..b027cd9c 100644 --- a/data/minecraft/structure/end_city/second_floor_1.nbt +++ b/data/minecraft/structure/end_city/second_floor_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ec5d2d16653c74f694fe8412c9e4ec2dc041221442c2ce1e23a27027302129ff -size 3715 +oid sha256:26c0b3778d488215a2038472bdfac6fd5301a7bbf3a19b69015d0583e770268b +size 3716 diff --git a/data/minecraft/structure/end_city/second_floor_2.nbt b/data/minecraft/structure/end_city/second_floor_2.nbt index 8cba4869..fc5c01e3 100644 --- a/data/minecraft/structure/end_city/second_floor_2.nbt +++ b/data/minecraft/structure/end_city/second_floor_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:646abf3645c9d1be63576369a7301e9632ddf22b0b88961a9bdcfd313f180fc5 -size 3968 +oid sha256:35b025abb80fbe03389a14cfbcd0e51106be4b5930d19055e9c8cefdeb60c2ee +size 3970 diff --git a/data/minecraft/structure/end_city/second_roof.nbt b/data/minecraft/structure/end_city/second_roof.nbt index c99212b9..e4cb8249 100644 --- a/data/minecraft/structure/end_city/second_roof.nbt +++ b/data/minecraft/structure/end_city/second_roof.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:64bd92e507532f41b0fb488afaa7633ebc8242d2acd000193f311caa6d34cbba -size 1426 +oid sha256:0eaab91df6bf412f6f785fc0cc456211510d89faee2a322363889beb75908629 +size 1427 diff --git a/data/minecraft/structure/end_city/ship.nbt b/data/minecraft/structure/end_city/ship.nbt index 6e639bb9..95ff2bbe 100644 --- a/data/minecraft/structure/end_city/ship.nbt +++ b/data/minecraft/structure/end_city/ship.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2a8f97894def86c5e2fee43b1168c22e7012e8177e17fefcc4393a810bcaf718 -size 26444 +oid sha256:5e112c4114622650bc278bd76f013458e121b2c75d2ebee1d70a9103a9c258fc +size 26445 diff --git a/data/minecraft/structure/end_city/third_floor_1.nbt b/data/minecraft/structure/end_city/third_floor_1.nbt index e221d0ed..784c4f77 100644 --- a/data/minecraft/structure/end_city/third_floor_1.nbt +++ b/data/minecraft/structure/end_city/third_floor_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b5f61d414d1e5a4ca0ca58465747386b5bf9212d7812348e03d184e6597517fc -size 4786 +oid sha256:1f001eaf4ec75aac48b942f276a3bf50ec3edb7b33a9e0a5ff1c4fc1966d3638 +size 4787 diff --git a/data/minecraft/structure/end_city/third_floor_2.nbt b/data/minecraft/structure/end_city/third_floor_2.nbt index a12336bf..9be436bf 100644 --- a/data/minecraft/structure/end_city/third_floor_2.nbt +++ b/data/minecraft/structure/end_city/third_floor_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ec66ca8842606bff3e4b8235ac4c8476564c81799871e44abc0b1804f2879786 -size 5158 +oid sha256:a9ac78e3c477ec32f35cb4d1759d9c12704cb053b9fe75cfe2fb92b485026c13 +size 5159 diff --git a/data/minecraft/structure/end_city/third_roof.nbt b/data/minecraft/structure/end_city/third_roof.nbt index 5d36e3db..4ffccf76 100644 --- a/data/minecraft/structure/end_city/third_roof.nbt +++ b/data/minecraft/structure/end_city/third_roof.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:483480843093fc2297ed30ad538c9689c5afec40d0668f0e59b923be84861f57 -size 1830 +oid sha256:13aa79f7b0639245bcc6d9f83322a77781a79546fd384a89285d48918f59f255 +size 1831 diff --git a/data/minecraft/structure/end_city/tower_base.nbt b/data/minecraft/structure/end_city/tower_base.nbt index fb5b36a6..16384553 100644 --- a/data/minecraft/structure/end_city/tower_base.nbt +++ b/data/minecraft/structure/end_city/tower_base.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1a37909898a827804e89930152d2325f4bf58b6efba201205ebab332783010e6 -size 932 +oid sha256:98a082ac23cf5ff676382c9c0a7c820c865e3b24b069266812948b1512509f13 +size 933 diff --git a/data/minecraft/structure/end_city/tower_floor.nbt b/data/minecraft/structure/end_city/tower_floor.nbt index 29cb982a..23baadb9 100644 --- a/data/minecraft/structure/end_city/tower_floor.nbt +++ b/data/minecraft/structure/end_city/tower_floor.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7837972b3379baf9b683b3782d16417f55c473824b2f38c5f5e472d5299254ba -size 979 +oid sha256:9b74b7884fda52a40d80580e6cba4743fade8a18f3e311db897a60600fce3420 +size 980 diff --git a/data/minecraft/structure/end_city/tower_piece.nbt b/data/minecraft/structure/end_city/tower_piece.nbt index 6fe47047..25d7157e 100644 --- a/data/minecraft/structure/end_city/tower_piece.nbt +++ b/data/minecraft/structure/end_city/tower_piece.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aa37d27c3744978a54de448dc45033ae18d58ffafa1309202c1fb6f440a137d7 -size 897 +oid sha256:f3467b086120eb08ee889061396d3a88e353279e1d41a49a72c465089e0a07d9 +size 898 diff --git a/data/minecraft/structure/end_city/tower_top.nbt b/data/minecraft/structure/end_city/tower_top.nbt index ae7c7160..d1b463aa 100644 --- a/data/minecraft/structure/end_city/tower_top.nbt +++ b/data/minecraft/structure/end_city/tower_top.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9938d809319779adafd43a763dde7f4e85c084051e2887a283be7160a8fadebc -size 2034 +oid sha256:93dd86c5d1ca0c9efde859e18013a82ebf9e64266607028a7413fd06decbff18 +size 2036 diff --git a/data/minecraft/structure/fossil/skull_1.nbt b/data/minecraft/structure/fossil/skull_1.nbt index c991249a..5657a63d 100644 --- a/data/minecraft/structure/fossil/skull_1.nbt +++ b/data/minecraft/structure/fossil/skull_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:80ab9628373a151bd8c031aefae36122a3257601a5045e8ac1549807c6e681db -size 441 +oid sha256:56dd3abf23a9190172c68ebd27c351a833cac3372b3c0f95095ce9dcf35d9d12 +size 442 diff --git a/data/minecraft/structure/fossil/skull_1_coal.nbt b/data/minecraft/structure/fossil/skull_1_coal.nbt index b86f3010..162069b9 100644 --- a/data/minecraft/structure/fossil/skull_1_coal.nbt +++ b/data/minecraft/structure/fossil/skull_1_coal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f60bdf856fe4335a790222b2ba4bd12dd2f012c45ed9953550cbdfd42580480 -size 395 +oid sha256:963b965694e23e206fa5cc6c12487c55cf5f985d2f51f723444818bee9e6f506 +size 396 diff --git a/data/minecraft/structure/fossil/skull_2.nbt b/data/minecraft/structure/fossil/skull_2.nbt index 3384b0f5..1a4ae3e4 100644 --- a/data/minecraft/structure/fossil/skull_2.nbt +++ b/data/minecraft/structure/fossil/skull_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cbfadaa2adff95bfe2cc15aa39d6265af8f9cbc2121c632a318e2114a10798c9 -size 397 +oid sha256:a2ee092118d3ab0b979584098a282a5f706fb6e92a1bff0c3dbe764692d22530 +size 398 diff --git a/data/minecraft/structure/fossil/skull_2_coal.nbt b/data/minecraft/structure/fossil/skull_2_coal.nbt index 796e80dd..dbe9ec45 100644 --- a/data/minecraft/structure/fossil/skull_2_coal.nbt +++ b/data/minecraft/structure/fossil/skull_2_coal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:204f8289772b5e8deef71ad259cf3fe1598706afde743cd58180d032587a3a45 -size 344 +oid sha256:dbb6d58ff0df7d5dc3c8acef39d65103793ee250ae6f5982e85cdd231ca31144 +size 346 diff --git a/data/minecraft/structure/fossil/skull_3.nbt b/data/minecraft/structure/fossil/skull_3.nbt index 8dcf5a02..aa3d8d3e 100644 --- a/data/minecraft/structure/fossil/skull_3.nbt +++ b/data/minecraft/structure/fossil/skull_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a3ca225506640089c6e4666eca04de940adc6b7d69a38c568f8cd101df951e8a -size 347 +oid sha256:81f783dc5ed4657bda93c5bf9742fa00c825773dc1643d6a07b13d3228de6035 +size 348 diff --git a/data/minecraft/structure/fossil/skull_3_coal.nbt b/data/minecraft/structure/fossil/skull_3_coal.nbt index e9b69041..3ae33555 100644 --- a/data/minecraft/structure/fossil/skull_3_coal.nbt +++ b/data/minecraft/structure/fossil/skull_3_coal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bbe944c8b0ae7d4920b4c12dca6480ce9d57349144b13accb03d57e079806cea -size 316 +oid sha256:8d0dcd14772d827a860a54d9d1ac35f0e3f97f1f559666a3dcbdf62c9c5cfc8e +size 318 diff --git a/data/minecraft/structure/fossil/skull_4.nbt b/data/minecraft/structure/fossil/skull_4.nbt index 523ad40b..d0a2acfa 100644 --- a/data/minecraft/structure/fossil/skull_4.nbt +++ b/data/minecraft/structure/fossil/skull_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:218ba7866872f4e846cf245a5d3267323cea57036ffedf759774403984b0614d -size 269 +oid sha256:a03515c8385b6f1e58aacf448138ae793a31fbd10eed00f6a13110e9aeed21c9 +size 270 diff --git a/data/minecraft/structure/fossil/skull_4_coal.nbt b/data/minecraft/structure/fossil/skull_4_coal.nbt index a5e072c2..8a1e6b87 100644 --- a/data/minecraft/structure/fossil/skull_4_coal.nbt +++ b/data/minecraft/structure/fossil/skull_4_coal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:23b59489339400ce1b0b024a53145614889ef9a707d9e3a0739025f3e320939b -size 234 +oid sha256:8e9ba2a82c6662bf42ef650d20d7c8f19e47f13b02f511ca125e86968c60d332 +size 236 diff --git a/data/minecraft/structure/fossil/spine_1.nbt b/data/minecraft/structure/fossil/spine_1.nbt index ca68596c..df9fb36c 100644 --- a/data/minecraft/structure/fossil/spine_1.nbt +++ b/data/minecraft/structure/fossil/spine_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bfae93d1777a839afd072f3c434809e9772284b3da8fb6600eea0b9bc4f55107 -size 271 +oid sha256:a83a94441cd4dd26e7c5c51b6ca0691b82079d3a160762cc78b5c4a16342a1f9 +size 272 diff --git a/data/minecraft/structure/fossil/spine_1_coal.nbt b/data/minecraft/structure/fossil/spine_1_coal.nbt index 8ceada2c..e66bf147 100644 --- a/data/minecraft/structure/fossil/spine_1_coal.nbt +++ b/data/minecraft/structure/fossil/spine_1_coal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:93fdcd8c8e70967ae78ff2acb2ff1a67454a56bcc41b3105414c199882f84266 -size 251 +oid sha256:c13d78e136a398c2416f9e9cea3dfd1723b37e679a1c282d130247e71e1fcd38 +size 252 diff --git a/data/minecraft/structure/fossil/spine_2.nbt b/data/minecraft/structure/fossil/spine_2.nbt index 2265ac3a..5c6c71d3 100644 --- a/data/minecraft/structure/fossil/spine_2.nbt +++ b/data/minecraft/structure/fossil/spine_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c0d59528cc48ad0efbbf87903e27117ed5b2ea1e647eb6d20575123caeb9c720 -size 360 +oid sha256:48c995f2c544103e9b4a822d9f27120fa2b47cbd7cc0100aac7ba5072656fbec +size 362 diff --git a/data/minecraft/structure/fossil/spine_2_coal.nbt b/data/minecraft/structure/fossil/spine_2_coal.nbt index 55400c14..1eeb5468 100644 --- a/data/minecraft/structure/fossil/spine_2_coal.nbt +++ b/data/minecraft/structure/fossil/spine_2_coal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:89f2c1508135f4afdd9fa10130170b0e1bf3e3f84bbd1a82e8be91c5ff4209e0 -size 324 +oid sha256:41004dfb3d55cbe4f640a832b0974f5317dc69e6c598a47d5cd17dfcaedf016f +size 325 diff --git a/data/minecraft/structure/fossil/spine_3.nbt b/data/minecraft/structure/fossil/spine_3.nbt index 06f92603..7ba732cc 100644 --- a/data/minecraft/structure/fossil/spine_3.nbt +++ b/data/minecraft/structure/fossil/spine_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1b740fd27a05b852a0a29b48c0781ed837feb357d9e909a4f882e8f39c885760 -size 456 +oid sha256:4ddd6619e889609969db8bfc55786a60bd6bf445d98f64530e9124b3c1142fac +size 457 diff --git a/data/minecraft/structure/fossil/spine_3_coal.nbt b/data/minecraft/structure/fossil/spine_3_coal.nbt index dc1a8016..fc66715d 100644 --- a/data/minecraft/structure/fossil/spine_3_coal.nbt +++ b/data/minecraft/structure/fossil/spine_3_coal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c675d822d4b4e96043be207d80a3b604e0989f0115787149a8ea8b3cc733e3db -size 436 +oid sha256:09959f73d34b76c4b2664ace11c0fa640799d63ef423caa6276447c49398e734 +size 437 diff --git a/data/minecraft/structure/fossil/spine_4.nbt b/data/minecraft/structure/fossil/spine_4.nbt index bb2037ed..94cfecd7 100644 --- a/data/minecraft/structure/fossil/spine_4.nbt +++ b/data/minecraft/structure/fossil/spine_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:577b427b05815478ee0a0e99f5c2f814fb8c5baedba93252ed96530048df554d -size 528 +oid sha256:f23183fd2517f00621390517cc8be9ff5e6658c3288089b70e1d439fc89ec78d +size 529 diff --git a/data/minecraft/structure/fossil/spine_4_coal.nbt b/data/minecraft/structure/fossil/spine_4_coal.nbt index a5ba3d39..3dbcaa08 100644 --- a/data/minecraft/structure/fossil/spine_4_coal.nbt +++ b/data/minecraft/structure/fossil/spine_4_coal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d671376fe7672db0c985e335b21ca7235e1159fddf710679aa6bb554efadb05e -size 481 +oid sha256:d99db2c3e1fcdc1daa05f4e1bb47f4c3b305754df95096f4c92d4713d98c8b80 +size 482 diff --git a/data/minecraft/structure/igloo/bottom.nbt b/data/minecraft/structure/igloo/bottom.nbt index 293af824..b30a9757 100644 --- a/data/minecraft/structure/igloo/bottom.nbt +++ b/data/minecraft/structure/igloo/bottom.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:77f1acb0b16c382ffd9d2abb0a6af3fd76b313f95162b6665a43be9f074f77d1 -size 2777 +oid sha256:f8e1207a54f0554e620d6c62b36cac8f13c513ca8d1af6ed9d5ad5e17e4d741b +size 2732 diff --git a/data/minecraft/structure/igloo/middle.nbt b/data/minecraft/structure/igloo/middle.nbt index a89d56e9..7eb77598 100644 --- a/data/minecraft/structure/igloo/middle.nbt +++ b/data/minecraft/structure/igloo/middle.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d0c63aba5be0821ffba6d64fe65a27eb855c2ca0db07dae5ab2b1ff7fc6d4d5e -size 236 +oid sha256:6b952c9d51b898137f3f54e5edd6d88b8de7200cecb7e6d450a4b43aa89c945a +size 237 diff --git a/data/minecraft/structure/igloo/top.nbt b/data/minecraft/structure/igloo/top.nbt index 1120d6ea..d34830fe 100644 --- a/data/minecraft/structure/igloo/top.nbt +++ b/data/minecraft/structure/igloo/top.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d4cc65f6b36574993ea33cfa9e711a2e866637c4d6c8bf3c733d0e31794031f -size 924 +oid sha256:8650b4c724935c16fc3042b5cf647957f1b8a9fa0bac95ab50a3f89a5c3853e2 +size 925 diff --git a/data/minecraft/structure/nether_fossils/fossil_1.nbt b/data/minecraft/structure/nether_fossils/fossil_1.nbt index 60979b61..aff45a41 100644 --- a/data/minecraft/structure/nether_fossils/fossil_1.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ca70aaad5ef2d217df2c17bb912517182b29ba63f157aefa97669bb54f6cf5c3 -size 397 +oid sha256:fdd49c588fbd2b4cbddef15b72eda592111ad9910f038e0638742029f7ab450f +size 398 diff --git a/data/minecraft/structure/nether_fossils/fossil_10.nbt b/data/minecraft/structure/nether_fossils/fossil_10.nbt index 6cd3c26a..f364e143 100644 --- a/data/minecraft/structure/nether_fossils/fossil_10.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_10.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:513213c37258ea11144db938414486121a78af8166015c99130470bd4ce28638 -size 237 +oid sha256:dd186459f007d2177be95df660e9d7304de732f019fa1a21f27efeea14d5164d +size 238 diff --git a/data/minecraft/structure/nether_fossils/fossil_11.nbt b/data/minecraft/structure/nether_fossils/fossil_11.nbt index ceb8b498..d2776184 100644 --- a/data/minecraft/structure/nether_fossils/fossil_11.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_11.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:80651127daa4ee8416c8e2d907b073ac11201b7200d07f3891962123d9a760b8 -size 674 +oid sha256:7dbd25e2626eac8f5ab540a2b83a0fe1232730612e33c5dbb13e056c3e9d2632 +size 675 diff --git a/data/minecraft/structure/nether_fossils/fossil_12.nbt b/data/minecraft/structure/nether_fossils/fossil_12.nbt index 75db1b9c..6b45fdc6 100644 --- a/data/minecraft/structure/nether_fossils/fossil_12.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_12.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7d17ba6ef330b0135490583036615a36ed6a5155dd7d93c2cef4243e08e601ff -size 316 +oid sha256:6aaebd4181e3b73d05326905ce04bd7e628f0465172b9e9e05958d730c650748 +size 318 diff --git a/data/minecraft/structure/nether_fossils/fossil_13.nbt b/data/minecraft/structure/nether_fossils/fossil_13.nbt index af252860..be14d3ba 100644 --- a/data/minecraft/structure/nether_fossils/fossil_13.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_13.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0b8b7bbdefb3f68b894f9d879471b500cb57a6f8e31c2ed50cea7f4dff67ff4f -size 523 +oid sha256:e2b4227ed3b77effcac82d86cc7f663833b4a9c4c85b753a1aa50a0a689844f6 +size 525 diff --git a/data/minecraft/structure/nether_fossils/fossil_14.nbt b/data/minecraft/structure/nether_fossils/fossil_14.nbt index 8341882e..fcdea3ab 100644 --- a/data/minecraft/structure/nether_fossils/fossil_14.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_14.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8c580c8fe946be18c2357439fb7881f00487a79f4d3488f7900b33ed03487919 -size 938 +oid sha256:4dde7e58b8fcf47cc90475425c1d67b44a2d46c1a0fb0f4a4179db0cdf84a77f +size 939 diff --git a/data/minecraft/structure/nether_fossils/fossil_2.nbt b/data/minecraft/structure/nether_fossils/fossil_2.nbt index e4560484..9e78ef09 100644 --- a/data/minecraft/structure/nether_fossils/fossil_2.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5d16b8a3adb26f21ea0cb9f423057b69356a27175a379f722be2f8f20bc9e757 -size 258 +oid sha256:109e7f1944c6336a08655f11375d0f4ee69f6ebe6661c935af5405f2d68061da +size 260 diff --git a/data/minecraft/structure/nether_fossils/fossil_3.nbt b/data/minecraft/structure/nether_fossils/fossil_3.nbt index 5a0d8ac6..c03d3204 100644 --- a/data/minecraft/structure/nether_fossils/fossil_3.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:92581ea2711a2a07c1cf81e121716f08f04c747cb34f4e2eca31a9e5bb8124c9 +oid sha256:3574cd9097b97c79a0abab633e57f9ad876ead2118605cf733b217961f7d63a5 size 249 diff --git a/data/minecraft/structure/nether_fossils/fossil_4.nbt b/data/minecraft/structure/nether_fossils/fossil_4.nbt index 7067f49d..a20d98ee 100644 --- a/data/minecraft/structure/nether_fossils/fossil_4.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:789d4012d8b3d95820932cb9329580457f8d25549c0f45b272d5a850b2756fbc -size 211 +oid sha256:08d2dbd98204a2829789ace8a57c517747e3a0ae4af31b760ff0280aba6b5241 +size 212 diff --git a/data/minecraft/structure/nether_fossils/fossil_5.nbt b/data/minecraft/structure/nether_fossils/fossil_5.nbt index f2a786f2..d84e7afd 100644 --- a/data/minecraft/structure/nether_fossils/fossil_5.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0b38462a4dce7788bda78405e241e3fe99a51473c9976fd1851d58aca3f5deca -size 205 +oid sha256:f5112c9739caeef6f27b6a39d065f3626641ba8a4bbca4040c43e1ed119299d7 +size 206 diff --git a/data/minecraft/structure/nether_fossils/fossil_6.nbt b/data/minecraft/structure/nether_fossils/fossil_6.nbt index f37af7d9..11d5a02d 100644 --- a/data/minecraft/structure/nether_fossils/fossil_6.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2c657f2870643f0723eb988a75a810c71c7269306e6217c0bc0ef1fbf5a1d2b9 -size 630 +oid sha256:c65c4e7528903c5b17d5a1e79b02c7e226ebdf940bc3013829a3a9a7a6a525a3 +size 631 diff --git a/data/minecraft/structure/nether_fossils/fossil_7.nbt b/data/minecraft/structure/nether_fossils/fossil_7.nbt index 434c60b8..1f63b760 100644 --- a/data/minecraft/structure/nether_fossils/fossil_7.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3f586c483fb1e0f0dd10307ed44532101408aa677416012d53ae228d829e521b -size 509 +oid sha256:f7b7aae3c464be0d4dd84ffbcb66712a099c88eb07fc66482961e4fd3ddacccb +size 510 diff --git a/data/minecraft/structure/nether_fossils/fossil_8.nbt b/data/minecraft/structure/nether_fossils/fossil_8.nbt index d35ed274..f322c535 100644 --- a/data/minecraft/structure/nether_fossils/fossil_8.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:be2402c82059e7b66acac3e6536aae820b55e65c4b588934fa3f4132f7ac9dfc -size 219 +oid sha256:ccba775285eb55a3a840b72667c5262c1618b81b6009d68f8e9a144e00b5c093 +size 221 diff --git a/data/minecraft/structure/nether_fossils/fossil_9.nbt b/data/minecraft/structure/nether_fossils/fossil_9.nbt index 8f0ad092..68476fb5 100644 --- a/data/minecraft/structure/nether_fossils/fossil_9.nbt +++ b/data/minecraft/structure/nether_fossils/fossil_9.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8eba90a038fd04426bd5eebd6195a255dc45a38d7ce346b77c7c5ab27c31d061 -size 394 +oid sha256:490ddd56993e62d7169f3c0857ef9699b5bbd0e4d6283462b70065c2b2c65ce7 +size 395 diff --git a/data/minecraft/structure/pillager_outpost/base_plate.nbt b/data/minecraft/structure/pillager_outpost/base_plate.nbt index 59359a71..dc96e8b9 100644 --- a/data/minecraft/structure/pillager_outpost/base_plate.nbt +++ b/data/minecraft/structure/pillager_outpost/base_plate.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e3e8a9283f950e3c9c40964e6a1a2ad3c8093146817d91def5365878f22986a +oid sha256:545a463bd09c2ae64003f8a1f11bcc0ea5a7b626832a331d1ee324ae31a90e69 size 19281 diff --git a/data/minecraft/structure/pillager_outpost/feature_cage1.nbt b/data/minecraft/structure/pillager_outpost/feature_cage1.nbt index 6ebc5571..3c527227 100644 --- a/data/minecraft/structure/pillager_outpost/feature_cage1.nbt +++ b/data/minecraft/structure/pillager_outpost/feature_cage1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:622718bb038abe24e17850cea7ed651e31a234af257bb8210747121ffa1e3d6c -size 1662 +oid sha256:15caa2d6898f0372d0885b647bcd1adcff2af4a2678ed30eccc04fc64d0e467a +size 1630 diff --git a/data/minecraft/structure/pillager_outpost/feature_cage2.nbt b/data/minecraft/structure/pillager_outpost/feature_cage2.nbt index c581f7e4..4db861ab 100644 --- a/data/minecraft/structure/pillager_outpost/feature_cage2.nbt +++ b/data/minecraft/structure/pillager_outpost/feature_cage2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8812f9f1f68a8c01edf909e9fc64cfe64bb8aba456a46780411c2ee3242283ce -size 1031 +oid sha256:074860097463fb3ef2bfad768196b79514b8867ed9b26d3c0e7750346ce0fb34 +size 1032 diff --git a/data/minecraft/structure/pillager_outpost/feature_cage_with_allays.nbt b/data/minecraft/structure/pillager_outpost/feature_cage_with_allays.nbt index c15aef13..3c040592 100644 --- a/data/minecraft/structure/pillager_outpost/feature_cage_with_allays.nbt +++ b/data/minecraft/structure/pillager_outpost/feature_cage_with_allays.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:47bd25a52d37d47d7feb6091c262b36e2d89cc81d09c9b5b001c1cab280b2a68 -size 1791 +oid sha256:ec7da568eb209e633d4554bde0fb2a92b515a4c1bdeaa32b9cb057e9751c6877 +size 1756 diff --git a/data/minecraft/structure/pillager_outpost/feature_logs.nbt b/data/minecraft/structure/pillager_outpost/feature_logs.nbt index 2fba6052..abe72b6c 100644 --- a/data/minecraft/structure/pillager_outpost/feature_logs.nbt +++ b/data/minecraft/structure/pillager_outpost/feature_logs.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a9d36b8929c0114cf55854b150c97d9077dd6ebc4713a91dc69c79445b4bbf78 -size 658 +oid sha256:aacacf97d90f7fd5ad581d85b5f4286a252dc52a5a8b4f519f3bd0d8f294a99c +size 659 diff --git a/data/minecraft/structure/pillager_outpost/feature_plate.nbt b/data/minecraft/structure/pillager_outpost/feature_plate.nbt index b6774c35..b8718f35 100644 --- a/data/minecraft/structure/pillager_outpost/feature_plate.nbt +++ b/data/minecraft/structure/pillager_outpost/feature_plate.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:598f9d2ee0826853d4267b9edcf97793c1e338356e2bb8abc674d94e05091fd4 -size 6038 +oid sha256:00719e8430087b80b62ea1652c87a08f1fb747ee6d59cad5fb46b4c37e72111e +size 6040 diff --git a/data/minecraft/structure/pillager_outpost/feature_targets.nbt b/data/minecraft/structure/pillager_outpost/feature_targets.nbt index ca071acd..4652ddb5 100644 --- a/data/minecraft/structure/pillager_outpost/feature_targets.nbt +++ b/data/minecraft/structure/pillager_outpost/feature_targets.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:78dd174458271278901cfe883e258594db4fc76135127976e6bc03cda73b588d -size 578 +oid sha256:970201a3d21627be3d656007d84b160bc5135284f87e584f90d3a7bf36e690f9 +size 579 diff --git a/data/minecraft/structure/pillager_outpost/feature_tent1.nbt b/data/minecraft/structure/pillager_outpost/feature_tent1.nbt index f0ef7bc2..12b63e53 100644 --- a/data/minecraft/structure/pillager_outpost/feature_tent1.nbt +++ b/data/minecraft/structure/pillager_outpost/feature_tent1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:77311436e6998ae8866a0918c911f04ffd8591c6ccc1d5c289576f2af7266ee1 -size 856 +oid sha256:774bb0e5d388622f0cd909374be9d88c68b91000c820e1a06e2bee7601d474c5 +size 858 diff --git a/data/minecraft/structure/pillager_outpost/feature_tent2.nbt b/data/minecraft/structure/pillager_outpost/feature_tent2.nbt index ca89178e..2821f11f 100644 --- a/data/minecraft/structure/pillager_outpost/feature_tent2.nbt +++ b/data/minecraft/structure/pillager_outpost/feature_tent2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aaaa29e421a859dc9f93c9cc94cac1ba781cd774120def90c369f16e57873b37 -size 868 +oid sha256:b28790d9aff3aba91cbfacbe3ed1f045c88d6cc49734225162b1dccbe64a4acb +size 869 diff --git a/data/minecraft/structure/pillager_outpost/watchtower.nbt b/data/minecraft/structure/pillager_outpost/watchtower.nbt index 08d372ab..accac53b 100644 --- a/data/minecraft/structure/pillager_outpost/watchtower.nbt +++ b/data/minecraft/structure/pillager_outpost/watchtower.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:adc61dc5e7505296c88800bdfc69ad2366bb818fc538c0d54cbfacf224b9d120 -size 14623 +oid sha256:77d9d16adb47c3bc41577688097bfae24ef61416470205b744be0cf6e5e2c614 +size 14585 diff --git a/data/minecraft/structure/pillager_outpost/watchtower_overgrown.nbt b/data/minecraft/structure/pillager_outpost/watchtower_overgrown.nbt index d2ced393..9eda14f8 100644 --- a/data/minecraft/structure/pillager_outpost/watchtower_overgrown.nbt +++ b/data/minecraft/structure/pillager_outpost/watchtower_overgrown.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:00292e6b7bb955aa291da0d26377b246f38ddaf5bf26a79ffeb79eaf7257e232 -size 16062 +oid sha256:e494109b801e6c9fb411a45b1d90a50ffc1c843c36b38e7bfc9439ad6fff404a +size 16026 diff --git a/data/minecraft/structure/ruined_portal/giant_portal_1.nbt b/data/minecraft/structure/ruined_portal/giant_portal_1.nbt index 41444d17..5bf04e54 100644 --- a/data/minecraft/structure/ruined_portal/giant_portal_1.nbt +++ b/data/minecraft/structure/ruined_portal/giant_portal_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4cdcc34df38cc644ab3b148c1481b41ed1436814654b4c106c1c36e4bb6d3f75 -size 7199 +oid sha256:407df76c96650e418fa374304cf34099cb5d86ed406c31b641b1e5e1490e19cc +size 7201 diff --git a/data/minecraft/structure/ruined_portal/giant_portal_2.nbt b/data/minecraft/structure/ruined_portal/giant_portal_2.nbt index 76da1a84..62a8d256 100644 --- a/data/minecraft/structure/ruined_portal/giant_portal_2.nbt +++ b/data/minecraft/structure/ruined_portal/giant_portal_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3791b39779a75e0dfb0688b0c87ba6301d3675a8e3d8c026a841191f6561b930 -size 6837 +oid sha256:36bbce074e7e8d1f4f8759d9dd1a51d2a0d9d8edf06059d196326bd87b89b1ef +size 6838 diff --git a/data/minecraft/structure/ruined_portal/giant_portal_3.nbt b/data/minecraft/structure/ruined_portal/giant_portal_3.nbt index 6f6edd09..cc566371 100644 --- a/data/minecraft/structure/ruined_portal/giant_portal_3.nbt +++ b/data/minecraft/structure/ruined_portal/giant_portal_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8eb9de5917d23f45345157cbfd9f6d10b70ddb6f1415e58ae0a0b4bd96f3efbf -size 9898 +oid sha256:e8e2be323fd63be8cfbd016ff268231dc018d5fd0f9eb44f91128330fdbf52b8 +size 9899 diff --git a/data/minecraft/structure/ruined_portal/portal_1.nbt b/data/minecraft/structure/ruined_portal/portal_1.nbt index bfca2fba..79932242 100644 --- a/data/minecraft/structure/ruined_portal/portal_1.nbt +++ b/data/minecraft/structure/ruined_portal/portal_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fb4337778701b25fc9d0913cf01e7f3617e2e2d0f058a073bb78b8a551891dfd -size 1431 +oid sha256:4732799ba5ba60d6bb8a36bffee6c9bf8206bb8213ebfb7c66925ffab317f937 +size 1432 diff --git a/data/minecraft/structure/ruined_portal/portal_10.nbt b/data/minecraft/structure/ruined_portal/portal_10.nbt index 4a5c0143..b08683ea 100644 --- a/data/minecraft/structure/ruined_portal/portal_10.nbt +++ b/data/minecraft/structure/ruined_portal/portal_10.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:303446efb62919f4a70e03d3a52df92d002b5a5c1dc15234cfa09b70019e1716 -size 2878 +oid sha256:35c91ecf224e8f822b0891b6e20a33585d3d71b57dcadb7e9d107845ad50dc52 +size 2880 diff --git a/data/minecraft/structure/ruined_portal/portal_2.nbt b/data/minecraft/structure/ruined_portal/portal_2.nbt index 00e5123e..ccc914e1 100644 --- a/data/minecraft/structure/ruined_portal/portal_2.nbt +++ b/data/minecraft/structure/ruined_portal/portal_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b35405abc44e52b38a35bf32cfed6812fef7fb7cf3ea046997922d043f4ac0ad +oid sha256:b30b3c1cd081c6f967c0fd8d1c9a674629b5cf118b289372de2e155d048708c2 size 2762 diff --git a/data/minecraft/structure/ruined_portal/portal_3.nbt b/data/minecraft/structure/ruined_portal/portal_3.nbt index 478118ef..29a6d0c7 100644 --- a/data/minecraft/structure/ruined_portal/portal_3.nbt +++ b/data/minecraft/structure/ruined_portal/portal_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dbff37f9023dbcc183ab89d5c5edec0e23dd8d365e70d2336542d73b12e413ed -size 1994 +oid sha256:2172d865f8f2a96e76944d258640732097e61ebf5d513726264e08614fe51f9a +size 1995 diff --git a/data/minecraft/structure/ruined_portal/portal_4.nbt b/data/minecraft/structure/ruined_portal/portal_4.nbt index 54921d0e..9783efe1 100644 --- a/data/minecraft/structure/ruined_portal/portal_4.nbt +++ b/data/minecraft/structure/ruined_portal/portal_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f47aba0ffdd0171748a6497d4d335be101ab9e57267b0704f465686241165bff -size 1885 +oid sha256:aaee59d7c5670b830e395b707c591237535addfcfe1054ad6905fa5026e68f0f +size 1886 diff --git a/data/minecraft/structure/ruined_portal/portal_5.nbt b/data/minecraft/structure/ruined_portal/portal_5.nbt index c19bf02f..38c53431 100644 --- a/data/minecraft/structure/ruined_portal/portal_5.nbt +++ b/data/minecraft/structure/ruined_portal/portal_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:000938220556d2e6b33296edd4fe944cb5e366ba36a2124e7f5e9789fa29e894 -size 2215 +oid sha256:1e78ccbbe0ccd21a11efa9629825ba7597a7212f3c293581f03f54556c82abc8 +size 2217 diff --git a/data/minecraft/structure/ruined_portal/portal_6.nbt b/data/minecraft/structure/ruined_portal/portal_6.nbt index 86e152e3..c6351485 100644 --- a/data/minecraft/structure/ruined_portal/portal_6.nbt +++ b/data/minecraft/structure/ruined_portal/portal_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d56727da8d570340508b61fcc2980fd0db5950c20591e379d709cf1f7f96faf5 -size 982 +oid sha256:6ad6dc668e63b26146f375f00d0d78bbfb2142ac22287a2f1a4e90b1686113fe +size 984 diff --git a/data/minecraft/structure/ruined_portal/portal_7.nbt b/data/minecraft/structure/ruined_portal/portal_7.nbt index c54d3afb..157ccd08 100644 --- a/data/minecraft/structure/ruined_portal/portal_7.nbt +++ b/data/minecraft/structure/ruined_portal/portal_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:44f9bb96e164f3149a6e3642e4700c5295428bf2dddc3d2602f5cc0c37884a81 -size 1830 +oid sha256:5757e27387fd37eec0f8c5bb097a9a0c2dc06a52e195e8797074fe6d2ed6a029 +size 1831 diff --git a/data/minecraft/structure/ruined_portal/portal_8.nbt b/data/minecraft/structure/ruined_portal/portal_8.nbt index 2ed9d05e..1929b7dc 100644 --- a/data/minecraft/structure/ruined_portal/portal_8.nbt +++ b/data/minecraft/structure/ruined_portal/portal_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:575e61b9964f111c35f4770b181aa56c481a7cae6f832b4fba91d298b4df26ca -size 3407 +oid sha256:8d168bd5d1f768556532ea834f5dddd198654601d20ecd37c421e211f2fb8901 +size 3408 diff --git a/data/minecraft/structure/ruined_portal/portal_9.nbt b/data/minecraft/structure/ruined_portal/portal_9.nbt index 0c14adad..35ca4523 100644 --- a/data/minecraft/structure/ruined_portal/portal_9.nbt +++ b/data/minecraft/structure/ruined_portal/portal_9.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bfa401185de9f31a8f3a63f3a7eaab52d6a99581ef3eb455192485d641629514 -size 2168 +oid sha256:d8f955a5558f029884afe18d3c75b99a61d0c4c746c72ad89ce419cbe5b4c2bb +size 2169 diff --git a/data/minecraft/structure/shipwreck/rightsideup_backhalf.nbt b/data/minecraft/structure/shipwreck/rightsideup_backhalf.nbt index 16d78f55..f07bb63b 100644 --- a/data/minecraft/structure/shipwreck/rightsideup_backhalf.nbt +++ b/data/minecraft/structure/shipwreck/rightsideup_backhalf.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6b0c2436ce27849af2dc387783ca214a04d6d0d54eeedf9341e037ac45319446 -size 2712 +oid sha256:3376ca0a80901bd13612f5598ca15e55d76b644de62593f2bf1d4f28405cd8dc +size 2713 diff --git a/data/minecraft/structure/shipwreck/rightsideup_backhalf_degraded.nbt b/data/minecraft/structure/shipwreck/rightsideup_backhalf_degraded.nbt index f75c28f8..93f8617d 100644 --- a/data/minecraft/structure/shipwreck/rightsideup_backhalf_degraded.nbt +++ b/data/minecraft/structure/shipwreck/rightsideup_backhalf_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d6daaef053fd60a9949c696b57ef3c1f4d7688debf7dc2cfe0a97803f579b2a4 -size 2569 +oid sha256:e37caffe1652f4370bb0c22a5025f632f4d038d35a1712f8808763b121e6d549 +size 2570 diff --git a/data/minecraft/structure/shipwreck/rightsideup_fronthalf.nbt b/data/minecraft/structure/shipwreck/rightsideup_fronthalf.nbt index 63da855d..d4b8c03b 100644 --- a/data/minecraft/structure/shipwreck/rightsideup_fronthalf.nbt +++ b/data/minecraft/structure/shipwreck/rightsideup_fronthalf.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5fd72be9e9fec17e9cf67999bcb4485313557e1fdfa99a746503668a772f5ef7 -size 2475 +oid sha256:5f49bd50e7843b61c35e95d498f76db679c4a987fc576fdfcb21eb173d426f71 +size 2476 diff --git a/data/minecraft/structure/shipwreck/rightsideup_fronthalf_degraded.nbt b/data/minecraft/structure/shipwreck/rightsideup_fronthalf_degraded.nbt index 8ffb7908..575b9889 100644 --- a/data/minecraft/structure/shipwreck/rightsideup_fronthalf_degraded.nbt +++ b/data/minecraft/structure/shipwreck/rightsideup_fronthalf_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ab3cb79731e644e060d3ca78d982c351bb56c772620cae179ba8cfd02eaf272f -size 2252 +oid sha256:6b8120b175def83ad132c5cb90a51bc8131dae55bbdabe156742d2adbd695dde +size 2253 diff --git a/data/minecraft/structure/shipwreck/rightsideup_full.nbt b/data/minecraft/structure/shipwreck/rightsideup_full.nbt index 886608f7..8846f6a6 100644 --- a/data/minecraft/structure/shipwreck/rightsideup_full.nbt +++ b/data/minecraft/structure/shipwreck/rightsideup_full.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e52f8a22011da54f545d4defdda89615620f7ee3ae7bc6aaa53fac5fd89e105 -size 3754 +oid sha256:8da5471014a685b76d0a8a1148fab4cf192e4dab3faaf6e814f59571a0dd14cc +size 3755 diff --git a/data/minecraft/structure/shipwreck/rightsideup_full_degraded.nbt b/data/minecraft/structure/shipwreck/rightsideup_full_degraded.nbt index 531cdb78..6a034a5e 100644 --- a/data/minecraft/structure/shipwreck/rightsideup_full_degraded.nbt +++ b/data/minecraft/structure/shipwreck/rightsideup_full_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6b0eb1a0ab17280b9bd5ae353732cb470db01898c64306e9cc7359b4bb6536cb -size 3527 +oid sha256:a7ef2e951962eba36aec0c60c73f3d324ea678d4048625ad2dba07e7978146cb +size 3528 diff --git a/data/minecraft/structure/shipwreck/sideways_backhalf.nbt b/data/minecraft/structure/shipwreck/sideways_backhalf.nbt index e7f3f05f..913a47ae 100644 --- a/data/minecraft/structure/shipwreck/sideways_backhalf.nbt +++ b/data/minecraft/structure/shipwreck/sideways_backhalf.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e4aead076cfda640820ed91bfe91a0d004338923f5fbcc631bef7b7141e107f3 -size 2434 +oid sha256:3aa82fc24c3dfc56abbd146db8ea78aac92245bd0cb5b33ecaced76da014675a +size 2436 diff --git a/data/minecraft/structure/shipwreck/sideways_backhalf_degraded.nbt b/data/minecraft/structure/shipwreck/sideways_backhalf_degraded.nbt index 9ee32728..3877d633 100644 --- a/data/minecraft/structure/shipwreck/sideways_backhalf_degraded.nbt +++ b/data/minecraft/structure/shipwreck/sideways_backhalf_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e5e1ece59baceb637cef62925e8c9912afef650e34f22e104708227b8029feef -size 2258 +oid sha256:2dfaa159668d4fc42e6ff02f3d9d85502aaca6ff077208eb6b64eca943dc0fbf +size 2259 diff --git a/data/minecraft/structure/shipwreck/sideways_fronthalf.nbt b/data/minecraft/structure/shipwreck/sideways_fronthalf.nbt index e40bb48d..914d4464 100644 --- a/data/minecraft/structure/shipwreck/sideways_fronthalf.nbt +++ b/data/minecraft/structure/shipwreck/sideways_fronthalf.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4478ce8087a4b7899da664c9164bb3482f086a4bae77a594ad42365db7821371 -size 2203 +oid sha256:406ef9ad7cbe5441761084b8972f3064457157a3f8f5b120b4df4f827867404d +size 2204 diff --git a/data/minecraft/structure/shipwreck/sideways_fronthalf_degraded.nbt b/data/minecraft/structure/shipwreck/sideways_fronthalf_degraded.nbt index f1681c40..e048a030 100644 --- a/data/minecraft/structure/shipwreck/sideways_fronthalf_degraded.nbt +++ b/data/minecraft/structure/shipwreck/sideways_fronthalf_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c0e9edfad99dd6aab51ac3913abf13db403ee730504faa795786337a3fa39901 -size 1912 +oid sha256:9a3738aaa7df2fa307bbea395badfac79c252d132000f9cf93aed9775983e0d7 +size 1914 diff --git a/data/minecraft/structure/shipwreck/sideways_full.nbt b/data/minecraft/structure/shipwreck/sideways_full.nbt index 03472d9c..02acbd78 100644 --- a/data/minecraft/structure/shipwreck/sideways_full.nbt +++ b/data/minecraft/structure/shipwreck/sideways_full.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ad852520033ac3a7ca8b06ed20929ecb0d42ea10cd90e91b8d16f037fc5a16d2 -size 3511 +oid sha256:630929d672737a8d1033620157ce3cd5e3fa69cecf48df08505a5db47a577a29 +size 3512 diff --git a/data/minecraft/structure/shipwreck/sideways_full_degraded.nbt b/data/minecraft/structure/shipwreck/sideways_full_degraded.nbt index 4863509d..e8655984 100644 --- a/data/minecraft/structure/shipwreck/sideways_full_degraded.nbt +++ b/data/minecraft/structure/shipwreck/sideways_full_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4220aec0de6c05278cea7aeb78bd75adedddeeb62b2a2c6e101c3803af71d3ab -size 3307 +oid sha256:923117f06c9141069d4b4c7e37ebdbdc5e89bce6d0acf6932ded12c41ec0a7f7 +size 3308 diff --git a/data/minecraft/structure/shipwreck/upsidedown_backhalf.nbt b/data/minecraft/structure/shipwreck/upsidedown_backhalf.nbt index e10b30a9..6402588b 100644 --- a/data/minecraft/structure/shipwreck/upsidedown_backhalf.nbt +++ b/data/minecraft/structure/shipwreck/upsidedown_backhalf.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:117b4aee46f749673b08e13ab9a09fdbd2bb803205b09ad9df5109d538e55f94 -size 2517 +oid sha256:1f840a092f44c4eacb9263a90e735c5213ed5e0fb9698f169e75d9a2cf8361cb +size 2518 diff --git a/data/minecraft/structure/shipwreck/upsidedown_backhalf_degraded.nbt b/data/minecraft/structure/shipwreck/upsidedown_backhalf_degraded.nbt index 1994d85a..f917b758 100644 --- a/data/minecraft/structure/shipwreck/upsidedown_backhalf_degraded.nbt +++ b/data/minecraft/structure/shipwreck/upsidedown_backhalf_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a1fdce1529617334bef02e34bdd2679462d4225d1b51e1a63e016813d843e881 -size 2388 +oid sha256:59a9a1d7fe8aab036a9588361af4410a69b85ad29bc1acf150bf1ee38b605b70 +size 2389 diff --git a/data/minecraft/structure/shipwreck/upsidedown_fronthalf.nbt b/data/minecraft/structure/shipwreck/upsidedown_fronthalf.nbt index d1d69624..6529669b 100644 --- a/data/minecraft/structure/shipwreck/upsidedown_fronthalf.nbt +++ b/data/minecraft/structure/shipwreck/upsidedown_fronthalf.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8c0c2239ffd2af800125c482430c501dbb8317986559be5ef6105269898003f3 -size 2323 +oid sha256:1b76e4b2df1424d6e1404a829ef3442231fc93ebbbecc6a81e00d90af085fcf1 +size 2325 diff --git a/data/minecraft/structure/shipwreck/upsidedown_fronthalf_degraded.nbt b/data/minecraft/structure/shipwreck/upsidedown_fronthalf_degraded.nbt index e82d4931..b51f7f6a 100644 --- a/data/minecraft/structure/shipwreck/upsidedown_fronthalf_degraded.nbt +++ b/data/minecraft/structure/shipwreck/upsidedown_fronthalf_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cc8ea0f81103aa4985bc524349ffbaad747d981040f13caf07bc4d5c9e76834d -size 2209 +oid sha256:bcfce1b511fcac6b8242d03a373702d7a040d50f5b179d4c44ffdae6f3a7604f +size 2210 diff --git a/data/minecraft/structure/shipwreck/upsidedown_full.nbt b/data/minecraft/structure/shipwreck/upsidedown_full.nbt index 5f3a0390..8d8d0389 100644 --- a/data/minecraft/structure/shipwreck/upsidedown_full.nbt +++ b/data/minecraft/structure/shipwreck/upsidedown_full.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:399281000afc109f497f219ae5f4529f84d9593cd30c92b9dbae0c1aa30c44d1 -size 3469 +oid sha256:9a9946f38d7b0a3b3b5d692be0665e3e835ae723c1be1f8566d9e12ab3fbeff1 +size 3470 diff --git a/data/minecraft/structure/shipwreck/upsidedown_full_degraded.nbt b/data/minecraft/structure/shipwreck/upsidedown_full_degraded.nbt index 6522b649..32934d3e 100644 --- a/data/minecraft/structure/shipwreck/upsidedown_full_degraded.nbt +++ b/data/minecraft/structure/shipwreck/upsidedown_full_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:def1bab3595a910d2b66d8f99656052d6ef20d7d289a22890007fe1101da6cf5 -size 3298 +oid sha256:ce600e21360a07b3d4657b0d9fea67d6a4315d086167a1f301e1b5f2901f26cb +size 3299 diff --git a/data/minecraft/structure/shipwreck/with_mast.nbt b/data/minecraft/structure/shipwreck/with_mast.nbt index 9e062ced..51d10f41 100644 --- a/data/minecraft/structure/shipwreck/with_mast.nbt +++ b/data/minecraft/structure/shipwreck/with_mast.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:028104d8f8e74d4b2aab1b92eff0cdb4587026a03106ad5087a11d19dc7329fe -size 3959 +oid sha256:689133e1e1813474f0a19ccec1c3779a9ef0b274485cd386d1745ea090641783 +size 3960 diff --git a/data/minecraft/structure/shipwreck/with_mast_degraded.nbt b/data/minecraft/structure/shipwreck/with_mast_degraded.nbt index ff28fe8c..d6b4f418 100644 --- a/data/minecraft/structure/shipwreck/with_mast_degraded.nbt +++ b/data/minecraft/structure/shipwreck/with_mast_degraded.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f1a9c1c6f70782f76b487546a7e5db0843feb1b3d1d058f9ef47e34355daa68c -size 3684 +oid sha256:1b4244ce177b4dda16d01756d01c90cf090ac2aa0134dd3d684ea234dbd4bb28 +size 3685 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_full_1.nbt b/data/minecraft/structure/trail_ruins/buildings/group_full_1.nbt index caa26b08..71cda637 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_full_1.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_full_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3f246e40e0ee0518846bee3f715d2509b086083182415836be8221c25c5a9176 -size 1338 +oid sha256:d152c7eb5714e0dc3f7ef05d55ffcd706d87c8c23bc27c8d8a6c1f6eaaf9d2a9 +size 1339 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_full_2.nbt b/data/minecraft/structure/trail_ruins/buildings/group_full_2.nbt index 0052221d..68dbc837 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_full_2.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_full_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:09f0d465345f9f0d1ae96289a5026dc6add57ab0704ca842b5b98042b90a95ce -size 1280 +oid sha256:3533ca3e878beab7e804a3ef4302dc3bdd33f4477a72243f541374fcae957448 +size 1281 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_full_3.nbt b/data/minecraft/structure/trail_ruins/buildings/group_full_3.nbt index 9276ee07..3ca1116f 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_full_3.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_full_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:787e199c6c9dd3c57b58d7ec95c36614365c7ff87dd5d1e8c1f30a736fda835d -size 1298 +oid sha256:de955635bcfa6d2e34413cbbde1861f7f9ef7ee04ef2c117182527eeeaddd671 +size 1299 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_full_4.nbt b/data/minecraft/structure/trail_ruins/buildings/group_full_4.nbt index f4df148c..ad07dafa 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_full_4.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_full_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a975db80f20d3b4d13754242723bbc00e61f440bbae13027b44e0d832e5af998 -size 1262 +oid sha256:54515b8275db63a91899b511ba904633c5f6e660385cae0d88ada4dd9017f16e +size 1263 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_full_5.nbt b/data/minecraft/structure/trail_ruins/buildings/group_full_5.nbt index 0798044d..db81b4e1 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_full_5.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_full_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:12d3a5f3dde4e69e9a2b5ca3740e5367f17c78507077f1d4f670a6dc748ae4dd -size 1260 +oid sha256:225069440b7328a580ae7e340b40220607385447af520eff268342f94757b2a3 +size 1261 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_hall_1.nbt b/data/minecraft/structure/trail_ruins/buildings/group_hall_1.nbt index 13db1daa..487c246b 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_hall_1.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_hall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cce6e1b100330194e63295486813a840c6dc4f83270996550ec71eb97b4e7289 -size 1516 +oid sha256:10c2ca97bd65e8fc979427ea7d356013f7fb4479595ffddff1a807badeaeb840 +size 1517 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_hall_2.nbt b/data/minecraft/structure/trail_ruins/buildings/group_hall_2.nbt index fe150589..f3de70fb 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_hall_2.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_hall_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:945c7a567ccae2a06bb6603b9906180b5ac4169d3d9b23dd702822205053f296 -size 1615 +oid sha256:7e0fe0ebce593325839664613aba0d1fdf7e8af7b61284d361c6b2e923aaa550 +size 1616 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_hall_3.nbt b/data/minecraft/structure/trail_ruins/buildings/group_hall_3.nbt index 3313346a..f38de6c1 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_hall_3.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_hall_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7ae8ee07bd4964a96c13f5883d38d261eddc946bdccd57ad1fa63d1f6d6339ba -size 1715 +oid sha256:309c859b55ac76e1b8d9abba4666c2682f2a8f5bf6d40818a8e6472bfd3aecc0 +size 1716 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_hall_4.nbt b/data/minecraft/structure/trail_ruins/buildings/group_hall_4.nbt index d2fc3e14..fd288190 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_hall_4.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_hall_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:84beb2e18e8c682b66771f690b17e240bdcd89990c85f49ca23d10fc6e7bf3c2 -size 1639 +oid sha256:d996fa67e8b4d477faf8929469ed5221086b486d4edfc8fc0aa915309b948a6c +size 1640 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_hall_5.nbt b/data/minecraft/structure/trail_ruins/buildings/group_hall_5.nbt index ca83da29..ae7e97ab 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_hall_5.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_hall_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:70f2f485a570f2134ff1e0de192a35b4cf1cb055ff16dc273c2deb68b35b26a6 -size 1525 +oid sha256:95e41915c23f5df704df316bbf0ecda9b40efa53e69a933cca23d3dd59720808 +size 1526 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_lower_1.nbt b/data/minecraft/structure/trail_ruins/buildings/group_lower_1.nbt index e7ab7f09..09f6e6c4 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_lower_1.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_lower_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:51bde80089fb7876f0508121e8bcc7eef8d420c6ef512d15bee98757dae2d7c4 -size 1046 +oid sha256:90db8183624d6869e60a9598d049e0f1561681bdfa1598976b9278a94fcb1a7f +size 1047 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_lower_2.nbt b/data/minecraft/structure/trail_ruins/buildings/group_lower_2.nbt index bf002c59..fbc83842 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_lower_2.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_lower_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0ac6ea29671cf7264adfe4798d6d1989f813efe5fc8de5b27f5760bd37a4d5b9 +oid sha256:d93fe9b15580acce74a01a1c7e2a0c7eb786acb770cde881e680a48931821ed9 size 1043 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_lower_3.nbt b/data/minecraft/structure/trail_ruins/buildings/group_lower_3.nbt index 8ff87eec..2e49c448 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_lower_3.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_lower_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c6134d3974098fe7a907e419287108a1f4d6491ac0df5cec809917d3361aa486 +oid sha256:aaa78e883c5f2080f5afac01b19a00e5c2c382d6817a9ac6d57dc1a63e781e7a size 1046 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_lower_4.nbt b/data/minecraft/structure/trail_ruins/buildings/group_lower_4.nbt index b9ec3cfa..6aabc371 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_lower_4.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_lower_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e79d4fd763aaa7cad0a7de415263a69e6bf49e9463b68eea7dd90d374022ce54 -size 973 +oid sha256:cdceb5f569f826ee4533c4ff83cf1890caebc7e6fbc0c8d3cfd8023eb253860d +size 974 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_lower_5.nbt b/data/minecraft/structure/trail_ruins/buildings/group_lower_5.nbt index a8fd6b86..ffb580dd 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_lower_5.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_lower_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5b1bd57ac83776e694343a6c454f1146951bbfe32e7af759b87ab5ab61778e90 -size 972 +oid sha256:15d73d26068f5a722467dd9a877b8908b8cebe1c8881e731945256ae86bed9cd +size 973 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_room_1.nbt b/data/minecraft/structure/trail_ruins/buildings/group_room_1.nbt index d8452f3f..462bb287 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_room_1.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_room_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:88053e6b0ac4d75a5d8abc9c422262b8a8e7150dfc9d810d4369148837eea4be -size 779 +oid sha256:00a7ffa73c2a8f0ae342cf4c66e32a67888751ea8974955be527d6562568d772 +size 780 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_room_2.nbt b/data/minecraft/structure/trail_ruins/buildings/group_room_2.nbt index 1d46786a..0f392dc6 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_room_2.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_room_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fe1ff1037698c853225c1c7291df7dd5628258c66218763d4bf12ab3c5b258a9 -size 862 +oid sha256:cea7eaeecff94b4e770f75d050116bc5b6d5c54b31d76ae9fb43de6aa8f461c9 +size 864 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_room_3.nbt b/data/minecraft/structure/trail_ruins/buildings/group_room_3.nbt index 9fcbecef..3701d1b6 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_room_3.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_room_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:55860b9263f44b3aee07cb64f70464af5d7c2bac5049cee992071b5f48743a37 -size 847 +oid sha256:42055527e698154d8435e66ad316af5c297545398139014edfcf6b99ada5e678 +size 848 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_room_4.nbt b/data/minecraft/structure/trail_ruins/buildings/group_room_4.nbt index a423f16e..cd4e8983 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_room_4.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_room_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:76152fa6465c14cbc8776808eade6adfdeebedb8b46c211ac394375370046638 -size 779 +oid sha256:153c8adbf6930c5ebaae07ccc2d354bc0b3004649da3e4b7efdd4b8af76bdf2a +size 781 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_room_5.nbt b/data/minecraft/structure/trail_ruins/buildings/group_room_5.nbt index e0503837..fae7ebeb 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_room_5.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_room_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:65fc181e01f9fe1ceacd9a4eae421e63a7f99674b1121cbe2950fd908ad0e4b3 -size 778 +oid sha256:1b7929253421ecb546f387370cba954e37174dab3ee6cf91b53016967d258ac7 +size 779 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_upper_1.nbt b/data/minecraft/structure/trail_ruins/buildings/group_upper_1.nbt index b6d2f66d..6fafa98e 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_upper_1.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_upper_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ffd89f45f0054f6ceff28751e5297c5092b93dca44d7ca857d4a35fe1285f0d9 -size 1269 +oid sha256:8b72413a76d797568ca5b8cbdee16c5b51a7ffd87dff01ab80ce530fb22650ab +size 1270 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_upper_2.nbt b/data/minecraft/structure/trail_ruins/buildings/group_upper_2.nbt index d84e3c31..f4506fcb 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_upper_2.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_upper_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:575e683c8d95d51db2d489a839129a3419c087befc8d524b74473b0504a90cc1 -size 1261 +oid sha256:d36f157229e9033f87d3b5565af22e2fec0f43d5e93a13007f81dc85fc0c2fbd +size 1263 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_upper_3.nbt b/data/minecraft/structure/trail_ruins/buildings/group_upper_3.nbt index be2d056e..6ee221a3 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_upper_3.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_upper_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7009bde23f13cebc5bc99af999017d287326cf0da373f94375c038e5b0061644 -size 1272 +oid sha256:44f813b89436f4c4226d3e24b19b3832040c417cfba22a66f9473a082150d0ae +size 1274 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_upper_4.nbt b/data/minecraft/structure/trail_ruins/buildings/group_upper_4.nbt index 9a0b2841..f82481f8 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_upper_4.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_upper_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:03451baad49f7e4a4b927fc6b871f7ec71e23fdf10fd55e10d10788dc3252da3 -size 1180 +oid sha256:874fcbd6bfd22219bd3d17f35bb5897204d333a5f3cdc3b3be2a1e73bf16bcde +size 1181 diff --git a/data/minecraft/structure/trail_ruins/buildings/group_upper_5.nbt b/data/minecraft/structure/trail_ruins/buildings/group_upper_5.nbt index aa63848b..57541f12 100644 --- a/data/minecraft/structure/trail_ruins/buildings/group_upper_5.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/group_upper_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c24b7ec4eededf3c6eb01df37a4c0b7ea3ef75c29f0a66fb91a8f37634381ee0 -size 1176 +oid sha256:fa234f068ba1605fe0660f9bffdedf3fce67d7f1be5e5fa7e580cb52c646e9a9 +size 1178 diff --git a/data/minecraft/structure/trail_ruins/buildings/large_room_1.nbt b/data/minecraft/structure/trail_ruins/buildings/large_room_1.nbt index 8950b4db..fbf6d4a1 100644 --- a/data/minecraft/structure/trail_ruins/buildings/large_room_1.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/large_room_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e7ce23591b5ce23dd0a68b3b1cbfdefe18a0ed091b575a3347fe394304c723a0 -size 1945 +oid sha256:a6c465972dd9d28b3eaa1a1984c8e5beda1b44e27dd6ba55bc02e7dd191cdc25 +size 1946 diff --git a/data/minecraft/structure/trail_ruins/buildings/large_room_2.nbt b/data/minecraft/structure/trail_ruins/buildings/large_room_2.nbt index 494a280a..0ef9cd0f 100644 --- a/data/minecraft/structure/trail_ruins/buildings/large_room_2.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/large_room_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:45831083f3086ae2b3b324ebd2ad555a1ba19252c5e0916672a837778e1397d0 -size 1657 +oid sha256:1a51af25eac3001671f2e931613e3ac00bdbe89208d0519056bb117063d34fd1 +size 1658 diff --git a/data/minecraft/structure/trail_ruins/buildings/large_room_3.nbt b/data/minecraft/structure/trail_ruins/buildings/large_room_3.nbt index 24261c4c..6968f7e1 100644 --- a/data/minecraft/structure/trail_ruins/buildings/large_room_3.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/large_room_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:02fa6169901a5fadcefbca8b11c0c2cefd6568f6349700e7588c5b86f7e7caac -size 2706 +oid sha256:c5f4149206b7be7229512f3a00b88543152927927a60b566f2c6bb2c01218047 +size 2707 diff --git a/data/minecraft/structure/trail_ruins/buildings/large_room_4.nbt b/data/minecraft/structure/trail_ruins/buildings/large_room_4.nbt index f336e976..e7483bd7 100644 --- a/data/minecraft/structure/trail_ruins/buildings/large_room_4.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/large_room_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:24f28dadd38f69d96a679043bd0e87bea603cf72ec323c9db0cb7b79e5427d3b -size 1562 +oid sha256:80e09a4d5187f9dcd321e89dedea983ec3ccb003710345642cb98cdd496e9bd6 +size 1564 diff --git a/data/minecraft/structure/trail_ruins/buildings/large_room_5.nbt b/data/minecraft/structure/trail_ruins/buildings/large_room_5.nbt index 64d6483c..0a7a9402 100644 --- a/data/minecraft/structure/trail_ruins/buildings/large_room_5.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/large_room_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:24aec5cc96ca3d8a135567eb81c8cb38b297ba01416439db6586581a231ed60d -size 3217 +oid sha256:56437fd9a46dd90e5aff85a65b756b51bb3e788e017e57421db5df86bc967754 +size 3219 diff --git a/data/minecraft/structure/trail_ruins/buildings/one_room_1.nbt b/data/minecraft/structure/trail_ruins/buildings/one_room_1.nbt index 1bba784a..978a6b55 100644 --- a/data/minecraft/structure/trail_ruins/buildings/one_room_1.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/one_room_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3e150b341fbdc36c600519645a2a64827f9730c27e9a4dcc843b253ca1016a85 -size 1004 +oid sha256:ff1c61a51b0f6c1589ee47e526ae4eb48a34757e6199d630ab5155959ab50ba1 +size 1005 diff --git a/data/minecraft/structure/trail_ruins/buildings/one_room_2.nbt b/data/minecraft/structure/trail_ruins/buildings/one_room_2.nbt index d7eb7517..2832259c 100644 --- a/data/minecraft/structure/trail_ruins/buildings/one_room_2.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/one_room_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d0e5081fdf2859fa02f690d33efe1fa66f18f882066bd248d33a769c100eaaa -size 1085 +oid sha256:c7ac17b53fe665a4f3685ae439769afe50e4ff75625be94aef2d3344f3175f6d +size 1086 diff --git a/data/minecraft/structure/trail_ruins/buildings/one_room_3.nbt b/data/minecraft/structure/trail_ruins/buildings/one_room_3.nbt index 0d73060b..dae05945 100644 --- a/data/minecraft/structure/trail_ruins/buildings/one_room_3.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/one_room_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1655abe423c6f386d62c6654a86b38fcd7211c72811a5a723f56e30db5f5085c -size 1104 +oid sha256:753e904984c5a1e68fbb9de80559392bc0821d1c0b79980833b324b8500e554b +size 1105 diff --git a/data/minecraft/structure/trail_ruins/buildings/one_room_4.nbt b/data/minecraft/structure/trail_ruins/buildings/one_room_4.nbt index ff2e86a8..4ae5cf34 100644 --- a/data/minecraft/structure/trail_ruins/buildings/one_room_4.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/one_room_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:402ff2d9a7e71744628d9aa4635a1d5aa8e26c6a8bcb850ff35eb768856c9850 -size 1451 +oid sha256:97ca94b5d310ee5262411f795b50a7740bbde576b3c10fecfa228f91abd5d2e5 +size 1452 diff --git a/data/minecraft/structure/trail_ruins/buildings/one_room_5.nbt b/data/minecraft/structure/trail_ruins/buildings/one_room_5.nbt index 449773b8..53e4270a 100644 --- a/data/minecraft/structure/trail_ruins/buildings/one_room_5.nbt +++ b/data/minecraft/structure/trail_ruins/buildings/one_room_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4a11a755d76234174ce2a5cd5c97fd6f0a8649fd4560e74dedd258e4baeb2e19 -size 972 +oid sha256:659ed7b0809b07728fbb0b82294ba89c52a553ad88437aca769b11655e7f4177 +size 973 diff --git a/data/minecraft/structure/trail_ruins/decor/decor_1.nbt b/data/minecraft/structure/trail_ruins/decor/decor_1.nbt index fff7f01b..cac37b4f 100644 --- a/data/minecraft/structure/trail_ruins/decor/decor_1.nbt +++ b/data/minecraft/structure/trail_ruins/decor/decor_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b031fea8a6f853c6efb09d5fe3d1c3efe5b926d18aa9299dddc431a0c9bb474d -size 488 +oid sha256:4885fded73b3b555560c2392141eafb46497ccd7a6bc8d8713c6837327c33962 +size 489 diff --git a/data/minecraft/structure/trail_ruins/decor/decor_2.nbt b/data/minecraft/structure/trail_ruins/decor/decor_2.nbt index 3f79baa8..fb67d79e 100644 --- a/data/minecraft/structure/trail_ruins/decor/decor_2.nbt +++ b/data/minecraft/structure/trail_ruins/decor/decor_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b8ef4d671bff822a8696d9054e52a0a305d241acbaa43b318381deb896f6ba73 -size 469 +oid sha256:0601a050fad4a29eb147e014b1ed931d0560a320808a168d0a7782041375e1df +size 471 diff --git a/data/minecraft/structure/trail_ruins/decor/decor_3.nbt b/data/minecraft/structure/trail_ruins/decor/decor_3.nbt index 526cee43..1018da9a 100644 --- a/data/minecraft/structure/trail_ruins/decor/decor_3.nbt +++ b/data/minecraft/structure/trail_ruins/decor/decor_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:99a3d701fb746b506b908aa6d4e99ff648c5dcbd70aaecfb7f0d48bab096e87f -size 376 +oid sha256:597352b3c437c2e7e8ded5839aaceb8be19b0bbdc6e00d54150b046dedefffbd +size 377 diff --git a/data/minecraft/structure/trail_ruins/decor/decor_4.nbt b/data/minecraft/structure/trail_ruins/decor/decor_4.nbt index f37d26b1..c34b4b5e 100644 --- a/data/minecraft/structure/trail_ruins/decor/decor_4.nbt +++ b/data/minecraft/structure/trail_ruins/decor/decor_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fd5703231619198ca217d5a0e8252e2da08184ae4e669973978789a4223e95d4 -size 415 +oid sha256:2e32df9c1b81dceebfe89c63e769ebd11e9fd95da42ec0b1673b71f6af18f357 +size 416 diff --git a/data/minecraft/structure/trail_ruins/decor/decor_5.nbt b/data/minecraft/structure/trail_ruins/decor/decor_5.nbt index cd50e615..9e71081f 100644 --- a/data/minecraft/structure/trail_ruins/decor/decor_5.nbt +++ b/data/minecraft/structure/trail_ruins/decor/decor_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a65ed3a4788bc63c62c21877f52711ae19331c49faabbe1717cfce2c3fd14ca5 -size 491 +oid sha256:dcd5254373a6216df5e32388823e6d5b9873b1c91459ed2cec0555dea3abefe5 +size 492 diff --git a/data/minecraft/structure/trail_ruins/decor/decor_6.nbt b/data/minecraft/structure/trail_ruins/decor/decor_6.nbt index 921a927e..afd5a016 100644 --- a/data/minecraft/structure/trail_ruins/decor/decor_6.nbt +++ b/data/minecraft/structure/trail_ruins/decor/decor_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a25288fa8b6fb9dfbb1a354f965cd9d865bfa55fbd1d3d240f5a04051a519b6b -size 505 +oid sha256:c344164b937830038222606e147614e0f04612cf95872f6d5223f52f1260d23a +size 506 diff --git a/data/minecraft/structure/trail_ruins/decor/decor_7.nbt b/data/minecraft/structure/trail_ruins/decor/decor_7.nbt index c74ad550..2d69e782 100644 --- a/data/minecraft/structure/trail_ruins/decor/decor_7.nbt +++ b/data/minecraft/structure/trail_ruins/decor/decor_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0bcc157bed3fd53d0d80b63796c122ee4a24d6a5ef90b69d4c6122f434a7135c -size 630 +oid sha256:4c729c4d6e60884a24948d99fb2a36195bf1155c5cd09834fda038cac2b758fa +size 631 diff --git a/data/minecraft/structure/trail_ruins/roads/long_road_end.nbt b/data/minecraft/structure/trail_ruins/roads/long_road_end.nbt index 9ee66383..026d768e 100644 --- a/data/minecraft/structure/trail_ruins/roads/long_road_end.nbt +++ b/data/minecraft/structure/trail_ruins/roads/long_road_end.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bc128f5a4b10de8ed8412549bc487cb55d281badbabdc4d1b3162c8a0102ed8d -size 857 +oid sha256:6e0e13b50f7e6d1c2420956a4a93c576e3c0d12338030a02428aa2dfe54e49bd +size 858 diff --git a/data/minecraft/structure/trail_ruins/roads/road_end_1.nbt b/data/minecraft/structure/trail_ruins/roads/road_end_1.nbt index 9c8df213..562dd061 100644 --- a/data/minecraft/structure/trail_ruins/roads/road_end_1.nbt +++ b/data/minecraft/structure/trail_ruins/roads/road_end_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d4f9f20059ee3ab682da82b446dbba25e21c6e261ee83f32f0e0e09cdb67dc31 -size 465 +oid sha256:4e2ca2809e712344e9c24795c07a806114c53b33e7e8d9a128afd77902c8c35f +size 467 diff --git a/data/minecraft/structure/trail_ruins/roads/road_section_1.nbt b/data/minecraft/structure/trail_ruins/roads/road_section_1.nbt index a13d6803..01127051 100644 --- a/data/minecraft/structure/trail_ruins/roads/road_section_1.nbt +++ b/data/minecraft/structure/trail_ruins/roads/road_section_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2a5a3a2fd079d6aa67b76ede762862946b69c172e089d96b3a635a2501712775 -size 705 +oid sha256:1dc5f3b5490705ab7e410e871a2b9fae17d56b5657d453ddfa0ffcfc54d84090 +size 706 diff --git a/data/minecraft/structure/trail_ruins/roads/road_section_2.nbt b/data/minecraft/structure/trail_ruins/roads/road_section_2.nbt index 2f653bb9..264544f4 100644 --- a/data/minecraft/structure/trail_ruins/roads/road_section_2.nbt +++ b/data/minecraft/structure/trail_ruins/roads/road_section_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:43ad76ffee60ba822170df65fc8dff496899112a466ab6e4d301e213ed25b1b8 -size 718 +oid sha256:2c35cce424163cb7644b737a8ac6d980ddc32b98ea4d33291fd9fdbf3b7d4dc3 +size 719 diff --git a/data/minecraft/structure/trail_ruins/roads/road_section_3.nbt b/data/minecraft/structure/trail_ruins/roads/road_section_3.nbt index d3e10aac..cb1a8d27 100644 --- a/data/minecraft/structure/trail_ruins/roads/road_section_3.nbt +++ b/data/minecraft/structure/trail_ruins/roads/road_section_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:095149fdbba051c2513c373ba2a5adf375bb4fbbc62b6cbe77735a01998a7fb1 -size 755 +oid sha256:fe52ab8269ea31e06869adc01e116509cc9f61147cde47903aedf9baf0af9649 +size 757 diff --git a/data/minecraft/structure/trail_ruins/roads/road_section_4.nbt b/data/minecraft/structure/trail_ruins/roads/road_section_4.nbt index 43e52fb9..758b63fb 100644 --- a/data/minecraft/structure/trail_ruins/roads/road_section_4.nbt +++ b/data/minecraft/structure/trail_ruins/roads/road_section_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e700d4004114a8851632fd12d14c69b8a2be3e5c4ae0a416ffdd526fbeabda3b -size 771 +oid sha256:a8d81bf011f7ce447a551bec81e4ccccb7d14e02fafcb69fc3f4670c4fd700c1 +size 772 diff --git a/data/minecraft/structure/trail_ruins/roads/road_spacer_1.nbt b/data/minecraft/structure/trail_ruins/roads/road_spacer_1.nbt index 90076fc5..72b0caa9 100644 --- a/data/minecraft/structure/trail_ruins/roads/road_spacer_1.nbt +++ b/data/minecraft/structure/trail_ruins/roads/road_spacer_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a0fc029d36c407f785685ec07a3c25bb18b44bcce020fb95e87e533dd8c4447a -size 643 +oid sha256:a4371ff2428a011a9cf5ba163ec6106c505cdc3a030f9afb7c3b7808d0560b5e +size 644 diff --git a/data/minecraft/structure/trail_ruins/tower/hall_1.nbt b/data/minecraft/structure/trail_ruins/tower/hall_1.nbt index b68cfb42..67772620 100644 --- a/data/minecraft/structure/trail_ruins/tower/hall_1.nbt +++ b/data/minecraft/structure/trail_ruins/tower/hall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:343a8b161476fae7f739eb54e91c21959c74cfe9ce274bbedca2c04e80ba8dc1 -size 1518 +oid sha256:6555bda901feed127456a4aa278441cb67977ea6e95e2ca30187a2f445565132 +size 1519 diff --git a/data/minecraft/structure/trail_ruins/tower/hall_2.nbt b/data/minecraft/structure/trail_ruins/tower/hall_2.nbt index 28361039..81fac965 100644 --- a/data/minecraft/structure/trail_ruins/tower/hall_2.nbt +++ b/data/minecraft/structure/trail_ruins/tower/hall_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f579f71d94c72c3d2966bd1d714e0de37a785a1ef7ff246767f4c66e3b4211e7 -size 1893 +oid sha256:372862f43d5a41112fba2801489c17435e5beca34b7208b332442a009883ff68 +size 1894 diff --git a/data/minecraft/structure/trail_ruins/tower/hall_3.nbt b/data/minecraft/structure/trail_ruins/tower/hall_3.nbt index 4f518a58..1aa408dc 100644 --- a/data/minecraft/structure/trail_ruins/tower/hall_3.nbt +++ b/data/minecraft/structure/trail_ruins/tower/hall_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b9ba0753e7ff2928f8ca6f1a4ee5cbd51f4d1ab02e8db52fcfebbf4a9af29389 -size 2139 +oid sha256:166aa9384e5faf56e50bcdfb046e4606229eb6618c839c36a638098fc80571f1 +size 2140 diff --git a/data/minecraft/structure/trail_ruins/tower/hall_4.nbt b/data/minecraft/structure/trail_ruins/tower/hall_4.nbt index 9ec4792f..c62fe34f 100644 --- a/data/minecraft/structure/trail_ruins/tower/hall_4.nbt +++ b/data/minecraft/structure/trail_ruins/tower/hall_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:59f706dc80c8e50d71d80b6c1bc14599f513fd0403b8a2bf4b6075bf5b9f502b -size 2029 +oid sha256:2e3a25e7cf897d11a24b073c90fdddb93d7122c38a86fdbe88efc619215b8b0a +size 2030 diff --git a/data/minecraft/structure/trail_ruins/tower/hall_5.nbt b/data/minecraft/structure/trail_ruins/tower/hall_5.nbt index 019d602f..ed305307 100644 --- a/data/minecraft/structure/trail_ruins/tower/hall_5.nbt +++ b/data/minecraft/structure/trail_ruins/tower/hall_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f6cb966f56daea0c2f28caf8d2aa4194d1575b6505fce1c64d826f0965567d64 -size 1872 +oid sha256:7ee68a75368dee8a91c2d81ddc66c379d66a4f853bea98db88958db0ab204958 +size 1873 diff --git a/data/minecraft/structure/trail_ruins/tower/large_hall_1.nbt b/data/minecraft/structure/trail_ruins/tower/large_hall_1.nbt index 8255fb2d..e70e103b 100644 --- a/data/minecraft/structure/trail_ruins/tower/large_hall_1.nbt +++ b/data/minecraft/structure/trail_ruins/tower/large_hall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cd78a6c37c5517a57c64a329a0071ae5eaa19d21da897d31ad2ab8bf50407262 -size 2023 +oid sha256:e88236b894dc043d9074e4bb66eb14d563e09b1c9cfcea71cf076d6b90d43a32 +size 2024 diff --git a/data/minecraft/structure/trail_ruins/tower/large_hall_2.nbt b/data/minecraft/structure/trail_ruins/tower/large_hall_2.nbt index 54817686..715c47cc 100644 --- a/data/minecraft/structure/trail_ruins/tower/large_hall_2.nbt +++ b/data/minecraft/structure/trail_ruins/tower/large_hall_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c06b4300c0b094f78b06a2b7983a0611c118540e0a87cdce08cc4652568361c5 -size 1964 +oid sha256:373ecf6b74e681d7e8e876073bd0732c440fcd2fa03c875d48008dc4ebde77a5 +size 1965 diff --git a/data/minecraft/structure/trail_ruins/tower/large_hall_3.nbt b/data/minecraft/structure/trail_ruins/tower/large_hall_3.nbt index e7320537..d3759ac3 100644 --- a/data/minecraft/structure/trail_ruins/tower/large_hall_3.nbt +++ b/data/minecraft/structure/trail_ruins/tower/large_hall_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:516cbd4891136759aa31684515651dfdd8e5e125c99e8de157b0bed4b01917e6 -size 2022 +oid sha256:ee1cac8891ca88746bf10ee970962da0300d5cfa160fcc552e7ce13750e9ce5d +size 2023 diff --git a/data/minecraft/structure/trail_ruins/tower/large_hall_4.nbt b/data/minecraft/structure/trail_ruins/tower/large_hall_4.nbt index 3cb1558a..b206ddda 100644 --- a/data/minecraft/structure/trail_ruins/tower/large_hall_4.nbt +++ b/data/minecraft/structure/trail_ruins/tower/large_hall_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8d2fd185149f7e53e921abfd8de8492f57e286143495e367a32cbecba9460a8a -size 1806 +oid sha256:eef43435145233b28f62b9f2165488f3acfdbf979c71954788af5d542c5812f3 +size 1807 diff --git a/data/minecraft/structure/trail_ruins/tower/large_hall_5.nbt b/data/minecraft/structure/trail_ruins/tower/large_hall_5.nbt index a6f15678..10daf43b 100644 --- a/data/minecraft/structure/trail_ruins/tower/large_hall_5.nbt +++ b/data/minecraft/structure/trail_ruins/tower/large_hall_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b9f7c90a6072556f3ddd34db8f5c94126459b4118a9611f19401c84367f6eca3 -size 2002 +oid sha256:5d239f8d16e0df3edf1ada01b0bfc488a68b224825162fc03d2e5ad5ce9ca994 +size 2003 diff --git a/data/minecraft/structure/trail_ruins/tower/one_room_1.nbt b/data/minecraft/structure/trail_ruins/tower/one_room_1.nbt index f5035cfe..bb930d66 100644 --- a/data/minecraft/structure/trail_ruins/tower/one_room_1.nbt +++ b/data/minecraft/structure/trail_ruins/tower/one_room_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d8d77d060126c01be437d0fb228d3d1b2b5910da0ed9c959517c088d1159d932 -size 648 +oid sha256:793f6717966ae1a7e1a5b1b8a75120f618cca29e03107742206b465aa350ff33 +size 649 diff --git a/data/minecraft/structure/trail_ruins/tower/one_room_2.nbt b/data/minecraft/structure/trail_ruins/tower/one_room_2.nbt index 8e4f03c1..edbda065 100644 --- a/data/minecraft/structure/trail_ruins/tower/one_room_2.nbt +++ b/data/minecraft/structure/trail_ruins/tower/one_room_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:737f0385c75daaeecd16c457811516ec22a0f700bf57727589a83368fa737536 -size 717 +oid sha256:183db34e52052245660a983d05c7d3eff954cff0af9baaf3231a2a6e01601ae8 +size 718 diff --git a/data/minecraft/structure/trail_ruins/tower/one_room_3.nbt b/data/minecraft/structure/trail_ruins/tower/one_room_3.nbt index 82263b3a..e7b1e576 100644 --- a/data/minecraft/structure/trail_ruins/tower/one_room_3.nbt +++ b/data/minecraft/structure/trail_ruins/tower/one_room_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b2b3714e50ac771af470514770821a5849cc4ed0135ecf3e4712a36c70142fb0 -size 622 +oid sha256:ad763e86448be5d52760659ca91dc86f7595fa064972189890f131e955b7d9a0 +size 624 diff --git a/data/minecraft/structure/trail_ruins/tower/one_room_4.nbt b/data/minecraft/structure/trail_ruins/tower/one_room_4.nbt index 239a2e01..b68a85f1 100644 --- a/data/minecraft/structure/trail_ruins/tower/one_room_4.nbt +++ b/data/minecraft/structure/trail_ruins/tower/one_room_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6171d246119ac786700e40264bb87cd529b2878f18b82c963de9033013a12dd0 -size 613 +oid sha256:d7f78444001698166da7805289bc14faca591d8ffbfcdcdc7171c4d34afefd91 +size 615 diff --git a/data/minecraft/structure/trail_ruins/tower/one_room_5.nbt b/data/minecraft/structure/trail_ruins/tower/one_room_5.nbt index 67e2d066..23c32079 100644 --- a/data/minecraft/structure/trail_ruins/tower/one_room_5.nbt +++ b/data/minecraft/structure/trail_ruins/tower/one_room_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1a4cd354566136b7eb6fa866abaa8f731c4629e055c23a8d6fa0915d28e3a4f9 -size 636 +oid sha256:03435418f6e67f02e35b37b823577754b10eb01aeb12ff183df3100c822cc95d +size 637 diff --git a/data/minecraft/structure/trail_ruins/tower/platform_1.nbt b/data/minecraft/structure/trail_ruins/tower/platform_1.nbt index 76a84f8b..69a84252 100644 --- a/data/minecraft/structure/trail_ruins/tower/platform_1.nbt +++ b/data/minecraft/structure/trail_ruins/tower/platform_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b42b1ea4f280dd7ce9900129beef134b77bb045771f9e36d8476b4ab109e59a9 -size 1195 +oid sha256:468109a6364b7b428ba2d97987613b3c4424f875d9db30e3bbaa71e1e01b7256 +size 1196 diff --git a/data/minecraft/structure/trail_ruins/tower/platform_2.nbt b/data/minecraft/structure/trail_ruins/tower/platform_2.nbt index 2c70d297..d3adb3f7 100644 --- a/data/minecraft/structure/trail_ruins/tower/platform_2.nbt +++ b/data/minecraft/structure/trail_ruins/tower/platform_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2199eebc1e8f30e9fd9754dfbc6f11b2731a32f61ab2c8c20af13cae09d63611 -size 1134 +oid sha256:c2cc850a901f5f80c92f291406429ab1a0c7832f6e8112b77fb9a0f63e601f3e +size 1135 diff --git a/data/minecraft/structure/trail_ruins/tower/platform_3.nbt b/data/minecraft/structure/trail_ruins/tower/platform_3.nbt index 2ea78c52..0336932e 100644 --- a/data/minecraft/structure/trail_ruins/tower/platform_3.nbt +++ b/data/minecraft/structure/trail_ruins/tower/platform_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9376976d8af404418b117bdc9a424ba881c3c6035ddfb0aeb51a1bd6deb789c2 -size 858 +oid sha256:e3023c615949733f003f04e9f1fc08d0f50ade276f328b35ac30f228d9669d06 +size 859 diff --git a/data/minecraft/structure/trail_ruins/tower/platform_4.nbt b/data/minecraft/structure/trail_ruins/tower/platform_4.nbt index c3b50b76..e2d18384 100644 --- a/data/minecraft/structure/trail_ruins/tower/platform_4.nbt +++ b/data/minecraft/structure/trail_ruins/tower/platform_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:38af93bed95f3672d7c4b17f3ecc6eaae88a24ccac13b86910e2b7c0ff9fa6a2 -size 1205 +oid sha256:31dbce2eeca9394995d9fb06e5ac8de8e459bb6fd6e144e2ee8b74c9e1c6d5f9 +size 1206 diff --git a/data/minecraft/structure/trail_ruins/tower/platform_5.nbt b/data/minecraft/structure/trail_ruins/tower/platform_5.nbt index 8f225408..f674c181 100644 --- a/data/minecraft/structure/trail_ruins/tower/platform_5.nbt +++ b/data/minecraft/structure/trail_ruins/tower/platform_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b97e6711eecf3d2185ffadb6b8bbced6d622b836db0dc0759f59b6198997e5fb -size 1146 +oid sha256:223e0293262a72714a8eb73bbc306f3cc7c1cfff6dbfae48ca234c77589367e0 +size 1147 diff --git a/data/minecraft/structure/trail_ruins/tower/stable_1.nbt b/data/minecraft/structure/trail_ruins/tower/stable_1.nbt index b81f7114..787f3ea0 100644 --- a/data/minecraft/structure/trail_ruins/tower/stable_1.nbt +++ b/data/minecraft/structure/trail_ruins/tower/stable_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3193bf0d88c179422f1db5e72d6aff9f041a2ff929df4a3cacff039ab3146332 -size 1272 +oid sha256:0448a2a0b33e7c10204d06ef58f06ebb7e3adced4fafb22f10731540a4c7fab1 +size 1274 diff --git a/data/minecraft/structure/trail_ruins/tower/stable_2.nbt b/data/minecraft/structure/trail_ruins/tower/stable_2.nbt index f979b65f..9cf4e745 100644 --- a/data/minecraft/structure/trail_ruins/tower/stable_2.nbt +++ b/data/minecraft/structure/trail_ruins/tower/stable_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ac3d84983b43b5e27eb146a820574a1e23438a00bcb415ea57aa8528b485ea9c -size 1290 +oid sha256:279e1aca15b76ea3958893a75d9ef9055cc19474d39ce551db6698bf19224ef2 +size 1291 diff --git a/data/minecraft/structure/trail_ruins/tower/stable_3.nbt b/data/minecraft/structure/trail_ruins/tower/stable_3.nbt index c2474416..774c52a0 100644 --- a/data/minecraft/structure/trail_ruins/tower/stable_3.nbt +++ b/data/minecraft/structure/trail_ruins/tower/stable_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3ae8868780dd6bb092b45a5c5f7d453084a6500879b810001492d32004d84b59 -size 1255 +oid sha256:39dfd300f802c62ef765b9d12da4c939b960c2d681c5feb700875bd6a63fa564 +size 1256 diff --git a/data/minecraft/structure/trail_ruins/tower/stable_4.nbt b/data/minecraft/structure/trail_ruins/tower/stable_4.nbt index 1b38b43b..b809bd09 100644 --- a/data/minecraft/structure/trail_ruins/tower/stable_4.nbt +++ b/data/minecraft/structure/trail_ruins/tower/stable_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:68286da91c92a2434f46a76a66c0aeb26aaf383b152c5ee5e377327d546bbd2c -size 1289 +oid sha256:2b31b265afb4d5b15279c9331a710ec88d96cd74fd8666ac19998adbd949dde2 +size 1290 diff --git a/data/minecraft/structure/trail_ruins/tower/stable_5.nbt b/data/minecraft/structure/trail_ruins/tower/stable_5.nbt index 20bb8c08..210cfcc0 100644 --- a/data/minecraft/structure/trail_ruins/tower/stable_5.nbt +++ b/data/minecraft/structure/trail_ruins/tower/stable_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:27d412aaa7c4bd6a00c6b5a31841a0f01269c5c0aecbf963f0030a48755c1ed1 -size 1034 +oid sha256:95ef86b72d48d858bc25c1c3288faed7f6574135bef2f7695731b617e69f9113 +size 1035 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_1.nbt b/data/minecraft/structure/trail_ruins/tower/tower_1.nbt index 621261c3..5da27a92 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_1.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:041f7736f3d03701494b6d78b7e4783f3560c94503c25e85304999dad4b7172b -size 1584 +oid sha256:c0c400d7ea41606b9a46bd34f780156ed2ce7267cb323366ea876e6fa9b787c4 +size 1585 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_2.nbt b/data/minecraft/structure/trail_ruins/tower/tower_2.nbt index 2288e7ba..6e2b3b7d 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_2.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e877ba59843984fe959513da5ea17db0dff0f954a077525550c6d0e79828de5f -size 1618 +oid sha256:2c85f1f4e2413d14247bcaf98991bae06d4b327ecb9cb3159fbc05122fc0a1f7 +size 1619 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_3.nbt b/data/minecraft/structure/trail_ruins/tower/tower_3.nbt index 6978e276..d69d4a2b 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_3.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fc1096715236075c4a14cbb6a8322aa723da15d2938b526e9b3c183044f9cc7d -size 2228 +oid sha256:9640544cfb237f7ebe7816d329f4efdd966ff318e6aca999d25c834912f3d32b +size 2229 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_4.nbt b/data/minecraft/structure/trail_ruins/tower/tower_4.nbt index 39caa3b2..354f66d3 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_4.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:691b66ae663e4a2be8f0dd5dc3bf0f46dbe04816874bfff97fc129d64a966824 -size 2089 +oid sha256:e9f108f2725593a3de9c59bf8df9bac37a5d7d59586cacc5a425245235e97ee0 +size 2091 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_5.nbt b/data/minecraft/structure/trail_ruins/tower/tower_5.nbt index f8febde0..3aa5fda3 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_5.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0b754c4d962f2180d29ddf891273bd0956c3789383a495196b0d69560ac91039 -size 2061 +oid sha256:694705298d02bf47cf3485f3831385ffe84dac9de19ffe1ad3c7abb9d4a3ea94 +size 2062 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_top_1.nbt b/data/minecraft/structure/trail_ruins/tower/tower_top_1.nbt index 19e96eb3..9c5fd516 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_top_1.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_top_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:115d46d2f7859556844e267a2d6ed835fb3a29ebfc3c22c116f290718eac7685 -size 504 +oid sha256:bf374b874ef7416d346a75b80f8b960e09f5ab0b4bf31d564a82c0175c4dd877 +size 505 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_top_2.nbt b/data/minecraft/structure/trail_ruins/tower/tower_top_2.nbt index e07d2c41..4d59eeda 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_top_2.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_top_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:feca6dc3fa77dd2674785a19efe4307c911172bf5ef3dbae24f0f02f5afdb550 -size 521 +oid sha256:5bad514083ca7397f5fe5fbc6fc3a0a58745ebdecccf50f08fd936ec04cf935b +size 522 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_top_3.nbt b/data/minecraft/structure/trail_ruins/tower/tower_top_3.nbt index 3b7fa734..32757368 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_top_3.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_top_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0be4939566446deff21010857c15f297782a3cdc2195a8e804c2d0afd88df792 -size 500 +oid sha256:91613ee95a81aaf29e29a7b5db294426be55c19c178ad31f599487d06b1d0d04 +size 501 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_top_4.nbt b/data/minecraft/structure/trail_ruins/tower/tower_top_4.nbt index 43616d11..1605097a 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_top_4.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_top_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:17e108aab0812e7d1bf21805bd4c3b4ce03921d46f79924a8cc5710dedd20049 -size 479 +oid sha256:34f4ac2b44542b0c6d08b81792212def75b4d6a99e2bd2a28512bb54846ffb69 +size 480 diff --git a/data/minecraft/structure/trail_ruins/tower/tower_top_5.nbt b/data/minecraft/structure/trail_ruins/tower/tower_top_5.nbt index 08f510ac..e22f7226 100644 --- a/data/minecraft/structure/trail_ruins/tower/tower_top_5.nbt +++ b/data/minecraft/structure/trail_ruins/tower/tower_top_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8d86e731b6578b5dc10bbefbd90a54f83fa5f73b87ce1dddd2068900aaaf181d -size 405 +oid sha256:da2c1ae06f9a706a8e3d464324655a99a078a248ffe4a274894439fd8f49a20b +size 406 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/c1_breeze.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/c1_breeze.nbt index 873ea27b..b1b69ba3 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/c1_breeze.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/c1_breeze.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4d08dfcf253e992110875967b19867d5bfff6e34006ac0777a65e38f4d5280cb -size 1694 +oid sha256:f99ee53231f315f4c58ef4116119aa152260b4d11e9345f205d4295d1ea3c1a3 +size 1695 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/full_corner_column.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/full_corner_column.nbt index 850eb7b0..d2577ef1 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/full_corner_column.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/full_corner_column.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:28c612b09dee726633f2b298ce0a3d269b835d76ef6bff50d556e4590494d7a6 -size 4157 +oid sha256:3bb444384fa3de83e33e2050cff451b09a2e4f939f91a4d96b9fe5528aec057b +size 4156 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/full_stacked_walkway.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/full_stacked_walkway.nbt index d5550bd4..1dab11d2 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/full_stacked_walkway.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/full_stacked_walkway.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:07465129538f570d9609a8740506c1a2c71df51d6e1c099a845fd135b0a5ff96 -size 4336 +oid sha256:2286f1a60b6a8420bf77e31f8e05311210c9b4022f2d6fbf5fd70360bc9073bd +size 4337 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/full_stacked_walkway_2.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/full_stacked_walkway_2.nbt index 39f75eeb..2e558797 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/full_stacked_walkway_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/full_stacked_walkway_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c414525505046907d33cf27f631291824d94a1e0de47a0bf0707be3483541efb -size 4280 +oid sha256:34c5b07d5d2466c38341df61457b3cdf6bd0c0f53570747734b64ea387da441a +size 4281 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/grate_bridge.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/grate_bridge.nbt index 42d9b01e..4b386f0b 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/grate_bridge.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/grate_bridge.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:546332239ec348c5f5f129d7e20b9773bcd3b11081af57ad21fa8f7bd2108778 -size 1753 +oid sha256:d36c593004773aaaa8a312eae63f9efa4e5f16d6034424bcf41b4efdae449e09 +size 1754 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/hanging_platform.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/hanging_platform.nbt index 5124e210..6404010c 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/hanging_platform.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/hanging_platform.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5d4eda960c683143e87de39efb2411c8dabbba39cc2226191d5f7bcd43ee216a -size 487 +oid sha256:d25f6d9bb4f411701701996780c53a613a1aff7cd11cea0be6b8a7041e11265e +size 488 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/lower_staircase_down.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/lower_staircase_down.nbt index 5e4e495b..6c5b9ac3 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/lower_staircase_down.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/lower_staircase_down.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:adaba8e9d3e9b63ef88006831f623f28481b86626e65aadba4962708915d84ac -size 428 +oid sha256:3fc83ac1d17e988eb4dfd3af7553e09c999340a170343f093069430d714bbcad +size 429 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/short_grate_platform.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/short_grate_platform.nbt index 438a8c8f..9f6c9c91 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/short_grate_platform.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/short_grate_platform.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:633646120df47c83ca5ebdb75734cb357a00c974ea383764f36c3acbf8770d6d -size 799 +oid sha256:5a533a0b670fcb634907087e417c0a5e708a597362b3750a40fff14bd2b1f5bc +size 800 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/short_platform.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/short_platform.nbt index 036afbc8..75b7bb21 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/short_platform.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/short_platform.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9f7c6c2fcd7ec98346e911635e55914f2fb01ba23d2d792c7b45a994a8fd71fe -size 583 +oid sha256:cc36d118750b649dde734d32be749d83d158509456b91cde3572cef3b0e2f02b +size 585 diff --git a/data/minecraft/structure/trial_chambers/chamber/addon/walkway_with_bridge_1.nbt b/data/minecraft/structure/trial_chambers/chamber/addon/walkway_with_bridge_1.nbt index fdf64e28..3f80ad81 100644 --- a/data/minecraft/structure/trial_chambers/chamber/addon/walkway_with_bridge_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/addon/walkway_with_bridge_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a97b398b182ee52e9332c1e43f2bd61defc6587610c1fe536910302397725ee5 -size 6221 +oid sha256:fba4c74612fcd191b40afc744a4a3c671dd036c0522afdf0c0f6704dd96209ca +size 6222 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly.nbt index 314956d4..31cfdaef 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:834c52448847f4bb66aa2234a852e6487a9a3afbc1bd9f160f0dae284b72039d -size 54407 +oid sha256:db894c78f0da8b44e5a0c79b351346b5ccc999416b0fe7d4c3bc9ff509c7b3df +size 54409 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_1.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_1.nbt index 221cd531..d41535d8 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4471b0123e7553ecec70c60e4399ad59fd4d583b88b4db08488f66efb308db33 -size 956 +oid sha256:c2546a9236b7ff319a51da439e5a9ef876d4a984f75048126d2b2ea23ef1cf9c +size 957 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_2.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_2.nbt index 02d4a5b4..d01f2720 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8eb32e9d2090342e9d3174d4f7e777c24227f35a742d5ca0062b90944c068e5a -size 949 +oid sha256:78cf6560d4a5947b6df06a4a79ebfc691f9ae388009dd31a71bd2e59d5707c5b +size 950 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_3.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_3.nbt index 1e0396c0..306ed7de 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f8b4b10cbc517255b9c58a6e130baa2fc20f16f8f5a785b197817eae57197f01 -size 956 +oid sha256:c4a7215d5cd5550322eb000a09075bc595d8ef1afdf78441e328b8beabcce624 +size 957 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_4.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_4.nbt index 37d0f191..ab340718 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_4.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6a70c8836c3934dd7d102cf641ab5516500822739acd4c9658886576d7ede355 -size 952 +oid sha256:a916c82fa22c31b5b9f2dccc0d4a4c0278f9809f03b61a1b3a0482352a15166f +size 953 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_5.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_5.nbt index 43b7a4cd..6c952606 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_5.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:93e270d11014b5411c948b9c98840aee951f507016eaa3a84d16cc6ac2a6dd55 -size 1023 +oid sha256:e83f584a207ee3ed336cd89be1fcc7a1640b06f6fb8e5763e1a143ea2a14b396 +size 1024 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_6.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_6.nbt index 9ebf2eda..0cd7251d 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_6.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d190cef037cff2d929df7d01ff1a509a96944e1fc954f2aa1e7cd235791b8405 -size 1021 +oid sha256:3484d090e3be61fcacc0b3e255839c7c60558ce442ffbe75c723fff83de3d1f2 +size 1022 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_7.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_7.nbt index 9f956662..0cdc9f25 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/cover_7.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/cover_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8bfa268ef616d54b685e77f8af925c5d5e4f774e2c5bd114edca0819bf1a4193 -size 755 +oid sha256:b80a71fe01ba645eb8894977c70ca7accdab1dc40401b7db08294db20cf85bb8 +size 756 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/full_column.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/full_column.nbt index a6d46c32..327336a3 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/full_column.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/full_column.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1ba06e037e8cf70fda41ee18045bbf1f7b0e6b4b3ea4d8dd04092289c137d03b -size 660 +oid sha256:4cf6da338fff29035d2defb4fc5bfc2bc9224b180f50fa35ea2d24505a43226f +size 661 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_1.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_1.nbt index e2a9253c..ffa9e32b 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6cefd8c437e7e2462faad99130a6c364b9359dcc593e23d1e415b2bbee3ff78e -size 586 +oid sha256:0665f37afa2c2f5d87bbfd56a80eadd51ee75796244004c698ba97866108f51b +size 587 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_2.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_2.nbt index fcf2b979..2daf4a1d 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1dac1ad60d6aee737ea1d952f75c52e932dbc1c6d3a3ab67f5644e08dd4becb1 -size 868 +oid sha256:c7b02ed873c224b28498a56e679d0b1e648338f70763950ce353d1fd0c4c1827 +size 869 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_3.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_3.nbt index 37f6e10f..65c6e02b 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cdf5aec6d7d34a7b7b018ff14ad3ecaef526b27149faae1aeb7b553dc8adee48 -size 536 +oid sha256:b764d23c6909446e6a3ef960c18b82a4079e0870059cfec5eaf8d80500fbb2e2 +size 537 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_4.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_4.nbt index 491d90fb..489bb049 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_4.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5d9ab38197e8d03a5626f9d28ae3cb5add29eead2ee5fe9d58952f156e8ded29 -size 638 +oid sha256:68b452cd8f8ba2a5fbdce0ccf675149dadabcaa0fddbc5f7fbd8241e6a3ede96 +size 639 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_5.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_5.nbt index c8184dbf..24efa197 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_5.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/hanging_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2ea62ddefad6300c661bed636fae2ea927504ffadd30f89dc0438479feb3e47d -size 339 +oid sha256:a20ffc225f0744803729bddc69315c885ec26c02be87995789f1b299ef3684c5 +size 340 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_1.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_1.nbt index 2f566247..106b5f32 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8c8b03678d3f6836b5f338b943bd2d82fb994e17cecbbd6098b7dfaeeaddc6e7 -size 2461 +oid sha256:675c7f6b8aa5b67c3f1b08eec0a4dd1904aff206d6465275fe47dc41de29a83e +size 2462 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_2.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_2.nbt index 94c79885..8bfbf9de 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:46d8be41e6dd6c9b9eef7031173af9213c2c102a38be1cb11e24cc1931ffe83e -size 2494 +oid sha256:2bd2a0e49553fd48990b5c801f3b92c6ce28de9da80c3df8d3091b20a84e0afe +size 2495 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_3.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_3.nbt index bd3a9ac9..2e682dd6 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/left_staircase_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a51e937fc375bb197023d3c3729f07fde71379357320bb80a0a55ef5f29bc70b -size 2509 +oid sha256:225fef580c864a742e34a2a473b72d484ae13ed5f3da324f22788044413e1180 +size 2511 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/platform_1.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/platform_1.nbt index 553aef04..27cdcee7 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/platform_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/platform_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9599bfdbe69dfc7df796e08ee6bb14c0432590f504bba6ef964fc641487bc385 -size 471 +oid sha256:4db33533e2db454977741eeea106ba4ac676adc30caea2ba22f621f8113eb34d +size 473 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_1.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_1.nbt index 0c0137ed..a0828a1f 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bacf83745cfe022a6426a272cd310839977444d8d4490ad1314498d74e1ac198 -size 2423 +oid sha256:a4e9b6222a3bd98b8f72644f6f144a104e7a2dae50ced81365cf071685e8a530 +size 2424 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_2.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_2.nbt index b4dbebc4..253368d7 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5fa88c6a18462787b8449d3c4ece6e23ba644d677b58e69c91e8d94a45ff37fc -size 2550 +oid sha256:aecbd7a39a35be28aa2d76a2340f29cd5cf62119ea6221bb769f5afb9b48d01c +size 2551 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_3.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_3.nbt index afb2f1ac..7679d593 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/right_staircase_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:02a3b7fd72ac0f50b9d3f7e0aa93a14b45b990701fe2d6de11b2f45a8f51f514 -size 2556 +oid sha256:0b61448260af4e342b218304d304afde7537ec64ee49d04e3905df616692454f +size 2558 diff --git a/data/minecraft/structure/trial_chambers/chamber/assembly/spawner_1.nbt b/data/minecraft/structure/trial_chambers/chamber/assembly/spawner_1.nbt index 6a3e2743..5989943c 100644 --- a/data/minecraft/structure/trial_chambers/chamber/assembly/spawner_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/assembly/spawner_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aabba3dc85d520dc5f85bf56bd7e8f1baba1f6873b1eb8356edd1465bf4933f0 -size 915 +oid sha256:fc2e37afe5896db151e6df747982b4ed5fb0cf4a31815f5ea83f4225a0a164e1 +size 916 diff --git a/data/minecraft/structure/trial_chambers/chamber/chamber_1.nbt b/data/minecraft/structure/trial_chambers/chamber/chamber_1.nbt index ef082843..a6288892 100644 --- a/data/minecraft/structure/trial_chambers/chamber/chamber_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/chamber_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6e8f807d861808bffe422131f405edbe143d99b228ed609d1d9fc900876439e4 -size 38588 +oid sha256:a8c6e5d07fbf7f7753d854e3e15ca7b5fbcfab743c406503e7f90e5ffab1a252 +size 38589 diff --git a/data/minecraft/structure/trial_chambers/chamber/chamber_2.nbt b/data/minecraft/structure/trial_chambers/chamber/chamber_2.nbt index 384465e2..33c7d17e 100644 --- a/data/minecraft/structure/trial_chambers/chamber/chamber_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/chamber_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:987c0184040efbd87c253bbeb73c9f07461900ceda9edc7a3d75b8601b5076fd -size 38937 +oid sha256:a3ba7af853a44e4610f53e2a96ae2aafddc56ea77964a2a17e49f9ff276d0d50 +size 38938 diff --git a/data/minecraft/structure/trial_chambers/chamber/chamber_4.nbt b/data/minecraft/structure/trial_chambers/chamber/chamber_4.nbt index 3de799b1..55c37ff7 100644 --- a/data/minecraft/structure/trial_chambers/chamber/chamber_4.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/chamber_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b1952a6577eb0a5cb45e51926d365fc52f2d52e09f773482e9cb739ddebff733 -size 24478 +oid sha256:5e637cb98838c02e44104d70014864f8a30660b8da3334525846e83377645ef4 +size 24479 diff --git a/data/minecraft/structure/trial_chambers/chamber/chamber_8.nbt b/data/minecraft/structure/trial_chambers/chamber/chamber_8.nbt index c8646ed8..def2226e 100644 --- a/data/minecraft/structure/trial_chambers/chamber/chamber_8.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/chamber_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:62d107d2825a4f447d0a360678c19e87d2356be4054bcb01aa617331a4eb541e +oid sha256:432df228324fa35b45a8b212ad63434540835607510a573e6abb87048b4199ed size 19203 diff --git a/data/minecraft/structure/trial_chambers/chamber/entrance_cap.nbt b/data/minecraft/structure/trial_chambers/chamber/entrance_cap.nbt index 1580b650..391c694e 100644 --- a/data/minecraft/structure/trial_chambers/chamber/entrance_cap.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/entrance_cap.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a0e55e446c6d63f5dede921b06d0ddb0dc1c72025329417623407e869ac6dc46 -size 382 +oid sha256:f5c0328898d258c1689c6e3a23fce563d72b416b5cc0014ab7728b155377c927 +size 384 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption.nbt index b6d15332..383599ef 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d179106c8babbe016eb72b320179b2aaec33940239ff7451d42404e6b3be2eff -size 31896 +oid sha256:c2914d5d7eeb6581986572281578922f40e577a5ccc772f12089b727aaae67f6 +size 31897 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/breeze_slice_1.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/breeze_slice_1.nbt index 9de5a415..77782770 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/breeze_slice_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/breeze_slice_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aa732f4ff8419bc736b9e121ae4e6d4f9c1db6aee58934876baf39b087ff73e6 -size 2593 +oid sha256:ec39594f65e806198e1245fce573ae93d8d58627ce20ab760464bf1d30bf56e5 +size 2594 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/center_1.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/center_1.nbt index b4fffc01..3ec00510 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/center_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/center_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2a2600a3b0e0fced8d0fadd13e3acc62760933634a05aaf48754a6b0cfa2a053 -size 1536 +oid sha256:c8e1753c581d4d4f9a5f4a69e63b30430b9e20128f0fda4a4d9f433f2584317f +size 1537 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_1.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_1.nbt index 9e560f05..57677dd8 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2ab0771c90a3cceac59d8a946a02a04bd66a99f26744fac0ff0f91a303162e65 -size 4436 +oid sha256:19508250e4c53949c04bca527c39321ecfca2f28e7abfa9a09486acdc5552c44 +size 4438 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_2.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_2.nbt index ff8c1969..e20b85a6 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8c1d1b8a3c5c32b717ab27c5e7cf8f6beb9be22530ddfb5e9cebbc96e69354d9 -size 4601 +oid sha256:03f4f915a42687a3bf919805c6b506e353b8dde41d3b8f69167ce97f7ecac03b +size 4602 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_3.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_3.nbt index 25e0c3f7..31a6b541 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:59781e8d45b2f05541bc326349fdbf42071a6f50fa83eb0efeb4d10943ed2919 -size 4682 +oid sha256:4db0e8b059443a80a59b36cb2b8addd12092fc3a9e539f2df2aa3750e61fffe1 +size 4684 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_4.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_4.nbt index 10be2492..4b59d915 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_4.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1c8262c31a7abdb8a8b20ae84f7336678a2012cee788d48fab052487ce6dd39e -size 4834 +oid sha256:21e35e7325f3490e3fef12c1613508f25e2f027e284192418b37899d18ad3ec6 +size 4835 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_5.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_5.nbt index 9983618f..f6ac3a71 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_5.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/quadrant_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:142c983eb32816b8c98afe8de29e0e9a3e031c8e2f92675ab2a3fac6b4edc9bc -size 4785 +oid sha256:ee5e78e5a6cdf5abd27b9d527e39f5ec24610663cb00e932d742e76f38936c00 +size 4787 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/slice_1.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/slice_1.nbt index 98888118..195bfd21 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/slice_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/slice_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:efd77377af16c67965e8ca9706f50ae22db15d0a790d853ddf5c29ca922bb86e -size 2505 +oid sha256:668e3c8442251a361b01032c3cdacaa44df9f95ff1e67f09cf7130e7c29f5440 +size 2506 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/slice_2.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/slice_2.nbt index f3f6f077..9fd55a77 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/slice_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/slice_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:647da15b2dec93ff8d94c9b8b745d00ea73f6bfeb31f59dcd856f178d8eef4d2 -size 2482 +oid sha256:04628b4339dcd28cda378c95f5597fdf0f58b7c5f66c47b5a3871cec09096867 +size 2483 diff --git a/data/minecraft/structure/trial_chambers/chamber/eruption/slice_3.nbt b/data/minecraft/structure/trial_chambers/chamber/eruption/slice_3.nbt index dc865d70..ee22b474 100644 --- a/data/minecraft/structure/trial_chambers/chamber/eruption/slice_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/eruption/slice_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e676f78db5ce52f5574cfda9c3b1ae2c773c4c8e2870fc6d83bf8fc1e01e93ea -size 2475 +oid sha256:bdd86ac92086c00316819000f35b3ba05c323d9da84fc896315abc272a523aeb +size 2476 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal.nbt index 2701a711..d81573f2 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7fdda8d0bd71f43c55c3d57d312156e2b563ec4566551c4aef55c4d4690ae761 -size 47358 +oid sha256:b295ab3103c3932f3f2fe1e73ecead95887b961252cc45af37174598a148991f +size 47359 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/center_1.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/center_1.nbt index 79c060f1..9858bd1a 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/center_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/center_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:106333bf255bbef2f2d9839dc05345f64f0bfbf7f9af2d9d89a773cb495e6d69 -size 3676 +oid sha256:75e5faf16607b6cb5e450776d9faf2f866f1b9b5d73917256f24700f7c82b071 +size 3678 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/ominous_slice_1.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/ominous_slice_1.nbt index 27843167..6f8e6f02 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/ominous_slice_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/ominous_slice_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7630de556f055b609f2570d9064400b79aa2270e5ebf86ac303c62132cc8b35b -size 1918 +oid sha256:331b71a8eda9ee8122f17710185d85c0c23287ce7443316313ccc02cb7981b32 +size 1920 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_1.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_1.nbt index 49d5c304..2146635c 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f0dfd1a8a23d1d9ffbdce4bd4b46829f912ff8af469deed5bee4473090d2d72b -size 3461 +oid sha256:3661dbc9a9cc50baeacac35c606c2c54661117a54afb7c0155762096ff58932e +size 3462 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_2.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_2.nbt index 09d4215e..cc054a97 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:51d26d0d3b8e4e0017d05e3967e00b9d172844b250d23bf41b6f7417151eec31 -size 3325 +oid sha256:20a31e073feecb19e7b0b1f41c1de7641f7813f5fe6ccd83cb1fdf74f2db4c24 +size 3326 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_3.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_3.nbt index 2b98cd86..734d0941 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/quadrant_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:39374993a5255172030b36c05b7300c7849ffa497678bc5fbf6f24e64b29d06c -size 3908 +oid sha256:330baee7ed6b7cda6ffa4cc8f4fd6ffecefb78fbdbd0d787cc4285644dbfcd5a +size 3910 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_1.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_1.nbt index 19893815..c55e03a6 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1b5f84beea8b97f0ffeae643ee82316ab0447cb91984e05b8eaf652cceebb4ac -size 1921 +oid sha256:c221a25e972fea2f08c26aabdf78044cc3cdada18f0468fcd9832716ced5b2fa +size 1922 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_2.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_2.nbt index 92e69055..e950def3 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d1ae05ae5c609cbe38a46e02217ce1b419cee3559d661c5786c31145c8831a7a -size 1963 +oid sha256:bb86f5590ffc75974fc5f10517a5d46719c3747ef2b107af874db4b08cbe3cc0 +size 1965 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_3.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_3.nbt index ade0ffd5..a68920b2 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d3cb1114579c662951fdcc614d7c602f974417c943fc078e04dbf3919cfef2fa -size 2010 +oid sha256:20321a5dfd2b73ea583ee793153b5efdca27a5a15fceca0f39299bc25ac4265d +size 2011 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_4.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_4.nbt index ebd5c711..578b9abd 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_4.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d1728ef9fb2318624284ec4960e20aee4d1950fc24a633347caa077fce63fc33 -size 2017 +oid sha256:e64d09f6653a886c56b3d9d085e3c7918a8756766ce3f54d2bc3674c4c8b3a33 +size 2019 diff --git a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_5.nbt b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_5.nbt index 3f8f41b6..46715e26 100644 --- a/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_5.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/pedestal/slice_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b1906b936cb558f3078aadfd7abb396e8d556dcbcb51a112c150f06044efae56 -size 1970 +oid sha256:3b802f037ca8944763d00d9f4ab6f7a6dc23e8238272a2e7ec1476eb744cd07b +size 1971 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted.nbt index e1be5cfc..4231a0be 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3104c78433e2cfcdd6e7cf9fcd011924f11e87db929ff13a0d806b72745bd80c -size 34272 +oid sha256:b984607c2c0992c89da34130ff8b60a599a30467c9ddd225e4cbca0f3dd39285 +size 34273 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/center.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/center.nbt index 700e96ff..0c881b1c 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/center.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/center.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a3b89760f76087c67a1bd8833623dfc13b5805f8ed968314219435426e884a37 -size 1274 +oid sha256:b187a12329f7192efd64af50171ab3177ab27e8cf317fa9d0c65ef613d1efe2d +size 1276 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_1.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_1.nbt index 9ba8bc9e..f48631b8 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:df02e99a825c983fe811d2ca31827b0311726606743ad53140655a3106ac4c58 -size 1007 +oid sha256:99e2a145ab64ee61d89d51b6ade2576e028c08e6e8411bcef6e7c13f0285c2de +size 1008 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_2.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_2.nbt index 650ea5a0..24da8e30 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5ccea10186557330697ebe178e367b563f7fc88d5ef854e28cde9a3eff31f29e -size 1132 +oid sha256:f6bbd4c10785c4f50c609d4d1ff7b0f683915d6e9359acc0a755e0183c52ad97 +size 1133 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_3.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_3.nbt index 6070d39f..8aaaeea4 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/hallway_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:003da197c302481507b4907273236e730b21a817f2b4e15fb9e9f49339f1825d -size 1058 +oid sha256:57178d6d5ffd4a199e87718ae394e231d3b58fa9b9ff926fcbc2cf0a52752326 +size 1059 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/ominous_upper_arm_1.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/ominous_upper_arm_1.nbt index c44d1f00..b4af0da8 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/ominous_upper_arm_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/ominous_upper_arm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c50ca8f6f7156c10282d2909a5c1e1c43851fc08562f465023bb3f3a624a228 -size 1343 +oid sha256:ed6c1efa3d73dd00638faa639a923dbf2954d3886861f933f9e092e7b238bc92 +size 1344 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_1.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_1.nbt index 0636d200..5a793dda 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:218daa2a6a80e18e84e88a82cd89e431e02ad339997aa908a155ad836b4980b7 -size 3430 +oid sha256:94d64e1d800ea3daa3e7de55fca831fb9f9aed1ca4e195a7940aaf81760f7a43 +size 3431 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_2.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_2.nbt index e3c18e6b..14742a19 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4404d43fe4afddf4c759ed387618d5f143fa3050cfbb7ff9df87e2867d4274bc +oid sha256:4b7f3419c4ba135af9a82e27aaf9542b309b66338738f6bef29d8a4267cba0d5 size 3446 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_3.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_3.nbt index 2653bd5c..7fb0ca03 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5d87e751c7f9a358847ad74d4615d06809245ed7bcdec0d418cb619fd9e442ac +oid sha256:716549066edeceefe0c1e22ecafdb782fcc504eaa1299de091aafc307deb3dc8 size 3436 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_4.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_4.nbt index 301c3697..aa34db1d 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_4.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/quadrant_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:57c923878104d4904522f6d416e003b8eeb9620ca40e55875f57b00b6d179ff2 -size 4324 +oid sha256:1ffecc8da9674bd5d8866f74c493d47a555cb3898a54aa315a60e746990db0c2 +size 4326 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_1.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_1.nbt index 355ecc39..23f4f9f9 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_1.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:080fce90e5890a3e3bf5547be3aeef4d18795b6f7c29c5c614ff3ba37d1ddc6e -size 1323 +oid sha256:36847877135397a449c9f12b1cc6697453b59c929b5dbeee82a98378556dde1a +size 1324 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_2.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_2.nbt index 146b998a..36f9f88d 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_2.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:03696e975b678764a4bbee3b7f0ed655c8471e807b32fb5b0500f6bb1a638a2e -size 1317 +oid sha256:5f2379dd777a2e9610001b50e0898c55d52a7d9a248f892143dda684225b494d +size 1319 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_3.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_3.nbt index 4ea64538..44f5da17 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_3.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4acf38208483afb5d39c68d45ebfdd0e8b0e52e5df48a646caac8f4dab160a3a -size 1452 +oid sha256:33a72af41000038a81f25ecdc91b80df376d30d7db83a0b656ea684938834a84 +size 1453 diff --git a/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_4.nbt b/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_4.nbt index 74fe0b5f..904a0cf6 100644 --- a/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_4.nbt +++ b/data/minecraft/structure/trial_chambers/chamber/slanted/ramp_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8f4eeacdee59b18ef6a2cdb189adc85d6f3670aea49a32bc220f3c31bf3df932 -size 1231 +oid sha256:8a8c99e63cfca10267a039c203e15cf96e58adf644006923284672fe1881cfcd +size 1232 diff --git a/data/minecraft/structure/trial_chambers/chests/connectors/supply.nbt b/data/minecraft/structure/trial_chambers/chests/connectors/supply.nbt index 1e9168ab..3dac102b 100644 --- a/data/minecraft/structure/trial_chambers/chests/connectors/supply.nbt +++ b/data/minecraft/structure/trial_chambers/chests/connectors/supply.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:76ea8fd1f99a05093dac9f9aef76e6e5a15a85f89f8011d598881db3c2c27fd2 -size 353 +oid sha256:0fde573e8d394658bed123d8254680c37a7b4b85f150f60673273c1a71e8e658 +size 355 diff --git a/data/minecraft/structure/trial_chambers/chests/supply.nbt b/data/minecraft/structure/trial_chambers/chests/supply.nbt index 992317bf..ec690e78 100644 --- a/data/minecraft/structure/trial_chambers/chests/supply.nbt +++ b/data/minecraft/structure/trial_chambers/chests/supply.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e183ff5afc830bfd05d379e7c5ee36a7cb32581c3f20ec962724e2939ca64ea -size 439 +oid sha256:68ff0fb04c804e18705fda445021b1112b9bd4c0c7185a5dac296596dd1367bf +size 440 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/arrow_dispenser.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/arrow_dispenser.nbt index a32b9895..04b18aa5 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/arrow_dispenser.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/arrow_dispenser.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0aab918569a88f5c3a06f9be001e331504c59e9a6efe14e5463daea2e3da4e12 -size 834 +oid sha256:532eb16fb777b8dd89dca5bb213b0870bf541ecb5cef2a9f380c883211b6f772 +size 835 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/bridge_lower.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/bridge_lower.nbt index 16fef995..b7bd70c1 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/bridge_lower.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/bridge_lower.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9d625b15e599d5a5455bc67aa00b3e55e9fcd91ffa70088c000077b8acd1d88c -size 697 +oid sha256:5d5c51a6c9f1b553ed7ae9e89eb12d7ae7a9aa048e62b7f86204919b5b7269bb +size 698 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/chandelier_upper.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/chandelier_upper.nbt index 5c3ae103..b1450c2b 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/chandelier_upper.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/chandelier_upper.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e21b90305bc86eb03377d349ae146f3ed86e9c5fa264290ee66107c542ba05a -size 513 +oid sha256:156ad800d5d496b1dcf13688bbee3d528ba45cf6ef0548a5659576aea9b018e9 +size 514 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/decoration_upper.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/decoration_upper.nbt index 6c8ff953..2b85f42d 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/decoration_upper.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/decoration_upper.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1e4db64ace2d47d22eb8fc0cbb879122915fcfffe20c92e1a4b87d2c58c99d35 -size 513 +oid sha256:800c3753bd9c66f7afff6e12dc09a585e28790a6e22c680fad6e16bb150ff872 +size 514 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/display_1.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/display_1.nbt index fd3eccbf..71a232ea 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/display_1.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/display_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9593f50fbb70e98ef21d0de1930c3e0ea85657614a076e53c63cd64fffe86322 -size 900 +oid sha256:b9673a2b70fa92bb1bcac56cffaa3001f6eeaccfa262c82c1acc92b105be1630 +size 901 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/display_2.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/display_2.nbt index 7a927602..d955a846 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/display_2.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/display_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:84ff2fce9536da599cda74afcee27d94315fbc16af6dea60488640a98c780d8f -size 1527 +oid sha256:8b7c4e7cc24131893045db4708264ed7817a40d2cdedb0d3fa6330bc089c7c6e +size 1528 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/display_3.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/display_3.nbt index 8a1a9882..a0d54316 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/display_3.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/display_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7e9bf1330610ac364be210164eb34e80d116bbf0c5d59182aa07f70dbeb758fe -size 811 +oid sha256:9a5c413e8f8e4a0f145d69ae4de050ec2bfe371612f28b5b57fc48630e4a2e8c +size 812 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/head_upper.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/head_upper.nbt index d4e0fb42..f7115ca5 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/head_upper.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/head_upper.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3e11f19cdb0c6f4e8a7a25bf64b3477bbaa4d696e2cd96c5793dde8c288eb829 -size 525 +oid sha256:dc8b35e37dff3f53091a2262a5d32b254f6ea0b9fb29860005b6911210ffe5ea +size 526 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/ladder_to_middle.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/ladder_to_middle.nbt index dbe2384f..50d1c12b 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/ladder_to_middle.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/ladder_to_middle.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e86702aae58329419e559d5d42bd46cfbad7d2ede401a2cfb2f2a79982a3a447 -size 669 +oid sha256:55b9b28c0bc3490395fc22465831618c6101ac9d9943bc93c4dc77924632ada1 +size 670 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/open_walkway.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/open_walkway.nbt index f292b784..5cc8dc7a 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/open_walkway.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/open_walkway.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ca832d03fa6d73c8a4b576f61877dd14e513750df37f5a9d398aded53a34f534 -size 1160 +oid sha256:486bf7f9363451c7f1f1236127f8e3432642ef75a6d6371d56d77c1658af7a55 +size 1161 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/open_walkway_upper.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/open_walkway_upper.nbt index d2baca1f..fd8e6baa 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/open_walkway_upper.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/open_walkway_upper.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9a4932bd32a0aa4ddcff1e9f91920c978c6c0dcf2a57b5f3d9cefc822b01b898 -size 586 +oid sha256:35c3ec728d2d798ad7725babf4560c148f8f372dada951a8b12d599403eca1d7 +size 587 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/reward_upper.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/reward_upper.nbt index 55482d65..ea90477b 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/reward_upper.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/reward_upper.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:914bbadff2d2103765e81b9b3babc09fd4f6ddf513a4190a4dfcb9834a293bb0 -size 588 +oid sha256:2a6393e09c4de0fdd9762bd387b356c30b0121bec76ff62ffb01ee61b4e7a3dc +size 590 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/staircase.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/staircase.nbt index e2741415..a916e27d 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/staircase.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/staircase.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:99c9d81d53adaf09d2ea03ed1ffdd4f7e5519f11b4b60e99066a28f2f32d69a7 -size 456 +oid sha256:c4e1cba468e358e2d61f5e0b84c4dd2d6a86ea27e8fbf49f9f2ec8634ed1d067 +size 457 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/wall.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/wall.nbt index 568eca31..880b92f6 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/wall.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2978cd73a8b44fbbc6231846c984cf556b985898b9efa73a5ce7c37081105534 -size 908 +oid sha256:4bdf1b43d9df51f1aeda37db6dcad60ca64a4cc9ecb71ec8eff7cbbdb0d143e9 +size 909 diff --git a/data/minecraft/structure/trial_chambers/corridor/addon/walled_walkway.nbt b/data/minecraft/structure/trial_chambers/corridor/addon/walled_walkway.nbt index d06ed164..5759e8ca 100644 --- a/data/minecraft/structure/trial_chambers/corridor/addon/walled_walkway.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/addon/walled_walkway.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6aa9c75552e221604e450decb49f5ad57b9ae805d4f018bb8569e6b3c6a8e2b2 -size 1186 +oid sha256:a4963cef102f5160f0fe5635b777f6472e2c987818dd20e858000fc0c09b002a +size 1187 diff --git a/data/minecraft/structure/trial_chambers/corridor/atrium/bogged_relief.nbt b/data/minecraft/structure/trial_chambers/corridor/atrium/bogged_relief.nbt index a792d87c..92f6c32a 100644 --- a/data/minecraft/structure/trial_chambers/corridor/atrium/bogged_relief.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/atrium/bogged_relief.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3606d50be8c68d39b57b4ced601f39104c4d846253f06575303d394f310825cf -size 3244 +oid sha256:d75d6a0b99d2d37be081ddada6ccd6a237ef2092e83f04ae9fdefeb105e231d2 +size 3245 diff --git a/data/minecraft/structure/trial_chambers/corridor/atrium/breeze_relief.nbt b/data/minecraft/structure/trial_chambers/corridor/atrium/breeze_relief.nbt index 45ae5510..3cf60307 100644 --- a/data/minecraft/structure/trial_chambers/corridor/atrium/breeze_relief.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/atrium/breeze_relief.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5cd78ab1785981dd07ca150cb5aedee8379dc59e6da39f881134d06005621a5b -size 3223 +oid sha256:a587c41a1e95087052d7f1a124224fff571eb2fe97593bbfb7ac54f3827815d3 +size 3224 diff --git a/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_1.nbt b/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_1.nbt index 7064fba7..5c6139fa 100644 --- a/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_1.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:07d14d3854811f9ee9c576f40876279c648477ab0bfe87a0581810a1e64b4103 -size 2882 +oid sha256:a1303c85e302960e6660e2373d282b7ca104227ebf74717f874e599fa1f19788 +size 2884 diff --git a/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_2.nbt b/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_2.nbt index 15262d7e..20cac789 100644 --- a/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_2.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:12534449b4b226e2162f7b8df6a4019f740b9a69ae788220308eb704447a4ff4 -size 2819 +oid sha256:94053b9593b8714a403679eb2fe66dea6454fc073648b3a953ce2a5b463a033c +size 2821 diff --git a/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_3.nbt b/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_3.nbt index 6bb2cdf2..6a96caf5 100644 --- a/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_3.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/atrium/grand_staircase_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7e9acc19666189140bbdc2b8bab2cf7df32d47f7a947f079df33ae2a9bde5574 -size 2830 +oid sha256:07e7f175a7951f3eac8c38a23e0b2b16c69b54f23997d74307178ae83ba34d63 +size 2831 diff --git a/data/minecraft/structure/trial_chambers/corridor/atrium/spider_relief.nbt b/data/minecraft/structure/trial_chambers/corridor/atrium/spider_relief.nbt index 41b35413..51d70b94 100644 --- a/data/minecraft/structure/trial_chambers/corridor/atrium/spider_relief.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/atrium/spider_relief.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2e9a1659a988258928be51b0569ac5c5f7a6ebddb4455860422d3991202dc78d -size 3848 +oid sha256:b968a924d2928fda0b15057ab8746e7fca90a983b04c34c0e2c2002905c54238 +size 3849 diff --git a/data/minecraft/structure/trial_chambers/corridor/atrium/spiral_relief.nbt b/data/minecraft/structure/trial_chambers/corridor/atrium/spiral_relief.nbt index 067ceeab..0ccd1658 100644 --- a/data/minecraft/structure/trial_chambers/corridor/atrium/spiral_relief.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/atrium/spiral_relief.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:69d0bde2fad0e59a53152962b82e8507d84078bc608692a626267b01eec3f3fd -size 3316 +oid sha256:1e91518beb403cb6ac2c54899b2bc0c22c7eae54f6a363a6e7bdded6028ae597 +size 3317 diff --git a/data/minecraft/structure/trial_chambers/corridor/atrium_1.nbt b/data/minecraft/structure/trial_chambers/corridor/atrium_1.nbt index 64dfa42e..a2361e5f 100644 --- a/data/minecraft/structure/trial_chambers/corridor/atrium_1.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/atrium_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a56007d42848d65b0a42948e42c2e17b7f887561aa96393871b59821d09ad974 -size 23426 +oid sha256:eb07c940b52744a466d8780269dad6a3a9a0457cdcd960cfb228e7bbe9f0b76f +size 23427 diff --git a/data/minecraft/structure/trial_chambers/corridor/end_1.nbt b/data/minecraft/structure/trial_chambers/corridor/end_1.nbt index a3e6e741..9f895c8c 100644 --- a/data/minecraft/structure/trial_chambers/corridor/end_1.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/end_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:35eeab1a5dab93578c71324da48eef80e10774bdc2c9443fda5d2e465baee411 -size 21444 +oid sha256:11c106c1afc3a392dac32ec26d28b89a06f25931ba3497715a42e4712c1f9406 +size 21446 diff --git a/data/minecraft/structure/trial_chambers/corridor/end_2.nbt b/data/minecraft/structure/trial_chambers/corridor/end_2.nbt index f6213236..4125a818 100644 --- a/data/minecraft/structure/trial_chambers/corridor/end_2.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/end_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8b4ec3464418a5cdafa73ead88a9b1540e19eefd055d151e8169c493f8e21842 -size 21888 +oid sha256:be9ade1acde4400861f9010f7e2ae1ed290850bfbe2e061feab991664ee683b0 +size 21889 diff --git a/data/minecraft/structure/trial_chambers/corridor/entrance_1.nbt b/data/minecraft/structure/trial_chambers/corridor/entrance_1.nbt index 68579798..b8bd3e07 100644 --- a/data/minecraft/structure/trial_chambers/corridor/entrance_1.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/entrance_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:34c391a4fd4eb1d7e23bf89afc5dfd53a262a5680fc5a166abbc2c7772652bca -size 22025 +oid sha256:231b1735adb8ad38a1cad8329cb2e81d49d8d3bf67882c70ea3551a05ebe5cbf +size 22026 diff --git a/data/minecraft/structure/trial_chambers/corridor/entrance_2.nbt b/data/minecraft/structure/trial_chambers/corridor/entrance_2.nbt index 376843bd..42494c6d 100644 --- a/data/minecraft/structure/trial_chambers/corridor/entrance_2.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/entrance_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6d19455c9120f2b4b1f9ec27884f7c55cff48295e46aa0de35a84c5ee4fbd484 -size 21599 +oid sha256:71d8c35e9afdcb29f33bfcdaedd0ab3b654ef356ff46156f1832885c12111412 +size 21600 diff --git a/data/minecraft/structure/trial_chambers/corridor/entrance_3.nbt b/data/minecraft/structure/trial_chambers/corridor/entrance_3.nbt index 56e76c7c..24b3be3e 100644 --- a/data/minecraft/structure/trial_chambers/corridor/entrance_3.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/entrance_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:45050af6c018d9d9a970bd7aece74d8534fd56cb476d7578af659cbb039ecf82 -size 24029 +oid sha256:f197db17dbcc44aa831a39912f55f44fbf4bde2f93afa4bc0ea5ce68ff656e07 +size 24031 diff --git a/data/minecraft/structure/trial_chambers/corridor/first_plate.nbt b/data/minecraft/structure/trial_chambers/corridor/first_plate.nbt index d4a0376a..2e5e7dfb 100644 --- a/data/minecraft/structure/trial_chambers/corridor/first_plate.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/first_plate.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:df9877ab36499b136425e6ac4a2a99817c51f09dae2ae501b828eb9685263b86 -size 1472 +oid sha256:6d892cdaa068013a48d1241505913204ca5b7b46c1b98ccb3596d9795430a772 +size 1473 diff --git a/data/minecraft/structure/trial_chambers/corridor/second_plate.nbt b/data/minecraft/structure/trial_chambers/corridor/second_plate.nbt index 9b967ef7..08951f1c 100644 --- a/data/minecraft/structure/trial_chambers/corridor/second_plate.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/second_plate.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d39ba6b5c594dbd3df1049bc0932f0aa43a5a54135bf3ea6953b9367169b11a1 -size 1477 +oid sha256:880716d15554ffd4fed04dbf1b1026b1c81382ef71a73e1e334eef9058895f51 +size 1478 diff --git a/data/minecraft/structure/trial_chambers/corridor/straight_1.nbt b/data/minecraft/structure/trial_chambers/corridor/straight_1.nbt index 3e84d046..46da6ab5 100644 --- a/data/minecraft/structure/trial_chambers/corridor/straight_1.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/straight_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9226b03bd48e05c0e5735e8789e3012350b8ceebce12498c7f0200c2e40dd6de -size 5671 +oid sha256:8e54e41f3a3b165af77e075ad5f38c3368fdb4490c4689dcc37459b9d08c31dd +size 5672 diff --git a/data/minecraft/structure/trial_chambers/corridor/straight_2.nbt b/data/minecraft/structure/trial_chambers/corridor/straight_2.nbt index cf4e5a97..ce8d67c3 100644 --- a/data/minecraft/structure/trial_chambers/corridor/straight_2.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/straight_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0a0266c13d5f857772379621c57b4973639c42137f9f68600d6772701a606564 -size 5847 +oid sha256:3fb3f5e3e0f92ce6782bcf47c9504a696a46b96c330670a2369e7500104baa65 +size 5848 diff --git a/data/minecraft/structure/trial_chambers/corridor/straight_3.nbt b/data/minecraft/structure/trial_chambers/corridor/straight_3.nbt index 14ed0c40..f8eb60b5 100644 --- a/data/minecraft/structure/trial_chambers/corridor/straight_3.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/straight_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:93192f41ac2397aa5cd3abc7d624373f857240974de1dbeafa67e3815b418aa7 -size 5820 +oid sha256:fca6dfd5ee9592672a7c4713eef0116bd4be04d8d47859c479e15281caa1eaa8 +size 5821 diff --git a/data/minecraft/structure/trial_chambers/corridor/straight_4.nbt b/data/minecraft/structure/trial_chambers/corridor/straight_4.nbt index 4021f7ef..87af3515 100644 --- a/data/minecraft/structure/trial_chambers/corridor/straight_4.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/straight_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8ab834d41e603f7f2ec4d2f2afea22479a5e1c14346b6f9d465cf02a208fbffd -size 5814 +oid sha256:7dc689c3ca56fdcaf72c7352f1757c7754a64636f1c105b7613f986b79c96750 +size 5815 diff --git a/data/minecraft/structure/trial_chambers/corridor/straight_5.nbt b/data/minecraft/structure/trial_chambers/corridor/straight_5.nbt index 79d3c581..6b3d20e5 100644 --- a/data/minecraft/structure/trial_chambers/corridor/straight_5.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/straight_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f27b3bcad1f27bfe75a20cc4091ecd1f8a9436b47d959ceda9325f659501eb56 -size 5821 +oid sha256:d61e4ba84dece1875e20e87642e58f2ec934422f7ccbf6becdae1e8f77118385 +size 5822 diff --git a/data/minecraft/structure/trial_chambers/corridor/straight_6.nbt b/data/minecraft/structure/trial_chambers/corridor/straight_6.nbt index b6d7322c..d17d8f79 100644 --- a/data/minecraft/structure/trial_chambers/corridor/straight_6.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/straight_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:54e7fd93a852d8f311dc82c983f604097ecbb09f846ffaa4aa2dab16997426e8 -size 5786 +oid sha256:be0495335016b21f3ea046ee8c54ecdb4ed5f6ba5d7d45f4aa0f884e9c73055e +size 5788 diff --git a/data/minecraft/structure/trial_chambers/corridor/straight_7.nbt b/data/minecraft/structure/trial_chambers/corridor/straight_7.nbt index 53aeda4f..fbcc2a48 100644 --- a/data/minecraft/structure/trial_chambers/corridor/straight_7.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/straight_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e228fa24dea585a5b54eb9ef0729f98917e2ab7093de928c33fafdd75fa4b03 -size 5776 +oid sha256:8058ca53f3214266270386e87d3341ce650a55dcf22a755f24785fe81124fa73 +size 5777 diff --git a/data/minecraft/structure/trial_chambers/corridor/straight_8.nbt b/data/minecraft/structure/trial_chambers/corridor/straight_8.nbt index e8cd2c44..e085c7dd 100644 --- a/data/minecraft/structure/trial_chambers/corridor/straight_8.nbt +++ b/data/minecraft/structure/trial_chambers/corridor/straight_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e86533843abc08943e3a0703207d66ba88865fac5cc972973fa7535af7c1f3f -size 5561 +oid sha256:745a5f94b9b94deb7cf4090a38577423cad48cabeeed4a1acbe3824c36401afd +size 5562 diff --git a/data/minecraft/structure/trial_chambers/decor/barrel.nbt b/data/minecraft/structure/trial_chambers/decor/barrel.nbt index d3287ced..d84c720c 100644 --- a/data/minecraft/structure/trial_chambers/decor/barrel.nbt +++ b/data/minecraft/structure/trial_chambers/decor/barrel.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c84f20e1c07e60a4076a162be66fe36591d6fee9ce07a16fa4b5b34d6d87ac4 -size 336 +oid sha256:0a6fee458d6f59d2a3d92b159f67d217697fcee32ada3b5b9577136ec4c848e8 +size 337 diff --git a/data/minecraft/structure/trial_chambers/decor/black_bed.nbt b/data/minecraft/structure/trial_chambers/decor/black_bed.nbt index 95bac085..a81a9c05 100644 --- a/data/minecraft/structure/trial_chambers/decor/black_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/black_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ba2ad39c06f8c997d455b21974d3e03ef9f6d6f5979a9c4f60c06e540d325b2c -size 326 +oid sha256:2e89546d0cb54f00f0a60497f98ebb3b05496d0f22bcad79e23ecf543e53b66d +size 327 diff --git a/data/minecraft/structure/trial_chambers/decor/blue_bed.nbt b/data/minecraft/structure/trial_chambers/decor/blue_bed.nbt index cdc2a8f9..caeac9c8 100644 --- a/data/minecraft/structure/trial_chambers/decor/blue_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/blue_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:134a2cdb188b6fecd931b9c6307e9cfdacb7778640abb4fc08dc56b55c3e4056 -size 324 +oid sha256:e173866bd6eefa8f37990754f7a0845423a9a2319a21a48e91b3ceb0988714bf +size 325 diff --git a/data/minecraft/structure/trial_chambers/decor/brown_bed.nbt b/data/minecraft/structure/trial_chambers/decor/brown_bed.nbt index 667dfbd6..1d477f31 100644 --- a/data/minecraft/structure/trial_chambers/decor/brown_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/brown_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a58bc20380b2448b87bdf454b6fd72d2951336606b2a80996521cacc9acbb805 -size 326 +oid sha256:a7f50ec522b2e760c640c41412458cdaeaa2c18469a241fdd1a5aa3d7399cc1e +size 327 diff --git a/data/minecraft/structure/trial_chambers/decor/candle_1.nbt b/data/minecraft/structure/trial_chambers/decor/candle_1.nbt index de0cd329..4e738865 100644 --- a/data/minecraft/structure/trial_chambers/decor/candle_1.nbt +++ b/data/minecraft/structure/trial_chambers/decor/candle_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c594c6a03c7714c16439e9c4270b1295a558de7a1da1ed17d012982a6b348cbf -size 306 +oid sha256:07374a44772c6f378ed238ea9ef5f779b1019f245bd539c24813d29575e8d1b7 +size 307 diff --git a/data/minecraft/structure/trial_chambers/decor/candle_2.nbt b/data/minecraft/structure/trial_chambers/decor/candle_2.nbt index 479e3ce0..96b6a086 100644 --- a/data/minecraft/structure/trial_chambers/decor/candle_2.nbt +++ b/data/minecraft/structure/trial_chambers/decor/candle_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3794202dfe71e5506b12ed8fb7270e24596de1ec8152c80c67d63179206271f5 -size 306 +oid sha256:b463e889494d370408e097f54b23161db4a92d71581b1e7b99b60a34c12fea14 +size 307 diff --git a/data/minecraft/structure/trial_chambers/decor/candle_3.nbt b/data/minecraft/structure/trial_chambers/decor/candle_3.nbt index 2740e5b5..507f4d2a 100644 --- a/data/minecraft/structure/trial_chambers/decor/candle_3.nbt +++ b/data/minecraft/structure/trial_chambers/decor/candle_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f3c428088703bf29eedecbb230276d8286b42764ae094c91193c634dd4322d97 -size 306 +oid sha256:7346e76067b3a83dd0a72a653e3bc2e968847d79e1a13bd05e132dd64f520ee1 +size 307 diff --git a/data/minecraft/structure/trial_chambers/decor/candle_4.nbt b/data/minecraft/structure/trial_chambers/decor/candle_4.nbt index 72795ce8..f6103c07 100644 --- a/data/minecraft/structure/trial_chambers/decor/candle_4.nbt +++ b/data/minecraft/structure/trial_chambers/decor/candle_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:391fc7d99518c6ee5203051a8058655de3b845007c6e6e142766c61197ba6f56 -size 306 +oid sha256:57fbb95e970572caf4221a544a07a4456717863ce7da8e0d312de8f1c679e41b +size 307 diff --git a/data/minecraft/structure/trial_chambers/decor/cyan_bed.nbt b/data/minecraft/structure/trial_chambers/decor/cyan_bed.nbt index 60f7d251..7ff662f8 100644 --- a/data/minecraft/structure/trial_chambers/decor/cyan_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/cyan_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fe49d8aa80015e2028149bb5e8ddf0cf8fdf413a360e27ed2cc54a4520f161b3 -size 324 +oid sha256:8fa1f6bc3aa323c512b0da54d9a61252380d52e3dedbdb7121f4c69c41a53a58 +size 325 diff --git a/data/minecraft/structure/trial_chambers/decor/dead_bush_pot.nbt b/data/minecraft/structure/trial_chambers/decor/dead_bush_pot.nbt index 3022c6d5..dffe3182 100644 --- a/data/minecraft/structure/trial_chambers/decor/dead_bush_pot.nbt +++ b/data/minecraft/structure/trial_chambers/decor/dead_bush_pot.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:986b4ab6ccb2f9a63c3556cd52c8cd435ab0b348396056d10f1561a31f2e0e41 -size 289 +oid sha256:727a32ec43aad0050ef407dc667b38d36b15c2383510f690a31a4136106323f4 +size 290 diff --git a/data/minecraft/structure/trial_chambers/decor/disposal.nbt b/data/minecraft/structure/trial_chambers/decor/disposal.nbt index b2505ff9..97019c6d 100644 --- a/data/minecraft/structure/trial_chambers/decor/disposal.nbt +++ b/data/minecraft/structure/trial_chambers/decor/disposal.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7adf7f2bde4d6999b094f6c6c1a6436bda6bf48c31e4ba2d8e6ae28b0d71cb37 -size 515 +oid sha256:b98de5a96bdbbf821baf8027d805eceb6202648ae0e7a983a1c8c0ffee11fe21 +size 516 diff --git a/data/minecraft/structure/trial_chambers/decor/empty_pot.nbt b/data/minecraft/structure/trial_chambers/decor/empty_pot.nbt index 4facf0aa..27286601 100644 --- a/data/minecraft/structure/trial_chambers/decor/empty_pot.nbt +++ b/data/minecraft/structure/trial_chambers/decor/empty_pot.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cd1e48c125529bf5f35affa2c846370679914258e49411f9b52b6668fc71a234 -size 285 +oid sha256:ed85c26b5c9362f8c2d31f401c6dd0d189bb909c4fe2a80bdfac674031a32959 +size 286 diff --git a/data/minecraft/structure/trial_chambers/decor/flow_pot.nbt b/data/minecraft/structure/trial_chambers/decor/flow_pot.nbt index 8f9f2cfe..3bd42f19 100644 --- a/data/minecraft/structure/trial_chambers/decor/flow_pot.nbt +++ b/data/minecraft/structure/trial_chambers/decor/flow_pot.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:52c60be51f30576aabd71ac539d20622fceaf528dff58a3a73bd2142c948e3e4 -size 387 +oid sha256:4fd991fb2030a5bfbcb53f513ee5f30baf55e5dda03c3916193ff1b8f42b3ef0 +size 388 diff --git a/data/minecraft/structure/trial_chambers/decor/gray_bed.nbt b/data/minecraft/structure/trial_chambers/decor/gray_bed.nbt index 41c70cd5..29f8c800 100644 --- a/data/minecraft/structure/trial_chambers/decor/gray_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/gray_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:655d90ffee833f508e11f467cddfae92130a740d5a07197dfdde3db516d0364a -size 325 +oid sha256:e306a9c4ac8afc8629154fdade41dbd1fe5130be57f93dcefb45bfea92b71154 +size 326 diff --git a/data/minecraft/structure/trial_chambers/decor/green_bed.nbt b/data/minecraft/structure/trial_chambers/decor/green_bed.nbt index 58223893..4da2008f 100644 --- a/data/minecraft/structure/trial_chambers/decor/green_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/green_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dc8a1124f1f323273b7435c54d1e6f759833a77fe13acd86016ce5e2c85f2faf -size 325 +oid sha256:399d19bc9708558007f39fccd5ada67b474a3d3b261d68b5d173311ba8d63b87 +size 327 diff --git a/data/minecraft/structure/trial_chambers/decor/guster_pot.nbt b/data/minecraft/structure/trial_chambers/decor/guster_pot.nbt index 212fca50..8fbd8a3e 100644 --- a/data/minecraft/structure/trial_chambers/decor/guster_pot.nbt +++ b/data/minecraft/structure/trial_chambers/decor/guster_pot.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:db8ff1a02e34446a6865bfcdf942bd0348231665a9b43344b8e1b1220073c7f5 -size 384 +oid sha256:1c862aba5b064eafe69ec7941a498f10fc5156aa041d1d506ee78644fbdcb90d +size 385 diff --git a/data/minecraft/structure/trial_chambers/decor/light_blue_bed.nbt b/data/minecraft/structure/trial_chambers/decor/light_blue_bed.nbt index c553aacf..c37ea3bf 100644 --- a/data/minecraft/structure/trial_chambers/decor/light_blue_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/light_blue_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a4f203b3efee3af7a7b99cb3732ed37a9205f8760533aea99dfd43977a0ac7cc -size 330 +oid sha256:4f075c1f99d7e22088f04135b1eed263931fb91ceeb663be92efea6ed6cc89ae +size 331 diff --git a/data/minecraft/structure/trial_chambers/decor/light_gray_bed.nbt b/data/minecraft/structure/trial_chambers/decor/light_gray_bed.nbt index 4448a1f1..01f5e89c 100644 --- a/data/minecraft/structure/trial_chambers/decor/light_gray_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/light_gray_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0c84b6bf8ed962b6a593b06169d91a6d8798a6edb3921e84979fd8470eb2bb05 -size 330 +oid sha256:1fab3071b65cf5fc70adf7b67155ff2d6329b804665cf59f6e926c9bf05d7c66 +size 331 diff --git a/data/minecraft/structure/trial_chambers/decor/lime_bed.nbt b/data/minecraft/structure/trial_chambers/decor/lime_bed.nbt index a5e129d6..e98cd3b3 100644 --- a/data/minecraft/structure/trial_chambers/decor/lime_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/lime_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9eaa53fd9812f6dfe7fdaadae0546b4f3bf6f361324d17f9c608a4436d10092f -size 324 +oid sha256:52548e4f640696996af6f70586c0340420469e8f070788e5e764acfabfa938d4 +size 325 diff --git a/data/minecraft/structure/trial_chambers/decor/magenta_bed.nbt b/data/minecraft/structure/trial_chambers/decor/magenta_bed.nbt index a42447fa..5f534e80 100644 --- a/data/minecraft/structure/trial_chambers/decor/magenta_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/magenta_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f8a0981c75ef8c26b1ce5b5c5f5af113dde040ddcc055a28c4f837297d4fc0e -size 327 +oid sha256:b6497328c475559da381b562eb7de3b171b7dee1da4d1cd92b8e2befa092f1f4 +size 328 diff --git a/data/minecraft/structure/trial_chambers/decor/orange_bed.nbt b/data/minecraft/structure/trial_chambers/decor/orange_bed.nbt index 66be88cf..6c682b3e 100644 --- a/data/minecraft/structure/trial_chambers/decor/orange_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/orange_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:78a18bba7fc7a641ed2dbd19282ce90872f19b42c263ee685e2d14cf507333b3 -size 326 +oid sha256:01085ae3b260adaf35f39ca382270215c0ab5137a0822f26e7b75d25364f4944 +size 328 diff --git a/data/minecraft/structure/trial_chambers/decor/pink_bed.nbt b/data/minecraft/structure/trial_chambers/decor/pink_bed.nbt index c220c4d4..e50e03d6 100644 --- a/data/minecraft/structure/trial_chambers/decor/pink_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/pink_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2388183c05d70be445e2ae17f7b95fdc527fa359145e59406bba6fbb3cfbad3b -size 324 +oid sha256:e5927fe332aad2ad4d7de72ec138fbd1e88a577940dd3a52f616a477694f502a +size 325 diff --git a/data/minecraft/structure/trial_chambers/decor/purple_bed.nbt b/data/minecraft/structure/trial_chambers/decor/purple_bed.nbt index 5c6f1ae3..2fa37b87 100644 --- a/data/minecraft/structure/trial_chambers/decor/purple_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/purple_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0031b578cd801868af11d3755ba0fc8984c08f38673b55aea1a56a0977cf62d0 -size 326 +oid sha256:3a861e7ce40320ee4c96be39c90c6fbfedb03941ff5e8d1b3922db260dab89bc +size 328 diff --git a/data/minecraft/structure/trial_chambers/decor/red_bed.nbt b/data/minecraft/structure/trial_chambers/decor/red_bed.nbt index e5cc468f..d17e3547 100644 --- a/data/minecraft/structure/trial_chambers/decor/red_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/red_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:40861b8fed096079815f97f5e70639ff1e6ca2843f6427bb5c8c777e66d4692f -size 323 +oid sha256:e2ee9cf76e52fa0840b2c8b26722ff970729cf7550d333fd17cb7c5a674e1c5c +size 324 diff --git a/data/minecraft/structure/trial_chambers/decor/scrape_pot.nbt b/data/minecraft/structure/trial_chambers/decor/scrape_pot.nbt index e84a7eae..63b93c00 100644 --- a/data/minecraft/structure/trial_chambers/decor/scrape_pot.nbt +++ b/data/minecraft/structure/trial_chambers/decor/scrape_pot.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ad441dcee897e063be2146430d11d62e29393f1fd2cf395bd75b4de401c844c2 -size 383 +oid sha256:629fd0f6bc8641c6cbf24883815ff0c0433851cf99c23956d284d25813cbf879 +size 385 diff --git a/data/minecraft/structure/trial_chambers/decor/undecorated_pot.nbt b/data/minecraft/structure/trial_chambers/decor/undecorated_pot.nbt index 588ae6fd..c5cadee4 100644 --- a/data/minecraft/structure/trial_chambers/decor/undecorated_pot.nbt +++ b/data/minecraft/structure/trial_chambers/decor/undecorated_pot.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c36fb70123b0f283c8c8db07bbf2bc2eb48a9786f1325e034710183d867d77a6 -size 352 +oid sha256:d49035f907fcaa5f7fcce0f5ac2ad39f4cd758e0c5713a8a24d6a71d25ce34d0 +size 353 diff --git a/data/minecraft/structure/trial_chambers/decor/white_bed.nbt b/data/minecraft/structure/trial_chambers/decor/white_bed.nbt index abe9238b..8f6491d8 100644 --- a/data/minecraft/structure/trial_chambers/decor/white_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/white_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1ea4f5ef34487175a1f5dfbe21dbbbc93224877975c19e1674ee4931d6cf64db -size 326 +oid sha256:2f540d0049e23157273518319fa95480c8e7b97b16a3cf175a57b8f52184a835 +size 327 diff --git a/data/minecraft/structure/trial_chambers/decor/yellow_bed.nbt b/data/minecraft/structure/trial_chambers/decor/yellow_bed.nbt index 437ed3dd..7e31b8ec 100644 --- a/data/minecraft/structure/trial_chambers/decor/yellow_bed.nbt +++ b/data/minecraft/structure/trial_chambers/decor/yellow_bed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d487ae0e35d7938f829eec3080743c40de8e7d65aca8fda21b177096168969c2 -size 327 +oid sha256:5612c7733dd950a1cb5ecd48564e7a1f086cbed7063a02e36ec33365ef8c7416 +size 328 diff --git a/data/minecraft/structure/trial_chambers/dispensers/chamber.nbt b/data/minecraft/structure/trial_chambers/dispensers/chamber.nbt index f7d75c01..ac8bb46e 100644 --- a/data/minecraft/structure/trial_chambers/dispensers/chamber.nbt +++ b/data/minecraft/structure/trial_chambers/dispensers/chamber.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9ee0f0e06c260cd2d831bbb343421c5ea46f74e5a8ee741a6eb28f81de5ad11c -size 383 +oid sha256:a7fe5c08c143375307947d76cb54e10b4a32f45bfae95335f2dbf362e1cad134 +size 384 diff --git a/data/minecraft/structure/trial_chambers/dispensers/floor_dispenser.nbt b/data/minecraft/structure/trial_chambers/dispensers/floor_dispenser.nbt index a1ac23e4..3ab2e1b4 100644 --- a/data/minecraft/structure/trial_chambers/dispensers/floor_dispenser.nbt +++ b/data/minecraft/structure/trial_chambers/dispensers/floor_dispenser.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:06b9a9c98cda3b2f719b9677bff458ac6f06afa202c82ffedb2f335e6974e5d1 -size 357 +oid sha256:5d8f8480185b80dd7639d2cb6aa591999681786dd4effc501d0d786278ac961b +size 358 diff --git a/data/minecraft/structure/trial_chambers/dispensers/wall_dispenser.nbt b/data/minecraft/structure/trial_chambers/dispensers/wall_dispenser.nbt index 727266b5..f5615241 100644 --- a/data/minecraft/structure/trial_chambers/dispensers/wall_dispenser.nbt +++ b/data/minecraft/structure/trial_chambers/dispensers/wall_dispenser.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:05e22fe0af0ce2b25e3deae206a91bec085f9ad2163672b352fcfc523da6b84a -size 413 +oid sha256:8aea8a8811d8106b227c216a75ed4b4fbe58c9f38ac0ab842a560c0022bcab71 +size 414 diff --git a/data/minecraft/structure/trial_chambers/hallway/cache_1.nbt b/data/minecraft/structure/trial_chambers/hallway/cache_1.nbt index 3adee67b..09c61941 100644 --- a/data/minecraft/structure/trial_chambers/hallway/cache_1.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/cache_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6cbd3cab4a292df339e2afc2e752555b95aea9c1586b7442eb2dfd3a68efbfb8 -size 2708 +oid sha256:2c5e5fefb1cd837816339df8d8655d2e19dd12e52ee022a229a07baa56e1bdd9 +size 2709 diff --git a/data/minecraft/structure/trial_chambers/hallway/corner_staircase.nbt b/data/minecraft/structure/trial_chambers/hallway/corner_staircase.nbt index b1919fe5..35b978fa 100644 --- a/data/minecraft/structure/trial_chambers/hallway/corner_staircase.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/corner_staircase.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:06da249f420992d39983717de641a2b04ac6b5d1c6f01ba31bbf5ad8b3cf1ba0 -size 1434 +oid sha256:0463c77c17a36de8000a3920688599fc7a1383c811179d8c01ec5006b4c8adee +size 1435 diff --git a/data/minecraft/structure/trial_chambers/hallway/corner_staircase_down.nbt b/data/minecraft/structure/trial_chambers/hallway/corner_staircase_down.nbt index 5104a277..dd54275e 100644 --- a/data/minecraft/structure/trial_chambers/hallway/corner_staircase_down.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/corner_staircase_down.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4dea9f83c5c3bdd0896eb0a185931f6086c469beb37d00b707166e4c954e47f1 -size 1437 +oid sha256:26fae3910b7c1452061cfc6cacaacca159082404211532443e3fe62ecb772067 +size 1438 diff --git a/data/minecraft/structure/trial_chambers/hallway/corridor_connector_1.nbt b/data/minecraft/structure/trial_chambers/hallway/corridor_connector_1.nbt index 286e8d14..0d204827 100644 --- a/data/minecraft/structure/trial_chambers/hallway/corridor_connector_1.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/corridor_connector_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0e602bddf92a970bf71b38210d3dc86b85060cfd52a7558894ee35d35ee2d92a -size 688 +oid sha256:889ebdb2bffa12bbd756fe4af5f766fe06d499afddf4fbcd6291cf8f1d5a59bd +size 689 diff --git a/data/minecraft/structure/trial_chambers/hallway/encounter_1.nbt b/data/minecraft/structure/trial_chambers/hallway/encounter_1.nbt index 2348ede2..6e6271d3 100644 --- a/data/minecraft/structure/trial_chambers/hallway/encounter_1.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/encounter_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:092db73b5978422ed758f2e11b74f1a959a0ad910102f336c40aa63b81bec119 -size 7350 +oid sha256:3d84847152ab284b483acc6d968488a75b94c4cb08203882f2954dad46c0ebe8 +size 7351 diff --git a/data/minecraft/structure/trial_chambers/hallway/encounter_2.nbt b/data/minecraft/structure/trial_chambers/hallway/encounter_2.nbt index f37a946a..ed7cb57b 100644 --- a/data/minecraft/structure/trial_chambers/hallway/encounter_2.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/encounter_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2f26dad19d24419a84f468d47615d344335d53b6fdfbfadd4421061b2f5c05e1 -size 6704 +oid sha256:8dfd1b616e935ab527e4c12e6685af7d39df1cde1188f5871853e0ab543ffae9 +size 6705 diff --git a/data/minecraft/structure/trial_chambers/hallway/encounter_3.nbt b/data/minecraft/structure/trial_chambers/hallway/encounter_3.nbt index a01c04ce..313924c4 100644 --- a/data/minecraft/structure/trial_chambers/hallway/encounter_3.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/encounter_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f0f90490297c69b66201f005741a5c9597064000ab981351a3db741f55462c9 -size 5627 +oid sha256:8b451df393b096b4c4c1a81c156c3ed3b215e19171b751fa80d0b23d76cc094a +size 5628 diff --git a/data/minecraft/structure/trial_chambers/hallway/encounter_4.nbt b/data/minecraft/structure/trial_chambers/hallway/encounter_4.nbt index e946e179..72612ed1 100644 --- a/data/minecraft/structure/trial_chambers/hallway/encounter_4.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/encounter_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:37f4153f3548cc324aabeb5711baa1ad0057a80c945de0452768f25d7eac96c0 -size 17905 +oid sha256:46793a7be5f957a96f1060295d9d148b62b58ad15d47faaabf95099d582043bc +size 17906 diff --git a/data/minecraft/structure/trial_chambers/hallway/encounter_5.nbt b/data/minecraft/structure/trial_chambers/hallway/encounter_5.nbt index 2d8ac7ae..c58a7f54 100644 --- a/data/minecraft/structure/trial_chambers/hallway/encounter_5.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/encounter_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1689f1cb5e023f41f6d3b62d1e43aca9a8179253bcbb06af4210d55589892f46 -size 14322 +oid sha256:d3bc5b33d2467a1f31bcfd80288e717fd57e1312fb68b5df142d9ac37d83e78e +size 14324 diff --git a/data/minecraft/structure/trial_chambers/hallway/left_corner.nbt b/data/minecraft/structure/trial_chambers/hallway/left_corner.nbt index b29363ac..9495e057 100644 --- a/data/minecraft/structure/trial_chambers/hallway/left_corner.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/left_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ce8aca30cf58366ad23ae4ab59164de46ab5a9427c0c30032c5fa331864913e7 -size 937 +oid sha256:d03de289c207172325ad68c8cb3204a11304d09352ae89ca4b5193be99b522bb +size 938 diff --git a/data/minecraft/structure/trial_chambers/hallway/long_straight_staircase.nbt b/data/minecraft/structure/trial_chambers/hallway/long_straight_staircase.nbt index 6ddc194f..033cedf9 100644 --- a/data/minecraft/structure/trial_chambers/hallway/long_straight_staircase.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/long_straight_staircase.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:64b5406927bee843ec0d460d08c0e8fbd2284fcd3ac46cbb8bf3699aa0ba2fbb -size 2592 +oid sha256:96c8e87a7c863ef5870b47df2401374121cd505e9c7157e2aae0b0fad1dc82f2 +size 2593 diff --git a/data/minecraft/structure/trial_chambers/hallway/long_straight_staircase_down.nbt b/data/minecraft/structure/trial_chambers/hallway/long_straight_staircase_down.nbt index fc6149c0..452c5018 100644 --- a/data/minecraft/structure/trial_chambers/hallway/long_straight_staircase_down.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/long_straight_staircase_down.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b916919b7d3806022aef0d6709ff4ad25dd1e3b6cfb732aedeb9a92ae6ed5e4b -size 2593 +oid sha256:7a9808130669bc85292559445fdce9bdc63a120de3809d562092887cdc83f3f9 +size 2594 diff --git a/data/minecraft/structure/trial_chambers/hallway/lower_hallway_connector.nbt b/data/minecraft/structure/trial_chambers/hallway/lower_hallway_connector.nbt index 8ccae0c1..4616de2a 100644 --- a/data/minecraft/structure/trial_chambers/hallway/lower_hallway_connector.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/lower_hallway_connector.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bcf1526688878d9745ebd09877254647c2d13b718bb2e8118bd531f31414dce0 -size 3185 +oid sha256:01f5d7921e5c9371196b60d2ee15672f271ef15a1b0cb36ec3578430766a29f6 +size 3186 diff --git a/data/minecraft/structure/trial_chambers/hallway/right_corner.nbt b/data/minecraft/structure/trial_chambers/hallway/right_corner.nbt index e45fd15f..3e5773a9 100644 --- a/data/minecraft/structure/trial_chambers/hallway/right_corner.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/right_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:288bf37213abfc19bbba6517b128693b00d35b7f79780e2c5b58540ad032c70b -size 944 +oid sha256:fa573c01bf41d204a5c271d4396e7aee2f7fdb5eff754c0b8ef59bde4408bd93 +size 945 diff --git a/data/minecraft/structure/trial_chambers/hallway/rubble.nbt b/data/minecraft/structure/trial_chambers/hallway/rubble.nbt index a54757cd..d146a365 100644 --- a/data/minecraft/structure/trial_chambers/hallway/rubble.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/rubble.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:90b189d53bf7af460df48cbe3e198134ae2bd4c3e3b77ff3f18c6c854b278c51 -size 935 +oid sha256:f27f0c27fa5bc7194ce9033ede9e0cbb81918b01e21df3f12880184200dc31ab +size 936 diff --git a/data/minecraft/structure/trial_chambers/hallway/rubble_chamber.nbt b/data/minecraft/structure/trial_chambers/hallway/rubble_chamber.nbt index 74cc80fb..02f135ab 100644 --- a/data/minecraft/structure/trial_chambers/hallway/rubble_chamber.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/rubble_chamber.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fa8c2b266217a5e0be084aa475572964703cba7e54dcbd30ccfdfc82136025dd -size 925 +oid sha256:fcd92d89c618123d53c0802a22170f4cb2ff76749bfe3d1971e4005214d82e75 +size 926 diff --git a/data/minecraft/structure/trial_chambers/hallway/rubble_chamber_thin.nbt b/data/minecraft/structure/trial_chambers/hallway/rubble_chamber_thin.nbt index 5f29615e..ad7a0c48 100644 --- a/data/minecraft/structure/trial_chambers/hallway/rubble_chamber_thin.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/rubble_chamber_thin.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:24459ff96a1f0f2f915d7e95760cfc429fb09f97cc605d489bb3f0fe377c434b -size 470 +oid sha256:73bc3cf6aee34c77905ccddb2ea2450e52fef65a9fd9b650ae7ff698e6221f83 +size 471 diff --git a/data/minecraft/structure/trial_chambers/hallway/rubble_thin.nbt b/data/minecraft/structure/trial_chambers/hallway/rubble_thin.nbt index 5f29615e..ad7a0c48 100644 --- a/data/minecraft/structure/trial_chambers/hallway/rubble_thin.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/rubble_thin.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:24459ff96a1f0f2f915d7e95760cfc429fb09f97cc605d489bb3f0fe377c434b -size 470 +oid sha256:73bc3cf6aee34c77905ccddb2ea2450e52fef65a9fd9b650ae7ff698e6221f83 +size 471 diff --git a/data/minecraft/structure/trial_chambers/hallway/straight.nbt b/data/minecraft/structure/trial_chambers/hallway/straight.nbt index 9174ef01..9145ff2e 100644 --- a/data/minecraft/structure/trial_chambers/hallway/straight.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/straight.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:948c79aa92ced975e6cf23438330f0a1805ca2b948790c39573ac1f6332eb00b -size 931 +oid sha256:8c2fff6a2eb4a192909607b9362b23b8f5b352f36be1aa9a78718f3d69973aad +size 932 diff --git a/data/minecraft/structure/trial_chambers/hallway/straight_staircase.nbt b/data/minecraft/structure/trial_chambers/hallway/straight_staircase.nbt index 813eb0b5..0b6905bd 100644 --- a/data/minecraft/structure/trial_chambers/hallway/straight_staircase.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/straight_staircase.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d2b9952d0f8615da6a649ff2d49c66ade889729e38df4638c11cad15f43b6226 +oid sha256:e5f3e450981318a95a71a0793486d95bbd557258a09d99547bc04621193a3c66 size 1177 diff --git a/data/minecraft/structure/trial_chambers/hallway/straight_staircase_down.nbt b/data/minecraft/structure/trial_chambers/hallway/straight_staircase_down.nbt index f0b190c0..dff4b762 100644 --- a/data/minecraft/structure/trial_chambers/hallway/straight_staircase_down.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/straight_staircase_down.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d31bc7f63dd2a285ef87af41cebe3a4fc255f046a3844ea430db3474864094f5 -size 1176 +oid sha256:71075ba1152e52a15fda8f210255a139b658ffec1757c753c40f81c146848a77 +size 1177 diff --git a/data/minecraft/structure/trial_chambers/hallway/trapped_staircase.nbt b/data/minecraft/structure/trial_chambers/hallway/trapped_staircase.nbt index 480bfab1..ba565f5c 100644 --- a/data/minecraft/structure/trial_chambers/hallway/trapped_staircase.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/trapped_staircase.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7708efb7b32cc7b90c0040513461904d3cba0b521f788c11c0db8208f2edc087 -size 3612 +oid sha256:70a99b0412d6db9564b2403ff09da870427fc21109186a52a9cc7bd365338918 +size 3613 diff --git a/data/minecraft/structure/trial_chambers/hallway/upper_hallway_connector.nbt b/data/minecraft/structure/trial_chambers/hallway/upper_hallway_connector.nbt index 83be7ec3..7031dea9 100644 --- a/data/minecraft/structure/trial_chambers/hallway/upper_hallway_connector.nbt +++ b/data/minecraft/structure/trial_chambers/hallway/upper_hallway_connector.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f48972763bce409fcf8cdafb951a703c865ca4e1a2cd5706c118e473a6ef64dd -size 2699 +oid sha256:3a1f8160f316ae069909ec604084d6081e48cca07049effff2ab53da01135378 +size 2700 diff --git a/data/minecraft/structure/trial_chambers/intersection/intersection_1.nbt b/data/minecraft/structure/trial_chambers/intersection/intersection_1.nbt index fc3c4c68..e9130dbe 100644 --- a/data/minecraft/structure/trial_chambers/intersection/intersection_1.nbt +++ b/data/minecraft/structure/trial_chambers/intersection/intersection_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7b0d6a898944994e3d75bed2a4355b3e22fdad20b1bdaf83e79224f3ba2457cf -size 29421 +oid sha256:331230d9f8dc8856bcf228b4e5f485a53e52350a81fbe45eb6bd4b545c7f6c23 +size 29422 diff --git a/data/minecraft/structure/trial_chambers/intersection/intersection_2.nbt b/data/minecraft/structure/trial_chambers/intersection/intersection_2.nbt index 469a4908..2b7d6ed3 100644 --- a/data/minecraft/structure/trial_chambers/intersection/intersection_2.nbt +++ b/data/minecraft/structure/trial_chambers/intersection/intersection_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:36956c5b024c1e5dc429b4ffefbfc050cbe6590cccaac6524f2433963a4af4ab -size 30343 +oid sha256:77a6780276406f49d87649d63e2d33240db1f8f629b7948a9d55c790e450122e +size 30344 diff --git a/data/minecraft/structure/trial_chambers/intersection/intersection_3.nbt b/data/minecraft/structure/trial_chambers/intersection/intersection_3.nbt index b24cd2d2..704ce122 100644 --- a/data/minecraft/structure/trial_chambers/intersection/intersection_3.nbt +++ b/data/minecraft/structure/trial_chambers/intersection/intersection_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c3ee20ca11d4aa5942d81441dfdc5372111bfddb043783323e71fa10c54c1d18 -size 49355 +oid sha256:61ef1d936bf105b25990a6499bebeb7509ae95a19b2b9b5ec508f394ea6835ae +size 49356 diff --git a/data/minecraft/structure/trial_chambers/reward/ominous_vault.nbt b/data/minecraft/structure/trial_chambers/reward/ominous_vault.nbt index 77f891f1..3d78a2e5 100644 --- a/data/minecraft/structure/trial_chambers/reward/ominous_vault.nbt +++ b/data/minecraft/structure/trial_chambers/reward/ominous_vault.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aa6b96ec78a2a751f6f096128a9f97afb67533f86f4a8503194c34dad17e5b30 -size 689 +oid sha256:aec1b02c3493b82c828285614bc420cf59bfbc9885dbeed1b9f95611b9a5b65b +size 690 diff --git a/data/minecraft/structure/trial_chambers/reward/vault.nbt b/data/minecraft/structure/trial_chambers/reward/vault.nbt index 727570b2..7f0ad2a6 100644 --- a/data/minecraft/structure/trial_chambers/reward/vault.nbt +++ b/data/minecraft/structure/trial_chambers/reward/vault.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c216de9583eb9ad57b8dc60e6b1c98c56cb141256ac5c4e37f585c77f2f60c26 -size 503 +oid sha256:2a8af677dc71c18f46169fbb5fd42ab3b0088344c408797cd7ae46c00a49a0cf +size 504 diff --git a/data/minecraft/structure/trial_chambers/spawner/breeze/breeze.nbt b/data/minecraft/structure/trial_chambers/spawner/breeze/breeze.nbt index a5a5c139..711f984e 100644 --- a/data/minecraft/structure/trial_chambers/spawner/breeze/breeze.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/breeze/breeze.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:32108017cffb2977b6dc4c3cd10eec282560dd8dd008491114e16b5f05d96aa2 -size 468 +oid sha256:8ef0d88bdff17ba95df86a128bd672d242569352b9b8ef8d77921f92a1c73b96 +size 469 diff --git a/data/minecraft/structure/trial_chambers/spawner/connectors/breeze.nbt b/data/minecraft/structure/trial_chambers/spawner/connectors/breeze.nbt index b4d66e30..e0b3592d 100644 --- a/data/minecraft/structure/trial_chambers/spawner/connectors/breeze.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/connectors/breeze.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:58c3a986892b7166876027d2b3d7e2777a445bb87883c1a74a53cfc24dfd3e85 -size 327 +oid sha256:d0159d9e47048eebdf5790eeb43881aa2964435ab60330dcdb01039c5fd812a8 +size 328 diff --git a/data/minecraft/structure/trial_chambers/spawner/connectors/melee.nbt b/data/minecraft/structure/trial_chambers/spawner/connectors/melee.nbt index 0da8c797..7d500dd3 100644 --- a/data/minecraft/structure/trial_chambers/spawner/connectors/melee.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/connectors/melee.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:81c832f2561816720c1060eab5f795469ad3672d03a87b16a2d96b4bafe1b81f -size 326 +oid sha256:f6c3d7f10943f0926cc06dd35365cc3da585776b4acd99fe2ad0e9ea28ad98c2 +size 327 diff --git a/data/minecraft/structure/trial_chambers/spawner/connectors/ranged.nbt b/data/minecraft/structure/trial_chambers/spawner/connectors/ranged.nbt index 35723b4d..d3fef7d7 100644 --- a/data/minecraft/structure/trial_chambers/spawner/connectors/ranged.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/connectors/ranged.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1546e349b6cb6dcadcdb0fbf84e14f18698f0d1c210bcf2adb7aa579c91edfdc -size 326 +oid sha256:7489c3cee5e67f912bc0a8f0222b3cc11904f49df53d1b040f7e3397fc13be07 +size 327 diff --git a/data/minecraft/structure/trial_chambers/spawner/connectors/slow_ranged.nbt b/data/minecraft/structure/trial_chambers/spawner/connectors/slow_ranged.nbt index d2751114..553dcd05 100644 --- a/data/minecraft/structure/trial_chambers/spawner/connectors/slow_ranged.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/connectors/slow_ranged.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f48b267af73697a4940f2b053963dc81bbf95c6207104bb1538ba307e79639b -size 330 +oid sha256:37d49db6ea43ac8c0f26a0e12f2479d21525aee26a32d8af35070a2d088559dc +size 331 diff --git a/data/minecraft/structure/trial_chambers/spawner/connectors/small_melee.nbt b/data/minecraft/structure/trial_chambers/spawner/connectors/small_melee.nbt index 3bec6c4f..2f6e4ae8 100644 --- a/data/minecraft/structure/trial_chambers/spawner/connectors/small_melee.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/connectors/small_melee.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:54be869cec74a83613de90bdf83dee67553b631ca0a696d6f23c008c7931af27 -size 329 +oid sha256:2ae39dd6e7d208a8ded4d0f3955be446d8d2febc2e832c259a44267ea6050a1a +size 330 diff --git a/data/minecraft/structure/trial_chambers/spawner/melee/husk.nbt b/data/minecraft/structure/trial_chambers/spawner/melee/husk.nbt index d707e461..036e474a 100644 --- a/data/minecraft/structure/trial_chambers/spawner/melee/husk.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/melee/husk.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4767fb80606522e5a9816d53bef813a2f9b12b2467539fad022c75aec1382460 -size 472 +oid sha256:545e9b7ba28612f8983f62ce67566e5c5d77807f2f21ce3dc08736e7544e0af1 +size 473 diff --git a/data/minecraft/structure/trial_chambers/spawner/melee/spider.nbt b/data/minecraft/structure/trial_chambers/spawner/melee/spider.nbt index 3a3b9df7..163c9020 100644 --- a/data/minecraft/structure/trial_chambers/spawner/melee/spider.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/melee/spider.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d34fad0516659eb3934124ceab10870f99dbf3cf37e33a948724546c47190051 -size 479 +oid sha256:fbd8622ac50bce4859fd62f12ecb952dd76246405d379fb45aa3e95fcf655162 +size 481 diff --git a/data/minecraft/structure/trial_chambers/spawner/melee/zombie.nbt b/data/minecraft/structure/trial_chambers/spawner/melee/zombie.nbt index a0401a0a..0b2af2d7 100644 --- a/data/minecraft/structure/trial_chambers/spawner/melee/zombie.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/melee/zombie.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:73142001e3f97345231e68e466070958495e12963ed48bac9b298ea558e184b1 -size 478 +oid sha256:0f9c7fa6e6d2eb5764e09b6e0c8e0a24e611eaf6663e7439ca8f71d549c61cef +size 480 diff --git a/data/minecraft/structure/trial_chambers/spawner/ranged/poison_skeleton.nbt b/data/minecraft/structure/trial_chambers/spawner/ranged/poison_skeleton.nbt index 49b38aa7..91d51f84 100644 --- a/data/minecraft/structure/trial_chambers/spawner/ranged/poison_skeleton.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/ranged/poison_skeleton.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:70c2d23128c41f2c697afd732e98ebddad5030ef2821bbfb2b05a1ad3990c7d3 -size 523 +oid sha256:03b7f7060e37ca889183f1297f9b1de9bb3197d91c185026b4cdff3becda31b9 +size 524 diff --git a/data/minecraft/structure/trial_chambers/spawner/ranged/skeleton.nbt b/data/minecraft/structure/trial_chambers/spawner/ranged/skeleton.nbt index 3ab54608..a9e07936 100644 --- a/data/minecraft/structure/trial_chambers/spawner/ranged/skeleton.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/ranged/skeleton.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ffe8c2a4369833e2a1d50573009e7fe5d93b2090d840a6db6727a4d9fb437613 -size 478 +oid sha256:e3db58700b238f60f931762b37f5671b16a87559541c33a89cf976d3a3b19d8d +size 480 diff --git a/data/minecraft/structure/trial_chambers/spawner/ranged/stray.nbt b/data/minecraft/structure/trial_chambers/spawner/ranged/stray.nbt index 0f60683c..dae6c72d 100644 --- a/data/minecraft/structure/trial_chambers/spawner/ranged/stray.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/ranged/stray.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:352a35586290b7d767c0b5f6c1bbdcf37905231807cace2fecdd1cd7d6267063 -size 475 +oid sha256:e2d0cf706fc8efc4ee52fe1974e29c917aa6504dffd1911038886a5ba7c52d4f +size 476 diff --git a/data/minecraft/structure/trial_chambers/spawner/slow_ranged/poison_skeleton.nbt b/data/minecraft/structure/trial_chambers/spawner/slow_ranged/poison_skeleton.nbt index 52d26dd9..bc4a4f18 100644 --- a/data/minecraft/structure/trial_chambers/spawner/slow_ranged/poison_skeleton.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/slow_ranged/poison_skeleton.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a4b445e639f951dfe26bbd9556e6404bc5141c1771e42a2ed8552d89c4d7ad72 -size 526 +oid sha256:5078172bf1324faab157939d1c2e9cc0246471896e880ed379b1f0b5f889f44a +size 527 diff --git a/data/minecraft/structure/trial_chambers/spawner/slow_ranged/skeleton.nbt b/data/minecraft/structure/trial_chambers/spawner/slow_ranged/skeleton.nbt index 2f1562b5..8b569c9e 100644 --- a/data/minecraft/structure/trial_chambers/spawner/slow_ranged/skeleton.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/slow_ranged/skeleton.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:697a638586e1339ff0d4adb3e9ad3e7d9e4c49db62adbfa259ca7a74b8f7e72b -size 484 +oid sha256:10eeb4919f93d2ca376f6205e67e7827da6d6787cae904a0c14bc72edbca4bb3 +size 485 diff --git a/data/minecraft/structure/trial_chambers/spawner/slow_ranged/stray.nbt b/data/minecraft/structure/trial_chambers/spawner/slow_ranged/stray.nbt index 716b609d..8ecf1363 100644 --- a/data/minecraft/structure/trial_chambers/spawner/slow_ranged/stray.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/slow_ranged/stray.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:eb60d67171cdbf7df854c30d6644133deccc18a393bc80279a256155ec51d06f -size 477 +oid sha256:33a75cd2a3a5a3d10d67b72258059a32365a88ca2888370c3f11259267d54cc5 +size 479 diff --git a/data/minecraft/structure/trial_chambers/spawner/small_melee/baby_zombie.nbt b/data/minecraft/structure/trial_chambers/spawner/small_melee/baby_zombie.nbt index 5bf9930e..ca171c75 100644 --- a/data/minecraft/structure/trial_chambers/spawner/small_melee/baby_zombie.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/small_melee/baby_zombie.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:03fd94ccc43a30224159460113de39d8c62704939a9b359f189097b7e14173ad -size 498 +oid sha256:bd4f9b4f9225d9365619810dab80e3ca6127b5cc3d8803f0585584fe557dd953 +size 499 diff --git a/data/minecraft/structure/trial_chambers/spawner/small_melee/cave_spider.nbt b/data/minecraft/structure/trial_chambers/spawner/small_melee/cave_spider.nbt index 0389ede9..7c4f95c4 100644 --- a/data/minecraft/structure/trial_chambers/spawner/small_melee/cave_spider.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/small_melee/cave_spider.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a516235a5b22644521b32aee4c6dc78ea46c961a27c44154f3b20917e4b0cdda -size 521 +oid sha256:9fa8ebc7055d6157ccd50af0c0b95f6ebe16ddc44ea57d36de405ef21fdadeab +size 523 diff --git a/data/minecraft/structure/trial_chambers/spawner/small_melee/silverfish.nbt b/data/minecraft/structure/trial_chambers/spawner/small_melee/silverfish.nbt index 5ced2ba5..8b33cbaa 100644 --- a/data/minecraft/structure/trial_chambers/spawner/small_melee/silverfish.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/small_melee/silverfish.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:94f433772904df5868e7b18778f56bf80c175e682659bdd2af88721a18cfc258 -size 482 +oid sha256:1f669423f1fc03dab12cc9852eb63cdf32c927a53144ae268fec6aef9fbb9ce6 +size 483 diff --git a/data/minecraft/structure/trial_chambers/spawner/small_melee/slime.nbt b/data/minecraft/structure/trial_chambers/spawner/small_melee/slime.nbt index 5070fc33..19797a2d 100644 --- a/data/minecraft/structure/trial_chambers/spawner/small_melee/slime.nbt +++ b/data/minecraft/structure/trial_chambers/spawner/small_melee/slime.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cebd3343cd2620b5078bb8a87d21931ecedef4c3c70481df78a4e27bf669fa18 -size 472 +oid sha256:4d20383d795b2ee171aa1aeac7cff5a8f8c373b904bd73b71e68e8b25a85ccd2 +size 473 diff --git a/data/minecraft/structure/underwater_ruin/big_brick_1.nbt b/data/minecraft/structure/underwater_ruin/big_brick_1.nbt index 7e9f6f5e..defa0269 100644 --- a/data/minecraft/structure/underwater_ruin/big_brick_1.nbt +++ b/data/minecraft/structure/underwater_ruin/big_brick_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9a7154036ef7b99b530bce4ec7249a91b45a4ad0311ed0355826bad7184fda75 -size 11113 +oid sha256:b32243eb7701df0ea33090cc07662bb60460a827a5e9e470b41e0b1ab9073d18 +size 11114 diff --git a/data/minecraft/structure/underwater_ruin/big_brick_2.nbt b/data/minecraft/structure/underwater_ruin/big_brick_2.nbt index faad24b0..e1bd44d7 100644 --- a/data/minecraft/structure/underwater_ruin/big_brick_2.nbt +++ b/data/minecraft/structure/underwater_ruin/big_brick_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:45135869425cdbb7f97add6423a8d30ea87f1f7f27537ebe319835a99b8f1f3c -size 11460 +oid sha256:8931c09bffe1862eacc55b4b18cc20dcaad7cd318b66b86418af838d5325b8f4 +size 11462 diff --git a/data/minecraft/structure/underwater_ruin/big_brick_3.nbt b/data/minecraft/structure/underwater_ruin/big_brick_3.nbt index 1ce4188f..1d75b045 100644 --- a/data/minecraft/structure/underwater_ruin/big_brick_3.nbt +++ b/data/minecraft/structure/underwater_ruin/big_brick_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ba4171a1ebfb0d8001f1d0a957cc7ebfca84af4dd32bf172476f6293c53c7886 -size 11631 +oid sha256:d4a497df74ebe3fd9ee99b1523bcd40868d9747ab2982e83098c31a4492182a4 +size 11632 diff --git a/data/minecraft/structure/underwater_ruin/big_brick_8.nbt b/data/minecraft/structure/underwater_ruin/big_brick_8.nbt index 38ead987..83d3b3f8 100644 --- a/data/minecraft/structure/underwater_ruin/big_brick_8.nbt +++ b/data/minecraft/structure/underwater_ruin/big_brick_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:056ae12f18680e14dda88d86e7771b610323cf8a79eb127746f10ffdee385b4c -size 11013 +oid sha256:764c5569377fe8ed8274e9153eb1cf5226cf7082e1b2e35dfee53515cb1d58f2 +size 11015 diff --git a/data/minecraft/structure/underwater_ruin/big_cracked_1.nbt b/data/minecraft/structure/underwater_ruin/big_cracked_1.nbt index 7ab84137..7c827bdb 100644 --- a/data/minecraft/structure/underwater_ruin/big_cracked_1.nbt +++ b/data/minecraft/structure/underwater_ruin/big_cracked_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1b63f60cd4fd1fc3f1879e261eb86f786173951807ea5729211effe3b027272e -size 11096 +oid sha256:135f10a8bea9c16b0923b527ea4030cb80e3afc7eaf4f35617e63c9faa64d576 +size 11097 diff --git a/data/minecraft/structure/underwater_ruin/big_cracked_2.nbt b/data/minecraft/structure/underwater_ruin/big_cracked_2.nbt index d4217111..7e7fc90f 100644 --- a/data/minecraft/structure/underwater_ruin/big_cracked_2.nbt +++ b/data/minecraft/structure/underwater_ruin/big_cracked_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6d050987a5bed33c8db073cb7fe4acba0322899fd30e84c7ea901fcb0c4e9977 -size 11504 +oid sha256:bf855043e1222e3b926e33c3afd514e4983a6192670b562cd4cc3583d28f035e +size 11505 diff --git a/data/minecraft/structure/underwater_ruin/big_cracked_3.nbt b/data/minecraft/structure/underwater_ruin/big_cracked_3.nbt index d0a4f911..04f70ce9 100644 --- a/data/minecraft/structure/underwater_ruin/big_cracked_3.nbt +++ b/data/minecraft/structure/underwater_ruin/big_cracked_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:667fbd89d7ef21dd70eea17e76cdcbbc7bd00466ffbde21088c08d8072dd35c5 -size 11620 +oid sha256:ad6a9abc232164e62afd785a039c0bc9dff831d2ee4581f8005ff48659c95d27 +size 11622 diff --git a/data/minecraft/structure/underwater_ruin/big_cracked_8.nbt b/data/minecraft/structure/underwater_ruin/big_cracked_8.nbt index 0760f90d..dcc1fdc0 100644 --- a/data/minecraft/structure/underwater_ruin/big_cracked_8.nbt +++ b/data/minecraft/structure/underwater_ruin/big_cracked_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aca537a75dddf6e28e63bff869978cde682fb59d03f1b945b0a7d5f3e1c02d28 -size 11022 +oid sha256:0bc4922929b67eab30a4149cb028e80eb449a54a8ed0f4b6a4a63168d7dd1a9b +size 11024 diff --git a/data/minecraft/structure/underwater_ruin/big_mossy_1.nbt b/data/minecraft/structure/underwater_ruin/big_mossy_1.nbt index ccff61c7..6fec7403 100644 --- a/data/minecraft/structure/underwater_ruin/big_mossy_1.nbt +++ b/data/minecraft/structure/underwater_ruin/big_mossy_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:71f0e4a80a10d46a944ed61dd1a41906c64b1bdc01d9d215887182645f8b5f88 -size 11095 +oid sha256:5f57e8581610b040a6356b848832853b4ce9a5aa307dddaa8df2c9a80c9dc653 +size 11096 diff --git a/data/minecraft/structure/underwater_ruin/big_mossy_2.nbt b/data/minecraft/structure/underwater_ruin/big_mossy_2.nbt index 5eea8db6..8af0af16 100644 --- a/data/minecraft/structure/underwater_ruin/big_mossy_2.nbt +++ b/data/minecraft/structure/underwater_ruin/big_mossy_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1b7be51064f8741ea810a9de85a33140bbd029feb04d71c5510585a3dfd221e7 -size 11503 +oid sha256:06e0a1f60650216d05dc818fc1e6b987fb322f038a54d6d2d49e8fb246b2377a +size 11504 diff --git a/data/minecraft/structure/underwater_ruin/big_mossy_3.nbt b/data/minecraft/structure/underwater_ruin/big_mossy_3.nbt index eba08f9d..68d29fe5 100644 --- a/data/minecraft/structure/underwater_ruin/big_mossy_3.nbt +++ b/data/minecraft/structure/underwater_ruin/big_mossy_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a9db1f65e0fa3d8fee8499830c1d989d70f9120ff56ed34edcf9c71d366c3b5d -size 11631 +oid sha256:fa6cd4a982f298d17f2564f016a3a7ae454cfa28ef815f8f799f95ef2de1d643 +size 11632 diff --git a/data/minecraft/structure/underwater_ruin/big_mossy_8.nbt b/data/minecraft/structure/underwater_ruin/big_mossy_8.nbt index a56feb62..78f4860a 100644 --- a/data/minecraft/structure/underwater_ruin/big_mossy_8.nbt +++ b/data/minecraft/structure/underwater_ruin/big_mossy_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4591c973aa873fd860ec1ff9fefc3342e2b293805e45748d0f337a8f84bb6fc3 -size 11044 +oid sha256:d2a4f54087a48c5bebfa76461ce67520d1d198d5613651c394a42824484d2e37 +size 11045 diff --git a/data/minecraft/structure/underwater_ruin/big_warm_4.nbt b/data/minecraft/structure/underwater_ruin/big_warm_4.nbt index c95d2bd5..76ec1184 100644 --- a/data/minecraft/structure/underwater_ruin/big_warm_4.nbt +++ b/data/minecraft/structure/underwater_ruin/big_warm_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fa35c4be74f8864b421661f9bec12979e31aa45d617f0a8f14d1ce11303b7341 -size 11265 +oid sha256:2b4ee1669b409e0c6e1403b9c75807301814bf5198a86ef99360fdf6e445d735 +size 11266 diff --git a/data/minecraft/structure/underwater_ruin/big_warm_5.nbt b/data/minecraft/structure/underwater_ruin/big_warm_5.nbt index 2b7df89f..ace75129 100644 --- a/data/minecraft/structure/underwater_ruin/big_warm_5.nbt +++ b/data/minecraft/structure/underwater_ruin/big_warm_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e44d8c9176f3082f577d3dd11d0f7f6679b9562db293ee6e786c980a82d21bc3 -size 11032 +oid sha256:7df3d38127d1931e9011875247ec239f8325ec1a5ed4274d5d023e84dc26cc16 +size 11034 diff --git a/data/minecraft/structure/underwater_ruin/big_warm_6.nbt b/data/minecraft/structure/underwater_ruin/big_warm_6.nbt index a83dffb4..c8a7af47 100644 --- a/data/minecraft/structure/underwater_ruin/big_warm_6.nbt +++ b/data/minecraft/structure/underwater_ruin/big_warm_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:28385df5a354617fab36411bbc8b7d194aeca212935f0895cd048ba8e8ea0a19 -size 11106 +oid sha256:e217c6184a5a889654b5c8b187287385543b86c7dab7a9cea6819c48e6414bcb +size 11108 diff --git a/data/minecraft/structure/underwater_ruin/big_warm_7.nbt b/data/minecraft/structure/underwater_ruin/big_warm_7.nbt index 19eb5cc1..6ec28cf2 100644 --- a/data/minecraft/structure/underwater_ruin/big_warm_7.nbt +++ b/data/minecraft/structure/underwater_ruin/big_warm_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0495693fa199810939e7324ccbf481ec16d1b6c475f72529e23dd6d4ef197826 -size 11139 +oid sha256:7be409aa151a9b3d93df99f4aeccaf94ffbd73cd4cd0f8daa331059568cade10 +size 11141 diff --git a/data/minecraft/structure/underwater_ruin/brick_1.nbt b/data/minecraft/structure/underwater_ruin/brick_1.nbt index 6c83a159..d74baf9b 100644 --- a/data/minecraft/structure/underwater_ruin/brick_1.nbt +++ b/data/minecraft/structure/underwater_ruin/brick_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:22ed6b19ddf0ba9b69b8a2d9b41b19464f0643eedfe083d2f7707f9420998f6e -size 1269 +oid sha256:eecaeefdc29aeb10d46faa4522400016f44c228e5378c5c1f27242f05e7d6876 +size 1270 diff --git a/data/minecraft/structure/underwater_ruin/brick_2.nbt b/data/minecraft/structure/underwater_ruin/brick_2.nbt index 1bab7636..bd85dcae 100644 --- a/data/minecraft/structure/underwater_ruin/brick_2.nbt +++ b/data/minecraft/structure/underwater_ruin/brick_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5fae4fee21b15d954dd71dc3ccc804b8916a3733862f11bd172ab2e826ea3224 -size 1259 +oid sha256:97002db1d400693c9396fac807980944fc3cdd12f51b0884b79e22f48c86ceaf +size 1260 diff --git a/data/minecraft/structure/underwater_ruin/brick_3.nbt b/data/minecraft/structure/underwater_ruin/brick_3.nbt index df277aa1..a0e5e64e 100644 --- a/data/minecraft/structure/underwater_ruin/brick_3.nbt +++ b/data/minecraft/structure/underwater_ruin/brick_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:10826c1d49bf67a5721e78880da64115ecf866f8e51780b6d00a09b168f8bed1 -size 1318 +oid sha256:ba1919f2ed48419fcf516182aa894f73ab27ddedf4aa1aef3bb89a5a8e90cf39 +size 1319 diff --git a/data/minecraft/structure/underwater_ruin/brick_4.nbt b/data/minecraft/structure/underwater_ruin/brick_4.nbt index 0b5d3c6f..677f6861 100644 --- a/data/minecraft/structure/underwater_ruin/brick_4.nbt +++ b/data/minecraft/structure/underwater_ruin/brick_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a82e3ce0958da06b911564b6c7ddc16297630b51d038ad539bf35a6e6c8b0c59 -size 1295 +oid sha256:1f595d60dcdef6a8f326edba51bf54d6c2f8d419b098c674d95f609d630751a1 +size 1296 diff --git a/data/minecraft/structure/underwater_ruin/brick_5.nbt b/data/minecraft/structure/underwater_ruin/brick_5.nbt index a8f8b3aa..7cc6a452 100644 --- a/data/minecraft/structure/underwater_ruin/brick_5.nbt +++ b/data/minecraft/structure/underwater_ruin/brick_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c64844bdecc9c9361762f8a5044a45c7826348b84c5dfcb5e68602d720f35ab9 -size 1276 +oid sha256:d3370d83ae75c85e2266515e71437cdd006b83f94ae6f7d92b52ab567b55ae62 +size 1277 diff --git a/data/minecraft/structure/underwater_ruin/brick_6.nbt b/data/minecraft/structure/underwater_ruin/brick_6.nbt index 723cc794..39d52a90 100644 --- a/data/minecraft/structure/underwater_ruin/brick_6.nbt +++ b/data/minecraft/structure/underwater_ruin/brick_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6523279ebb6dbecdd1d71fb9139cded17a99e9c7ca705da5884874a04cc5a6ad -size 1467 +oid sha256:62f7e757469f0c7852a5790620413462e54642b24aa294317f6c052d5e539aec +size 1468 diff --git a/data/minecraft/structure/underwater_ruin/brick_7.nbt b/data/minecraft/structure/underwater_ruin/brick_7.nbt index 4ffa7df7..184828b2 100644 --- a/data/minecraft/structure/underwater_ruin/brick_7.nbt +++ b/data/minecraft/structure/underwater_ruin/brick_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8b1fba1ac92b8e5b28dbfa2cf9ae6d33be65fe00608bd23e80c34ef8e80c717c -size 1292 +oid sha256:fc894b307fb84615af2518d2a1e23a42261161f7acf647ccea90d86c6e6a1287 +size 1293 diff --git a/data/minecraft/structure/underwater_ruin/brick_8.nbt b/data/minecraft/structure/underwater_ruin/brick_8.nbt index 80b0bfb5..abe0a5b7 100644 --- a/data/minecraft/structure/underwater_ruin/brick_8.nbt +++ b/data/minecraft/structure/underwater_ruin/brick_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0f15f0c69c6e69416cb93d9a4f301473e98c0c6f4d87f9776d938e64b4031251 -size 1305 +oid sha256:cc85d708af63e9936a60295ce4838f30d8489dc3eb5e2392ad1fd8fd90b9254c +size 1306 diff --git a/data/minecraft/structure/underwater_ruin/cracked_1.nbt b/data/minecraft/structure/underwater_ruin/cracked_1.nbt index 31a73401..1d092462 100644 --- a/data/minecraft/structure/underwater_ruin/cracked_1.nbt +++ b/data/minecraft/structure/underwater_ruin/cracked_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1bf2291653202bba6f393949d2196f9b9b1202137f90b66b3e5f8d7ca79b91c9 -size 1264 +oid sha256:6dd933d0e1cd310437051326d10186485da9affa8f102bc0d0d569dc3973c59c +size 1266 diff --git a/data/minecraft/structure/underwater_ruin/cracked_2.nbt b/data/minecraft/structure/underwater_ruin/cracked_2.nbt index ce446f5a..58aaf891 100644 --- a/data/minecraft/structure/underwater_ruin/cracked_2.nbt +++ b/data/minecraft/structure/underwater_ruin/cracked_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9893d8c4cbdff220bbc785cd7f2224221619f464f57cb71d08e561c64707995e -size 1257 +oid sha256:8143276d0e83a1b2279e7f084b5b39b86d88e5373588ec8cdc58eb56ad879173 +size 1258 diff --git a/data/minecraft/structure/underwater_ruin/cracked_3.nbt b/data/minecraft/structure/underwater_ruin/cracked_3.nbt index f63a739e..4b227c93 100644 --- a/data/minecraft/structure/underwater_ruin/cracked_3.nbt +++ b/data/minecraft/structure/underwater_ruin/cracked_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b29f009ea1b614b1b4d4012543c6da29e286d9fcdb45d6281360e3f7f436d1af -size 1346 +oid sha256:eb625b6db009c98b90448642d74d81cafa5adf5b7b8648c46631886dabca72ea +size 1348 diff --git a/data/minecraft/structure/underwater_ruin/cracked_4.nbt b/data/minecraft/structure/underwater_ruin/cracked_4.nbt index 34f44fb2..8ae19c5e 100644 --- a/data/minecraft/structure/underwater_ruin/cracked_4.nbt +++ b/data/minecraft/structure/underwater_ruin/cracked_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5f47941914b97023910e4d6a39f4cdaa40d900b7da04151ee817064fe06f5adf -size 1255 +oid sha256:3e107f5d7a9dcbb72a156553b7c0a1088e6af33c34ef40b16f78d1889d52abe0 +size 1257 diff --git a/data/minecraft/structure/underwater_ruin/cracked_5.nbt b/data/minecraft/structure/underwater_ruin/cracked_5.nbt index d6efe7f0..b33fc44b 100644 --- a/data/minecraft/structure/underwater_ruin/cracked_5.nbt +++ b/data/minecraft/structure/underwater_ruin/cracked_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:41c5df7dd7a6d6da6f9f7d24ae449739b3b1451f19509c298304d3390d024b9e -size 1281 +oid sha256:6e72b4746f9f6fbe0ffb32f23ea2b81184d00bc343478ecd36b2e7d38a962a36 +size 1282 diff --git a/data/minecraft/structure/underwater_ruin/cracked_6.nbt b/data/minecraft/structure/underwater_ruin/cracked_6.nbt index 7c583289..b99cc249 100644 --- a/data/minecraft/structure/underwater_ruin/cracked_6.nbt +++ b/data/minecraft/structure/underwater_ruin/cracked_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c4c9b43e2c2b807431f8d5a49d4f9a1dce06c4542e48fa912eb545e345b1cae2 -size 1408 +oid sha256:4142805aee06de69f692f664956d195d591af24a229ed1fe1776ad1c5361bbcb +size 1410 diff --git a/data/minecraft/structure/underwater_ruin/cracked_7.nbt b/data/minecraft/structure/underwater_ruin/cracked_7.nbt index c7f33caf..2c82ecde 100644 --- a/data/minecraft/structure/underwater_ruin/cracked_7.nbt +++ b/data/minecraft/structure/underwater_ruin/cracked_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a901dc71e9592220950f6d4da9ab47c658ec66fd5728fb4f59466683ddea504d -size 1313 +oid sha256:7c2b1eaf3726a85d2c821b23c431bc30a414fc9134e172abce94af33bfcf884e +size 1314 diff --git a/data/minecraft/structure/underwater_ruin/cracked_8.nbt b/data/minecraft/structure/underwater_ruin/cracked_8.nbt index d3b6cf28..03a82586 100644 --- a/data/minecraft/structure/underwater_ruin/cracked_8.nbt +++ b/data/minecraft/structure/underwater_ruin/cracked_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e908ce7c8df3f006b94f7585b0854d7ebe0f094ee7913fe35061d965c71d0d03 -size 1293 +oid sha256:8f245736d5954668652e3db0673d29515e2c1684631db0b7b301f142e91db25b +size 1294 diff --git a/data/minecraft/structure/underwater_ruin/mossy_1.nbt b/data/minecraft/structure/underwater_ruin/mossy_1.nbt index e3e0a196..83a25270 100644 --- a/data/minecraft/structure/underwater_ruin/mossy_1.nbt +++ b/data/minecraft/structure/underwater_ruin/mossy_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7cc3df953215246163398fc20cb39b7f8ac8c66d160c0f97404e6d4f52e2efd2 -size 1277 +oid sha256:7421deba3cdc5b5ab992661d7732abe5e248e03878c7195e64f5b28c98b77665 +size 1279 diff --git a/data/minecraft/structure/underwater_ruin/mossy_2.nbt b/data/minecraft/structure/underwater_ruin/mossy_2.nbt index 7c218788..5fe476a6 100644 --- a/data/minecraft/structure/underwater_ruin/mossy_2.nbt +++ b/data/minecraft/structure/underwater_ruin/mossy_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4e93962f59d8bc12ccfbceb8e34e45f9f164690d91a74719d9f0de3698b809df -size 1232 +oid sha256:4255a060ebff0b9c71340194440f24f0ba4e125c54883bb61eca47b2340364a9 +size 1233 diff --git a/data/minecraft/structure/underwater_ruin/mossy_3.nbt b/data/minecraft/structure/underwater_ruin/mossy_3.nbt index 796417cb..2739d787 100644 --- a/data/minecraft/structure/underwater_ruin/mossy_3.nbt +++ b/data/minecraft/structure/underwater_ruin/mossy_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fcdc3deaf5351a26bf57e9e2ede2c323adab5fb9debee5111c9562761d7d984c -size 1322 +oid sha256:5e68755d83083d2ca8122f136312322450a446a248b4178acfa0a48c17130db9 +size 1323 diff --git a/data/minecraft/structure/underwater_ruin/mossy_4.nbt b/data/minecraft/structure/underwater_ruin/mossy_4.nbt index 8b22b042..a47f2612 100644 --- a/data/minecraft/structure/underwater_ruin/mossy_4.nbt +++ b/data/minecraft/structure/underwater_ruin/mossy_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:79834c3e447d2ca160ac8e81e755c923a40d87b82ec412daa92b788aa8458e9a -size 1281 +oid sha256:0c5dd62686c9e1d0317818b73053c6c098329b7b42bc039f1d1b8e5fd73ca8bb +size 1282 diff --git a/data/minecraft/structure/underwater_ruin/mossy_5.nbt b/data/minecraft/structure/underwater_ruin/mossy_5.nbt index d58a757d..ca9993d4 100644 --- a/data/minecraft/structure/underwater_ruin/mossy_5.nbt +++ b/data/minecraft/structure/underwater_ruin/mossy_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8f4a0699855403195810f625eefca17a304b665ce08c770814e1220ec5198173 -size 1298 +oid sha256:7f1961245d4cc22f1bb274d8b53b08e9b191822c4b2e2d89f2d03fe177ce0724 +size 1300 diff --git a/data/minecraft/structure/underwater_ruin/mossy_6.nbt b/data/minecraft/structure/underwater_ruin/mossy_6.nbt index a1b56149..915797cd 100644 --- a/data/minecraft/structure/underwater_ruin/mossy_6.nbt +++ b/data/minecraft/structure/underwater_ruin/mossy_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:25cfc6d0939bd5a00f223e3d1d5df32f5b38143c3243282bd4925930c0de5f9e -size 1451 +oid sha256:241d0796b5f1468accceeff9cb268e96f68c88f9e036a33ea93a8cb2b3e26044 +size 1452 diff --git a/data/minecraft/structure/underwater_ruin/mossy_7.nbt b/data/minecraft/structure/underwater_ruin/mossy_7.nbt index 36bead64..56795391 100644 --- a/data/minecraft/structure/underwater_ruin/mossy_7.nbt +++ b/data/minecraft/structure/underwater_ruin/mossy_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d7b1484bc63e5f7fedae72ccf01adf71637324473a94c4b229f684fcd9e13379 -size 1309 +oid sha256:36fbc836a7084fcddf9a56e348c265c3c5ce2ce0781523992e13663fae46cfdd +size 1310 diff --git a/data/minecraft/structure/underwater_ruin/mossy_8.nbt b/data/minecraft/structure/underwater_ruin/mossy_8.nbt index 1c5a728c..01515164 100644 --- a/data/minecraft/structure/underwater_ruin/mossy_8.nbt +++ b/data/minecraft/structure/underwater_ruin/mossy_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4bb64746a1de1733b4432a9fa8df49aa9d766d458e81d8aefb468d4157d299fc -size 1321 +oid sha256:85a005d9515789914a1f329371afcda9c21afd2a9947d85a14b56d9a3b809bd1 +size 1322 diff --git a/data/minecraft/structure/underwater_ruin/warm_1.nbt b/data/minecraft/structure/underwater_ruin/warm_1.nbt index f3447881..c701d7cb 100644 --- a/data/minecraft/structure/underwater_ruin/warm_1.nbt +++ b/data/minecraft/structure/underwater_ruin/warm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:88daf62a72cbfb096362b670e6be6ca534c06a0817d312f32e32f34256bc338f -size 1268 +oid sha256:874b236c5169422eec35bd6d7d3da2833d0bcf9880bcbab140ddd34b942b396e +size 1269 diff --git a/data/minecraft/structure/underwater_ruin/warm_2.nbt b/data/minecraft/structure/underwater_ruin/warm_2.nbt index dc8446eb..752d3423 100644 --- a/data/minecraft/structure/underwater_ruin/warm_2.nbt +++ b/data/minecraft/structure/underwater_ruin/warm_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b9516bdbd59633384472b1e63b03dea4757e79492dfca43df064f52e8271ed8e -size 1298 +oid sha256:4b67c4309672436a26b1192735dd3c72253ccc56fcfe07dec3d47405aabebe51 +size 1299 diff --git a/data/minecraft/structure/underwater_ruin/warm_3.nbt b/data/minecraft/structure/underwater_ruin/warm_3.nbt index 938af838..eaf20823 100644 --- a/data/minecraft/structure/underwater_ruin/warm_3.nbt +++ b/data/minecraft/structure/underwater_ruin/warm_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:18dfa44700a63ad5695816483465d622df1d944a4a1da3f971f676a07f980588 -size 1271 +oid sha256:a8b29c15227db2820538750cf4082f02acb9c8e8d6710254d4cd2ef62faf1c60 +size 1272 diff --git a/data/minecraft/structure/underwater_ruin/warm_4.nbt b/data/minecraft/structure/underwater_ruin/warm_4.nbt index 44e3886c..ff91681e 100644 --- a/data/minecraft/structure/underwater_ruin/warm_4.nbt +++ b/data/minecraft/structure/underwater_ruin/warm_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:575b4a5be370733b2503d214b7b29f332abe1655878d3c6b5e5bf5cfe35e777b -size 1347 +oid sha256:d66b6a8b55cfede5adc8d53e75e1f9493dd7655161159e928ac498020e855020 +size 1348 diff --git a/data/minecraft/structure/underwater_ruin/warm_5.nbt b/data/minecraft/structure/underwater_ruin/warm_5.nbt index bcd052ac..93e5023c 100644 --- a/data/minecraft/structure/underwater_ruin/warm_5.nbt +++ b/data/minecraft/structure/underwater_ruin/warm_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:83d41035139174c4057496a669a5bd01c56bfa09871ad2da1d7d0b2ef3c4e112 -size 1226 +oid sha256:78f4a1da5d59427f110d1c9566ec088bcf715a4c3020dff540cd26423b966c60 +size 1227 diff --git a/data/minecraft/structure/underwater_ruin/warm_6.nbt b/data/minecraft/structure/underwater_ruin/warm_6.nbt index 8b76ec9f..347c012a 100644 --- a/data/minecraft/structure/underwater_ruin/warm_6.nbt +++ b/data/minecraft/structure/underwater_ruin/warm_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f8c9efe21f71a01fbf16848522f6ccb5820cd24ceb251bb3c0fdeada03dee744 -size 1270 +oid sha256:375fabe46977f50dbf8ea3448eb61ac63305f3a3341dff159884ce3507f3410d +size 1271 diff --git a/data/minecraft/structure/underwater_ruin/warm_7.nbt b/data/minecraft/structure/underwater_ruin/warm_7.nbt index 72c12c10..dd9a5f83 100644 --- a/data/minecraft/structure/underwater_ruin/warm_7.nbt +++ b/data/minecraft/structure/underwater_ruin/warm_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fb4561071a603a5ce00cbb79139b2d3feaf98ad200f308c7041019338e302bcd -size 1210 +oid sha256:d8ae879269e8136f69b6f9e026b84a8d54517da58c1cce43bf2a6ca260d8ad99 +size 1211 diff --git a/data/minecraft/structure/underwater_ruin/warm_8.nbt b/data/minecraft/structure/underwater_ruin/warm_8.nbt index ffc0f6a0..f8b9a8a5 100644 --- a/data/minecraft/structure/underwater_ruin/warm_8.nbt +++ b/data/minecraft/structure/underwater_ruin/warm_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ad3d9e7e146e98275be51ef0f810d38925699d2804a096e5bea19bfb8da60b35 -size 1339 +oid sha256:1116512f62dc862281e379829a113b214f40b0ba09852fa8984832c4c8ef4a76 +size 1340 diff --git a/data/minecraft/structure/village/common/animals/cat_black.nbt b/data/minecraft/structure/village/common/animals/cat_black.nbt index 07754fd3..90171a6a 100644 --- a/data/minecraft/structure/village/common/animals/cat_black.nbt +++ b/data/minecraft/structure/village/common/animals/cat_black.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4b7bea87d2137683239522bb6ab391d70fa0f4e02a1d2ee2ae679a25d5fd6915 -size 922 +oid sha256:71e56c9b90c28e3b5fe35c2c8b5955c5ab28b626359ab644df65fa939eb5fdf5 +size 892 diff --git a/data/minecraft/structure/village/common/animals/cat_british.nbt b/data/minecraft/structure/village/common/animals/cat_british.nbt index fd83a51c..6bb708a3 100644 --- a/data/minecraft/structure/village/common/animals/cat_british.nbt +++ b/data/minecraft/structure/village/common/animals/cat_british.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f8176da46b64b55f81649d14b655790717ee8ffb3c81ad5738f25ad3bd173ab -size 929 +oid sha256:52e843aa9763c836e1e83a157b231d8398c0a7e82f64cf243672e8269800dbf6 +size 901 diff --git a/data/minecraft/structure/village/common/animals/cat_calico.nbt b/data/minecraft/structure/village/common/animals/cat_calico.nbt index ba904f08..efb1f64f 100644 --- a/data/minecraft/structure/village/common/animals/cat_calico.nbt +++ b/data/minecraft/structure/village/common/animals/cat_calico.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:256caa09fa6c4703f10615d0f2d45a0cc44514a71245740a5c0444cdc200ba49 -size 853 +oid sha256:9739aed88113d53d6c6336a175f772adf5a23871d2bd46225505c131485c9e73 +size 827 diff --git a/data/minecraft/structure/village/common/animals/cat_jellie.nbt b/data/minecraft/structure/village/common/animals/cat_jellie.nbt index 18bdab2e..16426a14 100644 --- a/data/minecraft/structure/village/common/animals/cat_jellie.nbt +++ b/data/minecraft/structure/village/common/animals/cat_jellie.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9f90749cb6599acded877914038789dc1f711d52c4b8a1b989bfc870a9b861fe -size 925 +oid sha256:ff79cfa1a393638f1aae5f00dec9ec44fb6edc5fe28160ff4ebd440109f34aee +size 896 diff --git a/data/minecraft/structure/village/common/animals/cat_persian.nbt b/data/minecraft/structure/village/common/animals/cat_persian.nbt index 7a48a9f4..e7775b19 100644 --- a/data/minecraft/structure/village/common/animals/cat_persian.nbt +++ b/data/minecraft/structure/village/common/animals/cat_persian.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e4e147467d76a7f19acd38c032ae430c44b4dbb519eaa8db9702dc84cf44b20 -size 857 +oid sha256:fe6a6b2a50565e8401bb86659ae0c136137aa6eeef2852b87630cdffacfd2708 +size 829 diff --git a/data/minecraft/structure/village/common/animals/cat_ragdoll.nbt b/data/minecraft/structure/village/common/animals/cat_ragdoll.nbt index 1b493caf..dbe6754b 100644 --- a/data/minecraft/structure/village/common/animals/cat_ragdoll.nbt +++ b/data/minecraft/structure/village/common/animals/cat_ragdoll.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:95a08bd48e7223e4544437e7aa42ec93e879cb5a8a5fdaa777723ac849c3a0c8 -size 920 +oid sha256:3cfae776a64dbddc31fbe91e67ec797d2adee07bc9084e1629729014de9306f5 +size 892 diff --git a/data/minecraft/structure/village/common/animals/cat_red.nbt b/data/minecraft/structure/village/common/animals/cat_red.nbt index 4236b61f..121087df 100644 --- a/data/minecraft/structure/village/common/animals/cat_red.nbt +++ b/data/minecraft/structure/village/common/animals/cat_red.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:155a7b93b4e31d24886a6a054763414b60513a3d6322715e60bc11fe15f136a1 -size 839 +oid sha256:28ac1ea87d58c274206cb5d1aaf88800f5ed863b2ac2adcd1142af20b04453c4 +size 810 diff --git a/data/minecraft/structure/village/common/animals/cat_siamese.nbt b/data/minecraft/structure/village/common/animals/cat_siamese.nbt index cb2927c2..f7011150 100644 --- a/data/minecraft/structure/village/common/animals/cat_siamese.nbt +++ b/data/minecraft/structure/village/common/animals/cat_siamese.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:119c4c12f9218e9b006844d4ab039dca23e12df3ace3b29c2ef5465ea98b1162 -size 845 +oid sha256:da9f4fbd41f6a74dc2173eebce2c87ee57c0e939062231f48d6b270d1d76e723 +size 819 diff --git a/data/minecraft/structure/village/common/animals/cat_tabby.nbt b/data/minecraft/structure/village/common/animals/cat_tabby.nbt index 46381fd7..85f0b039 100644 --- a/data/minecraft/structure/village/common/animals/cat_tabby.nbt +++ b/data/minecraft/structure/village/common/animals/cat_tabby.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b653f6e518e277b0ac21ef5c7b2503803fdca9d3e687a0fb751d4b4383160985 -size 918 +oid sha256:387169823d4187c6c0e49103b22c2782fbb23cb564f300ae6913966d454589be +size 888 diff --git a/data/minecraft/structure/village/common/animals/cat_white.nbt b/data/minecraft/structure/village/common/animals/cat_white.nbt index 7ef6681f..68224029 100644 --- a/data/minecraft/structure/village/common/animals/cat_white.nbt +++ b/data/minecraft/structure/village/common/animals/cat_white.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:20f31193d05a3c2c4fdf14ad2c72e0e9725aea21e5add512bcf39b98ae96e3ba -size 914 +oid sha256:fd6efa38e8a63def2027ca6288e88152e8eefdc1a134efa1e14ddf9cfd3bbb72 +size 886 diff --git a/data/minecraft/structure/village/common/animals/cows_1.nbt b/data/minecraft/structure/village/common/animals/cows_1.nbt index c9ece9fc..f0a7f02b 100644 --- a/data/minecraft/structure/village/common/animals/cows_1.nbt +++ b/data/minecraft/structure/village/common/animals/cows_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:51f84f6055a18a6d72f818076a0afeab76f238d6a3a70afa92b384199009ec6d -size 956 +oid sha256:dc2f2661be5a50d11a1974b8040e029d4ef1ce0c0d95962ea5ff7755822c46d9 +size 928 diff --git a/data/minecraft/structure/village/common/animals/horses_1.nbt b/data/minecraft/structure/village/common/animals/horses_1.nbt index 4e66f60a..10aa7bf1 100644 --- a/data/minecraft/structure/village/common/animals/horses_1.nbt +++ b/data/minecraft/structure/village/common/animals/horses_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c33bec44703fbebbc041c996b241dafc22790465d00a3662e79a6817be8a169 -size 920 +oid sha256:a820cf34db2e42a14df54a6621c7cfc411ca775bcab5da544e38dcacfe710a53 +size 893 diff --git a/data/minecraft/structure/village/common/animals/horses_2.nbt b/data/minecraft/structure/village/common/animals/horses_2.nbt index 06f53a43..5540d605 100644 --- a/data/minecraft/structure/village/common/animals/horses_2.nbt +++ b/data/minecraft/structure/village/common/animals/horses_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a457c272be132cb949395fadedec7d02ee05b5bb53877bc78281d5f7dfcd2413 -size 1031 +oid sha256:3f36e6c3c4e12cfae750fb39f0e073c012e1f0e780b206bea7e4f6dcbcaeed69 +size 1003 diff --git a/data/minecraft/structure/village/common/animals/horses_3.nbt b/data/minecraft/structure/village/common/animals/horses_3.nbt index d0d693c5..37a9ecfa 100644 --- a/data/minecraft/structure/village/common/animals/horses_3.nbt +++ b/data/minecraft/structure/village/common/animals/horses_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5a87b5b45edfae41eed04c30cb763ce08c9b9eec892288ba7b240b20d9ac4c83 -size 1039 +oid sha256:1c03c6c60b00bab979623f5354a560ac28920d1527d06b25f5d08f5cda9fa9fe +size 1011 diff --git a/data/minecraft/structure/village/common/animals/horses_4.nbt b/data/minecraft/structure/village/common/animals/horses_4.nbt index 1deed4b2..8b6b76f0 100644 --- a/data/minecraft/structure/village/common/animals/horses_4.nbt +++ b/data/minecraft/structure/village/common/animals/horses_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e0e2acdd7ad1990d8584ea046e7e7ba6fafe9bd068ebdf83b8d59b2233ac988e -size 912 +oid sha256:9f6a6fa970a4170f891138301637785e61a0cb46da9f6bfb94112eafab1eec47 +size 884 diff --git a/data/minecraft/structure/village/common/animals/horses_5.nbt b/data/minecraft/structure/village/common/animals/horses_5.nbt index 9d68b7de..87aaf86f 100644 --- a/data/minecraft/structure/village/common/animals/horses_5.nbt +++ b/data/minecraft/structure/village/common/animals/horses_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:51eb6f370b09f64efe636e90549548f7a9f123fe2c6034c7ddd9a1e771139442 -size 932 +oid sha256:79f564d335a2508f4c4cb44545f1ba403601eef67a3473c99c71d70453080b62 +size 906 diff --git a/data/minecraft/structure/village/common/animals/pigs_1.nbt b/data/minecraft/structure/village/common/animals/pigs_1.nbt index dd24a1e2..a9678381 100644 --- a/data/minecraft/structure/village/common/animals/pigs_1.nbt +++ b/data/minecraft/structure/village/common/animals/pigs_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0b3459349ca322352a07ba2025bcd7865913da12adfd7e9dc53d4c3e55b5f806 -size 966 +oid sha256:d88b9a9850a695802a44a86e6a14f44aa3b2db09965bc2a193e043f61a638d51 +size 932 diff --git a/data/minecraft/structure/village/common/animals/sheep_1.nbt b/data/minecraft/structure/village/common/animals/sheep_1.nbt index 3c461e70..e0382ba6 100644 --- a/data/minecraft/structure/village/common/animals/sheep_1.nbt +++ b/data/minecraft/structure/village/common/animals/sheep_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:92158da5afa1705bd62ffe3e50a9cecb45cea16ae773ba4afcfba39022e22bd8 -size 981 +oid sha256:36fb013f2b16a4f726622e797ea43586ff1efff6d684c633ab5cf8e8e431a8b4 +size 950 diff --git a/data/minecraft/structure/village/common/animals/sheep_2.nbt b/data/minecraft/structure/village/common/animals/sheep_2.nbt index 7d34f010..812ed734 100644 --- a/data/minecraft/structure/village/common/animals/sheep_2.nbt +++ b/data/minecraft/structure/village/common/animals/sheep_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:66909b51c76a2d88f86a2382b01bcfb03e00bf2f59b45f07b0c7b655df79bf32 -size 981 +oid sha256:b707ec29bf03436c749397d0a2eb50fc7c7bfc0bc1a614719d3c99e9dd11b649 +size 950 diff --git a/data/minecraft/structure/village/common/iron_golem.nbt b/data/minecraft/structure/village/common/iron_golem.nbt index 3f5308f3..63f0c1a4 100644 --- a/data/minecraft/structure/village/common/iron_golem.nbt +++ b/data/minecraft/structure/village/common/iron_golem.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f71178541a36c43e57628b75a7e00127e11112f8b8dbadd4e84b300c40d0030b -size 854 +oid sha256:8e760878b1a2884ec411b5c480e5be16783dc73ab566e88c52506116c16e84b2 +size 823 diff --git a/data/minecraft/structure/village/common/well_bottom.nbt b/data/minecraft/structure/village/common/well_bottom.nbt index 71159870..9d6270d0 100644 --- a/data/minecraft/structure/village/common/well_bottom.nbt +++ b/data/minecraft/structure/village/common/well_bottom.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8991d40885e4751e0c46019c20258f919d7bb9c840a9b5b71e6ab10eab8ea144 -size 426 +oid sha256:4b21747020d10888eb17671968778429f3a672a328164affa64739abf1c34fdf +size 427 diff --git a/data/minecraft/structure/village/decays/grass_11x13.nbt b/data/minecraft/structure/village/decays/grass_11x13.nbt index 2ca45a38..0d980324 100644 --- a/data/minecraft/structure/village/decays/grass_11x13.nbt +++ b/data/minecraft/structure/village/decays/grass_11x13.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e327cf0684bc8b415eda139399719506296029db05e63dac01978b6e63fefd43 -size 557 +oid sha256:f85eae8e13483d840180249c26b2603fd55e675e44a282e72f96171008148dd4 +size 558 diff --git a/data/minecraft/structure/village/decays/grass_16x16.nbt b/data/minecraft/structure/village/decays/grass_16x16.nbt index 3f275fdd..1928a038 100644 --- a/data/minecraft/structure/village/decays/grass_16x16.nbt +++ b/data/minecraft/structure/village/decays/grass_16x16.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d93ddf8fdbea35abfd9aba57de9dc257cf6abc65a662724d3588ad911cdf3ac2 -size 873 +oid sha256:020f16905f04082d4cc341cce96442686407ba48c5b448a64ee46afdbac39cd6 +size 874 diff --git a/data/minecraft/structure/village/decays/grass_9x9.nbt b/data/minecraft/structure/village/decays/grass_9x9.nbt index b013e5af..5c53712d 100644 --- a/data/minecraft/structure/village/decays/grass_9x9.nbt +++ b/data/minecraft/structure/village/decays/grass_9x9.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bd9b4443fc4bcc83d8c28336a15867c45f70a1d50c65dfda1d8612c25d2536b7 +oid sha256:ceb5d1b69c10870baaa4119665c9ed9dac11e10d5f9ae7f93bb9209197c310cc size 393 diff --git a/data/minecraft/structure/village/desert/camel_spawn.nbt b/data/minecraft/structure/village/desert/camel_spawn.nbt index 63d28f7d..2284e01b 100644 --- a/data/minecraft/structure/village/desert/camel_spawn.nbt +++ b/data/minecraft/structure/village/desert/camel_spawn.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:85ce0bde8600204c601cd68d6bee2c5037a5e1332aeca21ce6383278a1ca3784 -size 282 +oid sha256:17f25e404a65c004036e1a472c9333d4275bbf06efafbf53fbfcbef7266d2cc3 +size 283 diff --git a/data/minecraft/structure/village/desert/desert_lamp_1.nbt b/data/minecraft/structure/village/desert/desert_lamp_1.nbt index a5cba86f..a7a2893f 100644 --- a/data/minecraft/structure/village/desert/desert_lamp_1.nbt +++ b/data/minecraft/structure/village/desert/desert_lamp_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fe66142a954974f4ff4ab3b3e4f371388b32972c4a0af672008da5b3d532272a -size 278 +oid sha256:97ad489ffb1ada4ccb6c0c0656d1c98e88a8f061600c3c16d75a3141ce9b6ce7 +size 279 diff --git a/data/minecraft/structure/village/desert/houses/desert_animal_pen_1.nbt b/data/minecraft/structure/village/desert/houses/desert_animal_pen_1.nbt index 40eadd3a..945dfd50 100644 --- a/data/minecraft/structure/village/desert/houses/desert_animal_pen_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_animal_pen_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9f4a54c5ee40275e3ba9f924295facbedbc6c679edf6145191db7b794d57675c -size 1688 +oid sha256:8b5f2bc895b8813741a17f5a9cd4209ba1e4bacaaf3ebfc634db4df93abef9fa +size 1690 diff --git a/data/minecraft/structure/village/desert/houses/desert_animal_pen_2.nbt b/data/minecraft/structure/village/desert/houses/desert_animal_pen_2.nbt index 6effaee6..b75e208c 100644 --- a/data/minecraft/structure/village/desert/houses/desert_animal_pen_2.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_animal_pen_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5405e404e4c3157dc118eb47ac72b0c8ce2f6c1cb4bb89f2dd87ed117bfbf950 -size 1862 +oid sha256:44dd5e2271ab63af6aeeba6c198141a683720abebd6e4636b2b2d4dcc7034a59 +size 1864 diff --git a/data/minecraft/structure/village/desert/houses/desert_armorer_1.nbt b/data/minecraft/structure/village/desert/houses/desert_armorer_1.nbt index 12ffe1e4..28ccd4a1 100644 --- a/data/minecraft/structure/village/desert/houses/desert_armorer_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_armorer_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:910aca847d966ce10343a7302fda4da103ae4230eadad338f2aea0b93fbd3e3d -size 1763 +oid sha256:d62c4facd15468717daf4ecc4d15e9a3ba4f49313ea9dd68e47402b421306356 +size 1765 diff --git a/data/minecraft/structure/village/desert/houses/desert_butcher_shop_1.nbt b/data/minecraft/structure/village/desert/houses/desert_butcher_shop_1.nbt index a29cf92e..55861836 100644 --- a/data/minecraft/structure/village/desert/houses/desert_butcher_shop_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_butcher_shop_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:60b65103ab70d6e501a68d243be46a4877246ea270eb4a6298e63c8169c7a43b -size 1795 +oid sha256:60f85bc8b72fe02a7aa3187b78768399e737ae1ff3718d81300ebce3b70ceaa1 +size 1797 diff --git a/data/minecraft/structure/village/desert/houses/desert_cartographer_house_1.nbt b/data/minecraft/structure/village/desert/houses/desert_cartographer_house_1.nbt index 3fa66a54..05b8ff0c 100644 --- a/data/minecraft/structure/village/desert/houses/desert_cartographer_house_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_cartographer_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:103b2fc5c19248476d44a09e77ea8eaa933bb2841612106b0485a68c35aec3d7 -size 1675 +oid sha256:c9ac7028562fdf0aa6d288507795c3a645429b5090ab5653949931fde6641413 +size 1677 diff --git a/data/minecraft/structure/village/desert/houses/desert_farm_1.nbt b/data/minecraft/structure/village/desert/houses/desert_farm_1.nbt index 8b357de1..474371cd 100644 --- a/data/minecraft/structure/village/desert/houses/desert_farm_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_farm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:56828f026644102b9ba2cf8579357e522265a25f8c32703c4e234d5ef4dc065b -size 714 +oid sha256:54899eebba96aa9648b34bcdcca07125e79f7e7b79f203e36923be1018319670 +size 715 diff --git a/data/minecraft/structure/village/desert/houses/desert_farm_2.nbt b/data/minecraft/structure/village/desert/houses/desert_farm_2.nbt index 4fbc499f..ce3ddcd0 100644 --- a/data/minecraft/structure/village/desert/houses/desert_farm_2.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_farm_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8b5ae2f0845b2509d28f5945ef6b78f37faacf19d66c0351244ae65d746f65ca -size 885 +oid sha256:7165c2553820cd6eaa29fab8fa786f330ce0303b0d9aad8780db6a05b7457faf +size 887 diff --git a/data/minecraft/structure/village/desert/houses/desert_fisher_1.nbt b/data/minecraft/structure/village/desert/houses/desert_fisher_1.nbt index 931b88aa..608f58f7 100644 --- a/data/minecraft/structure/village/desert/houses/desert_fisher_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_fisher_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f9424c036f002e66c15c1e3781f0a52f210391fe5209cfd62ab165714a134072 -size 2285 +oid sha256:91f0a1c0398c2ea1b70f5eaa57db47e3dcb3a9e811edb4543acf95a663f05b3d +size 2286 diff --git a/data/minecraft/structure/village/desert/houses/desert_fletcher_house_1.nbt b/data/minecraft/structure/village/desert/houses/desert_fletcher_house_1.nbt index 2d3c2bf9..222ecf59 100644 --- a/data/minecraft/structure/village/desert/houses/desert_fletcher_house_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_fletcher_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:47bca75cb1db730a5fb3aa1e829d4b301902a02e3368263ac68fdff5b51d98dd -size 3094 +oid sha256:893b998bb174d5e116cbb08a68a33457a35c9860fc52c94c9f4f4b93f37538d2 +size 3095 diff --git a/data/minecraft/structure/village/desert/houses/desert_large_farm_1.nbt b/data/minecraft/structure/village/desert/houses/desert_large_farm_1.nbt index 323ba5d4..9444858a 100644 --- a/data/minecraft/structure/village/desert/houses/desert_large_farm_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_large_farm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:080135797d685e623ec146104ced67993cdd937aa13a481e2ec4594e58ce3d7c -size 1622 +oid sha256:10b245801e305655146605e26d723e2ee46bdd7b1e3404782bc28d6b91bf4f25 +size 1623 diff --git a/data/minecraft/structure/village/desert/houses/desert_library_1.nbt b/data/minecraft/structure/village/desert/houses/desert_library_1.nbt index 8faddb31..3f3c31e9 100644 --- a/data/minecraft/structure/village/desert/houses/desert_library_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_library_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0daa17e025c4d0863150a0081ef531e11631670b091f2fffb642d3a9ca22bf0b -size 1538 +oid sha256:3cda71597a329812c44d65b449de4a5ad2de1e8ea9cb48ec2b149883fac3d426 +size 1539 diff --git a/data/minecraft/structure/village/desert/houses/desert_mason_1.nbt b/data/minecraft/structure/village/desert/houses/desert_mason_1.nbt index 0788f0ed..99a4b46d 100644 --- a/data/minecraft/structure/village/desert/houses/desert_mason_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_mason_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6d2adfb1c296da2d617cba78e2e524bae3fa330d4484791e51b1265ba0a2cd2a -size 1441 +oid sha256:67f100aa8af0f46cfcdb1d90473c8083f7934b21b611bc22296d709e57ec746e +size 1443 diff --git a/data/minecraft/structure/village/desert/houses/desert_medium_house_1.nbt b/data/minecraft/structure/village/desert/houses/desert_medium_house_1.nbt index a7a6f325..48496a15 100644 --- a/data/minecraft/structure/village/desert/houses/desert_medium_house_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4e59f8608536d21012870d2ff415d2b5cb475f52e1705a5b79c9f75e70d75863 -size 1440 +oid sha256:c5217566b822ef1c791f0021b7b25dc9e7b0b4e13f0a39215b03a6293b88967e +size 1442 diff --git a/data/minecraft/structure/village/desert/houses/desert_medium_house_2.nbt b/data/minecraft/structure/village/desert/houses/desert_medium_house_2.nbt index dd60ac81..b10082dd 100644 --- a/data/minecraft/structure/village/desert/houses/desert_medium_house_2.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:19a12a8183960f4fa3da0538c4a37026dd4e41dfba33a0a02a596abc4cabfe18 -size 2837 +oid sha256:7757ad5b65558a3735ef7b8d21d4476ea2c457dfd0343884f4dbedd94ee0d836 +size 2838 diff --git a/data/minecraft/structure/village/desert/houses/desert_shepherd_house_1.nbt b/data/minecraft/structure/village/desert/houses/desert_shepherd_house_1.nbt index 98d95bc2..d0ea5d14 100644 --- a/data/minecraft/structure/village/desert/houses/desert_shepherd_house_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_shepherd_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1b925740950bf5dac8780767a7869cfdeb98db6271be37c255c508e44ec101a7 -size 1565 +oid sha256:a91385eec381fd69e54c3cb556918a519cd271682fb92963b934670db88eec2c +size 1567 diff --git a/data/minecraft/structure/village/desert/houses/desert_small_house_1.nbt b/data/minecraft/structure/village/desert/houses/desert_small_house_1.nbt index 7d360c83..e3c08fd5 100644 --- a/data/minecraft/structure/village/desert/houses/desert_small_house_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6a98c0134f4900bddb3654c5e331c08d2c1a14bde05c3a2524ac28c762638ae4 -size 1179 +oid sha256:09dbc7eed5f44eed3e1a3bdc6d06c06cddf064967a16c2687214128da39ad38f +size 1180 diff --git a/data/minecraft/structure/village/desert/houses/desert_small_house_2.nbt b/data/minecraft/structure/village/desert/houses/desert_small_house_2.nbt index 9451f842..90d7fc75 100644 --- a/data/minecraft/structure/village/desert/houses/desert_small_house_2.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3bd6575d6055e16e1879f10c93987bb28e2b17ac1850dbfd716bc9ae5c83b3b7 -size 1313 +oid sha256:66bfe2fdef3455283aae502ee77565eead1d70524bba39b19551ccf2de23dbb6 +size 1314 diff --git a/data/minecraft/structure/village/desert/houses/desert_small_house_3.nbt b/data/minecraft/structure/village/desert/houses/desert_small_house_3.nbt index bc316f9e..0b8f3adf 100644 --- a/data/minecraft/structure/village/desert/houses/desert_small_house_3.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:55a3f3d70546e33cb5bd866c7afe21daecef867a843534b00d14a07212454154 -size 1131 +oid sha256:84e0be34e11c528e138e2b0e1289d4202e05bfd23ae2e527e3a73c7faf67cf03 +size 1132 diff --git a/data/minecraft/structure/village/desert/houses/desert_small_house_4.nbt b/data/minecraft/structure/village/desert/houses/desert_small_house_4.nbt index 482a944e..86ce86af 100644 --- a/data/minecraft/structure/village/desert/houses/desert_small_house_4.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:de8b7eee6834730eeb6df96b7131ba2a7aa99006bf75937403c3d9879d28b6c0 -size 1053 +oid sha256:4dd4a2b5bcc534f3313888175d132270bad7052ed7ce8e459ff84e4d72bf2d53 +size 1055 diff --git a/data/minecraft/structure/village/desert/houses/desert_small_house_5.nbt b/data/minecraft/structure/village/desert/houses/desert_small_house_5.nbt index ac225daa..e49a660c 100644 --- a/data/minecraft/structure/village/desert/houses/desert_small_house_5.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6a7abd523d993553c9ca59f7b2fed5838bd111a2e1f458c4b2e5f865fc7339bf -size 1107 +oid sha256:3c1a8e527f16c52c9c17d5bc9dec0370005886797489e57fa67d7e78bd1f7d46 +size 1108 diff --git a/data/minecraft/structure/village/desert/houses/desert_small_house_6.nbt b/data/minecraft/structure/village/desert/houses/desert_small_house_6.nbt index 3d5ae3b6..e28216df 100644 --- a/data/minecraft/structure/village/desert/houses/desert_small_house_6.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_small_house_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1726e6b0c016a7a0ca94ac8dbe98814dcc36b005528c1f6eafb0ef8c15003639 -size 2292 +oid sha256:f32591e4b7fd2db39eb20e47c7ff9a3e540b968a735110fe2f5cb9f0e21e40c5 +size 2293 diff --git a/data/minecraft/structure/village/desert/houses/desert_small_house_7.nbt b/data/minecraft/structure/village/desert/houses/desert_small_house_7.nbt index 17581717..1a5b9a4b 100644 --- a/data/minecraft/structure/village/desert/houses/desert_small_house_7.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_small_house_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c079f9abccc01736346655ef5dd2fad009cc0734e0fa2314494785de3390862e -size 1598 +oid sha256:52c096e1e1a44358fda2bb57f991f19d29bfdf0d4ba72f2ac005ae418f363aaf +size 1600 diff --git a/data/minecraft/structure/village/desert/houses/desert_small_house_8.nbt b/data/minecraft/structure/village/desert/houses/desert_small_house_8.nbt index ef0ea238..b7dfda91 100644 --- a/data/minecraft/structure/village/desert/houses/desert_small_house_8.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_small_house_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ed3887e920ae8dc4e851617147d7322c0af89309b9f6b1e444b85668096adfe8 -size 1025 +oid sha256:970fd097bb83ad420538536f8e85ab60e0991e76bdcf7ae72984aaf772e32960 +size 1026 diff --git a/data/minecraft/structure/village/desert/houses/desert_tannery_1.nbt b/data/minecraft/structure/village/desert/houses/desert_tannery_1.nbt index b5012f6f..dd71d769 100644 --- a/data/minecraft/structure/village/desert/houses/desert_tannery_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_tannery_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e4445307c68d4b819b7d2dfce2e4f8824af079186a8c795f15533b5bf5e1e3b0 -size 1835 +oid sha256:171d0d430edc28a4de440a80165e8dd0c2eb59c188b1ee5b36f9c6752f624ac2 +size 1836 diff --git a/data/minecraft/structure/village/desert/houses/desert_temple_1.nbt b/data/minecraft/structure/village/desert/houses/desert_temple_1.nbt index 3b490836..c036fc9a 100644 --- a/data/minecraft/structure/village/desert/houses/desert_temple_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_temple_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:57bf2772ed6920a25b10de8754d8ae8486920488f3241d1db8e92b7f673ec0a8 -size 2998 +oid sha256:c74bcbe20a95003a240bfc8e7d669fcc0df05a24c62792a2cd25db14ae0d6db3 +size 2999 diff --git a/data/minecraft/structure/village/desert/houses/desert_temple_2.nbt b/data/minecraft/structure/village/desert/houses/desert_temple_2.nbt index 275f1485..c6ecb8a5 100644 --- a/data/minecraft/structure/village/desert/houses/desert_temple_2.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_temple_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bdb453dc3939bc50540aa412d252abacc772d85269c35ffa53e24e83f8fefbbf -size 2879 +oid sha256:9b6065d5206ce94b7ee2479e999f9f9ab31189de6c28c337d2c7dbe44dfa2da6 +size 2880 diff --git a/data/minecraft/structure/village/desert/houses/desert_tool_smith_1.nbt b/data/minecraft/structure/village/desert/houses/desert_tool_smith_1.nbt index 7a7842db..24823184 100644 --- a/data/minecraft/structure/village/desert/houses/desert_tool_smith_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_tool_smith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3eeb18ee915b7c42f891de7b7bc0867716dbfef3e488dd2c8e6842702ef36a51 +oid sha256:be7d27a72f616c585b7622c498db8aa773524a909839f5ee99a38f1020bc27e3 size 2962 diff --git a/data/minecraft/structure/village/desert/houses/desert_weaponsmith_1.nbt b/data/minecraft/structure/village/desert/houses/desert_weaponsmith_1.nbt index 027048be..c7d0d4b5 100644 --- a/data/minecraft/structure/village/desert/houses/desert_weaponsmith_1.nbt +++ b/data/minecraft/structure/village/desert/houses/desert_weaponsmith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:271c31d56e121942accda951625c57692114a55418701aa2c1343c0d72d1bd22 -size 2080 +oid sha256:e063f39e481c4625252eaee886db447fddb368fe5cac430e25ea78f11534ebd7 +size 2083 diff --git a/data/minecraft/structure/village/desert/streets/corner_01.nbt b/data/minecraft/structure/village/desert/streets/corner_01.nbt index 8c66e54d..0997cb33 100644 --- a/data/minecraft/structure/village/desert/streets/corner_01.nbt +++ b/data/minecraft/structure/village/desert/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dcedd78852d4f87a1fdc67fd647ba2aafc6d7e53bdd48cb5b9cc54f7f5d62393 -size 748 +oid sha256:837bf606c8e99c2e9c622c8637ade74e6637e59efa3e85abd50fa657342867c0 +size 749 diff --git a/data/minecraft/structure/village/desert/streets/corner_02.nbt b/data/minecraft/structure/village/desert/streets/corner_02.nbt index 2e60433a..d2177490 100644 --- a/data/minecraft/structure/village/desert/streets/corner_02.nbt +++ b/data/minecraft/structure/village/desert/streets/corner_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:04edb47a9649dc10176ebeb484699ed0100ed94f6c930d266a01715cedd27557 -size 468 +oid sha256:46edb1633bf2a1033c399cdf89a49a1e9a1cc319b2c895007978ea964d1ba258 +size 469 diff --git a/data/minecraft/structure/village/desert/streets/crossroad_01.nbt b/data/minecraft/structure/village/desert/streets/crossroad_01.nbt index 16ca28a7..fc4231df 100644 --- a/data/minecraft/structure/village/desert/streets/crossroad_01.nbt +++ b/data/minecraft/structure/village/desert/streets/crossroad_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:92191bc4f557ba934abfae3589f680466744a1b73e6f74dc6b14185dc9b4597a -size 1272 +oid sha256:9b9b001ee7f336dafdebe250f60e618e26260d5572477a8292432de0fe9daf5f +size 1273 diff --git a/data/minecraft/structure/village/desert/streets/crossroad_02.nbt b/data/minecraft/structure/village/desert/streets/crossroad_02.nbt index 3f92770b..c5f943a6 100644 --- a/data/minecraft/structure/village/desert/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/desert/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3f19992b8b6eabd2ce9ceba2b59781dbd15d98bb493fb19dc74f56fc2b77b70c -size 781 +oid sha256:65a5874ddc4058cffea8ab835e9d8a3d5fa832c0b62321a4316e34d1259edf4c +size 783 diff --git a/data/minecraft/structure/village/desert/streets/crossroad_03.nbt b/data/minecraft/structure/village/desert/streets/crossroad_03.nbt index df83ce7c..6512b8fa 100644 --- a/data/minecraft/structure/village/desert/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/desert/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3b6ab7070307b40b3855099c6fa573d4f56e8b0d2ced7ea04b66b4f18b062332 -size 443 +oid sha256:87bfaf45889f92b4e34068125ca01c78a5e46c7565785601f3079e13ab55f6b6 +size 444 diff --git a/data/minecraft/structure/village/desert/streets/square_01.nbt b/data/minecraft/structure/village/desert/streets/square_01.nbt index 3730353f..4c6f973a 100644 --- a/data/minecraft/structure/village/desert/streets/square_01.nbt +++ b/data/minecraft/structure/village/desert/streets/square_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:308a96df89c863e195252d45fb4caa9381a661bae60c7efadbd668cfed7d0faf -size 1581 +oid sha256:68d22f544cfa719be51c39069619030fadf3e20100c1b103d089d6756c0d8557 +size 1582 diff --git a/data/minecraft/structure/village/desert/streets/square_02.nbt b/data/minecraft/structure/village/desert/streets/square_02.nbt index a4a36ba6..94ad560d 100644 --- a/data/minecraft/structure/village/desert/streets/square_02.nbt +++ b/data/minecraft/structure/village/desert/streets/square_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fe2e1fd017cb64b4bd612548b98410e1ddc31dfb84115459a7a9460afa4e2e45 -size 1310 +oid sha256:4e7d8e99d3d12d0bb34a5a7916dc39f25ddf4db27806942794366bbebddaa942 +size 1311 diff --git a/data/minecraft/structure/village/desert/streets/straight_01.nbt b/data/minecraft/structure/village/desert/streets/straight_01.nbt index 06dc32b3..ffb39a41 100644 --- a/data/minecraft/structure/village/desert/streets/straight_01.nbt +++ b/data/minecraft/structure/village/desert/streets/straight_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:34b5006ef931a38f1f3cc7f48f20a59d169684781b2ea39a7e5ebc3f956a009f -size 984 +oid sha256:e2db72d1eeb1e2ea7021068592450cc215ca2b9229a420b01474ab4239049504 +size 985 diff --git a/data/minecraft/structure/village/desert/streets/straight_02.nbt b/data/minecraft/structure/village/desert/streets/straight_02.nbt index 0f3740f3..dafc849c 100644 --- a/data/minecraft/structure/village/desert/streets/straight_02.nbt +++ b/data/minecraft/structure/village/desert/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:84bfbaa3f005bf5dbc678b48aaa48c8a9cd144eb51d0bf5bc88ca99c11b5ffd7 -size 1229 +oid sha256:53efae7fead90ea3593197a4647b59aee5fd3eb11a456eb503303898681e5011 +size 1230 diff --git a/data/minecraft/structure/village/desert/streets/straight_03.nbt b/data/minecraft/structure/village/desert/streets/straight_03.nbt index 1ea72cc8..46ab33be 100644 --- a/data/minecraft/structure/village/desert/streets/straight_03.nbt +++ b/data/minecraft/structure/village/desert/streets/straight_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3bcbbc318215d39c3435eb793c3f88c7a80a2ed46ca6e87da9d183289adfeb87 -size 322 +oid sha256:e8c706ee2d7d455d712f128ea1ab51a50f1239191c8b0d45f80d0baa22004bb6 +size 323 diff --git a/data/minecraft/structure/village/desert/streets/turn_01.nbt b/data/minecraft/structure/village/desert/streets/turn_01.nbt index f54bc1ec..c338914b 100644 --- a/data/minecraft/structure/village/desert/streets/turn_01.nbt +++ b/data/minecraft/structure/village/desert/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e0075c1dec330d5f3d7cd9fe3fff6cff3a51622c05c1f6c6733685b935dce877 -size 400 +oid sha256:6cfda88878719ddae202035d2fed1be02725601e1215e66fa98532c33174c87d +size 401 diff --git a/data/minecraft/structure/village/desert/terminators/terminator_01.nbt b/data/minecraft/structure/village/desert/terminators/terminator_01.nbt index 33bfabe3..bef5b138 100644 --- a/data/minecraft/structure/village/desert/terminators/terminator_01.nbt +++ b/data/minecraft/structure/village/desert/terminators/terminator_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9ea01855094d2f04e2595236554e2e2d2541d0f6305d74752b135245cd6ead0d -size 292 +oid sha256:b901e8e903be47348848379bc96479aaa185cfb054bb92bf0996e13011d7dcda +size 294 diff --git a/data/minecraft/structure/village/desert/terminators/terminator_02.nbt b/data/minecraft/structure/village/desert/terminators/terminator_02.nbt index e59ffbdd..d8f5b263 100644 --- a/data/minecraft/structure/village/desert/terminators/terminator_02.nbt +++ b/data/minecraft/structure/village/desert/terminators/terminator_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a7b5e119f808ce1f568f93abb98a88fd0fe678b221791090e6e764d8b47d30df -size 371 +oid sha256:c671ace00ad9cf4916d1e5cf914df70efede0f3f0d80d1d19b2f2aef87d5cdba +size 373 diff --git a/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_1.nbt b/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_1.nbt index b5d56138..3199676c 100644 --- a/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_1.nbt +++ b/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f1ed69575d2048b3bce5a2ccc7f304e4f0bea6406d4c92399fda7c7535c15cc6 -size 1014 +oid sha256:2c052b42f6d1182968e60656be3c5278f97334f60d365e0cfc8c35aefd815b62 +size 1016 diff --git a/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_2.nbt b/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_2.nbt index b9fc1090..08ac2dba 100644 --- a/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_2.nbt +++ b/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:472e793bf2757afa0b278bf62b21bcfdcb61a7317db63071c99df7210f636f45 -size 1834 +oid sha256:37ad005126d1996870fcaf30e4faac6e6134c843059c1c1e66b173316d8249d0 +size 1835 diff --git a/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_3.nbt b/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_3.nbt index e6bee167..142d8aa2 100644 --- a/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_3.nbt +++ b/data/minecraft/structure/village/desert/town_centers/desert_meeting_point_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d85deeb0c3da1cd2bd36c8db343449d2d720ca95d323062e59df383e63f5d9b7 -size 1899 +oid sha256:42212b9a6dce46218458e520327084be91871bfa2772512302cb1775d67ddef0 +size 1900 diff --git a/data/minecraft/structure/village/desert/villagers/baby.nbt b/data/minecraft/structure/village/desert/villagers/baby.nbt index cf77e58c..87189bff 100644 --- a/data/minecraft/structure/village/desert/villagers/baby.nbt +++ b/data/minecraft/structure/village/desert/villagers/baby.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9c8916ea096657b4caeaa840feb2e62ab6daaf7c2aca19610848dc352adf2ef6 -size 750 +oid sha256:5e7e145695d2b5b60e33466712807b76701f60e435147ef3509259cc1c47f069 +size 719 diff --git a/data/minecraft/structure/village/desert/villagers/nitwit.nbt b/data/minecraft/structure/village/desert/villagers/nitwit.nbt index 7ac1e592..c34d04b9 100644 --- a/data/minecraft/structure/village/desert/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/desert/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5d8caaf3fed631531516dbeef760c54475bce0ccff023bd086790b1a0a2318b1 -size 750 +oid sha256:744215dabc436a79a04feb450fa5bb8cd2043590fd268e57b85d905794299d94 +size 716 diff --git a/data/minecraft/structure/village/desert/villagers/unemployed.nbt b/data/minecraft/structure/village/desert/villagers/unemployed.nbt index c48931eb..9e1fb669 100644 --- a/data/minecraft/structure/village/desert/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/desert/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0f6f611115a1001393dd974b8d820bdca0779c11d0b5b9bd0de4a228045d27a9 -size 750 +oid sha256:151c9af9cfcfdb60d046c532f7db86ad5f88d624baafc5c2c954a3f77bb92d63 +size 715 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_medium_house_1.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_medium_house_1.nbt index 9c3f1c92..da8a3529 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_medium_house_1.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:89d9fa48c2ec1e05ba23af99f98ee66bc27bdafd96502351c7ffee83d125f878 -size 1448 +oid sha256:a57e2878770bf47bd8172c4ec852d21bd05c472757adf3aab3b227912d03541e +size 1449 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_medium_house_2.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_medium_house_2.nbt index 89977c85..20a07556 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_medium_house_2.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1f7c16d6e2826f4f067d3298465ba8f21fbc6d4fed18ee25425c10e7da2ce0de -size 2844 +oid sha256:cd5b47619ab6ec1426602ffedc32387890983ae255db35a2f93d92b95ee95978 +size 2846 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_1.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_1.nbt index 88df046e..c6c53cf0 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_1.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7742066b3e1d2ea4831a448f2f2b30b8990a5e792e3e7dd720801a35caaa08b7 -size 1184 +oid sha256:451b0518cffd9fc672db08eadf105109d6d93ddba3159e5f393f33ad78a4c7f2 +size 1186 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_2.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_2.nbt index 3d4ba52b..a3f310df 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_2.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a8a31f110d3d3c1c3d51b31c0019c82e13837d09d3904b10b3e3fc5c55bce21b -size 1318 +oid sha256:a46e96daaa634ded3bfd9cf455cc06d108153e762bd0073ae18c39b4c636bb91 +size 1319 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_3.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_3.nbt index c3dbc5bf..0d41cdc8 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_3.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4944fc81e52dbd7d7e871a97ba36eba28ad28f885fa2240b00b352e61a63304f -size 1137 +oid sha256:a4df91e7cf766ca21e9b9cee3209c4ec3fc2131e255a38ac09c74b6ff30592fe +size 1138 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_4.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_4.nbt index 338ae238..04b02435 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_4.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:83c4df47bb4718da556fbfb958e924451c6cc6f15bf4a2622f2ae88008384af7 -size 1060 +oid sha256:516defc96b9af56866a346c3f9744c54e8c806ce37afafda9d88067a87078de0 +size 1062 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_5.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_5.nbt index 2ef2d940..44d4284e 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_5.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d2a41e25447848546521ab0cd0fdc470f98858fdd370e529f383065ac554c1ba -size 1113 +oid sha256:67e7c4bf5077a80bcb550f6c2652bec88c28bf4b593812f4de865a1e39ef7b6d +size 1114 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_6.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_6.nbt index 292fda60..2f4b99c2 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_6.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8a3a7786d1d376c615056fa98f825613e83d0d9c57ea6fb0f51967334bc41d28 -size 1963 +oid sha256:51fa8a4f8e92459d3c4db67df899b21951c4ae7c2cf0945d3b81ec6191724d9b +size 1964 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_7.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_7.nbt index e32888a0..69f08870 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_7.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:441309a508ce30209d395175202de0ebc88522a91fa913b39534e90cf124a916 -size 1605 +oid sha256:430789e2dac163d5d6b5f267fddb34cb1d3041f1e10b7e030d5d62218b6bcb03 +size 1606 diff --git a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_8.nbt b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_8.nbt index e5eb46c2..75f739c9 100644 --- a/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_8.nbt +++ b/data/minecraft/structure/village/desert/zombie/houses/desert_small_house_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1ef6e2fe7a0ae5052e9ab52fef69bc03720137e695a9ce6358b00a8279cba95d -size 1030 +oid sha256:197b14304c3592cb0396725d65025036461d999fed8a0215f6b25aaa845ce8e7 +size 1031 diff --git a/data/minecraft/structure/village/desert/zombie/streets/corner_01.nbt b/data/minecraft/structure/village/desert/zombie/streets/corner_01.nbt index e653ec8b..10348427 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/corner_01.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5c532e2f06d0cb64ac11de524472bc9c2d252e274ff40ae1951ba33f6a84a485 -size 753 +oid sha256:e00bdea6fcbd117502fb810b7bd9fff5b9bed1053e1dc231c019b81299016f45 +size 754 diff --git a/data/minecraft/structure/village/desert/zombie/streets/corner_02.nbt b/data/minecraft/structure/village/desert/zombie/streets/corner_02.nbt index d7bf602e..5f47fd75 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/corner_02.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/corner_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cbf664d493d2261cd29393468d7505723d3b439968a75f60a3407d789d6a6fed -size 471 +oid sha256:40345e14ffadd24b714dae15167c90bfc379025187dec1ed537c0a2b3214e883 +size 472 diff --git a/data/minecraft/structure/village/desert/zombie/streets/crossroad_01.nbt b/data/minecraft/structure/village/desert/zombie/streets/crossroad_01.nbt index dcde6e49..8fdcadd7 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/crossroad_01.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/crossroad_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fbf6d0f9c5a3363cc776b2919e93fe4f7e6c936d472ea9b4e156bbead0c1e1c9 -size 1278 +oid sha256:e3ebc74e4cb6fad9e4c3ba423f3850a057e5cdbdf8b3d9960d416abd5742c821 +size 1279 diff --git a/data/minecraft/structure/village/desert/zombie/streets/crossroad_02.nbt b/data/minecraft/structure/village/desert/zombie/streets/crossroad_02.nbt index e5f8e32c..89fc84a8 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:eb4054c483f15f7ebb0ca499e0e16c3797fab7252aa8bd52758ad77577fe5a56 -size 785 +oid sha256:cc4e35f380fa77d90e6942a4dbc3225c801a1679daaceeacd2bd6e53e1351846 +size 787 diff --git a/data/minecraft/structure/village/desert/zombie/streets/crossroad_03.nbt b/data/minecraft/structure/village/desert/zombie/streets/crossroad_03.nbt index 8a4960dd..5786e3b9 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0e504f920826c33ac4c7172f498d2c08ee90fa1f42b223bc908071f84026f03f -size 448 +oid sha256:11495ec71f7352173fa9a561cd80f60a9cee9888326f9e0a1e3802d17d0457f2 +size 449 diff --git a/data/minecraft/structure/village/desert/zombie/streets/square_01.nbt b/data/minecraft/structure/village/desert/zombie/streets/square_01.nbt index 0fe82c32..0a4b0859 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/square_01.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/square_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f549fee85a4d17ddfd4cc52161ac6234bd29eba11aae3f436e98a11b0de5c410 +oid sha256:a660213749ace646ecefa8c53fa696f039fa311c1510a4933d1136d08aab62e8 size 1587 diff --git a/data/minecraft/structure/village/desert/zombie/streets/square_02.nbt b/data/minecraft/structure/village/desert/zombie/streets/square_02.nbt index f41420b9..19958ac4 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/square_02.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/square_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0f6e8bb6d608fde29a4069406ef5ef9123c3e7d8537ae2cc6bdfe4c7fff969d1 -size 1314 +oid sha256:d8a5fa7af1b57e15e20c731f58a44cb356378b09160284db859198ad68a30b36 +size 1315 diff --git a/data/minecraft/structure/village/desert/zombie/streets/straight_01.nbt b/data/minecraft/structure/village/desert/zombie/streets/straight_01.nbt index c39facca..513e4623 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/straight_01.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/straight_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dbec838fbe9c0704f1aec9f18a5f75242c426e330d55dc3d6e78fec4a502162e -size 988 +oid sha256:86e9a2abf0fddfd6bb8742ff748534a0c979bce4ad61f47b4d326ceef7ecb02a +size 989 diff --git a/data/minecraft/structure/village/desert/zombie/streets/straight_02.nbt b/data/minecraft/structure/village/desert/zombie/streets/straight_02.nbt index 77756ede..4afa167f 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/straight_02.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a061cfc2fed86e1953f836faf69da1a04a641787011ac4aa72eecdc42dcd320a -size 1233 +oid sha256:818fe0948123ffd5e6abe0c64e4a3a18edbb0edcbba110093904ab9e362217fe +size 1234 diff --git a/data/minecraft/structure/village/desert/zombie/streets/straight_03.nbt b/data/minecraft/structure/village/desert/zombie/streets/straight_03.nbt index f958ebdd..1e584a9b 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/straight_03.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/straight_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d4a68c54591abeee11096848bc169ff897d18b10e71d60436747e60c8e77d57f -size 327 +oid sha256:14527664fc3d5176967fa396c1578067609fac80f3414739e1c0c6e691d8a9ef +size 328 diff --git a/data/minecraft/structure/village/desert/zombie/streets/turn_01.nbt b/data/minecraft/structure/village/desert/zombie/streets/turn_01.nbt index 5e8d78cc..ffe7bd61 100644 --- a/data/minecraft/structure/village/desert/zombie/streets/turn_01.nbt +++ b/data/minecraft/structure/village/desert/zombie/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f14211fd8dff66de834ca49c70c463ed4f9c1546442f36ebeb053c195dd0e57a -size 404 +oid sha256:499c5b90be40a3d2a360a87df7b436f7ccc2a5dda82ae2d0f48374f05b511ec0 +size 406 diff --git a/data/minecraft/structure/village/desert/zombie/terminators/terminator_02.nbt b/data/minecraft/structure/village/desert/zombie/terminators/terminator_02.nbt index d93a8e98..3fdf913c 100644 --- a/data/minecraft/structure/village/desert/zombie/terminators/terminator_02.nbt +++ b/data/minecraft/structure/village/desert/zombie/terminators/terminator_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:32754ed75c522e09e359a01ec5800addcffe511fab87456d00c2be0c65163d1c -size 376 +oid sha256:1a730d3aeab2b25dee09cd9e5738eabdb4f57d0009a46e8053e4f605b7075878 +size 377 diff --git a/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_1.nbt b/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_1.nbt index dcc1e13a..a7e9e85d 100644 --- a/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_1.nbt +++ b/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c9135de41f7c763cab82eb79c4216746dd93b976ca08e7dc42e9f8f8add658b6 -size 1127 +oid sha256:61cca96e22c7b6ececf5b8d4f700b08454fdcd74cb21141c09bfe65b0a537a97 +size 1128 diff --git a/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_2.nbt b/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_2.nbt index 28c96c2e..c59aa030 100644 --- a/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_2.nbt +++ b/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aca3693cbd1ee86bdd77d96386bf8a2acb6f2340b5cf54052913c25a0f7dda72 -size 2311 +oid sha256:435718a267d404f886b4f3eda5fb2b8732f5e38d5cc9b84443af6a4a36926176 +size 2312 diff --git a/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_3.nbt b/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_3.nbt index de467e33..87a1f558 100644 --- a/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_3.nbt +++ b/data/minecraft/structure/village/desert/zombie/town_centers/desert_meeting_point_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6b33ca574d43b15e1b99bc1f40d6e2d27dbb990bcd7fa1d00d9c782b495907ce -size 4579 +oid sha256:f71f0c912160a03a4b70cc8b6826d2e61b91393f2d9aff15cfe4617ce614af9b +size 4580 diff --git a/data/minecraft/structure/village/desert/zombie/villagers/nitwit.nbt b/data/minecraft/structure/village/desert/zombie/villagers/nitwit.nbt index 87e7ab4e..7c5889f5 100644 --- a/data/minecraft/structure/village/desert/zombie/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/desert/zombie/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dd0b9f99a059b5e263b78eaa8ff7431824ca021c0c01b15c3177de3b8bec9802 -size 755 +oid sha256:547274e462cc985437a37a99c4106d4c799a3aaf709c2bf0b8e6a5975c3f69d4 +size 722 diff --git a/data/minecraft/structure/village/desert/zombie/villagers/unemployed.nbt b/data/minecraft/structure/village/desert/zombie/villagers/unemployed.nbt index b9c9718c..1add0fd6 100644 --- a/data/minecraft/structure/village/desert/zombie/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/desert/zombie/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bdc73290673630044c4850780f763a88b303a460f81e70f64f71ad2144c7f984 -size 755 +oid sha256:9b9caa22782c0643793fe1618f9593f65751d9dd4305e62d80decf4ba20d126a +size 721 diff --git a/data/minecraft/structure/village/plains/houses/plains_accessory_1.nbt b/data/minecraft/structure/village/plains/houses/plains_accessory_1.nbt index a38b9c8d..49b5e91e 100644 --- a/data/minecraft/structure/village/plains/houses/plains_accessory_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_accessory_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9a1e0b34dc1baa678756723530f9c31437b1ebfa7f5471621cd314da9fbc48f7 -size 522 +oid sha256:4a9265c57a404667a629331403dc3a3bab5ee9febb26397ea8c7ba226489d988 +size 523 diff --git a/data/minecraft/structure/village/plains/houses/plains_animal_pen_1.nbt b/data/minecraft/structure/village/plains/houses/plains_animal_pen_1.nbt index 41940ab6..77e7c66c 100644 --- a/data/minecraft/structure/village/plains/houses/plains_animal_pen_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_animal_pen_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:72b8d74e2add718421767df9cf8a48ac9928940f7a152abd7c71e0b35c276aee -size 723 +oid sha256:c1314787141388101fe5eb17bbea71fef60ae26dd637210a46fb386792a0107e +size 726 diff --git a/data/minecraft/structure/village/plains/houses/plains_animal_pen_2.nbt b/data/minecraft/structure/village/plains/houses/plains_animal_pen_2.nbt index 6a256aef..a1d1e002 100644 --- a/data/minecraft/structure/village/plains/houses/plains_animal_pen_2.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_animal_pen_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3701734322a2fc573feb593390f86681557a861e745daa71456ab860479774b6 -size 1010 +oid sha256:775ca022cde2687a67ad46a504da89af9b7703db076e86a35249fcb3c952b1ff +size 1013 diff --git a/data/minecraft/structure/village/plains/houses/plains_animal_pen_3.nbt b/data/minecraft/structure/village/plains/houses/plains_animal_pen_3.nbt index 4fc6f595..ff21fe3f 100644 --- a/data/minecraft/structure/village/plains/houses/plains_animal_pen_3.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_animal_pen_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1101d828c0ffdaa6c2bef6e38fdb05b6d68fdbb281b8af56146a54ca5983cd42 -size 1352 +oid sha256:e84cc9ccfdb81546ca78999a80e6555827e41a4878758849b2148ca8351462d0 +size 1355 diff --git a/data/minecraft/structure/village/plains/houses/plains_armorer_house_1.nbt b/data/minecraft/structure/village/plains/houses/plains_armorer_house_1.nbt index dec7a78d..abcb0de8 100644 --- a/data/minecraft/structure/village/plains/houses/plains_armorer_house_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_armorer_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2c1371d9122e7160c93aefce03fe3c586dbe5ad61099cc61a7574c3f0c1b388b -size 2629 +oid sha256:2fb1fa11e280daa7fb58b9d28b906ad947b7ce8ae5defb269277b750fc78e778 +size 2634 diff --git a/data/minecraft/structure/village/plains/houses/plains_big_house_1.nbt b/data/minecraft/structure/village/plains/houses/plains_big_house_1.nbt index ec99eb11..7e917e9d 100644 --- a/data/minecraft/structure/village/plains/houses/plains_big_house_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_big_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a0a7b429353a131d743115fa2a23bc0c1087ca0ac3efb6a7e2c85aea8938477a -size 3262 +oid sha256:ec0cb0671dcb95ad9d2635db7a9d5dc87d3e8da89ea260fd40200720c855e8a3 +size 3264 diff --git a/data/minecraft/structure/village/plains/houses/plains_butcher_shop_1.nbt b/data/minecraft/structure/village/plains/houses/plains_butcher_shop_1.nbt index 81f7d501..279b1e94 100644 --- a/data/minecraft/structure/village/plains/houses/plains_butcher_shop_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_butcher_shop_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c3d7d27f6553d999de09753a1278d114a772a95f212928005533d75c21129ac7 -size 4181 +oid sha256:1d41f31ae1f207b400c31afa5764f48833e496bf672750e4a96b93bf33395fc6 +size 4183 diff --git a/data/minecraft/structure/village/plains/houses/plains_butcher_shop_2.nbt b/data/minecraft/structure/village/plains/houses/plains_butcher_shop_2.nbt index 749c4f7e..50cbb0e3 100644 --- a/data/minecraft/structure/village/plains/houses/plains_butcher_shop_2.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_butcher_shop_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:627f1717ba024b245722202e8bb45700e171331ca9385b5ce511c86981429141 -size 4579 +oid sha256:ce6bc556f4b0b98b802c37ea5274c4ace0c5093b9cda3c69d629ab7ac226d5cb +size 4580 diff --git a/data/minecraft/structure/village/plains/houses/plains_cartographer_1.nbt b/data/minecraft/structure/village/plains/houses/plains_cartographer_1.nbt index 434fbb0c..2ebbcff9 100644 --- a/data/minecraft/structure/village/plains/houses/plains_cartographer_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_cartographer_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9bc7554d54c84fd84116cb91501bfe9327c8c6f1d5e06a072ea9f0ffd1c50c02 -size 2392 +oid sha256:ff2a30edeaca1f27559daa21f64e9bd25d7143af0446254737a86cb610cfb9b9 +size 2393 diff --git a/data/minecraft/structure/village/plains/houses/plains_fisher_cottage_1.nbt b/data/minecraft/structure/village/plains/houses/plains_fisher_cottage_1.nbt index b0273d59..537524ea 100644 --- a/data/minecraft/structure/village/plains/houses/plains_fisher_cottage_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_fisher_cottage_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4ac0a62750f75e3dafc9b73ca3f674bfd980929c37523d3e26f3fe5eed62d5dd -size 3526 +oid sha256:c487fbbeee78ff20083a47c88ee40a22d49ae27df22dcfd581cec5b291bf9047 +size 3527 diff --git a/data/minecraft/structure/village/plains/houses/plains_fletcher_house_1.nbt b/data/minecraft/structure/village/plains/houses/plains_fletcher_house_1.nbt index 83350b32..b39ef428 100644 --- a/data/minecraft/structure/village/plains/houses/plains_fletcher_house_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_fletcher_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:64bb1c9b164c1c268af3f15a26bee1ba92ec8c4d75a84ba2f1eb370ea046e54b -size 2913 +oid sha256:7373de513aeb0cca715f7075fbe5d82b7730c860cd82e5f77af327ebc25df7c7 +size 2914 diff --git a/data/minecraft/structure/village/plains/houses/plains_large_farm_1.nbt b/data/minecraft/structure/village/plains/houses/plains_large_farm_1.nbt index 3a64e98d..64dd723b 100644 --- a/data/minecraft/structure/village/plains/houses/plains_large_farm_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_large_farm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:397c9cd0547d0cbd7c8a6e295f35eb76e9028fe048e538aa5fdb5d9d30e75014 -size 1156 +oid sha256:8e76392b14c91133da580f66111a740e1f6f8c353add4b1c1907f5558a963012 +size 1157 diff --git a/data/minecraft/structure/village/plains/houses/plains_library_1.nbt b/data/minecraft/structure/village/plains/houses/plains_library_1.nbt index ba4cdf50..b2dc3bc0 100644 --- a/data/minecraft/structure/village/plains/houses/plains_library_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_library_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c4f8c64ed7656bc75f49a8ab250042fe91458968e53654b5f9d5299ee203d7e5 -size 6512 +oid sha256:d24dace3284d40e5b299efbbf47740e109b792b1e23b7266b26ec19f20eec3da +size 6515 diff --git a/data/minecraft/structure/village/plains/houses/plains_library_2.nbt b/data/minecraft/structure/village/plains/houses/plains_library_2.nbt index 4ba53724..3afe527e 100644 --- a/data/minecraft/structure/village/plains/houses/plains_library_2.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_library_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ddeb33e32763e39ca947283340f99df5bea953a42ae0e3561b95610d3463f482 -size 2916 +oid sha256:37be8af236b2558613aa1f80841c88c4f66190c32d391d74f77d889b1ebeb381 +size 2917 diff --git a/data/minecraft/structure/village/plains/houses/plains_masons_house_1.nbt b/data/minecraft/structure/village/plains/houses/plains_masons_house_1.nbt index 7b38f293..211b1f41 100644 --- a/data/minecraft/structure/village/plains/houses/plains_masons_house_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_masons_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4280152ba2cd583876b626a78acef8a5a415792d8f28e0d4cc99569561de0146 -size 2294 +oid sha256:70a6d88887179d4f6527554b4f1118ab4c32b2fe76d41e11a34198797d255e45 +size 2297 diff --git a/data/minecraft/structure/village/plains/houses/plains_medium_house_1.nbt b/data/minecraft/structure/village/plains/houses/plains_medium_house_1.nbt index 168200d7..7864a9b1 100644 --- a/data/minecraft/structure/village/plains/houses/plains_medium_house_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:548ceb4a46a3ff6b2f1332959f2e8dd65aa2a66f5876e8ccda815790604137f2 -size 4239 +oid sha256:8e64f7c396ac944543b20a69b7264720d5a6e9fa8818e4f490a565a46f30d94e +size 4241 diff --git a/data/minecraft/structure/village/plains/houses/plains_medium_house_2.nbt b/data/minecraft/structure/village/plains/houses/plains_medium_house_2.nbt index 12f5c64b..8358847d 100644 --- a/data/minecraft/structure/village/plains/houses/plains_medium_house_2.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d465294d672b5a7a148e81bf3c18aa07511ea365e00edd3fe0589713baaa7007 -size 2541 +oid sha256:7317a11f3741f69d62e3d514a80d223f5df0c28d8fc4236b325e03a4c7279f04 +size 2543 diff --git a/data/minecraft/structure/village/plains/houses/plains_meeting_point_4.nbt b/data/minecraft/structure/village/plains/houses/plains_meeting_point_4.nbt index 788f1cb9..b4c12c6d 100644 --- a/data/minecraft/structure/village/plains/houses/plains_meeting_point_4.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_meeting_point_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:436154301068240ab27dc5e46288aadd4320699272dd4ff3332379163498b64b -size 3905 +oid sha256:3b9f8431562cb2e2810f214aa8be88d8ff8ed68375ba645a4beae67e4b78093a +size 3907 diff --git a/data/minecraft/structure/village/plains/houses/plains_meeting_point_5.nbt b/data/minecraft/structure/village/plains/houses/plains_meeting_point_5.nbt index 5dfe5d28..9846b734 100644 --- a/data/minecraft/structure/village/plains/houses/plains_meeting_point_5.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_meeting_point_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4731063ebf0d5e38128493b02a7307b3d85155f009fa1f0772fdbe19a11ac2cd -size 2651 +oid sha256:74caa113550ab07104e416d1bb279773154017d17296dc22e70f4b6c0dffc451 +size 2652 diff --git a/data/minecraft/structure/village/plains/houses/plains_shepherds_house_1.nbt b/data/minecraft/structure/village/plains/houses/plains_shepherds_house_1.nbt index 3d48e0cf..a5d7e964 100644 --- a/data/minecraft/structure/village/plains/houses/plains_shepherds_house_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_shepherds_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:45b79f644ef354f137b8b1fc65694e64b7f1157aa1d44b16d337310783936d37 -size 2914 +oid sha256:edef7883c9d55608bae7f5b69181cb07d36ef470187d3a537018746e0c817501 +size 2915 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_farm_1.nbt b/data/minecraft/structure/village/plains/houses/plains_small_farm_1.nbt index 5268183f..8655f738 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_farm_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_farm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:509f06534d015c6d3c40be85a7d8d16ebf3dc1c510ba79dc515b31f22ddd043b -size 772 +oid sha256:80fd42b91bd3e64f4a599c230214bb52e30f21ee3d1abe74dd76e9482dda236b +size 773 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_house_1.nbt b/data/minecraft/structure/village/plains/houses/plains_small_house_1.nbt index 0397e30f..c20a33ea 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_house_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:98f65e0cb0adc4648d362e93196b729ef318cbe198570f2ac92453a37001babb -size 1807 +oid sha256:124244c41977d5383b59805030d87ede3061070a15d31678d7f9660d8060733b +size 1809 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_house_2.nbt b/data/minecraft/structure/village/plains/houses/plains_small_house_2.nbt index 549673d6..f240d266 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_house_2.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f2fb78f7f7f1eefdacd67e57faed91f886b7885ae0f6b9fe90825aaf8ff1f21c -size 1698 +oid sha256:8e5e3a54e1a459bc95a48d789eaac11d584c8ebd5f72b3096dde512391702331 +size 1700 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_house_3.nbt b/data/minecraft/structure/village/plains/houses/plains_small_house_3.nbt index 6e6596d5..3a9e23a4 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_house_3.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:41865088221ced1a036ccf5c3fca9b891ec71aa5b31dc21978345448e9b19ed8 -size 1800 +oid sha256:86f9aedea24a4988633b25f91f6ef066f80033509ff3889b18162515df5967da +size 1803 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_house_4.nbt b/data/minecraft/structure/village/plains/houses/plains_small_house_4.nbt index 5ff74fda..26a2944b 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_house_4.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cf2bd83504e6687038f469a7e7c161efd3579faeb06aa41f79f64a9ac6d68725 -size 1724 +oid sha256:438edab2f0d94d30862d8ab3eeb1b3087d8298415dd4247032b610d57218f7e5 +size 1726 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_house_5.nbt b/data/minecraft/structure/village/plains/houses/plains_small_house_5.nbt index ff9f5d28..2b72c295 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_house_5.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e0ee16384502cca7ff190f2fb61e47bd572922ebb243e74a9d39e50dffa88146 -size 3489 +oid sha256:1b61a823f26aae487dcc57110788c4a0a06ba7fe77ede89b40ca0ab77844ebdc +size 3492 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_house_6.nbt b/data/minecraft/structure/village/plains/houses/plains_small_house_6.nbt index 1dcb2c0a..4869e9f5 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_house_6.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_house_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9b57d7950b56fa1f3165f9c06eacdf490c5826d21200164d9b0de46446c790d6 -size 1774 +oid sha256:e35b1b652f53395c54afb5a9a694de007e76165ab28d7ad6df094e3bf9f09c26 +size 1775 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_house_7.nbt b/data/minecraft/structure/village/plains/houses/plains_small_house_7.nbt index 613ced51..b11a728b 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_house_7.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_house_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dfc4d068179cf8604c1e0582632d8e6f69882a6ff4d24f23a1f982bb0bb0661d -size 2034 +oid sha256:115d28e8ed3b9e8aa9212b07a5e7f2b6e21cd4d455861671eafd9a5d4e4de326 +size 2036 diff --git a/data/minecraft/structure/village/plains/houses/plains_small_house_8.nbt b/data/minecraft/structure/village/plains/houses/plains_small_house_8.nbt index a7c1ff2a..648e4745 100644 --- a/data/minecraft/structure/village/plains/houses/plains_small_house_8.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_small_house_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:78a1891edddaf5d9a04119580babcfe7cd56145031b03f9f09915af6758701fa -size 2682 +oid sha256:7c77aa158397ca9b1aac2b9bcb54fd730858a841d245341aced5805bb0989742 +size 2684 diff --git a/data/minecraft/structure/village/plains/houses/plains_stable_1.nbt b/data/minecraft/structure/village/plains/houses/plains_stable_1.nbt index ded5df8a..43bb6e9d 100644 --- a/data/minecraft/structure/village/plains/houses/plains_stable_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_stable_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:46e6f5348de5ad9bb2955c9f48518b9a731b8bdea19e6ba36e0a22e8c89fa534 +oid sha256:823d1bd3f71cbdc72108caca853589270282288bcbf115339d83241e439fad4b size 3779 diff --git a/data/minecraft/structure/village/plains/houses/plains_stable_2.nbt b/data/minecraft/structure/village/plains/houses/plains_stable_2.nbt index a42c3ec5..b3fb3d63 100644 --- a/data/minecraft/structure/village/plains/houses/plains_stable_2.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_stable_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f252af9d4bacd56675bbafb1753a94a0e5484c1a01c53f05ecdc3e655e33711a -size 3071 +oid sha256:8507262d181174c43e8bc4f2dde1bec8de037dab8984cd7298d5804493dc6fb8 +size 3072 diff --git a/data/minecraft/structure/village/plains/houses/plains_tannery_1.nbt b/data/minecraft/structure/village/plains/houses/plains_tannery_1.nbt index f9192dd2..976d39d6 100644 --- a/data/minecraft/structure/village/plains/houses/plains_tannery_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_tannery_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0c76819d456b26f6b6952bd3702acffc7b2a344b33e2503df17cda4c846d313e -size 2502 +oid sha256:6ee26f3393e042277abab746f8bd23cbcf305654143f9dc56b5a4e57106853ec +size 2503 diff --git a/data/minecraft/structure/village/plains/houses/plains_temple_3.nbt b/data/minecraft/structure/village/plains/houses/plains_temple_3.nbt index 49642a28..eeac4ed2 100644 --- a/data/minecraft/structure/village/plains/houses/plains_temple_3.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_temple_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d6b8efb523ecca256974502e01c40cc863e02f44c7763787ffd7c9390d9bf3d6 -size 2491 +oid sha256:8bd46ae28b09a8075ec83ae4809e5ca48e5610c411f22293804397c36098b35e +size 2493 diff --git a/data/minecraft/structure/village/plains/houses/plains_temple_4.nbt b/data/minecraft/structure/village/plains/houses/plains_temple_4.nbt index 741502c8..06949e58 100644 --- a/data/minecraft/structure/village/plains/houses/plains_temple_4.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_temple_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e82889c37397583474d4c6857e06be3a1884913b9979fd962bf5d3af683c0c1 -size 3210 +oid sha256:55d7fdc0a3e58d16a0ccfa074bbe88304613a33ed5787a6e37647148a2a61505 +size 3211 diff --git a/data/minecraft/structure/village/plains/houses/plains_tool_smith_1.nbt b/data/minecraft/structure/village/plains/houses/plains_tool_smith_1.nbt index a0dd1f60..26ee4875 100644 --- a/data/minecraft/structure/village/plains/houses/plains_tool_smith_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_tool_smith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0679725cfdc2221cbdd6372ce930f109a2c59281d256bd507a69666214051763 -size 2674 +oid sha256:f70da9c35dfe01e1958ccb8466d1b4b195a46c6db542dc7e391724ca65d1463f +size 2675 diff --git a/data/minecraft/structure/village/plains/houses/plains_weaponsmith_1.nbt b/data/minecraft/structure/village/plains/houses/plains_weaponsmith_1.nbt index 925e2169..bc98bf73 100644 --- a/data/minecraft/structure/village/plains/houses/plains_weaponsmith_1.nbt +++ b/data/minecraft/structure/village/plains/houses/plains_weaponsmith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4d1019d3fc46a3ba3c0b235c322924669bdbf697c5e5b681fabb7415c9d45226 -size 3362 +oid sha256:eb27f257b0f663a206337cad5049ed284b836cbbcf549beea9a3b5892524861f +size 3365 diff --git a/data/minecraft/structure/village/plains/plains_lamp_1.nbt b/data/minecraft/structure/village/plains/plains_lamp_1.nbt index d25d6c72..b0b7468a 100644 --- a/data/minecraft/structure/village/plains/plains_lamp_1.nbt +++ b/data/minecraft/structure/village/plains/plains_lamp_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:488ffbcbd1de020fd0ccbce32f6aa9120684eeb6fc97248cc059da5863c19fd1 -size 468 +oid sha256:88abb93e379edf14580bc2b834d1584c0107d22541088ff9cddc191bcfc546ff +size 470 diff --git a/data/minecraft/structure/village/plains/streets/corner_01.nbt b/data/minecraft/structure/village/plains/streets/corner_01.nbt index 3a4ba1da..f26a3776 100644 --- a/data/minecraft/structure/village/plains/streets/corner_01.nbt +++ b/data/minecraft/structure/village/plains/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:90b9a33a5cc3828c43a53d5a2dfb41e5b8e0f5cf15e242555c3ef84f29a3f6a8 -size 1182 +oid sha256:a163001e656fbd5a7b20e598fca7fe8b327302ea177988988538977d1d8e8232 +size 1183 diff --git a/data/minecraft/structure/village/plains/streets/corner_02.nbt b/data/minecraft/structure/village/plains/streets/corner_02.nbt index 7eba4d9b..fbad771c 100644 --- a/data/minecraft/structure/village/plains/streets/corner_02.nbt +++ b/data/minecraft/structure/village/plains/streets/corner_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8c2825f9123f8194254b1b1d0200b202a83c551e03ec79445d1e0477ac7845bd -size 1108 +oid sha256:26f3aa773a1d399db8371ff0c0088574ce97c151d1477f95d905dbec3bc0e601 +size 1109 diff --git a/data/minecraft/structure/village/plains/streets/corner_03.nbt b/data/minecraft/structure/village/plains/streets/corner_03.nbt index e518a3d5..eb62d2cd 100644 --- a/data/minecraft/structure/village/plains/streets/corner_03.nbt +++ b/data/minecraft/structure/village/plains/streets/corner_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fc43b063c663e3bd537eae24d4295a03f6d231bae753f0f8314413cdc82715e1 -size 350 +oid sha256:0292975e4912a945a8f615fa077518f8e4d9fd9661de2152ef015ac38492d4ee +size 351 diff --git a/data/minecraft/structure/village/plains/streets/crossroad_01.nbt b/data/minecraft/structure/village/plains/streets/crossroad_01.nbt index 2cebbe7a..148a4fe5 100644 --- a/data/minecraft/structure/village/plains/streets/crossroad_01.nbt +++ b/data/minecraft/structure/village/plains/streets/crossroad_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3f7f3969e96b14315fb6a861d4bc8db5fe12ebefdb4299d447f14af08eb308b5 -size 1215 +oid sha256:106a1cc4efc79e9ff6a5fa6b98076ad2c9bb6a052faaa44ad5dd3429a59329a8 +size 1216 diff --git a/data/minecraft/structure/village/plains/streets/crossroad_02.nbt b/data/minecraft/structure/village/plains/streets/crossroad_02.nbt index 20c1bd65..9a6f3dd9 100644 --- a/data/minecraft/structure/village/plains/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/plains/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b4627f3dc7afe1678d17facd5458e4e2bf0f74fc19f8f3d52e6d38967872c283 -size 1160 +oid sha256:90d34cb88e2eb75aad05aa18f7242f1eed7c8397ab706d6078a5b7f472e6a88b +size 1161 diff --git a/data/minecraft/structure/village/plains/streets/crossroad_03.nbt b/data/minecraft/structure/village/plains/streets/crossroad_03.nbt index 5be51949..e4fb7eae 100644 --- a/data/minecraft/structure/village/plains/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/plains/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9f18b9cb4efa79d889a6a8450389a63dc376df3c1707a47e0e158f770211e37e -size 1203 +oid sha256:6262071b40e83a64238b2fad11b66f1f56cbce1577191c84d6c6813e185ea7cf +size 1204 diff --git a/data/minecraft/structure/village/plains/streets/crossroad_04.nbt b/data/minecraft/structure/village/plains/streets/crossroad_04.nbt index 353d5fc9..d3decc31 100644 --- a/data/minecraft/structure/village/plains/streets/crossroad_04.nbt +++ b/data/minecraft/structure/village/plains/streets/crossroad_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5b4d929b328c9b7cfa42d424860db506b3d22766cb3a0da699bc858092586324 -size 377 +oid sha256:d9c31a2c3b97b536b22756dd32cb675f3f8ed397cd3217789dbf1ad1871910bb +size 378 diff --git a/data/minecraft/structure/village/plains/streets/crossroad_05.nbt b/data/minecraft/structure/village/plains/streets/crossroad_05.nbt index 8264ac49..11e3098c 100644 --- a/data/minecraft/structure/village/plains/streets/crossroad_05.nbt +++ b/data/minecraft/structure/village/plains/streets/crossroad_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:df11c3993cb23e2c0996114bf913252780577d72124d393c4a93596ef20cf85c -size 409 +oid sha256:bc044a11b1dec490adf0328278ec8fd10a6f0b3d22fa949996c2b40a54e73823 +size 410 diff --git a/data/minecraft/structure/village/plains/streets/crossroad_06.nbt b/data/minecraft/structure/village/plains/streets/crossroad_06.nbt index bb2b3a30..1c0174c3 100644 --- a/data/minecraft/structure/village/plains/streets/crossroad_06.nbt +++ b/data/minecraft/structure/village/plains/streets/crossroad_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b9eba2672498e622e761bfb6bd4d09fe719cd65765762b565a42d0234be7c883 -size 470 +oid sha256:25d6fcd68a9c60e08382468e56ee8b091a6a2310f2c90d45f8d5af87ed467fc4 +size 471 diff --git a/data/minecraft/structure/village/plains/streets/straight_01.nbt b/data/minecraft/structure/village/plains/streets/straight_01.nbt index e7eda7a2..b93d81c5 100644 --- a/data/minecraft/structure/village/plains/streets/straight_01.nbt +++ b/data/minecraft/structure/village/plains/streets/straight_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2edfa2048087684b8abe72bad05c9a917601271a69a0568f764ba1e37f17efd0 -size 1131 +oid sha256:c33daa0cdd49d332fb1064e75480203ff48c26703bdfce0fa98447cc1a134a20 +size 1132 diff --git a/data/minecraft/structure/village/plains/streets/straight_02.nbt b/data/minecraft/structure/village/plains/streets/straight_02.nbt index fbbce8bc..11a1f8f2 100644 --- a/data/minecraft/structure/village/plains/streets/straight_02.nbt +++ b/data/minecraft/structure/village/plains/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9a2a3dc59fac7f40983960b485c0896f9b91c99ababb7ac07b3e68d64dba5599 -size 1084 +oid sha256:405d11d1dafc49bbf94a05593c3326948fe005f8529cdbc81a26adfb51f3cdd7 +size 1085 diff --git a/data/minecraft/structure/village/plains/streets/straight_03.nbt b/data/minecraft/structure/village/plains/streets/straight_03.nbt index d2ad63fa..459f26a6 100644 --- a/data/minecraft/structure/village/plains/streets/straight_03.nbt +++ b/data/minecraft/structure/village/plains/streets/straight_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fd6719905e07d2e7cbbf7c14a89dcea432b9f1204d26f92d613eb31ddf619472 -size 776 +oid sha256:e0080086bed1de2b10b0bbcf5572c2a214c0231e6ebc82e1dd79454115a38d1b +size 777 diff --git a/data/minecraft/structure/village/plains/streets/straight_04.nbt b/data/minecraft/structure/village/plains/streets/straight_04.nbt index a092d04a..034f2ac6 100644 --- a/data/minecraft/structure/village/plains/streets/straight_04.nbt +++ b/data/minecraft/structure/village/plains/streets/straight_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dccfad6ed79b8ea199de910e10a74289dd6ddb5c47f44ee56814db0ec56fce19 -size 633 +oid sha256:81e61b82027879f3b9bfd4393c19139c71a51e93a337c214f5ad401cbed36967 +size 634 diff --git a/data/minecraft/structure/village/plains/streets/straight_05.nbt b/data/minecraft/structure/village/plains/streets/straight_05.nbt index 788800f8..079f005a 100644 --- a/data/minecraft/structure/village/plains/streets/straight_05.nbt +++ b/data/minecraft/structure/village/plains/streets/straight_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:89b994c4e6b2af99626fac9a6457b43db25847fff7f25d1c390a2fce5aa85fed -size 1328 +oid sha256:955241b329b205c43cc2cca3dd261f1a85ce05514b6ce4916334dee6c8e5bb50 +size 1329 diff --git a/data/minecraft/structure/village/plains/streets/straight_06.nbt b/data/minecraft/structure/village/plains/streets/straight_06.nbt index 79c5b33e..975515e3 100644 --- a/data/minecraft/structure/village/plains/streets/straight_06.nbt +++ b/data/minecraft/structure/village/plains/streets/straight_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2ff971f3e548d3cb84e190535cc1f9d6f5561ac5ea71344424e71b5c23d6610b -size 1703 +oid sha256:c0d7e774f4a2985bb58c51c5be1f0b3f792afea65d87f52bd82d5c8a18b0ac1f +size 1704 diff --git a/data/minecraft/structure/village/plains/streets/turn_01.nbt b/data/minecraft/structure/village/plains/streets/turn_01.nbt index 30321470..4a5ee8e3 100644 --- a/data/minecraft/structure/village/plains/streets/turn_01.nbt +++ b/data/minecraft/structure/village/plains/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dc3c835f595084553b53a03e50d4c4c69d8fdbf72e74478dda6bc5048b413db3 -size 789 +oid sha256:d83132ed35a3034015ba9386485e73ed6195aa0b5a1b7752c108bf1c0a863456 +size 790 diff --git a/data/minecraft/structure/village/plains/terminators/terminator_01.nbt b/data/minecraft/structure/village/plains/terminators/terminator_01.nbt index e80c0d27..71933995 100644 --- a/data/minecraft/structure/village/plains/terminators/terminator_01.nbt +++ b/data/minecraft/structure/village/plains/terminators/terminator_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:37c86d361d8301c56bf17699c05db365eda672ddac04d963325299618e7666d8 -size 283 +oid sha256:34650b04439bb06b2e7871aa67e8282b345c24743c9bc80f6903e41cf3beedd2 +size 285 diff --git a/data/minecraft/structure/village/plains/terminators/terminator_02.nbt b/data/minecraft/structure/village/plains/terminators/terminator_02.nbt index 9000cf93..4ae9715b 100644 --- a/data/minecraft/structure/village/plains/terminators/terminator_02.nbt +++ b/data/minecraft/structure/village/plains/terminators/terminator_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2d0d359d47e4cf80b564029d8fd96fc382a108a38ce0e8570367b9d0888acbf7 -size 250 +oid sha256:1b878198ed08e576b6d01138d8a970734e86a667e801af4db8b38507f50265ed +size 251 diff --git a/data/minecraft/structure/village/plains/terminators/terminator_03.nbt b/data/minecraft/structure/village/plains/terminators/terminator_03.nbt index 0f49b7e5..ccb1d251 100644 --- a/data/minecraft/structure/village/plains/terminators/terminator_03.nbt +++ b/data/minecraft/structure/village/plains/terminators/terminator_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0db93090534a64d17309ad1f3a935ca8c3ece35b8508c5b862f89b3147a9f2d0 -size 291 +oid sha256:69c7d89264c0ad0a3b879b1d5b4286901a419450f4f7fef3f9cba40c77d96003 +size 292 diff --git a/data/minecraft/structure/village/plains/terminators/terminator_04.nbt b/data/minecraft/structure/village/plains/terminators/terminator_04.nbt index 5a3db358..3ce4dc1f 100644 --- a/data/minecraft/structure/village/plains/terminators/terminator_04.nbt +++ b/data/minecraft/structure/village/plains/terminators/terminator_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:93204aff54022f38c004d91c35d3feffa8150733987c7e571f43c86f409ee2d3 -size 320 +oid sha256:9100caa7a2660b2e9dfa22bf940802a75b733ea6f72f5576a1e7a8d66144c39b +size 322 diff --git a/data/minecraft/structure/village/plains/town_centers/plains_fountain_01.nbt b/data/minecraft/structure/village/plains/town_centers/plains_fountain_01.nbt index 0481b054..e76ec0f1 100644 --- a/data/minecraft/structure/village/plains/town_centers/plains_fountain_01.nbt +++ b/data/minecraft/structure/village/plains/town_centers/plains_fountain_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d5dbf286448f954a9501717b37219ff3f94feea68cebcb9a93733cc63fa42838 +oid sha256:e8669fb85e0339ca4fb5d93c7d797cf4a9f5e19fe6aaf1e4fa6f7604ab491f5a size 957 diff --git a/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_1.nbt b/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_1.nbt index 55c70384..4e988bff 100644 --- a/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_1.nbt +++ b/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:590e41ce91451a9ab37d9413d46a06f398de9e9efae9889ea11f271fc1b02147 -size 1051 +oid sha256:06100ecc4de8e6e3d11f2748ba7d463533da93144509b3d6150e5bf33b957515 +size 1052 diff --git a/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_2.nbt b/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_2.nbt index 4741e5ac..40c7b7b6 100644 --- a/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_2.nbt +++ b/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c7d465aa1789aab88cd47064304cb2dd86cabde27a65e03a2c96984acb1645c2 -size 2538 +oid sha256:966a9b7035b75c6961b7eb056da3940951d242aa6d45bc30a81764ffed28eabf +size 2540 diff --git a/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_3.nbt b/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_3.nbt index 18123a39..6f37e1c3 100644 --- a/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_3.nbt +++ b/data/minecraft/structure/village/plains/town_centers/plains_meeting_point_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:73140d564a1d4ca5a69c6460eb52a7016e8fb1a2e224fb83c276042b4e97105e -size 1586 +oid sha256:04407203a40cd084dc430a10aea3b61ce9f83cb328a5b8948f72c1e7bb304802 +size 1585 diff --git a/data/minecraft/structure/village/plains/villagers/baby.nbt b/data/minecraft/structure/village/plains/villagers/baby.nbt index 5a65ef48..0d0d870a 100644 --- a/data/minecraft/structure/village/plains/villagers/baby.nbt +++ b/data/minecraft/structure/village/plains/villagers/baby.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:53b0eca3d1bfdb3e97935285ff53780e820aa24b5663bc86f01d78e1280d0c4b -size 750 +oid sha256:226a6656aae6f3f6d8b39c4d6c982edee40ab5e00c5110ac6a1a7027d2bc6cc9 +size 718 diff --git a/data/minecraft/structure/village/plains/villagers/nitwit.nbt b/data/minecraft/structure/village/plains/villagers/nitwit.nbt index 728ab34a..77786c58 100644 --- a/data/minecraft/structure/village/plains/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/plains/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7f7ca589ac4c1b25513e79d0e62861aed98dc3407d96452636c10c1a69069b82 -size 749 +oid sha256:71a20804dd995d2223d9c25127acd8e7d73022a69263afb07441ed9086b3281c +size 716 diff --git a/data/minecraft/structure/village/plains/villagers/unemployed.nbt b/data/minecraft/structure/village/plains/villagers/unemployed.nbt index f72aa61a..732e1865 100644 --- a/data/minecraft/structure/village/plains/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/plains/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:961a9829a257ab96c32cfd62fba8f7a3dbae9bb55ca98e55fc15785dc0193407 -size 749 +oid sha256:5e1502a0ff0665eb567561b6f73f382a0e0bc9765eaf88f2627dac15199bbdca +size 715 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_animal_pen_3.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_animal_pen_3.nbt index d8a39c6b..67d43239 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_animal_pen_3.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_animal_pen_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:85d79c9830c02e34eaf2149273d3c973fa6a45ff6eb4219ac0c4c94853047ae3 -size 1360 +oid sha256:f10a4f434070d819b5a62dd0acc6bf72d9173c6e76a9cf1ee2313b048cd3f306 +size 1362 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_big_house_1.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_big_house_1.nbt index 8f37c613..4d2f3d56 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_big_house_1.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_big_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ba96de064df68e8cde1ecb0aefb4c51f8032f83c1f5caccc7c65446490c3230b -size 3271 +oid sha256:2c29f0b4948d7ba2b28a4723aec0db31b00a8b4cec1e2a6fe16e653f947df517 +size 3272 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_butcher_shop_2.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_butcher_shop_2.nbt index f42c9bfc..670f6941 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_butcher_shop_2.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_butcher_shop_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:281e8bdeaec9e74125969f3519695aa22a9add6190e15dd860d36d61d841e257 -size 4661 +oid sha256:5c287ee671a3b77f4883323d3e873a438314391a87101e8b9b5f10eed1b85a76 +size 4660 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_fletcher_house_1.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_fletcher_house_1.nbt index 094e4d45..f897e151 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_fletcher_house_1.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_fletcher_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:060aa11fb126d5d60c2c96add2a0fda17b7b5032107b264df90afddae72eb877 -size 2906 +oid sha256:596271e8dd0a4341f82ee3d8a7077eb564c0a192dddf4dc9f42247c2bba64443 +size 2912 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_medium_house_1.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_medium_house_1.nbt index fd99ae0a..f0a9e4b0 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_medium_house_1.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a7e3e35ab28d9f7f6991c9f972efa6aa45b5a51e12bdeb30893715a9f2ab5281 -size 4247 +oid sha256:8a4593d668533a7b300607cf64bac9d22dd330bf8c6bd4d22136306b60f704ad +size 4248 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_medium_house_2.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_medium_house_2.nbt index 9b0aaffc..908701c1 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_medium_house_2.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d9e2c19352b2f042feac4e1b4120792efce130a04e1de03d7b58632ed5755a7 -size 2540 +oid sha256:46a818ddc4021431bd9023e8211165678d8bc5801cb721609c202b26e9f3deb9 +size 2542 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_meeting_point_4.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_meeting_point_4.nbt index 90783b61..95047a8d 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_meeting_point_4.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_meeting_point_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7e11eacd0cb24be0e434fdcf24a98841ac88d91c791cef512afb96154e9e2c65 -size 3918 +oid sha256:38de99e1435aa614cc767a7c036e6bc8dba6e9cbdfc6eab9b1ab0b6aba1ee81c +size 3919 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_meeting_point_5.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_meeting_point_5.nbt index 8eefb25c..7beb7510 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_meeting_point_5.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_meeting_point_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:48ff59a142203a719d0eb05070d387af2a46c007358d295b29db5205dd8ef682 -size 2597 +oid sha256:d357141658438201edd6b443d8dab9c81488186fa6879be0085f3f25efba80ab +size 2599 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_shepherds_house_1.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_shepherds_house_1.nbt index b5a9fe87..bf816f7f 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_shepherds_house_1.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_shepherds_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8227c70bcd732275f60ff6810d9a799bc409009c3f20f99d26b91ae0c4c56bf1 -size 2924 +oid sha256:5ff6e832c041827f52d0d637d5194c3fffb60b8d064e2c9526ba2fa163aeb016 +size 2925 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_1.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_1.nbt index aa93f477..b23dcb5d 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_1.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b89bf46b6fe956c675a17f76b4c0adc567cef2d5c47abede64d32faf07953d37 -size 1807 +oid sha256:0359d6b1d29b47dafa0c92bf6b507229222f213e0df32931586ae632d900f8a7 +size 1810 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_2.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_2.nbt index e9f83556..774cd3cd 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_2.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9c1a33a84ac9c93936b93e90e3161c835db70a4a1da8ebaa8982e42436fbbe53 -size 1705 +oid sha256:35b4e9c47da99164eba45a9445aa4400d097c74e55bee6f64b0a67848d296c9e +size 1708 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_3.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_3.nbt index 6254d90c..0c0c57dd 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_3.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:34fb42245e4259c0ae14951a5cd46f9256ae08ae957bb1084323af1d3c38d09f -size 1807 +oid sha256:79fcbfac449cd94031db5e675cba2120d27917955f5a46ab09e02b11a7b5d658 +size 1810 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_4.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_4.nbt index 85b7e90f..e0d3a45d 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_4.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fb8a9a7b99685c4ca13445bfc944fe186bc41235337facbd5cf6fa76ea79bb41 -size 1781 +oid sha256:f6589ea31b8e1cd5bde2ef3385ef42e0595b2f11fc6cd3c06d319572f66e73b9 +size 1783 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_5.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_5.nbt index ce8537d7..2a917726 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_5.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5b14fdd37fa6a1fb92fe1b59646921079ef28c68927fb1f772912a1ad6862e51 -size 3494 +oid sha256:e6e34b78bbcfd91b12c4c87ac744640873e1c42a62fb4d58935c2ff716d6cb01 +size 3496 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_6.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_6.nbt index fda2f445..6a36c1e7 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_6.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dcac806a2183a92187c8577f92e22f8c8821b6926176e67854515f2730cda0f0 -size 1766 +oid sha256:e2bbc62501f4b53e1ad9ca1190845d9687fa23afd020326c54f3c43f95e75b76 +size 1767 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_7.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_7.nbt index 87f97278..cec39f83 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_7.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:426b5f8dc6a65be4186fa3a5df6b6e843400ad0f959b1c0ecd1848e804078ba4 -size 2032 +oid sha256:aefe9b71874a6089bc2b964ff12392624b13db3a99344f0b59657ab302ed1a73 +size 2034 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_8.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_8.nbt index 11813075..ee24203d 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_8.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_small_house_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d3d8c10d281397deb0b5111d8f493d4aabcf6d5d092580dba1525a5ed021f484 -size 2689 +oid sha256:8ca735818d0bc2502cec6fc71c414b6a38e1da3fe9510dabbc80860210bbb800 +size 2691 diff --git a/data/minecraft/structure/village/plains/zombie/houses/plains_stable_1.nbt b/data/minecraft/structure/village/plains/zombie/houses/plains_stable_1.nbt index 7672a8b9..622d4efa 100644 --- a/data/minecraft/structure/village/plains/zombie/houses/plains_stable_1.nbt +++ b/data/minecraft/structure/village/plains/zombie/houses/plains_stable_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a6ef7b5cfb2527c1a92bcd9c0100571532362692d817f318d369c531c7b57b7c +oid sha256:468250b64c51f574ac0c0d23e4af4a8923f3d7d4ff1029353337bf5bf9ba1b00 size 3861 diff --git a/data/minecraft/structure/village/plains/zombie/streets/corner_01.nbt b/data/minecraft/structure/village/plains/zombie/streets/corner_01.nbt index 1a303ffb..026f4514 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/corner_01.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:224e8b923049e310615c7f04f37387f9cd61f033d56b5ef8738f5924612ddf68 -size 1187 +oid sha256:d198f622066837ba788f749b425bf0d229736e02351883bac0fea353cb39fc1b +size 1188 diff --git a/data/minecraft/structure/village/plains/zombie/streets/corner_02.nbt b/data/minecraft/structure/village/plains/zombie/streets/corner_02.nbt index 653287ff..32a346ba 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/corner_02.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/corner_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d82f2920efd8e4008548fdadeb2243239f6ddf1b21e7f400623332d29005de02 -size 1114 +oid sha256:8382773a7bb602f329f9ac37d86959bad4f73252b2e062bec5fb56b49c0481be +size 1115 diff --git a/data/minecraft/structure/village/plains/zombie/streets/corner_03.nbt b/data/minecraft/structure/village/plains/zombie/streets/corner_03.nbt index ec1bb0e5..cec2e553 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/corner_03.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/corner_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ec0a2a92098c3735096b14beaf1f208b8d83e2f77a3e14dd2110217351869e75 -size 355 +oid sha256:f85c9c62c73efc442fafca481fdd79c85034954e223b496149592a3adbcd8537 +size 356 diff --git a/data/minecraft/structure/village/plains/zombie/streets/crossroad_01.nbt b/data/minecraft/structure/village/plains/zombie/streets/crossroad_01.nbt index eccd1f9e..77de9c79 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/crossroad_01.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/crossroad_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:402a57c758b41e31b4c658816a8e698b97d5a875926df821e27aaa28c8eaa0f6 -size 1220 +oid sha256:d81b54138ee7164595b144bee73aee211703de0aa30fa69f613f43dcddd2fbae +size 1221 diff --git a/data/minecraft/structure/village/plains/zombie/streets/crossroad_02.nbt b/data/minecraft/structure/village/plains/zombie/streets/crossroad_02.nbt index 92633f46..d8e0b34c 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6161ef6bbb4d2325b885760bb5696078f0e2aad4f8d37bc0fcc43de9425db981 -size 1164 +oid sha256:ecea71f5f8136aa9e3ced670a0c6eb964f469838801ac41d4cea1b44a3096149 +size 1165 diff --git a/data/minecraft/structure/village/plains/zombie/streets/crossroad_03.nbt b/data/minecraft/structure/village/plains/zombie/streets/crossroad_03.nbt index 92cfe861..5fc03e66 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d85efecec35b4796276f27293969219d27b6b713e9e3021bf59b651b72293356 -size 1207 +oid sha256:e2eb80231eb2355ad8dc00f4e31ad73fd89b1ade898f8bbd4d386f38b975d31c +size 1209 diff --git a/data/minecraft/structure/village/plains/zombie/streets/crossroad_04.nbt b/data/minecraft/structure/village/plains/zombie/streets/crossroad_04.nbt index e56c0121..b46e7961 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/crossroad_04.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/crossroad_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4794edce593b94cf739c4651b16f87a2fcd01273326036ceb7fbbb12938918c9 -size 382 +oid sha256:e88dd2ad6310a1e381da2f655b5dc1fdb1bfbfebe426cb52fb401c59c0f0ca97 +size 383 diff --git a/data/minecraft/structure/village/plains/zombie/streets/crossroad_05.nbt b/data/minecraft/structure/village/plains/zombie/streets/crossroad_05.nbt index 3369b270..03b50922 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/crossroad_05.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/crossroad_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ad5e8c4ceca546af3001b87d3e189078bfee27106139cb8ba587c3c6299efd73 -size 413 +oid sha256:d2e93939b3a2ddde050dfa2654a4803a54f25ab37cda90480dccd525520ab551 +size 414 diff --git a/data/minecraft/structure/village/plains/zombie/streets/crossroad_06.nbt b/data/minecraft/structure/village/plains/zombie/streets/crossroad_06.nbt index fe7d8e58..f5318639 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/crossroad_06.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/crossroad_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0ce25d8f23b24a74dd19f672cdc9c191485489bfda75629dfd6c6c14e50accbd -size 475 +oid sha256:d74a98dd636a9f49a8b7beb5a04427cd50fc35e273cdff95c0cdd227c19e3392 +size 476 diff --git a/data/minecraft/structure/village/plains/zombie/streets/straight_01.nbt b/data/minecraft/structure/village/plains/zombie/streets/straight_01.nbt index 277276db..18534b33 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/straight_01.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/straight_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:56ab4a1508e1d2a100dd8dff0c703ea905ae5856994eb7d109afa18396d86e02 -size 1135 +oid sha256:d0205d49e6003eca432fe59302b662e4bf40af3e5470bb01e5a716b501ab54db +size 1136 diff --git a/data/minecraft/structure/village/plains/zombie/streets/straight_02.nbt b/data/minecraft/structure/village/plains/zombie/streets/straight_02.nbt index e5470588..650b840c 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/straight_02.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:77c916da6c2de033471a6768970f2f3b6279f932acb76febe952926c133a3307 -size 1089 +oid sha256:0eba4508e80e29e1ed7e2144c2ed1342ec89b2d7790003423d8b692ee1ebf461 +size 1090 diff --git a/data/minecraft/structure/village/plains/zombie/streets/straight_03.nbt b/data/minecraft/structure/village/plains/zombie/streets/straight_03.nbt index 60d1598f..87985e81 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/straight_03.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/straight_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a9b191439816562cfc77d9ff1d67040da416e3c7967e572988de14005859e418 -size 781 +oid sha256:c136c6bac24377cbe4bd02b831e25341f7fbf8c9aa7b5e60255d9e07dfbb2ce6 +size 783 diff --git a/data/minecraft/structure/village/plains/zombie/streets/straight_04.nbt b/data/minecraft/structure/village/plains/zombie/streets/straight_04.nbt index a952c1f1..10086e9a 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/straight_04.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/straight_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5dfc199a1b3457d3aa9b841d4369ce23fe7689cba6cdd0ab3469d615684b67ad -size 638 +oid sha256:ec3e88ac9a2574ba21f2545836fa40a9a1f0ca1251bbc549c4b87d2f54654ac1 +size 640 diff --git a/data/minecraft/structure/village/plains/zombie/streets/straight_05.nbt b/data/minecraft/structure/village/plains/zombie/streets/straight_05.nbt index ff24cfc6..a57d3abe 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/straight_05.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/straight_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ea6252e9b711c69d24d8328b966a831de3c3afd67044e4675d8472e69ff1c72c -size 1334 +oid sha256:b73e0d93bfe1184b2ba37958df84138dcba3abb8b9942499444738349a7f1a6c +size 1335 diff --git a/data/minecraft/structure/village/plains/zombie/streets/straight_06.nbt b/data/minecraft/structure/village/plains/zombie/streets/straight_06.nbt index ac3efc56..ae261b08 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/straight_06.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/straight_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6b5091f71a9f064ba4d09523ff4f2bcda40cd88e252a9529b92be69b43851f8a -size 1708 +oid sha256:d2cb5e1bd0371b72d44f2dda92abdf23ee255ecfedac89ecc5a6f564510afba1 +size 1709 diff --git a/data/minecraft/structure/village/plains/zombie/streets/turn_01.nbt b/data/minecraft/structure/village/plains/zombie/streets/turn_01.nbt index e5634633..f9912e04 100644 --- a/data/minecraft/structure/village/plains/zombie/streets/turn_01.nbt +++ b/data/minecraft/structure/village/plains/zombie/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3e54c8ab7b103be259282917b26c002bd2a4295b76cf23852fe1c0d0fd723675 -size 794 +oid sha256:403a7197296924b5e0a5abdee6861464f3fb65489559eaababbf522b37ee720b +size 795 diff --git a/data/minecraft/structure/village/plains/zombie/town_centers/plains_fountain_01.nbt b/data/minecraft/structure/village/plains/zombie/town_centers/plains_fountain_01.nbt index c795452a..4c953556 100644 --- a/data/minecraft/structure/village/plains/zombie/town_centers/plains_fountain_01.nbt +++ b/data/minecraft/structure/village/plains/zombie/town_centers/plains_fountain_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9c4ddd6c991628bb158cb645ba245870578b9183a972a98ee5755f4e86fa33d1 -size 931 +oid sha256:c4576dfaaaa827f7a91b6ec548e2aa154b9727d6b5b1aa0cdd5fe04ffc9e4f87 +size 933 diff --git a/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_1.nbt b/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_1.nbt index 14444712..4cb32e97 100644 --- a/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_1.nbt +++ b/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0f0680408b947638d615ad658607305566bd85af4b68c7d3362c83ca653174cb -size 992 +oid sha256:c92bf3c1392a456cff698067907f25d3b3a7988afc9fe1aee8c73c7015664556 +size 994 diff --git a/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_2.nbt b/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_2.nbt index 3bf200e7..af998062 100644 --- a/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_2.nbt +++ b/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bf6ed00f64c48d016b85d99de6ce55dcebbb9de09fa1314623039f9ebba144b7 -size 2484 +oid sha256:259b37c0c7abe105e8875bcbdb67321d2acfc7e850f9cfe4307023c64b4377db +size 2485 diff --git a/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_3.nbt b/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_3.nbt index 519d7fe6..adbf0fd1 100644 --- a/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_3.nbt +++ b/data/minecraft/structure/village/plains/zombie/town_centers/plains_meeting_point_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:443556e2f24b799067c5bc98e831f00a8ef424c4bc3cb2dc15138efc62c00b99 +oid sha256:2b8457352b053ea8704c7e385a85858605d706e70489e74d69fd77314f51d365 size 1527 diff --git a/data/minecraft/structure/village/plains/zombie/villagers/nitwit.nbt b/data/minecraft/structure/village/plains/zombie/villagers/nitwit.nbt index 08f85a9f..967e4096 100644 --- a/data/minecraft/structure/village/plains/zombie/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/plains/zombie/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d2345fd8b729e0cbfed1f7044ff06dae67a0cb7591081881a672e052a169c27b -size 755 +oid sha256:881a4402706e3ecff7d926f112b71ec6b15b353b575e6f75344a9540bd3cd2cc +size 721 diff --git a/data/minecraft/structure/village/plains/zombie/villagers/unemployed.nbt b/data/minecraft/structure/village/plains/zombie/villagers/unemployed.nbt index b534c89b..429b9750 100644 --- a/data/minecraft/structure/village/plains/zombie/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/plains/zombie/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2dcfa09e9416da7b6f2cc191ebd5c4fd75833cb088c89d48fd8eedd0a50f2d57 -size 756 +oid sha256:b97090541ba589c52244497a70c15bb2e33f9b53ba4050f08314a59d9c72c0e6 +size 721 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_1.nbt index d5df372c..3c8fceeb 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:00c8c9bb10e377c839a23b2a9b5275b4cb185cbef6c570f60f6335d4749e6571 -size 1859 +oid sha256:bb9499026180ed92795c5ee2f0cb6640a6becc1d99066284bd6c06e6f12bb7f8 +size 1861 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_2.nbt b/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_2.nbt index 5a84329c..03a63b8e 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_2.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e7bbad3a1013192b105630861cba0e346c7e955e01c0618654c97f3dd5bf1a3e +oid sha256:d2b51cf43a8b69bc61e2cfd72ec5bbf679e00fdf0cb6acd814c5fc93da3d9575 size 3474 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_3.nbt b/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_3.nbt index 86ea7e3f..c82180af 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_3.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_animal_pen_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b144bdece75b97b8bf163b97f203531d3784c30b67755bc9958fdfae16a277b6 -size 1658 +oid sha256:b3f4cd4b3cdc4086133c95acacec5a61b839f0e3f510b557e857f4724a7eaec4 +size 1660 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_armorer_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_armorer_1.nbt index dcebb30e..936da76c 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_armorer_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_armorer_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e04d30d084b45a106c9d70938c9378d811cac290e890c310b0e043876ff27e2 -size 1722 +oid sha256:407eb9ac86a75580a3be143e6492e0339d45923cd5f7d97311c83792501238a0 +size 1723 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_butchers_shop_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_butchers_shop_1.nbt index 2ad349e9..ad954ba9 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_butchers_shop_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_butchers_shop_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:236a44ce3c32a4981195f2ec898f4a51e45bb72d1ae5cf46f3b65127803c193d -size 3938 +oid sha256:88fa938d258b745ea71080d667aa24f5ed0900b98680d1acfb4bb3e1c8e2a4b9 +size 3939 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_butchers_shop_2.nbt b/data/minecraft/structure/village/savanna/houses/savanna_butchers_shop_2.nbt index 2c922d81..3630d4cf 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_butchers_shop_2.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_butchers_shop_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:462929b0639679203ccf3626284023368d9b90ef0bed21fc9dc6eaef5d3f374d -size 2085 +oid sha256:f4a46829910ea769b6a328aca392375ded57b0465e7ad9c9c6473ad73b4d470f +size 2087 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_cartographer_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_cartographer_1.nbt index aa321f23..5c4e3182 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_cartographer_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_cartographer_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:131019e35ec7346e3de75e36da3f8be432795525e5273161b081a9107bd573cd -size 2642 +oid sha256:d5c8938fdff69e079e045baa856d970b0897beb7a97fc5ab078084c071e37e29 +size 2645 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_fisher_cottage_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_fisher_cottage_1.nbt index 903aea78..3dc6047f 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_fisher_cottage_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_fisher_cottage_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d460ae8e651a816a7cc520beef34dec7c5231fb1c4ef2c709f1025a44381b785 -size 3179 +oid sha256:7e73cbe2f0b220bf76b285eaf6cd5802a3bf824761504c68afff8e8ad2a342e3 +size 3181 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_fletcher_house_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_fletcher_house_1.nbt index 125bd7d4..9042ba4e 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_fletcher_house_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_fletcher_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9826f5279f9af536d1b099fa2c09063632bbb43832ccad65ad1ea9cef317eb06 -size 3035 +oid sha256:2319391cee7d7df40443d31f652bdf0ee94a57463ac13ccb90dc6499b1ea389e +size 3036 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_large_farm_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_large_farm_1.nbt index e9b9ac8a..3c7fc3e8 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_large_farm_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_large_farm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c921e3c220c8fa3ed73db8f4e9b5afd9cc2e03d68dccacc63a6e5e34f92ae83 -size 1244 +oid sha256:0e493eabef899d8cab64339452f17be0bea0c8a6c5abdc51f91e70cfad4d2a8b +size 1246 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_large_farm_2.nbt b/data/minecraft/structure/village/savanna/houses/savanna_large_farm_2.nbt index c4f07a62..edea3275 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_large_farm_2.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_large_farm_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:864621248e8c10ffbfebe0f338f17a9ede3e6d8b54137d92ac60eb17a0aac8e0 -size 2152 +oid sha256:7f95c22eba63f09f1e5388ad1e453f4b93315819a641eebcd40032b7675e097e +size 2153 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_library_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_library_1.nbt index 57d774c7..9fdc0fd1 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_library_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_library_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bd35e362cfd8587c16011ccfc64c583628fa8d432d558a39c5a1184aee6b5536 -size 2768 +oid sha256:91e5d48cd185ee9160a2efd5fc1418893f8164b012c5704ea3c8eca8e92012d2 +size 2770 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_mason_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_mason_1.nbt index 4de58544..b0ed0345 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_mason_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_mason_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:336fd4cf003eb7d5fbc07662f4733aa693c098345cd4a252638bceea2508afab -size 2519 +oid sha256:3ed925df89cad8c80bea32672be74256d1c6131e797b8e35951d0e8464f42acb +size 2520 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_medium_house_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_medium_house_1.nbt index d9c71400..d4a1a622 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_medium_house_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e4502655c59d48e6a577675f1e95df87557a43ff1b16bf41551e9cbcdf682e2b -size 3641 +oid sha256:e563781338bfd01a534595218a064ad51409d0210b99de8a0a24d4c1ac283c4d +size 3642 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_medium_house_2.nbt b/data/minecraft/structure/village/savanna/houses/savanna_medium_house_2.nbt index 159d1179..895b8b10 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_medium_house_2.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7bdc7eb38d8accda965a4e6b7a91a89aabb692bb5dacc31c64bccd92eed57c7a -size 1858 +oid sha256:f525281463cee9dd1889c6531580de1abb14e14538c869e96be4718ddf5794d6 +size 1859 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_shepherd_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_shepherd_1.nbt index 29486f78..822672a6 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_shepherd_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_shepherd_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f07a4abc7940f8dc58ce745e47115f17ddda19b1177c81c948c2635e91e98e25 -size 6325 +oid sha256:12d1589606601bff3ab92ab5ae6c3996719378e5265fc7adb613662a123a3f11 +size 6327 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_farm.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_farm.nbt index cb6d89bb..4cd33914 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_farm.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_farm.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f001a9db78aa5d0acc43b79510d9e21dbba3605587f78f0a04abff2ef81df0bc -size 1137 +oid sha256:67a7e44b957c443c5715b6424092ad6dff7f014cd08e0f84d2dcefae24a243e2 +size 1138 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_house_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_house_1.nbt index 631b3a63..258141b5 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_house_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d54789b4f96860980cfb4daa84779ae78f072bd3b2fbeb3f1b12c1a9e0d68355 -size 1850 +oid sha256:70be429e5426208b5955213d41bda35531a4d799df17f61641deffe8efeed269 +size 1851 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_house_2.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_house_2.nbt index 50b53ddc..83ca0a91 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_house_2.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:23a6c43ca8b31cfaa8960e4454b9e7488909c1e8988fdd63f4ac300bba5e3484 -size 1859 +oid sha256:8a98e1af5454fa54a228dab41b839261decddc2f9952d0d36e74a6e3797812e5 +size 1860 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_house_3.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_house_3.nbt index 968c5afe..1d539eee 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_house_3.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e7db7849deb05b06115b83679d7bf162d0f570f116566297f10c3802b99c3067 -size 1811 +oid sha256:b85f926bf316fe1b678411c27cfab57e755b5145d15c0ff0821de96667190b79 +size 1812 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_house_4.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_house_4.nbt index 9443b04c..6383d3a2 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_house_4.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dcc546df084e23d8b8f76e2d8094069638a99b2d48ecaa34cc15f3dcadcb380f -size 2707 +oid sha256:11741df756defd3237df20f6281c984d493e00268ddc6d0f36727f6a7a64ed34 +size 2708 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_house_5.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_house_5.nbt index 0438d1f0..eaf45c91 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_house_5.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c8a0dbb71d791f127b6ab49172f25784c08bf4479f682743811f17e5afc2b75 -size 2373 +oid sha256:b2d8b532189ebcc2ac14bfff4a9c5f2856f2414c726705c7b751ee765e26ffcb +size 2374 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_house_6.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_house_6.nbt index f04cb58d..102c7fb8 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_house_6.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_house_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f495715a02ac257fe81eb1639da4105105f881b9c2e6d7e3dae1a8f3af58ce52 -size 1785 +oid sha256:7baec6886bdcf2dd50962c4f6f4f9dc5691c5c0357931523cf1c5bd39d941bc8 +size 1786 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_house_7.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_house_7.nbt index 6cfe5f34..0853f3f1 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_house_7.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_house_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a970fd876512e2f979089833fe83b37325ad4cc3d33934219b15a403dcbb65e8 -size 1882 +oid sha256:8fb8b9558c2d831865be58319c448703dbf5b50d7febcd920f68eb90e694a9f7 +size 1883 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_small_house_8.nbt b/data/minecraft/structure/village/savanna/houses/savanna_small_house_8.nbt index a947d07f..0da1cb48 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_small_house_8.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_small_house_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2226d4c6171d8ec23e2688e11f900828a9331939cc63e1d29d08caadfc0a79e3 -size 1545 +oid sha256:ecc77f9dd1d7876d3c2fcc8536f845c2e3c30a333d89efe3b56bf450fb4b4c0e +size 1546 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_tannery_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_tannery_1.nbt index ec851ce9..cad20394 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_tannery_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_tannery_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:48be3724a48c1f0430b7a9d13cdd6b9e6c0132af2fb0a504e74fd2f8b226f987 -size 2129 +oid sha256:0134456d6beaeb6fd98bb3655a654ba5c9d6fa1e4c123a4cab0ad6b179de2aec +size 2132 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_temple_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_temple_1.nbt index b4a72a69..9cf11881 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_temple_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_temple_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1bd921253f6cede360dd0dd26e45090107b7845fd4184817ba4651846a3af181 -size 3628 +oid sha256:3595222c73adab13b78aa1f78c61e2a293e62c1b6f48fd53335527b14f5f8158 +size 3629 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_temple_2.nbt b/data/minecraft/structure/village/savanna/houses/savanna_temple_2.nbt index 264e8357..869c9cc9 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_temple_2.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_temple_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:951aa562341f3f196548ea662a727950d395a5e10be646b4ca96cc32ef8defcd -size 2025 +oid sha256:9504989164f4a928f094c7d4016ade58a6455cdae84fd851e59ad08454d24984 +size 2026 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_tool_smith_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_tool_smith_1.nbt index b4c03c6d..2a2c5fc2 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_tool_smith_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_tool_smith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:576001d0e9fc1cd801ee24065e02b8efad18dba91e722bd3c58ae7c2591e9962 -size 2461 +oid sha256:c08a9b2b486d765317e78e4634aa1c067af2e47f53024d4404647ed44fe5c829 +size 2462 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_weaponsmith_1.nbt b/data/minecraft/structure/village/savanna/houses/savanna_weaponsmith_1.nbt index a00cd843..421f560e 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_weaponsmith_1.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_weaponsmith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1383d020d8e5f7dddef938cdd18d5aa43be3b9cf80456712740853a5d4550890 -size 2078 +oid sha256:f386433e63f3b41c2b5992c14d63b3c6d475ea9c28d71e244f0f44052c5560a0 +size 2079 diff --git a/data/minecraft/structure/village/savanna/houses/savanna_weaponsmith_2.nbt b/data/minecraft/structure/village/savanna/houses/savanna_weaponsmith_2.nbt index 4a2c9146..750f123c 100644 --- a/data/minecraft/structure/village/savanna/houses/savanna_weaponsmith_2.nbt +++ b/data/minecraft/structure/village/savanna/houses/savanna_weaponsmith_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e89d3694674bcf33b765ceeee94be7a457510995f7561d0e7afc096e351e9e97 -size 2197 +oid sha256:b57a07e40f551edf8e640eec615378fea479cf1b726026e6917c5276c4aa8569 +size 2200 diff --git a/data/minecraft/structure/village/savanna/savanna_lamp_post_01.nbt b/data/minecraft/structure/village/savanna/savanna_lamp_post_01.nbt index bbbdfb78..eb6dac60 100644 --- a/data/minecraft/structure/village/savanna/savanna_lamp_post_01.nbt +++ b/data/minecraft/structure/village/savanna/savanna_lamp_post_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fdb102736a475c45a35a1c550e1b1f857bb7f00d8a874eff26d1c925ab0f04df -size 282 +oid sha256:7c0ea2b1a7269f87df17a32af548ebea9414fd507e4bfc1ca60b416eeec6c855 +size 284 diff --git a/data/minecraft/structure/village/savanna/streets/corner_01.nbt b/data/minecraft/structure/village/savanna/streets/corner_01.nbt index 1123bb1d..fa0b5f10 100644 --- a/data/minecraft/structure/village/savanna/streets/corner_01.nbt +++ b/data/minecraft/structure/village/savanna/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:94b41a36838f8f61b1c211f63a33a010119e42222556b6713b15dc73038a5654 -size 1197 +oid sha256:4d41a385841575f6d7f5d99e78787b5ddc78b8b6ca2eb53694930368235384e4 +size 1198 diff --git a/data/minecraft/structure/village/savanna/streets/corner_03.nbt b/data/minecraft/structure/village/savanna/streets/corner_03.nbt index 2d2c910c..d89cd751 100644 --- a/data/minecraft/structure/village/savanna/streets/corner_03.nbt +++ b/data/minecraft/structure/village/savanna/streets/corner_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:77b7610e8277d1034a6e3fa73d0b6795c841f85a1a24849313cd64156da48444 -size 350 +oid sha256:7b2f04d4d7e916ad8e2a394a80c3602dd26e3386d21cfca6199819c6507dc2c2 +size 351 diff --git a/data/minecraft/structure/village/savanna/streets/crossroad_02.nbt b/data/minecraft/structure/village/savanna/streets/crossroad_02.nbt index edaa82e8..9b106daa 100644 --- a/data/minecraft/structure/village/savanna/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/savanna/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5a1ef327a88d3d5d35a6c23bc797aa8c741d543f56c952d2ca1e900a6f4662d8 +oid sha256:2cf70ae5dfb9713c7ba22836a00aeda893b3579c1a2a73068375d24003aa41ef size 627 diff --git a/data/minecraft/structure/village/savanna/streets/crossroad_03.nbt b/data/minecraft/structure/village/savanna/streets/crossroad_03.nbt index e4fcb369..ee15b52a 100644 --- a/data/minecraft/structure/village/savanna/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/savanna/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3c5556518955f28e8d11f2bac21c5dfac11bb428ee37a1b233aa11b22a3b893d -size 1225 +oid sha256:e3af98a97aef7dcdafffef73a2e0038555d7afe44541e3408638915aebe9549c +size 1226 diff --git a/data/minecraft/structure/village/savanna/streets/crossroad_04.nbt b/data/minecraft/structure/village/savanna/streets/crossroad_04.nbt index 895960e2..d649f52a 100644 --- a/data/minecraft/structure/village/savanna/streets/crossroad_04.nbt +++ b/data/minecraft/structure/village/savanna/streets/crossroad_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8b54b6c584130e8248a58900452a5a256fcf5356d793ee23b3a38aa74d76decb -size 379 +oid sha256:aa0a95ae9b62afe58db53faf855b275d6b0cab684b23ba3d5f2c7987be2474fa +size 380 diff --git a/data/minecraft/structure/village/savanna/streets/crossroad_05.nbt b/data/minecraft/structure/village/savanna/streets/crossroad_05.nbt index 566c333c..a28a6418 100644 --- a/data/minecraft/structure/village/savanna/streets/crossroad_05.nbt +++ b/data/minecraft/structure/village/savanna/streets/crossroad_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5f1d1276709dad3602f3f60814ea049873d21aa0f44f108a35caf71cd5191b7c -size 409 +oid sha256:c6a535f0a9a6506caa4c03a5461ff06652b74a869ed8d4058b91d72e2e1c947c +size 410 diff --git a/data/minecraft/structure/village/savanna/streets/crossroad_06.nbt b/data/minecraft/structure/village/savanna/streets/crossroad_06.nbt index 132cdf43..0bd7174a 100644 --- a/data/minecraft/structure/village/savanna/streets/crossroad_06.nbt +++ b/data/minecraft/structure/village/savanna/streets/crossroad_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a123c58a9965f677799d108bbb77ade9f3d27cf2da9d971c0425c5071f9c6f4c -size 467 +oid sha256:852dbd434815650f5648dcbeb18380bcf0aafeb2bf3c8fd6050aa206477237f9 +size 468 diff --git a/data/minecraft/structure/village/savanna/streets/crossroad_07.nbt b/data/minecraft/structure/village/savanna/streets/crossroad_07.nbt index ce5524bf..5b22ba93 100644 --- a/data/minecraft/structure/village/savanna/streets/crossroad_07.nbt +++ b/data/minecraft/structure/village/savanna/streets/crossroad_07.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:76bb696d23580179ac336d2a2db3327bc70ce7cd243e3cbea199f84e90fc66e6 -size 1380 +oid sha256:7239996ad4cea7dd27e4fa7c534faade0161db5079e228c3660533cc2a8f24fc +size 1382 diff --git a/data/minecraft/structure/village/savanna/streets/split_01.nbt b/data/minecraft/structure/village/savanna/streets/split_01.nbt index d2b4086f..9aee9474 100644 --- a/data/minecraft/structure/village/savanna/streets/split_01.nbt +++ b/data/minecraft/structure/village/savanna/streets/split_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cae12080e222d56298555bb81dd16b981c7f54e047aae38420a257fcae77194d -size 524 +oid sha256:90018ce795f41955da9850533f206688289abd1067eaca57525dc11e519aba08 +size 525 diff --git a/data/minecraft/structure/village/savanna/streets/split_02.nbt b/data/minecraft/structure/village/savanna/streets/split_02.nbt index a89389bf..c0401041 100644 --- a/data/minecraft/structure/village/savanna/streets/split_02.nbt +++ b/data/minecraft/structure/village/savanna/streets/split_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7df7156772707ec8a4186931129b7a3320b8e1db0a393af70088fa48e86336a0 -size 735 +oid sha256:8367f5ea8edc3febbe35487f8d08484ad87197de0d1a9a13734c35ebf58c6313 +size 737 diff --git a/data/minecraft/structure/village/savanna/streets/straight_02.nbt b/data/minecraft/structure/village/savanna/streets/straight_02.nbt index 62ed455c..97aa69e6 100644 --- a/data/minecraft/structure/village/savanna/streets/straight_02.nbt +++ b/data/minecraft/structure/village/savanna/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6a10789ab0c7ea72289f912354d37a8caf07c0a9169b60f7a5cdf52ec896f228 -size 1123 +oid sha256:b55eab053c6b8bf188d3faa0ae7fe0e2efbfaaeded02b19314e9c906c21196d4 +size 1125 diff --git a/data/minecraft/structure/village/savanna/streets/straight_04.nbt b/data/minecraft/structure/village/savanna/streets/straight_04.nbt index 6961b6af..b5a40f97 100644 --- a/data/minecraft/structure/village/savanna/streets/straight_04.nbt +++ b/data/minecraft/structure/village/savanna/streets/straight_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8d1046694dda5dd17afab0e6daf81248644b012c7d6ed258a4338577e4c31f0f -size 640 +oid sha256:1ab61a4b90de5bf9a861d5e0dc44b97eb035faab013a61d0dc2c0b96f9c6faaf +size 641 diff --git a/data/minecraft/structure/village/savanna/streets/straight_05.nbt b/data/minecraft/structure/village/savanna/streets/straight_05.nbt index 6aa2cb0e..3ac32ab7 100644 --- a/data/minecraft/structure/village/savanna/streets/straight_05.nbt +++ b/data/minecraft/structure/village/savanna/streets/straight_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7691f1829455f399c9f44f0a6df76807402544fe9636f01b2bb128e19dca7c02 -size 1929 +oid sha256:1e127aa310aba0e4821cc10a365178e924659a2598e6fb4acac64a34f059b08f +size 1931 diff --git a/data/minecraft/structure/village/savanna/streets/straight_06.nbt b/data/minecraft/structure/village/savanna/streets/straight_06.nbt index c36efd5d..15678bb0 100644 --- a/data/minecraft/structure/village/savanna/streets/straight_06.nbt +++ b/data/minecraft/structure/village/savanna/streets/straight_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:81b192dd43cb7444fc8d303425d5efd627e6671b36ad37c878c9bb7572eff2bd -size 1087 +oid sha256:35587d2b9da5b325c46df0429fa9e3288c8d85f0edc5f0e69a0f73ad76698de6 +size 1088 diff --git a/data/minecraft/structure/village/savanna/streets/straight_08.nbt b/data/minecraft/structure/village/savanna/streets/straight_08.nbt index 73da659c..bbbc1bb3 100644 --- a/data/minecraft/structure/village/savanna/streets/straight_08.nbt +++ b/data/minecraft/structure/village/savanna/streets/straight_08.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c72af6afd83cb76e37b95ef3c68addb0f40b08a4757f254c544d734f8cbdc936 -size 939 +oid sha256:fbb646c3636c4dd9722b11310a2f77b09ce6d586cac17d5eda1d40a2e3ccd8c1 +size 940 diff --git a/data/minecraft/structure/village/savanna/streets/straight_09.nbt b/data/minecraft/structure/village/savanna/streets/straight_09.nbt index a0aa47be..f20fdafc 100644 --- a/data/minecraft/structure/village/savanna/streets/straight_09.nbt +++ b/data/minecraft/structure/village/savanna/streets/straight_09.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5c6622bb2d88a5fda2b9d5dcafc000ef99c60c1094e211f85accd4db69743570 -size 1522 +oid sha256:dc6e623be9a695c672924b90b3c41c10302fa55eea1502311ef4a626e270e41a +size 1523 diff --git a/data/minecraft/structure/village/savanna/streets/straight_10.nbt b/data/minecraft/structure/village/savanna/streets/straight_10.nbt index 60efed1f..4cb49415 100644 --- a/data/minecraft/structure/village/savanna/streets/straight_10.nbt +++ b/data/minecraft/structure/village/savanna/streets/straight_10.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cc68c7690880e20fa438c1fcbf8257bd43adeec83f769fc3503030577c5dbdea -size 523 +oid sha256:8d63381a9f3f15b9228a93c58da369027607839f614a396ac40cd7df53e18af2 +size 524 diff --git a/data/minecraft/structure/village/savanna/streets/straight_11.nbt b/data/minecraft/structure/village/savanna/streets/straight_11.nbt index 1c8dd2ea..a08e8ced 100644 --- a/data/minecraft/structure/village/savanna/streets/straight_11.nbt +++ b/data/minecraft/structure/village/savanna/streets/straight_11.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e1363e06d61a5d9efce64e61908afc14237e480b2af8631a4bd282e9b3ecb5b4 -size 1560 +oid sha256:878d68687bc6e191614fa44dab2652a89fb31682d233fe3453f554c617cc73f4 +size 1561 diff --git a/data/minecraft/structure/village/savanna/streets/turn_01.nbt b/data/minecraft/structure/village/savanna/streets/turn_01.nbt index f7d596bc..9c7dfdb3 100644 --- a/data/minecraft/structure/village/savanna/streets/turn_01.nbt +++ b/data/minecraft/structure/village/savanna/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0d3f86c29fba09c9d63a8b4b2dbb6651d689b8867e8270f875bffb81d6155eae -size 1158 +oid sha256:a4d1e5bb6758db3aa351d099bd419b420424b59e0b3e5ae0d380ab1d3e7d4b01 +size 1159 diff --git a/data/minecraft/structure/village/savanna/terminators/terminator_05.nbt b/data/minecraft/structure/village/savanna/terminators/terminator_05.nbt index 29bb8532..b3c150b7 100644 --- a/data/minecraft/structure/village/savanna/terminators/terminator_05.nbt +++ b/data/minecraft/structure/village/savanna/terminators/terminator_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c58d5c5c1ccb3417e76c5ba855cf1595cf43039613d51eb3ede5d16caec45c2f -size 1189 +oid sha256:2b9c697bf2a5a9a174a0b6315b616e5f5ea6cfd0f17176ecc4e485a468c91e9c +size 1190 diff --git a/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_1.nbt b/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_1.nbt index 87adc66d..111f803d 100644 --- a/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_1.nbt +++ b/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4fa51307f3802527e45b9f722dfc4fc346a895bce5e09d0c799dea901bb9b61a -size 3285 +oid sha256:9e2348d5dbcf52f48db98e5fa2b38be3b67bb582dcffb974e285f21e5b6393dc +size 3287 diff --git a/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_2.nbt b/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_2.nbt index 025c95bb..25f37138 100644 --- a/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_2.nbt +++ b/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7edce9cc2f3a09f32243afd801ed65f94189bf3d929d4170bd6141a585d5c342 -size 1118 +oid sha256:8628f5c3347c83c8c908d944857d6fc795e59c4e0a2d9cea2459aac1ee6b2b18 +size 1119 diff --git a/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_3.nbt b/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_3.nbt index 0e0a056d..9f05558a 100644 --- a/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_3.nbt +++ b/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2aac3e5aa473dcfb4135a72055ff1ede0e2f5e954535fe7093e190ee238dc244 -size 980 +oid sha256:2246bdfd4e8f9cfc097e58395b8edba3133d7e73bc5518bf343e5e4989da1f5e +size 981 diff --git a/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_4.nbt b/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_4.nbt index aee9d9b3..b72a6900 100644 --- a/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_4.nbt +++ b/data/minecraft/structure/village/savanna/town_centers/savanna_meeting_point_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a5c9ba856df83e53cc6cfbdaf9775307316ac37fbf6ff84db420564e6e4f3799 -size 1186 +oid sha256:d06594af96aef079e06e4ac5667f10072595fa02261fd7bd9e3d442942d19098 +size 1187 diff --git a/data/minecraft/structure/village/savanna/villagers/baby.nbt b/data/minecraft/structure/village/savanna/villagers/baby.nbt index 76f6c4a8..53611a39 100644 --- a/data/minecraft/structure/village/savanna/villagers/baby.nbt +++ b/data/minecraft/structure/village/savanna/villagers/baby.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2c4e4833a720e90de98add303de10bdca395883f01474606c81a68092a8a1733 -size 752 +oid sha256:465fa4d753bc13719fce28f065c6c4afb9c3f8e70c0c5dbf53648ab104813acd +size 722 diff --git a/data/minecraft/structure/village/savanna/villagers/nitwit.nbt b/data/minecraft/structure/village/savanna/villagers/nitwit.nbt index 540e5ea4..d92f56f3 100644 --- a/data/minecraft/structure/village/savanna/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/savanna/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d19b1d92f3e13af523d8b78dff78d98e8b69c44033df1963f3a6b6a27ca4376e -size 752 +oid sha256:7266f88e934fdfed15037728b17f2360b049e07f3078f1008945c8995e1f61f1 +size 718 diff --git a/data/minecraft/structure/village/savanna/villagers/unemployed.nbt b/data/minecraft/structure/village/savanna/villagers/unemployed.nbt index 8fb25166..5e4e26c3 100644 --- a/data/minecraft/structure/village/savanna/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/savanna/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:83b1164be7542fb3af8bb73f22c426399286e533b46d132ac613b8000b7bc41e -size 750 +oid sha256:8d39d183a08522d626eecc6e1d9114e0aa6978c996a149d017caa9533e266aac +size 717 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_animal_pen_2.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_animal_pen_2.nbt index f4c78cd1..0f874451 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_animal_pen_2.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_animal_pen_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a9216cda87baa83687a478a583aa8e4ed1a175b6e1b9ee30284178f427ab08db +oid sha256:6a04726bbf226998145a88929c50ca4e6871ed19baff16cb0d7a214ef1ac7803 size 3482 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_animal_pen_3.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_animal_pen_3.nbt index 126fbb13..f17f62fe 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_animal_pen_3.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_animal_pen_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a1a208023cbcf2fffcf012761407247453966f113fc7864f9182647db59f4531 -size 1664 +oid sha256:94dc062d5d5605a303acab91f5539b465d31684632237b2bf45f783fe346aca6 +size 1666 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_large_farm_2.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_large_farm_2.nbt index bee938e0..d5ac98d4 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_large_farm_2.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_large_farm_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:856b04b76c52da55940dfc7176d853558e15c1af5ce994717814681d526e4372 -size 2160 +oid sha256:e1040e0a0df8d69bbfaf150bd70f9f43fe6de295dbb37c653559c961c614818e +size 2162 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_medium_house_1.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_medium_house_1.nbt index 9f053cbf..8b8fdce6 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_medium_house_1.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2d5be8a118313f543f2f4838bad493c85e09e63cc9257ecbc9a3b7ab2f151246 -size 3644 +oid sha256:a446acae6343acf22b6f3d2e088c94d1860c33e6197056ce9d7939c1318ebe06 +size 3646 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_medium_house_2.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_medium_house_2.nbt index edf69514..cd2c2028 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_medium_house_2.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1fbdbc0d1df79d69ee75a0009f9d5d0461d45c5c4e53f6edfe7185ecb7a0d9dc -size 1865 +oid sha256:8d230c4b750f029ee6d090d4b3a33034722b06a68a45bf78d1530214ace46df3 +size 1866 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_1.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_1.nbt index 2491ae08..9755a6a5 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_1.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a84afb7f42bcd14a9876826dba4bf27518114e9ec623e4a2d034cb8cad0d8d94 -size 1879 +oid sha256:d0cd759873244d414403d5b96fb6cef73bf75af29acf2096ee009f2765e83e05 +size 1880 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_2.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_2.nbt index 92f38ac8..06511002 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_2.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:19f93a01f40d8122e1527929cbf5020c90b63c02ee200716548a9d152e15209b -size 1876 +oid sha256:02ef7c186a2b4bccb9be8007e05f153065007313c9ed957ff04541e96ac20494 +size 1877 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_3.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_3.nbt index 8ddb2dbe..9774b7ed 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_3.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8abb4d28b35c01ef18b4f268d96467ad4f12843ad94e9eaa83f9c216606051b5 -size 1828 +oid sha256:aee26b94663a803bdbdedf834e6e76aae03c61cbf8469365a5378506b21752b7 +size 1829 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_4.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_4.nbt index a929b8f3..34371cd5 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_4.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:26a76e1e8436d4dec977ee55433b3d58d2520b3b5c1ca406a8d6a15c20b1c02c -size 2709 +oid sha256:395272ebdd88c24167d96ceafab724ca36d882cf2521ec887b37af9c48203f0a +size 2710 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_5.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_5.nbt index 70ae5c50..08c8d943 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_5.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c4e2e67e8c77ee4431a1b4e98dcadb25e36c2eab7d8ec7c7fc5aa4a29312d99 -size 2394 +oid sha256:d8b7949481a57cb186a969777ac6d2818ba14d5a3d0175c1bc1dff6aaa821880 +size 2395 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_6.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_6.nbt index 8d50584f..291d2310 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_6.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:19a598b5e3fec1db695e665c12f041b281c3e2bc61a83fb3e93a0009a46b6017 -size 1792 +oid sha256:f1152a45caf032700acb2899323c0549cb77b024d8573be5155f836dfea39585 +size 1793 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_7.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_7.nbt index 75c011e0..2d6ad302 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_7.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bbf566598703297d44f54436d087c2be3b4241438e9d228b65d84b1d65b1f82b -size 1908 +oid sha256:5e6071f9a93ee0730d122ce9216965262489794e4450fbd827c651243aace78e +size 1909 diff --git a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_8.nbt b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_8.nbt index 569a0dec..7595e5c2 100644 --- a/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_8.nbt +++ b/data/minecraft/structure/village/savanna/zombie/houses/savanna_small_house_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4837462543485f68f0ec80db97ae5d84190ec7163af456c47f181dd0403a10e0 -size 1551 +oid sha256:8f22dca8304008c0a3f22724584b80a5980c16dc333bc96b84870b9084b539be +size 1552 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/corner_01.nbt b/data/minecraft/structure/village/savanna/zombie/streets/corner_01.nbt index 555fc1a8..e7905dad 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/corner_01.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e0d5df53e35a39ac196cecd9bb0872add1ff3cedbe4cc9502c281de46d6f8387 -size 1202 +oid sha256:e62997eee162802e627cbffe28657f1b789c5d9d45f115682e21258dc1b561d2 +size 1204 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/corner_03.nbt b/data/minecraft/structure/village/savanna/zombie/streets/corner_03.nbt index 0f820834..45827fbb 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/corner_03.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/corner_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ed7f996049f9c1a90dad687be72bff2965effaaad15dafc05c07a163a8c4c4e0 -size 356 +oid sha256:0e0b9ac89a85fc09d68342a09212963f8b7955a12f48339a94cc0a3028cd07d7 +size 358 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_02.nbt b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_02.nbt index 5b954a48..b728569c 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a2c0ba9771159e03fa08b24b509b7e9b9b73c34e70f69a5a1dd5fd1ee2ff9c4c -size 631 +oid sha256:0c55d27d35653b2cba4fde74272ead32ae51857328d848549d003eb59a8ac4f4 +size 632 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_03.nbt b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_03.nbt index 1834c860..ec325901 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:36bdef89cce72a821f55775dcec3133f8b2740b148a551bc8e639b184080c94d -size 1229 +oid sha256:f0ed699439f9e7c6101f13ba80949dafc7dedde01110d400fe13634f60c2326e +size 1230 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_04.nbt b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_04.nbt index 88efe968..c43812d3 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_04.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c02bbf0b4fb392021334ee87ea7a6f635a4dae817fe2e5846ecf036105fb793 -size 384 +oid sha256:829d4e4ad354a6c80beaf4e7064b328baea7efd65f4a2b6d3ec2c20e9d26e0f6 +size 385 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_05.nbt b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_05.nbt index 08633664..cbf1667b 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_05.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4d879f2ebc76179acfd5cf0cbf667b01c785b2e8e448ada08a572f6880084d28 -size 415 +oid sha256:eed3253c7726228f6cb54d4e234b5a62635ef9ae15dbb8976bb8bc0249599066 +size 416 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_06.nbt b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_06.nbt index 75d3076a..093d2937 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_06.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:05f5ba726eff993cc63946f334ef4814d0b5b5d5d572282f882aa2f733043882 -size 472 +oid sha256:d8de4f65422a920dd6233bc56a4f86ca36611baf3b432752cd1843623c1587f2 +size 473 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_07.nbt b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_07.nbt index bc64c448..783f0b2e 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/crossroad_07.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/crossroad_07.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:337be6f246b5b7feedc52659c5ca2df89350b663a3dabaf429b77a9bac527256 -size 1384 +oid sha256:1ad087704e48fe4816b0f34d513db536cb74269c66d78a1dfcabe966e4b224a7 +size 1386 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/split_01.nbt b/data/minecraft/structure/village/savanna/zombie/streets/split_01.nbt index c4e5a833..b0bc04d0 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/split_01.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/split_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:701b643a16efb97a2df2e3de0fa3782a401bbf9c1e894beab20274a6b8d3d1b7 +oid sha256:fa55744503790e9c8cbbd7d44bfbd404f4f9bec2ae6a39fe4a0e33418aa1af5c size 530 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/split_02.nbt b/data/minecraft/structure/village/savanna/zombie/streets/split_02.nbt index d5ec72b7..53d1b81e 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/split_02.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/split_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:847818577810845572184f0906dddf8f76e6f06f9874e84909ecd4cdf97b1100 -size 742 +oid sha256:b2815835532b0aca87dfcd204e85be2fefef624b939f0ecd4874b0e190755305 +size 743 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/straight_02.nbt b/data/minecraft/structure/village/savanna/zombie/streets/straight_02.nbt index 84d03453..dbcefae4 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/straight_02.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7426d5463988e04a5e3d2e6c7b3b11049d32ab97d9ed86dbc25c649a1d47c7e4 -size 1129 +oid sha256:0460209ab678ff1bee9a987f01caff2a6035b6067d6372387504af44648b0c65 +size 1130 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/straight_04.nbt b/data/minecraft/structure/village/savanna/zombie/streets/straight_04.nbt index 91e35cc2..b265b693 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/straight_04.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/straight_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:472779db7379b92a12a9aa666c59c8f7f992398af15c560ebd1d33f11583bc83 -size 645 +oid sha256:64b740769c12d7fcc1b226fd6014ca18231b51d4b484b60c9520c455d4e62446 +size 648 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/straight_05.nbt b/data/minecraft/structure/village/savanna/zombie/streets/straight_05.nbt index 8da72021..7c69fff1 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/straight_05.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/straight_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d62c615a5247559228f0745ae40174ff62a65c65f027477a97ab5f8d38d1d3b3 -size 1937 +oid sha256:baa6c184575f8b1c8ddcf52fd4097401fc6f36f5600da0512683f2ec349d6ac1 +size 1938 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/straight_06.nbt b/data/minecraft/structure/village/savanna/zombie/streets/straight_06.nbt index 2be8375f..3de9ad81 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/straight_06.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/straight_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:82e11a5c7616d9ee3b2245ad581526d3e14fe543b4d8cc9baf6add10d7264615 -size 1092 +oid sha256:953dbb21a796bd775ef5ccf82547486f3b78d251d1b43ffdad597bd7939251c5 +size 1094 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/straight_08.nbt b/data/minecraft/structure/village/savanna/zombie/streets/straight_08.nbt index d57f2e68..d0a243b0 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/straight_08.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/straight_08.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:374ff851adcfa5000ad08b3e97277aa714eb6d7db8aef949c2fceadf983cfdf7 -size 944 +oid sha256:ed923567d2e652cbc89407fcf1f6a328610115fd883c05f2593435a4c7f1a3c9 +size 945 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/straight_09.nbt b/data/minecraft/structure/village/savanna/zombie/streets/straight_09.nbt index 0592dbd1..0aeef25f 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/straight_09.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/straight_09.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:52e658d0b2a3e22c8cb5336309f5c09607a8732b2e33021951acb5808c596023 -size 1526 +oid sha256:2411d77d9bc4ab220c9621e47bad91f3824bc9a708230fd1955fb616a41d843b +size 1527 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/straight_10.nbt b/data/minecraft/structure/village/savanna/zombie/streets/straight_10.nbt index f8a2c3f4..04d98983 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/straight_10.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/straight_10.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7727f309c3099541e59be1778d79d6dde07db9d71268805be1e2ff7aba80fee9 -size 529 +oid sha256:37f9eabc32577e5780c3b4963fac216015629f565c08f6d00dd5ac4feefd8dd5 +size 530 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/straight_11.nbt b/data/minecraft/structure/village/savanna/zombie/streets/straight_11.nbt index 5eb352e5..bfa9deaf 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/straight_11.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/straight_11.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:986b9cbe45d7a08fce494d6423c9e3343cb3141be2cdf9d738d6d4e4e8c02146 -size 1567 +oid sha256:0c49f9ac50929522b484e207d88f5930d23402f96b519d07eb3d0dffabb213c5 +size 1569 diff --git a/data/minecraft/structure/village/savanna/zombie/streets/turn_01.nbt b/data/minecraft/structure/village/savanna/zombie/streets/turn_01.nbt index 156d2530..61b7c4ce 100644 --- a/data/minecraft/structure/village/savanna/zombie/streets/turn_01.nbt +++ b/data/minecraft/structure/village/savanna/zombie/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:88da058c6b96399ae37653be2bc25ef4f49596272b284e75b04839cc1b8bd154 -size 1165 +oid sha256:ef383f2ba16a5a45c7c635b5c14c5cf8cbbfdba9b7b73084b8f0b36c66e5c999 +size 1167 diff --git a/data/minecraft/structure/village/savanna/zombie/terminators/terminator_05.nbt b/data/minecraft/structure/village/savanna/zombie/terminators/terminator_05.nbt index f154f69c..ca960304 100644 --- a/data/minecraft/structure/village/savanna/zombie/terminators/terminator_05.nbt +++ b/data/minecraft/structure/village/savanna/zombie/terminators/terminator_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2fdba5f8603c0ce15de8c914f85867e74173a57538d90c56366bbf2710668619 -size 1193 +oid sha256:c0df982a64ad5bc36709edcbff15c03549f11fab9c7749a73b447ad7a349c020 +size 1194 diff --git a/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_1.nbt b/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_1.nbt index 7194c00b..98d3a7a0 100644 --- a/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_1.nbt +++ b/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cde5ed62de5578b026515593b7908a6586af7d134f78e6f88341cc98305382fe -size 3184 +oid sha256:35db10e48e1576b3af6ce13d341726065ef8997f0924b4e9a9ca1720f6fa534d +size 3185 diff --git a/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_2.nbt b/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_2.nbt index a8e1df13..f5742ffb 100644 --- a/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_2.nbt +++ b/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:395bea240a3a75bec8e4f87fe4c13026cd552202219fcb4909a180e259ad371d -size 2712 +oid sha256:6bffc038f1858edeff9c91875516885823d55270c687dc64bcc90ae0bdb90c3e +size 2713 diff --git a/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_3.nbt b/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_3.nbt index ef501643..b0fc49c9 100644 --- a/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_3.nbt +++ b/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b7850447bf4206018ab03589df58ebf9f47aa7c3df69e387c259fb41639a9e00 -size 917 +oid sha256:321425685c02e7f7870ac3fe3c606a83d0f1bfb237cc3de5f0676ffc64727422 +size 919 diff --git a/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_4.nbt b/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_4.nbt index 942a0994..94141f43 100644 --- a/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_4.nbt +++ b/data/minecraft/structure/village/savanna/zombie/town_centers/savanna_meeting_point_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f3aa2c567dbc75e6a87e1d7460d0c9d29fa8560551bc89dbcbe271f560576ba2 -size 1145 +oid sha256:7035ae7c494d72a9e70d4b10b11bc69674edb301bf1a2f888e1ec27f3ee13fe5 +size 1146 diff --git a/data/minecraft/structure/village/savanna/zombie/villagers/nitwit.nbt b/data/minecraft/structure/village/savanna/zombie/villagers/nitwit.nbt index b0e929e8..cc3f2609 100644 --- a/data/minecraft/structure/village/savanna/zombie/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/savanna/zombie/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e8a6e548028f177fb8295db5d53305e99903b27e06c6610e81fb33e1531f05a3 -size 758 +oid sha256:c398248deb06a4df0c278dbd62dcb969016305cf67c616380b67f949657199dc +size 724 diff --git a/data/minecraft/structure/village/savanna/zombie/villagers/unemployed.nbt b/data/minecraft/structure/village/savanna/zombie/villagers/unemployed.nbt index 206d7dfc..ffa97bd1 100644 --- a/data/minecraft/structure/village/savanna/zombie/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/savanna/zombie/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8b8379e3f9eb9e25bd7af7660021bfb656b4c2c6f174b09f3e736c5ecd18ff2f -size 756 +oid sha256:fe259aa946d849edd1faf9f266670d9fbf6aa66cdf286ef5a3a349a1d4b6800c +size 723 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_animal_pen_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_animal_pen_1.nbt index c3afec9b..8b9c4c71 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_animal_pen_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_animal_pen_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:96d575be22a6f8ab59747c807e788e9a23e3bb9a9a18f5b0cb713f83ce0fa7e8 -size 1620 +oid sha256:889cc3f301668cf3ae74237e61cb7dc76e6f48be7e17dc802239ad17417819db +size 1622 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_animal_pen_2.nbt b/data/minecraft/structure/village/snowy/houses/snowy_animal_pen_2.nbt index 05de5ad6..e054b1f9 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_animal_pen_2.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_animal_pen_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2682fbe29a8331f9c1fa7c52127c56d6fa9d88abb2bb084e7b37dbdb9e691d7d -size 1261 +oid sha256:d1b1db0477514ce5ece0e34f3bafee87a9ae6c68f7765c184c57730babedcd1a +size 1262 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_armorer_house_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_armorer_house_1.nbt index 66e633a6..35099a02 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_armorer_house_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_armorer_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f355c0e0e20523db1cf7dce7833c024602a4729c042b399ddae7808a71ed9e79 -size 2190 +oid sha256:99ba17a2a4cd1d1cd6b6fbf96d4be9ff5ae8b68884b7dbf4815f3d5522718c6d +size 2192 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_armorer_house_2.nbt b/data/minecraft/structure/village/snowy/houses/snowy_armorer_house_2.nbt index 296e61f0..6d11b727 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_armorer_house_2.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_armorer_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:095ea71ea27e300ac88fb6f7bab96accc5342a34f44d184cc6bcdf805613647d -size 2068 +oid sha256:7e8569cf2747b328fa0487e3dde0a9c306ba10831ac87dd0e4a6f11252bbc886 +size 2070 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_butchers_shop_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_butchers_shop_1.nbt index 7f2dfdb9..e8c8db44 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_butchers_shop_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_butchers_shop_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f443b17a966a6c35654642f118b45d45d0f572749405eb37c571fd6ba066059e -size 2566 +oid sha256:4df78188100afac936a549bd7bf321d6e892ec0ee029015ec40a168bd7ed13b7 +size 2568 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_butchers_shop_2.nbt b/data/minecraft/structure/village/snowy/houses/snowy_butchers_shop_2.nbt index 18b6e0bd..40b9709d 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_butchers_shop_2.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_butchers_shop_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dbabcc4358dace970b90543cc28857e8b1fb6d4acc50f3cdbb9b6780e8dc3f08 +oid sha256:33e43bff0d47c00d88ee0c35815e40b3856b8d3aede52140d7b6cf7a2233e34b size 1463 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_cartographer_house_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_cartographer_house_1.nbt index 21173fed..815517cf 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_cartographer_house_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_cartographer_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dd059e9a08ca45b0d1815adae21a0a6b32ae3f57a37d77d6186e0f1b1fc4fd09 -size 2359 +oid sha256:205e94ae1c228e4418dd6a396dd4db6a4a10c3033ec92c211c06147ab28e81a7 +size 2362 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_farm_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_farm_1.nbt index 0d635f3d..60de297d 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_farm_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_farm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:16479de9178ddc1c89db9630aa51ac85c5e3723eeac03ade3585793d4e3fc7de -size 1252 +oid sha256:6ccdfa1c08f0915d07328747f8518dfcca797c42ead7763ecee418d89cf6ced8 +size 1254 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_farm_2.nbt b/data/minecraft/structure/village/snowy/houses/snowy_farm_2.nbt index e846f875..10f8377b 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_farm_2.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_farm_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:af9df2c038db135ebc671df5759f134dc962cc51a29258802f948be9cc76f0d3 +oid sha256:8cc0e511af21555f49c3e2fe89636c046b957b3a94f9383945a1e1462b1d3004 size 1075 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_fisher_cottage.nbt b/data/minecraft/structure/village/snowy/houses/snowy_fisher_cottage.nbt index e627cdb2..87782b25 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_fisher_cottage.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_fisher_cottage.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:36ad7a93c1f0c1e5f7b7a7336dcb965107baa09aeded6714e8c1489705078c3d -size 2236 +oid sha256:62df4ee3e75384ffb6c97474bb8e2423ffd83c6347906e77edb8df96fbf4d00d +size 2237 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_fletcher_house_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_fletcher_house_1.nbt index 77583c81..886d75cd 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_fletcher_house_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_fletcher_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:78fd9be3cfe83da2a8f614a66d662d64cd6f43160e90bff6d072f4203240c32c -size 2120 +oid sha256:2dd7f5a0dd515bad0f1805af36a14e265fcdae79f5ab647b0eb1e2756dd4851c +size 2122 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_library_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_library_1.nbt index d2469378..f63c8930 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_library_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_library_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4d106efcaba952c4a6b0e32ab6016afb3e608bba01a60c06464507e392b39786 -size 3446 +oid sha256:35e4194cb06fd84398ac9e510452d6ac054724fc3b4a7904ab714a01d12b1623 +size 3447 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_masons_house_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_masons_house_1.nbt index cc25db8c..0da52ed6 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_masons_house_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_masons_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:210d0f4b8864d1b87970d63173703bdc990eded58c3f7a6515a302f7fa61e040 -size 2997 +oid sha256:123d4b716d61af9f49779b8cd5b2ca6d3bf956a21164267096c31568c3f63fc9 +size 2999 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_masons_house_2.nbt b/data/minecraft/structure/village/snowy/houses/snowy_masons_house_2.nbt index cff740ad..a34baae1 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_masons_house_2.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_masons_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dc7c7392becff9a8597be613aa91f1dc499248af1e8b97012f8d33fbf3688ab9 -size 3183 +oid sha256:9bda52382419c63f656a59964128f98dc47edc95ec9923ea5d609c91df41ab8a +size 3186 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_medium_house_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_medium_house_1.nbt index 789e6a47..28dd5bf0 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_medium_house_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0beae5b3722b515c3baf5999dc84d61f26799b7844e747ab0572d612a1ba6720 -size 1593 +oid sha256:0f5ee3fa74ab0eb9434e4d9c7c126f78c4b2f0554d790734ecafb68d5391024a +size 1595 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_medium_house_2.nbt b/data/minecraft/structure/village/snowy/houses/snowy_medium_house_2.nbt index 6b612468..e5ed1525 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_medium_house_2.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6225de4e64629a5417caadd4c2b1442fd0f380eea547103f026d16be6b69f4b8 -size 3531 +oid sha256:9ab3947582e950c02cd9c4902c0152eb38266b51989738b241a6bfb14dcdd814 +size 3532 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_medium_house_3.nbt b/data/minecraft/structure/village/snowy/houses/snowy_medium_house_3.nbt index 290cac6c..0d70b560 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_medium_house_3.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_medium_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:47c60a46bdc3fb3a22705eef926b5e2890b959168f8e338123c2eb27c93d1b09 -size 1205 +oid sha256:b5791986573526860dbc2402b454f59da0963ec28eb50db10051a56f9ff979b2 +size 1206 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_shepherds_house_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_shepherds_house_1.nbt index 25cb70ed..e56e2d55 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_shepherds_house_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_shepherds_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:14e46e7c86de518d4fe5504e3dc6a873dbf0a2b3fad0b6053788fdf2dc8b079c -size 2166 +oid sha256:b4ab16f4afa644888f792be165f791090585208a958adf08f9034bff4a0ab316 +size 2168 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_small_house_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_small_house_1.nbt index 9d9ae88c..e6bd59dd 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_small_house_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:216e73cb66e8a83d61d0894e129a79de402392283d85a09d848c338681594e88 -size 1317 +oid sha256:86ec5f10d87ca7d1747d77c916b50ca5894b5f61b7025caeab2cd1367acbf1ce +size 1318 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_small_house_2.nbt b/data/minecraft/structure/village/snowy/houses/snowy_small_house_2.nbt index 3e289164..6d632816 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_small_house_2.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3cd59bb12c433270ada63e4fdabbe771693d597e24bbc8d424b9f7c4bf1c01c9 -size 2121 +oid sha256:0c15108c9b3fb3e094ea49e3328b6afcf39e860d74aa9d92da364b861dd9e1a1 +size 2123 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_small_house_3.nbt b/data/minecraft/structure/village/snowy/houses/snowy_small_house_3.nbt index 0e3671c8..a5882254 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_small_house_3.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f96d48c3480cb46ff1de97acf42874f53cc7888c4365e475cedafda481712ddb -size 1756 +oid sha256:317960e24cd3cf70ce5f4bad1dbfbe689578787e2dbafbdeaf674df7dc8f969a +size 1757 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_small_house_4.nbt b/data/minecraft/structure/village/snowy/houses/snowy_small_house_4.nbt index 11deb7d4..9f34d66c 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_small_house_4.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ef92dc197d3abfd76a9967d1418d7d8dd1d989ec9be2ac4ec405016e87145315 -size 1601 +oid sha256:5599cd514d10ae97a05ca0f2c6fde0ed8830d92404def616f67309ed35300a55 +size 1602 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_small_house_5.nbt b/data/minecraft/structure/village/snowy/houses/snowy_small_house_5.nbt index 34f1be08..a7a5159f 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_small_house_5.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0ff5e39d9073cb20415356705fc69a2856045cbe0f037f1527a200e66007f510 -size 1140 +oid sha256:0407d5821085e958ccae536a8856be87adca8234ab70e933a58171e9239df6fe +size 1141 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_small_house_6.nbt b/data/minecraft/structure/village/snowy/houses/snowy_small_house_6.nbt index 7d95c072..0f7eb51d 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_small_house_6.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_small_house_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2b54883e6a8db4a0f17d8a50a54b0c7f360546c103f72d7daef8df64420f7786 -size 2213 +oid sha256:1c1f5cb7cbfcd01de9cc7ce310d95725b256b089314ffec8a27e2b7e65f8e380 +size 2216 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_small_house_7.nbt b/data/minecraft/structure/village/snowy/houses/snowy_small_house_7.nbt index c7d11540..d3888d49 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_small_house_7.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_small_house_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9eeada7420003812881229e9d1e430232f9f8ce6ec7050a608847d2221723535 -size 1617 +oid sha256:02a9ee2aae7dd712d313ceecb6d5368283e6815564d79996129117cabcd3198e +size 1619 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_small_house_8.nbt b/data/minecraft/structure/village/snowy/houses/snowy_small_house_8.nbt index 1c178ab0..0ff7b631 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_small_house_8.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_small_house_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:50e37d881b1b10c4f25ff6ee94261af42890a9c05dc867f17cde72c2a6665807 -size 1020 +oid sha256:12a230ec5c66ea6da785bdf378e978637beca05e1d816e18c9448bd180b51cd7 +size 1021 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_tannery_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_tannery_1.nbt index e8dfec5f..d3caffa9 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_tannery_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_tannery_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:513ec510d7878b19a7e505db6ae8ed96ff7682a0c107076848217e549fd31fb6 -size 2973 +oid sha256:ec9c3b45af8702b4bfff89faa6d43fe04cdd5733062aa090b5e67443be8faed9 +size 2975 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_temple_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_temple_1.nbt index eda40b99..6b6d3bbf 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_temple_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_temple_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b346c7b50df37a746e595e9963a0b3d13595ae8c3638a1b0725b47103e1b990d -size 3572 +oid sha256:728d8b8801c523b1bae0065e9fc41a6a20e6ffd91c063b3ddd9e91026d3c2fbc +size 3574 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_tool_smith_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_tool_smith_1.nbt index cef71c22..fd38a1fd 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_tool_smith_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_tool_smith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d9cb9d03496415114d750101bc87de5659965ed857dfb4c0a6e8dade9b993d7e -size 1914 +oid sha256:f87aaa7e44ef0b5a5c5788866632a072a75a023b44b0f85cb9ea7dde698c5aba +size 1915 diff --git a/data/minecraft/structure/village/snowy/houses/snowy_weapon_smith_1.nbt b/data/minecraft/structure/village/snowy/houses/snowy_weapon_smith_1.nbt index 75c4e843..c305b865 100644 --- a/data/minecraft/structure/village/snowy/houses/snowy_weapon_smith_1.nbt +++ b/data/minecraft/structure/village/snowy/houses/snowy_weapon_smith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:53b861b5f0360cef8f9fe07157b6e1e6cf8f79ddf63118c0308c12730dca65fa -size 2755 +oid sha256:548076e7e2f9a21a307fdcc1d4e85178b1bf50b394874c12a9de9a777df7250e +size 2757 diff --git a/data/minecraft/structure/village/snowy/snowy_lamp_post_01.nbt b/data/minecraft/structure/village/snowy/snowy_lamp_post_01.nbt index cfd9b650..31488879 100644 --- a/data/minecraft/structure/village/snowy/snowy_lamp_post_01.nbt +++ b/data/minecraft/structure/village/snowy/snowy_lamp_post_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2184d3629e1f3826cb2f038d3099ad23e6dc660d899b598059f189780c59ba05 -size 378 +oid sha256:7610f9abae41baeed9609642f71d711f530ecd12eb1abc6291e9dfd4c05e20c3 +size 380 diff --git a/data/minecraft/structure/village/snowy/snowy_lamp_post_02.nbt b/data/minecraft/structure/village/snowy/snowy_lamp_post_02.nbt index 5165bc1d..7176e26b 100644 --- a/data/minecraft/structure/village/snowy/snowy_lamp_post_02.nbt +++ b/data/minecraft/structure/village/snowy/snowy_lamp_post_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:eab9937a5cd7696c7346a463d1780227e71651b4e403de1d0c6e555d392dc9a5 -size 356 +oid sha256:80e59bb6c4e6544d1f8f2c0f048537388440f56ca4bfd657155dbdf9f345d72d +size 357 diff --git a/data/minecraft/structure/village/snowy/snowy_lamp_post_03.nbt b/data/minecraft/structure/village/snowy/snowy_lamp_post_03.nbt index 91f1d5a3..14f78e56 100644 --- a/data/minecraft/structure/village/snowy/snowy_lamp_post_03.nbt +++ b/data/minecraft/structure/village/snowy/snowy_lamp_post_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5405c4b9a12de44b78ba02fbc5bbbd3e32a9c5a54d5846bdbf8a7d7090470c25 -size 502 +oid sha256:4e5fa3ed908359b2d97242b2af77d2152abefdaf68eb819c246ad2d6a6e7b5cd +size 504 diff --git a/data/minecraft/structure/village/snowy/streets/corner_01.nbt b/data/minecraft/structure/village/snowy/streets/corner_01.nbt index 016e87d6..ba813243 100644 --- a/data/minecraft/structure/village/snowy/streets/corner_01.nbt +++ b/data/minecraft/structure/village/snowy/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2855242e6dca1f76a1b45c1c05890cdbb9b1e41d6b8ad5f902bb68fd4beed536 +oid sha256:eae12cd8878b53ce079e77cbe91fd3d75920b2d236f6e874ab44e4290164d0ce size 1097 diff --git a/data/minecraft/structure/village/snowy/streets/corner_02.nbt b/data/minecraft/structure/village/snowy/streets/corner_02.nbt index 0c63d560..df5c03fd 100644 --- a/data/minecraft/structure/village/snowy/streets/corner_02.nbt +++ b/data/minecraft/structure/village/snowy/streets/corner_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:81a1ce9aaa29b652f889c3fb1fbba2904d208b627b04e7f2e98302a82790eedc -size 1808 +oid sha256:fe41db9049eacfbe82907b941bba811899217879eff9b1f8e617004689897e58 +size 1809 diff --git a/data/minecraft/structure/village/snowy/streets/corner_03.nbt b/data/minecraft/structure/village/snowy/streets/corner_03.nbt index 1bee7b16..2e8f414d 100644 --- a/data/minecraft/structure/village/snowy/streets/corner_03.nbt +++ b/data/minecraft/structure/village/snowy/streets/corner_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0440c79d51d734c75945a115fcc56115eccd8d64199a8885884c8a5f1bcd1d80 -size 394 +oid sha256:142b44ac9edce32c71d12a0d18b36947ece29adc7fc77db5f06c7af912198336 +size 395 diff --git a/data/minecraft/structure/village/snowy/streets/crossroad_01.nbt b/data/minecraft/structure/village/snowy/streets/crossroad_01.nbt index 6792182c..9411b1e9 100644 --- a/data/minecraft/structure/village/snowy/streets/crossroad_01.nbt +++ b/data/minecraft/structure/village/snowy/streets/crossroad_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2ccb685149573c7b906fb9fa93bdeeef674d2f60d21488f998e767cf1a7e24e5 -size 1919 +oid sha256:c7e9c5148c430cf939f0da405d3c0257994ae541f5816a38ea5947c8247760eb +size 1920 diff --git a/data/minecraft/structure/village/snowy/streets/crossroad_02.nbt b/data/minecraft/structure/village/snowy/streets/crossroad_02.nbt index b8063e31..fd060e88 100644 --- a/data/minecraft/structure/village/snowy/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/snowy/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8443cd11e89cb1183431ee60d67f89fb1a6689501ed4a02db1fa5967c655f4aa -size 1958 +oid sha256:f42959c1672ae900446384e195d90dbdeb3c2f869b44b9f671eafc4cbc8afdeb +size 1959 diff --git a/data/minecraft/structure/village/snowy/streets/crossroad_03.nbt b/data/minecraft/structure/village/snowy/streets/crossroad_03.nbt index 6094ad5c..9daa666f 100644 --- a/data/minecraft/structure/village/snowy/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/snowy/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e02392b03cde16570103e9e218b770fe79fd7abd2bd74b85bd370fa36b6847d -size 2023 +oid sha256:b90941b1cd66facd31f81df414b318e365f8b2f6b5380bba1c582fc17c1d5e35 +size 2024 diff --git a/data/minecraft/structure/village/snowy/streets/crossroad_04.nbt b/data/minecraft/structure/village/snowy/streets/crossroad_04.nbt index df963970..a5703881 100644 --- a/data/minecraft/structure/village/snowy/streets/crossroad_04.nbt +++ b/data/minecraft/structure/village/snowy/streets/crossroad_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:36f441e87d1c539fb15a9e327f8a212e6bd48fae2a43c0dff0b5b3b7f3604613 -size 430 +oid sha256:cf2d81e346c53d45f602c9a60c0a6fc8afb427d3107cf76101911f470e5ad9e3 +size 431 diff --git a/data/minecraft/structure/village/snowy/streets/crossroad_05.nbt b/data/minecraft/structure/village/snowy/streets/crossroad_05.nbt index 3b68f1fa..95630440 100644 --- a/data/minecraft/structure/village/snowy/streets/crossroad_05.nbt +++ b/data/minecraft/structure/village/snowy/streets/crossroad_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8ebf34202d27aac10e2cdb727ccb11d23d776e23e43b65f0405f3c8d11ee29c5 -size 473 +oid sha256:33f37650bd78f5c5aad0acde734312999c6bd83f18a839b22ac30eba62169880 +size 474 diff --git a/data/minecraft/structure/village/snowy/streets/crossroad_06.nbt b/data/minecraft/structure/village/snowy/streets/crossroad_06.nbt index 75d661c8..d36b6b52 100644 --- a/data/minecraft/structure/village/snowy/streets/crossroad_06.nbt +++ b/data/minecraft/structure/village/snowy/streets/crossroad_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9ae0ac25fd74c9f2d3d8371c62d2ad6d3fb23fb68d8ad4710849f260df488700 -size 528 +oid sha256:a38fd4ce74619f104a4e484662e8195edcf8449531197323028e15890f3befa0 +size 529 diff --git a/data/minecraft/structure/village/snowy/streets/square_01.nbt b/data/minecraft/structure/village/snowy/streets/square_01.nbt index e8c1156f..b101ab71 100644 --- a/data/minecraft/structure/village/snowy/streets/square_01.nbt +++ b/data/minecraft/structure/village/snowy/streets/square_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:32dd75f70ee32b11c23e0578dde4aee56f726735208fbe6b97bcd817aa0fe405 -size 1510 +oid sha256:67f1ce60794045cc19e17b220959e3e26aacc5bf29eb5abf2d3dc1461f4b2dce +size 1511 diff --git a/data/minecraft/structure/village/snowy/streets/straight_01.nbt b/data/minecraft/structure/village/snowy/streets/straight_01.nbt index 825e387c..a99ef6bf 100644 --- a/data/minecraft/structure/village/snowy/streets/straight_01.nbt +++ b/data/minecraft/structure/village/snowy/streets/straight_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c13405d3763ca009cc060b6751cd288adb5e1b4574668180d34bbd6a93918ef0 -size 1851 +oid sha256:bd87a7748dfa6809c33beae3ba6ff4422003c68bc682171f3b2f58c1b0b995df +size 1853 diff --git a/data/minecraft/structure/village/snowy/streets/straight_02.nbt b/data/minecraft/structure/village/snowy/streets/straight_02.nbt index 8b6a0738..6d845ee4 100644 --- a/data/minecraft/structure/village/snowy/streets/straight_02.nbt +++ b/data/minecraft/structure/village/snowy/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f4801a9e1f5c10c46c6ce35d61de4e74809d4ef44df19f4f0b55efbb355422da -size 1774 +oid sha256:2e8150202e44a191b805b6b583777f62d2022675e1158089067a3793a465a0ef +size 1776 diff --git a/data/minecraft/structure/village/snowy/streets/straight_03.nbt b/data/minecraft/structure/village/snowy/streets/straight_03.nbt index 3774cf6e..a0962e34 100644 --- a/data/minecraft/structure/village/snowy/streets/straight_03.nbt +++ b/data/minecraft/structure/village/snowy/streets/straight_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aead073ac816e2e5131490cae605debf12e5417820f807a3b9454dabfd5bfd37 -size 1218 +oid sha256:fc8983ed37cae678d834b8398a62f45a92ce021631dcf9288e7b04f8852f26a1 +size 1220 diff --git a/data/minecraft/structure/village/snowy/streets/straight_04.nbt b/data/minecraft/structure/village/snowy/streets/straight_04.nbt index a0457502..712156e3 100644 --- a/data/minecraft/structure/village/snowy/streets/straight_04.nbt +++ b/data/minecraft/structure/village/snowy/streets/straight_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ca2f754302c507d01936cb95cddfd2b7c718d712bad0464765bccc528047855e -size 709 +oid sha256:bd70b4221560d38e3b06b9a2674956b44e182e45e72be2d000607e283f0ae6d5 +size 710 diff --git a/data/minecraft/structure/village/snowy/streets/straight_06.nbt b/data/minecraft/structure/village/snowy/streets/straight_06.nbt index bcd63a2c..d776802d 100644 --- a/data/minecraft/structure/village/snowy/streets/straight_06.nbt +++ b/data/minecraft/structure/village/snowy/streets/straight_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a7558600402a590783652789aab03786a27c353168179fe2b140a7ded4152d24 +oid sha256:3c3c252376e1c0dd2f691a10f1846cb11b2bfd69535e394e8d90bf4a713610c4 size 2619 diff --git a/data/minecraft/structure/village/snowy/streets/straight_08.nbt b/data/minecraft/structure/village/snowy/streets/straight_08.nbt index 96c992ff..0da7f212 100644 --- a/data/minecraft/structure/village/snowy/streets/straight_08.nbt +++ b/data/minecraft/structure/village/snowy/streets/straight_08.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8a92382520622f9f6f2588dfbcadda18d90f71e2a0ffd6d998b52c2eb2eeb49d -size 1941 +oid sha256:6baed7ae7c2810dfe03049640d0f187953687bf5ad1e3a43b4e134454acaadae +size 1943 diff --git a/data/minecraft/structure/village/snowy/streets/turn_01.nbt b/data/minecraft/structure/village/snowy/streets/turn_01.nbt index 08aaba26..96976744 100644 --- a/data/minecraft/structure/village/snowy/streets/turn_01.nbt +++ b/data/minecraft/structure/village/snowy/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d364898a576581a76a3891d9f1f1a525f7afa1e22b0e2fd1fb862efb6058e9c -size 1232 +oid sha256:47a108e0a3b1f82496f34e76acb55c020b12982537efeb61b18fd88e76ea960c +size 1234 diff --git a/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_1.nbt b/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_1.nbt index aa6bd119..57e81c54 100644 --- a/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_1.nbt +++ b/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ea0795b8559de5590f16f6ee79747ae62443b8025b4ee94fa321c3997cbc5275 -size 2733 +oid sha256:ad0ebcc20bc453f03e5a898cdc6960d471a725467e6e505d830dafa2ff40b101 +size 2734 diff --git a/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_2.nbt b/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_2.nbt index 66dcfaf3..0903e7a6 100644 --- a/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_2.nbt +++ b/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e4e79daf062f945d5eed5d8e80d00cefb85dbdc5cec82daaef6c81361eb958cd -size 1035 +oid sha256:b5dd557e36624e853b638132ab1ccd28cfb750289c302c0f9467748465554d09 +size 1036 diff --git a/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_3.nbt b/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_3.nbt index 0c21872c..8662d2b4 100644 --- a/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_3.nbt +++ b/data/minecraft/structure/village/snowy/town_centers/snowy_meeting_point_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:af54ea7ab8119fcaa8ee01aa6eb61eac22bd67b01f286aca95cf22ed33a0b638 -size 851 +oid sha256:d6bc46e87f952dc7090c5ec404ed98658d3f4f78cbad906194f5f099e5892181 +size 852 diff --git a/data/minecraft/structure/village/snowy/villagers/baby.nbt b/data/minecraft/structure/village/snowy/villagers/baby.nbt index 006167ae..bf6110dc 100644 --- a/data/minecraft/structure/village/snowy/villagers/baby.nbt +++ b/data/minecraft/structure/village/snowy/villagers/baby.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dbc9300fac8db965d18a67586e42902e41fb69fe71b867f479f406e266267f9a -size 749 +oid sha256:8c71a3a58b5d4db2a9a71154c8080121487ff669480ebca83fecb722769676e0 +size 718 diff --git a/data/minecraft/structure/village/snowy/villagers/nitwit.nbt b/data/minecraft/structure/village/snowy/villagers/nitwit.nbt index 8d9e73a9..03c84afa 100644 --- a/data/minecraft/structure/village/snowy/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/snowy/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a2394060e2c9f012154b6e1c6b528ee1cba4c9c86d2a406d54d9639c14b91438 -size 750 +oid sha256:490fb8742b929854fe7f126b31e2943b39e3caf493d6163e7d9a64189bde0c1b +size 716 diff --git a/data/minecraft/structure/village/snowy/villagers/unemployed.nbt b/data/minecraft/structure/village/snowy/villagers/unemployed.nbt index 218d9e73..b0f4a7f2 100644 --- a/data/minecraft/structure/village/snowy/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/snowy/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:846e84c74cf0fca21b39f805a3187b3cc78a54076d4f55c7f42d8a9c33cbc252 -size 747 +oid sha256:b7d316571d7f5924febc3fbfc644e9d38bf000fe579eb2a740237247382ac8fa +size 713 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_1.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_1.nbt index ad261152..10921e2b 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_1.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9957b0e7fa599d828ec8c2b5107036bd314d25e406e2ce47dc877164369b4bf2 -size 1600 +oid sha256:fa9103006e0f3841c7c01296eb6e971279e4557b8529c443957334844a3a91e0 +size 1601 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_2.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_2.nbt index 9be848b1..824a9906 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_2.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a31895d930cc5314df2919b092d1acf431b9f2fd4926faf30cbbd29d18c7f9ed -size 3577 +oid sha256:3e6b6679c862252d4273756732ba759d948ed9956978e74975eadd81e070e651 +size 3578 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_3.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_3.nbt index 3ce3df4c..11a6b7f0 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_3.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_medium_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:03638c184954ef75b3ccdc45ebf841dbda5435be241873054ddafcd3f05982f1 -size 1211 +oid sha256:36087303432bcb511bd5f7acd22ef4017de0e6da099ba67473e7f536330d2153 +size 1212 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_1.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_1.nbt index 256c8d88..63a0f38f 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_1.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ff3b01bdfdf278caed71eeb8ae1cfd7b18af0cc88f9dc6b6e2d839145dde1de1 -size 1322 +oid sha256:b3ebe5ae71a0ea71765c7a17372ddc5b0502ef313fd740c904fb91c0da5c34a1 +size 1323 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_2.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_2.nbt index 312ed365..a1b89b17 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_2.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e7bae8fbd6ca80b0706241f362d605bf22d6790c859c697501b270422b7fd886 -size 2138 +oid sha256:aba472c62ca3a895f46be8fe261e890e96ab20f6225a5c26f4c3aeecba96b1fd +size 2141 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_3.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_3.nbt index 54ce9167..6fd00c29 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_3.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:57a2f32758b47f6beb386236fc9687d59b5f9351ef930c34412b50cce5e60999 -size 1812 +oid sha256:3ad0c1bf9f5af447be584cb142353ebe3370ef05af08c535610fb499cc767d40 +size 1813 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_4.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_4.nbt index 729e366b..b37bfcc9 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_4.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5b1f0408f32a9b1d19da4f153ee5101aec482a0914c93eb4284819a1215badcf -size 1608 +oid sha256:21d9cfaf5ab1c151c2aab3ef7095bcc4091c6731149cd62d47af8b8f8a5d0ac6 +size 1609 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_5.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_5.nbt index bced0d9d..fd769650 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_5.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:49c222d2350f09d9b280599edd4556032ab1364880b75d1967650cd1341d36b0 -size 1148 +oid sha256:93ba928b7e3471d2c6fcf2933e1ae4df8eb96eb1b4dc4972c40df58cb2e2ad15 +size 1149 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_6.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_6.nbt index ccd407cc..ed2f9f71 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_6.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3caf4ce41235baa5c464f16f5dce91a9815e54b1e2e4a7553dc79af3a4bb5677 -size 2221 +oid sha256:038383c81eaf95d46420f9d89dfe42c4d925b0f702f78b139bdbed3f2078fb97 +size 2223 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_7.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_7.nbt index 4cdc100a..b387f9c8 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_7.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:999f785d59d2c17434654ef2d6347f824afd0381a7aa53d429b570844ad43688 -size 1623 +oid sha256:e4ccafb2a0e2dea904bcffc65f155f8bbd866205057d9117d69f5c8611e451fa +size 1625 diff --git a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_8.nbt b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_8.nbt index 1791106a..581ef1f7 100644 --- a/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_8.nbt +++ b/data/minecraft/structure/village/snowy/zombie/houses/snowy_small_house_8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1a6e67b29646ee8365430ef376c0ea15f4ab1ba9aecdcc934d876441da1768b0 -size 859 +oid sha256:dbd0247e3ab9e2b881c2e09519958465c3560d167860da329e38b97529fa19bc +size 860 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/corner_01.nbt b/data/minecraft/structure/village/snowy/zombie/streets/corner_01.nbt index b844df1d..a7ff376b 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/corner_01.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:80f0706046897e4296d6f24cc236768fe1f266449f0b2d89dfcc2c891c91299a +oid sha256:533dead5741ec33a84d305f0a885d912e5cf7521c56a8c95f08a3d59c2a2e1bf size 1107 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/corner_02.nbt b/data/minecraft/structure/village/snowy/zombie/streets/corner_02.nbt index b7d0d400..0d8792ed 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/corner_02.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/corner_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:02ca21b6b9ab98bfa2c28fab9a14b3564171ff8fb118a7b5f45ed3dc40037c47 -size 1814 +oid sha256:99698bd404b4e7aea1ef05ef11d518f751bf09ea89b1cb8b31e0c20a3a0cba6a +size 1816 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/corner_03.nbt b/data/minecraft/structure/village/snowy/zombie/streets/corner_03.nbt index 7fdf26e4..879c7248 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/corner_03.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/corner_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e598c543ad7ecc301202aed6425e7b7dabfbe779fc26624c17fb2f969e3b325 -size 399 +oid sha256:5d14609ef523026073148518403530e5a90a8e1e584d5cf1a1155922e8f90890 +size 400 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_01.nbt b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_01.nbt index adc80863..8f35c7f1 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_01.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4cf07cc0b016cdfaaed6b2e83cbf735640fab06427e6348afb6a2f2f93d682de -size 1924 +oid sha256:937346fed6ba2825fb2f4064c7b21f133f3f581f7679ec5f39bdba543d225424 +size 1925 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_02.nbt b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_02.nbt index 0f289161..24054762 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d5661ab167d586c1d3fcd046a90a9e3b14446f1efcca2c7e4b13170097494c3b -size 1962 +oid sha256:405bdda0da05dec988463e82d2ecf2a5125e4446371f1fcbba6943e60d3e3c82 +size 1963 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_03.nbt b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_03.nbt index 087898e6..65f5ac4a 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6dcb4ad20b7c68ec1600042d2d6ea73dba73df8a7b5556305934b1de2a762f69 -size 2028 +oid sha256:6eef6d5282d21aff74f5e4fcf109e613294af294dce6a00ceb85ec41d8ba65f2 +size 2030 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_04.nbt b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_04.nbt index ab62c013..fb80905e 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_04.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b69cd1f3de74fccd6e7647d70d48e5deeab1f18380fc77613af9dec71c7af687 -size 435 +oid sha256:c328270aeda75cb0c949915410fc7fef3edf934a5cf08d653eff8f839973cd75 +size 436 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_05.nbt b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_05.nbt index 87c8480d..4478894b 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_05.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:07d09e9ab21b4b378dbeef3f3d92b3d27474ab78f05b506c7cb7ceea49876846 -size 477 +oid sha256:fee12ac5ae3865532a8f715172669817d6304119f8ccb34bcf761d8a34733c35 +size 478 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_06.nbt b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_06.nbt index 723da73b..0c61e780 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/crossroad_06.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/crossroad_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d085e6d78232ab000e5ee021c4fc4d842af4065a9e74f751215e36c6a62647fe -size 532 +oid sha256:2492a33cd7bae5d2568783c62954a107cd75fff63d9b77aeaee95f423326de63 +size 533 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/square_01.nbt b/data/minecraft/structure/village/snowy/zombie/streets/square_01.nbt index 4b706cd8..27182697 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/square_01.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/square_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dfab8551ce332f18940e3ad6a6c42185e77cda2dfbc2e0fa4d2642cd69db35ce -size 1515 +oid sha256:b094ffbc5fd918a9b345ee894de6d8fa57debb038321c0cce038d3b64203f914 +size 1517 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/straight_01.nbt b/data/minecraft/structure/village/snowy/zombie/streets/straight_01.nbt index 20452774..b2b22a1a 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/straight_01.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/straight_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:175f330693b6e6491ba1edd4ab352d973dfe2578d82c2d36cbb3077311926952 -size 1856 +oid sha256:9b7628d638d8a6193f6816ecb455582d8623d063bd5f0fe87e0d237b02c7468f +size 1857 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/straight_02.nbt b/data/minecraft/structure/village/snowy/zombie/streets/straight_02.nbt index 08d4b42c..15a9a2fd 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/straight_02.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:eee8f48f9db390d4cef8554d0a6592a619e069dbda24c6c037215ec919352db0 -size 1781 +oid sha256:63d0b33c3d6f3857ef2066167a7ebaaee21fcb5d48f745e3c3bac4439bde59de +size 1782 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/straight_03.nbt b/data/minecraft/structure/village/snowy/zombie/streets/straight_03.nbt index a2c9fea6..feb33057 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/straight_03.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/straight_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ce808c015d60e59eff2448c16d18cb07159e7596e2b34ca31719ea1361ba5b05 -size 1223 +oid sha256:db154e96a88fa55ea84dd3a2e41a16debf62d85b491170f492d2ad884f852ed9 +size 1225 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/straight_04.nbt b/data/minecraft/structure/village/snowy/zombie/streets/straight_04.nbt index 99f25a88..d4546959 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/straight_04.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/straight_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e09e665eea3b65ae8181748470c5621f1cf5421374f242d5ea3eede50a0ec105 -size 718 +oid sha256:7784d9941c79a8a62125981a74c5382a22001591f6ea152a425196426ee5a40c +size 719 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/straight_06.nbt b/data/minecraft/structure/village/snowy/zombie/streets/straight_06.nbt index dc39d82c..b4a5cace 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/straight_06.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/straight_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e86470ff310ebbb8fc1d2741c17c450c57b125c552580e69c1dea655eb0c2a6 -size 2624 +oid sha256:cc8eb3d0043cb31951e064300effb6a699edf426e29c64b571c342da766809b1 +size 2623 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/straight_08.nbt b/data/minecraft/structure/village/snowy/zombie/streets/straight_08.nbt index 941ce7a7..ff9f5224 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/straight_08.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/straight_08.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fe93941a1e7f01dfed1394da61a823a959d8be6035343afb404cc2a0e25ee5d7 -size 1947 +oid sha256:2e066f8d2ced0101a7b28b86b96e013eaa5a68ca47364973c7fbf6eda73a77b5 +size 1948 diff --git a/data/minecraft/structure/village/snowy/zombie/streets/turn_01.nbt b/data/minecraft/structure/village/snowy/zombie/streets/turn_01.nbt index 481db031..b79e065f 100644 --- a/data/minecraft/structure/village/snowy/zombie/streets/turn_01.nbt +++ b/data/minecraft/structure/village/snowy/zombie/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:321f63e294ef8f2b1ba6980d80244a53d3be827b6da8500d8206e760cfe98be0 -size 1237 +oid sha256:ef8f31ec0af3d853ebd1bffd593b42e8cfae640d26d096732cf0829702dd0a05 +size 1238 diff --git a/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_1.nbt b/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_1.nbt index dcbc1f80..c129f1d2 100644 --- a/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_1.nbt +++ b/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:209375b1cbb81b9e23d317ad7697e137785d07ecbf56caf59820725b96daf3b7 -size 2693 +oid sha256:f18cb0ad3302f6b8ad8c8baf1faa3206f7f0a7d2407885ec3b1d8447ff9e82e0 +size 2695 diff --git a/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_2.nbt b/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_2.nbt index 28242dce..72ecf2df 100644 --- a/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_2.nbt +++ b/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a310fb7d5a0dd08d9569789fcc7d796d6bbd34e72dbf88be65343822f96a9d8a -size 990 +oid sha256:a9a2d6cf4c0153c5408dcb9515d0dc0715ffe6fb9d43ca3087263ce085db60b4 +size 991 diff --git a/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_3.nbt b/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_3.nbt index 352480fa..153eec27 100644 --- a/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_3.nbt +++ b/data/minecraft/structure/village/snowy/zombie/town_centers/snowy_meeting_point_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b7673e965b1952cf81770046ec77fe277902b46d86c8e4108dae839c176584f1 -size 816 +oid sha256:e610377e1563df6402132bb3e3ff11ccd02c93f6865e2b185ca886b2d9e886bc +size 817 diff --git a/data/minecraft/structure/village/snowy/zombie/villagers/nitwit.nbt b/data/minecraft/structure/village/snowy/zombie/villagers/nitwit.nbt index 4c6e1303..c9e04efa 100644 --- a/data/minecraft/structure/village/snowy/zombie/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/snowy/zombie/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:202e42682fbf71dc166a423b0ac1b70ff65a382e41c1547f69fad48568da3fde -size 756 +oid sha256:45841e0b3239c3cf422628bc7e8cd836004a0c32333437796db3b8abe73d2cec +size 722 diff --git a/data/minecraft/structure/village/snowy/zombie/villagers/unemployed.nbt b/data/minecraft/structure/village/snowy/zombie/villagers/unemployed.nbt index 2d66ab63..0bee67c7 100644 --- a/data/minecraft/structure/village/snowy/zombie/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/snowy/zombie/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:25db0cd680d6b528e6b329b077725d3275dc65e5d6d9c2e22a957d793ca7097c -size 752 +oid sha256:90a8938f1f997026208dcf59345bfff72a33a1b915aabbd3b01e9b91d88ab0aa +size 719 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_animal_pen_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_animal_pen_1.nbt index eeb390ce..201d6a95 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_animal_pen_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_animal_pen_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1cb7fccdbe5ad5b7fcd245a2d66a8cf2d6209584df42a1c37f1b4d78fe36cb5c -size 2089 +oid sha256:549f409837a833685d18c14b400e725fad5468a962df4a16f82d0aac71964400 +size 2091 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_armorer_2.nbt b/data/minecraft/structure/village/taiga/houses/taiga_armorer_2.nbt index 55e09600..f3cf5ff1 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_armorer_2.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_armorer_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8948cd20f38b88d3c721a0dd1d59a018b0116bc3226d66fb79e4ad2af4b2639c -size 2551 +oid sha256:3a7ce94dab9454c3e3b366a0edfb88c9e107f5587aa8304b92d5c021a7b3663c +size 2578 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_armorer_house_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_armorer_house_1.nbt index a934d00c..245878b2 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_armorer_house_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_armorer_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:780acf8c501706e775cf81a04e87d5d738a5a1a29e7d7911f9aa85f55e2b8736 -size 2072 +oid sha256:d6cd39963a7c152ef309454f04423cfc360be74828a64b0727081021bcff6a95 +size 2073 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_butcher_shop_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_butcher_shop_1.nbt index 4eb345e7..c4c6e7c9 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_butcher_shop_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_butcher_shop_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:62e8b54c6b134cf6de432d6d3dd71b81c04be8c02c39b9e4d1cadc6bca9e8112 -size 3295 +oid sha256:b23079b6304bab7545cf83073b24ff4bb24f632b4b29ed12ba5676d11176d4ea +size 3297 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_cartographer_house_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_cartographer_house_1.nbt index 3ef245c8..c25ec09e 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_cartographer_house_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_cartographer_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e7e721f484a1cfb3dabae7531f873a9e048cccebae486c93ab122aad4c023a0c -size 2606 +oid sha256:edc84afc3b8dbfbb1f861d51ca235634f08bf063401d62133931ae3d0bc4f26f +size 2607 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_fisher_cottage_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_fisher_cottage_1.nbt index 04470658..eac05214 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_fisher_cottage_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_fisher_cottage_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2bda92c1e6213b4a82c28a83fd99a63a5dc97e4318aa23bf4274c14d3326c435 -size 3654 +oid sha256:220fc1f1954320d04a1afa5fb8f0dbe90ab21ca374b42b4b3675d0987e9aefe4 +size 3655 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_fletcher_house_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_fletcher_house_1.nbt index 4e9b8fd6..9fadd9e4 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_fletcher_house_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_fletcher_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4b15104503ef41b5d09eda5a3cd514bd419ea4b1d93e0a844a9ea7bc71e474f7 -size 2767 +oid sha256:69d47efcb4cb0e6bd6ea1bcd3af7a24a65a8741c5b3162e342c828f8a5852ff2 +size 2768 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_large_farm_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_large_farm_1.nbt index 2c949d80..9f43993b 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_large_farm_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_large_farm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a5830e9aad55251df1bab99003a4c1ddc0bebe4a4bd7caa7aba3860a70a5ac57 -size 2212 +oid sha256:05b144bb5dd1aa5a3c916698a72862cbf63bbb6c90f7dd82c79e90eeace41692 +size 2214 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_large_farm_2.nbt b/data/minecraft/structure/village/taiga/houses/taiga_large_farm_2.nbt index 81cd768e..5dbcc56f 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_large_farm_2.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_large_farm_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b8b82bb252b208f593c7f4d4a975a5fcd7b1d41d5c46c2a9f771bf53cce66ae3 -size 1599 +oid sha256:2074c339273ca2c5bd8ae47aa8f37d3d3451540d544a2c9308a878ae39b6f472 +size 1601 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_library_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_library_1.nbt index 7ded1015..fdc99369 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_library_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_library_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8718761124d205b81747955faed77a265d3e3fdf852be914dd763756e98298d9 -size 3446 +oid sha256:891e7cf1cf2f7db8330a661f8a7ff89e8a2ec2d092f3feba19d0772eccb1e07c +size 3448 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_masons_house_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_masons_house_1.nbt index 623a4170..41d8ed7d 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_masons_house_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_masons_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:abc74b5d9d6384dd0dcead2e0fd7c4ef4cd3b77f36c7874f10770a5ad92285e9 -size 2189 +oid sha256:e209b55452c88b253184df33ea908c56d34892ff71949cc3230e69886243f98f +size 2191 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_medium_house_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_medium_house_1.nbt index 0d28c0c1..8470d146 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_medium_house_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c2b389d86edc0b20ccedcdd2c92bb48939b8c48f5874baa9943eec97f79cddaf -size 2836 +oid sha256:529fb5b169e5e80e3f298c156070181741f56fb376ec44889efa794c6caec3d8 +size 2837 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_medium_house_2.nbt b/data/minecraft/structure/village/taiga/houses/taiga_medium_house_2.nbt index 77e0cbae..b67228d0 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_medium_house_2.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:856886b7b9a4351ea421c1da59eb26016717ec3fb55ee1ee702c2f1642ee98a5 -size 2609 +oid sha256:eedbf0bae8f89acd4516a889388e5e4b60542b303dd133f63c28292f7a246edd +size 2611 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_medium_house_3.nbt b/data/minecraft/structure/village/taiga/houses/taiga_medium_house_3.nbt index a618d57e..4cff06ac 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_medium_house_3.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_medium_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e91af1854d387a28efa0aa13cdee1633963894928cd7f397b6d1ad2137949d6 -size 3065 +oid sha256:d7bebc110b48f4d0e7af8ba0fe6a4c0092bdbc8dd32113ee54acc531f7c672ed +size 3067 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_medium_house_4.nbt b/data/minecraft/structure/village/taiga/houses/taiga_medium_house_4.nbt index 2a66dfa3..3732865f 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_medium_house_4.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_medium_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c3db43489ca44bf2e91d6db61d074b328ad0db43c8649a8925cde197da25412f -size 2770 +oid sha256:ffbb3a9bbfa89092b5b5b31d874e80f4f84129e71f828962c880ba05e8465045 +size 2772 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_shepherds_house_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_shepherds_house_1.nbt index 06bd826e..de50f615 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_shepherds_house_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_shepherds_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:781f2f4767487b531d6c388aad75eedb8babfb96fcc7bbc10cc56c14377d1541 -size 3016 +oid sha256:56bb13de46912d9493ef074a2e29bab79b1defa456d62c04952d0f8806b638fa +size 3017 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_small_farm_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_small_farm_1.nbt index da4cf577..12756497 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_small_farm_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_small_farm_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:25a4a2565bcc5b82859a8db69235b799d9d2163de452db326ec56bbf6566b1d8 -size 1256 +oid sha256:1c9d0ac0efd24f3a5eeffbf8fdbe75680a6eb0df48e2d09f56ce9c98dd37e3eb +size 1258 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_small_house_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_small_house_1.nbt index f7fb0044..0c61d799 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_small_house_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:073c860de34f22c0f5c42f88218a4deca651bd90422203b7795f56eb522dd5f2 -size 2382 +oid sha256:66b508edf52e5e1fe236ffd63c708a35eb1a016a1c8e3f82cc56de49dc876643 +size 2375 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_small_house_2.nbt b/data/minecraft/structure/village/taiga/houses/taiga_small_house_2.nbt index 9dc53f60..57322f6a 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_small_house_2.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a6c12c7740748d187d6ecaf053ac79ce707cefdc1fcd645af48b82af2d52505e -size 1775 +oid sha256:f1af4dfc9d02103b0eb655c1974be4a8ee022eb987c19c92ea0c3f04eda2bfd3 +size 1777 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_small_house_3.nbt b/data/minecraft/structure/village/taiga/houses/taiga_small_house_3.nbt index d031e8b4..6c959260 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_small_house_3.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:784ef111b19ae480749dbc6a137c333bfc5c13cbce0fbbfc2681858886061f8c -size 1869 +oid sha256:06e0900e5844cec52e8be348a760a3465d1f1d76488f73288e8a6813d99263e8 +size 1872 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_small_house_4.nbt b/data/minecraft/structure/village/taiga/houses/taiga_small_house_4.nbt index 9c989ed7..75e8653d 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_small_house_4.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:eed21f396713a8d464ea093d89041241a39d979353bd92677e40936fea3ea6a8 -size 1608 +oid sha256:b5add8320c01ea77ef1a1dafbfb2369d75095e6f449d6d269ba6be1ad25e8305 +size 1609 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_small_house_5.nbt b/data/minecraft/structure/village/taiga/houses/taiga_small_house_5.nbt index d16814cb..32db18bb 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_small_house_5.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ffe0afdb038a4e0f6469295aad95e22b7b4d7d5eafd47cc9ac4fecd150bb6bf3 -size 2040 +oid sha256:87865496cb72f493e6679f42c2776fb8cd550c4928d9a2168c7ab5834a5858a8 +size 2042 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_tannery_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_tannery_1.nbt index ed784c5b..753bc33d 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_tannery_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_tannery_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:54a3ba0b12944f6070899b7d3df5f4dd29b2e07b63a5434ede2d42f7af587936 -size 2153 +oid sha256:511e438fb42e146aab0f593566b950c9eae78559efa4843459c445dce30bcd18 +size 2152 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_temple_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_temple_1.nbt index 84d15c1d..ee224fc7 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_temple_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_temple_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:52e486e3f5aee16f1cdba06efffa7771259432cc790302d9aa662ff4f4edd7e5 -size 6644 +oid sha256:4658115f8775edecb9dbb0605e4203983bc5f464a510a1e1435d34e362543155 +size 6645 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_tool_smith_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_tool_smith_1.nbt index 7ed42903..e26722d8 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_tool_smith_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_tool_smith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c97cbcc12eb667571277594af235c508702d36cc6ca9c10264ea2d0e2184bede +oid sha256:222531b230ad73eae0b0964e05536cd61a6295eed3eaa6acb1caffa6ecbe16ba size 2165 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_weaponsmith_1.nbt b/data/minecraft/structure/village/taiga/houses/taiga_weaponsmith_1.nbt index 88ab8c6c..b523056e 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_weaponsmith_1.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_weaponsmith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1b2bf960a44a2c722826f7e420702e6b4151dfdd30841f16abeeb69ad5b3a14c -size 2076 +oid sha256:e9ae382a03b621d534af0e434093ea63e4ae912624298d579f04767ade0130ec +size 2077 diff --git a/data/minecraft/structure/village/taiga/houses/taiga_weaponsmith_2.nbt b/data/minecraft/structure/village/taiga/houses/taiga_weaponsmith_2.nbt index c9183f3b..33a7a8dc 100644 --- a/data/minecraft/structure/village/taiga/houses/taiga_weaponsmith_2.nbt +++ b/data/minecraft/structure/village/taiga/houses/taiga_weaponsmith_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0c026f4f62e4b3257eb51a7497e19047ece0842ed8733e811f95334d36cc15ae -size 1188 +oid sha256:a56f6d01751431334bbefb80b87b94cec0d83f8b6fc6c6365809367682bcc142 +size 1189 diff --git a/data/minecraft/structure/village/taiga/streets/corner_01.nbt b/data/minecraft/structure/village/taiga/streets/corner_01.nbt index 6d33b2b8..c17915f3 100644 --- a/data/minecraft/structure/village/taiga/streets/corner_01.nbt +++ b/data/minecraft/structure/village/taiga/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c8ce5de805c11c5dfe66cde4d5f3a36b09eff19a03e4ede1f539c66abf14ca28 -size 1181 +oid sha256:539a2b2b2d685218c9970b692ea901720562c00acafc3bc7159937ca28de4e77 +size 1182 diff --git a/data/minecraft/structure/village/taiga/streets/corner_02.nbt b/data/minecraft/structure/village/taiga/streets/corner_02.nbt index 9aab37fc..2c2f1628 100644 --- a/data/minecraft/structure/village/taiga/streets/corner_02.nbt +++ b/data/minecraft/structure/village/taiga/streets/corner_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f955910a62e8ffa20e0c19c391289c3744df06f76f6052d55e56c0e12b8a2d4d -size 1182 +oid sha256:00c8fc82089e11cc415c0018a0b40a558b8def6bd27cfa5feb9e24d3f8409fc0 +size 1184 diff --git a/data/minecraft/structure/village/taiga/streets/corner_03.nbt b/data/minecraft/structure/village/taiga/streets/corner_03.nbt index 5a3a84ba..b5ea8ecb 100644 --- a/data/minecraft/structure/village/taiga/streets/corner_03.nbt +++ b/data/minecraft/structure/village/taiga/streets/corner_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d0de2a98ae484de1f911edf0ecfd382d271f01bec9df0ab7b7817b1153e7fe9 -size 349 +oid sha256:962c9ee9e08698631848974c49a3cc5de33f8cab6df0fbd6a9fae872fc2d2ad9 +size 350 diff --git a/data/minecraft/structure/village/taiga/streets/crossroad_01.nbt b/data/minecraft/structure/village/taiga/streets/crossroad_01.nbt index 1f722e2d..36355886 100644 --- a/data/minecraft/structure/village/taiga/streets/crossroad_01.nbt +++ b/data/minecraft/structure/village/taiga/streets/crossroad_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:209012e6a77f3b980ede06a112b6b235a64a9d99fdfd69c237b39635ab4081c3 -size 1213 +oid sha256:d884465c81336c19ee7ae34c1df1fe5b0e6140ec12bf7c8ec5b321e03b845dcb +size 1214 diff --git a/data/minecraft/structure/village/taiga/streets/crossroad_02.nbt b/data/minecraft/structure/village/taiga/streets/crossroad_02.nbt index aac7d2fa..c3ebef6f 100644 --- a/data/minecraft/structure/village/taiga/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/taiga/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e04ff325177a01fc5cfac693ef02fba8bb06344e5ccc48a10cfb5dbd560c050a -size 1158 +oid sha256:add7bfb42dab7ebcf960a775846aba320510458043c1dcb6d633ab09c9d50054 +size 1160 diff --git a/data/minecraft/structure/village/taiga/streets/crossroad_03.nbt b/data/minecraft/structure/village/taiga/streets/crossroad_03.nbt index 04818db7..6427e21b 100644 --- a/data/minecraft/structure/village/taiga/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/taiga/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:14559a38b49ad0646fae2c6734c745d063d20f208d438d2f9ad89c97177de91d -size 1201 +oid sha256:4b579155cdd533da8e0e5c017b408d826ce892fa1c2b9fec257df8b936e2f21c +size 1202 diff --git a/data/minecraft/structure/village/taiga/streets/crossroad_04.nbt b/data/minecraft/structure/village/taiga/streets/crossroad_04.nbt index 33514e39..b8200a62 100644 --- a/data/minecraft/structure/village/taiga/streets/crossroad_04.nbt +++ b/data/minecraft/structure/village/taiga/streets/crossroad_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8a621255c1c623743963eaa61af7ac5b16be8d50a2ca2ef5f7993fdc87bee1c9 -size 435 +oid sha256:53e092fefee1987cc259313dd763eaf2a9abfae78c47c8e8b42c9ff5b1281ca6 +size 436 diff --git a/data/minecraft/structure/village/taiga/streets/crossroad_05.nbt b/data/minecraft/structure/village/taiga/streets/crossroad_05.nbt index 976a0aa2..8fe41994 100644 --- a/data/minecraft/structure/village/taiga/streets/crossroad_05.nbt +++ b/data/minecraft/structure/village/taiga/streets/crossroad_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:051765395bca03ff89b2715c149824f8f196d688d9f1963876040ce91d2e0610 -size 409 +oid sha256:d02462f2ba74f3b63d2df3283be72cc998439695087316c989cd766bfc4ac2db +size 410 diff --git a/data/minecraft/structure/village/taiga/streets/crossroad_06.nbt b/data/minecraft/structure/village/taiga/streets/crossroad_06.nbt index cf4c2110..5abce047 100644 --- a/data/minecraft/structure/village/taiga/streets/crossroad_06.nbt +++ b/data/minecraft/structure/village/taiga/streets/crossroad_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d61f3bfbfee9e23e6ce907d4413ae52300c04586a295fba6f9e51f3d32ad822e -size 469 +oid sha256:46f9228b8debe8acbb9bb6a491f95d690569c20cad6694dd64f8d7266faa2240 +size 470 diff --git a/data/minecraft/structure/village/taiga/streets/straight_01.nbt b/data/minecraft/structure/village/taiga/streets/straight_01.nbt index 961097f4..ab29d32d 100644 --- a/data/minecraft/structure/village/taiga/streets/straight_01.nbt +++ b/data/minecraft/structure/village/taiga/streets/straight_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:878865d5a8df9806d70fb975ea2c5357061491d39b2abb77f63f6d1320eb64cf -size 1130 +oid sha256:fdc0213dff873e5ad43b208819100959f1cfaa228b06db94d4fc6f4a373a3088 +size 1131 diff --git a/data/minecraft/structure/village/taiga/streets/straight_02.nbt b/data/minecraft/structure/village/taiga/streets/straight_02.nbt index 9abe107b..50d743bd 100644 --- a/data/minecraft/structure/village/taiga/streets/straight_02.nbt +++ b/data/minecraft/structure/village/taiga/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:006545685570eef2379c0a17d75b98d941be8cd5f95bcd318e00fbcad7caaee0 -size 1146 +oid sha256:fd884410255d13fd842b44ad1609be8e46ceb6e0ae2c5ed6d0fa0b83643d46f3 +size 1147 diff --git a/data/minecraft/structure/village/taiga/streets/straight_03.nbt b/data/minecraft/structure/village/taiga/streets/straight_03.nbt index 36d62938..17f64b0a 100644 --- a/data/minecraft/structure/village/taiga/streets/straight_03.nbt +++ b/data/minecraft/structure/village/taiga/streets/straight_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:26408def192fc0800a9ab14fea6cf7723b29c755ec607a85d06156c898d70711 -size 775 +oid sha256:30768f0544012ebd8512c973dd6bdd4e06bf1a92086749d9acd986f68ec64b55 +size 776 diff --git a/data/minecraft/structure/village/taiga/streets/straight_04.nbt b/data/minecraft/structure/village/taiga/streets/straight_04.nbt index 3af2f58b..ec48e3e1 100644 --- a/data/minecraft/structure/village/taiga/streets/straight_04.nbt +++ b/data/minecraft/structure/village/taiga/streets/straight_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:068d530c8530ba3e7d1f5d4c2c999266001a7ace0c389b9ad229b1e8ce011b4d -size 686 +oid sha256:7ef1273a6c5bae1d60b6559976b8923bd2dc4aabde112f5016705ac9f91ff027 +size 687 diff --git a/data/minecraft/structure/village/taiga/streets/straight_05.nbt b/data/minecraft/structure/village/taiga/streets/straight_05.nbt index 87fe99d0..fd75fd10 100644 --- a/data/minecraft/structure/village/taiga/streets/straight_05.nbt +++ b/data/minecraft/structure/village/taiga/streets/straight_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0a49023e26fa2ee1b5f2ccaf528b7f99acc993275eb6c9dfa7e44747ee9b17e9 -size 1389 +oid sha256:0b5f43d0b2141f1e316a4ef21e75c6d29482f371daaf4db8553a59f33f8b23fc +size 1390 diff --git a/data/minecraft/structure/village/taiga/streets/straight_06.nbt b/data/minecraft/structure/village/taiga/streets/straight_06.nbt index e9e3f188..63766f1a 100644 --- a/data/minecraft/structure/village/taiga/streets/straight_06.nbt +++ b/data/minecraft/structure/village/taiga/streets/straight_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d3c9ca09ee16ef781c4bdea763fbb527d7e445ba736cfde80a1347984e77232f -size 1702 +oid sha256:861c664b858324d80ac8127bbe1d1bc2487fea9ecbfbc4cfe5595621395dbfb3 +size 1703 diff --git a/data/minecraft/structure/village/taiga/streets/turn_01.nbt b/data/minecraft/structure/village/taiga/streets/turn_01.nbt index b9ea17b8..6b4d056c 100644 --- a/data/minecraft/structure/village/taiga/streets/turn_01.nbt +++ b/data/minecraft/structure/village/taiga/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bb5ef0d11d55d3d2706e6ed29be6e023bc840cb135eaa8cf17daed12d9815de3 -size 788 +oid sha256:80a18e6963368a4184be4226ace4fbfba79dff703f186336479ae571d749e101 +size 789 diff --git a/data/minecraft/structure/village/taiga/taiga_decoration_1.nbt b/data/minecraft/structure/village/taiga/taiga_decoration_1.nbt index f38aa3b2..4be59419 100644 --- a/data/minecraft/structure/village/taiga/taiga_decoration_1.nbt +++ b/data/minecraft/structure/village/taiga/taiga_decoration_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:13a1cf354987059fbe6042e2a4d1e0920247b84940de510b529ee83ffda2ecec -size 421 +oid sha256:ef0000207ef611d224a342fe0c39f57388e582f21f288d770ad1e701e1993906 +size 423 diff --git a/data/minecraft/structure/village/taiga/taiga_decoration_2.nbt b/data/minecraft/structure/village/taiga/taiga_decoration_2.nbt index 8b34f3d0..37f8f8d3 100644 --- a/data/minecraft/structure/village/taiga/taiga_decoration_2.nbt +++ b/data/minecraft/structure/village/taiga/taiga_decoration_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:55d69634f35e7d94aca68ff01c09d9d355b5f86eb29b5f6bb58430e29b2a9e68 -size 367 +oid sha256:8cb8786ab9e3a374e6d4d37ed1a68186d79042598d283730bf2482ba11992411 +size 368 diff --git a/data/minecraft/structure/village/taiga/taiga_decoration_3.nbt b/data/minecraft/structure/village/taiga/taiga_decoration_3.nbt index 25a425ef..ded081b9 100644 --- a/data/minecraft/structure/village/taiga/taiga_decoration_3.nbt +++ b/data/minecraft/structure/village/taiga/taiga_decoration_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fb1cb341541b9ebb5c7d5c6078aeab5b616fe2c77dc1e4a1621b4a106588be80 -size 353 +oid sha256:6b4ec923f618d74f165d4413d3732393c7317b5fc061bf517fe7d6ca86377edf +size 354 diff --git a/data/minecraft/structure/village/taiga/taiga_decoration_4.nbt b/data/minecraft/structure/village/taiga/taiga_decoration_4.nbt index 88c1e927..e6fbe7c6 100644 --- a/data/minecraft/structure/village/taiga/taiga_decoration_4.nbt +++ b/data/minecraft/structure/village/taiga/taiga_decoration_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2b7a1b0289d03da21c546ef3d0969a5a09c493b43b26adc5016c0cd94c62a169 -size 322 +oid sha256:6699d6d5f560774541f1ebf958e89609eb2f2f1a2774cb005cc57ff7da63f7ea +size 324 diff --git a/data/minecraft/structure/village/taiga/taiga_decoration_5.nbt b/data/minecraft/structure/village/taiga/taiga_decoration_5.nbt index f94df639..64cfe04b 100644 --- a/data/minecraft/structure/village/taiga/taiga_decoration_5.nbt +++ b/data/minecraft/structure/village/taiga/taiga_decoration_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2f90553e44c42e616ae39136069b8c4daccbbc7ca17bf4ac405d8330623596ec -size 248 +oid sha256:b229a82414c7196e24bfb793ac71fbc6e84ea290fa3bd0c611abc3b6ee6a6d17 +size 250 diff --git a/data/minecraft/structure/village/taiga/taiga_decoration_6.nbt b/data/minecraft/structure/village/taiga/taiga_decoration_6.nbt index 4051d0ed..c4b87b40 100644 --- a/data/minecraft/structure/village/taiga/taiga_decoration_6.nbt +++ b/data/minecraft/structure/village/taiga/taiga_decoration_6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:461262850a008c7ec51cb8e4375ae5fb2e1b8e648b5e813657ef14dec6afa4d7 -size 470 +oid sha256:7d5df1e5851b40801ef98d7221748bd7fb5222ef6dc629ebd7f4918d53d51e77 +size 471 diff --git a/data/minecraft/structure/village/taiga/taiga_lamp_post_1.nbt b/data/minecraft/structure/village/taiga/taiga_lamp_post_1.nbt index 080c78ea..7fb57577 100644 --- a/data/minecraft/structure/village/taiga/taiga_lamp_post_1.nbt +++ b/data/minecraft/structure/village/taiga/taiga_lamp_post_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0ae95fe29d980f75ea2227adefb2734f9a5487439c62d5c9bef0a030595e62bf -size 251 +oid sha256:e8f40551acd9e44dc33f675360934fa16d8be21132b70cd09976a47d6992b9e5 +size 252 diff --git a/data/minecraft/structure/village/taiga/town_centers/taiga_meeting_point_1.nbt b/data/minecraft/structure/village/taiga/town_centers/taiga_meeting_point_1.nbt index 4e577e7e..8d9eeee3 100644 --- a/data/minecraft/structure/village/taiga/town_centers/taiga_meeting_point_1.nbt +++ b/data/minecraft/structure/village/taiga/town_centers/taiga_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bdbff1b8bd42b5068a95eba33280fdfa873bb82b118c11e0f7866e7dcbaf8207 -size 3946 +oid sha256:d730a7b544cd9d766f794270afa25d08b07595943d836a4889cc4a6e519a012d +size 3948 diff --git a/data/minecraft/structure/village/taiga/town_centers/taiga_meeting_point_2.nbt b/data/minecraft/structure/village/taiga/town_centers/taiga_meeting_point_2.nbt index 20d9bf59..ae18c188 100644 --- a/data/minecraft/structure/village/taiga/town_centers/taiga_meeting_point_2.nbt +++ b/data/minecraft/structure/village/taiga/town_centers/taiga_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8c18dfe1f073c03f2960c6ad85e8f743bd1340af78a9aff96f83bd307aec006b -size 2270 +oid sha256:0b31cac4ceadc9fe8357b531d3039d10687e1a21b715a1e069429e3db4679881 +size 2272 diff --git a/data/minecraft/structure/village/taiga/villagers/baby.nbt b/data/minecraft/structure/village/taiga/villagers/baby.nbt index 4e035ac7..8d4b8782 100644 --- a/data/minecraft/structure/village/taiga/villagers/baby.nbt +++ b/data/minecraft/structure/village/taiga/villagers/baby.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f9ff66f1ffa8eca08e5fe7a4367f76b6c78a9ebfdf27e18f7604c5941c01db78 -size 750 +oid sha256:df971237533ea7e337dc06d228b83544ab9794011dfafed9b6552b83411d43a8 +size 719 diff --git a/data/minecraft/structure/village/taiga/villagers/nitwit.nbt b/data/minecraft/structure/village/taiga/villagers/nitwit.nbt index f82f523a..37a0aff7 100644 --- a/data/minecraft/structure/village/taiga/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/taiga/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:111f0a420e2cf69e2c7af3fefd5d0797d82934f3fabbb4a645719782e8d2928b -size 750 +oid sha256:1bee6145bde4dd406bf5301c472e9c8886df1b0ec80481b9d2ed6633c7d5068e +size 716 diff --git a/data/minecraft/structure/village/taiga/villagers/unemployed.nbt b/data/minecraft/structure/village/taiga/villagers/unemployed.nbt index 2d40b4f7..4e06e993 100644 --- a/data/minecraft/structure/village/taiga/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/taiga/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:abe833aff234a6229fd4b9c3a11c25976943c34e62fcb4fd03a6edddf94d4204 -size 748 +oid sha256:61f99459960376aecf36e787e19f19b67e0ff47c395ac77cb715b462b0ceaedb +size 715 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_cartographer_house_1.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_cartographer_house_1.nbt index 9acbf2ff..2c49c42a 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_cartographer_house_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_cartographer_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:146abda357fbe6ffa7a1da492b74f64fc462872c7d64acb90ff3a861513f7835 -size 2612 +oid sha256:e719a8dccdd507174a0437ff3cacf2a6a42557f7a0261c443c72f31f72700f8b +size 2613 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_fisher_cottage_1.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_fisher_cottage_1.nbt index 48874e10..a40240f5 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_fisher_cottage_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_fisher_cottage_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:32ec0d420abd8377eb788316bbfa4c5755a1e23e077dedf7bcbaf2e9418b4556 -size 3666 +oid sha256:12312d370a03139ba9a7d289b9574f909024fa0928596719fb6303e88711880d +size 3667 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_large_farm_2.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_large_farm_2.nbt index 5ed8158e..c552db8f 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_large_farm_2.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_large_farm_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:55e23067709758427d615b6762987ec62c12e728c93dae438f39be1f043b2f1f -size 1606 +oid sha256:5250f58858b6faabf6b566b7f90c63c3e676d77e093dee5370885426867bb292 +size 1607 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_library_1.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_library_1.nbt index 7a5b49eb..714c427a 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_library_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_library_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bafaed290c22496656660d123b8bb11af0e22a43e6cb0eb084e6b0ae32da49e7 -size 3457 +oid sha256:b73fa901547021debd257c4f0f78dd14b2f7802fdcb779485d110b95ba1e91f8 +size 3460 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_1.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_1.nbt index 36f02063..e2e47429 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c78ade7d996c98aae9b4d5d268390167ad63e9ed0b4ded5f59719f069e3ac942 -size 2789 +oid sha256:70fd036fcd7749352b63ae72bbe652e6741a1db33678fd765412f411c391bd85 +size 2790 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_2.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_2.nbt index 2d7a0ad4..b0c94d18 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_2.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7547d59426b0fa5cdbaa6dbc635c65ea162ca3d645802d81da1b8f8a310d6a2d -size 2606 +oid sha256:db6875c18f6c1925777002a991edff302eb104a3e29cd5447503fceee69b6358 +size 2607 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_3.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_3.nbt index ef8f9e07..77648f12 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_3.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e58f3d0ac48a138e7e3a31c65bdc0ba1c6c0514493308e59a0808684c3d63af7 -size 3069 +oid sha256:ee62c080c0b2443e2d5f8087a205ec9eee326d99ec962298f9073a83765f75f2 +size 3070 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_4.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_4.nbt index d9942e7a..bf220330 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_4.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_medium_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:179c2a74ef9c399a1bddbf324d9328dfecdc549c6a905f7c150422796ad9c5c9 -size 2709 +oid sha256:48f68b6e3cb49a66f89eb7eefe19265c261f882f4164c2fa4a82c1a625a3213e +size 2710 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_shepherds_house_1.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_shepherds_house_1.nbt index 0cb3a4b9..20c59439 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_shepherds_house_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_shepherds_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:826bf5c1dc28b5f4ed1a6f7b1914cb1736612df1454711179fe55eaf061a0b40 -size 3040 +oid sha256:b6fd07194ac4ed7e3d76c5ed596dc90f6bb051b79dab28387ad8a0cfd0ab4506 +size 3041 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_1.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_1.nbt index 8a45a218..23baa9b8 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:66fa5756b2ec60a185620c65583c9da432d36b935c648257db180ed7dce4ba8e -size 2391 +oid sha256:0b3e6f1f317630e33fdf85c9d4b8096f6ba560273d9a89e27321971873a6c7c8 +size 2381 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_2.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_2.nbt index 0ae21864..6530704b 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_2.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:688747b406e0a307f76c6cd32968655e85f2e0b9fbe30659ecd5c15d3830b629 -size 1794 +oid sha256:35936b1d031c8a02d5ecbd1b2d9916b6734d7a4a1fadbe6618934b6f6198065d +size 1796 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_3.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_3.nbt index c5541726..3bd0af58 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_3.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d08ccaf7f05c1afa1218b72ce5596c8d5b2e802a18a2aebf2abd4ed566d04a0a -size 1885 +oid sha256:818178de12417a8c13e0b4c6bfe3bfffa8b19c93b2ba7b8984e9e27d670dede0 +size 1887 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_4.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_4.nbt index 24e19d85..760a682a 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_4.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:21a3a3a63b0eec0f18f0e6adfa7dd84ec75d129062322048e40467a504f0101b -size 1613 +oid sha256:122c580fcc3e9909f0a71dc258e6ccb7c44cc880947413a866759c0d4b91073f +size 1615 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_5.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_5.nbt index 5eb19049..ab919492 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_5.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_small_house_5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:99ca15c95386591ac72592e0af0b09ee6601398418780269aa58e976e359ed8e -size 2047 +oid sha256:49565095d90d046f1fd5ace9fa8dc96f8f82315507c6fec34c811dce4bba2bb2 +size 2049 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_temple_1.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_temple_1.nbt index 84d15c1d..ee224fc7 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_temple_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_temple_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:52e486e3f5aee16f1cdba06efffa7771259432cc790302d9aa662ff4f4edd7e5 -size 6644 +oid sha256:4658115f8775edecb9dbb0605e4203983bc5f464a510a1e1435d34e362543155 +size 6645 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_tool_smith_1.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_tool_smith_1.nbt index d552748d..b54b6abc 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_tool_smith_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_tool_smith_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d79daba7fd915ab4918c78c65c5ae925fe928099f9d1d51cdb995a87b895077c +oid sha256:49eaf03f7adac44823cd5e03e834915b2248c904cc6552c3dd57ec274261edc2 size 2175 diff --git a/data/minecraft/structure/village/taiga/zombie/houses/taiga_weaponsmith_2.nbt b/data/minecraft/structure/village/taiga/zombie/houses/taiga_weaponsmith_2.nbt index b435db70..625aae4e 100644 --- a/data/minecraft/structure/village/taiga/zombie/houses/taiga_weaponsmith_2.nbt +++ b/data/minecraft/structure/village/taiga/zombie/houses/taiga_weaponsmith_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:39cc51e63d2055f5d1d777c2bc541df66c3acf4fa0c5d06a0ee46a891e1ad466 -size 1193 +oid sha256:76ab302220108c91a91310d2029d0f495cd27f4a3b652ae13636cdff09bcb92a +size 1194 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/corner_01.nbt b/data/minecraft/structure/village/taiga/zombie/streets/corner_01.nbt index 4534cc73..5515f34b 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/corner_01.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/corner_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:db3e22cce5813a87ecdefdf58d041c259f4410970cd6ac0c4857f0a95a9f380a -size 1186 +oid sha256:91957e603679a9f595e5b0a62bb2dbb6f94684127adad72afcb110d2b53999b3 +size 1187 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/corner_02.nbt b/data/minecraft/structure/village/taiga/zombie/streets/corner_02.nbt index f222050b..fc75e026 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/corner_02.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/corner_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1bc2565b1f262e917935a51f848a1a492f917028475d9ae421367ced65ee28f5 -size 1189 +oid sha256:a3efc6020cacfb1d028f1074033a4d1a2ca35e7ee8e9f2ccc9088c782431c59a +size 1190 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/corner_03.nbt b/data/minecraft/structure/village/taiga/zombie/streets/corner_03.nbt index 8f8e68da..f9bb2c04 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/corner_03.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/corner_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:33f3740e1934d86156148fba6f4dd2fd01a2080ead2d1e5d7af9d411a6b678e6 -size 354 +oid sha256:567aaa72489dc2aed72bc691819c9130e69752cdf644e43f201fd1abf058ad7f +size 355 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_01.nbt b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_01.nbt index 8df6d027..429f2a4e 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_01.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5b501f51b6f879dbad400abab82651f874001c2b97908b0193a11516a2d165d3 -size 1219 +oid sha256:c0ec99447bd52e15ec78ba9bc668a092df7705eddba44322effa3773a74a8c4c +size 1220 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_02.nbt b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_02.nbt index 474a9767..6d7527ba 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_02.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f7b5eba07f9b20333ca0ab1365838f1d70c1338243c611f0351fef8b0fe7e561 -size 1163 +oid sha256:e7dca079dfa2691e057eddb60dc481f02d2be1a24eb623714818c823af066cde +size 1164 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_03.nbt b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_03.nbt index bec52e73..f08b42ec 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_03.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2a5487900b643ba333f3f97cb422157293372b93ff94e596921b08cfa1e9b4a6 -size 1206 +oid sha256:918346395e8addc5dd12c7371680df7574dfbbd0730da9548e93ffd411d3afee +size 1208 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_04.nbt b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_04.nbt index 8f161e22..b9b97a72 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_04.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5548d160ad5d7aa6ab62b36f80f6e154e24be4d6e0b2a645114f994b24f5bcb3 -size 444 +oid sha256:4d05bf0ab4a59d19cc0c704b9cdf0fa75233499d5ea26f01e83fb897356bff32 +size 445 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_05.nbt b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_05.nbt index 14d844ce..2aa93736 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_05.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ce9c470e5d66b552cde8bb2c24568a939c09ef596835d5be134e0188e0abf2f1 -size 413 +oid sha256:0049934cb3ca90c05596069e3ba616fca29eea3ee96018d43f21ccf92ce6fe5d +size 414 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_06.nbt b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_06.nbt index 335f16f5..7e1335d8 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/crossroad_06.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/crossroad_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d867aaa63f91036c9bef3af9a10e130cff7b02c9dfa01c48c6f6b2fe6fc8d411 -size 475 +oid sha256:9b902f6d11cd16857fa09f46f039c4c64f961741cd5f0bd63e28de3f5bb65db1 +size 476 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/straight_01.nbt b/data/minecraft/structure/village/taiga/zombie/streets/straight_01.nbt index 5cc7826f..45ca057b 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/straight_01.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/straight_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:929b75e90c0a0a49c6b08ab7c631c2a78746889657f55f072f3bbb8a59a7c59c -size 1133 +oid sha256:a56190d78c97a7d319cb95ac2dd5dcab143b7f7ef9366ef3e775528fed60b4a3 +size 1135 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/straight_02.nbt b/data/minecraft/structure/village/taiga/zombie/streets/straight_02.nbt index 385d8d66..1c42f1f5 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/straight_02.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/straight_02.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f59e8e38780b3c2f0984d3009a85de3d43c778cbf8052cc92818e10d7e973245 -size 1150 +oid sha256:fcec4140b15fc5cd74c4e8269fb1af844531f62252ecb1fd1cf36cd5b8fe79c5 +size 1151 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/straight_03.nbt b/data/minecraft/structure/village/taiga/zombie/streets/straight_03.nbt index 0aa10f0d..ec9e7ca8 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/straight_03.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/straight_03.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3d93a6e24268bf0b0e36dde406aa86f9c21bbaa5576844811a483a18e3ade4c4 -size 780 +oid sha256:eced29acc8ab6435279f757c2d2b8194d75a508007f550cd0f43df8d73e17a09 +size 781 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/straight_04.nbt b/data/minecraft/structure/village/taiga/zombie/streets/straight_04.nbt index 2e820c48..b914d2d5 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/straight_04.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/straight_04.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:45400033d91777a7c0fc3240f73c5fcf6cb192612ec4d3b9b650827b7a6f3fa9 -size 691 +oid sha256:a5dccd3fd5b22a4e7dde88e809e579148f2bf4c6e3ff50af205c2a0cbc13d780 +size 693 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/straight_05.nbt b/data/minecraft/structure/village/taiga/zombie/streets/straight_05.nbt index 634b8064..10dcf6f0 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/straight_05.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/straight_05.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:15ff83b1d5b467efcbe921764f243adb7eff5e1fa2e57ba7197f1d6a8e55d641 -size 1394 +oid sha256:f29c0b7d2b9357729f1868e693d61bbbd1d17708977a2b6e031bc7eddcd9c677 +size 1395 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/straight_06.nbt b/data/minecraft/structure/village/taiga/zombie/streets/straight_06.nbt index aede9d83..b35683b9 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/straight_06.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/straight_06.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3f7fa6751217890f6d9fdd06f80df1a8ea2333fccb06d69ed714e1de7ee5392d -size 1707 +oid sha256:e3fbda9e66c6f16bedbfc607bf685a6fccc689c291625543e6bf0d0f4b704c23 +size 1708 diff --git a/data/minecraft/structure/village/taiga/zombie/streets/turn_01.nbt b/data/minecraft/structure/village/taiga/zombie/streets/turn_01.nbt index ef475a95..d7dc128b 100644 --- a/data/minecraft/structure/village/taiga/zombie/streets/turn_01.nbt +++ b/data/minecraft/structure/village/taiga/zombie/streets/turn_01.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:364501318145e2b39b05c9810d49b6bf053526e03e95e430b410126e7aa6a0a7 -size 793 +oid sha256:e3b9717f7681891a890b13e7455e4f6b1206c9ee338886d0c992b7431976cba7 +size 794 diff --git a/data/minecraft/structure/village/taiga/zombie/town_centers/taiga_meeting_point_1.nbt b/data/minecraft/structure/village/taiga/zombie/town_centers/taiga_meeting_point_1.nbt index 2c9e9815..7e773353 100644 --- a/data/minecraft/structure/village/taiga/zombie/town_centers/taiga_meeting_point_1.nbt +++ b/data/minecraft/structure/village/taiga/zombie/town_centers/taiga_meeting_point_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:edb8f26ad7fb63ebc42e6a599dda4668996c92418c0553ac8ffa06f5f126aadc -size 1848 +oid sha256:f10619385474e26ff157bf6871d92d81038f42b55bf3163ba2f616ff29556f2c +size 1849 diff --git a/data/minecraft/structure/village/taiga/zombie/town_centers/taiga_meeting_point_2.nbt b/data/minecraft/structure/village/taiga/zombie/town_centers/taiga_meeting_point_2.nbt index ccf1a270..edf6336c 100644 --- a/data/minecraft/structure/village/taiga/zombie/town_centers/taiga_meeting_point_2.nbt +++ b/data/minecraft/structure/village/taiga/zombie/town_centers/taiga_meeting_point_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c78316d9e315c1a47586ca2a19eac168123c07525aef782f835b715344f27cee -size 2257 +oid sha256:916d1a720f4252f95196f9b1f1e521060d260349995e499d470baae083d0c99d +size 2258 diff --git a/data/minecraft/structure/village/taiga/zombie/villagers/nitwit.nbt b/data/minecraft/structure/village/taiga/zombie/villagers/nitwit.nbt index 130be393..7cce4f1d 100644 --- a/data/minecraft/structure/village/taiga/zombie/villagers/nitwit.nbt +++ b/data/minecraft/structure/village/taiga/zombie/villagers/nitwit.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:76898c4fe76eaaa4fade9c3a47c3d0614fe3027938f390d956368a26d814183a -size 755 +oid sha256:8043903746f5e430085ec653217d5a106de13b69221e8695aaaea9169cd1dc50 +size 722 diff --git a/data/minecraft/structure/village/taiga/zombie/villagers/unemployed.nbt b/data/minecraft/structure/village/taiga/zombie/villagers/unemployed.nbt index 0311ed85..cb60b226 100644 --- a/data/minecraft/structure/village/taiga/zombie/villagers/unemployed.nbt +++ b/data/minecraft/structure/village/taiga/zombie/villagers/unemployed.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e017bfc7f607b93b4e4963661b760ae7f56fa27b02532d5213048f3766da9eb6 -size 754 +oid sha256:d72ca363e3e52449889017c3e05e7206eb429b7d10c7825b1d3ba5a20c59884c +size 721 diff --git a/data/minecraft/structure/woodland_mansion/1x1_a1.nbt b/data/minecraft/structure/woodland_mansion/1x1_a1.nbt index 2ba31ea9..874e42b0 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_a1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_a1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fd171ad630984b07fb3cbbb1b1637f3269b28afa28cefead7b19778121a9c80d -size 1433 +oid sha256:b8e35c00c3d8ee10e95d7b1f71966258ec87d48ba964f8e0495d7cccba17474f +size 1434 diff --git a/data/minecraft/structure/woodland_mansion/1x1_a2.nbt b/data/minecraft/structure/woodland_mansion/1x1_a2.nbt index 33a98116..7b7bb45a 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_a2.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_a2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:49141424f6a067b9650d91184958e3bbf31f1556e3b9a58eb1e3571baad7f2c5 -size 1528 +oid sha256:d39db576b29a014bf4f30d25841316496af4cb4c4cbc9e412b11c2e621511822 +size 1529 diff --git a/data/minecraft/structure/woodland_mansion/1x1_a3.nbt b/data/minecraft/structure/woodland_mansion/1x1_a3.nbt index 43ed3643..a83c8c53 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_a3.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_a3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:47af1a8aee6d1baae8a56e0d2e0e7ad41987dc45ab9410dd28fb4c0530fb18c1 -size 1416 +oid sha256:4d927b19460fd7ac297c940408e0475cb006b99c22bca7ec80d8648cb792e7b0 +size 1417 diff --git a/data/minecraft/structure/woodland_mansion/1x1_a4.nbt b/data/minecraft/structure/woodland_mansion/1x1_a4.nbt index e8abd21c..d2b534cf 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_a4.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_a4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c573332682b2e3ceecb8a0bcb67c318c09d103daff4a2064245f353936fe9dea -size 1683 +oid sha256:1e7d96bc47ecb647aedfec7c5edf3157f972b56b2e287c646fe1af2166b2b27d +size 1684 diff --git a/data/minecraft/structure/woodland_mansion/1x1_a5.nbt b/data/minecraft/structure/woodland_mansion/1x1_a5.nbt index 241a66a4..0585725e 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_a5.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_a5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f19de96c803764979da7297e04842e8820046de1cdb9f14354236f1edbdde1ac -size 1491 +oid sha256:166425bb51d7c5e4b25652bdd72afe8b859ab453489bc93bb11be449ec4fe438 +size 1492 diff --git a/data/minecraft/structure/woodland_mansion/1x1_as1.nbt b/data/minecraft/structure/woodland_mansion/1x1_as1.nbt index 540a07c0..749dc3d6 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_as1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_as1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dabddf2a0cb416a3d66f2ab04711dd030024ef2c5c525dfdc7c91c1af6510eef -size 1485 +oid sha256:73735bd37fa03fdd7a840552647613a1da90011bf217dfe39526de1ef8126fdd +size 1486 diff --git a/data/minecraft/structure/woodland_mansion/1x1_as2.nbt b/data/minecraft/structure/woodland_mansion/1x1_as2.nbt index 36e66fdf..99d01853 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_as2.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_as2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:133c541675ce84536cb73143e24e0533024dfea73169f56a36448e581eeb129b -size 1455 +oid sha256:90b085f69e11a09463ab68619cac06d4d1a7a75fd02637d89f141dc3cf522021 +size 1456 diff --git a/data/minecraft/structure/woodland_mansion/1x1_as3.nbt b/data/minecraft/structure/woodland_mansion/1x1_as3.nbt index 19137e9c..6133484b 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_as3.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_as3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:698a3ac6b368eb75c4e02ae9fd0c0124dea81857d0140a145acd96682c82f7bb -size 1211 +oid sha256:3468e7549919c021e1db95f79ae3d9eef8057044ed425f84ccacdbfde2bf17dc +size 1212 diff --git a/data/minecraft/structure/woodland_mansion/1x1_as4.nbt b/data/minecraft/structure/woodland_mansion/1x1_as4.nbt index 194892e8..ccf76a2b 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_as4.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_as4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e9e1433698c6466672884b8c45923f8b6fbec703bc928ca9904e8dbc80da493f -size 1211 +oid sha256:633f100d4ee72bca7423172870861376f0cb24aa6740cebe17cc76b7e79bb1be +size 1212 diff --git a/data/minecraft/structure/woodland_mansion/1x1_b1.nbt b/data/minecraft/structure/woodland_mansion/1x1_b1.nbt index 2aa8805b..66ce7767 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_b1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_b1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ddd8c68bdcc0971a8a6a60531d0423767b0c2d3770e49469e1216656e27e14e2 -size 1924 +oid sha256:0748abbf7e10145d3c613853a1efbdbad6e329e0608746c68dc1fbe1f895413c +size 1925 diff --git a/data/minecraft/structure/woodland_mansion/1x1_b2.nbt b/data/minecraft/structure/woodland_mansion/1x1_b2.nbt index 564eb95b..f02ee3fc 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_b2.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_b2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:51ca20c98f74a620a99952c3402f2e9e3cff053accc3dd1fb1a41cedeb92b796 -size 1864 +oid sha256:95967699cd0cf7dfc01de0c87ffdfc616dbcb446e3c51a4f9f6e88ba63ce04ea +size 1865 diff --git a/data/minecraft/structure/woodland_mansion/1x1_b3.nbt b/data/minecraft/structure/woodland_mansion/1x1_b3.nbt index 5970bcff..02c08203 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_b3.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_b3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6ea7035b019969b102458ee0c5cc74e55ecee320895ede908c2e4ee6ae1fc852 -size 1807 +oid sha256:1ed3a344146b43d2d8a1d8e40b0f52da70186af38c142a390ba3138a763c367f +size 1808 diff --git a/data/minecraft/structure/woodland_mansion/1x1_b4.nbt b/data/minecraft/structure/woodland_mansion/1x1_b4.nbt index 06ace88e..84b97df0 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_b4.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_b4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b807dbb47ba85010935d4a9562e0a3f1461eb979a6e6961fce98458478cda482 -size 1831 +oid sha256:ecff030441310fedc75e0e48757768451711a018c3d127e452a9f5521deda82d +size 1832 diff --git a/data/minecraft/structure/woodland_mansion/1x1_b5.nbt b/data/minecraft/structure/woodland_mansion/1x1_b5.nbt index d74d6cbc..120f6db7 100644 --- a/data/minecraft/structure/woodland_mansion/1x1_b5.nbt +++ b/data/minecraft/structure/woodland_mansion/1x1_b5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:12e2920ff8618ed774eaccbcb2547d44ed9f555623e4a5a1f4a18b1d012f29ae -size 1921 +oid sha256:6783e72c031711138b4ced78d16170c5a83a30be0102d149df991e1d056edefe +size 1923 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a1.nbt b/data/minecraft/structure/woodland_mansion/1x2_a1.nbt index 80fac05c..68f37cf6 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2aeedeaa374c8dfab86add8893aa16febd829e4cf58b2ebcd4b7f3de58706e59 -size 2936 +oid sha256:1a373d9eb2f45088d52dd372ae2a98fea9677835cc10b8fd6177c96004a5fb22 +size 2938 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a2.nbt b/data/minecraft/structure/woodland_mansion/1x2_a2.nbt index bcb850f6..787b1b05 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a2.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:922afe3edde31dfdd2a7992013e0f13350c2bbdaa57254c25bbc113dbaf2a493 -size 2828 +oid sha256:abf0ee7eac1abf5a77dea5260213cfc62ac8505c439865f9a7316ca17c7021c8 +size 2829 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a3.nbt b/data/minecraft/structure/woodland_mansion/1x2_a3.nbt index b52927ed..3d0d5b7e 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a3.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e25fd5de461b1b37d5245f416d9f330f9ce51d02f3430720a06cfb3301038024 -size 2951 +oid sha256:e90f1bd1b7f8c513d5f0a2db1194b2fd6b67edbfe9d970a560705219ce9466f6 +size 2952 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a4.nbt b/data/minecraft/structure/woodland_mansion/1x2_a4.nbt index eac1aca3..f4ad6c07 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a4.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:03cfdab29ea4796f4fcb57b490a0ba91efb7680aff8526e8d6c8378eaaa08b35 -size 2897 +oid sha256:acabca0c4147bc8f0412206d1d897bd15fd0ac4fdf661310dfe5afed10713ba9 +size 2898 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a5.nbt b/data/minecraft/structure/woodland_mansion/1x2_a5.nbt index 90d4dbdc..306316bd 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a5.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:727f23074fe602df1d3cf3379767a513ef3727d1709c991c1c3745e1b62f095c -size 2570 +oid sha256:c180017a011440d463cdba9c12e0529733db7428da1e7c27f51e2867d4324607 +size 2571 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a6.nbt b/data/minecraft/structure/woodland_mansion/1x2_a6.nbt index 2b05c714..7d381fb8 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a6.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a6.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6703de10b58fb841fbab6329870638606c42189441bc22527161b7872a848965 -size 2815 +oid sha256:a4699216cf524212c9dc524add5f528bfbf5c4bd2e0eb41b846c799a1960c42a +size 2810 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a7.nbt b/data/minecraft/structure/woodland_mansion/1x2_a7.nbt index c0a24062..7efe81fc 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a7.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a7.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3abf41cae7656a493042262d53d160bdfe1d823b3d7dd304244877c025f13c8f -size 2948 +oid sha256:47de6e95cd90e3f53ee2c871d50d28a811e8d79326e23c7948064e74f2497cd9 +size 2949 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a8.nbt b/data/minecraft/structure/woodland_mansion/1x2_a8.nbt index fd01d9b4..ed29bc34 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a8.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a8.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7813a786799584d0bf89cbb2a3cc1fa6eac815e62d81d36c25150e21c52ac757 -size 3189 +oid sha256:a34fecc7793ebd453ebc0dbf602a86e4fbd4b5c0ff692d3322acc6dfd919b5b2 +size 3191 diff --git a/data/minecraft/structure/woodland_mansion/1x2_a9.nbt b/data/minecraft/structure/woodland_mansion/1x2_a9.nbt index aaa01528..446227f3 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_a9.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_a9.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a78483c263441ebf36c09a031c11c7ef737557f951a301d267a31584fa4aff50 -size 3095 +oid sha256:6bdc5f04dee01ca2a0ef3e9c842549b9082fcd973ef2328fff8fe1e6a683d405 +size 3096 diff --git a/data/minecraft/structure/woodland_mansion/1x2_b1.nbt b/data/minecraft/structure/woodland_mansion/1x2_b1.nbt index 849a3820..41d0e8d7 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_b1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_b1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f783c953e305f2e528a4d0183538e54402ce487af342458b71f70893f52f2acd -size 3277 +oid sha256:8f116daeaa3f233ae8c09fb26a1397d1a3028eaac891bae03fc7d2c29f2be617 +size 3279 diff --git a/data/minecraft/structure/woodland_mansion/1x2_b2.nbt b/data/minecraft/structure/woodland_mansion/1x2_b2.nbt index 726b44f2..6459d661 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_b2.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_b2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:af4f91dc18fd72cb0594d96645802842661ebabc082432662872ef4c70629cd6 -size 3134 +oid sha256:4b13941be098d1ba86cf08f0eb90a9ea2c2e152c2ee0e08a0907941f449f0e30 +size 3136 diff --git a/data/minecraft/structure/woodland_mansion/1x2_b3.nbt b/data/minecraft/structure/woodland_mansion/1x2_b3.nbt index aa9b1cab..8aceda5b 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_b3.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_b3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1761b19533723dd460b08015425768f03439507dc36349f3b7b00ab4de975055 -size 2793 +oid sha256:81230506b96e7f06506dd1785dc9e00f5a5c5dd9d0958412fa6cc03a6b950f0c +size 2795 diff --git a/data/minecraft/structure/woodland_mansion/1x2_b4.nbt b/data/minecraft/structure/woodland_mansion/1x2_b4.nbt index 2cdc932e..96848b98 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_b4.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_b4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2c0c2dd2f269c3ccf7db620dc3776aff17455876fe4e75af8600e668469a01ad -size 2964 +oid sha256:e17a6edb5fd88b821ce77c4d7afb6cb306a0a1b73d0c780fb1fb0b9eb87443b8 +size 2966 diff --git a/data/minecraft/structure/woodland_mansion/1x2_b5.nbt b/data/minecraft/structure/woodland_mansion/1x2_b5.nbt index 580fddf3..e56cdeb0 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_b5.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_b5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:78a08a4ddb74c01a0f4f0dfa89eb291bb8847777b08fa49b86b60cdf7cb5b74e -size 2408 +oid sha256:28ae058c56dcee187fd8fbe7559e086f026b5abcd7324d5dcb8da24e75b7cc3c +size 2409 diff --git a/data/minecraft/structure/woodland_mansion/1x2_c1.nbt b/data/minecraft/structure/woodland_mansion/1x2_c1.nbt index 63828294..260100ad 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_c1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_c1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ec080da968b4e1bcbd7cacd4d63ae621db1d314aec8d10c32545c0cfe8da9050 -size 3546 +oid sha256:6dd8b2e08865a03b8e8dfc95a4330d0011d47a02be4b6c0d7988c19e36057fd4 +size 3547 diff --git a/data/minecraft/structure/woodland_mansion/1x2_c2.nbt b/data/minecraft/structure/woodland_mansion/1x2_c2.nbt index b9dc10a3..cc2b62ec 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_c2.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_c2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a562b0d2f81a608f967699455d73c1b4c6923ac1fdecc2a665a84fe16c7d1c57 -size 3348 +oid sha256:ecc6729e5c01eda9afa3364ecc347f4bbbe18e55b91cf171150ffd07e3b8cf09 +size 3349 diff --git a/data/minecraft/structure/woodland_mansion/1x2_c3.nbt b/data/minecraft/structure/woodland_mansion/1x2_c3.nbt index 995505f4..062c325b 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_c3.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_c3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dacdeeea660f38f300468569b5e40dd268ebe9398cd3017041ddcaba30fcd98a -size 3617 +oid sha256:3d0f00f5347265061fcd62ed510b5ca7b8e7608cf7a77f397412f4a23d9bb06e +size 3618 diff --git a/data/minecraft/structure/woodland_mansion/1x2_c4.nbt b/data/minecraft/structure/woodland_mansion/1x2_c4.nbt index 5d2b6758..b5430b90 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_c4.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_c4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b9218b8a042b218eb15a00660184b81c40eb2540c8d1037e77bee481817564d4 -size 3620 +oid sha256:84db41ed65110aa325175c192c12dc42ba506f5700fff98ebdc7a981241ae885 +size 3621 diff --git a/data/minecraft/structure/woodland_mansion/1x2_c_stairs.nbt b/data/minecraft/structure/woodland_mansion/1x2_c_stairs.nbt index 937ce284..553a8295 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_c_stairs.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_c_stairs.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8151fc84c1f97b350c08f40451ddac492067475e99c730d596f0aed4cde82be3 -size 6730 +oid sha256:835ba5bf8c353ada27a7100cdf810c3e479ea5fbf18ebbed5fce41d232dc86a0 +size 6731 diff --git a/data/minecraft/structure/woodland_mansion/1x2_d1.nbt b/data/minecraft/structure/woodland_mansion/1x2_d1.nbt index 2f2b4c40..a6da8cd9 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_d1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_d1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b6045f7014c78efe9ab627084d8355c78216cda4a617960e310c7488824bfc3a -size 3733 +oid sha256:5256609a2560a1a6d9134aeef9c6d3b6d4bef7eaf290aad9d4977f344d05be52 +size 3735 diff --git a/data/minecraft/structure/woodland_mansion/1x2_d2.nbt b/data/minecraft/structure/woodland_mansion/1x2_d2.nbt index 40914795..0255c87a 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_d2.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_d2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:647454f9b69380a798c38daae5ea493db7769c62234a02e4c668ea72321e7889 -size 3905 +oid sha256:66e2cfe9e1d8dbdcdb5040ce769c4e8403fe8bcabbd61cf605f48d88d5bfe412 +size 3907 diff --git a/data/minecraft/structure/woodland_mansion/1x2_d3.nbt b/data/minecraft/structure/woodland_mansion/1x2_d3.nbt index 522fb7d3..6936f4d7 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_d3.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_d3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4a3962612c3dfa2ba629e88525bd6eb1b52f40acc734615706ad5a9407f890ea -size 3843 +oid sha256:5e45bec4e7d745e8cee7d4241c63ffe5c5df5168156a5dbdfd4682d36e1a8392 +size 3844 diff --git a/data/minecraft/structure/woodland_mansion/1x2_d4.nbt b/data/minecraft/structure/woodland_mansion/1x2_d4.nbt index d47179b3..c6bbbbd4 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_d4.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_d4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dea09d64c8ac70724dff7f74e688a35c54ef4e508a7a2a0dfa9e3c624d5907c2 -size 3409 +oid sha256:cb617169a410aefa40b21f50cb644aec72caffa59ac44426743b98748420d241 +size 3410 diff --git a/data/minecraft/structure/woodland_mansion/1x2_d5.nbt b/data/minecraft/structure/woodland_mansion/1x2_d5.nbt index 0aae8a3d..25cf2a61 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_d5.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_d5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5523f2b290fdedd095d1fb14c6cf3b3734a936d034eb39971ed244361e5dcaa3 -size 3373 +oid sha256:52d597f17b3d2b41867cca48f3bed21e186512b03a024aafab7de39fd24b91c2 +size 3374 diff --git a/data/minecraft/structure/woodland_mansion/1x2_d_stairs.nbt b/data/minecraft/structure/woodland_mansion/1x2_d_stairs.nbt index a4472221..420c25d6 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_d_stairs.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_d_stairs.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b82627024382c0191aae8f85dae4dc663ac5619b726ab4d7762766990d5cdd1d -size 6625 +oid sha256:45d0103747115f59a72c8d6814db8e5e157a453bd4d80baae1eabadc89860012 +size 6626 diff --git a/data/minecraft/structure/woodland_mansion/1x2_s1.nbt b/data/minecraft/structure/woodland_mansion/1x2_s1.nbt index eafc2170..fb4b8a3e 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_s1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_s1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:922d05b5c9cb2ac0ae87aa4a133a7f886f9a2ebd9255ec1b53553fe26f207844 -size 2687 +oid sha256:6d731c95eb6cbca9a0935331c3df23aaaa45bfaaf92254c6e5f0282ce46b3353 +size 2688 diff --git a/data/minecraft/structure/woodland_mansion/1x2_s2.nbt b/data/minecraft/structure/woodland_mansion/1x2_s2.nbt index 0c40b5e8..dcccd47a 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_s2.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_s2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:18e21efade590ce14a82c552791f38e01cb76d9ffb1c3c625c18c52f3153ed67 -size 2731 +oid sha256:2a68d09014a43f6589e6895003e411f6144297c15db1c88d3d0bf09ce7b3a1d3 +size 2733 diff --git a/data/minecraft/structure/woodland_mansion/1x2_se1.nbt b/data/minecraft/structure/woodland_mansion/1x2_se1.nbt index 8c0be6dd..1416f3eb 100644 --- a/data/minecraft/structure/woodland_mansion/1x2_se1.nbt +++ b/data/minecraft/structure/woodland_mansion/1x2_se1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e2a1d2ff0a5e2bf81e48215a32dd33d6e0da470c46892496ebf6d6b191be4778 -size 3884 +oid sha256:beae3d473369713463b522f0d5c38bc06a688292749ae63d03633bb6f290ab6c +size 3885 diff --git a/data/minecraft/structure/woodland_mansion/2x2_a1.nbt b/data/minecraft/structure/woodland_mansion/2x2_a1.nbt index 6cb04598..bb7b9e2b 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_a1.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_a1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a7f4a2249a1f4f2fc480a97888e52d04f1de07b852aabb083a5e43b1ddbdeeb5 -size 6288 +oid sha256:04d58c08dfe075f11ded73b7668d8d106e5550cd015027bff9d6bfe348fdbc50 +size 6290 diff --git a/data/minecraft/structure/woodland_mansion/2x2_a2.nbt b/data/minecraft/structure/woodland_mansion/2x2_a2.nbt index 9dad075e..5ddaaad4 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_a2.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_a2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6bfde92775a5c540ce59121eb48262ce3dc96d25712eab6ea0b648339d6cca46 -size 5633 +oid sha256:a0cb7495bd0e8f2294a84939b72656b0a16aa657d5ba48432fca8289743e6cbf +size 5634 diff --git a/data/minecraft/structure/woodland_mansion/2x2_a3.nbt b/data/minecraft/structure/woodland_mansion/2x2_a3.nbt index b6af3b66..7637ca29 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_a3.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_a3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5aec6a63730ae450dddfc2c90d2195117b18983ad1897f94fa7dabde816255df -size 5213 +oid sha256:7617035b62691ce6b7413465432214bda764c1546ee9a047221e7f0ac1643f24 +size 5215 diff --git a/data/minecraft/structure/woodland_mansion/2x2_a4.nbt b/data/minecraft/structure/woodland_mansion/2x2_a4.nbt index 55bca64f..70b266e6 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_a4.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_a4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:380db450e9a53999da93930bf485c96e81745ad8be40ebd94df03e0375db105f -size 5409 +oid sha256:e7cb11b424dc3a0834402554ef76098d55cd5430b202ae3830938405ab157064 +size 5410 diff --git a/data/minecraft/structure/woodland_mansion/2x2_b1.nbt b/data/minecraft/structure/woodland_mansion/2x2_b1.nbt index 4f8b22bf..91c4e353 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_b1.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_b1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3df9a8693ada89bfbf3ae6557df4f31e0c34ffcba7f8f6aabe1744c536f42d34 -size 7313 +oid sha256:1477daced5ade3a76cbf49a24eec6ca1758e9c9c1936a2a9691d7a7dd05d2af9 +size 7315 diff --git a/data/minecraft/structure/woodland_mansion/2x2_b2.nbt b/data/minecraft/structure/woodland_mansion/2x2_b2.nbt index ba3e5dc8..16e5e8ee 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_b2.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_b2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1e5fa0eb3469f79a580deec9025df598bc72ff5cf01b596356c7697d833f011b -size 7299 +oid sha256:fc2c7c0768f13e610a50900623e63c058cffd8ba0d8aee96e1c99fcfbfbecf44 +size 7301 diff --git a/data/minecraft/structure/woodland_mansion/2x2_b3.nbt b/data/minecraft/structure/woodland_mansion/2x2_b3.nbt index c971cc43..158c7840 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_b3.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_b3.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:98676b5942b3c9203a7963eccdbdda3c3b610e642cab386bafa4c2e83c90b3e6 -size 7104 +oid sha256:958429b9b420db192a5e04cffb8fe748a2d3a692ae0ae94c6afcf8b22459e707 +size 7105 diff --git a/data/minecraft/structure/woodland_mansion/2x2_b4.nbt b/data/minecraft/structure/woodland_mansion/2x2_b4.nbt index e89682c7..ea18d8d1 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_b4.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_b4.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:29822eb08bf917c6d6ae9befdc02b02babb93a9cb8746d2b227e4b8a2f8e94bd -size 7241 +oid sha256:38734f189d0b8db293590c1a92cfe211009298590d226efd637aea410044c2bf +size 7243 diff --git a/data/minecraft/structure/woodland_mansion/2x2_b5.nbt b/data/minecraft/structure/woodland_mansion/2x2_b5.nbt index 9c40118c..b5a95de1 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_b5.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_b5.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1df49875038766da0731fb619d40949fa076b7059f68acd1a408d94a7b05379e -size 7543 +oid sha256:00297476e57993ea4a84df08fb87e1d85bd8b92f414f488126fdf23ca7442522 +size 7545 diff --git a/data/minecraft/structure/woodland_mansion/2x2_s1.nbt b/data/minecraft/structure/woodland_mansion/2x2_s1.nbt index d0023a38..f814f655 100644 --- a/data/minecraft/structure/woodland_mansion/2x2_s1.nbt +++ b/data/minecraft/structure/woodland_mansion/2x2_s1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3deb8775c012940e41b274c47c4527f3e66010438003fc0ffc05919450024ad5 -size 6794 +oid sha256:13ce04c379c86c7e1fad007bfd69c8ea18a767c5e1f0f99815cd9d2e9676957b +size 6795 diff --git a/data/minecraft/structure/woodland_mansion/carpet_east.nbt b/data/minecraft/structure/woodland_mansion/carpet_east.nbt index b0b6e822..02d3dc31 100644 --- a/data/minecraft/structure/woodland_mansion/carpet_east.nbt +++ b/data/minecraft/structure/woodland_mansion/carpet_east.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6c46b097f16b629c2fa8760ff21c3c46caf805fa23877afe33b5887df21baed6 -size 179 +oid sha256:b2136f216b3d74bf71e766ae3dfc364d3d2d2b9d1bc0f7e7bea85f9a6ad36d1d +size 180 diff --git a/data/minecraft/structure/woodland_mansion/carpet_north.nbt b/data/minecraft/structure/woodland_mansion/carpet_north.nbt index e614961c..22435066 100644 --- a/data/minecraft/structure/woodland_mansion/carpet_north.nbt +++ b/data/minecraft/structure/woodland_mansion/carpet_north.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:22c0b9cdf0c7703b3718a0e236756b49cfde9b9024cb3dafe374e21e79b1b73c -size 176 +oid sha256:8e77119aa1e5e852c331c666503777c492523734bef6470d1a6cb8832b1e92e0 +size 178 diff --git a/data/minecraft/structure/woodland_mansion/carpet_south_1.nbt b/data/minecraft/structure/woodland_mansion/carpet_south_1.nbt index 42abf86d..52c3273b 100644 --- a/data/minecraft/structure/woodland_mansion/carpet_south_1.nbt +++ b/data/minecraft/structure/woodland_mansion/carpet_south_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a0229b7f7e206ee9b0cc6335698ccb756a11c97bab7416a3a4675d95621c5386 -size 720 +oid sha256:60f4b66bceb51ac4a128057d1ca4e3cb1aa0e492e88431bdfc83a686ac8be1e1 +size 721 diff --git a/data/minecraft/structure/woodland_mansion/carpet_south_2.nbt b/data/minecraft/structure/woodland_mansion/carpet_south_2.nbt index 9a614d8f..54102087 100644 --- a/data/minecraft/structure/woodland_mansion/carpet_south_2.nbt +++ b/data/minecraft/structure/woodland_mansion/carpet_south_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:947e74c93f0b33cff6782b2fbd6ccc6ec18636f6dff348405e617f33f830a390 -size 929 +oid sha256:144cd7d83b2cd947a28eb82650bea652db5a84148b9f00fae66f97ec15991114 +size 930 diff --git a/data/minecraft/structure/woodland_mansion/carpet_west_1.nbt b/data/minecraft/structure/woodland_mansion/carpet_west_1.nbt index 29f8f155..d4e758b7 100644 --- a/data/minecraft/structure/woodland_mansion/carpet_west_1.nbt +++ b/data/minecraft/structure/woodland_mansion/carpet_west_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ce9cd233125bdedce1bbbaeb05c95c40264aa0b6e462f186b4ad4ab6578ae75a -size 793 +oid sha256:ff184b5cdbf9a8f6b4c88b9a55bf5265bd8b2233cd403d4f5c2733d53c275190 +size 794 diff --git a/data/minecraft/structure/woodland_mansion/carpet_west_2.nbt b/data/minecraft/structure/woodland_mansion/carpet_west_2.nbt index 645cd2d7..40197632 100644 --- a/data/minecraft/structure/woodland_mansion/carpet_west_2.nbt +++ b/data/minecraft/structure/woodland_mansion/carpet_west_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:61b53c3b1c65e20a30386322f535d4b3e222d23bafca882ee133c0c4cb5d293a +oid sha256:62405d417776d0abd36b0f2a9100d93075de83996a2f76ba5757ee78b5769457 size 1021 diff --git a/data/minecraft/structure/woodland_mansion/corridor_floor.nbt b/data/minecraft/structure/woodland_mansion/corridor_floor.nbt index 90922dd6..e9255d4f 100644 --- a/data/minecraft/structure/woodland_mansion/corridor_floor.nbt +++ b/data/minecraft/structure/woodland_mansion/corridor_floor.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:265b42d4d38041e16a52386ac186da47a38254ed42840a90e0ae3dd3b66e3745 -size 1171 +oid sha256:8fdee78da78f72607946ca110be9f3f383f3bc8d1a9c1ea873fff490bf2fb546 +size 1172 diff --git a/data/minecraft/structure/woodland_mansion/entrance.nbt b/data/minecraft/structure/woodland_mansion/entrance.nbt index e844bc4a..a7405f73 100644 --- a/data/minecraft/structure/woodland_mansion/entrance.nbt +++ b/data/minecraft/structure/woodland_mansion/entrance.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fc8233c37676363070914137aade124107c04fee2f130618a67ef73a0d45d216 -size 18255 +oid sha256:37d955bbd625165646c82c8cdeeec5dcf272ec8f3ca3dc475dbddd033f50485a +size 18256 diff --git a/data/minecraft/structure/woodland_mansion/indoors_door_1.nbt b/data/minecraft/structure/woodland_mansion/indoors_door_1.nbt index b2f742a1..d4c1a2ed 100644 --- a/data/minecraft/structure/woodland_mansion/indoors_door_1.nbt +++ b/data/minecraft/structure/woodland_mansion/indoors_door_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3099f83827cfc9c840a5ebaa305ef98ee7d35aace7ef548cecfe02f6bc6569a7 -size 409 +oid sha256:3184572067ef43d22b6c56eabefdb64550b03cb77caebeec4fbe2ad6fac433c1 +size 410 diff --git a/data/minecraft/structure/woodland_mansion/indoors_door_2.nbt b/data/minecraft/structure/woodland_mansion/indoors_door_2.nbt index 0fa468c8..aff781ea 100644 --- a/data/minecraft/structure/woodland_mansion/indoors_door_2.nbt +++ b/data/minecraft/structure/woodland_mansion/indoors_door_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:305a57a2bae08cdaba8ef9f848a6eb3656f6a4d26f54075aa35b49cf90f06713 -size 504 +oid sha256:b56ab713f0ff5fb9a3fa0d0d1ceb00b11ea45e777a09f15b2a062d0787c60eb9 +size 505 diff --git a/data/minecraft/structure/woodland_mansion/indoors_wall_1.nbt b/data/minecraft/structure/woodland_mansion/indoors_wall_1.nbt index b8c0b40f..d427ab44 100644 --- a/data/minecraft/structure/woodland_mansion/indoors_wall_1.nbt +++ b/data/minecraft/structure/woodland_mansion/indoors_wall_1.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c61f276b31a45e513fb35453ec32485c9d56f3713303305a44b3fca7a6f72331 -size 364 +oid sha256:31d1f4b4ea4ef34623ac13e49d0007c6a4b3db2b0041dada241bc97c931d3ba3 +size 366 diff --git a/data/minecraft/structure/woodland_mansion/indoors_wall_2.nbt b/data/minecraft/structure/woodland_mansion/indoors_wall_2.nbt index c3245ec1..19e0d201 100644 --- a/data/minecraft/structure/woodland_mansion/indoors_wall_2.nbt +++ b/data/minecraft/structure/woodland_mansion/indoors_wall_2.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4fd7bdeeec610fe0274efb195fe4625b0cb70bfacd1da8cc2611e25b1e27de95 -size 441 +oid sha256:1c401e8fa63ed13fc5636b658d019d46d37dee4bc5366472ea44b31ca3cb6766 +size 442 diff --git a/data/minecraft/structure/woodland_mansion/roof.nbt b/data/minecraft/structure/woodland_mansion/roof.nbt index 1edcd712..86b6bd65 100644 --- a/data/minecraft/structure/woodland_mansion/roof.nbt +++ b/data/minecraft/structure/woodland_mansion/roof.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:46eeff7c527f75aee28718d166c3092505b2a354c7c42cbdebdf6c4ec90dc32c -size 332 +oid sha256:b26acb4c0c99d304b677e9c4621113a7c8b79511e42dca93051a4c9b18484f87 +size 333 diff --git a/data/minecraft/structure/woodland_mansion/roof_corner.nbt b/data/minecraft/structure/woodland_mansion/roof_corner.nbt index ebd90ff7..74f68aff 100644 --- a/data/minecraft/structure/woodland_mansion/roof_corner.nbt +++ b/data/minecraft/structure/woodland_mansion/roof_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ed055d130e6dfbce5cb244472fc18131fe31fa46b8a8ec52be31bc411530df74 -size 449 +oid sha256:a515bb0b689c61ba657bf041d675b220f1b2b81269d7bf8cd0e1c483e9fd95f1 +size 450 diff --git a/data/minecraft/structure/woodland_mansion/roof_front.nbt b/data/minecraft/structure/woodland_mansion/roof_front.nbt index 95b7d14c..2ab79e2e 100644 --- a/data/minecraft/structure/woodland_mansion/roof_front.nbt +++ b/data/minecraft/structure/woodland_mansion/roof_front.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2a15bc5ee39ee62152c50c6ca7b6c067e57e988ef2fecd7e35e7a35d9a8ebf7e -size 635 +oid sha256:aebfe73038d68f51202559505764cf12268d5cb0a737888714ace55e34418dae +size 636 diff --git a/data/minecraft/structure/woodland_mansion/roof_inner_corner.nbt b/data/minecraft/structure/woodland_mansion/roof_inner_corner.nbt index 787e55ab..96a1af48 100644 --- a/data/minecraft/structure/woodland_mansion/roof_inner_corner.nbt +++ b/data/minecraft/structure/woodland_mansion/roof_inner_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:22de95103eb90ac31c61aa445d4fd0b14ae37c22bf9af9c6778b36d8a95c6e59 -size 444 +oid sha256:63aa2fa62ad819624a868dd70177026bcb63e404a3d048f3a7231acc8a4727f6 +size 445 diff --git a/data/minecraft/structure/woodland_mansion/small_wall.nbt b/data/minecraft/structure/woodland_mansion/small_wall.nbt index b83c218e..e9518274 100644 --- a/data/minecraft/structure/woodland_mansion/small_wall.nbt +++ b/data/minecraft/structure/woodland_mansion/small_wall.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:63a63fe30baa3a778de017eaa29d83573af56168d0147f80da9a7a3bd79c6bb4 -size 510 +oid sha256:e5a4247489ab3a2e6fdb9841bc04e863d7e4c4355a882e770d673cc4faec797a +size 511 diff --git a/data/minecraft/structure/woodland_mansion/small_wall_corner.nbt b/data/minecraft/structure/woodland_mansion/small_wall_corner.nbt index 94a1be89..e875b3af 100644 --- a/data/minecraft/structure/woodland_mansion/small_wall_corner.nbt +++ b/data/minecraft/structure/woodland_mansion/small_wall_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c3d5d31523ce2cdd4cdbb8f5e021b1a7ba50bbcc4d4bfdb19bcb95d6c70b0d0b -size 261 +oid sha256:bfda42a2839d6c96bec3323a2eccd4549808bea1a14b3eeb7da8db2af5661d1f +size 262 diff --git a/data/minecraft/structure/woodland_mansion/wall_corner.nbt b/data/minecraft/structure/woodland_mansion/wall_corner.nbt index c74d19ad..78581730 100644 --- a/data/minecraft/structure/woodland_mansion/wall_corner.nbt +++ b/data/minecraft/structure/woodland_mansion/wall_corner.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cbe380a4e363d4a64729a773d5c01744cf79b72663f46be8e119c9d6fa3e23a7 -size 307 +oid sha256:e381e5a9d2d21fae441874c15237aa76e41b418a896b43583ca664ffbe433682 +size 308 diff --git a/data/minecraft/structure/woodland_mansion/wall_flat.nbt b/data/minecraft/structure/woodland_mansion/wall_flat.nbt index 4f631b2a..73a54a56 100644 --- a/data/minecraft/structure/woodland_mansion/wall_flat.nbt +++ b/data/minecraft/structure/woodland_mansion/wall_flat.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8f87779b6cb6d188ea3cfee39dc8d470db9173d07b9b6ea1f80d4c24fb55ab16 -size 725 +oid sha256:46acf8bef5b3eb4510cd0128b0def652f35d302de4a983f51c05ed43b1490fb7 +size 727 diff --git a/data/minecraft/structure/woodland_mansion/wall_window.nbt b/data/minecraft/structure/woodland_mansion/wall_window.nbt index 2eb63946..51c4d389 100644 --- a/data/minecraft/structure/woodland_mansion/wall_window.nbt +++ b/data/minecraft/structure/woodland_mansion/wall_window.nbt @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f1e42c9e3738442574194e858bb4429ff79f29b1f6678f5758a9b4b38b10289c -size 829 +oid sha256:ee8a83acde4b6e64134d52810ed51731a05030f139179756ce42af3bb57be079 +size 830 diff --git a/data/minecraft/tags/block/bee_attractive.json b/data/minecraft/tags/block/bee_attractive.json index c6edf1c8..f2851d5d 100644 --- a/data/minecraft/tags/block/bee_attractive.json +++ b/data/minecraft/tags/block/bee_attractive.json @@ -25,7 +25,9 @@ "minecraft:mangrove_propagule", "minecraft:cherry_leaves", "minecraft:pink_petals", + "minecraft:wildflowers", "minecraft:chorus_flower", - "minecraft:spore_blossom" + "minecraft:spore_blossom", + "minecraft:cactus_flower" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/big_dripleaf_placeable.json b/data/minecraft/tags/block/big_dripleaf_placeable.json index 5ef3d369..5285e530 100644 --- a/data/minecraft/tags/block/big_dripleaf_placeable.json +++ b/data/minecraft/tags/block/big_dripleaf_placeable.json @@ -1,7 +1,15 @@ { "values": [ "#minecraft:small_dripleaf_placeable", - "#minecraft:dirt", + "minecraft:dirt", + "minecraft:grass_block", + "minecraft:podzol", + "minecraft:coarse_dirt", + "minecraft:mycelium", + "minecraft:rooted_dirt", + "minecraft:moss_block", + "minecraft:mud", + "minecraft:muddy_mangrove_roots", "minecraft:farmland" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/camels_spawnable_on.json b/data/minecraft/tags/block/camels_spawnable_on.json new file mode 100644 index 00000000..3dd992bb --- /dev/null +++ b/data/minecraft/tags/block/camels_spawnable_on.json @@ -0,0 +1,5 @@ +{ + "values": [ + "#minecraft:sand" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/block/dragon_immune.json b/data/minecraft/tags/block/dragon_immune.json index fe9dfc5e..a04c3db3 100644 --- a/data/minecraft/tags/block/dragon_immune.json +++ b/data/minecraft/tags/block/dragon_immune.json @@ -16,6 +16,8 @@ "minecraft:end_stone", "minecraft:iron_bars", "minecraft:respawn_anchor", - "minecraft:reinforced_deepslate" + "minecraft:reinforced_deepslate", + "minecraft:test_block", + "minecraft:test_instance_block" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/dead_bush_may_place_on.json b/data/minecraft/tags/block/dry_vegetation_may_place_on.json similarity index 60% rename from data/minecraft/tags/block/dead_bush_may_place_on.json rename to data/minecraft/tags/block/dry_vegetation_may_place_on.json index 56f44e1f..ac023d9f 100644 --- a/data/minecraft/tags/block/dead_bush_may_place_on.json +++ b/data/minecraft/tags/block/dry_vegetation_may_place_on.json @@ -2,6 +2,7 @@ "values": [ "#minecraft:sand", "#minecraft:terracotta", - "#minecraft:dirt" + "#minecraft:dirt", + "minecraft:farmland" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/edible_for_sheep.json b/data/minecraft/tags/block/edible_for_sheep.json new file mode 100644 index 00000000..91cc71b0 --- /dev/null +++ b/data/minecraft/tags/block/edible_for_sheep.json @@ -0,0 +1,8 @@ +{ + "values": [ + "minecraft:short_grass", + "minecraft:short_dry_grass", + "minecraft:tall_dry_grass", + "minecraft:fern" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/block/enderman_holdable.json b/data/minecraft/tags/block/enderman_holdable.json index 28a83e79..4454c0ae 100644 --- a/data/minecraft/tags/block/enderman_holdable.json +++ b/data/minecraft/tags/block/enderman_holdable.json @@ -18,6 +18,7 @@ "minecraft:crimson_roots", "minecraft:warped_fungus", "minecraft:warped_nylium", - "minecraft:warped_roots" + "minecraft:warped_roots", + "minecraft:cactus_flower" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/flowers.json b/data/minecraft/tags/block/flowers.json index fa676d19..e0095f65 100644 --- a/data/minecraft/tags/block/flowers.json +++ b/data/minecraft/tags/block/flowers.json @@ -11,7 +11,9 @@ "minecraft:mangrove_propagule", "minecraft:cherry_leaves", "minecraft:pink_petals", + "minecraft:wildflowers", "minecraft:chorus_flower", - "minecraft:spore_blossom" + "minecraft:spore_blossom", + "minecraft:cactus_flower" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/inside_step_sound_blocks.json b/data/minecraft/tags/block/inside_step_sound_blocks.json index bd63a6c1..c376c71d 100644 --- a/data/minecraft/tags/block/inside_step_sound_blocks.json +++ b/data/minecraft/tags/block/inside_step_sound_blocks.json @@ -5,6 +5,8 @@ "minecraft:glow_lichen", "minecraft:lily_pad", "minecraft:small_amethyst_bud", - "minecraft:pink_petals" + "minecraft:pink_petals", + "minecraft:wildflowers", + "minecraft:leaf_litter" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/mineable/axe.json b/data/minecraft/tags/block/mineable/axe.json index 78611b85..62b74b06 100644 --- a/data/minecraft/tags/block/mineable/axe.json +++ b/data/minecraft/tags/block/mineable/axe.json @@ -1,76 +1,43 @@ { "values": [ "minecraft:note_block", - "minecraft:attached_melon_stem", - "minecraft:attached_pumpkin_stem", - "minecraft:azalea", "minecraft:bamboo", "minecraft:barrel", "minecraft:bee_nest", "minecraft:beehive", - "minecraft:beetroots", "minecraft:big_dripleaf_stem", "minecraft:big_dripleaf", "minecraft:bookshelf", "minecraft:brown_mushroom_block", - "minecraft:brown_mushroom", "minecraft:campfire", - "minecraft:carrots", "minecraft:cartography_table", "minecraft:carved_pumpkin", - "minecraft:cave_vines_plant", - "minecraft:cave_vines", "minecraft:chest", "minecraft:chorus_flower", "minecraft:chorus_plant", "minecraft:cocoa", "minecraft:composter", "minecraft:crafting_table", - "minecraft:crimson_fungus", "minecraft:daylight_detector", - "minecraft:dead_bush", - "minecraft:fern", "minecraft:fletching_table", "minecraft:glow_lichen", - "minecraft:short_grass", - "minecraft:hanging_roots", "minecraft:jack_o_lantern", "minecraft:jukebox", "minecraft:ladder", - "minecraft:large_fern", "minecraft:lectern", - "minecraft:lily_pad", "minecraft:loom", - "minecraft:melon_stem", "minecraft:melon", "minecraft:mushroom_stem", - "minecraft:nether_wart", - "minecraft:potatoes", - "minecraft:pumpkin_stem", "minecraft:pumpkin", "minecraft:red_mushroom_block", - "minecraft:red_mushroom", - "minecraft:scaffolding", - "minecraft:small_dripleaf", "minecraft:smithing_table", "minecraft:soul_campfire", - "minecraft:spore_blossom", - "minecraft:sugar_cane", - "minecraft:sweet_berry_bush", - "minecraft:tall_grass", "minecraft:trapped_chest", - "minecraft:twisting_vines_plant", - "minecraft:twisting_vines", "minecraft:vine", - "minecraft:warped_fungus", - "minecraft:weeping_vines_plant", - "minecraft:weeping_vines", - "minecraft:wheat", "#minecraft:banners", "#minecraft:fence_gates", "#minecraft:logs", "#minecraft:planks", - "#minecraft:saplings", "#minecraft:signs", "#minecraft:wooden_buttons", "#minecraft:wooden_doors", diff --git a/data/minecraft/tags/block/mineable/hoe.json b/data/minecraft/tags/block/mineable/hoe.json index 28868bb4..ed7b791a 100644 --- a/data/minecraft/tags/block/mineable/hoe.json +++ b/data/minecraft/tags/block/mineable/hoe.json @@ -1,5 +1,6 @@ { "values": [ + "#minecraft:leaves", "minecraft:nether_wart_block", "minecraft:warped_wart_block", "minecraft:hay_block", @@ -8,16 +9,6 @@ "minecraft:shroomlight", "minecraft:sponge", "minecraft:wet_sponge", - "minecraft:jungle_leaves", - "minecraft:oak_leaves", - "minecraft:spruce_leaves", - "minecraft:pale_oak_leaves", - "minecraft:dark_oak_leaves", - "minecraft:acacia_leaves", - "minecraft:birch_leaves", - "minecraft:azalea_leaves", - "minecraft:flowering_azalea_leaves", - "minecraft:mangrove_leaves", "minecraft:sculk_sensor", "minecraft:calibrated_sculk_sensor", "minecraft:moss_block", @@ -27,8 +18,6 @@ "minecraft:sculk", "minecraft:sculk_catalyst", "minecraft:sculk_vein", - "minecraft:sculk_shrieker", - "minecraft:pink_petals", - "minecraft:cherry_leaves" + "minecraft:sculk_shrieker" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/plays_ambient_desert_block_sounds.json b/data/minecraft/tags/block/plays_ambient_desert_block_sounds.json new file mode 100644 index 00000000..abb97570 --- /dev/null +++ b/data/minecraft/tags/block/plays_ambient_desert_block_sounds.json @@ -0,0 +1,7 @@ +{ + "values": [ + "#minecraft:terracotta", + "minecraft:sand", + "minecraft:red_sand" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/block/replaceable.json b/data/minecraft/tags/block/replaceable.json index 604c412a..da052432 100644 --- a/data/minecraft/tags/block/replaceable.json +++ b/data/minecraft/tags/block/replaceable.json @@ -6,6 +6,9 @@ "minecraft:short_grass", "minecraft:fern", "minecraft:dead_bush", + "minecraft:bush", + "minecraft:short_dry_grass", + "minecraft:tall_dry_grass", "minecraft:seagrass", "minecraft:tall_seagrass", "minecraft:fire", @@ -24,6 +27,7 @@ "minecraft:warped_roots", "minecraft:nether_sprouts", "minecraft:crimson_roots", + "minecraft:leaf_litter", "minecraft:hanging_roots" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/replaceable_by_mushrooms.json b/data/minecraft/tags/block/replaceable_by_mushrooms.json new file mode 100644 index 00000000..d2894adf --- /dev/null +++ b/data/minecraft/tags/block/replaceable_by_mushrooms.json @@ -0,0 +1,35 @@ +{ + "values": [ + "#minecraft:leaves", + "#minecraft:small_flowers", + "minecraft:pale_moss_carpet", + "minecraft:short_grass", + "minecraft:fern", + "minecraft:dead_bush", + "minecraft:vine", + "minecraft:glow_lichen", + "minecraft:sunflower", + "minecraft:lilac", + "minecraft:rose_bush", + "minecraft:peony", + "minecraft:tall_grass", + "minecraft:large_fern", + "minecraft:hanging_roots", + "minecraft:pitcher_plant", + "minecraft:water", + "minecraft:seagrass", + "minecraft:tall_seagrass", + "minecraft:brown_mushroom", + "minecraft:red_mushroom", + "minecraft:brown_mushroom_block", + "minecraft:red_mushroom_block", + "minecraft:warped_roots", + "minecraft:nether_sprouts", + "minecraft:crimson_roots", + "minecraft:leaf_litter", + "minecraft:short_dry_grass", + "minecraft:tall_dry_grass", + "minecraft:bush", + "minecraft:firefly_bush" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/block/replaceable_by_trees.json b/data/minecraft/tags/block/replaceable_by_trees.json index ba17b35c..c04ade87 100644 --- a/data/minecraft/tags/block/replaceable_by_trees.json +++ b/data/minecraft/tags/block/replaceable_by_trees.json @@ -19,8 +19,13 @@ "minecraft:water", "minecraft:seagrass", "minecraft:tall_seagrass", + "minecraft:bush", + "minecraft:firefly_bush", "minecraft:warped_roots", "minecraft:nether_sprouts", - "minecraft:crimson_roots" + "minecraft:crimson_roots", + "minecraft:leaf_litter", + "minecraft:short_dry_grass", + "minecraft:tall_dry_grass" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/sword_efficient.json b/data/minecraft/tags/block/sword_efficient.json index 9f051b23..bdfcc89d 100644 --- a/data/minecraft/tags/block/sword_efficient.json +++ b/data/minecraft/tags/block/sword_efficient.json @@ -1,51 +1,15 @@ { "values": [ "#minecraft:leaves", - "#minecraft:saplings", - "#minecraft:crops", - "minecraft:short_grass", - "minecraft:fern", - "minecraft:dead_bush", "minecraft:vine", "minecraft:glow_lichen", - "minecraft:sunflower", - "minecraft:lilac", - "minecraft:rose_bush", - "minecraft:peony", - "minecraft:tall_grass", - "minecraft:large_fern", - "minecraft:hanging_roots", - "minecraft:pitcher_plant", - "minecraft:brown_mushroom", - "minecraft:red_mushroom", - "minecraft:sugar_cane", "minecraft:pumpkin", "minecraft:carved_pumpkin", "minecraft:jack_o_lantern", "minecraft:melon", - "minecraft:attached_pumpkin_stem", - "minecraft:attached_melon_stem", - "minecraft:lily_pad", "minecraft:cocoa", - "minecraft:pitcher_crop", - "minecraft:sweet_berry_bush", - "minecraft:cave_vines", - "minecraft:cave_vines_plant", - "minecraft:spore_blossom", - "minecraft:pink_petals", "minecraft:big_dripleaf", "minecraft:big_dripleaf_stem", - "minecraft:small_dripleaf", - "minecraft:nether_wart", - "minecraft:warped_fungus", - "minecraft:warped_roots", - "minecraft:nether_sprouts", - "minecraft:crimson_fungus", - "minecraft:weeping_vines", - "minecraft:weeping_vines_plant", - "minecraft:twisting_vines", - "minecraft:twisting_vines_plant", - "minecraft:crimson_roots", "minecraft:chorus_plant", "minecraft:chorus_flower" ] diff --git a/data/minecraft/tags/block/sword_instantly_mines.json b/data/minecraft/tags/block/sword_instantly_mines.json new file mode 100644 index 00000000..5059bebb --- /dev/null +++ b/data/minecraft/tags/block/sword_instantly_mines.json @@ -0,0 +1,6 @@ +{ + "values": [ + "minecraft:bamboo", + "minecraft:bamboo_sapling" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/block/wall_post_override.json b/data/minecraft/tags/block/wall_post_override.json index 0595e842..51925946 100644 --- a/data/minecraft/tags/block/wall_post_override.json +++ b/data/minecraft/tags/block/wall_post_override.json @@ -6,6 +6,7 @@ "minecraft:tripwire", "#minecraft:signs", "#minecraft:banners", - "#minecraft:pressure_plates" + "#minecraft:pressure_plates", + "minecraft:cactus_flower" ] } \ No newline at end of file diff --git a/data/minecraft/tags/block/wither_immune.json b/data/minecraft/tags/block/wither_immune.json index c926979e..5c14361a 100644 --- a/data/minecraft/tags/block/wither_immune.json +++ b/data/minecraft/tags/block/wither_immune.json @@ -12,6 +12,8 @@ "minecraft:jigsaw", "minecraft:moving_piston", "minecraft:light", - "minecraft:reinforced_deepslate" + "minecraft:reinforced_deepslate", + "minecraft:test_block", + "minecraft:test_instance_block" ] } \ No newline at end of file diff --git a/data/minecraft/tags/cat_variant/default_spawns.json b/data/minecraft/tags/cat_variant/default_spawns.json deleted file mode 100644 index dc6f9e88..00000000 --- a/data/minecraft/tags/cat_variant/default_spawns.json +++ /dev/null @@ -1,14 +0,0 @@ -{ - "values": [ - "minecraft:tabby", - "minecraft:black", - "minecraft:red", - "minecraft:siamese", - "minecraft:british_shorthair", - "minecraft:calico", - "minecraft:persian", - "minecraft:ragdoll", - "minecraft:white", - "minecraft:jellie" - ] -} \ No newline at end of file diff --git a/data/minecraft/tags/cat_variant/full_moon_spawns.json b/data/minecraft/tags/cat_variant/full_moon_spawns.json deleted file mode 100644 index 039963f9..00000000 --- a/data/minecraft/tags/cat_variant/full_moon_spawns.json +++ /dev/null @@ -1,6 +0,0 @@ -{ - "values": [ - "#minecraft:default_spawns", - "minecraft:all_black" - ] -} \ No newline at end of file diff --git a/data/minecraft/tags/damage_type/bypasses_shield.json b/data/minecraft/tags/damage_type/bypasses_shield.json index a12ed3cf..e5c6ff1b 100644 --- a/data/minecraft/tags/damage_type/bypasses_shield.json +++ b/data/minecraft/tags/damage_type/bypasses_shield.json @@ -1,7 +1,15 @@ { "values": [ "#minecraft:bypasses_armor", + "minecraft:cactus", + "minecraft:campfire", + "minecraft:dry_out", "minecraft:falling_anvil", - "minecraft:falling_stalactite" + "minecraft:falling_stalactite", + "minecraft:hot_floor", + "minecraft:in_fire", + "minecraft:lava", + "minecraft:lightning_bolt", + "minecraft:sweet_berry_bush" ] } \ No newline at end of file diff --git a/data/minecraft/tags/entity_type/can_equip_saddle.json b/data/minecraft/tags/entity_type/can_equip_saddle.json new file mode 100644 index 00000000..86bc5563 --- /dev/null +++ b/data/minecraft/tags/entity_type/can_equip_saddle.json @@ -0,0 +1,12 @@ +{ + "values": [ + "minecraft:horse", + "minecraft:skeleton_horse", + "minecraft:zombie_horse", + "minecraft:donkey", + "minecraft:mule", + "minecraft:pig", + "minecraft:strider", + "minecraft:camel" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/entity_type/can_wear_horse_armor.json b/data/minecraft/tags/entity_type/can_wear_horse_armor.json new file mode 100644 index 00000000..b6847820 --- /dev/null +++ b/data/minecraft/tags/entity_type/can_wear_horse_armor.json @@ -0,0 +1,5 @@ +{ + "values": [ + "minecraft:horse" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/item/bee_food.json b/data/minecraft/tags/item/bee_food.json index c6edf1c8..f2851d5d 100644 --- a/data/minecraft/tags/item/bee_food.json +++ b/data/minecraft/tags/item/bee_food.json @@ -25,7 +25,9 @@ "minecraft:mangrove_propagule", "minecraft:cherry_leaves", "minecraft:pink_petals", + "minecraft:wildflowers", "minecraft:chorus_flower", - "minecraft:spore_blossom" + "minecraft:spore_blossom", + "minecraft:cactus_flower" ] } \ No newline at end of file diff --git a/data/minecraft/tags/item/book_cloning_target.json b/data/minecraft/tags/item/book_cloning_target.json new file mode 100644 index 00000000..0fdf7a21 --- /dev/null +++ b/data/minecraft/tags/item/book_cloning_target.json @@ -0,0 +1,5 @@ +{ + "values": [ + "minecraft:writable_book" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/item/eggs.json b/data/minecraft/tags/item/eggs.json new file mode 100644 index 00000000..828fbcc1 --- /dev/null +++ b/data/minecraft/tags/item/eggs.json @@ -0,0 +1,7 @@ +{ + "values": [ + "minecraft:egg", + "minecraft:blue_egg", + "minecraft:brown_egg" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/item/flowers.json b/data/minecraft/tags/item/flowers.json new file mode 100644 index 00000000..e0095f65 --- /dev/null +++ b/data/minecraft/tags/item/flowers.json @@ -0,0 +1,19 @@ +{ + "values": [ + "#minecraft:small_flowers", + "minecraft:sunflower", + "minecraft:lilac", + "minecraft:peony", + "minecraft:rose_bush", + "minecraft:pitcher_plant", + "minecraft:flowering_azalea_leaves", + "minecraft:flowering_azalea", + "minecraft:mangrove_propagule", + "minecraft:cherry_leaves", + "minecraft:pink_petals", + "minecraft:wildflowers", + "minecraft:chorus_flower", + "minecraft:spore_blossom", + "minecraft:cactus_flower" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/worldgen/biome/has_structure/trial_chambers.json b/data/minecraft/tags/worldgen/biome/has_structure/trial_chambers.json index 51f2b8c0..ff5c6a15 100644 --- a/data/minecraft/tags/worldgen/biome/has_structure/trial_chambers.json +++ b/data/minecraft/tags/worldgen/biome/has_structure/trial_chambers.json @@ -30,6 +30,7 @@ "minecraft:flower_forest", "minecraft:birch_forest", "minecraft:dark_forest", + "minecraft:pale_garden", "minecraft:savanna_plateau", "minecraft:savanna", "minecraft:jungle", @@ -49,7 +50,6 @@ "minecraft:eroded_badlands", "minecraft:windswept_savanna", "minecraft:cherry_grove", - "minecraft:pale_garden", "minecraft:frozen_peaks", "minecraft:dripstone_caves", "minecraft:lush_caves" diff --git a/data/minecraft/tags/worldgen/biome/has_structure/woodland_mansion.json b/data/minecraft/tags/worldgen/biome/has_structure/woodland_mansion.json index 2d31b9e8..33519bb4 100644 --- a/data/minecraft/tags/worldgen/biome/has_structure/woodland_mansion.json +++ b/data/minecraft/tags/worldgen/biome/has_structure/woodland_mansion.json @@ -1,5 +1,6 @@ { "values": [ - "minecraft:dark_forest" + "minecraft:dark_forest", + "minecraft:pale_garden" ] } \ No newline at end of file diff --git a/data/minecraft/tags/worldgen/biome/is_overworld.json b/data/minecraft/tags/worldgen/biome/is_overworld.json index 133f965a..9de4c3f3 100644 --- a/data/minecraft/tags/worldgen/biome/is_overworld.json +++ b/data/minecraft/tags/worldgen/biome/is_overworld.json @@ -30,6 +30,7 @@ "minecraft:flower_forest", "minecraft:birch_forest", "minecraft:dark_forest", + "minecraft:pale_garden", "minecraft:savanna_plateau", "minecraft:savanna", "minecraft:jungle", @@ -49,7 +50,6 @@ "minecraft:eroded_badlands", "minecraft:windswept_savanna", "minecraft:cherry_grove", - "minecraft:pale_garden", "minecraft:frozen_peaks", "minecraft:dripstone_caves", "minecraft:lush_caves", diff --git a/data/minecraft/tags/worldgen/biome/spawns_cold_variant_farm_animals.json b/data/minecraft/tags/worldgen/biome/spawns_cold_variant_farm_animals.json new file mode 100644 index 00000000..c9da19ea --- /dev/null +++ b/data/minecraft/tags/worldgen/biome/spawns_cold_variant_farm_animals.json @@ -0,0 +1,26 @@ +{ + "values": [ + "minecraft:snowy_plains", + "minecraft:ice_spikes", + "minecraft:frozen_peaks", + "minecraft:jagged_peaks", + "minecraft:snowy_slopes", + "minecraft:frozen_ocean", + "minecraft:deep_frozen_ocean", + "minecraft:grove", + "minecraft:deep_dark", + "minecraft:frozen_river", + "minecraft:snowy_taiga", + "minecraft:snowy_beach", + "#minecraft:is_end", + "minecraft:cold_ocean", + "minecraft:deep_cold_ocean", + "minecraft:old_growth_pine_taiga", + "minecraft:old_growth_spruce_taiga", + "minecraft:taiga", + "minecraft:windswept_forest", + "minecraft:windswept_gravelly_hills", + "minecraft:windswept_hills", + "minecraft:stony_peaks" + ] +} \ No newline at end of file diff --git a/data/minecraft/tags/worldgen/biome/spawns_warm_variant_farm_animals.json b/data/minecraft/tags/worldgen/biome/spawns_warm_variant_farm_animals.json new file mode 100644 index 00000000..b009f682 --- /dev/null +++ b/data/minecraft/tags/worldgen/biome/spawns_warm_variant_farm_animals.json @@ -0,0 +1,13 @@ +{ + "values": [ + "minecraft:desert", + "minecraft:warm_ocean", + "#minecraft:is_jungle", + "#minecraft:is_savanna", + "#minecraft:is_nether", + "#minecraft:is_badlands", + "minecraft:mangrove_swamp", + "minecraft:deep_lukewarm_ocean", + "minecraft:lukewarm_ocean" + ] +} \ No newline at end of file diff --git a/data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_desert_village_maps.json b/data/minecraft/tags/worldgen/structure/on_desert_village_maps.json similarity index 100% rename from data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_desert_village_maps.json rename to data/minecraft/tags/worldgen/structure/on_desert_village_maps.json diff --git a/data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_jungle_explorer_maps.json b/data/minecraft/tags/worldgen/structure/on_jungle_explorer_maps.json similarity index 100% rename from data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_jungle_explorer_maps.json rename to data/minecraft/tags/worldgen/structure/on_jungle_explorer_maps.json diff --git a/data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_plains_village_maps.json b/data/minecraft/tags/worldgen/structure/on_plains_village_maps.json similarity index 100% rename from data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_plains_village_maps.json rename to data/minecraft/tags/worldgen/structure/on_plains_village_maps.json diff --git a/data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_savanna_village_maps.json b/data/minecraft/tags/worldgen/structure/on_savanna_village_maps.json similarity index 100% rename from data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_savanna_village_maps.json rename to data/minecraft/tags/worldgen/structure/on_savanna_village_maps.json diff --git a/data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_snowy_village_maps.json b/data/minecraft/tags/worldgen/structure/on_snowy_village_maps.json similarity index 100% rename from data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_snowy_village_maps.json rename to data/minecraft/tags/worldgen/structure/on_snowy_village_maps.json diff --git a/data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_swamp_explorer_maps.json b/data/minecraft/tags/worldgen/structure/on_swamp_explorer_maps.json similarity index 100% rename from data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_swamp_explorer_maps.json rename to data/minecraft/tags/worldgen/structure/on_swamp_explorer_maps.json diff --git a/data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_taiga_village_maps.json b/data/minecraft/tags/worldgen/structure/on_taiga_village_maps.json similarity index 100% rename from data/minecraft/datapacks/trade_rebalance/data/minecraft/tags/worldgen/structure/on_taiga_village_maps.json rename to data/minecraft/tags/worldgen/structure/on_taiga_village_maps.json diff --git a/data/minecraft/test_environment/default.json b/data/minecraft/test_environment/default.json new file mode 100644 index 00000000..8808857c --- /dev/null +++ b/data/minecraft/test_environment/default.json @@ -0,0 +1,4 @@ +{ + "type": "minecraft:all_of", + "definitions": [] +} \ No newline at end of file diff --git a/data/minecraft/test_instance/always_pass.json b/data/minecraft/test_instance/always_pass.json new file mode 100644 index 00000000..b4effb8c --- /dev/null +++ b/data/minecraft/test_instance/always_pass.json @@ -0,0 +1,9 @@ +{ + "type": "minecraft:function", + "environment": "minecraft:default", + "function": "minecraft:always_pass", + "max_ticks": 1, + "required": false, + "setup_ticks": 1, + "structure": "minecraft:empty" +} \ No newline at end of file diff --git a/data/minecraft/trim_material/amethyst.json b/data/minecraft/trim_material/amethyst.json index f751eb3f..8ee4630b 100644 --- a/data/minecraft/trim_material/amethyst.json +++ b/data/minecraft/trim_material/amethyst.json @@ -3,6 +3,5 @@ "description": { "color": "#9A5CC6", "translate": "trim_material.minecraft.amethyst" - }, - "ingredient": "minecraft:amethyst_shard" + } } \ No newline at end of file diff --git a/data/minecraft/trim_material/copper.json b/data/minecraft/trim_material/copper.json index cced560f..57948bb5 100644 --- a/data/minecraft/trim_material/copper.json +++ b/data/minecraft/trim_material/copper.json @@ -3,6 +3,5 @@ "description": { "color": "#B4684D", "translate": "trim_material.minecraft.copper" - }, - "ingredient": "minecraft:copper_ingot" + } } \ No newline at end of file diff --git a/data/minecraft/trim_material/diamond.json b/data/minecraft/trim_material/diamond.json index 3b03942c..bf9d314f 100644 --- a/data/minecraft/trim_material/diamond.json +++ b/data/minecraft/trim_material/diamond.json @@ -4,7 +4,6 @@ "color": "#6EECD2", "translate": "trim_material.minecraft.diamond" }, - "ingredient": "minecraft:diamond", "override_armor_assets": { "minecraft:diamond": "diamond_darker" } diff --git a/data/minecraft/trim_material/emerald.json b/data/minecraft/trim_material/emerald.json index 989d975b..10c7c240 100644 --- a/data/minecraft/trim_material/emerald.json +++ b/data/minecraft/trim_material/emerald.json @@ -3,6 +3,5 @@ "description": { "color": "#11A036", "translate": "trim_material.minecraft.emerald" - }, - "ingredient": "minecraft:emerald" + } } \ No newline at end of file diff --git a/data/minecraft/trim_material/gold.json b/data/minecraft/trim_material/gold.json index e3c80fba..3c0eff3b 100644 --- a/data/minecraft/trim_material/gold.json +++ b/data/minecraft/trim_material/gold.json @@ -4,7 +4,6 @@ "color": "#DEB12D", "translate": "trim_material.minecraft.gold" }, - "ingredient": "minecraft:gold_ingot", "override_armor_assets": { "minecraft:gold": "gold_darker" } diff --git a/data/minecraft/trim_material/iron.json b/data/minecraft/trim_material/iron.json index cec858a5..208e50f9 100644 --- a/data/minecraft/trim_material/iron.json +++ b/data/minecraft/trim_material/iron.json @@ -4,7 +4,6 @@ "color": "#ECECEC", "translate": "trim_material.minecraft.iron" }, - "ingredient": "minecraft:iron_ingot", "override_armor_assets": { "minecraft:iron": "iron_darker" } diff --git a/data/minecraft/trim_material/lapis.json b/data/minecraft/trim_material/lapis.json index ba6829b2..2f78caad 100644 --- a/data/minecraft/trim_material/lapis.json +++ b/data/minecraft/trim_material/lapis.json @@ -3,6 +3,5 @@ "description": { "color": "#416E97", "translate": "trim_material.minecraft.lapis" - }, - "ingredient": "minecraft:lapis_lazuli" + } } \ No newline at end of file diff --git a/data/minecraft/trim_material/netherite.json b/data/minecraft/trim_material/netherite.json index ae517ac4..f787cde2 100644 --- a/data/minecraft/trim_material/netherite.json +++ b/data/minecraft/trim_material/netherite.json @@ -4,7 +4,6 @@ "color": "#625859", "translate": "trim_material.minecraft.netherite" }, - "ingredient": "minecraft:netherite_ingot", "override_armor_assets": { "minecraft:netherite": "netherite_darker" } diff --git a/data/minecraft/trim_material/quartz.json b/data/minecraft/trim_material/quartz.json index 52237b16..67588503 100644 --- a/data/minecraft/trim_material/quartz.json +++ b/data/minecraft/trim_material/quartz.json @@ -3,6 +3,5 @@ "description": { "color": "#E3D4C4", "translate": "trim_material.minecraft.quartz" - }, - "ingredient": "minecraft:quartz" + } } \ No newline at end of file diff --git a/data/minecraft/trim_material/redstone.json b/data/minecraft/trim_material/redstone.json index 23a3ee57..a2e7750b 100644 --- a/data/minecraft/trim_material/redstone.json +++ b/data/minecraft/trim_material/redstone.json @@ -3,6 +3,5 @@ "description": { "color": "#971607", "translate": "trim_material.minecraft.redstone" - }, - "ingredient": "minecraft:redstone" + } } \ No newline at end of file diff --git a/data/minecraft/trim_material/resin.json b/data/minecraft/trim_material/resin.json index 3c6851a4..3798c0e7 100644 --- a/data/minecraft/trim_material/resin.json +++ b/data/minecraft/trim_material/resin.json @@ -3,6 +3,5 @@ "description": { "color": "#FC7812", "translate": "trim_material.minecraft.resin" - }, - "ingredient": "minecraft:resin_brick" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/bolt.json b/data/minecraft/trim_pattern/bolt.json index 27c0d9bc..55989273 100644 --- a/data/minecraft/trim_pattern/bolt.json +++ b/data/minecraft/trim_pattern/bolt.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.bolt" - }, - "template_item": "minecraft:bolt_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/coast.json b/data/minecraft/trim_pattern/coast.json index 6e77fc37..174e48e5 100644 --- a/data/minecraft/trim_pattern/coast.json +++ b/data/minecraft/trim_pattern/coast.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.coast" - }, - "template_item": "minecraft:coast_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/dune.json b/data/minecraft/trim_pattern/dune.json index 2b825b34..09293865 100644 --- a/data/minecraft/trim_pattern/dune.json +++ b/data/minecraft/trim_pattern/dune.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.dune" - }, - "template_item": "minecraft:dune_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/eye.json b/data/minecraft/trim_pattern/eye.json index 52260df5..86265106 100644 --- a/data/minecraft/trim_pattern/eye.json +++ b/data/minecraft/trim_pattern/eye.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.eye" - }, - "template_item": "minecraft:eye_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/flow.json b/data/minecraft/trim_pattern/flow.json index 2d94de80..21ad7420 100644 --- a/data/minecraft/trim_pattern/flow.json +++ b/data/minecraft/trim_pattern/flow.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.flow" - }, - "template_item": "minecraft:flow_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/host.json b/data/minecraft/trim_pattern/host.json index 483d3f41..b43cc5ed 100644 --- a/data/minecraft/trim_pattern/host.json +++ b/data/minecraft/trim_pattern/host.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.host" - }, - "template_item": "minecraft:host_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/raiser.json b/data/minecraft/trim_pattern/raiser.json index b7d69d45..448d93fd 100644 --- a/data/minecraft/trim_pattern/raiser.json +++ b/data/minecraft/trim_pattern/raiser.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.raiser" - }, - "template_item": "minecraft:raiser_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/rib.json b/data/minecraft/trim_pattern/rib.json index ae0e5159..0e77a83f 100644 --- a/data/minecraft/trim_pattern/rib.json +++ b/data/minecraft/trim_pattern/rib.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.rib" - }, - "template_item": "minecraft:rib_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/sentry.json b/data/minecraft/trim_pattern/sentry.json index 1d864542..e32df2ca 100644 --- a/data/minecraft/trim_pattern/sentry.json +++ b/data/minecraft/trim_pattern/sentry.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.sentry" - }, - "template_item": "minecraft:sentry_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/shaper.json b/data/minecraft/trim_pattern/shaper.json index 38a76d94..9636aa24 100644 --- a/data/minecraft/trim_pattern/shaper.json +++ b/data/minecraft/trim_pattern/shaper.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.shaper" - }, - "template_item": "minecraft:shaper_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/silence.json b/data/minecraft/trim_pattern/silence.json index 0cf9ca84..2c073608 100644 --- a/data/minecraft/trim_pattern/silence.json +++ b/data/minecraft/trim_pattern/silence.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.silence" - }, - "template_item": "minecraft:silence_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/snout.json b/data/minecraft/trim_pattern/snout.json index 0b23038b..bf3686d7 100644 --- a/data/minecraft/trim_pattern/snout.json +++ b/data/minecraft/trim_pattern/snout.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.snout" - }, - "template_item": "minecraft:snout_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/spire.json b/data/minecraft/trim_pattern/spire.json index 9df73f59..c57dc165 100644 --- a/data/minecraft/trim_pattern/spire.json +++ b/data/minecraft/trim_pattern/spire.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.spire" - }, - "template_item": "minecraft:spire_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/tide.json b/data/minecraft/trim_pattern/tide.json index a01adda4..9d6332dd 100644 --- a/data/minecraft/trim_pattern/tide.json +++ b/data/minecraft/trim_pattern/tide.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.tide" - }, - "template_item": "minecraft:tide_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/vex.json b/data/minecraft/trim_pattern/vex.json index bc010f1f..231f7d36 100644 --- a/data/minecraft/trim_pattern/vex.json +++ b/data/minecraft/trim_pattern/vex.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.vex" - }, - "template_item": "minecraft:vex_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/ward.json b/data/minecraft/trim_pattern/ward.json index e07ffbc1..bcdfcf77 100644 --- a/data/minecraft/trim_pattern/ward.json +++ b/data/minecraft/trim_pattern/ward.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.ward" - }, - "template_item": "minecraft:ward_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/wayfinder.json b/data/minecraft/trim_pattern/wayfinder.json index ecb8cc90..61838729 100644 --- a/data/minecraft/trim_pattern/wayfinder.json +++ b/data/minecraft/trim_pattern/wayfinder.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.wayfinder" - }, - "template_item": "minecraft:wayfinder_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/trim_pattern/wild.json b/data/minecraft/trim_pattern/wild.json index 4696f382..18d392b5 100644 --- a/data/minecraft/trim_pattern/wild.json +++ b/data/minecraft/trim_pattern/wild.json @@ -3,6 +3,5 @@ "decal": false, "description": { "translate": "trim_pattern.minecraft.wild" - }, - "template_item": "minecraft:wild_armor_trim_smithing_template" + } } \ No newline at end of file diff --git a/data/minecraft/wolf_sound_variant/angry.json b/data/minecraft/wolf_sound_variant/angry.json new file mode 100644 index 00000000..b8e40f3d --- /dev/null +++ b/data/minecraft/wolf_sound_variant/angry.json @@ -0,0 +1,8 @@ +{ + "ambient_sound": "minecraft:entity.wolf_angry.ambient", + "death_sound": "minecraft:entity.wolf_angry.death", + "growl_sound": "minecraft:entity.wolf_angry.growl", + "hurt_sound": "minecraft:entity.wolf_angry.hurt", + "pant_sound": "minecraft:entity.wolf_angry.pant", + "whine_sound": "minecraft:entity.wolf_angry.whine" +} \ No newline at end of file diff --git a/data/minecraft/wolf_sound_variant/big.json b/data/minecraft/wolf_sound_variant/big.json new file mode 100644 index 00000000..27f167e7 --- /dev/null +++ b/data/minecraft/wolf_sound_variant/big.json @@ -0,0 +1,8 @@ +{ + "ambient_sound": "minecraft:entity.wolf_big.ambient", + "death_sound": "minecraft:entity.wolf_big.death", + "growl_sound": "minecraft:entity.wolf_big.growl", + "hurt_sound": "minecraft:entity.wolf_big.hurt", + "pant_sound": "minecraft:entity.wolf_big.pant", + "whine_sound": "minecraft:entity.wolf_big.whine" +} \ No newline at end of file diff --git a/data/minecraft/wolf_sound_variant/classic.json b/data/minecraft/wolf_sound_variant/classic.json new file mode 100644 index 00000000..7c43a8a4 --- /dev/null +++ b/data/minecraft/wolf_sound_variant/classic.json @@ -0,0 +1,8 @@ +{ + "ambient_sound": "minecraft:entity.wolf.ambient", + "death_sound": "minecraft:entity.wolf.death", + "growl_sound": "minecraft:entity.wolf.growl", + "hurt_sound": "minecraft:entity.wolf.hurt", + "pant_sound": "minecraft:entity.wolf.pant", + "whine_sound": "minecraft:entity.wolf.whine" +} \ No newline at end of file diff --git a/data/minecraft/wolf_sound_variant/cute.json b/data/minecraft/wolf_sound_variant/cute.json new file mode 100644 index 00000000..83b26be2 --- /dev/null +++ b/data/minecraft/wolf_sound_variant/cute.json @@ -0,0 +1,8 @@ +{ + "ambient_sound": "minecraft:entity.wolf_cute.ambient", + "death_sound": "minecraft:entity.wolf_cute.death", + "growl_sound": "minecraft:entity.wolf_cute.growl", + "hurt_sound": "minecraft:entity.wolf_cute.hurt", + "pant_sound": "minecraft:entity.wolf_cute.pant", + "whine_sound": "minecraft:entity.wolf_cute.whine" +} \ No newline at end of file diff --git a/data/minecraft/wolf_sound_variant/grumpy.json b/data/minecraft/wolf_sound_variant/grumpy.json new file mode 100644 index 00000000..94ada85b --- /dev/null +++ b/data/minecraft/wolf_sound_variant/grumpy.json @@ -0,0 +1,8 @@ +{ + "ambient_sound": "minecraft:entity.wolf_grumpy.ambient", + "death_sound": "minecraft:entity.wolf_grumpy.death", + "growl_sound": "minecraft:entity.wolf_grumpy.growl", + "hurt_sound": "minecraft:entity.wolf_grumpy.hurt", + "pant_sound": "minecraft:entity.wolf_grumpy.pant", + "whine_sound": "minecraft:entity.wolf_grumpy.whine" +} \ No newline at end of file diff --git a/data/minecraft/wolf_sound_variant/puglin.json b/data/minecraft/wolf_sound_variant/puglin.json new file mode 100644 index 00000000..09194d34 --- /dev/null +++ b/data/minecraft/wolf_sound_variant/puglin.json @@ -0,0 +1,8 @@ +{ + "ambient_sound": "minecraft:entity.wolf_puglin.ambient", + "death_sound": "minecraft:entity.wolf_puglin.death", + "growl_sound": "minecraft:entity.wolf_puglin.growl", + "hurt_sound": "minecraft:entity.wolf_puglin.hurt", + "pant_sound": "minecraft:entity.wolf_puglin.pant", + "whine_sound": "minecraft:entity.wolf_puglin.whine" +} \ No newline at end of file diff --git a/data/minecraft/wolf_sound_variant/sad.json b/data/minecraft/wolf_sound_variant/sad.json new file mode 100644 index 00000000..80cbaa34 --- /dev/null +++ b/data/minecraft/wolf_sound_variant/sad.json @@ -0,0 +1,8 @@ +{ + "ambient_sound": "minecraft:entity.wolf_sad.ambient", + "death_sound": "minecraft:entity.wolf_sad.death", + "growl_sound": "minecraft:entity.wolf_sad.growl", + "hurt_sound": "minecraft:entity.wolf_sad.hurt", + "pant_sound": "minecraft:entity.wolf_sad.pant", + "whine_sound": "minecraft:entity.wolf_sad.whine" +} \ No newline at end of file diff --git a/data/minecraft/wolf_variant/ashen.json b/data/minecraft/wolf_variant/ashen.json index 16ad8aef..0322dba9 100644 --- a/data/minecraft/wolf_variant/ashen.json +++ b/data/minecraft/wolf_variant/ashen.json @@ -1,6 +1,16 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_ashen_angry", - "biomes": "minecraft:snowy_taiga", - "tame_texture": "minecraft:entity/wolf/wolf_ashen_tame", - "wild_texture": "minecraft:entity/wolf/wolf_ashen" + "assets": { + "angry": "minecraft:entity/wolf/wolf_ashen_angry", + "tame": "minecraft:entity/wolf/wolf_ashen_tame", + "wild": "minecraft:entity/wolf/wolf_ashen" + }, + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "minecraft:snowy_taiga" + }, + "priority": 1 + } + ] } \ No newline at end of file diff --git a/data/minecraft/wolf_variant/black.json b/data/minecraft/wolf_variant/black.json index fe704d12..52d7db61 100644 --- a/data/minecraft/wolf_variant/black.json +++ b/data/minecraft/wolf_variant/black.json @@ -1,6 +1,16 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_black_angry", - "biomes": "minecraft:old_growth_pine_taiga", - "tame_texture": "minecraft:entity/wolf/wolf_black_tame", - "wild_texture": "minecraft:entity/wolf/wolf_black" + "assets": { + "angry": "minecraft:entity/wolf/wolf_black_angry", + "tame": "minecraft:entity/wolf/wolf_black_tame", + "wild": "minecraft:entity/wolf/wolf_black" + }, + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "minecraft:old_growth_pine_taiga" + }, + "priority": 1 + } + ] } \ No newline at end of file diff --git a/data/minecraft/wolf_variant/chestnut.json b/data/minecraft/wolf_variant/chestnut.json index c94e4f52..88f48773 100644 --- a/data/minecraft/wolf_variant/chestnut.json +++ b/data/minecraft/wolf_variant/chestnut.json @@ -1,6 +1,16 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_chestnut_angry", - "biomes": "minecraft:old_growth_spruce_taiga", - "tame_texture": "minecraft:entity/wolf/wolf_chestnut_tame", - "wild_texture": "minecraft:entity/wolf/wolf_chestnut" + "assets": { + "angry": "minecraft:entity/wolf/wolf_chestnut_angry", + "tame": "minecraft:entity/wolf/wolf_chestnut_tame", + "wild": "minecraft:entity/wolf/wolf_chestnut" + }, + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "minecraft:old_growth_spruce_taiga" + }, + "priority": 1 + } + ] } \ No newline at end of file diff --git a/data/minecraft/wolf_variant/pale.json b/data/minecraft/wolf_variant/pale.json index fde95058..f90fdc72 100644 --- a/data/minecraft/wolf_variant/pale.json +++ b/data/minecraft/wolf_variant/pale.json @@ -1,6 +1,12 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_angry", - "biomes": "minecraft:taiga", - "tame_texture": "minecraft:entity/wolf/wolf_tame", - "wild_texture": "minecraft:entity/wolf/wolf" + "assets": { + "angry": "minecraft:entity/wolf/wolf_angry", + "tame": "minecraft:entity/wolf/wolf_tame", + "wild": "minecraft:entity/wolf/wolf" + }, + "spawn_conditions": [ + { + "priority": 0 + } + ] } \ No newline at end of file diff --git a/data/minecraft/wolf_variant/rusty.json b/data/minecraft/wolf_variant/rusty.json index 834607a9..87635835 100644 --- a/data/minecraft/wolf_variant/rusty.json +++ b/data/minecraft/wolf_variant/rusty.json @@ -1,6 +1,16 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_rusty_angry", - "biomes": "#minecraft:is_jungle", - "tame_texture": "minecraft:entity/wolf/wolf_rusty_tame", - "wild_texture": "minecraft:entity/wolf/wolf_rusty" + "assets": { + "angry": "minecraft:entity/wolf/wolf_rusty_angry", + "tame": "minecraft:entity/wolf/wolf_rusty_tame", + "wild": "minecraft:entity/wolf/wolf_rusty" + }, + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:is_jungle" + }, + "priority": 1 + } + ] } \ No newline at end of file diff --git a/data/minecraft/wolf_variant/snowy.json b/data/minecraft/wolf_variant/snowy.json index 41441e8d..f8291232 100644 --- a/data/minecraft/wolf_variant/snowy.json +++ b/data/minecraft/wolf_variant/snowy.json @@ -1,6 +1,16 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_snowy_angry", - "biomes": "minecraft:grove", - "tame_texture": "minecraft:entity/wolf/wolf_snowy_tame", - "wild_texture": "minecraft:entity/wolf/wolf_snowy" + "assets": { + "angry": "minecraft:entity/wolf/wolf_snowy_angry", + "tame": "minecraft:entity/wolf/wolf_snowy_tame", + "wild": "minecraft:entity/wolf/wolf_snowy" + }, + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "minecraft:grove" + }, + "priority": 1 + } + ] } \ No newline at end of file diff --git a/data/minecraft/wolf_variant/spotted.json b/data/minecraft/wolf_variant/spotted.json index f4c52147..96ee0aff 100644 --- a/data/minecraft/wolf_variant/spotted.json +++ b/data/minecraft/wolf_variant/spotted.json @@ -1,6 +1,16 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_spotted_angry", - "biomes": "#minecraft:is_savanna", - "tame_texture": "minecraft:entity/wolf/wolf_spotted_tame", - "wild_texture": "minecraft:entity/wolf/wolf_spotted" + "assets": { + "angry": "minecraft:entity/wolf/wolf_spotted_angry", + "tame": "minecraft:entity/wolf/wolf_spotted_tame", + "wild": "minecraft:entity/wolf/wolf_spotted" + }, + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:is_savanna" + }, + "priority": 1 + } + ] } \ No newline at end of file diff --git a/data/minecraft/wolf_variant/striped.json b/data/minecraft/wolf_variant/striped.json index c36f7a6d..90d714cd 100644 --- a/data/minecraft/wolf_variant/striped.json +++ b/data/minecraft/wolf_variant/striped.json @@ -1,6 +1,16 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_striped_angry", - "biomes": "#minecraft:is_badlands", - "tame_texture": "minecraft:entity/wolf/wolf_striped_tame", - "wild_texture": "minecraft:entity/wolf/wolf_striped" + "assets": { + "angry": "minecraft:entity/wolf/wolf_striped_angry", + "tame": "minecraft:entity/wolf/wolf_striped_tame", + "wild": "minecraft:entity/wolf/wolf_striped" + }, + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "#minecraft:is_badlands" + }, + "priority": 1 + } + ] } \ No newline at end of file diff --git a/data/minecraft/wolf_variant/woods.json b/data/minecraft/wolf_variant/woods.json index 7c2afa20..35dba8c4 100644 --- a/data/minecraft/wolf_variant/woods.json +++ b/data/minecraft/wolf_variant/woods.json @@ -1,6 +1,16 @@ { - "angry_texture": "minecraft:entity/wolf/wolf_woods_angry", - "biomes": "minecraft:forest", - "tame_texture": "minecraft:entity/wolf/wolf_woods_tame", - "wild_texture": "minecraft:entity/wolf/wolf_woods" + "assets": { + "angry": "minecraft:entity/wolf/wolf_woods_angry", + "tame": "minecraft:entity/wolf/wolf_woods_tame", + "wild": "minecraft:entity/wolf/wolf_woods" + }, + "spawn_conditions": [ + { + "condition": { + "type": "minecraft:biome", + "biomes": "minecraft:forest" + }, + "priority": 1 + } + ] } \ No newline at end of file diff --git a/data/minecraft/worldgen/biome/badlands.json b/data/minecraft/worldgen/biome/badlands.json index 68fe2473..ae75cf61 100644 --- a/data/minecraft/worldgen/biome/badlands.json +++ b/data/minecraft/worldgen/biome/badlands.json @@ -87,12 +87,14 @@ [ "minecraft:glow_lichen", "minecraft:patch_grass_badlands", + "minecraft:patch_dry_grass_badlands", "minecraft:patch_dead_bush_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", "minecraft:patch_sugar_cane_badlands", "minecraft:patch_pumpkin", - "minecraft:patch_cactus_decorated" + "minecraft:patch_cactus_decorated", + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" @@ -111,6 +113,30 @@ ], "axolotls": [], "creature": [ + { + "type": "minecraft:sheep", + "maxCount": 4, + "minCount": 4, + "weight": 12 + }, + { + "type": "minecraft:pig", + "maxCount": 4, + "minCount": 4, + "weight": 10 + }, + { + "type": "minecraft:chicken", + "maxCount": 4, + "minCount": 4, + "weight": 10 + }, + { + "type": "minecraft:cow", + "maxCount": 4, + "minCount": 4, + "weight": 8 + }, { "type": "minecraft:armadillo", "maxCount": 2, diff --git a/data/minecraft/worldgen/biome/bamboo_jungle.json b/data/minecraft/worldgen/biome/bamboo_jungle.json index a0df35fa..8d681239 100644 --- a/data/minecraft/worldgen/biome/bamboo_jungle.json +++ b/data/minecraft/worldgen/biome/bamboo_jungle.json @@ -88,8 +88,9 @@ "minecraft:patch_grass_jungle", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:vines", "minecraft:patch_melon" ], diff --git a/data/minecraft/worldgen/biome/beach.json b/data/minecraft/worldgen/biome/beach.json index 8146697d..8de498ec 100644 --- a/data/minecraft/worldgen/biome/beach.json +++ b/data/minecraft/worldgen/biome/beach.json @@ -75,8 +75,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/birch_forest.json b/data/minecraft/worldgen/biome/birch_forest.json index 2dfdd62b..6778612e 100644 --- a/data/minecraft/worldgen/biome/birch_forest.json +++ b/data/minecraft/worldgen/biome/birch_forest.json @@ -83,13 +83,16 @@ [ "minecraft:glow_lichen", "minecraft:forest_flowers", + "minecraft:wildflowers_birch_forest", "minecraft:trees_birch", + "minecraft:patch_bush", "minecraft:flower_default", "minecraft:patch_grass_forest", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/cold_ocean.json b/data/minecraft/worldgen/biome/cold_ocean.json index ef30c579..6d96a7b7 100644 --- a/data/minecraft/worldgen/biome/cold_ocean.json +++ b/data/minecraft/worldgen/biome/cold_ocean.json @@ -76,8 +76,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:seagrass_cold", "minecraft:kelp_cold" ], diff --git a/data/minecraft/worldgen/biome/dark_forest.json b/data/minecraft/worldgen/biome/dark_forest.json index 9096e3bf..f44558bc 100644 --- a/data/minecraft/worldgen/biome/dark_forest.json +++ b/data/minecraft/worldgen/biome/dark_forest.json @@ -6,6 +6,7 @@ ], "downfall": 0.8, "effects": { + "dry_foliage_color": 8082228, "fog_color": 12638463, "grass_color_modifier": "dark_forest", "mood_sound": { @@ -89,8 +90,10 @@ "minecraft:patch_grass_forest", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_leaf_litter", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/deep_cold_ocean.json b/data/minecraft/worldgen/biome/deep_cold_ocean.json index c26e48f8..214327c8 100644 --- a/data/minecraft/worldgen/biome/deep_cold_ocean.json +++ b/data/minecraft/worldgen/biome/deep_cold_ocean.json @@ -76,8 +76,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:seagrass_deep_cold", "minecraft:kelp_cold" ], diff --git a/data/minecraft/worldgen/biome/deep_dark.json b/data/minecraft/worldgen/biome/deep_dark.json index 0bffad77..81e98dd1 100644 --- a/data/minecraft/worldgen/biome/deep_dark.json +++ b/data/minecraft/worldgen/biome/deep_dark.json @@ -85,7 +85,6 @@ "minecraft:patch_grass_plain", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin" ], [ diff --git a/data/minecraft/worldgen/biome/deep_frozen_ocean.json b/data/minecraft/worldgen/biome/deep_frozen_ocean.json index 8e834edf..b01af165 100644 --- a/data/minecraft/worldgen/biome/deep_frozen_ocean.json +++ b/data/minecraft/worldgen/biome/deep_frozen_ocean.json @@ -80,8 +80,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/deep_lukewarm_ocean.json b/data/minecraft/worldgen/biome/deep_lukewarm_ocean.json index 55caa339..fdf7f559 100644 --- a/data/minecraft/worldgen/biome/deep_lukewarm_ocean.json +++ b/data/minecraft/worldgen/biome/deep_lukewarm_ocean.json @@ -76,8 +76,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:seagrass_deep_warm", "minecraft:kelp_warm" ], diff --git a/data/minecraft/worldgen/biome/deep_ocean.json b/data/minecraft/worldgen/biome/deep_ocean.json index 7f964ef6..302bd3a3 100644 --- a/data/minecraft/worldgen/biome/deep_ocean.json +++ b/data/minecraft/worldgen/biome/deep_ocean.json @@ -76,8 +76,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:seagrass_deep", "minecraft:kelp_cold" ], diff --git a/data/minecraft/worldgen/biome/desert.json b/data/minecraft/worldgen/biome/desert.json index 9f4c9f62..cb4d62b2 100644 --- a/data/minecraft/worldgen/biome/desert.json +++ b/data/minecraft/worldgen/biome/desert.json @@ -88,6 +88,7 @@ "minecraft:glow_lichen", "minecraft:flower_default", "minecraft:patch_grass_badlands", + "minecraft:patch_dry_grass_desert", "minecraft:patch_dead_bush_2", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", @@ -116,7 +117,13 @@ "type": "minecraft:rabbit", "maxCount": 3, "minCount": 2, - "weight": 4 + "weight": 12 + }, + { + "type": "minecraft:camel", + "maxCount": 1, + "minCount": 1, + "weight": 1 } ], "misc": [], diff --git a/data/minecraft/worldgen/biome/dripstone_caves.json b/data/minecraft/worldgen/biome/dripstone_caves.json index 9a9b2093..2c52745d 100644 --- a/data/minecraft/worldgen/biome/dripstone_caves.json +++ b/data/minecraft/worldgen/biome/dripstone_caves.json @@ -92,7 +92,6 @@ "minecraft:patch_grass_plain", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin" ], [ diff --git a/data/minecraft/worldgen/biome/eroded_badlands.json b/data/minecraft/worldgen/biome/eroded_badlands.json index 68fe2473..ae75cf61 100644 --- a/data/minecraft/worldgen/biome/eroded_badlands.json +++ b/data/minecraft/worldgen/biome/eroded_badlands.json @@ -87,12 +87,14 @@ [ "minecraft:glow_lichen", "minecraft:patch_grass_badlands", + "minecraft:patch_dry_grass_badlands", "minecraft:patch_dead_bush_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", "minecraft:patch_sugar_cane_badlands", "minecraft:patch_pumpkin", - "minecraft:patch_cactus_decorated" + "minecraft:patch_cactus_decorated", + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" @@ -111,6 +113,30 @@ ], "axolotls": [], "creature": [ + { + "type": "minecraft:sheep", + "maxCount": 4, + "minCount": 4, + "weight": 12 + }, + { + "type": "minecraft:pig", + "maxCount": 4, + "minCount": 4, + "weight": 10 + }, + { + "type": "minecraft:chicken", + "maxCount": 4, + "minCount": 4, + "weight": 10 + }, + { + "type": "minecraft:cow", + "maxCount": 4, + "minCount": 4, + "weight": 8 + }, { "type": "minecraft:armadillo", "maxCount": 2, diff --git a/data/minecraft/worldgen/biome/flower_forest.json b/data/minecraft/worldgen/biome/flower_forest.json index 2eea7114..cac1e70b 100644 --- a/data/minecraft/worldgen/biome/flower_forest.json +++ b/data/minecraft/worldgen/biome/flower_forest.json @@ -88,8 +88,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/forest.json b/data/minecraft/worldgen/biome/forest.json index 8922b7ab..6d16e033 100644 --- a/data/minecraft/worldgen/biome/forest.json +++ b/data/minecraft/worldgen/biome/forest.json @@ -83,13 +83,15 @@ [ "minecraft:glow_lichen", "minecraft:forest_flowers", - "minecraft:trees_birch_and_oak", + "minecraft:trees_birch_and_oak_leaf_litter", + "minecraft:patch_bush", "minecraft:flower_default", "minecraft:patch_grass_forest", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/frozen_ocean.json b/data/minecraft/worldgen/biome/frozen_ocean.json index 2f8fa124..f60bd4d9 100644 --- a/data/minecraft/worldgen/biome/frozen_ocean.json +++ b/data/minecraft/worldgen/biome/frozen_ocean.json @@ -80,8 +80,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/frozen_river.json b/data/minecraft/worldgen/biome/frozen_river.json index 6ce80510..279bbc38 100644 --- a/data/minecraft/worldgen/biome/frozen_river.json +++ b/data/minecraft/worldgen/biome/frozen_river.json @@ -72,12 +72,14 @@ [ "minecraft:glow_lichen", "minecraft:trees_water", + "minecraft:patch_bush", "minecraft:flower_default", "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/grove.json b/data/minecraft/worldgen/biome/grove.json index 459e9ca1..af07cbde 100644 --- a/data/minecraft/worldgen/biome/grove.json +++ b/data/minecraft/worldgen/biome/grove.json @@ -87,7 +87,6 @@ [ "minecraft:glow_lichen", "minecraft:trees_grove", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin" ], [ diff --git a/data/minecraft/worldgen/biome/ice_spikes.json b/data/minecraft/worldgen/biome/ice_spikes.json index 0b87fb4a..68f99d70 100644 --- a/data/minecraft/worldgen/biome/ice_spikes.json +++ b/data/minecraft/worldgen/biome/ice_spikes.json @@ -80,8 +80,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/jungle.json b/data/minecraft/worldgen/biome/jungle.json index 61850c66..67b5fe7a 100644 --- a/data/minecraft/worldgen/biome/jungle.json +++ b/data/minecraft/worldgen/biome/jungle.json @@ -88,8 +88,9 @@ "minecraft:patch_grass_jungle", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:vines", "minecraft:patch_melon" ], diff --git a/data/minecraft/worldgen/biome/lukewarm_ocean.json b/data/minecraft/worldgen/biome/lukewarm_ocean.json index 0a79ab2f..54a836a7 100644 --- a/data/minecraft/worldgen/biome/lukewarm_ocean.json +++ b/data/minecraft/worldgen/biome/lukewarm_ocean.json @@ -76,8 +76,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:seagrass_warm", "minecraft:kelp_warm" ], diff --git a/data/minecraft/worldgen/biome/mangrove_swamp.json b/data/minecraft/worldgen/biome/mangrove_swamp.json index 7bd60980..178f8866 100644 --- a/data/minecraft/worldgen/biome/mangrove_swamp.json +++ b/data/minecraft/worldgen/biome/mangrove_swamp.json @@ -6,6 +6,7 @@ ], "downfall": 0.9, "effects": { + "dry_foliage_color": 8082228, "fog_color": 12638463, "foliage_color": 9285927, "grass_color_modifier": "swamp", @@ -89,7 +90,8 @@ "minecraft:patch_grass_normal", "minecraft:patch_dead_bush", "minecraft:patch_waterlily", - "minecraft:seagrass_swamp" + "minecraft:seagrass_swamp", + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/meadow.json b/data/minecraft/worldgen/biome/meadow.json index 393849cf..5768f877 100644 --- a/data/minecraft/worldgen/biome/meadow.json +++ b/data/minecraft/worldgen/biome/meadow.json @@ -86,9 +86,10 @@ [ "minecraft:glow_lichen", "minecraft:patch_tall_grass_2", - "minecraft:patch_grass_plain", + "minecraft:patch_grass_meadow", "minecraft:flower_meadow", - "minecraft:trees_meadow" + "minecraft:trees_meadow", + "minecraft:wildflowers_meadow" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/mushroom_fields.json b/data/minecraft/worldgen/biome/mushroom_fields.json index af257808..d03e1792 100644 --- a/data/minecraft/worldgen/biome/mushroom_fields.json +++ b/data/minecraft/worldgen/biome/mushroom_fields.json @@ -74,8 +74,9 @@ "minecraft:mushroom_island_vegetation", "minecraft:brown_mushroom_taiga", "minecraft:red_mushroom_taiga", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/ocean.json b/data/minecraft/worldgen/biome/ocean.json index 93740259..3513295e 100644 --- a/data/minecraft/worldgen/biome/ocean.json +++ b/data/minecraft/worldgen/biome/ocean.json @@ -76,8 +76,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:seagrass_normal", "minecraft:kelp_cold" ], diff --git a/data/minecraft/worldgen/biome/old_growth_birch_forest.json b/data/minecraft/worldgen/biome/old_growth_birch_forest.json index 33e51ae0..28a1d945 100644 --- a/data/minecraft/worldgen/biome/old_growth_birch_forest.json +++ b/data/minecraft/worldgen/biome/old_growth_birch_forest.json @@ -83,13 +83,16 @@ [ "minecraft:glow_lichen", "minecraft:forest_flowers", + "minecraft:wildflowers_birch_forest", "minecraft:birch_tall", + "minecraft:patch_bush", "minecraft:flower_default", "minecraft:patch_grass_forest", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/old_growth_pine_taiga.json b/data/minecraft/worldgen/biome/old_growth_pine_taiga.json index 9c885581..e221c248 100644 --- a/data/minecraft/worldgen/biome/old_growth_pine_taiga.json +++ b/data/minecraft/worldgen/biome/old_growth_pine_taiga.json @@ -92,8 +92,9 @@ "minecraft:red_mushroom_old_growth", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:patch_berry_common" ], [ diff --git a/data/minecraft/worldgen/biome/old_growth_spruce_taiga.json b/data/minecraft/worldgen/biome/old_growth_spruce_taiga.json index 59752b9e..7f393afc 100644 --- a/data/minecraft/worldgen/biome/old_growth_spruce_taiga.json +++ b/data/minecraft/worldgen/biome/old_growth_spruce_taiga.json @@ -92,8 +92,9 @@ "minecraft:red_mushroom_old_growth", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:patch_berry_common" ], [ diff --git a/data/minecraft/worldgen/biome/pale_garden.json b/data/minecraft/worldgen/biome/pale_garden.json index d46ba10d..ac2df049 100644 --- a/data/minecraft/worldgen/biome/pale_garden.json +++ b/data/minecraft/worldgen/biome/pale_garden.json @@ -6,6 +6,7 @@ ], "downfall": 0.8, "effects": { + "dry_foliage_color": 10528412, "fog_color": 8484720, "foliage_color": 8883574, "grass_color": 7832178, @@ -79,8 +80,9 @@ "minecraft:pale_garden_flowers", "minecraft:flower_pale_garden", "minecraft:patch_grass_forest", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/plains.json b/data/minecraft/worldgen/biome/plains.json index 41249530..a396056c 100644 --- a/data/minecraft/worldgen/biome/plains.json +++ b/data/minecraft/worldgen/biome/plains.json @@ -72,13 +72,15 @@ [ "minecraft:glow_lichen", "minecraft:patch_tall_grass_2", + "minecraft:patch_bush", "minecraft:trees_plains", "minecraft:flower_plains", "minecraft:patch_grass_plain", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/river.json b/data/minecraft/worldgen/biome/river.json index 834c5e16..0221bd99 100644 --- a/data/minecraft/worldgen/biome/river.json +++ b/data/minecraft/worldgen/biome/river.json @@ -72,12 +72,14 @@ [ "minecraft:glow_lichen", "minecraft:trees_water", + "minecraft:patch_bush", "minecraft:flower_default", "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:seagrass_river" ], [ diff --git a/data/minecraft/worldgen/biome/savanna.json b/data/minecraft/worldgen/biome/savanna.json index c0865011..59b9a6c7 100644 --- a/data/minecraft/worldgen/biome/savanna.json +++ b/data/minecraft/worldgen/biome/savanna.json @@ -77,8 +77,9 @@ "minecraft:patch_grass_savanna", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/savanna_plateau.json b/data/minecraft/worldgen/biome/savanna_plateau.json index c776c779..eafc228a 100644 --- a/data/minecraft/worldgen/biome/savanna_plateau.json +++ b/data/minecraft/worldgen/biome/savanna_plateau.json @@ -77,8 +77,9 @@ "minecraft:patch_grass_savanna", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/snowy_beach.json b/data/minecraft/worldgen/biome/snowy_beach.json index c5d81fea..e87419ca 100644 --- a/data/minecraft/worldgen/biome/snowy_beach.json +++ b/data/minecraft/worldgen/biome/snowy_beach.json @@ -75,8 +75,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/snowy_plains.json b/data/minecraft/worldgen/biome/snowy_plains.json index 489a061e..845813c5 100644 --- a/data/minecraft/worldgen/biome/snowy_plains.json +++ b/data/minecraft/worldgen/biome/snowy_plains.json @@ -77,8 +77,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/snowy_slopes.json b/data/minecraft/worldgen/biome/snowy_slopes.json index df845d75..c601af88 100644 --- a/data/minecraft/worldgen/biome/snowy_slopes.json +++ b/data/minecraft/worldgen/biome/snowy_slopes.json @@ -86,7 +86,6 @@ ], [ "minecraft:glow_lichen", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin" ], [ diff --git a/data/minecraft/worldgen/biome/snowy_taiga.json b/data/minecraft/worldgen/biome/snowy_taiga.json index 2fe871e8..bb792a2b 100644 --- a/data/minecraft/worldgen/biome/snowy_taiga.json +++ b/data/minecraft/worldgen/biome/snowy_taiga.json @@ -77,8 +77,9 @@ "minecraft:patch_grass_taiga_2", "minecraft:brown_mushroom_taiga", "minecraft:red_mushroom_taiga", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:patch_berry_rare" ], [ diff --git a/data/minecraft/worldgen/biome/sparse_jungle.json b/data/minecraft/worldgen/biome/sparse_jungle.json index 8ca6b210..5e37d71c 100644 --- a/data/minecraft/worldgen/biome/sparse_jungle.json +++ b/data/minecraft/worldgen/biome/sparse_jungle.json @@ -87,8 +87,9 @@ "minecraft:patch_grass_jungle", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:vines", "minecraft:patch_melon_sparse" ], diff --git a/data/minecraft/worldgen/biome/stony_shore.json b/data/minecraft/worldgen/biome/stony_shore.json index 1637f0f4..5371b007 100644 --- a/data/minecraft/worldgen/biome/stony_shore.json +++ b/data/minecraft/worldgen/biome/stony_shore.json @@ -75,8 +75,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/sunflower_plains.json b/data/minecraft/worldgen/biome/sunflower_plains.json index 78ab660d..0e007c0d 100644 --- a/data/minecraft/worldgen/biome/sunflower_plains.json +++ b/data/minecraft/worldgen/biome/sunflower_plains.json @@ -78,8 +78,9 @@ "minecraft:patch_grass_plain", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/swamp.json b/data/minecraft/worldgen/biome/swamp.json index c0a03d9d..3816f56d 100644 --- a/data/minecraft/worldgen/biome/swamp.json +++ b/data/minecraft/worldgen/biome/swamp.json @@ -6,6 +6,7 @@ ], "downfall": 0.9, "effects": { + "dry_foliage_color": 8082228, "fog_color": 12638463, "foliage_color": 6975545, "grass_color_modifier": "swamp", @@ -95,6 +96,8 @@ "minecraft:red_mushroom_normal", "minecraft:patch_sugar_cane_swamp", "minecraft:patch_pumpkin", + "minecraft:patch_firefly_bush_swamp", + "minecraft:patch_firefly_bush_near_water_swamp", "minecraft:seagrass_swamp" ], [ diff --git a/data/minecraft/worldgen/biome/taiga.json b/data/minecraft/worldgen/biome/taiga.json index b5318709..5947919e 100644 --- a/data/minecraft/worldgen/biome/taiga.json +++ b/data/minecraft/worldgen/biome/taiga.json @@ -77,8 +77,9 @@ "minecraft:patch_grass_taiga_2", "minecraft:brown_mushroom_taiga", "minecraft:red_mushroom_taiga", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:patch_berry_common" ], [ diff --git a/data/minecraft/worldgen/biome/warm_ocean.json b/data/minecraft/worldgen/biome/warm_ocean.json index 50aba537..32383491 100644 --- a/data/minecraft/worldgen/biome/warm_ocean.json +++ b/data/minecraft/worldgen/biome/warm_ocean.json @@ -76,8 +76,9 @@ "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", - "minecraft:patch_sugar_cane", "minecraft:patch_pumpkin", + "minecraft:patch_sugar_cane", + "minecraft:patch_firefly_bush_near_water", "minecraft:warm_ocean_vegetation", "minecraft:seagrass_warm", "minecraft:sea_pickle" diff --git a/data/minecraft/worldgen/biome/windswept_forest.json b/data/minecraft/worldgen/biome/windswept_forest.json index c94e221f..4e4dd49c 100644 --- a/data/minecraft/worldgen/biome/windswept_forest.json +++ b/data/minecraft/worldgen/biome/windswept_forest.json @@ -75,12 +75,14 @@ [ "minecraft:glow_lichen", "minecraft:trees_windswept_forest", + "minecraft:patch_bush", "minecraft:flower_default", "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/windswept_gravelly_hills.json b/data/minecraft/worldgen/biome/windswept_gravelly_hills.json index 6277321f..e0c01405 100644 --- a/data/minecraft/worldgen/biome/windswept_gravelly_hills.json +++ b/data/minecraft/worldgen/biome/windswept_gravelly_hills.json @@ -75,12 +75,14 @@ [ "minecraft:glow_lichen", "minecraft:trees_windswept_hills", + "minecraft:patch_bush", "minecraft:flower_default", "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/windswept_hills.json b/data/minecraft/worldgen/biome/windswept_hills.json index 6277321f..e0c01405 100644 --- a/data/minecraft/worldgen/biome/windswept_hills.json +++ b/data/minecraft/worldgen/biome/windswept_hills.json @@ -75,12 +75,14 @@ [ "minecraft:glow_lichen", "minecraft:trees_windswept_hills", + "minecraft:patch_bush", "minecraft:flower_default", "minecraft:patch_grass_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/windswept_savanna.json b/data/minecraft/worldgen/biome/windswept_savanna.json index b6a6b1db..3d4b7388 100644 --- a/data/minecraft/worldgen/biome/windswept_savanna.json +++ b/data/minecraft/worldgen/biome/windswept_savanna.json @@ -76,8 +76,9 @@ "minecraft:patch_grass_normal", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", + "minecraft:patch_pumpkin", "minecraft:patch_sugar_cane", - "minecraft:patch_pumpkin" + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" diff --git a/data/minecraft/worldgen/biome/wooded_badlands.json b/data/minecraft/worldgen/biome/wooded_badlands.json index e22ccb1b..9db71008 100644 --- a/data/minecraft/worldgen/biome/wooded_badlands.json +++ b/data/minecraft/worldgen/biome/wooded_badlands.json @@ -88,12 +88,14 @@ "minecraft:glow_lichen", "minecraft:trees_badlands", "minecraft:patch_grass_badlands", + "minecraft:patch_dry_grass_badlands", "minecraft:patch_dead_bush_badlands", "minecraft:brown_mushroom_normal", "minecraft:red_mushroom_normal", "minecraft:patch_sugar_cane_badlands", "minecraft:patch_pumpkin", - "minecraft:patch_cactus_decorated" + "minecraft:patch_cactus_decorated", + "minecraft:patch_firefly_bush_near_water" ], [ "minecraft:freeze_top_layer" @@ -112,6 +114,30 @@ ], "axolotls": [], "creature": [ + { + "type": "minecraft:sheep", + "maxCount": 4, + "minCount": 4, + "weight": 12 + }, + { + "type": "minecraft:pig", + "maxCount": 4, + "minCount": 4, + "weight": 10 + }, + { + "type": "minecraft:chicken", + "maxCount": 4, + "minCount": 4, + "weight": 10 + }, + { + "type": "minecraft:cow", + "maxCount": 4, + "minCount": 4, + "weight": 8 + }, { "type": "minecraft:armadillo", "maxCount": 2, diff --git a/data/minecraft/worldgen/configured_feature/birch_bees_0002_leaf_litter.json b/data/minecraft/worldgen/configured_feature/birch_bees_0002_leaf_litter.json new file mode 100644 index 00000000..3cc8c9bd --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/birch_bees_0002_leaf_litter.json @@ -0,0 +1,359 @@ +{ + "type": "minecraft:tree", + "config": { + "decorators": [ + { + "type": "minecraft:beehive", + "probability": 0.002 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 4, + "tries": 96 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "4" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 2, + "tries": 150 + } + ], + "dirt_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dirt" + } + }, + "foliage_placer": { + "type": "minecraft:blob_foliage_placer", + "height": 3, + "offset": 0, + "radius": 2 + }, + "foliage_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:birch_leaves", + "Properties": { + "distance": "7", + "persistent": "false", + "waterlogged": "false" + } + } + }, + "force_dirt": false, + "ignore_vines": true, + "minimum_size": { + "type": "minecraft:two_layers_feature_size", + "limit": 1, + "lower_size": 0, + "upper_size": 1 + }, + "trunk_placer": { + "type": "minecraft:straight_trunk_placer", + "base_height": 5, + "height_rand_a": 2, + "height_rand_b": 0 + }, + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:birch_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/birch_leaf_litter.json b/data/minecraft/worldgen/configured_feature/birch_leaf_litter.json new file mode 100644 index 00000000..4ad4310b --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/birch_leaf_litter.json @@ -0,0 +1,355 @@ +{ + "type": "minecraft:tree", + "config": { + "decorators": [ + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 4, + "tries": 96 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "4" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 2, + "tries": 150 + } + ], + "dirt_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dirt" + } + }, + "foliage_placer": { + "type": "minecraft:blob_foliage_placer", + "height": 3, + "offset": 0, + "radius": 2 + }, + "foliage_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:birch_leaves", + "Properties": { + "distance": "7", + "persistent": "false", + "waterlogged": "false" + } + } + }, + "force_dirt": false, + "ignore_vines": true, + "minimum_size": { + "type": "minecraft:two_layers_feature_size", + "limit": 1, + "lower_size": 0, + "upper_size": 1 + }, + "trunk_placer": { + "type": "minecraft:straight_trunk_placer", + "base_height": 5, + "height_rand_a": 2, + "height_rand_b": 0 + }, + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:birch_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/birch_tall.json b/data/minecraft/worldgen/configured_feature/birch_tall.json index 7701dbad..ee8d6377 100644 --- a/data/minecraft/worldgen/configured_feature/birch_tall.json +++ b/data/minecraft/worldgen/configured_feature/birch_tall.json @@ -3,9 +3,17 @@ "config": { "default": "minecraft:birch_bees_0002", "features": [ + { + "chance": 0.00625, + "feature": "minecraft:fallen_super_birch_tree" + }, { "chance": 0.5, "feature": "minecraft:super_birch_bees_0002" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_birch_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/crimson_fungus.json b/data/minecraft/worldgen/configured_feature/crimson_fungus.json index 451af841..420cc88b 100644 --- a/data/minecraft/worldgen/configured_feature/crimson_fungus.json +++ b/data/minecraft/worldgen/configured_feature/crimson_fungus.json @@ -66,6 +66,7 @@ "minecraft:flowering_azalea", "minecraft:moss_carpet", "minecraft:pink_petals", + "minecraft:wildflowers", "minecraft:big_dripleaf", "minecraft:big_dripleaf_stem", "minecraft:small_dripleaf" diff --git a/data/minecraft/worldgen/configured_feature/crimson_fungus_planted.json b/data/minecraft/worldgen/configured_feature/crimson_fungus_planted.json index 2d67804b..18a41976 100644 --- a/data/minecraft/worldgen/configured_feature/crimson_fungus_planted.json +++ b/data/minecraft/worldgen/configured_feature/crimson_fungus_planted.json @@ -66,6 +66,7 @@ "minecraft:flowering_azalea", "minecraft:moss_carpet", "minecraft:pink_petals", + "minecraft:wildflowers", "minecraft:big_dripleaf", "minecraft:big_dripleaf_stem", "minecraft:small_dripleaf" diff --git a/data/minecraft/worldgen/configured_feature/dark_forest_vegetation.json b/data/minecraft/worldgen/configured_feature/dark_forest_vegetation.json index ad2c35d4..ba26b1be 100644 --- a/data/minecraft/worldgen/configured_feature/dark_forest_vegetation.json +++ b/data/minecraft/worldgen/configured_feature/dark_forest_vegetation.json @@ -1,7 +1,7 @@ { "type": "minecraft:random_selector", "config": { - "default": "minecraft:oak_checked", + "default": "minecraft:oak_leaf_litter", "features": [ { "chance": 0.025, @@ -19,15 +19,23 @@ }, { "chance": 0.6666667, - "feature": "minecraft:dark_oak_checked" + "feature": "minecraft:dark_oak_leaf_litter" + }, + { + "chance": 0.0025, + "feature": "minecraft:fallen_birch_tree" }, { "chance": 0.2, - "feature": "minecraft:birch_checked" + "feature": "minecraft:birch_leaf_litter" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_oak_tree" }, { "chance": 0.1, - "feature": "minecraft:fancy_oak_checked" + "feature": "minecraft:fancy_oak_leaf_litter" } ] } diff --git a/data/minecraft/worldgen/configured_feature/dark_oak_leaf_litter.json b/data/minecraft/worldgen/configured_feature/dark_oak_leaf_litter.json new file mode 100644 index 00000000..d8f43473 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/dark_oak_leaf_litter.json @@ -0,0 +1,356 @@ +{ + "type": "minecraft:tree", + "config": { + "decorators": [ + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 4, + "tries": 96 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "4" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 2, + "tries": 150 + } + ], + "dirt_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dirt" + } + }, + "foliage_placer": { + "type": "minecraft:dark_oak_foliage_placer", + "offset": 0, + "radius": 0 + }, + "foliage_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dark_oak_leaves", + "Properties": { + "distance": "7", + "persistent": "false", + "waterlogged": "false" + } + } + }, + "force_dirt": false, + "ignore_vines": true, + "minimum_size": { + "type": "minecraft:three_layers_feature_size", + "limit": 1, + "lower_size": 0, + "middle_size": 1, + "upper_limit": 1, + "upper_size": 2 + }, + "trunk_placer": { + "type": "minecraft:dark_oak_trunk_placer", + "base_height": 6, + "height_rand_a": 2, + "height_rand_b": 1 + }, + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dark_oak_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/fallen_birch_tree.json b/data/minecraft/worldgen/configured_feature/fallen_birch_tree.json new file mode 100644 index 00000000..1f95f2b1 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/fallen_birch_tree.json @@ -0,0 +1,46 @@ +{ + "type": "minecraft:fallen_tree", + "config": { + "log_decorators": [ + { + "type": "minecraft:attached_to_logs", + "block_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:red_mushroom" + }, + "weight": 2 + }, + { + "data": { + "Name": "minecraft:brown_mushroom" + }, + "weight": 1 + } + ] + }, + "directions": [ + "up" + ], + "probability": 0.1 + } + ], + "log_length": { + "type": "minecraft:uniform", + "max_inclusive": 8, + "min_inclusive": 5 + }, + "stump_decorators": [], + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:birch_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/fallen_jungle_tree.json b/data/minecraft/worldgen/configured_feature/fallen_jungle_tree.json new file mode 100644 index 00000000..29cfe152 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/fallen_jungle_tree.json @@ -0,0 +1,50 @@ +{ + "type": "minecraft:fallen_tree", + "config": { + "log_decorators": [ + { + "type": "minecraft:attached_to_logs", + "block_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:red_mushroom" + }, + "weight": 2 + }, + { + "data": { + "Name": "minecraft:brown_mushroom" + }, + "weight": 1 + } + ] + }, + "directions": [ + "up" + ], + "probability": 0.1 + } + ], + "log_length": { + "type": "minecraft:uniform", + "max_inclusive": 11, + "min_inclusive": 4 + }, + "stump_decorators": [ + { + "type": "minecraft:trunk_vine" + } + ], + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:jungle_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/fallen_oak_tree.json b/data/minecraft/worldgen/configured_feature/fallen_oak_tree.json new file mode 100644 index 00000000..59e49f03 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/fallen_oak_tree.json @@ -0,0 +1,50 @@ +{ + "type": "minecraft:fallen_tree", + "config": { + "log_decorators": [ + { + "type": "minecraft:attached_to_logs", + "block_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:red_mushroom" + }, + "weight": 2 + }, + { + "data": { + "Name": "minecraft:brown_mushroom" + }, + "weight": 1 + } + ] + }, + "directions": [ + "up" + ], + "probability": 0.1 + } + ], + "log_length": { + "type": "minecraft:uniform", + "max_inclusive": 7, + "min_inclusive": 4 + }, + "stump_decorators": [ + { + "type": "minecraft:trunk_vine" + } + ], + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/fallen_spruce_tree.json b/data/minecraft/worldgen/configured_feature/fallen_spruce_tree.json new file mode 100644 index 00000000..30113ea3 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/fallen_spruce_tree.json @@ -0,0 +1,46 @@ +{ + "type": "minecraft:fallen_tree", + "config": { + "log_decorators": [ + { + "type": "minecraft:attached_to_logs", + "block_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:red_mushroom" + }, + "weight": 2 + }, + { + "data": { + "Name": "minecraft:brown_mushroom" + }, + "weight": 1 + } + ] + }, + "directions": [ + "up" + ], + "probability": 0.1 + } + ], + "log_length": { + "type": "minecraft:uniform", + "max_inclusive": 10, + "min_inclusive": 6 + }, + "stump_decorators": [], + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:spruce_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/fallen_super_birch_tree.json b/data/minecraft/worldgen/configured_feature/fallen_super_birch_tree.json new file mode 100644 index 00000000..a189ea4c --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/fallen_super_birch_tree.json @@ -0,0 +1,46 @@ +{ + "type": "minecraft:fallen_tree", + "config": { + "log_decorators": [ + { + "type": "minecraft:attached_to_logs", + "block_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:red_mushroom" + }, + "weight": 2 + }, + { + "data": { + "Name": "minecraft:brown_mushroom" + }, + "weight": 1 + } + ] + }, + "directions": [ + "up" + ], + "probability": 0.1 + } + ], + "log_length": { + "type": "minecraft:uniform", + "max_inclusive": 15, + "min_inclusive": 5 + }, + "stump_decorators": [], + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:birch_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/fancy_oak_bees_0002.json b/data/minecraft/worldgen/configured_feature/fancy_oak_bees_0002.json deleted file mode 100644 index 18932aa3..00000000 --- a/data/minecraft/worldgen/configured_feature/fancy_oak_bees_0002.json +++ /dev/null @@ -1,58 +0,0 @@ -{ - "type": "minecraft:tree", - "config": { - "decorators": [ - { - "type": "minecraft:beehive", - "probability": 0.002 - } - ], - "dirt_provider": { - "type": "minecraft:simple_state_provider", - "state": { - "Name": "minecraft:dirt" - } - }, - "foliage_placer": { - "type": "minecraft:fancy_foliage_placer", - "height": 4, - "offset": 4, - "radius": 2 - }, - "foliage_provider": { - "type": "minecraft:simple_state_provider", - "state": { - "Name": "minecraft:oak_leaves", - "Properties": { - "distance": "7", - "persistent": "false", - "waterlogged": "false" - } - } - }, - "force_dirt": false, - "ignore_vines": true, - "minimum_size": { - "type": "minecraft:two_layers_feature_size", - "limit": 0, - "lower_size": 0, - "min_clipped_height": 4, - "upper_size": 0 - }, - "trunk_placer": { - "type": "minecraft:fancy_trunk_placer", - "base_height": 3, - "height_rand_a": 11, - "height_rand_b": 0 - }, - "trunk_provider": { - "type": "minecraft:simple_state_provider", - "state": { - "Name": "minecraft:oak_log", - "Properties": { - "axis": "y" - } - } - } - } -} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/fancy_oak_bees_0002_leaf_litter.json b/data/minecraft/worldgen/configured_feature/fancy_oak_bees_0002_leaf_litter.json new file mode 100644 index 00000000..efd3d4bd --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/fancy_oak_bees_0002_leaf_litter.json @@ -0,0 +1,360 @@ +{ + "type": "minecraft:tree", + "config": { + "decorators": [ + { + "type": "minecraft:beehive", + "probability": 0.002 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 4, + "tries": 96 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "4" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 2, + "tries": 150 + } + ], + "dirt_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dirt" + } + }, + "foliage_placer": { + "type": "minecraft:fancy_foliage_placer", + "height": 4, + "offset": 4, + "radius": 2 + }, + "foliage_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_leaves", + "Properties": { + "distance": "7", + "persistent": "false", + "waterlogged": "false" + } + } + }, + "force_dirt": false, + "ignore_vines": true, + "minimum_size": { + "type": "minecraft:two_layers_feature_size", + "limit": 0, + "lower_size": 0, + "min_clipped_height": 4, + "upper_size": 0 + }, + "trunk_placer": { + "type": "minecraft:fancy_trunk_placer", + "base_height": 3, + "height_rand_a": 11, + "height_rand_b": 0 + }, + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/fancy_oak_leaf_litter.json b/data/minecraft/worldgen/configured_feature/fancy_oak_leaf_litter.json new file mode 100644 index 00000000..37ef0fe8 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/fancy_oak_leaf_litter.json @@ -0,0 +1,356 @@ +{ + "type": "minecraft:tree", + "config": { + "decorators": [ + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 4, + "tries": 96 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "4" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 2, + "tries": 150 + } + ], + "dirt_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dirt" + } + }, + "foliage_placer": { + "type": "minecraft:fancy_foliage_placer", + "height": 4, + "offset": 4, + "radius": 2 + }, + "foliage_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_leaves", + "Properties": { + "distance": "7", + "persistent": "false", + "waterlogged": "false" + } + } + }, + "force_dirt": false, + "ignore_vines": true, + "minimum_size": { + "type": "minecraft:two_layers_feature_size", + "limit": 0, + "lower_size": 0, + "min_clipped_height": 4, + "upper_size": 0 + }, + "trunk_placer": { + "type": "minecraft:fancy_trunk_placer", + "base_height": 3, + "height_rand_a": 11, + "height_rand_b": 0 + }, + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/oak_bees_0002.json b/data/minecraft/worldgen/configured_feature/oak_bees_0002.json deleted file mode 100644 index ef3b7b7d..00000000 --- a/data/minecraft/worldgen/configured_feature/oak_bees_0002.json +++ /dev/null @@ -1,57 +0,0 @@ -{ - "type": "minecraft:tree", - "config": { - "decorators": [ - { - "type": "minecraft:beehive", - "probability": 0.002 - } - ], - "dirt_provider": { - "type": "minecraft:simple_state_provider", - "state": { - "Name": "minecraft:dirt" - } - }, - "foliage_placer": { - "type": "minecraft:blob_foliage_placer", - "height": 3, - "offset": 0, - "radius": 2 - }, - "foliage_provider": { - "type": "minecraft:simple_state_provider", - "state": { - "Name": "minecraft:oak_leaves", - "Properties": { - "distance": "7", - "persistent": "false", - "waterlogged": "false" - } - } - }, - "force_dirt": false, - "ignore_vines": true, - "minimum_size": { - "type": "minecraft:two_layers_feature_size", - "limit": 1, - "lower_size": 0, - "upper_size": 1 - }, - "trunk_placer": { - "type": "minecraft:straight_trunk_placer", - "base_height": 4, - "height_rand_a": 2, - "height_rand_b": 0 - }, - "trunk_provider": { - "type": "minecraft:simple_state_provider", - "state": { - "Name": "minecraft:oak_log", - "Properties": { - "axis": "y" - } - } - } - } -} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/oak_bees_0002_leaf_litter.json b/data/minecraft/worldgen/configured_feature/oak_bees_0002_leaf_litter.json new file mode 100644 index 00000000..2b559098 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/oak_bees_0002_leaf_litter.json @@ -0,0 +1,359 @@ +{ + "type": "minecraft:tree", + "config": { + "decorators": [ + { + "type": "minecraft:beehive", + "probability": 0.002 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 4, + "tries": 96 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "4" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 2, + "tries": 150 + } + ], + "dirt_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dirt" + } + }, + "foliage_placer": { + "type": "minecraft:blob_foliage_placer", + "height": 3, + "offset": 0, + "radius": 2 + }, + "foliage_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_leaves", + "Properties": { + "distance": "7", + "persistent": "false", + "waterlogged": "false" + } + } + }, + "force_dirt": false, + "ignore_vines": true, + "minimum_size": { + "type": "minecraft:two_layers_feature_size", + "limit": 1, + "lower_size": 0, + "upper_size": 1 + }, + "trunk_placer": { + "type": "minecraft:straight_trunk_placer", + "base_height": 4, + "height_rand_a": 2, + "height_rand_b": 0 + }, + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/oak_leaf_litter.json b/data/minecraft/worldgen/configured_feature/oak_leaf_litter.json new file mode 100644 index 00000000..77151bac --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/oak_leaf_litter.json @@ -0,0 +1,355 @@ +{ + "type": "minecraft:tree", + "config": { + "decorators": [ + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 4, + "tries": 96 + }, + { + "type": "minecraft:place_on_ground", + "block_state_provider": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "4" + } + }, + "weight": 1 + } + ] + }, + "height": 2, + "radius": 2, + "tries": 150 + } + ], + "dirt_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:dirt" + } + }, + "foliage_placer": { + "type": "minecraft:blob_foliage_placer", + "height": 3, + "offset": 0, + "radius": 2 + }, + "foliage_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_leaves", + "Properties": { + "distance": "7", + "persistent": "false", + "waterlogged": "false" + } + } + }, + "force_dirt": false, + "ignore_vines": true, + "minimum_size": { + "type": "minecraft:two_layers_feature_size", + "limit": 1, + "lower_size": 0, + "upper_size": 1 + }, + "trunk_placer": { + "type": "minecraft:straight_trunk_placer", + "base_height": 4, + "height_rand_a": 2, + "height_rand_b": 0 + }, + "trunk_provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:oak_log", + "Properties": { + "axis": "y" + } + } + } + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/patch_bush.json b/data/minecraft/worldgen/configured_feature/patch_bush.json new file mode 100644 index 00000000..211e0230 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/patch_bush.json @@ -0,0 +1,30 @@ +{ + "type": "minecraft:random_patch", + "config": { + "feature": { + "feature": { + "type": "minecraft:simple_block", + "config": { + "to_place": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:bush" + } + } + } + }, + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + } + } + ] + }, + "tries": 24, + "xz_spread": 5, + "y_spread": 3 + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/patch_cactus.json b/data/minecraft/worldgen/configured_feature/patch_cactus.json index 406cf985..98f3ea87 100644 --- a/data/minecraft/worldgen/configured_feature/patch_cactus.json +++ b/data/minecraft/worldgen/configured_feature/patch_cactus.json @@ -26,6 +26,27 @@ } } } + }, + { + "height": { + "type": "minecraft:weighted_list", + "distribution": [ + { + "data": 0, + "weight": 3 + }, + { + "data": 1, + "weight": 1 + } + ] + }, + "provider": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:cactus_flower" + } + } } ], "prioritize_tip": false diff --git a/data/minecraft/worldgen/configured_feature/patch_dry_grass.json b/data/minecraft/worldgen/configured_feature/patch_dry_grass.json new file mode 100644 index 00000000..0b392e75 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/patch_dry_grass.json @@ -0,0 +1,41 @@ +{ + "type": "minecraft:random_patch", + "config": { + "feature": { + "feature": { + "type": "minecraft:simple_block", + "config": { + "to_place": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:short_dry_grass" + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:tall_dry_grass" + }, + "weight": 1 + } + ] + } + } + }, + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + } + } + ] + }, + "tries": 64, + "xz_spread": 7, + "y_spread": 3 + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/patch_firefly_bush.json b/data/minecraft/worldgen/configured_feature/patch_firefly_bush.json new file mode 100644 index 00000000..8fc824aa --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/patch_firefly_bush.json @@ -0,0 +1,30 @@ +{ + "type": "minecraft:random_patch", + "config": { + "feature": { + "feature": { + "type": "minecraft:simple_block", + "config": { + "to_place": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:firefly_bush" + } + } + } + }, + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + } + } + ] + }, + "tries": 20, + "xz_spread": 4, + "y_spread": 3 + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/patch_grass_meadow.json b/data/minecraft/worldgen/configured_feature/patch_grass_meadow.json new file mode 100644 index 00000000..913d615f --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/patch_grass_meadow.json @@ -0,0 +1,30 @@ +{ + "type": "minecraft:random_patch", + "config": { + "feature": { + "feature": { + "type": "minecraft:simple_block", + "config": { + "to_place": { + "type": "minecraft:simple_state_provider", + "state": { + "Name": "minecraft:short_grass" + } + } + } + }, + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + } + } + ] + }, + "tries": 16, + "xz_spread": 7, + "y_spread": 3 + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/patch_leaf_litter.json b/data/minecraft/worldgen/configured_feature/patch_leaf_litter.json new file mode 100644 index 00000000..6e38b375 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/patch_leaf_litter.json @@ -0,0 +1,149 @@ +{ + "type": "minecraft:random_patch", + "config": { + "feature": { + "feature": { + "type": "minecraft:simple_block", + "config": { + "to_place": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "north", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "east", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "south", + "segment_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:leaf_litter", + "Properties": { + "facing": "west", + "segment_amount": "3" + } + }, + "weight": 1 + } + ] + } + } + }, + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + } + } + ] + }, + "tries": 32, + "xz_spread": 7, + "y_spread": 3 + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/trees_badlands.json b/data/minecraft/worldgen/configured_feature/trees_badlands.json new file mode 100644 index 00000000..661d28ae --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/trees_badlands.json @@ -0,0 +1,12 @@ +{ + "type": "minecraft:random_selector", + "config": { + "default": "minecraft:oak_leaf_litter", + "features": [ + { + "chance": 0.0125, + "feature": "minecraft:fallen_oak_tree" + } + ] + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/trees_birch.json b/data/minecraft/worldgen/configured_feature/trees_birch.json new file mode 100644 index 00000000..6d309c01 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/trees_birch.json @@ -0,0 +1,12 @@ +{ + "type": "minecraft:random_selector", + "config": { + "default": "minecraft:birch_bees_0002", + "features": [ + { + "chance": 0.0125, + "feature": "minecraft:fallen_birch_tree" + } + ] + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/trees_birch_and_oak.json b/data/minecraft/worldgen/configured_feature/trees_birch_and_oak.json deleted file mode 100644 index f779aad0..00000000 --- a/data/minecraft/worldgen/configured_feature/trees_birch_and_oak.json +++ /dev/null @@ -1,16 +0,0 @@ -{ - "type": "minecraft:random_selector", - "config": { - "default": "minecraft:oak_bees_0002", - "features": [ - { - "chance": 0.2, - "feature": "minecraft:birch_bees_0002" - }, - { - "chance": 0.1, - "feature": "minecraft:fancy_oak_bees_0002" - } - ] - } -} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/trees_birch_and_oak_leaf_litter.json b/data/minecraft/worldgen/configured_feature/trees_birch_and_oak_leaf_litter.json new file mode 100644 index 00000000..179fdbec --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/trees_birch_and_oak_leaf_litter.json @@ -0,0 +1,24 @@ +{ + "type": "minecraft:random_selector", + "config": { + "default": "minecraft:oak_bees_0002_leaf_litter", + "features": [ + { + "chance": 0.0025, + "feature": "minecraft:fallen_birch_tree" + }, + { + "chance": 0.2, + "feature": "minecraft:birch_bees_0002_leaf_litter" + }, + { + "chance": 0.1, + "feature": "minecraft:fancy_oak_bees_0002_leaf_litter" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_oak_tree" + } + ] + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/trees_flower_forest.json b/data/minecraft/worldgen/configured_feature/trees_flower_forest.json index d8095f78..ecdadd9d 100644 --- a/data/minecraft/worldgen/configured_feature/trees_flower_forest.json +++ b/data/minecraft/worldgen/configured_feature/trees_flower_forest.json @@ -3,6 +3,10 @@ "config": { "default": "minecraft:oak_bees_002", "features": [ + { + "chance": 0.0025, + "feature": "minecraft:fallen_birch_tree" + }, { "chance": 0.2, "feature": "minecraft:birch_bees_002" diff --git a/data/minecraft/worldgen/configured_feature/trees_jungle.json b/data/minecraft/worldgen/configured_feature/trees_jungle.json index 39bdb585..98a5c862 100644 --- a/data/minecraft/worldgen/configured_feature/trees_jungle.json +++ b/data/minecraft/worldgen/configured_feature/trees_jungle.json @@ -14,6 +14,10 @@ { "chance": 0.33333334, "feature": "minecraft:mega_jungle_tree_checked" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_jungle_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/trees_old_growth_pine_taiga.json b/data/minecraft/worldgen/configured_feature/trees_old_growth_pine_taiga.json index 1e4efd39..162d5d2f 100644 --- a/data/minecraft/worldgen/configured_feature/trees_old_growth_pine_taiga.json +++ b/data/minecraft/worldgen/configured_feature/trees_old_growth_pine_taiga.json @@ -14,6 +14,10 @@ { "chance": 0.33333334, "feature": "minecraft:pine_checked" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_spruce_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/trees_old_growth_spruce_taiga.json b/data/minecraft/worldgen/configured_feature/trees_old_growth_spruce_taiga.json index fb290593..343c030c 100644 --- a/data/minecraft/worldgen/configured_feature/trees_old_growth_spruce_taiga.json +++ b/data/minecraft/worldgen/configured_feature/trees_old_growth_spruce_taiga.json @@ -10,6 +10,10 @@ { "chance": 0.33333334, "feature": "minecraft:pine_checked" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_spruce_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/trees_plains.json b/data/minecraft/worldgen/configured_feature/trees_plains.json index c5f56bf6..99468ece 100644 --- a/data/minecraft/worldgen/configured_feature/trees_plains.json +++ b/data/minecraft/worldgen/configured_feature/trees_plains.json @@ -12,6 +12,10 @@ "feature": "minecraft:fancy_oak_bees_005", "placement": [] } + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_oak_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/trees_savanna.json b/data/minecraft/worldgen/configured_feature/trees_savanna.json index f3f04267..27f9535b 100644 --- a/data/minecraft/worldgen/configured_feature/trees_savanna.json +++ b/data/minecraft/worldgen/configured_feature/trees_savanna.json @@ -6,6 +6,10 @@ { "chance": 0.8, "feature": "minecraft:acacia_checked" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_oak_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/trees_snowy.json b/data/minecraft/worldgen/configured_feature/trees_snowy.json new file mode 100644 index 00000000..b919971f --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/trees_snowy.json @@ -0,0 +1,12 @@ +{ + "type": "minecraft:random_selector", + "config": { + "default": "minecraft:spruce_checked", + "features": [ + { + "chance": 0.0125, + "feature": "minecraft:fallen_spruce_tree" + } + ] + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/trees_sparse_jungle.json b/data/minecraft/worldgen/configured_feature/trees_sparse_jungle.json index a2b593bb..6ab500eb 100644 --- a/data/minecraft/worldgen/configured_feature/trees_sparse_jungle.json +++ b/data/minecraft/worldgen/configured_feature/trees_sparse_jungle.json @@ -10,6 +10,10 @@ { "chance": 0.5, "feature": "minecraft:jungle_bush" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_jungle_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/trees_taiga.json b/data/minecraft/worldgen/configured_feature/trees_taiga.json index 1da37322..f101351f 100644 --- a/data/minecraft/worldgen/configured_feature/trees_taiga.json +++ b/data/minecraft/worldgen/configured_feature/trees_taiga.json @@ -6,6 +6,10 @@ { "chance": 0.33333334, "feature": "minecraft:pine_checked" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_spruce_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/trees_windswept_hills.json b/data/minecraft/worldgen/configured_feature/trees_windswept_hills.json index 3d2554bf..8a3da4be 100644 --- a/data/minecraft/worldgen/configured_feature/trees_windswept_hills.json +++ b/data/minecraft/worldgen/configured_feature/trees_windswept_hills.json @@ -3,6 +3,10 @@ "config": { "default": "minecraft:oak_checked", "features": [ + { + "chance": 0.008325, + "feature": "minecraft:fallen_spruce_tree" + }, { "chance": 0.666, "feature": "minecraft:spruce_checked" @@ -10,6 +14,10 @@ { "chance": 0.1, "feature": "minecraft:fancy_oak_checked" + }, + { + "chance": 0.0125, + "feature": "minecraft:fallen_oak_tree" } ] } diff --git a/data/minecraft/worldgen/configured_feature/warped_fungus.json b/data/minecraft/worldgen/configured_feature/warped_fungus.json index 000e8682..be66cb2d 100644 --- a/data/minecraft/worldgen/configured_feature/warped_fungus.json +++ b/data/minecraft/worldgen/configured_feature/warped_fungus.json @@ -66,6 +66,7 @@ "minecraft:flowering_azalea", "minecraft:moss_carpet", "minecraft:pink_petals", + "minecraft:wildflowers", "minecraft:big_dripleaf", "minecraft:big_dripleaf_stem", "minecraft:small_dripleaf" diff --git a/data/minecraft/worldgen/configured_feature/warped_fungus_planted.json b/data/minecraft/worldgen/configured_feature/warped_fungus_planted.json index e2391974..6136f9d7 100644 --- a/data/minecraft/worldgen/configured_feature/warped_fungus_planted.json +++ b/data/minecraft/worldgen/configured_feature/warped_fungus_planted.json @@ -66,6 +66,7 @@ "minecraft:flowering_azalea", "minecraft:moss_carpet", "minecraft:pink_petals", + "minecraft:wildflowers", "minecraft:big_dripleaf", "minecraft:big_dripleaf_stem", "minecraft:small_dripleaf" diff --git a/data/minecraft/worldgen/configured_feature/wildflowers_birch_forest.json b/data/minecraft/worldgen/configured_feature/wildflowers_birch_forest.json new file mode 100644 index 00000000..8f0d68f1 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/wildflowers_birch_forest.json @@ -0,0 +1,189 @@ +{ + "type": "minecraft:flower", + "config": { + "feature": { + "feature": { + "type": "minecraft:simple_block", + "config": { + "to_place": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "north", + "flower_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "east", + "flower_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "south", + "flower_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "west", + "flower_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "north", + "flower_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "east", + "flower_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "south", + "flower_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "west", + "flower_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "north", + "flower_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "east", + "flower_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "south", + "flower_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "west", + "flower_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "north", + "flower_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "east", + "flower_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "south", + "flower_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "west", + "flower_amount": "4" + } + }, + "weight": 1 + } + ] + } + } + }, + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + } + } + ] + }, + "tries": 64, + "xz_spread": 6, + "y_spread": 2 + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/configured_feature/wildflowers_meadow.json b/data/minecraft/worldgen/configured_feature/wildflowers_meadow.json new file mode 100644 index 00000000..7eedc193 --- /dev/null +++ b/data/minecraft/worldgen/configured_feature/wildflowers_meadow.json @@ -0,0 +1,189 @@ +{ + "type": "minecraft:flower", + "config": { + "feature": { + "feature": { + "type": "minecraft:simple_block", + "config": { + "to_place": { + "type": "minecraft:weighted_state_provider", + "entries": [ + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "north", + "flower_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "east", + "flower_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "south", + "flower_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "west", + "flower_amount": "1" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "north", + "flower_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "east", + "flower_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "south", + "flower_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "west", + "flower_amount": "2" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "north", + "flower_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "east", + "flower_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "south", + "flower_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "west", + "flower_amount": "3" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "north", + "flower_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "east", + "flower_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "south", + "flower_amount": "4" + } + }, + "weight": 1 + }, + { + "data": { + "Name": "minecraft:wildflowers", + "Properties": { + "facing": "west", + "flower_amount": "4" + } + }, + "weight": 1 + } + ] + } + } + }, + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + } + } + ] + }, + "tries": 8, + "xz_spread": 6, + "y_spread": 2 + } +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/birch_bees_0002_leaf_litter.json b/data/minecraft/worldgen/placed_feature/birch_bees_0002_leaf_litter.json new file mode 100644 index 00000000..4d983284 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/birch_bees_0002_leaf_litter.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:birch_bees_0002_leaf_litter", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:birch_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/birch_leaf_litter.json b/data/minecraft/worldgen/placed_feature/birch_leaf_litter.json new file mode 100644 index 00000000..5f64be20 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/birch_leaf_litter.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:birch_leaf_litter", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:birch_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/dark_oak_leaf_litter.json b/data/minecraft/worldgen/placed_feature/dark_oak_leaf_litter.json new file mode 100644 index 00000000..b46e1728 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/dark_oak_leaf_litter.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:dark_oak_leaf_litter", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:dark_oak_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/fallen_birch_tree.json b/data/minecraft/worldgen/placed_feature/fallen_birch_tree.json new file mode 100644 index 00000000..f6dc2939 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/fallen_birch_tree.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:fallen_birch_tree", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:birch_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/fallen_jungle_tree.json b/data/minecraft/worldgen/placed_feature/fallen_jungle_tree.json new file mode 100644 index 00000000..1a17826b --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/fallen_jungle_tree.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:fallen_jungle_tree", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:jungle_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/oak_bees_0002.json b/data/minecraft/worldgen/placed_feature/fallen_oak_tree.json similarity index 87% rename from data/minecraft/worldgen/placed_feature/oak_bees_0002.json rename to data/minecraft/worldgen/placed_feature/fallen_oak_tree.json index f17c0332..e6aac160 100644 --- a/data/minecraft/worldgen/placed_feature/oak_bees_0002.json +++ b/data/minecraft/worldgen/placed_feature/fallen_oak_tree.json @@ -1,5 +1,5 @@ { - "feature": "minecraft:oak_bees_0002", + "feature": "minecraft:fallen_oak_tree", "placement": [ { "type": "minecraft:block_predicate_filter", diff --git a/data/minecraft/worldgen/placed_feature/fallen_spruce_tree.json b/data/minecraft/worldgen/placed_feature/fallen_spruce_tree.json new file mode 100644 index 00000000..ab56e627 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/fallen_spruce_tree.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:fallen_spruce_tree", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:spruce_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/fallen_super_birch_tree.json b/data/minecraft/worldgen/placed_feature/fallen_super_birch_tree.json new file mode 100644 index 00000000..4af5ed15 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/fallen_super_birch_tree.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:fallen_super_birch_tree", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:birch_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/fancy_oak_bees_0002_leaf_litter.json b/data/minecraft/worldgen/placed_feature/fancy_oak_bees_0002_leaf_litter.json new file mode 100644 index 00000000..7a9bd273 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/fancy_oak_bees_0002_leaf_litter.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:fancy_oak_bees_0002_leaf_litter", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:oak_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/fancy_oak_leaf_litter.json b/data/minecraft/worldgen/placed_feature/fancy_oak_leaf_litter.json new file mode 100644 index 00000000..96b13592 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/fancy_oak_leaf_litter.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:fancy_oak_leaf_litter", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:oak_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/oak_bees_0002_leaf_litter.json b/data/minecraft/worldgen/placed_feature/oak_bees_0002_leaf_litter.json new file mode 100644 index 00000000..de58b9f7 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/oak_bees_0002_leaf_litter.json @@ -0,0 +1,17 @@ +{ + "feature": "minecraft:oak_bees_0002_leaf_litter", + "placement": [ + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:oak_sapling", + "Properties": { + "stage": "0" + } + } + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/fancy_oak_bees_0002.json b/data/minecraft/worldgen/placed_feature/oak_leaf_litter.json similarity index 86% rename from data/minecraft/worldgen/placed_feature/fancy_oak_bees_0002.json rename to data/minecraft/worldgen/placed_feature/oak_leaf_litter.json index 2b07c958..3cbaadaa 100644 --- a/data/minecraft/worldgen/placed_feature/fancy_oak_bees_0002.json +++ b/data/minecraft/worldgen/placed_feature/oak_leaf_litter.json @@ -1,5 +1,5 @@ { - "feature": "minecraft:fancy_oak_bees_0002", + "feature": "minecraft:oak_leaf_litter", "placement": [ { "type": "minecraft:block_predicate_filter", diff --git a/data/minecraft/worldgen/placed_feature/patch_bush.json b/data/minecraft/worldgen/placed_feature/patch_bush.json new file mode 100644 index 00000000..294cc1ae --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/patch_bush.json @@ -0,0 +1,19 @@ +{ + "feature": "minecraft:patch_bush", + "placement": [ + { + "type": "minecraft:rarity_filter", + "chance": 4 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "MOTION_BLOCKING" + }, + { + "type": "minecraft:biome" + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/patch_dry_grass_badlands.json b/data/minecraft/worldgen/placed_feature/patch_dry_grass_badlands.json new file mode 100644 index 00000000..61002e43 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/patch_dry_grass_badlands.json @@ -0,0 +1,19 @@ +{ + "feature": "minecraft:patch_dry_grass", + "placement": [ + { + "type": "minecraft:rarity_filter", + "chance": 6 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "MOTION_BLOCKING" + }, + { + "type": "minecraft:biome" + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/patch_dry_grass_desert.json b/data/minecraft/worldgen/placed_feature/patch_dry_grass_desert.json new file mode 100644 index 00000000..e18ef109 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/patch_dry_grass_desert.json @@ -0,0 +1,19 @@ +{ + "feature": "minecraft:patch_dry_grass", + "placement": [ + { + "type": "minecraft:rarity_filter", + "chance": 3 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "MOTION_BLOCKING" + }, + { + "type": "minecraft:biome" + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/patch_firefly_bush_near_water.json b/data/minecraft/worldgen/placed_feature/patch_firefly_bush_near_water.json new file mode 100644 index 00000000..86a0190c --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/patch_firefly_bush_near_water.json @@ -0,0 +1,90 @@ +{ + "feature": "minecraft:patch_firefly_bush", + "placement": [ + { + "type": "minecraft:count", + "count": 2 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "MOTION_BLOCKING_NO_LEAVES" + }, + { + "type": "minecraft:biome" + }, + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:all_of", + "predicates": [ + { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + }, + { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:firefly_bush" + } + }, + { + "type": "minecraft:any_of", + "predicates": [ + { + "type": "minecraft:matching_fluids", + "fluids": [ + "minecraft:water", + "minecraft:flowing_water" + ], + "offset": [ + 1, + -1, + 0 + ] + }, + { + "type": "minecraft:matching_fluids", + "fluids": [ + "minecraft:water", + "minecraft:flowing_water" + ], + "offset": [ + -1, + -1, + 0 + ] + }, + { + "type": "minecraft:matching_fluids", + "fluids": [ + "minecraft:water", + "minecraft:flowing_water" + ], + "offset": [ + 0, + -1, + 1 + ] + }, + { + "type": "minecraft:matching_fluids", + "fluids": [ + "minecraft:water", + "minecraft:flowing_water" + ], + "offset": [ + 0, + -1, + -1 + ] + } + ] + } + ] + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/patch_firefly_bush_near_water_swamp.json b/data/minecraft/worldgen/placed_feature/patch_firefly_bush_near_water_swamp.json new file mode 100644 index 00000000..bc8e0f3c --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/patch_firefly_bush_near_water_swamp.json @@ -0,0 +1,90 @@ +{ + "feature": "minecraft:patch_firefly_bush", + "placement": [ + { + "type": "minecraft:count", + "count": 3 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "MOTION_BLOCKING" + }, + { + "type": "minecraft:biome" + }, + { + "type": "minecraft:block_predicate_filter", + "predicate": { + "type": "minecraft:all_of", + "predicates": [ + { + "type": "minecraft:matching_blocks", + "blocks": "minecraft:air" + }, + { + "type": "minecraft:would_survive", + "state": { + "Name": "minecraft:firefly_bush" + } + }, + { + "type": "minecraft:any_of", + "predicates": [ + { + "type": "minecraft:matching_fluids", + "fluids": [ + "minecraft:water", + "minecraft:flowing_water" + ], + "offset": [ + 1, + -1, + 0 + ] + }, + { + "type": "minecraft:matching_fluids", + "fluids": [ + "minecraft:water", + "minecraft:flowing_water" + ], + "offset": [ + -1, + -1, + 0 + ] + }, + { + "type": "minecraft:matching_fluids", + "fluids": [ + "minecraft:water", + "minecraft:flowing_water" + ], + "offset": [ + 0, + -1, + 1 + ] + }, + { + "type": "minecraft:matching_fluids", + "fluids": [ + "minecraft:water", + "minecraft:flowing_water" + ], + "offset": [ + 0, + -1, + -1 + ] + } + ] + } + ] + } + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/patch_firefly_bush_swamp.json b/data/minecraft/worldgen/placed_feature/patch_firefly_bush_swamp.json new file mode 100644 index 00000000..9e762a7a --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/patch_firefly_bush_swamp.json @@ -0,0 +1,19 @@ +{ + "feature": "minecraft:patch_firefly_bush", + "placement": [ + { + "type": "minecraft:rarity_filter", + "chance": 8 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "MOTION_BLOCKING" + }, + { + "type": "minecraft:biome" + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/patch_grass_meadow.json b/data/minecraft/worldgen/placed_feature/patch_grass_meadow.json new file mode 100644 index 00000000..2e1f7145 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/patch_grass_meadow.json @@ -0,0 +1,21 @@ +{ + "feature": "minecraft:patch_grass_meadow", + "placement": [ + { + "type": "minecraft:noise_threshold_count", + "above_noise": 10, + "below_noise": 5, + "noise_level": -0.8 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "WORLD_SURFACE_WG" + }, + { + "type": "minecraft:biome" + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/patch_leaf_litter.json b/data/minecraft/worldgen/placed_feature/patch_leaf_litter.json new file mode 100644 index 00000000..76a56d7e --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/patch_leaf_litter.json @@ -0,0 +1,19 @@ +{ + "feature": "minecraft:patch_leaf_litter", + "placement": [ + { + "type": "minecraft:count", + "count": 2 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "WORLD_SURFACE_WG" + }, + { + "type": "minecraft:biome" + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/trees_badlands.json b/data/minecraft/worldgen/placed_feature/trees_badlands.json index 4b85d9a0..b0bae882 100644 --- a/data/minecraft/worldgen/placed_feature/trees_badlands.json +++ b/data/minecraft/worldgen/placed_feature/trees_badlands.json @@ -1,5 +1,5 @@ { - "feature": "minecraft:oak", + "feature": "minecraft:trees_badlands", "placement": [ { "type": "minecraft:count", diff --git a/data/minecraft/worldgen/placed_feature/trees_birch.json b/data/minecraft/worldgen/placed_feature/trees_birch.json index f5e8cca4..96e1dbd0 100644 --- a/data/minecraft/worldgen/placed_feature/trees_birch.json +++ b/data/minecraft/worldgen/placed_feature/trees_birch.json @@ -1,5 +1,5 @@ { - "feature": "minecraft:birch_bees_0002", + "feature": "minecraft:trees_birch", "placement": [ { "type": "minecraft:count", diff --git a/data/minecraft/worldgen/placed_feature/trees_birch_and_oak.json b/data/minecraft/worldgen/placed_feature/trees_birch_and_oak_leaf_litter.json similarity index 91% rename from data/minecraft/worldgen/placed_feature/trees_birch_and_oak.json rename to data/minecraft/worldgen/placed_feature/trees_birch_and_oak_leaf_litter.json index d690f091..1751dd2a 100644 --- a/data/minecraft/worldgen/placed_feature/trees_birch_and_oak.json +++ b/data/minecraft/worldgen/placed_feature/trees_birch_and_oak_leaf_litter.json @@ -1,5 +1,5 @@ { - "feature": "minecraft:trees_birch_and_oak", + "feature": "minecraft:trees_birch_and_oak_leaf_litter", "placement": [ { "type": "minecraft:count", diff --git a/data/minecraft/worldgen/placed_feature/trees_snowy.json b/data/minecraft/worldgen/placed_feature/trees_snowy.json index 9051c074..524337a7 100644 --- a/data/minecraft/worldgen/placed_feature/trees_snowy.json +++ b/data/minecraft/worldgen/placed_feature/trees_snowy.json @@ -1,5 +1,5 @@ { - "feature": "minecraft:spruce", + "feature": "minecraft:trees_snowy", "placement": [ { "type": "minecraft:count", diff --git a/data/minecraft/worldgen/placed_feature/wildflowers_birch_forest.json b/data/minecraft/worldgen/placed_feature/wildflowers_birch_forest.json new file mode 100644 index 00000000..6cbd8112 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/wildflowers_birch_forest.json @@ -0,0 +1,23 @@ +{ + "feature": "minecraft:wildflowers_birch_forest", + "placement": [ + { + "type": "minecraft:count", + "count": 3 + }, + { + "type": "minecraft:rarity_filter", + "chance": 2 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "MOTION_BLOCKING" + }, + { + "type": "minecraft:biome" + } + ] +} \ No newline at end of file diff --git a/data/minecraft/worldgen/placed_feature/wildflowers_meadow.json b/data/minecraft/worldgen/placed_feature/wildflowers_meadow.json new file mode 100644 index 00000000..9afe9ed3 --- /dev/null +++ b/data/minecraft/worldgen/placed_feature/wildflowers_meadow.json @@ -0,0 +1,21 @@ +{ + "feature": "minecraft:wildflowers_meadow", + "placement": [ + { + "type": "minecraft:noise_threshold_count", + "above_noise": 10, + "below_noise": 5, + "noise_level": -0.8 + }, + { + "type": "minecraft:in_square" + }, + { + "type": "minecraft:heightmap", + "heightmap": "MOTION_BLOCKING" + }, + { + "type": "minecraft:biome" + } + ] +} \ No newline at end of file diff --git a/net/minecraft/ChatFormatting.java b/net/minecraft/ChatFormatting.java index 28478ae6..de37ade5 100644 --- a/net/minecraft/ChatFormatting.java +++ b/net/minecraft/ChatFormatting.java @@ -2,6 +2,7 @@ package net.minecraft; import com.google.common.collect.Lists; import com.mojang.serialization.Codec; +import com.mojang.serialization.DataResult; import java.util.Arrays; import java.util.Collection; import java.util.List; @@ -38,6 +39,11 @@ public enum ChatFormatting implements StringRepresentable { RESET("RESET", 'r', -1, null); public static final Codec CODEC = StringRepresentable.fromEnum(ChatFormatting::values); + public static final Codec COLOR_CODEC = CODEC.validate( + chatFormatting -> chatFormatting.isFormat() + ? DataResult.error(() -> "Formatting was not a valid color: " + chatFormatting) + : DataResult.success(chatFormatting) + ); public static final char PREFIX_CODE = '§'; private static final Map FORMATTING_BY_NAME = (Map)Arrays.stream(values()) .collect(Collectors.toMap(chatFormatting -> cleanName(chatFormatting.name), chatFormatting -> chatFormatting)); diff --git a/net/minecraft/CrashReportCategory.java b/net/minecraft/CrashReportCategory.java index 7ce60a93..2f433578 100644 --- a/net/minecraft/CrashReportCategory.java +++ b/net/minecraft/CrashReportCategory.java @@ -18,15 +18,15 @@ public class CrashReportCategory { this.title = title; } - public static String formatLocation(LevelHeightAccessor levelHeightAccess, double x, double y, double z) { - return String.format(Locale.ROOT, "%.2f,%.2f,%.2f - %s", x, y, z, formatLocation(levelHeightAccess, BlockPos.containing(x, y, z))); + public static String formatLocation(LevelHeightAccessor levelHeightAccessor, double x, double y, double z) { + return String.format(Locale.ROOT, "%.2f,%.2f,%.2f - %s", x, y, z, formatLocation(levelHeightAccessor, BlockPos.containing(x, y, z))); } - public static String formatLocation(LevelHeightAccessor levelHeightAccess, BlockPos pos) { - return formatLocation(levelHeightAccess, pos.getX(), pos.getY(), pos.getZ()); + public static String formatLocation(LevelHeightAccessor levelHeightAccessor, BlockPos pos) { + return formatLocation(levelHeightAccessor, pos.getX(), pos.getY(), pos.getZ()); } - public static String formatLocation(LevelHeightAccessor levelHeightAccess, int x, int y, int z) { + public static String formatLocation(LevelHeightAccessor levelHeightAccessor, int x, int y, int z) { StringBuilder stringBuilder = new StringBuilder(); try { @@ -45,10 +45,10 @@ public class CrashReportCategory { int m = y & 15; int n = z & 15; int o = SectionPos.sectionToBlockCoord(i); - int p = levelHeightAccess.getMinY(); + int p = levelHeightAccessor.getMinY(); int q = SectionPos.sectionToBlockCoord(k); int r = SectionPos.sectionToBlockCoord(i + 1) - 1; - int s = levelHeightAccess.getMaxY(); + int s = levelHeightAccessor.getMaxY(); int t = SectionPos.sectionToBlockCoord(k + 1) - 1; stringBuilder.append( String.format(Locale.ROOT, "Section: (at %d,%d,%d in %d,%d,%d; chunk contains blocks %d,%d,%d to %d,%d,%d)", l, m, n, i, j, k, o, p, q, r, s, t) @@ -67,10 +67,10 @@ public class CrashReportCategory { int m = (i + 1 << 5) - 1; int n = (j + 1 << 5) - 1; int o = i << 9; - int p = levelHeightAccess.getMinY(); + int p = levelHeightAccessor.getMinY(); int q = j << 9; int r = (i + 1 << 9) - 1; - int s = levelHeightAccess.getMaxY(); + int s = levelHeightAccessor.getMaxY(); int t = (j + 1 << 9) - 1; stringBuilder.append( String.format(Locale.ROOT, "Region: (%d,%d; contains chunks %d,%d to %d,%d, blocks %d,%d,%d to %d,%d,%d)", i, j, k, l, m, n, o, p, q, r, s, t) @@ -186,12 +186,13 @@ public class CrashReportCategory { return this.stackTrace; } - public static void populateBlockDetails(CrashReportCategory category, LevelHeightAccessor levelHeightAccessor, BlockPos pos, @Nullable BlockState state) { - if (state != null) { - category.setDetail("Block", state::toString); - } + public static void populateBlockDetails(CrashReportCategory category, LevelHeightAccessor levelHeightAccessor, BlockPos pos, BlockState state) { + category.setDetail("Block", state::toString); + populateBlockLocationDetails(category, levelHeightAccessor, pos); + } - category.setDetail("Block location", (CrashReportDetail)(() -> formatLocation(levelHeightAccessor, pos))); + public static CrashReportCategory populateBlockLocationDetails(CrashReportCategory category, LevelHeightAccessor levelHeightAccessor, BlockPos pos) { + return category.setDetail("Block location", (CrashReportDetail)(() -> formatLocation(levelHeightAccessor, pos))); } static class Entry { diff --git a/net/minecraft/DetectedVersion.java b/net/minecraft/DetectedVersion.java index 87e5bd19..d611d9ae 100644 --- a/net/minecraft/DetectedVersion.java +++ b/net/minecraft/DetectedVersion.java @@ -28,12 +28,12 @@ public class DetectedVersion implements WorldVersion { private DetectedVersion() { this.id = UUID.randomUUID().toString().replaceAll("-", ""); - this.name = "1.21.4"; + this.name = "1.21.5"; this.stable = true; - this.worldVersion = new DataVersion(4189, "main"); + this.worldVersion = new DataVersion(4325, "main"); this.protocolVersion = SharedConstants.getProtocolVersion(); - this.resourcePackVersion = 46; - this.dataPackVersion = 61; + this.resourcePackVersion = 55; + this.dataPackVersion = 71; this.buildTime = new Date(); } diff --git a/net/minecraft/SharedConstants.java b/net/minecraft/SharedConstants.java index bdac852f..3c50eea0 100644 --- a/net/minecraft/SharedConstants.java +++ b/net/minecraft/SharedConstants.java @@ -34,7 +34,7 @@ public class SharedConstants { * @deprecated Use {@link #getCurrentVersion()} and {@link com.mojang.bridge.game.GameVersion#getWorldVersion()} instead. */ @Deprecated - public static final int WORLD_VERSION = 4189; + public static final int WORLD_VERSION = 4325; @Deprecated public static final String SERIES = "main"; /** @@ -44,7 +44,7 @@ public class SharedConstants { * @deprecated Use {@link #getCurrentVersion()} and {@link com.mojang.bridge.game.GameVersion#getName()} instead. */ @Deprecated - public static final String VERSION_STRING = "1.21.4"; + public static final String VERSION_STRING = "1.21.5"; /** * The numeric format number for the networking protocol used by the release target of this game version. * @@ -54,7 +54,7 @@ public class SharedConstants { * @deprecated Use {@link #getProtocolVersion()} instead. */ @Deprecated - public static final int RELEASE_NETWORK_PROTOCOL_VERSION = 769; + public static final int RELEASE_NETWORK_PROTOCOL_VERSION = 770; /** * The numeric format number for the networking protocol used by the snapshot of this game version. * @@ -66,8 +66,8 @@ public class SharedConstants { * @deprecated Use {@link #getProtocolVersion()} instead. */ @Deprecated - public static final int SNAPSHOT_NETWORK_PROTOCOL_VERSION = 228; - public static final int SNBT_NAG_VERSION = 4173; + public static final int SNAPSHOT_NETWORK_PROTOCOL_VERSION = 243; + public static final int SNBT_NAG_VERSION = 4292; /** * The bit in the networking protocol version for denoting {@linkplain #SNAPSHOT snapshot versions}. * @@ -82,7 +82,7 @@ public class SharedConstants { * @deprecated Use {@link #getCurrentVersion()}, {@link com.mojang.bridge.game.GameVersion#com.mojang.bridge.game.GameVersion#getPackVersion(com.mojang.bridge.game.PackType)}, and com.mojang.bridge.game.PackType#RESOURCE instead. */ @Deprecated - public static final int RESOURCE_PACK_FORMAT = 46; + public static final int RESOURCE_PACK_FORMAT = 55; /** * The format of the data packs used by this game version. Data packs contain server-side data such as recipes, loot tables, and tags. * @@ -90,7 +90,7 @@ public class SharedConstants { * @deprecated Use {@link #getCurrentVersion()}, {@link com.mojang.bridge.game.GameVersion#com.mojang.bridge.game.GameVersion#getPackVersion(com.mojang.bridge.game.PackType)}, and com.mojang.bridge.game.PackType#DATA instead. */ @Deprecated - public static final int DATA_PACK_FORMAT = 61; + public static final int DATA_PACK_FORMAT = 71; @Deprecated public static final int LANGUAGE_FORMAT = 1; public static final int REPORT_FORMAT_VERSION = 1; @@ -154,6 +154,7 @@ public class SharedConstants { public static final boolean DEBUG_TRIAL_SPAWNER_DETECTS_SHEEP_AS_PLAYERS = false; public static final boolean DEBUG_VAULT_DETECTS_SHEEP_AS_PLAYERS = false; public static final boolean DEBUG_FORCE_ONBOARDING_SCREEN = false; + public static final boolean DEBUG_CURSOR_POS = false; public static final boolean DEBUG_IGNORE_LOCAL_MOB_CAP = false; public static final boolean DEBUG_DISABLE_LIQUID_SPREADING = false; public static final boolean DEBUG_AQUIFERS = false; @@ -277,7 +278,7 @@ public class SharedConstants { *

For releases, this will be equivalent to {@link #RELEASE_NETWORK_PROTOCOL_VERSION}. For snapshot versions, this will be the combination (bitwise OR) of {@link #SNAPSHOT_NETWORK_PROTOCOL_VERSION} and the bit marked by {@link #SNAPSHOT_PROTOCOL_BIT}.

*/ public static int getProtocolVersion() { - return 769; + return 770; } public static boolean debugVoidTerrain(ChunkPos chunkPos) { diff --git a/net/minecraft/Util.java b/net/minecraft/Util.java index f9ff28e8..2e912aae 100644 --- a/net/minecraft/Util.java +++ b/net/minecraft/Util.java @@ -5,6 +5,7 @@ import com.google.common.collect.ImmutableList; import com.google.common.collect.ImmutableMap; import com.google.common.collect.Iterators; import com.google.common.collect.Lists; +import com.google.common.collect.Maps; import com.google.common.util.concurrent.MoreExecutors; import com.mojang.datafixers.DataFixUtils; import com.mojang.datafixers.Typed; @@ -458,6 +459,10 @@ public class Util { } } + public static int growByHalf(int value, int minValue) { + return (int)Math.max(Math.min((long)value + (value >> 1), 2147483639L), minValue); + } + public static Util.OS getPlatform() { String string = System.getProperty("os.name").toLowerCase(Locale.ROOT); if (string.contains("win")) { @@ -547,7 +552,7 @@ public class Util { return object; } - public static , V> EnumMap makeEnumMap(Class enumClass, Function valueGetter) { + public static , V> Map makeEnumMap(Class enumClass, Function valueGetter) { EnumMap enumMap = new EnumMap(enumClass); for (K enum_ : (Enum[])enumClass.getEnumConstants()) { @@ -557,6 +562,14 @@ public class Util { return enumMap; } + public static Map mapValues(Map map, Function mapper) { + return (Map)map.entrySet().stream().collect(Collectors.toMap(Entry::getKey, entry -> mapper.apply(entry.getValue()))); + } + + public static Map mapValuesLazy(Map map, com.google.common.base.Function mapper) { + return Maps.transformValues(map, mapper); + } + /** * Takes a list of futures and returns a future of list that completes when all of them succeed or any of them error, */ @@ -606,14 +619,14 @@ public class Util { return CompletableFuture.allOf(completableFutures2).thenApply(void_ -> list); } - public static Optional ifElse(Optional opt, Consumer consumer, Runnable orElse) { - if (opt.isPresent()) { - consumer.accept(opt.get()); + public static Optional ifElse(Optional optional, Consumer ifPresent, Runnable ifEmpty) { + if (optional.isPresent()) { + ifPresent.accept(optional.get()); } else { - orElse.run(); + ifEmpty.run(); } - return opt; + return optional; } public static Supplier name(Supplier item, Supplier nameSupplier) { diff --git a/net/minecraft/advancements/Advancement.java b/net/minecraft/advancements/Advancement.java index d1641e60..efd74e85 100644 --- a/net/minecraft/advancements/Advancement.java +++ b/net/minecraft/advancements/Advancement.java @@ -8,7 +8,9 @@ import java.util.Map; import java.util.Optional; import java.util.function.Consumer; import net.minecraft.ChatFormatting; +import net.minecraft.advancements.AdvancementRequirements.Strategy; import net.minecraft.advancements.critereon.CriterionValidator; +import net.minecraft.core.ClientAsset; import net.minecraft.core.HolderGetter; import net.minecraft.network.FriendlyByteBuf; import net.minecraft.network.RegistryFriendlyByteBuf; @@ -71,7 +73,7 @@ public record Advancement( Component component = display.getTitle(); ChatFormatting chatFormatting = display.getType().getChatColor(); Component component2 = ComponentUtils.mergeStyles(component.copy(), Style.EMPTY.withColor(chatFormatting)).append("\n").append(display.getDescription()); - Component component3 = component.copy().withStyle(style -> style.withHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, component2))); + Component component3 = component.copy().withStyle(style -> style.withHoverEvent(new HoverEvent.ShowText(component2))); return ComponentUtils.wrapInSquareBrackets(component3).withStyle(chatFormatting); } @@ -114,7 +116,7 @@ public record Advancement( private AdvancementRewards rewards = AdvancementRewards.EMPTY; private final ImmutableMap.Builder> criteria = ImmutableMap.builder(); private Optional requirements = Optional.empty(); - private AdvancementRequirements.Strategy requirementsStrategy = AdvancementRequirements.Strategy.AND; + private Strategy requirementsStrategy = Strategy.AND; private boolean sendsTelemetryEvent; public static Advancement.Builder advancement() { @@ -148,7 +150,7 @@ public record Advancement( boolean announceChat, boolean hidden ) { - return this.display(new DisplayInfo(icon, title, description, Optional.ofNullable(background), type, showToast, announceChat, hidden)); + return this.display(new DisplayInfo(icon, title, description, Optional.ofNullable(background).map(ClientAsset::new), type, showToast, announceChat, hidden)); } public Advancement.Builder display( @@ -162,7 +164,9 @@ public record Advancement( boolean hidden ) { return this.display( - new DisplayInfo(new ItemStack(icon.asItem()), title, description, Optional.ofNullable(background), type, showToast, announceChat, hidden) + new DisplayInfo( + new ItemStack(icon.asItem()), title, description, Optional.ofNullable(background).map(ClientAsset::new), type, showToast, announceChat, hidden + ) ); } @@ -185,7 +189,7 @@ public record Advancement( return this; } - public Advancement.Builder requirements(AdvancementRequirements.Strategy requirementsStrategy) { + public Advancement.Builder requirements(Strategy requirementsStrategy) { this.requirementsStrategy = requirementsStrategy; return this; } diff --git a/net/minecraft/advancements/AdvancementProgress.java b/net/minecraft/advancements/AdvancementProgress.java index 0ee174cc..191503f3 100644 --- a/net/minecraft/advancements/AdvancementProgress.java +++ b/net/minecraft/advancements/AdvancementProgress.java @@ -16,6 +16,7 @@ import java.util.Objects; import java.util.Set; import java.util.Map.Entry; import java.util.stream.Collectors; +import net.minecraft.Util; import net.minecraft.network.FriendlyByteBuf; import net.minecraft.network.chat.Component; import net.minecraft.util.ExtraCodecs; @@ -27,7 +28,7 @@ public class AdvancementProgress implements Comparable { .xmap(Instant::from, instant -> instant.atZone(ZoneId.systemDefault())); private static final Codec> CRITERIA_CODEC = Codec.unboundedMap(Codec.STRING, OBTAINED_TIME_CODEC) .xmap( - map -> (Map)map.entrySet().stream().collect(Collectors.toMap(Entry::getKey, entry -> new CriterionProgress((Instant)entry.getValue()))), + map -> Util.mapValues(map, CriterionProgress::new), map -> (Map)map.entrySet() .stream() .filter(entry -> ((CriterionProgress)entry.getValue()).isDone()) diff --git a/net/minecraft/advancements/AdvancementRewards.java b/net/minecraft/advancements/AdvancementRewards.java index 48e68a60..1a6c38bd 100644 --- a/net/minecraft/advancements/AdvancementRewards.java +++ b/net/minecraft/advancements/AdvancementRewards.java @@ -6,7 +6,6 @@ import com.mojang.serialization.codecs.RecordCodecBuilder; import java.util.List; import java.util.Optional; import net.minecraft.commands.CacheableFunction; -import net.minecraft.core.registries.Registries; import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.MinecraftServer; @@ -25,8 +24,8 @@ public record AdvancementRewards(int experience, List> lo public static final Codec CODEC = RecordCodecBuilder.create( instance -> instance.group( Codec.INT.optionalFieldOf("experience", 0).forGetter(AdvancementRewards::experience), - ResourceKey.codec(Registries.LOOT_TABLE).listOf().optionalFieldOf("loot", List.of()).forGetter(AdvancementRewards::loot), - ResourceKey.codec(Registries.RECIPE).listOf().optionalFieldOf("recipes", List.of()).forGetter(AdvancementRewards::recipes), + LootTable.KEY_CODEC.listOf().optionalFieldOf("loot", List.of()).forGetter(AdvancementRewards::loot), + Recipe.KEY_CODEC.listOf().optionalFieldOf("recipes", List.of()).forGetter(AdvancementRewards::recipes), CacheableFunction.CODEC.optionalFieldOf("function").forGetter(AdvancementRewards::function) ) .apply(instance, AdvancementRewards::new) diff --git a/net/minecraft/advancements/DisplayInfo.java b/net/minecraft/advancements/DisplayInfo.java index bcb67f3b..3fe7a140 100644 --- a/net/minecraft/advancements/DisplayInfo.java +++ b/net/minecraft/advancements/DisplayInfo.java @@ -3,11 +3,11 @@ package net.minecraft.advancements; import com.mojang.serialization.Codec; import com.mojang.serialization.codecs.RecordCodecBuilder; import java.util.Optional; +import net.minecraft.core.ClientAsset; import net.minecraft.network.RegistryFriendlyByteBuf; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.ComponentSerialization; import net.minecraft.network.codec.StreamCodec; -import net.minecraft.resources.ResourceLocation; import net.minecraft.world.item.ItemStack; public class DisplayInfo { @@ -16,7 +16,7 @@ public class DisplayInfo { ItemStack.STRICT_CODEC.fieldOf("icon").forGetter(DisplayInfo::getIcon), ComponentSerialization.CODEC.fieldOf("title").forGetter(DisplayInfo::getTitle), ComponentSerialization.CODEC.fieldOf("description").forGetter(DisplayInfo::getDescription), - ResourceLocation.CODEC.optionalFieldOf("background").forGetter(DisplayInfo::getBackground), + ClientAsset.CODEC.optionalFieldOf("background").forGetter(DisplayInfo::getBackground), AdvancementType.CODEC.optionalFieldOf("frame", AdvancementType.TASK).forGetter(DisplayInfo::getType), Codec.BOOL.optionalFieldOf("show_toast", true).forGetter(DisplayInfo::shouldShowToast), Codec.BOOL.optionalFieldOf("announce_to_chat", true).forGetter(DisplayInfo::shouldAnnounceChat), @@ -30,7 +30,7 @@ public class DisplayInfo { private final Component title; private final Component description; private final ItemStack icon; - private final Optional background; + private final Optional background; private final AdvancementType type; private final boolean showToast; private final boolean announceChat; @@ -42,7 +42,7 @@ public class DisplayInfo { ItemStack icon, Component title, Component description, - Optional background, + Optional background, AdvancementType type, boolean showToast, boolean announceChat, @@ -75,7 +75,7 @@ public class DisplayInfo { return this.icon; } - public Optional getBackground() { + public Optional getBackground() { return this.background; } @@ -122,7 +122,7 @@ public class DisplayInfo { } buffer.writeInt(i); - this.background.ifPresent(buffer::writeResourceLocation); + this.background.map(ClientAsset::id).ifPresent(buffer::writeResourceLocation); buffer.writeFloat(this.x); buffer.writeFloat(this.y); } @@ -133,7 +133,7 @@ public class DisplayInfo { ItemStack itemStack = ItemStack.STREAM_CODEC.decode(buffer); AdvancementType advancementType = buffer.readEnum(AdvancementType.class); int i = buffer.readInt(); - Optional optional = (i & 1) != 0 ? Optional.of(buffer.readResourceLocation()) : Optional.empty(); + Optional optional = (i & 1) != 0 ? Optional.of(new ClientAsset(buffer.readResourceLocation())) : Optional.empty(); boolean bl = (i & 2) != 0; boolean bl2 = (i & 4) != 0; DisplayInfo displayInfo = new DisplayInfo(itemStack, component, component2, optional, advancementType, bl, false, bl2); diff --git a/net/minecraft/advancements/critereon/BlockPredicate.java b/net/minecraft/advancements/critereon/BlockPredicate.java index 14e3c5c2..71f7cdd8 100644 --- a/net/minecraft/advancements/critereon/BlockPredicate.java +++ b/net/minecraft/advancements/critereon/BlockPredicate.java @@ -9,6 +9,7 @@ import net.minecraft.core.BlockPos; import net.minecraft.core.HolderGetter; import net.minecraft.core.HolderSet; import net.minecraft.core.RegistryCodecs; +import net.minecraft.core.component.DataComponentGetter; import net.minecraft.core.registries.Registries; import net.minecraft.nbt.CompoundTag; import net.minecraft.network.RegistryFriendlyByteBuf; @@ -23,12 +24,15 @@ import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.pattern.BlockInWorld; import org.jetbrains.annotations.Nullable; -public record BlockPredicate(Optional> blocks, Optional properties, Optional nbt) { +public record BlockPredicate( + Optional> blocks, Optional properties, Optional nbt, DataComponentMatchers components +) { public static final Codec CODEC = RecordCodecBuilder.create( instance -> instance.group( RegistryCodecs.homogeneousList(Registries.BLOCK).optionalFieldOf("blocks").forGetter(BlockPredicate::blocks), StatePropertiesPredicate.CODEC.optionalFieldOf("state").forGetter(BlockPredicate::properties), - NbtPredicate.CODEC.optionalFieldOf("nbt").forGetter(BlockPredicate::nbt) + NbtPredicate.CODEC.optionalFieldOf("nbt").forGetter(BlockPredicate::nbt), + DataComponentMatchers.CODEC.forGetter(BlockPredicate::components) ) .apply(instance, BlockPredicate::new) ); @@ -39,16 +43,29 @@ public record BlockPredicate(Optional> blocks, Optional> blocks, Optional> blocks, Optional> blocks = Optional.empty(); private Optional properties = Optional.empty(); private Optional nbt = Optional.empty(); + private DataComponentMatchers components = DataComponentMatchers.ANY; private Builder() { } @@ -108,8 +130,13 @@ public record BlockPredicate(Optional> blocks, Optional, DataComponentPredicate> partial) + implements Predicate { + public static final DataComponentMatchers ANY = new DataComponentMatchers(DataComponentExactPredicate.EMPTY, Map.of()); + public static final MapCodec CODEC = RecordCodecBuilder.mapCodec( + instance -> instance.group( + DataComponentExactPredicate.CODEC.optionalFieldOf("components", DataComponentExactPredicate.EMPTY).forGetter(DataComponentMatchers::exact), + DataComponentPredicate.CODEC.optionalFieldOf("predicates", Map.of()).forGetter(DataComponentMatchers::partial) + ) + .apply(instance, DataComponentMatchers::new) + ); + public static final StreamCodec STREAM_CODEC = StreamCodec.composite( + DataComponentExactPredicate.STREAM_CODEC, + DataComponentMatchers::exact, + DataComponentPredicate.STREAM_CODEC, + DataComponentMatchers::partial, + DataComponentMatchers::new + ); + + public boolean test(DataComponentGetter dataComponentGetter) { + if (!this.exact.test(dataComponentGetter)) { + return false; + } else { + for (DataComponentPredicate dataComponentPredicate : this.partial.values()) { + if (!dataComponentPredicate.matches(dataComponentGetter)) { + return false; + } + } + + return true; + } + } + + public boolean isEmpty() { + return this.exact.isEmpty() && this.partial.isEmpty(); + } + + public static class Builder { + private DataComponentExactPredicate exact = DataComponentExactPredicate.EMPTY; + private final ImmutableMap.Builder, DataComponentPredicate> partial = ImmutableMap.builder(); + + private Builder() { + } + + public static DataComponentMatchers.Builder components() { + return new DataComponentMatchers.Builder(); + } + + public DataComponentMatchers.Builder partial(DataComponentPredicate.Type type, T value) { + this.partial.put(type, value); + return this; + } + + public DataComponentMatchers.Builder exact(DataComponentExactPredicate exact) { + this.exact = exact; + return this; + } + + public DataComponentMatchers build() { + return new DataComponentMatchers(this.exact, this.partial.buildOrThrow()); + } + } +} diff --git a/net/minecraft/advancements/critereon/EntityEquipmentPredicate.java b/net/minecraft/advancements/critereon/EntityEquipmentPredicate.java index d8dcb3a1..8953109a 100644 --- a/net/minecraft/advancements/critereon/EntityEquipmentPredicate.java +++ b/net/minecraft/advancements/critereon/EntityEquipmentPredicate.java @@ -4,7 +4,7 @@ import com.mojang.serialization.Codec; import com.mojang.serialization.codecs.RecordCodecBuilder; import java.util.Optional; import net.minecraft.core.HolderGetter; -import net.minecraft.core.component.DataComponentPredicate; +import net.minecraft.core.component.DataComponentExactPredicate; import net.minecraft.core.component.DataComponents; import net.minecraft.world.entity.Entity; import net.minecraft.world.entity.EquipmentSlot; @@ -42,8 +42,14 @@ public record EntityEquipmentPredicate( .head( ItemPredicate.Builder.item() .of(itemRegistry, Items.WHITE_BANNER) - .hasComponents( - DataComponentPredicate.someOf(Raid.getOminousBannerInstance(patternRegistry).getComponents(), DataComponents.BANNER_PATTERNS, DataComponents.ITEM_NAME) + .withComponents( + DataComponentMatchers.Builder.components() + .exact( + DataComponentExactPredicate.someOf( + Raid.getOminousBannerInstance(patternRegistry).getComponents(), DataComponents.BANNER_PATTERNS, DataComponents.ITEM_NAME + ) + ) + .build() ) ) .build(); diff --git a/net/minecraft/advancements/critereon/EntityPredicate.java b/net/minecraft/advancements/critereon/EntityPredicate.java index c2b8cb49..0c93f933 100644 --- a/net/minecraft/advancements/critereon/EntityPredicate.java +++ b/net/minecraft/advancements/critereon/EntityPredicate.java @@ -7,6 +7,7 @@ import java.util.List; import java.util.Optional; import java.util.stream.Stream; import net.minecraft.core.HolderGetter; +import net.minecraft.core.component.DataComponentGetter; import net.minecraft.server.level.ServerLevel; import net.minecraft.server.level.ServerPlayer; import net.minecraft.tags.TagKey; @@ -39,7 +40,8 @@ public record EntityPredicate( Optional passenger, Optional targetedEntity, Optional team, - Optional slots + Optional slots, + DataComponentMatchers components ) { public static final Codec CODEC = Codec.recursive( "EntityPredicate", @@ -59,7 +61,8 @@ public record EntityPredicate( codec.optionalFieldOf("passenger").forGetter(EntityPredicate::passenger), codec.optionalFieldOf("targeted_entity").forGetter(EntityPredicate::targetedEntity), Codec.STRING.optionalFieldOf("team").forGetter(EntityPredicate::team), - SlotsPredicate.CODEC.optionalFieldOf("slots").forGetter(EntityPredicate::slots) + SlotsPredicate.CODEC.optionalFieldOf("slots").forGetter(EntityPredicate::slots), + DataComponentMatchers.CODEC.forGetter(EntityPredicate::components) ) .apply(instance, EntityPredicate::new) ) @@ -115,7 +118,7 @@ public record EntityPredicate( } else { if (this.location.steppingOn.isPresent()) { Vec3 vec3 = Vec3.atCenterOf(entity.getOnPos()); - if (!((LocationPredicate)this.location.steppingOn.get()).matches(level, vec3.x(), vec3.y(), vec3.z())) { + if (!entity.onGround() || !((LocationPredicate)this.location.steppingOn.get()).matches(level, vec3.x(), vec3.y(), vec3.z())) { return false; } } @@ -153,9 +156,11 @@ public record EntityPredicate( } } - return this.slots.isPresent() && !((SlotsPredicate)this.slots.get()).matches(entity) - ? false - : !this.nbt.isPresent() || ((NbtPredicate)this.nbt.get()).matches(entity); + if (this.slots.isPresent() && !((SlotsPredicate)this.slots.get()).matches(entity)) { + return false; + } else { + return !this.components.test((DataComponentGetter)entity) ? false : this.nbt.isEmpty() || ((NbtPredicate)this.nbt.get()).matches(entity); + } } } } @@ -187,6 +192,7 @@ public record EntityPredicate( private Optional targetedEntity = Optional.empty(); private Optional team = Optional.empty(); private Optional slots = Optional.empty(); + private DataComponentMatchers components = DataComponentMatchers.ANY; public static EntityPredicate.Builder entity() { return new EntityPredicate.Builder(); @@ -292,6 +298,11 @@ public record EntityPredicate( return this; } + public EntityPredicate.Builder components(DataComponentMatchers components) { + this.components = components; + return this; + } + public EntityPredicate build() { return new EntityPredicate( this.entityType, @@ -308,7 +319,8 @@ public record EntityPredicate( this.passenger, this.targetedEntity, this.team, - this.slots + this.slots, + this.components ); } } diff --git a/net/minecraft/advancements/critereon/EntitySubPredicates.java b/net/minecraft/advancements/critereon/EntitySubPredicates.java index deff8c76..9f2c9fc9 100644 --- a/net/minecraft/advancements/critereon/EntitySubPredicates.java +++ b/net/minecraft/advancements/critereon/EntitySubPredicates.java @@ -1,39 +1,8 @@ package net.minecraft.advancements.critereon; -import com.mojang.serialization.Codec; import com.mojang.serialization.MapCodec; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.Optional; -import java.util.function.Function; -import net.minecraft.advancements.critereon.EntitySubPredicates.EntityHolderVariantPredicateType.Instance; -import net.minecraft.core.Holder; -import net.minecraft.core.HolderSet; import net.minecraft.core.Registry; -import net.minecraft.core.RegistryCodecs; import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.core.registries.Registries; -import net.minecraft.resources.ResourceKey; -import net.minecraft.world.entity.Entity; -import net.minecraft.world.entity.animal.Cat; -import net.minecraft.world.entity.animal.CatVariant; -import net.minecraft.world.entity.animal.Fox; -import net.minecraft.world.entity.animal.FrogVariant; -import net.minecraft.world.entity.animal.MushroomCow; -import net.minecraft.world.entity.animal.Parrot; -import net.minecraft.world.entity.animal.Rabbit; -import net.minecraft.world.entity.animal.Salmon; -import net.minecraft.world.entity.animal.TropicalFish; -import net.minecraft.world.entity.animal.Wolf; -import net.minecraft.world.entity.animal.WolfVariant; -import net.minecraft.world.entity.animal.axolotl.Axolotl; -import net.minecraft.world.entity.animal.frog.Frog; -import net.minecraft.world.entity.animal.horse.Horse; -import net.minecraft.world.entity.animal.horse.Llama; -import net.minecraft.world.entity.animal.horse.Variant; -import net.minecraft.world.entity.decoration.Painting; -import net.minecraft.world.entity.decoration.PaintingVariant; -import net.minecraft.world.entity.npc.VillagerDataHolder; -import net.minecraft.world.entity.npc.VillagerType; public class EntitySubPredicates { public static final MapCodec LIGHTNING = register("lightning", LightningBoltPredicate.CODEC); @@ -42,169 +11,12 @@ public class EntitySubPredicates { public static final MapCodec SLIME = register("slime", SlimePredicate.CODEC); public static final MapCodec RAIDER = register("raider", RaiderPredicate.CODEC); public static final MapCodec SHEEP = register("sheep", SheepPredicate.CODEC); - public static final EntitySubPredicates.EntityVariantPredicateType AXOLOTL = register( - "axolotl", - EntitySubPredicates.EntityVariantPredicateType.create( - Axolotl.Variant.CODEC, entity -> entity instanceof Axolotl axolotl ? Optional.of(axolotl.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType FOX = register( - "fox", - EntitySubPredicates.EntityVariantPredicateType.create( - Fox.Variant.CODEC, entity -> entity instanceof Fox fox ? Optional.of(fox.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType MOOSHROOM = register( - "mooshroom", - EntitySubPredicates.EntityVariantPredicateType.create( - MushroomCow.Variant.CODEC, entity -> entity instanceof MushroomCow mushroomCow ? Optional.of(mushroomCow.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType RABBIT = register( - "rabbit", - EntitySubPredicates.EntityVariantPredicateType.create( - Rabbit.Variant.CODEC, entity -> entity instanceof Rabbit rabbit ? Optional.of(rabbit.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType HORSE = register( - "horse", - EntitySubPredicates.EntityVariantPredicateType.create( - Variant.CODEC, entity -> entity instanceof Horse horse ? Optional.of(horse.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType LLAMA = register( - "llama", - EntitySubPredicates.EntityVariantPredicateType.create( - Llama.Variant.CODEC, entity -> entity instanceof Llama llama ? Optional.of(llama.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType VILLAGER = register( - "villager", - EntitySubPredicates.EntityVariantPredicateType.create( - BuiltInRegistries.VILLAGER_TYPE.byNameCodec(), - entity -> entity instanceof VillagerDataHolder villagerDataHolder ? Optional.of(villagerDataHolder.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType PARROT = register( - "parrot", - EntitySubPredicates.EntityVariantPredicateType.create( - Parrot.Variant.CODEC, entity -> entity instanceof Parrot parrot ? Optional.of(parrot.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType SALMON = register( - "salmon", - EntitySubPredicates.EntityVariantPredicateType.create( - Salmon.Variant.CODEC, entity -> entity instanceof Salmon salmon ? Optional.of(salmon.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityVariantPredicateType TROPICAL_FISH = register( - "tropical_fish", - EntitySubPredicates.EntityVariantPredicateType.create( - TropicalFish.Pattern.CODEC, entity -> entity instanceof TropicalFish tropicalFish ? Optional.of(tropicalFish.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityHolderVariantPredicateType PAINTING = register( - "painting", - EntitySubPredicates.EntityHolderVariantPredicateType.create( - Registries.PAINTING_VARIANT, entity -> entity instanceof Painting painting ? Optional.of(painting.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityHolderVariantPredicateType CAT = register( - "cat", - EntitySubPredicates.EntityHolderVariantPredicateType.create( - Registries.CAT_VARIANT, entity -> entity instanceof Cat cat ? Optional.of(cat.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityHolderVariantPredicateType FROG = register( - "frog", - EntitySubPredicates.EntityHolderVariantPredicateType.create( - Registries.FROG_VARIANT, entity -> entity instanceof Frog frog ? Optional.of(frog.getVariant()) : Optional.empty() - ) - ); - public static final EntitySubPredicates.EntityHolderVariantPredicateType WOLF = register( - "wolf", - EntitySubPredicates.EntityHolderVariantPredicateType.create( - Registries.WOLF_VARIANT, entity -> entity instanceof Wolf wolf ? Optional.of(wolf.getVariant()) : Optional.empty() - ) - ); private static MapCodec register(String name, MapCodec codec) { return Registry.register(BuiltInRegistries.ENTITY_SUB_PREDICATE_TYPE, name, codec); } - private static EntitySubPredicates.EntityVariantPredicateType register(String name, EntitySubPredicates.EntityVariantPredicateType predicateType) { - Registry.register(BuiltInRegistries.ENTITY_SUB_PREDICATE_TYPE, name, predicateType.codec); - return predicateType; - } - - private static EntitySubPredicates.EntityHolderVariantPredicateType register( - String name, EntitySubPredicates.EntityHolderVariantPredicateType predicateType - ) { - Registry.register(BuiltInRegistries.ENTITY_SUB_PREDICATE_TYPE, name, predicateType.codec); - return predicateType; - } - public static MapCodec bootstrap(Registry> registry) { return LIGHTNING; } - - public static EntitySubPredicate catVariant(Holder catVariant) { - return CAT.createPredicate(HolderSet.direct(catVariant)); - } - - public static EntitySubPredicate frogVariant(Holder frogVariant) { - return FROG.createPredicate(HolderSet.direct(frogVariant)); - } - - public static EntitySubPredicate wolfVariant(HolderSet wolfVariant) { - return WOLF.createPredicate(wolfVariant); - } - - public static class EntityHolderVariantPredicateType { - final MapCodec.Instance> codec; - final Function>> getter; - - public static EntitySubPredicates.EntityHolderVariantPredicateType create( - ResourceKey> registryKey, Function>> getter - ) { - return new EntitySubPredicates.EntityHolderVariantPredicateType<>(registryKey, getter); - } - - public EntityHolderVariantPredicateType(ResourceKey> registryKey, Function>> getter) { - this.getter = getter; - this.codec = RecordCodecBuilder.mapCodec( - instance -> instance.group(RegistryCodecs.homogeneousList(registryKey).fieldOf("variant").forGetter(instancex -> instancex.variants)) - .apply(instance, holderSet -> new Instance(this, holderSet)) - ); - } - - public EntitySubPredicate createPredicate(HolderSet variants) { - return new Instance(this, variants); - } - } - - public static class EntityVariantPredicateType { - final MapCodec.Instance> codec; - final Function> getter; - - public static EntitySubPredicates.EntityVariantPredicateType create(Registry variantRegistry, Function> getter) { - return new EntitySubPredicates.EntityVariantPredicateType<>(variantRegistry.byNameCodec(), getter); - } - - public static EntitySubPredicates.EntityVariantPredicateType create(Codec codec, Function> getter) { - return new EntitySubPredicates.EntityVariantPredicateType<>(codec, getter); - } - - public EntityVariantPredicateType(Codec codec, Function> getter) { - this.getter = getter; - this.codec = RecordCodecBuilder.mapCodec( - instance -> instance.group(codec.fieldOf("variant").forGetter(instancex -> instancex.variant)) - .apply(instance, object -> new net.minecraft.advancements.critereon.EntitySubPredicates.EntityVariantPredicateType.Instance(this, object)) - ); - } - - public EntitySubPredicate createPredicate(V variant) { - return new net.minecraft.advancements.critereon.EntitySubPredicates.EntityVariantPredicateType.Instance(this, variant); - } - } } diff --git a/net/minecraft/advancements/critereon/InventoryChangeTrigger.java b/net/minecraft/advancements/critereon/InventoryChangeTrigger.java index fe1c6928..fe063418 100644 --- a/net/minecraft/advancements/critereon/InventoryChangeTrigger.java +++ b/net/minecraft/advancements/critereon/InventoryChangeTrigger.java @@ -4,13 +4,13 @@ import com.mojang.serialization.Codec; import com.mojang.serialization.codecs.RecordCodecBuilder; import it.unimi.dsi.fastutil.objects.ObjectArrayList; import java.util.List; -import java.util.Map; import java.util.Optional; import java.util.stream.Stream; import net.minecraft.advancements.CriteriaTriggers; import net.minecraft.advancements.Criterion; +import net.minecraft.advancements.critereon.InventoryChangeTrigger.TriggerInstance.Slots; +import net.minecraft.advancements.critereon.SimpleCriterionTrigger.SimpleInstance; import net.minecraft.core.HolderSet; -import net.minecraft.core.component.DataComponentPredicate; import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.item.ItemStack; @@ -46,14 +46,11 @@ public class InventoryChangeTrigger extends SimpleCriterionTrigger triggerInstance.matches(inventory, stack, full, empty, occupied)); } - public record TriggerInstance(Optional player, InventoryChangeTrigger.TriggerInstance.Slots slots, List items) - implements SimpleCriterionTrigger.SimpleInstance { + public record TriggerInstance(Optional player, Slots slots, List items) implements SimpleInstance { public static final Codec CODEC = RecordCodecBuilder.create( instance -> instance.group( EntityPredicate.ADVANCEMENT_CODEC.optionalFieldOf("player").forGetter(InventoryChangeTrigger.TriggerInstance::player), - InventoryChangeTrigger.TriggerInstance.Slots.CODEC - .optionalFieldOf("slots", InventoryChangeTrigger.TriggerInstance.Slots.ANY) - .forGetter(InventoryChangeTrigger.TriggerInstance::slots), + Slots.CODEC.optionalFieldOf("slots", Slots.ANY).forGetter(InventoryChangeTrigger.TriggerInstance::slots), ItemPredicate.CODEC.listOf().optionalFieldOf("items", List.of()).forGetter(InventoryChangeTrigger.TriggerInstance::items) ) .apply(instance, InventoryChangeTrigger.TriggerInstance::new) @@ -64,8 +61,7 @@ public class InventoryChangeTrigger extends SimpleCriterionTrigger hasItems(ItemPredicate... items) { - return CriteriaTriggers.INVENTORY_CHANGED - .createCriterion(new InventoryChangeTrigger.TriggerInstance(Optional.empty(), InventoryChangeTrigger.TriggerInstance.Slots.ANY, List.of(items))); + return CriteriaTriggers.INVENTORY_CHANGED.createCriterion(new InventoryChangeTrigger.TriggerInstance(Optional.empty(), Slots.ANY, List.of(items))); } public static Criterion hasItems(ItemLike... items) { @@ -73,7 +69,7 @@ public class InventoryChangeTrigger extends SimpleCriterionTrigger CODEC = RecordCodecBuilder.create( - instance -> instance.group( - MinMaxBounds.Ints.CODEC.optionalFieldOf("occupied", MinMaxBounds.Ints.ANY).forGetter(InventoryChangeTrigger.TriggerInstance.Slots::occupied), - MinMaxBounds.Ints.CODEC.optionalFieldOf("full", MinMaxBounds.Ints.ANY).forGetter(InventoryChangeTrigger.TriggerInstance.Slots::full), - MinMaxBounds.Ints.CODEC.optionalFieldOf("empty", MinMaxBounds.Ints.ANY).forGetter(InventoryChangeTrigger.TriggerInstance.Slots::empty) - ) - .apply(instance, InventoryChangeTrigger.TriggerInstance.Slots::new) - ); - public static final InventoryChangeTrigger.TriggerInstance.Slots ANY = new InventoryChangeTrigger.TriggerInstance.Slots( - MinMaxBounds.Ints.ANY, MinMaxBounds.Ints.ANY, MinMaxBounds.Ints.ANY - ); - - public boolean matches(int full, int empty, int occupied) { - if (!this.full.matches(full)) { - return false; - } else { - return !this.empty.matches(empty) ? false : this.occupied.matches(occupied); - } - } - } } } diff --git a/net/minecraft/advancements/critereon/ItemAttributeModifiersPredicate.java b/net/minecraft/advancements/critereon/ItemAttributeModifiersPredicate.java deleted file mode 100644 index 9536099d..00000000 --- a/net/minecraft/advancements/critereon/ItemAttributeModifiersPredicate.java +++ /dev/null @@ -1,69 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.Optional; -import java.util.function.Predicate; -import net.minecraft.advancements.critereon.MinMaxBounds.Doubles; -import net.minecraft.core.HolderSet; -import net.minecraft.core.RegistryCodecs; -import net.minecraft.core.component.DataComponentType; -import net.minecraft.core.component.DataComponents; -import net.minecraft.core.registries.Registries; -import net.minecraft.resources.ResourceLocation; -import net.minecraft.world.entity.EquipmentSlotGroup; -import net.minecraft.world.entity.ai.attributes.Attribute; -import net.minecraft.world.entity.ai.attributes.AttributeModifier.Operation; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.component.ItemAttributeModifiers; -import net.minecraft.world.item.component.ItemAttributeModifiers.Entry; - -public record ItemAttributeModifiersPredicate(Optional> modifiers) - implements SingleComponentItemPredicate { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group( - CollectionPredicate.codec(ItemAttributeModifiersPredicate.EntryPredicate.CODEC) - .optionalFieldOf("modifiers") - .forGetter(ItemAttributeModifiersPredicate::modifiers) - ) - .apply(instance, ItemAttributeModifiersPredicate::new) - ); - - @Override - public DataComponentType componentType() { - return DataComponents.ATTRIBUTE_MODIFIERS; - } - - public boolean matches(ItemStack itemStack, ItemAttributeModifiers itemAttributeModifiers) { - return !this.modifiers.isPresent() || ((CollectionPredicate)this.modifiers.get()).test((Iterable)itemAttributeModifiers.modifiers()); - } - - public record EntryPredicate( - Optional> attribute, Optional id, Doubles amount, Optional operation, Optional slot - ) implements Predicate { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group( - RegistryCodecs.homogeneousList(Registries.ATTRIBUTE).optionalFieldOf("attribute").forGetter(ItemAttributeModifiersPredicate.EntryPredicate::attribute), - ResourceLocation.CODEC.optionalFieldOf("id").forGetter(ItemAttributeModifiersPredicate.EntryPredicate::id), - Doubles.CODEC.optionalFieldOf("amount", Doubles.ANY).forGetter(ItemAttributeModifiersPredicate.EntryPredicate::amount), - Operation.CODEC.optionalFieldOf("operation").forGetter(ItemAttributeModifiersPredicate.EntryPredicate::operation), - EquipmentSlotGroup.CODEC.optionalFieldOf("slot").forGetter(ItemAttributeModifiersPredicate.EntryPredicate::slot) - ) - .apply(instance, ItemAttributeModifiersPredicate.EntryPredicate::new) - ); - - public boolean test(Entry entry) { - if (this.attribute.isPresent() && !((HolderSet)this.attribute.get()).contains(entry.attribute())) { - return false; - } else if (this.id.isPresent() && !((ResourceLocation)this.id.get()).equals(entry.modifier().id())) { - return false; - } else if (!this.amount.matches(entry.modifier().amount())) { - return false; - } else { - return this.operation.isPresent() && this.operation.get() != entry.modifier().operation() - ? false - : !this.slot.isPresent() || this.slot.get() == entry.slot(); - } - } - } -} diff --git a/net/minecraft/advancements/critereon/ItemBundlePredicate.java b/net/minecraft/advancements/critereon/ItemBundlePredicate.java deleted file mode 100644 index e8c22fbe..00000000 --- a/net/minecraft/advancements/critereon/ItemBundlePredicate.java +++ /dev/null @@ -1,25 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.Optional; -import net.minecraft.core.component.DataComponentType; -import net.minecraft.core.component.DataComponents; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.component.BundleContents; - -public record ItemBundlePredicate(Optional> items) implements SingleComponentItemPredicate { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group(CollectionPredicate.codec(ItemPredicate.CODEC).optionalFieldOf("items").forGetter(ItemBundlePredicate::items)) - .apply(instance, ItemBundlePredicate::new) - ); - - @Override - public DataComponentType componentType() { - return DataComponents.BUNDLE_CONTENTS; - } - - public boolean matches(ItemStack itemStack, BundleContents bundleContents) { - return !this.items.isPresent() || ((CollectionPredicate)this.items.get()).test(bundleContents.items()); - } -} diff --git a/net/minecraft/advancements/critereon/ItemContainerPredicate.java b/net/minecraft/advancements/critereon/ItemContainerPredicate.java deleted file mode 100644 index 91cf0987..00000000 --- a/net/minecraft/advancements/critereon/ItemContainerPredicate.java +++ /dev/null @@ -1,26 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.Optional; -import net.minecraft.core.component.DataComponentType; -import net.minecraft.core.component.DataComponents; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.component.ItemContainerContents; - -public record ItemContainerPredicate(Optional> items) - implements SingleComponentItemPredicate { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group(CollectionPredicate.codec(ItemPredicate.CODEC).optionalFieldOf("items").forGetter(ItemContainerPredicate::items)) - .apply(instance, ItemContainerPredicate::new) - ); - - @Override - public DataComponentType componentType() { - return DataComponents.CONTAINER; - } - - public boolean matches(ItemStack itemStack, ItemContainerContents itemContainerContents) { - return !this.items.isPresent() || ((CollectionPredicate)this.items.get()).test(itemContainerContents.nonEmptyItems()); - } -} diff --git a/net/minecraft/advancements/critereon/ItemCustomDataPredicate.java b/net/minecraft/advancements/critereon/ItemCustomDataPredicate.java deleted file mode 100644 index 33ed2c48..00000000 --- a/net/minecraft/advancements/critereon/ItemCustomDataPredicate.java +++ /dev/null @@ -1,17 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import net.minecraft.world.item.ItemStack; - -public record ItemCustomDataPredicate(NbtPredicate value) implements ItemSubPredicate { - public static final Codec CODEC = NbtPredicate.CODEC.xmap(ItemCustomDataPredicate::new, ItemCustomDataPredicate::value); - - @Override - public boolean matches(ItemStack stack) { - return this.value.matches(stack); - } - - public static ItemCustomDataPredicate customData(NbtPredicate value) { - return new ItemCustomDataPredicate(value); - } -} diff --git a/net/minecraft/advancements/critereon/ItemDamagePredicate.java b/net/minecraft/advancements/critereon/ItemDamagePredicate.java deleted file mode 100644 index c083def5..00000000 --- a/net/minecraft/advancements/critereon/ItemDamagePredicate.java +++ /dev/null @@ -1,31 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import net.minecraft.advancements.critereon.MinMaxBounds.Ints; -import net.minecraft.core.component.DataComponentType; -import net.minecraft.core.component.DataComponents; -import net.minecraft.world.item.ItemStack; - -public record ItemDamagePredicate(Ints durability, Ints damage) implements SingleComponentItemPredicate { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group( - Ints.CODEC.optionalFieldOf("durability", Ints.ANY).forGetter(ItemDamagePredicate::durability), - Ints.CODEC.optionalFieldOf("damage", Ints.ANY).forGetter(ItemDamagePredicate::damage) - ) - .apply(instance, ItemDamagePredicate::new) - ); - - @Override - public DataComponentType componentType() { - return DataComponents.DAMAGE; - } - - public boolean matches(ItemStack itemStack, Integer integer) { - return !this.durability.matches(itemStack.getMaxDamage() - integer) ? false : this.damage.matches(integer); - } - - public static ItemDamagePredicate durability(Ints damage) { - return new ItemDamagePredicate(damage, Ints.ANY); - } -} diff --git a/net/minecraft/advancements/critereon/ItemEnchantmentsPredicate.java b/net/minecraft/advancements/critereon/ItemEnchantmentsPredicate.java deleted file mode 100644 index 03b755b9..00000000 --- a/net/minecraft/advancements/critereon/ItemEnchantmentsPredicate.java +++ /dev/null @@ -1,69 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import java.util.List; -import java.util.function.Function; -import net.minecraft.core.component.DataComponentType; -import net.minecraft.core.component.DataComponents; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.enchantment.ItemEnchantments; - -public abstract class ItemEnchantmentsPredicate implements SingleComponentItemPredicate { - private final List enchantments; - - protected ItemEnchantmentsPredicate(List enchantments) { - this.enchantments = enchantments; - } - - public static Codec codec(Function, T> predicateFactory) { - return EnchantmentPredicate.CODEC.listOf().xmap(predicateFactory, ItemEnchantmentsPredicate::enchantments); - } - - protected List enchantments() { - return this.enchantments; - } - - public boolean matches(ItemStack stack, ItemEnchantments enchantments) { - for (EnchantmentPredicate enchantmentPredicate : this.enchantments) { - if (!enchantmentPredicate.containedIn(enchantments)) { - return false; - } - } - - return true; - } - - public static ItemEnchantmentsPredicate.Enchantments enchantments(List enchantments) { - return new ItemEnchantmentsPredicate.Enchantments(enchantments); - } - - public static ItemEnchantmentsPredicate.StoredEnchantments storedEnchantments(List enchantments) { - return new ItemEnchantmentsPredicate.StoredEnchantments(enchantments); - } - - public static class Enchantments extends ItemEnchantmentsPredicate { - public static final Codec CODEC = codec(ItemEnchantmentsPredicate.Enchantments::new); - - protected Enchantments(List list) { - super(list); - } - - @Override - public DataComponentType componentType() { - return DataComponents.ENCHANTMENTS; - } - } - - public static class StoredEnchantments extends ItemEnchantmentsPredicate { - public static final Codec CODEC = codec(ItemEnchantmentsPredicate.StoredEnchantments::new); - - protected StoredEnchantments(List list) { - super(list); - } - - @Override - public DataComponentType componentType() { - return DataComponents.STORED_ENCHANTMENTS; - } - } -} diff --git a/net/minecraft/advancements/critereon/ItemFireworkExplosionPredicate.java b/net/minecraft/advancements/critereon/ItemFireworkExplosionPredicate.java deleted file mode 100644 index 5a41c8a4..00000000 --- a/net/minecraft/advancements/critereon/ItemFireworkExplosionPredicate.java +++ /dev/null @@ -1,47 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.Optional; -import java.util.function.Predicate; -import net.minecraft.core.component.DataComponentType; -import net.minecraft.core.component.DataComponents; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.component.FireworkExplosion; -import net.minecraft.world.item.component.FireworkExplosion.Shape; - -public record ItemFireworkExplosionPredicate(ItemFireworkExplosionPredicate.FireworkPredicate predicate) - implements SingleComponentItemPredicate { - public static final Codec CODEC = ItemFireworkExplosionPredicate.FireworkPredicate.CODEC - .xmap(ItemFireworkExplosionPredicate::new, ItemFireworkExplosionPredicate::predicate); - - @Override - public DataComponentType componentType() { - return DataComponents.FIREWORK_EXPLOSION; - } - - public boolean matches(ItemStack itemStack, FireworkExplosion fireworkExplosion) { - return this.predicate.test(fireworkExplosion); - } - - public record FireworkPredicate(Optional shape, Optional twinkle, Optional trail) implements Predicate { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group( - Shape.CODEC.optionalFieldOf("shape").forGetter(ItemFireworkExplosionPredicate.FireworkPredicate::shape), - Codec.BOOL.optionalFieldOf("has_twinkle").forGetter(ItemFireworkExplosionPredicate.FireworkPredicate::twinkle), - Codec.BOOL.optionalFieldOf("has_trail").forGetter(ItemFireworkExplosionPredicate.FireworkPredicate::trail) - ) - .apply(instance, ItemFireworkExplosionPredicate.FireworkPredicate::new) - ); - - public boolean test(FireworkExplosion explosion) { - if (this.shape.isPresent() && this.shape.get() != explosion.shape()) { - return false; - } else { - return this.twinkle.isPresent() && this.twinkle.get() != explosion.hasTwinkle() - ? false - : !this.trail.isPresent() || (Boolean)this.trail.get() == explosion.hasTrail(); - } - } - } -} diff --git a/net/minecraft/advancements/critereon/ItemFireworksPredicate.java b/net/minecraft/advancements/critereon/ItemFireworksPredicate.java deleted file mode 100644 index a3f1a0e1..00000000 --- a/net/minecraft/advancements/critereon/ItemFireworksPredicate.java +++ /dev/null @@ -1,36 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.Optional; -import net.minecraft.advancements.critereon.MinMaxBounds.Ints; -import net.minecraft.core.component.DataComponentType; -import net.minecraft.core.component.DataComponents; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.component.FireworkExplosion; -import net.minecraft.world.item.component.Fireworks; - -public record ItemFireworksPredicate( - Optional> explosions, Ints flightDuration -) implements SingleComponentItemPredicate { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group( - CollectionPredicate.codec(ItemFireworkExplosionPredicate.FireworkPredicate.CODEC) - .optionalFieldOf("explosions") - .forGetter(ItemFireworksPredicate::explosions), - Ints.CODEC.optionalFieldOf("flight_duration", Ints.ANY).forGetter(ItemFireworksPredicate::flightDuration) - ) - .apply(instance, ItemFireworksPredicate::new) - ); - - @Override - public DataComponentType componentType() { - return DataComponents.FIREWORKS; - } - - public boolean matches(ItemStack itemStack, Fireworks fireworks) { - return this.explosions.isPresent() && !((CollectionPredicate)this.explosions.get()).test((Iterable)fireworks.explosions()) - ? false - : this.flightDuration.matches(fireworks.flightDuration()); - } -} diff --git a/net/minecraft/advancements/critereon/ItemPredicate.java b/net/minecraft/advancements/critereon/ItemPredicate.java index ef558c74..3c1648ae 100644 --- a/net/minecraft/advancements/critereon/ItemPredicate.java +++ b/net/minecraft/advancements/critereon/ItemPredicate.java @@ -1,62 +1,41 @@ package net.minecraft.advancements.critereon; -import com.google.common.collect.ImmutableMap; import com.mojang.serialization.Codec; import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.Map; import java.util.Optional; import java.util.function.Predicate; -import net.minecraft.advancements.critereon.ItemSubPredicate.Type; -import net.minecraft.advancements.critereon.MinMaxBounds.Ints; import net.minecraft.core.HolderGetter; import net.minecraft.core.HolderSet; import net.minecraft.core.RegistryCodecs; -import net.minecraft.core.component.DataComponentHolder; -import net.minecraft.core.component.DataComponentPredicate; +import net.minecraft.core.component.DataComponentGetter; import net.minecraft.core.registries.Registries; import net.minecraft.tags.TagKey; import net.minecraft.world.item.Item; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.ItemLike; -public record ItemPredicate(Optional> items, Ints count, DataComponentPredicate components, Map, ItemSubPredicate> subPredicates) - implements Predicate { +public record ItemPredicate(Optional> items, MinMaxBounds.Ints count, DataComponentMatchers components) implements Predicate { public static final Codec CODEC = RecordCodecBuilder.create( instance -> instance.group( RegistryCodecs.homogeneousList(Registries.ITEM).optionalFieldOf("items").forGetter(ItemPredicate::items), - Ints.CODEC.optionalFieldOf("count", Ints.ANY).forGetter(ItemPredicate::count), - DataComponentPredicate.CODEC.optionalFieldOf("components", DataComponentPredicate.EMPTY).forGetter(ItemPredicate::components), - ItemSubPredicate.CODEC.optionalFieldOf("predicates", Map.of()).forGetter(ItemPredicate::subPredicates) + MinMaxBounds.Ints.CODEC.optionalFieldOf("count", MinMaxBounds.Ints.ANY).forGetter(ItemPredicate::count), + DataComponentMatchers.CODEC.forGetter(ItemPredicate::components) ) .apply(instance, ItemPredicate::new) ); - public boolean test(ItemStack stack) { - if (this.items.isPresent() && !stack.is((HolderSet)this.items.get())) { - return false; - } else if (!this.count.matches(stack.getCount())) { - return false; - } else if (!this.components.test((DataComponentHolder)stack)) { + public boolean test(ItemStack itemStack) { + if (this.items.isPresent() && !itemStack.is((HolderSet)this.items.get())) { return false; } else { - for (ItemSubPredicate itemSubPredicate : this.subPredicates.values()) { - if (!itemSubPredicate.matches(stack)) { - return false; - } - } - - return true; + return !this.count.matches(itemStack.getCount()) ? false : this.components.test((DataComponentGetter)itemStack); } } public static class Builder { private Optional> items = Optional.empty(); - private Ints count = Ints.ANY; - private DataComponentPredicate components = DataComponentPredicate.EMPTY; - private final ImmutableMap.Builder, ItemSubPredicate> subPredicates = ImmutableMap.builder(); - - private Builder() { - } + private MinMaxBounds.Ints count = MinMaxBounds.Ints.ANY; + private DataComponentMatchers components = DataComponentMatchers.ANY; public static ItemPredicate.Builder item() { return new ItemPredicate.Builder(); @@ -72,23 +51,18 @@ public record ItemPredicate(Optional> items, Ints count, DataCom return this; } - public ItemPredicate.Builder withCount(Ints count) { + public ItemPredicate.Builder withCount(MinMaxBounds.Ints count) { this.count = count; return this; } - public ItemPredicate.Builder withSubPredicate(Type type, T subPredicate) { - this.subPredicates.put(type, subPredicate); - return this; - } - - public ItemPredicate.Builder hasComponents(DataComponentPredicate components) { + public ItemPredicate.Builder withComponents(DataComponentMatchers components) { this.components = components; return this; } public ItemPredicate build() { - return new ItemPredicate(this.items, this.count, this.components, this.subPredicates.build()); + return new ItemPredicate(this.items, this.count, this.components); } } } diff --git a/net/minecraft/advancements/critereon/ItemSubPredicate.java b/net/minecraft/advancements/critereon/ItemSubPredicate.java deleted file mode 100644 index 04778af1..00000000 --- a/net/minecraft/advancements/critereon/ItemSubPredicate.java +++ /dev/null @@ -1,17 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import java.util.Map; -import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.world.item.ItemStack; - -public interface ItemSubPredicate { - Codec, ItemSubPredicate>> CODEC = Codec.dispatchedMap( - BuiltInRegistries.ITEM_SUB_PREDICATE_TYPE.byNameCodec(), ItemSubPredicate.Type::codec - ); - - boolean matches(ItemStack stack); - - public record Type(Codec codec) { - } -} diff --git a/net/minecraft/advancements/critereon/ItemSubPredicates.java b/net/minecraft/advancements/critereon/ItemSubPredicates.java deleted file mode 100644 index 248eef45..00000000 --- a/net/minecraft/advancements/critereon/ItemSubPredicates.java +++ /dev/null @@ -1,38 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import net.minecraft.core.Registry; -import net.minecraft.core.registries.BuiltInRegistries; - -public class ItemSubPredicates { - public static final ItemSubPredicate.Type DAMAGE = register("damage", ItemDamagePredicate.CODEC); - public static final ItemSubPredicate.Type ENCHANTMENTS = register( - "enchantments", ItemEnchantmentsPredicate.Enchantments.CODEC - ); - public static final ItemSubPredicate.Type STORED_ENCHANTMENTS = register( - "stored_enchantments", ItemEnchantmentsPredicate.StoredEnchantments.CODEC - ); - public static final ItemSubPredicate.Type POTIONS = register("potion_contents", ItemPotionsPredicate.CODEC); - public static final ItemSubPredicate.Type CUSTOM_DATA = register("custom_data", ItemCustomDataPredicate.CODEC); - public static final ItemSubPredicate.Type CONTAINER = register("container", ItemContainerPredicate.CODEC); - public static final ItemSubPredicate.Type BUNDLE_CONTENTS = register("bundle_contents", ItemBundlePredicate.CODEC); - public static final ItemSubPredicate.Type FIREWORK_EXPLOSION = register( - "firework_explosion", ItemFireworkExplosionPredicate.CODEC - ); - public static final ItemSubPredicate.Type FIREWORKS = register("fireworks", ItemFireworksPredicate.CODEC); - public static final ItemSubPredicate.Type WRITABLE_BOOK = register("writable_book_content", ItemWritableBookPredicate.CODEC); - public static final ItemSubPredicate.Type WRITTEN_BOOK = register("written_book_content", ItemWrittenBookPredicate.CODEC); - public static final ItemSubPredicate.Type ATTRIBUTE_MODIFIERS = register( - "attribute_modifiers", ItemAttributeModifiersPredicate.CODEC - ); - public static final ItemSubPredicate.Type ARMOR_TRIM = register("trim", ItemTrimPredicate.CODEC); - public static final ItemSubPredicate.Type JUKEBOX_PLAYABLE = register("jukebox_playable", ItemJukeboxPlayablePredicate.CODEC); - - private static ItemSubPredicate.Type register(String name, Codec codec) { - return Registry.register(BuiltInRegistries.ITEM_SUB_PREDICATE_TYPE, name, new ItemSubPredicate.Type<>(codec)); - } - - public static ItemSubPredicate.Type bootstrap(Registry> registry) { - return DAMAGE; - } -} diff --git a/net/minecraft/advancements/critereon/ItemWritableBookPredicate.java b/net/minecraft/advancements/critereon/ItemWritableBookPredicate.java deleted file mode 100644 index 02334278..00000000 --- a/net/minecraft/advancements/critereon/ItemWritableBookPredicate.java +++ /dev/null @@ -1,39 +0,0 @@ -package net.minecraft.advancements.critereon; - -import com.mojang.serialization.Codec; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.Optional; -import java.util.function.Predicate; -import net.minecraft.core.component.DataComponentType; -import net.minecraft.core.component.DataComponents; -import net.minecraft.server.network.Filterable; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.component.WritableBookContent; - -public record ItemWritableBookPredicate(Optional, ItemWritableBookPredicate.PagePredicate>> pages) - implements SingleComponentItemPredicate { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group( - CollectionPredicate.codec(ItemWritableBookPredicate.PagePredicate.CODEC).optionalFieldOf("pages").forGetter(ItemWritableBookPredicate::pages) - ) - .apply(instance, ItemWritableBookPredicate::new) - ); - - @Override - public DataComponentType componentType() { - return DataComponents.WRITABLE_BOOK_CONTENT; - } - - public boolean matches(ItemStack itemStack, WritableBookContent writableBookContent) { - return !this.pages.isPresent() || ((CollectionPredicate)this.pages.get()).test((Iterable)writableBookContent.pages()); - } - - public record PagePredicate(String contents) implements Predicate> { - public static final Codec CODEC = Codec.STRING - .xmap(ItemWritableBookPredicate.PagePredicate::new, ItemWritableBookPredicate.PagePredicate::contents); - - public boolean test(Filterable contents) { - return contents.raw().equals(this.contents); - } - } -} diff --git a/net/minecraft/advancements/critereon/LootTableTrigger.java b/net/minecraft/advancements/critereon/LootTableTrigger.java index ae1050d0..8cfa0c7b 100644 --- a/net/minecraft/advancements/critereon/LootTableTrigger.java +++ b/net/minecraft/advancements/critereon/LootTableTrigger.java @@ -6,7 +6,6 @@ import java.util.Optional; import net.minecraft.advancements.CriteriaTriggers; import net.minecraft.advancements.Criterion; import net.minecraft.advancements.critereon.SimpleCriterionTrigger.SimpleInstance; -import net.minecraft.core.registries.Registries; import net.minecraft.resources.ResourceKey; import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.level.storage.loot.LootTable; @@ -25,7 +24,7 @@ public class LootTableTrigger extends SimpleCriterionTrigger CODEC = RecordCodecBuilder.create( instance -> instance.group( EntityPredicate.ADVANCEMENT_CODEC.optionalFieldOf("player").forGetter(LootTableTrigger.TriggerInstance::player), - ResourceKey.codec(Registries.LOOT_TABLE).fieldOf("loot_table").forGetter(LootTableTrigger.TriggerInstance::lootTable) + LootTable.KEY_CODEC.fieldOf("loot_table").forGetter(LootTableTrigger.TriggerInstance::lootTable) ) .apply(instance, LootTableTrigger.TriggerInstance::new) ); diff --git a/net/minecraft/advancements/critereon/MinMaxBounds.java b/net/minecraft/advancements/critereon/MinMaxBounds.java index eacd7248..fe975e5d 100644 --- a/net/minecraft/advancements/critereon/MinMaxBounds.java +++ b/net/minecraft/advancements/critereon/MinMaxBounds.java @@ -7,10 +7,13 @@ import com.mojang.brigadier.exceptions.SimpleCommandExceptionType; import com.mojang.datafixers.util.Either; import com.mojang.serialization.Codec; import com.mojang.serialization.codecs.RecordCodecBuilder; +import io.netty.buffer.ByteBuf; import java.util.Optional; import java.util.function.Function; import java.util.function.Supplier; import net.minecraft.network.chat.Component; +import net.minecraft.network.codec.ByteBufCodecs; +import net.minecraft.network.codec.StreamCodec; public interface MinMaxBounds { SimpleCommandExceptionType ERROR_EMPTY = new SimpleCommandExceptionType(Component.translatable("argument.range.empty")); @@ -42,6 +45,30 @@ public interface MinMaxBounds { }); } + static > StreamCodec createStreamCodec( + StreamCodec streamCodec, MinMaxBounds.BoundsFactory boundsFactory + ) { + return new StreamCodec() { + private static final int MIN_FLAG = 1; + public static final int MAX_FLAG = 2; + + public R decode(B byteBuf) { + byte b = byteBuf.readByte(); + Optional optional = (b & 1) != 0 ? Optional.of(streamCodec.decode(byteBuf)) : Optional.empty(); + Optional optional2 = (b & 2) != 0 ? Optional.of(streamCodec.decode(byteBuf)) : Optional.empty(); + return boundsFactory.create(optional, optional2); + } + + public void encode(B byteBuf, R minMaxBounds) { + Optional optional = minMaxBounds.min(); + Optional optional2 = minMaxBounds.max(); + byteBuf.writeByte((optional.isPresent() ? 1 : 0) | (optional2.isPresent() ? 2 : 0)); + optional.ifPresent(number -> streamCodec.encode(byteBuf, (T)number)); + optional2.ifPresent(number -> streamCodec.encode(byteBuf, (T)number)); + } + }; + } + static > R fromReader( StringReader reader, MinMaxBounds.BoundsFromReaderFactory boundedFactory, @@ -123,6 +150,9 @@ public interface MinMaxBounds { public record Doubles(Optional min, Optional max, Optional minSq, Optional maxSq) implements MinMaxBounds { public static final MinMaxBounds.Doubles ANY = new MinMaxBounds.Doubles(Optional.empty(), Optional.empty()); public static final Codec CODEC = MinMaxBounds.createCodec((Codec)Codec.DOUBLE, MinMaxBounds.Doubles::new); + public static final StreamCodec STREAM_CODEC = MinMaxBounds.createStreamCodec( + (StreamCodec)ByteBufCodecs.DOUBLE, MinMaxBounds.Doubles::new + ); private Doubles(Optional min, Optional max) { this(min, max, squareOpt(min), squareOpt(max)); @@ -178,6 +208,9 @@ public interface MinMaxBounds { public record Ints(Optional min, Optional max, Optional minSq, Optional maxSq) implements MinMaxBounds { public static final MinMaxBounds.Ints ANY = new MinMaxBounds.Ints(Optional.empty(), Optional.empty()); public static final Codec CODEC = MinMaxBounds.createCodec((Codec)Codec.INT, MinMaxBounds.Ints::new); + public static final StreamCodec STREAM_CODEC = MinMaxBounds.createStreamCodec( + (StreamCodec)ByteBufCodecs.INT, MinMaxBounds.Ints::new + ); private Ints(Optional min, Optional max) { this(min, max, min.map(integer -> integer.longValue() * integer.longValue()), squareOpt(max)); diff --git a/net/minecraft/advancements/critereon/NbtPredicate.java b/net/minecraft/advancements/critereon/NbtPredicate.java index 1b9c06dc..3b202cc5 100644 --- a/net/minecraft/advancements/critereon/NbtPredicate.java +++ b/net/minecraft/advancements/critereon/NbtPredicate.java @@ -2,6 +2,7 @@ package net.minecraft.advancements.critereon; import com.mojang.serialization.Codec; import io.netty.buffer.ByteBuf; +import net.minecraft.core.component.DataComponentGetter; import net.minecraft.core.component.DataComponents; import net.minecraft.nbt.CompoundTag; import net.minecraft.nbt.NbtUtils; @@ -19,8 +20,8 @@ public record NbtPredicate(CompoundTag tag) { public static final Codec CODEC = TagParser.LENIENT_CODEC.xmap(NbtPredicate::new, NbtPredicate::tag); public static final StreamCodec STREAM_CODEC = ByteBufCodecs.COMPOUND_TAG.map(NbtPredicate::new, NbtPredicate::tag); - public boolean matches(ItemStack stack) { - CustomData customData = stack.getOrDefault(DataComponents.CUSTOM_DATA, CustomData.EMPTY); + public boolean matches(DataComponentGetter componentGetter) { + CustomData customData = componentGetter.getOrDefault(DataComponents.CUSTOM_DATA, CustomData.EMPTY); return customData.matchedBy(this.tag); } @@ -34,8 +35,8 @@ public record NbtPredicate(CompoundTag tag) { public static CompoundTag getEntityTagToCompare(Entity entity) { CompoundTag compoundTag = entity.saveWithoutId(new CompoundTag()); - if (entity instanceof Player) { - ItemStack itemStack = ((Player)entity).getInventory().getSelected(); + if (entity instanceof Player player) { + ItemStack itemStack = player.getInventory().getSelectedItem(); if (!itemStack.isEmpty()) { compoundTag.put("SelectedItem", itemStack.save(entity.registryAccess())); } diff --git a/net/minecraft/advancements/critereon/PlayerPredicate.java b/net/minecraft/advancements/critereon/PlayerPredicate.java index f328c4df..52d80085 100644 --- a/net/minecraft/advancements/critereon/PlayerPredicate.java +++ b/net/minecraft/advancements/critereon/PlayerPredicate.java @@ -19,11 +19,9 @@ import java.util.function.Supplier; import net.minecraft.advancements.AdvancementHolder; import net.minecraft.advancements.AdvancementProgress; import net.minecraft.advancements.CriterionProgress; -import net.minecraft.advancements.critereon.MinMaxBounds.Ints; import net.minecraft.core.Holder; import net.minecraft.core.Holder.Reference; import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.core.registries.Registries; import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.PlayerAdvancements; @@ -45,7 +43,7 @@ import net.minecraft.world.phys.HitResult.Type; import org.jetbrains.annotations.Nullable; public record PlayerPredicate( - Ints level, + MinMaxBounds.Ints level, GameTypePredicate gameType, List> stats, Object2BooleanMap>> recipes, @@ -56,12 +54,10 @@ public record PlayerPredicate( public static final int LOOKING_AT_RANGE = 100; public static final MapCodec CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( - Ints.CODEC.optionalFieldOf("level", Ints.ANY).forGetter(PlayerPredicate::level), + MinMaxBounds.Ints.CODEC.optionalFieldOf("level", MinMaxBounds.Ints.ANY).forGetter(PlayerPredicate::level), GameTypePredicate.CODEC.optionalFieldOf("gamemode", GameTypePredicate.ANY).forGetter(PlayerPredicate::gameType), PlayerPredicate.StatMatcher.CODEC.listOf().optionalFieldOf("stats", List.of()).forGetter(PlayerPredicate::stats), - ExtraCodecs.object2BooleanMap(ResourceKey.codec(Registries.RECIPE)) - .optionalFieldOf("recipes", Object2BooleanMaps.emptyMap()) - .forGetter(PlayerPredicate::recipes), + ExtraCodecs.object2BooleanMap(Recipe.KEY_CODEC).optionalFieldOf("recipes", Object2BooleanMaps.emptyMap()).forGetter(PlayerPredicate::recipes), Codec.unboundedMap(ResourceLocation.CODEC, PlayerPredicate.AdvancementPredicate.CODEC) .optionalFieldOf("advancements", Map.of()) .forGetter(PlayerPredicate::advancements), @@ -77,7 +73,7 @@ public record PlayerPredicate( return false; } else if (!this.level.matches(serverPlayer.experienceLevel)) { return false; - } else if (!this.gameType.matches(serverPlayer.gameMode.getGameModeForPlayer())) { + } else if (!this.gameType.matches(serverPlayer.gameMode())) { return false; } else { StatsCounter statsCounter = serverPlayer.getStats(); @@ -177,7 +173,7 @@ public record PlayerPredicate( } public static class Builder { - private Ints level = Ints.ANY; + private MinMaxBounds.Ints level = MinMaxBounds.Ints.ANY; private GameTypePredicate gameType = GameTypePredicate.ANY; private final ImmutableList.Builder> stats = ImmutableList.builder(); private final Object2BooleanMap>> recipes = new Object2BooleanOpenHashMap<>(); @@ -189,12 +185,12 @@ public record PlayerPredicate( return new PlayerPredicate.Builder(); } - public PlayerPredicate.Builder setLevel(Ints level) { + public PlayerPredicate.Builder setLevel(MinMaxBounds.Ints level) { this.level = level; return this; } - public PlayerPredicate.Builder addStat(StatType type, Reference value, Ints range) { + public PlayerPredicate.Builder addStat(StatType type, Reference value, MinMaxBounds.Ints range) { this.stats.add(new PlayerPredicate.StatMatcher<>(type, value, range)); return this; } @@ -234,12 +230,12 @@ public record PlayerPredicate( } } - record StatMatcher(StatType type, Holder value, Ints range, Supplier> stat) { + record StatMatcher(StatType type, Holder value, MinMaxBounds.Ints range, Supplier> stat) { public static final Codec> CODEC = BuiltInRegistries.STAT_TYPE .byNameCodec() .dispatch(PlayerPredicate.StatMatcher::type, PlayerPredicate.StatMatcher::createTypedCodec); - public StatMatcher(StatType type, Holder value, Ints range) { + public StatMatcher(StatType type, Holder value, MinMaxBounds.Ints range) { this(type, value, range, Suppliers.memoize(() -> type.get(value.value()))); } @@ -247,7 +243,7 @@ public record PlayerPredicate( return RecordCodecBuilder.mapCodec( instance -> instance.group( statType.getRegistry().holderByNameCodec().fieldOf("stat").forGetter(PlayerPredicate.StatMatcher::value), - Ints.CODEC.optionalFieldOf("value", Ints.ANY).forGetter(PlayerPredicate.StatMatcher::range) + MinMaxBounds.Ints.CODEC.optionalFieldOf("value", MinMaxBounds.Ints.ANY).forGetter(PlayerPredicate.StatMatcher::range) ) .apply(instance, (holder, ints) -> new PlayerPredicate.StatMatcher<>(statType, holder, ints)) ); diff --git a/net/minecraft/advancements/critereon/RecipeCraftedTrigger.java b/net/minecraft/advancements/critereon/RecipeCraftedTrigger.java index 6f3a0705..b3907217 100644 --- a/net/minecraft/advancements/critereon/RecipeCraftedTrigger.java +++ b/net/minecraft/advancements/critereon/RecipeCraftedTrigger.java @@ -9,7 +9,6 @@ import java.util.Optional; import net.minecraft.advancements.CriteriaTriggers; import net.minecraft.advancements.Criterion; import net.minecraft.advancements.critereon.SimpleCriterionTrigger.SimpleInstance; -import net.minecraft.core.registries.Registries; import net.minecraft.resources.ResourceKey; import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.item.ItemStack; @@ -30,7 +29,7 @@ public class RecipeCraftedTrigger extends SimpleCriterionTrigger CODEC = RecordCodecBuilder.create( instance -> instance.group( EntityPredicate.ADVANCEMENT_CODEC.optionalFieldOf("player").forGetter(RecipeCraftedTrigger.TriggerInstance::player), - ResourceKey.codec(Registries.RECIPE).fieldOf("recipe_id").forGetter(RecipeCraftedTrigger.TriggerInstance::recipeId), + Recipe.KEY_CODEC.fieldOf("recipe_id").forGetter(RecipeCraftedTrigger.TriggerInstance::recipeId), ItemPredicate.CODEC.listOf().optionalFieldOf("ingredients", List.of()).forGetter(RecipeCraftedTrigger.TriggerInstance::ingredients) ) .apply(instance, RecipeCraftedTrigger.TriggerInstance::new) diff --git a/net/minecraft/advancements/critereon/RecipeUnlockedTrigger.java b/net/minecraft/advancements/critereon/RecipeUnlockedTrigger.java index 95909b8d..9ca45eb6 100644 --- a/net/minecraft/advancements/critereon/RecipeUnlockedTrigger.java +++ b/net/minecraft/advancements/critereon/RecipeUnlockedTrigger.java @@ -6,7 +6,6 @@ import java.util.Optional; import net.minecraft.advancements.CriteriaTriggers; import net.minecraft.advancements.Criterion; import net.minecraft.advancements.critereon.SimpleCriterionTrigger.SimpleInstance; -import net.minecraft.core.registries.Registries; import net.minecraft.resources.ResourceKey; import net.minecraft.server.level.ServerPlayer; import net.minecraft.world.item.crafting.Recipe; @@ -30,7 +29,7 @@ public class RecipeUnlockedTrigger extends SimpleCriterionTrigger CODEC = RecordCodecBuilder.create( instance -> instance.group( EntityPredicate.ADVANCEMENT_CODEC.optionalFieldOf("player").forGetter(RecipeUnlockedTrigger.TriggerInstance::player), - ResourceKey.codec(Registries.RECIPE).fieldOf("recipe").forGetter(RecipeUnlockedTrigger.TriggerInstance::recipe) + Recipe.KEY_CODEC.fieldOf("recipe").forGetter(RecipeUnlockedTrigger.TriggerInstance::recipe) ) .apply(instance, RecipeUnlockedTrigger.TriggerInstance::new) ); diff --git a/net/minecraft/advancements/critereon/SheepPredicate.java b/net/minecraft/advancements/critereon/SheepPredicate.java index 492ce723..0504ac59 100644 --- a/net/minecraft/advancements/critereon/SheepPredicate.java +++ b/net/minecraft/advancements/critereon/SheepPredicate.java @@ -6,17 +6,13 @@ import com.mojang.serialization.codecs.RecordCodecBuilder; import java.util.Optional; import net.minecraft.server.level.ServerLevel; import net.minecraft.world.entity.Entity; -import net.minecraft.world.entity.animal.Sheep; -import net.minecraft.world.item.DyeColor; +import net.minecraft.world.entity.animal.sheep.Sheep; import net.minecraft.world.phys.Vec3; import org.jetbrains.annotations.Nullable; -public record SheepPredicate(Optional sheared, Optional color) implements EntitySubPredicate { +public record SheepPredicate(Optional sheared) implements EntitySubPredicate { public static final MapCodec CODEC = RecordCodecBuilder.mapCodec( - instance -> instance.group( - Codec.BOOL.optionalFieldOf("sheared").forGetter(SheepPredicate::sheared), DyeColor.CODEC.optionalFieldOf("color").forGetter(SheepPredicate::color) - ) - .apply(instance, SheepPredicate::new) + instance -> instance.group(Codec.BOOL.optionalFieldOf("sheared").forGetter(SheepPredicate::sheared)).apply(instance, SheepPredicate::new) ); @Override @@ -26,14 +22,10 @@ public record SheepPredicate(Optional sheared, Optional color @Override public boolean matches(Entity entity, ServerLevel level, @Nullable Vec3 position) { - if (entity instanceof Sheep sheep) { - return this.sheared.isPresent() && sheep.isSheared() != this.sheared.get() ? false : !this.color.isPresent() || sheep.getColor() == this.color.get(); - } else { - return false; - } + return entity instanceof Sheep sheep ? !this.sheared.isPresent() || sheep.isSheared() == (Boolean)this.sheared.get() : false; } - public static SheepPredicate hasWool(DyeColor color) { - return new SheepPredicate(Optional.of(false), Optional.of(color)); + public static SheepPredicate hasWool() { + return new SheepPredicate(Optional.of(false)); } } diff --git a/net/minecraft/advancements/critereon/SingleComponentItemPredicate.java b/net/minecraft/advancements/critereon/SingleComponentItemPredicate.java index e4009c57..3554b778 100644 --- a/net/minecraft/advancements/critereon/SingleComponentItemPredicate.java +++ b/net/minecraft/advancements/critereon/SingleComponentItemPredicate.java @@ -1,16 +1,17 @@ package net.minecraft.advancements.critereon; +import net.minecraft.core.component.DataComponentGetter; import net.minecraft.core.component.DataComponentType; -import net.minecraft.world.item.ItemStack; +import net.minecraft.core.component.predicates.DataComponentPredicate; -public interface SingleComponentItemPredicate extends ItemSubPredicate { +public interface SingleComponentItemPredicate extends DataComponentPredicate { @Override - default boolean matches(ItemStack stack) { - T object = stack.get(this.componentType()); - return object != null && this.matches(stack, object); + default boolean matches(DataComponentGetter componentGetter) { + T object = componentGetter.get(this.componentType()); + return object != null && this.matches(object); } DataComponentType componentType(); - boolean matches(ItemStack stack, T value); + boolean matches(T value); } diff --git a/net/minecraft/client/ClientBootstrap.java b/net/minecraft/client/ClientBootstrap.java index 4c286719..34af8b87 100644 --- a/net/minecraft/client/ClientBootstrap.java +++ b/net/minecraft/client/ClientBootstrap.java @@ -8,6 +8,7 @@ import net.minecraft.client.renderer.item.properties.conditional.ConditionalItem import net.minecraft.client.renderer.item.properties.numeric.RangeSelectItemModelProperties; import net.minecraft.client.renderer.item.properties.select.SelectItemModelProperties; import net.minecraft.client.renderer.special.SpecialModelRenderers; +import net.minecraft.client.renderer.texture.atlas.SpriteSources; @Environment(EnvType.CLIENT) public class ClientBootstrap { @@ -22,6 +23,7 @@ public class ClientBootstrap { SelectItemModelProperties.bootstrap(); ConditionalItemModelProperties.bootstrap(); RangeSelectItemModelProperties.bootstrap(); + SpriteSources.bootstrap(); } } } diff --git a/net/minecraft/client/GameNarrator.java b/net/minecraft/client/GameNarrator.java index 483b2c29..92f35ebb 100644 --- a/net/minecraft/client/GameNarrator.java +++ b/net/minecraft/client/GameNarrator.java @@ -10,6 +10,7 @@ import net.minecraft.client.gui.components.toasts.ToastManager; import net.minecraft.client.main.SilentInitException; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; +import net.minecraft.sounds.SoundSource; import org.lwjgl.util.tinyfd.TinyFileDialogs; import org.slf4j.Logger; @@ -28,7 +29,7 @@ public class GameNarrator { if (this.getStatus().shouldNarrateChat()) { String string = message.getString(); this.logNarratedMessage(string); - this.narrator.say(string, false); + this.narrateMessage(string, false); } } @@ -36,7 +37,7 @@ public class GameNarrator { String string = message.getString(); if (this.getStatus().shouldNarrateSystem() && !string.isEmpty()) { this.logNarratedMessage(string); - this.narrator.say(string, false); + this.narrateMessage(string, false); } } @@ -49,11 +50,16 @@ public class GameNarrator { this.logNarratedMessage(message); if (this.narrator.active()) { this.narrator.clear(); - this.narrator.say(message, true); + this.narrateMessage(message, true); } } } + private void narrateMessage(String message, boolean interrupt) { + this.narrator + .say(message, interrupt, this.minecraft.options.getSoundSourceVolume(SoundSource.VOICE) * this.minecraft.options.getSoundSourceVolume(SoundSource.MASTER)); + } + private NarratorStatus getStatus() { return this.minecraft.options.narrator().get(); } @@ -66,7 +72,7 @@ public class GameNarrator { public void updateNarratorStatus(NarratorStatus status) { this.clear(); - this.narrator.say(Component.translatable("options.narrator").append(" : ").append(status.getName()).getString(), true); + this.narrateMessage(Component.translatable("options.narrator").append(" : ").append(status.getName()).getString(), true); ToastManager toastManager = Minecraft.getInstance().getToastManager(); if (this.narrator.active()) { if (status == NarratorStatus.OFF) { diff --git a/net/minecraft/client/KeyboardHandler.java b/net/minecraft/client/KeyboardHandler.java index b90a48b1..af958aa9 100644 --- a/net/minecraft/client/KeyboardHandler.java +++ b/net/minecraft/client/KeyboardHandler.java @@ -21,6 +21,7 @@ import net.minecraft.client.gui.components.EditBox; import net.minecraft.client.gui.screens.PauseScreen; import net.minecraft.client.gui.screens.Screen; import net.minecraft.client.gui.screens.debug.GameModeSwitcherScreen; +import net.minecraft.client.gui.screens.options.VideoSettingsScreen; import net.minecraft.client.gui.screens.options.controls.KeyBindsScreen; import net.minecraft.client.multiplayer.ClientPacketListener; import net.minecraft.client.player.LocalPlayer; @@ -256,7 +257,7 @@ public class KeyboardHandler { this.minecraft.getTextureManager().dumpAllSheets(path2); Component component = Component.literal(path.relativize(path2).toString()) .withStyle(ChatFormatting.UNDERLINE) - .withStyle(style -> style.withClickEvent(new ClickEvent(ClickEvent.Action.OPEN_FILE, path2.toFile().toString()))); + .withStyle(style -> style.withClickEvent(new ClickEvent.OpenFile(path2))); this.debugFeedbackTranslated("debug.dump_dynamic_textures", component); return true; case 84: @@ -385,7 +386,13 @@ public class KeyboardHandler { if (action == 1 && (!(this.minecraft.screen instanceof KeyBindsScreen) || ((KeyBindsScreen)screen).lastKeySelection <= Util.getMillis() - 20L)) { if (this.minecraft.options.keyFullscreen.matches(key, scanCode)) { this.minecraft.getWindow().toggleFullScreen(); - this.minecraft.options.fullscreen().set(this.minecraft.getWindow().isFullscreen()); + boolean bl2 = this.minecraft.getWindow().isFullscreen(); + this.minecraft.options.fullscreen().set(bl2); + this.minecraft.options.save(); + if (this.minecraft.screen instanceof VideoSettingsScreen videoSettingsScreen) { + videoSettingsScreen.updateFullscreenButton(bl2); + } + return; } @@ -414,7 +421,7 @@ public class KeyboardHandler { } } - LocalPlayer var16 = this.minecraft.player; + LocalPlayer var17 = this.minecraft.player; } } diff --git a/net/minecraft/client/Minecraft.java b/net/minecraft/client/Minecraft.java index ee82c80f..3252e654 100644 --- a/net/minecraft/client/Minecraft.java +++ b/net/minecraft/client/Minecraft.java @@ -20,15 +20,14 @@ import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.platform.ClientShutdownWatchdog; import com.mojang.blaze3d.platform.DisplayData; import com.mojang.blaze3d.platform.FramerateLimitTracker; -import com.mojang.blaze3d.platform.GlDebug; -import com.mojang.blaze3d.platform.GlUtil; +import com.mojang.blaze3d.platform.GLX; import com.mojang.blaze3d.platform.IconSet; import com.mojang.blaze3d.platform.Window; import com.mojang.blaze3d.platform.WindowEventHandler; +import com.mojang.blaze3d.systems.GpuDevice; import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.blaze3d.systems.TimerQuery; import com.mojang.blaze3d.systems.TimerQuery.FrameProfile; -import com.mojang.blaze3d.vertex.BufferUploader; import com.mojang.blaze3d.vertex.Tesselator; import com.mojang.datafixers.DataFixer; import com.mojang.jtracy.DiscontinuousFrame; @@ -42,7 +41,6 @@ import java.io.UncheckedIOException; import java.lang.management.ManagementFactory; import java.net.Proxy; import java.net.SocketAddress; -import java.nio.ByteBuffer; import java.nio.file.Path; import java.nio.file.Paths; import java.time.Duration; @@ -113,7 +111,6 @@ import net.minecraft.client.gui.screens.social.SocialInteractionsScreen; import net.minecraft.client.gui.screens.worldselection.WorldOpenFlows; import net.minecraft.client.main.GameConfig; import net.minecraft.client.main.SilentInitException; -import net.minecraft.client.main.GameConfig.QuickPlayData; import net.minecraft.client.model.geom.EntityModelSet; import net.minecraft.client.multiplayer.ClientHandshakePacketListenerImpl; import net.minecraft.client.multiplayer.ClientLevel; @@ -139,16 +136,17 @@ import net.minecraft.client.renderer.ShaderManager; import net.minecraft.client.renderer.VirtualScreen; import net.minecraft.client.renderer.block.BlockModelShaper; import net.minecraft.client.renderer.block.BlockRenderDispatcher; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.client.renderer.blockentity.BlockEntityRenderDispatcher; import net.minecraft.client.renderer.debug.DebugRenderer; import net.minecraft.client.renderer.entity.EntityRenderDispatcher; import net.minecraft.client.renderer.entity.EntityRenderers; import net.minecraft.client.renderer.entity.ItemRenderer; import net.minecraft.client.renderer.item.ItemModelResolver; -import net.minecraft.client.renderer.texture.TextureAtlas; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.renderer.texture.TextureManager; import net.minecraft.client.resources.ClientPackSource; +import net.minecraft.client.resources.DryFoliageColorReloadListener; import net.minecraft.client.resources.FoliageColorReloadListener; import net.minecraft.client.resources.GrassColorReloadListener; import net.minecraft.client.resources.MapDecorationTextureManager; @@ -159,7 +157,6 @@ import net.minecraft.client.resources.SkinManager; import net.minecraft.client.resources.SplashManager; import net.minecraft.client.resources.language.I18n; import net.minecraft.client.resources.language.LanguageManager; -import net.minecraft.client.resources.model.BakedModel; import net.minecraft.client.resources.model.EquipmentAssetManager; import net.minecraft.client.resources.model.ModelManager; import net.minecraft.client.resources.server.DownloadedPackSource; @@ -180,10 +177,10 @@ import net.minecraft.network.chat.ClickEvent; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.MutableComponent; -import net.minecraft.network.chat.ClickEvent.Action; import net.minecraft.network.chat.contents.KeybindResolver; import net.minecraft.network.protocol.game.ServerboundClientTickEndPacket; import net.minecraft.network.protocol.game.ServerboundPlayerActionPacket; +import net.minecraft.network.protocol.game.ServerboundPlayerActionPacket.Action; import net.minecraft.network.protocol.login.ServerboundHelloPacket; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.Bootstrap; @@ -227,7 +224,7 @@ import net.minecraft.util.profiling.metrics.profiling.ActiveMetricsRecorder; import net.minecraft.util.profiling.metrics.profiling.InactiveMetricsRecorder; import net.minecraft.util.profiling.metrics.profiling.MetricsRecorder; import net.minecraft.util.profiling.metrics.storage.MetricsPersister; -import net.minecraft.util.random.SimpleWeightedRandomList; +import net.minecraft.util.random.WeightedList; import net.minecraft.util.thread.ReentrantBlockableEventLoop; import net.minecraft.world.InteractionHand; import net.minecraft.world.InteractionResult; @@ -247,7 +244,6 @@ import net.minecraft.world.level.block.RenderShape; import net.minecraft.world.level.block.entity.SkullBlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.storage.LevelStorageSource; -import net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess; import net.minecraft.world.level.validation.DirectoryValidator; import net.minecraft.world.phys.BlockHitResult; import net.minecraft.world.phys.EntityHitResult; @@ -395,7 +391,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements @Nullable private TutorialToast socialInteractionsToast; private int fpsPieRenderTicks; - private final ContinuousProfiler fpsPieProfiler = new ContinuousProfiler(Util.timeSource, () -> this.fpsPieRenderTicks); + private final ContinuousProfiler fpsPieProfiler; private MetricsRecorder metricsRecorder = InactiveMetricsRecorder.INSTANCE; private final ResourceLoadStateTracker reloadStateTracker = new ResourceLoadStateTracker(); private long savedCpuDuration; @@ -454,22 +450,23 @@ public class Minecraft extends ReentrantBlockableEventLoop implements this.toastManager = new ToastManager(this); this.gameThread = Thread.currentThread(); this.options = new Options(this, this.gameDirectory); + boolean bl = this.options.startedCleanly; + this.options.startedCleanly = false; + this.options.save(); RenderSystem.setShaderGlintAlpha(this.options.glintStrength().get()); this.running = true; this.tutorial = new Tutorial(this, this.options); this.hotbarManager = new HotbarManager(path, this.fixerUpper); LOGGER.info("Backend library: {}", RenderSystem.getBackendDescription()); - DisplayData displayData; + DisplayData displayData = gameConfig.display; if (this.options.overrideHeight > 0 && this.options.overrideWidth > 0) { - displayData = new DisplayData( - this.options.overrideWidth, - this.options.overrideHeight, - gameConfig.display.fullscreenWidth, - gameConfig.display.fullscreenHeight, - gameConfig.display.isFullscreen - ); - } else { - displayData = gameConfig.display; + displayData = gameConfig.display.withSize(this.options.overrideWidth, this.options.overrideHeight); + } + + if (!bl) { + displayData = displayData.withFullscreen(false); + this.options.fullscreenVideoModeString = null; + LOGGER.warn("Detected unexpected shutdown during last game startup: resetting fullscreen mode"); } Util.timeSource = RenderSystem.initBackendSystem(); @@ -490,18 +487,23 @@ public class Minecraft extends ReentrantBlockableEventLoop implements try { this.window.setIcon(this.vanillaPackResources, SharedConstants.getCurrentVersion().isStable() ? IconSet.RELEASE : IconSet.SNAPSHOT); - } catch (IOException var13) { - LOGGER.error("Couldn't set icon", (Throwable)var13); + } catch (IOException var15) { + LOGGER.error("Couldn't set icon", (Throwable)var15); } this.mouseHandler = new MouseHandler(this); this.mouseHandler.setup(this.window.getWindow()); this.keyboardHandler = new KeyboardHandler(this); this.keyboardHandler.setup(this.window.getWindow()); - RenderSystem.initRenderer(this.options.glDebugVerbosity, false); + RenderSystem.initRenderer( + this.window.getWindow(), + this.options.glDebugVerbosity, + false, + (resourceLocation, shaderType) -> this.getShaderManager().getShader(resourceLocation, shaderType), + gameConfig.game.renderDebugLabels + ); + LOGGER.info("Using optional rendering extensions: {}", String.join(", ", RenderSystem.getDevice().getEnabledExtensions())); this.mainRenderTarget = new MainTarget(this.window.getWidth(), this.window.getHeight()); - this.mainRenderTarget.setClearColor(0.0F, 0.0F, 0.0F, 0.0F); - this.mainRenderTarget.clear(); this.resourceManager = new ReloadableResourceManager(PackType.CLIENT_RESOURCES); this.resourcePackRepository.reload(); this.options.loadSelectedResourcePacks(this.resourcePackRepository); @@ -530,8 +532,9 @@ public class Minecraft extends ReentrantBlockableEventLoop implements this.updateFontOptions(); this.resourceManager.registerReloadListener(new GrassColorReloadListener()); this.resourceManager.registerReloadListener(new FoliageColorReloadListener()); + this.resourceManager.registerReloadListener(new DryFoliageColorReloadListener()); this.window.setErrorSection("Startup"); - RenderSystem.setupDefaultState(0, 0, this.window.getWidth(), this.window.getHeight()); + RenderSystem.setupDefaultState(); this.window.setErrorSection("Post startup"); this.blockColors = BlockColors.createDefault(); this.modelManager = new ModelManager(this.textureManager, this.blockColors, this.options.mipmapLevels().get()); @@ -549,7 +552,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements int i = Runtime.getRuntime().availableProcessors(); Tesselator.init(); this.renderBuffers = new RenderBuffers(i); - } catch (OutOfMemoryError var12) { + } catch (OutOfMemoryError var14) { TinyFileDialogs.tinyfd_messageBox( "Minecraft", "Oh no! The game was unable to allocate memory off-heap while trying to start. You may try to free some memory by closing other applications on your computer, check that your system meets the minimum requirements, and try again. If the problem persists, please visit: " @@ -558,7 +561,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements "error", true ); - throw new SilentInitException("Unable to allocate render buffers", var12); + throw new SilentInitException("Unable to allocate render buffers", var14); } this.playerSocialManager = new PlayerSocialManager(this, this.userApiService); @@ -598,7 +601,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements this.resourceManager.registerReloadListener(this.regionalCompliancies); this.gui = new Gui(this); this.debugRenderer = new DebugRenderer(this); - RealmsClient realmsClient = RealmsClient.create(this); + RealmsClient realmsClient = RealmsClient.getOrCreate(this); this.realmsDataFetcher = new RealmsDataFetcher(realmsClient); RenderSystem.setErrorCallback(this::onFullscreenError); if (this.mainRenderTarget.width != this.window.getWidth() || this.mainRenderTarget.height != this.window.getHeight()) { @@ -609,15 +612,25 @@ public class Minecraft extends ReentrantBlockableEventLoop implements + this.window.getHeight() + ").\nPlease make sure you have up-to-date drivers (see aka.ms/mcdriver for instructions)." ); - if (GlDebug.isDebugEnabled()) { - stringBuilder.append("\n\nReported GL debug messages:\n").append(String.join("\n", GlDebug.getLastOpenGlDebugMessages())); + + try { + GpuDevice gpuDevice = RenderSystem.getDevice(); + List list = gpuDevice.getLastDebugMessages(); + if (!list.isEmpty()) { + stringBuilder.append("\n\nReported GL debug messages:\n").append(String.join("\n", list)); + } + } catch (Throwable var13) { } this.window.setWindowed(this.mainRenderTarget.width, this.mainRenderTarget.height); TinyFileDialogs.tinyfd_messageBox("Minecraft", stringBuilder.toString(), "ok", "error", false); } else if (this.options.fullscreen().get() && !this.window.isFullscreen()) { - this.window.toggleFullScreen(); - this.options.fullscreen().set(this.window.isFullscreen()); + if (bl) { + this.window.toggleFullScreen(); + this.options.fullscreen().set(this.window.isFullscreen()); + } else { + this.options.fullscreen().set(false); + } } this.window.updateVsync(this.options.enableVsync().get()); @@ -635,10 +648,10 @@ public class Minecraft extends ReentrantBlockableEventLoop implements TitleScreen.registerTextures(this.textureManager); LoadingOverlay.registerTextures(this.textureManager); this.setScreen(new GenericMessageScreen(Component.translatable("gui.loadingMinecraft"))); - List list = this.resourcePackRepository.openAllSelected(); - this.reloadStateTracker.startReload(ReloadReason.INITIAL, list); + List list2 = this.resourcePackRepository.openAllSelected(); + this.reloadStateTracker.startReload(ReloadReason.INITIAL, list2); ReloadInstance reloadInstance = this.resourceManager - .createReload(Util.backgroundExecutor().forName("resourceLoad"), this, RESOURCE_RELOAD_INITIAL_TASK, list); + .createReload(Util.backgroundExecutor().forName("resourceLoad"), this, RESOURCE_RELOAD_INITIAL_TASK, list2); GameLoadTimesEvent.INSTANCE.beginStep(TelemetryProperty.LOAD_TIME_LOADING_OVERLAY_MS); Minecraft.GameLoadCookie gameLoadCookie = new Minecraft.GameLoadCookie(realmsClient, gameConfig.quickPlay); this.setOverlay( @@ -653,6 +666,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements ); this.quickPlayLog = QuickPlayLog.of(gameConfig.quickPlay.path()); this.framerateLimitTracker = new FramerateLimitTracker(this.options, this); + this.fpsPieProfiler = new ContinuousProfiler(Util.timeSource, () -> this.fpsPieRenderTicks, this.framerateLimitTracker::isHeavilyThrottled); if (TracyClient.isAvailable() && gameConfig.game.captureTracyImages) { this.tracyFrameCapture = new TracyFrameCapture(); } else { @@ -673,6 +687,8 @@ public class Minecraft extends ReentrantBlockableEventLoop implements GameLoadTimesEvent.INSTANCE.endStep(TelemetryProperty.LOAD_TIME_TOTAL_TIME_MS); GameLoadTimesEvent.INSTANCE.send(this.telemetryManager.getOutsideSessionSender()); runnable.run(); + this.options.startedCleanly = true; + this.options.save(); } public boolean isGameLoadFinished() { @@ -997,13 +1013,13 @@ public class Minecraft extends ReentrantBlockableEventLoop implements private void selfTest() { boolean bl = false; BlockModelShaper blockModelShaper = this.getBlockRenderer().getBlockModelShaper(); - BakedModel bakedModel = blockModelShaper.getModelManager().getMissingModel(); + BlockStateModel blockStateModel = blockModelShaper.getModelManager().getMissingBlockStateModel(); for (Block block : BuiltInRegistries.BLOCK) { for (BlockState blockState : block.getStateDefinition().getPossibleStates()) { if (blockState.getRenderShape() == RenderShape.MODEL) { - BakedModel bakedModel2 = blockModelShaper.getBlockModel(blockState); - if (bakedModel2 == bakedModel) { + BlockStateModel blockStateModel2 = blockModelShaper.getBlockModel(blockState); + if (blockStateModel2 == blockStateModel) { LOGGER.debug("Missing model for: {}", blockState); bl = true; } @@ -1011,7 +1027,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements } } - TextureAtlasSprite textureAtlasSprite = bakedModel.getParticleIcon(); + TextureAtlasSprite textureAtlasSprite = blockStateModel.particleIcon(); for (Block block2 : BuiltInRegistries.BLOCK) { for (BlockState blockState2 : block2.getStateDefinition().getPossibleStates()) { @@ -1096,7 +1112,6 @@ public class Minecraft extends ReentrantBlockableEventLoop implements this.screen.added(); } - BufferUploader.reset(); if (guiScreen != null) { this.mouseHandler.releaseMouse(); KeyMapping.releaseAll(); @@ -1178,6 +1193,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements FreeTypeUtil.destroy(); Util.shutdownExecutors(); + RenderSystem.getDevice().close(); } catch (Throwable var5) { LOGGER.error("Shutdown failure!", var5); throw var5; @@ -1221,7 +1237,9 @@ public class Minecraft extends ReentrantBlockableEventLoop implements } this.window.setErrorSection("Render"); - profilerFiller.push("sound"); + profilerFiller.push("gpuAsync"); + RenderSystem.executePendingTasks(); + profilerFiller.popPush("sound"); this.soundManager.updateSource(this.gameRenderer.getMainCamera()); profilerFiller.popPush("toasts"); this.toastManager.update(); @@ -1238,12 +1256,10 @@ public class Minecraft extends ReentrantBlockableEventLoop implements } } - RenderSystem.clear(16640); - this.mainRenderTarget.bindWrite(true); + RenderTarget renderTarget = this.getMainRenderTarget(); + RenderSystem.getDevice().createCommandEncoder().clearColorAndDepthTextures(renderTarget.getColorTexture(), 0, renderTarget.getDepthTexture(), 1.0); RenderSystem.setShaderFog(FogParameters.NO_FOG); - profilerFiller.push("display"); - RenderSystem.enableCull(); - profilerFiller.popPush("mouse"); + profilerFiller.push("mouse"); this.mouseHandler.handleAccumulatedMovement(); profilerFiller.pop(); if (!this.noRender) { @@ -1253,9 +1269,8 @@ public class Minecraft extends ReentrantBlockableEventLoop implements } profilerFiller.push("blit"); - this.mainRenderTarget.unbindWrite(); if (!this.window.isMinimized()) { - this.mainRenderTarget.blitToScreen(this.window.getWidth(), this.window.getHeight()); + renderTarget.blitToScreen(); } this.frameTimeNs = Util.getNanos() - l; @@ -1266,7 +1281,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements profilerFiller.popPush("updateDisplay"); if (this.tracyFrameCapture != null) { this.tracyFrameCapture.upload(); - this.tracyFrameCapture.capture(this.mainRenderTarget); + this.tracyFrameCapture.capture(renderTarget); } this.window.updateDisplay(this.tracyFrameCapture); @@ -1428,7 +1443,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements Consumer consumer2 = path -> { Component component = Component.literal(path.toString()) .withStyle(ChatFormatting.UNDERLINE) - .withStyle(style -> style.withClickEvent(new ClickEvent(Action.OPEN_FILE, path.toFile().getParent()))); + .withStyle(style -> style.withClickEvent(new ClickEvent.OpenFile(path.getParent()))); this.execute(() -> logger.accept(Component.translatable("debug.profiling.stop", component))); }; SystemReport systemReport = fillSystemReport(new SystemReport(), this, this.languageManager, this.launchedVersion, this.options); @@ -1662,7 +1677,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements if (interactionResult2 instanceof Success success2) { if (success2.swingSource() == SwingSource.CLIENT) { this.player.swing(interactionHand); - if (!itemStack.isEmpty() && (itemStack.getCount() != i || this.gameMode.hasInfiniteItems())) { + if (!itemStack.isEmpty() && (itemStack.getCount() != i || this.player.hasInfiniteMaterials())) { this.gameRenderer.itemInHandRenderer.itemUsed(interactionHand); } } @@ -1867,8 +1882,8 @@ public class Minecraft extends ReentrantBlockableEventLoop implements if (this.options.keyHotbarSlots[i].consumeClick()) { if (this.player.isSpectator()) { this.gui.getSpectatorGui().onHotbarSelected(i); - } else if (!this.player.isCreative() || this.screen != null || !bl2 && !bl) { - this.player.getInventory().selected = i; + } else if (!this.player.hasInfiniteMaterials() || this.screen != null || !bl2 && !bl) { + this.player.getInventory().setSelectedSlot(i); } else { CreativeModeInventoryScreen.handleHotbarLoadOrSave(this, i, bl2, bl); } @@ -1904,12 +1919,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements while (this.options.keySwapOffhand.consumeClick()) { if (!this.player.isSpectator()) { - this.getConnection() - .send( - new ServerboundPlayerActionPacket( - net.minecraft.network.protocol.game.ServerboundPlayerActionPacket.Action.SWAP_ITEM_WITH_OFFHAND, BlockPos.ZERO, Direction.DOWN - ) - ); + this.getConnection().send(new ServerboundPlayerActionPacket(Action.SWAP_ITEM_WITH_OFFHAND, BlockPos.ZERO, Direction.DOWN)); } } @@ -1978,7 +1988,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements return new WorldOpenFlows(this, this.levelSource); } - public void doWorldLoad(LevelStorageAccess levelStorage, PackRepository packRepository, WorldStem worldStem, boolean newWorld) { + public void doWorldLoad(LevelStorageSource.LevelStorageAccess levelStorage, PackRepository packRepository, WorldStem worldStem, boolean newWorld) { this.disconnect(); this.progressListener.set(null); Instant instant = Instant.now(); @@ -1996,8 +2006,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements })); this.isLocalServer = true; this.updateReportEnvironment(ReportEnvironment.local()); - this.quickPlayLog - .setWorldData(net.minecraft.client.quickplay.QuickPlayLog.Type.SINGLEPLAYER, levelStorage.getLevelId(), worldStem.worldData().getLevelName()); + this.quickPlayLog.setWorldData(QuickPlayLog.Type.SINGLEPLAYER, levelStorage.getLevelId(), worldStem.worldData().getLevelName()); } catch (Throwable var12) { CrashReport crashReport = CrashReport.forThrowable(var12, "Starting integrated server"); CrashReportCategory crashReportCategory = crashReport.addCategory("Starting integrated server"); @@ -2323,10 +2332,15 @@ public class Minecraft extends ReentrantBlockableEventLoop implements "Window size", (Supplier)(() -> minecraft != null ? minecraft.window.getWidth() + "x" + minecraft.window.getHeight() : "") ); report.setDetail("GFLW Platform", Window::getPlatform); - report.setDetail("GL Caps", RenderSystem::getCapsString); - report.setDetail( - "GL debug messages", (Supplier)(() -> GlDebug.isDebugEnabled() ? String.join("\n", GlDebug.getLastOpenGlDebugMessages()) : "") - ); + report.setDetail("Render Extensions", (Supplier)(() -> String.join(", ", RenderSystem.getDevice().getEnabledExtensions()))); + report.setDetail("GL debug messages", (Supplier)(() -> { + GpuDevice gpuDevice = RenderSystem.tryGetDevice(); + if (gpuDevice == null) { + return ""; + } else { + return gpuDevice.isDebuggingEnabled() ? String.join("\n", gpuDevice.getLastDebugMessages()) : ""; + } + })); report.setDetail("Is Modded", (Supplier)(() -> checkModStatus().fullDescription())); report.setDetail("Universe", (Supplier)(() -> minecraft != null ? Long.toHexString(minecraft.canary) : "404")); report.setDetail("Type", "Client (map_client.txt)"); @@ -2353,7 +2367,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements report.setDetail("Locale", String.valueOf(Locale.getDefault())); report.setDetail("System encoding", (Supplier)(() -> System.getProperty("sun.jnu.encoding", ""))); report.setDetail("File encoding", (Supplier)(() -> System.getProperty("file.encoding", ""))); - report.setDetail("CPU", GlUtil::getCpuInfo); + report.setDetail("CPU", GLX::_getCpuInfo); return report; } @@ -2483,9 +2497,9 @@ public class Minecraft extends ReentrantBlockableEventLoop implements if (level.dimension() != Level.NETHER && this.player.getAbilities().instabuild && this.player.getAbilities().mayfly) { return new MusicInfo(Musics.CREATIVE, f); } else { - Optional> optional = holder.value().getBackgroundMusic(); + Optional> optional = holder.value().getBackgroundMusic(); if (optional.isPresent()) { - Optional optional2 = ((SimpleWeightedRandomList)optional.get()).getRandomValue(level.random); + Optional optional2 = ((WeightedList)optional.get()).getRandom(level.random); return new MusicInfo((Music)optional2.orElse(null), f); } else { return new MusicInfo(Musics.GAME, f); @@ -2675,7 +2689,6 @@ public class Minecraft extends ReentrantBlockableEventLoop implements this.player.yRotO = this.player.getYRot(); this.player.xRotO = this.player.getXRot(); - renderTarget.bindWrite(true); this.gameRenderer.renderLevel(DeltaTracker.ONE); try { @@ -2688,7 +2701,7 @@ public class Minecraft extends ReentrantBlockableEventLoop implements Component component = Component.literal(gameDirectory.getName()) .withStyle(ChatFormatting.UNDERLINE) - .withStyle(style -> style.withClickEvent(new ClickEvent(Action.OPEN_FILE, gameDirectory.getAbsolutePath()))); + .withStyle(style -> style.withClickEvent(new ClickEvent.OpenFile(gameDirectory.getAbsoluteFile()))); return Component.translatable("screenshot.success", component); } catch (Exception var18) { LOGGER.error("Couldn't save image", (Throwable)var18); @@ -2703,50 +2716,11 @@ public class Minecraft extends ReentrantBlockableEventLoop implements this.window.setHeight(j); renderTarget.resize(i, j); this.gameRenderer.setPanoramicMode(false); - this.getMainRenderTarget().bindWrite(true); } return var12; } - private Component grabHugeScreenshot(File gameDirectory, int columnWidth, int rowHeight, int width, int height) { - try { - ByteBuffer byteBuffer = GlUtil.allocateMemory(columnWidth * rowHeight * 3); - Screenshot screenshot = new Screenshot(gameDirectory, width, height, rowHeight); - float f = (float)width / columnWidth; - float g = (float)height / rowHeight; - float h = f > g ? f : g; - - for (int i = (height - 1) / rowHeight * rowHeight; i >= 0; i -= rowHeight) { - for (int j = 0; j < width; j += columnWidth) { - RenderSystem.setShaderTexture(0, TextureAtlas.LOCATION_BLOCKS); - float k = (width - columnWidth) / 2.0F * 2.0F - j * 2; - float l = (height - rowHeight) / 2.0F * 2.0F - i * 2; - k /= columnWidth; - l /= rowHeight; - this.gameRenderer.renderZoomed(h, k, l); - byteBuffer.clear(); - RenderSystem.pixelStore(3333, 1); - RenderSystem.pixelStore(3317, 1); - RenderSystem.readPixels(0, 0, columnWidth, rowHeight, 32992, 5121, byteBuffer); - screenshot.addRegion(byteBuffer, j, i, columnWidth, rowHeight); - } - - screenshot.saveRow(); - } - - File file = screenshot.close(); - GlUtil.freeMemory(byteBuffer); - Component component = Component.literal(file.getName()) - .withStyle(ChatFormatting.UNDERLINE) - .withStyle(style -> style.withClickEvent(new ClickEvent(Action.OPEN_FILE, file.getAbsolutePath()))); - return Component.translatable("screenshot.success", component); - } catch (Exception var15) { - LOGGER.warn("Couldn't save screenshot", (Throwable)var15); - return Component.translatable("screenshot.failure", var15.getMessage()); - } - } - @Nullable public StoringChunkProgressListener getProgressListener() { return (StoringChunkProgressListener)this.progressListener.get(); @@ -2889,6 +2863,6 @@ public class Minecraft extends ReentrantBlockableEventLoop implements } @Environment(EnvType.CLIENT) - record GameLoadCookie(RealmsClient realmsClient, QuickPlayData quickPlayData) { + record GameLoadCookie(RealmsClient realmsClient, GameConfig.QuickPlayData quickPlayData) { } } diff --git a/net/minecraft/client/MouseHandler.java b/net/minecraft/client/MouseHandler.java index d88fd7ba..3ec5e081 100644 --- a/net/minecraft/client/MouseHandler.java +++ b/net/minecraft/client/MouseHandler.java @@ -2,6 +2,7 @@ package net.minecraft.client; import com.mojang.blaze3d.Blaze3D; import com.mojang.blaze3d.platform.InputConstants; +import com.mojang.blaze3d.platform.Window; import com.mojang.blaze3d.platform.InputConstants.Type; import com.mojang.logging.LogUtils; import java.nio.file.InvalidPathException; @@ -9,11 +10,15 @@ import java.nio.file.Path; import java.nio.file.Paths; import java.util.ArrayList; import java.util.List; +import java.util.Locale; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.CrashReport; import net.minecraft.CrashReportCategory; +import net.minecraft.CrashReportDetail; import net.minecraft.ReportedException; +import net.minecraft.client.gui.Font; +import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.gui.components.toasts.SystemToast; import net.minecraft.client.gui.screens.Screen; import net.minecraft.util.Mth; @@ -56,7 +61,8 @@ public class MouseHandler { * @see GLFWMouseButtonCallbackI */ private void onPress(long windowPointer, int button, int action, int modifiers) { - if (windowPointer == this.minecraft.getWindow().getWindow()) { + Window window = this.minecraft.getWindow(); + if (windowPointer == window.getWindow()) { this.minecraft.getFramerateLimitTracker().onInputReceived(); if (this.minecraft.screen != null) { this.minecraft.setLastInputType(InputType.MOUSE); @@ -97,8 +103,8 @@ public class MouseHandler { this.grabMouse(); } } else { - double d = this.xpos * this.minecraft.getWindow().getGuiScaledWidth() / this.minecraft.getWindow().getScreenWidth(); - double e = this.ypos * this.minecraft.getWindow().getGuiScaledHeight() / this.minecraft.getWindow().getScreenHeight(); + double d = this.getScaledXPos(window); + double e = this.getScaledYPos(window); Screen screen = this.minecraft.screen; if (bl) { screen.afterMouseAction(); @@ -107,12 +113,11 @@ public class MouseHandler { if (screen.mouseClicked(d, e, i)) { return; } - } catch (Throwable var17) { - CrashReport crashReport = CrashReport.forThrowable(var17, "mouseClicked event handler"); + } catch (Throwable var18) { + CrashReport crashReport = CrashReport.forThrowable(var18, "mouseClicked event handler"); screen.fillCrashDetails(crashReport); CrashReportCategory crashReportCategory = crashReport.addCategory("Mouse"); - crashReportCategory.setDetail("Scaled X", d); - crashReportCategory.setDetail("Scaled Y", e); + this.fillMousePositionDetails(crashReportCategory, window); crashReportCategory.setDetail("Button", button); throw new ReportedException(crashReport); } @@ -121,12 +126,11 @@ public class MouseHandler { if (screen.mouseReleased(d, e, i)) { return; } - } catch (Throwable var16) { - CrashReport crashReport = CrashReport.forThrowable(var16, "mouseReleased event handler"); + } catch (Throwable var17) { + CrashReport crashReport = CrashReport.forThrowable(var17, "mouseReleased event handler"); screen.fillCrashDetails(crashReport); CrashReportCategory crashReportCategory = crashReport.addCategory("Mouse"); - crashReportCategory.setDetail("Scaled X", d); - crashReportCategory.setDetail("Scaled Y", e); + this.fillMousePositionDetails(crashReportCategory, window); crashReportCategory.setDetail("Button", button); throw new ReportedException(crashReport); } @@ -155,6 +159,27 @@ public class MouseHandler { } } + public void fillMousePositionDetails(CrashReportCategory category, Window window) { + category.setDetail( + "Mouse location", + (CrashReportDetail)(() -> String.format( + Locale.ROOT, "Scaled: (%f, %f). Absolute: (%f, %f)", getScaledXPos(window, this.xpos), getScaledYPos(window, this.ypos), this.xpos, this.ypos + )) + ); + category.setDetail( + "Screen size", + (CrashReportDetail)(() -> String.format( + Locale.ROOT, + "Scaled: (%d, %d). Absolute: (%d, %d). Scale factor of %f", + window.getGuiScaledWidth(), + window.getGuiScaledHeight(), + window.getWidth(), + window.getHeight(), + window.getGuiScale() + )) + ); + } + /** * Will be called when a scrolling device is used, such as a mouse wheel or scrolling area of a touchpad. * @@ -169,8 +194,8 @@ public class MouseHandler { double f = (bl ? Math.signum(yOffset) : yOffset) * d; if (this.minecraft.getOverlay() == null) { if (this.minecraft.screen != null) { - double g = this.xpos * this.minecraft.getWindow().getGuiScaledWidth() / this.minecraft.getWindow().getScreenWidth(); - double h = this.ypos * this.minecraft.getWindow().getGuiScaledHeight() / this.minecraft.getWindow().getScreenHeight(); + double g = this.getScaledXPos(this.minecraft.getWindow()); + double h = this.getScaledYPos(this.minecraft.getWindow()); this.minecraft.screen.mouseScrolled(g, h, e, f); this.minecraft.screen.afterMouseAction(); } else if (this.minecraft.player != null) { @@ -189,7 +214,7 @@ public class MouseHandler { } } else { Inventory inventory = this.minecraft.player.getInventory(); - inventory.setSelectedHotbarSlot(ScrollWheelHandler.getNextScrollWheelSelection(i, inventory.selected, Inventory.getSelectionSize())); + inventory.setSelectedSlot(ScrollWheelHandler.getNextScrollWheelSelection(i, inventory.getSelectedSlot(), Inventory.getSelectionSize())); } } } @@ -273,32 +298,31 @@ public class MouseHandler { } if (screen != null && this.minecraft.getOverlay() == null && bl) { - double f = this.xpos * this.minecraft.getWindow().getGuiScaledWidth() / this.minecraft.getWindow().getScreenWidth(); - double g = this.ypos * this.minecraft.getWindow().getGuiScaledHeight() / this.minecraft.getWindow().getScreenHeight(); + Window window = this.minecraft.getWindow(); + double f = this.getScaledXPos(window); + double g = this.getScaledYPos(window); try { screen.mouseMoved(f, g); - } catch (Throwable var19) { - CrashReport crashReport = CrashReport.forThrowable(var19, "mouseMoved event handler"); + } catch (Throwable var20) { + CrashReport crashReport = CrashReport.forThrowable(var20, "mouseMoved event handler"); screen.fillCrashDetails(crashReport); CrashReportCategory crashReportCategory = crashReport.addCategory("Mouse"); - crashReportCategory.setDetail("Scaled X", f); - crashReportCategory.setDetail("Scaled Y", g); + this.fillMousePositionDetails(crashReportCategory, window); throw new ReportedException(crashReport); } if (this.activeButton != -1 && this.mousePressedTime > 0.0) { - double h = this.accumulatedDX * this.minecraft.getWindow().getGuiScaledWidth() / this.minecraft.getWindow().getScreenWidth(); - double i = this.accumulatedDY * this.minecraft.getWindow().getGuiScaledHeight() / this.minecraft.getWindow().getScreenHeight(); + double h = getScaledXPos(window, this.accumulatedDX); + double i = getScaledYPos(window, this.accumulatedDY); try { screen.mouseDragged(f, g, this.activeButton, h, i); - } catch (Throwable var18) { - CrashReport crashReport2 = CrashReport.forThrowable(var18, "mouseDragged event handler"); + } catch (Throwable var19) { + CrashReport crashReport2 = CrashReport.forThrowable(var19, "mouseDragged event handler"); screen.fillCrashDetails(crashReport2); CrashReportCategory crashReportCategory2 = crashReport2.addCategory("Mouse"); - crashReportCategory2.setDetail("Scaled X", f); - crashReportCategory2.setDetail("Scaled Y", g); + this.fillMousePositionDetails(crashReportCategory2, window); throw new ReportedException(crashReport2); } } @@ -315,6 +339,22 @@ public class MouseHandler { this.accumulatedDY = 0.0; } + public static double getScaledXPos(Window window, double xPos) { + return xPos * window.getGuiScaledWidth() / window.getScreenWidth(); + } + + public double getScaledXPos(Window window) { + return getScaledXPos(window, this.xpos); + } + + public static double getScaledYPos(Window window, double yPos) { + return yPos * window.getGuiScaledHeight() / window.getScreenHeight(); + } + + public double getScaledYPos(Window window) { + return getScaledYPos(window, this.ypos); + } + private void turnPlayer(double movementTime) { double d = this.minecraft.options.sensitivity().get() * 0.6F + 0.2F; double e = d * d * d; @@ -416,4 +456,12 @@ public class MouseHandler { public void cursorEntered() { this.ignoreFirstMove = true; } + + public void drawDebugMouseInfo(Font font, GuiGraphics guiGraphics) { + Window window = this.minecraft.getWindow(); + double d = this.getScaledXPos(window); + double e = this.getScaledYPos(window) - 8.0; + String string = String.format(Locale.ROOT, "%.0f,%.0f", d, e); + guiGraphics.drawString(font, string, (int)d, (int)e, -1); + } } diff --git a/net/minecraft/client/Options.java b/net/minecraft/client/Options.java index 0300716c..278e053b 100644 --- a/net/minecraft/client/Options.java +++ b/net/minecraft/client/Options.java @@ -20,7 +20,6 @@ import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.datafixers.util.Pair; import com.mojang.logging.LogUtils; import com.mojang.serialization.Codec; -import com.mojang.serialization.DataResult; import com.mojang.serialization.JsonOps; import java.io.BufferedReader; import java.io.File; @@ -32,7 +31,6 @@ import java.nio.charset.StandardCharsets; import java.util.ArrayList; import java.util.Arrays; import java.util.Comparator; -import java.util.EnumMap; import java.util.EnumSet; import java.util.Iterator; import java.util.List; @@ -49,6 +47,12 @@ import net.fabricmc.api.Environment; import net.minecraft.ChatFormatting; import net.minecraft.SharedConstants; import net.minecraft.Util; +import net.minecraft.client.OptionInstance.AltEnum; +import net.minecraft.client.OptionInstance.ClampingLazyMaxIntRange; +import net.minecraft.client.OptionInstance.Enum; +import net.minecraft.client.OptionInstance.IntRange; +import net.minecraft.client.OptionInstance.LazyEnum; +import net.minecraft.client.OptionInstance.UnitDouble; import net.minecraft.client.gui.components.ChatComponent; import net.minecraft.client.gui.components.Tooltip; import net.minecraft.client.renderer.GpuWarnlistManager; @@ -57,6 +61,8 @@ import net.minecraft.client.sounds.SoundEngine; import net.minecraft.client.sounds.SoundManager; import net.minecraft.client.tutorial.TutorialSteps; import net.minecraft.nbt.CompoundTag; +import net.minecraft.nbt.StringTag; +import net.minecraft.nbt.Tag; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.MutableComponent; @@ -108,7 +114,7 @@ public class Options { } else { return double_ == 1.0 ? genericValueLabel(component, Component.translatable("options.sensitivity.max")) : percentValueLabel(component, 2.0 * double_); } - }, OptionInstance.UnitDouble.INSTANCE, 0.5, double_ -> {}); + }, UnitDouble.INSTANCE, 0.5, double_ -> {}); private final OptionInstance renderDistance; private final OptionInstance simulationDistance; private int serverRenderDistance = 0; @@ -116,7 +122,7 @@ public class Options { "options.entityDistanceScaling", OptionInstance.noTooltip(), Options::percentValueLabel, - new OptionInstance.IntRange(2, 20).xmap(i -> i / 4.0, double_ -> (int)(double_ * 4.0)), + new IntRange(2, 20).xmap(i -> i / 4.0, double_ -> (int)(double_ * 4.0)), Codec.doubleRange(0.5, 5.0), 1.0, double_ -> {} @@ -128,7 +134,7 @@ public class Options { (component, integer) -> integer == 260 ? genericValueLabel(component, Component.translatable("options.framerateLimit.max")) : genericValueLabel(component, Component.translatable("options.framerate", integer)), - new OptionInstance.IntRange(1, 26).xmap(i -> i * 10, integer -> integer / 10), + new IntRange(1, 26).xmap(i -> i * 10, integer -> integer / 10), Codec.intRange(10, 260), 120, integer -> Minecraft.getInstance().getFramerateLimitTracker().setFramerateLimit(integer) @@ -144,7 +150,7 @@ public class Options { }; }, OptionInstance.forOptionEnum(), - new OptionInstance.Enum<>(Arrays.asList(InactivityFpsLimit.values()), InactivityFpsLimit.CODEC), + new Enum<>(Arrays.asList(InactivityFpsLimit.values()), InactivityFpsLimit.CODEC), InactivityFpsLimit.AFK, inactivityFpsLimit -> {} ); @@ -152,7 +158,7 @@ public class Options { "options.renderClouds", OptionInstance.noTooltip(), OptionInstance.forOptionEnum(), - new OptionInstance.Enum<>( + new Enum<>( Arrays.asList(CloudStatus.values()), Codec.withAlternative(CloudStatus.CODEC, Codec.BOOL, boolean_ -> boolean_ ? CloudStatus.FANCY : CloudStatus.OFF) ), CloudStatus.FANCY, @@ -176,7 +182,7 @@ public class Options { MutableComponent mutableComponent = Component.translatable(graphicsStatus.getKey()); return graphicsStatus == GraphicsStatus.FABULOUS ? mutableComponent.withStyle(ChatFormatting.ITALIC) : mutableComponent; }, - new OptionInstance.AltEnum<>( + new AltEnum<>( Arrays.asList(GraphicsStatus.values()), (List)Stream.of(GraphicsStatus.values()).filter(graphicsStatus -> graphicsStatus != GraphicsStatus.FABULOUS).collect(Collectors.toList()), () -> Minecraft.getInstance().isRunning() && Minecraft.getInstance().getGpuWarnlistManager().isSkippingFabulous(), @@ -211,7 +217,7 @@ public class Options { }; }, OptionInstance.forOptionEnum(), - new OptionInstance.Enum<>(Arrays.asList(PrioritizeChunkUpdates.values()), Codec.INT.xmap(PrioritizeChunkUpdates::byId, PrioritizeChunkUpdates::getId)), + new Enum<>(Arrays.asList(PrioritizeChunkUpdates.values()), Codec.INT.xmap(PrioritizeChunkUpdates::byId, PrioritizeChunkUpdates::getId)), PrioritizeChunkUpdates.NONE, prioritizeChunkUpdates -> {} ); @@ -221,7 +227,7 @@ public class Options { "options.chat.visibility", OptionInstance.noTooltip(), OptionInstance.forOptionEnum(), - new OptionInstance.Enum<>(Arrays.asList(ChatVisiblity.values()), Codec.INT.xmap(ChatVisiblity::byId, ChatVisiblity::getId)), + new Enum<>(Arrays.asList(ChatVisiblity.values()), Codec.INT.xmap(ChatVisiblity::byId, ChatVisiblity::getId)), ChatVisiblity.FULL, chatVisiblity -> {} ); @@ -229,12 +235,12 @@ public class Options { "options.chat.opacity", OptionInstance.noTooltip(), (component, double_) -> percentValueLabel(component, double_ * 0.9 + 0.1), - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 1.0, double_ -> Minecraft.getInstance().gui.getChat().rescaleChat() ); private final OptionInstance chatLineSpacing = new OptionInstance<>( - "options.chat.line_spacing", OptionInstance.noTooltip(), Options::percentValueLabel, OptionInstance.UnitDouble.INSTANCE, 0.0, double_ -> {} + "options.chat.line_spacing", OptionInstance.noTooltip(), Options::percentValueLabel, UnitDouble.INSTANCE, 0.0, double_ -> {} ); private static final Component MENU_BACKGROUND_BLURRINESS_TOOLTIP = Component.translatable("options.accessibility.menu_background_blurriness.tooltip"); private static final int BLURRINESS_DEFAULT_VALUE = 5; @@ -242,7 +248,7 @@ public class Options { "options.accessibility.menu_background_blurriness", OptionInstance.cachedConstantTooltip(MENU_BACKGROUND_BLURRINESS_TOOLTIP), Options::genericValueOrOffLabel, - new OptionInstance.IntRange(0, 10), + new IntRange(0, 10), 5, integer -> {} ); @@ -250,12 +256,12 @@ public class Options { "options.accessibility.text_background_opacity", OptionInstance.noTooltip(), Options::percentValueLabel, - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 0.5, double_ -> Minecraft.getInstance().gui.getChat().rescaleChat() ); private final OptionInstance panoramaSpeed = new OptionInstance<>( - "options.accessibility.panorama_speed", OptionInstance.noTooltip(), Options::percentValueLabel, OptionInstance.UnitDouble.INSTANCE, 1.0, double_ -> {} + "options.accessibility.panorama_speed", OptionInstance.noTooltip(), Options::percentValueLabel, UnitDouble.INSTANCE, 1.0, double_ -> {} ); private static final Component ACCESSIBILITY_TOOLTIP_CONTRAST_MODE = Component.translatable("options.accessibility.high_contrast.tooltip"); private final OptionInstance highContrast = OptionInstance.createBoolean( @@ -294,7 +300,7 @@ public class Options { "options.mainHand", OptionInstance.noTooltip(), OptionInstance.forOptionEnum(), - new OptionInstance.Enum<>(Arrays.asList(HumanoidArm.values()), HumanoidArm.CODEC), + new Enum<>(Arrays.asList(HumanoidArm.values()), HumanoidArm.CODEC), HumanoidArm.RIGHT, humanoidArm -> {} ); @@ -304,7 +310,7 @@ public class Options { "options.chat.scale", OptionInstance.noTooltip(), (component, double_) -> (Component)(double_ == 0.0 ? CommonComponents.optionStatus(component, false) : percentValueLabel(component, double_)), - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 1.0, double_ -> Minecraft.getInstance().gui.getChat().rescaleChat() ); @@ -312,7 +318,7 @@ public class Options { "options.chat.width", OptionInstance.noTooltip(), (component, double_) -> pixelValueLabel(component, ChatComponent.getWidth(double_)), - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 1.0, double_ -> Minecraft.getInstance().gui.getChat().rescaleChat() ); @@ -320,7 +326,7 @@ public class Options { "options.chat.height.unfocused", OptionInstance.noTooltip(), (component, double_) -> pixelValueLabel(component, ChatComponent.getHeight(double_)), - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, ChatComponent.defaultUnfocusedPct(), double_ -> Minecraft.getInstance().gui.getChat().rescaleChat() ); @@ -328,7 +334,7 @@ public class Options { "options.chat.height.focused", OptionInstance.noTooltip(), (component, double_) -> pixelValueLabel(component, ChatComponent.getHeight(double_)), - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 1.0, double_ -> Minecraft.getInstance().gui.getChat().rescaleChat() ); @@ -338,7 +344,7 @@ public class Options { (component, double_) -> double_ <= 0.0 ? Component.translatable("options.chat.delay_none") : Component.translatable("options.chat.delay", String.format(Locale.ROOT, "%.1f", double_)), - new OptionInstance.IntRange(0, 60).xmap(i -> i / 10.0, double_ -> (int)(double_ * 10.0)), + new IntRange(0, 60).xmap(i -> i / 10.0, double_ -> (int)(double_ * 10.0)), Codec.doubleRange(0.0, 6.0), 0.0, double_ -> Minecraft.getInstance().getChatListener().setMessageDelay(double_) @@ -348,7 +354,7 @@ public class Options { "options.notifications.display_time", OptionInstance.cachedConstantTooltip(ACCESSIBILITY_TOOLTIP_NOTIFICATION_DISPLAY_TIME), (component, double_) -> genericValueLabel(component, Component.translatable("options.multiplier", double_)), - new OptionInstance.IntRange(5, 100).xmap(i -> i / 10.0, double_ -> (int)(double_ * 10.0)), + new IntRange(5, 100).xmap(i -> i / 10.0, double_ -> (int)(double_ * 10.0)), Codec.doubleRange(0.5, 10.0), 1.0, double_ -> {} @@ -357,7 +363,7 @@ public class Options { "options.mipmapLevels", OptionInstance.noTooltip(), (component, integer) -> (Component)(integer == 0 ? CommonComponents.optionStatus(component, false) : genericValueLabel(component, integer)), - new OptionInstance.IntRange(0, 4), + new IntRange(0, 4), 4, integer -> {} ); @@ -366,7 +372,7 @@ public class Options { "options.attackIndicator", OptionInstance.noTooltip(), OptionInstance.forOptionEnum(), - new OptionInstance.Enum<>(Arrays.asList(AttackIndicatorStatus.values()), Codec.INT.xmap(AttackIndicatorStatus::byId, AttackIndicatorStatus::getId)), + new Enum<>(Arrays.asList(AttackIndicatorStatus.values()), Codec.INT.xmap(AttackIndicatorStatus::byId, AttackIndicatorStatus::getId)), AttackIndicatorStatus.CROSSHAIR, attackIndicatorStatus -> {} ); @@ -376,13 +382,13 @@ public class Options { "options.biomeBlendRadius", OptionInstance.noTooltip(), (component, integer) -> { int i = integer * 2 + 1; return genericValueLabel(component, Component.translatable("options.biomeBlendRadius." + i)); - }, new OptionInstance.IntRange(0, 7, false), 2, integer -> Minecraft.getInstance().levelRenderer.allChanged() + }, new IntRange(0, 7, false), 2, integer -> Minecraft.getInstance().levelRenderer.allChanged() ); private final OptionInstance mouseWheelSensitivity = new OptionInstance<>( "options.mouseWheelSensitivity", OptionInstance.noTooltip(), (component, double_) -> genericValueLabel(component, Component.literal(String.format(Locale.ROOT, "%.2f", double_))), - new OptionInstance.IntRange(-200, 100).xmap(Options::logMouse, Options::unlogMouse), + new IntRange(-200, 100).xmap(Options::logMouse, Options::unlogMouse), Codec.doubleRange(logMouse(-200), logMouse(100)), logMouse(0), double_ -> {} @@ -428,11 +434,9 @@ public class Options { "options.allowServerListing", OptionInstance.cachedConstantTooltip(ALLOW_SERVER_LISTING_TOOLTIP), true, boolean_ -> {} ); private final OptionInstance reducedDebugInfo = OptionInstance.createBoolean("options.reducedDebugInfo", false); - private final Map> soundSourceVolumes = Util.make(new EnumMap(SoundSource.class), enumMap -> { - for (SoundSource soundSource : SoundSource.values()) { - enumMap.put(soundSource, this.createSoundSliderOptionInstance("soundCategory." + soundSource.getName(), soundSource)); - } - }); + private final Map> soundSourceVolumes = Util.makeEnumMap( + SoundSource.class, soundSource -> this.createSoundSliderOptionInstance("soundCategory." + soundSource.getName(), soundSource) + ); private final OptionInstance showSubtitles = OptionInstance.createBoolean("options.showSubtitles", false); private static final Component DIRECTIONAL_AUDIO_TOOLTIP_ON = Component.translatable("options.directionalAudio.on.tooltip"); private static final Component DIRECTIONAL_AUDIO_TOOLTIP_OFF = Component.translatable("options.directionalAudio.off.tooltip"); @@ -575,7 +579,7 @@ public class Options { default -> genericValueLabel(component, integer); }; }, - new OptionInstance.IntRange(30, 110), + new IntRange(30, 110), Codec.DOUBLE.xmap(double_ -> (int)(double_ * 40.0 + 70.0), integer -> (integer.intValue() - 70.0) / 40.0), 70, integer -> Minecraft.getInstance().levelRenderer.needsUpdate() @@ -604,7 +608,7 @@ public class Options { "options.screenEffectScale", OptionInstance.cachedConstantTooltip(ACCESSIBILITY_TOOLTIP_SCREEN_EFFECT), Options::percentValueOrOffLabel, - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 1.0, double_ -> {} ); @@ -613,7 +617,7 @@ public class Options { "options.fovEffectScale", OptionInstance.cachedConstantTooltip(ACCESSIBILITY_TOOLTIP_FOV_EFFECT), Options::percentValueOrOffLabel, - OptionInstance.UnitDouble.INSTANCE.xmap(Mth::square, Math::sqrt), + UnitDouble.INSTANCE.xmap(Mth::square, Math::sqrt), Codec.doubleRange(0.0, 1.0), 1.0, double_ -> {} @@ -623,7 +627,7 @@ public class Options { "options.darknessEffectScale", OptionInstance.cachedConstantTooltip(ACCESSIBILITY_TOOLTIP_DARKNESS_EFFECT), Options::percentValueOrOffLabel, - OptionInstance.UnitDouble.INSTANCE.xmap(Mth::square, Math::sqrt), + UnitDouble.INSTANCE.xmap(Mth::square, Math::sqrt), 1.0, double_ -> {} ); @@ -632,7 +636,7 @@ public class Options { "options.glintSpeed", OptionInstance.cachedConstantTooltip(ACCESSIBILITY_TOOLTIP_GLINT_SPEED), Options::percentValueOrOffLabel, - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 0.5, double_ -> {} ); @@ -641,7 +645,7 @@ public class Options { "options.glintStrength", OptionInstance.cachedConstantTooltip(ACCESSIBILITY_TOOLTIP_GLINT_STRENGTH), Options::percentValueOrOffLabel, - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 0.75, RenderSystem::setShaderGlintAlpha ); @@ -650,7 +654,7 @@ public class Options { "options.damageTiltStrength", OptionInstance.cachedConstantTooltip(ACCESSIBILITY_TOOLTIP_DAMAGE_TILT_STRENGTH), Options::percentValueOrOffLabel, - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 1.0, double_ -> {} ); @@ -663,14 +667,14 @@ public class Options { } else { return i == 100 ? genericValueLabel(component, Component.translatable("options.gamma.max")) : genericValueLabel(component, i); } - }, OptionInstance.UnitDouble.INSTANCE, 0.5, double_ -> {}); + }, UnitDouble.INSTANCE, 0.5, double_ -> {}); public static final int AUTO_GUI_SCALE = 0; private static final int MAX_GUI_SCALE_INCLUSIVE = 2147483646; private final OptionInstance guiScale = new OptionInstance<>( "options.guiScale", OptionInstance.noTooltip(), (component, integer) -> integer == 0 ? Component.translatable("options.guiScale.auto") : Component.literal(Integer.toString(integer)), - new OptionInstance.ClampingLazyMaxIntRange(0, () -> { + new ClampingLazyMaxIntRange(0, () -> { Minecraft minecraftx = Minecraft.getInstance(); return !minecraftx.isRunning() ? 2147483646 : minecraftx.getWindow().calculateScale(0, minecraftx.isEnforceUnicode()); }, 2147483646), @@ -681,7 +685,7 @@ public class Options { "options.particles", OptionInstance.noTooltip(), OptionInstance.forOptionEnum(), - new OptionInstance.Enum<>(Arrays.asList(ParticleStatus.values()), Codec.INT.xmap(ParticleStatus::byId, ParticleStatus::getId)), + new Enum<>(Arrays.asList(ParticleStatus.values()), Codec.INT.xmap(ParticleStatus::byId, ParticleStatus::getId)), ParticleStatus.ALL, particleStatus -> {} ); @@ -691,7 +695,7 @@ public class Options { (component, narratorStatus) -> (Component)(this.minecraft.getNarrator().isActive() ? narratorStatus.getName() : Component.translatable("options.narrator.notavailable")), - new OptionInstance.Enum<>(Arrays.asList(NarratorStatus.values()), Codec.INT.xmap(NarratorStatus::byId, NarratorStatus::getId)), + new Enum<>(Arrays.asList(NarratorStatus.values()), Codec.INT.xmap(NarratorStatus::byId, NarratorStatus::getId)), NarratorStatus.OFF, narratorStatus -> this.minecraft.getNarrator().updateNarratorStatus(narratorStatus) ); @@ -706,7 +710,7 @@ public class Options { return string.startsWith("OpenAL Soft on ") ? Component.literal(string.substring(SoundEngine.OPEN_AL_SOFT_PREFIX_LENGTH)) : Component.literal(string); } }, - new OptionInstance.LazyEnum<>( + new LazyEnum<>( () -> Stream.concat(Stream.of(""), Minecraft.getInstance().getSoundManager().getAvailableSoundDevices().stream()).toList(), string -> Minecraft.getInstance().isRunning() && string != "" && !Minecraft.getInstance().getSoundManager().getAvailableSoundDevices().contains(string) ? Optional.empty() @@ -722,6 +726,7 @@ public class Options { ); public boolean onboardAccessibility = true; public boolean syncWrites; + public boolean startedCleanly = true; public OptionInstance darkMojangStudiosBackground() { return this.darkMojangStudiosBackground; @@ -981,7 +986,7 @@ public class Options { text, OptionInstance.noTooltip(), Options::percentValueOrOffLabel, - OptionInstance.UnitDouble.INSTANCE, + UnitDouble.INSTANCE, 1.0, double_ -> Minecraft.getInstance().getSoundManager().updateSourceVolume(soundSource, double_.floatValue()) ); @@ -1096,7 +1101,7 @@ public class Options { "options.renderDistance", OptionInstance.noTooltip(), (component, integer) -> genericValueLabel(component, Component.translatable("options.chunks", integer)), - new OptionInstance.IntRange(2, bl ? 32 : 16, false), + new IntRange(2, bl ? 32 : 16, false), 12, integer -> Minecraft.getInstance().levelRenderer.needsUpdate() ); @@ -1104,7 +1109,7 @@ public class Options { "options.simulationDistance", OptionInstance.noTooltip(), (component, integer) -> genericValueLabel(component, Component.translatable("options.chunks", integer)), - new OptionInstance.IntRange(5, bl ? 32 : 16, false), + new IntRange(5, bl ? 32 : 16, false), 12, integer -> {} ); @@ -1219,6 +1224,7 @@ public class Options { accessor.process("telemetryOptInExtra", this.telemetryOptInExtra); this.onboardAccessibility = accessor.process("onboardAccessibility", this.onboardAccessibility); accessor.process("menuBackgroundBlurriness", this.menuBackgroundBlurriness); + this.startedCleanly = accessor.process("startedCleanly", this.startedCleanly); for (KeyMapping keyMapping : this.keyMappings) { String string = keyMapping.saveString(); @@ -1258,7 +1264,7 @@ public class Options { try { Iterator iterator = OPTION_SPLITTER.split(string).iterator(); compoundTag.putString((String)iterator.next(), (String)iterator.next()); - } catch (Exception var3) { + } catch (Exception var3x) { LOGGER.warn("Skipping bad option: {}", string); } }); @@ -1279,86 +1285,90 @@ public class Options { } final CompoundTag compoundTag2 = this.dataFix(compoundTag); - if (!compoundTag2.contains("graphicsMode") && compoundTag2.contains("fancyGraphics")) { - if (isTrue(compoundTag2.getString("fancyGraphics"))) { - this.graphicsMode.set(GraphicsStatus.FANCY); - } else { - this.graphicsMode.set(GraphicsStatus.FAST); - } + Optional optional = compoundTag2.getString("fancyGraphics"); + if (optional.isPresent() && !compoundTag2.contains("graphicsMode")) { + this.graphicsMode.set(isTrue((String)optional.get()) ? GraphicsStatus.FANCY : GraphicsStatus.FAST); } - this.processOptions(new Options.FieldAccess() { - @Nullable - private String getValueOrNull(String name) { - return compoundTag2.contains(name) ? compoundTag2.get(name).getAsString() : null; - } - - @Override - public void process(String name, OptionInstance value) { - String string = this.getValueOrNull(name); - if (string != null) { - JsonReader jsonReader = new JsonReader(new StringReader(string.isEmpty() ? "\"\"" : string)); - JsonElement jsonElement = JsonParser.parseReader(jsonReader); - DataResult dataResult = value.codec().parse(JsonOps.INSTANCE, jsonElement); - dataResult.error().ifPresent(error -> Options.LOGGER.error("Error parsing option value " + string + " for option " + value + ": " + error.message())); - dataResult.ifSuccess(value::set); - } - } - - @Override - public int process(String name, int value) { - String string = this.getValueOrNull(name); - if (string != null) { - try { - return Integer.parseInt(string); - } catch (NumberFormatException var5) { - Options.LOGGER.warn("Invalid integer value for option {} = {}", name, string, var5); + this.processOptions( + new Options.FieldAccess() { + @Nullable + private String getValue(String string) { + Tag tag = compoundTag2.get(string); + if (tag == null) { + return null; + } else if (tag instanceof StringTag(String var7x)) { + return var7x; + } else { + throw new IllegalStateException("Cannot read field of wrong type, expected string: " + tag); } } - return value; - } + @Override + public void process(String name, OptionInstance value) { + String string = this.getValue(name); + if (string != null) { + JsonReader jsonReader = new JsonReader(new StringReader(string.isEmpty() ? "\"\"" : string)); + JsonElement jsonElement = JsonParser.parseReader(jsonReader); + value.codec() + .parse(JsonOps.INSTANCE, jsonElement) + .ifError(error -> Options.LOGGER.error("Error parsing option value {} for option {}: {}", string, value, error.message())) + .ifSuccess(value::set); + } + } - @Override - public boolean process(String name, boolean value) { - String string = this.getValueOrNull(name); - return string != null ? Options.isTrue(string) : value; - } + @Override + public int process(String name, int value) { + String string = this.getValue(name); + if (string != null) { + try { + return Integer.parseInt(string); + } catch (NumberFormatException var5) { + Options.LOGGER.warn("Invalid integer value for option {} = {}", name, string, var5); + } + } - @Override - public String process(String name, String value) { - return MoreObjects.firstNonNull(this.getValueOrNull(name), value); - } - - @Override - public float process(String name, float value) { - String string = this.getValueOrNull(name); - if (string == null) { return value; - } else if (Options.isTrue(string)) { - return 1.0F; - } else if (Options.isFalse(string)) { - return 0.0F; - } else { - try { - return Float.parseFloat(string); - } catch (NumberFormatException var5) { - Options.LOGGER.warn("Invalid floating point value for option {} = {}", name, string, var5); + } + + @Override + public boolean process(String name, boolean value) { + String string = this.getValue(name); + return string != null ? Options.isTrue(string) : value; + } + + @Override + public String process(String name, String value) { + return MoreObjects.firstNonNull(this.getValue(name), value); + } + + @Override + public float process(String name, float value) { + String string = this.getValue(name); + if (string == null) { return value; + } else if (Options.isTrue(string)) { + return 1.0F; + } else if (Options.isFalse(string)) { + return 0.0F; + } else { + try { + return Float.parseFloat(string); + } catch (NumberFormatException var5) { + Options.LOGGER.warn("Invalid floating point value for option {} = {}", name, string, var5); + return value; + } } } - } - @Override - public T process(String name, T value, Function stringValuefier, Function valueStringifier) { - String string = this.getValueOrNull(name); - return (T)(string == null ? value : stringValuefier.apply(string)); + @Override + public T process(String name, T value, Function stringValuefier, Function valueStringifier) { + String string = this.getValue(name); + return (T)(string == null ? value : stringValuefier.apply(string)); + } } - }); - if (compoundTag2.contains("fullscreenResolution")) { - this.fullscreenVideoModeString = compoundTag2.getString("fullscreenResolution"); - } - + ); + compoundTag2.getString("fullscreenResolution").ifPresent(string -> this.fullscreenVideoModeString = string); KeyMapping.resetMapping(); } catch (Exception var7) { LOGGER.error("Failed to load options", (Throwable)var7); @@ -1377,7 +1387,7 @@ public class Options { int i = 0; try { - i = Integer.parseInt(nbt.getString("version")); + i = (Integer)nbt.getString("version").map(Integer::parseInt).orElse(0); } catch (RuntimeException var4) { } @@ -1447,8 +1457,9 @@ public class Options { } } ); - if (this.minecraft.getWindow().getPreferredFullscreenVideoMode().isPresent()) { - printWriter.println("fullscreenResolution:" + ((VideoMode)this.minecraft.getWindow().getPreferredFullscreenVideoMode().get()).write()); + String string = this.getFullscreenVideoModeString(); + if (string != null) { + printWriter.println("fullscreenResolution:" + string); } } catch (Throwable var5) { try { @@ -1468,6 +1479,16 @@ public class Options { this.broadcastOptions(); } + @Nullable + private String getFullscreenVideoModeString() { + Window window = this.minecraft.getWindow(); + if (window == null) { + return this.fullscreenVideoModeString; + } else { + return window.getPreferredFullscreenVideoMode().isPresent() ? ((VideoMode)window.getPreferredFullscreenVideoMode().get()).write() : null; + } + } + public ClientInformation buildPlayerInformation() { int i = 0; diff --git a/net/minecraft/client/Screenshot.java b/net/minecraft/client/Screenshot.java index 1a2fcb32..4341be61 100644 --- a/net/minecraft/client/Screenshot.java +++ b/net/minecraft/client/Screenshot.java @@ -1,14 +1,15 @@ package net.minecraft.client; +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.platform.NativeImage; +import com.mojang.blaze3d.systems.CommandEncoder; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.logging.LogUtils; -import java.io.DataOutputStream; import java.io.File; -import java.io.FileOutputStream; -import java.io.IOException; -import java.nio.ByteBuffer; import java.util.function.Consumer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -23,12 +24,6 @@ import org.slf4j.Logger; public class Screenshot { private static final Logger LOGGER = LogUtils.getLogger(); public static final String SCREENSHOT_DIR = "screenshots"; - private int rowHeight; - private final DataOutputStream outputStream; - private final byte[] bytes; - private final int width; - private final int height; - private File file; /** * Saves a screenshot in the game directory with a time-stamped filename. @@ -41,51 +36,82 @@ public class Screenshot { * Saves a screenshot in the game directory with the given file name (or null to generate a time-stamped name). */ public static void grab(File gameDirectory, @Nullable String screenshotName, RenderTarget buffer, Consumer messageConsumer) { - if (!RenderSystem.isOnRenderThread()) { - RenderSystem.recordRenderCall(() -> _grab(gameDirectory, screenshotName, buffer, messageConsumer)); - } else { - _grab(gameDirectory, screenshotName, buffer, messageConsumer); - } - } - - private static void _grab(File gameDirectory, @Nullable String screenshotName, RenderTarget buffer, Consumer messageConsumer) { - NativeImage nativeImage = takeScreenshot(buffer); - File file = new File(gameDirectory, "screenshots"); - file.mkdir(); - File file2; - if (screenshotName == null) { - file2 = getFile(file); - } else { - file2 = new File(file, screenshotName); - } - - Util.ioPool() - .execute( - () -> { - try { - nativeImage.writeToFile(file2); - Component component = Component.literal(file2.getName()) - .withStyle(ChatFormatting.UNDERLINE) - .withStyle(style -> style.withClickEvent(new ClickEvent(ClickEvent.Action.OPEN_FILE, file2.getAbsolutePath()))); - messageConsumer.accept(Component.translatable("screenshot.success", component)); - } catch (Exception var7) { - LOGGER.warn("Couldn't save screenshot", (Throwable)var7); - messageConsumer.accept(Component.translatable("screenshot.failure", var7.getMessage())); - } finally { - nativeImage.close(); - } + takeScreenshot( + buffer, + nativeImage -> { + File file2 = new File(gameDirectory, "screenshots"); + file2.mkdir(); + File file3; + if (screenshotName == null) { + file3 = getFile(file2); + } else { + file3 = new File(file2, screenshotName); } - ); + + Util.ioPool() + .execute( + () -> { + try { + NativeImage exception = nativeImage; + + try { + nativeImage.writeToFile(file3); + Component component = Component.literal(file3.getName()) + .withStyle(ChatFormatting.UNDERLINE) + .withStyle(style -> style.withClickEvent(new ClickEvent.OpenFile(file3.getAbsoluteFile()))); + messageConsumer.accept(Component.translatable("screenshot.success", component)); + } catch (Throwable var7) { + if (nativeImage != null) { + try { + exception.close(); + } catch (Throwable var6) { + var7.addSuppressed(var6); + } + } + + throw var7; + } + + if (nativeImage != null) { + nativeImage.close(); + } + } catch (Exception var8) { + LOGGER.warn("Couldn't save screenshot", (Throwable)var8); + messageConsumer.accept(Component.translatable("screenshot.failure", var8.getMessage())); + } + } + ); + } + ); } - public static NativeImage takeScreenshot(RenderTarget framebuffer) { - int i = framebuffer.width; - int j = framebuffer.height; - NativeImage nativeImage = new NativeImage(i, j, false); - RenderSystem.bindTexture(framebuffer.getColorTextureId()); - nativeImage.downloadTexture(0, true); - nativeImage.flipY(); - return nativeImage; + public static void takeScreenshot(RenderTarget renderTarget, Consumer writer) { + int i = renderTarget.width; + int j = renderTarget.height; + GpuTexture gpuTexture = renderTarget.getColorTexture(); + if (gpuTexture == null) { + throw new IllegalStateException("Tried to capture screenshot of an incomplete framebuffer"); + } else { + GpuBuffer gpuBuffer = RenderSystem.getDevice() + .createBuffer(() -> "Screenshot buffer", BufferType.PIXEL_PACK, BufferUsage.STATIC_READ, i * j * gpuTexture.getFormat().pixelSize()); + CommandEncoder commandEncoder = RenderSystem.getDevice().createCommandEncoder(); + RenderSystem.getDevice().createCommandEncoder().copyTextureToBuffer(gpuTexture, gpuBuffer, 0, () -> { + try (GpuBuffer.ReadView readView = commandEncoder.readBuffer(gpuBuffer)) { + NativeImage nativeImage = new NativeImage(i, j, false); + + for (int k = 0; k < j; k++) { + for (int l = 0; l < i; l++) { + int m = readView.data().getInt((l + k * i) * gpuTexture.getFormat().pixelSize()); + nativeImage.setPixelABGR(l, j - k - 1, m | 0xFF000000); + } + } + + writer.accept(nativeImage); + } + + gpuBuffer.close(); + }, 0); + } } /** @@ -104,58 +130,4 @@ public class Screenshot { i++; } } - - public Screenshot(File gameDirectory, int width, int height, int rowHeight) throws IOException { - this.width = width; - this.height = height; - this.rowHeight = rowHeight; - File file = new File(gameDirectory, "screenshots"); - file.mkdir(); - String string = "huge_" + Util.getFilenameFormattedDateTime(); - int i = 1; - - while ((this.file = new File(file, string + (i == 1 ? "" : "_" + i) + ".tga")).exists()) { - i++; - } - - byte[] bs = new byte[18]; - bs[2] = 2; - bs[12] = (byte)(width % 256); - bs[13] = (byte)(width / 256); - bs[14] = (byte)(height % 256); - bs[15] = (byte)(height / 256); - bs[16] = 24; - this.bytes = new byte[width * rowHeight * 3]; - this.outputStream = new DataOutputStream(new FileOutputStream(this.file)); - this.outputStream.write(bs); - } - - public void addRegion(ByteBuffer buffer, int width, int height, int rowWidth, int rowHeight) { - int i = rowWidth; - int j = rowHeight; - if (rowWidth > this.width - width) { - i = this.width - width; - } - - if (rowHeight > this.height - height) { - j = this.height - height; - } - - this.rowHeight = j; - - for (int k = 0; k < j; k++) { - buffer.position((rowHeight - j) * rowWidth * 3 + k * rowWidth * 3); - int l = (width + k * this.width) * 3; - buffer.get(this.bytes, l, i * 3); - } - } - - public void saveRow() throws IOException { - this.outputStream.write(this.bytes, 0, this.width * 3 * this.rowHeight); - } - - public File close() throws IOException { - this.outputStream.close(); - return this.file; - } } diff --git a/net/minecraft/client/color/block/BlockColors.java b/net/minecraft/client/color/block/BlockColors.java index b4a606a1..5784a3eb 100644 --- a/net/minecraft/client/color/block/BlockColors.java +++ b/net/minecraft/client/color/block/BlockColors.java @@ -50,7 +50,8 @@ public class BlockColors { Blocks.GRASS_BLOCK, Blocks.FERN, Blocks.SHORT_GRASS, - Blocks.POTTED_FERN + Blocks.POTTED_FERN, + Blocks.BUSH ); blockColors.register((blockState, blockAndTintGetter, blockPos, i) -> { if (i != 0) { @@ -58,7 +59,7 @@ public class BlockColors { } else { return -1; } - }, Blocks.PINK_PETALS); + }, Blocks.PINK_PETALS, Blocks.WILDFLOWERS); blockColors.register((blockState, blockAndTintGetter, blockPos, i) -> -10380959, Blocks.SPRUCE_LEAVES); blockColors.register((blockState, blockAndTintGetter, blockPos, i) -> -8345771, Blocks.BIRCH_LEAVES); blockColors.register( @@ -72,6 +73,12 @@ public class BlockColors { Blocks.VINE, Blocks.MANGROVE_LEAVES ); + blockColors.register( + (blockState, blockAndTintGetter, blockPos, i) -> blockAndTintGetter != null && blockPos != null + ? BiomeColors.getAverageDryFoliageColor(blockAndTintGetter, blockPos) + : -10732494, + Blocks.LEAF_LITTER + ); blockColors.register( (blockState, blockAndTintGetter, blockPos, i) -> blockAndTintGetter != null && blockPos != null ? BiomeColors.getAverageWaterColor(blockAndTintGetter, blockPos) diff --git a/net/minecraft/client/data/AtlasProvider.java b/net/minecraft/client/data/AtlasProvider.java new file mode 100644 index 00000000..5ebf7754 --- /dev/null +++ b/net/minecraft/client/data/AtlasProvider.java @@ -0,0 +1,174 @@ +package net.minecraft.client.data; + +import java.util.ArrayList; +import java.util.Comparator; +import java.util.List; +import java.util.Map; +import java.util.concurrent.CompletableFuture; +import java.util.function.UnaryOperator; +import java.util.stream.Collectors; +import java.util.stream.Stream; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.data.models.ItemModelGenerators; +import net.minecraft.client.renderer.MaterialMapper; +import net.minecraft.client.renderer.Sheets; +import net.minecraft.client.renderer.blockentity.BellRenderer; +import net.minecraft.client.renderer.blockentity.ConduitRenderer; +import net.minecraft.client.renderer.blockentity.EnchantTableRenderer; +import net.minecraft.client.renderer.texture.atlas.SpriteSource; +import net.minecraft.client.renderer.texture.atlas.SpriteSources; +import net.minecraft.client.renderer.texture.atlas.sources.DirectoryLister; +import net.minecraft.client.renderer.texture.atlas.sources.PalettedPermutations; +import net.minecraft.client.renderer.texture.atlas.sources.SingleFile; +import net.minecraft.client.resources.model.AtlasIds; +import net.minecraft.client.resources.model.EquipmentClientInfo; +import net.minecraft.client.resources.model.Material; +import net.minecraft.client.resources.model.ModelBakery; +import net.minecraft.data.CachedOutput; +import net.minecraft.data.DataProvider; +import net.minecraft.data.PackOutput; +import net.minecraft.data.PackOutput.PathProvider; +import net.minecraft.data.PackOutput.Target; +import net.minecraft.resources.ResourceKey; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.world.item.equipment.trim.MaterialAssetGroup; +import net.minecraft.world.item.equipment.trim.TrimPattern; +import net.minecraft.world.item.equipment.trim.TrimPatterns; + +@Environment(EnvType.CLIENT) +public class AtlasProvider implements DataProvider { + private static final ResourceLocation TRIM_PALETTE_KEY = ResourceLocation.withDefaultNamespace("trims/color_palettes/trim_palette"); + private static final Map TRIM_PALETTE_VALUES = (Map)extractAllMaterialAssets() + .collect( + Collectors.toMap(MaterialAssetGroup.AssetInfo::suffix, assetInfo -> ResourceLocation.withDefaultNamespace("trims/color_palettes/" + assetInfo.suffix())) + ); + private static final List> VANILLA_PATTERNS = List.of( + TrimPatterns.SENTRY, + TrimPatterns.DUNE, + TrimPatterns.COAST, + TrimPatterns.WILD, + TrimPatterns.WARD, + TrimPatterns.EYE, + TrimPatterns.VEX, + TrimPatterns.TIDE, + TrimPatterns.SNOUT, + TrimPatterns.RIB, + TrimPatterns.SPIRE, + TrimPatterns.WAYFINDER, + TrimPatterns.SHAPER, + TrimPatterns.SILENCE, + TrimPatterns.RAISER, + TrimPatterns.HOST, + TrimPatterns.FLOW, + TrimPatterns.BOLT + ); + private static final List HUMANOID_LAYERS = List.of( + EquipmentClientInfo.LayerType.HUMANOID, EquipmentClientInfo.LayerType.HUMANOID_LEGGINGS + ); + private final PathProvider pathProvider; + + public AtlasProvider(PackOutput output) { + this.pathProvider = output.createPathProvider(Target.RESOURCE_PACK, "atlases"); + } + + private static List patternTextures() { + List list = new ArrayList(VANILLA_PATTERNS.size() * HUMANOID_LAYERS.size()); + + for (ResourceKey resourceKey : VANILLA_PATTERNS) { + ResourceLocation resourceLocation = TrimPatterns.defaultAssetId(resourceKey); + + for (EquipmentClientInfo.LayerType layerType : HUMANOID_LAYERS) { + list.add(resourceLocation.withPath((UnaryOperator)(string -> layerType.trimAssetPrefix() + "/" + string))); + } + } + + return list; + } + + private static SpriteSource forMaterial(Material material) { + return new SingleFile(material.texture()); + } + + private static SpriteSource forMapper(MaterialMapper mapper) { + return new DirectoryLister(mapper.prefix(), mapper.prefix() + "/"); + } + + private static List simpleMapper(MaterialMapper mapper) { + return List.of(forMapper(mapper)); + } + + private static List noPrefixMapper(String path) { + return List.of(new DirectoryLister(path, "")); + } + + private static Stream extractAllMaterialAssets() { + return ItemModelGenerators.TRIM_MATERIAL_MODELS + .stream() + .map(ItemModelGenerators.TrimMaterialData::assets) + .flatMap(materialAssetGroup -> Stream.concat(Stream.of(materialAssetGroup.base()), materialAssetGroup.overrides().values().stream())) + .sorted(Comparator.comparing(MaterialAssetGroup.AssetInfo::suffix)); + } + + private static List armorTrims() { + return List.of(new PalettedPermutations(patternTextures(), TRIM_PALETTE_KEY, TRIM_PALETTE_VALUES)); + } + + private static List blocksList() { + return List.of( + forMapper(Sheets.BLOCKS_MAPPER), + forMapper(Sheets.ITEMS_MAPPER), + forMapper(ConduitRenderer.MAPPER), + forMaterial(BellRenderer.BELL_RESOURCE_LOCATION), + forMaterial(Sheets.DECORATED_POT_SIDE), + forMaterial(EnchantTableRenderer.BOOK_LOCATION), + new PalettedPermutations( + List.of( + ItemModelGenerators.TRIM_PREFIX_HELMET, + ItemModelGenerators.TRIM_PREFIX_CHESTPLATE, + ItemModelGenerators.TRIM_PREFIX_LEGGINGS, + ItemModelGenerators.TRIM_PREFIX_BOOTS + ), + TRIM_PALETTE_KEY, + TRIM_PALETTE_VALUES + ) + ); + } + + private static List bannerPatterns() { + return List.of(forMaterial(ModelBakery.BANNER_BASE), forMapper(Sheets.BANNER_MAPPER)); + } + + private static List shieldPatterns() { + return List.of(forMaterial(ModelBakery.SHIELD_BASE), forMaterial(ModelBakery.NO_PATTERN_SHIELD), forMapper(Sheets.SHIELD_MAPPER)); + } + + @Override + public CompletableFuture run(CachedOutput output) { + return CompletableFuture.allOf( + this.storeAtlas(output, AtlasIds.ARMOR_TRIMS, armorTrims()), + this.storeAtlas(output, AtlasIds.BANNER_PATTERNS, bannerPatterns()), + this.storeAtlas(output, AtlasIds.BEDS, simpleMapper(Sheets.BED_MAPPER)), + this.storeAtlas(output, AtlasIds.BLOCKS, blocksList()), + this.storeAtlas(output, AtlasIds.CHESTS, simpleMapper(Sheets.CHEST_MAPPER)), + this.storeAtlas(output, AtlasIds.DECORATED_POT, simpleMapper(Sheets.DECORATED_POT_MAPPER)), + this.storeAtlas(output, AtlasIds.GUI, noPrefixMapper("gui/sprites")), + this.storeAtlas(output, AtlasIds.MAP_DECORATIONS, noPrefixMapper("map/decorations")), + this.storeAtlas(output, AtlasIds.MOB_EFFECTS, noPrefixMapper("mob_effect")), + this.storeAtlas(output, AtlasIds.PAINTINGS, noPrefixMapper("painting")), + this.storeAtlas(output, AtlasIds.PARTICLES, noPrefixMapper("particle")), + this.storeAtlas(output, AtlasIds.SHIELD_PATTERNS, shieldPatterns()), + this.storeAtlas(output, AtlasIds.SHULKER_BOXES, simpleMapper(Sheets.SHULKER_MAPPER)), + this.storeAtlas(output, AtlasIds.SIGNS, simpleMapper(Sheets.SIGN_MAPPER)) + ); + } + + private CompletableFuture storeAtlas(CachedOutput output, ResourceLocation atlasId, List sources) { + return DataProvider.saveStable(output, SpriteSources.FILE_CODEC, sources, this.pathProvider.json(atlasId)); + } + + @Override + public String getName() { + return "Atlas Definitions"; + } +} diff --git a/net/minecraft/client/data/Main.java b/net/minecraft/client/data/Main.java index 659a7f7a..7ef7ed80 100644 --- a/net/minecraft/client/data/Main.java +++ b/net/minecraft/client/data/Main.java @@ -50,5 +50,6 @@ public class Main { PackGenerator packGenerator = dataGenerator.getVanillaPack(toRun); packGenerator.addProvider(ModelProvider::new); packGenerator.addProvider(EquipmentAssetProvider::new); + packGenerator.addProvider(AtlasProvider::new); } } diff --git a/net/minecraft/client/data/models/BlockModelGenerators.java b/net/minecraft/client/data/models/BlockModelGenerators.java index fe2bbfbe..ae315175 100644 --- a/net/minecraft/client/data/models/BlockModelGenerators.java +++ b/net/minecraft/client/data/models/BlockModelGenerators.java @@ -1,9 +1,9 @@ package net.minecraft.client.data.models; -import com.google.common.collect.ImmutableList; import com.google.common.collect.ImmutableMap; -import com.google.common.collect.Maps; +import com.google.common.collect.ImmutableMap.Builder; import com.mojang.datafixers.util.Pair; +import com.mojang.math.Quadrant; import it.unimi.dsi.fastutil.ints.Int2ObjectFunction; import it.unimi.dsi.fastutil.ints.Int2ObjectMap; import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap; @@ -18,21 +18,18 @@ import java.util.function.BiConsumer; import java.util.function.BiFunction; import java.util.function.Consumer; import java.util.function.Function; -import java.util.function.UnaryOperator; import java.util.stream.Collectors; import java.util.stream.IntStream; +import java.util.stream.Stream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.Util; import net.minecraft.client.color.item.GrassColorSource; import net.minecraft.client.color.item.ItemTintSource; -import net.minecraft.client.data.models.blockstates.BlockStateGenerator; -import net.minecraft.client.data.models.blockstates.Condition; +import net.minecraft.client.data.models.blockstates.BlockModelDefinitionGenerator; +import net.minecraft.client.data.models.blockstates.ConditionBuilder; import net.minecraft.client.data.models.blockstates.MultiPartGenerator; import net.minecraft.client.data.models.blockstates.MultiVariantGenerator; import net.minecraft.client.data.models.blockstates.PropertyDispatch; -import net.minecraft.client.data.models.blockstates.Variant; -import net.minecraft.client.data.models.blockstates.VariantProperties; import net.minecraft.client.data.models.model.ItemModelUtils; import net.minecraft.client.data.models.model.ModelInstance; import net.minecraft.client.data.models.model.ModelLocationUtils; @@ -41,21 +38,22 @@ import net.minecraft.client.data.models.model.ModelTemplates; import net.minecraft.client.data.models.model.TextureMapping; import net.minecraft.client.data.models.model.TextureSlot; import net.minecraft.client.data.models.model.TexturedModel; +import net.minecraft.client.renderer.block.model.VariantMutator; +import net.minecraft.client.renderer.block.model.multipart.CombinedCondition; +import net.minecraft.client.renderer.block.model.multipart.Condition; import net.minecraft.client.renderer.item.ItemModel; -import net.minecraft.client.renderer.special.BannerSpecialRenderer; import net.minecraft.client.renderer.special.BedSpecialRenderer; import net.minecraft.client.renderer.special.ChestSpecialRenderer; -import net.minecraft.client.renderer.special.ConduitSpecialRenderer; -import net.minecraft.client.renderer.special.DecoratedPotSpecialRenderer; import net.minecraft.client.renderer.special.ShulkerBoxSpecialRenderer; -import net.minecraft.client.renderer.special.SkullSpecialRenderer; -import net.minecraft.client.renderer.special.SpecialModelRenderer; +import net.minecraft.client.renderer.special.SkullSpecialRenderer.Unbaked; import net.minecraft.core.Direction; import net.minecraft.core.FrontAndTop; -import net.minecraft.core.Direction.Axis; import net.minecraft.data.BlockFamilies; import net.minecraft.data.BlockFamily; +import net.minecraft.data.BlockFamily.Variant; import net.minecraft.resources.ResourceLocation; +import net.minecraft.util.random.Weighted; +import net.minecraft.util.random.WeightedList; import net.minecraft.world.item.DyeColor; import net.minecraft.world.item.Item; import net.minecraft.world.item.Items; @@ -71,20 +69,21 @@ import net.minecraft.world.level.block.MangrovePropaguleBlock; import net.minecraft.world.level.block.MossyCarpetBlock; import net.minecraft.world.level.block.MultifaceBlock; import net.minecraft.world.level.block.PitcherCropBlock; +import net.minecraft.world.level.block.SkullBlock; import net.minecraft.world.level.block.SnifferEggBlock; +import net.minecraft.world.level.block.TestBlock; import net.minecraft.world.level.block.VaultBlock; -import net.minecraft.world.level.block.SkullBlock.Type; -import net.minecraft.world.level.block.SkullBlock.Types; +import net.minecraft.world.level.block.state.StateHolder; import net.minecraft.world.level.block.state.properties.AttachFace; import net.minecraft.world.level.block.state.properties.BambooLeaves; import net.minecraft.world.level.block.state.properties.BellAttachType; import net.minecraft.world.level.block.state.properties.BlockStateProperties; import net.minecraft.world.level.block.state.properties.BooleanProperty; import net.minecraft.world.level.block.state.properties.ComparatorMode; +import net.minecraft.world.level.block.state.properties.CreakingHeartState; import net.minecraft.world.level.block.state.properties.DoorHingeSide; import net.minecraft.world.level.block.state.properties.DoubleBlockHalf; import net.minecraft.world.level.block.state.properties.DripstoneThickness; -import net.minecraft.world.level.block.state.properties.EnumProperty; import net.minecraft.world.level.block.state.properties.Half; import net.minecraft.world.level.block.state.properties.PistonType; import net.minecraft.world.level.block.state.properties.Property; @@ -93,22 +92,85 @@ import net.minecraft.world.level.block.state.properties.RedstoneSide; import net.minecraft.world.level.block.state.properties.SculkSensorPhase; import net.minecraft.world.level.block.state.properties.SlabType; import net.minecraft.world.level.block.state.properties.StairsShape; +import net.minecraft.world.level.block.state.properties.TestBlockMode; import net.minecraft.world.level.block.state.properties.Tilt; import net.minecraft.world.level.block.state.properties.WallSide; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class BlockModelGenerators { - final Consumer blockStateOutput; + final Consumer blockStateOutput; final ItemModelOutput itemModelOutput; final BiConsumer modelOutput; - final List nonOrientableTrapdoor = ImmutableList.of(Blocks.OAK_TRAPDOOR, Blocks.DARK_OAK_TRAPDOOR, Blocks.IRON_TRAPDOOR); - final Map fullBlockModelCustomGenerators = ImmutableMap.builder() - .put(Blocks.STONE, BlockModelGenerators::createMirroredCubeGenerator) - .put(Blocks.DEEPSLATE, BlockModelGenerators::createMirroredColumnGenerator) - .put(Blocks.MUD_BRICKS, BlockModelGenerators::createNorthWestMirroredCubeGenerator) - .build(); - final Map texturedModels = ImmutableMap.builder() + static final List NON_ORIENTABLE_TRAPDOOR = List.of(Blocks.OAK_TRAPDOOR, Blocks.DARK_OAK_TRAPDOOR, Blocks.IRON_TRAPDOOR); + public static final VariantMutator NOP = variant -> variant; + public static final VariantMutator UV_LOCK = VariantMutator.UV_LOCK.withValue(true); + public static final VariantMutator X_ROT_90 = VariantMutator.X_ROT.withValue(Quadrant.R90); + public static final VariantMutator X_ROT_180 = VariantMutator.X_ROT.withValue(Quadrant.R180); + public static final VariantMutator X_ROT_270 = VariantMutator.X_ROT.withValue(Quadrant.R270); + public static final VariantMutator Y_ROT_90 = VariantMutator.Y_ROT.withValue(Quadrant.R90); + public static final VariantMutator Y_ROT_180 = VariantMutator.Y_ROT.withValue(Quadrant.R180); + public static final VariantMutator Y_ROT_270 = VariantMutator.Y_ROT.withValue(Quadrant.R270); + private static final Function FLOWER_BED_MODEL_1_SEGMENT_CONDITION = conditionBuilder -> conditionBuilder; + private static final Function FLOWER_BED_MODEL_2_SEGMENT_CONDITION = conditionBuilder -> conditionBuilder.term( + BlockStateProperties.FLOWER_AMOUNT, 2, 3, 4 + ); + private static final Function FLOWER_BED_MODEL_3_SEGMENT_CONDITION = conditionBuilder -> conditionBuilder.term( + BlockStateProperties.FLOWER_AMOUNT, 3, 4 + ); + private static final Function FLOWER_BED_MODEL_4_SEGMENT_CONDITION = conditionBuilder -> conditionBuilder.term( + BlockStateProperties.FLOWER_AMOUNT, 4 + ); + private static final Function LEAF_LITTER_MODEL_1_SEGMENT_CONDITION = conditionBuilder -> conditionBuilder.term( + BlockStateProperties.SEGMENT_AMOUNT, 1 + ); + private static final Function LEAF_LITTER_MODEL_2_SEGMENT_CONDITION = conditionBuilder -> conditionBuilder.term( + BlockStateProperties.SEGMENT_AMOUNT, 2, 3 + ); + private static final Function LEAF_LITTER_MODEL_3_SEGMENT_CONDITION = conditionBuilder -> conditionBuilder.term( + BlockStateProperties.SEGMENT_AMOUNT, 3 + ); + private static final Function LEAF_LITTER_MODEL_4_SEGMENT_CONDITION = conditionBuilder -> conditionBuilder.term( + BlockStateProperties.SEGMENT_AMOUNT, 4 + ); + static final Map FULL_BLOCK_MODEL_CUSTOM_GENERATORS = Map.of( + Blocks.STONE, + BlockModelGenerators::createMirroredCubeGenerator, + Blocks.DEEPSLATE, + BlockModelGenerators::createMirroredColumnGenerator, + Blocks.MUD_BRICKS, + BlockModelGenerators::createNorthWestMirroredCubeGenerator + ); + private static final PropertyDispatch ROTATION_FACING = PropertyDispatch.modify(BlockStateProperties.FACING) + .select(Direction.DOWN, X_ROT_90) + .select(Direction.UP, X_ROT_270) + .select(Direction.NORTH, NOP) + .select(Direction.SOUTH, Y_ROT_180) + .select(Direction.WEST, Y_ROT_270) + .select(Direction.EAST, Y_ROT_90); + private static final PropertyDispatch ROTATIONS_COLUMN_WITH_FACING = PropertyDispatch.modify(BlockStateProperties.FACING) + .select(Direction.DOWN, X_ROT_180) + .select(Direction.UP, NOP) + .select(Direction.NORTH, X_ROT_90) + .select(Direction.SOUTH, X_ROT_90.then(Y_ROT_180)) + .select(Direction.WEST, X_ROT_90.then(Y_ROT_270)) + .select(Direction.EAST, X_ROT_90.then(Y_ROT_90)); + private static final PropertyDispatch ROTATION_TORCH = PropertyDispatch.modify(BlockStateProperties.HORIZONTAL_FACING) + .select(Direction.EAST, NOP) + .select(Direction.SOUTH, Y_ROT_90) + .select(Direction.WEST, Y_ROT_180) + .select(Direction.NORTH, Y_ROT_270); + private static final PropertyDispatch ROTATION_HORIZONTAL_FACING_ALT = PropertyDispatch.modify(BlockStateProperties.HORIZONTAL_FACING) + .select(Direction.SOUTH, NOP) + .select(Direction.WEST, Y_ROT_90) + .select(Direction.NORTH, Y_ROT_180) + .select(Direction.EAST, Y_ROT_270); + private static final PropertyDispatch ROTATION_HORIZONTAL_FACING = PropertyDispatch.modify(BlockStateProperties.HORIZONTAL_FACING) + .select(Direction.EAST, Y_ROT_90) + .select(Direction.SOUTH, Y_ROT_180) + .select(Direction.WEST, Y_ROT_270) + .select(Direction.NORTH, NOP); + static final Map TEXTURED_MODELS = ImmutableMap.builder() .put(Blocks.SANDSTONE, TexturedModel.TOP_BOTTOM_WITH_WALL.get(Blocks.SANDSTONE)) .put(Blocks.RED_SANDSTONE, TexturedModel.TOP_BOTTOM_WITH_WALL.get(Blocks.RED_SANDSTONE)) .put(Blocks.SMOOTH_SANDSTONE, TexturedModel.createAllSame(TextureMapping.getBlockTexture(Blocks.SANDSTONE, "_top"))) @@ -146,85 +208,94 @@ public class BlockModelGenerators { .put(Blocks.CHISELED_TUFF_BRICKS, TexturedModel.COLUMN_WITH_WALL.get(Blocks.CHISELED_TUFF_BRICKS)) .put(Blocks.CHISELED_TUFF, TexturedModel.COLUMN_WITH_WALL.get(Blocks.CHISELED_TUFF)) .build(); - static final Map> SHAPE_CONSUMERS = ImmutableMap.>builder() - .put(net.minecraft.data.BlockFamily.Variant.BUTTON, BlockModelGenerators.BlockFamilyProvider::button) - .put(net.minecraft.data.BlockFamily.Variant.DOOR, BlockModelGenerators.BlockFamilyProvider::door) - .put(net.minecraft.data.BlockFamily.Variant.CHISELED, BlockModelGenerators.BlockFamilyProvider::fullBlockVariant) - .put(net.minecraft.data.BlockFamily.Variant.CRACKED, BlockModelGenerators.BlockFamilyProvider::fullBlockVariant) - .put(net.minecraft.data.BlockFamily.Variant.CUSTOM_FENCE, BlockModelGenerators.BlockFamilyProvider::customFence) - .put(net.minecraft.data.BlockFamily.Variant.FENCE, BlockModelGenerators.BlockFamilyProvider::fence) - .put(net.minecraft.data.BlockFamily.Variant.CUSTOM_FENCE_GATE, BlockModelGenerators.BlockFamilyProvider::customFenceGate) - .put(net.minecraft.data.BlockFamily.Variant.FENCE_GATE, BlockModelGenerators.BlockFamilyProvider::fenceGate) - .put(net.minecraft.data.BlockFamily.Variant.SIGN, BlockModelGenerators.BlockFamilyProvider::sign) - .put(net.minecraft.data.BlockFamily.Variant.SLAB, BlockModelGenerators.BlockFamilyProvider::slab) - .put(net.minecraft.data.BlockFamily.Variant.STAIRS, BlockModelGenerators.BlockFamilyProvider::stairs) - .put(net.minecraft.data.BlockFamily.Variant.PRESSURE_PLATE, BlockModelGenerators.BlockFamilyProvider::pressurePlate) - .put(net.minecraft.data.BlockFamily.Variant.TRAPDOOR, BlockModelGenerators.BlockFamilyProvider::trapdoor) - .put(net.minecraft.data.BlockFamily.Variant.WALL, BlockModelGenerators.BlockFamilyProvider::wall) + static final Map> SHAPE_CONSUMERS = ImmutableMap.>builder() + .put(Variant.BUTTON, BlockModelGenerators.BlockFamilyProvider::button) + .put(Variant.DOOR, BlockModelGenerators.BlockFamilyProvider::door) + .put(Variant.CHISELED, BlockModelGenerators.BlockFamilyProvider::fullBlockVariant) + .put(Variant.CRACKED, BlockModelGenerators.BlockFamilyProvider::fullBlockVariant) + .put(Variant.CUSTOM_FENCE, BlockModelGenerators.BlockFamilyProvider::customFence) + .put(Variant.FENCE, BlockModelGenerators.BlockFamilyProvider::fence) + .put(Variant.CUSTOM_FENCE_GATE, BlockModelGenerators.BlockFamilyProvider::customFenceGate) + .put(Variant.FENCE_GATE, BlockModelGenerators.BlockFamilyProvider::fenceGate) + .put(Variant.SIGN, BlockModelGenerators.BlockFamilyProvider::sign) + .put(Variant.SLAB, BlockModelGenerators.BlockFamilyProvider::slab) + .put(Variant.STAIRS, BlockModelGenerators.BlockFamilyProvider::stairs) + .put(Variant.PRESSURE_PLATE, BlockModelGenerators.BlockFamilyProvider::pressurePlate) + .put(Variant.TRAPDOOR, BlockModelGenerators.BlockFamilyProvider::trapdoor) + .put(Variant.WALL, BlockModelGenerators.BlockFamilyProvider::wall) .build(); - public static final List>> MULTIFACE_GENERATOR = List.of( - Pair.of(Direction.NORTH, resourceLocation -> Variant.variant().with(VariantProperties.MODEL, resourceLocation)), - Pair.of( - Direction.EAST, - resourceLocation -> Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ), - Pair.of( - Direction.SOUTH, - resourceLocation -> Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ), - Pair.of( - Direction.WEST, - resourceLocation -> Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ), - Pair.of( - Direction.UP, - resourceLocation -> Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ), - Pair.of( - Direction.DOWN, - resourceLocation -> Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) + private static final Map MULTIFACE_GENERATOR = ImmutableMap.of( + Direction.NORTH, + NOP, + Direction.EAST, + Y_ROT_90.then(UV_LOCK), + Direction.SOUTH, + Y_ROT_180.then(UV_LOCK), + Direction.WEST, + Y_ROT_270.then(UV_LOCK), + Direction.UP, + X_ROT_270.then(UV_LOCK), + Direction.DOWN, + X_ROT_90.then(UV_LOCK) ); private static final Map CHISELED_BOOKSHELF_SLOT_MODEL_CACHE = new HashMap(); - private static BlockStateGenerator createMirroredCubeGenerator( - Block cubeBlock, ResourceLocation location, TextureMapping textureMapping, BiConsumer modelOutput - ) { - ResourceLocation resourceLocation = ModelTemplates.CUBE_MIRRORED_ALL.create(cubeBlock, textureMapping, modelOutput); - return createRotatedVariant(cubeBlock, location, resourceLocation); + static net.minecraft.client.renderer.block.model.Variant plainModel(ResourceLocation modelLocation) { + return new net.minecraft.client.renderer.block.model.Variant(modelLocation); } - private static BlockStateGenerator createNorthWestMirroredCubeGenerator( - Block cubeBlock, ResourceLocation location, TextureMapping textureMapping, BiConsumer modelOutput - ) { - ResourceLocation resourceLocation = ModelTemplates.CUBE_NORTH_WEST_MIRRORED_ALL.create(cubeBlock, textureMapping, modelOutput); - return createSimpleBlock(cubeBlock, resourceLocation); + static MultiVariant variant(net.minecraft.client.renderer.block.model.Variant variant) { + return new MultiVariant(WeightedList.of(variant)); } - private static BlockStateGenerator createMirroredColumnGenerator( - Block columnBlock, ResourceLocation location, TextureMapping textureMapping, BiConsumer modelOutput + private static MultiVariant variants(net.minecraft.client.renderer.block.model.Variant... variants) { + return new MultiVariant(WeightedList.of(Arrays.stream(variants).map(variant -> new Weighted<>(variant, 1)).toList())); + } + + static MultiVariant plainVariant(ResourceLocation id) { + return variant(plainModel(id)); + } + + private static ConditionBuilder condition() { + return new ConditionBuilder(); + } + + private static Condition or(ConditionBuilder... condition) { + return new CombinedCondition(CombinedCondition.Operation.OR, Stream.of(condition).map(ConditionBuilder::build).toList()); + } + + private static BlockModelDefinitionGenerator createMirroredCubeGenerator( + Block block, + net.minecraft.client.renderer.block.model.Variant variant, + TextureMapping textureMapping, + BiConsumer modelOutput ) { - ResourceLocation resourceLocation = ModelTemplates.CUBE_COLUMN_MIRRORED.create(columnBlock, textureMapping, modelOutput); - return createRotatedVariant(columnBlock, location, resourceLocation).with(createRotatedPillar()); + net.minecraft.client.renderer.block.model.Variant variant2 = plainModel(ModelTemplates.CUBE_MIRRORED_ALL.create(block, textureMapping, modelOutput)); + return MultiVariantGenerator.dispatch(block, createRotatedVariants(variant, variant2)); + } + + private static BlockModelDefinitionGenerator createNorthWestMirroredCubeGenerator( + Block block, + net.minecraft.client.renderer.block.model.Variant variant, + TextureMapping textureMapping, + BiConsumer modelOutput + ) { + MultiVariant multiVariant = plainVariant(ModelTemplates.CUBE_NORTH_WEST_MIRRORED_ALL.create(block, textureMapping, modelOutput)); + return createSimpleBlock(block, multiVariant); + } + + private static BlockModelDefinitionGenerator createMirroredColumnGenerator( + Block block, + net.minecraft.client.renderer.block.model.Variant variant, + TextureMapping textureMapping, + BiConsumer modelOutput + ) { + net.minecraft.client.renderer.block.model.Variant variant2 = plainModel(ModelTemplates.CUBE_COLUMN_MIRRORED.create(block, textureMapping, modelOutput)); + return MultiVariantGenerator.dispatch(block, createRotatedVariants(variant, variant2)).with(createRotatedPillar()); } public BlockModelGenerators( - Consumer blockStateOutput, ItemModelOutput itemModelOutput, BiConsumer modelOutput + Consumer blockStateOutput, ItemModelOutput itemModelOutput, BiConsumer modelOutput ) { this.blockStateOutput = blockStateOutput; this.itemModelOutput = itemModelOutput; @@ -289,95 +360,44 @@ public class BlockModelGenerators { } } - private static PropertyDispatch createHorizontalFacingDispatch() { - return PropertyDispatch.property(BlockStateProperties.HORIZONTAL_FACING) - .select(Direction.EAST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select(Direction.SOUTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) - .select(Direction.WEST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)) - .select(Direction.NORTH, Variant.variant()); + private static MultiVariant createRotatedVariants(net.minecraft.client.renderer.block.model.Variant variant) { + return variants(variant, variant.with(Y_ROT_90), variant.with(Y_ROT_180), variant.with(Y_ROT_270)); } - private static PropertyDispatch createHorizontalFacingDispatchAlt() { - return PropertyDispatch.property(BlockStateProperties.HORIZONTAL_FACING) - .select(Direction.SOUTH, Variant.variant()) - .select(Direction.WEST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select(Direction.NORTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) - .select(Direction.EAST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)); + private static MultiVariant createRotatedVariants( + net.minecraft.client.renderer.block.model.Variant variant, net.minecraft.client.renderer.block.model.Variant mirroredVariant + ) { + return variants(variant, mirroredVariant, variant.with(Y_ROT_180), mirroredVariant.with(Y_ROT_180)); } - private static PropertyDispatch createTorchHorizontalDispatch() { - return PropertyDispatch.property(BlockStateProperties.HORIZONTAL_FACING) - .select(Direction.EAST, Variant.variant()) - .select(Direction.SOUTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select(Direction.WEST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) - .select(Direction.NORTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)); - } - - private static PropertyDispatch createFacingDispatch() { - return PropertyDispatch.property(BlockStateProperties.FACING) - .select(Direction.DOWN, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90)) - .select(Direction.UP, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R270)) - .select(Direction.NORTH, Variant.variant()) - .select(Direction.SOUTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) - .select(Direction.WEST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)) - .select(Direction.EAST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)); - } - - private static MultiVariantGenerator createRotatedVariant(Block block, ResourceLocation model) { - return MultiVariantGenerator.multiVariant(block, createRotatedVariants(model)); - } - - private static Variant[] createRotatedVariants(ResourceLocation modelLocation) { - return new Variant[]{ - Variant.variant().with(VariantProperties.MODEL, modelLocation), - Variant.variant().with(VariantProperties.MODEL, modelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90), - Variant.variant().with(VariantProperties.MODEL, modelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180), - Variant.variant().with(VariantProperties.MODEL, modelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - }; - } - - private static MultiVariantGenerator createRotatedVariant(Block block, ResourceLocation model1, ResourceLocation model2) { - return MultiVariantGenerator.multiVariant( - block, - Variant.variant().with(VariantProperties.MODEL, model1), - Variant.variant().with(VariantProperties.MODEL, model2), - Variant.variant().with(VariantProperties.MODEL, model1).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180), - Variant.variant().with(VariantProperties.MODEL, model2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ); - } - - private static PropertyDispatch createBooleanModelDispatch(BooleanProperty property, ResourceLocation trueModelLocation, ResourceLocation falseModelLocation) { - return PropertyDispatch.property(property) - .select(true, Variant.variant().with(VariantProperties.MODEL, trueModelLocation)) - .select(false, Variant.variant().with(VariantProperties.MODEL, falseModelLocation)); + private static PropertyDispatch createBooleanModelDispatch(BooleanProperty property, MultiVariant onTrue, MultiVariant onFalse) { + return PropertyDispatch.initial(property).select(true, onTrue).select(false, onFalse); } private void createRotatedMirroredVariantBlock(Block block) { - ResourceLocation resourceLocation = TexturedModel.CUBE.create(block, this.modelOutput); - ResourceLocation resourceLocation2 = TexturedModel.CUBE_MIRRORED.create(block, this.modelOutput); - this.blockStateOutput.accept(createRotatedVariant(block, resourceLocation, resourceLocation2)); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(TexturedModel.CUBE.create(block, this.modelOutput)); + net.minecraft.client.renderer.block.model.Variant variant2 = plainModel(TexturedModel.CUBE_MIRRORED.create(block, this.modelOutput)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, createRotatedVariants(variant, variant2))); } private void createRotatedVariantBlock(Block block) { - ResourceLocation resourceLocation = TexturedModel.CUBE.create(block, this.modelOutput); - this.blockStateOutput.accept(createRotatedVariant(block, resourceLocation)); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(TexturedModel.CUBE.create(block, this.modelOutput)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, createRotatedVariants(variant))); } private void createBrushableBlock(Block block) { this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(block) + MultiVariantGenerator.dispatch(block) .with( - PropertyDispatch.property(BlockStateProperties.DUSTED) + PropertyDispatch.initial(BlockStateProperties.DUSTED) .generate( integer -> { String string = "_" + integer; ResourceLocation resourceLocation = TextureMapping.getBlockTexture(block, string); - return Variant.variant() - .with( - VariantProperties.MODEL, - ModelTemplates.CUBE_ALL.createWithSuffix(block, string, new TextureMapping().put(TextureSlot.ALL, resourceLocation), this.modelOutput) - ); + ResourceLocation resourceLocation2 = ModelTemplates.CUBE_ALL + .createWithSuffix(block, string, new TextureMapping().put(TextureSlot.ALL, resourceLocation), this.modelOutput); + return plainVariant(resourceLocation2); } ) ) @@ -385,945 +405,313 @@ public class BlockModelGenerators { this.registerSimpleItemModel(block, ModelLocationUtils.getModelLocation(block, "_0")); } - static BlockStateGenerator createButton(Block buttonBlock, ResourceLocation unpoweredModelLocation, ResourceLocation poweredModelLocation) { - return MultiVariantGenerator.multiVariant(buttonBlock) + static BlockModelDefinitionGenerator createButton(Block block, MultiVariant unpowered, MultiVariant powered) { + return MultiVariantGenerator.dispatch(block) + .with(PropertyDispatch.initial(BlockStateProperties.POWERED).select(false, unpowered).select(true, powered)) .with( - PropertyDispatch.property(BlockStateProperties.POWERED) - .select(false, Variant.variant().with(VariantProperties.MODEL, unpoweredModelLocation)) - .select(true, Variant.variant().with(VariantProperties.MODEL, poweredModelLocation)) - ) - .with( - PropertyDispatch.properties(BlockStateProperties.ATTACH_FACE, BlockStateProperties.HORIZONTAL_FACING) - .select(AttachFace.FLOOR, Direction.EAST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select(AttachFace.FLOOR, Direction.WEST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)) - .select(AttachFace.FLOOR, Direction.SOUTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) - .select(AttachFace.FLOOR, Direction.NORTH, Variant.variant()) - .select( - AttachFace.WALL, - Direction.EAST, - Variant.variant() - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - AttachFace.WALL, - Direction.WEST, - Variant.variant() - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - AttachFace.WALL, - Direction.SOUTH, - Variant.variant() - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - AttachFace.WALL, Direction.NORTH, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.UV_LOCK, true) - ) - .select( - AttachFace.CEILING, - Direction.EAST, - Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270).with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - ) - .select( - AttachFace.CEILING, - Direction.WEST, - Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90).with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - ) - .select(AttachFace.CEILING, Direction.SOUTH, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180)) - .select( - AttachFace.CEILING, - Direction.NORTH, - Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180).with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - ) + PropertyDispatch.modify(BlockStateProperties.ATTACH_FACE, BlockStateProperties.HORIZONTAL_FACING) + .select(AttachFace.FLOOR, Direction.EAST, Y_ROT_90) + .select(AttachFace.FLOOR, Direction.WEST, Y_ROT_270) + .select(AttachFace.FLOOR, Direction.SOUTH, Y_ROT_180) + .select(AttachFace.FLOOR, Direction.NORTH, NOP) + .select(AttachFace.WALL, Direction.EAST, Y_ROT_90.then(X_ROT_90).then(UV_LOCK)) + .select(AttachFace.WALL, Direction.WEST, Y_ROT_270.then(X_ROT_90).then(UV_LOCK)) + .select(AttachFace.WALL, Direction.SOUTH, Y_ROT_180.then(X_ROT_90).then(UV_LOCK)) + .select(AttachFace.WALL, Direction.NORTH, X_ROT_90.then(UV_LOCK)) + .select(AttachFace.CEILING, Direction.EAST, Y_ROT_270.then(X_ROT_180)) + .select(AttachFace.CEILING, Direction.WEST, Y_ROT_90.then(X_ROT_180)) + .select(AttachFace.CEILING, Direction.SOUTH, X_ROT_180) + .select(AttachFace.CEILING, Direction.NORTH, Y_ROT_180.then(X_ROT_180)) ); } - private static PropertyDispatch.C4 configureDoorHalf( - PropertyDispatch.C4 properties, - DoubleBlockHalf half, - ResourceLocation leftModelLocation, - ResourceLocation leftOpenModelLocation, - ResourceLocation rightModelLocation, - ResourceLocation rightOpenModelLocation + private static BlockModelDefinitionGenerator createDoor( + Block block, + MultiVariant topLeft, + MultiVariant topLeftOpen, + MultiVariant topRight, + MultiVariant topRightOpen, + MultiVariant bottomLeft, + MultiVariant bottomLeftOpen, + MultiVariant bottomRight, + MultiVariant bottomRightOpen ) { - return properties.select(Direction.EAST, half, DoorHingeSide.LEFT, false, Variant.variant().with(VariantProperties.MODEL, leftModelLocation)) - .select( - Direction.SOUTH, - half, - DoorHingeSide.LEFT, - false, - Variant.variant().with(VariantProperties.MODEL, leftModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - half, - DoorHingeSide.LEFT, - false, - Variant.variant().with(VariantProperties.MODEL, leftModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.NORTH, - half, - DoorHingeSide.LEFT, - false, - Variant.variant().with(VariantProperties.MODEL, leftModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(Direction.EAST, half, DoorHingeSide.RIGHT, false, Variant.variant().with(VariantProperties.MODEL, rightModelLocation)) - .select( - Direction.SOUTH, - half, - DoorHingeSide.RIGHT, - false, - Variant.variant().with(VariantProperties.MODEL, rightModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - half, - DoorHingeSide.RIGHT, - false, - Variant.variant().with(VariantProperties.MODEL, rightModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.NORTH, - half, - DoorHingeSide.RIGHT, - false, - Variant.variant().with(VariantProperties.MODEL, rightModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - Direction.EAST, - half, - DoorHingeSide.LEFT, - true, - Variant.variant().with(VariantProperties.MODEL, leftOpenModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.SOUTH, - half, - DoorHingeSide.LEFT, - true, - Variant.variant().with(VariantProperties.MODEL, leftOpenModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.WEST, - half, - DoorHingeSide.LEFT, - true, - Variant.variant().with(VariantProperties.MODEL, leftOpenModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(Direction.NORTH, half, DoorHingeSide.LEFT, true, Variant.variant().with(VariantProperties.MODEL, leftOpenModelLocation)) - .select( - Direction.EAST, - half, - DoorHingeSide.RIGHT, - true, - Variant.variant().with(VariantProperties.MODEL, rightOpenModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(Direction.SOUTH, half, DoorHingeSide.RIGHT, true, Variant.variant().with(VariantProperties.MODEL, rightOpenModelLocation)) - .select( - Direction.WEST, - half, - DoorHingeSide.RIGHT, - true, - Variant.variant().with(VariantProperties.MODEL, rightOpenModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.NORTH, - half, - DoorHingeSide.RIGHT, - true, - Variant.variant().with(VariantProperties.MODEL, rightOpenModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) + return MultiVariantGenerator.dispatch(block) + .with( + PropertyDispatch.initial( + BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.DOUBLE_BLOCK_HALF, BlockStateProperties.DOOR_HINGE, BlockStateProperties.OPEN + ) + .select(Direction.EAST, DoubleBlockHalf.LOWER, DoorHingeSide.LEFT, false, topLeft) + .select(Direction.SOUTH, DoubleBlockHalf.LOWER, DoorHingeSide.LEFT, false, topLeft.with(Y_ROT_90)) + .select(Direction.WEST, DoubleBlockHalf.LOWER, DoorHingeSide.LEFT, false, topLeft.with(Y_ROT_180)) + .select(Direction.NORTH, DoubleBlockHalf.LOWER, DoorHingeSide.LEFT, false, topLeft.with(Y_ROT_270)) + .select(Direction.EAST, DoubleBlockHalf.LOWER, DoorHingeSide.RIGHT, false, topRight) + .select(Direction.SOUTH, DoubleBlockHalf.LOWER, DoorHingeSide.RIGHT, false, topRight.with(Y_ROT_90)) + .select(Direction.WEST, DoubleBlockHalf.LOWER, DoorHingeSide.RIGHT, false, topRight.with(Y_ROT_180)) + .select(Direction.NORTH, DoubleBlockHalf.LOWER, DoorHingeSide.RIGHT, false, topRight.with(Y_ROT_270)) + .select(Direction.EAST, DoubleBlockHalf.LOWER, DoorHingeSide.LEFT, true, topLeftOpen.with(Y_ROT_90)) + .select(Direction.SOUTH, DoubleBlockHalf.LOWER, DoorHingeSide.LEFT, true, topLeftOpen.with(Y_ROT_180)) + .select(Direction.WEST, DoubleBlockHalf.LOWER, DoorHingeSide.LEFT, true, topLeftOpen.with(Y_ROT_270)) + .select(Direction.NORTH, DoubleBlockHalf.LOWER, DoorHingeSide.LEFT, true, topLeftOpen) + .select(Direction.EAST, DoubleBlockHalf.LOWER, DoorHingeSide.RIGHT, true, topRightOpen.with(Y_ROT_270)) + .select(Direction.SOUTH, DoubleBlockHalf.LOWER, DoorHingeSide.RIGHT, true, topRightOpen) + .select(Direction.WEST, DoubleBlockHalf.LOWER, DoorHingeSide.RIGHT, true, topRightOpen.with(Y_ROT_90)) + .select(Direction.NORTH, DoubleBlockHalf.LOWER, DoorHingeSide.RIGHT, true, topRightOpen.with(Y_ROT_180)) + .select(Direction.EAST, DoubleBlockHalf.UPPER, DoorHingeSide.LEFT, false, bottomLeft) + .select(Direction.SOUTH, DoubleBlockHalf.UPPER, DoorHingeSide.LEFT, false, bottomLeft.with(Y_ROT_90)) + .select(Direction.WEST, DoubleBlockHalf.UPPER, DoorHingeSide.LEFT, false, bottomLeft.with(Y_ROT_180)) + .select(Direction.NORTH, DoubleBlockHalf.UPPER, DoorHingeSide.LEFT, false, bottomLeft.with(Y_ROT_270)) + .select(Direction.EAST, DoubleBlockHalf.UPPER, DoorHingeSide.RIGHT, false, bottomRight) + .select(Direction.SOUTH, DoubleBlockHalf.UPPER, DoorHingeSide.RIGHT, false, bottomRight.with(Y_ROT_90)) + .select(Direction.WEST, DoubleBlockHalf.UPPER, DoorHingeSide.RIGHT, false, bottomRight.with(Y_ROT_180)) + .select(Direction.NORTH, DoubleBlockHalf.UPPER, DoorHingeSide.RIGHT, false, bottomRight.with(Y_ROT_270)) + .select(Direction.EAST, DoubleBlockHalf.UPPER, DoorHingeSide.LEFT, true, bottomLeftOpen.with(Y_ROT_90)) + .select(Direction.SOUTH, DoubleBlockHalf.UPPER, DoorHingeSide.LEFT, true, bottomLeftOpen.with(Y_ROT_180)) + .select(Direction.WEST, DoubleBlockHalf.UPPER, DoorHingeSide.LEFT, true, bottomLeftOpen.with(Y_ROT_270)) + .select(Direction.NORTH, DoubleBlockHalf.UPPER, DoorHingeSide.LEFT, true, bottomLeftOpen) + .select(Direction.EAST, DoubleBlockHalf.UPPER, DoorHingeSide.RIGHT, true, bottomRightOpen.with(Y_ROT_270)) + .select(Direction.SOUTH, DoubleBlockHalf.UPPER, DoorHingeSide.RIGHT, true, bottomRightOpen) + .select(Direction.WEST, DoubleBlockHalf.UPPER, DoorHingeSide.RIGHT, true, bottomRightOpen.with(Y_ROT_90)) + .select(Direction.NORTH, DoubleBlockHalf.UPPER, DoorHingeSide.RIGHT, true, bottomRightOpen.with(Y_ROT_180)) ); } - private static BlockStateGenerator createDoor( - Block doorBlock, - ResourceLocation topLeftModelLocation, - ResourceLocation topLeftOpenModelLocation, - ResourceLocation topRightModelLocation, - ResourceLocation topRightOpenModelLocation, - ResourceLocation bottomLeftModelLocation, - ResourceLocation bottomLeftOpenModelLocation, - ResourceLocation bottomRightModelLocation, - ResourceLocation bottomRightOpenModelLocation + static BlockModelDefinitionGenerator createCustomFence( + Block block, MultiVariant post, MultiVariant north, MultiVariant east, MultiVariant south, MultiVariant west ) { - return MultiVariantGenerator.multiVariant(doorBlock) - .with( - configureDoorHalf( - configureDoorHalf( - PropertyDispatch.properties( - BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.DOUBLE_BLOCK_HALF, BlockStateProperties.DOOR_HINGE, BlockStateProperties.OPEN - ), - DoubleBlockHalf.LOWER, - topLeftModelLocation, - topLeftOpenModelLocation, - topRightModelLocation, - topRightOpenModelLocation - ), - DoubleBlockHalf.UPPER, - bottomLeftModelLocation, - bottomLeftOpenModelLocation, - bottomRightModelLocation, - bottomRightOpenModelLocation - ) - ); + return MultiPartGenerator.multiPart(block) + .with(post) + .with(condition().term(BlockStateProperties.NORTH, true), north) + .with(condition().term(BlockStateProperties.EAST, true), east) + .with(condition().term(BlockStateProperties.SOUTH, true), south) + .with(condition().term(BlockStateProperties.WEST, true), west); } - static BlockStateGenerator createCustomFence( - Block customFenceBlock, - ResourceLocation postModelId, - ResourceLocation northModelId, - ResourceLocation eastModelId, - ResourceLocation southModelId, - ResourceLocation westModelId + static BlockModelDefinitionGenerator createFence(Block block, MultiVariant post, MultiVariant side) { + return MultiPartGenerator.multiPart(block) + .with(post) + .with(condition().term(BlockStateProperties.NORTH, true), side.with(UV_LOCK)) + .with(condition().term(BlockStateProperties.EAST, true), side.with(Y_ROT_90).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.SOUTH, true), side.with(Y_ROT_180).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.WEST, true), side.with(Y_ROT_270).with(UV_LOCK)); + } + + static BlockModelDefinitionGenerator createWall(Block block, MultiVariant post, MultiVariant lowSide, MultiVariant tallSide) { + return MultiPartGenerator.multiPart(block) + .with(condition().term(BlockStateProperties.UP, true), post) + .with(condition().term(BlockStateProperties.NORTH_WALL, WallSide.LOW), lowSide.with(UV_LOCK)) + .with(condition().term(BlockStateProperties.EAST_WALL, WallSide.LOW), lowSide.with(Y_ROT_90).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.SOUTH_WALL, WallSide.LOW), lowSide.with(Y_ROT_180).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.WEST_WALL, WallSide.LOW), lowSide.with(Y_ROT_270).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.NORTH_WALL, WallSide.TALL), tallSide.with(UV_LOCK)) + .with(condition().term(BlockStateProperties.EAST_WALL, WallSide.TALL), tallSide.with(Y_ROT_90).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.SOUTH_WALL, WallSide.TALL), tallSide.with(Y_ROT_180).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.WEST_WALL, WallSide.TALL), tallSide.with(Y_ROT_270).with(UV_LOCK)); + } + + static BlockModelDefinitionGenerator createFenceGate( + Block block, MultiVariant open, MultiVariant closed, MultiVariant wallOpen, MultiVariant wallClosed, boolean uvLock ) { - return MultiPartGenerator.multiPart(customFenceBlock) - .with(Variant.variant().with(VariantProperties.MODEL, postModelId)) + return MultiVariantGenerator.dispatch(block) .with( - Condition.condition().term(BlockStateProperties.NORTH, true), - Variant.variant().with(VariantProperties.MODEL, northModelId).with(VariantProperties.UV_LOCK, false) + PropertyDispatch.initial(BlockStateProperties.IN_WALL, BlockStateProperties.OPEN) + .select(false, false, closed) + .select(true, false, wallClosed) + .select(false, true, open) + .select(true, true, wallOpen) ) + .with(uvLock ? UV_LOCK : NOP) + .with(ROTATION_HORIZONTAL_FACING_ALT); + } + + static BlockModelDefinitionGenerator createStairs(Block block, MultiVariant inner, MultiVariant straight, MultiVariant outer) { + return MultiVariantGenerator.dispatch(block) .with( - Condition.condition().term(BlockStateProperties.EAST, true), - Variant.variant().with(VariantProperties.MODEL, eastModelId).with(VariantProperties.UV_LOCK, false) - ) - .with( - Condition.condition().term(BlockStateProperties.SOUTH, true), - Variant.variant().with(VariantProperties.MODEL, southModelId).with(VariantProperties.UV_LOCK, false) - ) - .with( - Condition.condition().term(BlockStateProperties.WEST, true), - Variant.variant().with(VariantProperties.MODEL, westModelId).with(VariantProperties.UV_LOCK, false) + PropertyDispatch.initial(BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.HALF, BlockStateProperties.STAIRS_SHAPE) + .select(Direction.EAST, Half.BOTTOM, StairsShape.STRAIGHT, straight) + .select(Direction.WEST, Half.BOTTOM, StairsShape.STRAIGHT, straight.with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.SOUTH, Half.BOTTOM, StairsShape.STRAIGHT, straight.with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.NORTH, Half.BOTTOM, StairsShape.STRAIGHT, straight.with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.EAST, Half.BOTTOM, StairsShape.OUTER_RIGHT, outer) + .select(Direction.WEST, Half.BOTTOM, StairsShape.OUTER_RIGHT, outer.with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.SOUTH, Half.BOTTOM, StairsShape.OUTER_RIGHT, outer.with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.NORTH, Half.BOTTOM, StairsShape.OUTER_RIGHT, outer.with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.EAST, Half.BOTTOM, StairsShape.OUTER_LEFT, outer.with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.WEST, Half.BOTTOM, StairsShape.OUTER_LEFT, outer.with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.SOUTH, Half.BOTTOM, StairsShape.OUTER_LEFT, outer) + .select(Direction.NORTH, Half.BOTTOM, StairsShape.OUTER_LEFT, outer.with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.EAST, Half.BOTTOM, StairsShape.INNER_RIGHT, inner) + .select(Direction.WEST, Half.BOTTOM, StairsShape.INNER_RIGHT, inner.with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.SOUTH, Half.BOTTOM, StairsShape.INNER_RIGHT, inner.with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.NORTH, Half.BOTTOM, StairsShape.INNER_RIGHT, inner.with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.EAST, Half.BOTTOM, StairsShape.INNER_LEFT, inner.with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.WEST, Half.BOTTOM, StairsShape.INNER_LEFT, inner.with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.SOUTH, Half.BOTTOM, StairsShape.INNER_LEFT, inner) + .select(Direction.NORTH, Half.BOTTOM, StairsShape.INNER_LEFT, inner.with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.EAST, Half.TOP, StairsShape.STRAIGHT, straight.with(X_ROT_180).with(UV_LOCK)) + .select(Direction.WEST, Half.TOP, StairsShape.STRAIGHT, straight.with(X_ROT_180).with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.SOUTH, Half.TOP, StairsShape.STRAIGHT, straight.with(X_ROT_180).with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.NORTH, Half.TOP, StairsShape.STRAIGHT, straight.with(X_ROT_180).with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.EAST, Half.TOP, StairsShape.OUTER_RIGHT, outer.with(X_ROT_180).with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.WEST, Half.TOP, StairsShape.OUTER_RIGHT, outer.with(X_ROT_180).with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.SOUTH, Half.TOP, StairsShape.OUTER_RIGHT, outer.with(X_ROT_180).with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.NORTH, Half.TOP, StairsShape.OUTER_RIGHT, outer.with(X_ROT_180).with(UV_LOCK)) + .select(Direction.EAST, Half.TOP, StairsShape.OUTER_LEFT, outer.with(X_ROT_180).with(UV_LOCK)) + .select(Direction.WEST, Half.TOP, StairsShape.OUTER_LEFT, outer.with(X_ROT_180).with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.SOUTH, Half.TOP, StairsShape.OUTER_LEFT, outer.with(X_ROT_180).with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.NORTH, Half.TOP, StairsShape.OUTER_LEFT, outer.with(X_ROT_180).with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.EAST, Half.TOP, StairsShape.INNER_RIGHT, inner.with(X_ROT_180).with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.WEST, Half.TOP, StairsShape.INNER_RIGHT, inner.with(X_ROT_180).with(Y_ROT_270).with(UV_LOCK)) + .select(Direction.SOUTH, Half.TOP, StairsShape.INNER_RIGHT, inner.with(X_ROT_180).with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.NORTH, Half.TOP, StairsShape.INNER_RIGHT, inner.with(X_ROT_180).with(UV_LOCK)) + .select(Direction.EAST, Half.TOP, StairsShape.INNER_LEFT, inner.with(X_ROT_180).with(UV_LOCK)) + .select(Direction.WEST, Half.TOP, StairsShape.INNER_LEFT, inner.with(X_ROT_180).with(Y_ROT_180).with(UV_LOCK)) + .select(Direction.SOUTH, Half.TOP, StairsShape.INNER_LEFT, inner.with(X_ROT_180).with(Y_ROT_90).with(UV_LOCK)) + .select(Direction.NORTH, Half.TOP, StairsShape.INNER_LEFT, inner.with(X_ROT_180).with(Y_ROT_270).with(UV_LOCK)) ); } - static BlockStateGenerator createFence(Block fenceBlock, ResourceLocation fencePostModelLocation, ResourceLocation fenceSideModelLocation) { - return MultiPartGenerator.multiPart(fenceBlock) - .with(Variant.variant().with(VariantProperties.MODEL, fencePostModelLocation)) + private static BlockModelDefinitionGenerator createOrientableTrapdoor(Block block, MultiVariant top, MultiVariant bottom, MultiVariant open) { + return MultiVariantGenerator.dispatch(block) .with( - Condition.condition().term(BlockStateProperties.NORTH, true), - Variant.variant().with(VariantProperties.MODEL, fenceSideModelLocation).with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.EAST, true), - Variant.variant() - .with(VariantProperties.MODEL, fenceSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.SOUTH, true), - Variant.variant() - .with(VariantProperties.MODEL, fenceSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.WEST, true), - Variant.variant() - .with(VariantProperties.MODEL, fenceSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) + PropertyDispatch.initial(BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.HALF, BlockStateProperties.OPEN) + .select(Direction.NORTH, Half.BOTTOM, false, bottom) + .select(Direction.SOUTH, Half.BOTTOM, false, bottom.with(Y_ROT_180)) + .select(Direction.EAST, Half.BOTTOM, false, bottom.with(Y_ROT_90)) + .select(Direction.WEST, Half.BOTTOM, false, bottom.with(Y_ROT_270)) + .select(Direction.NORTH, Half.TOP, false, top) + .select(Direction.SOUTH, Half.TOP, false, top.with(Y_ROT_180)) + .select(Direction.EAST, Half.TOP, false, top.with(Y_ROT_90)) + .select(Direction.WEST, Half.TOP, false, top.with(Y_ROT_270)) + .select(Direction.NORTH, Half.BOTTOM, true, open) + .select(Direction.SOUTH, Half.BOTTOM, true, open.with(Y_ROT_180)) + .select(Direction.EAST, Half.BOTTOM, true, open.with(Y_ROT_90)) + .select(Direction.WEST, Half.BOTTOM, true, open.with(Y_ROT_270)) + .select(Direction.NORTH, Half.TOP, true, open.with(X_ROT_180).with(Y_ROT_180)) + .select(Direction.SOUTH, Half.TOP, true, open.with(X_ROT_180)) + .select(Direction.EAST, Half.TOP, true, open.with(X_ROT_180).with(Y_ROT_270)) + .select(Direction.WEST, Half.TOP, true, open.with(X_ROT_180).with(Y_ROT_90)) ); } - static BlockStateGenerator createWall( - Block wallBlock, ResourceLocation postModelLocation, ResourceLocation lowSideModelLocation, ResourceLocation tallSideModelLocation + private static BlockModelDefinitionGenerator createTrapdoor(Block block, MultiVariant top, MultiVariant bottom, MultiVariant open) { + return MultiVariantGenerator.dispatch(block) + .with( + PropertyDispatch.initial(BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.HALF, BlockStateProperties.OPEN) + .select(Direction.NORTH, Half.BOTTOM, false, bottom) + .select(Direction.SOUTH, Half.BOTTOM, false, bottom) + .select(Direction.EAST, Half.BOTTOM, false, bottom) + .select(Direction.WEST, Half.BOTTOM, false, bottom) + .select(Direction.NORTH, Half.TOP, false, top) + .select(Direction.SOUTH, Half.TOP, false, top) + .select(Direction.EAST, Half.TOP, false, top) + .select(Direction.WEST, Half.TOP, false, top) + .select(Direction.NORTH, Half.BOTTOM, true, open) + .select(Direction.SOUTH, Half.BOTTOM, true, open.with(Y_ROT_180)) + .select(Direction.EAST, Half.BOTTOM, true, open.with(Y_ROT_90)) + .select(Direction.WEST, Half.BOTTOM, true, open.with(Y_ROT_270)) + .select(Direction.NORTH, Half.TOP, true, open) + .select(Direction.SOUTH, Half.TOP, true, open.with(Y_ROT_180)) + .select(Direction.EAST, Half.TOP, true, open.with(Y_ROT_90)) + .select(Direction.WEST, Half.TOP, true, open.with(Y_ROT_270)) + ); + } + + static MultiVariantGenerator createSimpleBlock(Block block, MultiVariant variants) { + return MultiVariantGenerator.dispatch(block, variants); + } + + private static PropertyDispatch createRotatedPillar() { + return PropertyDispatch.modify(BlockStateProperties.AXIS) + .select(Direction.Axis.Y, NOP) + .select(Direction.Axis.Z, X_ROT_90) + .select(Direction.Axis.X, X_ROT_90.then(Y_ROT_90)); + } + + static BlockModelDefinitionGenerator createPillarBlockUVLocked( + Block block, TextureMapping textureMapping, BiConsumer modelOutput ) { - return MultiPartGenerator.multiPart(wallBlock) - .with(Condition.condition().term(BlockStateProperties.UP, true), Variant.variant().with(VariantProperties.MODEL, postModelLocation)) + MultiVariant multiVariant = plainVariant(ModelTemplates.CUBE_COLUMN_UV_LOCKED_X.create(block, textureMapping, modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.CUBE_COLUMN_UV_LOCKED_Y.create(block, textureMapping, modelOutput)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.CUBE_COLUMN_UV_LOCKED_Z.create(block, textureMapping, modelOutput)); + return MultiVariantGenerator.dispatch(block) .with( - Condition.condition().term(BlockStateProperties.NORTH_WALL, WallSide.LOW), - Variant.variant().with(VariantProperties.MODEL, lowSideModelLocation).with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.EAST_WALL, WallSide.LOW), - Variant.variant() - .with(VariantProperties.MODEL, lowSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.SOUTH_WALL, WallSide.LOW), - Variant.variant() - .with(VariantProperties.MODEL, lowSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.WEST_WALL, WallSide.LOW), - Variant.variant() - .with(VariantProperties.MODEL, lowSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.NORTH_WALL, WallSide.TALL), - Variant.variant().with(VariantProperties.MODEL, tallSideModelLocation).with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.EAST_WALL, WallSide.TALL), - Variant.variant() - .with(VariantProperties.MODEL, tallSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.SOUTH_WALL, WallSide.TALL), - Variant.variant() - .with(VariantProperties.MODEL, tallSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.WEST_WALL, WallSide.TALL), - Variant.variant() - .with(VariantProperties.MODEL, tallSideModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) + PropertyDispatch.initial(BlockStateProperties.AXIS) + .select(Direction.Axis.X, multiVariant) + .select(Direction.Axis.Y, multiVariant2) + .select(Direction.Axis.Z, multiVariant3) ); } - static BlockStateGenerator createFenceGate( - Block fenceGateBlock, - ResourceLocation openModelLocation, - ResourceLocation closedModelLocation, - ResourceLocation wallOpenModelLocation, - ResourceLocation wallClosedModelLocation, - boolean uvLock - ) { - return MultiVariantGenerator.multiVariant(fenceGateBlock, Variant.variant().with(VariantProperties.UV_LOCK, uvLock)) - .with(createHorizontalFacingDispatchAlt()) - .with( - PropertyDispatch.properties(BlockStateProperties.IN_WALL, BlockStateProperties.OPEN) - .select(false, false, Variant.variant().with(VariantProperties.MODEL, closedModelLocation)) - .select(true, false, Variant.variant().with(VariantProperties.MODEL, wallClosedModelLocation)) - .select(false, true, Variant.variant().with(VariantProperties.MODEL, openModelLocation)) - .select(true, true, Variant.variant().with(VariantProperties.MODEL, wallOpenModelLocation)) - ); + static BlockModelDefinitionGenerator createAxisAlignedPillarBlock(Block block, MultiVariant variants) { + return MultiVariantGenerator.dispatch(block, variants).with(createRotatedPillar()); } - static BlockStateGenerator createStairs( - Block stairsBlock, ResourceLocation innerModelLocation, ResourceLocation straightModelLocation, ResourceLocation outerModelLocation - ) { - return MultiVariantGenerator.multiVariant(stairsBlock) - .with( - PropertyDispatch.properties(BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.HALF, BlockStateProperties.STAIRS_SHAPE) - .select(Direction.EAST, Half.BOTTOM, StairsShape.STRAIGHT, Variant.variant().with(VariantProperties.MODEL, straightModelLocation)) - .select( - Direction.WEST, - Half.BOTTOM, - StairsShape.STRAIGHT, - Variant.variant() - .with(VariantProperties.MODEL, straightModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.SOUTH, - Half.BOTTOM, - StairsShape.STRAIGHT, - Variant.variant() - .with(VariantProperties.MODEL, straightModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.NORTH, - Half.BOTTOM, - StairsShape.STRAIGHT, - Variant.variant() - .with(VariantProperties.MODEL, straightModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select(Direction.EAST, Half.BOTTOM, StairsShape.OUTER_RIGHT, Variant.variant().with(VariantProperties.MODEL, outerModelLocation)) - .select( - Direction.WEST, - Half.BOTTOM, - StairsShape.OUTER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.SOUTH, - Half.BOTTOM, - StairsShape.OUTER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.NORTH, - Half.BOTTOM, - StairsShape.OUTER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.EAST, - Half.BOTTOM, - StairsShape.OUTER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.WEST, - Half.BOTTOM, - StairsShape.OUTER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select(Direction.SOUTH, Half.BOTTOM, StairsShape.OUTER_LEFT, Variant.variant().with(VariantProperties.MODEL, outerModelLocation)) - .select( - Direction.NORTH, - Half.BOTTOM, - StairsShape.OUTER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select(Direction.EAST, Half.BOTTOM, StairsShape.INNER_RIGHT, Variant.variant().with(VariantProperties.MODEL, innerModelLocation)) - .select( - Direction.WEST, - Half.BOTTOM, - StairsShape.INNER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.SOUTH, - Half.BOTTOM, - StairsShape.INNER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.NORTH, - Half.BOTTOM, - StairsShape.INNER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.EAST, - Half.BOTTOM, - StairsShape.INNER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.WEST, - Half.BOTTOM, - StairsShape.INNER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select(Direction.SOUTH, Half.BOTTOM, StairsShape.INNER_LEFT, Variant.variant().with(VariantProperties.MODEL, innerModelLocation)) - .select( - Direction.NORTH, - Half.BOTTOM, - StairsShape.INNER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.EAST, - Half.TOP, - StairsShape.STRAIGHT, - Variant.variant() - .with(VariantProperties.MODEL, straightModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.WEST, - Half.TOP, - StairsShape.STRAIGHT, - Variant.variant() - .with(VariantProperties.MODEL, straightModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.SOUTH, - Half.TOP, - StairsShape.STRAIGHT, - Variant.variant() - .with(VariantProperties.MODEL, straightModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.NORTH, - Half.TOP, - StairsShape.STRAIGHT, - Variant.variant() - .with(VariantProperties.MODEL, straightModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.EAST, - Half.TOP, - StairsShape.OUTER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.WEST, - Half.TOP, - StairsShape.OUTER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.SOUTH, - Half.TOP, - StairsShape.OUTER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.NORTH, - Half.TOP, - StairsShape.OUTER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.EAST, - Half.TOP, - StairsShape.OUTER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.WEST, - Half.TOP, - StairsShape.OUTER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.SOUTH, - Half.TOP, - StairsShape.OUTER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.NORTH, - Half.TOP, - StairsShape.OUTER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, outerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.EAST, - Half.TOP, - StairsShape.INNER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.WEST, - Half.TOP, - StairsShape.INNER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.SOUTH, - Half.TOP, - StairsShape.INNER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.NORTH, - Half.TOP, - StairsShape.INNER_RIGHT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.EAST, - Half.TOP, - StairsShape.INNER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.WEST, - Half.TOP, - StairsShape.INNER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.SOUTH, - Half.TOP, - StairsShape.INNER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .select( - Direction.NORTH, - Half.TOP, - StairsShape.INNER_LEFT, - Variant.variant() - .with(VariantProperties.MODEL, innerModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - ); - } - - private static BlockStateGenerator createOrientableTrapdoor( - Block orientableTrapdoorBlock, ResourceLocation topModelLocation, ResourceLocation bottomModelLocation, ResourceLocation openModelLocation - ) { - return MultiVariantGenerator.multiVariant(orientableTrapdoorBlock) - .with( - PropertyDispatch.properties(BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.HALF, BlockStateProperties.OPEN) - .select(Direction.NORTH, Half.BOTTOM, false, Variant.variant().with(VariantProperties.MODEL, bottomModelLocation)) - .select( - Direction.SOUTH, - Half.BOTTOM, - false, - Variant.variant().with(VariantProperties.MODEL, bottomModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.EAST, - Half.BOTTOM, - false, - Variant.variant().with(VariantProperties.MODEL, bottomModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - Half.BOTTOM, - false, - Variant.variant().with(VariantProperties.MODEL, bottomModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(Direction.NORTH, Half.TOP, false, Variant.variant().with(VariantProperties.MODEL, topModelLocation)) - .select( - Direction.SOUTH, - Half.TOP, - false, - Variant.variant().with(VariantProperties.MODEL, topModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.EAST, - Half.TOP, - false, - Variant.variant().with(VariantProperties.MODEL, topModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - Half.TOP, - false, - Variant.variant().with(VariantProperties.MODEL, topModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(Direction.NORTH, Half.BOTTOM, true, Variant.variant().with(VariantProperties.MODEL, openModelLocation)) - .select( - Direction.SOUTH, - Half.BOTTOM, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.EAST, - Half.BOTTOM, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - Half.BOTTOM, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - Direction.NORTH, - Half.TOP, - true, - Variant.variant() - .with(VariantProperties.MODEL, openModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.SOUTH, - Half.TOP, - true, - Variant.variant() - .with(VariantProperties.MODEL, openModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R0) - ) - .select( - Direction.EAST, - Half.TOP, - true, - Variant.variant() - .with(VariantProperties.MODEL, openModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - Direction.WEST, - Half.TOP, - true, - Variant.variant() - .with(VariantProperties.MODEL, openModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - ); - } - - private static BlockStateGenerator createTrapdoor( - Block trapdoorBlock, ResourceLocation topModelLocation, ResourceLocation bottomModelLocation, ResourceLocation openModelLocation - ) { - return MultiVariantGenerator.multiVariant(trapdoorBlock) - .with( - PropertyDispatch.properties(BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.HALF, BlockStateProperties.OPEN) - .select(Direction.NORTH, Half.BOTTOM, false, Variant.variant().with(VariantProperties.MODEL, bottomModelLocation)) - .select(Direction.SOUTH, Half.BOTTOM, false, Variant.variant().with(VariantProperties.MODEL, bottomModelLocation)) - .select(Direction.EAST, Half.BOTTOM, false, Variant.variant().with(VariantProperties.MODEL, bottomModelLocation)) - .select(Direction.WEST, Half.BOTTOM, false, Variant.variant().with(VariantProperties.MODEL, bottomModelLocation)) - .select(Direction.NORTH, Half.TOP, false, Variant.variant().with(VariantProperties.MODEL, topModelLocation)) - .select(Direction.SOUTH, Half.TOP, false, Variant.variant().with(VariantProperties.MODEL, topModelLocation)) - .select(Direction.EAST, Half.TOP, false, Variant.variant().with(VariantProperties.MODEL, topModelLocation)) - .select(Direction.WEST, Half.TOP, false, Variant.variant().with(VariantProperties.MODEL, topModelLocation)) - .select(Direction.NORTH, Half.BOTTOM, true, Variant.variant().with(VariantProperties.MODEL, openModelLocation)) - .select( - Direction.SOUTH, - Half.BOTTOM, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.EAST, - Half.BOTTOM, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - Half.BOTTOM, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(Direction.NORTH, Half.TOP, true, Variant.variant().with(VariantProperties.MODEL, openModelLocation)) - .select( - Direction.SOUTH, - Half.TOP, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.EAST, - Half.TOP, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - Half.TOP, - true, - Variant.variant().with(VariantProperties.MODEL, openModelLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - ); - } - - static MultiVariantGenerator createSimpleBlock(Block block, ResourceLocation model) { - return MultiVariantGenerator.multiVariant(block, Variant.variant().with(VariantProperties.MODEL, model)); - } - - private static PropertyDispatch createRotatedPillar() { - return PropertyDispatch.property(BlockStateProperties.AXIS) - .select(Axis.Y, Variant.variant()) - .select(Axis.Z, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90)) - .select( - Axis.X, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ); - } - - static BlockStateGenerator createPillarBlockUVLocked(Block block, TextureMapping textureMapping, BiConsumer modelOutput) { - ResourceLocation resourceLocation = ModelTemplates.CUBE_COLUMN_UV_LOCKED_X.create(block, textureMapping, modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.CUBE_COLUMN_UV_LOCKED_Y.create(block, textureMapping, modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.CUBE_COLUMN_UV_LOCKED_Z.create(block, textureMapping, modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.CUBE_COLUMN.create(block, textureMapping, modelOutput); - return MultiVariantGenerator.multiVariant(block, Variant.variant().with(VariantProperties.MODEL, resourceLocation4)) - .with( - PropertyDispatch.property(BlockStateProperties.AXIS) - .select(Axis.X, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(Axis.Y, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select(Axis.Z, Variant.variant().with(VariantProperties.MODEL, resourceLocation3)) - ); - } - - static BlockStateGenerator createAxisAlignedPillarBlock(Block axisAlignedPillarBlock, ResourceLocation modelLocation) { - return MultiVariantGenerator.multiVariant(axisAlignedPillarBlock, Variant.variant().with(VariantProperties.MODEL, modelLocation)).with(createRotatedPillar()); - } - - private void createAxisAlignedPillarBlockCustomModel(Block axisAlignedPillarBlock, ResourceLocation modelLocation) { - this.blockStateOutput.accept(createAxisAlignedPillarBlock(axisAlignedPillarBlock, modelLocation)); + private void createAxisAlignedPillarBlockCustomModel(Block block, MultiVariant variants) { + this.blockStateOutput.accept(createAxisAlignedPillarBlock(block, variants)); } public void createAxisAlignedPillarBlock(Block axisAlignedPillarBlock, TexturedModel.Provider provider) { - ResourceLocation resourceLocation = provider.create(axisAlignedPillarBlock, this.modelOutput); - this.blockStateOutput.accept(createAxisAlignedPillarBlock(axisAlignedPillarBlock, resourceLocation)); + MultiVariant multiVariant = plainVariant(provider.create(axisAlignedPillarBlock, this.modelOutput)); + this.blockStateOutput.accept(createAxisAlignedPillarBlock(axisAlignedPillarBlock, multiVariant)); } private void createHorizontallyRotatedBlock(Block horizontallyRotatedBlock, TexturedModel.Provider provider) { - ResourceLocation resourceLocation = provider.create(horizontallyRotatedBlock, this.modelOutput); - this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(horizontallyRotatedBlock, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .with(createHorizontalFacingDispatch()) - ); + MultiVariant multiVariant = plainVariant(provider.create(horizontallyRotatedBlock, this.modelOutput)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(horizontallyRotatedBlock, multiVariant).with(ROTATION_HORIZONTAL_FACING)); } - static BlockStateGenerator createRotatedPillarWithHorizontalVariant( - Block rotatedPillarBlock, ResourceLocation modelLocation, ResourceLocation horizontalModelLocation - ) { - return MultiVariantGenerator.multiVariant(rotatedPillarBlock) + static BlockModelDefinitionGenerator createRotatedPillarWithHorizontalVariant(Block block, MultiVariant variants, MultiVariant horizontalVariants) { + return MultiVariantGenerator.dispatch(block) .with( - PropertyDispatch.property(BlockStateProperties.AXIS) - .select(Axis.Y, Variant.variant().with(VariantProperties.MODEL, modelLocation)) - .select(Axis.Z, Variant.variant().with(VariantProperties.MODEL, horizontalModelLocation).with(VariantProperties.X_ROT, VariantProperties.Rotation.R90)) - .select( - Axis.X, - Variant.variant() - .with(VariantProperties.MODEL, horizontalModelLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) + PropertyDispatch.initial(BlockStateProperties.AXIS) + .select(Direction.Axis.Y, variants) + .select(Direction.Axis.Z, horizontalVariants.with(X_ROT_90)) + .select(Direction.Axis.X, horizontalVariants.with(X_ROT_90).with(Y_ROT_90)) ); } private void createRotatedPillarWithHorizontalVariant( Block rotatedPillarBlock, TexturedModel.Provider modelProvider, TexturedModel.Provider horizontalModelProvider ) { - ResourceLocation resourceLocation = modelProvider.create(rotatedPillarBlock, this.modelOutput); - ResourceLocation resourceLocation2 = horizontalModelProvider.create(rotatedPillarBlock, this.modelOutput); - this.blockStateOutput.accept(createRotatedPillarWithHorizontalVariant(rotatedPillarBlock, resourceLocation, resourceLocation2)); + MultiVariant multiVariant = plainVariant(modelProvider.create(rotatedPillarBlock, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(horizontalModelProvider.create(rotatedPillarBlock, this.modelOutput)); + this.blockStateOutput.accept(createRotatedPillarWithHorizontalVariant(rotatedPillarBlock, multiVariant, multiVariant2)); } private void createCreakingHeart(Block block) { - Function function = provider -> provider.updateTexture( - textureMapping -> textureMapping.put(TextureSlot.SIDE, TextureMapping.getBlockTexture(block, "_active")) - ) - .updateTexture(textureMapping -> textureMapping.put(TextureSlot.END, TextureMapping.getBlockTexture(block, "_top_active"))) - .createWithSuffix(block, "_active", this.modelOutput); - ResourceLocation resourceLocation = TexturedModel.COLUMN_ALT.create(block, this.modelOutput); - ResourceLocation resourceLocation2 = TexturedModel.COLUMN_HORIZONTAL_ALT.create(block, this.modelOutput); - ResourceLocation resourceLocation3 = (ResourceLocation)function.apply(TexturedModel.COLUMN_ALT); - ResourceLocation resourceLocation4 = (ResourceLocation)function.apply(TexturedModel.COLUMN_HORIZONTAL_ALT); + MultiVariant multiVariant = plainVariant(TexturedModel.COLUMN_ALT.create(block, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(TexturedModel.COLUMN_HORIZONTAL_ALT.create(block, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(this.createCreakingHeartModel(TexturedModel.COLUMN_ALT, block, "_awake")); + MultiVariant multiVariant4 = plainVariant(this.createCreakingHeartModel(TexturedModel.COLUMN_HORIZONTAL_ALT, block, "_awake")); + MultiVariant multiVariant5 = plainVariant(this.createCreakingHeartModel(TexturedModel.COLUMN_ALT, block, "_dormant")); + MultiVariant multiVariant6 = plainVariant(this.createCreakingHeartModel(TexturedModel.COLUMN_HORIZONTAL_ALT, block, "_dormant")); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(block) + MultiVariantGenerator.dispatch(block) .with( - PropertyDispatch.properties(BlockStateProperties.AXIS, CreakingHeartBlock.ACTIVE) - .select(Axis.Y, false, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(Axis.Z, false, Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.X_ROT, VariantProperties.Rotation.R90)) - .select( - Axis.X, - false, - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select(Axis.Y, true, Variant.variant().with(VariantProperties.MODEL, resourceLocation3)) - .select(Axis.Z, true, Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.X_ROT, VariantProperties.Rotation.R90)) - .select( - Axis.X, - true, - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation4) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) + PropertyDispatch.initial(BlockStateProperties.AXIS, CreakingHeartBlock.STATE) + .select(Direction.Axis.Y, CreakingHeartState.UPROOTED, multiVariant) + .select(Direction.Axis.Z, CreakingHeartState.UPROOTED, multiVariant2.with(X_ROT_90)) + .select(Direction.Axis.X, CreakingHeartState.UPROOTED, multiVariant2.with(X_ROT_90).with(Y_ROT_90)) + .select(Direction.Axis.Y, CreakingHeartState.DORMANT, multiVariant5) + .select(Direction.Axis.Z, CreakingHeartState.DORMANT, multiVariant6.with(X_ROT_90)) + .select(Direction.Axis.X, CreakingHeartState.DORMANT, multiVariant6.with(X_ROT_90).with(Y_ROT_90)) + .select(Direction.Axis.Y, CreakingHeartState.AWAKE, multiVariant3) + .select(Direction.Axis.Z, CreakingHeartState.AWAKE, multiVariant4.with(X_ROT_90)) + .select(Direction.Axis.X, CreakingHeartState.AWAKE, multiVariant4.with(X_ROT_90).with(Y_ROT_90)) ) ); } + private ResourceLocation createCreakingHeartModel(TexturedModel.Provider modelProvider, Block block, String suffix) { + return modelProvider.updateTexture( + textureMapping -> textureMapping.put(TextureSlot.SIDE, TextureMapping.getBlockTexture(block, suffix)) + .put(TextureSlot.END, TextureMapping.getBlockTexture(block, "_top" + suffix)) + ) + .createWithSuffix(block, suffix, this.modelOutput); + } + private ResourceLocation createSuffixedVariant( Block block, String suffix, ModelTemplate modelTemplate, Function textureMappingGetter ) { @@ -1332,20 +720,14 @@ public class BlockModelGenerators { ); } - static BlockStateGenerator createPressurePlate(Block pressurePlateBlock, ResourceLocation unpoweredModelLocation, ResourceLocation poweredModelLocation) { - return MultiVariantGenerator.multiVariant(pressurePlateBlock) - .with(createBooleanModelDispatch(BlockStateProperties.POWERED, poweredModelLocation, unpoweredModelLocation)); + static BlockModelDefinitionGenerator createPressurePlate(Block block, MultiVariant unpowered, MultiVariant powered) { + return MultiVariantGenerator.dispatch(block).with(createBooleanModelDispatch(BlockStateProperties.POWERED, powered, unpowered)); } - static BlockStateGenerator createSlab( - Block slabBlock, ResourceLocation bottomHalfModelLocation, ResourceLocation topHalfModelLocation, ResourceLocation doubleModelLocation - ) { - return MultiVariantGenerator.multiVariant(slabBlock) + static BlockModelDefinitionGenerator createSlab(Block block, MultiVariant bottom, MultiVariant top, MultiVariant doubleVariants) { + return MultiVariantGenerator.dispatch(block) .with( - PropertyDispatch.property(BlockStateProperties.SLAB_TYPE) - .select(SlabType.BOTTOM, Variant.variant().with(VariantProperties.MODEL, bottomHalfModelLocation)) - .select(SlabType.TOP, Variant.variant().with(VariantProperties.MODEL, topHalfModelLocation)) - .select(SlabType.DOUBLE, Variant.variant().with(VariantProperties.MODEL, doubleModelLocation)) + PropertyDispatch.initial(BlockStateProperties.SLAB_TYPE).select(SlabType.BOTTOM, bottom).select(SlabType.TOP, top).select(SlabType.DOUBLE, doubleVariants) ); } @@ -1354,12 +736,12 @@ public class BlockModelGenerators { } public void createTrivialBlock(Block block, TexturedModel.Provider provider) { - this.blockStateOutput.accept(createSimpleBlock(block, provider.create(block, this.modelOutput))); + this.blockStateOutput.accept(createSimpleBlock(block, plainVariant(provider.create(block, this.modelOutput)))); } public void createTintedLeaves(Block block, TexturedModel.Provider provider, int tint) { ResourceLocation resourceLocation = provider.create(block, this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(block, resourceLocation)); + this.blockStateOutput.accept(createSimpleBlock(block, plainVariant(resourceLocation))); this.registerSimpleTintedItemModel(block, resourceLocation, ItemModelUtils.constantTint(tint)); } @@ -1375,111 +757,87 @@ public class BlockModelGenerators { } private BlockModelGenerators.BlockFamilyProvider family(Block block) { - TexturedModel texturedModel = (TexturedModel)this.texturedModels.getOrDefault(block, TexturedModel.CUBE.get(block)); + TexturedModel texturedModel = (TexturedModel)TEXTURED_MODELS.getOrDefault(block, TexturedModel.CUBE.get(block)); return new BlockModelGenerators.BlockFamilyProvider(texturedModel.getMapping()).fullBlock(block, texturedModel.getTemplate()); } public void createHangingSign(Block particleBlock, Block hangingSignBlock, Block wallHangingSignBlock) { - ResourceLocation resourceLocation = this.createParticleOnlyBlockModel(hangingSignBlock, particleBlock); - this.blockStateOutput.accept(createSimpleBlock(hangingSignBlock, resourceLocation)); - this.blockStateOutput.accept(createSimpleBlock(wallHangingSignBlock, resourceLocation)); + MultiVariant multiVariant = this.createParticleOnlyBlockModel(hangingSignBlock, particleBlock); + this.blockStateOutput.accept(createSimpleBlock(hangingSignBlock, multiVariant)); + this.blockStateOutput.accept(createSimpleBlock(wallHangingSignBlock, multiVariant)); this.registerSimpleFlatItemModel(hangingSignBlock.asItem()); } void createDoor(Block doorBlock) { TextureMapping textureMapping = TextureMapping.door(doorBlock); - ResourceLocation resourceLocation = ModelTemplates.DOOR_BOTTOM_LEFT.create(doorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.DOOR_BOTTOM_LEFT_OPEN.create(doorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.DOOR_BOTTOM_RIGHT.create(doorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.DOOR_BOTTOM_RIGHT_OPEN.create(doorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation5 = ModelTemplates.DOOR_TOP_LEFT.create(doorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation6 = ModelTemplates.DOOR_TOP_LEFT_OPEN.create(doorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation7 = ModelTemplates.DOOR_TOP_RIGHT.create(doorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation8 = ModelTemplates.DOOR_TOP_RIGHT_OPEN.create(doorBlock, textureMapping, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.DOOR_BOTTOM_LEFT.create(doorBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.DOOR_BOTTOM_LEFT_OPEN.create(doorBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.DOOR_BOTTOM_RIGHT.create(doorBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant4 = plainVariant(ModelTemplates.DOOR_BOTTOM_RIGHT_OPEN.create(doorBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant5 = plainVariant(ModelTemplates.DOOR_TOP_LEFT.create(doorBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant6 = plainVariant(ModelTemplates.DOOR_TOP_LEFT_OPEN.create(doorBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant7 = plainVariant(ModelTemplates.DOOR_TOP_RIGHT.create(doorBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant8 = plainVariant(ModelTemplates.DOOR_TOP_RIGHT_OPEN.create(doorBlock, textureMapping, this.modelOutput)); this.registerSimpleFlatItemModel(doorBlock.asItem()); this.blockStateOutput - .accept( - createDoor( - doorBlock, - resourceLocation, - resourceLocation2, - resourceLocation3, - resourceLocation4, - resourceLocation5, - resourceLocation6, - resourceLocation7, - resourceLocation8 - ) - ); + .accept(createDoor(doorBlock, multiVariant, multiVariant2, multiVariant3, multiVariant4, multiVariant5, multiVariant6, multiVariant7, multiVariant8)); } private void copyDoorModel(Block doorBlock, Block sourceBlock) { - ResourceLocation resourceLocation = ModelTemplates.DOOR_BOTTOM_LEFT.getDefaultModelLocation(doorBlock); - ResourceLocation resourceLocation2 = ModelTemplates.DOOR_BOTTOM_LEFT_OPEN.getDefaultModelLocation(doorBlock); - ResourceLocation resourceLocation3 = ModelTemplates.DOOR_BOTTOM_RIGHT.getDefaultModelLocation(doorBlock); - ResourceLocation resourceLocation4 = ModelTemplates.DOOR_BOTTOM_RIGHT_OPEN.getDefaultModelLocation(doorBlock); - ResourceLocation resourceLocation5 = ModelTemplates.DOOR_TOP_LEFT.getDefaultModelLocation(doorBlock); - ResourceLocation resourceLocation6 = ModelTemplates.DOOR_TOP_LEFT_OPEN.getDefaultModelLocation(doorBlock); - ResourceLocation resourceLocation7 = ModelTemplates.DOOR_TOP_RIGHT.getDefaultModelLocation(doorBlock); - ResourceLocation resourceLocation8 = ModelTemplates.DOOR_TOP_RIGHT_OPEN.getDefaultModelLocation(doorBlock); + MultiVariant multiVariant = plainVariant(ModelTemplates.DOOR_BOTTOM_LEFT.getDefaultModelLocation(doorBlock)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.DOOR_BOTTOM_LEFT_OPEN.getDefaultModelLocation(doorBlock)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.DOOR_BOTTOM_RIGHT.getDefaultModelLocation(doorBlock)); + MultiVariant multiVariant4 = plainVariant(ModelTemplates.DOOR_BOTTOM_RIGHT_OPEN.getDefaultModelLocation(doorBlock)); + MultiVariant multiVariant5 = plainVariant(ModelTemplates.DOOR_TOP_LEFT.getDefaultModelLocation(doorBlock)); + MultiVariant multiVariant6 = plainVariant(ModelTemplates.DOOR_TOP_LEFT_OPEN.getDefaultModelLocation(doorBlock)); + MultiVariant multiVariant7 = plainVariant(ModelTemplates.DOOR_TOP_RIGHT.getDefaultModelLocation(doorBlock)); + MultiVariant multiVariant8 = plainVariant(ModelTemplates.DOOR_TOP_RIGHT_OPEN.getDefaultModelLocation(doorBlock)); this.itemModelOutput.copy(doorBlock.asItem(), sourceBlock.asItem()); this.blockStateOutput - .accept( - createDoor( - sourceBlock, - resourceLocation, - resourceLocation2, - resourceLocation3, - resourceLocation4, - resourceLocation5, - resourceLocation6, - resourceLocation7, - resourceLocation8 - ) - ); + .accept(createDoor(sourceBlock, multiVariant, multiVariant2, multiVariant3, multiVariant4, multiVariant5, multiVariant6, multiVariant7, multiVariant8)); } void createOrientableTrapdoor(Block orientableTrapdoorBlock) { TextureMapping textureMapping = TextureMapping.defaultTexture(orientableTrapdoorBlock); - ResourceLocation resourceLocation = ModelTemplates.ORIENTABLE_TRAPDOOR_TOP.create(orientableTrapdoorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.ORIENTABLE_TRAPDOOR_BOTTOM.create(orientableTrapdoorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.ORIENTABLE_TRAPDOOR_OPEN.create(orientableTrapdoorBlock, textureMapping, this.modelOutput); - this.blockStateOutput.accept(createOrientableTrapdoor(orientableTrapdoorBlock, resourceLocation, resourceLocation2, resourceLocation3)); - this.registerSimpleItemModel(orientableTrapdoorBlock, resourceLocation2); + MultiVariant multiVariant = plainVariant(ModelTemplates.ORIENTABLE_TRAPDOOR_TOP.create(orientableTrapdoorBlock, textureMapping, this.modelOutput)); + ResourceLocation resourceLocation = ModelTemplates.ORIENTABLE_TRAPDOOR_BOTTOM.create(orientableTrapdoorBlock, textureMapping, this.modelOutput); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.ORIENTABLE_TRAPDOOR_OPEN.create(orientableTrapdoorBlock, textureMapping, this.modelOutput)); + this.blockStateOutput.accept(createOrientableTrapdoor(orientableTrapdoorBlock, multiVariant, plainVariant(resourceLocation), multiVariant2)); + this.registerSimpleItemModel(orientableTrapdoorBlock, resourceLocation); } void createTrapdoor(Block trapdoorBlock) { TextureMapping textureMapping = TextureMapping.defaultTexture(trapdoorBlock); - ResourceLocation resourceLocation = ModelTemplates.TRAPDOOR_TOP.create(trapdoorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.TRAPDOOR_BOTTOM.create(trapdoorBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.TRAPDOOR_OPEN.create(trapdoorBlock, textureMapping, this.modelOutput); - this.blockStateOutput.accept(createTrapdoor(trapdoorBlock, resourceLocation, resourceLocation2, resourceLocation3)); - this.registerSimpleItemModel(trapdoorBlock, resourceLocation2); + MultiVariant multiVariant = plainVariant(ModelTemplates.TRAPDOOR_TOP.create(trapdoorBlock, textureMapping, this.modelOutput)); + ResourceLocation resourceLocation = ModelTemplates.TRAPDOOR_BOTTOM.create(trapdoorBlock, textureMapping, this.modelOutput); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.TRAPDOOR_OPEN.create(trapdoorBlock, textureMapping, this.modelOutput)); + this.blockStateOutput.accept(createTrapdoor(trapdoorBlock, multiVariant, plainVariant(resourceLocation), multiVariant2)); + this.registerSimpleItemModel(trapdoorBlock, resourceLocation); } private void copyTrapdoorModel(Block trapdoorBlock, Block sourceBlock) { - ResourceLocation resourceLocation = ModelTemplates.TRAPDOOR_TOP.getDefaultModelLocation(trapdoorBlock); - ResourceLocation resourceLocation2 = ModelTemplates.TRAPDOOR_BOTTOM.getDefaultModelLocation(trapdoorBlock); - ResourceLocation resourceLocation3 = ModelTemplates.TRAPDOOR_OPEN.getDefaultModelLocation(trapdoorBlock); + MultiVariant multiVariant = plainVariant(ModelTemplates.TRAPDOOR_TOP.getDefaultModelLocation(trapdoorBlock)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.TRAPDOOR_BOTTOM.getDefaultModelLocation(trapdoorBlock)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.TRAPDOOR_OPEN.getDefaultModelLocation(trapdoorBlock)); this.itemModelOutput.copy(trapdoorBlock.asItem(), sourceBlock.asItem()); - this.blockStateOutput.accept(createTrapdoor(sourceBlock, resourceLocation, resourceLocation2, resourceLocation3)); + this.blockStateOutput.accept(createTrapdoor(sourceBlock, multiVariant, multiVariant2, multiVariant3)); } private void createBigDripLeafBlock() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.BIG_DRIPLEAF); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.BIG_DRIPLEAF, "_partial_tilt"); - ResourceLocation resourceLocation3 = ModelLocationUtils.getModelLocation(Blocks.BIG_DRIPLEAF, "_full_tilt"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.BIG_DRIPLEAF)); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.BIG_DRIPLEAF, "_partial_tilt")); + MultiVariant multiVariant3 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.BIG_DRIPLEAF, "_full_tilt")); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.BIG_DRIPLEAF) - .with(createHorizontalFacingDispatch()) + MultiVariantGenerator.dispatch(Blocks.BIG_DRIPLEAF) .with( - PropertyDispatch.property(BlockStateProperties.TILT) - .select(Tilt.NONE, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(Tilt.UNSTABLE, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(Tilt.PARTIAL, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select(Tilt.FULL, Variant.variant().with(VariantProperties.MODEL, resourceLocation3)) + PropertyDispatch.initial(BlockStateProperties.TILT) + .select(Tilt.NONE, multiVariant) + .select(Tilt.UNSTABLE, multiVariant) + .select(Tilt.PARTIAL, multiVariant2) + .select(Tilt.FULL, multiVariant3) ) + .with(ROTATION_HORIZONTAL_FACING) ); } @@ -1492,7 +850,7 @@ public class BlockModelGenerators { } private void createNonTemplateModelBlock(Block block, Block modelBlock) { - this.blockStateOutput.accept(createSimpleBlock(block, ModelLocationUtils.getModelLocation(modelBlock))); + this.blockStateOutput.accept(createSimpleBlock(block, plainVariant(ModelLocationUtils.getModelLocation(modelBlock)))); } private void createCrossBlockWithDefaultItem(Block block, BlockModelGenerators.PlantType plantType) { @@ -1511,22 +869,20 @@ public class BlockModelGenerators { } private void createCrossBlock(Block block, BlockModelGenerators.PlantType plantType, TextureMapping textureMapping) { - ResourceLocation resourceLocation = plantType.getCross().create(block, textureMapping, this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(block, resourceLocation)); + MultiVariant multiVariant = plainVariant(plantType.getCross().create(block, textureMapping, this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(block, multiVariant)); } private void createCrossBlock(Block block, BlockModelGenerators.PlantType plantType, Property ageProperty, int... possibleValues) { if (ageProperty.getPossibleValues().size() != possibleValues.length) { throw new IllegalArgumentException("missing values for property: " + ageProperty); } else { - PropertyDispatch propertyDispatch = PropertyDispatch.property(ageProperty).generate(integer -> { + this.registerSimpleFlatItemModel(block.asItem()); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(block).with(PropertyDispatch.initial(ageProperty).generate(integer -> { String string = "_stage" + possibleValues[integer]; TextureMapping textureMapping = TextureMapping.cross(TextureMapping.getBlockTexture(block, string)); - ResourceLocation resourceLocation = plantType.getCross().createWithSuffix(block, string, textureMapping, this.modelOutput); - return Variant.variant().with(VariantProperties.MODEL, resourceLocation); - }); - this.registerSimpleFlatItemModel(block.asItem()); - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(block).with(propertyDispatch)); + return plainVariant(plantType.getCross().createWithSuffix(block, string, textureMapping, this.modelOutput)); + }))); } } @@ -1538,20 +894,16 @@ public class BlockModelGenerators { private void createPlant(Block block, Block pottedBlock, BlockModelGenerators.PlantType plantType) { this.createCrossBlock(block, plantType); TextureMapping textureMapping = plantType.getPlantTextureMapping(block); - ResourceLocation resourceLocation = plantType.getCrossPot().create(pottedBlock, textureMapping, this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(pottedBlock, resourceLocation)); + MultiVariant multiVariant = plainVariant(plantType.getCrossPot().create(pottedBlock, textureMapping, this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(pottedBlock, multiVariant)); } private void createCoralFans(Block coralFanBlock, Block coralWallFanBlock) { TexturedModel texturedModel = TexturedModel.CORAL_FAN.get(coralFanBlock); - ResourceLocation resourceLocation = texturedModel.create(coralFanBlock, this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(coralFanBlock, resourceLocation)); - ResourceLocation resourceLocation2 = ModelTemplates.CORAL_WALL_FAN.create(coralWallFanBlock, texturedModel.getMapping(), this.modelOutput); - this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(coralWallFanBlock, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .with(createHorizontalFacingDispatch()) - ); + MultiVariant multiVariant = plainVariant(texturedModel.create(coralFanBlock, this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(coralFanBlock, multiVariant)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.CORAL_WALL_FAN.create(coralWallFanBlock, texturedModel.getMapping(), this.modelOutput)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(coralWallFanBlock, multiVariant2).with(ROTATION_HORIZONTAL_FACING)); this.registerSimpleFlatItemModel(coralFanBlock); } @@ -1559,26 +911,24 @@ public class BlockModelGenerators { this.registerSimpleFlatItemModel(unattachedStemBlock.asItem()); TextureMapping textureMapping = TextureMapping.stem(unattachedStemBlock); TextureMapping textureMapping2 = TextureMapping.attachedStem(unattachedStemBlock, attachedStemBlock); - ResourceLocation resourceLocation = ModelTemplates.ATTACHED_STEM.create(attachedStemBlock, textureMapping2, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.ATTACHED_STEM.create(attachedStemBlock, textureMapping2, this.modelOutput)); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(attachedStemBlock, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) + MultiVariantGenerator.dispatch(attachedStemBlock, multiVariant) .with( - PropertyDispatch.property(BlockStateProperties.HORIZONTAL_FACING) - .select(Direction.WEST, Variant.variant()) - .select(Direction.SOUTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)) - .select(Direction.NORTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select(Direction.EAST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) + PropertyDispatch.modify(BlockStateProperties.HORIZONTAL_FACING) + .select(Direction.WEST, NOP) + .select(Direction.SOUTH, Y_ROT_270) + .select(Direction.NORTH, Y_ROT_90) + .select(Direction.EAST, Y_ROT_180) ) ); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(unattachedStemBlock) + MultiVariantGenerator.dispatch(unattachedStemBlock) .with( - PropertyDispatch.property(BlockStateProperties.AGE_7) - .generate( - integer -> Variant.variant().with(VariantProperties.MODEL, ModelTemplates.STEMS[integer].create(unattachedStemBlock, textureMapping, this.modelOutput)) - ) + PropertyDispatch.initial(BlockStateProperties.AGE_7) + .generate(integer -> plainVariant(ModelTemplates.STEMS[integer].create(unattachedStemBlock, textureMapping, this.modelOutput))) ) ); } @@ -1586,22 +936,24 @@ public class BlockModelGenerators { private void createPitcherPlant() { Block block = Blocks.PITCHER_PLANT; this.registerSimpleFlatItemModel(block.asItem()); - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(block, "_top"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(block, "_bottom"); - this.createDoubleBlock(block, resourceLocation, resourceLocation2); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(block, "_top")); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(block, "_bottom")); + this.createDoubleBlock(block, multiVariant, multiVariant2); } private void createPitcherCrop() { Block block = Blocks.PITCHER_CROP; this.registerSimpleFlatItemModel(block.asItem()); - PropertyDispatch propertyDispatch = PropertyDispatch.properties(PitcherCropBlock.AGE, BlockStateProperties.DOUBLE_BLOCK_HALF) - .generate((integer, doubleBlockHalf) -> { - return switch (doubleBlockHalf) { - case UPPER -> Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(block, "_top_stage_" + integer)); - case LOWER -> Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(block, "_bottom_stage_" + integer)); - }; - }); - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(block).with(propertyDispatch)); + this.blockStateOutput + .accept( + MultiVariantGenerator.dispatch(block) + .with(PropertyDispatch.initial(PitcherCropBlock.AGE, BlockStateProperties.DOUBLE_BLOCK_HALF).generate((integer, doubleBlockHalf) -> { + return switch (doubleBlockHalf) { + case UPPER -> plainVariant(ModelLocationUtils.getModelLocation(block, "_top_stage_" + integer)); + case LOWER -> plainVariant(ModelLocationUtils.getModelLocation(block, "_bottom_stage_" + integer)); + }; + })) + ); } private void createCoral( @@ -1623,9 +975,9 @@ public class BlockModelGenerators { } private void createDoublePlant(Block block, BlockModelGenerators.PlantType plantType) { - ResourceLocation resourceLocation = this.createSuffixedVariant(block, "_top", plantType.getCross(), TextureMapping::cross); - ResourceLocation resourceLocation2 = this.createSuffixedVariant(block, "_bottom", plantType.getCross(), TextureMapping::cross); - this.createDoubleBlock(block, resourceLocation, resourceLocation2); + MultiVariant multiVariant = plainVariant(this.createSuffixedVariant(block, "_top", plantType.getCross(), TextureMapping::cross)); + MultiVariant multiVariant2 = plainVariant(this.createSuffixedVariant(block, "_bottom", plantType.getCross(), TextureMapping::cross)); + this.createDoubleBlock(block, multiVariant, multiVariant2); } private void createDoublePlantWithDefaultItem(Block block, BlockModelGenerators.PlantType plantType) { @@ -1641,137 +993,106 @@ public class BlockModelGenerators { private void createSunflower() { this.registerSimpleFlatItemModel(Blocks.SUNFLOWER, "_front"); - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.SUNFLOWER, "_top"); - ResourceLocation resourceLocation2 = this.createSuffixedVariant( - Blocks.SUNFLOWER, "_bottom", BlockModelGenerators.PlantType.NOT_TINTED.getCross(), TextureMapping::cross + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.SUNFLOWER, "_top")); + MultiVariant multiVariant2 = plainVariant( + this.createSuffixedVariant(Blocks.SUNFLOWER, "_bottom", BlockModelGenerators.PlantType.NOT_TINTED.getCross(), TextureMapping::cross) ); - this.createDoubleBlock(Blocks.SUNFLOWER, resourceLocation, resourceLocation2); + this.createDoubleBlock(Blocks.SUNFLOWER, multiVariant, multiVariant2); } private void createTallSeagrass() { - ResourceLocation resourceLocation = this.createSuffixedVariant(Blocks.TALL_SEAGRASS, "_top", ModelTemplates.SEAGRASS, TextureMapping::defaultTexture); - ResourceLocation resourceLocation2 = this.createSuffixedVariant(Blocks.TALL_SEAGRASS, "_bottom", ModelTemplates.SEAGRASS, TextureMapping::defaultTexture); - this.createDoubleBlock(Blocks.TALL_SEAGRASS, resourceLocation, resourceLocation2); + MultiVariant multiVariant = plainVariant(this.createSuffixedVariant(Blocks.TALL_SEAGRASS, "_top", ModelTemplates.SEAGRASS, TextureMapping::defaultTexture)); + MultiVariant multiVariant2 = plainVariant( + this.createSuffixedVariant(Blocks.TALL_SEAGRASS, "_bottom", ModelTemplates.SEAGRASS, TextureMapping::defaultTexture) + ); + this.createDoubleBlock(Blocks.TALL_SEAGRASS, multiVariant, multiVariant2); } private void createSmallDripleaf() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.SMALL_DRIPLEAF, "_top"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.SMALL_DRIPLEAF, "_bottom"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.SMALL_DRIPLEAF, "_top")); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.SMALL_DRIPLEAF, "_bottom")); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.SMALL_DRIPLEAF) - .with(createHorizontalFacingDispatch()) + MultiVariantGenerator.dispatch(Blocks.SMALL_DRIPLEAF) .with( - PropertyDispatch.property(BlockStateProperties.DOUBLE_BLOCK_HALF) - .select(DoubleBlockHalf.LOWER, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select(DoubleBlockHalf.UPPER, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) + PropertyDispatch.initial(BlockStateProperties.DOUBLE_BLOCK_HALF).select(DoubleBlockHalf.LOWER, multiVariant2).select(DoubleBlockHalf.UPPER, multiVariant) ) + .with(ROTATION_HORIZONTAL_FACING) ); } - private void createDoubleBlock(Block doubleBlock, ResourceLocation topHalfModelLocation, ResourceLocation bottomHalfModelLocation) { + private void createDoubleBlock(Block block, MultiVariant lower, MultiVariant upper) { this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(doubleBlock) - .with( - PropertyDispatch.property(BlockStateProperties.DOUBLE_BLOCK_HALF) - .select(DoubleBlockHalf.LOWER, Variant.variant().with(VariantProperties.MODEL, bottomHalfModelLocation)) - .select(DoubleBlockHalf.UPPER, Variant.variant().with(VariantProperties.MODEL, topHalfModelLocation)) - ) + MultiVariantGenerator.dispatch(block) + .with(PropertyDispatch.initial(BlockStateProperties.DOUBLE_BLOCK_HALF).select(DoubleBlockHalf.LOWER, upper).select(DoubleBlockHalf.UPPER, lower)) ); } private void createPassiveRail(Block railBlock) { TextureMapping textureMapping = TextureMapping.rail(railBlock); TextureMapping textureMapping2 = TextureMapping.rail(TextureMapping.getBlockTexture(railBlock, "_corner")); - ResourceLocation resourceLocation = ModelTemplates.RAIL_FLAT.create(railBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.RAIL_CURVED.create(railBlock, textureMapping2, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.RAIL_RAISED_NE.create(railBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.RAIL_RAISED_SW.create(railBlock, textureMapping, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.RAIL_FLAT.create(railBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.RAIL_CURVED.create(railBlock, textureMapping2, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.RAIL_RAISED_NE.create(railBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant4 = plainVariant(ModelTemplates.RAIL_RAISED_SW.create(railBlock, textureMapping, this.modelOutput)); this.registerSimpleFlatItemModel(railBlock); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(railBlock) + MultiVariantGenerator.dispatch(railBlock) .with( - PropertyDispatch.property(BlockStateProperties.RAIL_SHAPE) - .select(RailShape.NORTH_SOUTH, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select( - RailShape.EAST_WEST, Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - RailShape.ASCENDING_EAST, - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - RailShape.ASCENDING_WEST, - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select(RailShape.ASCENDING_NORTH, Variant.variant().with(VariantProperties.MODEL, resourceLocation3)) - .select(RailShape.ASCENDING_SOUTH, Variant.variant().with(VariantProperties.MODEL, resourceLocation4)) - .select(RailShape.SOUTH_EAST, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select( - RailShape.SOUTH_WEST, Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - RailShape.NORTH_WEST, Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - RailShape.NORTH_EAST, Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) + PropertyDispatch.initial(BlockStateProperties.RAIL_SHAPE) + .select(RailShape.NORTH_SOUTH, multiVariant) + .select(RailShape.EAST_WEST, multiVariant.with(Y_ROT_90)) + .select(RailShape.ASCENDING_EAST, multiVariant3.with(Y_ROT_90)) + .select(RailShape.ASCENDING_WEST, multiVariant4.with(Y_ROT_90)) + .select(RailShape.ASCENDING_NORTH, multiVariant3) + .select(RailShape.ASCENDING_SOUTH, multiVariant4) + .select(RailShape.SOUTH_EAST, multiVariant2) + .select(RailShape.SOUTH_WEST, multiVariant2.with(Y_ROT_90)) + .select(RailShape.NORTH_WEST, multiVariant2.with(Y_ROT_180)) + .select(RailShape.NORTH_EAST, multiVariant2.with(Y_ROT_270)) ) ); } private void createActiveRail(Block railBlock) { - ResourceLocation resourceLocation = this.createSuffixedVariant(railBlock, "", ModelTemplates.RAIL_FLAT, TextureMapping::rail); - ResourceLocation resourceLocation2 = this.createSuffixedVariant(railBlock, "", ModelTemplates.RAIL_RAISED_NE, TextureMapping::rail); - ResourceLocation resourceLocation3 = this.createSuffixedVariant(railBlock, "", ModelTemplates.RAIL_RAISED_SW, TextureMapping::rail); - ResourceLocation resourceLocation4 = this.createSuffixedVariant(railBlock, "_on", ModelTemplates.RAIL_FLAT, TextureMapping::rail); - ResourceLocation resourceLocation5 = this.createSuffixedVariant(railBlock, "_on", ModelTemplates.RAIL_RAISED_NE, TextureMapping::rail); - ResourceLocation resourceLocation6 = this.createSuffixedVariant(railBlock, "_on", ModelTemplates.RAIL_RAISED_SW, TextureMapping::rail); - PropertyDispatch propertyDispatch = PropertyDispatch.properties(BlockStateProperties.POWERED, BlockStateProperties.RAIL_SHAPE_STRAIGHT) - .generate( - (boolean_, railShape) -> { - switch (railShape) { - case NORTH_SOUTH: - return Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation4 : resourceLocation); - case EAST_WEST: - return Variant.variant() - .with(VariantProperties.MODEL, boolean_ ? resourceLocation4 : resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90); - case ASCENDING_EAST: - return Variant.variant() - .with(VariantProperties.MODEL, boolean_ ? resourceLocation5 : resourceLocation2) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90); - case ASCENDING_WEST: - return Variant.variant() - .with(VariantProperties.MODEL, boolean_ ? resourceLocation6 : resourceLocation3) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90); - case ASCENDING_NORTH: - return Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation5 : resourceLocation2); - case ASCENDING_SOUTH: - return Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation6 : resourceLocation3); - default: - throw new UnsupportedOperationException("Fix you generator!"); - } - } - ); + MultiVariant multiVariant = plainVariant(this.createSuffixedVariant(railBlock, "", ModelTemplates.RAIL_FLAT, TextureMapping::rail)); + MultiVariant multiVariant2 = plainVariant(this.createSuffixedVariant(railBlock, "", ModelTemplates.RAIL_RAISED_NE, TextureMapping::rail)); + MultiVariant multiVariant3 = plainVariant(this.createSuffixedVariant(railBlock, "", ModelTemplates.RAIL_RAISED_SW, TextureMapping::rail)); + MultiVariant multiVariant4 = plainVariant(this.createSuffixedVariant(railBlock, "_on", ModelTemplates.RAIL_FLAT, TextureMapping::rail)); + MultiVariant multiVariant5 = plainVariant(this.createSuffixedVariant(railBlock, "_on", ModelTemplates.RAIL_RAISED_NE, TextureMapping::rail)); + MultiVariant multiVariant6 = plainVariant(this.createSuffixedVariant(railBlock, "_on", ModelTemplates.RAIL_RAISED_SW, TextureMapping::rail)); this.registerSimpleFlatItemModel(railBlock); - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(railBlock).with(propertyDispatch)); + this.blockStateOutput + .accept( + MultiVariantGenerator.dispatch(railBlock) + .with(PropertyDispatch.initial(BlockStateProperties.POWERED, BlockStateProperties.RAIL_SHAPE_STRAIGHT).generate((boolean_, railShape) -> { + return switch (railShape) { + case NORTH_SOUTH -> boolean_ ? multiVariant4 : multiVariant; + case EAST_WEST -> (boolean_ ? multiVariant4 : multiVariant).with(Y_ROT_90); + case ASCENDING_EAST -> (boolean_ ? multiVariant5 : multiVariant2).with(Y_ROT_90); + case ASCENDING_WEST -> (boolean_ ? multiVariant6 : multiVariant3).with(Y_ROT_90); + case ASCENDING_NORTH -> boolean_ ? multiVariant5 : multiVariant2; + case ASCENDING_SOUTH -> boolean_ ? multiVariant6 : multiVariant3; + default -> throw new UnsupportedOperationException("Fix you generator!"); + }; + })) + ); } private void createAirLikeBlock(Block airLikeBlock, Item particleItem) { - ResourceLocation resourceLocation = ModelTemplates.PARTICLE_ONLY.create(airLikeBlock, TextureMapping.particleFromItem(particleItem), this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(airLikeBlock, resourceLocation)); + MultiVariant multiVariant = plainVariant(ModelTemplates.PARTICLE_ONLY.create(airLikeBlock, TextureMapping.particleFromItem(particleItem), this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(airLikeBlock, multiVariant)); } private void createAirLikeBlock(Block airLikeBlock, ResourceLocation particleTexture) { - ResourceLocation resourceLocation = ModelTemplates.PARTICLE_ONLY.create(airLikeBlock, TextureMapping.particle(particleTexture), this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(airLikeBlock, resourceLocation)); + MultiVariant multiVariant = plainVariant(ModelTemplates.PARTICLE_ONLY.create(airLikeBlock, TextureMapping.particle(particleTexture), this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(airLikeBlock, multiVariant)); } - private ResourceLocation createParticleOnlyBlockModel(Block block, Block particleBlock) { - return ModelTemplates.PARTICLE_ONLY.create(block, TextureMapping.particle(particleBlock), this.modelOutput); + private MultiVariant createParticleOnlyBlockModel(Block block, Block particleBlock) { + return plainVariant(ModelTemplates.PARTICLE_ONLY.create(block, TextureMapping.particle(particleBlock), this.modelOutput)); } public void createParticleOnlyBlock(Block block, Block particleBlock) { @@ -1784,234 +1105,200 @@ public class BlockModelGenerators { private void createFullAndCarpetBlocks(Block fullBlock, Block carpetBlock) { this.createTrivialCube(fullBlock); - ResourceLocation resourceLocation = TexturedModel.CARPET.get(fullBlock).create(carpetBlock, this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(carpetBlock, resourceLocation)); + MultiVariant multiVariant = plainVariant(TexturedModel.CARPET.get(fullBlock).create(carpetBlock, this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(carpetBlock, multiVariant)); + } + + private void createLeafLitter(Block block) { + MultiVariant multiVariant = plainVariant(TexturedModel.LEAF_LITTER_1.create(block, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(TexturedModel.LEAF_LITTER_2.create(block, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(TexturedModel.LEAF_LITTER_3.create(block, this.modelOutput)); + MultiVariant multiVariant4 = plainVariant(TexturedModel.LEAF_LITTER_4.create(block, this.modelOutput)); + this.registerSimpleFlatItemModel(block.asItem()); + this.createSegmentedBlock( + block, + multiVariant, + LEAF_LITTER_MODEL_1_SEGMENT_CONDITION, + multiVariant2, + LEAF_LITTER_MODEL_2_SEGMENT_CONDITION, + multiVariant3, + LEAF_LITTER_MODEL_3_SEGMENT_CONDITION, + multiVariant4, + LEAF_LITTER_MODEL_4_SEGMENT_CONDITION + ); } private void createFlowerBed(Block flowerBedBlock) { + MultiVariant multiVariant = plainVariant(TexturedModel.FLOWERBED_1.create(flowerBedBlock, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(TexturedModel.FLOWERBED_2.create(flowerBedBlock, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(TexturedModel.FLOWERBED_3.create(flowerBedBlock, this.modelOutput)); + MultiVariant multiVariant4 = plainVariant(TexturedModel.FLOWERBED_4.create(flowerBedBlock, this.modelOutput)); this.registerSimpleFlatItemModel(flowerBedBlock.asItem()); - ResourceLocation resourceLocation = TexturedModel.FLOWERBED_1.create(flowerBedBlock, this.modelOutput); - ResourceLocation resourceLocation2 = TexturedModel.FLOWERBED_2.create(flowerBedBlock, this.modelOutput); - ResourceLocation resourceLocation3 = TexturedModel.FLOWERBED_3.create(flowerBedBlock, this.modelOutput); - ResourceLocation resourceLocation4 = TexturedModel.FLOWERBED_4.create(flowerBedBlock, this.modelOutput); + this.createSegmentedBlock( + flowerBedBlock, + multiVariant, + FLOWER_BED_MODEL_1_SEGMENT_CONDITION, + multiVariant2, + FLOWER_BED_MODEL_2_SEGMENT_CONDITION, + multiVariant3, + FLOWER_BED_MODEL_3_SEGMENT_CONDITION, + multiVariant4, + FLOWER_BED_MODEL_4_SEGMENT_CONDITION + ); + } + + private void createSegmentedBlock( + Block block, + MultiVariant segment1Variant, + Function segment1Condition, + MultiVariant segment2Variant, + Function segment2Condition, + MultiVariant segment3Variant, + Function segment3Condition, + MultiVariant segment4Variant, + Function segment4Condition + ) { this.blockStateOutput .accept( - MultiPartGenerator.multiPart(flowerBedBlock) + MultiPartGenerator.multiPart(block) + .with((ConditionBuilder)segment1Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.NORTH)), segment1Variant) + .with((ConditionBuilder)segment1Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.EAST)), segment1Variant.with(Y_ROT_90)) .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 1, 2, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.NORTH), - Variant.variant().with(VariantProperties.MODEL, resourceLocation) + (ConditionBuilder)segment1Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.SOUTH)), segment1Variant.with(Y_ROT_180) ) + .with((ConditionBuilder)segment1Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.WEST)), segment1Variant.with(Y_ROT_270)) + .with((ConditionBuilder)segment2Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.NORTH)), segment2Variant) + .with((ConditionBuilder)segment2Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.EAST)), segment2Variant.with(Y_ROT_90)) .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 1, 2, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.EAST), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) + (ConditionBuilder)segment2Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.SOUTH)), segment2Variant.with(Y_ROT_180) ) + .with((ConditionBuilder)segment2Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.WEST)), segment2Variant.with(Y_ROT_270)) + .with((ConditionBuilder)segment3Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.NORTH)), segment3Variant) + .with((ConditionBuilder)segment3Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.EAST)), segment3Variant.with(Y_ROT_90)) .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 1, 2, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.SOUTH), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) + (ConditionBuilder)segment3Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.SOUTH)), segment3Variant.with(Y_ROT_180) ) + .with((ConditionBuilder)segment3Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.WEST)), segment3Variant.with(Y_ROT_270)) + .with((ConditionBuilder)segment4Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.NORTH)), segment4Variant) + .with((ConditionBuilder)segment4Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.EAST)), segment4Variant.with(Y_ROT_90)) .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 1, 2, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.WEST), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 2, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.NORTH), - Variant.variant().with(VariantProperties.MODEL, resourceLocation2) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 2, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.EAST), - Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 2, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.SOUTH), - Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 2, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.WEST), - Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.NORTH), - Variant.variant().with(VariantProperties.MODEL, resourceLocation3) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.EAST), - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.SOUTH), - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 3, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.WEST), - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.NORTH), - Variant.variant().with(VariantProperties.MODEL, resourceLocation4) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.EAST), - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.SOUTH), - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .with( - Condition.condition().term(BlockStateProperties.FLOWER_AMOUNT, 4).term(BlockStateProperties.HORIZONTAL_FACING, Direction.WEST), - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) + (ConditionBuilder)segment4Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.SOUTH)), segment4Variant.with(Y_ROT_180) ) + .with((ConditionBuilder)segment4Condition.apply(condition().term(BlockStateProperties.HORIZONTAL_FACING, Direction.WEST)), segment4Variant.with(Y_ROT_270)) ); } private void createColoredBlockWithRandomRotations(TexturedModel.Provider modelProvider, Block... coloredBlocks) { for (Block block : coloredBlocks) { - ResourceLocation resourceLocation = modelProvider.create(block, this.modelOutput); - this.blockStateOutput.accept(createRotatedVariant(block, resourceLocation)); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(modelProvider.create(block, this.modelOutput)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, createRotatedVariants(variant))); } } private void createColoredBlockWithStateRotations(TexturedModel.Provider modelProvider, Block... coloredBlocks) { for (Block block : coloredBlocks) { - ResourceLocation resourceLocation = modelProvider.create(block, this.modelOutput); - this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(block, Variant.variant().with(VariantProperties.MODEL, resourceLocation)).with(createHorizontalFacingDispatchAlt()) - ); + MultiVariant multiVariant = plainVariant(modelProvider.create(block, this.modelOutput)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(block, multiVariant).with(ROTATION_HORIZONTAL_FACING_ALT)); } } private void createGlassBlocks(Block glassBlock, Block paneBlock) { this.createTrivialCube(glassBlock); TextureMapping textureMapping = TextureMapping.pane(glassBlock, paneBlock); - ResourceLocation resourceLocation = ModelTemplates.STAINED_GLASS_PANE_POST.create(paneBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.STAINED_GLASS_PANE_SIDE.create(paneBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.STAINED_GLASS_PANE_SIDE_ALT.create(paneBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.STAINED_GLASS_PANE_NOSIDE.create(paneBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation5 = ModelTemplates.STAINED_GLASS_PANE_NOSIDE_ALT.create(paneBlock, textureMapping, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.STAINED_GLASS_PANE_POST.create(paneBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.STAINED_GLASS_PANE_SIDE.create(paneBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.STAINED_GLASS_PANE_SIDE_ALT.create(paneBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant4 = plainVariant(ModelTemplates.STAINED_GLASS_PANE_NOSIDE.create(paneBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant5 = plainVariant(ModelTemplates.STAINED_GLASS_PANE_NOSIDE_ALT.create(paneBlock, textureMapping, this.modelOutput)); Item item = paneBlock.asItem(); this.registerSimpleItemModel(item, this.createFlatItemModelWithBlockTexture(item, glassBlock)); this.blockStateOutput .accept( MultiPartGenerator.multiPart(paneBlock) - .with(Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .with(Condition.condition().term(BlockStateProperties.NORTH, true), Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .with( - Condition.condition().term(BlockStateProperties.EAST, true), - Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .with(Condition.condition().term(BlockStateProperties.SOUTH, true), Variant.variant().with(VariantProperties.MODEL, resourceLocation3)) - .with( - Condition.condition().term(BlockStateProperties.WEST, true), - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .with(Condition.condition().term(BlockStateProperties.NORTH, false), Variant.variant().with(VariantProperties.MODEL, resourceLocation4)) - .with(Condition.condition().term(BlockStateProperties.EAST, false), Variant.variant().with(VariantProperties.MODEL, resourceLocation5)) - .with( - Condition.condition().term(BlockStateProperties.SOUTH, false), - Variant.variant().with(VariantProperties.MODEL, resourceLocation5).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .with( - Condition.condition().term(BlockStateProperties.WEST, false), - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) + .with(multiVariant) + .with(condition().term(BlockStateProperties.NORTH, true), multiVariant2) + .with(condition().term(BlockStateProperties.EAST, true), multiVariant2.with(Y_ROT_90)) + .with(condition().term(BlockStateProperties.SOUTH, true), multiVariant3) + .with(condition().term(BlockStateProperties.WEST, true), multiVariant3.with(Y_ROT_90)) + .with(condition().term(BlockStateProperties.NORTH, false), multiVariant4) + .with(condition().term(BlockStateProperties.EAST, false), multiVariant5) + .with(condition().term(BlockStateProperties.SOUTH, false), multiVariant5.with(Y_ROT_90)) + .with(condition().term(BlockStateProperties.WEST, false), multiVariant4.with(Y_ROT_270)) ); } private void createCommandBlock(Block commandBlock) { TextureMapping textureMapping = TextureMapping.commandBlock(commandBlock); - ResourceLocation resourceLocation = ModelTemplates.COMMAND_BLOCK.create(commandBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = this.createSuffixedVariant( - commandBlock, "_conditional", ModelTemplates.COMMAND_BLOCK, resourceLocationx -> textureMapping.copyAndUpdate(TextureSlot.SIDE, resourceLocationx) + MultiVariant multiVariant = plainVariant(ModelTemplates.COMMAND_BLOCK.create(commandBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant( + this.createSuffixedVariant( + commandBlock, "_conditional", ModelTemplates.COMMAND_BLOCK, resourceLocation -> textureMapping.copyAndUpdate(TextureSlot.SIDE, resourceLocation) + ) ); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(commandBlock) - .with(createBooleanModelDispatch(BlockStateProperties.CONDITIONAL, resourceLocation2, resourceLocation)) - .with(createFacingDispatch()) + MultiVariantGenerator.dispatch(commandBlock) + .with(createBooleanModelDispatch(BlockStateProperties.CONDITIONAL, multiVariant2, multiVariant)) + .with(ROTATION_FACING) ); } private void createAnvil(Block anvilBlock) { - ResourceLocation resourceLocation = TexturedModel.ANVIL.create(anvilBlock, this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(anvilBlock, resourceLocation).with(createHorizontalFacingDispatchAlt())); + MultiVariant multiVariant = plainVariant(TexturedModel.ANVIL.create(anvilBlock, this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(anvilBlock, multiVariant).with(ROTATION_HORIZONTAL_FACING_ALT)); } - private List createBambooModels(int age) { + private static MultiVariant createBambooModels(int age) { String string = "_age" + age; - return (List)IntStream.range(1, 5) - .mapToObj(i -> Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.BAMBOO, i + string))) - .collect(Collectors.toList()); + return new MultiVariant( + WeightedList.of( + (List>)IntStream.range(1, 5) + .mapToObj(i -> new Weighted<>(plainModel(ModelLocationUtils.getModelLocation(Blocks.BAMBOO, i + string)), 1)) + .collect(Collectors.toList()) + ) + ); } private void createBamboo() { this.blockStateOutput .accept( MultiPartGenerator.multiPart(Blocks.BAMBOO) - .with(Condition.condition().term(BlockStateProperties.AGE_1, 0), this.createBambooModels(0)) - .with(Condition.condition().term(BlockStateProperties.AGE_1, 1), this.createBambooModels(1)) + .with(condition().term(BlockStateProperties.AGE_1, 0), createBambooModels(0)) + .with(condition().term(BlockStateProperties.AGE_1, 1), createBambooModels(1)) .with( - Condition.condition().term(BlockStateProperties.BAMBOO_LEAVES, BambooLeaves.SMALL), - Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.BAMBOO, "_small_leaves")) + condition().term(BlockStateProperties.BAMBOO_LEAVES, BambooLeaves.SMALL), + plainVariant(ModelLocationUtils.getModelLocation(Blocks.BAMBOO, "_small_leaves")) ) .with( - Condition.condition().term(BlockStateProperties.BAMBOO_LEAVES, BambooLeaves.LARGE), - Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.BAMBOO, "_large_leaves")) + condition().term(BlockStateProperties.BAMBOO_LEAVES, BambooLeaves.LARGE), + plainVariant(ModelLocationUtils.getModelLocation(Blocks.BAMBOO, "_large_leaves")) ) ); } - private PropertyDispatch createColumnWithFacing() { - return PropertyDispatch.property(BlockStateProperties.FACING) - .select(Direction.DOWN, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180)) - .select(Direction.UP, Variant.variant()) - .select(Direction.NORTH, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90)) - .select( - Direction.SOUTH, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.WEST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - Direction.EAST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ); - } - private void createBarrel() { ResourceLocation resourceLocation = TextureMapping.getBlockTexture(Blocks.BARREL, "_top_open"); + MultiVariant multiVariant = plainVariant(TexturedModel.CUBE_TOP_BOTTOM.create(Blocks.BARREL, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant( + TexturedModel.CUBE_TOP_BOTTOM + .get(Blocks.BARREL) + .updateTextures(textureMapping -> textureMapping.put(TextureSlot.TOP, resourceLocation)) + .createWithSuffix(Blocks.BARREL, "_open", this.modelOutput) + ); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.BARREL) - .with(this.createColumnWithFacing()) - .with( - PropertyDispatch.property(BlockStateProperties.OPEN) - .select(false, Variant.variant().with(VariantProperties.MODEL, TexturedModel.CUBE_TOP_BOTTOM.create(Blocks.BARREL, this.modelOutput))) - .select( - true, - Variant.variant() - .with( - VariantProperties.MODEL, - TexturedModel.CUBE_TOP_BOTTOM - .get(Blocks.BARREL) - .updateTextures(textureMapping -> textureMapping.put(TextureSlot.TOP, resourceLocation)) - .createWithSuffix(Blocks.BARREL, "_open", this.modelOutput) - ) - ) - ) + MultiVariantGenerator.dispatch(Blocks.BARREL) + .with(PropertyDispatch.initial(BlockStateProperties.OPEN).select(false, multiVariant).select(true, multiVariant2)) + .with(ROTATIONS_COLUMN_WITH_FACING) ); } - private static > PropertyDispatch createEmptyOrFullDispatch( - Property property, T minimumValueForFullVariant, ResourceLocation fullVariantModelLocation, ResourceLocation emptyVariantModelLocation + private static > PropertyDispatch createEmptyOrFullDispatch( + Property property, T threshold, MultiVariant full, MultiVariant empty ) { - Variant variant = Variant.variant().with(VariantProperties.MODEL, fullVariantModelLocation); - Variant variant2 = Variant.variant().with(VariantProperties.MODEL, emptyVariantModelLocation); - return PropertyDispatch.property(property).generate(comparable2 -> { - boolean bl = comparable2.compareTo(minimumValueForFullVariant) >= 0; - return bl ? variant : variant2; + return PropertyDispatch.initial(property).generate(comparable2 -> { + boolean bl = comparable2.compareTo(threshold) >= 0; + return bl ? full : empty; }); } @@ -2029,107 +1316,68 @@ public class BlockModelGenerators { ); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(beeNestBlock) - .with(createHorizontalFacingDispatch()) - .with(createEmptyOrFullDispatch(BeehiveBlock.HONEY_LEVEL, 5, resourceLocation2, resourceLocation)) + MultiVariantGenerator.dispatch(beeNestBlock) + .with(createEmptyOrFullDispatch(BeehiveBlock.HONEY_LEVEL, 5, plainVariant(resourceLocation2), plainVariant(resourceLocation))) + .with(ROTATION_HORIZONTAL_FACING) ); } private void createCropBlock(Block cropBlock, Property ageProperty, int... ageToVisualStageMapping) { + this.registerSimpleFlatItemModel(cropBlock.asItem()); if (ageProperty.getPossibleValues().size() != ageToVisualStageMapping.length) { throw new IllegalArgumentException(); } else { Int2ObjectMap int2ObjectMap = new Int2ObjectOpenHashMap<>(); - PropertyDispatch propertyDispatch = PropertyDispatch.property(ageProperty) - .generate( - integer -> { - int i = ageToVisualStageMapping[integer]; - ResourceLocation resourceLocation = int2ObjectMap.computeIfAbsent( - i, (Int2ObjectFunction)(j -> this.createSuffixedVariant(cropBlock, "_stage" + i, ModelTemplates.CROP, TextureMapping::crop)) - ); - return Variant.variant().with(VariantProperties.MODEL, resourceLocation); - } + this.blockStateOutput + .accept( + MultiVariantGenerator.dispatch(cropBlock) + .with( + PropertyDispatch.initial(ageProperty) + .generate( + integer -> { + int i = ageToVisualStageMapping[integer]; + return plainVariant( + int2ObjectMap.computeIfAbsent( + i, + (Int2ObjectFunction)(ix -> this.createSuffixedVariant( + cropBlock, "_stage" + ix, ModelTemplates.CROP, TextureMapping::crop + )) + ) + ); + } + ) + ) ); - this.registerSimpleFlatItemModel(cropBlock.asItem()); - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(cropBlock).with(propertyDispatch)); } } private void createBell() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.BELL, "_floor"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.BELL, "_ceiling"); - ResourceLocation resourceLocation3 = ModelLocationUtils.getModelLocation(Blocks.BELL, "_wall"); - ResourceLocation resourceLocation4 = ModelLocationUtils.getModelLocation(Blocks.BELL, "_between_walls"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.BELL, "_floor")); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.BELL, "_ceiling")); + MultiVariant multiVariant3 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.BELL, "_wall")); + MultiVariant multiVariant4 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.BELL, "_between_walls")); this.registerSimpleFlatItemModel(Items.BELL); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.BELL) + MultiVariantGenerator.dispatch(Blocks.BELL) .with( - PropertyDispatch.properties(BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.BELL_ATTACHMENT) - .select(Direction.NORTH, BellAttachType.FLOOR, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select( - Direction.SOUTH, - BellAttachType.FLOOR, - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.EAST, - BellAttachType.FLOOR, - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - BellAttachType.FLOOR, - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(Direction.NORTH, BellAttachType.CEILING, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select( - Direction.SOUTH, - BellAttachType.CEILING, - Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.EAST, - BellAttachType.CEILING, - Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.WEST, - BellAttachType.CEILING, - Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - Direction.NORTH, - BellAttachType.SINGLE_WALL, - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - Direction.SOUTH, - BellAttachType.SINGLE_WALL, - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select(Direction.EAST, BellAttachType.SINGLE_WALL, Variant.variant().with(VariantProperties.MODEL, resourceLocation3)) - .select( - Direction.WEST, - BellAttachType.SINGLE_WALL, - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.SOUTH, - BellAttachType.DOUBLE_WALL, - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - Direction.NORTH, - BellAttachType.DOUBLE_WALL, - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(Direction.EAST, BellAttachType.DOUBLE_WALL, Variant.variant().with(VariantProperties.MODEL, resourceLocation4)) - .select( - Direction.WEST, - BellAttachType.DOUBLE_WALL, - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) + PropertyDispatch.initial(BlockStateProperties.HORIZONTAL_FACING, BlockStateProperties.BELL_ATTACHMENT) + .select(Direction.NORTH, BellAttachType.FLOOR, multiVariant) + .select(Direction.SOUTH, BellAttachType.FLOOR, multiVariant.with(Y_ROT_180)) + .select(Direction.EAST, BellAttachType.FLOOR, multiVariant.with(Y_ROT_90)) + .select(Direction.WEST, BellAttachType.FLOOR, multiVariant.with(Y_ROT_270)) + .select(Direction.NORTH, BellAttachType.CEILING, multiVariant2) + .select(Direction.SOUTH, BellAttachType.CEILING, multiVariant2.with(Y_ROT_180)) + .select(Direction.EAST, BellAttachType.CEILING, multiVariant2.with(Y_ROT_90)) + .select(Direction.WEST, BellAttachType.CEILING, multiVariant2.with(Y_ROT_270)) + .select(Direction.NORTH, BellAttachType.SINGLE_WALL, multiVariant3.with(Y_ROT_270)) + .select(Direction.SOUTH, BellAttachType.SINGLE_WALL, multiVariant3.with(Y_ROT_90)) + .select(Direction.EAST, BellAttachType.SINGLE_WALL, multiVariant3) + .select(Direction.WEST, BellAttachType.SINGLE_WALL, multiVariant3.with(Y_ROT_180)) + .select(Direction.SOUTH, BellAttachType.DOUBLE_WALL, multiVariant4.with(Y_ROT_90)) + .select(Direction.NORTH, BellAttachType.DOUBLE_WALL, multiVariant4.with(Y_ROT_270)) + .select(Direction.EAST, BellAttachType.DOUBLE_WALL, multiVariant4) + .select(Direction.WEST, BellAttachType.DOUBLE_WALL, multiVariant4.with(Y_ROT_180)) ) ); } @@ -2137,100 +1385,78 @@ public class BlockModelGenerators { private void createGrindstone() { this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant( - Blocks.GRINDSTONE, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.GRINDSTONE)) - ) + MultiVariantGenerator.dispatch(Blocks.GRINDSTONE, plainVariant(ModelLocationUtils.getModelLocation(Blocks.GRINDSTONE))) .with( - PropertyDispatch.properties(BlockStateProperties.ATTACH_FACE, BlockStateProperties.HORIZONTAL_FACING) - .select(AttachFace.FLOOR, Direction.NORTH, Variant.variant()) - .select(AttachFace.FLOOR, Direction.EAST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select(AttachFace.FLOOR, Direction.SOUTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) - .select(AttachFace.FLOOR, Direction.WEST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)) - .select(AttachFace.WALL, Direction.NORTH, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90)) - .select( - AttachFace.WALL, - Direction.EAST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - AttachFace.WALL, - Direction.SOUTH, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - AttachFace.WALL, - Direction.WEST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(AttachFace.CEILING, Direction.SOUTH, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180)) - .select( - AttachFace.CEILING, - Direction.WEST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - AttachFace.CEILING, - Direction.NORTH, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - AttachFace.CEILING, - Direction.EAST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) + PropertyDispatch.modify(BlockStateProperties.ATTACH_FACE, BlockStateProperties.HORIZONTAL_FACING) + .select(AttachFace.FLOOR, Direction.NORTH, NOP) + .select(AttachFace.FLOOR, Direction.EAST, Y_ROT_90) + .select(AttachFace.FLOOR, Direction.SOUTH, Y_ROT_180) + .select(AttachFace.FLOOR, Direction.WEST, Y_ROT_270) + .select(AttachFace.WALL, Direction.NORTH, X_ROT_90) + .select(AttachFace.WALL, Direction.EAST, X_ROT_90.then(Y_ROT_90)) + .select(AttachFace.WALL, Direction.SOUTH, X_ROT_90.then(Y_ROT_180)) + .select(AttachFace.WALL, Direction.WEST, X_ROT_90.then(Y_ROT_270)) + .select(AttachFace.CEILING, Direction.SOUTH, X_ROT_180) + .select(AttachFace.CEILING, Direction.WEST, X_ROT_180.then(Y_ROT_90)) + .select(AttachFace.CEILING, Direction.NORTH, X_ROT_180.then(Y_ROT_180)) + .select(AttachFace.CEILING, Direction.EAST, X_ROT_180.then(Y_ROT_270)) ) ); } private void createFurnace(Block furnaceBlock, TexturedModel.Provider modelProvider) { - ResourceLocation resourceLocation = modelProvider.create(furnaceBlock, this.modelOutput); - ResourceLocation resourceLocation2 = TextureMapping.getBlockTexture(furnaceBlock, "_front_on"); - ResourceLocation resourceLocation3 = modelProvider.get(furnaceBlock) - .updateTextures(textureMapping -> textureMapping.put(TextureSlot.FRONT, resourceLocation2)) - .createWithSuffix(furnaceBlock, "_on", this.modelOutput); + MultiVariant multiVariant = plainVariant(modelProvider.create(furnaceBlock, this.modelOutput)); + ResourceLocation resourceLocation = TextureMapping.getBlockTexture(furnaceBlock, "_front_on"); + MultiVariant multiVariant2 = plainVariant( + modelProvider.get(furnaceBlock) + .updateTextures(textureMapping -> textureMapping.put(TextureSlot.FRONT, resourceLocation)) + .createWithSuffix(furnaceBlock, "_on", this.modelOutput) + ); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(furnaceBlock) - .with(createBooleanModelDispatch(BlockStateProperties.LIT, resourceLocation3, resourceLocation)) - .with(createHorizontalFacingDispatch()) + MultiVariantGenerator.dispatch(furnaceBlock) + .with(createBooleanModelDispatch(BlockStateProperties.LIT, multiVariant2, multiVariant)) + .with(ROTATION_HORIZONTAL_FACING) ); } private void createCampfires(Block... campfireBlocks) { - ResourceLocation resourceLocation = ModelLocationUtils.decorateBlockModelLocation("campfire_off"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.decorateBlockModelLocation("campfire_off")); for (Block block : campfireBlocks) { - ResourceLocation resourceLocation2 = ModelTemplates.CAMPFIRE.create(block, TextureMapping.campfire(block), this.modelOutput); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.CAMPFIRE.create(block, TextureMapping.campfire(block), this.modelOutput)); this.registerSimpleFlatItemModel(block.asItem()); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(block) - .with(createBooleanModelDispatch(BlockStateProperties.LIT, resourceLocation2, resourceLocation)) - .with(createHorizontalFacingDispatchAlt()) + MultiVariantGenerator.dispatch(block) + .with(createBooleanModelDispatch(BlockStateProperties.LIT, multiVariant2, multiVariant)) + .with(ROTATION_HORIZONTAL_FACING_ALT) ); } } private void createAzalea(Block azaleaBlock) { - ResourceLocation resourceLocation = ModelTemplates.AZALEA.create(azaleaBlock, TextureMapping.cubeTop(azaleaBlock), this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(azaleaBlock, resourceLocation)); + MultiVariant multiVariant = plainVariant(ModelTemplates.AZALEA.create(azaleaBlock, TextureMapping.cubeTop(azaleaBlock), this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(azaleaBlock, multiVariant)); } private void createPottedAzalea(Block pottedAzaleaBlock) { - ResourceLocation resourceLocation; + MultiVariant multiVariant; if (pottedAzaleaBlock == Blocks.POTTED_FLOWERING_AZALEA) { - resourceLocation = ModelTemplates.POTTED_FLOWERING_AZALEA.create(pottedAzaleaBlock, TextureMapping.pottedAzalea(pottedAzaleaBlock), this.modelOutput); + multiVariant = plainVariant( + ModelTemplates.POTTED_FLOWERING_AZALEA.create(pottedAzaleaBlock, TextureMapping.pottedAzalea(pottedAzaleaBlock), this.modelOutput) + ); } else { - resourceLocation = ModelTemplates.POTTED_AZALEA.create(pottedAzaleaBlock, TextureMapping.pottedAzalea(pottedAzaleaBlock), this.modelOutput); + multiVariant = plainVariant(ModelTemplates.POTTED_AZALEA.create(pottedAzaleaBlock, TextureMapping.pottedAzalea(pottedAzaleaBlock), this.modelOutput)); } - this.blockStateOutput.accept(createSimpleBlock(pottedAzaleaBlock, resourceLocation)); + this.blockStateOutput.accept(createSimpleBlock(pottedAzaleaBlock, multiVariant)); } private void createBookshelf() { TextureMapping textureMapping = TextureMapping.column(TextureMapping.getBlockTexture(Blocks.BOOKSHELF), TextureMapping.getBlockTexture(Blocks.OAK_PLANKS)); - ResourceLocation resourceLocation = ModelTemplates.CUBE_COLUMN.create(Blocks.BOOKSHELF, textureMapping, this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(Blocks.BOOKSHELF, resourceLocation)); + MultiVariant multiVariant = plainVariant(ModelTemplates.CUBE_COLUMN.create(Blocks.BOOKSHELF, textureMapping, this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(Blocks.BOOKSHELF, multiVariant)); } private void createRedstoneWire() { @@ -2239,68 +1465,57 @@ public class BlockModelGenerators { .accept( MultiPartGenerator.multiPart(Blocks.REDSTONE_WIRE) .with( - Condition.or( - Condition.condition() + or( + condition() .term(BlockStateProperties.NORTH_REDSTONE, RedstoneSide.NONE) .term(BlockStateProperties.EAST_REDSTONE, RedstoneSide.NONE) .term(BlockStateProperties.SOUTH_REDSTONE, RedstoneSide.NONE) .term(BlockStateProperties.WEST_REDSTONE, RedstoneSide.NONE), - Condition.condition() + condition() .term(BlockStateProperties.NORTH_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP) .term(BlockStateProperties.EAST_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), - Condition.condition() + condition() .term(BlockStateProperties.EAST_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP) .term(BlockStateProperties.SOUTH_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), - Condition.condition() + condition() .term(BlockStateProperties.SOUTH_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP) .term(BlockStateProperties.WEST_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), - Condition.condition() + condition() .term(BlockStateProperties.WEST_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP) .term(BlockStateProperties.NORTH_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP) ), - Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_dot")) + plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_dot")) ) .with( - Condition.condition().term(BlockStateProperties.NORTH_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), - Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_side0")) + condition().term(BlockStateProperties.NORTH_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), + plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_side0")) ) .with( - Condition.condition().term(BlockStateProperties.SOUTH_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), - Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_side_alt0")) + condition().term(BlockStateProperties.SOUTH_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), + plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_side_alt0")) ) .with( - Condition.condition().term(BlockStateProperties.EAST_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_side_alt1")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) + condition().term(BlockStateProperties.EAST_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), + plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_side_alt1")).with(Y_ROT_270) ) .with( - Condition.condition().term(BlockStateProperties.WEST_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_side1")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) + condition().term(BlockStateProperties.WEST_REDSTONE, RedstoneSide.SIDE, RedstoneSide.UP), + plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_side1")).with(Y_ROT_270) ) .with( - Condition.condition().term(BlockStateProperties.NORTH_REDSTONE, RedstoneSide.UP), - Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_up")) + condition().term(BlockStateProperties.NORTH_REDSTONE, RedstoneSide.UP), plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_up")) ) .with( - Condition.condition().term(BlockStateProperties.EAST_REDSTONE, RedstoneSide.UP), - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_up")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) + condition().term(BlockStateProperties.EAST_REDSTONE, RedstoneSide.UP), + plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_up")).with(Y_ROT_90) ) .with( - Condition.condition().term(BlockStateProperties.SOUTH_REDSTONE, RedstoneSide.UP), - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_up")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) + condition().term(BlockStateProperties.SOUTH_REDSTONE, RedstoneSide.UP), + plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_up")).with(Y_ROT_180) ) .with( - Condition.condition().term(BlockStateProperties.WEST_REDSTONE, RedstoneSide.UP), - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.decorateBlockModelLocation("redstone_dust_up")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) + condition().term(BlockStateProperties.WEST_REDSTONE, RedstoneSide.UP), + plainVariant(ModelLocationUtils.decorateBlockModelLocation("redstone_dust_up")).with(Y_ROT_270) ) ); } @@ -2309,30 +1524,29 @@ public class BlockModelGenerators { this.registerSimpleFlatItemModel(Items.COMPARATOR); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.COMPARATOR) - .with(createHorizontalFacingDispatchAlt()) + MultiVariantGenerator.dispatch(Blocks.COMPARATOR) .with( - PropertyDispatch.properties(BlockStateProperties.MODE_COMPARATOR, BlockStateProperties.POWERED) - .select(ComparatorMode.COMPARE, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.COMPARATOR))) - .select(ComparatorMode.COMPARE, true, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.COMPARATOR, "_on"))) - .select( - ComparatorMode.SUBTRACT, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.COMPARATOR, "_subtract")) - ) - .select( - ComparatorMode.SUBTRACT, true, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.COMPARATOR, "_on_subtract")) - ) + PropertyDispatch.initial(BlockStateProperties.MODE_COMPARATOR, BlockStateProperties.POWERED) + .select(ComparatorMode.COMPARE, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.COMPARATOR))) + .select(ComparatorMode.COMPARE, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.COMPARATOR, "_on"))) + .select(ComparatorMode.SUBTRACT, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.COMPARATOR, "_subtract"))) + .select(ComparatorMode.SUBTRACT, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.COMPARATOR, "_on_subtract"))) ) + .with(ROTATION_HORIZONTAL_FACING_ALT) ); } private void createSmoothStoneSlab() { TextureMapping textureMapping = TextureMapping.cube(Blocks.SMOOTH_STONE); TextureMapping textureMapping2 = TextureMapping.column(TextureMapping.getBlockTexture(Blocks.SMOOTH_STONE_SLAB, "_side"), textureMapping.get(TextureSlot.TOP)); - ResourceLocation resourceLocation = ModelTemplates.SLAB_BOTTOM.create(Blocks.SMOOTH_STONE_SLAB, textureMapping2, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.SLAB_TOP.create(Blocks.SMOOTH_STONE_SLAB, textureMapping2, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.CUBE_COLUMN.createWithOverride(Blocks.SMOOTH_STONE_SLAB, "_double", textureMapping2, this.modelOutput); - this.blockStateOutput.accept(createSlab(Blocks.SMOOTH_STONE_SLAB, resourceLocation, resourceLocation2, resourceLocation3)); - this.blockStateOutput.accept(createSimpleBlock(Blocks.SMOOTH_STONE, ModelTemplates.CUBE_ALL.create(Blocks.SMOOTH_STONE, textureMapping, this.modelOutput))); + MultiVariant multiVariant = plainVariant(ModelTemplates.SLAB_BOTTOM.create(Blocks.SMOOTH_STONE_SLAB, textureMapping2, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.SLAB_TOP.create(Blocks.SMOOTH_STONE_SLAB, textureMapping2, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant( + ModelTemplates.CUBE_COLUMN.createWithOverride(Blocks.SMOOTH_STONE_SLAB, "_double", textureMapping2, this.modelOutput) + ); + this.blockStateOutput.accept(createSlab(Blocks.SMOOTH_STONE_SLAB, multiVariant, multiVariant2, multiVariant3)); + this.blockStateOutput + .accept(createSimpleBlock(Blocks.SMOOTH_STONE, plainVariant(ModelTemplates.CUBE_ALL.create(Blocks.SMOOTH_STONE, textureMapping, this.modelOutput)))); } private void createBrewingStand() { @@ -2340,112 +1554,34 @@ public class BlockModelGenerators { this.blockStateOutput .accept( MultiPartGenerator.multiPart(Blocks.BREWING_STAND) - .with(Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.BREWING_STAND))) - .with( - Condition.condition().term(BlockStateProperties.HAS_BOTTLE_0, true), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_bottle0")) - ) - .with( - Condition.condition().term(BlockStateProperties.HAS_BOTTLE_1, true), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_bottle1")) - ) - .with( - Condition.condition().term(BlockStateProperties.HAS_BOTTLE_2, true), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_bottle2")) - ) - .with( - Condition.condition().term(BlockStateProperties.HAS_BOTTLE_0, false), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_empty0")) - ) - .with( - Condition.condition().term(BlockStateProperties.HAS_BOTTLE_1, false), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_empty1")) - ) - .with( - Condition.condition().term(BlockStateProperties.HAS_BOTTLE_2, false), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_empty2")) - ) + .with(plainVariant(TextureMapping.getBlockTexture(Blocks.BREWING_STAND))) + .with(condition().term(BlockStateProperties.HAS_BOTTLE_0, true), plainVariant(TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_bottle0"))) + .with(condition().term(BlockStateProperties.HAS_BOTTLE_1, true), plainVariant(TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_bottle1"))) + .with(condition().term(BlockStateProperties.HAS_BOTTLE_2, true), plainVariant(TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_bottle2"))) + .with(condition().term(BlockStateProperties.HAS_BOTTLE_0, false), plainVariant(TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_empty0"))) + .with(condition().term(BlockStateProperties.HAS_BOTTLE_1, false), plainVariant(TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_empty1"))) + .with(condition().term(BlockStateProperties.HAS_BOTTLE_2, false), plainVariant(TextureMapping.getBlockTexture(Blocks.BREWING_STAND, "_empty2"))) ); } private void createMushroomBlock(Block mushroomBlock) { - ResourceLocation resourceLocation = ModelTemplates.SINGLE_FACE.create(mushroomBlock, TextureMapping.defaultTexture(mushroomBlock), this.modelOutput); - ResourceLocation resourceLocation2 = ModelLocationUtils.decorateBlockModelLocation("mushroom_block_inside"); + MultiVariant multiVariant = plainVariant(ModelTemplates.SINGLE_FACE.create(mushroomBlock, TextureMapping.defaultTexture(mushroomBlock), this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.decorateBlockModelLocation("mushroom_block_inside")); this.blockStateOutput .accept( MultiPartGenerator.multiPart(mushroomBlock) - .with(Condition.condition().term(BlockStateProperties.NORTH, true), Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .with( - Condition.condition().term(BlockStateProperties.EAST, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.SOUTH, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.WEST, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.UP, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.DOWN, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .with(Condition.condition().term(BlockStateProperties.NORTH, false), Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .with( - Condition.condition().term(BlockStateProperties.EAST, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, false) - ) - .with( - Condition.condition().term(BlockStateProperties.SOUTH, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, false) - ) - .with( - Condition.condition().term(BlockStateProperties.WEST, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, false) - ) - .with( - Condition.condition().term(BlockStateProperties.UP, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, false) - ) - .with( - Condition.condition().term(BlockStateProperties.DOWN, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, false) - ) + .with(condition().term(BlockStateProperties.NORTH, true), multiVariant) + .with(condition().term(BlockStateProperties.EAST, true), multiVariant.with(Y_ROT_90).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.SOUTH, true), multiVariant.with(Y_ROT_180).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.WEST, true), multiVariant.with(Y_ROT_270).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.UP, true), multiVariant.with(X_ROT_270).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.DOWN, true), multiVariant.with(X_ROT_90).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.NORTH, false), multiVariant2) + .with(condition().term(BlockStateProperties.EAST, false), multiVariant2.with(Y_ROT_90)) + .with(condition().term(BlockStateProperties.SOUTH, false), multiVariant2.with(Y_ROT_180)) + .with(condition().term(BlockStateProperties.WEST, false), multiVariant2.with(Y_ROT_270)) + .with(condition().term(BlockStateProperties.UP, false), multiVariant2.with(X_ROT_270)) + .with(condition().term(BlockStateProperties.DOWN, false), multiVariant2.with(X_ROT_90)) ); this.registerSimpleItemModel(mushroomBlock, TexturedModel.CUBE.createWithSuffix(mushroomBlock, "_inventory", this.modelOutput)); } @@ -2454,16 +1590,16 @@ public class BlockModelGenerators { this.registerSimpleFlatItemModel(Items.CAKE); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.CAKE) + MultiVariantGenerator.dispatch(Blocks.CAKE) .with( - PropertyDispatch.property(BlockStateProperties.BITES) - .select(0, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.CAKE))) - .select(1, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice1"))) - .select(2, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice2"))) - .select(3, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice3"))) - .select(4, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice4"))) - .select(5, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice5"))) - .select(6, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice6"))) + PropertyDispatch.initial(BlockStateProperties.BITES) + .select(0, plainVariant(ModelLocationUtils.getModelLocation(Blocks.CAKE))) + .select(1, plainVariant(ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice1"))) + .select(2, plainVariant(ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice2"))) + .select(3, plainVariant(ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice3"))) + .select(4, plainVariant(ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice4"))) + .select(5, plainVariant(ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice5"))) + .select(6, plainVariant(ModelLocationUtils.getModelLocation(Blocks.CAKE, "_slice6"))) ) ); } @@ -2478,7 +1614,7 @@ public class BlockModelGenerators { .put(TextureSlot.SOUTH, TextureMapping.getBlockTexture(Blocks.CARTOGRAPHY_TABLE, "_side1")) .put(TextureSlot.WEST, TextureMapping.getBlockTexture(Blocks.CARTOGRAPHY_TABLE, "_side2")); this.blockStateOutput - .accept(createSimpleBlock(Blocks.CARTOGRAPHY_TABLE, ModelTemplates.CUBE.create(Blocks.CARTOGRAPHY_TABLE, textureMapping, this.modelOutput))); + .accept(createSimpleBlock(Blocks.CARTOGRAPHY_TABLE, plainVariant(ModelTemplates.CUBE.create(Blocks.CARTOGRAPHY_TABLE, textureMapping, this.modelOutput)))); } private void createSmithingTable() { @@ -2490,12 +1626,14 @@ public class BlockModelGenerators { .put(TextureSlot.SOUTH, TextureMapping.getBlockTexture(Blocks.SMITHING_TABLE, "_front")) .put(TextureSlot.EAST, TextureMapping.getBlockTexture(Blocks.SMITHING_TABLE, "_side")) .put(TextureSlot.WEST, TextureMapping.getBlockTexture(Blocks.SMITHING_TABLE, "_side")); - this.blockStateOutput.accept(createSimpleBlock(Blocks.SMITHING_TABLE, ModelTemplates.CUBE.create(Blocks.SMITHING_TABLE, textureMapping, this.modelOutput))); + this.blockStateOutput + .accept(createSimpleBlock(Blocks.SMITHING_TABLE, plainVariant(ModelTemplates.CUBE.create(Blocks.SMITHING_TABLE, textureMapping, this.modelOutput)))); } private void createCraftingTableLike(Block craftingTableBlock, Block craftingTableMaterialBlock, BiFunction textureMappingGetter) { TextureMapping textureMapping = (TextureMapping)textureMappingGetter.apply(craftingTableBlock, craftingTableMaterialBlock); - this.blockStateOutput.accept(createSimpleBlock(craftingTableBlock, ModelTemplates.CUBE.create(craftingTableBlock, textureMapping, this.modelOutput))); + this.blockStateOutput + .accept(createSimpleBlock(craftingTableBlock, plainVariant(ModelTemplates.CUBE.create(craftingTableBlock, textureMapping, this.modelOutput)))); } public void createGenericCube(Block block) { @@ -2507,23 +1645,22 @@ public class BlockModelGenerators { .put(TextureSlot.SOUTH, TextureMapping.getBlockTexture(block, "_south")) .put(TextureSlot.EAST, TextureMapping.getBlockTexture(block, "_east")) .put(TextureSlot.WEST, TextureMapping.getBlockTexture(block, "_west")); - this.blockStateOutput.accept(createSimpleBlock(block, ModelTemplates.CUBE.create(block, textureMapping, this.modelOutput))); + this.blockStateOutput.accept(createSimpleBlock(block, plainVariant(ModelTemplates.CUBE.create(block, textureMapping, this.modelOutput)))); } private void createPumpkins() { TextureMapping textureMapping = TextureMapping.column(Blocks.PUMPKIN); - this.blockStateOutput.accept(createSimpleBlock(Blocks.PUMPKIN, ModelLocationUtils.getModelLocation(Blocks.PUMPKIN))); + this.blockStateOutput.accept(createSimpleBlock(Blocks.PUMPKIN, plainVariant(ModelLocationUtils.getModelLocation(Blocks.PUMPKIN)))); this.createPumpkinVariant(Blocks.CARVED_PUMPKIN, textureMapping); this.createPumpkinVariant(Blocks.JACK_O_LANTERN, textureMapping); } private void createPumpkinVariant(Block pumpkinBlock, TextureMapping columnTextureMapping) { - ResourceLocation resourceLocation = ModelTemplates.CUBE_ORIENTABLE - .create(pumpkinBlock, columnTextureMapping.copyAndUpdate(TextureSlot.FRONT, TextureMapping.getBlockTexture(pumpkinBlock)), this.modelOutput); - this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(pumpkinBlock, Variant.variant().with(VariantProperties.MODEL, resourceLocation)).with(createHorizontalFacingDispatch()) - ); + MultiVariant multiVariant = plainVariant( + ModelTemplates.CUBE_ORIENTABLE + .create(pumpkinBlock, columnTextureMapping.copyAndUpdate(TextureSlot.FRONT, TextureMapping.getBlockTexture(pumpkinBlock)), this.modelOutput) + ); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(pumpkinBlock, multiVariant).with(ROTATION_HORIZONTAL_FACING)); } private void createCauldrons() { @@ -2533,85 +1670,69 @@ public class BlockModelGenerators { .accept( createSimpleBlock( Blocks.LAVA_CAULDRON, - ModelTemplates.CAULDRON_FULL - .create(Blocks.LAVA_CAULDRON, TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.LAVA, "_still")), this.modelOutput) + plainVariant( + ModelTemplates.CAULDRON_FULL + .create(Blocks.LAVA_CAULDRON, TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.LAVA, "_still")), this.modelOutput) + ) ) ); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.WATER_CAULDRON) + MultiVariantGenerator.dispatch(Blocks.WATER_CAULDRON) .with( - PropertyDispatch.property(LayeredCauldronBlock.LEVEL) + PropertyDispatch.initial(LayeredCauldronBlock.LEVEL) .select( 1, - Variant.variant() - .with( - VariantProperties.MODEL, - ModelTemplates.CAULDRON_LEVEL1 - .createWithSuffix( - Blocks.WATER_CAULDRON, "_level1", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.WATER, "_still")), this.modelOutput - ) - ) + plainVariant( + ModelTemplates.CAULDRON_LEVEL1 + .createWithSuffix(Blocks.WATER_CAULDRON, "_level1", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.WATER, "_still")), this.modelOutput) + ) ) .select( 2, - Variant.variant() - .with( - VariantProperties.MODEL, - ModelTemplates.CAULDRON_LEVEL2 - .createWithSuffix( - Blocks.WATER_CAULDRON, "_level2", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.WATER, "_still")), this.modelOutput - ) - ) + plainVariant( + ModelTemplates.CAULDRON_LEVEL2 + .createWithSuffix(Blocks.WATER_CAULDRON, "_level2", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.WATER, "_still")), this.modelOutput) + ) ) .select( 3, - Variant.variant() - .with( - VariantProperties.MODEL, - ModelTemplates.CAULDRON_FULL - .createWithSuffix(Blocks.WATER_CAULDRON, "_full", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.WATER, "_still")), this.modelOutput) - ) + plainVariant( + ModelTemplates.CAULDRON_FULL + .createWithSuffix(Blocks.WATER_CAULDRON, "_full", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.WATER, "_still")), this.modelOutput) + ) ) ) ); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.POWDER_SNOW_CAULDRON) + MultiVariantGenerator.dispatch(Blocks.POWDER_SNOW_CAULDRON) .with( - PropertyDispatch.property(LayeredCauldronBlock.LEVEL) + PropertyDispatch.initial(LayeredCauldronBlock.LEVEL) .select( 1, - Variant.variant() - .with( - VariantProperties.MODEL, - ModelTemplates.CAULDRON_LEVEL1 - .createWithSuffix( - Blocks.POWDER_SNOW_CAULDRON, "_level1", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.POWDER_SNOW)), this.modelOutput - ) - ) + plainVariant( + ModelTemplates.CAULDRON_LEVEL1 + .createWithSuffix( + Blocks.POWDER_SNOW_CAULDRON, "_level1", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.POWDER_SNOW)), this.modelOutput + ) + ) ) .select( 2, - Variant.variant() - .with( - VariantProperties.MODEL, - ModelTemplates.CAULDRON_LEVEL2 - .createWithSuffix( - Blocks.POWDER_SNOW_CAULDRON, "_level2", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.POWDER_SNOW)), this.modelOutput - ) - ) + plainVariant( + ModelTemplates.CAULDRON_LEVEL2 + .createWithSuffix( + Blocks.POWDER_SNOW_CAULDRON, "_level2", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.POWDER_SNOW)), this.modelOutput + ) + ) ) .select( 3, - Variant.variant() - .with( - VariantProperties.MODEL, - ModelTemplates.CAULDRON_FULL - .createWithSuffix( - Blocks.POWDER_SNOW_CAULDRON, "_full", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.POWDER_SNOW)), this.modelOutput - ) - ) + plainVariant( + ModelTemplates.CAULDRON_FULL + .createWithSuffix(Blocks.POWDER_SNOW_CAULDRON, "_full", TextureMapping.cauldron(TextureMapping.getBlockTexture(Blocks.POWDER_SNOW)), this.modelOutput) + ) ) ) ); @@ -2619,33 +1740,32 @@ public class BlockModelGenerators { private void createChorusFlower() { TextureMapping textureMapping = TextureMapping.defaultTexture(Blocks.CHORUS_FLOWER); - ResourceLocation resourceLocation = ModelTemplates.CHORUS_FLOWER.create(Blocks.CHORUS_FLOWER, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = this.createSuffixedVariant( - Blocks.CHORUS_FLOWER, "_dead", ModelTemplates.CHORUS_FLOWER, resourceLocationx -> textureMapping.copyAndUpdate(TextureSlot.TEXTURE, resourceLocationx) + MultiVariant multiVariant = plainVariant(ModelTemplates.CHORUS_FLOWER.create(Blocks.CHORUS_FLOWER, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant( + this.createSuffixedVariant( + Blocks.CHORUS_FLOWER, "_dead", ModelTemplates.CHORUS_FLOWER, resourceLocation -> textureMapping.copyAndUpdate(TextureSlot.TEXTURE, resourceLocation) + ) ); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.CHORUS_FLOWER) - .with(createEmptyOrFullDispatch(BlockStateProperties.AGE_5, 5, resourceLocation2, resourceLocation)) - ); + .accept(MultiVariantGenerator.dispatch(Blocks.CHORUS_FLOWER).with(createEmptyOrFullDispatch(BlockStateProperties.AGE_5, 5, multiVariant2, multiVariant))); } private void createCrafterBlock() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.CRAFTER); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.CRAFTER, "_triggered"); - ResourceLocation resourceLocation3 = ModelLocationUtils.getModelLocation(Blocks.CRAFTER, "_crafting"); - ResourceLocation resourceLocation4 = ModelLocationUtils.getModelLocation(Blocks.CRAFTER, "_crafting_triggered"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.CRAFTER)); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.CRAFTER, "_triggered")); + MultiVariant multiVariant3 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.CRAFTER, "_crafting")); + MultiVariant multiVariant4 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.CRAFTER, "_crafting_triggered")); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.CRAFTER) - .with(PropertyDispatch.property(BlockStateProperties.ORIENTATION).generate(frontAndTop -> this.applyRotation(frontAndTop, Variant.variant()))) + MultiVariantGenerator.dispatch(Blocks.CRAFTER) .with( - PropertyDispatch.properties(BlockStateProperties.TRIGGERED, CrafterBlock.CRAFTING) - .select(false, false, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(true, true, Variant.variant().with(VariantProperties.MODEL, resourceLocation4)) - .select(true, false, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select(false, true, Variant.variant().with(VariantProperties.MODEL, resourceLocation3)) + PropertyDispatch.initial(BlockStateProperties.TRIGGERED, CrafterBlock.CRAFTING) + .select(false, false, multiVariant) + .select(true, true, multiVariant4) + .select(true, false, multiVariant2) + .select(false, true, multiVariant3) ) + .with(PropertyDispatch.modify(BlockStateProperties.ORIENTATION).generate(BlockModelGenerators::applyRotation)) ); } @@ -2657,193 +1777,111 @@ public class BlockModelGenerators { TextureMapping textureMapping2 = new TextureMapping() .put(TextureSlot.SIDE, TextureMapping.getBlockTexture(Blocks.FURNACE, "_top")) .put(TextureSlot.FRONT, TextureMapping.getBlockTexture(dispenserBlock, "_front_vertical")); - ResourceLocation resourceLocation = ModelTemplates.CUBE_ORIENTABLE.create(dispenserBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.CUBE_ORIENTABLE_VERTICAL.create(dispenserBlock, textureMapping2, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.CUBE_ORIENTABLE.create(dispenserBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.CUBE_ORIENTABLE_VERTICAL.create(dispenserBlock, textureMapping2, this.modelOutput)); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(dispenserBlock) + MultiVariantGenerator.dispatch(dispenserBlock) .with( - PropertyDispatch.property(BlockStateProperties.FACING) - .select( - Direction.DOWN, Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.X_ROT, VariantProperties.Rotation.R180) - ) - .select(Direction.UP, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select(Direction.NORTH, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(Direction.EAST, Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select( - Direction.SOUTH, Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select(Direction.WEST, Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)) + PropertyDispatch.initial(BlockStateProperties.FACING) + .select(Direction.DOWN, multiVariant2.with(X_ROT_180)) + .select(Direction.UP, multiVariant2) + .select(Direction.NORTH, multiVariant) + .select(Direction.EAST, multiVariant.with(Y_ROT_90)) + .select(Direction.SOUTH, multiVariant.with(Y_ROT_180)) + .select(Direction.WEST, multiVariant.with(Y_ROT_270)) ) ); } private void createEndPortalFrame() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.END_PORTAL_FRAME); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.END_PORTAL_FRAME, "_filled"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.END_PORTAL_FRAME)); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.END_PORTAL_FRAME, "_filled")); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.END_PORTAL_FRAME) - .with( - PropertyDispatch.property(BlockStateProperties.EYE) - .select(false, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(true, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - ) - .with(createHorizontalFacingDispatchAlt()) + MultiVariantGenerator.dispatch(Blocks.END_PORTAL_FRAME) + .with(PropertyDispatch.initial(BlockStateProperties.EYE).select(false, multiVariant).select(true, multiVariant2)) + .with(ROTATION_HORIZONTAL_FACING_ALT) ); } private void createChorusPlant() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_side"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_noside"); - ResourceLocation resourceLocation3 = ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_noside1"); - ResourceLocation resourceLocation4 = ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_noside2"); - ResourceLocation resourceLocation5 = ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_noside3"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_side")); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_noside")); + net.minecraft.client.renderer.block.model.Variant variant2 = plainModel(ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_noside1")); + net.minecraft.client.renderer.block.model.Variant variant3 = plainModel(ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_noside2")); + net.minecraft.client.renderer.block.model.Variant variant4 = plainModel(ModelLocationUtils.getModelLocation(Blocks.CHORUS_PLANT, "_noside3")); + net.minecraft.client.renderer.block.model.Variant variant5 = variant.with(UV_LOCK); + net.minecraft.client.renderer.block.model.Variant variant6 = variant2.with(UV_LOCK); + net.minecraft.client.renderer.block.model.Variant variant7 = variant3.with(UV_LOCK); + net.minecraft.client.renderer.block.model.Variant variant8 = variant4.with(UV_LOCK); this.blockStateOutput .accept( MultiPartGenerator.multiPart(Blocks.CHORUS_PLANT) - .with(Condition.condition().term(BlockStateProperties.NORTH, true), Variant.variant().with(VariantProperties.MODEL, resourceLocation)) + .with(condition().term(BlockStateProperties.NORTH, true), multiVariant) + .with(condition().term(BlockStateProperties.EAST, true), multiVariant.with(Y_ROT_90).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.SOUTH, true), multiVariant.with(Y_ROT_180).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.WEST, true), multiVariant.with(Y_ROT_270).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.UP, true), multiVariant.with(X_ROT_270).with(UV_LOCK)) + .with(condition().term(BlockStateProperties.DOWN, true), multiVariant.with(X_ROT_90).with(UV_LOCK)) .with( - Condition.condition().term(BlockStateProperties.EAST, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) + condition().term(BlockStateProperties.NORTH, false), + new MultiVariant(WeightedList.of(new Weighted<>(variant, 2), new Weighted<>(variant2, 1), new Weighted<>(variant3, 1), new Weighted<>(variant4, 1))) ) .with( - Condition.condition().term(BlockStateProperties.SOUTH, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) + condition().term(BlockStateProperties.EAST, false), + new MultiVariant( + WeightedList.of( + new Weighted<>(variant6.with(Y_ROT_90), 1), + new Weighted<>(variant7.with(Y_ROT_90), 1), + new Weighted<>(variant8.with(Y_ROT_90), 1), + new Weighted<>(variant5.with(Y_ROT_90), 2) + ) + ) ) .with( - Condition.condition().term(BlockStateProperties.WEST, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) + condition().term(BlockStateProperties.SOUTH, false), + new MultiVariant( + WeightedList.of( + new Weighted<>(variant7.with(Y_ROT_180), 1), + new Weighted<>(variant8.with(Y_ROT_180), 1), + new Weighted<>(variant5.with(Y_ROT_180), 2), + new Weighted<>(variant6.with(Y_ROT_180), 1) + ) + ) ) .with( - Condition.condition().term(BlockStateProperties.UP, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) + condition().term(BlockStateProperties.WEST, false), + new MultiVariant( + WeightedList.of( + new Weighted<>(variant8.with(Y_ROT_270), 1), + new Weighted<>(variant5.with(Y_ROT_270), 2), + new Weighted<>(variant6.with(Y_ROT_270), 1), + new Weighted<>(variant7.with(Y_ROT_270), 1) + ) + ) ) .with( - Condition.condition().term(BlockStateProperties.DOWN, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) + condition().term(BlockStateProperties.UP, false), + new MultiVariant( + WeightedList.of( + new Weighted<>(variant5.with(X_ROT_270), 2), + new Weighted<>(variant8.with(X_ROT_270), 1), + new Weighted<>(variant6.with(X_ROT_270), 1), + new Weighted<>(variant7.with(X_ROT_270), 1) + ) + ) ) .with( - Condition.condition().term(BlockStateProperties.NORTH, false), - Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.WEIGHT, 2), - Variant.variant().with(VariantProperties.MODEL, resourceLocation3), - Variant.variant().with(VariantProperties.MODEL, resourceLocation4), - Variant.variant().with(VariantProperties.MODEL, resourceLocation5) - ) - .with( - Condition.condition().term(BlockStateProperties.EAST, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation3) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation4) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation5) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.WEIGHT, 2) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.SOUTH, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation4) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation5) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.WEIGHT, 2) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation3) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.WEST, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation5) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.WEIGHT, 2) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation3) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation4) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.UP, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.WEIGHT, 2) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation5) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation3) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation4) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.UV_LOCK, true) - ) - .with( - Condition.condition().term(BlockStateProperties.DOWN, false), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation5) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation4) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation3) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation2) - .with(VariantProperties.WEIGHT, 2) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.UV_LOCK, true) + condition().term(BlockStateProperties.DOWN, false), + new MultiVariant( + WeightedList.of( + new Weighted<>(variant8.with(X_ROT_90), 1), + new Weighted<>(variant7.with(X_ROT_90), 1), + new Weighted<>(variant6.with(X_ROT_90), 1), + new Weighted<>(variant5.with(X_ROT_90), 2) + ) + ) ) ); } @@ -2852,82 +1890,51 @@ public class BlockModelGenerators { this.blockStateOutput .accept( MultiPartGenerator.multiPart(Blocks.COMPOSTER) - .with(Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER))) - .with( - Condition.condition().term(BlockStateProperties.LEVEL_COMPOSTER, 1), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents1")) - ) - .with( - Condition.condition().term(BlockStateProperties.LEVEL_COMPOSTER, 2), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents2")) - ) - .with( - Condition.condition().term(BlockStateProperties.LEVEL_COMPOSTER, 3), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents3")) - ) - .with( - Condition.condition().term(BlockStateProperties.LEVEL_COMPOSTER, 4), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents4")) - ) - .with( - Condition.condition().term(BlockStateProperties.LEVEL_COMPOSTER, 5), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents5")) - ) - .with( - Condition.condition().term(BlockStateProperties.LEVEL_COMPOSTER, 6), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents6")) - ) - .with( - Condition.condition().term(BlockStateProperties.LEVEL_COMPOSTER, 7), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents7")) - ) - .with( - Condition.condition().term(BlockStateProperties.LEVEL_COMPOSTER, 8), - Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents_ready")) - ) + .with(plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER))) + .with(condition().term(BlockStateProperties.LEVEL_COMPOSTER, 1), plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents1"))) + .with(condition().term(BlockStateProperties.LEVEL_COMPOSTER, 2), plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents2"))) + .with(condition().term(BlockStateProperties.LEVEL_COMPOSTER, 3), plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents3"))) + .with(condition().term(BlockStateProperties.LEVEL_COMPOSTER, 4), plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents4"))) + .with(condition().term(BlockStateProperties.LEVEL_COMPOSTER, 5), plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents5"))) + .with(condition().term(BlockStateProperties.LEVEL_COMPOSTER, 6), plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents6"))) + .with(condition().term(BlockStateProperties.LEVEL_COMPOSTER, 7), plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents7"))) + .with(condition().term(BlockStateProperties.LEVEL_COMPOSTER, 8), plainVariant(TextureMapping.getBlockTexture(Blocks.COMPOSTER, "_contents_ready"))) ); } private void createCopperBulb(Block bulbBlock) { - ResourceLocation resourceLocation = ModelTemplates.CUBE_ALL.create(bulbBlock, TextureMapping.cube(bulbBlock), this.modelOutput); - ResourceLocation resourceLocation2 = this.createSuffixedVariant(bulbBlock, "_powered", ModelTemplates.CUBE_ALL, TextureMapping::cube); - ResourceLocation resourceLocation3 = this.createSuffixedVariant(bulbBlock, "_lit", ModelTemplates.CUBE_ALL, TextureMapping::cube); - ResourceLocation resourceLocation4 = this.createSuffixedVariant(bulbBlock, "_lit_powered", ModelTemplates.CUBE_ALL, TextureMapping::cube); - this.blockStateOutput.accept(this.createCopperBulb(bulbBlock, resourceLocation, resourceLocation3, resourceLocation2, resourceLocation4)); + MultiVariant multiVariant = plainVariant(ModelTemplates.CUBE_ALL.create(bulbBlock, TextureMapping.cube(bulbBlock), this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(this.createSuffixedVariant(bulbBlock, "_powered", ModelTemplates.CUBE_ALL, TextureMapping::cube)); + MultiVariant multiVariant3 = plainVariant(this.createSuffixedVariant(bulbBlock, "_lit", ModelTemplates.CUBE_ALL, TextureMapping::cube)); + MultiVariant multiVariant4 = plainVariant(this.createSuffixedVariant(bulbBlock, "_lit_powered", ModelTemplates.CUBE_ALL, TextureMapping::cube)); + this.blockStateOutput.accept(createCopperBulb(bulbBlock, multiVariant, multiVariant3, multiVariant2, multiVariant4)); } - private BlockStateGenerator createCopperBulb( - Block bulbBlock, ResourceLocation unlit, ResourceLocation unlitPowered, ResourceLocation lit, ResourceLocation litPowered + private static BlockModelDefinitionGenerator createCopperBulb( + Block block, MultiVariant unlit, MultiVariant unlitPowered, MultiVariant lit, MultiVariant litPowered ) { - return MultiVariantGenerator.multiVariant(bulbBlock) - .with( - PropertyDispatch.properties(BlockStateProperties.LIT, BlockStateProperties.POWERED) - .generate( - (boolean_, boolean2) -> boolean_ - ? Variant.variant().with(VariantProperties.MODEL, boolean2 ? litPowered : unlitPowered) - : Variant.variant().with(VariantProperties.MODEL, boolean2 ? lit : unlit) - ) - ); + return MultiVariantGenerator.dispatch(block) + .with(PropertyDispatch.initial(BlockStateProperties.LIT, BlockStateProperties.POWERED).generate((boolean_, boolean2) -> { + if (boolean_) { + return boolean2 ? litPowered : unlitPowered; + } else { + return boolean2 ? lit : unlit; + } + })); } private void copyCopperBulbModel(Block bulbBlock, Block sourceBlock) { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(bulbBlock); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(bulbBlock, "_powered"); - ResourceLocation resourceLocation3 = ModelLocationUtils.getModelLocation(bulbBlock, "_lit"); - ResourceLocation resourceLocation4 = ModelLocationUtils.getModelLocation(bulbBlock, "_lit_powered"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(bulbBlock)); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(bulbBlock, "_powered")); + MultiVariant multiVariant3 = plainVariant(ModelLocationUtils.getModelLocation(bulbBlock, "_lit")); + MultiVariant multiVariant4 = plainVariant(ModelLocationUtils.getModelLocation(bulbBlock, "_lit_powered")); this.itemModelOutput.copy(bulbBlock.asItem(), sourceBlock.asItem()); - this.blockStateOutput.accept(this.createCopperBulb(sourceBlock, resourceLocation, resourceLocation3, resourceLocation2, resourceLocation4)); + this.blockStateOutput.accept(createCopperBulb(sourceBlock, multiVariant, multiVariant3, multiVariant2, multiVariant4)); } private void createAmethystCluster(Block amethystBlock) { - this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant( - amethystBlock, - Variant.variant().with(VariantProperties.MODEL, ModelTemplates.CROSS.create(amethystBlock, TextureMapping.cross(amethystBlock), this.modelOutput)) - ) - .with(this.createColumnWithFacing()) - ); + MultiVariant multiVariant = plainVariant(ModelTemplates.CROSS.create(amethystBlock, TextureMapping.cross(amethystBlock), this.modelOutput)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(amethystBlock, multiVariant).with(ROTATIONS_COLUMN_WITH_FACING)); } private void createAmethystClusters() { @@ -2938,7 +1945,7 @@ public class BlockModelGenerators { } private void createPointedDripstone() { - PropertyDispatch.C2 c2 = PropertyDispatch.properties( + PropertyDispatch.C2 c2 = PropertyDispatch.initial( BlockStateProperties.VERTICAL_DIRECTION, BlockStateProperties.DRIPSTONE_THICKNESS ); @@ -2950,14 +1957,13 @@ public class BlockModelGenerators { c2.select(Direction.DOWN, dripstoneThickness, this.createPointedDripstoneVariant(Direction.DOWN, dripstoneThickness)); } - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(Blocks.POINTED_DRIPSTONE).with(c2)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(Blocks.POINTED_DRIPSTONE).with(c2)); } - private Variant createPointedDripstoneVariant(Direction direction, DripstoneThickness dripstoneThickness) { - String string = "_" + direction.getSerializedName() + "_" + dripstoneThickness.getSerializedName(); + private MultiVariant createPointedDripstoneVariant(Direction direction, DripstoneThickness thickness) { + String string = "_" + direction.getSerializedName() + "_" + thickness.getSerializedName(); TextureMapping textureMapping = TextureMapping.cross(TextureMapping.getBlockTexture(Blocks.POINTED_DRIPSTONE, string)); - return Variant.variant() - .with(VariantProperties.MODEL, ModelTemplates.POINTED_DRIPSTONE.createWithSuffix(Blocks.POINTED_DRIPSTONE, string, textureMapping, this.modelOutput)); + return plainVariant(ModelTemplates.POINTED_DRIPSTONE.createWithSuffix(Blocks.POINTED_DRIPSTONE, string, textureMapping, this.modelOutput)); } private void createNyliumBlock(Block nyliumBlock) { @@ -2965,7 +1971,8 @@ public class BlockModelGenerators { .put(TextureSlot.BOTTOM, TextureMapping.getBlockTexture(Blocks.NETHERRACK)) .put(TextureSlot.TOP, TextureMapping.getBlockTexture(nyliumBlock)) .put(TextureSlot.SIDE, TextureMapping.getBlockTexture(nyliumBlock, "_side")); - this.blockStateOutput.accept(createSimpleBlock(nyliumBlock, ModelTemplates.CUBE_BOTTOM_TOP.create(nyliumBlock, textureMapping, this.modelOutput))); + this.blockStateOutput + .accept(createSimpleBlock(nyliumBlock, plainVariant(ModelTemplates.CUBE_BOTTOM_TOP.create(nyliumBlock, textureMapping, this.modelOutput)))); } private void createDaylightDetector() { @@ -2978,21 +1985,15 @@ public class BlockModelGenerators { .put(TextureSlot.SIDE, resourceLocation); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.DAYLIGHT_DETECTOR) + MultiVariantGenerator.dispatch(Blocks.DAYLIGHT_DETECTOR) .with( - PropertyDispatch.property(BlockStateProperties.INVERTED) - .select( - false, - Variant.variant().with(VariantProperties.MODEL, ModelTemplates.DAYLIGHT_DETECTOR.create(Blocks.DAYLIGHT_DETECTOR, textureMapping, this.modelOutput)) - ) + PropertyDispatch.initial(BlockStateProperties.INVERTED) + .select(false, plainVariant(ModelTemplates.DAYLIGHT_DETECTOR.create(Blocks.DAYLIGHT_DETECTOR, textureMapping, this.modelOutput))) .select( true, - Variant.variant() - .with( - VariantProperties.MODEL, - ModelTemplates.DAYLIGHT_DETECTOR - .create(ModelLocationUtils.getModelLocation(Blocks.DAYLIGHT_DETECTOR, "_inverted"), textureMapping2, this.modelOutput) - ) + plainVariant( + ModelTemplates.DAYLIGHT_DETECTOR.create(ModelLocationUtils.getModelLocation(Blocks.DAYLIGHT_DETECTOR, "_inverted"), textureMapping2, this.modelOutput) + ) ) ) ); @@ -3001,22 +2002,20 @@ public class BlockModelGenerators { private void createRotatableColumn(Block rotatableColumnBlock) { this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant( - rotatableColumnBlock, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(rotatableColumnBlock)) - ) - .with(this.createColumnWithFacing()) + MultiVariantGenerator.dispatch(rotatableColumnBlock, plainVariant(ModelLocationUtils.getModelLocation(rotatableColumnBlock))) + .with(ROTATIONS_COLUMN_WITH_FACING) ); } private void createLightningRod() { Block block = Blocks.LIGHTNING_ROD; - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(block, "_on"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(block); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(block, "_on")); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(block)); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(block, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(block))) - .with(this.createColumnWithFacing()) - .with(createBooleanModelDispatch(BlockStateProperties.POWERED, resourceLocation, resourceLocation2)) + MultiVariantGenerator.dispatch(block) + .with(createBooleanModelDispatch(BlockStateProperties.POWERED, multiVariant, multiVariant2)) + .with(ROTATIONS_COLUMN_WITH_FACING) ); } @@ -3027,148 +2026,115 @@ public class BlockModelGenerators { TextureMapping textureMapping2 = new TextureMapping() .put(TextureSlot.DIRT, TextureMapping.getBlockTexture(Blocks.DIRT)) .put(TextureSlot.TOP, TextureMapping.getBlockTexture(Blocks.FARMLAND, "_moist")); - ResourceLocation resourceLocation = ModelTemplates.FARMLAND.create(Blocks.FARMLAND, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.FARMLAND - .create(TextureMapping.getBlockTexture(Blocks.FARMLAND, "_moist"), textureMapping2, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.FARMLAND.create(Blocks.FARMLAND, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant( + ModelTemplates.FARMLAND.create(TextureMapping.getBlockTexture(Blocks.FARMLAND, "_moist"), textureMapping2, this.modelOutput) + ); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.FARMLAND).with(createEmptyOrFullDispatch(BlockStateProperties.MOISTURE, 7, resourceLocation2, resourceLocation)) - ); + .accept(MultiVariantGenerator.dispatch(Blocks.FARMLAND).with(createEmptyOrFullDispatch(BlockStateProperties.MOISTURE, 7, multiVariant2, multiVariant))); } - private List createFloorFireModels(Block fireBlock) { - ResourceLocation resourceLocation = ModelTemplates.FIRE_FLOOR - .create(ModelLocationUtils.getModelLocation(fireBlock, "_floor0"), TextureMapping.fire0(fireBlock), this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.FIRE_FLOOR - .create(ModelLocationUtils.getModelLocation(fireBlock, "_floor1"), TextureMapping.fire1(fireBlock), this.modelOutput); - return ImmutableList.of(resourceLocation, resourceLocation2); + private MultiVariant createFloorFireModels(Block block) { + return variants( + plainModel(ModelTemplates.FIRE_FLOOR.create(ModelLocationUtils.getModelLocation(block, "_floor0"), TextureMapping.fire0(block), this.modelOutput)), + plainModel(ModelTemplates.FIRE_FLOOR.create(ModelLocationUtils.getModelLocation(block, "_floor1"), TextureMapping.fire1(block), this.modelOutput)) + ); } - private List createSideFireModels(Block fireBlock) { - ResourceLocation resourceLocation = ModelTemplates.FIRE_SIDE - .create(ModelLocationUtils.getModelLocation(fireBlock, "_side0"), TextureMapping.fire0(fireBlock), this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.FIRE_SIDE - .create(ModelLocationUtils.getModelLocation(fireBlock, "_side1"), TextureMapping.fire1(fireBlock), this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.FIRE_SIDE_ALT - .create(ModelLocationUtils.getModelLocation(fireBlock, "_side_alt0"), TextureMapping.fire0(fireBlock), this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.FIRE_SIDE_ALT - .create(ModelLocationUtils.getModelLocation(fireBlock, "_side_alt1"), TextureMapping.fire1(fireBlock), this.modelOutput); - return ImmutableList.of(resourceLocation, resourceLocation2, resourceLocation3, resourceLocation4); + private MultiVariant createSideFireModels(Block block) { + return variants( + plainModel(ModelTemplates.FIRE_SIDE.create(ModelLocationUtils.getModelLocation(block, "_side0"), TextureMapping.fire0(block), this.modelOutput)), + plainModel(ModelTemplates.FIRE_SIDE.create(ModelLocationUtils.getModelLocation(block, "_side1"), TextureMapping.fire1(block), this.modelOutput)), + plainModel(ModelTemplates.FIRE_SIDE_ALT.create(ModelLocationUtils.getModelLocation(block, "_side_alt0"), TextureMapping.fire0(block), this.modelOutput)), + plainModel(ModelTemplates.FIRE_SIDE_ALT.create(ModelLocationUtils.getModelLocation(block, "_side_alt1"), TextureMapping.fire1(block), this.modelOutput)) + ); } - private List createTopFireModels(Block fireBlock) { - ResourceLocation resourceLocation = ModelTemplates.FIRE_UP - .create(ModelLocationUtils.getModelLocation(fireBlock, "_up0"), TextureMapping.fire0(fireBlock), this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.FIRE_UP - .create(ModelLocationUtils.getModelLocation(fireBlock, "_up1"), TextureMapping.fire1(fireBlock), this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.FIRE_UP_ALT - .create(ModelLocationUtils.getModelLocation(fireBlock, "_up_alt0"), TextureMapping.fire0(fireBlock), this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.FIRE_UP_ALT - .create(ModelLocationUtils.getModelLocation(fireBlock, "_up_alt1"), TextureMapping.fire1(fireBlock), this.modelOutput); - return ImmutableList.of(resourceLocation, resourceLocation2, resourceLocation3, resourceLocation4); - } - - private static List wrapModels(List modelLocations, UnaryOperator variantMapper) { - return (List)modelLocations.stream() - .map(resourceLocation -> Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .map(variantMapper) - .collect(Collectors.toList()); + private MultiVariant createTopFireModels(Block block) { + return variants( + plainModel(ModelTemplates.FIRE_UP.create(ModelLocationUtils.getModelLocation(block, "_up0"), TextureMapping.fire0(block), this.modelOutput)), + plainModel(ModelTemplates.FIRE_UP.create(ModelLocationUtils.getModelLocation(block, "_up1"), TextureMapping.fire1(block), this.modelOutput)), + plainModel(ModelTemplates.FIRE_UP_ALT.create(ModelLocationUtils.getModelLocation(block, "_up_alt0"), TextureMapping.fire0(block), this.modelOutput)), + plainModel(ModelTemplates.FIRE_UP_ALT.create(ModelLocationUtils.getModelLocation(block, "_up_alt1"), TextureMapping.fire1(block), this.modelOutput)) + ); } private void createFire() { - Condition condition = Condition.condition() + ConditionBuilder conditionBuilder = condition() .term(BlockStateProperties.NORTH, false) .term(BlockStateProperties.EAST, false) .term(BlockStateProperties.SOUTH, false) .term(BlockStateProperties.WEST, false) .term(BlockStateProperties.UP, false); - List list = this.createFloorFireModels(Blocks.FIRE); - List list2 = this.createSideFireModels(Blocks.FIRE); - List list3 = this.createTopFireModels(Blocks.FIRE); + MultiVariant multiVariant = this.createFloorFireModels(Blocks.FIRE); + MultiVariant multiVariant2 = this.createSideFireModels(Blocks.FIRE); + MultiVariant multiVariant3 = this.createTopFireModels(Blocks.FIRE); this.blockStateOutput .accept( MultiPartGenerator.multiPart(Blocks.FIRE) - .with(condition, wrapModels(list, variant -> variant)) - .with(Condition.or(Condition.condition().term(BlockStateProperties.NORTH, true), condition), wrapModels(list2, variant -> variant)) - .with( - Condition.or(Condition.condition().term(BlockStateProperties.EAST, true), condition), - wrapModels(list2, variant -> variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - ) - .with( - Condition.or(Condition.condition().term(BlockStateProperties.SOUTH, true), condition), - wrapModels(list2, variant -> variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) - ) - .with( - Condition.or(Condition.condition().term(BlockStateProperties.WEST, true), condition), - wrapModels(list2, variant -> variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)) - ) - .with(Condition.condition().term(BlockStateProperties.UP, true), wrapModels(list3, variant -> variant)) + .with(conditionBuilder, multiVariant) + .with(or(condition().term(BlockStateProperties.NORTH, true), conditionBuilder), multiVariant2) + .with(or(condition().term(BlockStateProperties.EAST, true), conditionBuilder), multiVariant2.with(Y_ROT_90)) + .with(or(condition().term(BlockStateProperties.SOUTH, true), conditionBuilder), multiVariant2.with(Y_ROT_180)) + .with(or(condition().term(BlockStateProperties.WEST, true), conditionBuilder), multiVariant2.with(Y_ROT_270)) + .with(condition().term(BlockStateProperties.UP, true), multiVariant3) ); } private void createSoulFire() { - List list = this.createFloorFireModels(Blocks.SOUL_FIRE); - List list2 = this.createSideFireModels(Blocks.SOUL_FIRE); + MultiVariant multiVariant = this.createFloorFireModels(Blocks.SOUL_FIRE); + MultiVariant multiVariant2 = this.createSideFireModels(Blocks.SOUL_FIRE); this.blockStateOutput .accept( MultiPartGenerator.multiPart(Blocks.SOUL_FIRE) - .with(wrapModels(list, variant -> variant)) - .with(wrapModels(list2, variant -> variant)) - .with(wrapModels(list2, variant -> variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90))) - .with(wrapModels(list2, variant -> variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180))) - .with(wrapModels(list2, variant -> variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270))) + .with(multiVariant) + .with(multiVariant2) + .with(multiVariant2.with(Y_ROT_90)) + .with(multiVariant2.with(Y_ROT_180)) + .with(multiVariant2.with(Y_ROT_270)) ); } private void createLantern(Block lanternBlock) { - ResourceLocation resourceLocation = TexturedModel.LANTERN.create(lanternBlock, this.modelOutput); - ResourceLocation resourceLocation2 = TexturedModel.HANGING_LANTERN.create(lanternBlock, this.modelOutput); + MultiVariant multiVariant = plainVariant(TexturedModel.LANTERN.create(lanternBlock, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(TexturedModel.HANGING_LANTERN.create(lanternBlock, this.modelOutput)); this.registerSimpleFlatItemModel(lanternBlock.asItem()); this.blockStateOutput - .accept(MultiVariantGenerator.multiVariant(lanternBlock).with(createBooleanModelDispatch(BlockStateProperties.HANGING, resourceLocation2, resourceLocation))); + .accept(MultiVariantGenerator.dispatch(lanternBlock).with(createBooleanModelDispatch(BlockStateProperties.HANGING, multiVariant2, multiVariant))); } private void createMuddyMangroveRoots() { TextureMapping textureMapping = TextureMapping.column( TextureMapping.getBlockTexture(Blocks.MUDDY_MANGROVE_ROOTS, "_side"), TextureMapping.getBlockTexture(Blocks.MUDDY_MANGROVE_ROOTS, "_top") ); - ResourceLocation resourceLocation = ModelTemplates.CUBE_COLUMN.create(Blocks.MUDDY_MANGROVE_ROOTS, textureMapping, this.modelOutput); - this.blockStateOutput.accept(createAxisAlignedPillarBlock(Blocks.MUDDY_MANGROVE_ROOTS, resourceLocation)); + MultiVariant multiVariant = plainVariant(ModelTemplates.CUBE_COLUMN.create(Blocks.MUDDY_MANGROVE_ROOTS, textureMapping, this.modelOutput)); + this.blockStateOutput.accept(createAxisAlignedPillarBlock(Blocks.MUDDY_MANGROVE_ROOTS, multiVariant)); } private void createMangrovePropagule() { this.registerSimpleFlatItemModel(Items.MANGROVE_PROPAGULE); Block block = Blocks.MANGROVE_PROPAGULE; - PropertyDispatch.C2 c2 = PropertyDispatch.properties(MangrovePropaguleBlock.HANGING, MangrovePropaguleBlock.AGE); - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(block); - - for (int i = 0; i <= 4; i++) { - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(block, "_hanging_" + i); - c2.select(true, i, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)); - c2.select(false, i, Variant.variant().with(VariantProperties.MODEL, resourceLocation)); - } - - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(Blocks.MANGROVE_PROPAGULE).with(c2)); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(block)); + this.blockStateOutput + .accept( + MultiVariantGenerator.dispatch(Blocks.MANGROVE_PROPAGULE) + .with( + PropertyDispatch.initial(MangrovePropaguleBlock.HANGING, MangrovePropaguleBlock.AGE) + .generate((boolean_, integer) -> boolean_ ? plainVariant(ModelLocationUtils.getModelLocation(block, "_hanging_" + integer)) : multiVariant) + ) + ); } private void createFrostedIce() { this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.FROSTED_ICE) + MultiVariantGenerator.dispatch(Blocks.FROSTED_ICE) .with( - PropertyDispatch.property(BlockStateProperties.AGE_3) - .select( - 0, Variant.variant().with(VariantProperties.MODEL, this.createSuffixedVariant(Blocks.FROSTED_ICE, "_0", ModelTemplates.CUBE_ALL, TextureMapping::cube)) - ) - .select( - 1, Variant.variant().with(VariantProperties.MODEL, this.createSuffixedVariant(Blocks.FROSTED_ICE, "_1", ModelTemplates.CUBE_ALL, TextureMapping::cube)) - ) - .select( - 2, Variant.variant().with(VariantProperties.MODEL, this.createSuffixedVariant(Blocks.FROSTED_ICE, "_2", ModelTemplates.CUBE_ALL, TextureMapping::cube)) - ) - .select( - 3, Variant.variant().with(VariantProperties.MODEL, this.createSuffixedVariant(Blocks.FROSTED_ICE, "_3", ModelTemplates.CUBE_ALL, TextureMapping::cube)) - ) + PropertyDispatch.initial(BlockStateProperties.AGE_3) + .select(0, plainVariant(this.createSuffixedVariant(Blocks.FROSTED_ICE, "_0", ModelTemplates.CUBE_ALL, TextureMapping::cube))) + .select(1, plainVariant(this.createSuffixedVariant(Blocks.FROSTED_ICE, "_1", ModelTemplates.CUBE_ALL, TextureMapping::cube))) + .select(2, plainVariant(this.createSuffixedVariant(Blocks.FROSTED_ICE, "_2", ModelTemplates.CUBE_ALL, TextureMapping::cube))) + .select(3, plainVariant(this.createSuffixedVariant(Blocks.FROSTED_ICE, "_3", ModelTemplates.CUBE_ALL, TextureMapping::cube))) ) ); } @@ -3180,206 +2146,173 @@ public class BlockModelGenerators { .copyForced(TextureSlot.BOTTOM, TextureSlot.PARTICLE) .put(TextureSlot.TOP, TextureMapping.getBlockTexture(Blocks.GRASS_BLOCK, "_top")) .put(TextureSlot.SIDE, TextureMapping.getBlockTexture(Blocks.GRASS_BLOCK, "_snow")); - Variant variant = Variant.variant() - .with(VariantProperties.MODEL, ModelTemplates.CUBE_BOTTOM_TOP.createWithSuffix(Blocks.GRASS_BLOCK, "_snow", textureMapping, this.modelOutput)); - this.createGrassLikeBlock(Blocks.GRASS_BLOCK, ModelLocationUtils.getModelLocation(Blocks.GRASS_BLOCK), variant); - this.registerSimpleTintedItemModel(Blocks.GRASS_BLOCK, ModelLocationUtils.getModelLocation(Blocks.GRASS_BLOCK), new GrassColorSource()); - ResourceLocation resourceLocation2 = TexturedModel.CUBE_TOP_BOTTOM - .get(Blocks.MYCELIUM) - .updateTextures(textureMappingx -> textureMappingx.put(TextureSlot.BOTTOM, resourceLocation)) - .create(Blocks.MYCELIUM, this.modelOutput); - this.createGrassLikeBlock(Blocks.MYCELIUM, resourceLocation2, variant); - ResourceLocation resourceLocation3 = TexturedModel.CUBE_TOP_BOTTOM - .get(Blocks.PODZOL) - .updateTextures(textureMappingx -> textureMappingx.put(TextureSlot.BOTTOM, resourceLocation)) - .create(Blocks.PODZOL, this.modelOutput); - this.createGrassLikeBlock(Blocks.PODZOL, resourceLocation3, variant); + MultiVariant multiVariant = plainVariant(ModelTemplates.CUBE_BOTTOM_TOP.createWithSuffix(Blocks.GRASS_BLOCK, "_snow", textureMapping, this.modelOutput)); + ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.GRASS_BLOCK); + this.createGrassLikeBlock(Blocks.GRASS_BLOCK, createRotatedVariants(plainModel(resourceLocation2)), multiVariant); + this.registerSimpleTintedItemModel(Blocks.GRASS_BLOCK, resourceLocation2, new GrassColorSource()); + MultiVariant multiVariant2 = createRotatedVariants( + plainModel( + TexturedModel.CUBE_TOP_BOTTOM + .get(Blocks.MYCELIUM) + .updateTextures(textureMappingx -> textureMappingx.put(TextureSlot.BOTTOM, resourceLocation)) + .create(Blocks.MYCELIUM, this.modelOutput) + ) + ); + this.createGrassLikeBlock(Blocks.MYCELIUM, multiVariant2, multiVariant); + MultiVariant multiVariant3 = createRotatedVariants( + plainModel( + TexturedModel.CUBE_TOP_BOTTOM + .get(Blocks.PODZOL) + .updateTextures(textureMappingx -> textureMappingx.put(TextureSlot.BOTTOM, resourceLocation)) + .create(Blocks.PODZOL, this.modelOutput) + ) + ); + this.createGrassLikeBlock(Blocks.PODZOL, multiVariant3, multiVariant); } - private void createGrassLikeBlock(Block grassLikeBlock, ResourceLocation modelLocation, Variant variant) { - List list = Arrays.asList(createRotatedVariants(modelLocation)); + private void createGrassLikeBlock(Block block, MultiVariant variants, MultiVariant snowyVariants) { this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(grassLikeBlock).with(PropertyDispatch.property(BlockStateProperties.SNOWY).select(true, variant).select(false, list)) - ); + .accept(MultiVariantGenerator.dispatch(block).with(PropertyDispatch.initial(BlockStateProperties.SNOWY).select(true, snowyVariants).select(false, variants))); } private void createCocoa() { this.registerSimpleFlatItemModel(Items.COCOA_BEANS); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.COCOA) + MultiVariantGenerator.dispatch(Blocks.COCOA) .with( - PropertyDispatch.property(BlockStateProperties.AGE_2) - .select(0, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.COCOA, "_stage0"))) - .select(1, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.COCOA, "_stage1"))) - .select(2, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.COCOA, "_stage2"))) + PropertyDispatch.initial(BlockStateProperties.AGE_2) + .select(0, plainVariant(ModelLocationUtils.getModelLocation(Blocks.COCOA, "_stage0"))) + .select(1, plainVariant(ModelLocationUtils.getModelLocation(Blocks.COCOA, "_stage1"))) + .select(2, plainVariant(ModelLocationUtils.getModelLocation(Blocks.COCOA, "_stage2"))) ) - .with(createHorizontalFacingDispatchAlt()) + .with(ROTATION_HORIZONTAL_FACING_ALT) ); } private void createDirtPath() { - this.blockStateOutput.accept(createRotatedVariant(Blocks.DIRT_PATH, ModelLocationUtils.getModelLocation(Blocks.DIRT_PATH))); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(ModelLocationUtils.getModelLocation(Blocks.DIRT_PATH)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(Blocks.DIRT_PATH, createRotatedVariants(variant))); } private void createWeightedPressurePlate(Block pressurePlateBlock, Block plateMaterialBlock) { TextureMapping textureMapping = TextureMapping.defaultTexture(plateMaterialBlock); - ResourceLocation resourceLocation = ModelTemplates.PRESSURE_PLATE_UP.create(pressurePlateBlock, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.PRESSURE_PLATE_DOWN.create(pressurePlateBlock, textureMapping, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.PRESSURE_PLATE_UP.create(pressurePlateBlock, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.PRESSURE_PLATE_DOWN.create(pressurePlateBlock, textureMapping, this.modelOutput)); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(pressurePlateBlock).with(createEmptyOrFullDispatch(BlockStateProperties.POWER, 1, resourceLocation2, resourceLocation)) - ); + .accept(MultiVariantGenerator.dispatch(pressurePlateBlock).with(createEmptyOrFullDispatch(BlockStateProperties.POWER, 1, multiVariant2, multiVariant))); } private void createHopper() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.HOPPER); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.HOPPER, "_side"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.HOPPER)); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.HOPPER, "_side")); this.registerSimpleFlatItemModel(Items.HOPPER); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.HOPPER) + MultiVariantGenerator.dispatch(Blocks.HOPPER) .with( - PropertyDispatch.property(BlockStateProperties.FACING_HOPPER) - .select(Direction.DOWN, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(Direction.NORTH, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select(Direction.EAST, Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select( - Direction.SOUTH, Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - Direction.WEST, Variant.variant().with(VariantProperties.MODEL, resourceLocation2).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) + PropertyDispatch.initial(BlockStateProperties.FACING_HOPPER) + .select(Direction.DOWN, multiVariant) + .select(Direction.NORTH, multiVariant2) + .select(Direction.EAST, multiVariant2.with(Y_ROT_90)) + .select(Direction.SOUTH, multiVariant2.with(Y_ROT_180)) + .select(Direction.WEST, multiVariant2.with(Y_ROT_270)) ) ); } private void copyModel(Block sourceBlock, Block targetBlock) { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(sourceBlock); - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(targetBlock, Variant.variant().with(VariantProperties.MODEL, resourceLocation))); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(sourceBlock)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(targetBlock, multiVariant)); this.itemModelOutput.copy(sourceBlock.asItem(), targetBlock.asItem()); } private void createIronBars() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_post_ends"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_post"); - ResourceLocation resourceLocation3 = ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_cap"); - ResourceLocation resourceLocation4 = ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_cap_alt"); - ResourceLocation resourceLocation5 = ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_side"); - ResourceLocation resourceLocation6 = ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_side_alt"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_post_ends")); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_post")); + MultiVariant multiVariant3 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_cap")); + MultiVariant multiVariant4 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_cap_alt")); + MultiVariant multiVariant5 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_side")); + MultiVariant multiVariant6 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.IRON_BARS, "_side_alt")); this.blockStateOutput .accept( MultiPartGenerator.multiPart(Blocks.IRON_BARS) - .with(Variant.variant().with(VariantProperties.MODEL, resourceLocation)) + .with(multiVariant) .with( - Condition.condition() + condition() .term(BlockStateProperties.NORTH, false) .term(BlockStateProperties.EAST, false) .term(BlockStateProperties.SOUTH, false) .term(BlockStateProperties.WEST, false), - Variant.variant().with(VariantProperties.MODEL, resourceLocation2) + multiVariant2 ) .with( - Condition.condition() + condition() .term(BlockStateProperties.NORTH, true) .term(BlockStateProperties.EAST, false) .term(BlockStateProperties.SOUTH, false) .term(BlockStateProperties.WEST, false), - Variant.variant().with(VariantProperties.MODEL, resourceLocation3) + multiVariant3 ) .with( - Condition.condition() + condition() .term(BlockStateProperties.NORTH, false) .term(BlockStateProperties.EAST, true) .term(BlockStateProperties.SOUTH, false) .term(BlockStateProperties.WEST, false), - Variant.variant().with(VariantProperties.MODEL, resourceLocation3).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) + multiVariant3.with(Y_ROT_90) ) .with( - Condition.condition() + condition() .term(BlockStateProperties.NORTH, false) .term(BlockStateProperties.EAST, false) .term(BlockStateProperties.SOUTH, true) .term(BlockStateProperties.WEST, false), - Variant.variant().with(VariantProperties.MODEL, resourceLocation4) + multiVariant4 ) .with( - Condition.condition() + condition() .term(BlockStateProperties.NORTH, false) .term(BlockStateProperties.EAST, false) .term(BlockStateProperties.SOUTH, false) .term(BlockStateProperties.WEST, true), - Variant.variant().with(VariantProperties.MODEL, resourceLocation4).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .with(Condition.condition().term(BlockStateProperties.NORTH, true), Variant.variant().with(VariantProperties.MODEL, resourceLocation5)) - .with( - Condition.condition().term(BlockStateProperties.EAST, true), - Variant.variant().with(VariantProperties.MODEL, resourceLocation5).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .with(Condition.condition().term(BlockStateProperties.SOUTH, true), Variant.variant().with(VariantProperties.MODEL, resourceLocation6)) - .with( - Condition.condition().term(BlockStateProperties.WEST, true), - Variant.variant().with(VariantProperties.MODEL, resourceLocation6).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) + multiVariant4.with(Y_ROT_90) ) + .with(condition().term(BlockStateProperties.NORTH, true), multiVariant5) + .with(condition().term(BlockStateProperties.EAST, true), multiVariant5.with(Y_ROT_90)) + .with(condition().term(BlockStateProperties.SOUTH, true), multiVariant6) + .with(condition().term(BlockStateProperties.WEST, true), multiVariant6.with(Y_ROT_90)) ); this.registerSimpleFlatItemModel(Blocks.IRON_BARS); } private void createNonTemplateHorizontalBlock(Block horizontalBlock) { this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(horizontalBlock, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(horizontalBlock))) - .with(createHorizontalFacingDispatch()) - ); + .accept(MultiVariantGenerator.dispatch(horizontalBlock, plainVariant(ModelLocationUtils.getModelLocation(horizontalBlock))).with(ROTATION_HORIZONTAL_FACING)); } private void createLever() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.LEVER); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.LEVER, "_on"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.LEVER)); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.LEVER, "_on")); this.registerSimpleFlatItemModel(Blocks.LEVER); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.LEVER) - .with(createBooleanModelDispatch(BlockStateProperties.POWERED, resourceLocation, resourceLocation2)) + MultiVariantGenerator.dispatch(Blocks.LEVER) + .with(createBooleanModelDispatch(BlockStateProperties.POWERED, multiVariant, multiVariant2)) .with( - PropertyDispatch.properties(BlockStateProperties.ATTACH_FACE, BlockStateProperties.HORIZONTAL_FACING) - .select( - AttachFace.CEILING, - Direction.NORTH, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - AttachFace.CEILING, - Direction.EAST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(AttachFace.CEILING, Direction.SOUTH, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180)) - .select( - AttachFace.CEILING, - Direction.WEST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R180).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select(AttachFace.FLOOR, Direction.NORTH, Variant.variant()) - .select(AttachFace.FLOOR, Direction.EAST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90)) - .select(AttachFace.FLOOR, Direction.SOUTH, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180)) - .select(AttachFace.FLOOR, Direction.WEST, Variant.variant().with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270)) - .select(AttachFace.WALL, Direction.NORTH, Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90)) - .select( - AttachFace.WALL, - Direction.EAST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - AttachFace.WALL, - Direction.SOUTH, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - AttachFace.WALL, - Direction.WEST, - Variant.variant().with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) + PropertyDispatch.modify(BlockStateProperties.ATTACH_FACE, BlockStateProperties.HORIZONTAL_FACING) + .select(AttachFace.CEILING, Direction.NORTH, X_ROT_180.then(Y_ROT_180)) + .select(AttachFace.CEILING, Direction.EAST, X_ROT_180.then(Y_ROT_270)) + .select(AttachFace.CEILING, Direction.SOUTH, X_ROT_180) + .select(AttachFace.CEILING, Direction.WEST, X_ROT_180.then(Y_ROT_90)) + .select(AttachFace.FLOOR, Direction.NORTH, NOP) + .select(AttachFace.FLOOR, Direction.EAST, Y_ROT_90) + .select(AttachFace.FLOOR, Direction.SOUTH, Y_ROT_180) + .select(AttachFace.FLOOR, Direction.WEST, Y_ROT_270) + .select(AttachFace.WALL, Direction.NORTH, X_ROT_90) + .select(AttachFace.WALL, Direction.EAST, X_ROT_90.then(Y_ROT_90)) + .select(AttachFace.WALL, Direction.SOUTH, X_ROT_90.then(Y_ROT_180)) + .select(AttachFace.WALL, Direction.WEST, X_ROT_90.then(Y_ROT_270)) ) ); } @@ -3387,87 +2320,63 @@ public class BlockModelGenerators { private void createLilyPad() { ResourceLocation resourceLocation = this.createFlatItemModelWithBlockTexture(Items.LILY_PAD, Blocks.LILY_PAD); this.registerSimpleTintedItemModel(Blocks.LILY_PAD, resourceLocation, ItemModelUtils.constantTint(-9321636)); - this.blockStateOutput.accept(createRotatedVariant(Blocks.LILY_PAD, ModelLocationUtils.getModelLocation(Blocks.LILY_PAD))); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(ModelLocationUtils.getModelLocation(Blocks.LILY_PAD)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(Blocks.LILY_PAD, createRotatedVariants(variant))); } private void createFrogspawnBlock() { this.registerSimpleFlatItemModel(Blocks.FROGSPAWN); - this.blockStateOutput.accept(createSimpleBlock(Blocks.FROGSPAWN, ModelLocationUtils.getModelLocation(Blocks.FROGSPAWN))); + this.blockStateOutput.accept(createSimpleBlock(Blocks.FROGSPAWN, plainVariant(ModelLocationUtils.getModelLocation(Blocks.FROGSPAWN)))); } private void createNetherPortalBlock() { this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.NETHER_PORTAL) + MultiVariantGenerator.dispatch(Blocks.NETHER_PORTAL) .with( - PropertyDispatch.property(BlockStateProperties.HORIZONTAL_AXIS) - .select(Axis.X, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.NETHER_PORTAL, "_ns"))) - .select(Axis.Z, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.NETHER_PORTAL, "_ew"))) + PropertyDispatch.initial(BlockStateProperties.HORIZONTAL_AXIS) + .select(Direction.Axis.X, plainVariant(ModelLocationUtils.getModelLocation(Blocks.NETHER_PORTAL, "_ns"))) + .select(Direction.Axis.Z, plainVariant(ModelLocationUtils.getModelLocation(Blocks.NETHER_PORTAL, "_ew"))) ) ); } private void createNetherrack() { - ResourceLocation resourceLocation = TexturedModel.CUBE.create(Blocks.NETHERRACK, this.modelOutput); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(TexturedModel.CUBE.create(Blocks.NETHERRACK, this.modelOutput)); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant( + MultiVariantGenerator.dispatch( Blocks.NETHERRACK, - Variant.variant().with(VariantProperties.MODEL, resourceLocation), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.X_ROT, VariantProperties.Rotation.R90), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.X_ROT, VariantProperties.Rotation.R180), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.X_ROT, VariantProperties.Rotation.R270), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R90), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R180), - Variant.variant() - .with(VariantProperties.MODEL, resourceLocation) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - .with(VariantProperties.X_ROT, VariantProperties.Rotation.R270) + variants( + variant, + variant.with(X_ROT_90), + variant.with(X_ROT_180), + variant.with(X_ROT_270), + variant.with(Y_ROT_90), + variant.with(Y_ROT_90.then(X_ROT_90)), + variant.with(Y_ROT_90.then(X_ROT_180)), + variant.with(Y_ROT_90.then(X_ROT_270)), + variant.with(Y_ROT_180), + variant.with(Y_ROT_180.then(X_ROT_90)), + variant.with(Y_ROT_180.then(X_ROT_180)), + variant.with(Y_ROT_180.then(X_ROT_270)), + variant.with(Y_ROT_270), + variant.with(Y_ROT_270.then(X_ROT_90)), + variant.with(Y_ROT_270.then(X_ROT_180)), + variant.with(Y_ROT_270.then(X_ROT_270)) + ) ) ); } private void createObserver() { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.OBSERVER); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.OBSERVER, "_on"); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.OBSERVER)); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.OBSERVER, "_on")); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.OBSERVER) - .with(createBooleanModelDispatch(BlockStateProperties.POWERED, resourceLocation2, resourceLocation)) - .with(createFacingDispatch()) + MultiVariantGenerator.dispatch(Blocks.OBSERVER) + .with(createBooleanModelDispatch(BlockStateProperties.POWERED, multiVariant2, multiVariant)) + .with(ROTATION_FACING) ); } @@ -3479,25 +2388,21 @@ public class BlockModelGenerators { ResourceLocation resourceLocation2 = TextureMapping.getBlockTexture(Blocks.PISTON, "_top"); TextureMapping textureMapping2 = textureMapping.copyAndUpdate(TextureSlot.PLATFORM, resourceLocation); TextureMapping textureMapping3 = textureMapping.copyAndUpdate(TextureSlot.PLATFORM, resourceLocation2); - ResourceLocation resourceLocation3 = ModelLocationUtils.getModelLocation(Blocks.PISTON, "_base"); - this.createPistonVariant(Blocks.PISTON, resourceLocation3, textureMapping3); - this.createPistonVariant(Blocks.STICKY_PISTON, resourceLocation3, textureMapping2); - ResourceLocation resourceLocation4 = ModelTemplates.CUBE_BOTTOM_TOP + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(Blocks.PISTON, "_base")); + this.createPistonVariant(Blocks.PISTON, multiVariant, textureMapping3); + this.createPistonVariant(Blocks.STICKY_PISTON, multiVariant, textureMapping2); + ResourceLocation resourceLocation3 = ModelTemplates.CUBE_BOTTOM_TOP .createWithSuffix(Blocks.PISTON, "_inventory", textureMapping.copyAndUpdate(TextureSlot.TOP, resourceLocation2), this.modelOutput); - ResourceLocation resourceLocation5 = ModelTemplates.CUBE_BOTTOM_TOP + ResourceLocation resourceLocation4 = ModelTemplates.CUBE_BOTTOM_TOP .createWithSuffix(Blocks.STICKY_PISTON, "_inventory", textureMapping.copyAndUpdate(TextureSlot.TOP, resourceLocation), this.modelOutput); - this.registerSimpleItemModel(Blocks.PISTON, resourceLocation4); - this.registerSimpleItemModel(Blocks.STICKY_PISTON, resourceLocation5); + this.registerSimpleItemModel(Blocks.PISTON, resourceLocation3); + this.registerSimpleItemModel(Blocks.STICKY_PISTON, resourceLocation4); } - private void createPistonVariant(Block pistonBlock, ResourceLocation baseModelLocation, TextureMapping topTextureMapping) { - ResourceLocation resourceLocation = ModelTemplates.PISTON.create(pistonBlock, topTextureMapping, this.modelOutput); + private void createPistonVariant(Block block, MultiVariant variants, TextureMapping topTextureMapping) { + MultiVariant multiVariant = plainVariant(ModelTemplates.PISTON.create(block, topTextureMapping, this.modelOutput)); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(pistonBlock) - .with(createBooleanModelDispatch(BlockStateProperties.EXTENDED, baseModelLocation, resourceLocation)) - .with(createFacingDispatch()) - ); + .accept(MultiVariantGenerator.dispatch(block).with(createBooleanModelDispatch(BlockStateProperties.EXTENDED, variants, multiVariant)).with(ROTATION_FACING)); } private void createPistonHeads() { @@ -3508,36 +2413,25 @@ public class BlockModelGenerators { TextureMapping textureMapping3 = textureMapping.copyAndUpdate(TextureSlot.PLATFORM, TextureMapping.getBlockTexture(Blocks.PISTON, "_top")); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.PISTON_HEAD) + MultiVariantGenerator.dispatch(Blocks.PISTON_HEAD) .with( - PropertyDispatch.properties(BlockStateProperties.SHORT, BlockStateProperties.PISTON_TYPE) + PropertyDispatch.initial(BlockStateProperties.SHORT, BlockStateProperties.PISTON_TYPE) + .select(false, PistonType.DEFAULT, plainVariant(ModelTemplates.PISTON_HEAD.createWithSuffix(Blocks.PISTON, "_head", textureMapping3, this.modelOutput))) .select( - false, - PistonType.DEFAULT, - Variant.variant().with(VariantProperties.MODEL, ModelTemplates.PISTON_HEAD.createWithSuffix(Blocks.PISTON, "_head", textureMapping3, this.modelOutput)) - ) - .select( - false, - PistonType.STICKY, - Variant.variant() - .with(VariantProperties.MODEL, ModelTemplates.PISTON_HEAD.createWithSuffix(Blocks.PISTON, "_head_sticky", textureMapping2, this.modelOutput)) + false, PistonType.STICKY, plainVariant(ModelTemplates.PISTON_HEAD.createWithSuffix(Blocks.PISTON, "_head_sticky", textureMapping2, this.modelOutput)) ) .select( true, PistonType.DEFAULT, - Variant.variant() - .with(VariantProperties.MODEL, ModelTemplates.PISTON_HEAD_SHORT.createWithSuffix(Blocks.PISTON, "_head_short", textureMapping3, this.modelOutput)) + plainVariant(ModelTemplates.PISTON_HEAD_SHORT.createWithSuffix(Blocks.PISTON, "_head_short", textureMapping3, this.modelOutput)) ) .select( true, PistonType.STICKY, - Variant.variant() - .with( - VariantProperties.MODEL, ModelTemplates.PISTON_HEAD_SHORT.createWithSuffix(Blocks.PISTON, "_head_short_sticky", textureMapping2, this.modelOutput) - ) + plainVariant(ModelTemplates.PISTON_HEAD_SHORT.createWithSuffix(Blocks.PISTON, "_head_short_sticky", textureMapping2, this.modelOutput)) ) ) - .with(createFacingDispatch()) + .with(ROTATION_FACING) ); } @@ -3550,31 +2444,31 @@ public class BlockModelGenerators { TextureMapping textureMapping5 = TextureMapping.trialSpawner(block, "_side_active_ominous", "_top_active_ominous"); TextureMapping textureMapping6 = TextureMapping.trialSpawner(block, "_side_active_ominous", "_top_ejecting_reward_ominous"); ResourceLocation resourceLocation = ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES.create(block, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES.createWithSuffix(block, "_active", textureMapping2, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES - .createWithSuffix(block, "_ejecting_reward", textureMapping3, this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES - .createWithSuffix(block, "_inactive_ominous", textureMapping4, this.modelOutput); - ResourceLocation resourceLocation5 = ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES.createWithSuffix(block, "_active_ominous", textureMapping5, this.modelOutput); - ResourceLocation resourceLocation6 = ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES - .createWithSuffix(block, "_ejecting_reward_ominous", textureMapping6, this.modelOutput); + MultiVariant multiVariant = plainVariant(resourceLocation); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES.createWithSuffix(block, "_active", textureMapping2, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant( + ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES.createWithSuffix(block, "_ejecting_reward", textureMapping3, this.modelOutput) + ); + MultiVariant multiVariant4 = plainVariant( + ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES.createWithSuffix(block, "_inactive_ominous", textureMapping4, this.modelOutput) + ); + MultiVariant multiVariant5 = plainVariant( + ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES.createWithSuffix(block, "_active_ominous", textureMapping5, this.modelOutput) + ); + MultiVariant multiVariant6 = plainVariant( + ModelTemplates.CUBE_BOTTOM_TOP_INNER_FACES.createWithSuffix(block, "_ejecting_reward_ominous", textureMapping6, this.modelOutput) + ); this.registerSimpleItemModel(block, resourceLocation); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(block) - .with( - PropertyDispatch.properties(BlockStateProperties.TRIAL_SPAWNER_STATE, BlockStateProperties.OMINOUS) - .generate( - (trialSpawnerState, boolean_) -> { - return switch (trialSpawnerState) { - case INACTIVE, COOLDOWN -> Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation4 : resourceLocation); - case WAITING_FOR_PLAYERS, ACTIVE, WAITING_FOR_REWARD_EJECTION -> Variant.variant() - .with(VariantProperties.MODEL, boolean_ ? resourceLocation5 : resourceLocation2); - case EJECTING_REWARD -> Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation6 : resourceLocation3); - }; - } - ) - ) + MultiVariantGenerator.dispatch(block) + .with(PropertyDispatch.initial(BlockStateProperties.TRIAL_SPAWNER_STATE, BlockStateProperties.OMINOUS).generate((trialSpawnerState, boolean_) -> { + return switch (trialSpawnerState) { + case INACTIVE, COOLDOWN -> boolean_ ? multiVariant4 : multiVariant; + case WAITING_FOR_PLAYERS, ACTIVE, WAITING_FOR_REWARD_EJECTION -> boolean_ ? multiVariant5 : multiVariant2; + case EJECTING_REWARD -> boolean_ ? multiVariant6 : multiVariant3; + }; + })) ); } @@ -3585,48 +2479,42 @@ public class BlockModelGenerators { TextureMapping textureMapping3 = TextureMapping.vault(block, "_front_ejecting", "_side_on", "_top", "_bottom"); TextureMapping textureMapping4 = TextureMapping.vault(block, "_front_ejecting", "_side_on", "_top_ejecting", "_bottom"); ResourceLocation resourceLocation = ModelTemplates.VAULT.create(block, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.VAULT.createWithSuffix(block, "_active", textureMapping2, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.VAULT.createWithSuffix(block, "_unlocking", textureMapping3, this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.VAULT.createWithSuffix(block, "_ejecting_reward", textureMapping4, this.modelOutput); + MultiVariant multiVariant = plainVariant(resourceLocation); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.VAULT.createWithSuffix(block, "_active", textureMapping2, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.VAULT.createWithSuffix(block, "_unlocking", textureMapping3, this.modelOutput)); + MultiVariant multiVariant4 = plainVariant(ModelTemplates.VAULT.createWithSuffix(block, "_ejecting_reward", textureMapping4, this.modelOutput)); TextureMapping textureMapping5 = TextureMapping.vault(block, "_front_off_ominous", "_side_off_ominous", "_top_ominous", "_bottom_ominous"); TextureMapping textureMapping6 = TextureMapping.vault(block, "_front_on_ominous", "_side_on_ominous", "_top_ominous", "_bottom_ominous"); TextureMapping textureMapping7 = TextureMapping.vault(block, "_front_ejecting_ominous", "_side_on_ominous", "_top_ominous", "_bottom_ominous"); TextureMapping textureMapping8 = TextureMapping.vault(block, "_front_ejecting_ominous", "_side_on_ominous", "_top_ejecting_ominous", "_bottom_ominous"); - ResourceLocation resourceLocation5 = ModelTemplates.VAULT.createWithSuffix(block, "_ominous", textureMapping5, this.modelOutput); - ResourceLocation resourceLocation6 = ModelTemplates.VAULT.createWithSuffix(block, "_active_ominous", textureMapping6, this.modelOutput); - ResourceLocation resourceLocation7 = ModelTemplates.VAULT.createWithSuffix(block, "_unlocking_ominous", textureMapping7, this.modelOutput); - ResourceLocation resourceLocation8 = ModelTemplates.VAULT.createWithSuffix(block, "_ejecting_reward_ominous", textureMapping8, this.modelOutput); + MultiVariant multiVariant5 = plainVariant(ModelTemplates.VAULT.createWithSuffix(block, "_ominous", textureMapping5, this.modelOutput)); + MultiVariant multiVariant6 = plainVariant(ModelTemplates.VAULT.createWithSuffix(block, "_active_ominous", textureMapping6, this.modelOutput)); + MultiVariant multiVariant7 = plainVariant(ModelTemplates.VAULT.createWithSuffix(block, "_unlocking_ominous", textureMapping7, this.modelOutput)); + MultiVariant multiVariant8 = plainVariant(ModelTemplates.VAULT.createWithSuffix(block, "_ejecting_reward_ominous", textureMapping8, this.modelOutput)); this.registerSimpleItemModel(block, resourceLocation); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(block) - .with(createHorizontalFacingDispatch()) - .with(PropertyDispatch.properties(VaultBlock.STATE, VaultBlock.OMINOUS).generate((vaultState, boolean_) -> { - return switch (vaultState) { - case INACTIVE -> Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation5 : resourceLocation); - case ACTIVE -> Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation6 : resourceLocation2); - case UNLOCKING -> Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation7 : resourceLocation3); - case EJECTING -> Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation8 : resourceLocation4); - }; - })) - ); + .accept(MultiVariantGenerator.dispatch(block).with(PropertyDispatch.initial(VaultBlock.STATE, VaultBlock.OMINOUS).generate((vaultState, boolean_) -> { + return switch (vaultState) { + case INACTIVE -> boolean_ ? multiVariant5 : multiVariant; + case ACTIVE -> boolean_ ? multiVariant6 : multiVariant2; + case UNLOCKING -> boolean_ ? multiVariant7 : multiVariant3; + case EJECTING -> boolean_ ? multiVariant8 : multiVariant4; + }; + })).with(ROTATION_HORIZONTAL_FACING)); } private void createSculkSensor() { ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.SCULK_SENSOR, "_inactive"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.SCULK_SENSOR, "_active"); + MultiVariant multiVariant = plainVariant(resourceLocation); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.SCULK_SENSOR, "_active")); this.registerSimpleItemModel(Blocks.SCULK_SENSOR, resourceLocation); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.SCULK_SENSOR) + MultiVariantGenerator.dispatch(Blocks.SCULK_SENSOR) .with( - PropertyDispatch.property(BlockStateProperties.SCULK_SENSOR_PHASE) + PropertyDispatch.initial(BlockStateProperties.SCULK_SENSOR_PHASE) .generate( - sculkSensorPhase -> Variant.variant() - .with( - VariantProperties.MODEL, - sculkSensorPhase != SculkSensorPhase.ACTIVE && sculkSensorPhase != SculkSensorPhase.COOLDOWN ? resourceLocation : resourceLocation2 - ) + sculkSensorPhase -> sculkSensorPhase != SculkSensorPhase.ACTIVE && sculkSensorPhase != SculkSensorPhase.COOLDOWN ? multiVariant : multiVariant2 ) ) ); @@ -3634,81 +2522,67 @@ public class BlockModelGenerators { private void createCalibratedSculkSensor() { ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.CALIBRATED_SCULK_SENSOR, "_inactive"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.CALIBRATED_SCULK_SENSOR, "_active"); + MultiVariant multiVariant = plainVariant(resourceLocation); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.CALIBRATED_SCULK_SENSOR, "_active")); this.registerSimpleItemModel(Blocks.CALIBRATED_SCULK_SENSOR, resourceLocation); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.CALIBRATED_SCULK_SENSOR) + MultiVariantGenerator.dispatch(Blocks.CALIBRATED_SCULK_SENSOR) .with( - PropertyDispatch.property(BlockStateProperties.SCULK_SENSOR_PHASE) + PropertyDispatch.initial(BlockStateProperties.SCULK_SENSOR_PHASE) .generate( - sculkSensorPhase -> Variant.variant() - .with( - VariantProperties.MODEL, - sculkSensorPhase != SculkSensorPhase.ACTIVE && sculkSensorPhase != SculkSensorPhase.COOLDOWN ? resourceLocation : resourceLocation2 - ) + sculkSensorPhase -> sculkSensorPhase != SculkSensorPhase.ACTIVE && sculkSensorPhase != SculkSensorPhase.COOLDOWN ? multiVariant : multiVariant2 ) ) - .with(createHorizontalFacingDispatch()) + .with(ROTATION_HORIZONTAL_FACING) ); } private void createSculkShrieker() { ResourceLocation resourceLocation = ModelTemplates.SCULK_SHRIEKER.create(Blocks.SCULK_SHRIEKER, TextureMapping.sculkShrieker(false), this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.SCULK_SHRIEKER - .createWithSuffix(Blocks.SCULK_SHRIEKER, "_can_summon", TextureMapping.sculkShrieker(true), this.modelOutput); + MultiVariant multiVariant = plainVariant(resourceLocation); + MultiVariant multiVariant2 = plainVariant( + ModelTemplates.SCULK_SHRIEKER.createWithSuffix(Blocks.SCULK_SHRIEKER, "_can_summon", TextureMapping.sculkShrieker(true), this.modelOutput) + ); this.registerSimpleItemModel(Blocks.SCULK_SHRIEKER, resourceLocation); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.SCULK_SHRIEKER) - .with(createBooleanModelDispatch(BlockStateProperties.CAN_SUMMON, resourceLocation2, resourceLocation)) - ); + .accept(MultiVariantGenerator.dispatch(Blocks.SCULK_SHRIEKER).with(createBooleanModelDispatch(BlockStateProperties.CAN_SUMMON, multiVariant2, multiVariant))); } private void createScaffolding() { ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.SCAFFOLDING, "_stable"); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.SCAFFOLDING, "_unstable"); + MultiVariant multiVariant = plainVariant(resourceLocation); + MultiVariant multiVariant2 = plainVariant(ModelLocationUtils.getModelLocation(Blocks.SCAFFOLDING, "_unstable")); this.registerSimpleItemModel(Blocks.SCAFFOLDING, resourceLocation); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.SCAFFOLDING).with(createBooleanModelDispatch(BlockStateProperties.BOTTOM, resourceLocation2, resourceLocation)) - ); + .accept(MultiVariantGenerator.dispatch(Blocks.SCAFFOLDING).with(createBooleanModelDispatch(BlockStateProperties.BOTTOM, multiVariant2, multiVariant))); } private void createCaveVines() { - ResourceLocation resourceLocation = this.createSuffixedVariant(Blocks.CAVE_VINES, "", ModelTemplates.CROSS, TextureMapping::cross); - ResourceLocation resourceLocation2 = this.createSuffixedVariant(Blocks.CAVE_VINES, "_lit", ModelTemplates.CROSS, TextureMapping::cross); + MultiVariant multiVariant = plainVariant(this.createSuffixedVariant(Blocks.CAVE_VINES, "", ModelTemplates.CROSS, TextureMapping::cross)); + MultiVariant multiVariant2 = plainVariant(this.createSuffixedVariant(Blocks.CAVE_VINES, "_lit", ModelTemplates.CROSS, TextureMapping::cross)); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.CAVE_VINES).with(createBooleanModelDispatch(BlockStateProperties.BERRIES, resourceLocation2, resourceLocation)) - ); - ResourceLocation resourceLocation3 = this.createSuffixedVariant(Blocks.CAVE_VINES_PLANT, "", ModelTemplates.CROSS, TextureMapping::cross); - ResourceLocation resourceLocation4 = this.createSuffixedVariant(Blocks.CAVE_VINES_PLANT, "_lit", ModelTemplates.CROSS, TextureMapping::cross); + .accept(MultiVariantGenerator.dispatch(Blocks.CAVE_VINES).with(createBooleanModelDispatch(BlockStateProperties.BERRIES, multiVariant2, multiVariant))); + MultiVariant multiVariant3 = plainVariant(this.createSuffixedVariant(Blocks.CAVE_VINES_PLANT, "", ModelTemplates.CROSS, TextureMapping::cross)); + MultiVariant multiVariant4 = plainVariant(this.createSuffixedVariant(Blocks.CAVE_VINES_PLANT, "_lit", ModelTemplates.CROSS, TextureMapping::cross)); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.CAVE_VINES_PLANT) - .with(createBooleanModelDispatch(BlockStateProperties.BERRIES, resourceLocation4, resourceLocation3)) - ); + .accept(MultiVariantGenerator.dispatch(Blocks.CAVE_VINES_PLANT).with(createBooleanModelDispatch(BlockStateProperties.BERRIES, multiVariant4, multiVariant3))); } private void createRedstoneLamp() { - ResourceLocation resourceLocation = TexturedModel.CUBE.create(Blocks.REDSTONE_LAMP, this.modelOutput); - ResourceLocation resourceLocation2 = this.createSuffixedVariant(Blocks.REDSTONE_LAMP, "_on", ModelTemplates.CUBE_ALL, TextureMapping::cube); + MultiVariant multiVariant = plainVariant(TexturedModel.CUBE.create(Blocks.REDSTONE_LAMP, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(this.createSuffixedVariant(Blocks.REDSTONE_LAMP, "_on", ModelTemplates.CUBE_ALL, TextureMapping::cube)); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.REDSTONE_LAMP).with(createBooleanModelDispatch(BlockStateProperties.LIT, resourceLocation2, resourceLocation)) - ); + .accept(MultiVariantGenerator.dispatch(Blocks.REDSTONE_LAMP).with(createBooleanModelDispatch(BlockStateProperties.LIT, multiVariant2, multiVariant))); } private void createNormalTorch(Block torchBlock, Block wallTorchBlock) { TextureMapping textureMapping = TextureMapping.torch(torchBlock); - this.blockStateOutput.accept(createSimpleBlock(torchBlock, ModelTemplates.TORCH.create(torchBlock, textureMapping, this.modelOutput))); + this.blockStateOutput.accept(createSimpleBlock(torchBlock, plainVariant(ModelTemplates.TORCH.create(torchBlock, textureMapping, this.modelOutput)))); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant( - wallTorchBlock, Variant.variant().with(VariantProperties.MODEL, ModelTemplates.WALL_TORCH.create(wallTorchBlock, textureMapping, this.modelOutput)) - ) - .with(createTorchHorizontalDispatch()) + MultiVariantGenerator.dispatch(wallTorchBlock, plainVariant(ModelTemplates.WALL_TORCH.create(wallTorchBlock, textureMapping, this.modelOutput))) + .with(ROTATION_TORCH) ); this.registerSimpleFlatItemModel(torchBlock); } @@ -3716,19 +2590,19 @@ public class BlockModelGenerators { private void createRedstoneTorch() { TextureMapping textureMapping = TextureMapping.torch(Blocks.REDSTONE_TORCH); TextureMapping textureMapping2 = TextureMapping.torch(TextureMapping.getBlockTexture(Blocks.REDSTONE_TORCH, "_off")); - ResourceLocation resourceLocation = ModelTemplates.REDSTONE_TORCH.create(Blocks.REDSTONE_TORCH, textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.TORCH_UNLIT.createWithSuffix(Blocks.REDSTONE_TORCH, "_off", textureMapping2, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.REDSTONE_TORCH.create(Blocks.REDSTONE_TORCH, textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.TORCH_UNLIT.createWithSuffix(Blocks.REDSTONE_TORCH, "_off", textureMapping2, this.modelOutput)); + this.blockStateOutput + .accept(MultiVariantGenerator.dispatch(Blocks.REDSTONE_TORCH).with(createBooleanModelDispatch(BlockStateProperties.LIT, multiVariant, multiVariant2))); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.REDSTONE_WALL_TORCH.create(Blocks.REDSTONE_WALL_TORCH, textureMapping, this.modelOutput)); + MultiVariant multiVariant4 = plainVariant( + ModelTemplates.WALL_TORCH_UNLIT.createWithSuffix(Blocks.REDSTONE_WALL_TORCH, "_off", textureMapping2, this.modelOutput) + ); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.REDSTONE_TORCH).with(createBooleanModelDispatch(BlockStateProperties.LIT, resourceLocation, resourceLocation2)) - ); - ResourceLocation resourceLocation3 = ModelTemplates.REDSTONE_WALL_TORCH.create(Blocks.REDSTONE_WALL_TORCH, textureMapping, this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.WALL_TORCH_UNLIT.createWithSuffix(Blocks.REDSTONE_WALL_TORCH, "_off", textureMapping2, this.modelOutput); - this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.REDSTONE_WALL_TORCH) - .with(createBooleanModelDispatch(BlockStateProperties.LIT, resourceLocation3, resourceLocation4)) - .with(createTorchHorizontalDispatch()) + MultiVariantGenerator.dispatch(Blocks.REDSTONE_WALL_TORCH) + .with(createBooleanModelDispatch(BlockStateProperties.LIT, multiVariant3, multiVariant4)) + .with(ROTATION_TORCH) ); this.registerSimpleFlatItemModel(Blocks.REDSTONE_TORCH); } @@ -3737,9 +2611,9 @@ public class BlockModelGenerators { this.registerSimpleFlatItemModel(Items.REPEATER); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.REPEATER) + MultiVariantGenerator.dispatch(Blocks.REPEATER) .with( - PropertyDispatch.properties(BlockStateProperties.DELAY, BlockStateProperties.LOCKED, BlockStateProperties.POWERED) + PropertyDispatch.initial(BlockStateProperties.DELAY, BlockStateProperties.LOCKED, BlockStateProperties.POWERED) .generate((integer, boolean_, boolean2) -> { StringBuilder stringBuilder = new StringBuilder(); stringBuilder.append('_').append(integer).append("tick"); @@ -3751,10 +2625,10 @@ public class BlockModelGenerators { stringBuilder.append("_locked"); } - return Variant.variant().with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.REPEATER, stringBuilder.toString())); + return plainVariant(TextureMapping.getBlockTexture(Blocks.REPEATER, stringBuilder.toString())); }) ) - .with(createHorizontalFacingDispatchAlt()) + .with(ROTATION_HORIZONTAL_FACING_ALT) ); } @@ -3762,46 +2636,40 @@ public class BlockModelGenerators { this.registerSimpleFlatItemModel(Items.SEA_PICKLE); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.SEA_PICKLE) + MultiVariantGenerator.dispatch(Blocks.SEA_PICKLE) .with( - PropertyDispatch.properties(BlockStateProperties.PICKLES, BlockStateProperties.WATERLOGGED) - .select(1, false, Arrays.asList(createRotatedVariants(ModelLocationUtils.decorateBlockModelLocation("dead_sea_pickle")))) - .select(2, false, Arrays.asList(createRotatedVariants(ModelLocationUtils.decorateBlockModelLocation("two_dead_sea_pickles")))) - .select(3, false, Arrays.asList(createRotatedVariants(ModelLocationUtils.decorateBlockModelLocation("three_dead_sea_pickles")))) - .select(4, false, Arrays.asList(createRotatedVariants(ModelLocationUtils.decorateBlockModelLocation("four_dead_sea_pickles")))) - .select(1, true, Arrays.asList(createRotatedVariants(ModelLocationUtils.decorateBlockModelLocation("sea_pickle")))) - .select(2, true, Arrays.asList(createRotatedVariants(ModelLocationUtils.decorateBlockModelLocation("two_sea_pickles")))) - .select(3, true, Arrays.asList(createRotatedVariants(ModelLocationUtils.decorateBlockModelLocation("three_sea_pickles")))) - .select(4, true, Arrays.asList(createRotatedVariants(ModelLocationUtils.decorateBlockModelLocation("four_sea_pickles")))) + PropertyDispatch.initial(BlockStateProperties.PICKLES, BlockStateProperties.WATERLOGGED) + .select(1, false, createRotatedVariants(plainModel(ModelLocationUtils.decorateBlockModelLocation("dead_sea_pickle")))) + .select(2, false, createRotatedVariants(plainModel(ModelLocationUtils.decorateBlockModelLocation("two_dead_sea_pickles")))) + .select(3, false, createRotatedVariants(plainModel(ModelLocationUtils.decorateBlockModelLocation("three_dead_sea_pickles")))) + .select(4, false, createRotatedVariants(plainModel(ModelLocationUtils.decorateBlockModelLocation("four_dead_sea_pickles")))) + .select(1, true, createRotatedVariants(plainModel(ModelLocationUtils.decorateBlockModelLocation("sea_pickle")))) + .select(2, true, createRotatedVariants(plainModel(ModelLocationUtils.decorateBlockModelLocation("two_sea_pickles")))) + .select(3, true, createRotatedVariants(plainModel(ModelLocationUtils.decorateBlockModelLocation("three_sea_pickles")))) + .select(4, true, createRotatedVariants(plainModel(ModelLocationUtils.decorateBlockModelLocation("four_sea_pickles")))) ) ); } private void createSnowBlocks() { TextureMapping textureMapping = TextureMapping.cube(Blocks.SNOW); - ResourceLocation resourceLocation = ModelTemplates.CUBE_ALL.create(Blocks.SNOW_BLOCK, textureMapping, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.CUBE_ALL.create(Blocks.SNOW_BLOCK, textureMapping, this.modelOutput)); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.SNOW) + MultiVariantGenerator.dispatch(Blocks.SNOW) .with( - PropertyDispatch.property(BlockStateProperties.LAYERS) - .generate( - integer -> Variant.variant() - .with(VariantProperties.MODEL, integer < 8 ? ModelLocationUtils.getModelLocation(Blocks.SNOW, "_height" + integer * 2) : resourceLocation) - ) + PropertyDispatch.initial(BlockStateProperties.LAYERS) + .generate(integer -> integer < 8 ? plainVariant(ModelLocationUtils.getModelLocation(Blocks.SNOW, "_height" + integer * 2)) : multiVariant) ) ); this.registerSimpleItemModel(Blocks.SNOW, ModelLocationUtils.getModelLocation(Blocks.SNOW, "_height2")); - this.blockStateOutput.accept(createSimpleBlock(Blocks.SNOW_BLOCK, resourceLocation)); + this.blockStateOutput.accept(createSimpleBlock(Blocks.SNOW_BLOCK, multiVariant)); } private void createStonecutter() { this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant( - Blocks.STONECUTTER, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.STONECUTTER)) - ) - .with(createHorizontalFacingDispatch()) + MultiVariantGenerator.dispatch(Blocks.STONECUTTER, plainVariant(ModelLocationUtils.getModelLocation(Blocks.STONECUTTER))).with(ROTATION_HORIZONTAL_FACING) ); } @@ -3810,31 +2678,56 @@ public class BlockModelGenerators { this.registerSimpleItemModel(Blocks.STRUCTURE_BLOCK, resourceLocation); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.STRUCTURE_BLOCK) + MultiVariantGenerator.dispatch(Blocks.STRUCTURE_BLOCK) .with( - PropertyDispatch.property(BlockStateProperties.STRUCTUREBLOCK_MODE) + PropertyDispatch.initial(BlockStateProperties.STRUCTUREBLOCK_MODE) .generate( - structureMode -> Variant.variant() - .with( - VariantProperties.MODEL, - this.createSuffixedVariant(Blocks.STRUCTURE_BLOCK, "_" + structureMode.getSerializedName(), ModelTemplates.CUBE_ALL, TextureMapping::cube) - ) + structureMode -> plainVariant( + this.createSuffixedVariant(Blocks.STRUCTURE_BLOCK, "_" + structureMode.getSerializedName(), ModelTemplates.CUBE_ALL, TextureMapping::cube) + ) ) ) ); } + private void createTestBlock() { + Map map = new HashMap(); + + for (TestBlockMode testBlockMode : TestBlockMode.values()) { + map.put(testBlockMode, this.createSuffixedVariant(Blocks.TEST_BLOCK, "_" + testBlockMode.getSerializedName(), ModelTemplates.CUBE_ALL, TextureMapping::cube)); + } + + this.blockStateOutput + .accept( + MultiVariantGenerator.dispatch(Blocks.TEST_BLOCK) + .with(PropertyDispatch.initial(BlockStateProperties.TEST_BLOCK_MODE).generate(testBlockModex -> plainVariant((ResourceLocation)map.get(testBlockModex)))) + ); + this.itemModelOutput + .accept( + Items.TEST_BLOCK, + ItemModelUtils.selectBlockItemProperty( + TestBlock.MODE, + ItemModelUtils.plainModel((ResourceLocation)map.get(TestBlockMode.START)), + Map.of( + TestBlockMode.FAIL, + ItemModelUtils.plainModel((ResourceLocation)map.get(TestBlockMode.FAIL)), + TestBlockMode.LOG, + ItemModelUtils.plainModel((ResourceLocation)map.get(TestBlockMode.LOG)), + TestBlockMode.ACCEPT, + ItemModelUtils.plainModel((ResourceLocation)map.get(TestBlockMode.ACCEPT)) + ) + ) + ); + } + private void createSweetBerryBush() { this.registerSimpleFlatItemModel(Items.SWEET_BERRIES); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.SWEET_BERRY_BUSH) + MultiVariantGenerator.dispatch(Blocks.SWEET_BERRY_BUSH) .with( - PropertyDispatch.property(BlockStateProperties.AGE_3) - .generate( - integer -> Variant.variant() - .with(VariantProperties.MODEL, this.createSuffixedVariant(Blocks.SWEET_BERRY_BUSH, "_stage" + integer, ModelTemplates.CROSS, TextureMapping::cross)) - ) + PropertyDispatch.initial(BlockStateProperties.AGE_3) + .generate(integer -> plainVariant(this.createSuffixedVariant(Blocks.SWEET_BERRY_BUSH, "_stage" + integer, ModelTemplates.CROSS, TextureMapping::cross))) ) ); } @@ -3843,235 +2736,43 @@ public class BlockModelGenerators { this.registerSimpleFlatItemModel(Items.STRING); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.TRIPWIRE) + MultiVariantGenerator.dispatch(Blocks.TRIPWIRE) .with( - PropertyDispatch.properties( + PropertyDispatch.initial( BlockStateProperties.ATTACHED, BlockStateProperties.EAST, BlockStateProperties.NORTH, BlockStateProperties.SOUTH, BlockStateProperties.WEST ) - .select(false, false, false, false, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ns"))) - .select( - false, - true, - false, - false, - false, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_n")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select(false, false, true, false, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_n"))) - .select( - false, - false, - false, - true, - false, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_n")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - false, - false, - false, - false, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_n")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(false, true, true, false, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ne"))) - .select( - false, - true, - false, - true, - false, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ne")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - false, - false, - false, - true, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ne")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - false, - false, - true, - false, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ne")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(false, false, true, true, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ns"))) - .select( - false, - true, - false, - false, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ns")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select(false, true, true, true, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nse"))) - .select( - false, - true, - false, - true, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nse")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - false, - false, - true, - true, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nse")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - false, - true, - true, - false, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nse")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select(false, true, true, true, true, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nsew"))) - .select( - true, false, false, false, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ns")) - ) - .select( - true, false, true, false, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_n")) - ) - .select( - true, - false, - false, - true, - false, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_n")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - true, - true, - false, - false, - false, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_n")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - true, - false, - false, - false, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_n")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - true, true, true, false, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ne")) - ) - .select( - true, - true, - false, - true, - false, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ne")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - true, - false, - false, - true, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ne")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - true, - false, - true, - false, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ne")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - true, false, true, true, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ns")) - ) - .select( - true, - true, - false, - false, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ns")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - true, true, true, true, false, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nse")) - ) - .select( - true, - true, - false, - true, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nse")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90) - ) - .select( - true, - false, - true, - true, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nse")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180) - ) - .select( - true, - true, - true, - false, - true, - Variant.variant() - .with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nse")) - .with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270) - ) - .select( - true, true, true, true, true, Variant.variant().with(VariantProperties.MODEL, ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nsew")) - ) + .select(false, false, false, false, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ns"))) + .select(false, true, false, false, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_n")).with(Y_ROT_90)) + .select(false, false, true, false, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_n"))) + .select(false, false, false, true, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_n")).with(Y_ROT_180)) + .select(false, false, false, false, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_n")).with(Y_ROT_270)) + .select(false, true, true, false, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ne"))) + .select(false, true, false, true, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ne")).with(Y_ROT_90)) + .select(false, false, false, true, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ne")).with(Y_ROT_180)) + .select(false, false, true, false, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ne")).with(Y_ROT_270)) + .select(false, false, true, true, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ns"))) + .select(false, true, false, false, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_ns")).with(Y_ROT_90)) + .select(false, true, true, true, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nse"))) + .select(false, true, false, true, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nse")).with(Y_ROT_90)) + .select(false, false, true, true, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nse")).with(Y_ROT_180)) + .select(false, true, true, false, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nse")).with(Y_ROT_270)) + .select(false, true, true, true, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_nsew"))) + .select(true, false, false, false, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ns"))) + .select(true, false, true, false, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_n"))) + .select(true, false, false, true, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_n")).with(Y_ROT_180)) + .select(true, true, false, false, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_n")).with(Y_ROT_90)) + .select(true, false, false, false, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_n")).with(Y_ROT_270)) + .select(true, true, true, false, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ne"))) + .select(true, true, false, true, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ne")).with(Y_ROT_90)) + .select(true, false, false, true, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ne")).with(Y_ROT_180)) + .select(true, false, true, false, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ne")).with(Y_ROT_270)) + .select(true, false, true, true, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ns"))) + .select(true, true, false, false, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_ns")).with(Y_ROT_90)) + .select(true, true, true, true, false, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nse"))) + .select(true, true, false, true, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nse")).with(Y_ROT_90)) + .select(true, false, true, true, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nse")).with(Y_ROT_180)) + .select(true, true, true, false, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nse")).with(Y_ROT_270)) + .select(true, true, true, true, true, plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE, "_attached_nsew"))) ) ); } @@ -4080,82 +2781,70 @@ public class BlockModelGenerators { this.registerSimpleFlatItemModel(Blocks.TRIPWIRE_HOOK); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.TRIPWIRE_HOOK) + MultiVariantGenerator.dispatch(Blocks.TRIPWIRE_HOOK) .with( - PropertyDispatch.properties(BlockStateProperties.ATTACHED, BlockStateProperties.POWERED) + PropertyDispatch.initial(BlockStateProperties.ATTACHED, BlockStateProperties.POWERED) .generate( - (boolean_, boolean2) -> Variant.variant() - .with(VariantProperties.MODEL, TextureMapping.getBlockTexture(Blocks.TRIPWIRE_HOOK, (boolean_ ? "_attached" : "") + (boolean2 ? "_on" : ""))) + (boolean_, boolean2) -> plainVariant(ModelLocationUtils.getModelLocation(Blocks.TRIPWIRE_HOOK, (boolean_ ? "_attached" : "") + (boolean2 ? "_on" : ""))) ) ) - .with(createHorizontalFacingDispatch()) + .with(ROTATION_HORIZONTAL_FACING) ); } - private ResourceLocation createTurtleEggModel(int hatchAmount, String variantName, TextureMapping textureMapping) { - switch (hatchAmount) { - case 1: - return ModelTemplates.TURTLE_EGG.create(ModelLocationUtils.decorateBlockModelLocation(variantName + "turtle_egg"), textureMapping, this.modelOutput); - case 2: - return ModelTemplates.TWO_TURTLE_EGGS - .create(ModelLocationUtils.decorateBlockModelLocation("two_" + variantName + "turtle_eggs"), textureMapping, this.modelOutput); - case 3: - return ModelTemplates.THREE_TURTLE_EGGS - .create(ModelLocationUtils.decorateBlockModelLocation("three_" + variantName + "turtle_eggs"), textureMapping, this.modelOutput); - case 4: - return ModelTemplates.FOUR_TURTLE_EGGS - .create(ModelLocationUtils.decorateBlockModelLocation("four_" + variantName + "turtle_eggs"), textureMapping, this.modelOutput); - default: - throw new UnsupportedOperationException(); - } + private net.minecraft.client.renderer.block.model.Variant createTurtleEggModel(int eggs, String variantName, TextureMapping textureMapping) { + return switch (eggs) { + case 1 -> plainModel( + ModelTemplates.TURTLE_EGG.create(ModelLocationUtils.decorateBlockModelLocation(variantName + "turtle_egg"), textureMapping, this.modelOutput) + ); + case 2 -> plainModel( + ModelTemplates.TWO_TURTLE_EGGS + .create(ModelLocationUtils.decorateBlockModelLocation("two_" + variantName + "turtle_eggs"), textureMapping, this.modelOutput) + ); + case 3 -> plainModel( + ModelTemplates.THREE_TURTLE_EGGS + .create(ModelLocationUtils.decorateBlockModelLocation("three_" + variantName + "turtle_eggs"), textureMapping, this.modelOutput) + ); + case 4 -> plainModel( + ModelTemplates.FOUR_TURTLE_EGGS + .create(ModelLocationUtils.decorateBlockModelLocation("four_" + variantName + "turtle_eggs"), textureMapping, this.modelOutput) + ); + default -> throw new UnsupportedOperationException(); + }; } - private ResourceLocation createTurtleEggModel(Integer eggAmount, Integer variantId) { - switch (variantId) { - case 0: - return this.createTurtleEggModel(eggAmount, "", TextureMapping.cube(TextureMapping.getBlockTexture(Blocks.TURTLE_EGG))); - case 1: - return this.createTurtleEggModel( - eggAmount, "slightly_cracked_", TextureMapping.cube(TextureMapping.getBlockTexture(Blocks.TURTLE_EGG, "_slightly_cracked")) - ); - case 2: - return this.createTurtleEggModel(eggAmount, "very_cracked_", TextureMapping.cube(TextureMapping.getBlockTexture(Blocks.TURTLE_EGG, "_very_cracked"))); - default: - throw new UnsupportedOperationException(); - } + private net.minecraft.client.renderer.block.model.Variant createTurtleEggModel(int eggs, int hatchAmount) { + return switch (hatchAmount) { + case 0 -> this.createTurtleEggModel(eggs, "", TextureMapping.cube(TextureMapping.getBlockTexture(Blocks.TURTLE_EGG))); + case 1 -> this.createTurtleEggModel(eggs, "slightly_cracked_", TextureMapping.cube(TextureMapping.getBlockTexture(Blocks.TURTLE_EGG, "_slightly_cracked"))); + case 2 -> this.createTurtleEggModel(eggs, "very_cracked_", TextureMapping.cube(TextureMapping.getBlockTexture(Blocks.TURTLE_EGG, "_very_cracked"))); + default -> throw new UnsupportedOperationException(); + }; } private void createTurtleEgg() { this.registerSimpleFlatItemModel(Items.TURTLE_EGG); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.TURTLE_EGG) + MultiVariantGenerator.dispatch(Blocks.TURTLE_EGG) .with( - PropertyDispatch.properties(BlockStateProperties.EGGS, BlockStateProperties.HATCH) - .generateList((integer, integer2) -> Arrays.asList(createRotatedVariants(this.createTurtleEggModel(integer, integer2)))) + PropertyDispatch.initial(BlockStateProperties.EGGS, BlockStateProperties.HATCH) + .generate((integer, integer2) -> createRotatedVariants(this.createTurtleEggModel(integer, integer2))) ) ); } private void createSnifferEgg() { this.registerSimpleFlatItemModel(Items.SNIFFER_EGG); - Function function = integer -> { + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(Blocks.SNIFFER_EGG).with(PropertyDispatch.initial(SnifferEggBlock.HATCH).generate(integer -> { String string = switch (integer) { case 1 -> "_slightly_cracked"; case 2 -> "_very_cracked"; default -> "_not_cracked"; }; TextureMapping textureMapping = TextureMapping.snifferEgg(string); - return ModelTemplates.SNIFFER_EGG.createWithSuffix(Blocks.SNIFFER_EGG, string, textureMapping, this.modelOutput); - }; - this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(Blocks.SNIFFER_EGG) - .with( - PropertyDispatch.property(SnifferEggBlock.HATCH) - .generate(integer -> Variant.variant().with(VariantProperties.MODEL, (ResourceLocation)function.apply(integer))) - ) - ); + return plainVariant(ModelTemplates.SNIFFER_EGG.createWithSuffix(Blocks.SNIFFER_EGG, string, textureMapping, this.modelOutput)); + }))); } private void createMultiface(Block multifaceBlock) { @@ -4168,74 +2857,65 @@ public class BlockModelGenerators { this.createMultifaceBlockStates(block); } - private void createMultifaceBlockStates(Block block) { - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(block); - MultiPartGenerator multiPartGenerator = MultiPartGenerator.multiPart(block); - Condition.TerminalCondition terminalCondition = Util.make( - Condition.condition(), - terminalConditionx -> MULTIFACE_GENERATOR.stream().map(Pair::getFirst).map(MultifaceBlock::getFaceProperty).forEach(booleanPropertyx -> { - if (block.defaultBlockState().hasProperty(booleanPropertyx)) { - terminalConditionx.term(booleanPropertyx, false); - } - }) - ); - - for (Pair> pair : MULTIFACE_GENERATOR) { - BooleanProperty booleanProperty = MultifaceBlock.getFaceProperty(pair.getFirst()); - Function function = pair.getSecond(); - if (block.defaultBlockState().hasProperty(booleanProperty)) { - multiPartGenerator.with(Condition.condition().term(booleanProperty, true), (Variant)function.apply(resourceLocation)); - multiPartGenerator.with(terminalCondition, (Variant)function.apply(resourceLocation)); + private static > Map selectMultifaceProperties(StateHolder state, Function facePropertyGetter) { + Builder builder = ImmutableMap.builderWithExpectedSize(MULTIFACE_GENERATOR.size()); + MULTIFACE_GENERATOR.forEach((direction, variantMutator) -> { + T property = (T)facePropertyGetter.apply(direction); + if (state.hasProperty(property)) { + builder.put(property, variantMutator); } - } + }); + return builder.build(); + } + private void createMultifaceBlockStates(Block block) { + Map, VariantMutator> map = selectMultifaceProperties(block.defaultBlockState(), MultifaceBlock::getFaceProperty); + ConditionBuilder conditionBuilder = condition(); + map.forEach((property, variantMutator) -> conditionBuilder.term(property, false)); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(block)); + MultiPartGenerator multiPartGenerator = MultiPartGenerator.multiPart(block); + map.forEach((property, variantMutator) -> { + multiPartGenerator.with(condition().term(property, true), multiVariant.with(variantMutator)); + multiPartGenerator.with(conditionBuilder, multiVariant.with(variantMutator)); + }); this.blockStateOutput.accept(multiPartGenerator); } private void createMossyCarpet(Block block) { - ResourceLocation resourceLocation = TexturedModel.CARPET.create(block, this.modelOutput); - ResourceLocation resourceLocation2 = TexturedModel.MOSSY_CARPET_SIDE - .get(block) - .updateTextures(textureMapping -> textureMapping.put(TextureSlot.SIDE, TextureMapping.getBlockTexture(block, "_side_tall"))) - .createWithSuffix(block, "_side_tall", this.modelOutput); - ResourceLocation resourceLocation3 = TexturedModel.MOSSY_CARPET_SIDE - .get(block) - .updateTextures(textureMapping -> textureMapping.put(TextureSlot.SIDE, TextureMapping.getBlockTexture(block, "_side_small"))) - .createWithSuffix(block, "_side_small", this.modelOutput); + Map, VariantMutator> map = selectMultifaceProperties(block.defaultBlockState(), MossyCarpetBlock::getPropertyForFace); + ConditionBuilder conditionBuilder = condition().term(MossyCarpetBlock.BASE, false); + map.forEach((property, variantMutator) -> conditionBuilder.term(property, WallSide.NONE)); + MultiVariant multiVariant = plainVariant(TexturedModel.CARPET.create(block, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant( + TexturedModel.MOSSY_CARPET_SIDE + .get(block) + .updateTextures(textureMapping -> textureMapping.put(TextureSlot.SIDE, TextureMapping.getBlockTexture(block, "_side_tall"))) + .createWithSuffix(block, "_side_tall", this.modelOutput) + ); + MultiVariant multiVariant3 = plainVariant( + TexturedModel.MOSSY_CARPET_SIDE + .get(block) + .updateTextures(textureMapping -> textureMapping.put(TextureSlot.SIDE, TextureMapping.getBlockTexture(block, "_side_small"))) + .createWithSuffix(block, "_side_small", this.modelOutput) + ); MultiPartGenerator multiPartGenerator = MultiPartGenerator.multiPart(block); - Condition.TerminalCondition terminalCondition = Condition.condition().term(MossyCarpetBlock.BASE, false); - multiPartGenerator.with(Condition.condition().term(MossyCarpetBlock.BASE, true), Variant.variant().with(VariantProperties.MODEL, resourceLocation)); - multiPartGenerator.with(terminalCondition, Variant.variant().with(VariantProperties.MODEL, resourceLocation)); - MULTIFACE_GENERATOR.stream().map(Pair::getFirst).forEach(directionx -> { - EnumProperty enumPropertyx = MossyCarpetBlock.getPropertyForFace(directionx); - if (enumPropertyx != null && block.defaultBlockState().hasProperty(enumPropertyx)) { - terminalCondition.term(enumPropertyx, WallSide.NONE); - } + multiPartGenerator.with(condition().term(MossyCarpetBlock.BASE, true), multiVariant); + multiPartGenerator.with(conditionBuilder, multiVariant); + map.forEach((property, variantMutator) -> { + multiPartGenerator.with(condition().term(property, WallSide.TALL), multiVariant2.with(variantMutator)); + multiPartGenerator.with(condition().term(property, WallSide.LOW), multiVariant3.with(variantMutator)); + multiPartGenerator.with(conditionBuilder, multiVariant2.with(variantMutator)); }); - - for (Pair> pair : MULTIFACE_GENERATOR) { - Direction direction = pair.getFirst(); - EnumProperty enumProperty = MossyCarpetBlock.getPropertyForFace(direction); - if (enumProperty != null) { - Function function = pair.getSecond(); - multiPartGenerator.with(Condition.condition().term(enumProperty, WallSide.TALL), (Variant)function.apply(resourceLocation2)); - multiPartGenerator.with(Condition.condition().term(enumProperty, WallSide.LOW), (Variant)function.apply(resourceLocation3)); - multiPartGenerator.with(terminalCondition, (Variant)function.apply(resourceLocation2)); - } - } - this.blockStateOutput.accept(multiPartGenerator); } private void createHangingMoss(Block block) { - PropertyDispatch propertyDispatch = PropertyDispatch.property(HangingMossBlock.TIP).generate(boolean_ -> { + this.registerSimpleFlatItemModel(block); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(block).with(PropertyDispatch.initial(HangingMossBlock.TIP).generate(boolean_ -> { String string = boolean_ ? "_tip" : ""; TextureMapping textureMapping = TextureMapping.cross(TextureMapping.getBlockTexture(block, string)); - ResourceLocation resourceLocation = BlockModelGenerators.PlantType.NOT_TINTED.getCross().createWithSuffix(block, string, textureMapping, this.modelOutput); - return Variant.variant().with(VariantProperties.MODEL, resourceLocation); - }); - this.registerSimpleFlatItemModel(block); - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(block).with(propertyDispatch)); + return plainVariant(BlockModelGenerators.PlantType.NOT_TINTED.getCross().createWithSuffix(block, string, textureMapping, this.modelOutput)); + }))); } private void createSculkCatalyst() { @@ -4248,47 +2928,35 @@ public class BlockModelGenerators { .put(TextureSlot.BOTTOM, resourceLocation) .put(TextureSlot.TOP, TextureMapping.getBlockTexture(Blocks.SCULK_CATALYST, "_top_bloom")) .put(TextureSlot.SIDE, TextureMapping.getBlockTexture(Blocks.SCULK_CATALYST, "_side_bloom")); - ResourceLocation resourceLocation2 = ModelTemplates.CUBE_BOTTOM_TOP.createWithSuffix(Blocks.SCULK_CATALYST, "", textureMapping, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.CUBE_BOTTOM_TOP.createWithSuffix(Blocks.SCULK_CATALYST, "_bloom", textureMapping2, this.modelOutput); + ResourceLocation resourceLocation2 = ModelTemplates.CUBE_BOTTOM_TOP.create(Blocks.SCULK_CATALYST, textureMapping, this.modelOutput); + MultiVariant multiVariant = plainVariant(resourceLocation2); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.CUBE_BOTTOM_TOP.createWithSuffix(Blocks.SCULK_CATALYST, "_bloom", textureMapping2, this.modelOutput)); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.SCULK_CATALYST) - .with( - PropertyDispatch.property(BlockStateProperties.BLOOM) - .generate(boolean_ -> Variant.variant().with(VariantProperties.MODEL, boolean_ ? resourceLocation3 : resourceLocation2)) - ) + MultiVariantGenerator.dispatch(Blocks.SCULK_CATALYST) + .with(PropertyDispatch.initial(BlockStateProperties.BLOOM).generate(boolean_ -> boolean_ ? multiVariant2 : multiVariant)) ); this.registerSimpleItemModel(Blocks.SCULK_CATALYST, resourceLocation2); } private void createChiseledBookshelf() { Block block = Blocks.CHISELED_BOOKSHELF; - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(block); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(block)); MultiPartGenerator multiPartGenerator = MultiPartGenerator.multiPart(block); - List.of( - Pair.of(Direction.NORTH, VariantProperties.Rotation.R0), - Pair.of(Direction.EAST, VariantProperties.Rotation.R90), - Pair.of(Direction.SOUTH, VariantProperties.Rotation.R180), - Pair.of(Direction.WEST, VariantProperties.Rotation.R270) - ) - .forEach( - pair -> { - Direction direction = (Direction)pair.getFirst(); - VariantProperties.Rotation rotation = (VariantProperties.Rotation)pair.getSecond(); - Condition.TerminalCondition terminalCondition = Condition.condition().term(BlockStateProperties.HORIZONTAL_FACING, direction); - multiPartGenerator.with( - terminalCondition, - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, rotation).with(VariantProperties.UV_LOCK, true) - ); - this.addSlotStateAndRotationVariants(multiPartGenerator, terminalCondition, rotation); - } - ); + List.of(Pair.of(Direction.NORTH, NOP), Pair.of(Direction.EAST, Y_ROT_90), Pair.of(Direction.SOUTH, Y_ROT_180), Pair.of(Direction.WEST, Y_ROT_270)) + .forEach(pair -> { + Direction direction = (Direction)pair.getFirst(); + VariantMutator variantMutator = (VariantMutator)pair.getSecond(); + Condition condition = condition().term(BlockStateProperties.HORIZONTAL_FACING, direction).build(); + multiPartGenerator.with(condition, multiVariant.with(variantMutator).with(UV_LOCK)); + this.addSlotStateAndRotationVariants(multiPartGenerator, condition, variantMutator); + }); this.blockStateOutput.accept(multiPartGenerator); this.registerSimpleItemModel(block, ModelLocationUtils.getModelLocation(block, "_inventory")); CHISELED_BOOKSHELF_SLOT_MODEL_CACHE.clear(); } - private void addSlotStateAndRotationVariants(MultiPartGenerator generator, Condition.TerminalCondition condition, VariantProperties.Rotation rotation) { + private void addSlotStateAndRotationVariants(MultiPartGenerator generator, Condition condition, VariantMutator rotation) { List.of( Pair.of(BlockStateProperties.CHISELED_BOOKSHELF_SLOT_0_OCCUPIED, ModelTemplates.CHISELED_BOOKSHELF_SLOT_TOP_LEFT), Pair.of(BlockStateProperties.CHISELED_BOOKSHELF_SLOT_1_OCCUPIED, ModelTemplates.CHISELED_BOOKSHELF_SLOT_TOP_MID), @@ -4306,33 +2974,26 @@ public class BlockModelGenerators { } private void addBookSlotModel( - MultiPartGenerator generator, - Condition.TerminalCondition condition, - VariantProperties.Rotation rotation, - BooleanProperty property, - ModelTemplate template, - boolean occupied + MultiPartGenerator generator, Condition conditon, VariantMutator rotation, BooleanProperty hasBookProperty, ModelTemplate template, boolean hasBook ) { - String string = occupied ? "_occupied" : "_empty"; + String string = hasBook ? "_occupied" : "_empty"; TextureMapping textureMapping = new TextureMapping().put(TextureSlot.TEXTURE, TextureMapping.getBlockTexture(Blocks.CHISELED_BOOKSHELF, string)); BlockModelGenerators.BookSlotModelCacheKey bookSlotModelCacheKey = new BlockModelGenerators.BookSlotModelCacheKey(template, string); - ResourceLocation resourceLocation = (ResourceLocation)CHISELED_BOOKSHELF_SLOT_MODEL_CACHE.computeIfAbsent( - bookSlotModelCacheKey, bookSlotModelCacheKeyx -> template.createWithSuffix(Blocks.CHISELED_BOOKSHELF, string, textureMapping, this.modelOutput) + MultiVariant multiVariant = plainVariant( + (ResourceLocation)CHISELED_BOOKSHELF_SLOT_MODEL_CACHE.computeIfAbsent( + bookSlotModelCacheKey, bookSlotModelCacheKeyx -> template.createWithSuffix(Blocks.CHISELED_BOOKSHELF, string, textureMapping, this.modelOutput) + ) ); generator.with( - Condition.and(condition, Condition.condition().term(property, occupied)), - Variant.variant().with(VariantProperties.MODEL, resourceLocation).with(VariantProperties.Y_ROT, rotation) + new CombinedCondition(CombinedCondition.Operation.AND, List.of(conditon, condition().term(hasBookProperty, hasBook).build())), multiVariant.with(rotation) ); } private void createMagmaBlock() { - this.blockStateOutput - .accept( - createSimpleBlock( - Blocks.MAGMA_BLOCK, - ModelTemplates.CUBE_ALL.create(Blocks.MAGMA_BLOCK, TextureMapping.cube(ModelLocationUtils.decorateBlockModelLocation("magma")), this.modelOutput) - ) - ); + MultiVariant multiVariant = plainVariant( + ModelTemplates.CUBE_ALL.create(Blocks.MAGMA_BLOCK, TextureMapping.cube(ModelLocationUtils.decorateBlockModelLocation("magma")), this.modelOutput) + ); + this.blockStateOutput.accept(createSimpleBlock(Blocks.MAGMA_BLOCK, multiVariant)); } private void createShulkerBox(Block block, @Nullable DyeColor color) { @@ -4352,23 +3013,25 @@ public class BlockModelGenerators { private void createInfestedStone() { ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.STONE); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.STONE, "_mirrored"); - this.blockStateOutput.accept(createRotatedVariant(Blocks.INFESTED_STONE, resourceLocation, resourceLocation2)); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(resourceLocation); + net.minecraft.client.renderer.block.model.Variant variant2 = plainModel(ModelLocationUtils.getModelLocation(Blocks.STONE, "_mirrored")); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(Blocks.INFESTED_STONE, createRotatedVariants(variant, variant2))); this.registerSimpleItemModel(Blocks.INFESTED_STONE, resourceLocation); } private void createInfestedDeepslate() { ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(Blocks.DEEPSLATE); - ResourceLocation resourceLocation2 = ModelLocationUtils.getModelLocation(Blocks.DEEPSLATE, "_mirrored"); - this.blockStateOutput.accept(createRotatedVariant(Blocks.INFESTED_DEEPSLATE, resourceLocation, resourceLocation2).with(createRotatedPillar())); + net.minecraft.client.renderer.block.model.Variant variant = plainModel(resourceLocation); + net.minecraft.client.renderer.block.model.Variant variant2 = plainModel(ModelLocationUtils.getModelLocation(Blocks.DEEPSLATE, "_mirrored")); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(Blocks.INFESTED_DEEPSLATE, createRotatedVariants(variant, variant2)).with(createRotatedPillar())); this.registerSimpleItemModel(Blocks.INFESTED_DEEPSLATE, resourceLocation); } private void createNetherRoots(Block plantBlock, Block pottedPlantBlock) { this.createCrossBlockWithDefaultItem(plantBlock, BlockModelGenerators.PlantType.NOT_TINTED); TextureMapping textureMapping = TextureMapping.plant(TextureMapping.getBlockTexture(plantBlock, "_pot")); - ResourceLocation resourceLocation = BlockModelGenerators.PlantType.NOT_TINTED.getCrossPot().create(pottedPlantBlock, textureMapping, this.modelOutput); - this.blockStateOutput.accept(createSimpleBlock(pottedPlantBlock, resourceLocation)); + MultiVariant multiVariant = plainVariant(BlockModelGenerators.PlantType.NOT_TINTED.getCrossPot().create(pottedPlantBlock, textureMapping, this.modelOutput)); + this.blockStateOutput.accept(createSimpleBlock(pottedPlantBlock, multiVariant)); } private void createRespawnAnchor() { @@ -4387,44 +3050,27 @@ public class BlockModelGenerators { this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.RESPAWN_ANCHOR) - .with( - PropertyDispatch.property(BlockStateProperties.RESPAWN_ANCHOR_CHARGES) - .generate(integer -> Variant.variant().with(VariantProperties.MODEL, resourceLocations[integer])) - ) + MultiVariantGenerator.dispatch(Blocks.RESPAWN_ANCHOR) + .with(PropertyDispatch.initial(BlockStateProperties.RESPAWN_ANCHOR_CHARGES).generate(integer -> plainVariant(resourceLocations[integer]))) ); this.registerSimpleItemModel(Blocks.RESPAWN_ANCHOR, resourceLocations[0]); } - private Variant applyRotation(FrontAndTop frontAndTop, Variant variant) { - switch (frontAndTop) { - case DOWN_NORTH: - return variant.with(VariantProperties.X_ROT, VariantProperties.Rotation.R90); - case DOWN_SOUTH: - return variant.with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180); - case DOWN_WEST: - return variant.with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270); - case DOWN_EAST: - return variant.with(VariantProperties.X_ROT, VariantProperties.Rotation.R90).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90); - case UP_NORTH: - return variant.with(VariantProperties.X_ROT, VariantProperties.Rotation.R270).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180); - case UP_SOUTH: - return variant.with(VariantProperties.X_ROT, VariantProperties.Rotation.R270); - case UP_WEST: - return variant.with(VariantProperties.X_ROT, VariantProperties.Rotation.R270).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90); - case UP_EAST: - return variant.with(VariantProperties.X_ROT, VariantProperties.Rotation.R270).with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270); - case NORTH_UP: - return variant; - case SOUTH_UP: - return variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R180); - case WEST_UP: - return variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R270); - case EAST_UP: - return variant.with(VariantProperties.Y_ROT, VariantProperties.Rotation.R90); - default: - throw new UnsupportedOperationException("Rotation " + frontAndTop + " can't be expressed with existing x and y values"); - } + private static VariantMutator applyRotation(FrontAndTop rotation) { + return switch (rotation) { + case DOWN_NORTH -> X_ROT_90; + case DOWN_SOUTH -> X_ROT_90.then(Y_ROT_180); + case DOWN_WEST -> X_ROT_90.then(Y_ROT_270); + case DOWN_EAST -> X_ROT_90.then(Y_ROT_90); + case UP_NORTH -> X_ROT_270.then(Y_ROT_180); + case UP_SOUTH -> X_ROT_270; + case UP_WEST -> X_ROT_270.then(Y_ROT_90); + case UP_EAST -> X_ROT_270.then(Y_ROT_270); + case NORTH_UP -> NOP; + case SOUTH_UP -> Y_ROT_180; + case WEST_UP -> Y_ROT_270; + case EAST_UP -> Y_ROT_90; + }; } private void createJigsaw() { @@ -4440,49 +3086,49 @@ public class BlockModelGenerators { .put(TextureSlot.NORTH, resourceLocation) .put(TextureSlot.SOUTH, resourceLocation2) .put(TextureSlot.UP, resourceLocation4); - ResourceLocation resourceLocation5 = ModelTemplates.CUBE_DIRECTIONAL.create(Blocks.JIGSAW, textureMapping, this.modelOutput); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(Blocks.JIGSAW, Variant.variant().with(VariantProperties.MODEL, resourceLocation5)) - .with(PropertyDispatch.property(BlockStateProperties.ORIENTATION).generate(frontAndTop -> this.applyRotation(frontAndTop, Variant.variant()))) + MultiVariantGenerator.dispatch(Blocks.JIGSAW, plainVariant(ModelTemplates.CUBE_DIRECTIONAL.create(Blocks.JIGSAW, textureMapping, this.modelOutput))) + .with(PropertyDispatch.modify(BlockStateProperties.ORIENTATION).generate(BlockModelGenerators::applyRotation)) ); } private void createPetrifiedOakSlab() { Block block = Blocks.OAK_PLANKS; - ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(block); - TexturedModel texturedModel = TexturedModel.CUBE.get(block); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.getModelLocation(block)); + TextureMapping textureMapping = TextureMapping.cube(block); Block block2 = Blocks.PETRIFIED_OAK_SLAB; - ResourceLocation resourceLocation2 = ModelTemplates.SLAB_BOTTOM.create(block2, texturedModel.getMapping(), this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.SLAB_TOP.create(block2, texturedModel.getMapping(), this.modelOutput); - this.blockStateOutput.accept(createSlab(block2, resourceLocation2, resourceLocation3, resourceLocation)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.SLAB_BOTTOM.create(block2, textureMapping, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.SLAB_TOP.create(block2, textureMapping, this.modelOutput)); + this.blockStateOutput.accept(createSlab(block2, multiVariant2, multiVariant3, multiVariant)); } - private void createHead(Block headBlock, Block wallHeadBlock, Type type, ResourceLocation modelLocation) { - ResourceLocation resourceLocation = ModelLocationUtils.decorateBlockModelLocation("skull"); - this.blockStateOutput.accept(createSimpleBlock(headBlock, resourceLocation)); - this.blockStateOutput.accept(createSimpleBlock(wallHeadBlock, resourceLocation)); - this.itemModelOutput.accept(headBlock.asItem(), ItemModelUtils.specialModel(modelLocation, new SkullSpecialRenderer.Unbaked(type))); + private void createHead(Block headBlock, Block wallHeadBlock, SkullBlock.Type type, ResourceLocation modelLocation) { + MultiVariant multiVariant = plainVariant(ModelLocationUtils.decorateBlockModelLocation("skull")); + this.blockStateOutput.accept(createSimpleBlock(headBlock, multiVariant)); + this.blockStateOutput.accept(createSimpleBlock(wallHeadBlock, multiVariant)); + this.itemModelOutput.accept(headBlock.asItem(), ItemModelUtils.specialModel(modelLocation, new Unbaked(type))); } private void createHeads() { ResourceLocation resourceLocation = ModelLocationUtils.decorateItemModelLocation("template_skull"); - this.createHead(Blocks.CREEPER_HEAD, Blocks.CREEPER_WALL_HEAD, Types.CREEPER, resourceLocation); - this.createHead(Blocks.PLAYER_HEAD, Blocks.PLAYER_WALL_HEAD, Types.PLAYER, resourceLocation); - this.createHead(Blocks.ZOMBIE_HEAD, Blocks.ZOMBIE_WALL_HEAD, Types.ZOMBIE, resourceLocation); - this.createHead(Blocks.SKELETON_SKULL, Blocks.SKELETON_WALL_SKULL, Types.SKELETON, resourceLocation); - this.createHead(Blocks.WITHER_SKELETON_SKULL, Blocks.WITHER_SKELETON_WALL_SKULL, Types.WITHER_SKELETON, resourceLocation); - this.createHead(Blocks.PIGLIN_HEAD, Blocks.PIGLIN_WALL_HEAD, Types.PIGLIN, resourceLocation); - this.createHead(Blocks.DRAGON_HEAD, Blocks.DRAGON_WALL_HEAD, Types.DRAGON, ModelLocationUtils.getModelLocation(Items.DRAGON_HEAD)); + this.createHead(Blocks.CREEPER_HEAD, Blocks.CREEPER_WALL_HEAD, SkullBlock.Types.CREEPER, resourceLocation); + this.createHead(Blocks.PLAYER_HEAD, Blocks.PLAYER_WALL_HEAD, SkullBlock.Types.PLAYER, resourceLocation); + this.createHead(Blocks.ZOMBIE_HEAD, Blocks.ZOMBIE_WALL_HEAD, SkullBlock.Types.ZOMBIE, resourceLocation); + this.createHead(Blocks.SKELETON_SKULL, Blocks.SKELETON_WALL_SKULL, SkullBlock.Types.SKELETON, resourceLocation); + this.createHead(Blocks.WITHER_SKELETON_SKULL, Blocks.WITHER_SKELETON_WALL_SKULL, SkullBlock.Types.WITHER_SKELETON, resourceLocation); + this.createHead(Blocks.PIGLIN_HEAD, Blocks.PIGLIN_WALL_HEAD, SkullBlock.Types.PIGLIN, resourceLocation); + this.createHead(Blocks.DRAGON_HEAD, Blocks.DRAGON_WALL_HEAD, SkullBlock.Types.DRAGON, ModelLocationUtils.getModelLocation(Items.DRAGON_HEAD)); } private void createBanner(Block block, Block wallBlock, DyeColor color) { - ResourceLocation resourceLocation = ModelLocationUtils.decorateBlockModelLocation("banner"); - ResourceLocation resourceLocation2 = ModelLocationUtils.decorateItemModelLocation("template_banner"); - this.blockStateOutput.accept(createSimpleBlock(block, resourceLocation)); - this.blockStateOutput.accept(createSimpleBlock(wallBlock, resourceLocation)); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.decorateBlockModelLocation("banner")); + ResourceLocation resourceLocation = ModelLocationUtils.decorateItemModelLocation("template_banner"); + this.blockStateOutput.accept(createSimpleBlock(block, multiVariant)); + this.blockStateOutput.accept(createSimpleBlock(wallBlock, multiVariant)); Item item = block.asItem(); - this.itemModelOutput.accept(item, ItemModelUtils.specialModel(resourceLocation2, new BannerSpecialRenderer.Unbaked(color))); + this.itemModelOutput + .accept(item, ItemModelUtils.specialModel(resourceLocation, new net.minecraft.client.renderer.special.BannerSpecialRenderer.Unbaked(color))); } private void createBanners() { @@ -4524,12 +3170,12 @@ public class BlockModelGenerators { } private void createBed(Block block, Block particleBlock, DyeColor color) { - ResourceLocation resourceLocation = ModelLocationUtils.decorateBlockModelLocation("bed"); - this.blockStateOutput.accept(createSimpleBlock(block, resourceLocation)); + MultiVariant multiVariant = plainVariant(ModelLocationUtils.decorateBlockModelLocation("bed")); + this.blockStateOutput.accept(createSimpleBlock(block, multiVariant)); Item item = block.asItem(); - ResourceLocation resourceLocation2 = ModelTemplates.BED_INVENTORY + ResourceLocation resourceLocation = ModelTemplates.BED_INVENTORY .create(ModelLocationUtils.getModelLocation(item), TextureMapping.particle(particleBlock), this.modelOutput); - this.itemModelOutput.accept(item, ItemModelUtils.specialModel(resourceLocation2, new BedSpecialRenderer.Unbaked(color))); + this.itemModelOutput.accept(item, ItemModelUtils.specialModel(resourceLocation, new BedSpecialRenderer.Unbaked(color))); } private void createBeds() { @@ -4551,7 +3197,7 @@ public class BlockModelGenerators { this.createBed(Blocks.BLACK_BED, Blocks.BLACK_WOOL, DyeColor.BLACK); } - private void generateSimpleSpecialItemModel(Block block, SpecialModelRenderer.Unbaked specialModel) { + private void generateSimpleSpecialItemModel(Block block, net.minecraft.client.renderer.special.SpecialModelRenderer.Unbaked specialModel) { Item item = block.asItem(); ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(item); this.itemModelOutput.accept(item, ItemModelUtils.specialModel(resourceLocation, specialModel)); @@ -4636,6 +3282,10 @@ public class BlockModelGenerators { this.createHangingMoss(Blocks.PALE_HANGING_MOSS); this.createTrivialCube(Blocks.PALE_MOSS_BLOCK); this.createFlowerBed(Blocks.PINK_PETALS); + this.createFlowerBed(Blocks.WILDFLOWERS); + this.createLeafLitter(Blocks.LEAF_LITTER); + this.createCrossBlock(Blocks.FIREFLY_BUSH, BlockModelGenerators.PlantType.EMISSIVE_NOT_TINTED); + this.registerSimpleFlatItemModel(Items.FIREFLY_BUSH); this.createAirLikeBlock(Blocks.BARRIER, Items.BARRIER); this.registerSimpleFlatItemModel(Items.BARRIER); this.createLightBlock(); @@ -4789,6 +3439,8 @@ public class BlockModelGenerators { this.createStonecutter(); this.createStructureBlock(); this.createSweetBerryBush(); + this.createTestBlock(); + this.createTrivialCube(Blocks.TEST_INSTANCE_BLOCK); this.createTripwire(); this.createTripwireHook(); this.createTurtleEgg(); @@ -4823,7 +3475,7 @@ public class BlockModelGenerators { this.createCrafterBlock(); this.createLantern(Blocks.LANTERN); this.createLantern(Blocks.SOUL_LANTERN); - this.createAxisAlignedPillarBlockCustomModel(Blocks.CHAIN, ModelLocationUtils.getModelLocation(Blocks.CHAIN)); + this.createAxisAlignedPillarBlockCustomModel(Blocks.CHAIN, plainVariant(ModelLocationUtils.getModelLocation(Blocks.CHAIN))); this.createAxisAlignedPillarBlock(Blocks.BASALT, TexturedModel.COLUMN); this.createAxisAlignedPillarBlock(Blocks.POLISHED_BASALT, TexturedModel.COLUMN); this.createTrivialCube(Blocks.SMOOTH_BASALT); @@ -4876,9 +3528,9 @@ public class BlockModelGenerators { this.createShulkerBox(Blocks.RED_SHULKER_BOX, DyeColor.RED); this.createShulkerBox(Blocks.BLACK_SHULKER_BOX, DyeColor.BLACK); this.createParticleOnlyBlock(Blocks.CONDUIT); - this.generateSimpleSpecialItemModel(Blocks.CONDUIT, new ConduitSpecialRenderer.Unbaked()); + this.generateSimpleSpecialItemModel(Blocks.CONDUIT, new net.minecraft.client.renderer.special.ConduitSpecialRenderer.Unbaked()); this.createParticleOnlyBlock(Blocks.DECORATED_POT, Blocks.TERRACOTTA); - this.generateSimpleSpecialItemModel(Blocks.DECORATED_POT, new DecoratedPotSpecialRenderer.Unbaked()); + this.generateSimpleSpecialItemModel(Blocks.DECORATED_POT, new net.minecraft.client.renderer.special.DecoratedPotSpecialRenderer.Unbaked()); this.createParticleOnlyBlock(Blocks.END_PORTAL, Blocks.OBSIDIAN); this.createParticleOnlyBlock(Blocks.END_GATEWAY, Blocks.OBSIDIAN); this.createTrivialCube(Blocks.AZALEA_LEAVES); @@ -5017,6 +3669,10 @@ public class BlockModelGenerators { this.createMushroomBlock(Blocks.MUSHROOM_STEM); this.createCrossBlock(Blocks.SHORT_GRASS, BlockModelGenerators.PlantType.TINTED); this.createItemWithGrassTint(Blocks.SHORT_GRASS); + this.createCrossBlockWithDefaultItem(Blocks.SHORT_DRY_GRASS, BlockModelGenerators.PlantType.NOT_TINTED); + this.createCrossBlockWithDefaultItem(Blocks.TALL_DRY_GRASS, BlockModelGenerators.PlantType.NOT_TINTED); + this.createCrossBlock(Blocks.BUSH, BlockModelGenerators.PlantType.TINTED); + this.createItemWithGrassTint(Blocks.BUSH); this.createCrossBlock(Blocks.SUGAR_CANE, BlockModelGenerators.PlantType.TINTED); this.registerSimpleFlatItemModel(Items.SUGAR_CANE); this.createGrowingPlant(Blocks.KELP, Blocks.KELP_PLANT, BlockModelGenerators.PlantType.NOT_TINTED); @@ -5030,6 +3686,7 @@ public class BlockModelGenerators { Blocks.BAMBOO_SAPLING, BlockModelGenerators.PlantType.TINTED, TextureMapping.cross(TextureMapping.getBlockTexture(Blocks.BAMBOO, "_stage0")) ); this.createBamboo(); + this.createCrossBlockWithDefaultItem(Blocks.CACTUS_FLOWER, BlockModelGenerators.PlantType.NOT_TINTED); this.createCrossBlockWithDefaultItem(Blocks.COBWEB, BlockModelGenerators.PlantType.NOT_TINTED); this.createDoublePlantWithDefaultItem(Blocks.LILAC, BlockModelGenerators.PlantType.NOT_TINTED); this.createDoublePlantWithDefaultItem(Blocks.ROSE_BUSH, BlockModelGenerators.PlantType.NOT_TINTED); @@ -5184,18 +3841,12 @@ public class BlockModelGenerators { private void createLightBlock() { ItemModel.Unbaked unbaked = ItemModelUtils.plainModel(this.createFlatItemModel(Items.LIGHT)); Map map = new HashMap(16); - PropertyDispatch.C1 c1 = PropertyDispatch.property(BlockStateProperties.LEVEL); + PropertyDispatch.C1 c1 = PropertyDispatch.initial(BlockStateProperties.LEVEL); for (int i = 0; i <= 15; i++) { String string = String.format(Locale.ROOT, "_%02d", i); ResourceLocation resourceLocation = TextureMapping.getItemTexture(Items.LIGHT, string); - c1.select( - i, - Variant.variant() - .with( - VariantProperties.MODEL, ModelTemplates.PARTICLE_ONLY.createWithSuffix(Blocks.LIGHT, string, TextureMapping.particle(resourceLocation), this.modelOutput) - ) - ); + c1.select(i, plainVariant(ModelTemplates.PARTICLE_ONLY.createWithSuffix(Blocks.LIGHT, string, TextureMapping.particle(resourceLocation), this.modelOutput))); ItemModel.Unbaked unbaked2 = ItemModelUtils.plainModel( ModelTemplates.FLAT_ITEM.create(ModelLocationUtils.getModelLocation(Items.LIGHT, string), TextureMapping.layer0(resourceLocation), this.modelOutput) ); @@ -5203,53 +3854,52 @@ public class BlockModelGenerators { } this.itemModelOutput.accept(Items.LIGHT, ItemModelUtils.selectBlockItemProperty(LightBlock.LEVEL, unbaked, map)); - this.blockStateOutput.accept(MultiVariantGenerator.multiVariant(Blocks.LIGHT).with(c1)); + this.blockStateOutput.accept(MultiVariantGenerator.dispatch(Blocks.LIGHT).with(c1)); } private void createCandleAndCandleCake(Block candleBlock, Block candleCakeBlock) { this.registerSimpleFlatItemModel(candleBlock.asItem()); TextureMapping textureMapping = TextureMapping.cube(TextureMapping.getBlockTexture(candleBlock)); TextureMapping textureMapping2 = TextureMapping.cube(TextureMapping.getBlockTexture(candleBlock, "_lit")); - ResourceLocation resourceLocation = ModelTemplates.CANDLE.createWithSuffix(candleBlock, "_one_candle", textureMapping, this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.TWO_CANDLES.createWithSuffix(candleBlock, "_two_candles", textureMapping, this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.THREE_CANDLES.createWithSuffix(candleBlock, "_three_candles", textureMapping, this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.FOUR_CANDLES.createWithSuffix(candleBlock, "_four_candles", textureMapping, this.modelOutput); - ResourceLocation resourceLocation5 = ModelTemplates.CANDLE.createWithSuffix(candleBlock, "_one_candle_lit", textureMapping2, this.modelOutput); - ResourceLocation resourceLocation6 = ModelTemplates.TWO_CANDLES.createWithSuffix(candleBlock, "_two_candles_lit", textureMapping2, this.modelOutput); - ResourceLocation resourceLocation7 = ModelTemplates.THREE_CANDLES.createWithSuffix(candleBlock, "_three_candles_lit", textureMapping2, this.modelOutput); - ResourceLocation resourceLocation8 = ModelTemplates.FOUR_CANDLES.createWithSuffix(candleBlock, "_four_candles_lit", textureMapping2, this.modelOutput); + MultiVariant multiVariant = plainVariant(ModelTemplates.CANDLE.createWithSuffix(candleBlock, "_one_candle", textureMapping, this.modelOutput)); + MultiVariant multiVariant2 = plainVariant(ModelTemplates.TWO_CANDLES.createWithSuffix(candleBlock, "_two_candles", textureMapping, this.modelOutput)); + MultiVariant multiVariant3 = plainVariant(ModelTemplates.THREE_CANDLES.createWithSuffix(candleBlock, "_three_candles", textureMapping, this.modelOutput)); + MultiVariant multiVariant4 = plainVariant(ModelTemplates.FOUR_CANDLES.createWithSuffix(candleBlock, "_four_candles", textureMapping, this.modelOutput)); + MultiVariant multiVariant5 = plainVariant(ModelTemplates.CANDLE.createWithSuffix(candleBlock, "_one_candle_lit", textureMapping2, this.modelOutput)); + MultiVariant multiVariant6 = plainVariant(ModelTemplates.TWO_CANDLES.createWithSuffix(candleBlock, "_two_candles_lit", textureMapping2, this.modelOutput)); + MultiVariant multiVariant7 = plainVariant(ModelTemplates.THREE_CANDLES.createWithSuffix(candleBlock, "_three_candles_lit", textureMapping2, this.modelOutput)); + MultiVariant multiVariant8 = plainVariant(ModelTemplates.FOUR_CANDLES.createWithSuffix(candleBlock, "_four_candles_lit", textureMapping2, this.modelOutput)); this.blockStateOutput .accept( - MultiVariantGenerator.multiVariant(candleBlock) + MultiVariantGenerator.dispatch(candleBlock) .with( - PropertyDispatch.properties(BlockStateProperties.CANDLES, BlockStateProperties.LIT) - .select(1, false, Variant.variant().with(VariantProperties.MODEL, resourceLocation)) - .select(2, false, Variant.variant().with(VariantProperties.MODEL, resourceLocation2)) - .select(3, false, Variant.variant().with(VariantProperties.MODEL, resourceLocation3)) - .select(4, false, Variant.variant().with(VariantProperties.MODEL, resourceLocation4)) - .select(1, true, Variant.variant().with(VariantProperties.MODEL, resourceLocation5)) - .select(2, true, Variant.variant().with(VariantProperties.MODEL, resourceLocation6)) - .select(3, true, Variant.variant().with(VariantProperties.MODEL, resourceLocation7)) - .select(4, true, Variant.variant().with(VariantProperties.MODEL, resourceLocation8)) + PropertyDispatch.initial(BlockStateProperties.CANDLES, BlockStateProperties.LIT) + .select(1, false, multiVariant) + .select(2, false, multiVariant2) + .select(3, false, multiVariant3) + .select(4, false, multiVariant4) + .select(1, true, multiVariant5) + .select(2, true, multiVariant6) + .select(3, true, multiVariant7) + .select(4, true, multiVariant8) ) ); - ResourceLocation resourceLocation9 = ModelTemplates.CANDLE_CAKE.create(candleCakeBlock, TextureMapping.candleCake(candleBlock, false), this.modelOutput); - ResourceLocation resourceLocation10 = ModelTemplates.CANDLE_CAKE - .createWithSuffix(candleCakeBlock, "_lit", TextureMapping.candleCake(candleBlock, true), this.modelOutput); + MultiVariant multiVariant9 = plainVariant(ModelTemplates.CANDLE_CAKE.create(candleCakeBlock, TextureMapping.candleCake(candleBlock, false), this.modelOutput)); + MultiVariant multiVariant10 = plainVariant( + ModelTemplates.CANDLE_CAKE.createWithSuffix(candleCakeBlock, "_lit", TextureMapping.candleCake(candleBlock, true), this.modelOutput) + ); this.blockStateOutput - .accept( - MultiVariantGenerator.multiVariant(candleCakeBlock).with(createBooleanModelDispatch(BlockStateProperties.LIT, resourceLocation10, resourceLocation9)) - ); + .accept(MultiVariantGenerator.dispatch(candleCakeBlock).with(createBooleanModelDispatch(BlockStateProperties.LIT, multiVariant10, multiVariant9))); } @Environment(EnvType.CLIENT) class BlockFamilyProvider { private final TextureMapping mapping; - private final Map models = Maps.newHashMap(); + private final Map models = new HashMap(); @Nullable private BlockFamily family; @Nullable - private ResourceLocation fullBlock; + private net.minecraft.client.renderer.block.model.Variant fullBlock; private final Set skipGeneratingModelsFor = new HashSet(); public BlockFamilyProvider(final TextureMapping mapping) { @@ -5257,15 +3907,15 @@ public class BlockModelGenerators { } public BlockModelGenerators.BlockFamilyProvider fullBlock(Block block, ModelTemplate modelTemplate) { - this.fullBlock = modelTemplate.create(block, this.mapping, BlockModelGenerators.this.modelOutput); - if (BlockModelGenerators.this.fullBlockModelCustomGenerators.containsKey(block)) { + this.fullBlock = BlockModelGenerators.plainModel(modelTemplate.create(block, this.mapping, BlockModelGenerators.this.modelOutput)); + if (BlockModelGenerators.FULL_BLOCK_MODEL_CUSTOM_GENERATORS.containsKey(block)) { BlockModelGenerators.this.blockStateOutput .accept( - ((BlockModelGenerators.BlockStateGeneratorSupplier)BlockModelGenerators.this.fullBlockModelCustomGenerators.get(block)) + ((BlockModelGenerators.BlockStateGeneratorSupplier)BlockModelGenerators.FULL_BLOCK_MODEL_CUSTOM_GENERATORS.get(block)) .create(block, this.fullBlock, this.mapping, BlockModelGenerators.this.modelOutput) ); } else { - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(block, this.fullBlock)); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(block, BlockModelGenerators.variant(this.fullBlock))); } return this; @@ -5273,83 +3923,121 @@ public class BlockModelGenerators { public BlockModelGenerators.BlockFamilyProvider donateModelTo(Block sourceBlock, Block block) { ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(sourceBlock); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(block, resourceLocation)); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(block, BlockModelGenerators.plainVariant(resourceLocation))); BlockModelGenerators.this.itemModelOutput.copy(sourceBlock.asItem(), block.asItem()); this.skipGeneratingModelsFor.add(block); return this; } public BlockModelGenerators.BlockFamilyProvider button(Block buttonBlock) { - ResourceLocation resourceLocation = ModelTemplates.BUTTON.create(buttonBlock, this.mapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.BUTTON_PRESSED.create(buttonBlock, this.mapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createButton(buttonBlock, resourceLocation, resourceLocation2)); - ResourceLocation resourceLocation3 = ModelTemplates.BUTTON_INVENTORY.create(buttonBlock, this.mapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.registerSimpleItemModel(buttonBlock, resourceLocation3); + MultiVariant multiVariant = BlockModelGenerators.plainVariant(ModelTemplates.BUTTON.create(buttonBlock, this.mapping, BlockModelGenerators.this.modelOutput)); + MultiVariant multiVariant2 = BlockModelGenerators.plainVariant( + ModelTemplates.BUTTON_PRESSED.create(buttonBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createButton(buttonBlock, multiVariant, multiVariant2)); + ResourceLocation resourceLocation = ModelTemplates.BUTTON_INVENTORY.create(buttonBlock, this.mapping, BlockModelGenerators.this.modelOutput); + BlockModelGenerators.this.registerSimpleItemModel(buttonBlock, resourceLocation); return this; } public BlockModelGenerators.BlockFamilyProvider wall(Block wallBlock) { - ResourceLocation resourceLocation = ModelTemplates.WALL_POST.create(wallBlock, this.mapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.WALL_LOW_SIDE.create(wallBlock, this.mapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.WALL_TALL_SIDE.create(wallBlock, this.mapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createWall(wallBlock, resourceLocation, resourceLocation2, resourceLocation3)); - ResourceLocation resourceLocation4 = ModelTemplates.WALL_INVENTORY.create(wallBlock, this.mapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.registerSimpleItemModel(wallBlock, resourceLocation4); + MultiVariant multiVariant = BlockModelGenerators.plainVariant( + ModelTemplates.WALL_POST.create(wallBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant2 = BlockModelGenerators.plainVariant( + ModelTemplates.WALL_LOW_SIDE.create(wallBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant3 = BlockModelGenerators.plainVariant( + ModelTemplates.WALL_TALL_SIDE.create(wallBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createWall(wallBlock, multiVariant, multiVariant2, multiVariant3)); + ResourceLocation resourceLocation = ModelTemplates.WALL_INVENTORY.create(wallBlock, this.mapping, BlockModelGenerators.this.modelOutput); + BlockModelGenerators.this.registerSimpleItemModel(wallBlock, resourceLocation); return this; } public BlockModelGenerators.BlockFamilyProvider customFence(Block fenceBlock) { TextureMapping textureMapping = TextureMapping.customParticle(fenceBlock); - ResourceLocation resourceLocation = ModelTemplates.CUSTOM_FENCE_POST.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.CUSTOM_FENCE_SIDE_NORTH.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.CUSTOM_FENCE_SIDE_EAST.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.CUSTOM_FENCE_SIDE_SOUTH.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation5 = ModelTemplates.CUSTOM_FENCE_SIDE_WEST.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput); + MultiVariant multiVariant = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_POST.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant2 = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_SIDE_NORTH.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant3 = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_SIDE_EAST.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant4 = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_SIDE_SOUTH.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant5 = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_SIDE_WEST.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); BlockModelGenerators.this.blockStateOutput - .accept(BlockModelGenerators.createCustomFence(fenceBlock, resourceLocation, resourceLocation2, resourceLocation3, resourceLocation4, resourceLocation5)); - ResourceLocation resourceLocation6 = ModelTemplates.CUSTOM_FENCE_INVENTORY.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.registerSimpleItemModel(fenceBlock, resourceLocation6); + .accept(BlockModelGenerators.createCustomFence(fenceBlock, multiVariant, multiVariant2, multiVariant3, multiVariant4, multiVariant5)); + ResourceLocation resourceLocation = ModelTemplates.CUSTOM_FENCE_INVENTORY.create(fenceBlock, textureMapping, BlockModelGenerators.this.modelOutput); + BlockModelGenerators.this.registerSimpleItemModel(fenceBlock, resourceLocation); return this; } public BlockModelGenerators.BlockFamilyProvider fence(Block fenceBlock) { - ResourceLocation resourceLocation = ModelTemplates.FENCE_POST.create(fenceBlock, this.mapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.FENCE_SIDE.create(fenceBlock, this.mapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createFence(fenceBlock, resourceLocation, resourceLocation2)); - ResourceLocation resourceLocation3 = ModelTemplates.FENCE_INVENTORY.create(fenceBlock, this.mapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.registerSimpleItemModel(fenceBlock, resourceLocation3); + MultiVariant multiVariant = BlockModelGenerators.plainVariant( + ModelTemplates.FENCE_POST.create(fenceBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant2 = BlockModelGenerators.plainVariant( + ModelTemplates.FENCE_SIDE.create(fenceBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createFence(fenceBlock, multiVariant, multiVariant2)); + ResourceLocation resourceLocation = ModelTemplates.FENCE_INVENTORY.create(fenceBlock, this.mapping, BlockModelGenerators.this.modelOutput); + BlockModelGenerators.this.registerSimpleItemModel(fenceBlock, resourceLocation); return this; } public BlockModelGenerators.BlockFamilyProvider customFenceGate(Block customFenceGateBlock) { TextureMapping textureMapping = TextureMapping.customParticle(customFenceGateBlock); - ResourceLocation resourceLocation = ModelTemplates.CUSTOM_FENCE_GATE_OPEN - .create(customFenceGateBlock, textureMapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.CUSTOM_FENCE_GATE_CLOSED - .create(customFenceGateBlock, textureMapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.CUSTOM_FENCE_GATE_WALL_OPEN - .create(customFenceGateBlock, textureMapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.CUSTOM_FENCE_GATE_WALL_CLOSED - .create(customFenceGateBlock, textureMapping, BlockModelGenerators.this.modelOutput); + MultiVariant multiVariant = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_GATE_OPEN.create(customFenceGateBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant2 = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_GATE_CLOSED.create(customFenceGateBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant3 = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_GATE_WALL_OPEN.create(customFenceGateBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant4 = BlockModelGenerators.plainVariant( + ModelTemplates.CUSTOM_FENCE_GATE_WALL_CLOSED.create(customFenceGateBlock, textureMapping, BlockModelGenerators.this.modelOutput) + ); BlockModelGenerators.this.blockStateOutput - .accept(BlockModelGenerators.createFenceGate(customFenceGateBlock, resourceLocation, resourceLocation2, resourceLocation3, resourceLocation4, false)); + .accept(BlockModelGenerators.createFenceGate(customFenceGateBlock, multiVariant, multiVariant2, multiVariant3, multiVariant4, false)); return this; } public BlockModelGenerators.BlockFamilyProvider fenceGate(Block fenceGateBlock) { - ResourceLocation resourceLocation = ModelTemplates.FENCE_GATE_OPEN.create(fenceGateBlock, this.mapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.FENCE_GATE_CLOSED.create(fenceGateBlock, this.mapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation3 = ModelTemplates.FENCE_GATE_WALL_OPEN.create(fenceGateBlock, this.mapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation4 = ModelTemplates.FENCE_GATE_WALL_CLOSED.create(fenceGateBlock, this.mapping, BlockModelGenerators.this.modelOutput); + MultiVariant multiVariant = BlockModelGenerators.plainVariant( + ModelTemplates.FENCE_GATE_OPEN.create(fenceGateBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant2 = BlockModelGenerators.plainVariant( + ModelTemplates.FENCE_GATE_CLOSED.create(fenceGateBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant3 = BlockModelGenerators.plainVariant( + ModelTemplates.FENCE_GATE_WALL_OPEN.create(fenceGateBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant4 = BlockModelGenerators.plainVariant( + ModelTemplates.FENCE_GATE_WALL_CLOSED.create(fenceGateBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); BlockModelGenerators.this.blockStateOutput - .accept(BlockModelGenerators.createFenceGate(fenceGateBlock, resourceLocation, resourceLocation2, resourceLocation3, resourceLocation4, true)); + .accept(BlockModelGenerators.createFenceGate(fenceGateBlock, multiVariant, multiVariant2, multiVariant3, multiVariant4, true)); return this; } public BlockModelGenerators.BlockFamilyProvider pressurePlate(Block pressurePlateBlock) { - ResourceLocation resourceLocation = ModelTemplates.PRESSURE_PLATE_UP.create(pressurePlateBlock, this.mapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.PRESSURE_PLATE_DOWN.create(pressurePlateBlock, this.mapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createPressurePlate(pressurePlateBlock, resourceLocation, resourceLocation2)); + MultiVariant multiVariant = BlockModelGenerators.plainVariant( + ModelTemplates.PRESSURE_PLATE_UP.create(pressurePlateBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + MultiVariant multiVariant2 = BlockModelGenerators.plainVariant( + ModelTemplates.PRESSURE_PLATE_DOWN.create(pressurePlateBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createPressurePlate(pressurePlateBlock, multiVariant, multiVariant2)); return this; } @@ -5357,10 +4045,12 @@ public class BlockModelGenerators { if (this.family == null) { throw new IllegalStateException("Family not defined"); } else { - Block block = (Block)this.family.getVariants().get(net.minecraft.data.BlockFamily.Variant.WALL_SIGN); - ResourceLocation resourceLocation = ModelTemplates.PARTICLE_ONLY.create(signBlock, this.mapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(signBlock, resourceLocation)); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(block, resourceLocation)); + Block block = (Block)this.family.getVariants().get(Variant.WALL_SIGN); + MultiVariant multiVariant = BlockModelGenerators.plainVariant( + ModelTemplates.PARTICLE_ONLY.create(signBlock, this.mapping, BlockModelGenerators.this.modelOutput) + ); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(signBlock, multiVariant)); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(block, multiVariant)); BlockModelGenerators.this.registerSimpleFlatItemModel(signBlock.asItem()); return this; } @@ -5371,26 +4061,32 @@ public class BlockModelGenerators { throw new IllegalStateException("Full block not generated yet"); } else { ResourceLocation resourceLocation = this.getOrCreateModel(ModelTemplates.SLAB_BOTTOM, slabBlock); - ResourceLocation resourceLocation2 = this.getOrCreateModel(ModelTemplates.SLAB_TOP, slabBlock); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSlab(slabBlock, resourceLocation, resourceLocation2, this.fullBlock)); + MultiVariant multiVariant = BlockModelGenerators.plainVariant(this.getOrCreateModel(ModelTemplates.SLAB_TOP, slabBlock)); + BlockModelGenerators.this.blockStateOutput + .accept( + BlockModelGenerators.createSlab( + slabBlock, BlockModelGenerators.plainVariant(resourceLocation), multiVariant, BlockModelGenerators.variant(this.fullBlock) + ) + ); BlockModelGenerators.this.registerSimpleItemModel(slabBlock, resourceLocation); return this; } } public BlockModelGenerators.BlockFamilyProvider stairs(Block stairsBlock) { - ResourceLocation resourceLocation = this.getOrCreateModel(ModelTemplates.STAIRS_INNER, stairsBlock); - ResourceLocation resourceLocation2 = this.getOrCreateModel(ModelTemplates.STAIRS_STRAIGHT, stairsBlock); - ResourceLocation resourceLocation3 = this.getOrCreateModel(ModelTemplates.STAIRS_OUTER, stairsBlock); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createStairs(stairsBlock, resourceLocation, resourceLocation2, resourceLocation3)); - BlockModelGenerators.this.registerSimpleItemModel(stairsBlock, resourceLocation2); + MultiVariant multiVariant = BlockModelGenerators.plainVariant(this.getOrCreateModel(ModelTemplates.STAIRS_INNER, stairsBlock)); + ResourceLocation resourceLocation = this.getOrCreateModel(ModelTemplates.STAIRS_STRAIGHT, stairsBlock); + MultiVariant multiVariant2 = BlockModelGenerators.plainVariant(this.getOrCreateModel(ModelTemplates.STAIRS_OUTER, stairsBlock)); + BlockModelGenerators.this.blockStateOutput + .accept(BlockModelGenerators.createStairs(stairsBlock, multiVariant, BlockModelGenerators.plainVariant(resourceLocation), multiVariant2)); + BlockModelGenerators.this.registerSimpleItemModel(stairsBlock, resourceLocation); return this; } private BlockModelGenerators.BlockFamilyProvider fullBlockVariant(Block block) { - TexturedModel texturedModel = (TexturedModel)BlockModelGenerators.this.texturedModels.getOrDefault(block, TexturedModel.CUBE.get(block)); - ResourceLocation resourceLocation = texturedModel.create(block, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(block, resourceLocation)); + TexturedModel texturedModel = (TexturedModel)BlockModelGenerators.TEXTURED_MODELS.getOrDefault(block, TexturedModel.CUBE.get(block)); + MultiVariant multiVariant = BlockModelGenerators.plainVariant(texturedModel.create(block, BlockModelGenerators.this.modelOutput)); + BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createSimpleBlock(block, multiVariant)); return this; } @@ -5400,7 +4096,7 @@ public class BlockModelGenerators { } private void trapdoor(Block trapdoorBlock) { - if (BlockModelGenerators.this.nonOrientableTrapdoor.contains(trapdoorBlock)) { + if (BlockModelGenerators.NON_ORIENTABLE_TRAPDOOR.contains(trapdoorBlock)) { BlockModelGenerators.this.createTrapdoor(trapdoorBlock); } else { BlockModelGenerators.this.createOrientableTrapdoor(trapdoorBlock); @@ -5433,8 +4129,11 @@ public class BlockModelGenerators { @FunctionalInterface @Environment(EnvType.CLIENT) interface BlockStateGeneratorSupplier { - BlockStateGenerator create( - Block block, ResourceLocation resourceLocation, TextureMapping textureMapping, BiConsumer biConsumer + BlockModelDefinitionGenerator create( + Block block, + net.minecraft.client.renderer.block.model.Variant variant, + TextureMapping textureMapping, + BiConsumer biConsumer ); } @@ -5493,27 +4192,37 @@ public class BlockModelGenerators { public BlockModelGenerators.WoodProvider wood(Block woodBlock) { TextureMapping textureMapping = this.logMapping.copyAndUpdate(TextureSlot.END, this.logMapping.get(TextureSlot.SIDE)); ResourceLocation resourceLocation = ModelTemplates.CUBE_COLUMN.create(woodBlock, textureMapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createAxisAlignedPillarBlock(woodBlock, resourceLocation)); + BlockModelGenerators.this.blockStateOutput + .accept(BlockModelGenerators.createAxisAlignedPillarBlock(woodBlock, BlockModelGenerators.plainVariant(resourceLocation))); + BlockModelGenerators.this.registerSimpleItemModel(woodBlock, resourceLocation); return this; } public BlockModelGenerators.WoodProvider log(Block logBlock) { ResourceLocation resourceLocation = ModelTemplates.CUBE_COLUMN.create(logBlock, this.logMapping, BlockModelGenerators.this.modelOutput); - BlockModelGenerators.this.blockStateOutput.accept(BlockModelGenerators.createAxisAlignedPillarBlock(logBlock, resourceLocation)); + BlockModelGenerators.this.blockStateOutput + .accept(BlockModelGenerators.createAxisAlignedPillarBlock(logBlock, BlockModelGenerators.plainVariant(resourceLocation))); + BlockModelGenerators.this.registerSimpleItemModel(logBlock, resourceLocation); return this; } public BlockModelGenerators.WoodProvider logWithHorizontal(Block logBlock) { ResourceLocation resourceLocation = ModelTemplates.CUBE_COLUMN.create(logBlock, this.logMapping, BlockModelGenerators.this.modelOutput); - ResourceLocation resourceLocation2 = ModelTemplates.CUBE_COLUMN_HORIZONTAL.create(logBlock, this.logMapping, BlockModelGenerators.this.modelOutput); + MultiVariant multiVariant = BlockModelGenerators.plainVariant( + ModelTemplates.CUBE_COLUMN_HORIZONTAL.create(logBlock, this.logMapping, BlockModelGenerators.this.modelOutput) + ); BlockModelGenerators.this.blockStateOutput - .accept(BlockModelGenerators.createRotatedPillarWithHorizontalVariant(logBlock, resourceLocation, resourceLocation2)); + .accept(BlockModelGenerators.createRotatedPillarWithHorizontalVariant(logBlock, BlockModelGenerators.plainVariant(resourceLocation), multiVariant)); + BlockModelGenerators.this.registerSimpleItemModel(logBlock, resourceLocation); return this; } public BlockModelGenerators.WoodProvider logUVLocked(Block logBlock) { BlockModelGenerators.this.blockStateOutput .accept(BlockModelGenerators.createPillarBlockUVLocked(logBlock, this.logMapping, BlockModelGenerators.this.modelOutput)); + BlockModelGenerators.this.registerSimpleItemModel( + logBlock, ModelTemplates.CUBE_COLUMN.create(logBlock, this.logMapping, BlockModelGenerators.this.modelOutput) + ); return this; } } diff --git a/net/minecraft/client/data/models/EquipmentAssetProvider.java b/net/minecraft/client/data/models/EquipmentAssetProvider.java index f71a02b3..19d1858d 100644 --- a/net/minecraft/client/data/models/EquipmentAssetProvider.java +++ b/net/minecraft/client/data/models/EquipmentAssetProvider.java @@ -12,6 +12,8 @@ import net.minecraft.client.resources.model.EquipmentClientInfo; import net.minecraft.data.CachedOutput; import net.minecraft.data.DataProvider; import net.minecraft.data.PackOutput; +import net.minecraft.data.PackOutput.PathProvider; +import net.minecraft.data.PackOutput.Target; import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.item.DyeColor; @@ -20,10 +22,10 @@ import net.minecraft.world.item.equipment.EquipmentAssets; @Environment(EnvType.CLIENT) public class EquipmentAssetProvider implements DataProvider { - private final PackOutput.PathProvider pathProvider; + private final PathProvider pathProvider; public EquipmentAssetProvider(PackOutput output) { - this.pathProvider = output.createPathProvider(PackOutput.Target.RESOURCE_PACK, "equipment"); + this.pathProvider = output.createPathProvider(Target.RESOURCE_PACK, "equipment"); } private static void bootstrap(BiConsumer, EquipmentClientInfo> output) { @@ -58,6 +60,20 @@ public class EquipmentAssetProvider implements DataProvider { .addLayers(EquipmentClientInfo.LayerType.WINGS, new EquipmentClientInfo.Layer(ResourceLocation.withDefaultNamespace("elytra"), Optional.empty(), true)) .build() ); + EquipmentClientInfo.Layer layer = new EquipmentClientInfo.Layer(ResourceLocation.withDefaultNamespace("saddle")); + output.accept( + EquipmentAssets.SADDLE, + EquipmentClientInfo.builder() + .addLayers(EquipmentClientInfo.LayerType.PIG_SADDLE, layer) + .addLayers(EquipmentClientInfo.LayerType.STRIDER_SADDLE, layer) + .addLayers(EquipmentClientInfo.LayerType.CAMEL_SADDLE, layer) + .addLayers(EquipmentClientInfo.LayerType.HORSE_SADDLE, layer) + .addLayers(EquipmentClientInfo.LayerType.DONKEY_SADDLE, layer) + .addLayers(EquipmentClientInfo.LayerType.MULE_SADDLE, layer) + .addLayers(EquipmentClientInfo.LayerType.SKELETON_HORSE_SADDLE, layer) + .addLayers(EquipmentClientInfo.LayerType.ZOMBIE_HORSE_SADDLE, layer) + .build() + ); for (Entry> entry : EquipmentAssets.CARPETS.entrySet()) { DyeColor dyeColor = (DyeColor)entry.getKey(); diff --git a/net/minecraft/client/data/models/ItemModelGenerators.java b/net/minecraft/client/data/models/ItemModelGenerators.java index 16a3cae4..5ef58ad3 100644 --- a/net/minecraft/client/data/models/ItemModelGenerators.java +++ b/net/minecraft/client/data/models/ItemModelGenerators.java @@ -3,7 +3,6 @@ package net.minecraft.client.data.models; import java.util.ArrayList; import java.util.List; import java.util.Locale; -import java.util.Map; import java.util.function.BiConsumer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -35,8 +34,7 @@ import net.minecraft.client.renderer.item.properties.numeric.UseDuration; import net.minecraft.client.renderer.item.properties.select.Charge; import net.minecraft.client.renderer.item.properties.select.DisplayContext; import net.minecraft.client.renderer.item.properties.select.TrimMaterialProperty; -import net.minecraft.client.renderer.special.ShieldSpecialRenderer; -import net.minecraft.client.renderer.special.TridentSpecialRenderer; +import net.minecraft.client.renderer.special.ShieldSpecialRenderer.Unbaked; import net.minecraft.core.component.DataComponents; import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; @@ -47,32 +45,37 @@ import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.Items; import net.minecraft.world.item.equipment.EquipmentAsset; import net.minecraft.world.item.equipment.EquipmentAssets; +import net.minecraft.world.item.equipment.trim.MaterialAssetGroup; import net.minecraft.world.item.equipment.trim.TrimMaterial; import net.minecraft.world.item.equipment.trim.TrimMaterials; @Environment(EnvType.CLIENT) public class ItemModelGenerators { private static final ItemTintSource BLANK_LAYER = ItemModelUtils.constantTint(-1); - private static final String SLOT_HELMET = "helmet"; - private static final String SLOT_CHESTPLATE = "chestplate"; - private static final String SLOT_LEGGINS = "leggings"; - private static final String SLOT_BOOTS = "boots"; - private static final List TRIM_MATERIAL_MODELS = List.of( - new ItemModelGenerators.TrimMaterialData("quartz", TrimMaterials.QUARTZ, Map.of()), - new ItemModelGenerators.TrimMaterialData("iron", TrimMaterials.IRON, Map.of(EquipmentAssets.IRON, "iron_darker")), - new ItemModelGenerators.TrimMaterialData("netherite", TrimMaterials.NETHERITE, Map.of(EquipmentAssets.NETHERITE, "netherite_darker")), - new ItemModelGenerators.TrimMaterialData("redstone", TrimMaterials.REDSTONE, Map.of()), - new ItemModelGenerators.TrimMaterialData("copper", TrimMaterials.COPPER, Map.of()), - new ItemModelGenerators.TrimMaterialData("gold", TrimMaterials.GOLD, Map.of(EquipmentAssets.GOLD, "gold_darker")), - new ItemModelGenerators.TrimMaterialData("emerald", TrimMaterials.EMERALD, Map.of()), - new ItemModelGenerators.TrimMaterialData("diamond", TrimMaterials.DIAMOND, Map.of(EquipmentAssets.DIAMOND, "diamond_darker")), - new ItemModelGenerators.TrimMaterialData("lapis", TrimMaterials.LAPIS, Map.of()), - new ItemModelGenerators.TrimMaterialData("amethyst", TrimMaterials.AMETHYST, Map.of()), - new ItemModelGenerators.TrimMaterialData("resin", TrimMaterials.RESIN, Map.of()) + public static final ResourceLocation TRIM_PREFIX_HELMET = prefixForSlotTrim("helmet"); + public static final ResourceLocation TRIM_PREFIX_CHESTPLATE = prefixForSlotTrim("chestplate"); + public static final ResourceLocation TRIM_PREFIX_LEGGINGS = prefixForSlotTrim("leggings"); + public static final ResourceLocation TRIM_PREFIX_BOOTS = prefixForSlotTrim("boots"); + public static final List TRIM_MATERIAL_MODELS = List.of( + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.QUARTZ, TrimMaterials.QUARTZ), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.IRON, TrimMaterials.IRON), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.NETHERITE, TrimMaterials.NETHERITE), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.REDSTONE, TrimMaterials.REDSTONE), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.COPPER, TrimMaterials.COPPER), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.GOLD, TrimMaterials.GOLD), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.EMERALD, TrimMaterials.EMERALD), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.DIAMOND, TrimMaterials.DIAMOND), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.LAPIS, TrimMaterials.LAPIS), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.AMETHYST, TrimMaterials.AMETHYST), + new ItemModelGenerators.TrimMaterialData(MaterialAssetGroup.RESIN, TrimMaterials.RESIN) ); private final ItemModelOutput itemModelOutput; private final BiConsumer modelOutput; + public static ResourceLocation prefixForSlotTrim(String name) { + return ResourceLocation.withDefaultNamespace("trims/items/" + name + "_trim"); + } + public ItemModelGenerators(ItemModelOutput itemModelOutput, BiConsumer modelOutput) { this.itemModelOutput = itemModelOutput; this.modelOutput = modelOutput; @@ -182,17 +185,17 @@ public class ItemModelGenerators { ModelTemplates.THREE_LAYERED_ITEM.create(modelLocation, TextureMapping.layered(layer0, layer1, layer2), this.modelOutput); } - private void generateTrimmableItem(Item item, ResourceKey key, String name, boolean dyeable) { + private void generateTrimmableItem(Item item, ResourceKey equipmentAsset, ResourceLocation modelId, boolean usesSecondLayer) { ResourceLocation resourceLocation = ModelLocationUtils.getModelLocation(item); ResourceLocation resourceLocation2 = TextureMapping.getItemTexture(item); ResourceLocation resourceLocation3 = TextureMapping.getItemTexture(item, "_overlay"); List>> list = new ArrayList(TRIM_MATERIAL_MODELS.size()); for (ItemModelGenerators.TrimMaterialData trimMaterialData : TRIM_MATERIAL_MODELS) { - ResourceLocation resourceLocation4 = resourceLocation.withSuffix("_" + trimMaterialData.name() + "_trim"); - ResourceLocation resourceLocation5 = ResourceLocation.withDefaultNamespace("trims/items/" + name + "_trim_" + trimMaterialData.textureName(key)); + ResourceLocation resourceLocation4 = resourceLocation.withSuffix("_" + trimMaterialData.assets().base().suffix() + "_trim"); + ResourceLocation resourceLocation5 = modelId.withSuffix("_" + trimMaterialData.assets().assetId(equipmentAsset).suffix()); ItemModel.Unbaked unbaked; - if (dyeable) { + if (usesSecondLayer) { this.generateLayeredItem(resourceLocation4, resourceLocation2, resourceLocation3, resourceLocation5); unbaked = ItemModelUtils.tintedModel(resourceLocation4, new Dye(-6265536)); } else { @@ -204,7 +207,7 @@ public class ItemModelGenerators { } ItemModel.Unbaked unbaked2; - if (dyeable) { + if (usesSecondLayer) { ModelTemplates.TWO_LAYERED_ITEM.create(resourceLocation, TextureMapping.layered(resourceLocation2, resourceLocation3), this.modelOutput); unbaked2 = ItemModelUtils.tintedModel(resourceLocation, new Dye(-6265536)); } else { @@ -257,12 +260,15 @@ public class ItemModelGenerators { this.itemModelOutput .accept( crossbowItem, - ItemModelUtils.conditional( - ItemModelUtils.isUsingItem(), - ItemModelUtils.rangeSelect(new CrossbowPull(), unbaked2, ItemModelUtils.override(unbaked3, 0.58F), ItemModelUtils.override(unbaked4, 1.0F)), - ItemModelUtils.select( - new Charge(), unbaked, ItemModelUtils.when(CrossbowItem.ChargeType.ARROW, unbaked5), ItemModelUtils.when(CrossbowItem.ChargeType.ROCKET, unbaked6) - ) + ItemModelUtils.select( + new Charge(), + ItemModelUtils.conditional( + ItemModelUtils.isUsingItem(), + ItemModelUtils.rangeSelect(new CrossbowPull(), unbaked2, ItemModelUtils.override(unbaked3, 0.58F), ItemModelUtils.override(unbaked4, 1.0F)), + unbaked + ), + ItemModelUtils.when(CrossbowItem.ChargeType.ARROW, unbaked5), + ItemModelUtils.when(CrossbowItem.ChargeType.ROCKET, unbaked6) ) ); } @@ -309,8 +315,8 @@ public class ItemModelGenerators { } private void generateShield(Item shieldItem) { - ItemModel.Unbaked unbaked = ItemModelUtils.specialModel(ModelLocationUtils.getModelLocation(shieldItem), new ShieldSpecialRenderer.Unbaked()); - ItemModel.Unbaked unbaked2 = ItemModelUtils.specialModel(ModelLocationUtils.getModelLocation(shieldItem, "_blocking"), new ShieldSpecialRenderer.Unbaked()); + ItemModel.Unbaked unbaked = ItemModelUtils.specialModel(ModelLocationUtils.getModelLocation(shieldItem), new Unbaked()); + ItemModel.Unbaked unbaked2 = ItemModelUtils.specialModel(ModelLocationUtils.getModelLocation(shieldItem, "_blocking"), new Unbaked()); this.generateBooleanDispatch(shieldItem, ItemModelUtils.isUsingItem(), unbaked2, unbaked); } @@ -328,8 +334,12 @@ public class ItemModelGenerators { private void generateTrident(Item tridentItem) { ItemModel.Unbaked unbaked = ItemModelUtils.plainModel(this.createFlatItemModel(tridentItem, ModelTemplates.FLAT_ITEM)); - ItemModel.Unbaked unbaked2 = ItemModelUtils.specialModel(ModelLocationUtils.getModelLocation(tridentItem, "_in_hand"), new TridentSpecialRenderer.Unbaked()); - ItemModel.Unbaked unbaked3 = ItemModelUtils.specialModel(ModelLocationUtils.getModelLocation(tridentItem, "_throwing"), new TridentSpecialRenderer.Unbaked()); + ItemModel.Unbaked unbaked2 = ItemModelUtils.specialModel( + ModelLocationUtils.getModelLocation(tridentItem, "_in_hand"), new net.minecraft.client.renderer.special.TridentSpecialRenderer.Unbaked() + ); + ItemModel.Unbaked unbaked3 = ItemModelUtils.specialModel( + ModelLocationUtils.getModelLocation(tridentItem, "_throwing"), new net.minecraft.client.renderer.special.TridentSpecialRenderer.Unbaked() + ); ItemModel.Unbaked unbaked4 = ItemModelUtils.conditional(ItemModelUtils.isUsingItem(), unbaked3, unbaked2); this.itemModelOutput.accept(tridentItem, createFlatModelDispatch(unbaked, unbaked4)); } @@ -357,12 +367,6 @@ public class ItemModelGenerators { this.itemModelOutput.accept(item, ItemModelUtils.tintedModel(resourceLocation, new Dye(color))); } - private void generateSpawnEgg(Item spawnEggItem, int primaryColor, int secondaryColor) { - ResourceLocation resourceLocation = ModelLocationUtils.decorateItemModelLocation("template_spawn_egg"); - this.itemModelOutput - .accept(spawnEggItem, ItemModelUtils.tintedModel(resourceLocation, ItemModelUtils.constantTint(primaryColor), ItemModelUtils.constantTint(secondaryColor))); - } - private void generateWolfArmor(Item armorItem) { ResourceLocation resourceLocation = TextureMapping.getItemTexture(armorItem); ResourceLocation resourceLocation2 = TextureMapping.getItemTexture(armorItem, "_overlay"); @@ -447,6 +451,8 @@ public class ItemModelGenerators { this.generateFlatItem(Items.DRAGON_BREATH, ModelTemplates.FLAT_ITEM); this.generateFlatItem(Items.DRIED_KELP, ModelTemplates.FLAT_ITEM); this.generateFlatItem(Items.EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.BLUE_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.BROWN_EGG, ModelTemplates.FLAT_ITEM); this.generateFlatItem(Items.EMERALD, ModelTemplates.FLAT_ITEM); this.generateFlatItem(Items.ENCHANTED_BOOK, ModelTemplates.FLAT_ITEM); this.generateFlatItem(Items.ENDER_EYE, ModelTemplates.FLAT_ITEM); @@ -643,31 +649,31 @@ public class ItemModelGenerators { this.generateFlatItem(Items.BOLT_ARMOR_TRIM_SMITHING_TEMPLATE, ModelTemplates.FLAT_ITEM); this.generateFlatItem(Items.DEBUG_STICK, Items.STICK, ModelTemplates.FLAT_HANDHELD_ITEM); this.generateFlatItem(Items.ENCHANTED_GOLDEN_APPLE, Items.GOLDEN_APPLE, ModelTemplates.FLAT_ITEM); - this.generateTrimmableItem(Items.TURTLE_HELMET, EquipmentAssets.TURTLE_SCUTE, "helmet", false); - this.generateTrimmableItem(Items.LEATHER_HELMET, EquipmentAssets.LEATHER, "helmet", true); - this.generateTrimmableItem(Items.LEATHER_CHESTPLATE, EquipmentAssets.LEATHER, "chestplate", true); - this.generateTrimmableItem(Items.LEATHER_LEGGINGS, EquipmentAssets.LEATHER, "leggings", true); - this.generateTrimmableItem(Items.LEATHER_BOOTS, EquipmentAssets.LEATHER, "boots", true); - this.generateTrimmableItem(Items.CHAINMAIL_HELMET, EquipmentAssets.CHAINMAIL, "helmet", false); - this.generateTrimmableItem(Items.CHAINMAIL_CHESTPLATE, EquipmentAssets.CHAINMAIL, "chestplate", false); - this.generateTrimmableItem(Items.CHAINMAIL_LEGGINGS, EquipmentAssets.CHAINMAIL, "leggings", false); - this.generateTrimmableItem(Items.CHAINMAIL_BOOTS, EquipmentAssets.CHAINMAIL, "boots", false); - this.generateTrimmableItem(Items.IRON_HELMET, EquipmentAssets.IRON, "helmet", false); - this.generateTrimmableItem(Items.IRON_CHESTPLATE, EquipmentAssets.IRON, "chestplate", false); - this.generateTrimmableItem(Items.IRON_LEGGINGS, EquipmentAssets.IRON, "leggings", false); - this.generateTrimmableItem(Items.IRON_BOOTS, EquipmentAssets.IRON, "boots", false); - this.generateTrimmableItem(Items.DIAMOND_HELMET, EquipmentAssets.DIAMOND, "helmet", false); - this.generateTrimmableItem(Items.DIAMOND_CHESTPLATE, EquipmentAssets.DIAMOND, "chestplate", false); - this.generateTrimmableItem(Items.DIAMOND_LEGGINGS, EquipmentAssets.DIAMOND, "leggings", false); - this.generateTrimmableItem(Items.DIAMOND_BOOTS, EquipmentAssets.DIAMOND, "boots", false); - this.generateTrimmableItem(Items.GOLDEN_HELMET, EquipmentAssets.GOLD, "helmet", false); - this.generateTrimmableItem(Items.GOLDEN_CHESTPLATE, EquipmentAssets.GOLD, "chestplate", false); - this.generateTrimmableItem(Items.GOLDEN_LEGGINGS, EquipmentAssets.GOLD, "leggings", false); - this.generateTrimmableItem(Items.GOLDEN_BOOTS, EquipmentAssets.GOLD, "boots", false); - this.generateTrimmableItem(Items.NETHERITE_HELMET, EquipmentAssets.NETHERITE, "helmet", false); - this.generateTrimmableItem(Items.NETHERITE_CHESTPLATE, EquipmentAssets.NETHERITE, "chestplate", false); - this.generateTrimmableItem(Items.NETHERITE_LEGGINGS, EquipmentAssets.NETHERITE, "leggings", false); - this.generateTrimmableItem(Items.NETHERITE_BOOTS, EquipmentAssets.NETHERITE, "boots", false); + this.generateTrimmableItem(Items.TURTLE_HELMET, EquipmentAssets.TURTLE_SCUTE, TRIM_PREFIX_HELMET, false); + this.generateTrimmableItem(Items.LEATHER_HELMET, EquipmentAssets.LEATHER, TRIM_PREFIX_HELMET, true); + this.generateTrimmableItem(Items.LEATHER_CHESTPLATE, EquipmentAssets.LEATHER, TRIM_PREFIX_CHESTPLATE, true); + this.generateTrimmableItem(Items.LEATHER_LEGGINGS, EquipmentAssets.LEATHER, TRIM_PREFIX_LEGGINGS, true); + this.generateTrimmableItem(Items.LEATHER_BOOTS, EquipmentAssets.LEATHER, TRIM_PREFIX_BOOTS, true); + this.generateTrimmableItem(Items.CHAINMAIL_HELMET, EquipmentAssets.CHAINMAIL, TRIM_PREFIX_HELMET, false); + this.generateTrimmableItem(Items.CHAINMAIL_CHESTPLATE, EquipmentAssets.CHAINMAIL, TRIM_PREFIX_CHESTPLATE, false); + this.generateTrimmableItem(Items.CHAINMAIL_LEGGINGS, EquipmentAssets.CHAINMAIL, TRIM_PREFIX_LEGGINGS, false); + this.generateTrimmableItem(Items.CHAINMAIL_BOOTS, EquipmentAssets.CHAINMAIL, TRIM_PREFIX_BOOTS, false); + this.generateTrimmableItem(Items.IRON_HELMET, EquipmentAssets.IRON, TRIM_PREFIX_HELMET, false); + this.generateTrimmableItem(Items.IRON_CHESTPLATE, EquipmentAssets.IRON, TRIM_PREFIX_CHESTPLATE, false); + this.generateTrimmableItem(Items.IRON_LEGGINGS, EquipmentAssets.IRON, TRIM_PREFIX_LEGGINGS, false); + this.generateTrimmableItem(Items.IRON_BOOTS, EquipmentAssets.IRON, TRIM_PREFIX_BOOTS, false); + this.generateTrimmableItem(Items.DIAMOND_HELMET, EquipmentAssets.DIAMOND, TRIM_PREFIX_HELMET, false); + this.generateTrimmableItem(Items.DIAMOND_CHESTPLATE, EquipmentAssets.DIAMOND, TRIM_PREFIX_CHESTPLATE, false); + this.generateTrimmableItem(Items.DIAMOND_LEGGINGS, EquipmentAssets.DIAMOND, TRIM_PREFIX_LEGGINGS, false); + this.generateTrimmableItem(Items.DIAMOND_BOOTS, EquipmentAssets.DIAMOND, TRIM_PREFIX_BOOTS, false); + this.generateTrimmableItem(Items.GOLDEN_HELMET, EquipmentAssets.GOLD, TRIM_PREFIX_HELMET, false); + this.generateTrimmableItem(Items.GOLDEN_CHESTPLATE, EquipmentAssets.GOLD, TRIM_PREFIX_CHESTPLATE, false); + this.generateTrimmableItem(Items.GOLDEN_LEGGINGS, EquipmentAssets.GOLD, TRIM_PREFIX_LEGGINGS, false); + this.generateTrimmableItem(Items.GOLDEN_BOOTS, EquipmentAssets.GOLD, TRIM_PREFIX_BOOTS, false); + this.generateTrimmableItem(Items.NETHERITE_HELMET, EquipmentAssets.NETHERITE, TRIM_PREFIX_HELMET, false); + this.generateTrimmableItem(Items.NETHERITE_CHESTPLATE, EquipmentAssets.NETHERITE, TRIM_PREFIX_CHESTPLATE, false); + this.generateTrimmableItem(Items.NETHERITE_LEGGINGS, EquipmentAssets.NETHERITE, TRIM_PREFIX_LEGGINGS, false); + this.generateTrimmableItem(Items.NETHERITE_BOOTS, EquipmentAssets.NETHERITE, TRIM_PREFIX_BOOTS, false); this.generateDyedItem(Items.LEATHER_HORSE_ARMOR, -6265536); this.generateFlatItem(Items.ANGLER_POTTERY_SHERD, ModelTemplates.FLAT_ITEM); this.generateFlatItem(Items.ARCHER_POTTERY_SHERD, ModelTemplates.FLAT_ITEM); @@ -728,87 +734,87 @@ public class ItemModelGenerators { this.generatePotion(Items.POTION); this.generatePotion(Items.SPLASH_POTION); this.generatePotion(Items.LINGERING_POTION); - this.generateSpawnEgg(Items.ARMADILLO_SPAWN_EGG, 11366765, 8538184); - this.generateSpawnEgg(Items.ALLAY_SPAWN_EGG, 56063, 44543); - this.generateSpawnEgg(Items.AXOLOTL_SPAWN_EGG, 16499171, 10890612); - this.generateSpawnEgg(Items.BAT_SPAWN_EGG, 4996656, 986895); - this.generateSpawnEgg(Items.BEE_SPAWN_EGG, 15582019, 4400155); - this.generateSpawnEgg(Items.BLAZE_SPAWN_EGG, 16167425, 16775294); - this.generateSpawnEgg(Items.BOGGED_SPAWN_EGG, 9084018, 3231003); - this.generateSpawnEgg(Items.BREEZE_SPAWN_EGG, 11506911, 9529055); - this.generateSpawnEgg(Items.CAT_SPAWN_EGG, 15714446, 9794134); - this.generateSpawnEgg(Items.CAMEL_SPAWN_EGG, 16565097, 13341495); - this.generateSpawnEgg(Items.CAVE_SPIDER_SPAWN_EGG, 803406, 11013646); - this.generateSpawnEgg(Items.CHICKEN_SPAWN_EGG, 10592673, 16711680); - this.generateSpawnEgg(Items.COD_SPAWN_EGG, 12691306, 15058059); - this.generateSpawnEgg(Items.COW_SPAWN_EGG, 4470310, 10592673); - this.generateSpawnEgg(Items.CREEPER_SPAWN_EGG, 894731, 0); - this.generateSpawnEgg(Items.DOLPHIN_SPAWN_EGG, 2243405, 16382457); - this.generateSpawnEgg(Items.DONKEY_SPAWN_EGG, 5457209, 8811878); - this.generateSpawnEgg(Items.DROWNED_SPAWN_EGG, 9433559, 7969893); - this.generateSpawnEgg(Items.ELDER_GUARDIAN_SPAWN_EGG, 13552826, 7632531); - this.generateSpawnEgg(Items.ENDER_DRAGON_SPAWN_EGG, 1842204, 14711290); - this.generateSpawnEgg(Items.ENDERMAN_SPAWN_EGG, 1447446, 0); - this.generateSpawnEgg(Items.ENDERMITE_SPAWN_EGG, 1447446, 7237230); - this.generateSpawnEgg(Items.EVOKER_SPAWN_EGG, 9804699, 1973274); - this.generateSpawnEgg(Items.FOX_SPAWN_EGG, 14005919, 13396256); - this.generateSpawnEgg(Items.FROG_SPAWN_EGG, 13661252, 16762748); - this.generateSpawnEgg(Items.GHAST_SPAWN_EGG, 16382457, 12369084); - this.generateSpawnEgg(Items.GLOW_SQUID_SPAWN_EGG, 611926, 8778172); - this.generateSpawnEgg(Items.GOAT_SPAWN_EGG, 10851452, 5589310); - this.generateSpawnEgg(Items.GUARDIAN_SPAWN_EGG, 5931634, 15826224); - this.generateSpawnEgg(Items.HOGLIN_SPAWN_EGG, 13004373, 6251620); - this.generateSpawnEgg(Items.HORSE_SPAWN_EGG, 12623485, 15656192); - this.generateSpawnEgg(Items.HUSK_SPAWN_EGG, 7958625, 15125652); - this.generateSpawnEgg(Items.IRON_GOLEM_SPAWN_EGG, 14405058, 7643954); - this.generateSpawnEgg(Items.LLAMA_SPAWN_EGG, 12623485, 10051392); - this.generateSpawnEgg(Items.MAGMA_CUBE_SPAWN_EGG, 3407872, 16579584); - this.generateSpawnEgg(Items.MOOSHROOM_SPAWN_EGG, 10489616, 12040119); - this.generateSpawnEgg(Items.MULE_SPAWN_EGG, 1769984, 5321501); - this.generateSpawnEgg(Items.OCELOT_SPAWN_EGG, 15720061, 5653556); - this.generateSpawnEgg(Items.PANDA_SPAWN_EGG, 15198183, 1776418); - this.generateSpawnEgg(Items.PARROT_SPAWN_EGG, 894731, 16711680); - this.generateSpawnEgg(Items.PHANTOM_SPAWN_EGG, 4411786, 8978176); - this.generateSpawnEgg(Items.PIG_SPAWN_EGG, 15771042, 14377823); - this.generateSpawnEgg(Items.PIGLIN_SPAWN_EGG, 10051392, 16380836); - this.generateSpawnEgg(Items.PIGLIN_BRUTE_SPAWN_EGG, 5843472, 16380836); - this.generateSpawnEgg(Items.PILLAGER_SPAWN_EGG, 5451574, 9804699); - this.generateSpawnEgg(Items.POLAR_BEAR_SPAWN_EGG, 15658718, 14014157); - this.generateSpawnEgg(Items.PUFFERFISH_SPAWN_EGG, 16167425, 3654642); - this.generateSpawnEgg(Items.RABBIT_SPAWN_EGG, 10051392, 7555121); - this.generateSpawnEgg(Items.RAVAGER_SPAWN_EGG, 7697520, 5984329); - this.generateSpawnEgg(Items.SALMON_SPAWN_EGG, 10489616, 951412); - this.generateSpawnEgg(Items.SHEEP_SPAWN_EGG, 15198183, 16758197); - this.generateSpawnEgg(Items.SHULKER_SPAWN_EGG, 9725844, 5060690); - this.generateSpawnEgg(Items.SILVERFISH_SPAWN_EGG, 7237230, 3158064); - this.generateSpawnEgg(Items.SKELETON_SPAWN_EGG, 12698049, 4802889); - this.generateSpawnEgg(Items.SKELETON_HORSE_SPAWN_EGG, 6842447, 15066584); - this.generateSpawnEgg(Items.SLIME_SPAWN_EGG, 5349438, 8306542); - this.generateSpawnEgg(Items.SNIFFER_SPAWN_EGG, 8855049, 2468720); - this.generateSpawnEgg(Items.SNOW_GOLEM_SPAWN_EGG, 14283506, 8496292); - this.generateSpawnEgg(Items.SPIDER_SPAWN_EGG, 3419431, 11013646); - this.generateSpawnEgg(Items.SQUID_SPAWN_EGG, 2243405, 7375001); - this.generateSpawnEgg(Items.STRAY_SPAWN_EGG, 6387319, 14543594); - this.generateSpawnEgg(Items.STRIDER_SPAWN_EGG, 10236982, 5065037); - this.generateSpawnEgg(Items.TADPOLE_SPAWN_EGG, 7164733, 1444352); - this.generateSpawnEgg(Items.TRADER_LLAMA_SPAWN_EGG, 15377456, 4547222); - this.generateSpawnEgg(Items.TROPICAL_FISH_SPAWN_EGG, 15690005, 16775663); - this.generateSpawnEgg(Items.TURTLE_SPAWN_EGG, 15198183, 44975); - this.generateSpawnEgg(Items.VEX_SPAWN_EGG, 8032420, 15265265); - this.generateSpawnEgg(Items.VILLAGER_SPAWN_EGG, 5651507, 12422002); - this.generateSpawnEgg(Items.VINDICATOR_SPAWN_EGG, 9804699, 2580065); - this.generateSpawnEgg(Items.WANDERING_TRADER_SPAWN_EGG, 4547222, 15377456); - this.generateSpawnEgg(Items.WARDEN_SPAWN_EGG, 1001033, 3790560); - this.generateSpawnEgg(Items.WITCH_SPAWN_EGG, 3407872, 5349438); - this.generateSpawnEgg(Items.WITHER_SPAWN_EGG, 1315860, 5075616); - this.generateSpawnEgg(Items.WITHER_SKELETON_SPAWN_EGG, 1315860, 4672845); - this.generateSpawnEgg(Items.WOLF_SPAWN_EGG, 14144467, 13545366); - this.generateSpawnEgg(Items.ZOGLIN_SPAWN_EGG, 13004373, 15132390); - this.generateSpawnEgg(Items.CREAKING_SPAWN_EGG, 6250335, 16545810); - this.generateSpawnEgg(Items.ZOMBIE_SPAWN_EGG, 44975, 7969893); - this.generateSpawnEgg(Items.ZOMBIE_HORSE_SPAWN_EGG, 3232308, 9945732); - this.generateSpawnEgg(Items.ZOMBIE_VILLAGER_SPAWN_EGG, 5651507, 7969893); - this.generateSpawnEgg(Items.ZOMBIFIED_PIGLIN_SPAWN_EGG, 15373203, 5009705); + this.generateFlatItem(Items.ARMADILLO_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ALLAY_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.AXOLOTL_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.BAT_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.BEE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.BLAZE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.BOGGED_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.BREEZE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.CAT_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.CAMEL_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.CAVE_SPIDER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.CHICKEN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.COD_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.COW_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.CREEPER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.DOLPHIN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.DONKEY_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.DROWNED_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ELDER_GUARDIAN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ENDER_DRAGON_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ENDERMAN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ENDERMITE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.EVOKER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.FOX_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.FROG_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.GHAST_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.GLOW_SQUID_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.GOAT_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.GUARDIAN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.HOGLIN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.HORSE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.HUSK_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.IRON_GOLEM_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.LLAMA_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.MAGMA_CUBE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.MOOSHROOM_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.MULE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.OCELOT_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.PANDA_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.PARROT_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.PHANTOM_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.PIG_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.PIGLIN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.PIGLIN_BRUTE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.PILLAGER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.POLAR_BEAR_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.PUFFERFISH_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.RABBIT_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.RAVAGER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SALMON_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SHEEP_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SHULKER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SILVERFISH_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SKELETON_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SKELETON_HORSE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SLIME_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SNIFFER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SNOW_GOLEM_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SPIDER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.SQUID_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.STRAY_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.STRIDER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.TADPOLE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.TRADER_LLAMA_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.TROPICAL_FISH_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.TURTLE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.VEX_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.VILLAGER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.VINDICATOR_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.WANDERING_TRADER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.WARDEN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.WITCH_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.WITHER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.WITHER_SKELETON_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.WOLF_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ZOGLIN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.CREAKING_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ZOMBIE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ZOMBIE_HORSE_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ZOMBIE_VILLAGER_SPAWN_EGG, ModelTemplates.FLAT_ITEM); + this.generateFlatItem(Items.ZOMBIFIED_PIGLIN_SPAWN_EGG, ModelTemplates.FLAT_ITEM); this.declareCustomModelItem(Items.AIR); this.declareCustomModelItem(Items.AMETHYST_CLUSTER); this.declareCustomModelItem(Items.SMALL_AMETHYST_BUD); @@ -825,10 +831,6 @@ public class ItemModelGenerators { } @Environment(EnvType.CLIENT) - record TrimMaterialData(String name, ResourceKey materialKey, Map, String> overrideArmorMaterials) { - - public String textureName(ResourceKey key) { - return (String)this.overrideArmorMaterials.getOrDefault(key, this.name); - } + public record TrimMaterialData(MaterialAssetGroup assets, ResourceKey materialKey) { } } diff --git a/net/minecraft/client/data/models/ModelProvider.java b/net/minecraft/client/data/models/ModelProvider.java index 79c90c72..5c0324f1 100644 --- a/net/minecraft/client/data/models/ModelProvider.java +++ b/net/minecraft/client/data/models/ModelProvider.java @@ -1,5 +1,6 @@ package net.minecraft.client.data.models; +import com.google.common.collect.Maps; import com.google.gson.JsonElement; import java.nio.file.Path; import java.util.HashMap; @@ -13,10 +14,11 @@ import java.util.function.Supplier; import java.util.stream.Stream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.data.models.blockstates.BlockStateGenerator; +import net.minecraft.client.data.models.blockstates.BlockModelDefinitionGenerator; import net.minecraft.client.data.models.model.ItemModelUtils; import net.minecraft.client.data.models.model.ModelInstance; import net.minecraft.client.data.models.model.ModelLocationUtils; +import net.minecraft.client.renderer.block.model.BlockModelDefinition; import net.minecraft.client.renderer.item.ClientItem; import net.minecraft.client.renderer.item.ItemModel; import net.minecraft.core.Holder.Reference; @@ -24,6 +26,8 @@ import net.minecraft.core.registries.BuiltInRegistries; import net.minecraft.data.CachedOutput; import net.minecraft.data.DataProvider; import net.minecraft.data.PackOutput; +import net.minecraft.data.PackOutput.PathProvider; +import net.minecraft.data.PackOutput.Target; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.item.BlockItem; import net.minecraft.world.item.Item; @@ -31,14 +35,14 @@ import net.minecraft.world.level.block.Block; @Environment(EnvType.CLIENT) public class ModelProvider implements DataProvider { - private final PackOutput.PathProvider blockStatePathProvider; - private final PackOutput.PathProvider itemInfoPathProvider; - private final PackOutput.PathProvider modelPathProvider; + private final PathProvider blockStatePathProvider; + private final PathProvider itemInfoPathProvider; + private final PathProvider modelPathProvider; public ModelProvider(PackOutput output) { - this.blockStatePathProvider = output.createPathProvider(PackOutput.Target.RESOURCE_PACK, "blockstates"); - this.itemInfoPathProvider = output.createPathProvider(PackOutput.Target.RESOURCE_PACK, "items"); - this.modelPathProvider = output.createPathProvider(PackOutput.Target.RESOURCE_PACK, "models"); + this.blockStatePathProvider = output.createPathProvider(Target.RESOURCE_PACK, "blockstates"); + this.itemInfoPathProvider = output.createPathProvider(Target.RESOURCE_PACK, "items"); + this.modelPathProvider = output.createPathProvider(Target.RESOURCE_PACK, "models"); } @Override @@ -57,23 +61,19 @@ public class ModelProvider implements DataProvider { ); } - static CompletableFuture saveAll(CachedOutput output, Function pathGetter, Map> entries) { - return DataProvider.saveAll(output, Supplier::get, pathGetter, entries); - } - @Override public final String getName() { return "Model Definitions"; } @Environment(EnvType.CLIENT) - static class BlockStateGeneratorCollector implements Consumer { - private final Map generators = new HashMap(); + static class BlockStateGeneratorCollector implements Consumer { + private final Map generators = new HashMap(); - public void accept(BlockStateGenerator blockStateGenerator) { - Block block = blockStateGenerator.getBlock(); - BlockStateGenerator blockStateGenerator2 = (BlockStateGenerator)this.generators.put(block, blockStateGenerator); - if (blockStateGenerator2 != null) { + public void accept(BlockModelDefinitionGenerator blockModelDefinitionGenerator) { + Block block = blockModelDefinitionGenerator.block(); + BlockModelDefinitionGenerator blockModelDefinitionGenerator2 = (BlockModelDefinitionGenerator)this.generators.put(block, blockModelDefinitionGenerator); + if (blockModelDefinitionGenerator2 != null) { throw new IllegalStateException("Duplicate blockstate definition for " + block); } } @@ -88,8 +88,10 @@ public class ModelProvider implements DataProvider { } } - public CompletableFuture save(CachedOutput output, PackOutput.PathProvider pathProvider) { - return ModelProvider.saveAll(output, block -> pathProvider.json(block.builtInRegistryHolder().key().location()), this.generators); + public CompletableFuture save(CachedOutput output, PathProvider pathProvider) { + Map map = Maps.transformValues(this.generators, BlockModelDefinitionGenerator::create); + Function function = block -> pathProvider.json(block.builtInRegistryHolder().key().location()); + return DataProvider.saveAll(output, BlockModelDefinition.CODEC, function, map); } } @@ -142,7 +144,7 @@ public class ModelProvider implements DataProvider { } } - public CompletableFuture save(CachedOutput output, PackOutput.PathProvider pathProvider) { + public CompletableFuture save(CachedOutput output, PathProvider pathProvider) { return DataProvider.saveAll(output, ClientItem.CODEC, item -> pathProvider.json(item.builtInRegistryHolder().key().location()), this.itemInfos); } } @@ -158,8 +160,8 @@ public class ModelProvider implements DataProvider { } } - public CompletableFuture save(CachedOutput output, PackOutput.PathProvider pathProvider) { - return ModelProvider.saveAll(output, pathProvider::json, this.models); + public CompletableFuture save(CachedOutput output, PathProvider pathProvider) { + return DataProvider.saveAll(output, Supplier::get, pathProvider::json, this.models); } } } diff --git a/net/minecraft/client/data/models/MultiVariant.java b/net/minecraft/client/data/models/MultiVariant.java new file mode 100644 index 00000000..36dd973c --- /dev/null +++ b/net/minecraft/client/data/models/MultiVariant.java @@ -0,0 +1,34 @@ +package net.minecraft.client.data.models; + +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.BlockStateModel; +import net.minecraft.client.renderer.block.model.SingleVariant; +import net.minecraft.client.renderer.block.model.Variant; +import net.minecraft.client.renderer.block.model.VariantMutator; +import net.minecraft.client.resources.model.WeightedVariants; +import net.minecraft.util.random.Weighted; +import net.minecraft.util.random.WeightedList; + +@Environment(EnvType.CLIENT) +public record MultiVariant(WeightedList variants) { + public MultiVariant(WeightedList variants) { + if (variants.isEmpty()) { + throw new IllegalArgumentException("Variant list must contain at least one element"); + } else { + this.variants = variants; + } + } + + public MultiVariant with(VariantMutator other) { + return new MultiVariant(this.variants.map(other)); + } + + public BlockStateModel.Unbaked toUnbaked() { + List> list = this.variants.unwrap(); + return (BlockStateModel.Unbaked)(list.size() == 1 + ? new SingleVariant.Unbaked((Variant)((Weighted)list.getFirst()).value()) + : new WeightedVariants.Unbaked(this.variants.map(SingleVariant.Unbaked::new))); + } +} diff --git a/net/minecraft/client/data/models/blockstates/BlockStateGenerator.java b/net/minecraft/client/data/models/blockstates/BlockModelDefinitionGenerator.java similarity index 54% rename from net/minecraft/client/data/models/blockstates/BlockStateGenerator.java rename to net/minecraft/client/data/models/blockstates/BlockModelDefinitionGenerator.java index 6f18d1f0..2958d508 100644 --- a/net/minecraft/client/data/models/blockstates/BlockStateGenerator.java +++ b/net/minecraft/client/data/models/blockstates/BlockModelDefinitionGenerator.java @@ -1,12 +1,13 @@ package net.minecraft.client.data.models.blockstates; -import com.google.gson.JsonElement; -import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.BlockModelDefinition; import net.minecraft.world.level.block.Block; @Environment(EnvType.CLIENT) -public interface BlockStateGenerator extends Supplier { - Block getBlock(); +public interface BlockModelDefinitionGenerator { + Block block(); + + BlockModelDefinition create(); } diff --git a/net/minecraft/client/data/models/blockstates/Condition.java b/net/minecraft/client/data/models/blockstates/Condition.java deleted file mode 100644 index d2b8a890..00000000 --- a/net/minecraft/client/data/models/blockstates/Condition.java +++ /dev/null @@ -1,129 +0,0 @@ -package net.minecraft.client.data.models.blockstates; - -import com.google.common.collect.Maps; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import java.util.Arrays; -import java.util.List; -import java.util.Map; -import java.util.function.Supplier; -import java.util.stream.Collectors; -import java.util.stream.Stream; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.world.level.block.state.StateDefinition; -import net.minecraft.world.level.block.state.properties.Property; - -@Environment(EnvType.CLIENT) -public interface Condition extends Supplier { - void validate(StateDefinition stateDefinition); - - static Condition.TerminalCondition condition() { - return new Condition.TerminalCondition(); - } - - static Condition and(Condition... conditions) { - return new Condition.CompositeCondition(Condition.Operation.AND, Arrays.asList(conditions)); - } - - static Condition or(Condition... conditions) { - return new Condition.CompositeCondition(Condition.Operation.OR, Arrays.asList(conditions)); - } - - @Environment(EnvType.CLIENT) - public static class CompositeCondition implements Condition { - private final Condition.Operation operation; - private final List subconditions; - - CompositeCondition(Condition.Operation operation, List subconditions) { - this.operation = operation; - this.subconditions = subconditions; - } - - @Override - public void validate(StateDefinition stateDefinition) { - this.subconditions.forEach(condition -> condition.validate(stateDefinition)); - } - - public JsonElement get() { - JsonArray jsonArray = new JsonArray(); - this.subconditions.stream().map(Supplier::get).forEach(jsonArray::add); - JsonObject jsonObject = new JsonObject(); - jsonObject.add(this.operation.id, jsonArray); - return jsonObject; - } - } - - @Environment(EnvType.CLIENT) - public static enum Operation { - AND("AND"), - OR("OR"); - - final String id; - - private Operation(final String id) { - this.id = id; - } - } - - @Environment(EnvType.CLIENT) - public static class TerminalCondition implements Condition { - private final Map, String> terms = Maps., String>newHashMap(); - - private static > String joinValues(Property property, Stream values) { - return (String)values.map(property::getName).collect(Collectors.joining("|")); - } - - private static > String getTerm(Property property, T startValue, T[] otherValues) { - return joinValues(property, Stream.concat(Stream.of(startValue), Stream.of(otherValues))); - } - - private > void putValue(Property property, String value) { - String string = (String)this.terms.put(property, value); - if (string != null) { - throw new IllegalStateException("Tried to replace " + property + " value from " + string + " to " + value); - } - } - - public final > Condition.TerminalCondition term(Property property, T value) { - this.putValue(property, property.getName(value)); - return this; - } - - @SafeVarargs - public final > Condition.TerminalCondition term(Property property, T startValue, T... otherValues) { - this.putValue(property, getTerm(property, startValue, otherValues)); - return this; - } - - public final > Condition.TerminalCondition negatedTerm(Property property, T value) { - this.putValue(property, "!" + property.getName(value)); - return this; - } - - @SafeVarargs - public final > Condition.TerminalCondition negatedTerm(Property property, T startValue, T... otherValues) { - this.putValue(property, "!" + getTerm(property, startValue, otherValues)); - return this; - } - - public JsonElement get() { - JsonObject jsonObject = new JsonObject(); - this.terms.forEach((property, string) -> jsonObject.addProperty(property.getName(), string)); - return jsonObject; - } - - @Override - public void validate(StateDefinition stateDefinition) { - List> list = (List>)this.terms - .keySet() - .stream() - .filter(property -> stateDefinition.getProperty(property.getName()) != property) - .collect(Collectors.toList()); - if (!list.isEmpty()) { - throw new IllegalStateException("Properties " + list + " are missing from " + stateDefinition); - } - } - } -} diff --git a/net/minecraft/client/data/models/blockstates/ConditionBuilder.java b/net/minecraft/client/data/models/blockstates/ConditionBuilder.java new file mode 100644 index 00000000..0f827bcb --- /dev/null +++ b/net/minecraft/client/data/models/blockstates/ConditionBuilder.java @@ -0,0 +1,46 @@ +package net.minecraft.client.data.models.blockstates; + +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.util.List; +import java.util.stream.Stream; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.multipart.Condition; +import net.minecraft.client.renderer.block.model.multipart.KeyValueCondition; +import net.minecraft.world.level.block.state.properties.Property; + +@Environment(EnvType.CLIENT) +public class ConditionBuilder { + private final Builder terms = ImmutableMap.builder(); + + private > void putValue(Property property, KeyValueCondition.Terms terms) { + this.terms.put(property.getName(), terms); + } + + public final > ConditionBuilder term(Property property, T value) { + this.putValue(property, new KeyValueCondition.Terms(List.of(new KeyValueCondition.Term(property.getName(value), false)))); + return this; + } + + @SafeVarargs + public final > ConditionBuilder term(Property property, T value, T... otherValues) { + List list = Stream.concat(Stream.of(value), Stream.of(otherValues)) + .map(property::getName) + .sorted() + .distinct() + .map(string -> new KeyValueCondition.Term(string, false)) + .toList(); + this.putValue(property, new KeyValueCondition.Terms(list)); + return this; + } + + public final > ConditionBuilder negatedTerm(Property property, T value) { + this.putValue(property, new KeyValueCondition.Terms(List.of(new KeyValueCondition.Term(property.getName(value), true)))); + return this; + } + + public Condition build() { + return new KeyValueCondition(this.terms.buildOrThrow()); + } +} diff --git a/net/minecraft/client/data/models/blockstates/MultiPartGenerator.java b/net/minecraft/client/data/models/blockstates/MultiPartGenerator.java index 83055641..e41a3fb1 100644 --- a/net/minecraft/client/data/models/blockstates/MultiPartGenerator.java +++ b/net/minecraft/client/data/models/blockstates/MultiPartGenerator.java @@ -1,29 +1,27 @@ package net.minecraft.client.data.models.blockstates; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.Lists; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; +import java.util.ArrayList; import java.util.List; -import java.util.function.Supplier; +import java.util.Optional; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.data.models.MultiVariant; +import net.minecraft.client.renderer.block.model.BlockModelDefinition; +import net.minecraft.client.renderer.block.model.multipart.Condition; +import net.minecraft.client.renderer.block.model.multipart.Selector; import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.StateDefinition; @Environment(EnvType.CLIENT) -public class MultiPartGenerator implements BlockStateGenerator { +public class MultiPartGenerator implements BlockModelDefinitionGenerator { private final Block block; - private final List parts = Lists.newArrayList(); + private final List parts = new ArrayList(); private MultiPartGenerator(Block block) { this.block = block; } @Override - public Block getBlock() { + public Block block() { return this.block; } @@ -31,77 +29,36 @@ public class MultiPartGenerator implements BlockStateGenerator { return new MultiPartGenerator(block); } - public MultiPartGenerator with(List variants) { - this.parts.add(new MultiPartGenerator.Entry(variants)); + public MultiPartGenerator with(MultiVariant variants) { + this.parts.add(new MultiPartGenerator.Entry(Optional.empty(), variants)); return this; } - public MultiPartGenerator with(Variant variant) { - return this.with(ImmutableList.of(variant)); + private void validateCondition(Condition condition) { + condition.instantiate(this.block.getStateDefinition()); } - public MultiPartGenerator with(Condition condition, List variants) { - this.parts.add(new MultiPartGenerator.ConditionalEntry(condition, variants)); + public MultiPartGenerator with(Condition condition, MultiVariant variants) { + this.validateCondition(condition); + this.parts.add(new MultiPartGenerator.Entry(Optional.of(condition), variants)); return this; } - public MultiPartGenerator with(Condition condition, Variant... variants) { - return this.with(condition, ImmutableList.copyOf(variants)); + public MultiPartGenerator with(ConditionBuilder condition, MultiVariant variants) { + return this.with(condition.build(), variants); } - public MultiPartGenerator with(Condition condition, Variant variant) { - return this.with(condition, ImmutableList.of(variant)); - } - - public JsonElement get() { - StateDefinition stateDefinition = this.block.getStateDefinition(); - this.parts.forEach(entry -> entry.validate(stateDefinition)); - JsonArray jsonArray = new JsonArray(); - this.parts.stream().map(MultiPartGenerator.Entry::get).forEach(jsonArray::add); - JsonObject jsonObject = new JsonObject(); - jsonObject.add("multipart", jsonArray); - return jsonObject; + @Override + public BlockModelDefinition create() { + return new BlockModelDefinition( + Optional.empty(), Optional.of(new BlockModelDefinition.MultiPartDefinition(this.parts.stream().map(MultiPartGenerator.Entry::toUnbaked).toList())) + ); } @Environment(EnvType.CLIENT) - static class ConditionalEntry extends MultiPartGenerator.Entry { - private final Condition condition; - - ConditionalEntry(Condition condition, List variants) { - super(variants); - this.condition = condition; - } - - @Override - public void validate(StateDefinition stateDefinition) { - this.condition.validate(stateDefinition); - } - - @Override - public void decorate(JsonObject json) { - json.add("when", (JsonElement)this.condition.get()); - } - } - - @Environment(EnvType.CLIENT) - static class Entry implements Supplier { - private final List variants; - - Entry(List variants) { - this.variants = variants; - } - - public void validate(StateDefinition stateDefinition) { - } - - public void decorate(JsonObject json) { - } - - public JsonElement get() { - JsonObject jsonObject = new JsonObject(); - this.decorate(jsonObject); - jsonObject.add("apply", Variant.convertList(this.variants)); - return jsonObject; + record Entry(Optional condition, MultiVariant variants) { + public Selector toUnbaked() { + return new Selector(this.condition, this.variants.toUnbaked()); } } } diff --git a/net/minecraft/client/data/models/blockstates/MultiVariantGenerator.java b/net/minecraft/client/data/models/blockstates/MultiVariantGenerator.java index 13775bc7..fb0ac251 100644 --- a/net/minecraft/client/data/models/blockstates/MultiVariantGenerator.java +++ b/net/minecraft/client/data/models/blockstates/MultiVariantGenerator.java @@ -1,86 +1,114 @@ package net.minecraft.client.data.models.blockstates; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.Lists; -import com.google.common.collect.Sets; -import com.google.common.collect.ImmutableList.Builder; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.mojang.datafixers.util.Pair; +import java.util.HashMap; +import java.util.HashSet; import java.util.List; import java.util.Map; +import java.util.Optional; import java.util.Set; -import java.util.TreeMap; import java.util.stream.Stream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.Util; +import net.minecraft.client.data.models.MultiVariant; +import net.minecraft.client.renderer.block.model.BlockModelDefinition; +import net.minecraft.client.renderer.block.model.BlockStateModel; +import net.minecraft.client.renderer.block.model.VariantMutator; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.state.properties.Property; @Environment(EnvType.CLIENT) -public class MultiVariantGenerator implements BlockStateGenerator { +public class MultiVariantGenerator implements BlockModelDefinitionGenerator { private final Block block; - private final List baseVariants; - private final Set> seenProperties = Sets.>newHashSet(); - private final List declaredPropertySets = Lists.newArrayList(); + private final List entries; + private final Set> seenProperties; - private MultiVariantGenerator(Block block, List baseVariants) { + MultiVariantGenerator(Block block, List entries, Set> seenProperties) { this.block = block; - this.baseVariants = baseVariants; + this.entries = entries; + this.seenProperties = seenProperties; } - public MultiVariantGenerator with(PropertyDispatch propertyDispatch) { - propertyDispatch.getDefinedProperties().forEach(property -> { - if (this.block.getStateDefinition().getProperty(property.getName()) != property) { - throw new IllegalStateException("Property " + property + " is not defined for block " + this.block); - } else if (!this.seenProperties.add(property)) { - throw new IllegalStateException("Values of property " + property + " already defined for block " + this.block); + static Set> validateAndExpandProperties(Set> seenProperties, Block block, PropertyDispatch propertyDispatch) { + List> list = propertyDispatch.getDefinedProperties(); + list.forEach(property -> { + if (block.getStateDefinition().getProperty(property.getName()) != property) { + throw new IllegalStateException("Property " + property + " is not defined for block " + block); + } else if (seenProperties.contains(property)) { + throw new IllegalStateException("Values of property " + property + " already defined for block " + block); } }); - this.declaredPropertySets.add(propertyDispatch); - return this; + Set> set = new HashSet(seenProperties); + set.addAll(list); + return set; } - public JsonElement get() { - Stream>> stream = Stream.of(Pair.of(Selector.empty(), this.baseVariants)); - - for (PropertyDispatch propertyDispatch : this.declaredPropertySets) { - Map> map = propertyDispatch.getEntries(); - stream = stream.flatMap(pair -> map.entrySet().stream().map(entry -> { - Selector selector = ((Selector)pair.getFirst()).extend((Selector)entry.getKey()); - List list = mergeVariants((List)pair.getSecond(), (List)entry.getValue()); - return Pair.of(selector, list); - })); - } - - Map map2 = new TreeMap(); - stream.forEach(pair -> map2.put(((Selector)pair.getFirst()).getKey(), Variant.convertList((List)pair.getSecond()))); - JsonObject jsonObject = new JsonObject(); - jsonObject.add("variants", Util.make(new JsonObject(), jsonObjectx -> map2.forEach(jsonObjectx::add))); - return jsonObject; + public MultiVariantGenerator with(PropertyDispatch propertyDispatch) { + Set> set = validateAndExpandProperties(this.seenProperties, this.block, propertyDispatch); + List list = this.entries.stream().flatMap(entry -> entry.apply(propertyDispatch)).toList(); + return new MultiVariantGenerator(this.block, list, set); } - private static List mergeVariants(List first, List second) { - Builder builder = ImmutableList.builder(); - first.forEach(variant -> second.forEach(variant2 -> builder.add(Variant.merge(variant, variant2)))); - return builder.build(); + public MultiVariantGenerator with(VariantMutator mutator) { + List list = this.entries.stream().flatMap(entry -> entry.apply(mutator)).toList(); + return new MultiVariantGenerator(this.block, list, this.seenProperties); } @Override - public Block getBlock() { + public BlockModelDefinition create() { + Map map = new HashMap(); + + for (MultiVariantGenerator.Entry entry : this.entries) { + map.put(entry.properties.getKey(), entry.variant.toUnbaked()); + } + + return new BlockModelDefinition(Optional.of(new BlockModelDefinition.SimpleModelSelectors(map)), Optional.empty()); + } + + @Override + public Block block() { return this.block; } - public static MultiVariantGenerator multiVariant(Block block) { - return new MultiVariantGenerator(block, ImmutableList.of(Variant.variant())); + public static MultiVariantGenerator.Empty dispatch(Block block) { + return new MultiVariantGenerator.Empty(block); } - public static MultiVariantGenerator multiVariant(Block block, Variant variant) { - return new MultiVariantGenerator(block, ImmutableList.of(variant)); + public static MultiVariantGenerator dispatch(Block block, MultiVariant variants) { + return new MultiVariantGenerator(block, List.of(new MultiVariantGenerator.Entry(PropertyValueList.EMPTY, variants)), Set.of()); } - public static MultiVariantGenerator multiVariant(Block block, Variant... variants) { - return new MultiVariantGenerator(block, ImmutableList.copyOf(variants)); + @Environment(EnvType.CLIENT) + public static class Empty { + private final Block block; + + public Empty(Block block) { + this.block = block; + } + + public MultiVariantGenerator with(PropertyDispatch propertyDispatch) { + Set> set = MultiVariantGenerator.validateAndExpandProperties(Set.of(), this.block, propertyDispatch); + List list = propertyDispatch.getEntries() + .entrySet() + .stream() + .map(entry -> new MultiVariantGenerator.Entry((PropertyValueList)entry.getKey(), (MultiVariant)entry.getValue())) + .toList(); + return new MultiVariantGenerator(this.block, list, set); + } + } + + @Environment(EnvType.CLIENT) + record Entry(PropertyValueList properties, MultiVariant variant) { + + public Stream apply(PropertyDispatch propertyDispatch) { + return propertyDispatch.getEntries().entrySet().stream().map(entry -> { + PropertyValueList propertyValueList = this.properties.extend((PropertyValueList)entry.getKey()); + MultiVariant multiVariant = this.variant.with((VariantMutator)entry.getValue()); + return new MultiVariantGenerator.Entry(propertyValueList, multiVariant); + }); + } + + public Stream apply(VariantMutator mutator) { + return Stream.of(new MultiVariantGenerator.Entry(this.properties, this.variant.with(mutator))); + } } } diff --git a/net/minecraft/client/data/models/blockstates/PropertyDispatch.java b/net/minecraft/client/data/models/blockstates/PropertyDispatch.java index 4a551f2a..1779f0f0 100644 --- a/net/minecraft/client/data/models/blockstates/PropertyDispatch.java +++ b/net/minecraft/client/data/models/blockstates/PropertyDispatch.java @@ -1,44 +1,45 @@ package net.minecraft.client.data.models.blockstates; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.ImmutableMap; -import com.google.common.collect.Maps; -import java.util.Collections; +import com.mojang.datafixers.util.Function3; +import com.mojang.datafixers.util.Function4; +import com.mojang.datafixers.util.Function5; +import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.function.BiFunction; import java.util.function.Function; -import java.util.stream.Collectors; import java.util.stream.Stream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.data.models.MultiVariant; +import net.minecraft.client.renderer.block.model.VariantMutator; import net.minecraft.world.level.block.state.properties.Property; @Environment(EnvType.CLIENT) -public abstract class PropertyDispatch { - private final Map> values = Maps.>newHashMap(); +public abstract class PropertyDispatch { + private final Map values = new HashMap(); - protected void putValue(Selector selector, List variants) { - List list = (List)this.values.put(selector, variants); - if (list != null) { - throw new IllegalStateException("Value " + selector + " is already defined"); + protected void putValue(PropertyValueList properties, V value) { + V object = (V)this.values.put(properties, value); + if (object != null) { + throw new IllegalStateException("Value " + properties + " is already defined"); } } - Map> getEntries() { + Map getEntries() { this.verifyComplete(); - return ImmutableMap.copyOf(this.values); + return Map.copyOf(this.values); } private void verifyComplete() { List> list = this.getDefinedProperties(); - Stream stream = Stream.of(Selector.empty()); + Stream stream = Stream.of(PropertyValueList.EMPTY); for (Property property : list) { - stream = stream.flatMap(selector -> property.getAllValues().map(selector::extend)); + stream = stream.flatMap(propertyValueList -> property.getAllValues().map(propertyValueList::extend)); } - List list2 = (List)stream.filter(selector -> !this.values.containsKey(selector)).collect(Collectors.toList()); + List list2 = stream.filter(propertyValueList -> !this.values.containsKey(propertyValueList)).toList(); if (!list2.isEmpty()) { throw new IllegalStateException("Missing definition for properties: " + list2); } @@ -46,34 +47,64 @@ public abstract class PropertyDispatch { abstract List> getDefinedProperties(); - public static > PropertyDispatch.C1 property(Property property1) { - return new PropertyDispatch.C1<>(property1); + public static > PropertyDispatch.C1 initial(Property property) { + return new PropertyDispatch.C1<>(property); } - public static , T2 extends Comparable> PropertyDispatch.C2 properties(Property property1, Property property2) { + public static , T2 extends Comparable> PropertyDispatch.C2 initial( + Property property1, Property property2 + ) { return new PropertyDispatch.C2<>(property1, property2); } - public static , T2 extends Comparable, T3 extends Comparable> PropertyDispatch.C3 properties( + public static , T2 extends Comparable, T3 extends Comparable> PropertyDispatch.C3 initial( Property property1, Property property2, Property property3 ) { return new PropertyDispatch.C3<>(property1, property2, property3); } - public static , T2 extends Comparable, T3 extends Comparable, T4 extends Comparable> PropertyDispatch.C4 properties( + public static , T2 extends Comparable, T3 extends Comparable, T4 extends Comparable> PropertyDispatch.C4 initial( Property property1, Property property2, Property property3, Property property4 ) { return new PropertyDispatch.C4<>(property1, property2, property3, property4); } - public static , T2 extends Comparable, T3 extends Comparable, T4 extends Comparable, T5 extends Comparable> PropertyDispatch.C5 properties( + public static , T2 extends Comparable, T3 extends Comparable, T4 extends Comparable, T5 extends Comparable> PropertyDispatch.C5 initial( + Property property1, Property property2, Property property3, Property property4, Property property5 + ) { + return new PropertyDispatch.C5<>(property1, property2, property3, property4, property5); + } + + public static > PropertyDispatch.C1 modify(Property property) { + return new PropertyDispatch.C1<>(property); + } + + public static , T2 extends Comparable> PropertyDispatch.C2 modify( + Property property1, Property property2 + ) { + return new PropertyDispatch.C2<>(property1, property2); + } + + public static , T2 extends Comparable, T3 extends Comparable> PropertyDispatch.C3 modify( + Property property1, Property property2, Property property3 + ) { + return new PropertyDispatch.C3<>(property1, property2, property3); + } + + public static , T2 extends Comparable, T3 extends Comparable, T4 extends Comparable> PropertyDispatch.C4 modify( + Property property1, Property property2, Property property3, Property property4 + ) { + return new PropertyDispatch.C4<>(property1, property2, property3, property4); + } + + public static , T2 extends Comparable, T3 extends Comparable, T4 extends Comparable, T5 extends Comparable> PropertyDispatch.C5 modify( Property property1, Property property2, Property property3, Property property4, Property property5 ) { return new PropertyDispatch.C5<>(property1, property2, property3, property4, property5); } @Environment(EnvType.CLIENT) - public static class C1> extends PropertyDispatch { + public static class C1> extends PropertyDispatch { private final Property property1; C1(Property property1) { @@ -82,32 +113,23 @@ public abstract class PropertyDispatch { @Override public List> getDefinedProperties() { - return ImmutableList.of(this.property1); + return List.of(this.property1); } - public PropertyDispatch.C1 select(T1 value1, List variants) { - Selector selector = Selector.of(this.property1.value(value1)); - this.putValue(selector, variants); + public PropertyDispatch.C1 select(T1 property, V value) { + PropertyValueList propertyValueList = PropertyValueList.of(this.property1.value(property)); + this.putValue(propertyValueList, value); return this; } - public PropertyDispatch.C1 select(T1 value1, Variant variant) { - return this.select(value1, Collections.singletonList(variant)); - } - - public PropertyDispatch generate(Function generator) { - this.property1.getPossibleValues().forEach(comparable -> this.select((T1)comparable, (Variant)generator.apply(comparable))); - return this; - } - - public PropertyDispatch generateList(Function> generator) { - this.property1.getPossibleValues().forEach(comparable -> this.select((T1)comparable, (List)generator.apply(comparable))); + public PropertyDispatch generate(Function generator) { + this.property1.getPossibleValues().forEach(comparable -> this.select((T1)comparable, (V)generator.apply(comparable))); return this; } } @Environment(EnvType.CLIENT) - public static class C2, T2 extends Comparable> extends PropertyDispatch { + public static class C2, T2 extends Comparable> extends PropertyDispatch { private final Property property1; private final Property property2; @@ -118,44 +140,29 @@ public abstract class PropertyDispatch { @Override public List> getDefinedProperties() { - return ImmutableList.of(this.property1, this.property2); + return List.of(this.property1, this.property2); } - public PropertyDispatch.C2 select(T1 value1, T2 value2, List variants) { - Selector selector = Selector.of(this.property1.value(value1), this.property2.value(value2)); - this.putValue(selector, variants); + public PropertyDispatch.C2 select(T1 property1, T2 property2, V value) { + PropertyValueList propertyValueList = PropertyValueList.of(this.property1.value(property1), this.property2.value(property2)); + this.putValue(propertyValueList, value); return this; } - public PropertyDispatch.C2 select(T1 value1, T2 value2, Variant variant) { - return this.select(value1, value2, Collections.singletonList(variant)); - } - - public PropertyDispatch generate(BiFunction generator) { + public PropertyDispatch generate(BiFunction generator) { this.property1 .getPossibleValues() .forEach( comparable -> this.property2 .getPossibleValues() - .forEach(comparable2 -> this.select((T1)comparable, (T2)comparable2, (Variant)generator.apply(comparable, comparable2))) - ); - return this; - } - - public PropertyDispatch generateList(BiFunction> generator) { - this.property1 - .getPossibleValues() - .forEach( - comparable -> this.property2 - .getPossibleValues() - .forEach(comparable2 -> this.select((T1)comparable, (T2)comparable2, (List)generator.apply(comparable, comparable2))) + .forEach(comparable2 -> this.select((T1)comparable, (T2)comparable2, (V)generator.apply(comparable, comparable2))) ); return this; } } @Environment(EnvType.CLIENT) - public static class C3, T2 extends Comparable, T3 extends Comparable> extends PropertyDispatch { + public static class C3, T2 extends Comparable, T3 extends Comparable> extends PropertyDispatch { private final Property property1; private final Property property2; private final Property property3; @@ -168,37 +175,16 @@ public abstract class PropertyDispatch { @Override public List> getDefinedProperties() { - return ImmutableList.of(this.property1, this.property2, this.property3); + return List.of(this.property1, this.property2, this.property3); } - public PropertyDispatch.C3 select(T1 value1, T2 value2, T3 value3, List variants) { - Selector selector = Selector.of(this.property1.value(value1), this.property2.value(value2), this.property3.value(value3)); - this.putValue(selector, variants); + public PropertyDispatch.C3 select(T1 property1, T2 property2, T3 property3, V value) { + PropertyValueList propertyValueList = PropertyValueList.of(this.property1.value(property1), this.property2.value(property2), this.property3.value(property3)); + this.putValue(propertyValueList, value); return this; } - public PropertyDispatch.C3 select(T1 value1, T2 value2, T3 value3, Variant variant) { - return this.select(value1, value2, value3, Collections.singletonList(variant)); - } - - public PropertyDispatch generate(PropertyDispatch.TriFunction generator) { - this.property1 - .getPossibleValues() - .forEach( - comparable -> this.property2 - .getPossibleValues() - .forEach( - comparable2 -> this.property3 - .getPossibleValues() - .forEach( - comparable3 -> this.select((T1)comparable, (T2)comparable2, (T3)comparable3, generator.apply((T1)comparable, (T2)comparable2, (T3)comparable3)) - ) - ) - ); - return this; - } - - public PropertyDispatch generateList(PropertyDispatch.TriFunction> generator) { + public PropertyDispatch generate(Function3 generator) { this.property1 .getPossibleValues() .forEach( @@ -217,7 +203,8 @@ public abstract class PropertyDispatch { } @Environment(EnvType.CLIENT) - public static class C4, T2 extends Comparable, T3 extends Comparable, T4 extends Comparable> extends PropertyDispatch { + public static class C4, T2 extends Comparable, T3 extends Comparable, T4 extends Comparable> + extends PropertyDispatch { private final Property property1; private final Property property2; private final Property property3; @@ -232,47 +219,18 @@ public abstract class PropertyDispatch { @Override public List> getDefinedProperties() { - return ImmutableList.of(this.property1, this.property2, this.property3, this.property4); + return List.of(this.property1, this.property2, this.property3, this.property4); } - public PropertyDispatch.C4 select(T1 value1, T2 value2, T3 value3, T4 value4, List variants) { - Selector selector = Selector.of(this.property1.value(value1), this.property2.value(value2), this.property3.value(value3), this.property4.value(value4)); - this.putValue(selector, variants); + public PropertyDispatch.C4 select(T1 property1, T2 property2, T3 property3, T4 property4, V value) { + PropertyValueList propertyValueList = PropertyValueList.of( + this.property1.value(property1), this.property2.value(property2), this.property3.value(property3), this.property4.value(property4) + ); + this.putValue(propertyValueList, value); return this; } - public PropertyDispatch.C4 select(T1 value1, T2 value2, T3 value3, T4 value4, Variant variant) { - return this.select(value1, value2, value3, value4, Collections.singletonList(variant)); - } - - public PropertyDispatch generate(PropertyDispatch.QuadFunction generator) { - this.property1 - .getPossibleValues() - .forEach( - comparable -> this.property2 - .getPossibleValues() - .forEach( - comparable2 -> this.property3 - .getPossibleValues() - .forEach( - comparable3 -> this.property4 - .getPossibleValues() - .forEach( - comparable4 -> this.select( - (T1)comparable, - (T2)comparable2, - (T3)comparable3, - (T4)comparable4, - generator.apply((T1)comparable, (T2)comparable2, (T3)comparable3, (T4)comparable4) - ) - ) - ) - ) - ); - return this; - } - - public PropertyDispatch generateList(PropertyDispatch.QuadFunction> generator) { + public PropertyDispatch generate(Function4 generator) { this.property1 .getPossibleValues() .forEach( @@ -301,8 +259,8 @@ public abstract class PropertyDispatch { } @Environment(EnvType.CLIENT) - public static class C5, T2 extends Comparable, T3 extends Comparable, T4 extends Comparable, T5 extends Comparable> - extends PropertyDispatch { + public static class C5, T2 extends Comparable, T3 extends Comparable, T4 extends Comparable, T5 extends Comparable> + extends PropertyDispatch { private final Property property1; private final Property property2; private final Property property3; @@ -319,22 +277,22 @@ public abstract class PropertyDispatch { @Override public List> getDefinedProperties() { - return ImmutableList.of(this.property1, this.property2, this.property3, this.property4, this.property5); + return List.of(this.property1, this.property2, this.property3, this.property4, this.property5); } - public PropertyDispatch.C5 select(T1 value1, T2 value2, T3 value3, T4 value4, T5 value5, List variants) { - Selector selector = Selector.of( - this.property1.value(value1), this.property2.value(value2), this.property3.value(value3), this.property4.value(value4), this.property5.value(value5) + public PropertyDispatch.C5 select(T1 property1, T2 property2, T3 property3, T4 property4, T5 property5, V value) { + PropertyValueList propertyValueList = PropertyValueList.of( + this.property1.value(property1), + this.property2.value(property2), + this.property3.value(property3), + this.property4.value(property4), + this.property5.value(property5) ); - this.putValue(selector, variants); + this.putValue(propertyValueList, value); return this; } - public PropertyDispatch.C5 select(T1 value1, T2 value2, T3 value3, T4 value4, T5 value5, Variant variant) { - return this.select(value1, value2, value3, value4, value5, Collections.singletonList(variant)); - } - - public PropertyDispatch generate(PropertyDispatch.PentaFunction generator) { + public PropertyDispatch generate(Function5 generator) { this.property1 .getPossibleValues() .forEach( @@ -365,55 +323,5 @@ public abstract class PropertyDispatch { ); return this; } - - public PropertyDispatch generateList(PropertyDispatch.PentaFunction> generator) { - this.property1 - .getPossibleValues() - .forEach( - comparable -> this.property2 - .getPossibleValues() - .forEach( - comparable2 -> this.property3 - .getPossibleValues() - .forEach( - comparable3 -> this.property4 - .getPossibleValues() - .forEach( - comparable4 -> this.property5 - .getPossibleValues() - .forEach( - comparable5 -> this.select( - (T1)comparable, - (T2)comparable2, - (T3)comparable3, - (T4)comparable4, - (T5)comparable5, - generator.apply((T1)comparable, (T2)comparable2, (T3)comparable3, (T4)comparable4, (T5)comparable5) - ) - ) - ) - ) - ) - ); - return this; - } - } - - @FunctionalInterface - @Environment(EnvType.CLIENT) - public interface PentaFunction { - R apply(P1 p1, P2 p2, P3 p3, P4 p4, P5 p5); - } - - @FunctionalInterface - @Environment(EnvType.CLIENT) - public interface QuadFunction { - R apply(P1 p1, P2 p2, P3 p3, P4 p4); - } - - @FunctionalInterface - @Environment(EnvType.CLIENT) - public interface TriFunction { - R apply(P1 object, P2 object2, P3 object3); } } diff --git a/net/minecraft/client/data/models/blockstates/PropertyValueList.java b/net/minecraft/client/data/models/blockstates/PropertyValueList.java new file mode 100644 index 00000000..7147ec28 --- /dev/null +++ b/net/minecraft/client/data/models/blockstates/PropertyValueList.java @@ -0,0 +1,36 @@ +package net.minecraft.client.data.models.blockstates; + +import com.google.common.collect.ImmutableList; +import java.util.Comparator; +import java.util.List; +import java.util.stream.Collectors; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.Util; +import net.minecraft.world.level.block.state.properties.Property.Value; + +@Environment(EnvType.CLIENT) +public record PropertyValueList(List> values) { + public static final PropertyValueList EMPTY = new PropertyValueList(List.of()); + private static final Comparator> COMPARE_BY_NAME = Comparator.comparing(value -> value.property().getName()); + + public PropertyValueList extend(Value value) { + return new PropertyValueList(Util.copyAndAdd(this.values, value)); + } + + public PropertyValueList extend(PropertyValueList values) { + return new PropertyValueList(ImmutableList.>builder().addAll(this.values).addAll(values.values).build()); + } + + public static PropertyValueList of(Value... values) { + return new PropertyValueList(List.of(values)); + } + + public String getKey() { + return (String)this.values.stream().sorted(COMPARE_BY_NAME).map(Value::toString).collect(Collectors.joining(",")); + } + + public String toString() { + return this.getKey(); + } +} diff --git a/net/minecraft/client/data/models/blockstates/Selector.java b/net/minecraft/client/data/models/blockstates/Selector.java deleted file mode 100644 index 58d8010a..00000000 --- a/net/minecraft/client/data/models/blockstates/Selector.java +++ /dev/null @@ -1,52 +0,0 @@ -package net.minecraft.client.data.models.blockstates; - -import com.google.common.collect.ImmutableList; -import java.util.Comparator; -import java.util.List; -import java.util.stream.Collectors; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.world.level.block.state.properties.Property.Value; - -@Environment(EnvType.CLIENT) -public final class Selector { - private static final Selector EMPTY = new Selector(ImmutableList.of()); - private static final Comparator> COMPARE_BY_NAME = Comparator.comparing(value -> value.property().getName()); - private final List> values; - - public Selector extend(Value value) { - return new Selector(ImmutableList.>builder().addAll(this.values).add(value).build()); - } - - public Selector extend(Selector selector) { - return new Selector(ImmutableList.>builder().addAll(this.values).addAll(selector.values).build()); - } - - private Selector(List> values) { - this.values = values; - } - - public static Selector empty() { - return EMPTY; - } - - public static Selector of(Value... values) { - return new Selector(ImmutableList.copyOf(values)); - } - - public boolean equals(Object object) { - return this == object || object instanceof Selector && this.values.equals(((Selector)object).values); - } - - public int hashCode() { - return this.values.hashCode(); - } - - public String getKey() { - return (String)this.values.stream().sorted(COMPARE_BY_NAME).map(Value::toString).collect(Collectors.joining(",")); - } - - public String toString() { - return this.getKey(); - } -} diff --git a/net/minecraft/client/data/models/blockstates/Variant.java b/net/minecraft/client/data/models/blockstates/Variant.java deleted file mode 100644 index d25cd390..00000000 --- a/net/minecraft/client/data/models/blockstates/Variant.java +++ /dev/null @@ -1,52 +0,0 @@ -package net.minecraft.client.data.models.blockstates; - -import com.google.common.collect.Maps; -import com.google.gson.JsonArray; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import java.util.List; -import java.util.Map; -import java.util.function.Supplier; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; - -@Environment(EnvType.CLIENT) -public class Variant implements Supplier { - private final Map, VariantProperty.Value> values = Maps., VariantProperty.Value>newLinkedHashMap(); - - public Variant with(VariantProperty property, T value) { - VariantProperty.Value value2 = (VariantProperty.Value)this.values.put(property, property.withValue(value)); - if (value2 != null) { - throw new IllegalStateException("Replacing value of " + value2 + " with " + value); - } else { - return this; - } - } - - public static Variant variant() { - return new Variant(); - } - - public static Variant merge(Variant first, Variant second) { - Variant variant = new Variant(); - variant.values.putAll(first.values); - variant.values.putAll(second.values); - return variant; - } - - public JsonElement get() { - JsonObject jsonObject = new JsonObject(); - this.values.values().forEach(value -> value.addToVariant(jsonObject)); - return jsonObject; - } - - public static JsonElement convertList(List list) { - if (list.size() == 1) { - return ((Variant)list.get(0)).get(); - } else { - JsonArray jsonArray = new JsonArray(); - list.forEach(variant -> jsonArray.add(variant.get())); - return jsonArray; - } - } -} diff --git a/net/minecraft/client/data/models/blockstates/VariantProperties.java b/net/minecraft/client/data/models/blockstates/VariantProperties.java deleted file mode 100644 index 68a61b4f..00000000 --- a/net/minecraft/client/data/models/blockstates/VariantProperties.java +++ /dev/null @@ -1,31 +0,0 @@ -package net.minecraft.client.data.models.blockstates; - -import com.google.gson.JsonPrimitive; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.resources.ResourceLocation; - -@Environment(EnvType.CLIENT) -public class VariantProperties { - public static final VariantProperty X_ROT = new VariantProperty<>("x", rotation -> new JsonPrimitive(rotation.value)); - public static final VariantProperty Y_ROT = new VariantProperty<>("y", rotation -> new JsonPrimitive(rotation.value)); - public static final VariantProperty MODEL = new VariantProperty<>( - "model", resourceLocation -> new JsonPrimitive(resourceLocation.toString()) - ); - public static final VariantProperty UV_LOCK = new VariantProperty<>("uvlock", JsonPrimitive::new); - public static final VariantProperty WEIGHT = new VariantProperty<>("weight", JsonPrimitive::new); - - @Environment(EnvType.CLIENT) - public static enum Rotation { - R0(0), - R90(90), - R180(180), - R270(270); - - final int value; - - private Rotation(final int value) { - this.value = value; - } - } -} diff --git a/net/minecraft/client/data/models/blockstates/VariantProperty.java b/net/minecraft/client/data/models/blockstates/VariantProperty.java deleted file mode 100644 index 0fe3bbb7..00000000 --- a/net/minecraft/client/data/models/blockstates/VariantProperty.java +++ /dev/null @@ -1,47 +0,0 @@ -package net.minecraft.client.data.models.blockstates; - -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import java.util.function.Function; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; - -@Environment(EnvType.CLIENT) -public class VariantProperty { - final String key; - final Function serializer; - - public VariantProperty(String key, Function serializer) { - this.key = key; - this.serializer = serializer; - } - - public VariantProperty.Value withValue(T value) { - return new VariantProperty.Value(value); - } - - public String toString() { - return this.key; - } - - @Environment(EnvType.CLIENT) - public class Value { - private final T value; - - public Value(final T value) { - this.value = value; - } - - public VariantProperty getKey() { - return VariantProperty.this; - } - - public void addToVariant(JsonObject json) { - json.add(VariantProperty.this.key, (JsonElement)VariantProperty.this.serializer.apply(this.value)); - } - - public String toString() { - return VariantProperty.this.key + "=" + this.value; - } - } -} diff --git a/net/minecraft/client/data/models/model/ModelTemplates.java b/net/minecraft/client/data/models/model/ModelTemplates.java index c7abe57a..89e1b8e4 100644 --- a/net/minecraft/client/data/models/model/ModelTemplates.java +++ b/net/minecraft/client/data/models/model/ModelTemplates.java @@ -98,6 +98,10 @@ public class ModelTemplates { public static final ModelTemplate FLOWERBED_2 = create("flowerbed_2", "_2", TextureSlot.FLOWERBED, TextureSlot.STEM); public static final ModelTemplate FLOWERBED_3 = create("flowerbed_3", "_3", TextureSlot.FLOWERBED, TextureSlot.STEM); public static final ModelTemplate FLOWERBED_4 = create("flowerbed_4", "_4", TextureSlot.FLOWERBED, TextureSlot.STEM); + public static final ModelTemplate LEAF_LITTER_1 = create("template_leaf_litter_1", "_1", TextureSlot.TEXTURE); + public static final ModelTemplate LEAF_LITTER_2 = create("template_leaf_litter_2", "_2", TextureSlot.TEXTURE); + public static final ModelTemplate LEAF_LITTER_3 = create("template_leaf_litter_3", "_3", TextureSlot.TEXTURE); + public static final ModelTemplate LEAF_LITTER_4 = create("template_leaf_litter_4", "_4", TextureSlot.TEXTURE); public static final ModelTemplate CORAL_FAN = create("coral_fan", TextureSlot.FAN); public static final ModelTemplate CORAL_WALL_FAN = create("coral_wall_fan", TextureSlot.FAN); public static final ModelTemplate GLAZED_TERRACOTTA = create("template_glazed_terracotta", TextureSlot.PATTERN); diff --git a/net/minecraft/client/data/models/model/TexturedModel.java b/net/minecraft/client/data/models/model/TexturedModel.java index 77fb2b7a..2ced7407 100644 --- a/net/minecraft/client/data/models/model/TexturedModel.java +++ b/net/minecraft/client/data/models/model/TexturedModel.java @@ -25,6 +25,10 @@ public class TexturedModel { public static final TexturedModel.Provider FLOWERBED_2 = createDefault(TextureMapping::flowerbed, ModelTemplates.FLOWERBED_2); public static final TexturedModel.Provider FLOWERBED_3 = createDefault(TextureMapping::flowerbed, ModelTemplates.FLOWERBED_3); public static final TexturedModel.Provider FLOWERBED_4 = createDefault(TextureMapping::flowerbed, ModelTemplates.FLOWERBED_4); + public static final TexturedModel.Provider LEAF_LITTER_1 = createDefault(TextureMapping::defaultTexture, ModelTemplates.LEAF_LITTER_1); + public static final TexturedModel.Provider LEAF_LITTER_2 = createDefault(TextureMapping::defaultTexture, ModelTemplates.LEAF_LITTER_2); + public static final TexturedModel.Provider LEAF_LITTER_3 = createDefault(TextureMapping::defaultTexture, ModelTemplates.LEAF_LITTER_3); + public static final TexturedModel.Provider LEAF_LITTER_4 = createDefault(TextureMapping::defaultTexture, ModelTemplates.LEAF_LITTER_4); public static final TexturedModel.Provider GLAZED_TERRACOTTA = createDefault(TextureMapping::pattern, ModelTemplates.GLAZED_TERRACOTTA); public static final TexturedModel.Provider CORAL_FAN = createDefault(TextureMapping::fan, ModelTemplates.CORAL_FAN); public static final TexturedModel.Provider ANVIL = createDefault(TextureMapping::top, ModelTemplates.ANVIL); diff --git a/net/minecraft/client/gui/Gui.java b/net/minecraft/client/gui/Gui.java index a032e845..84653b2e 100644 --- a/net/minecraft/client/gui/Gui.java +++ b/net/minecraft/client/gui/Gui.java @@ -23,6 +23,7 @@ import net.minecraft.client.gui.components.DebugScreenOverlay; import net.minecraft.client.gui.components.PlayerTabOverlay; import net.minecraft.client.gui.components.SubtitleOverlay; import net.minecraft.client.gui.components.spectator.SpectatorGui; +import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.renderer.LightTexture; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.texture.TextureAtlasSprite; @@ -255,16 +256,17 @@ public class Gui { this.renderVignette(guiGraphics, this.minecraft.getCameraEntity()); } + LocalPlayer localPlayer = this.minecraft.player; float f = deltaTracker.getGameTimeDeltaTicks(); this.scopeScale = Mth.lerp(0.5F * f, this.scopeScale, 1.125F); if (this.minecraft.options.getCameraType().isFirstPerson()) { - if (this.minecraft.player.isScoping()) { + if (localPlayer.isScoping()) { this.renderSpyglassOverlay(guiGraphics, this.scopeScale); } else { this.scopeScale = 0.5F; for (EquipmentSlot equipmentSlot : EquipmentSlot.values()) { - ItemStack itemStack = this.minecraft.player.getItemBySlot(equipmentSlot); + ItemStack itemStack = localPlayer.getItemBySlot(equipmentSlot); Equippable equippable = itemStack.get(DataComponents.EQUIPPABLE); if (equippable != null && equippable.slot() == equipmentSlot && equippable.cameraOverlay().isPresent()) { this.renderTextureOverlay( @@ -275,22 +277,20 @@ public class Gui { } } - if (this.minecraft.player.getTicksFrozen() > 0) { - this.renderTextureOverlay(guiGraphics, POWDER_SNOW_OUTLINE_LOCATION, this.minecraft.player.getPercentFrozen()); + if (localPlayer.getTicksFrozen() > 0) { + this.renderTextureOverlay(guiGraphics, POWDER_SNOW_OUTLINE_LOCATION, localPlayer.getPercentFrozen()); } - float g = Mth.lerp( - deltaTracker.getGameTimeDeltaPartialTick(false), this.minecraft.player.oSpinningEffectIntensity, this.minecraft.player.spinningEffectIntensity - ); - if (g > 0.0F) { - if (!this.minecraft.player.hasEffect(MobEffects.CONFUSION)) { - this.renderPortalOverlay(guiGraphics, g); - } else { - float h = this.minecraft.options.screenEffectScale().get().floatValue(); - if (h < 1.0F) { - float i = g * (1.0F - h); - this.renderConfusionOverlay(guiGraphics, i); - } + float g = deltaTracker.getGameTimeDeltaPartialTick(false); + float h = Mth.lerp(g, localPlayer.oPortalEffectIntensity, localPlayer.portalEffectIntensity); + float i = localPlayer.getEffectBlendFactor(MobEffects.NAUSEA, g); + if (h > 0.0F) { + this.renderPortalOverlay(guiGraphics, h); + } else if (i > 0.0F) { + float j = this.minecraft.options.screenEffectScale().get().floatValue(); + if (j < 1.0F) { + float k = i * (1.0F - j); + this.renderConfusionOverlay(guiGraphics, k); } } } @@ -382,8 +382,8 @@ public class Gui { private void renderChat(GuiGraphics guiGraphics, DeltaTracker deltaTracker) { if (!this.chat.isChatFocused()) { Window window = this.minecraft.getWindow(); - int i = Mth.floor(this.minecraft.mouseHandler.xpos() * window.getGuiScaledWidth() / window.getScreenWidth()); - int j = Mth.floor(this.minecraft.mouseHandler.ypos() * window.getGuiScaledHeight() / window.getScreenHeight()); + int i = Mth.floor(this.minecraft.mouseHandler.getScaledXPos(window)); + int j = Mth.floor(this.minecraft.mouseHandler.getScaledYPos(window)); this.chat.render(guiGraphics, this.tickCount, i, j, false); } } @@ -430,7 +430,7 @@ public class Gui { matrix4fStack.rotateX(-camera.getXRot() * (float) (Math.PI / 180.0)); matrix4fStack.rotateY(camera.getYRot() * (float) (Math.PI / 180.0)); matrix4fStack.scale(-1.0F, -1.0F, -1.0F); - RenderSystem.renderCrosshair(10); + this.debugOverlay.render3dCrosshair(); matrix4fStack.popMatrix(); } else { int i = 15; @@ -572,7 +572,7 @@ public class Gui { guiGraphics.pose().translate(0.0F, 0.0F, -90.0F); guiGraphics.blitSprite(RenderType::guiTextured, HOTBAR_SPRITE, i - 91, guiGraphics.guiHeight() - 22, 182, 22); guiGraphics.blitSprite( - RenderType::guiTextured, HOTBAR_SELECTION_SPRITE, i - 91 - 1 + player.getInventory().selected * 20, guiGraphics.guiHeight() - 22 - 1, 24, 23 + RenderType::guiTextured, HOTBAR_SELECTION_SPRITE, i - 91 - 1 + player.getInventory().getSelectedSlot() * 20, guiGraphics.guiHeight() - 22 - 1, 24, 23 ); if (!itemStack.isEmpty()) { if (humanoidArm == HumanoidArm.LEFT) { @@ -588,7 +588,7 @@ public class Gui { for (int m = 0; m < 9; m++) { int n = i - 90 + m * 20 + 2; int o = guiGraphics.guiHeight() - 16 - 3; - this.renderSlot(guiGraphics, n, o, deltaTracker, player, player.getInventory().items.get(m), l++); + this.renderSlot(guiGraphics, n, o, deltaTracker, player, player.getInventory().getItem(m), l++); } if (!itemStack.isEmpty()) { @@ -1323,7 +1323,7 @@ public class Gui { } if (this.minecraft.player != null) { - ItemStack itemStack = this.minecraft.player.getInventory().getSelected(); + ItemStack itemStack = this.minecraft.player.getInventory().getSelectedItem(); if (itemStack.isEmpty()) { this.toolHighlightTimer = 0; } else if (this.lastToolHighlight.isEmpty() diff --git a/net/minecraft/client/gui/GuiGraphics.java b/net/minecraft/client/gui/GuiGraphics.java index 01356f6d..7acea9d6 100644 --- a/net/minecraft/client/gui/GuiGraphics.java +++ b/net/minecraft/client/gui/GuiGraphics.java @@ -21,6 +21,7 @@ import net.minecraft.CrashReportDetail; import net.minecraft.ReportedException; import net.minecraft.Util; import net.minecraft.client.Minecraft; +import net.minecraft.client.gui.Font.DisplayMode; import net.minecraft.client.gui.navigation.ScreenRectangle; import net.minecraft.client.gui.screens.Screen; import net.minecraft.client.gui.screens.inventory.tooltip.ClientTooltipComponent; @@ -35,18 +36,12 @@ import net.minecraft.client.renderer.item.ItemStackRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.resources.metadata.gui.GuiSpriteScaling; -import net.minecraft.client.resources.metadata.gui.GuiSpriteScaling.NineSlice; -import net.minecraft.client.resources.metadata.gui.GuiSpriteScaling.Stretch; -import net.minecraft.client.resources.metadata.gui.GuiSpriteScaling.Tile; import net.minecraft.client.resources.metadata.gui.GuiSpriteScaling.NineSlice.Border; import net.minecraft.core.component.DataComponents; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.FormattedText; import net.minecraft.network.chat.HoverEvent; import net.minecraft.network.chat.Style; -import net.minecraft.network.chat.HoverEvent.Action; -import net.minecraft.network.chat.HoverEvent.EntityTooltipInfo; -import net.minecraft.network.chat.HoverEvent.ItemStackInfo; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.ARGB; import net.minecraft.util.FormattedCharSequence; @@ -438,7 +433,7 @@ public class GuiGraphics { public int drawString(Font font, @Nullable String text, int x, int y, int color, boolean dropShadow) { return text == null ? 0 - : font.drawInBatch(text, (float)x, (float)y, color, dropShadow, this.pose.last().pose(), this.bufferSource, Font.DisplayMode.NORMAL, 0, 15728880); + : font.drawInBatch(text, (float)x, (float)y, color, dropShadow, this.pose.last().pose(), this.bufferSource, DisplayMode.NORMAL, 0, 15728880); } /** @@ -469,7 +464,7 @@ public class GuiGraphics { * @param dropShadow whether to apply a drop shadow to the string. */ public int drawString(Font font, FormattedCharSequence text, int x, int y, int color, boolean dropShadow) { - return font.drawInBatch(text, (float)x, (float)y, color, dropShadow, this.pose.last().pose(), this.bufferSource, Font.DisplayMode.NORMAL, 0, 15728880); + return font.drawInBatch(text, (float)x, (float)y, color, dropShadow, this.pose.last().pose(), this.bufferSource, DisplayMode.NORMAL, 0, 15728880); } /** @@ -557,11 +552,11 @@ public class GuiGraphics { public void blitSprite(Function renderTypeGetter, ResourceLocation sprite, int x, int y, int width, int height, int blitOffset) { TextureAtlasSprite textureAtlasSprite = this.sprites.getSprite(sprite); GuiSpriteScaling guiSpriteScaling = this.sprites.getSpriteScaling(textureAtlasSprite); - if (guiSpriteScaling instanceof Stretch) { + if (guiSpriteScaling instanceof GuiSpriteScaling.Stretch) { this.blitSprite(renderTypeGetter, textureAtlasSprite, x, y, width, height, blitOffset); - } else if (guiSpriteScaling instanceof Tile tile) { + } else if (guiSpriteScaling instanceof GuiSpriteScaling.Tile tile) { this.blitTiledSprite(renderTypeGetter, textureAtlasSprite, x, y, width, height, 0, 0, tile.width(), tile.height(), tile.width(), tile.height(), blitOffset); - } else if (guiSpriteScaling instanceof NineSlice nineSlice) { + } else if (guiSpriteScaling instanceof GuiSpriteScaling.NineSlice nineSlice) { this.blitNineSlicedSprite(renderTypeGetter, textureAtlasSprite, nineSlice, x, y, width, height, blitOffset); } } @@ -580,7 +575,7 @@ public class GuiGraphics { ) { TextureAtlasSprite textureAtlasSprite = this.sprites.getSprite(sprite); GuiSpriteScaling guiSpriteScaling = this.sprites.getSpriteScaling(textureAtlasSprite); - if (guiSpriteScaling instanceof Stretch) { + if (guiSpriteScaling instanceof GuiSpriteScaling.Stretch) { this.blitSprite(renderTypeGetter, textureAtlasSprite, textureWidth, textureHeight, uPosition, vPosition, x, y, uWidth, vHeight, -1); } else { this.enableScissor(x, y, x + uWidth, y + vHeight); @@ -632,7 +627,14 @@ public class GuiGraphics { } private void blitNineSlicedSprite( - Function renderTypeGetter, TextureAtlasSprite sprite, NineSlice nineSlice, int x, int y, int blitOffset, int width, int height + Function renderTypeGetter, + TextureAtlasSprite sprite, + GuiSpriteScaling.NineSlice nineSlice, + int x, + int y, + int blitOffset, + int width, + int height ) { Border border = nineSlice.border(); int i = Math.min(border.left(), blitOffset / 2); @@ -755,7 +757,7 @@ public class GuiGraphics { private void blitNineSliceInnerSegment( Function renderTypeGetter, - NineSlice nineSlice, + GuiSpriteScaling.NineSlice nineSlice, TextureAtlasSprite sprite, int x, int y, @@ -1014,9 +1016,9 @@ public class GuiGraphics { */ private void renderItem(@Nullable LivingEntity entity, @Nullable Level level, ItemStack stack, int x, int y, int seed, int guiOffset) { if (!stack.isEmpty()) { - this.minecraft.getItemModelResolver().updateForTopItem(this.scratchItemStackRenderState, stack, ItemDisplayContext.GUI, false, level, entity, seed); + this.minecraft.getItemModelResolver().updateForTopItem(this.scratchItemStackRenderState, stack, ItemDisplayContext.GUI, level, entity, seed); this.pose.pushPose(); - this.pose.translate((float)(x + 8), (float)(y + 8), (float)(150 + (this.scratchItemStackRenderState.isGui3d() ? guiOffset : 0))); + this.pose.translate((float)(x + 8), (float)(y + 8), (float)(150 + guiOffset)); try { this.pose.scale(16.0F, -16.0F, 16.0F); @@ -1279,22 +1281,20 @@ public class GuiGraphics { */ public void renderComponentHoverEffect(Font font, @Nullable Style style, int mouseX, int mouseY) { if (style != null && style.getHoverEvent() != null) { - HoverEvent hoverEvent = style.getHoverEvent(); - ItemStackInfo itemStackInfo = hoverEvent.getValue(Action.SHOW_ITEM); - if (itemStackInfo != null) { - this.renderTooltip(font, itemStackInfo.getItemStack(), mouseX, mouseY); - } else { - EntityTooltipInfo entityTooltipInfo = hoverEvent.getValue(Action.SHOW_ENTITY); - if (entityTooltipInfo != null) { + switch (style.getHoverEvent()) { + case HoverEvent.ShowItem(ItemStack var17): + this.renderTooltip(font, var17, mouseX, mouseY); + break; + case HoverEvent.ShowEntity(HoverEvent.EntityTooltipInfo var22): + HoverEvent.EntityTooltipInfo var18 = var22; if (this.minecraft.options.advancedItemTooltips) { - this.renderComponentTooltip(font, entityTooltipInfo.getTooltipLines(), mouseX, mouseY); + this.renderComponentTooltip(font, var18.getTooltipLines(), mouseX, mouseY); } - } else { - Component component = hoverEvent.getValue(Action.SHOW_TEXT); - if (component != null) { - this.renderTooltip(font, font.split(component, Math.max(this.guiWidth() / 2, 200)), mouseX, mouseY); - } - } + break; + case HoverEvent.ShowText(Component var13): + this.renderTooltip(font, font.split(var13, Math.max(this.guiWidth() / 2, 200)), mouseX, mouseY); + break; + default: } } } diff --git a/net/minecraft/client/gui/GuiSpriteManager.java b/net/minecraft/client/gui/GuiSpriteManager.java index f749c93b..965f11e9 100644 --- a/net/minecraft/client/gui/GuiSpriteManager.java +++ b/net/minecraft/client/gui/GuiSpriteManager.java @@ -9,6 +9,7 @@ import net.minecraft.client.resources.TextureAtlasHolder; import net.minecraft.client.resources.metadata.animation.AnimationMetadataSection; import net.minecraft.client.resources.metadata.gui.GuiMetadataSection; import net.minecraft.client.resources.metadata.gui.GuiSpriteScaling; +import net.minecraft.client.resources.model.AtlasIds; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.metadata.MetadataSectionType; @@ -17,7 +18,7 @@ public class GuiSpriteManager extends TextureAtlasHolder { private static final Set> METADATA_SECTIONS = Set.of(AnimationMetadataSection.TYPE, GuiMetadataSection.TYPE); public GuiSpriteManager(TextureManager textureManager) { - super(textureManager, ResourceLocation.withDefaultNamespace("textures/atlas/gui.png"), ResourceLocation.withDefaultNamespace("gui"), METADATA_SECTIONS); + super(textureManager, ResourceLocation.withDefaultNamespace("textures/atlas/gui.png"), AtlasIds.GUI, METADATA_SECTIONS); } @Override diff --git a/net/minecraft/client/gui/components/CommandSuggestions.java b/net/minecraft/client/gui/components/CommandSuggestions.java index 22aa0818..568628a9 100644 --- a/net/minecraft/client/gui/components/CommandSuggestions.java +++ b/net/minecraft/client/gui/components/CommandSuggestions.java @@ -504,16 +504,8 @@ public class CommandSuggestions { } public boolean mouseScrolled(double delta) { - int i = (int)( - CommandSuggestions.this.minecraft.mouseHandler.xpos() - * CommandSuggestions.this.minecraft.getWindow().getGuiScaledWidth() - / CommandSuggestions.this.minecraft.getWindow().getScreenWidth() - ); - int j = (int)( - CommandSuggestions.this.minecraft.mouseHandler.ypos() - * CommandSuggestions.this.minecraft.getWindow().getGuiScaledHeight() - / CommandSuggestions.this.minecraft.getWindow().getScreenHeight() - ); + int i = (int)CommandSuggestions.this.minecraft.mouseHandler.getScaledXPos(CommandSuggestions.this.minecraft.getWindow()); + int j = (int)CommandSuggestions.this.minecraft.mouseHandler.getScaledYPos(CommandSuggestions.this.minecraft.getWindow()); if (this.rect.contains(i, j)) { this.offset = Mth.clamp((int)(this.offset - delta), 0, Math.max(this.suggestionList.size() - CommandSuggestions.this.suggestionLineLimit, 0)); return true; diff --git a/net/minecraft/client/gui/components/ContainerObjectSelectionList.java b/net/minecraft/client/gui/components/ContainerObjectSelectionList.java index cd7d375c..556ef556 100644 --- a/net/minecraft/client/gui/components/ContainerObjectSelectionList.java +++ b/net/minecraft/client/gui/components/ContainerObjectSelectionList.java @@ -10,6 +10,7 @@ import net.minecraft.client.gui.components.events.GuiEventListener; import net.minecraft.client.gui.narration.NarratableEntry; import net.minecraft.client.gui.narration.NarratedElementType; import net.minecraft.client.gui.narration.NarrationElementOutput; +import net.minecraft.client.gui.narration.NarratableEntry.NarrationPriority; import net.minecraft.client.gui.navigation.FocusNavigationEvent; import net.minecraft.client.gui.navigation.ScreenAxis; import net.minecraft.client.gui.navigation.ScreenDirection; @@ -90,8 +91,8 @@ public abstract class ContainerObjectSelectionList> extends AbstractSelectionList.Entry implements ContainerEventHandler { + public abstract static class Entry> + extends net.minecraft.client.gui.components.AbstractSelectionList.Entry + implements ContainerEventHandler { @Nullable private GuiEventListener focused; @Nullable @@ -209,7 +212,7 @@ public abstract class ContainerObjectSelectionList HEIGHTMAP_NAMES = Util.make(new EnumMap(Heightmap.Types.class), enumMap -> { - enumMap.put(Heightmap.Types.WORLD_SURFACE_WG, "SW"); - enumMap.put(Heightmap.Types.WORLD_SURFACE, "S"); - enumMap.put(Heightmap.Types.OCEAN_FLOOR_WG, "OW"); - enumMap.put(Heightmap.Types.OCEAN_FLOOR, "O"); - enumMap.put(Heightmap.Types.MOTION_BLOCKING, "M"); - enumMap.put(Heightmap.Types.MOTION_BLOCKING_NO_LEAVES, "ML"); - }); + private static final Map HEIGHTMAP_NAMES = Maps.newEnumMap( + Map.of( + Heightmap.Types.WORLD_SURFACE_WG, + "SW", + Heightmap.Types.WORLD_SURFACE, + "S", + Heightmap.Types.OCEAN_FLOOR_WG, + "OW", + Heightmap.Types.OCEAN_FLOOR, + "O", + Heightmap.Types.MOTION_BLOCKING, + "M", + Heightmap.Types.MOTION_BLOCKING_NO_LEAVES, + "ML" + ) + ); private final Minecraft minecraft; private final DebugScreenOverlay.AllocationRateCalculator allocationRateCalculator; private final Font font; + private final GpuBuffer crosshairBuffer; + private final RenderSystem.AutoStorageIndexBuffer crosshairIndicies = RenderSystem.getSequentialBuffer(VertexFormat.Mode.LINES); private HitResult block; private HitResult liquid; @Nullable @@ -126,6 +155,21 @@ public class DebugScreenOverlay { this.pingChart = new PingDebugChart(this.font, this.pingLogger); this.bandwidthChart = new BandwidthDebugChart(this.font, this.bandwidthLogger); this.profilerPieChart = new ProfilerPieChart(this.font); + + try (ByteBufferBuilder byteBufferBuilder = new ByteBufferBuilder(DefaultVertexFormat.POSITION_COLOR_NORMAL.getVertexSize() * 12)) { + BufferBuilder bufferBuilder = new BufferBuilder(byteBufferBuilder, VertexFormat.Mode.LINES, DefaultVertexFormat.POSITION_COLOR_NORMAL); + bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-65536).setNormal(1.0F, 0.0F, 0.0F); + bufferBuilder.addVertex(10.0F, 0.0F, 0.0F).setColor(-65536).setNormal(1.0F, 0.0F, 0.0F); + bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-16711936).setNormal(0.0F, 1.0F, 0.0F); + bufferBuilder.addVertex(0.0F, 10.0F, 0.0F).setColor(-16711936).setNormal(0.0F, 1.0F, 0.0F); + bufferBuilder.addVertex(0.0F, 0.0F, 0.0F).setColor(-8421377).setNormal(0.0F, 0.0F, 1.0F); + bufferBuilder.addVertex(0.0F, 0.0F, 10.0F).setColor(-8421377).setNormal(0.0F, 0.0F, 1.0F); + + try (MeshData meshData = bufferBuilder.buildOrThrow()) { + this.crosshairBuffer = RenderSystem.getDevice() + .createBuffer(() -> "Crosshair vertex buffer", BufferType.VERTICES, BufferUsage.STATIC_WRITE, meshData.vertexBuffer()); + } + } } public void clearChunkCache() { @@ -289,7 +333,7 @@ public class DebugScreenOverlay { } Level level = this.getLevel(); - LongSet longSet = (LongSet)(level instanceof ServerLevel ? ((ServerLevel)level).getForcedChunks() : LongSets.EMPTY_SET); + LongSet longSet = (LongSet)(level instanceof ServerLevel ? ((ServerLevel)level).getForceLoadedChunks() : LongSets.EMPTY_SET); List list = Lists.newArrayList( "Minecraft " + SharedConstants.getCurrentVersion().getName() @@ -414,7 +458,7 @@ public class DebugScreenOverlay { ChunkGenerator chunkGenerator = serverChunkCache.getGenerator(); RandomState randomState = serverChunkCache.randomState(); chunkGenerator.addDebugScreenInfo(list, randomState, blockPos); - Climate.Sampler sampler = randomState.sampler(); + Sampler sampler = randomState.sampler(); BiomeSource biomeSource = chunkGenerator.getBiomeSource(); biomeSource.addDebugInfo(list, blockPos, sampler); NaturalSpawner.SpawnState spawnState = serverChunkCache.getLastSpawnState(); @@ -499,19 +543,20 @@ public class DebugScreenOverlay { long m = Runtime.getRuntime().totalMemory(); long n = Runtime.getRuntime().freeMemory(); long o = m - n; + GpuDevice gpuDevice = RenderSystem.getDevice(); List list = Lists.newArrayList( String.format(Locale.ROOT, "Java: %s", System.getProperty("java.version")), String.format(Locale.ROOT, "Mem: %2d%% %03d/%03dMB", o * 100L / l, bytesToMegabytes(o), bytesToMegabytes(l)), String.format(Locale.ROOT, "Allocation rate: %03dMB/s", bytesToMegabytes(this.allocationRateCalculator.bytesAllocatedPerSecond(o))), String.format(Locale.ROOT, "Allocated: %2d%% %03dMB", m * 100L / l, bytesToMegabytes(m)), "", - String.format(Locale.ROOT, "CPU: %s", GlUtil.getCpuInfo()), + String.format(Locale.ROOT, "CPU: %s", GLX._getCpuInfo()), "", String.format( - Locale.ROOT, "Display: %dx%d (%s)", Minecraft.getInstance().getWindow().getWidth(), Minecraft.getInstance().getWindow().getHeight(), GlUtil.getVendor() + Locale.ROOT, "Display: %dx%d (%s)", Minecraft.getInstance().getWindow().getWidth(), Minecraft.getInstance().getWindow().getHeight(), gpuDevice.getVendor() ), - GlUtil.getRenderer(), - GlUtil.getOpenGLVersion() + gpuDevice.getRenderer(), + String.format(Locale.ROOT, "%s %s", gpuDevice.getBackendName(), gpuDevice.getVersion()) ); if (this.minecraft.showOnlyReducedInfo()) { return list; @@ -649,6 +694,30 @@ public class DebugScreenOverlay { this.bandwidthLogger.reset(); } + public void render3dCrosshair() { + RenderPipeline renderPipeline = RenderPipelines.LINES; + RenderSystem.setShaderColor(0.0F, 0.0F, 0.0F, 1.0F); + RenderTarget renderTarget = Minecraft.getInstance().getMainRenderTarget(); + GpuTexture gpuTexture = renderTarget.getColorTexture(); + GpuTexture gpuTexture2 = renderTarget.getDepthTexture(); + GpuBuffer gpuBuffer = this.crosshairIndicies.getBuffer(18); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass(gpuTexture, OptionalInt.empty(), gpuTexture2, OptionalDouble.empty())) { + renderPass.setPipeline(renderPipeline); + RenderSystem.setShaderColor(0.0F, 0.0F, 0.0F, 1.0F); + RenderSystem.lineWidth(4.0F); + renderPass.setVertexBuffer(0, this.crosshairBuffer); + renderPass.setIndexBuffer(gpuBuffer, this.crosshairIndicies.type()); + renderPass.drawIndexed(0, 18); + RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); + RenderSystem.lineWidth(2.0F); + renderPass.drawIndexed(0, 18); + RenderSystem.lineWidth(1.0F); + } + } + @Environment(EnvType.CLIENT) static class AllocationRateCalculator { private static final int UPDATE_INTERVAL_MS = 500; diff --git a/net/minecraft/client/gui/components/FittingMultiLineTextWidget.java b/net/minecraft/client/gui/components/FittingMultiLineTextWidget.java index e021219b..848b62a0 100644 --- a/net/minecraft/client/gui/components/FittingMultiLineTextWidget.java +++ b/net/minecraft/client/gui/components/FittingMultiLineTextWidget.java @@ -42,32 +42,7 @@ public class FittingMultiLineTextWidget extends AbstractTextAreaWidget { @Override protected void renderBackground(GuiGraphics guiGraphics) { - if (this.scrollbarVisible()) { - super.renderBackground(guiGraphics); - } else if (this.isFocused()) { - this.renderBorder( - guiGraphics, - this.getX() - this.innerPadding(), - this.getY() - this.innerPadding(), - this.getWidth() + this.totalInnerPadding(), - this.getHeight() + this.totalInnerPadding() - ); - } - } - - @Override - public void renderWidget(GuiGraphics guiGraphics, int mouseX, int mouseY, float partialTick) { - if (this.visible) { - if (!this.scrollbarVisible()) { - this.renderBackground(guiGraphics); - guiGraphics.pose().pushPose(); - guiGraphics.pose().translate((float)this.getX(), (float)this.getY(), 0.0F); - this.multilineWidget.render(guiGraphics, mouseX, mouseY, partialTick); - guiGraphics.pose().popPose(); - } else { - super.renderWidget(guiGraphics, mouseX, mouseY, partialTick); - } - } + super.renderBackground(guiGraphics); } public boolean showingScrollBar() { @@ -86,4 +61,10 @@ public class FittingMultiLineTextWidget extends AbstractTextAreaWidget { protected void updateWidgetNarration(NarrationElementOutput narrationElementOutput) { narrationElementOutput.add(NarratedElementType.TITLE, this.getMessage()); } + + @Override + public void setMessage(Component message) { + super.setMessage(message); + this.multilineWidget.setMessage(message); + } } diff --git a/net/minecraft/client/gui/components/PopupScreen.java b/net/minecraft/client/gui/components/PopupScreen.java index 170a3449..b66cd9ef 100644 --- a/net/minecraft/client/gui/components/PopupScreen.java +++ b/net/minecraft/client/gui/components/PopupScreen.java @@ -101,7 +101,7 @@ public class PopupScreen extends Screen { public void renderBackground(GuiGraphics guiGraphics, int mouseX, int mouseY, float partialTick) { this.backgroundScreen.render(guiGraphics, -1, -1, partialTick); guiGraphics.flush(); - RenderSystem.clear(256); + RenderSystem.getDevice().createCommandEncoder().clearDepthTexture(this.minecraft.getMainRenderTarget().getDepthTexture(), 1.0); this.renderTransparentBackground(guiGraphics); guiGraphics.blitSprite( RenderType::guiTextured, BACKGROUND_SPRITE, this.layout.getX() - 18, this.layout.getY() - 18, this.layout.getWidth() + 36, this.layout.getHeight() + 36 diff --git a/net/minecraft/client/gui/components/events/ContainerEventHandler.java b/net/minecraft/client/gui/components/events/ContainerEventHandler.java index 83acfa49..b44e3c23 100644 --- a/net/minecraft/client/gui/components/events/ContainerEventHandler.java +++ b/net/minecraft/client/gui/components/events/ContainerEventHandler.java @@ -69,7 +69,7 @@ public interface ContainerEventHandler extends GuiEventListener { } } - return this.getChildAt(mouseX, mouseY).filter(guiEventListener -> guiEventListener.mouseReleased(mouseX, mouseY, button)).isPresent(); + return false; } @Override diff --git a/net/minecraft/client/gui/components/toasts/AdvancementToast.java b/net/minecraft/client/gui/components/toasts/AdvancementToast.java index 0d82d302..3ea149ad 100644 --- a/net/minecraft/client/gui/components/toasts/AdvancementToast.java +++ b/net/minecraft/client/gui/components/toasts/AdvancementToast.java @@ -1,6 +1,7 @@ package net.minecraft.client.gui.components.toasts; import java.util.List; +import java.util.Optional; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.advancements.AdvancementHolder; @@ -9,18 +10,18 @@ import net.minecraft.advancements.DisplayInfo; import net.minecraft.client.gui.Font; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.renderer.RenderType; -import net.minecraft.client.resources.sounds.SimpleSoundInstance; import net.minecraft.resources.ResourceLocation; +import net.minecraft.sounds.SoundEvent; import net.minecraft.sounds.SoundEvents; import net.minecraft.util.FormattedCharSequence; import net.minecraft.util.Mth; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class AdvancementToast implements Toast { private static final ResourceLocation BACKGROUND_SPRITE = ResourceLocation.withDefaultNamespace("toast/advancement"); public static final int DISPLAY_TIME = 5000; private final AdvancementHolder advancement; - private boolean playedSound; private Toast.Visibility wantedVisibility = Toast.Visibility.HIDE; public AdvancementToast(AdvancementHolder advancement) { @@ -38,17 +39,21 @@ public class AdvancementToast implements Toast { if (displayInfo == null) { this.wantedVisibility = Toast.Visibility.HIDE; } else { - if (!this.playedSound && visibilityTime > 0L) { - this.playedSound = true; - if (displayInfo.getType() == AdvancementType.CHALLENGE) { - toastManager.getMinecraft().getSoundManager().play(SimpleSoundInstance.forUI(SoundEvents.UI_TOAST_CHALLENGE_COMPLETE, 1.0F, 1.0F)); - } - } - this.wantedVisibility = visibilityTime >= 5000.0 * toastManager.getNotificationDisplayTimeMultiplier() ? Toast.Visibility.HIDE : Toast.Visibility.SHOW; } } + @Nullable + @Override + public SoundEvent getSoundEvent() { + return this.isChallengeAdvancement() ? SoundEvents.UI_TOAST_CHALLENGE_COMPLETE : null; + } + + private boolean isChallengeAdvancement() { + Optional optional = this.advancement.value().display(); + return optional.isPresent() && ((DisplayInfo)optional.get()).getType().equals(AdvancementType.CHALLENGE); + } + @Override public void render(GuiGraphics guiGraphics, Font font, long visibilityTime) { DisplayInfo displayInfo = (DisplayInfo)this.advancement.value().display().orElse(null); diff --git a/net/minecraft/client/gui/components/toasts/SystemToast.java b/net/minecraft/client/gui/components/toasts/SystemToast.java index adbe55a8..4b058a47 100644 --- a/net/minecraft/client/gui/components/toasts/SystemToast.java +++ b/net/minecraft/client/gui/components/toasts/SystemToast.java @@ -8,7 +8,6 @@ import net.minecraft.ChatFormatting; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.Font; import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.client.gui.components.toasts.Toast.Visibility; import net.minecraft.client.renderer.RenderType; import net.minecraft.network.chat.Component; import net.minecraft.resources.ResourceLocation; @@ -29,7 +28,7 @@ public class SystemToast implements Toast { private boolean changed; private final int width; private boolean forceHide; - private Visibility wantedVisibility = Visibility.HIDE; + private Toast.Visibility wantedVisibility = Toast.Visibility.HIDE; public SystemToast(SystemToast.SystemToastId id, Component title, @Nullable Component message) { this( @@ -73,7 +72,7 @@ public class SystemToast implements Toast { } @Override - public Visibility getWantedVisibility() { + public Toast.Visibility getWantedVisibility() { return this.wantedVisibility; } @@ -86,7 +85,7 @@ public class SystemToast implements Toast { double d = this.id.displayTime * toastManager.getNotificationDisplayTimeMultiplier(); long l = visibilityTime - this.lastChanged; - this.wantedVisibility = !this.forceHide && l < d ? Visibility.SHOW : Visibility.HIDE; + this.wantedVisibility = !this.forceHide && l < d ? Toast.Visibility.SHOW : Toast.Visibility.HIDE; } @Override diff --git a/net/minecraft/client/gui/components/toasts/Toast.java b/net/minecraft/client/gui/components/toasts/Toast.java index 1c7d8bed..645b4629 100644 --- a/net/minecraft/client/gui/components/toasts/Toast.java +++ b/net/minecraft/client/gui/components/toasts/Toast.java @@ -9,6 +9,7 @@ import net.minecraft.client.sounds.SoundManager; import net.minecraft.sounds.SoundEvent; import net.minecraft.sounds.SoundEvents; import net.minecraft.util.Mth; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public interface Toast { @@ -20,6 +21,11 @@ public interface Toast { void update(ToastManager toastManager, long visibilityTime); + @Nullable + default SoundEvent getSoundEvent() { + return null; + } + void render(GuiGraphics guiGraphics, Font font, long visibilityTime); default Object getToken() { diff --git a/net/minecraft/client/gui/components/toasts/ToastManager.java b/net/minecraft/client/gui/components/toasts/ToastManager.java index 7a49f07e..c04b96d1 100644 --- a/net/minecraft/client/gui/components/toasts/ToastManager.java +++ b/net/minecraft/client/gui/components/toasts/ToastManager.java @@ -4,13 +4,18 @@ import com.google.common.collect.Queues; import java.util.ArrayList; import java.util.BitSet; import java.util.Deque; +import java.util.HashSet; import java.util.List; +import java.util.Set; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.Util; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.resources.sounds.SimpleSoundInstance; +import net.minecraft.sounds.SoundEvent; import net.minecraft.util.Mth; +import org.apache.commons.lang3.mutable.MutableBoolean; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) @@ -21,14 +26,22 @@ public class ToastManager { private final List> visibleToasts = new ArrayList(); private final BitSet occupiedSlots = new BitSet(5); private final Deque queued = Queues.newArrayDeque(); + private final Set playedToastSounds = new HashSet(); public ToastManager(Minecraft minecraft) { this.minecraft = minecraft; } public void update() { + MutableBoolean mutableBoolean = new MutableBoolean(false); this.visibleToasts.removeIf(toastInstance -> { + Toast.Visibility visibility = toastInstance.visibility; toastInstance.update(); + if (toastInstance.visibility != visibility && mutableBoolean.isFalse()) { + mutableBoolean.setTrue(); + toastInstance.visibility.playSound(this.minecraft.getSoundManager()); + } + if (toastInstance.hasFinishedRendering()) { this.occupiedSlots.clear(toastInstance.firstSlotIndex, toastInstance.firstSlotIndex + toastInstance.occupiedSlotCount); return true; @@ -45,10 +58,17 @@ public class ToastManager { } else { this.visibleToasts.add(new ToastManager.ToastInstance<>(toast, j, i)); this.occupiedSlots.set(j, j + i); + SoundEvent soundEvent = toast.getSoundEvent(); + if (soundEvent != null && this.playedToastSounds.add(soundEvent)) { + this.minecraft.getSoundManager().play(SimpleSoundInstance.forUI(soundEvent, 1.0F, 1.0F)); + } + return true; } }); } + + this.playedToastSounds.clear(); } public void render(GuiGraphics guiGraphics) { @@ -124,7 +144,7 @@ public class ToastManager { final int occupiedSlotCount; private long animationStartTime = -1L; private long becameFullyVisibleAt = -1L; - private Toast.Visibility visibility = Toast.Visibility.SHOW; + Toast.Visibility visibility = Toast.Visibility.HIDE; private long fullyVisibleFor; private float visiblePortion; private boolean hasFinishedRendering; @@ -157,7 +177,7 @@ public class ToastManager { long l = Util.getMillis(); if (this.animationStartTime == -1L) { this.animationStartTime = l; - this.visibility.playSound(ToastManager.this.minecraft.getSoundManager()); + this.visibility = Toast.Visibility.SHOW; } if (this.visibility == Toast.Visibility.SHOW && l - this.animationStartTime <= 600L) { @@ -171,7 +191,6 @@ public class ToastManager { if (visibility != this.visibility) { this.animationStartTime = l - (int)((1.0F - this.visiblePortion) * 600.0F); this.visibility = visibility; - this.visibility.playSound(ToastManager.this.minecraft.getSoundManager()); } this.hasFinishedRendering = this.visibility == Toast.Visibility.HIDE && l - this.animationStartTime > 600L; diff --git a/net/minecraft/client/gui/components/toasts/TutorialToast.java b/net/minecraft/client/gui/components/toasts/TutorialToast.java index 3b5cc716..1b66ed33 100644 --- a/net/minecraft/client/gui/components/toasts/TutorialToast.java +++ b/net/minecraft/client/gui/components/toasts/TutorialToast.java @@ -6,7 +6,6 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.gui.Font; import net.minecraft.client.gui.GuiGraphics; -import net.minecraft.client.gui.components.toasts.Toast.Visibility; import net.minecraft.client.renderer.RenderType; import net.minecraft.network.chat.Component; import net.minecraft.resources.ResourceLocation; @@ -28,7 +27,7 @@ public class TutorialToast implements Toast { private static final int TEXT_WIDTH = 126; private final TutorialToast.Icons icon; private final List lines; - private Visibility visibility = Visibility.SHOW; + private Toast.Visibility visibility = Toast.Visibility.SHOW; private long lastSmoothingTime; private float smoothedProgress; private float progress; @@ -52,7 +51,7 @@ public class TutorialToast implements Toast { } @Override - public Visibility getWantedVisibility() { + public Toast.Visibility getWantedVisibility() { return this.visibility; } @@ -107,7 +106,7 @@ public class TutorialToast implements Toast { } public void hide() { - this.visibility = Visibility.HIDE; + this.visibility = Toast.Visibility.HIDE; } public void updateProgress(float progress) { diff --git a/net/minecraft/client/gui/font/FontManager.java b/net/minecraft/client/gui/font/FontManager.java index 3e44481e..9048e780 100644 --- a/net/minecraft/client/gui/font/FontManager.java +++ b/net/minecraft/client/gui/font/FontManager.java @@ -76,11 +76,11 @@ public class FontManager implements PreparableReloadListener, AutoCloseable { @Override public CompletableFuture reload( - PreparableReloadListener.PreparationBarrier barrier, ResourceManager manager, Executor backgroundExecutor, Executor gameExecutor + PreparableReloadListener.PreparationBarrier preparationBarrier, ResourceManager resourceManager, Executor executor, Executor executor2 ) { - return this.prepare(manager, backgroundExecutor) - .thenCompose(barrier::wait) - .thenAcceptAsync(preparation -> this.apply(preparation, Profiler.get()), gameExecutor); + return this.prepare(resourceManager, executor) + .thenCompose(preparationBarrier::wait) + .thenAcceptAsync(preparation -> this.apply(preparation, Profiler.get()), executor2); } private CompletableFuture prepare(ResourceManager resourceManager, Executor executor) { diff --git a/net/minecraft/client/gui/font/FontSet.java b/net/minecraft/client/gui/font/FontSet.java index c5176947..073b8305 100644 --- a/net/minecraft/client/gui/font/FontSet.java +++ b/net/minecraft/client/gui/font/FontSet.java @@ -63,7 +63,7 @@ public class FontSet implements AutoCloseable { } private void resetTextures() { - this.closeTextures(); + this.textures.clear(); this.glyphs.clear(); this.glyphInfos.clear(); this.glyphsByWidth.clear(); @@ -99,14 +99,6 @@ public class FontSet implements AutoCloseable { } public void close() { - this.closeTextures(); - } - - private void closeTextures() { - for (FontTexture fontTexture : this.textures) { - fontTexture.close(); - } - this.textures.clear(); } @@ -172,7 +164,7 @@ public class FontSet implements AutoCloseable { GlyphRenderTypes glyphRenderTypes = bl ? GlyphRenderTypes.createForColorTexture(resourceLocation) : GlyphRenderTypes.createForIntensityTexture(resourceLocation); - FontTexture fontTexture2 = new FontTexture(glyphRenderTypes, bl); + FontTexture fontTexture2 = new FontTexture(resourceLocation::toString, glyphRenderTypes, bl); this.textures.add(fontTexture2); this.textureManager.register(resourceLocation, fontTexture2); BakedGlyph bakedGlyph2 = fontTexture2.add(glyphInfo); diff --git a/net/minecraft/client/gui/font/FontTexture.java b/net/minecraft/client/gui/font/FontTexture.java index 91ca274c..de311a5b 100644 --- a/net/minecraft/client/gui/font/FontTexture.java +++ b/net/minecraft/client/gui/font/FontTexture.java @@ -1,9 +1,12 @@ package net.minecraft.client.gui.font; import com.mojang.blaze3d.font.SheetGlyphInfo; -import com.mojang.blaze3d.platform.NativeImage; import com.mojang.blaze3d.platform.TextureUtil; +import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.FilterMode; +import com.mojang.blaze3d.textures.TextureFormat; import java.nio.file.Path; +import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.gui.font.glyphs.BakedGlyph; @@ -19,28 +22,22 @@ public class FontTexture extends AbstractTexture implements Dumpable { private final boolean colored; private final FontTexture.Node root; - public FontTexture(GlyphRenderTypes renderTypes, boolean colored) { + public FontTexture(Supplier label, GlyphRenderTypes renderTypes, boolean colored) { this.colored = colored; this.root = new FontTexture.Node(0, 0, 256, 256); - TextureUtil.prepareImage(colored ? NativeImage.InternalGlFormat.RGBA : NativeImage.InternalGlFormat.RED, this.getId(), 256, 256); - this.setFilter(false, false); + this.texture = RenderSystem.getDevice().createTexture(label, colored ? TextureFormat.RGBA8 : TextureFormat.RED8, 256, 256, 1); + this.texture.setTextureFilter(FilterMode.NEAREST, false); this.renderTypes = renderTypes; } - @Override - public void close() { - this.releaseId(); - } - @Nullable public BakedGlyph add(SheetGlyphInfo glyphInfo) { if (glyphInfo.isColored() != this.colored) { return null; } else { FontTexture.Node node = this.root.insert(glyphInfo); - if (node != null) { - this.bind(); - glyphInfo.upload(node.x, node.y); + if (node != null && this.texture != null) { + glyphInfo.upload(node.x, node.y, this.texture); float f = 256.0F; float g = 256.0F; float h = 0.01F; @@ -63,8 +60,10 @@ public class FontTexture extends AbstractTexture implements Dumpable { @Override public void dumpContents(ResourceLocation resourceLocation, Path path) { - String string = resourceLocation.toDebugFileName(); - TextureUtil.writeAsPNG(path, string, this.getId(), 0, 256, 256, i -> (i & 0xFF000000) == 0 ? -16777216 : i); + if (this.texture != null) { + String string = resourceLocation.toDebugFileName(); + TextureUtil.writeAsPNG(path, string, this.texture, 0, i -> (i & 0xFF000000) == 0 ? -16777216 : i); + } } @Environment(EnvType.CLIENT) diff --git a/net/minecraft/client/gui/font/glyphs/SpecialGlyphs.java b/net/minecraft/client/gui/font/glyphs/SpecialGlyphs.java index 7fdf5aa4..0dddab1e 100644 --- a/net/minecraft/client/gui/font/glyphs/SpecialGlyphs.java +++ b/net/minecraft/client/gui/font/glyphs/SpecialGlyphs.java @@ -3,6 +3,8 @@ package net.minecraft.client.gui.font.glyphs; import com.mojang.blaze3d.font.GlyphInfo; import com.mojang.blaze3d.font.SheetGlyphInfo; import com.mojang.blaze3d.platform.NativeImage; +import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import java.util.function.Function; import java.util.function.Supplier; import net.fabricmc.api.EnvType; @@ -46,32 +48,36 @@ public enum SpecialGlyphs implements GlyphInfo { @Override public BakedGlyph bake(Function function) { - return (BakedGlyph)function.apply(new SheetGlyphInfo() { - @Override - public int getPixelWidth() { - return SpecialGlyphs.this.image.getWidth(); - } + return (BakedGlyph)function.apply( + new SheetGlyphInfo() { + @Override + public int getPixelWidth() { + return SpecialGlyphs.this.image.getWidth(); + } - @Override - public int getPixelHeight() { - return SpecialGlyphs.this.image.getHeight(); - } + @Override + public int getPixelHeight() { + return SpecialGlyphs.this.image.getHeight(); + } - @Override - public float getOversample() { - return 1.0F; - } + @Override + public float getOversample() { + return 1.0F; + } - @Override - public void upload(int xOffset, int yOffset) { - SpecialGlyphs.this.image.upload(0, xOffset, yOffset, false); - } + @Override + public void upload(int x, int y, GpuTexture texture) { + RenderSystem.getDevice() + .createCommandEncoder() + .writeToTexture(texture, SpecialGlyphs.this.image, 0, x, y, SpecialGlyphs.this.image.getWidth(), SpecialGlyphs.this.image.getHeight(), 0, 0); + } - @Override - public boolean isColored() { - return true; + @Override + public boolean isColored() { + return true; + } } - }); + ); } @FunctionalInterface diff --git a/net/minecraft/client/gui/font/providers/GlyphProviderType.java b/net/minecraft/client/gui/font/providers/GlyphProviderType.java index ad4acc18..87e21f46 100644 --- a/net/minecraft/client/gui/font/providers/GlyphProviderType.java +++ b/net/minecraft/client/gui/font/providers/GlyphProviderType.java @@ -1,18 +1,18 @@ package net.minecraft.client.gui.font.providers; +import com.mojang.blaze3d.font.SpaceProvider.Definition; import com.mojang.serialization.Codec; import com.mojang.serialization.MapCodec; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.gui.font.providers.BitmapProvider.Definition; import net.minecraft.util.StringRepresentable; @Environment(EnvType.CLIENT) public enum GlyphProviderType implements StringRepresentable { - BITMAP("bitmap", Definition.CODEC), + BITMAP("bitmap", BitmapProvider.Definition.CODEC), TTF("ttf", TrueTypeGlyphProviderDefinition.CODEC), - SPACE("space", com.mojang.blaze3d.font.SpaceProvider.Definition.CODEC), - UNIHEX("unihex", net.minecraft.client.gui.font.providers.UnihexProvider.Definition.CODEC), + SPACE("space", Definition.CODEC), + UNIHEX("unihex", UnihexProvider.Definition.CODEC), REFERENCE("reference", ProviderReferenceDefinition.CODEC); public static final Codec CODEC = StringRepresentable.fromEnum(GlyphProviderType::values); diff --git a/net/minecraft/client/gui/font/providers/UnihexProvider.java b/net/minecraft/client/gui/font/providers/UnihexProvider.java index 1f809308..0d8e6939 100644 --- a/net/minecraft/client/gui/font/providers/UnihexProvider.java +++ b/net/minecraft/client/gui/font/providers/UnihexProvider.java @@ -4,8 +4,6 @@ import com.google.common.annotations.VisibleForTesting; import com.mojang.blaze3d.font.GlyphInfo; import com.mojang.blaze3d.font.GlyphProvider; import com.mojang.blaze3d.font.SheetGlyphInfo; -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.platform.NativeImage; import com.mojang.datafixers.util.Either; import com.mojang.logging.LogUtils; import com.mojang.serialization.Codec; @@ -26,12 +24,14 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.gui.font.CodepointMap; import net.minecraft.client.gui.font.glyphs.BakedGlyph; +import net.minecraft.client.gui.font.providers.GlyphProviderDefinition.Loader; +import net.minecraft.client.gui.font.providers.GlyphProviderDefinition.Reference; +import net.minecraft.client.gui.font.providers.UnihexProvider.Glyph.1; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.util.ExtraCodecs; import net.minecraft.util.FastBufferedInputStream; import org.jetbrains.annotations.Nullable; -import org.lwjgl.system.MemoryUtil; import org.slf4j.Logger; @Environment(EnvType.CLIENT) @@ -214,7 +214,7 @@ public class UnihexProvider implements GlyphProvider { } @Override - public Either unpack() { + public Either unpack() { return Either.left(this::load); } @@ -347,35 +347,7 @@ public class UnihexProvider implements GlyphProvider { @Override public BakedGlyph bake(Function function) { - return (BakedGlyph)function.apply(new SheetGlyphInfo() { - @Override - public float getOversample() { - return 2.0F; - } - - @Override - public int getPixelWidth() { - return Glyph.this.width(); - } - - @Override - public int getPixelHeight() { - return 16; - } - - @Override - public void upload(int xOffset, int yOffset) { - IntBuffer intBuffer = MemoryUtil.memAllocInt(Glyph.this.width() * 16); - UnihexProvider.unpackBitsToBytes(intBuffer, Glyph.this.contents, Glyph.this.left, Glyph.this.right); - intBuffer.rewind(); - GlStateManager.upload(0, xOffset, yOffset, Glyph.this.width(), 16, NativeImage.Format.RGBA, intBuffer, MemoryUtil::memFree); - } - - @Override - public boolean isColored() { - return true; - } - }); + return (BakedGlyph)function.apply(new 1(this)); } } diff --git a/net/minecraft/client/gui/screens/AccessibilityOnboardingScreen.java b/net/minecraft/client/gui/screens/AccessibilityOnboardingScreen.java index 488d09f0..f30a34d8 100644 --- a/net/minecraft/client/gui/screens/AccessibilityOnboardingScreen.java +++ b/net/minecraft/client/gui/screens/AccessibilityOnboardingScreen.java @@ -122,7 +122,7 @@ public class AccessibilityOnboardingScreen extends Screen { if (this.timer < 40.0F) { this.timer++; } else if (this.minecraft.isWindowActive()) { - Narrator.getNarrator().say(ONBOARDING_NARRATOR_MESSAGE.getString(), true); + Narrator.getNarrator().say(ONBOARDING_NARRATOR_MESSAGE.getString(), true, 1.0F); this.hasNarrated = true; } } diff --git a/net/minecraft/client/gui/screens/ConnectScreen.java b/net/minecraft/client/gui/screens/ConnectScreen.java index 63a98e30..1c134006 100644 --- a/net/minecraft/client/gui/screens/ConnectScreen.java +++ b/net/minecraft/client/gui/screens/ConnectScreen.java @@ -16,13 +16,12 @@ import net.minecraft.client.gui.components.Button; import net.minecraft.client.multiplayer.ClientHandshakePacketListenerImpl; import net.minecraft.client.multiplayer.ServerData; import net.minecraft.client.multiplayer.TransferState; -import net.minecraft.client.multiplayer.ServerData.ServerPackStatus; import net.minecraft.client.multiplayer.chat.report.ReportEnvironment; import net.minecraft.client.multiplayer.resolver.ResolvedServerAddress; import net.minecraft.client.multiplayer.resolver.ServerAddress; import net.minecraft.client.multiplayer.resolver.ServerNameResolver; import net.minecraft.client.quickplay.QuickPlay; -import net.minecraft.client.quickplay.QuickPlayLog.Type; +import net.minecraft.client.quickplay.QuickPlayLog; import net.minecraft.client.resources.server.ServerPackManager.PackPromptStatus; import net.minecraft.network.Connection; import net.minecraft.network.chat.CommonComponents; @@ -79,7 +78,7 @@ public class ConnectScreen extends Screen { minecraft.disconnect(); minecraft.prepareForMultiplayer(); minecraft.updateReportEnvironment(ReportEnvironment.thirdParty(serverData.ip)); - minecraft.quickPlayLog().setWorldData(Type.MULTIPLAYER, serverData.ip, serverData.name); + minecraft.quickPlayLog().setWorldData(QuickPlayLog.Type.MULTIPLAYER, serverData.ip, serverData.name); minecraft.setScreen(connectScreen); connectScreen.connect(minecraft, serverAddress, serverData, transferState); } @@ -169,7 +168,7 @@ public class ConnectScreen extends Screen { } } - private static PackPromptStatus convertPackStatus(ServerPackStatus packStatus) { + private static PackPromptStatus convertPackStatus(ServerData.ServerPackStatus packStatus) { return switch (packStatus) { case ENABLED -> PackPromptStatus.ALLOWED; case DISABLED -> PackPromptStatus.DECLINED; diff --git a/net/minecraft/client/gui/screens/DeathScreen.java b/net/minecraft/client/gui/screens/DeathScreen.java index d2ce5413..4faafcf2 100644 --- a/net/minecraft/client/gui/screens/DeathScreen.java +++ b/net/minecraft/client/gui/screens/DeathScreen.java @@ -9,10 +9,10 @@ import net.minecraft.ChatFormatting; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.gui.components.Button; import net.minecraft.client.renderer.RenderType; +import net.minecraft.network.chat.ClickEvent; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Style; -import net.minecraft.network.chat.ClickEvent.Action; import net.minecraft.resources.ResourceLocation; import org.jetbrains.annotations.Nullable; @@ -151,7 +151,7 @@ public class DeathScreen extends Screen { public boolean mouseClicked(double mouseX, double mouseY, int button) { if (this.causeOfDeath != null && mouseY > 85.0 && mouseY < 85 + 9) { Style style = this.getClickedComponentStyleAt((int)mouseX); - if (style != null && style.getClickEvent() != null && style.getClickEvent().getAction() == Action.OPEN_URL) { + if (style != null && style.getClickEvent() != null && style.getClickEvent().action() == ClickEvent.Action.OPEN_URL) { this.handleComponentClicked(style); return false; } diff --git a/net/minecraft/client/gui/screens/EditServerScreen.java b/net/minecraft/client/gui/screens/EditServerScreen.java index f131403e..e188377f 100644 --- a/net/minecraft/client/gui/screens/EditServerScreen.java +++ b/net/minecraft/client/gui/screens/EditServerScreen.java @@ -9,7 +9,6 @@ import net.minecraft.client.gui.components.Button; import net.minecraft.client.gui.components.CycleButton; import net.minecraft.client.gui.components.EditBox; import net.minecraft.client.multiplayer.ServerData; -import net.minecraft.client.multiplayer.ServerData.ServerPackStatus; import net.minecraft.client.multiplayer.resolver.ServerAddress; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; @@ -44,8 +43,8 @@ public class EditServerScreen extends Screen { this.ipEdit.setResponder(string -> this.updateAddButtonStatus()); this.addWidget(this.ipEdit); this.addRenderableWidget( - CycleButton.builder(ServerPackStatus::getName) - .withValues(ServerPackStatus.values()) + CycleButton.builder(ServerData.ServerPackStatus::getName) + .withValues(ServerData.ServerPackStatus.values()) .withInitialValue(this.serverData.getResourcePackStatus()) .create( this.width / 2 - 100, diff --git a/net/minecraft/client/gui/screens/FaviconTexture.java b/net/minecraft/client/gui/screens/FaviconTexture.java index e5bd3353..00582f3a 100644 --- a/net/minecraft/client/gui/screens/FaviconTexture.java +++ b/net/minecraft/client/gui/screens/FaviconTexture.java @@ -44,7 +44,7 @@ public class FaviconTexture implements AutoCloseable { try { this.checkOpen(); if (this.texture == null) { - this.texture = new DynamicTexture(image); + this.texture = new DynamicTexture(() -> "Favicon " + this.textureLocation, image); } else { this.texture.setPixels(image); this.texture.upload(); diff --git a/net/minecraft/client/gui/screens/LoadingOverlay.java b/net/minecraft/client/gui/screens/LoadingOverlay.java index c4f22cbd..16d78a24 100644 --- a/net/minecraft/client/gui/screens/LoadingOverlay.java +++ b/net/minecraft/client/gui/screens/LoadingOverlay.java @@ -1,7 +1,7 @@ package net.minecraft.client.gui.screens; -import com.mojang.blaze3d.platform.GlStateManager; import com.mojang.blaze3d.platform.NativeImage; +import com.mojang.blaze3d.systems.RenderSystem; import java.io.IOException; import java.io.InputStream; import java.util.Optional; @@ -93,28 +93,24 @@ public class LoadingOverlay extends Overlay { h = Mth.clamp(g, 0.0F, 1.0F); } else { int k = BRAND_BACKGROUND.getAsInt(); - float m = (k >> 16 & 0xFF) / 255.0F; - float n = (k >> 8 & 0xFF) / 255.0F; - float o = (k & 0xFF) / 255.0F; - GlStateManager._clearColor(m, n, o, 1.0F); - GlStateManager._clear(16384); + RenderSystem.getDevice().createCommandEncoder().clearColorTexture(this.minecraft.getMainRenderTarget().getColorTexture(), k); h = 1.0F; } int k = (int)(guiGraphics.guiWidth() * 0.5); - int p = (int)(guiGraphics.guiHeight() * 0.5); + int m = (int)(guiGraphics.guiHeight() * 0.5); double d = Math.min(guiGraphics.guiWidth() * 0.75, guiGraphics.guiHeight()) * 0.25; - int q = (int)(d * 0.5); + int n = (int)(d * 0.5); double e = d * 4.0; - int r = (int)(e * 0.5); - int s = ARGB.white(h); - guiGraphics.blit(resourceLocation -> RenderType.mojangLogo(), MOJANG_STUDIOS_LOGO_LOCATION, k - r, p - q, -0.0625F, 0.0F, r, (int)d, 120, 60, 120, 120, s); - guiGraphics.blit(resourceLocation -> RenderType.mojangLogo(), MOJANG_STUDIOS_LOGO_LOCATION, k, p - q, 0.0625F, 60.0F, r, (int)d, 120, 60, 120, 120, s); - int t = (int)(guiGraphics.guiHeight() * 0.8325); - float u = this.reload.getActualProgress(); - this.currentProgress = Mth.clamp(this.currentProgress * 0.95F + u * 0.050000012F, 0.0F, 1.0F); + int o = (int)(e * 0.5); + int p = ARGB.white(h); + guiGraphics.blit(resourceLocation -> RenderType.mojangLogo(), MOJANG_STUDIOS_LOGO_LOCATION, k - o, m - n, -0.0625F, 0.0F, o, (int)d, 120, 60, 120, 120, p); + guiGraphics.blit(resourceLocation -> RenderType.mojangLogo(), MOJANG_STUDIOS_LOGO_LOCATION, k, m - n, 0.0625F, 60.0F, o, (int)d, 120, 60, 120, 120, p); + int q = (int)(guiGraphics.guiHeight() * 0.8325); + float r = this.reload.getActualProgress(); + this.currentProgress = Mth.clamp(this.currentProgress * 0.95F + r * 0.050000012F, 0.0F, 1.0F); if (f < 1.0F) { - this.drawProgressBar(guiGraphics, i / 2 - r, t - 5, i / 2 + r, t + 5, 1.0F - Mth.clamp(f, 0.0F, 1.0F)); + this.drawProgressBar(guiGraphics, i / 2 - o, q - 5, i / 2 + o, q + 5, 1.0F - Mth.clamp(f, 0.0F, 1.0F)); } if (f >= 2.0F) { diff --git a/net/minecraft/client/gui/screens/RecoverWorldDataScreen.java b/net/minecraft/client/gui/screens/RecoverWorldDataScreen.java index 204d8bdf..ae225881 100644 --- a/net/minecraft/client/gui/screens/RecoverWorldDataScreen.java +++ b/net/minecraft/client/gui/screens/RecoverWorldDataScreen.java @@ -23,7 +23,7 @@ import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.MutableComponent; import net.minecraft.util.CommonLinks; -import net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess; +import net.minecraft.world.level.storage.LevelStorageSource; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -45,9 +45,9 @@ public class RecoverWorldDataScreen extends Screen { private final Component message; private final MultiLineTextWidget messageWidget; private final MultiLineTextWidget issuesWidget; - private final LevelStorageAccess storageAccess; + private final LevelStorageSource.LevelStorageAccess storageAccess; - public RecoverWorldDataScreen(Minecraft minecraft, BooleanConsumer callback, LevelStorageAccess storageAccess) { + public RecoverWorldDataScreen(Minecraft minecraft, BooleanConsumer callback, LevelStorageSource.LevelStorageAccess storageAccess) { super(TITLE); this.callback = callback; this.message = Component.translatable("recover_world.message", Component.literal(storageAccess.getLevelId()).withStyle(ChatFormatting.GRAY)); @@ -97,7 +97,7 @@ public class RecoverWorldDataScreen extends Screen { } } - private Component buildInfo(LevelStorageAccess level, boolean useFallback, @Nullable Exception exception) { + private Component buildInfo(LevelStorageSource.LevelStorageAccess level, boolean useFallback, @Nullable Exception exception) { if (useFallback && exception instanceof FileNotFoundException) { return Component.empty(); } else { @@ -122,7 +122,7 @@ public class RecoverWorldDataScreen extends Screen { } @Nullable - private Exception collectIssue(LevelStorageAccess level, boolean useFallback) { + private Exception collectIssue(LevelStorageSource.LevelStorageAccess level, boolean useFallback) { try { if (!useFallback) { level.getSummary(level.getDataTag()); diff --git a/net/minecraft/client/gui/screens/Screen.java b/net/minecraft/client/gui/screens/Screen.java index d8054e15..756de07d 100644 --- a/net/minecraft/client/gui/screens/Screen.java +++ b/net/minecraft/client/gui/screens/Screen.java @@ -4,9 +4,7 @@ import com.google.common.annotations.VisibleForTesting; import com.google.common.collect.Lists; import com.mojang.blaze3d.platform.InputConstants; import com.mojang.logging.LogUtils; -import java.io.File; import java.net.URI; -import java.net.URISyntaxException; import java.nio.file.Path; import java.util.Comparator; import java.util.List; @@ -33,6 +31,7 @@ import net.minecraft.client.gui.narration.NarratableEntry; import net.minecraft.client.gui.narration.NarratedElementType; import net.minecraft.client.gui.narration.NarrationElementOutput; import net.minecraft.client.gui.narration.ScreenNarrationCollector; +import net.minecraft.client.gui.narration.NarratableEntry.NarrationPriority; import net.minecraft.client.gui.navigation.FocusNavigationEvent; import net.minecraft.client.gui.navigation.ScreenDirection; import net.minecraft.client.gui.navigation.ScreenRectangle; @@ -47,11 +46,9 @@ import net.minecraft.client.renderer.RenderType; import net.minecraft.network.chat.ClickEvent; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Style; -import net.minecraft.network.chat.ClickEvent.Action; import net.minecraft.resources.ResourceLocation; import net.minecraft.sounds.Music; import net.minecraft.util.FormattedCharSequence; -import net.minecraft.util.StringUtil; import net.minecraft.world.item.Item; import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.TooltipFlag.Default; @@ -261,44 +258,47 @@ public abstract class Screen extends AbstractContainerEventHandler implements Re this.insertText(style.getInsertion(), false); } } else if (clickEvent != null) { - if (clickEvent.getAction() == Action.OPEN_URL) { - if (!this.minecraft.options.chatLinks().get()) { - return false; - } + switch (clickEvent) { + case ClickEvent.OpenUrl(URI var28): + URI var19 = var28; + if (!this.minecraft.options.chatLinks().get()) { + return false; + } - try { - URI uRI = Util.parseAndValidateUntrustedUri(clickEvent.getValue()); if (this.minecraft.options.chatLinksPrompt().get()) { this.minecraft.setScreen(new ConfirmLinkScreen(bl -> { if (bl) { - Util.getPlatform().openUri(uRI); + Util.getPlatform().openUri(var19); } this.minecraft.setScreen(this); - }, clickEvent.getValue(), false)); + }, var19.toString(), false)); } else { - Util.getPlatform().openUri(uRI); + Util.getPlatform().openUri(var19); } - } catch (URISyntaxException var4) { - LOGGER.error("Can't open url for {}", clickEvent, var4); - } - } else if (clickEvent.getAction() == Action.OPEN_FILE) { - Util.getPlatform().openFile(new File(clickEvent.getValue())); - } else if (clickEvent.getAction() == Action.SUGGEST_COMMAND) { - this.insertText(StringUtil.filterText(clickEvent.getValue()), true); - } else if (clickEvent.getAction() == Action.RUN_COMMAND) { - String string = StringUtil.filterText(clickEvent.getValue()); - if (string.startsWith("/")) { - if (!this.minecraft.player.connection.sendUnsignedCommand(string.substring(1))) { - LOGGER.error("Not allowed to run command with signed argument from click event: '{}'", string); + break; + case ClickEvent.OpenFile openFile: + Util.getPlatform().openFile(openFile.file()); + break; + case ClickEvent.SuggestCommand(String var20): + this.insertText(var20, true); + break; + case ClickEvent.RunCommand(String var24): + String var21 = var24; + String string2 = var21; + if (var21.startsWith("/")) { + string2 = var21.substring(1); } - } else { - LOGGER.error("Failed to run command without '/' prefix from click event: '{}'", string); - } - } else if (clickEvent.getAction() == Action.COPY_TO_CLIPBOARD) { - this.minecraft.keyboardHandler.setClipboard(clickEvent.getValue()); - } else { - LOGGER.error("Don't know how to handle {}", clickEvent); + + if (!this.minecraft.player.connection.sendUnsignedCommand(string2)) { + LOGGER.error("Not allowed to run command with signed argument from click event: '{}'", string2); + } + break; + case ClickEvent.CopyToClipboard(String var14): + this.minecraft.keyboardHandler.setClipboard(var14); + break; + default: + LOGGER.error("Don't know how to handle {}", clickEvent); } return true; @@ -360,7 +360,6 @@ public abstract class Screen extends AbstractContainerEventHandler implements Re protected void renderBlurredBackground() { this.minecraft.gameRenderer.processBlurEffect(); - this.minecraft.getMainRenderTarget().bindWrite(false); } protected void renderPanorama(GuiGraphics guiGraphics, float partialTick) { @@ -538,7 +537,7 @@ public abstract class Screen extends AbstractContainerEventHandler implements Re if (list.size() > 1) { narrationElementOutput.add(NarratedElementType.POSITION, Component.translatable("narrator.position.screen", narratableSearchResult.index + 1, list.size())); - if (narratableSearchResult.priority == NarratableEntry.NarrationPriority.FOCUSED) { + if (narratableSearchResult.priority == NarrationPriority.FOCUSED) { narrationElementOutput.add(NarratedElementType.USAGE, this.getUsageNarration()); } } @@ -559,14 +558,14 @@ public abstract class Screen extends AbstractContainerEventHandler implements Re for (int j = entries.size(); i < j; i++) { NarratableEntry narratableEntry = (NarratableEntry)entries.get(i); - NarratableEntry.NarrationPriority narrationPriority = narratableEntry.narrationPriority(); + NarrationPriority narrationPriority = narratableEntry.narrationPriority(); if (narrationPriority.isTerminal()) { if (narratableEntry != target) { return new Screen.NarratableSearchResult(narratableEntry, i, narrationPriority); } narratableSearchResult2 = new Screen.NarratableSearchResult(narratableEntry, i, narrationPriority); - } else if (narrationPriority.compareTo(narratableSearchResult != null ? narratableSearchResult.priority : NarratableEntry.NarrationPriority.NONE) > 0) { + } else if (narrationPriority.compareTo(narratableSearchResult != null ? narratableSearchResult.priority : NarrationPriority.NONE) > 0) { narratableSearchResult = new Screen.NarratableSearchResult(narratableEntry, i, narrationPriority); } } @@ -632,9 +631,9 @@ public abstract class Screen extends AbstractContainerEventHandler implements Re public static class NarratableSearchResult { public final NarratableEntry entry; public final int index; - public final NarratableEntry.NarrationPriority priority; + public final NarrationPriority priority; - public NarratableSearchResult(NarratableEntry entry, int index, NarratableEntry.NarrationPriority priority) { + public NarratableSearchResult(NarratableEntry entry, int index, NarrationPriority priority) { this.entry = entry; this.index = index; this.priority = priority; diff --git a/net/minecraft/client/gui/screens/TitleScreen.java b/net/minecraft/client/gui/screens/TitleScreen.java index 8265a591..384761ea 100644 --- a/net/minecraft/client/gui/screens/TitleScreen.java +++ b/net/minecraft/client/gui/screens/TitleScreen.java @@ -39,7 +39,6 @@ import net.minecraft.util.Mth; import net.minecraft.world.level.levelgen.WorldOptions; import net.minecraft.world.level.levelgen.presets.WorldPresets; import net.minecraft.world.level.storage.LevelStorageSource; -import net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -234,7 +233,7 @@ public class TitleScreen extends Screen { button -> { LevelStorageSource levelStorageSource = this.minecraft.getLevelSource(); - try (LevelStorageAccess levelStorageAccess = levelStorageSource.createAccess("Demo_World")) { + try (LevelStorageSource.LevelStorageAccess levelStorageAccess = levelStorageSource.createAccess("Demo_World")) { if (levelStorageAccess.hasWorldData()) { this.minecraft .setScreen( @@ -263,7 +262,7 @@ public class TitleScreen extends Screen { private boolean checkDemoWorldPresence() { try { boolean var2; - try (LevelStorageAccess levelStorageAccess = this.minecraft.getLevelSource().createAccess("Demo_World")) { + try (LevelStorageSource.LevelStorageAccess levelStorageAccess = this.minecraft.getLevelSource().createAccess("Demo_World")) { var2 = levelStorageAccess.hasWorldData(); } @@ -364,7 +363,7 @@ public class TitleScreen extends Screen { private void confirmDemo(boolean confirmed) { if (confirmed) { - try (LevelStorageAccess levelStorageAccess = this.minecraft.getLevelSource().createAccess("Demo_World")) { + try (LevelStorageSource.LevelStorageAccess levelStorageAccess = this.minecraft.getLevelSource().createAccess("Demo_World")) { levelStorageAccess.deleteLevel(); } catch (IOException var7) { SystemToast.onWorldDeleteFailure(this.minecraft, "Demo_World"); diff --git a/net/minecraft/client/gui/screens/advancements/AdvancementTab.java b/net/minecraft/client/gui/screens/advancements/AdvancementTab.java index 10f67c0e..2793032e 100644 --- a/net/minecraft/client/gui/screens/advancements/AdvancementTab.java +++ b/net/minecraft/client/gui/screens/advancements/AdvancementTab.java @@ -12,6 +12,7 @@ import net.minecraft.client.Minecraft; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.texture.TextureManager; +import net.minecraft.core.ClientAsset; import net.minecraft.network.chat.Component; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.Mth; @@ -90,7 +91,10 @@ public class AdvancementTab { guiGraphics.enableScissor(x, y, x + 234, y + 113); guiGraphics.pose().pushPose(); guiGraphics.pose().translate((float)x, (float)y, 0.0F); - ResourceLocation resourceLocation = (ResourceLocation)this.display.getBackground().orElse(TextureManager.INTENTIONAL_MISSING_TEXTURE); + ResourceLocation resourceLocation = (ResourceLocation)this.display + .getBackground() + .map(ClientAsset::texturePath) + .orElse(TextureManager.INTENTIONAL_MISSING_TEXTURE); int i = Mth.floor(this.scrollX); int j = Mth.floor(this.scrollY); int k = i % 16; diff --git a/net/minecraft/client/gui/screens/advancements/AdvancementsScreen.java b/net/minecraft/client/gui/screens/advancements/AdvancementsScreen.java index 662d647a..debfbae4 100644 --- a/net/minecraft/client/gui/screens/advancements/AdvancementsScreen.java +++ b/net/minecraft/client/gui/screens/advancements/AdvancementsScreen.java @@ -14,7 +14,6 @@ import net.minecraft.client.gui.layouts.HeaderAndFooterLayout; import net.minecraft.client.gui.screens.Screen; import net.minecraft.client.multiplayer.ClientAdvancements; import net.minecraft.client.multiplayer.ClientPacketListener; -import net.minecraft.client.multiplayer.ClientAdvancements.Listener; import net.minecraft.client.renderer.RenderType; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; @@ -23,7 +22,7 @@ import net.minecraft.resources.ResourceLocation; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) -public class AdvancementsScreen extends Screen implements Listener { +public class AdvancementsScreen extends Screen implements ClientAdvancements.Listener { private static final ResourceLocation WINDOW_LOCATION = ResourceLocation.withDefaultNamespace("textures/gui/advancements/window.png"); public static final int WINDOW_WIDTH = 252; public static final int WINDOW_HEIGHT = 140; diff --git a/net/minecraft/client/gui/screens/inventory/AbstractContainerScreen.java b/net/minecraft/client/gui/screens/inventory/AbstractContainerScreen.java index 861166d9..1fc17150 100644 --- a/net/minecraft/client/gui/screens/inventory/AbstractContainerScreen.java +++ b/net/minecraft/client/gui/screens/inventory/AbstractContainerScreen.java @@ -354,7 +354,7 @@ public abstract class AbstractContainerScreen e if (super.mouseClicked(mouseX, mouseY, button)) { return true; } else { - boolean bl = this.minecraft.options.keyPickItem.matchesMouse(button) && this.minecraft.gameMode.hasInfiniteItems(); + boolean bl = this.minecraft.options.keyPickItem.matchesMouse(button) && this.minecraft.player.hasInfiniteMaterials(); Slot slot = this.getHoveredSlot(mouseX, mouseY); long l = Util.getMillis(); this.doubleclick = this.lastClickSlot == slot && l - this.lastClickTime < 250L && this.lastClickButton == button; diff --git a/net/minecraft/client/gui/screens/inventory/AnvilScreen.java b/net/minecraft/client/gui/screens/inventory/AnvilScreen.java index 7ba548a1..63741e4c 100644 --- a/net/minecraft/client/gui/screens/inventory/AnvilScreen.java +++ b/net/minecraft/client/gui/screens/inventory/AnvilScreen.java @@ -91,7 +91,7 @@ public class AnvilScreen extends ItemCombinerScreen { if (i > 0) { int j = 8453920; Component component; - if (i >= 40 && !this.minecraft.player.getAbilities().instabuild) { + if (i >= 40 && !this.minecraft.player.hasInfiniteMaterials()) { component = TOO_EXPENSIVE_TEXT; j = 16736352; } else if (!this.menu.getSlot(2).hasItem()) { diff --git a/net/minecraft/client/gui/screens/inventory/BookEditScreen.java b/net/minecraft/client/gui/screens/inventory/BookEditScreen.java index bc2978d7..896cd072 100644 --- a/net/minecraft/client/gui/screens/inventory/BookEditScreen.java +++ b/net/minecraft/client/gui/screens/inventory/BookEditScreen.java @@ -216,7 +216,7 @@ public class BookEditScreen extends Screen { if (this.isModified) { this.eraseEmptyTrailingPages(); this.updateLocalCopy(); - int i = this.hand == InteractionHand.MAIN_HAND ? this.owner.getInventory().selected : 40; + int i = this.hand == InteractionHand.MAIN_HAND ? this.owner.getInventory().getSelectedSlot() : 40; this.minecraft.getConnection().send(new ServerboundEditBookPacket(i, this.pages, publish ? Optional.of(this.title.trim()) : Optional.empty())); } } diff --git a/net/minecraft/client/gui/screens/inventory/BookViewScreen.java b/net/minecraft/client/gui/screens/inventory/BookViewScreen.java index a0c10799..b59155b3 100644 --- a/net/minecraft/client/gui/screens/inventory/BookViewScreen.java +++ b/net/minecraft/client/gui/screens/inventory/BookViewScreen.java @@ -16,7 +16,6 @@ import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.FormattedText; import net.minecraft.network.chat.Style; -import net.minecraft.network.chat.ClickEvent.Action; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.FormattedCharSequence; import net.minecraft.util.Mth; @@ -213,18 +212,11 @@ public class BookViewScreen extends Screen { ClickEvent clickEvent = style.getClickEvent(); if (clickEvent == null) { return false; - } else if (clickEvent.getAction() == Action.CHANGE_PAGE) { - String string = clickEvent.getValue(); - - try { - int i = Integer.parseInt(string) - 1; - return this.forcePage(i); - } catch (Exception var5) { - return false; - } + } else if (clickEvent instanceof ClickEvent.ChangePage(int var5)) { + return this.forcePage(var5 - 1); } else { boolean bl = super.handleComponentClicked(style); - if (bl && clickEvent.getAction() == Action.RUN_COMMAND) { + if (bl && clickEvent.action() == ClickEvent.Action.RUN_COMMAND) { this.closeScreen(); } diff --git a/net/minecraft/client/gui/screens/inventory/CreativeModeInventoryScreen.java b/net/minecraft/client/gui/screens/inventory/CreativeModeInventoryScreen.java index ad16d9d1..1573ae63 100644 --- a/net/minecraft/client/gui/screens/inventory/CreativeModeInventoryScreen.java +++ b/net/minecraft/client/gui/screens/inventory/CreativeModeInventoryScreen.java @@ -23,9 +23,9 @@ import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.player.inventory.Hotbar; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.searchtree.SearchTree; +import net.minecraft.core.HolderLookup; import net.minecraft.core.NonNullList; import net.minecraft.core.RegistryAccess; -import net.minecraft.core.HolderLookup.Provider; import net.minecraft.core.HolderSet.Named; import net.minecraft.core.component.DataComponents; import net.minecraft.core.registries.BuiltInRegistries; @@ -141,7 +141,7 @@ public class CreativeModeInventoryScreen extends AbstractContainerScreen list = stack.getTooltipLines(Item.TooltipContext.of(this.minecraft.level), this.minecraft.player, tooltipFlag); - if (bl2 && bl) { + if (list.isEmpty()) { + return list; + } else if (bl2 && bl) { return list; } else { List list2 = Lists.newArrayList(list); diff --git a/net/minecraft/client/gui/screens/inventory/EnchantmentScreen.java b/net/minecraft/client/gui/screens/inventory/EnchantmentScreen.java index 97095f83..2d4ac5c5 100644 --- a/net/minecraft/client/gui/screens/inventory/EnchantmentScreen.java +++ b/net/minecraft/client/gui/screens/inventory/EnchantmentScreen.java @@ -122,7 +122,7 @@ public class EnchantmentScreen extends AbstractContainerScreen int p = 86 - this.font.width(string); FormattedText formattedText = EnchantmentNames.getInstance().getRandomName(this.font, p); int q = 6839882; - if ((k < l + 1 || this.minecraft.player.experienceLevel < o) && !this.minecraft.player.getAbilities().instabuild) { + if ((k < l + 1 || this.minecraft.player.experienceLevel < o) && !this.minecraft.player.hasInfiniteMaterials()) { guiGraphics.blitSprite(RenderType::guiTextured, ENCHANTMENT_SLOT_DISABLED_SPRITE, m, j + 14 + 19 * l, 108, 19); guiGraphics.blitSprite(RenderType::guiTextured, DISABLED_LEVEL_SPRITES[l], m + 1, j + 15 + 19 * l, 16, 16); guiGraphics.drawWordWrap(this.font, formattedText, n, j + 16 + 19 * l, p, (q & 16711422) >> 1, false); @@ -178,7 +178,7 @@ public class EnchantmentScreen extends AbstractContainerScreen float f = this.minecraft.getDeltaTracker().getGameTimeDeltaPartialTick(false); super.render(guiGraphics, mouseX, mouseY, f); this.renderTooltip(guiGraphics, mouseX, mouseY); - boolean bl = this.minecraft.player.getAbilities().instabuild; + boolean bl = this.minecraft.player.hasInfiniteMaterials(); int i = this.menu.getGoldCount(); for (int j = 0; j < 3; j++) { diff --git a/net/minecraft/client/gui/screens/inventory/HorseInventoryScreen.java b/net/minecraft/client/gui/screens/inventory/HorseInventoryScreen.java index 58956aea..c51f5107 100644 --- a/net/minecraft/client/gui/screens/inventory/HorseInventoryScreen.java +++ b/net/minecraft/client/gui/screens/inventory/HorseInventoryScreen.java @@ -5,8 +5,10 @@ import net.fabricmc.api.Environment; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.renderer.RenderType; import net.minecraft.resources.ResourceLocation; +import net.minecraft.tags.EntityTypeTags; import net.minecraft.world.entity.EquipmentSlot; import net.minecraft.world.entity.animal.horse.AbstractHorse; +import net.minecraft.world.entity.animal.horse.Llama; import net.minecraft.world.entity.player.Inventory; import net.minecraft.world.inventory.HorseInventoryMenu; @@ -44,11 +46,12 @@ public class HorseInventoryScreen extends AbstractContainerScreen { @Override public void containerTick() { super.containerTick(); - if (this.minecraft.gameMode.hasInfiniteItems()) { + if (this.minecraft.player.hasInfiniteMaterials()) { this.minecraft .setScreen( new CreativeModeInventoryScreen(this.minecraft.player, this.minecraft.player.connection.enabledFeatures(), this.minecraft.options.operatorItemsTab().get()) @@ -49,7 +49,7 @@ public class InventoryScreen extends AbstractRecipeBookScreen { @Override protected void init() { - if (this.minecraft.gameMode.hasInfiniteItems()) { + if (this.minecraft.player.hasInfiniteMaterials()) { this.minecraft .setScreen( new CreativeModeInventoryScreen(this.minecraft.player, this.minecraft.player.connection.enabledFeatures(), this.minecraft.options.operatorItemsTab().get()) diff --git a/net/minecraft/client/gui/screens/inventory/LoomScreen.java b/net/minecraft/client/gui/screens/inventory/LoomScreen.java index 3b30472f..4984fa8f 100644 --- a/net/minecraft/client/gui/screens/inventory/LoomScreen.java +++ b/net/minecraft/client/gui/screens/inventory/LoomScreen.java @@ -28,7 +28,6 @@ import net.minecraft.world.item.DyeColor; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.block.entity.BannerPattern; import net.minecraft.world.level.block.entity.BannerPatternLayers; -import net.minecraft.world.level.block.entity.BannerPatternLayers.Builder; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) @@ -174,7 +173,7 @@ public class LoomScreen extends AbstractContainerScreen { poseStack.translate(0.5F, 0.5F, 0.5F); float f = 0.6666667F; poseStack.scale(0.6666667F, -0.6666667F, -0.6666667F); - BannerPatternLayers bannerPatternLayers = new Builder().add(patern, DyeColor.WHITE).build(); + BannerPatternLayers bannerPatternLayers = new BannerPatternLayers.Builder().add(patern, DyeColor.WHITE).build(); guiGraphics.drawSpecial( multiBufferSource -> BannerRenderer.renderPatterns( poseStack, multiBufferSource, 15728880, OverlayTexture.NO_OVERLAY, this.flag, ModelBakery.BANNER_BASE, true, DyeColor.GRAY, bannerPatternLayers diff --git a/net/minecraft/client/gui/screens/inventory/MerchantScreen.java b/net/minecraft/client/gui/screens/inventory/MerchantScreen.java index 46b3d2af..3fd34aef 100644 --- a/net/minecraft/client/gui/screens/inventory/MerchantScreen.java +++ b/net/minecraft/client/gui/screens/inventory/MerchantScreen.java @@ -4,6 +4,7 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.gui.components.Button; +import net.minecraft.client.gui.components.Button.OnPress; import net.minecraft.client.renderer.RenderType; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; @@ -296,7 +297,7 @@ public class MerchantScreen extends AbstractContainerScreen { class TradeOfferButton extends Button { final int index; - public TradeOfferButton(final int x, final int y, final int index, final Button.OnPress onPress) { + public TradeOfferButton(final int x, final int y, final int index, final OnPress onPress) { super(x, y, 88, 20, CommonComponents.EMPTY, onPress, DEFAULT_NARRATION); this.index = index; this.visible = false; diff --git a/net/minecraft/client/gui/screens/inventory/StructureBlockEditScreen.java b/net/minecraft/client/gui/screens/inventory/StructureBlockEditScreen.java index 43a3558c..edf270ec 100644 --- a/net/minecraft/client/gui/screens/inventory/StructureBlockEditScreen.java +++ b/net/minecraft/client/gui/screens/inventory/StructureBlockEditScreen.java @@ -31,6 +31,7 @@ public class StructureBlockEditScreen extends Screen { private static final Component INTEGRITY_LABEL = Component.translatable("structure_block.integrity"); private static final Component CUSTOM_DATA_LABEL = Component.translatable("structure_block.custom_data"); private static final Component INCLUDE_ENTITIES_LABEL = Component.translatable("structure_block.include_entities"); + private static final Component STRICT_LABEL = Component.translatable("structure_block.strict"); private static final Component DETECT_SIZE_LABEL = Component.translatable("structure_block.detect_size"); private static final Component SHOW_AIR_LABEL = Component.translatable("structure_block.show_air"); private static final Component SHOW_BOUNDING_BOX_LABEL = Component.translatable("structure_block.show_boundingbox"); @@ -43,6 +44,7 @@ public class StructureBlockEditScreen extends Screen { private Rotation initialRotation = Rotation.NONE; private StructureMode initialMode = StructureMode.DATA; private boolean initialEntityIgnoring; + private boolean initialStrict; private boolean initialShowAir; private boolean initialShowBoundingBox; private EditBox nameEdit; @@ -63,6 +65,7 @@ public class StructureBlockEditScreen extends Screen { private Button rot270Button; private Button detectButton; private CycleButton includeEntitiesButton; + private CycleButton strictButton; private CycleButton mirrorButton; private CycleButton toggleAirButton; private CycleButton toggleBoundingBox; @@ -85,6 +88,7 @@ public class StructureBlockEditScreen extends Screen { this.structure.setRotation(this.initialRotation); this.structure.setMode(this.initialMode); this.structure.setIgnoreEntities(this.initialEntityIgnoring); + this.structure.setStrict(this.initialStrict); this.structure.setShowAir(this.initialShowAir); this.structure.setShowBoundingBox(this.initialShowBoundingBox); this.minecraft.setScreen(null); @@ -98,6 +102,7 @@ public class StructureBlockEditScreen extends Screen { this.initialRotation = this.structure.getRotation(); this.initialMode = this.structure.getMode(); this.initialEntityIgnoring = this.structure.isIgnoreEntities(); + this.initialStrict = this.structure.isStrict(); this.initialShowAir = this.structure.getShowAir(); this.initialShowBoundingBox = this.structure.getShowBoundingBox(); this.saveButton = this.addRenderableWidget(Button.builder(Component.translatable("structure_block.button.save"), button -> { @@ -133,6 +138,11 @@ public class StructureBlockEditScreen extends Screen { .displayOnlyValue() .create(this.width / 2 + 4 + 100, 160, 50, 20, INCLUDE_ENTITIES_LABEL, (cycleButton, boolean_) -> this.structure.setIgnoreEntities(!boolean_)) ); + this.strictButton = this.addRenderableWidget( + CycleButton.onOffBuilder(this.structure.isStrict()) + .displayOnlyValue() + .create(this.width / 2 + 4 + 100, 120, 50, 20, STRICT_LABEL, (cycleButton, boolean_) -> this.structure.setStrict(boolean_)) + ); this.mirrorButton = this.addRenderableWidget( CycleButton.builder(Mirror::symbol) .withValues(Mirror.values()) @@ -289,6 +299,7 @@ public class StructureBlockEditScreen extends Screen { this.loadButton.visible = false; this.detectButton.visible = false; this.includeEntitiesButton.visible = false; + this.strictButton.visible = false; this.mirrorButton.visible = false; this.rot0Button.visible = false; this.rot90Button.visible = false; @@ -308,6 +319,7 @@ public class StructureBlockEditScreen extends Screen { this.saveButton.visible = true; this.detectButton.visible = true; this.includeEntitiesButton.visible = true; + this.strictButton.visible = false; this.toggleAirButton.visible = true; break; case LOAD: @@ -319,6 +331,7 @@ public class StructureBlockEditScreen extends Screen { this.seedEdit.setVisible(true); this.loadButton.visible = true; this.includeEntitiesButton.visible = true; + this.strictButton.visible = true; this.mirrorButton.visible = true; this.rot0Button.visible = true; this.rot90Button.visible = true; @@ -358,6 +371,7 @@ public class StructureBlockEditScreen extends Screen { this.structure.getRotation(), this.dataEdit.getValue(), this.structure.isIgnoreEntities(), + this.structure.isStrict(), this.structure.getShowAir(), this.structure.getShowBoundingBox(), f, @@ -439,6 +453,7 @@ public class StructureBlockEditScreen extends Screen { guiGraphics.drawString(this.font, INTEGRITY_LABEL, this.width / 2 - 153, 110, 10526880); this.integrityEdit.render(guiGraphics, mouseX, mouseY, partialTick); this.seedEdit.render(guiGraphics, mouseX, mouseY, partialTick); + guiGraphics.drawString(this.font, STRICT_LABEL, this.width / 2 + 154 - this.font.width(STRICT_LABEL), 110, 10526880); guiGraphics.drawString(this.font, SHOW_BOUNDING_BOX_LABEL, this.width / 2 + 154 - this.font.width(SHOW_BOUNDING_BOX_LABEL), 70, 10526880); } diff --git a/net/minecraft/client/gui/screens/inventory/TestBlockEditScreen.java b/net/minecraft/client/gui/screens/inventory/TestBlockEditScreen.java new file mode 100644 index 00000000..3536a6b1 --- /dev/null +++ b/net/minecraft/client/gui/screens/inventory/TestBlockEditScreen.java @@ -0,0 +1,97 @@ +package net.minecraft.client.gui.screens.inventory; + +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.gui.components.Button; +import net.minecraft.client.gui.components.CycleButton; +import net.minecraft.client.gui.components.EditBox; +import net.minecraft.client.gui.screens.Screen; +import net.minecraft.core.BlockPos; +import net.minecraft.network.chat.CommonComponents; +import net.minecraft.network.chat.Component; +import net.minecraft.network.protocol.game.ServerboundSetTestBlockPacket; +import net.minecraft.world.level.block.Blocks; +import net.minecraft.world.level.block.entity.TestBlockEntity; +import net.minecraft.world.level.block.state.properties.TestBlockMode; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public class TestBlockEditScreen extends Screen { + private static final List MODES = List.of(TestBlockMode.values()); + private static final Component TITLE = Component.translatable(Blocks.TEST_BLOCK.getDescriptionId()); + private static final Component MESSAGE_LABEL = Component.translatable("test_block.message"); + private final BlockPos position; + private TestBlockMode mode; + private String message; + @Nullable + private EditBox messageEdit; + + public TestBlockEditScreen(TestBlockEntity blockEntity) { + super(TITLE); + this.position = blockEntity.getBlockPos(); + this.mode = blockEntity.getMode(); + this.message = blockEntity.getMessage(); + } + + @Override + public void init() { + this.messageEdit = new EditBox(this.font, this.width / 2 - 152, 80, 240, 20, Component.translatable("test_block.message")); + this.messageEdit.setMaxLength(128); + this.messageEdit.setValue(this.message); + this.addRenderableWidget(this.messageEdit); + this.setInitialFocus(this.messageEdit); + this.updateMode(this.mode); + this.addRenderableWidget( + CycleButton.builder(TestBlockMode::getDisplayName) + .withValues(MODES) + .displayOnlyValue() + .withInitialValue(this.mode) + .create(this.width / 2 - 4 - 150, 185, 50, 20, TITLE, (cycleButton, testBlockMode) -> this.updateMode(testBlockMode)) + ); + this.addRenderableWidget(Button.builder(CommonComponents.GUI_DONE, button -> this.onDone()).bounds(this.width / 2 - 4 - 150, 210, 150, 20).build()); + this.addRenderableWidget(Button.builder(CommonComponents.GUI_CANCEL, button -> this.onCancel()).bounds(this.width / 2 + 4, 210, 150, 20).build()); + } + + @Override + public void render(GuiGraphics guiGraphics, int mouseX, int mouseY, float partialTick) { + super.render(guiGraphics, mouseX, mouseY, partialTick); + guiGraphics.drawCenteredString(this.font, this.title, this.width / 2, 10, 16777215); + if (this.mode != TestBlockMode.START) { + guiGraphics.drawString(this.font, MESSAGE_LABEL, this.width / 2 - 153, 70, 10526880); + } + + guiGraphics.drawString(this.font, this.mode.getDetailedMessage(), this.width / 2 - 153, 174, 10526880); + } + + @Override + public boolean isPauseScreen() { + return false; + } + + private void onDone() { + this.message = this.messageEdit.getValue(); + this.minecraft.getConnection().send(new ServerboundSetTestBlockPacket(this.position, this.mode, this.message)); + this.onClose(); + } + + @Override + public void onClose() { + this.onCancel(); + } + + private void onCancel() { + this.minecraft.setScreen(null); + } + + private void updateMode(TestBlockMode mode) { + this.mode = mode; + this.messageEdit.visible = mode != TestBlockMode.START; + } + + @Override + public void renderBackground(GuiGraphics guiGraphics, int mouseX, int mouseY, float partialTick) { + this.renderTransparentBackground(guiGraphics); + } +} diff --git a/net/minecraft/client/gui/screens/inventory/TestInstanceBlockEditScreen.java b/net/minecraft/client/gui/screens/inventory/TestInstanceBlockEditScreen.java new file mode 100644 index 00000000..abfff3f4 --- /dev/null +++ b/net/minecraft/client/gui/screens/inventory/TestInstanceBlockEditScreen.java @@ -0,0 +1,229 @@ +package net.minecraft.client.gui.screens.inventory; + +import java.util.Optional; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.ChatFormatting; +import net.minecraft.SharedConstants; +import net.minecraft.client.gui.GuiGraphics; +import net.minecraft.client.gui.components.Button; +import net.minecraft.client.gui.components.CycleButton; +import net.minecraft.client.gui.components.EditBox; +import net.minecraft.client.gui.components.FittingMultiLineTextWidget; +import net.minecraft.client.gui.screens.Screen; +import net.minecraft.core.Vec3i; +import net.minecraft.core.registries.Registries; +import net.minecraft.gametest.framework.GameTestInstance; +import net.minecraft.network.chat.CommonComponents; +import net.minecraft.network.chat.Component; +import net.minecraft.network.chat.MutableComponent; +import net.minecraft.network.protocol.game.ServerboundTestInstanceBlockActionPacket; +import net.minecraft.resources.ResourceKey; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.util.Mth; +import net.minecraft.world.level.block.Rotation; +import net.minecraft.world.level.block.entity.TestInstanceBlockEntity; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public class TestInstanceBlockEditScreen extends Screen { + private static final Component ID_LABEL = Component.translatable("test_instance_block.test_id"); + private static final Component SIZE_LABEL = Component.translatable("test_instance_block.size"); + private static final Component INCLUDE_ENTITIES_LABEL = Component.translatable("test_instance_block.entities"); + private static final Component ROTATION_LABEL = Component.translatable("test_instance_block.rotation"); + private static final int BUTTON_PADDING = 8; + private static final int WIDTH = 316; + private final TestInstanceBlockEntity blockEntity; + @Nullable + private EditBox idEdit; + @Nullable + private EditBox sizeXEdit; + @Nullable + private EditBox sizeYEdit; + @Nullable + private EditBox sizeZEdit; + @Nullable + private FittingMultiLineTextWidget infoWidget; + @Nullable + private Button saveButton; + @Nullable + private Button exportButton; + @Nullable + private CycleButton includeEntitiesButton; + @Nullable + private CycleButton rotationButton; + + public TestInstanceBlockEditScreen(TestInstanceBlockEntity blockEntity) { + super(blockEntity.getBlockState().getBlock().getName()); + this.blockEntity = blockEntity; + } + + @Override + protected void init() { + int i = this.width / 2 - 158; + boolean bl = SharedConstants.IS_RUNNING_IN_IDE; + int j = bl ? 3 : 2; + int k = widgetSize(j); + this.idEdit = new EditBox(this.font, i, 40, 316, 20, Component.translatable("test_instance_block.test_id")); + this.idEdit.setMaxLength(128); + Optional> optional = this.blockEntity.test(); + if (optional.isPresent()) { + this.idEdit.setValue(((ResourceKey)optional.get()).location().toString()); + } + + this.idEdit.setResponder(string -> this.updateTestInfo(false)); + this.addRenderableWidget(this.idEdit); + this.infoWidget = new FittingMultiLineTextWidget(i, 70, 316, 8 * 9, Component.literal(""), this.font); + this.addRenderableWidget(this.infoWidget); + Vec3i vec3i = this.blockEntity.getSize(); + int l = 0; + this.sizeXEdit = new EditBox(this.font, this.widgetX(l++, 5), 160, widgetSize(5), 20, Component.translatable("structure_block.size.x")); + this.sizeXEdit.setMaxLength(15); + this.addRenderableWidget(this.sizeXEdit); + this.sizeYEdit = new EditBox(this.font, this.widgetX(l++, 5), 160, widgetSize(5), 20, Component.translatable("structure_block.size.y")); + this.sizeYEdit.setMaxLength(15); + this.addRenderableWidget(this.sizeYEdit); + this.sizeZEdit = new EditBox(this.font, this.widgetX(l++, 5), 160, widgetSize(5), 20, Component.translatable("structure_block.size.z")); + this.sizeZEdit.setMaxLength(15); + this.addRenderableWidget(this.sizeZEdit); + this.setSize(vec3i); + this.rotationButton = this.addRenderableWidget( + CycleButton.builder(TestInstanceBlockEditScreen::rotationDisplay) + .withValues(Rotation.values()) + .withInitialValue(this.blockEntity.getRotation()) + .displayOnlyValue() + .create(this.widgetX(l++, 5), 160, widgetSize(5), 20, ROTATION_LABEL, (cycleButton, rotation) -> this.updateSaveState()) + ); + this.includeEntitiesButton = this.addRenderableWidget( + CycleButton.onOffBuilder(!this.blockEntity.ignoreEntities()).displayOnlyValue().create(this.widgetX(l++, 5), 160, widgetSize(5), 20, INCLUDE_ENTITIES_LABEL) + ); + l = 0; + this.addRenderableWidget(Button.builder(Component.translatable("test_instance.action.reset"), button -> { + this.sendToServer(ServerboundTestInstanceBlockActionPacket.Action.RESET); + this.minecraft.setScreen(null); + }).bounds(this.widgetX(l++, j), 185, k, 20).build()); + this.saveButton = this.addRenderableWidget(Button.builder(Component.translatable("test_instance.action.save"), button -> { + this.sendToServer(ServerboundTestInstanceBlockActionPacket.Action.SAVE); + this.minecraft.setScreen(null); + }).bounds(this.widgetX(l++, j), 185, k, 20).build()); + if (bl) { + this.exportButton = this.addRenderableWidget(Button.builder(Component.literal("Export Structure"), button -> { + this.sendToServer(ServerboundTestInstanceBlockActionPacket.Action.EXPORT); + this.minecraft.setScreen(null); + }).bounds(this.widgetX(l++, j), 185, k, 20).build()); + } + + this.addRenderableWidget(Button.builder(Component.translatable("test_instance.action.run"), button -> { + this.sendToServer(ServerboundTestInstanceBlockActionPacket.Action.RUN); + this.minecraft.setScreen(null); + }).bounds(this.widgetX(0, 3), 210, widgetSize(3), 20).build()); + this.addRenderableWidget(Button.builder(CommonComponents.GUI_DONE, button -> this.onDone()).bounds(this.widgetX(1, 3), 210, widgetSize(3), 20).build()); + this.addRenderableWidget(Button.builder(CommonComponents.GUI_CANCEL, button -> this.onCancel()).bounds(this.widgetX(2, 3), 210, widgetSize(3), 20).build()); + this.updateTestInfo(true); + } + + private void updateSaveState() { + boolean bl = this.rotationButton.getValue() == Rotation.NONE && ResourceLocation.tryParse(this.idEdit.getValue()) != null; + this.saveButton.active = bl; + if (this.exportButton != null) { + this.exportButton.active = bl; + } + } + + private static Component rotationDisplay(Rotation rotation) { + return Component.literal(switch (rotation) { + case NONE -> "0"; + case CLOCKWISE_90 -> "90"; + case CLOCKWISE_180 -> "180"; + case COUNTERCLOCKWISE_90 -> "270"; + }); + } + + private void setSize(Vec3i size) { + this.sizeXEdit.setValue(Integer.toString(size.getX())); + this.sizeYEdit.setValue(Integer.toString(size.getY())); + this.sizeZEdit.setValue(Integer.toString(size.getZ())); + } + + private int widgetX(int index, int widgetsInRow) { + int i = this.width / 2 - 158; + float f = exactWidgetSize(widgetsInRow); + return (int)(i + index * (8.0F + f)); + } + + private static int widgetSize(int widgetsInRow) { + return (int)exactWidgetSize(widgetsInRow); + } + + private static float exactWidgetSize(int widgetsInRow) { + return (float)(316 - (widgetsInRow - 1) * 8) / widgetsInRow; + } + + @Override + public void render(GuiGraphics guiGraphics, int mouseX, int mouseY, float partialTick) { + super.render(guiGraphics, mouseX, mouseY, partialTick); + int i = this.width / 2 - 158; + guiGraphics.drawCenteredString(this.font, this.title, this.width / 2, 10, 16777215); + guiGraphics.drawString(this.font, ID_LABEL, i, 30, 12632256); + guiGraphics.drawString(this.font, SIZE_LABEL, i, 150, 12632256); + guiGraphics.drawString(this.font, ROTATION_LABEL, this.rotationButton.getX(), 150, 12632256); + guiGraphics.drawString(this.font, INCLUDE_ENTITIES_LABEL, this.includeEntitiesButton.getX(), 150, 12632256); + } + + private void updateTestInfo(boolean load) { + boolean bl = this.sendToServer(load ? ServerboundTestInstanceBlockActionPacket.Action.INIT : ServerboundTestInstanceBlockActionPacket.Action.QUERY); + if (!bl) { + this.infoWidget.setMessage(Component.translatable("test_instance.description.invalid_id").withStyle(ChatFormatting.RED)); + } + + this.updateSaveState(); + } + + private void onDone() { + this.sendToServer(ServerboundTestInstanceBlockActionPacket.Action.SET); + this.onClose(); + } + + private boolean sendToServer(ServerboundTestInstanceBlockActionPacket.Action action) { + Optional optional = Optional.ofNullable(ResourceLocation.tryParse(this.idEdit.getValue())); + Optional> optional2 = optional.map(resourceLocation -> ResourceKey.create(Registries.TEST_INSTANCE, resourceLocation)); + Vec3i vec3i = new Vec3i(parseSize(this.sizeXEdit.getValue()), parseSize(this.sizeYEdit.getValue()), parseSize(this.sizeZEdit.getValue())); + boolean bl = !this.includeEntitiesButton.getValue(); + this.minecraft + .getConnection() + .send(new ServerboundTestInstanceBlockActionPacket(this.blockEntity.getBlockPos(), action, optional2, vec3i, this.rotationButton.getValue(), bl)); + return optional.isPresent(); + } + + public void setStatus(Component status, Optional size) { + MutableComponent mutableComponent = Component.empty(); + this.blockEntity + .errorMessage() + .ifPresent( + component -> mutableComponent.append( + Component.translatable("test_instance.description.failed", Component.empty().withStyle(ChatFormatting.RED).append(component)) + ) + .append("\n\n") + ); + mutableComponent.append(status); + this.infoWidget.setMessage(mutableComponent); + size.ifPresent(this::setSize); + } + + private void onCancel() { + this.onClose(); + } + + private static int parseSize(String size) { + try { + return Mth.clamp(Integer.parseInt(size), 1, 48); + } catch (NumberFormatException var2) { + return 1; + } + } + + @Override + public void renderBackground(GuiGraphics guiGraphics, int mouseX, int mouseY, float partialTick) { + this.renderTransparentBackground(guiGraphics); + } +} diff --git a/net/minecraft/client/gui/screens/multiplayer/JoinMultiplayerScreen.java b/net/minecraft/client/gui/screens/multiplayer/JoinMultiplayerScreen.java index eea8091c..88fe057f 100644 --- a/net/minecraft/client/gui/screens/multiplayer/JoinMultiplayerScreen.java +++ b/net/minecraft/client/gui/screens/multiplayer/JoinMultiplayerScreen.java @@ -17,10 +17,13 @@ import net.minecraft.client.gui.screens.ConnectScreen; import net.minecraft.client.gui.screens.DirectJoinServerScreen; import net.minecraft.client.gui.screens.EditServerScreen; import net.minecraft.client.gui.screens.Screen; +import net.minecraft.client.gui.screens.multiplayer.ServerSelectionList.Entry; +import net.minecraft.client.gui.screens.multiplayer.ServerSelectionList.LANHeader; +import net.minecraft.client.gui.screens.multiplayer.ServerSelectionList.NetworkServerEntry; +import net.minecraft.client.gui.screens.multiplayer.ServerSelectionList.OnlineServerEntry; import net.minecraft.client.multiplayer.ServerData; import net.minecraft.client.multiplayer.ServerList; import net.minecraft.client.multiplayer.ServerStatusPinger; -import net.minecraft.client.multiplayer.ServerData.Type; import net.minecraft.client.multiplayer.resolver.ServerAddress; import net.minecraft.client.resources.language.I18n; import net.minecraft.client.server.LanServer; @@ -82,26 +85,26 @@ public class JoinMultiplayerScreen extends Screen { Button.builder(Component.translatable("selectServer.select"), buttonx -> this.joinSelectedServer()).width(100).build() ); Button button = this.addRenderableWidget(Button.builder(Component.translatable("selectServer.direct"), buttonx -> { - this.editingServer = new ServerData(I18n.get("selectServer.defaultName"), "", Type.OTHER); + this.editingServer = new ServerData(I18n.get("selectServer.defaultName"), "", ServerData.Type.OTHER); this.minecraft.setScreen(new DirectJoinServerScreen(this, this::directJoinCallback, this.editingServer)); }).width(100).build()); Button button2 = this.addRenderableWidget(Button.builder(Component.translatable("selectServer.add"), buttonx -> { - this.editingServer = new ServerData(I18n.get("selectServer.defaultName"), "", Type.OTHER); + this.editingServer = new ServerData(I18n.get("selectServer.defaultName"), "", ServerData.Type.OTHER); this.minecraft.setScreen(new EditServerScreen(this, this::addServerCallback, this.editingServer)); }).width(100).build()); this.editButton = this.addRenderableWidget(Button.builder(Component.translatable("selectServer.edit"), buttonx -> { - ServerSelectionList.Entry entry = this.serverSelectionList.getSelected(); - if (entry instanceof ServerSelectionList.OnlineServerEntry) { - ServerData serverData = ((ServerSelectionList.OnlineServerEntry)entry).getServerData(); - this.editingServer = new ServerData(serverData.name, serverData.ip, Type.OTHER); + Entry entry = this.serverSelectionList.getSelected(); + if (entry instanceof OnlineServerEntry) { + ServerData serverData = ((OnlineServerEntry)entry).getServerData(); + this.editingServer = new ServerData(serverData.name, serverData.ip, ServerData.Type.OTHER); this.editingServer.copyFrom(serverData); this.minecraft.setScreen(new EditServerScreen(this, this::editServerCallback, this.editingServer)); } }).width(74).build()); this.deleteButton = this.addRenderableWidget(Button.builder(Component.translatable("selectServer.delete"), buttonx -> { - ServerSelectionList.Entry entry = this.serverSelectionList.getSelected(); - if (entry instanceof ServerSelectionList.OnlineServerEntry) { - String string = ((ServerSelectionList.OnlineServerEntry)entry).getServerData().name; + Entry entry = this.serverSelectionList.getSelected(); + if (entry instanceof OnlineServerEntry) { + String string = ((OnlineServerEntry)entry).getServerData().name; if (string != null) { Component component = Component.translatable("selectServer.deleteQuestion"); Component component2 = Component.translatable("selectServer.deleteWarning", string); @@ -163,9 +166,9 @@ public class JoinMultiplayerScreen extends Screen { } private void deleteCallback(boolean confirmed) { - ServerSelectionList.Entry entry = this.serverSelectionList.getSelected(); - if (confirmed && entry instanceof ServerSelectionList.OnlineServerEntry) { - this.servers.remove(((ServerSelectionList.OnlineServerEntry)entry).getServerData()); + Entry entry = this.serverSelectionList.getSelected(); + if (confirmed && entry instanceof OnlineServerEntry) { + this.servers.remove(((OnlineServerEntry)entry).getServerData()); this.servers.save(); this.serverSelectionList.setSelected(null); this.serverSelectionList.updateOnlineServers(this.servers); @@ -175,9 +178,9 @@ public class JoinMultiplayerScreen extends Screen { } private void editServerCallback(boolean confirmed) { - ServerSelectionList.Entry entry = this.serverSelectionList.getSelected(); - if (confirmed && entry instanceof ServerSelectionList.OnlineServerEntry) { - ServerData serverData = ((ServerSelectionList.OnlineServerEntry)entry).getServerData(); + Entry entry = this.serverSelectionList.getSelected(); + if (confirmed && entry instanceof OnlineServerEntry) { + ServerData serverData = ((OnlineServerEntry)entry).getServerData(); serverData.name = this.editingServer.name; serverData.ip = this.editingServer.ip; serverData.copyFrom(this.editingServer); @@ -247,12 +250,12 @@ public class JoinMultiplayerScreen extends Screen { } public void joinSelectedServer() { - ServerSelectionList.Entry entry = this.serverSelectionList.getSelected(); - if (entry instanceof ServerSelectionList.OnlineServerEntry) { - this.join(((ServerSelectionList.OnlineServerEntry)entry).getServerData()); - } else if (entry instanceof ServerSelectionList.NetworkServerEntry) { - LanServer lanServer = ((ServerSelectionList.NetworkServerEntry)entry).getServerData(); - this.join(new ServerData(lanServer.getMotd(), lanServer.getAddress(), Type.LAN)); + Entry entry = this.serverSelectionList.getSelected(); + if (entry instanceof OnlineServerEntry) { + this.join(((OnlineServerEntry)entry).getServerData()); + } else if (entry instanceof NetworkServerEntry) { + LanServer lanServer = ((NetworkServerEntry)entry).getServerData(); + this.join(new ServerData(lanServer.getMotd(), lanServer.getAddress(), ServerData.Type.LAN)); } } @@ -260,7 +263,7 @@ public class JoinMultiplayerScreen extends Screen { ConnectScreen.startConnecting(this, this.minecraft, ServerAddress.parseString(server.ip), server, false, null); } - public void setSelected(ServerSelectionList.Entry selected) { + public void setSelected(Entry selected) { this.serverSelectionList.setSelected(selected); this.onSelectedChange(); } @@ -269,10 +272,10 @@ public class JoinMultiplayerScreen extends Screen { this.selectButton.active = false; this.editButton.active = false; this.deleteButton.active = false; - ServerSelectionList.Entry entry = this.serverSelectionList.getSelected(); - if (entry != null && !(entry instanceof ServerSelectionList.LANHeader)) { + Entry entry = this.serverSelectionList.getSelected(); + if (entry != null && !(entry instanceof LANHeader)) { this.selectButton.active = true; - if (entry instanceof ServerSelectionList.OnlineServerEntry) { + if (entry instanceof OnlineServerEntry) { this.editButton.active = true; this.deleteButton.active = true; } diff --git a/net/minecraft/client/gui/screens/options/UnsupportedGraphicsWarningScreen.java b/net/minecraft/client/gui/screens/options/UnsupportedGraphicsWarningScreen.java index d5cfa095..3b09361e 100644 --- a/net/minecraft/client/gui/screens/options/UnsupportedGraphicsWarningScreen.java +++ b/net/minecraft/client/gui/screens/options/UnsupportedGraphicsWarningScreen.java @@ -7,6 +7,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.gui.components.Button; import net.minecraft.client.gui.components.MultiLineLabel; +import net.minecraft.client.gui.components.Button.OnPress; import net.minecraft.client.gui.screens.Screen; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; @@ -73,9 +74,9 @@ public class UnsupportedGraphicsWarningScreen extends Screen { @Environment(EnvType.CLIENT) public static final class ButtonOption { final Component message; - final Button.OnPress onPress; + final OnPress onPress; - public ButtonOption(Component message, Button.OnPress onPress) { + public ButtonOption(Component message, OnPress onPress) { this.message = message; this.onPress = onPress; } diff --git a/net/minecraft/client/gui/screens/options/VideoSettingsScreen.java b/net/minecraft/client/gui/screens/options/VideoSettingsScreen.java index c9db6a25..41cfc733 100644 --- a/net/minecraft/client/gui/screens/options/VideoSettingsScreen.java +++ b/net/minecraft/client/gui/screens/options/VideoSettingsScreen.java @@ -14,6 +14,9 @@ import net.minecraft.client.GraphicsStatus; import net.minecraft.client.Minecraft; import net.minecraft.client.OptionInstance; import net.minecraft.client.Options; +import net.minecraft.client.OptionInstance.ClampingLazyMaxIntRange; +import net.minecraft.client.OptionInstance.IntRange; +import net.minecraft.client.gui.components.AbstractWidget; import net.minecraft.client.gui.components.CycleButton; import net.minecraft.client.gui.screens.Screen; import net.minecraft.client.renderer.GpuWarnlistManager; @@ -106,7 +109,7 @@ public class VideoSettingsScreen extends OptionsSubScreen { ); } }, - new OptionInstance.IntRange(-1, monitor != null ? monitor.getModeCount() - 1 : -1), + new IntRange(-1, monitor != null ? monitor.getModeCount() - 1 : -1), j, integer -> { if (monitor != null) { @@ -182,7 +185,7 @@ public class VideoSettingsScreen extends OptionsSubScreen { public boolean mouseScrolled(double mouseX, double mouseY, double scrollX, double scrollY) { if (Screen.hasControlDown()) { OptionInstance optionInstance = this.options.guiScale(); - if (optionInstance.values() instanceof OptionInstance.ClampingLazyMaxIntRange clampingLazyMaxIntRange) { + if (optionInstance.values() instanceof ClampingLazyMaxIntRange clampingLazyMaxIntRange) { int i = optionInstance.get(); int j = i == 0 ? clampingLazyMaxIntRange.maxInclusive() + 1 : i; int k = j + (int)Math.signum(scrollY); @@ -202,4 +205,14 @@ public class VideoSettingsScreen extends OptionsSubScreen { return super.mouseScrolled(mouseX, mouseY, scrollX, scrollY); } } + + public void updateFullscreenButton(boolean isFullscreen) { + if (this.list != null) { + AbstractWidget abstractWidget = this.list.findOption(this.options.fullscreen()); + if (abstractWidget != null) { + CycleButton cycleButton = (CycleButton)abstractWidget; + cycleButton.setValue(isFullscreen); + } + } + } } diff --git a/net/minecraft/client/gui/screens/packs/PackSelectionScreen.java b/net/minecraft/client/gui/screens/packs/PackSelectionScreen.java index 735dc3a3..a27610a2 100644 --- a/net/minecraft/client/gui/screens/packs/PackSelectionScreen.java +++ b/net/minecraft/client/gui/screens/packs/PackSelectionScreen.java @@ -41,6 +41,7 @@ import net.minecraft.client.gui.screens.ConfirmScreen; import net.minecraft.client.gui.screens.NoticeWithLinkScreen; import net.minecraft.client.gui.screens.Screen; import net.minecraft.client.gui.screens.packs.PackSelectionModel.Entry; +import net.minecraft.client.gui.screens.packs.TransferableSelectionList.PackEntry; import net.minecraft.client.renderer.texture.DynamicTexture; import net.minecraft.client.renderer.texture.TextureManager; import net.minecraft.network.chat.CommonComponents; @@ -156,11 +157,11 @@ public class PackSelectionScreen extends Screen { private void updateList(TransferableSelectionList selection, Stream models) { selection.children().clear(); - TransferableSelectionList.PackEntry packEntry = selection.getSelected(); + PackEntry packEntry = selection.getSelected(); String string = packEntry == null ? "" : packEntry.getPackId(); selection.setSelected(null); models.forEach(entry -> { - TransferableSelectionList.PackEntry packEntryx = new TransferableSelectionList.PackEntry(this.minecraft, selection, entry); + PackEntry packEntryx = new PackEntry(this.minecraft, selection, entry); selection.children().add(packEntryx); if (entry.getId().equals(string)) { selection.setSelected(packEntryx); @@ -313,7 +314,7 @@ public class PackSelectionScreen extends Screen { try { NativeImage nativeImage = NativeImage.read(inputStream); - textureManager.register(resourceLocation, new DynamicTexture(nativeImage)); + textureManager.register(resourceLocation, new DynamicTexture(resourceLocation::toString, nativeImage)); var9 = resourceLocation; } catch (Throwable var12) { if (inputStream != null) { diff --git a/net/minecraft/client/gui/screens/reporting/ChatSelectionScreen.java b/net/minecraft/client/gui/screens/reporting/ChatSelectionScreen.java index 412d732d..2a32112a 100644 --- a/net/minecraft/client/gui/screens/reporting/ChatSelectionScreen.java +++ b/net/minecraft/client/gui/screens/reporting/ChatSelectionScreen.java @@ -21,8 +21,8 @@ import net.minecraft.client.gui.screens.reporting.ChatSelectionScreen.ChatSelect import net.minecraft.client.multiplayer.chat.ChatTrustLevel; import net.minecraft.client.multiplayer.chat.LoggedChatMessage; import net.minecraft.client.multiplayer.chat.LoggedChatMessage.Player; -import net.minecraft.client.multiplayer.chat.report.ChatReport; import net.minecraft.client.multiplayer.chat.report.ReportingContext; +import net.minecraft.client.multiplayer.chat.report.ChatReport.Builder; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.resources.ResourceLocation; @@ -41,11 +41,11 @@ public class ChatSelectionScreen extends Screen { private MultiLineLabel contextInfoLabel; @Nullable private ChatSelectionScreen.ChatSelectionList chatSelectionList; - final ChatReport.Builder report; - private final Consumer onSelected; + final Builder report; + private final Consumer onSelected; private ChatSelectionLogFiller chatLogFiller; - public ChatSelectionScreen(@Nullable Screen lastScreen, ReportingContext reportingContext, ChatReport.Builder report, Consumer onSelected) { + public ChatSelectionScreen(@Nullable Screen lastScreen, ReportingContext reportingContext, Builder report, Consumer onSelected) { super(TITLE); this.lastScreen = lastScreen; this.reportingContext = reportingContext; diff --git a/net/minecraft/client/gui/screens/worldselection/CreateWorldScreen.java b/net/minecraft/client/gui/screens/worldselection/CreateWorldScreen.java index 929fb21a..9f78f30f 100644 --- a/net/minecraft/client/gui/screens/worldselection/CreateWorldScreen.java +++ b/net/minecraft/client/gui/screens/worldselection/CreateWorldScreen.java @@ -35,6 +35,7 @@ import net.minecraft.client.gui.components.Button; import net.minecraft.client.gui.components.CycleButton; import net.minecraft.client.gui.components.EditBox; import net.minecraft.client.gui.components.Tooltip; +import net.minecraft.client.gui.components.CycleButton.ValueListSupplier; import net.minecraft.client.gui.components.tabs.GridLayoutTab; import net.minecraft.client.gui.components.tabs.TabManager; import net.minecraft.client.gui.components.tabs.TabNavigationBar; @@ -51,10 +52,11 @@ import net.minecraft.client.gui.screens.Screen; import net.minecraft.client.gui.screens.packs.PackSelectionScreen; import net.minecraft.client.gui.screens.worldselection.CreateWorldScreen.WorldTab.1; import net.minecraft.client.gui.screens.worldselection.CreateWorldScreen.WorldTab.2; +import net.minecraft.client.gui.screens.worldselection.SwitchGrid.Builder; import net.minecraft.client.gui.screens.worldselection.WorldCreationUiState.SelectedGameMode; import net.minecraft.client.gui.screens.worldselection.WorldCreationUiState.WorldTypeEntry; import net.minecraft.client.renderer.RenderType; -import net.minecraft.commands.Commands.CommandSelection; +import net.minecraft.commands.Commands; import net.minecraft.core.LayeredRegistryAccess; import net.minecraft.core.registries.Registries; import net.minecraft.network.chat.CommonComponents; @@ -85,10 +87,9 @@ import net.minecraft.world.level.levelgen.flat.FlatLevelGeneratorPresets; import net.minecraft.world.level.levelgen.presets.WorldPreset; import net.minecraft.world.level.levelgen.presets.WorldPresets; import net.minecraft.world.level.storage.LevelResource; +import net.minecraft.world.level.storage.LevelStorageSource; import net.minecraft.world.level.storage.PrimaryLevelData; import net.minecraft.world.level.storage.WorldData; -import net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess; -import net.minecraft.world.level.storage.PrimaryLevelData.SpecialWorldProperty; import net.minecraft.world.level.validation.DirectoryValidator; import org.apache.commons.lang3.mutable.MutableObject; import org.jetbrains.annotations.Nullable; @@ -179,7 +180,10 @@ public class CreateWorldScreen extends Screen { ) { queueLoadScreen(minecraft, PREPARING_WORLD_DATA); PackRepository packRepository = new PackRepository(new ServerPacksSource(minecraft.directoryValidator())); - InitConfig initConfig = createDefaultLoadConfig(packRepository, WorldDataConfiguration.DEFAULT); + WorldDataConfiguration worldDataConfiguration = SharedConstants.IS_RUNNING_IN_IDE + ? new WorldDataConfiguration(new DataPackConfig(List.of("vanilla", "tests"), List.of()), FeatureFlags.DEFAULT_FLAGS) + : WorldDataConfiguration.DEFAULT; + InitConfig initConfig = createDefaultLoadConfig(packRepository, worldDataConfiguration); CompletableFuture completableFuture = WorldLoader.load( initConfig, dataLoadContext -> new DataLoadOutput<>( @@ -294,7 +298,7 @@ public class CreateWorldScreen extends Screen { Lifecycle lifecycle2 = layeredRegistryAccess.compositeAccess().allRegistriesLifecycle(); Lifecycle lifecycle3 = lifecycle2.add(lifecycle); boolean bl = !this.recreated && lifecycle2 == Lifecycle.stable(); - LevelSettings levelSettings = this.createLevelSettings(complete.specialWorldProperty() == SpecialWorldProperty.DEBUG); + LevelSettings levelSettings = this.createLevelSettings(complete.specialWorldProperty() == PrimaryLevelData.SpecialWorldProperty.DEBUG); PrimaryLevelData primaryLevelData = new PrimaryLevelData(levelSettings, this.uiState.getSettings().options(), complete.specialWorldProperty(), lifecycle3); WorldOpenFlows.confirmWorldCreation(this.minecraft, this, lifecycle3, () -> this.createWorldAndCleanup(layeredRegistryAccess, primaryLevelData), bl); } @@ -311,14 +315,14 @@ public class CreateWorldScreen extends Screen { String string = this.uiState.getTargetFolder(); WorldCreationContext worldCreationContext = this.uiState.getSettings(); queueLoadScreen(this.minecraft, PREPARING_WORLD_DATA); - Optional optional = createNewWorldDirectory(this.minecraft, string, this.tempDataPackDir); + Optional optional = createNewWorldDirectory(this.minecraft, string, this.tempDataPackDir); if (optional.isEmpty()) { SystemToast.onPackCopyFailure(this.minecraft, string); return false; } else { this.minecraft .createWorldOpenFlows() - .createLevelFromExistingSettings((LevelStorageAccess)optional.get(), worldCreationContext.dataPackResources(), registryAccess, worldData); + .createLevelFromExistingSettings((LevelStorageSource.LevelStorageAccess)optional.get(), worldCreationContext.dataPackResources(), registryAccess, worldData); return true; } } @@ -510,7 +514,7 @@ public class CreateWorldScreen extends Screen { private static InitConfig createDefaultLoadConfig(PackRepository packRepository, WorldDataConfiguration initialDataConfig) { PackConfig packConfig = new PackConfig(packRepository, initialDataConfig, false, true); - return new InitConfig(packConfig, CommandSelection.INTEGRATED, 2); + return new InitConfig(packConfig, Commands.CommandSelection.INTEGRATED, 2); } private void removeTempDataPackDir() { @@ -558,9 +562,9 @@ public class CreateWorldScreen extends Screen { } } - private static Optional createNewWorldDirectory(Minecraft minecraft, String saveName, @Nullable Path tempDataPackDir) { + private static Optional createNewWorldDirectory(Minecraft minecraft, String saveName, @Nullable Path tempDataPackDir) { try { - LevelStorageAccess levelStorageAccess = minecraft.getLevelSource().createAccess(saveName); + LevelStorageSource.LevelStorageAccess levelStorageAccess = minecraft.getLevelSource().createAccess(saveName); if (tempDataPackDir == null) { return Optional.of(levelStorageAccess); } @@ -829,7 +833,7 @@ public class CreateWorldScreen extends Screen { this.seedEdit.setValue(CreateWorldScreen.this.uiState.getSeed()); this.seedEdit.setResponder(string -> CreateWorldScreen.this.uiState.setSeed(this.seedEdit.getValue())); rowHelper.addChild(CommonLayouts.labeledElement(CreateWorldScreen.this.font, this.seedEdit, SEED_LABEL), 2); - SwitchGrid.Builder builder = SwitchGrid.builder(310); + Builder builder = SwitchGrid.builder(310); builder.addSwitch(GENERATE_STRUCTURES, CreateWorldScreen.this.uiState::isGenerateStructures, CreateWorldScreen.this.uiState::setGenerateStructures) .withIsActiveCondition(() -> !CreateWorldScreen.this.uiState.isDebug()) .withInfo(GENERATE_STRUCTURES_INFO); @@ -847,7 +851,7 @@ public class CreateWorldScreen extends Screen { } } - private CycleButton.ValueListSupplier createWorldTypeValueSupplier() { + private ValueListSupplier createWorldTypeValueSupplier() { return new 2(this); } diff --git a/net/minecraft/client/gui/screens/worldselection/EditGameRulesScreen.java b/net/minecraft/client/gui/screens/worldselection/EditGameRulesScreen.java index 442e5175..faa9ad57 100644 --- a/net/minecraft/client/gui/screens/worldselection/EditGameRulesScreen.java +++ b/net/minecraft/client/gui/screens/worldselection/EditGameRulesScreen.java @@ -30,11 +30,6 @@ import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.util.FormattedCharSequence; import net.minecraft.world.level.GameRules; -import net.minecraft.world.level.GameRules.BooleanValue; -import net.minecraft.world.level.GameRules.Category; -import net.minecraft.world.level.GameRules.IntegerValue; -import net.minecraft.world.level.GameRules.Key; -import net.minecraft.world.level.GameRules.Value; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) @@ -102,7 +97,7 @@ public class EditGameRulesScreen extends Screen { public class BooleanRuleEntry extends EditGameRulesScreen.GameRuleEntry { private final CycleButton checkbox; - public BooleanRuleEntry(final Component label, final List tooltip, final String description, final BooleanValue value) { + public BooleanRuleEntry(final Component label, final List tooltip, final String description, final GameRules.BooleanValue value) { super(tooltip, label); this.checkbox = CycleButton.onOffBuilder(value.get()) .displayOnlyValue() @@ -147,7 +142,7 @@ public class EditGameRulesScreen extends Screen { @FunctionalInterface @Environment(EnvType.CLIENT) - interface EntryFactory> { + interface EntryFactory> { EditGameRulesScreen.RuleEntry create(Component component, List list, String string, T value); } @@ -185,7 +180,7 @@ public class EditGameRulesScreen extends Screen { public class IntegerRuleEntry extends EditGameRulesScreen.GameRuleEntry { private final EditBox input; - public IntegerRuleEntry(final Component label, final List tooltip, final String description, final IntegerValue value) { + public IntegerRuleEntry(final Component label, final List tooltip, final String description, final GameRules.IntegerValue value) { super(tooltip, label); this.input = new EditBox(EditGameRulesScreen.this.minecraft.font, 10, 5, 44, 20, label.copy().append("\n").append(description).append("\n")); this.input.setValue(Integer.toString(value.get())); @@ -232,7 +227,7 @@ public class EditGameRulesScreen extends Screen { EditGameRulesScreen.this.layout.getHeaderHeight(), 24 ); - Map, EditGameRulesScreen.RuleEntry>> map = Maps., EditGameRulesScreen.RuleEntry>>newHashMap(); + Map, EditGameRulesScreen.RuleEntry>> map = Maps., EditGameRulesScreen.RuleEntry>>newHashMap(); gameRules.visitGameRuleTypes( new net.minecraft.client.gui.screens.worldselection.EditGameRulesScreen.RuleList.1(this, EditGameRulesScreen.this, gameRules, map) ); @@ -243,13 +238,13 @@ public class EditGameRulesScreen extends Screen { entry -> { this.addEntry( EditGameRulesScreen.this.new CategoryRuleEntry( - Component.translatable(((Category)entry.getKey()).getDescriptionId()).withStyle(ChatFormatting.BOLD, ChatFormatting.YELLOW) + Component.translatable(((GameRules.Category)entry.getKey()).getDescriptionId()).withStyle(ChatFormatting.BOLD, ChatFormatting.YELLOW) ) ); ((Map)entry.getValue()) .entrySet() .stream() - .sorted(java.util.Map.Entry.comparingByKey(Comparator.comparing(Key::getId))) + .sorted(java.util.Map.Entry.comparingByKey(Comparator.comparing(GameRules.Key::getId))) .forEach(entryx -> this.addEntry((EditGameRulesScreen.RuleEntry)entryx.getValue())); } ); diff --git a/net/minecraft/client/gui/screens/worldselection/EditWorldScreen.java b/net/minecraft/client/gui/screens/worldselection/EditWorldScreen.java index 54e68f7c..998adbdc 100644 --- a/net/minecraft/client/gui/screens/worldselection/EditWorldScreen.java +++ b/net/minecraft/client/gui/screens/worldselection/EditWorldScreen.java @@ -33,7 +33,6 @@ import net.minecraft.util.StringUtil; import net.minecraft.world.level.storage.LevelResource; import net.minecraft.world.level.storage.LevelStorageSource; import net.minecraft.world.level.storage.LevelSummary; -import net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess; import org.apache.commons.io.FileUtils; import org.slf4j.Logger; @@ -55,15 +54,15 @@ public class EditWorldScreen extends Screen { private static final int HALF_WIDTH = 98; private final LinearLayout layout = LinearLayout.vertical().spacing(5); private final BooleanConsumer callback; - private final LevelStorageAccess levelAccess; + private final LevelStorageSource.LevelStorageAccess levelAccess; private final EditBox nameEdit; - public static EditWorldScreen create(Minecraft minecraft, LevelStorageAccess levelAccess, BooleanConsumer callback) throws IOException { + public static EditWorldScreen create(Minecraft minecraft, LevelStorageSource.LevelStorageAccess levelAccess, BooleanConsumer callback) throws IOException { LevelSummary levelSummary = levelAccess.getSummary(levelAccess.getDataTag()); return new EditWorldScreen(minecraft, levelAccess, levelSummary.getLevelName(), callback); } - private EditWorldScreen(Minecraft minecraft, LevelStorageAccess levelAccess, String levelName, BooleanConsumer callback) { + private EditWorldScreen(Minecraft minecraft, LevelStorageSource.LevelStorageAccess levelAccess, String levelName, BooleanConsumer callback) { super(Component.translatable("selectWorld.edit.title")); this.callback = callback; this.levelAccess = levelAccess; @@ -143,7 +142,7 @@ public class EditWorldScreen extends Screen { this.callback.accept(true); } - public static boolean makeBackupAndShowToast(LevelStorageAccess levelAccess) { + public static boolean makeBackupAndShowToast(LevelStorageSource.LevelStorageAccess levelAccess) { long l = 0L; IOException iOException = null; diff --git a/net/minecraft/client/gui/screens/worldselection/ExperimentsScreen.java b/net/minecraft/client/gui/screens/worldselection/ExperimentsScreen.java index 5f9e6124..55852bb9 100644 --- a/net/minecraft/client/gui/screens/worldselection/ExperimentsScreen.java +++ b/net/minecraft/client/gui/screens/worldselection/ExperimentsScreen.java @@ -24,6 +24,7 @@ import net.minecraft.client.gui.narration.NarrationElementOutput; import net.minecraft.client.gui.navigation.ScreenDirection; import net.minecraft.client.gui.navigation.ScreenRectangle; import net.minecraft.client.gui.screens.Screen; +import net.minecraft.client.gui.screens.worldselection.SwitchGrid.Builder; import net.minecraft.client.resources.language.I18n; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; @@ -64,7 +65,7 @@ public class ExperimentsScreen extends Screen { this.layout.addTitleHeader(TITLE, this.font); LinearLayout linearLayout = this.layout.addToContents(LinearLayout.vertical()); linearLayout.addChild(new MultiLineTextWidget(INFO, this.font).setMaxWidth(310), layoutSettings -> layoutSettings.paddingBottom(15)); - SwitchGrid.Builder builder = SwitchGrid.builder(299).withInfoUnderneath(2, true).withRowSpacing(4); + Builder builder = SwitchGrid.builder(299).withInfoUnderneath(2, true).withRowSpacing(4); this.packs .forEach( (pack, boolean_) -> builder.addSwitch( diff --git a/net/minecraft/client/gui/screens/worldselection/OptimizeWorldScreen.java b/net/minecraft/client/gui/screens/worldselection/OptimizeWorldScreen.java index 5fe7f498..3951db9f 100644 --- a/net/minecraft/client/gui/screens/worldselection/OptimizeWorldScreen.java +++ b/net/minecraft/client/gui/screens/worldselection/OptimizeWorldScreen.java @@ -23,9 +23,8 @@ import net.minecraft.server.packs.repository.ServerPacksSource; import net.minecraft.util.Mth; import net.minecraft.util.worldupdate.WorldUpgrader; import net.minecraft.world.level.Level; -import net.minecraft.world.level.LevelSettings; +import net.minecraft.world.level.storage.LevelStorageSource; import net.minecraft.world.level.storage.WorldData; -import net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -43,7 +42,7 @@ public class OptimizeWorldScreen extends Screen { @Nullable public static OptimizeWorldScreen create( - Minecraft minecraft, BooleanConsumer callback, DataFixer dataFixer, LevelStorageAccess levelStorage, boolean eraseCache + Minecraft minecraft, BooleanConsumer callback, DataFixer dataFixer, LevelStorageSource.LevelStorageAccess levelStorage, boolean eraseCache ) { try { WorldOpenFlows worldOpenFlows = minecraft.createWorldOpenFlows(); @@ -54,7 +53,7 @@ public class OptimizeWorldScreen extends Screen { WorldData worldData = worldStem.worldData(); Frozen frozen = worldStem.registries().compositeAccess(); levelStorage.saveDataTag(frozen, worldData); - var10 = new OptimizeWorldScreen(callback, dataFixer, levelStorage, worldData.getLevelSettings(), eraseCache, frozen); + var10 = new OptimizeWorldScreen(callback, dataFixer, levelStorage, worldData, eraseCache, frozen); } return var10; @@ -67,14 +66,14 @@ public class OptimizeWorldScreen extends Screen { private OptimizeWorldScreen( BooleanConsumer callback, DataFixer dataFixer, - LevelStorageAccess levelStorage, - LevelSettings levelSettings, + LevelStorageSource.LevelStorageAccess levelStorage, + WorldData worldData, boolean eraseCache, RegistryAccess registryAccess ) { - super(Component.translatable("optimizeWorld.title", levelSettings.levelName())); + super(Component.translatable("optimizeWorld.title", worldData.getLevelSettings().levelName())); this.callback = callback; - this.upgrader = new WorldUpgrader(levelStorage, dataFixer, registryAccess, eraseCache, false); + this.upgrader = new WorldUpgrader(levelStorage, dataFixer, worldData, registryAccess, eraseCache, false); } @Override diff --git a/net/minecraft/client/gui/screens/worldselection/SelectWorldScreen.java b/net/minecraft/client/gui/screens/worldselection/SelectWorldScreen.java index 4443e411..56835664 100644 --- a/net/minecraft/client/gui/screens/worldselection/SelectWorldScreen.java +++ b/net/minecraft/client/gui/screens/worldselection/SelectWorldScreen.java @@ -7,6 +7,8 @@ import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.gui.components.Button; import net.minecraft.client.gui.components.EditBox; import net.minecraft.client.gui.screens.Screen; +import net.minecraft.client.gui.screens.worldselection.WorldSelectionList.Entry; +import net.minecraft.client.gui.screens.worldselection.WorldSelectionList.WorldListEntry; import net.minecraft.network.chat.CommonComponents; import net.minecraft.network.chat.Component; import net.minecraft.world.level.levelgen.WorldOptions; @@ -40,7 +42,7 @@ public class SelectWorldScreen extends Screen { new WorldSelectionList(this, this.minecraft, this.width, this.height - 112, 48, 36, this.searchBox.getValue(), this.list) ); this.selectButton = this.addRenderableWidget( - Button.builder(LevelSummary.PLAY_WORLD, button -> this.list.getSelectedOpt().ifPresent(WorldSelectionList.WorldListEntry::joinWorld)) + Button.builder(LevelSummary.PLAY_WORLD, button -> this.list.getSelectedOpt().ifPresent(WorldListEntry::joinWorld)) .bounds(this.width / 2 - 154, this.height - 52, 150, 20) .build() ); @@ -50,19 +52,17 @@ public class SelectWorldScreen extends Screen { .build() ); this.renameButton = this.addRenderableWidget( - Button.builder(Component.translatable("selectWorld.edit"), button -> this.list.getSelectedOpt().ifPresent(WorldSelectionList.WorldListEntry::editWorld)) + Button.builder(Component.translatable("selectWorld.edit"), button -> this.list.getSelectedOpt().ifPresent(WorldListEntry::editWorld)) .bounds(this.width / 2 - 154, this.height - 28, 72, 20) .build() ); this.deleteButton = this.addRenderableWidget( - Button.builder(Component.translatable("selectWorld.delete"), button -> this.list.getSelectedOpt().ifPresent(WorldSelectionList.WorldListEntry::deleteWorld)) + Button.builder(Component.translatable("selectWorld.delete"), button -> this.list.getSelectedOpt().ifPresent(WorldListEntry::deleteWorld)) .bounds(this.width / 2 - 76, this.height - 28, 72, 20) .build() ); this.copyButton = this.addRenderableWidget( - Button.builder( - Component.translatable("selectWorld.recreate"), button -> this.list.getSelectedOpt().ifPresent(WorldSelectionList.WorldListEntry::recreateWorld) - ) + Button.builder(Component.translatable("selectWorld.recreate"), button -> this.list.getSelectedOpt().ifPresent(WorldListEntry::recreateWorld)) .bounds(this.width / 2 + 4, this.height - 28, 72, 20) .build() ); @@ -108,7 +108,7 @@ public class SelectWorldScreen extends Screen { @Override public void removed() { if (this.list != null) { - this.list.children().forEach(WorldSelectionList.Entry::close); + this.list.children().forEach(Entry::close); } } } diff --git a/net/minecraft/client/main/GameConfig.java b/net/minecraft/client/main/GameConfig.java index 9db47100..f9fbcc27 100644 --- a/net/minecraft/client/main/GameConfig.java +++ b/net/minecraft/client/main/GameConfig.java @@ -56,14 +56,24 @@ public class GameConfig { public final boolean disableMultiplayer; public final boolean disableChat; public final boolean captureTracyImages; + public final boolean renderDebugLabels; - public GameData(boolean demo, String launchVersion, String versionType, boolean disableMultiplayer, boolean disableChat, boolean captureTracyImages) { + public GameData( + boolean demo, + String launchVersion, + String versionType, + boolean disableMultiplayer, + boolean disableChat, + boolean captureTracyImages, + boolean renderDebugLabels + ) { this.demo = demo; this.launchVersion = launchVersion; this.versionType = versionType; this.disableMultiplayer = disableMultiplayer; this.disableChat = disableChat; this.captureTracyImages = captureTracyImages; + this.renderDebugLabels = renderDebugLabels; } } diff --git a/net/minecraft/client/main/Main.java b/net/minecraft/client/main/Main.java index bef3d789..4ef6f355 100644 --- a/net/minecraft/client/main/Main.java +++ b/net/minecraft/client/main/Main.java @@ -9,7 +9,6 @@ import com.mojang.authlib.properties.PropertyMap.Serializer; import com.mojang.blaze3d.TracyBootstrap; import com.mojang.blaze3d.platform.DisplayData; import com.mojang.blaze3d.systems.RenderSystem; -import com.mojang.blaze3d.vertex.BufferUploader; import com.mojang.jtracy.TracyClient; import com.mojang.logging.LogUtils; import com.mojang.util.UndashedUuid; @@ -38,10 +37,6 @@ import net.minecraft.client.ClientBootstrap; import net.minecraft.client.Minecraft; import net.minecraft.client.User; import net.minecraft.client.User.Type; -import net.minecraft.client.main.GameConfig.FolderData; -import net.minecraft.client.main.GameConfig.GameData; -import net.minecraft.client.main.GameConfig.QuickPlayData; -import net.minecraft.client.main.GameConfig.UserData; import net.minecraft.client.server.IntegratedServer; import net.minecraft.client.telemetry.TelemetryProperty; import net.minecraft.client.telemetry.events.GameLoadTimesEvent; @@ -68,49 +63,50 @@ public class Main { optionParser.accepts("disableChat"); optionParser.accepts("fullscreen"); optionParser.accepts("checkGlErrors"); - OptionSpec optionSpec = optionParser.accepts("jfrProfile"); - OptionSpec optionSpec2 = optionParser.accepts("tracy"); - OptionSpec optionSpec3 = optionParser.accepts("tracyNoImages"); - OptionSpec optionSpec4 = optionParser.accepts("quickPlayPath").withRequiredArg(); - OptionSpec optionSpec5 = optionParser.accepts("quickPlaySingleplayer").withRequiredArg(); - OptionSpec optionSpec6 = optionParser.accepts("quickPlayMultiplayer").withRequiredArg(); - OptionSpec optionSpec7 = optionParser.accepts("quickPlayRealms").withRequiredArg(); - OptionSpec optionSpec8 = optionParser.accepts("gameDir").withRequiredArg().ofType(File.class).defaultsTo(new File(".")); - OptionSpec optionSpec9 = optionParser.accepts("assetsDir").withRequiredArg().ofType(File.class); - OptionSpec optionSpec10 = optionParser.accepts("resourcePackDir").withRequiredArg().ofType(File.class); - OptionSpec optionSpec11 = optionParser.accepts("proxyHost").withRequiredArg(); - OptionSpec optionSpec12 = optionParser.accepts("proxyPort").withRequiredArg().defaultsTo("8080").ofType(Integer.class); - OptionSpec optionSpec13 = optionParser.accepts("proxyUser").withRequiredArg(); - OptionSpec optionSpec14 = optionParser.accepts("proxyPass").withRequiredArg(); - OptionSpec optionSpec15 = optionParser.accepts("username").withRequiredArg().defaultsTo("Player" + System.currentTimeMillis() % 1000L); - OptionSpec optionSpec16 = optionParser.accepts("uuid").withRequiredArg(); - OptionSpec optionSpec17 = optionParser.accepts("xuid").withOptionalArg().defaultsTo(""); - OptionSpec optionSpec18 = optionParser.accepts("clientId").withOptionalArg().defaultsTo(""); - OptionSpec optionSpec19 = optionParser.accepts("accessToken").withRequiredArg().required(); - OptionSpec optionSpec20 = optionParser.accepts("version").withRequiredArg().required(); - OptionSpec optionSpec21 = optionParser.accepts("width").withRequiredArg().ofType(Integer.class).defaultsTo(854); - OptionSpec optionSpec22 = optionParser.accepts("height").withRequiredArg().ofType(Integer.class).defaultsTo(480); - OptionSpec optionSpec23 = optionParser.accepts("fullscreenWidth").withRequiredArg().ofType(Integer.class); - OptionSpec optionSpec24 = optionParser.accepts("fullscreenHeight").withRequiredArg().ofType(Integer.class); - OptionSpec optionSpec25 = optionParser.accepts("userProperties").withRequiredArg().defaultsTo("{}"); - OptionSpec optionSpec26 = optionParser.accepts("profileProperties").withRequiredArg().defaultsTo("{}"); - OptionSpec optionSpec27 = optionParser.accepts("assetIndex").withRequiredArg(); - OptionSpec optionSpec28 = optionParser.accepts("userType").withRequiredArg().defaultsTo("legacy"); - OptionSpec optionSpec29 = optionParser.accepts("versionType").withRequiredArg().defaultsTo("release"); - OptionSpec optionSpec30 = optionParser.nonOptions(); + OptionSpec optionSpec = optionParser.accepts("renderDebugLabels"); + OptionSpec optionSpec2 = optionParser.accepts("jfrProfile"); + OptionSpec optionSpec3 = optionParser.accepts("tracy"); + OptionSpec optionSpec4 = optionParser.accepts("tracyNoImages"); + OptionSpec optionSpec5 = optionParser.accepts("quickPlayPath").withRequiredArg(); + OptionSpec optionSpec6 = optionParser.accepts("quickPlaySingleplayer").withRequiredArg(); + OptionSpec optionSpec7 = optionParser.accepts("quickPlayMultiplayer").withRequiredArg(); + OptionSpec optionSpec8 = optionParser.accepts("quickPlayRealms").withRequiredArg(); + OptionSpec optionSpec9 = optionParser.accepts("gameDir").withRequiredArg().ofType(File.class).defaultsTo(new File(".")); + OptionSpec optionSpec10 = optionParser.accepts("assetsDir").withRequiredArg().ofType(File.class); + OptionSpec optionSpec11 = optionParser.accepts("resourcePackDir").withRequiredArg().ofType(File.class); + OptionSpec optionSpec12 = optionParser.accepts("proxyHost").withRequiredArg(); + OptionSpec optionSpec13 = optionParser.accepts("proxyPort").withRequiredArg().defaultsTo("8080").ofType(Integer.class); + OptionSpec optionSpec14 = optionParser.accepts("proxyUser").withRequiredArg(); + OptionSpec optionSpec15 = optionParser.accepts("proxyPass").withRequiredArg(); + OptionSpec optionSpec16 = optionParser.accepts("username").withRequiredArg().defaultsTo("Player" + System.currentTimeMillis() % 1000L); + OptionSpec optionSpec17 = optionParser.accepts("uuid").withRequiredArg(); + OptionSpec optionSpec18 = optionParser.accepts("xuid").withOptionalArg().defaultsTo(""); + OptionSpec optionSpec19 = optionParser.accepts("clientId").withOptionalArg().defaultsTo(""); + OptionSpec optionSpec20 = optionParser.accepts("accessToken").withRequiredArg().required(); + OptionSpec optionSpec21 = optionParser.accepts("version").withRequiredArg().required(); + OptionSpec optionSpec22 = optionParser.accepts("width").withRequiredArg().ofType(Integer.class).defaultsTo(854); + OptionSpec optionSpec23 = optionParser.accepts("height").withRequiredArg().ofType(Integer.class).defaultsTo(480); + OptionSpec optionSpec24 = optionParser.accepts("fullscreenWidth").withRequiredArg().ofType(Integer.class); + OptionSpec optionSpec25 = optionParser.accepts("fullscreenHeight").withRequiredArg().ofType(Integer.class); + OptionSpec optionSpec26 = optionParser.accepts("userProperties").withRequiredArg().defaultsTo("{}"); + OptionSpec optionSpec27 = optionParser.accepts("profileProperties").withRequiredArg().defaultsTo("{}"); + OptionSpec optionSpec28 = optionParser.accepts("assetIndex").withRequiredArg(); + OptionSpec optionSpec29 = optionParser.accepts("userType").withRequiredArg().defaultsTo("legacy"); + OptionSpec optionSpec30 = optionParser.accepts("versionType").withRequiredArg().defaultsTo("release"); + OptionSpec optionSpec31 = optionParser.nonOptions(); OptionSet optionSet = optionParser.parse(strings); - File file = parseArgument(optionSet, optionSpec8); - String string = parseArgument(optionSet, optionSpec20); + File file = parseArgument(optionSet, optionSpec9); + String string = parseArgument(optionSet, optionSpec21); String string2 = "Pre-bootstrap"; Logger logger; GameConfig gameConfig; try { - if (optionSet.has(optionSpec)) { + if (optionSet.has(optionSpec2)) { JvmProfiler.INSTANCE.start(net.minecraft.util.profiling.jfr.Environment.CLIENT); } - if (optionSet.has(optionSpec2)) { + if (optionSet.has(optionSpec3)) { TracyBootstrap.setup(); } @@ -129,28 +125,28 @@ public class Main { GameLoadTimesEvent.INSTANCE.setBootstrapTime(Bootstrap.bootstrapDuration.get()); Bootstrap.validate(); string2 = "Argument parsing"; - List list = optionSet.valuesOf(optionSpec30); + List list = optionSet.valuesOf(optionSpec31); if (!list.isEmpty()) { logger.info("Completely ignored arguments: {}", list); } - String string3 = optionSpec28.value(optionSet); + String string3 = optionSpec29.value(optionSet); Type type = Type.byName(string3); if (type == null) { logger.warn("Unrecognized user type: {}", string3); } - String string4 = parseArgument(optionSet, optionSpec11); + String string4 = parseArgument(optionSet, optionSpec12); Proxy proxy = Proxy.NO_PROXY; if (string4 != null) { try { - proxy = new Proxy(java.net.Proxy.Type.SOCKS, new InetSocketAddress(string4, parseArgument(optionSet, optionSpec12))); - } catch (Exception var81) { + proxy = new Proxy(java.net.Proxy.Type.SOCKS, new InetSocketAddress(string4, parseArgument(optionSet, optionSpec13))); + } catch (Exception var83) { } } - final String string5 = parseArgument(optionSet, optionSpec13); - final String string6 = parseArgument(optionSet, optionSpec14); + final String string5 = parseArgument(optionSet, optionSpec14); + final String string6 = parseArgument(optionSet, optionSpec15); if (!proxy.equals(Proxy.NO_PROXY) && stringHasValue(string5) && stringHasValue(string6)) { Authenticator.setDefault(new Authenticator() { protected PasswordAuthentication getPasswordAuthentication() { @@ -159,45 +155,46 @@ public class Main { }); } - int i = parseArgument(optionSet, optionSpec21); - int j = parseArgument(optionSet, optionSpec22); - OptionalInt optionalInt = ofNullable(parseArgument(optionSet, optionSpec23)); - OptionalInt optionalInt2 = ofNullable(parseArgument(optionSet, optionSpec24)); + int i = parseArgument(optionSet, optionSpec22); + int j = parseArgument(optionSet, optionSpec23); + OptionalInt optionalInt = ofNullable(parseArgument(optionSet, optionSpec24)); + OptionalInt optionalInt2 = ofNullable(parseArgument(optionSet, optionSpec25)); boolean bl = optionSet.has("fullscreen"); boolean bl2 = optionSet.has("demo"); boolean bl3 = optionSet.has("disableMultiplayer"); boolean bl4 = optionSet.has("disableChat"); - boolean bl5 = !optionSet.has(optionSpec3); + boolean bl5 = !optionSet.has(optionSpec4); + boolean bl6 = optionSet.has(optionSpec); Gson gson = new GsonBuilder().registerTypeAdapter(PropertyMap.class, new Serializer()).create(); - PropertyMap propertyMap = GsonHelper.fromJson(gson, parseArgument(optionSet, optionSpec25), PropertyMap.class); - PropertyMap propertyMap2 = GsonHelper.fromJson(gson, parseArgument(optionSet, optionSpec26), PropertyMap.class); - String string7 = parseArgument(optionSet, optionSpec29); - File file2 = optionSet.has(optionSpec9) ? parseArgument(optionSet, optionSpec9) : new File(file, "assets/"); - File file3 = optionSet.has(optionSpec10) ? parseArgument(optionSet, optionSpec10) : new File(file, "resourcepacks/"); - UUID uUID = hasValidUuid(optionSpec16, optionSet, logger) - ? UndashedUuid.fromStringLenient(optionSpec16.value(optionSet)) - : UUIDUtil.createOfflinePlayerUUID(optionSpec15.value(optionSet)); - String string8 = optionSet.has(optionSpec27) ? optionSpec27.value(optionSet) : null; - String string9 = optionSet.valueOf(optionSpec17); - String string10 = optionSet.valueOf(optionSpec18); - String string11 = parseArgument(optionSet, optionSpec4); - String string12 = unescapeJavaArgument(parseArgument(optionSet, optionSpec5)); - String string13 = unescapeJavaArgument(parseArgument(optionSet, optionSpec6)); - String string14 = unescapeJavaArgument(parseArgument(optionSet, optionSpec7)); + PropertyMap propertyMap = GsonHelper.fromJson(gson, parseArgument(optionSet, optionSpec26), PropertyMap.class); + PropertyMap propertyMap2 = GsonHelper.fromJson(gson, parseArgument(optionSet, optionSpec27), PropertyMap.class); + String string7 = parseArgument(optionSet, optionSpec30); + File file2 = optionSet.has(optionSpec10) ? parseArgument(optionSet, optionSpec10) : new File(file, "assets/"); + File file3 = optionSet.has(optionSpec11) ? parseArgument(optionSet, optionSpec11) : new File(file, "resourcepacks/"); + UUID uUID = hasValidUuid(optionSpec17, optionSet, logger) + ? UndashedUuid.fromStringLenient(optionSpec17.value(optionSet)) + : UUIDUtil.createOfflinePlayerUUID(optionSpec16.value(optionSet)); + String string8 = optionSet.has(optionSpec28) ? optionSpec28.value(optionSet) : null; + String string9 = optionSet.valueOf(optionSpec18); + String string10 = optionSet.valueOf(optionSpec19); + String string11 = parseArgument(optionSet, optionSpec5); + String string12 = unescapeJavaArgument(parseArgument(optionSet, optionSpec6)); + String string13 = unescapeJavaArgument(parseArgument(optionSet, optionSpec7)); + String string14 = unescapeJavaArgument(parseArgument(optionSet, optionSpec8)); User user = new User( - optionSpec15.value(optionSet), uUID, optionSpec19.value(optionSet), emptyStringToEmptyOptional(string9), emptyStringToEmptyOptional(string10), type + optionSpec16.value(optionSet), uUID, optionSpec20.value(optionSet), emptyStringToEmptyOptional(string9), emptyStringToEmptyOptional(string10), type ); gameConfig = new GameConfig( - new UserData(user, propertyMap, propertyMap2, proxy), + new GameConfig.UserData(user, propertyMap, propertyMap2, proxy), new DisplayData(i, j, optionalInt, optionalInt2, bl), - new FolderData(file, file3, file2, string8), - new GameData(bl2, string, string7, bl3, bl4, bl5), - new QuickPlayData(string11, string12, string13, string14) + new GameConfig.FolderData(file, file3, file2, string8), + new GameConfig.GameData(bl2, string, string7, bl3, bl4, bl5, bl6), + new GameConfig.QuickPlayData(string11, string12, string13, string14) ); Util.startTimerHackThread(); completableFuture.join(); - } catch (Throwable var82) { - CrashReport crashReport = CrashReport.forThrowable(var82, string2); + } catch (Throwable var84) { + CrashReport crashReport = CrashReport.forThrowable(var84, string2); CrashReportCategory crashReportCategory = crashReport.addCategory("Initialization"); NativeModuleLister.addCrashSection(crashReportCategory); Minecraft.fillReport(null, null, string, null, crashReport); @@ -223,15 +220,13 @@ public class Main { try { Thread.currentThread().setName("Render thread"); RenderSystem.initRenderThread(); - RenderSystem.beginInitialization(); minecraft = new Minecraft(gameConfig); - RenderSystem.finishInitialization(); - } catch (SilentInitException var79) { + } catch (SilentInitException var81) { Util.shutdownExecutors(); - logger.warn("Failed to create window: ", (Throwable)var79); + logger.warn("Failed to create window: ", (Throwable)var81); return; - } catch (Throwable var80) { - CrashReport crashReport2 = CrashReport.forThrowable(var80, "Initializing game"); + } catch (Throwable var82) { + CrashReport crashReport2 = CrashReport.forThrowable(var82, "Initializing game"); CrashReportCategory crashReportCategory2 = crashReport2.addCategory("Initialization"); NativeModuleLister.addCrashSection(crashReportCategory2); Minecraft.fillReport(minecraft, null, gameConfig.game.launchVersion, null, crashReport2); @@ -241,7 +236,6 @@ public class Main { Minecraft minecraft2 = minecraft; minecraft.run(); - BufferUploader.reset(); try { minecraft2.stop(); diff --git a/net/minecraft/client/model/AbstractEquineModel.java b/net/minecraft/client/model/AbstractEquineModel.java index 7f9ef8ae..332796bd 100644 --- a/net/minecraft/client/model/AbstractEquineModel.java +++ b/net/minecraft/client/model/AbstractEquineModel.java @@ -21,13 +21,6 @@ public abstract class AbstractEquineModel extends E private static final float DEG_30 = (float) (Math.PI / 6); private static final float DEG_15 = (float) (Math.PI / 12); protected static final String HEAD_PARTS = "head_parts"; - private static final String SADDLE = "saddle"; - private static final String LEFT_SADDLE_MOUTH = "left_saddle_mouth"; - private static final String LEFT_SADDLE_LINE = "left_saddle_line"; - private static final String RIGHT_SADDLE_MOUTH = "right_saddle_mouth"; - private static final String RIGHT_SADDLE_LINE = "right_saddle_line"; - private static final String HEAD_SADDLE = "head_saddle"; - private static final String MOUTH_SADDLE_WRAP = "mouth_saddle_wrap"; protected static final MeshTransformer BABY_TRANSFORMER = new BabyModelTransform(true, 16.2F, 1.36F, 2.7272F, 2.0F, 20.0F, Set.of("head_parts")); protected final ModelPart body; protected final ModelPart headParts; @@ -36,8 +29,6 @@ public abstract class AbstractEquineModel extends E private final ModelPart rightFrontLeg; private final ModelPart leftFrontLeg; private final ModelPart tail; - private final ModelPart[] saddleParts; - private final ModelPart[] ridingParts; public AbstractEquineModel(ModelPart root) { super(root); @@ -48,15 +39,6 @@ public abstract class AbstractEquineModel extends E this.rightFrontLeg = root.getChild("right_front_leg"); this.leftFrontLeg = root.getChild("left_front_leg"); this.tail = this.body.getChild("tail"); - ModelPart modelPart = this.body.getChild("saddle"); - ModelPart modelPart2 = this.headParts.getChild("left_saddle_mouth"); - ModelPart modelPart3 = this.headParts.getChild("right_saddle_mouth"); - ModelPart modelPart4 = this.headParts.getChild("left_saddle_line"); - ModelPart modelPart5 = this.headParts.getChild("right_saddle_line"); - ModelPart modelPart6 = this.headParts.getChild("head_saddle"); - ModelPart modelPart7 = this.headParts.getChild("mouth_saddle_wrap"); - this.saddleParts = new ModelPart[]{modelPart, modelPart2, modelPart3, modelPart6, modelPart7}; - this.ridingParts = new ModelPart[]{modelPart4, modelPart5}; } public static MeshDefinition createBodyMesh(CubeDeformation cubeDeformation) { @@ -106,31 +88,6 @@ public abstract class AbstractEquineModel extends E CubeListBuilder.create().texOffs(42, 36).addBox(-1.5F, 0.0F, 0.0F, 3.0F, 14.0F, 4.0F, cubeDeformation), PartPose.offsetAndRotation(0.0F, -5.0F, 2.0F, (float) (Math.PI / 6), 0.0F, 0.0F) ); - partDefinition2.addOrReplaceChild( - "saddle", CubeListBuilder.create().texOffs(26, 0).addBox(-5.0F, -8.0F, -9.0F, 10.0F, 9.0F, 9.0F, new CubeDeformation(0.5F)), PartPose.ZERO - ); - partDefinition3.addOrReplaceChild( - "left_saddle_mouth", CubeListBuilder.create().texOffs(29, 5).addBox(2.0F, -9.0F, -6.0F, 1.0F, 2.0F, 2.0F, cubeDeformation), PartPose.ZERO - ); - partDefinition3.addOrReplaceChild( - "right_saddle_mouth", CubeListBuilder.create().texOffs(29, 5).addBox(-3.0F, -9.0F, -6.0F, 1.0F, 2.0F, 2.0F, cubeDeformation), PartPose.ZERO - ); - partDefinition3.addOrReplaceChild( - "left_saddle_line", - CubeListBuilder.create().texOffs(32, 2).addBox(3.1F, -6.0F, -8.0F, 0.0F, 3.0F, 16.0F), - PartPose.rotation((float) (-Math.PI / 6), 0.0F, 0.0F) - ); - partDefinition3.addOrReplaceChild( - "right_saddle_line", - CubeListBuilder.create().texOffs(32, 2).addBox(-3.1F, -6.0F, -8.0F, 0.0F, 3.0F, 16.0F), - PartPose.rotation((float) (-Math.PI / 6), 0.0F, 0.0F) - ); - partDefinition3.addOrReplaceChild( - "head_saddle", CubeListBuilder.create().texOffs(1, 1).addBox(-3.0F, -11.0F, -1.9F, 6.0F, 5.0F, 6.0F, new CubeDeformation(0.22F)), PartPose.ZERO - ); - partDefinition3.addOrReplaceChild( - "mouth_saddle_wrap", CubeListBuilder.create().texOffs(19, 0).addBox(-2.0F, -11.0F, -4.0F, 4.0F, 5.0F, 2.0F, new CubeDeformation(0.2F)), PartPose.ZERO - ); partDefinition4.addOrReplaceChild( "left_ear", CubeListBuilder.create().texOffs(19, 16).addBox(0.55F, -13.0F, 4.0F, 2.0F, 3.0F, 1.0F, new CubeDeformation(-0.001F)), PartPose.ZERO ); @@ -173,15 +130,6 @@ public abstract class AbstractEquineModel extends E public void setupAnim(T equineRenderState) { super.setupAnim(equineRenderState); - - for (ModelPart modelPart : this.saddleParts) { - modelPart.visible = equineRenderState.isSaddled; - } - - for (ModelPart modelPart : this.ridingParts) { - modelPart.visible = equineRenderState.isRidden && equineRenderState.isSaddled; - } - float f = Mth.clamp(equineRenderState.yRot, -20.0F, 20.0F); float g = equineRenderState.xRot * (float) (Math.PI / 180.0); float h = equineRenderState.walkAnimationSpeed; diff --git a/net/minecraft/client/model/AdultAndBabyModelPair.java b/net/minecraft/client/model/AdultAndBabyModelPair.java new file mode 100644 index 00000000..eb0bc7b5 --- /dev/null +++ b/net/minecraft/client/model/AdultAndBabyModelPair.java @@ -0,0 +1,11 @@ +package net.minecraft.client.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +public record AdultAndBabyModelPair(T adultModel, T babyModel) { + public T getModel(boolean isBaby) { + return isBaby ? this.babyModel : this.adultModel; + } +} diff --git a/net/minecraft/client/model/ArmorStandArmorModel.java b/net/minecraft/client/model/ArmorStandArmorModel.java index 7bb1c3ac..8cd07000 100644 --- a/net/minecraft/client/model/ArmorStandArmorModel.java +++ b/net/minecraft/client/model/ArmorStandArmorModel.java @@ -41,23 +41,23 @@ public class ArmorStandArmorModel extends HumanoidModel { public void setupAnim(ArmorStandRenderState armorStandRenderState) { super.setupAnim(armorStandRenderState); - this.head.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.headPose.getX(); - this.head.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.headPose.getY(); - this.head.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.headPose.getZ(); - this.body.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getX(); - this.body.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getY(); - this.body.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getZ(); - this.leftArm.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftArmPose.getX(); - this.leftArm.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftArmPose.getY(); - this.leftArm.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftArmPose.getZ(); - this.rightArm.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightArmPose.getX(); - this.rightArm.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightArmPose.getY(); - this.rightArm.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightArmPose.getZ(); - this.leftLeg.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftLegPose.getX(); - this.leftLeg.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftLegPose.getY(); - this.leftLeg.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftLegPose.getZ(); - this.rightLeg.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightLegPose.getX(); - this.rightLeg.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightLegPose.getY(); - this.rightLeg.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightLegPose.getZ(); + this.head.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.headPose.x(); + this.head.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.headPose.y(); + this.head.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.headPose.z(); + this.body.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.x(); + this.body.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.y(); + this.body.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.z(); + this.leftArm.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftArmPose.x(); + this.leftArm.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftArmPose.y(); + this.leftArm.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftArmPose.z(); + this.rightArm.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightArmPose.x(); + this.rightArm.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightArmPose.y(); + this.rightArm.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightArmPose.z(); + this.leftLeg.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftLegPose.x(); + this.leftLeg.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftLegPose.y(); + this.leftLeg.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.leftLegPose.z(); + this.rightLeg.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightLegPose.x(); + this.rightLeg.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightLegPose.y(); + this.rightLeg.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.rightLegPose.z(); } } diff --git a/net/minecraft/client/model/ArmorStandModel.java b/net/minecraft/client/model/ArmorStandModel.java index ea352b1b..dd177ccb 100644 --- a/net/minecraft/client/model/ArmorStandModel.java +++ b/net/minecraft/client/model/ArmorStandModel.java @@ -68,15 +68,15 @@ public class ArmorStandModel extends ArmorStandArmorModel { this.leftArm.visible = armorStandRenderState.showArms; this.rightArm.visible = armorStandRenderState.showArms; this.basePlate.visible = armorStandRenderState.showBasePlate; - this.rightBodyStick.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getX(); - this.rightBodyStick.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getY(); - this.rightBodyStick.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getZ(); - this.leftBodyStick.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getX(); - this.leftBodyStick.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getY(); - this.leftBodyStick.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getZ(); - this.shoulderStick.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getX(); - this.shoulderStick.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getY(); - this.shoulderStick.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.getZ(); + this.rightBodyStick.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.x(); + this.rightBodyStick.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.y(); + this.rightBodyStick.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.z(); + this.leftBodyStick.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.x(); + this.leftBodyStick.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.y(); + this.leftBodyStick.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.z(); + this.shoulderStick.xRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.x(); + this.shoulderStick.yRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.y(); + this.shoulderStick.zRot = (float) (Math.PI / 180.0) * armorStandRenderState.bodyPose.z(); } @Override diff --git a/net/minecraft/client/model/BoggedModel.java b/net/minecraft/client/model/BoggedModel.java index fea7e58d..4ab4520b 100644 --- a/net/minecraft/client/model/BoggedModel.java +++ b/net/minecraft/client/model/BoggedModel.java @@ -24,7 +24,7 @@ public class BoggedModel extends SkeletonModel { MeshDefinition meshDefinition = HumanoidModel.createMesh(CubeDeformation.NONE, 0.0F); PartDefinition partDefinition = meshDefinition.getRoot(); SkeletonModel.createDefaultSkeletonMesh(partDefinition); - PartDefinition partDefinition2 = partDefinition.getChild("head").clearChild("mushrooms"); + PartDefinition partDefinition2 = partDefinition.getChild("head").addOrReplaceChild("mushrooms", CubeListBuilder.create(), PartPose.ZERO); partDefinition2.addOrReplaceChild( "red_mushroom_1", CubeListBuilder.create().texOffs(50, 16).addBox(-3.0F, -3.0F, 0.0F, 6.0F, 4.0F, 0.0F), diff --git a/net/minecraft/client/model/CamelModel.java b/net/minecraft/client/model/CamelModel.java index e615f412..c66273f6 100644 --- a/net/minecraft/client/model/CamelModel.java +++ b/net/minecraft/client/model/CamelModel.java @@ -5,7 +5,6 @@ import net.fabricmc.api.Environment; import net.minecraft.client.animation.definitions.CamelAnimation; import net.minecraft.client.model.geom.ModelPart; import net.minecraft.client.model.geom.PartPose; -import net.minecraft.client.model.geom.builders.CubeDeformation; import net.minecraft.client.model.geom.builders.CubeListBuilder; import net.minecraft.client.model.geom.builders.LayerDefinition; import net.minecraft.client.model.geom.builders.MeshDefinition; @@ -19,25 +18,21 @@ public class CamelModel extends EntityModel { private static final float MAX_WALK_ANIMATION_SPEED = 2.0F; private static final float WALK_ANIMATION_SCALE_FACTOR = 2.5F; public static final MeshTransformer BABY_TRANSFORMER = MeshTransformer.scaling(0.45F); - private static final String SADDLE = "saddle"; - private static final String BRIDLE = "bridle"; - private static final String REINS = "reins"; - private final ModelPart head; - private final ModelPart[] saddleParts; - private final ModelPart[] ridingParts; + protected final ModelPart head; public CamelModel(ModelPart root) { super(root); ModelPart modelPart = root.getChild("body"); this.head = modelPart.getChild("head"); - this.saddleParts = new ModelPart[]{modelPart.getChild("saddle"), this.head.getChild("bridle")}; - this.ridingParts = new ModelPart[]{this.head.getChild("reins")}; } public static LayerDefinition createBodyLayer() { + return LayerDefinition.create(createBodyMesh(), 128, 128); + } + + protected static MeshDefinition createBodyMesh() { MeshDefinition meshDefinition = new MeshDefinition(); PartDefinition partDefinition = meshDefinition.getRoot(); - CubeDeformation cubeDeformation = new CubeDeformation(0.05F); PartDefinition partDefinition2 = partDefinition.addOrReplaceChild( "body", CubeListBuilder.create().texOffs(0, 25).addBox(-7.5F, -12.0F, -23.5F, 15.0F, 12.0F, 27.0F), PartPose.offset(0.0F, 4.0F, 9.5F) ); @@ -76,51 +71,12 @@ public class CamelModel extends EntityModel { partDefinition.addOrReplaceChild( "right_front_leg", CubeListBuilder.create().texOffs(0, 26).addBox(-2.5F, 2.0F, -2.5F, 5.0F, 21.0F, 5.0F), PartPose.offset(-4.9F, 1.0F, -10.5F) ); - partDefinition2.addOrReplaceChild( - "saddle", - CubeListBuilder.create() - .texOffs(74, 64) - .addBox(-4.5F, -17.0F, -15.5F, 9.0F, 5.0F, 11.0F, cubeDeformation) - .texOffs(92, 114) - .addBox(-3.5F, -20.0F, -15.5F, 7.0F, 3.0F, 11.0F, cubeDeformation) - .texOffs(0, 89) - .addBox(-7.5F, -12.0F, -23.5F, 15.0F, 12.0F, 27.0F, cubeDeformation), - PartPose.offset(0.0F, 0.0F, 0.0F) - ); - partDefinition3.addOrReplaceChild( - "reins", - CubeListBuilder.create() - .texOffs(98, 42) - .addBox(3.51F, -18.0F, -17.0F, 0.0F, 7.0F, 15.0F) - .texOffs(84, 57) - .addBox(-3.5F, -18.0F, -2.0F, 7.0F, 7.0F, 0.0F) - .texOffs(98, 42) - .addBox(-3.51F, -18.0F, -17.0F, 0.0F, 7.0F, 15.0F), - PartPose.offset(0.0F, 0.0F, 0.0F) - ); - partDefinition3.addOrReplaceChild( - "bridle", - CubeListBuilder.create() - .texOffs(60, 87) - .addBox(-3.5F, -7.0F, -15.0F, 7.0F, 8.0F, 19.0F, cubeDeformation) - .texOffs(21, 64) - .addBox(-3.5F, -21.0F, -15.0F, 7.0F, 14.0F, 7.0F, cubeDeformation) - .texOffs(50, 64) - .addBox(-2.5F, -21.0F, -21.0F, 5.0F, 5.0F, 6.0F, cubeDeformation) - .texOffs(74, 70) - .addBox(2.5F, -19.0F, -18.0F, 1.0F, 2.0F, 2.0F) - .texOffs(74, 70) - .mirror() - .addBox(-3.5F, -19.0F, -18.0F, 1.0F, 2.0F, 2.0F), - PartPose.offset(0.0F, 0.0F, 0.0F) - ); - return LayerDefinition.create(meshDefinition, 128, 128); + return meshDefinition; } public void setupAnim(CamelRenderState camelRenderState) { super.setupAnim(camelRenderState); this.applyHeadRotation(camelRenderState, camelRenderState.yRot, camelRenderState.xRot); - this.toggleInvisibleParts(camelRenderState); this.animateWalk(CamelAnimation.CAMEL_WALK, camelRenderState.walkAnimationPos, camelRenderState.walkAnimationSpeed, 2.0F, 2.5F); this.animate(camelRenderState.sitAnimationState, CamelAnimation.CAMEL_SIT, camelRenderState.ageInTicks, 1.0F); this.animate(camelRenderState.sitPoseAnimationState, CamelAnimation.CAMEL_SIT_POSE, camelRenderState.ageInTicks, 1.0F); @@ -140,17 +96,4 @@ public class CamelModel extends EntityModel { this.head.yRot = yRot * (float) (Math.PI / 180.0); this.head.xRot = xRot * (float) (Math.PI / 180.0); } - - private void toggleInvisibleParts(CamelRenderState renderState) { - boolean bl = renderState.isSaddled; - boolean bl2 = renderState.isRidden; - - for (ModelPart modelPart : this.saddleParts) { - modelPart.visible = bl; - } - - for (ModelPart modelPart : this.ridingParts) { - modelPart.visible = bl2 && bl; - } - } } diff --git a/net/minecraft/client/model/CamelSaddleModel.java b/net/minecraft/client/model/CamelSaddleModel.java new file mode 100644 index 00000000..0d2d49a2 --- /dev/null +++ b/net/minecraft/client/model/CamelSaddleModel.java @@ -0,0 +1,77 @@ +package net.minecraft.client.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.builders.CubeDeformation; +import net.minecraft.client.model.geom.builders.CubeListBuilder; +import net.minecraft.client.model.geom.builders.LayerDefinition; +import net.minecraft.client.model.geom.builders.MeshDefinition; +import net.minecraft.client.model.geom.builders.PartDefinition; +import net.minecraft.client.renderer.entity.state.CamelRenderState; + +@Environment(EnvType.CLIENT) +public class CamelSaddleModel extends CamelModel { + private static final String SADDLE = "saddle"; + private static final String BRIDLE = "bridle"; + private static final String REINS = "reins"; + private final ModelPart reins = this.head.getChild("reins"); + + public CamelSaddleModel(ModelPart modelPart) { + super(modelPart); + } + + public static LayerDefinition createSaddleLayer() { + MeshDefinition meshDefinition = createBodyMesh(); + PartDefinition partDefinition = meshDefinition.getRoot(); + PartDefinition partDefinition2 = partDefinition.getChild("body"); + PartDefinition partDefinition3 = partDefinition2.getChild("head"); + CubeDeformation cubeDeformation = new CubeDeformation(0.05F); + partDefinition2.addOrReplaceChild( + "saddle", + CubeListBuilder.create() + .texOffs(74, 64) + .addBox(-4.5F, -17.0F, -15.5F, 9.0F, 5.0F, 11.0F, cubeDeformation) + .texOffs(92, 114) + .addBox(-3.5F, -20.0F, -15.5F, 7.0F, 3.0F, 11.0F, cubeDeformation) + .texOffs(0, 89) + .addBox(-7.5F, -12.0F, -23.5F, 15.0F, 12.0F, 27.0F, cubeDeformation), + PartPose.offset(0.0F, 0.0F, 0.0F) + ); + partDefinition3.addOrReplaceChild( + "reins", + CubeListBuilder.create() + .texOffs(98, 42) + .addBox(3.51F, -18.0F, -17.0F, 0.0F, 7.0F, 15.0F) + .texOffs(84, 57) + .addBox(-3.5F, -18.0F, -2.0F, 7.0F, 7.0F, 0.0F) + .texOffs(98, 42) + .addBox(-3.51F, -18.0F, -17.0F, 0.0F, 7.0F, 15.0F), + PartPose.offset(0.0F, 0.0F, 0.0F) + ); + partDefinition3.addOrReplaceChild( + "bridle", + CubeListBuilder.create() + .texOffs(60, 87) + .addBox(-3.5F, -7.0F, -15.0F, 7.0F, 8.0F, 19.0F, cubeDeformation) + .texOffs(21, 64) + .addBox(-3.5F, -21.0F, -15.0F, 7.0F, 14.0F, 7.0F, cubeDeformation) + .texOffs(50, 64) + .addBox(-2.5F, -21.0F, -21.0F, 5.0F, 5.0F, 6.0F, cubeDeformation) + .texOffs(74, 70) + .addBox(2.5F, -19.0F, -18.0F, 1.0F, 2.0F, 2.0F) + .texOffs(74, 70) + .mirror() + .addBox(-3.5F, -19.0F, -18.0F, 1.0F, 2.0F, 2.0F), + PartPose.offset(0.0F, 0.0F, 0.0F) + ); + return LayerDefinition.create(meshDefinition, 128, 128); + } + + @Override + public void setupAnim(CamelRenderState camelRenderState) { + super.setupAnim(camelRenderState); + this.reins.visible = camelRenderState.isRidden; + } +} diff --git a/net/minecraft/client/model/ChickenModel.java b/net/minecraft/client/model/ChickenModel.java index b559a606..7658f938 100644 --- a/net/minecraft/client/model/ChickenModel.java +++ b/net/minecraft/client/model/ChickenModel.java @@ -16,7 +16,8 @@ import net.minecraft.util.Mth; @Environment(EnvType.CLIENT) public class ChickenModel extends EntityModel { public static final String RED_THING = "red_thing"; - public static final MeshTransformer BABY_TRANSFORMER = new BabyModelTransform(Set.of("head", "beak", "red_thing")); + public static final float Y_OFFSET = 16.0F; + public static final MeshTransformer BABY_TRANSFORMER = new BabyModelTransform(false, 5.0F, 2.0F, 2.0F, 1.99F, 24.0F, Set.of("head", "beak", "red_thing")); private final ModelPart head; private final ModelPart rightLeg; private final ModelPart leftLeg; @@ -33,9 +34,13 @@ public class ChickenModel extends EntityModel { } public static LayerDefinition createBodyLayer() { + MeshDefinition meshDefinition = createBaseChickenModel(); + return LayerDefinition.create(meshDefinition, 64, 32); + } + + protected static MeshDefinition createBaseChickenModel() { MeshDefinition meshDefinition = new MeshDefinition(); PartDefinition partDefinition = meshDefinition.getRoot(); - int i = 16; PartDefinition partDefinition2 = partDefinition.addOrReplaceChild( "head", CubeListBuilder.create().texOffs(0, 0).addBox(-2.0F, -6.0F, -2.0F, 4.0F, 6.0F, 3.0F), PartPose.offset(0.0F, 15.0F, -4.0F) ); @@ -55,7 +60,7 @@ public class ChickenModel extends EntityModel { partDefinition.addOrReplaceChild( "left_wing", CubeListBuilder.create().texOffs(24, 13).addBox(-1.0F, 0.0F, -3.0F, 1.0F, 4.0F, 6.0F), PartPose.offset(4.0F, 13.0F, 0.0F) ); - return LayerDefinition.create(meshDefinition, 64, 32); + return meshDefinition; } public void setupAnim(ChickenRenderState chickenRenderState) { diff --git a/net/minecraft/client/model/ColdChickenModel.java b/net/minecraft/client/model/ColdChickenModel.java new file mode 100644 index 00000000..c1af9c4f --- /dev/null +++ b/net/minecraft/client/model/ColdChickenModel.java @@ -0,0 +1,33 @@ +package net.minecraft.client.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.builders.CubeListBuilder; +import net.minecraft.client.model.geom.builders.LayerDefinition; +import net.minecraft.client.model.geom.builders.MeshDefinition; + +@Environment(EnvType.CLIENT) +public class ColdChickenModel extends ChickenModel { + public ColdChickenModel(ModelPart modelPart) { + super(modelPart); + } + + public static LayerDefinition createBodyLayer() { + MeshDefinition meshDefinition = createBaseChickenModel(); + meshDefinition.getRoot() + .addOrReplaceChild( + "body", + CubeListBuilder.create().texOffs(0, 9).addBox(-3.0F, -4.0F, -3.0F, 6.0F, 8.0F, 6.0F).texOffs(38, 9).addBox(0.0F, 3.0F, -1.0F, 0.0F, 3.0F, 5.0F), + PartPose.offsetAndRotation(0.0F, 16.0F, 0.0F, (float) (Math.PI / 2), 0.0F, 0.0F) + ); + meshDefinition.getRoot() + .addOrReplaceChild( + "head", + CubeListBuilder.create().texOffs(0, 0).addBox(-2.0F, -6.0F, -2.0F, 4.0F, 6.0F, 3.0F).texOffs(44, 0).addBox(-3.0F, -7.0F, -2.015F, 6.0F, 3.0F, 4.0F), + PartPose.offset(0.0F, 15.0F, -4.0F) + ); + return LayerDefinition.create(meshDefinition, 64, 32); + } +} diff --git a/net/minecraft/client/model/ColdCowModel.java b/net/minecraft/client/model/ColdCowModel.java new file mode 100644 index 00000000..e37f0e49 --- /dev/null +++ b/net/minecraft/client/model/ColdCowModel.java @@ -0,0 +1,51 @@ +package net.minecraft.client.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.builders.CubeDeformation; +import net.minecraft.client.model.geom.builders.CubeListBuilder; +import net.minecraft.client.model.geom.builders.LayerDefinition; +import net.minecraft.client.model.geom.builders.MeshDefinition; +import net.minecraft.client.model.geom.builders.PartDefinition; + +@Environment(EnvType.CLIENT) +public class ColdCowModel extends CowModel { + public ColdCowModel(ModelPart modelPart) { + super(modelPart); + } + + public static LayerDefinition createBodyLayer() { + MeshDefinition meshDefinition = createBaseCowModel(); + meshDefinition.getRoot() + .addOrReplaceChild( + "body", + CubeListBuilder.create() + .texOffs(20, 32) + .addBox(-6.0F, -10.0F, -7.0F, 12.0F, 18.0F, 10.0F, new CubeDeformation(0.5F)) + .texOffs(18, 4) + .addBox(-6.0F, -10.0F, -7.0F, 12.0F, 18.0F, 10.0F) + .texOffs(52, 0) + .addBox(-2.0F, 2.0F, -8.0F, 4.0F, 6.0F, 1.0F), + PartPose.offsetAndRotation(0.0F, 5.0F, 2.0F, (float) (Math.PI / 2), 0.0F, 0.0F) + ); + PartDefinition partDefinition = meshDefinition.getRoot() + .addOrReplaceChild( + "head", + CubeListBuilder.create().texOffs(0, 0).addBox(-4.0F, -4.0F, -6.0F, 8.0F, 8.0F, 6.0F).texOffs(9, 33).addBox(-3.0F, 1.0F, -7.0F, 6.0F, 3.0F, 1.0F), + PartPose.offset(0.0F, 4.0F, -8.0F) + ); + partDefinition.addOrReplaceChild( + "right_horn", + CubeListBuilder.create().texOffs(0, 40).addBox(-1.5F, -4.5F, -0.5F, 2.0F, 6.0F, 2.0F), + PartPose.offsetAndRotation(-4.5F, -2.5F, -3.5F, 1.5708F, 0.0F, 0.0F) + ); + partDefinition.addOrReplaceChild( + "left_horn", + CubeListBuilder.create().texOffs(0, 32).addBox(-1.5F, -3.0F, -0.5F, 2.0F, 6.0F, 2.0F), + PartPose.offsetAndRotation(5.5F, -2.5F, -5.0F, 1.5708F, 0.0F, 0.0F) + ); + return LayerDefinition.create(meshDefinition, 64, 64); + } +} diff --git a/net/minecraft/client/model/ColdPigModel.java b/net/minecraft/client/model/ColdPigModel.java new file mode 100644 index 00000000..81790e68 --- /dev/null +++ b/net/minecraft/client/model/ColdPigModel.java @@ -0,0 +1,33 @@ +package net.minecraft.client.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.builders.CubeDeformation; +import net.minecraft.client.model.geom.builders.CubeListBuilder; +import net.minecraft.client.model.geom.builders.LayerDefinition; +import net.minecraft.client.model.geom.builders.MeshDefinition; +import net.minecraft.client.model.geom.builders.PartDefinition; + +@Environment(EnvType.CLIENT) +public class ColdPigModel extends PigModel { + public ColdPigModel(ModelPart modelPart) { + super(modelPart); + } + + public static LayerDefinition createBodyLayer(CubeDeformation cubeDeformation) { + MeshDefinition meshDefinition = createBasePigModel(cubeDeformation); + PartDefinition partDefinition = meshDefinition.getRoot(); + partDefinition.addOrReplaceChild( + "body", + CubeListBuilder.create() + .texOffs(28, 8) + .addBox(-5.0F, -10.0F, -7.0F, 10.0F, 16.0F, 8.0F) + .texOffs(28, 32) + .addBox(-5.0F, -10.0F, -7.0F, 10.0F, 16.0F, 8.0F, new CubeDeformation(0.5F)), + PartPose.offsetAndRotation(0.0F, 11.0F, 2.0F, (float) (Math.PI / 2), 0.0F, 0.0F) + ); + return LayerDefinition.create(meshDefinition, 64, 64); + } +} diff --git a/net/minecraft/client/model/CowModel.java b/net/minecraft/client/model/CowModel.java index 7a2fe91a..c8eed884 100644 --- a/net/minecraft/client/model/CowModel.java +++ b/net/minecraft/client/model/CowModel.java @@ -14,25 +14,32 @@ import net.minecraft.client.renderer.entity.state.LivingEntityRenderState; @Environment(EnvType.CLIENT) public class CowModel extends QuadrupedModel { - public static final MeshTransformer BABY_TRANSFORMER = new BabyModelTransform(false, 10.0F, 4.0F, Set.of("head")); + public static final MeshTransformer BABY_TRANSFORMER = new BabyModelTransform(false, 8.0F, 6.0F, Set.of("head")); + private static final int LEG_SIZE = 12; public CowModel(ModelPart root) { super(root); } public static LayerDefinition createBodyLayer() { + MeshDefinition meshDefinition = createBaseCowModel(); + return LayerDefinition.create(meshDefinition, 64, 64); + } + + static MeshDefinition createBaseCowModel() { MeshDefinition meshDefinition = new MeshDefinition(); PartDefinition partDefinition = meshDefinition.getRoot(); - int i = 12; partDefinition.addOrReplaceChild( "head", CubeListBuilder.create() .texOffs(0, 0) .addBox(-4.0F, -4.0F, -6.0F, 8.0F, 8.0F, 6.0F) + .texOffs(1, 33) + .addBox(-3.0F, 1.0F, -7.0F, 6.0F, 3.0F, 1.0F) .texOffs(22, 0) - .addBox("right_horn", -5.0F, -5.0F, -4.0F, 1.0F, 3.0F, 1.0F) + .addBox("right_horn", -5.0F, -5.0F, -5.0F, 1.0F, 3.0F, 1.0F) .texOffs(22, 0) - .addBox("left_horn", 4.0F, -5.0F, -4.0F, 1.0F, 3.0F, 1.0F), + .addBox("left_horn", 4.0F, -5.0F, -5.0F, 1.0F, 3.0F, 1.0F), PartPose.offset(0.0F, 4.0F, -8.0F) ); partDefinition.addOrReplaceChild( @@ -40,12 +47,13 @@ public class CowModel extends QuadrupedModel { CubeListBuilder.create().texOffs(18, 4).addBox(-6.0F, -10.0F, -7.0F, 12.0F, 18.0F, 10.0F).texOffs(52, 0).addBox(-2.0F, 2.0F, -8.0F, 4.0F, 6.0F, 1.0F), PartPose.offsetAndRotation(0.0F, 5.0F, 2.0F, (float) (Math.PI / 2), 0.0F, 0.0F) ); - CubeListBuilder cubeListBuilder = CubeListBuilder.create().texOffs(0, 16).addBox(-2.0F, 0.0F, -2.0F, 4.0F, 12.0F, 4.0F); - partDefinition.addOrReplaceChild("right_hind_leg", cubeListBuilder, PartPose.offset(-4.0F, 12.0F, 7.0F)); + CubeListBuilder cubeListBuilder = CubeListBuilder.create().mirror().texOffs(0, 16).addBox(-2.0F, 0.0F, -2.0F, 4.0F, 12.0F, 4.0F); + CubeListBuilder cubeListBuilder2 = CubeListBuilder.create().texOffs(0, 16).addBox(-2.0F, 0.0F, -2.0F, 4.0F, 12.0F, 4.0F); + partDefinition.addOrReplaceChild("right_hind_leg", cubeListBuilder2, PartPose.offset(-4.0F, 12.0F, 7.0F)); partDefinition.addOrReplaceChild("left_hind_leg", cubeListBuilder, PartPose.offset(4.0F, 12.0F, 7.0F)); - partDefinition.addOrReplaceChild("right_front_leg", cubeListBuilder, PartPose.offset(-4.0F, 12.0F, -6.0F)); - partDefinition.addOrReplaceChild("left_front_leg", cubeListBuilder, PartPose.offset(4.0F, 12.0F, -6.0F)); - return LayerDefinition.create(meshDefinition, 64, 32); + partDefinition.addOrReplaceChild("right_front_leg", cubeListBuilder2, PartPose.offset(-4.0F, 12.0F, -5.0F)); + partDefinition.addOrReplaceChild("left_front_leg", cubeListBuilder, PartPose.offset(4.0F, 12.0F, -5.0F)); + return meshDefinition; } public ModelPart getHead() { diff --git a/net/minecraft/client/model/DonkeyModel.java b/net/minecraft/client/model/DonkeyModel.java index 918a1976..7c47776c 100644 --- a/net/minecraft/client/model/DonkeyModel.java +++ b/net/minecraft/client/model/DonkeyModel.java @@ -7,7 +7,6 @@ import net.minecraft.client.model.geom.PartPose; import net.minecraft.client.model.geom.builders.CubeDeformation; import net.minecraft.client.model.geom.builders.CubeListBuilder; import net.minecraft.client.model.geom.builders.LayerDefinition; -import net.minecraft.client.model.geom.builders.MeshDefinition; import net.minecraft.client.model.geom.builders.MeshTransformer; import net.minecraft.client.model.geom.builders.PartDefinition; import net.minecraft.client.renderer.entity.state.DonkeyRenderState; @@ -16,6 +15,10 @@ import net.minecraft.client.renderer.entity.state.DonkeyRenderState; public class DonkeyModel extends AbstractEquineModel { public static final float DONKEY_SCALE = 0.87F; public static final float MULE_SCALE = 0.92F; + private static final MeshTransformer DONKEY_TRANSFORMER = meshDefinition -> { + modifyMesh(meshDefinition.getRoot()); + return meshDefinition; + }; private final ModelPart leftChest = this.body.getChild("left_chest"); private final ModelPart rightChest = this.body.getChild("right_chest"); @@ -24,15 +27,23 @@ public class DonkeyModel extends AbstractEquineModel { } public static LayerDefinition createBodyLayer(float scale) { - MeshDefinition meshDefinition = AbstractEquineModel.createBodyMesh(CubeDeformation.NONE); - modifyMesh(meshDefinition.getRoot()); - return LayerDefinition.create(meshDefinition, 64, 64).apply(MeshTransformer.scaling(scale)); + return LayerDefinition.create(AbstractEquineModel.createBodyMesh(CubeDeformation.NONE), 64, 64) + .apply(DONKEY_TRANSFORMER) + .apply(MeshTransformer.scaling(scale)); } public static LayerDefinition createBabyLayer(float scale) { - MeshDefinition meshDefinition = AbstractEquineModel.createFullScaleBabyMesh(CubeDeformation.NONE); - modifyMesh(meshDefinition.getRoot()); - return LayerDefinition.create(AbstractEquineModel.BABY_TRANSFORMER.apply(meshDefinition), 64, 64).apply(MeshTransformer.scaling(scale)); + return LayerDefinition.create(AbstractEquineModel.createFullScaleBabyMesh(CubeDeformation.NONE), 64, 64) + .apply(DONKEY_TRANSFORMER) + .apply(BABY_TRANSFORMER) + .apply(MeshTransformer.scaling(scale)); + } + + public static LayerDefinition createSaddleLayer(float scale, boolean isBaby) { + return EquineSaddleModel.createFullScaleSaddleLayer(isBaby) + .apply(DONKEY_TRANSFORMER) + .apply(isBaby ? AbstractEquineModel.BABY_TRANSFORMER : MeshTransformer.IDENTITY) + .apply(MeshTransformer.scaling(scale)); } private static void modifyMesh(PartDefinition partDefinition) { diff --git a/net/minecraft/client/model/EquineSaddleModel.java b/net/minecraft/client/model/EquineSaddleModel.java new file mode 100644 index 00000000..b4d1c90c --- /dev/null +++ b/net/minecraft/client/model/EquineSaddleModel.java @@ -0,0 +1,74 @@ +package net.minecraft.client.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.builders.CubeDeformation; +import net.minecraft.client.model.geom.builders.CubeListBuilder; +import net.minecraft.client.model.geom.builders.LayerDefinition; +import net.minecraft.client.model.geom.builders.MeshDefinition; +import net.minecraft.client.model.geom.builders.MeshTransformer; +import net.minecraft.client.model.geom.builders.PartDefinition; +import net.minecraft.client.renderer.entity.state.EquineRenderState; + +@Environment(EnvType.CLIENT) +public class EquineSaddleModel extends AbstractEquineModel { + private static final String SADDLE = "saddle"; + private static final String LEFT_SADDLE_MOUTH = "left_saddle_mouth"; + private static final String LEFT_SADDLE_LINE = "left_saddle_line"; + private static final String RIGHT_SADDLE_MOUTH = "right_saddle_mouth"; + private static final String RIGHT_SADDLE_LINE = "right_saddle_line"; + private static final String HEAD_SADDLE = "head_saddle"; + private static final String MOUTH_SADDLE_WRAP = "mouth_saddle_wrap"; + private final ModelPart[] ridingParts; + + public EquineSaddleModel(ModelPart modelPart) { + super(modelPart); + ModelPart modelPart2 = this.headParts.getChild("left_saddle_line"); + ModelPart modelPart3 = this.headParts.getChild("right_saddle_line"); + this.ridingParts = new ModelPart[]{modelPart2, modelPart3}; + } + + public static LayerDefinition createSaddleLayer(boolean isBaby) { + return createFullScaleSaddleLayer(isBaby).apply(isBaby ? BABY_TRANSFORMER : MeshTransformer.IDENTITY); + } + + public static LayerDefinition createFullScaleSaddleLayer(boolean isBaby) { + MeshDefinition meshDefinition = isBaby ? createFullScaleBabyMesh(CubeDeformation.NONE) : createBodyMesh(CubeDeformation.NONE); + PartDefinition partDefinition = meshDefinition.getRoot(); + PartDefinition partDefinition2 = partDefinition.getChild("body"); + PartDefinition partDefinition3 = partDefinition.getChild("head_parts"); + partDefinition2.addOrReplaceChild( + "saddle", CubeListBuilder.create().texOffs(26, 0).addBox(-5.0F, -8.0F, -9.0F, 10.0F, 9.0F, 9.0F, new CubeDeformation(0.5F)), PartPose.ZERO + ); + partDefinition3.addOrReplaceChild("left_saddle_mouth", CubeListBuilder.create().texOffs(29, 5).addBox(2.0F, -9.0F, -6.0F, 1.0F, 2.0F, 2.0F), PartPose.ZERO); + partDefinition3.addOrReplaceChild("right_saddle_mouth", CubeListBuilder.create().texOffs(29, 5).addBox(-3.0F, -9.0F, -6.0F, 1.0F, 2.0F, 2.0F), PartPose.ZERO); + partDefinition3.addOrReplaceChild( + "left_saddle_line", + CubeListBuilder.create().texOffs(32, 2).addBox(3.1F, -6.0F, -8.0F, 0.0F, 3.0F, 16.0F), + PartPose.rotation((float) (-Math.PI / 6), 0.0F, 0.0F) + ); + partDefinition3.addOrReplaceChild( + "right_saddle_line", + CubeListBuilder.create().texOffs(32, 2).addBox(-3.1F, -6.0F, -8.0F, 0.0F, 3.0F, 16.0F), + PartPose.rotation((float) (-Math.PI / 6), 0.0F, 0.0F) + ); + partDefinition3.addOrReplaceChild( + "head_saddle", CubeListBuilder.create().texOffs(1, 1).addBox(-3.0F, -11.0F, -1.9F, 6.0F, 5.0F, 6.0F, new CubeDeformation(0.22F)), PartPose.ZERO + ); + partDefinition3.addOrReplaceChild( + "mouth_saddle_wrap", CubeListBuilder.create().texOffs(19, 0).addBox(-2.0F, -11.0F, -4.0F, 4.0F, 5.0F, 2.0F, new CubeDeformation(0.2F)), PartPose.ZERO + ); + return LayerDefinition.create(meshDefinition, 64, 64); + } + + @Override + public void setupAnim(EquineRenderState equineRenderState) { + super.setupAnim(equineRenderState); + + for (ModelPart modelPart : this.ridingParts) { + modelPart.visible = equineRenderState.isRidden; + } + } +} diff --git a/net/minecraft/client/model/PigModel.java b/net/minecraft/client/model/PigModel.java index 6f31cedc..6c65b433 100644 --- a/net/minecraft/client/model/PigModel.java +++ b/net/minecraft/client/model/PigModel.java @@ -22,6 +22,10 @@ public class PigModel extends QuadrupedModel { } public static LayerDefinition createBodyLayer(CubeDeformation cubeDeformation) { + return LayerDefinition.create(createBasePigModel(cubeDeformation), 64, 64); + } + + protected static MeshDefinition createBasePigModel(CubeDeformation cubeDeformation) { MeshDefinition meshDefinition = QuadrupedModel.createBodyMesh(6, cubeDeformation); PartDefinition partDefinition = meshDefinition.getRoot(); partDefinition.addOrReplaceChild( @@ -33,6 +37,6 @@ public class PigModel extends QuadrupedModel { .addBox(-2.0F, 0.0F, -9.0F, 4.0F, 3.0F, 1.0F, cubeDeformation), PartPose.offset(0.0F, 12.0F, -6.0F) ); - return LayerDefinition.create(meshDefinition, 64, 32); + return meshDefinition; } } diff --git a/net/minecraft/client/model/PolarBearModel.java b/net/minecraft/client/model/PolarBearModel.java index 7677c108..9f6de027 100644 --- a/net/minecraft/client/model/PolarBearModel.java +++ b/net/minecraft/client/model/PolarBearModel.java @@ -15,13 +15,13 @@ import net.minecraft.client.renderer.entity.state.PolarBearRenderState; @Environment(EnvType.CLIENT) public class PolarBearModel extends QuadrupedModel { private static final float BABY_HEAD_SCALE = 2.25F; - public static final MeshTransformer BABY_TRANSFORMER = new BabyModelTransform(true, 16.0F, 4.0F, 2.25F, 2.0F, 24.0F, Set.of("head")); + private static final MeshTransformer BABY_TRANSFORMER = new BabyModelTransform(true, 16.0F, 4.0F, 2.25F, 2.0F, 24.0F, Set.of("head")); public PolarBearModel(ModelPart root) { super(root); } - public static LayerDefinition createBodyLayer() { + public static LayerDefinition createBodyLayer(boolean isBaby) { MeshDefinition meshDefinition = new MeshDefinition(); PartDefinition partDefinition = meshDefinition.getRoot(); partDefinition.addOrReplaceChild( @@ -50,7 +50,7 @@ public class PolarBearModel extends QuadrupedModel { CubeListBuilder cubeListBuilder2 = CubeListBuilder.create().texOffs(50, 40).addBox(-2.0F, 0.0F, -2.0F, 4.0F, 10.0F, 6.0F); partDefinition.addOrReplaceChild("right_front_leg", cubeListBuilder2, PartPose.offset(-3.5F, 14.0F, -8.0F)); partDefinition.addOrReplaceChild("left_front_leg", cubeListBuilder2, PartPose.offset(3.5F, 14.0F, -8.0F)); - return LayerDefinition.create(meshDefinition, 128, 64).apply(MeshTransformer.scaling(1.2F)); + return LayerDefinition.create(meshDefinition, 128, 64).apply(isBaby ? BABY_TRANSFORMER : MeshTransformer.IDENTITY).apply(MeshTransformer.scaling(1.2F)); } public void setupAnim(PolarBearRenderState polarBearRenderState) { diff --git a/net/minecraft/client/model/WarmCowModel.java b/net/minecraft/client/model/WarmCowModel.java new file mode 100644 index 00000000..c8f6a462 --- /dev/null +++ b/net/minecraft/client/model/WarmCowModel.java @@ -0,0 +1,43 @@ +package net.minecraft.client.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.model.geom.ModelPart; +import net.minecraft.client.model.geom.PartPose; +import net.minecraft.client.model.geom.builders.CubeListBuilder; +import net.minecraft.client.model.geom.builders.LayerDefinition; +import net.minecraft.client.model.geom.builders.MeshDefinition; + +@Environment(EnvType.CLIENT) +public class WarmCowModel extends CowModel { + public WarmCowModel(ModelPart modelPart) { + super(modelPart); + } + + public static LayerDefinition createBodyLayer() { + MeshDefinition meshDefinition = createBaseCowModel(); + meshDefinition.getRoot() + .addOrReplaceChild( + "head", + CubeListBuilder.create() + .texOffs(0, 0) + .addBox(-4.0F, -4.0F, -6.0F, 8.0F, 8.0F, 6.0F) + .texOffs(1, 33) + .addBox(-3.0F, 1.0F, -7.0F, 6.0F, 3.0F, 1.0F) + .texOffs(27, 0) + .addBox(-8.0F, -3.0F, -5.0F, 4.0F, 2.0F, 2.0F) + .texOffs(39, 0) + .addBox(-8.0F, -5.0F, -5.0F, 2.0F, 2.0F, 2.0F) + .texOffs(27, 0) + .mirror() + .addBox(4.0F, -3.0F, -5.0F, 4.0F, 2.0F, 2.0F) + .mirror(false) + .texOffs(39, 0) + .mirror() + .addBox(6.0F, -5.0F, -5.0F, 2.0F, 2.0F, 2.0F) + .mirror(false), + PartPose.offset(0.0F, 4.0F, -8.0F) + ); + return LayerDefinition.create(meshDefinition, 64, 64); + } +} diff --git a/net/minecraft/client/model/geom/LayerDefinitions.java b/net/minecraft/client/model/geom/LayerDefinitions.java index 59cb1dae..5b539a04 100644 --- a/net/minecraft/client/model/geom/LayerDefinitions.java +++ b/net/minecraft/client/model/geom/LayerDefinitions.java @@ -26,10 +26,14 @@ import net.minecraft.client.model.BoggedModel; import net.minecraft.client.model.BookModel; import net.minecraft.client.model.BreezeModel; import net.minecraft.client.model.CamelModel; +import net.minecraft.client.model.CamelSaddleModel; import net.minecraft.client.model.CatModel; import net.minecraft.client.model.ChestModel; import net.minecraft.client.model.ChickenModel; import net.minecraft.client.model.CodModel; +import net.minecraft.client.model.ColdChickenModel; +import net.minecraft.client.model.ColdCowModel; +import net.minecraft.client.model.ColdPigModel; import net.minecraft.client.model.CowModel; import net.minecraft.client.model.CreakingModel; import net.minecraft.client.model.CreeperModel; @@ -40,6 +44,7 @@ import net.minecraft.client.model.ElytraModel; import net.minecraft.client.model.EndCrystalModel; import net.minecraft.client.model.EndermanModel; import net.minecraft.client.model.EndermiteModel; +import net.minecraft.client.model.EquineSaddleModel; import net.minecraft.client.model.EvokerFangsModel; import net.minecraft.client.model.FelineModel; import net.minecraft.client.model.FoxModel; @@ -97,6 +102,7 @@ import net.minecraft.client.model.TurtleModel; import net.minecraft.client.model.VexModel; import net.minecraft.client.model.VillagerModel; import net.minecraft.client.model.WardenModel; +import net.minecraft.client.model.WarmCowModel; import net.minecraft.client.model.WindChargeModel; import net.minecraft.client.model.WitchModel; import net.minecraft.client.model.WitherBossModel; @@ -131,62 +137,67 @@ public class LayerDefinitions { LayerDefinition layerDefinition6 = SkullModel.createMobHeadLayer(); LayerDefinition layerDefinition7 = LayerDefinition.create(AbstractEquineModel.createBodyMesh(CubeDeformation.NONE), 64, 64); LayerDefinition layerDefinition8 = LayerDefinition.create(AbstractEquineModel.createBabyMesh(CubeDeformation.NONE), 64, 64); + LayerDefinition layerDefinition9 = EquineSaddleModel.createSaddleLayer(false); + LayerDefinition layerDefinition10 = EquineSaddleModel.createSaddleLayer(true); MeshTransformer meshTransformer = MeshTransformer.scaling(0.9375F); - LayerDefinition layerDefinition9 = IllagerModel.createBodyLayer().apply(meshTransformer); - LayerDefinition layerDefinition10 = AxolotlModel.createBodyLayer(); - LayerDefinition layerDefinition11 = BeeModel.createBodyLayer(); - LayerDefinition layerDefinition12 = CowModel.createBodyLayer(); - LayerDefinition layerDefinition13 = layerDefinition12.apply(CowModel.BABY_TRANSFORMER); - LayerDefinition layerDefinition14 = ElytraModel.createLayer(); - LayerDefinition layerDefinition15 = LayerDefinition.create(FelineModel.createBodyMesh(CubeDeformation.NONE), 64, 32); - LayerDefinition layerDefinition16 = layerDefinition15.apply(FelineModel.BABY_TRANSFORMER); - LayerDefinition layerDefinition17 = LayerDefinition.create(FelineModel.createBodyMesh(new CubeDeformation(0.01F)), 64, 32); - LayerDefinition layerDefinition18 = LayerDefinition.create(PiglinModel.createMesh(CubeDeformation.NONE), 64, 64); - LayerDefinition layerDefinition19 = LayerDefinition.create(PiglinHeadModel.createHeadModel(), 64, 64); - LayerDefinition layerDefinition20 = SkullModel.createHumanoidHeadLayer(); - LayerDefinition layerDefinition21 = LlamaModel.createBodyLayer(CubeDeformation.NONE); - LayerDefinition layerDefinition22 = LlamaModel.createBodyLayer(new CubeDeformation(0.5F)); - LayerDefinition layerDefinition23 = StriderModel.createBodyLayer(); - LayerDefinition layerDefinition24 = HoglinModel.createBodyLayer(); - LayerDefinition layerDefinition25 = HoglinModel.createBabyLayer(); - LayerDefinition layerDefinition26 = SkeletonModel.createBodyLayer(); - LayerDefinition layerDefinition27 = LayerDefinition.create(VillagerModel.createBodyModel(), 64, 64).apply(meshTransformer); - LayerDefinition layerDefinition28 = SpiderModel.createSpiderBodyLayer(); - LayerDefinition layerDefinition29 = ArmadilloModel.createBodyLayer(); - LayerDefinition layerDefinition30 = CamelModel.createBodyLayer(); - LayerDefinition layerDefinition31 = ChickenModel.createBodyLayer(); - LayerDefinition layerDefinition32 = GoatModel.createBodyLayer(); - LayerDefinition layerDefinition33 = PandaModel.createBodyLayer(); - LayerDefinition layerDefinition34 = PigModel.createBodyLayer(CubeDeformation.NONE); - LayerDefinition layerDefinition35 = PigModel.createBodyLayer(new CubeDeformation(0.5F)); - LayerDefinition layerDefinition36 = PolarBearModel.createBodyLayer(); - LayerDefinition layerDefinition37 = SheepModel.createBodyLayer(); - LayerDefinition layerDefinition38 = SheepFurModel.createFurLayer(); - LayerDefinition layerDefinition39 = SnifferModel.createBodyLayer(); - LayerDefinition layerDefinition40 = TurtleModel.createBodyLayer(); - LayerDefinition layerDefinition41 = LayerDefinition.create(WolfModel.createMeshDefinition(CubeDeformation.NONE), 64, 32); - LayerDefinition layerDefinition42 = LayerDefinition.create(WolfModel.createMeshDefinition(new CubeDeformation(0.2F)), 64, 32); - LayerDefinition layerDefinition43 = ZombieVillagerModel.createBodyLayer(); - LayerDefinition layerDefinition44 = ArmorStandModel.createBodyLayer(); - LayerDefinition layerDefinition45 = ArmorStandArmorModel.createBodyLayer(INNER_ARMOR_DEFORMATION); - LayerDefinition layerDefinition46 = ArmorStandArmorModel.createBodyLayer(OUTER_ARMOR_DEFORMATION); - LayerDefinition layerDefinition47 = DrownedModel.createBodyLayer(CubeDeformation.NONE); - LayerDefinition layerDefinition48 = DrownedModel.createBodyLayer(new CubeDeformation(0.25F)); - LayerDefinition layerDefinition49 = SquidModel.createBodyLayer(); - LayerDefinition layerDefinition50 = DolphinModel.createBodyLayer(); - LayerDefinition layerDefinition51 = SalmonModel.createBodyLayer(); + LayerDefinition layerDefinition11 = IllagerModel.createBodyLayer().apply(meshTransformer); + LayerDefinition layerDefinition12 = AxolotlModel.createBodyLayer(); + LayerDefinition layerDefinition13 = BeeModel.createBodyLayer(); + LayerDefinition layerDefinition14 = CowModel.createBodyLayer(); + LayerDefinition layerDefinition15 = ColdChickenModel.createBodyLayer(); + LayerDefinition layerDefinition16 = ColdCowModel.createBodyLayer(); + LayerDefinition layerDefinition17 = ColdPigModel.createBodyLayer(CubeDeformation.NONE); + LayerDefinition layerDefinition18 = ElytraModel.createLayer(); + LayerDefinition layerDefinition19 = LayerDefinition.create(FelineModel.createBodyMesh(CubeDeformation.NONE), 64, 32); + LayerDefinition layerDefinition20 = layerDefinition19.apply(FelineModel.BABY_TRANSFORMER); + LayerDefinition layerDefinition21 = LayerDefinition.create(FelineModel.createBodyMesh(new CubeDeformation(0.01F)), 64, 32); + LayerDefinition layerDefinition22 = LayerDefinition.create(PiglinModel.createMesh(CubeDeformation.NONE), 64, 64); + LayerDefinition layerDefinition23 = LayerDefinition.create(PiglinHeadModel.createHeadModel(), 64, 64); + LayerDefinition layerDefinition24 = SkullModel.createHumanoidHeadLayer(); + LayerDefinition layerDefinition25 = LlamaModel.createBodyLayer(CubeDeformation.NONE); + LayerDefinition layerDefinition26 = LlamaModel.createBodyLayer(new CubeDeformation(0.5F)); + LayerDefinition layerDefinition27 = StriderModel.createBodyLayer(); + LayerDefinition layerDefinition28 = HoglinModel.createBodyLayer(); + LayerDefinition layerDefinition29 = HoglinModel.createBabyLayer(); + LayerDefinition layerDefinition30 = SkeletonModel.createBodyLayer(); + LayerDefinition layerDefinition31 = LayerDefinition.create(VillagerModel.createBodyModel(), 64, 64).apply(meshTransformer); + LayerDefinition layerDefinition32 = SpiderModel.createSpiderBodyLayer(); + LayerDefinition layerDefinition33 = ArmadilloModel.createBodyLayer(); + LayerDefinition layerDefinition34 = CamelModel.createBodyLayer(); + LayerDefinition layerDefinition35 = CamelSaddleModel.createSaddleLayer(); + LayerDefinition layerDefinition36 = ChickenModel.createBodyLayer(); + LayerDefinition layerDefinition37 = GoatModel.createBodyLayer(); + LayerDefinition layerDefinition38 = PandaModel.createBodyLayer(); + LayerDefinition layerDefinition39 = PigModel.createBodyLayer(CubeDeformation.NONE); + LayerDefinition layerDefinition40 = PigModel.createBodyLayer(new CubeDeformation(0.5F)); + LayerDefinition layerDefinition41 = SheepModel.createBodyLayer(); + LayerDefinition layerDefinition42 = SheepFurModel.createFurLayer(); + LayerDefinition layerDefinition43 = SnifferModel.createBodyLayer(); + LayerDefinition layerDefinition44 = TurtleModel.createBodyLayer(); + LayerDefinition layerDefinition45 = WarmCowModel.createBodyLayer(); + LayerDefinition layerDefinition46 = LayerDefinition.create(WolfModel.createMeshDefinition(CubeDeformation.NONE), 64, 32); + LayerDefinition layerDefinition47 = LayerDefinition.create(WolfModel.createMeshDefinition(new CubeDeformation(0.2F)), 64, 32); + LayerDefinition layerDefinition48 = ZombieVillagerModel.createBodyLayer(); + LayerDefinition layerDefinition49 = ArmorStandModel.createBodyLayer(); + LayerDefinition layerDefinition50 = ArmorStandArmorModel.createBodyLayer(INNER_ARMOR_DEFORMATION); + LayerDefinition layerDefinition51 = ArmorStandArmorModel.createBodyLayer(OUTER_ARMOR_DEFORMATION); + LayerDefinition layerDefinition52 = DrownedModel.createBodyLayer(CubeDeformation.NONE); + LayerDefinition layerDefinition53 = DrownedModel.createBodyLayer(new CubeDeformation(0.25F)); + LayerDefinition layerDefinition54 = SquidModel.createBodyLayer(); + LayerDefinition layerDefinition55 = DolphinModel.createBodyLayer(); + LayerDefinition layerDefinition56 = SalmonModel.createBodyLayer(); builder.put(ModelLayers.ALLAY, AllayModel.createBodyLayer()); - builder.put(ModelLayers.ARMADILLO, layerDefinition29); - builder.put(ModelLayers.ARMADILLO_BABY, layerDefinition29.apply(ArmadilloModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.ARMOR_STAND, layerDefinition44); - builder.put(ModelLayers.ARMOR_STAND_INNER_ARMOR, layerDefinition45); - builder.put(ModelLayers.ARMOR_STAND_OUTER_ARMOR, layerDefinition46); - builder.put(ModelLayers.ARMOR_STAND_SMALL, layerDefinition44.apply(HumanoidModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.ARMOR_STAND_SMALL_INNER_ARMOR, layerDefinition45.apply(HumanoidModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.ARMOR_STAND_SMALL_OUTER_ARMOR, layerDefinition46.apply(HumanoidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.ARMADILLO, layerDefinition33); + builder.put(ModelLayers.ARMADILLO_BABY, layerDefinition33.apply(ArmadilloModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.ARMOR_STAND, layerDefinition49); + builder.put(ModelLayers.ARMOR_STAND_INNER_ARMOR, layerDefinition50); + builder.put(ModelLayers.ARMOR_STAND_OUTER_ARMOR, layerDefinition51); + builder.put(ModelLayers.ARMOR_STAND_SMALL, layerDefinition49.apply(HumanoidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.ARMOR_STAND_SMALL_INNER_ARMOR, layerDefinition50.apply(HumanoidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.ARMOR_STAND_SMALL_OUTER_ARMOR, layerDefinition51.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ARROW, ArrowModel.createBodyLayer()); - builder.put(ModelLayers.AXOLOTL, layerDefinition10); - builder.put(ModelLayers.AXOLOTL_BABY, layerDefinition10.apply(AxolotlModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.AXOLOTL, layerDefinition12); + builder.put(ModelLayers.AXOLOTL_BABY, layerDefinition12.apply(AxolotlModel.BABY_TRANSFORMER)); builder.put(ModelLayers.STANDING_BANNER, BannerModel.createBodyLayer(true)); builder.put(ModelLayers.WALL_BANNER, BannerModel.createBodyLayer(false)); builder.put(ModelLayers.STANDING_BANNER_FLAG, BannerFlagModel.createFlagLayer(true)); @@ -194,8 +205,8 @@ public class LayerDefinitions { builder.put(ModelLayers.BAT, BatModel.createBodyLayer()); builder.put(ModelLayers.BED_FOOT, BedRenderer.createFootLayer()); builder.put(ModelLayers.BED_HEAD, BedRenderer.createHeadLayer()); - builder.put(ModelLayers.BEE, layerDefinition11); - builder.put(ModelLayers.BEE_BABY, layerDefinition11.apply(BeeModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.BEE, layerDefinition13); + builder.put(ModelLayers.BEE_BABY, layerDefinition13.apply(BeeModel.BABY_TRANSFORMER)); builder.put(ModelLayers.BEE_STINGER, BeeStingerModel.createBodyLayer()); builder.put(ModelLayers.BELL, BellModel.createBodyLayer()); builder.put(ModelLayers.BLAZE, BlazeModel.createBodyLayer()); @@ -207,54 +218,64 @@ public class LayerDefinitions { builder.put(ModelLayers.BOOK, BookModel.createBodyLayer()); builder.put(ModelLayers.BREEZE, BreezeModel.createBodyLayer(32, 32)); builder.put(ModelLayers.BREEZE_WIND, BreezeModel.createBodyLayer(128, 128)); - builder.put(ModelLayers.CAT, layerDefinition15.apply(CatModel.CAT_TRANSFORMER)); - builder.put(ModelLayers.CAT_BABY, layerDefinition16.apply(CatModel.CAT_TRANSFORMER)); - builder.put(ModelLayers.CAT_COLLAR, layerDefinition17.apply(CatModel.CAT_TRANSFORMER)); - builder.put(ModelLayers.CAT_BABY_COLLAR, layerDefinition17.apply(FelineModel.BABY_TRANSFORMER).apply(CatModel.CAT_TRANSFORMER)); - builder.put(ModelLayers.CAMEL, layerDefinition30); - builder.put(ModelLayers.CAMEL_BABY, layerDefinition30.apply(CamelModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.CAVE_SPIDER, layerDefinition28.apply(MeshTransformer.scaling(0.7F))); + builder.put(ModelLayers.CAT, layerDefinition19.apply(CatModel.CAT_TRANSFORMER)); + builder.put(ModelLayers.CAT_BABY, layerDefinition20.apply(CatModel.CAT_TRANSFORMER)); + builder.put(ModelLayers.CAT_COLLAR, layerDefinition21.apply(CatModel.CAT_TRANSFORMER)); + builder.put(ModelLayers.CAT_BABY_COLLAR, layerDefinition21.apply(FelineModel.BABY_TRANSFORMER).apply(CatModel.CAT_TRANSFORMER)); + builder.put(ModelLayers.CAMEL, layerDefinition34); + builder.put(ModelLayers.CAMEL_BABY, layerDefinition34.apply(CamelModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.CAMEL_SADDLE, layerDefinition35); + builder.put(ModelLayers.CAMEL_BABY_SADDLE, layerDefinition35.apply(CamelModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.CAVE_SPIDER, layerDefinition32.apply(MeshTransformer.scaling(0.7F))); builder.put(ModelLayers.CHEST, ChestModel.createSingleBodyLayer()); builder.put(ModelLayers.CHEST_MINECART, layerDefinition5); - builder.put(ModelLayers.CHICKEN, layerDefinition31); - builder.put(ModelLayers.CHICKEN_BABY, layerDefinition31.apply(ChickenModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.CHICKEN, layerDefinition36); + builder.put(ModelLayers.CHICKEN_BABY, layerDefinition36.apply(ChickenModel.BABY_TRANSFORMER)); builder.put(ModelLayers.COD, CodModel.createBodyLayer()); + builder.put(ModelLayers.COLD_CHICKEN, layerDefinition15); + builder.put(ModelLayers.COLD_CHICKEN_BABY, layerDefinition15.apply(ChickenModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.COLD_COW, layerDefinition16); + builder.put(ModelLayers.COLD_COW_BABY, layerDefinition16.apply(CowModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.COLD_PIG, layerDefinition17); + builder.put(ModelLayers.COLD_PIG_BABY, layerDefinition17.apply(PigModel.BABY_TRANSFORMER)); builder.put(ModelLayers.COMMAND_BLOCK_MINECART, layerDefinition5); builder.put(ModelLayers.CONDUIT_EYE, ConduitRenderer.createEyeLayer()); builder.put(ModelLayers.CONDUIT_WIND, ConduitRenderer.createWindLayer()); builder.put(ModelLayers.CONDUIT_SHELL, ConduitRenderer.createShellLayer()); builder.put(ModelLayers.CONDUIT_CAGE, ConduitRenderer.createCageLayer()); - builder.put(ModelLayers.COW, layerDefinition12); - builder.put(ModelLayers.COW_BABY, layerDefinition13); + builder.put(ModelLayers.COW, layerDefinition14); + builder.put(ModelLayers.COW_BABY, layerDefinition14.apply(CowModel.BABY_TRANSFORMER)); builder.put(ModelLayers.CREAKING, CreakingModel.createBodyLayer()); builder.put(ModelLayers.CREEPER, CreeperModel.createBodyLayer(CubeDeformation.NONE)); builder.put(ModelLayers.CREEPER_ARMOR, CreeperModel.createBodyLayer(new CubeDeformation(2.0F))); builder.put(ModelLayers.CREEPER_HEAD, layerDefinition6); builder.put(ModelLayers.DECORATED_POT_BASE, DecoratedPotRenderer.createBaseLayer()); builder.put(ModelLayers.DECORATED_POT_SIDES, DecoratedPotRenderer.createSidesLayer()); - builder.put(ModelLayers.DOLPHIN, layerDefinition50); - builder.put(ModelLayers.DOLPHIN_BABY, layerDefinition50.apply(DolphinModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.DOLPHIN, layerDefinition55); + builder.put(ModelLayers.DOLPHIN_BABY, layerDefinition55.apply(DolphinModel.BABY_TRANSFORMER)); builder.put(ModelLayers.DONKEY, DonkeyModel.createBodyLayer(0.87F)); builder.put(ModelLayers.DONKEY_BABY, DonkeyModel.createBabyLayer(0.87F)); + builder.put(ModelLayers.DONKEY_SADDLE, DonkeyModel.createSaddleLayer(0.87F, false)); + builder.put(ModelLayers.DONKEY_BABY_SADDLE, DonkeyModel.createSaddleLayer(0.87F, true)); builder.put(ModelLayers.DOUBLE_CHEST_LEFT, ChestModel.createDoubleBodyLeftLayer()); builder.put(ModelLayers.DOUBLE_CHEST_RIGHT, ChestModel.createDoubleBodyRightLayer()); builder.put(ModelLayers.DRAGON_SKULL, DragonHeadModel.createHeadLayer()); - builder.put(ModelLayers.DROWNED, layerDefinition47); + builder.put(ModelLayers.DROWNED, layerDefinition52); builder.put(ModelLayers.DROWNED_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.DROWNED_OUTER_ARMOR, layerDefinition4); - builder.put(ModelLayers.DROWNED_OUTER_LAYER, layerDefinition48); - builder.put(ModelLayers.DROWNED_BABY, layerDefinition47.apply(HumanoidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.DROWNED_OUTER_LAYER, layerDefinition53); + builder.put(ModelLayers.DROWNED_BABY, layerDefinition52.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.DROWNED_BABY_INNER_ARMOR, layerDefinition4.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.DROWNED_BABY_OUTER_ARMOR, layerDefinition4.apply(HumanoidModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.DROWNED_BABY_OUTER_LAYER, layerDefinition48.apply(HumanoidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.DROWNED_BABY_OUTER_LAYER, layerDefinition53.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ELDER_GUARDIAN, GuardianModel.createElderGuardianLayer()); - builder.put(ModelLayers.ELYTRA, layerDefinition14); - builder.put(ModelLayers.ELYTRA_BABY, layerDefinition14.apply(ElytraModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.ELYTRA, layerDefinition18); + builder.put(ModelLayers.ELYTRA_BABY, layerDefinition18.apply(ElytraModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ENDERMAN, EndermanModel.createBodyLayer()); builder.put(ModelLayers.ENDERMITE, EndermiteModel.createBodyLayer()); builder.put(ModelLayers.ENDER_DRAGON, EnderDragonModel.createBodyLayer()); builder.put(ModelLayers.END_CRYSTAL, EndCrystalModel.createBodyLayer()); - builder.put(ModelLayers.EVOKER, layerDefinition9); + builder.put(ModelLayers.EVOKER, layerDefinition11); builder.put(ModelLayers.EVOKER_FANGS, EvokerFangsModel.createBodyLayer()); builder.put(ModelLayers.FOX, FoxModel.createBodyLayer()); builder.put(ModelLayers.FOX_BABY, FoxModel.createBodyLayer().apply(FoxModel.BABY_TRANSFORMER)); @@ -265,13 +286,13 @@ public class LayerDefinitions { builder.put(ModelLayers.GIANT, layerDefinition.apply(meshTransformer2)); builder.put(ModelLayers.GIANT_INNER_ARMOR, layerDefinition4.apply(meshTransformer2)); builder.put(ModelLayers.GIANT_OUTER_ARMOR, layerDefinition2.apply(meshTransformer2)); - builder.put(ModelLayers.GLOW_SQUID, layerDefinition49); - builder.put(ModelLayers.GLOW_SQUID_BABY, layerDefinition49.apply(SquidModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.GOAT, layerDefinition32); - builder.put(ModelLayers.GOAT_BABY, layerDefinition32.apply(GoatModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.GLOW_SQUID, layerDefinition54); + builder.put(ModelLayers.GLOW_SQUID_BABY, layerDefinition54.apply(SquidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.GOAT, layerDefinition37); + builder.put(ModelLayers.GOAT_BABY, layerDefinition37.apply(GoatModel.BABY_TRANSFORMER)); builder.put(ModelLayers.GUARDIAN, GuardianModel.createBodyLayer()); - builder.put(ModelLayers.HOGLIN, layerDefinition24); - builder.put(ModelLayers.HOGLIN_BABY, layerDefinition25); + builder.put(ModelLayers.HOGLIN, layerDefinition28); + builder.put(ModelLayers.HOGLIN_BABY, layerDefinition29); builder.put(ModelLayers.HOPPER_MINECART, layerDefinition5); MeshTransformer meshTransformer3 = MeshTransformer.scaling(1.1F); builder.put(ModelLayers.HORSE, layerDefinition7.apply(meshTransformer3)); @@ -280,6 +301,8 @@ public class LayerDefinitions { builder.put( ModelLayers.HORSE_BABY_ARMOR, LayerDefinition.create(AbstractEquineModel.createBabyMesh(new CubeDeformation(0.1F)), 64, 64).apply(meshTransformer3) ); + builder.put(ModelLayers.HORSE_SADDLE, layerDefinition9.apply(meshTransformer3)); + builder.put(ModelLayers.HORSE_BABY_SADDLE, layerDefinition10.apply(meshTransformer3)); MeshTransformer meshTransformer4 = MeshTransformer.scaling(1.0625F); builder.put(ModelLayers.HUSK, layerDefinition.apply(meshTransformer4)); builder.put(ModelLayers.HUSK_INNER_ARMOR, layerDefinition4.apply(meshTransformer4)); @@ -287,175 +310,185 @@ public class LayerDefinitions { builder.put(ModelLayers.HUSK_BABY, layerDefinition.apply(HumanoidModel.BABY_TRANSFORMER).apply(meshTransformer4)); builder.put(ModelLayers.HUSK_BABY_INNER_ARMOR, layerDefinition4.apply(HumanoidModel.BABY_TRANSFORMER).apply(meshTransformer4)); builder.put(ModelLayers.HUSK_BABY_OUTER_ARMOR, layerDefinition2.apply(HumanoidModel.BABY_TRANSFORMER).apply(meshTransformer4)); - builder.put(ModelLayers.ILLUSIONER, layerDefinition9); + builder.put(ModelLayers.ILLUSIONER, layerDefinition11); builder.put(ModelLayers.IRON_GOLEM, IronGolemModel.createBodyLayer()); builder.put(ModelLayers.LEASH_KNOT, LeashKnotModel.createBodyLayer()); - builder.put(ModelLayers.LLAMA, layerDefinition21); - builder.put(ModelLayers.LLAMA_BABY, layerDefinition21.apply(LlamaModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.LLAMA_DECOR, layerDefinition22); - builder.put(ModelLayers.LLAMA_BABY_DECOR, layerDefinition22.apply(LlamaModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.LLAMA, layerDefinition25); + builder.put(ModelLayers.LLAMA_BABY, layerDefinition25.apply(LlamaModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.LLAMA_DECOR, layerDefinition26); + builder.put(ModelLayers.LLAMA_BABY_DECOR, layerDefinition26.apply(LlamaModel.BABY_TRANSFORMER)); builder.put(ModelLayers.LLAMA_SPIT, LlamaSpitModel.createBodyLayer()); builder.put(ModelLayers.MAGMA_CUBE, LavaSlimeModel.createBodyLayer()); builder.put(ModelLayers.MINECART, layerDefinition5); - builder.put(ModelLayers.MOOSHROOM, layerDefinition12); - builder.put(ModelLayers.MOOSHROOM_BABY, layerDefinition13); + builder.put(ModelLayers.MOOSHROOM, layerDefinition14); + builder.put(ModelLayers.MOOSHROOM_BABY, layerDefinition14.apply(CowModel.BABY_TRANSFORMER)); builder.put(ModelLayers.MULE, DonkeyModel.createBodyLayer(0.92F)); builder.put(ModelLayers.MULE_BABY, DonkeyModel.createBabyLayer(0.92F)); - builder.put(ModelLayers.OCELOT, layerDefinition15); - builder.put(ModelLayers.OCELOT_BABY, layerDefinition16); - builder.put(ModelLayers.PANDA, layerDefinition33); - builder.put(ModelLayers.PANDA_BABY, layerDefinition33.apply(PandaModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.MULE_SADDLE, DonkeyModel.createSaddleLayer(0.92F, false)); + builder.put(ModelLayers.MULE_BABY_SADDLE, DonkeyModel.createSaddleLayer(0.92F, true)); + builder.put(ModelLayers.OCELOT, layerDefinition19); + builder.put(ModelLayers.OCELOT_BABY, layerDefinition20); + builder.put(ModelLayers.PANDA, layerDefinition38); + builder.put(ModelLayers.PANDA_BABY, layerDefinition38.apply(PandaModel.BABY_TRANSFORMER)); builder.put(ModelLayers.PARROT, ParrotModel.createBodyLayer()); builder.put(ModelLayers.PHANTOM, PhantomModel.createBodyLayer()); - builder.put(ModelLayers.PIG, layerDefinition34); - builder.put(ModelLayers.PIG_BABY, layerDefinition34.apply(PigModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.PIG_SADDLE, layerDefinition35); - builder.put(ModelLayers.PIG_BABY_SADDLE, layerDefinition35.apply(PigModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.PIGLIN, layerDefinition18); + builder.put(ModelLayers.PIG, layerDefinition39); + builder.put(ModelLayers.PIG_BABY, layerDefinition39.apply(PigModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.PIG_SADDLE, layerDefinition40); + builder.put(ModelLayers.PIG_BABY_SADDLE, layerDefinition40.apply(PigModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.PIGLIN, layerDefinition22); builder.put(ModelLayers.PIGLIN_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.PIGLIN_OUTER_ARMOR, layerDefinition3); - builder.put(ModelLayers.PIGLIN_BRUTE, layerDefinition18); + builder.put(ModelLayers.PIGLIN_BRUTE, layerDefinition22); builder.put(ModelLayers.PIGLIN_BRUTE_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.PIGLIN_BRUTE_OUTER_ARMOR, layerDefinition3); - builder.put(ModelLayers.PIGLIN_BABY, layerDefinition18.apply(HumanoidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.PIGLIN_BABY, layerDefinition22.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.PIGLIN_BABY_INNER_ARMOR, layerDefinition4.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.PIGLIN_BABY_OUTER_ARMOR, layerDefinition3.apply(HumanoidModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.PIGLIN_HEAD, layerDefinition19); - builder.put(ModelLayers.PILLAGER, layerDefinition9); + builder.put(ModelLayers.PIGLIN_HEAD, layerDefinition23); + builder.put(ModelLayers.PILLAGER, layerDefinition11); builder.put(ModelLayers.PLAYER, LayerDefinition.create(PlayerModel.createMesh(CubeDeformation.NONE, false), 64, 64)); builder.put(ModelLayers.PLAYER_EARS, PlayerEarsModel.createEarsLayer()); builder.put(ModelLayers.PLAYER_CAPE, PlayerCapeModel.createCapeLayer()); - builder.put(ModelLayers.PLAYER_HEAD, layerDefinition20); + builder.put(ModelLayers.PLAYER_HEAD, layerDefinition24); builder.put(ModelLayers.PLAYER_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.PLAYER_OUTER_ARMOR, layerDefinition2); builder.put(ModelLayers.PLAYER_SLIM, LayerDefinition.create(PlayerModel.createMesh(CubeDeformation.NONE, true), 64, 64)); builder.put(ModelLayers.PLAYER_SLIM_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.PLAYER_SLIM_OUTER_ARMOR, layerDefinition2); builder.put(ModelLayers.PLAYER_SPIN_ATTACK, SpinAttackEffectModel.createLayer()); - builder.put(ModelLayers.POLAR_BEAR, layerDefinition36); - builder.put(ModelLayers.POLAR_BEAR_BABY, layerDefinition36.apply(PolarBearModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.POLAR_BEAR, PolarBearModel.createBodyLayer(false)); + builder.put(ModelLayers.POLAR_BEAR_BABY, PolarBearModel.createBodyLayer(true)); builder.put(ModelLayers.PUFFERFISH_BIG, PufferfishBigModel.createBodyLayer()); builder.put(ModelLayers.PUFFERFISH_MEDIUM, PufferfishMidModel.createBodyLayer()); builder.put(ModelLayers.PUFFERFISH_SMALL, PufferfishSmallModel.createBodyLayer()); builder.put(ModelLayers.RABBIT, RabbitModel.createBodyLayer(false)); builder.put(ModelLayers.RABBIT_BABY, RabbitModel.createBodyLayer(true)); builder.put(ModelLayers.RAVAGER, RavagerModel.createBodyLayer()); - builder.put(ModelLayers.SALMON, layerDefinition51); - builder.put(ModelLayers.SALMON_SMALL, layerDefinition51.apply(SalmonModel.SMALL_TRANSFORMER)); - builder.put(ModelLayers.SALMON_LARGE, layerDefinition51.apply(SalmonModel.LARGE_TRANSFORMER)); - builder.put(ModelLayers.SHEEP, layerDefinition37); - builder.put(ModelLayers.SHEEP_BABY, layerDefinition37.apply(SheepModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.SHEEP_WOOL, layerDefinition38); - builder.put(ModelLayers.SHEEP_BABY_WOOL, layerDefinition38.apply(SheepModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.SALMON, layerDefinition56); + builder.put(ModelLayers.SALMON_SMALL, layerDefinition56.apply(SalmonModel.SMALL_TRANSFORMER)); + builder.put(ModelLayers.SALMON_LARGE, layerDefinition56.apply(SalmonModel.LARGE_TRANSFORMER)); + builder.put(ModelLayers.SHEEP, layerDefinition41); + builder.put(ModelLayers.SHEEP_BABY, layerDefinition41.apply(SheepModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.SHEEP_WOOL, layerDefinition42); + builder.put(ModelLayers.SHEEP_BABY_WOOL, layerDefinition42.apply(SheepModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.SHEEP_WOOL_UNDERCOAT, layerDefinition41); + builder.put(ModelLayers.SHEEP_BABY_WOOL_UNDERCOAT, layerDefinition41.apply(SheepModel.BABY_TRANSFORMER)); builder.put(ModelLayers.SHIELD, ShieldModel.createLayer()); builder.put(ModelLayers.SHULKER, ShulkerModel.createBodyLayer()); builder.put(ModelLayers.SHULKER_BOX, ShulkerModel.createBoxLayer()); builder.put(ModelLayers.SHULKER_BULLET, ShulkerBulletModel.createBodyLayer()); builder.put(ModelLayers.SILVERFISH, SilverfishModel.createBodyLayer()); - builder.put(ModelLayers.SKELETON, layerDefinition26); + builder.put(ModelLayers.SKELETON, layerDefinition30); builder.put(ModelLayers.SKELETON_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.SKELETON_OUTER_ARMOR, layerDefinition2); builder.put(ModelLayers.SKELETON_HORSE, layerDefinition7); builder.put(ModelLayers.SKELETON_HORSE_BABY, layerDefinition8); + builder.put(ModelLayers.SKELETON_HORSE_SADDLE, layerDefinition9); + builder.put(ModelLayers.SKELETON_HORSE_BABY_SADDLE, layerDefinition10); builder.put(ModelLayers.SKELETON_SKULL, layerDefinition6); builder.put(ModelLayers.SLIME, SlimeModel.createInnerBodyLayer()); builder.put(ModelLayers.SLIME_OUTER, SlimeModel.createOuterBodyLayer()); - builder.put(ModelLayers.SNIFFER, layerDefinition39); - builder.put(ModelLayers.SNIFFER_BABY, layerDefinition39.apply(SnifferModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.SNIFFER, layerDefinition43); + builder.put(ModelLayers.SNIFFER_BABY, layerDefinition43.apply(SnifferModel.BABY_TRANSFORMER)); builder.put(ModelLayers.SNOW_GOLEM, SnowGolemModel.createBodyLayer()); builder.put(ModelLayers.SPAWNER_MINECART, layerDefinition5); - builder.put(ModelLayers.SPIDER, layerDefinition28); - builder.put(ModelLayers.SQUID, layerDefinition49); - builder.put(ModelLayers.SQUID_BABY, layerDefinition49.apply(SquidModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.STRAY, layerDefinition26); + builder.put(ModelLayers.SPIDER, layerDefinition32); + builder.put(ModelLayers.SQUID, layerDefinition54); + builder.put(ModelLayers.SQUID_BABY, layerDefinition54.apply(SquidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.STRAY, layerDefinition30); builder.put(ModelLayers.STRAY_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.STRAY_OUTER_ARMOR, layerDefinition2); builder.put(ModelLayers.STRAY_OUTER_LAYER, LayerDefinition.create(HumanoidModel.createMesh(new CubeDeformation(0.25F), 0.0F), 64, 32)); - builder.put(ModelLayers.STRIDER, layerDefinition23); - builder.put(ModelLayers.STRIDER_SADDLE, layerDefinition23); - builder.put(ModelLayers.STRIDER_BABY, layerDefinition23.apply(StriderModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.STRIDER_BABY_SADDLE, layerDefinition23.apply(StriderModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.STRIDER, layerDefinition27); + builder.put(ModelLayers.STRIDER_SADDLE, layerDefinition27); + builder.put(ModelLayers.STRIDER_BABY, layerDefinition27.apply(StriderModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.STRIDER_BABY_SADDLE, layerDefinition27.apply(StriderModel.BABY_TRANSFORMER)); builder.put(ModelLayers.TADPOLE, TadpoleModel.createBodyLayer()); builder.put(ModelLayers.TNT_MINECART, layerDefinition5); - builder.put(ModelLayers.TRADER_LLAMA, layerDefinition21); - builder.put(ModelLayers.TRADER_LLAMA_BABY, layerDefinition21.apply(LlamaModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.TRADER_LLAMA, layerDefinition25); + builder.put(ModelLayers.TRADER_LLAMA_BABY, layerDefinition25.apply(LlamaModel.BABY_TRANSFORMER)); builder.put(ModelLayers.TRIDENT, TridentModel.createLayer()); builder.put(ModelLayers.TROPICAL_FISH_LARGE, TropicalFishModelB.createBodyLayer(CubeDeformation.NONE)); builder.put(ModelLayers.TROPICAL_FISH_LARGE_PATTERN, TropicalFishModelB.createBodyLayer(FISH_PATTERN_DEFORMATION)); builder.put(ModelLayers.TROPICAL_FISH_SMALL, TropicalFishModelA.createBodyLayer(CubeDeformation.NONE)); builder.put(ModelLayers.TROPICAL_FISH_SMALL_PATTERN, TropicalFishModelA.createBodyLayer(FISH_PATTERN_DEFORMATION)); - builder.put(ModelLayers.TURTLE, layerDefinition40); - builder.put(ModelLayers.TURTLE_BABY, layerDefinition40.apply(TurtleModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.TURTLE, layerDefinition44); + builder.put(ModelLayers.TURTLE_BABY, layerDefinition44.apply(TurtleModel.BABY_TRANSFORMER)); builder.put(ModelLayers.VEX, VexModel.createBodyLayer()); - builder.put(ModelLayers.VILLAGER, layerDefinition27); - builder.put(ModelLayers.VILLAGER_BABY, layerDefinition27.apply(VillagerModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.VINDICATOR, layerDefinition9); + builder.put(ModelLayers.VILLAGER, layerDefinition31); + builder.put(ModelLayers.VILLAGER_BABY, layerDefinition31.apply(VillagerModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.VINDICATOR, layerDefinition11); builder.put(ModelLayers.WARDEN, WardenModel.createBodyLayer()); - builder.put(ModelLayers.WANDERING_TRADER, layerDefinition27); + builder.put(ModelLayers.WARM_COW, layerDefinition45); + builder.put(ModelLayers.WARM_COW_BABY, layerDefinition45.apply(CowModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.WANDERING_TRADER, layerDefinition31); builder.put(ModelLayers.WIND_CHARGE, WindChargeModel.createBodyLayer()); builder.put(ModelLayers.WITCH, WitchModel.createBodyLayer().apply(meshTransformer)); builder.put(ModelLayers.WITHER, WitherBossModel.createBodyLayer(CubeDeformation.NONE)); builder.put(ModelLayers.WITHER_ARMOR, WitherBossModel.createBodyLayer(INNER_ARMOR_DEFORMATION)); builder.put(ModelLayers.WITHER_SKULL, WitherSkullRenderer.createSkullLayer()); MeshTransformer meshTransformer5 = MeshTransformer.scaling(1.2F); - builder.put(ModelLayers.WITHER_SKELETON, layerDefinition26.apply(meshTransformer5)); + builder.put(ModelLayers.WITHER_SKELETON, layerDefinition30.apply(meshTransformer5)); builder.put(ModelLayers.WITHER_SKELETON_INNER_ARMOR, layerDefinition4.apply(meshTransformer5)); builder.put(ModelLayers.WITHER_SKELETON_OUTER_ARMOR, layerDefinition2.apply(meshTransformer5)); builder.put(ModelLayers.WITHER_SKELETON_SKULL, layerDefinition6); - builder.put(ModelLayers.WOLF, layerDefinition41); - builder.put(ModelLayers.WOLF_ARMOR, layerDefinition42); - builder.put(ModelLayers.WOLF_BABY, layerDefinition41.apply(WolfModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.WOLF_BABY_ARMOR, layerDefinition42.apply(WolfModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.ZOGLIN, layerDefinition24); - builder.put(ModelLayers.ZOGLIN_BABY, layerDefinition25); + builder.put(ModelLayers.WOLF, layerDefinition46); + builder.put(ModelLayers.WOLF_ARMOR, layerDefinition47); + builder.put(ModelLayers.WOLF_BABY, layerDefinition46.apply(WolfModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.WOLF_BABY_ARMOR, layerDefinition47.apply(WolfModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.ZOGLIN, layerDefinition28); + builder.put(ModelLayers.ZOGLIN_BABY, layerDefinition29); builder.put(ModelLayers.ZOMBIE, layerDefinition); builder.put(ModelLayers.ZOMBIE_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.ZOMBIE_OUTER_ARMOR, layerDefinition2); builder.put(ModelLayers.ZOMBIE_BABY, layerDefinition.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ZOMBIE_BABY_INNER_ARMOR, layerDefinition4.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ZOMBIE_BABY_OUTER_ARMOR, layerDefinition2.apply(HumanoidModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.ZOMBIE_HEAD, layerDefinition20); + builder.put(ModelLayers.ZOMBIE_HEAD, layerDefinition24); builder.put(ModelLayers.ZOMBIE_HORSE, layerDefinition7); builder.put(ModelLayers.ZOMBIE_HORSE_BABY, layerDefinition8); - builder.put(ModelLayers.ZOMBIE_VILLAGER, layerDefinition43); + builder.put(ModelLayers.ZOMBIE_HORSE_SADDLE, layerDefinition9); + builder.put(ModelLayers.ZOMBIE_HORSE_BABY_SADDLE, layerDefinition10); + builder.put(ModelLayers.ZOMBIE_VILLAGER, layerDefinition48); builder.put(ModelLayers.ZOMBIE_VILLAGER_INNER_ARMOR, ZombieVillagerModel.createArmorLayer(INNER_ARMOR_DEFORMATION)); builder.put(ModelLayers.ZOMBIE_VILLAGER_OUTER_ARMOR, ZombieVillagerModel.createArmorLayer(OUTER_ARMOR_DEFORMATION)); - builder.put(ModelLayers.ZOMBIE_VILLAGER_BABY, layerDefinition43.apply(HumanoidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.ZOMBIE_VILLAGER_BABY, layerDefinition48.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ZOMBIE_VILLAGER_BABY_INNER_ARMOR, ZombieVillagerModel.createArmorLayer(INNER_ARMOR_DEFORMATION).apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ZOMBIE_VILLAGER_BABY_OUTER_ARMOR, ZombieVillagerModel.createArmorLayer(OUTER_ARMOR_DEFORMATION).apply(HumanoidModel.BABY_TRANSFORMER)); - builder.put(ModelLayers.ZOMBIFIED_PIGLIN, layerDefinition18); + builder.put(ModelLayers.ZOMBIFIED_PIGLIN, layerDefinition22); builder.put(ModelLayers.ZOMBIFIED_PIGLIN_INNER_ARMOR, layerDefinition4); builder.put(ModelLayers.ZOMBIFIED_PIGLIN_OUTER_ARMOR, layerDefinition3); - builder.put(ModelLayers.ZOMBIFIED_PIGLIN_BABY, layerDefinition18.apply(HumanoidModel.BABY_TRANSFORMER)); + builder.put(ModelLayers.ZOMBIFIED_PIGLIN_BABY, layerDefinition22.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ZOMBIFIED_PIGLIN_BABY_INNER_ARMOR, layerDefinition4.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.ZOMBIFIED_PIGLIN_BABY_OUTER_ARMOR, layerDefinition3.apply(HumanoidModel.BABY_TRANSFORMER)); builder.put(ModelLayers.BAMBOO_RAFT, RaftModel.createRaftModel()); builder.put(ModelLayers.BAMBOO_CHEST_RAFT, RaftModel.createChestRaftModel()); - LayerDefinition layerDefinition52 = BoatModel.createBoatModel(); - LayerDefinition layerDefinition53 = BoatModel.createChestBoatModel(); - builder.put(ModelLayers.OAK_BOAT, layerDefinition52); - builder.put(ModelLayers.OAK_CHEST_BOAT, layerDefinition53); - builder.put(ModelLayers.SPRUCE_BOAT, layerDefinition52); - builder.put(ModelLayers.SPRUCE_CHEST_BOAT, layerDefinition53); - builder.put(ModelLayers.BIRCH_BOAT, layerDefinition52); - builder.put(ModelLayers.BIRCH_CHEST_BOAT, layerDefinition53); - builder.put(ModelLayers.JUNGLE_BOAT, layerDefinition52); - builder.put(ModelLayers.JUNGLE_CHEST_BOAT, layerDefinition53); - builder.put(ModelLayers.ACACIA_BOAT, layerDefinition52); - builder.put(ModelLayers.ACACIA_CHEST_BOAT, layerDefinition53); - builder.put(ModelLayers.CHERRY_BOAT, layerDefinition52); - builder.put(ModelLayers.CHERRY_CHEST_BOAT, layerDefinition53); - builder.put(ModelLayers.DARK_OAK_BOAT, layerDefinition52); - builder.put(ModelLayers.DARK_OAK_CHEST_BOAT, layerDefinition53); - builder.put(ModelLayers.PALE_OAK_BOAT, layerDefinition52); - builder.put(ModelLayers.PALE_OAK_CHEST_BOAT, layerDefinition53); - builder.put(ModelLayers.MANGROVE_BOAT, layerDefinition52); - builder.put(ModelLayers.MANGROVE_CHEST_BOAT, layerDefinition53); - LayerDefinition layerDefinition54 = SignRenderer.createSignLayer(true); - LayerDefinition layerDefinition55 = SignRenderer.createSignLayer(false); + LayerDefinition layerDefinition57 = BoatModel.createBoatModel(); + LayerDefinition layerDefinition58 = BoatModel.createChestBoatModel(); + builder.put(ModelLayers.OAK_BOAT, layerDefinition57); + builder.put(ModelLayers.OAK_CHEST_BOAT, layerDefinition58); + builder.put(ModelLayers.SPRUCE_BOAT, layerDefinition57); + builder.put(ModelLayers.SPRUCE_CHEST_BOAT, layerDefinition58); + builder.put(ModelLayers.BIRCH_BOAT, layerDefinition57); + builder.put(ModelLayers.BIRCH_CHEST_BOAT, layerDefinition58); + builder.put(ModelLayers.JUNGLE_BOAT, layerDefinition57); + builder.put(ModelLayers.JUNGLE_CHEST_BOAT, layerDefinition58); + builder.put(ModelLayers.ACACIA_BOAT, layerDefinition57); + builder.put(ModelLayers.ACACIA_CHEST_BOAT, layerDefinition58); + builder.put(ModelLayers.CHERRY_BOAT, layerDefinition57); + builder.put(ModelLayers.CHERRY_CHEST_BOAT, layerDefinition58); + builder.put(ModelLayers.DARK_OAK_BOAT, layerDefinition57); + builder.put(ModelLayers.DARK_OAK_CHEST_BOAT, layerDefinition58); + builder.put(ModelLayers.PALE_OAK_BOAT, layerDefinition57); + builder.put(ModelLayers.PALE_OAK_CHEST_BOAT, layerDefinition58); + builder.put(ModelLayers.MANGROVE_BOAT, layerDefinition57); + builder.put(ModelLayers.MANGROVE_CHEST_BOAT, layerDefinition58); + LayerDefinition layerDefinition59 = SignRenderer.createSignLayer(true); + LayerDefinition layerDefinition60 = SignRenderer.createSignLayer(false); WoodType.values().forEach(woodType -> { - builder.put(ModelLayers.createStandingSignModelName(woodType), layerDefinition54); - builder.put(ModelLayers.createWallSignModelName(woodType), layerDefinition55); + builder.put(ModelLayers.createStandingSignModelName(woodType), layerDefinition59); + builder.put(ModelLayers.createWallSignModelName(woodType), layerDefinition60); for (HangingSignRenderer.AttachmentType attachmentType : HangingSignRenderer.AttachmentType.values()) { LayerDefinition layerDefinition3x = HangingSignRenderer.createHangingSignLayer(attachmentType); diff --git a/net/minecraft/client/model/geom/ModelLayers.java b/net/minecraft/client/model/geom/ModelLayers.java index 485fa91e..bb5061e0 100644 --- a/net/minecraft/client/model/geom/ModelLayers.java +++ b/net/minecraft/client/model/geom/ModelLayers.java @@ -53,6 +53,8 @@ public class ModelLayers { public static final ModelLayerLocation BREEZE_WIND = register("breeze_wind"); public static final ModelLayerLocation CAMEL = register("camel"); public static final ModelLayerLocation CAMEL_BABY = register("camel_baby"); + public static final ModelLayerLocation CAMEL_SADDLE = register("camel", "saddle"); + public static final ModelLayerLocation CAMEL_BABY_SADDLE = register("camel_baby", "saddle"); public static final ModelLayerLocation CAT = register("cat"); public static final ModelLayerLocation CAT_BABY = register("cat_baby"); public static final ModelLayerLocation CAT_BABY_COLLAR = register("cat_baby", "collar"); @@ -65,6 +67,12 @@ public class ModelLayers { public static final ModelLayerLocation CHICKEN = register("chicken"); public static final ModelLayerLocation CHICKEN_BABY = register("chicken_baby"); public static final ModelLayerLocation COD = register("cod"); + public static final ModelLayerLocation COLD_CHICKEN = register("cold_chicken"); + public static final ModelLayerLocation COLD_CHICKEN_BABY = register("cold_chicken_baby"); + public static final ModelLayerLocation COLD_COW = register("cold_cow"); + public static final ModelLayerLocation COLD_COW_BABY = register("cold_cow_baby"); + public static final ModelLayerLocation COLD_PIG = register("cold_pig"); + public static final ModelLayerLocation COLD_PIG_BABY = register("cold_pig_baby"); public static final ModelLayerLocation COMMAND_BLOCK_MINECART = register("command_block_minecart"); public static final ModelLayerLocation CONDUIT_CAGE = register("conduit", "cage"); public static final ModelLayerLocation CONDUIT_EYE = register("conduit", "eye"); @@ -84,6 +92,8 @@ public class ModelLayers { public static final ModelLayerLocation DOLPHIN_BABY = register("dolphin_baby"); public static final ModelLayerLocation DONKEY = register("donkey"); public static final ModelLayerLocation DONKEY_BABY = register("donkey_baby"); + public static final ModelLayerLocation DONKEY_SADDLE = register("donkey", "saddle"); + public static final ModelLayerLocation DONKEY_BABY_SADDLE = register("donkey_baby", "saddle"); public static final ModelLayerLocation DOUBLE_CHEST_LEFT = register("double_chest_left"); public static final ModelLayerLocation DOUBLE_CHEST_RIGHT = register("double_chest_right"); public static final ModelLayerLocation DRAGON_SKULL = register("dragon_skull"); @@ -122,8 +132,10 @@ public class ModelLayers { public static final ModelLayerLocation HOPPER_MINECART = register("hopper_minecart"); public static final ModelLayerLocation HORSE = register("horse"); public static final ModelLayerLocation HORSE_ARMOR = register("horse_armor"); + public static final ModelLayerLocation HORSE_SADDLE = register("horse", "saddle"); public static final ModelLayerLocation HORSE_BABY = register("horse_baby"); public static final ModelLayerLocation HORSE_BABY_ARMOR = register("horse_armor_baby"); + public static final ModelLayerLocation HORSE_BABY_SADDLE = register("horse_baby", "saddle"); public static final ModelLayerLocation HUSK = register("husk"); public static final ModelLayerLocation HUSK_BABY = register("husk_baby"); public static final ModelLayerLocation HUSK_BABY_INNER_ARMOR = registerInnerArmor("husk_baby"); @@ -148,6 +160,8 @@ public class ModelLayers { public static final ModelLayerLocation MOOSHROOM_BABY = register("mooshroom_baby"); public static final ModelLayerLocation MULE = register("mule"); public static final ModelLayerLocation MULE_BABY = register("mule_baby"); + public static final ModelLayerLocation MULE_SADDLE = register("mule", "saddle"); + public static final ModelLayerLocation MULE_BABY_SADDLE = register("mule_baby", "saddle"); public static final ModelLayerLocation OAK_BOAT = register("boat/oak"); public static final ModelLayerLocation OAK_CHEST_BOAT = register("chest_boat/oak"); public static final ModelLayerLocation OCELOT = register("ocelot"); @@ -198,6 +212,8 @@ public class ModelLayers { public static final ModelLayerLocation SHEEP_BABY = register("sheep_baby"); public static final ModelLayerLocation SHEEP_BABY_WOOL = register("sheep_baby", "wool"); public static final ModelLayerLocation SHEEP_WOOL = register("sheep", "wool"); + public static final ModelLayerLocation SHEEP_WOOL_UNDERCOAT = register("sheep", "wool_undercoat"); + public static final ModelLayerLocation SHEEP_BABY_WOOL_UNDERCOAT = register("sheep_baby", "wool_undercoat"); public static final ModelLayerLocation SHIELD = register("shield"); public static final ModelLayerLocation SHULKER = register("shulker"); public static final ModelLayerLocation SHULKER_BOX = register("shulker_box"); @@ -206,6 +222,8 @@ public class ModelLayers { public static final ModelLayerLocation SKELETON = register("skeleton"); public static final ModelLayerLocation SKELETON_HORSE = register("skeleton_horse"); public static final ModelLayerLocation SKELETON_HORSE_BABY = register("skeleton_horse_baby"); + public static final ModelLayerLocation SKELETON_HORSE_SADDLE = register("skeleton_horse", "saddle"); + public static final ModelLayerLocation SKELETON_HORSE_BABY_SADDLE = register("skeleton_horse_baby", "saddle"); public static final ModelLayerLocation SKELETON_INNER_ARMOR = registerInnerArmor("skeleton"); public static final ModelLayerLocation SKELETON_OUTER_ARMOR = registerOuterArmor("skeleton"); public static final ModelLayerLocation SKELETON_SKULL = register("skeleton_skull"); @@ -245,6 +263,8 @@ public class ModelLayers { public static final ModelLayerLocation VINDICATOR = register("vindicator"); public static final ModelLayerLocation WANDERING_TRADER = register("wandering_trader"); public static final ModelLayerLocation WARDEN = register("warden"); + public static final ModelLayerLocation WARM_COW = register("warm_cow"); + public static final ModelLayerLocation WARM_COW_BABY = register("warm_cow_baby"); public static final ModelLayerLocation WIND_CHARGE = register("wind_charge"); public static final ModelLayerLocation WITCH = register("witch"); public static final ModelLayerLocation WITHER = register("wither"); @@ -267,6 +287,8 @@ public class ModelLayers { public static final ModelLayerLocation ZOMBIE_HEAD = register("zombie_head"); public static final ModelLayerLocation ZOMBIE_HORSE = register("zombie_horse"); public static final ModelLayerLocation ZOMBIE_HORSE_BABY = register("zombie_horse_baby"); + public static final ModelLayerLocation ZOMBIE_HORSE_SADDLE = register("zombie_horse", "saddle"); + public static final ModelLayerLocation ZOMBIE_HORSE_BABY_SADDLE = register("zombie_horse_baby", "saddle"); public static final ModelLayerLocation ZOMBIE_INNER_ARMOR = registerInnerArmor("zombie"); public static final ModelLayerLocation ZOMBIE_OUTER_ARMOR = registerOuterArmor("zombie"); public static final ModelLayerLocation ZOMBIE_VILLAGER = register("zombie_villager"); diff --git a/net/minecraft/client/model/geom/PartNames.java b/net/minecraft/client/model/geom/PartNames.java index 53bbdf6d..c1713482 100644 --- a/net/minecraft/client/model/geom/PartNames.java +++ b/net/minecraft/client/model/geom/PartNames.java @@ -57,6 +57,7 @@ public class PartNames { public static final String MANE = "mane"; public static final String NECK = "neck"; public static final String MOUTH = "mouth"; + public static final String UPPER_MOUTH = "upper_mouth"; public static final String HEAD = "head"; public static final String HAT = "hat"; public static final String BODY = "body"; diff --git a/net/minecraft/client/model/geom/builders/MeshDefinition.java b/net/minecraft/client/model/geom/builders/MeshDefinition.java index e9d28df5..c6529430 100644 --- a/net/minecraft/client/model/geom/builders/MeshDefinition.java +++ b/net/minecraft/client/model/geom/builders/MeshDefinition.java @@ -25,4 +25,8 @@ public class MeshDefinition { public MeshDefinition transformed(UnaryOperator transformer) { return new MeshDefinition(this.root.transformed(transformer)); } + + public MeshDefinition apply(MeshTransformer transformer) { + return transformer.apply(this); + } } diff --git a/net/minecraft/client/model/geom/builders/MeshTransformer.java b/net/minecraft/client/model/geom/builders/MeshTransformer.java index 6cb61008..4a811751 100644 --- a/net/minecraft/client/model/geom/builders/MeshTransformer.java +++ b/net/minecraft/client/model/geom/builders/MeshTransformer.java @@ -6,6 +6,8 @@ import net.fabricmc.api.Environment; @FunctionalInterface @Environment(EnvType.CLIENT) public interface MeshTransformer { + MeshTransformer IDENTITY = meshDefinition -> meshDefinition; + static MeshTransformer scaling(float f) { float g = 24.016F * (1.0F - f); return meshDefinition -> meshDefinition.transformed(partPose -> partPose.scaled(f).translated(0.0F, g, 0.0F)); diff --git a/net/minecraft/client/model/geom/builders/PartDefinition.java b/net/minecraft/client/model/geom/builders/PartDefinition.java index 1c2085b8..7816f224 100644 --- a/net/minecraft/client/model/geom/builders/PartDefinition.java +++ b/net/minecraft/client/model/geom/builders/PartDefinition.java @@ -12,7 +12,6 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.geom.ModelPart; import net.minecraft.client.model.geom.PartPose; -import net.minecraft.client.model.geom.ModelPart.Cube; @Environment(EnvType.CLIENT) public class PartDefinition { @@ -30,17 +29,22 @@ public class PartDefinition { return this.addOrReplaceChild(name, partDefinition); } - public PartDefinition addOrReplaceChild(String name, PartDefinition child) { - PartDefinition partDefinition = (PartDefinition)this.children.put(name, child); + public PartDefinition addOrReplaceChild(String name, PartDefinition chuld) { + PartDefinition partDefinition = (PartDefinition)this.children.put(name, chuld); if (partDefinition != null) { - child.children.putAll(partDefinition.children); + chuld.children.putAll(partDefinition.children); } - return child; + return chuld; } public PartDefinition clearChild(String name) { - return this.addOrReplaceChild(name, CubeListBuilder.create(), PartPose.ZERO); + PartDefinition partDefinition = (PartDefinition)this.children.get(name); + if (partDefinition == null) { + throw new IllegalArgumentException("No child with name: " + name); + } else { + return this.addOrReplaceChild(name, CubeListBuilder.create(), partDefinition.partPose); + } } public ModelPart bake(int texWidth, int texHeight) { @@ -52,7 +56,7 @@ public class PartDefinition { Entry::getKey, entry -> ((PartDefinition)entry.getValue()).bake(texWidth, texHeight), (modelPartx, modelPart2) -> modelPartx, Object2ObjectArrayMap::new ) ); - List list = this.cubes.stream().map(cubeDefinition -> cubeDefinition.bake(texWidth, texHeight)).toList(); + List list = this.cubes.stream().map(cubeDefinition -> cubeDefinition.bake(texWidth, texHeight)).toList(); ModelPart modelPart = new ModelPart(list, object2ObjectArrayMap); modelPart.setInitialPose(this.partPose); modelPart.loadPose(this.partPose); diff --git a/net/minecraft/client/multiplayer/CacheSlot.java b/net/minecraft/client/multiplayer/CacheSlot.java new file mode 100644 index 00000000..011519d7 --- /dev/null +++ b/net/minecraft/client/multiplayer/CacheSlot.java @@ -0,0 +1,42 @@ +package net.minecraft.client.multiplayer; + +import java.util.function.Function; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public class CacheSlot, D> { + private final Function operation; + @Nullable + private C context; + @Nullable + private D value; + + public CacheSlot(Function operation) { + this.operation = operation; + } + + public D compute(C context) { + if (context == this.context && this.value != null) { + return this.value; + } else { + D object = (D)this.operation.apply(context); + this.value = object; + this.context = context; + context.registerForCleaning(this); + return object; + } + } + + public void clear() { + this.value = null; + this.context = null; + } + + @FunctionalInterface + @Environment(EnvType.CLIENT) + public interface Cleaner> { + void registerForCleaning(CacheSlot cacheSlot); + } +} diff --git a/net/minecraft/client/multiplayer/ClientAdvancements.java b/net/minecraft/client/multiplayer/ClientAdvancements.java index d5b96f05..66c5460c 100644 --- a/net/minecraft/client/multiplayer/ClientAdvancements.java +++ b/net/minecraft/client/multiplayer/ClientAdvancements.java @@ -63,7 +63,7 @@ public class ClientAdvancements { } Optional optional = advancementNode.advancement().display(); - if (optional.isPresent() && ((DisplayInfo)optional.get()).shouldShowToast()) { + if (packet.shouldShowAdvancements() && optional.isPresent() && ((DisplayInfo)optional.get()).shouldShowToast()) { this.minecraft.getToastManager().addToast(new AdvancementToast(advancementNode.holder())); } } diff --git a/net/minecraft/client/multiplayer/ClientChunkCache.java b/net/minecraft/client/multiplayer/ClientChunkCache.java index 30cb1b70..8ebb73c1 100644 --- a/net/minecraft/client/multiplayer/ClientChunkCache.java +++ b/net/minecraft/client/multiplayer/ClientChunkCache.java @@ -5,6 +5,7 @@ import it.unimi.dsi.fastutil.longs.LongOpenHashSet; import java.io.FileOutputStream; import java.io.IOException; import java.nio.charset.StandardCharsets; +import java.util.Map; import java.util.concurrent.atomic.AtomicReferenceArray; import java.util.function.BooleanSupplier; import java.util.function.Consumer; @@ -13,9 +14,8 @@ import net.fabricmc.api.Environment; import net.minecraft.client.Minecraft; import net.minecraft.core.SectionPos; import net.minecraft.core.registries.Registries; -import net.minecraft.nbt.CompoundTag; import net.minecraft.network.FriendlyByteBuf; -import net.minecraft.network.protocol.game.ClientboundLevelChunkPacketData.BlockEntityTagOutput; +import net.minecraft.network.protocol.game.ClientboundLevelChunkPacketData; import net.minecraft.world.level.BlockGetter; import net.minecraft.world.level.ChunkPos; import net.minecraft.world.level.LightLayer; @@ -25,6 +25,7 @@ import net.minecraft.world.level.chunk.EmptyLevelChunk; import net.minecraft.world.level.chunk.LevelChunk; import net.minecraft.world.level.chunk.LevelChunkSection; import net.minecraft.world.level.chunk.status.ChunkStatus; +import net.minecraft.world.level.levelgen.Heightmap; import net.minecraft.world.level.lighting.LevelLightEngine; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -100,7 +101,9 @@ public class ClientChunkCache extends ChunkSource { } @Nullable - public LevelChunk replaceWithPacketData(int x, int z, FriendlyByteBuf buffer, CompoundTag tag, Consumer consumer) { + public LevelChunk replaceWithPacketData( + int x, int z, FriendlyByteBuf readBuffer, Map heightmaps, Consumer consumer + ) { if (!this.storage.inRange(x, z)) { LOGGER.warn("Ignoring chunk since it's not in the view range: {}, {}", x, z); return null; @@ -110,10 +113,10 @@ public class ClientChunkCache extends ChunkSource { ChunkPos chunkPos = new ChunkPos(x, z); if (!isValidChunk(levelChunk, x, z)) { levelChunk = new LevelChunk(this.level, chunkPos); - levelChunk.replaceWithPacketData(buffer, tag, consumer); + levelChunk.replaceWithPacketData(readBuffer, heightmaps, consumer); this.storage.replace(i, levelChunk); } else { - levelChunk.replaceWithPacketData(buffer, tag, consumer); + levelChunk.replaceWithPacketData(readBuffer, heightmaps, consumer); this.storage.refreshEmptySections(levelChunk); } diff --git a/net/minecraft/client/multiplayer/ClientConfigurationPacketListenerImpl.java b/net/minecraft/client/multiplayer/ClientConfigurationPacketListenerImpl.java index 41c8fcda..eccbac7d 100644 --- a/net/minecraft/client/multiplayer/ClientConfigurationPacketListenerImpl.java +++ b/net/minecraft/client/multiplayer/ClientConfigurationPacketListenerImpl.java @@ -7,8 +7,8 @@ import java.util.function.Function; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.Minecraft; -import net.minecraft.client.gui.components.ChatComponent; -import net.minecraft.core.RegistryAccess; +import net.minecraft.client.gui.components.ChatComponent.State; +import net.minecraft.core.RegistryAccess.Frozen; import net.minecraft.network.Connection; import net.minecraft.network.DisconnectionDetails; import net.minecraft.network.RegistryFriendlyByteBuf; @@ -38,12 +38,12 @@ public class ClientConfigurationPacketListenerImpl extends ClientCommonPacketLis private static final Logger LOGGER = LogUtils.getLogger(); private final GameProfile localGameProfile; private FeatureFlagSet enabledFeatures; - private final RegistryAccess.Frozen receivedRegistries; + private final Frozen receivedRegistries; private final RegistryDataCollector registryDataCollector = new RegistryDataCollector(); @Nullable private KnownPacksManager knownPacks; @Nullable - protected ChatComponent.State chatState; + protected State chatState; public ClientConfigurationPacketListenerImpl(Minecraft minecraft, Connection connection, CommonListenerCookie commonListenerCookie) { super(minecraft, connection, commonListenerCookie); @@ -116,7 +116,7 @@ public class ClientConfigurationPacketListenerImpl extends ClientCommonPacketLis @Override public void handleConfigurationFinished(ClientboundFinishConfigurationPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); - RegistryAccess.Frozen frozen = this.runWithResources( + Frozen frozen = this.runWithResources( resourceProvider -> this.registryDataCollector.collectGameRegistries(resourceProvider, this.receivedRegistries, this.connection.isMemoryConnection()) ); this.connection @@ -141,7 +141,12 @@ public class ClientConfigurationPacketListenerImpl extends ClientCommonPacketLis ) ); this.connection.send(ServerboundFinishConfigurationPacket.INSTANCE); - this.connection.setupOutboundProtocol(GameProtocols.SERVERBOUND_TEMPLATE.bind(RegistryFriendlyByteBuf.decorator(frozen))); + this.connection.setupOutboundProtocol(GameProtocols.SERVERBOUND_TEMPLATE.bind(RegistryFriendlyByteBuf.decorator(frozen), new GameProtocols.Context() { + @Override + public boolean hasInfiniteMaterials() { + return true; + } + })); } @Override diff --git a/net/minecraft/client/multiplayer/ClientLevel.java b/net/minecraft/client/multiplayer/ClientLevel.java index 8f3cabd7..767d696d 100644 --- a/net/minecraft/client/multiplayer/ClientLevel.java +++ b/net/minecraft/client/multiplayer/ClientLevel.java @@ -23,8 +23,9 @@ import net.minecraft.Util; import net.minecraft.client.Minecraft; import net.minecraft.client.color.block.BlockTintCache; import net.minecraft.client.multiplayer.prediction.BlockStatePredictionHandler; -import net.minecraft.client.particle.FireworkParticles; +import net.minecraft.client.particle.FireworkParticles.Starter; import net.minecraft.client.player.AbstractClientPlayer; +import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.renderer.BiomeColors; import net.minecraft.client.renderer.DimensionSpecialEffects; import net.minecraft.client.renderer.LevelEventHandler; @@ -35,7 +36,6 @@ import net.minecraft.core.BlockPos; import net.minecraft.core.Cursor3D; import net.minecraft.core.Direction; import net.minecraft.core.Holder; -import net.minecraft.core.Direction.Axis; import net.minecraft.core.particles.BlockParticleOption; import net.minecraft.core.particles.ParticleOptions; import net.minecraft.core.particles.ParticleTypes; @@ -58,6 +58,7 @@ import net.minecraft.world.Difficulty; import net.minecraft.world.TickRateManager; import net.minecraft.world.damagesource.DamageSource; import net.minecraft.world.entity.Entity; +import net.minecraft.world.entity.EntitySelector; import net.minecraft.world.entity.boss.EnderDragonPart; import net.minecraft.world.entity.boss.enderdragon.EnderDragon; import net.minecraft.world.entity.player.Player; @@ -93,6 +94,7 @@ import net.minecraft.world.level.material.FluidState; import net.minecraft.world.level.saveddata.maps.MapId; import net.minecraft.world.level.saveddata.maps.MapItemSavedData; import net.minecraft.world.level.storage.WritableLevelData; +import net.minecraft.world.phys.AABB; import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.shapes.VoxelShape; import net.minecraft.world.scores.Scoreboard; @@ -102,7 +104,7 @@ import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @Environment(EnvType.CLIENT) -public class ClientLevel extends Level { +public class ClientLevel extends Level implements CacheSlot.Cleaner { private static final Logger LOGGER = LogUtils.getLogger(); private static final double FLUID_PARTICLE_SPAWN_OFFSET = 0.05; private static final int NORMAL_LIGHT_UPDATES_PER_FRAME = 10; @@ -130,6 +132,9 @@ public class ClientLevel extends Level { object2ObjectArrayMap.put( BiomeColors.FOLIAGE_COLOR_RESOLVER, new BlockTintCache(blockPos -> this.calculateBlockTint(blockPos, BiomeColors.FOLIAGE_COLOR_RESOLVER)) ); + object2ObjectArrayMap.put( + BiomeColors.DRY_FOLIAGE_COLOR_RESOLVER, new BlockTintCache(blockPos -> this.calculateBlockTint(blockPos, BiomeColors.DRY_FOLIAGE_COLOR_RESOLVER)) + ); object2ObjectArrayMap.put( BiomeColors.WATER_COLOR_RESOLVER, new BlockTintCache(blockPos -> this.calculateBlockTint(blockPos, BiomeColors.WATER_COLOR_RESOLVER)) ); @@ -159,7 +164,7 @@ public class ClientLevel extends Level { this.setBlock(pos, state, 19); Player player = this.minecraft.player; if (this == player.level() && player.isColliding(pos, state)) { - player.absMoveTo(playerPos.x, playerPos.y, playerPos.z); + player.absSnapTo(playerPos.x, playerPos.y, playerPos.z); } } } @@ -356,6 +361,17 @@ public class ClientLevel extends Level { } } + @Override + public List getPushableEntities(Entity entity, AABB boundingBox) { + LocalPlayer localPlayer = this.minecraft.player; + return localPlayer != null + && localPlayer != entity + && localPlayer.getBoundingBox().intersects(boundingBox) + && EntitySelector.pushableBy(entity).test(localPlayer) + ? List.of(localPlayer) + : List.of(); + } + @Nullable @Override public Entity getEntity(int id) { @@ -439,20 +455,20 @@ public class ClientLevel extends Level { private void trySpawnDripParticles(BlockPos blockPos, BlockState blockState, ParticleOptions particleData, boolean shapeDownSolid) { if (blockState.getFluidState().isEmpty()) { VoxelShape voxelShape = blockState.getCollisionShape(this, blockPos); - double d = voxelShape.max(Axis.Y); + double d = voxelShape.max(Direction.Axis.Y); if (d < 1.0) { if (shapeDownSolid) { this.spawnFluidParticle(blockPos.getX(), blockPos.getX() + 1, blockPos.getZ(), blockPos.getZ() + 1, blockPos.getY() + 1 - 0.05, particleData); } } else if (!blockState.is(BlockTags.IMPERMEABLE)) { - double e = voxelShape.min(Axis.Y); + double e = voxelShape.min(Direction.Axis.Y); if (e > 0.0) { this.spawnParticle(blockPos, particleData, voxelShape, blockPos.getY() + e - 0.05); } else { BlockPos blockPos2 = blockPos.below(); BlockState blockState2 = this.getBlockState(blockPos2); VoxelShape voxelShape2 = blockState2.getCollisionShape(this, blockPos2); - double f = voxelShape2.max(Axis.Y); + double f = voxelShape2.max(Direction.Axis.Y); if (f < 1.0 && blockState2.getFluidState().isEmpty()) { this.spawnParticle(blockPos, particleData, voxelShape, blockPos.getY() - 0.05); } @@ -463,10 +479,10 @@ public class ClientLevel extends Level { private void spawnParticle(BlockPos pos, ParticleOptions particleData, VoxelShape voxelShape, double y) { this.spawnFluidParticle( - pos.getX() + voxelShape.min(Axis.X), - pos.getX() + voxelShape.max(Axis.X), - pos.getZ() + voxelShape.min(Axis.Z), - pos.getZ() + voxelShape.max(Axis.Z), + pos.getX() + voxelShape.min(Direction.Axis.X), + pos.getX() + voxelShape.max(Direction.Axis.X), + pos.getZ() + voxelShape.min(Direction.Axis.Z), + pos.getZ() + voxelShape.max(Direction.Axis.Z), y, particleData ); @@ -490,28 +506,35 @@ public class ClientLevel extends Level { @Override public void playSeededSound( - @Nullable Player player, double x, double y, double z, Holder sound, SoundSource category, float volume, float pitch, long seed + @Nullable Entity entity, double x, double y, double z, Holder sound, SoundSource source, float volume, float pitch, long seed ) { - if (player == this.minecraft.player) { - this.playSound(x, y, z, sound.value(), category, volume, pitch, false, seed); + if (entity == this.minecraft.player) { + this.playSound(x, y, z, sound.value(), source, volume, pitch, false, seed); } } @Override - public void playSeededSound(@Nullable Player player, Entity entity, Holder sound, SoundSource category, float volume, float pitch, long seed) { - if (player == this.minecraft.player) { - this.minecraft.getSoundManager().play(new EntityBoundSoundInstance(sound.value(), category, volume, pitch, entity, seed)); + public void playSeededSound(@Nullable Entity entity, Entity sourceEntity, Holder sound, SoundSource source, float volume, float pitch, long seed) { + if (entity == this.minecraft.player) { + this.minecraft.getSoundManager().play(new EntityBoundSoundInstance(sound.value(), source, volume, pitch, sourceEntity, seed)); } } @Override - public void playLocalSound(Entity entity, SoundEvent sound, SoundSource category, float volume, float pitch) { - this.minecraft.getSoundManager().play(new EntityBoundSoundInstance(sound, category, volume, pitch, entity, this.random.nextLong())); + public void playLocalSound(Entity entity, SoundEvent sound, SoundSource source, float volume, float pitch) { + this.minecraft.getSoundManager().play(new EntityBoundSoundInstance(sound, source, volume, pitch, entity, this.random.nextLong())); } @Override - public void playLocalSound(double x, double y, double z, SoundEvent sound, SoundSource category, float volume, float pitch, boolean distanceDelay) { - this.playSound(x, y, z, sound, category, volume, pitch, distanceDelay, this.random.nextLong()); + public void playPlayerSound(SoundEvent sound, SoundSource source, float volume, float pitch) { + if (this.minecraft.player != null) { + this.minecraft.getSoundManager().play(new EntityBoundSoundInstance(sound, source, volume, pitch, this.minecraft.player, this.random.nextLong())); + } + } + + @Override + public void playLocalSound(double x, double y, double z, SoundEvent sound, SoundSource source, float volume, float pitch, boolean distanceDelay) { + this.playSound(x, y, z, sound, source, volume, pitch, distanceDelay, this.random.nextLong()); } private void playSound(double x, double y, double z, SoundEvent soundEvent, SoundSource source, float volume, float pitch, boolean distanceDelay, long seed) { @@ -532,7 +555,7 @@ public class ClientLevel extends Level { this.addParticle(ParticleTypes.POOF, x, y, z, this.random.nextGaussian() * 0.05, 0.005, this.random.nextGaussian() * 0.05); } } else { - this.minecraft.particleEngine.add(new FireworkParticles.Starter(this, x, y, z, xSpeed, ySpeed, zSpeed, this.minecraft.particleEngine, explosions)); + this.minecraft.particleEngine.add(new Starter(this, x, y, z, xSpeed, ySpeed, zSpeed, this.minecraft.particleEngine, explosions)); } } @@ -578,15 +601,6 @@ public class ClientLevel extends Level { this.mapData.put(mapId, mapData); } - @Override - public void setMapData(MapId mapId, MapItemSavedData mapData) { - } - - @Override - public MapId getFreeMapId() { - return new MapId(0); - } - @Override public Scoreboard getScoreboard() { return this.connection.scoreboard(); @@ -621,14 +635,14 @@ public class ClientLevel extends Level { } @Override - public void levelEvent(@Nullable Player player, int type, BlockPos pos, int data) { + public void levelEvent(@Nullable Entity entity, int type, BlockPos pos, int data) { try { this.levelEventHandler.levelEvent(type, pos, data); } catch (Throwable var8) { CrashReport crashReport = CrashReport.forThrowable(var8, "Playing level event"); CrashReportCategory crashReportCategory = crashReport.addCategory("Level event being played"); crashReportCategory.setDetail("Block coordinates", CrashReportCategory.formatLocation(this, pos)); - crashReportCategory.setDetail("Event source", player); + crashReportCategory.setDetail("Event source", entity); crashReportCategory.setDetail("Event type", type); crashReportCategory.setDetail("Event data", data); throw new ReportedException(crashReport); @@ -894,6 +908,16 @@ public class ClientLevel extends Level { return this.seaLevel; } + @Override + public int getClientLeafTintColor(BlockPos pos) { + return Minecraft.getInstance().getBlockColors().getColor(this.getBlockState(pos), this, pos, 0); + } + + @Override + public void registerForCleaning(CacheSlot cacheSlot) { + this.connection.registerForCleaning(cacheSlot); + } + @Environment(EnvType.CLIENT) public static class ClientLevelData implements WritableLevelData { private final boolean hardcore; diff --git a/net/minecraft/client/multiplayer/ClientPacketListener.java b/net/minecraft/client/multiplayer/ClientPacketListener.java index f1fb7a39..ba82f5b5 100644 --- a/net/minecraft/client/multiplayer/ClientPacketListener.java +++ b/net/minecraft/client/multiplayer/ClientPacketListener.java @@ -3,12 +3,14 @@ package net.minecraft.client.multiplayer; import com.google.common.collect.Lists; import com.google.common.collect.Maps; import com.google.common.collect.Sets; +import com.google.common.hash.HashCode; import com.mojang.authlib.GameProfile; import com.mojang.brigadier.CommandDispatcher; import com.mojang.brigadier.ParseResults; import com.mojang.logging.LogUtils; import it.unimi.dsi.fastutil.objects.ReferenceOpenHashSet; import it.unimi.dsi.fastutil.objects.Object2IntMap.Entry; +import java.lang.ref.WeakReference; import java.time.Instant; import java.util.ArrayList; import java.util.BitSet; @@ -30,7 +32,7 @@ import net.minecraft.client.ClientRecipeBook; import net.minecraft.client.DebugQueryHandler; import net.minecraft.client.Minecraft; import net.minecraft.client.Options; -import net.minecraft.client.gui.components.ChatComponent; +import net.minecraft.client.gui.components.ChatComponent.State; import net.minecraft.client.gui.components.toasts.RecipeToast; import net.minecraft.client.gui.components.toasts.SystemToast; import net.minecraft.client.gui.screens.DeathScreen; @@ -43,15 +45,16 @@ import net.minecraft.client.gui.screens.inventory.BookViewScreen; import net.minecraft.client.gui.screens.inventory.CommandBlockEditScreen; import net.minecraft.client.gui.screens.inventory.CreativeModeInventoryScreen; import net.minecraft.client.gui.screens.inventory.HorseInventoryScreen; +import net.minecraft.client.gui.screens.inventory.TestInstanceBlockEditScreen; import net.minecraft.client.gui.screens.multiplayer.ServerReconfigScreen; import net.minecraft.client.gui.screens.recipebook.RecipeUpdateListener; import net.minecraft.client.particle.ItemPickupParticle; import net.minecraft.client.player.KeyboardInput; import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.player.RemotePlayer; +import net.minecraft.client.renderer.debug.BrainDebugRenderer; import net.minecraft.client.renderer.debug.VillageSectionsDebugRenderer; import net.minecraft.client.renderer.debug.WorldGenAttemptRenderer; -import net.minecraft.client.renderer.debug.BrainDebugRenderer.PoiInfo; import net.minecraft.client.resources.sounds.BeeAggressiveSoundInstance; import net.minecraft.client.resources.sounds.BeeFlyingSoundInstance; import net.minecraft.client.resources.sounds.BeeSoundInstance; @@ -66,11 +69,12 @@ import net.minecraft.core.Holder; import net.minecraft.core.Registry; import net.minecraft.core.RegistrySynchronization; import net.minecraft.core.SectionPos; +import net.minecraft.core.Registry.PendingTags; import net.minecraft.core.RegistryAccess.Frozen; import net.minecraft.core.component.DataComponents; import net.minecraft.core.particles.ParticleTypes; -import net.minecraft.nbt.CompoundTag; import net.minecraft.network.Connection; +import net.minecraft.network.HashedPatchMap; import net.minecraft.network.TickablePacketListener; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.LastSeenMessagesTracker; @@ -82,7 +86,6 @@ import net.minecraft.network.chat.RemoteChatSession; import net.minecraft.network.chat.SignableCommand; import net.minecraft.network.chat.SignedMessageBody; import net.minecraft.network.chat.SignedMessageLink; -import net.minecraft.network.chat.LastSeenMessagesTracker.Update; import net.minecraft.network.chat.RemoteChatSession.Data; import net.minecraft.network.chat.SignedMessageChain.Encoder; import net.minecraft.network.chat.numbers.NumberFormat; @@ -113,7 +116,6 @@ import net.minecraft.network.protocol.common.custom.WorldGenAttemptDebugPayload; import net.minecraft.network.protocol.configuration.ConfigurationProtocols; import net.minecraft.network.protocol.game.ClientGamePacketListener; import net.minecraft.network.protocol.game.ClientboundAddEntityPacket; -import net.minecraft.network.protocol.game.ClientboundAddExperienceOrbPacket; import net.minecraft.network.protocol.game.ClientboundAnimatePacket; import net.minecraft.network.protocol.game.ClientboundAwardStatsPacket; import net.minecraft.network.protocol.game.ClientboundBlockChangedAckPacket; @@ -224,6 +226,7 @@ import net.minecraft.network.protocol.game.ClientboundTabListPacket; import net.minecraft.network.protocol.game.ClientboundTagQueryPacket; import net.minecraft.network.protocol.game.ClientboundTakeItemEntityPacket; import net.minecraft.network.protocol.game.ClientboundTeleportEntityPacket; +import net.minecraft.network.protocol.game.ClientboundTestInstanceBlockStatus; import net.minecraft.network.protocol.game.ClientboundTickingStatePacket; import net.minecraft.network.protocol.game.ClientboundTickingStepPacket; import net.minecraft.network.protocol.game.ClientboundUpdateAdvancementsPacket; @@ -240,17 +243,16 @@ import net.minecraft.network.protocol.game.ServerboundChatSessionUpdatePacket; import net.minecraft.network.protocol.game.ServerboundChunkBatchReceivedPacket; import net.minecraft.network.protocol.game.ServerboundClientCommandPacket; import net.minecraft.network.protocol.game.ServerboundConfigurationAcknowledgedPacket; +import net.minecraft.network.protocol.game.ServerboundMovePlayerPacket; import net.minecraft.network.protocol.game.ServerboundMoveVehiclePacket; import net.minecraft.network.protocol.game.ServerboundPlayerLoadedPacket; import net.minecraft.network.protocol.game.VecDeltaCodec; -import net.minecraft.network.protocol.game.ClientboundGameEventPacket.Type; -import net.minecraft.network.protocol.game.ClientboundSetPlayerTeamPacket.Parameters; +import net.minecraft.network.protocol.game.ClientboundChunksBiomesPacket.ChunkBiomeData; import net.minecraft.network.protocol.game.ClientboundUpdateAttributesPacket.AttributeSnapshot; import net.minecraft.network.protocol.game.ServerboundClientCommandPacket.Action; -import net.minecraft.network.protocol.game.ServerboundMovePlayerPacket.PosRot; -import net.minecraft.network.protocol.game.ServerboundMovePlayerPacket.Rot; import net.minecraft.network.protocol.ping.ClientboundPongResponsePacket; import net.minecraft.network.syncher.SynchedEntityData.DataValue; +import net.minecraft.resources.RegistryOps; import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.ServerLinks; @@ -260,6 +262,7 @@ import net.minecraft.sounds.SoundSource; import net.minecraft.stats.Stat; import net.minecraft.stats.StatsCounter; import net.minecraft.tags.TagNetworkSerialization.NetworkPayload; +import net.minecraft.util.HashOps; import net.minecraft.util.Mth; import net.minecraft.util.RandomSource; import net.minecraft.util.SignatureValidator; @@ -328,8 +331,6 @@ import net.minecraft.world.scores.PlayerTeam; import net.minecraft.world.scores.ScoreAccess; import net.minecraft.world.scores.ScoreHolder; import net.minecraft.world.scores.Scoreboard; -import net.minecraft.world.scores.Team.CollisionRule; -import net.minecraft.world.scores.Team.Visibility; import net.minecraft.world.scores.criteria.ObjectiveCriteria; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -341,6 +342,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme private static final Component UNSERURE_SERVER_TOAST = Component.translatable("multiplayer.unsecureserver.toast"); private static final Component INVALID_PACKET = Component.translatable("multiplayer.disconnect.invalid_packet"); private static final Component RECONFIGURE_SCREEN_MESSAGE = Component.translatable("connect.reconfiguring"); + private static final Component BAD_CHAT_INDEX = Component.translatable("multiplayer.disconnect.bad_chat_index"); private static final int PENDING_OFFSET_THRESHOLD = 64; public static final int TELEPORT_INTERPOLATION_THRESHOLD = 64; private final GameProfile localGameProfile; @@ -371,10 +373,12 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme private final FeatureFlagSet enabledFeatures; private final PotionBrewing potionBrewing; private FuelValues fuelValues; + private final HashedPatchMap.HashGenerator decoratedHashOpsGenerator; private OptionalInt removedPlayerVehicleId = OptionalInt.empty(); @Nullable private LocalChatSession chatSession; private Encoder signedMessageEncoder = Encoder.UNSIGNED; + private int nextChatIndex; private LastSeenMessagesTracker lastSeenMessages = new LastSeenMessagesTracker(20); private MessageSignatureCache messageSignatureCache = MessageSignatureCache.createDefault(); @Nullable @@ -391,11 +395,16 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme private volatile boolean closed; private final Scoreboard scoreboard = new Scoreboard(); private final SessionSearchTrees searchTrees = new SessionSearchTrees(); + private final List>> cacheSlots = new ArrayList(); public ClientPacketListener(Minecraft minecraft, Connection connection, CommonListenerCookie commonListenerCookie) { super(minecraft, connection, commonListenerCookie); this.localGameProfile = commonListenerCookie.localGameProfile(); this.registryAccess = commonListenerCookie.receivedRegistries(); + RegistryOps registryOps = this.registryAccess.createSerializationContext(HashOps.CRC32C_INSTANCE); + this.decoratedHashOpsGenerator = typedDataComponent -> typedDataComponent.encodeValue(registryOps) + .getOrThrow(string -> new IllegalArgumentException("Failed to hash " + typedDataComponent + ": " + string)) + .asInt(); this.enabledFeatures = commonListenerCookie.enabledFeatures(); this.advancements = new ClientAdvancements(minecraft, this.telemetryManager); this.suggestionsProvider = new ClientSuggestionProvider(this, minecraft); @@ -420,10 +429,22 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } public void clearLevel() { + this.clearCacheSlots(); this.level = null; this.levelLoadStatusManager = null; } + private void clearCacheSlots() { + for (WeakReference> weakReference : this.cacheSlots) { + CacheSlot cacheSlot = (CacheSlot)weakReference.get(); + if (cacheSlot != null) { + cacheSlot.clear(); + } + } + + this.cacheSlots.clear(); + } + public RecipeAccess recipes() { return this.recipes; } @@ -482,6 +503,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme this.minecraft.gameMode.setLocalMode(commonPlayerSpawnInfo.gameType(), commonPlayerSpawnInfo.previousGameType()); this.minecraft.options.setServerRenderDistance(packet.chunkRadius()); this.chatSession = null; + this.nextChatIndex = 0; this.lastSeenMessages = new LastSeenMessagesTracker(20); this.messageSignatureCache = MessageSignatureCache.createDefault(); if (this.connection.isEncrypted()) { @@ -549,20 +571,6 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } } - @Override - public void handleAddExperienceOrb(ClientboundAddExperienceOrbPacket packet) { - PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); - double d = packet.getX(); - double e = packet.getY(); - double f = packet.getZ(); - Entity entity = new ExperienceOrb(this.level, d, e, f, packet.getValue()); - entity.syncPacketPositionCodec(d, e, f); - entity.setYRot(0.0F); - entity.setXRot(0.0F); - entity.setId(packet.getId()); - this.level.addEntity(entity); - } - @Override public void handleSetEntityMotion(ClientboundSetEntityMotionPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); @@ -588,18 +596,19 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme if (entity != null) { Vec3 vec3 = packet.values().position(); entity.getPositionCodec().setBase(vec3); - if (!entity.isControlledByLocalInstance()) { + if (!entity.isLocalInstanceAuthoritative()) { float f = packet.values().yRot(); float g = packet.values().xRot(); boolean bl = entity.position().distanceToSqr(vec3) > 4096.0; if (this.level.isTickingEntity(entity) && !bl) { - entity.lerpTo(vec3.x, vec3.y, vec3.z, f, g, 3); + entity.moveOrInterpolateTo(vec3, f, g); } else { - entity.moveTo(vec3.x, vec3.y, vec3.z, f, g); - if (entity.hasIndirectPassenger(this.minecraft.player)) { - entity.positionRider(this.minecraft.player); - this.minecraft.player.setOldPosAndRot(); - } + entity.snapTo(vec3, f, g); + } + + if (entity.isInterpolating() && entity.hasIndirectPassenger(this.minecraft.player)) { + entity.positionRider(this.minecraft.player); + this.minecraft.player.setOldPosAndRot(); } entity.setOnGround(packet.onGround()); @@ -617,7 +626,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme setValuesFromPositionPacket(packet.change(), packet.relatives(), this.minecraft.player, false); this.connection .send( - new PosRot( + new ServerboundMovePlayerPacket.PosRot( this.minecraft.player.getX(), this.minecraft.player.getY(), this.minecraft.player.getZ(), @@ -630,13 +639,13 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } } else { boolean bl = packet.relatives().contains(Relative.X) || packet.relatives().contains(Relative.Y) || packet.relatives().contains(Relative.Z); - boolean bl2 = this.level.isTickingEntity(entity) || !entity.isControlledByLocalInstance() || bl; + boolean bl2 = this.level.isTickingEntity(entity) || !entity.isLocalInstanceAuthoritative() || bl; boolean bl3 = setValuesFromPositionPacket(packet.change(), packet.relatives(), entity, bl2); entity.setOnGround(packet.onGround()); if (!bl3 && entity.hasIndirectPassenger(this.minecraft.player)) { entity.positionRider(this.minecraft.player); this.minecraft.player.setOldPosAndRot(); - if (entity.isControlledByOrIsLocalPlayer()) { + if (entity.isLocalInstanceAuthoritative()) { this.connection.send(ServerboundMoveVehiclePacket.fromEntity(entity)); } } @@ -666,7 +675,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme public void handleSetHeldSlot(ClientboundSetHeldSlotPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); if (Inventory.isHotbarSlot(packet.slot())) { - this.minecraft.player.getInventory().selected = packet.slot(); + this.minecraft.player.getInventory().setSelectedSlot(packet.slot()); } } @@ -675,7 +684,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); Entity entity = packet.getEntity(this.level); if (entity != null) { - if (entity.isControlledByLocalInstance()) { + if (entity.isLocalInstanceAuthoritative()) { VecDeltaCodec vecDeltaCodec = entity.getPositionCodec(); Vec3 vec3 = vecDeltaCodec.decode(packet.getXa(), packet.getYa(), packet.getZa()); vecDeltaCodec.setBase(vec3); @@ -684,11 +693,13 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme VecDeltaCodec vecDeltaCodec = entity.getPositionCodec(); Vec3 vec3 = vecDeltaCodec.decode(packet.getXa(), packet.getYa(), packet.getZa()); vecDeltaCodec.setBase(vec3); - float f = packet.hasRotation() ? packet.getyRot() : entity.lerpTargetYRot(); - float g = packet.hasRotation() ? packet.getxRot() : entity.lerpTargetXRot(); - entity.lerpTo(vec3.x(), vec3.y(), vec3.z(), f, g, 3); + if (packet.hasRotation()) { + entity.moveOrInterpolateTo(vec3, packet.getYRot(), packet.getXRot()); + } else { + entity.moveOrInterpolateTo(vec3, entity.getYRot(), entity.getXRot()); + } } else if (packet.hasRotation()) { - entity.lerpTo(entity.lerpTargetX(), entity.lerpTargetY(), entity.lerpTargetZ(), packet.getyRot(), packet.getxRot(), 3); + entity.moveOrInterpolateTo(entity.position(), packet.getYRot(), packet.getXRot()); } entity.setOnGround(packet.isOnGround()); @@ -699,9 +710,8 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme @Override public void handleMinecartAlongTrack(ClientboundMoveMinecartPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); - Entity entity = packet.getEntity(this.level); - if (entity instanceof AbstractMinecart abstractMinecart) { - if (!entity.isControlledByLocalInstance() && abstractMinecart.getBehavior() instanceof NewMinecartBehavior newMinecartBehavior) { + if (packet.getEntity(this.level) instanceof AbstractMinecart abstractMinecart) { + if (abstractMinecart.getBehavior() instanceof NewMinecartBehavior newMinecartBehavior) { newMinecartBehavior.lerpSteps.addAll(packet.lerpSteps()); } } @@ -741,22 +751,15 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } this.connection.send(new ServerboundAcceptTeleportationPacket(packet.id())); - this.connection.send(new PosRot(player.getX(), player.getY(), player.getZ(), player.getYRot(), player.getXRot(), false, false)); + this.connection.send(new ServerboundMovePlayerPacket.PosRot(player.getX(), player.getY(), player.getZ(), player.getYRot(), player.getXRot(), false, false)); } private static boolean setValuesFromPositionPacket(PositionMoveRotation positionMoveRotation, Set relatives, Entity entity, boolean lerp) { - PositionMoveRotation positionMoveRotation2 = PositionMoveRotation.ofEntityUsingLerpTarget(entity); + PositionMoveRotation positionMoveRotation2 = PositionMoveRotation.of(entity); PositionMoveRotation positionMoveRotation3 = PositionMoveRotation.calculateAbsolute(positionMoveRotation2, positionMoveRotation, relatives); boolean bl = positionMoveRotation2.position().distanceToSqr(positionMoveRotation3.position()) > 4096.0; if (lerp && !bl) { - entity.lerpTo( - positionMoveRotation3.position().x(), - positionMoveRotation3.position().y(), - positionMoveRotation3.position().z(), - positionMoveRotation3.yRot(), - positionMoveRotation3.xRot(), - 3 - ); + entity.moveOrInterpolateTo(positionMoveRotation3.position(), positionMoveRotation3.yRot(), positionMoveRotation3.xRot()); entity.setDeltaMovement(positionMoveRotation3.deltaMovement()); return true; } else { @@ -778,7 +781,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme player.setYRot(packet.yRot()); player.setXRot(packet.xRot()); player.setOldRot(); - this.connection.send(new Rot(player.getYRot(), player.getXRot(), false, false)); + this.connection.send(new ServerboundMovePlayerPacket.Rot(player.getYRot(), player.getXRot(), false, false)); } @Override @@ -808,15 +811,15 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme public void handleChunksBiomes(ClientboundChunksBiomesPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); - for (ClientboundChunksBiomesPacket.ChunkBiomeData chunkBiomeData : packet.chunkBiomeData()) { + for (ChunkBiomeData chunkBiomeData : packet.chunkBiomeData()) { this.level.getChunkSource().replaceBiomes(chunkBiomeData.pos().x, chunkBiomeData.pos().z, chunkBiomeData.getReadBuffer()); } - for (ClientboundChunksBiomesPacket.ChunkBiomeData chunkBiomeData : packet.chunkBiomeData()) { + for (ChunkBiomeData chunkBiomeData : packet.chunkBiomeData()) { this.level.onChunkLoaded(new ChunkPos(chunkBiomeData.pos().x, chunkBiomeData.pos().z)); } - for (ClientboundChunksBiomesPacket.ChunkBiomeData chunkBiomeData : packet.chunkBiomeData()) { + for (ChunkBiomeData chunkBiomeData : packet.chunkBiomeData()) { for (int i = -1; i <= 1; i++) { for (int j = -1; j <= 1; j++) { for (int k = this.level.getMinSectionY(); k <= this.level.getMaxSectionY(); k++) { @@ -881,7 +884,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); this.minecraft.getChatListener().clearQueue(); this.sendChatAcknowledgement(); - ChatComponent.State state = this.minecraft.gui.getChat().storeState(); + State state = this.minecraft.gui.getChat().storeState(); this.minecraft.clearClientLevel(new ServerReconfigScreen(RECONFIGURE_SCREEN_MESSAGE, this.connection)); this.connection .setupInboundProtocol( @@ -969,33 +972,40 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme @Override public void handlePlayerChat(ClientboundPlayerChatPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); - Optional optional = packet.body().unpack(this.messageSignatureCache); - if (optional.isEmpty()) { - this.connection.disconnect(INVALID_PACKET); + int i = this.nextChatIndex++; + if (packet.globalIndex() != i) { + LOGGER.error("Missing or out-of-order chat message from server, expected index {} but got {}", i, packet.globalIndex()); + this.connection.disconnect(BAD_CHAT_INDEX); } else { - this.messageSignatureCache.push((SignedMessageBody)optional.get(), packet.signature()); - UUID uUID = packet.sender(); - PlayerInfo playerInfo = this.getPlayerInfo(uUID); - if (playerInfo == null) { - LOGGER.error("Received player chat packet for unknown player with ID: {}", uUID); - this.minecraft.getChatListener().handleChatMessageError(uUID, packet.chatType()); + Optional optional = packet.body().unpack(this.messageSignatureCache); + if (optional.isEmpty()) { + LOGGER.error("Message from player with ID {} referenced unrecognized signature id", packet.sender()); + this.connection.disconnect(INVALID_PACKET); } else { - RemoteChatSession remoteChatSession = playerInfo.getChatSession(); - SignedMessageLink signedMessageLink; - if (remoteChatSession != null) { - signedMessageLink = new SignedMessageLink(packet.index(), uUID, remoteChatSession.sessionId()); + this.messageSignatureCache.push((SignedMessageBody)optional.get(), packet.signature()); + UUID uUID = packet.sender(); + PlayerInfo playerInfo = this.getPlayerInfo(uUID); + if (playerInfo == null) { + LOGGER.error("Received player chat packet for unknown player with ID: {}", uUID); + this.minecraft.getChatListener().handleChatMessageError(uUID, packet.signature(), packet.chatType()); } else { - signedMessageLink = SignedMessageLink.unsigned(uUID); - } + RemoteChatSession remoteChatSession = playerInfo.getChatSession(); + SignedMessageLink signedMessageLink; + if (remoteChatSession != null) { + signedMessageLink = new SignedMessageLink(packet.index(), uUID, remoteChatSession.sessionId()); + } else { + signedMessageLink = SignedMessageLink.unsigned(uUID); + } - PlayerChatMessage playerChatMessage = new PlayerChatMessage( - signedMessageLink, packet.signature(), (SignedMessageBody)optional.get(), packet.unsignedContent(), packet.filterMask() - ); - playerChatMessage = playerInfo.getMessageValidator().updateAndValidate(playerChatMessage); - if (playerChatMessage != null) { - this.minecraft.getChatListener().handlePlayerChatMessage(playerChatMessage, playerInfo.getProfile(), packet.chatType()); - } else { - this.minecraft.getChatListener().handleChatMessageError(uUID, packet.chatType()); + PlayerChatMessage playerChatMessage = new PlayerChatMessage( + signedMessageLink, packet.signature(), (SignedMessageBody)optional.get(), packet.unsignedContent(), packet.filterMask() + ); + playerChatMessage = playerInfo.getMessageValidator().updateAndValidate(playerChatMessage); + if (playerChatMessage != null) { + this.minecraft.getChatListener().handlePlayerChatMessage(playerChatMessage, playerInfo.getProfile(), packet.chatType()); + } else { + this.minecraft.getChatListener().handleChatMessageError(uUID, packet.signature(), packet.chatType()); + } } } } @@ -1248,8 +1258,8 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme localPlayer2.setShowDeathScreen(localPlayer.shouldShowDeathScreen()); localPlayer2.setLastDeathLocation(commonPlayerSpawnInfo.lastDeathLocation()); localPlayer2.setPortalCooldown(commonPlayerSpawnInfo.portalCooldown()); - localPlayer2.spinningEffectIntensity = localPlayer.spinningEffectIntensity; - localPlayer2.oSpinningEffectIntensity = localPlayer.oSpinningEffectIntensity; + localPlayer2.portalEffectIntensity = localPlayer.portalEffectIntensity; + localPlayer2.oPortalEffectIntensity = localPlayer.oPortalEffectIntensity; if (this.minecraft.screen instanceof DeathScreen || this.minecraft.screen instanceof DeathScreen.TitleConfirmScreen) { this.minecraft.setScreen(null); } @@ -1362,10 +1372,10 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme public void handleContainerContent(ClientboundContainerSetContentPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); Player player = this.minecraft.player; - if (packet.getContainerId() == 0) { - player.inventoryMenu.initializeContents(packet.getStateId(), packet.getItems(), packet.getCarriedItem()); - } else if (packet.getContainerId() == player.containerMenu.containerId) { - player.containerMenu.initializeContents(packet.getStateId(), packet.getItems(), packet.getCarriedItem()); + if (packet.containerId() == 0) { + player.inventoryMenu.initializeContents(packet.stateId(), packet.items(), packet.carriedItem()); + } else if (packet.containerId() == player.containerMenu.containerId) { + player.containerMenu.initializeContents(packet.stateId(), packet.items(), packet.carriedItem()); } } @@ -1385,11 +1395,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); BlockPos blockPos = packet.getPos(); this.minecraft.level.getBlockEntity(blockPos, packet.getType()).ifPresent(blockEntity -> { - CompoundTag compoundTag = packet.getTag(); - if (!compoundTag.isEmpty()) { - blockEntity.loadWithComponents(compoundTag, this.registryAccess); - } - + blockEntity.loadWithComponents(packet.getTag(), this.registryAccess); if (blockEntity instanceof CommandBlockEntity && this.minecraft.screen instanceof CommandBlockEditScreen) { ((CommandBlockEditScreen)this.minecraft.screen).updateGui(); } @@ -1435,7 +1441,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme public void handleGameEvent(ClientboundGameEventPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); Player player = this.minecraft.player; - Type type = packet.getEvent(); + ClientboundGameEventPacket.Type type = packet.getEvent(); float f = packet.getParam(); int i = Mth.floor(f + 0.5F); if (type == ClientboundGameEventPacket.NO_RESPAWN_BLOCK_AVAILABLE) { @@ -1477,7 +1483,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } else if (f == 104.0F) { this.minecraft.gui.getChat().addMessage(Component.translatable("demo.day.6", options.keyScreenshot.getTranslatedKeyMessage())); } - } else if (type == ClientboundGameEventPacket.ARROW_HIT_PLAYER) { + } else if (type == ClientboundGameEventPacket.PLAY_ARROW_HIT_SOUND) { this.level.playSound(player, player.getX(), player.getEyeY(), player.getZ(), SoundEvents.ARROW_HIT_PLAYER, SoundSource.PLAYERS, 0.18F, 0.45F); } else if (type == ClientboundGameEventPacket.RAIN_LEVEL_CHANGE) { this.level.setRainLevel(f); @@ -1610,7 +1616,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme clientRecipeBook.clear(); } - for (ClientboundRecipeBookAddPacket.Entry entry : packet.entries()) { + for (net.minecraft.network.protocol.game.ClientboundRecipeBookAddPacket.Entry entry : packet.entries()) { clientRecipeBook.add(entry.contents()); if (entry.highlight()) { clientRecipeBook.addHighlight(entry.contents().id()); @@ -1669,7 +1675,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } } - private Registry.PendingTags updateTags(ResourceKey> registryKey, NetworkPayload payload) { + private PendingTags updateTags(ResourceKey> registryKey, NetworkPayload payload) { Registry registry = this.registryAccess.lookupOrThrow(registryKey); return registry.prepareTagReload(payload.resolve(registry)); } @@ -1677,14 +1683,14 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme @Override public void handleUpdateTags(ClientboundUpdateTagsPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); - List> list = new ArrayList(packet.getTags().size()); + List> list = new ArrayList(packet.getTags().size()); boolean bl = this.connection.isMemoryConnection(); packet.getTags().forEach((resourceKey, networkPayload) -> { if (!bl || RegistrySynchronization.isNetworkable(resourceKey)) { list.add(this.updateTags(resourceKey, networkPayload)); } }); - list.forEach(Registry.PendingTags::apply); + list.forEach(PendingTags::apply); this.fuelValues = FuelValues.vanillaBurnTimes(this.registryAccess, this.enabledFeatures); List list2 = List.copyOf(CreativeModeTabs.searchTab().getDisplayItems()); this.searchTrees.updateCreativeTags(list2); @@ -1994,12 +2000,21 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme public void handleMoveVehicle(ClientboundMoveVehiclePacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); Entity entity = this.minecraft.player.getRootVehicle(); - if (entity != this.minecraft.player && entity.isControlledByLocalInstance()) { + if (entity != this.minecraft.player && entity.isLocalInstanceAuthoritative()) { Vec3 vec3 = packet.position(); - Vec3 vec32 = new Vec3(entity.lerpTargetX(), entity.lerpTargetY(), entity.lerpTargetZ()); + Vec3 vec32; + if (entity.isInterpolating()) { + vec32 = entity.getInterpolation().position(); + } else { + vec32 = entity.position(); + } + if (vec3.distanceTo(vec32) > 1.0E-5F) { - entity.cancelLerp(); - entity.absMoveTo(vec3.x(), vec3.y(), vec3.z(), packet.yRot(), packet.xRot()); + if (entity.isInterpolating()) { + entity.getInterpolation().cancel(); + } + + entity.absSnapTo(vec3.x(), vec3.y(), vec3.z(), packet.yRot(), packet.xRot()); } this.connection.send(ServerboundMoveVehiclePacket.fromEntity(entity)); @@ -2045,7 +2060,9 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } else if (payload instanceof PoiTicketCountDebugPayload poiTicketCountDebugPayload) { this.minecraft.debugRenderer.brainDebugRenderer.setFreeTicketCount(poiTicketCountDebugPayload.pos(), poiTicketCountDebugPayload.freeTicketCount()); } else if (payload instanceof PoiAddedDebugPayload poiAddedDebugPayload) { - PoiInfo poiInfo = new PoiInfo(poiAddedDebugPayload.pos(), poiAddedDebugPayload.poiType(), poiAddedDebugPayload.freeTicketCount()); + BrainDebugRenderer.PoiInfo poiInfo = new BrainDebugRenderer.PoiInfo( + poiAddedDebugPayload.pos(), poiAddedDebugPayload.poiType(), poiAddedDebugPayload.freeTicketCount() + ); this.minecraft.debugRenderer.brainDebugRenderer.addPoi(poiInfo); } else if (payload instanceof PoiRemovedDebugPayload poiRemovedDebugPayload) { this.minecraft.debugRenderer.brainDebugRenderer.removePoi(poiRemovedDebugPayload.pos()); @@ -2158,9 +2175,9 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme @Override public void handleSetPlayerTeamPacket(ClientboundSetPlayerTeamPacket packet) { PacketUtils.ensureRunningOnSameThread(packet, this, this.minecraft); - net.minecraft.network.protocol.game.ClientboundSetPlayerTeamPacket.Action action = packet.getTeamAction(); + ClientboundSetPlayerTeamPacket.Action action = packet.getTeamAction(); PlayerTeam playerTeam; - if (action == net.minecraft.network.protocol.game.ClientboundSetPlayerTeamPacket.Action.ADD) { + if (action == ClientboundSetPlayerTeamPacket.Action.ADD) { playerTeam = this.scoreboard.addPlayerTeam(packet.getName()); } else { playerTeam = this.scoreboard.getPlayerTeam(packet.getName()); @@ -2170,36 +2187,28 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } } - Optional optional = packet.getParameters(); + Optional optional = packet.getParameters(); optional.ifPresent(parameters -> { playerTeam.setDisplayName(parameters.getDisplayName()); playerTeam.setColor(parameters.getColor()); playerTeam.unpackOptions(parameters.getOptions()); - Visibility visibility = Visibility.byName(parameters.getNametagVisibility()); - if (visibility != null) { - playerTeam.setNameTagVisibility(visibility); - } - - CollisionRule collisionRule = CollisionRule.byName(parameters.getCollisionRule()); - if (collisionRule != null) { - playerTeam.setCollisionRule(collisionRule); - } - + playerTeam.setNameTagVisibility(parameters.getNametagVisibility()); + playerTeam.setCollisionRule(parameters.getCollisionRule()); playerTeam.setPlayerPrefix(parameters.getPlayerPrefix()); playerTeam.setPlayerSuffix(parameters.getPlayerSuffix()); }); - net.minecraft.network.protocol.game.ClientboundSetPlayerTeamPacket.Action action2 = packet.getPlayerAction(); - if (action2 == net.minecraft.network.protocol.game.ClientboundSetPlayerTeamPacket.Action.ADD) { + ClientboundSetPlayerTeamPacket.Action action2 = packet.getPlayerAction(); + if (action2 == ClientboundSetPlayerTeamPacket.Action.ADD) { for (String string : packet.getPlayers()) { this.scoreboard.addPlayerToTeam(string, playerTeam); } - } else if (action2 == net.minecraft.network.protocol.game.ClientboundSetPlayerTeamPacket.Action.REMOVE) { + } else if (action2 == ClientboundSetPlayerTeamPacket.Action.REMOVE) { for (String string : packet.getPlayers()) { this.scoreboard.removePlayerFromTeam(string, playerTeam); } } - if (action == net.minecraft.network.protocol.game.ClientboundSetPlayerTeamPacket.Action.REMOVE) { + if (action == ClientboundSetPlayerTeamPacket.Action.REMOVE) { this.scoreboard.removePlayerTeam(playerTeam); } } @@ -2375,6 +2384,14 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme this.pingDebugMonitor.onPongReceived(packet); } + @Override + public void handleTestInstanceBlockStatus(ClientboundTestInstanceBlockStatus status) { + PacketUtils.ensureRunningOnSameThread(status, this, this.minecraft); + if (this.minecraft.screen instanceof TestInstanceBlockEditScreen testInstanceBlockEditScreen) { + testInstanceBlockEditScreen.setStatus(status.status(), status.size()); + } + } + private void readSectionList( int x, int z, LevelLightEngine lightEngine, LightLayer lightLayer, BitSet skyYMask, BitSet emptySkyYMask, Iterator skyUpdates, boolean update ) { @@ -2466,9 +2483,8 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme return this.registryAccess; } - public void markMessageAsProcessed(PlayerChatMessage chatMessage, boolean acknowledged) { - MessageSignature messageSignature = chatMessage.signature(); - if (messageSignature != null && this.lastSeenMessages.addPending(messageSignature, acknowledged) && this.lastSeenMessages.offset() > 64) { + public void markMessageAsProcessed(MessageSignature signature, boolean acknowledged) { + if (this.lastSeenMessages.addPending(signature, acknowledged) && this.lastSeenMessages.offset() > 64) { this.sendChatAcknowledgement(); } } @@ -2483,7 +2499,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme public void sendChat(String message) { Instant instant = Instant.now(); long l = SaltSupplier.getLong(); - Update update = this.lastSeenMessages.generateAndApplyUpdate(); + LastSeenMessagesTracker.Update update = this.lastSeenMessages.generateAndApplyUpdate(); MessageSignature messageSignature = this.signedMessageEncoder.pack(new SignedMessageBody(message, instant, l, update.lastSeen())); this.send(new ServerboundChatPacket(message, instant, l, messageSignature, update.update())); } @@ -2495,7 +2511,7 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme } else { Instant instant = Instant.now(); long l = SaltSupplier.getLong(); - Update update = this.lastSeenMessages.generateAndApplyUpdate(); + LastSeenMessagesTracker.Update update = this.lastSeenMessages.generateAndApplyUpdate(); ArgumentSignatures argumentSignatures = ArgumentSignatures.signCommand(signableCommand, string -> { SignedMessageBody signedMessageBody = new SignedMessageBody(string, instant, l, update.lastSeen()); return this.signedMessageEncoder.pack(signedMessageBody); @@ -2601,4 +2617,12 @@ public class ClientPacketListener extends ClientCommonPacketListenerImpl impleme public ServerLinks serverLinks() { return this.serverLinks; } + + public void registerForCleaning(CacheSlot cacheSlot) { + this.cacheSlots.add(new WeakReference(cacheSlot)); + } + + public HashedPatchMap.HashGenerator decoratedHashOpsGenenerator() { + return this.decoratedHashOpsGenerator; + } } diff --git a/net/minecraft/client/multiplayer/MultiPlayerGameMode.java b/net/minecraft/client/multiplayer/MultiPlayerGameMode.java index 490f1b73..2ca72fa6 100644 --- a/net/minecraft/client/multiplayer/MultiPlayerGameMode.java +++ b/net/minecraft/client/multiplayer/MultiPlayerGameMode.java @@ -1,6 +1,8 @@ package net.minecraft.client.multiplayer; import com.google.common.collect.Lists; +import com.google.common.primitives.Shorts; +import com.google.common.primitives.SignedBytes; import com.mojang.logging.LogUtils; import it.unimi.dsi.fastutil.ints.Int2ObjectMap; import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap; @@ -20,6 +22,7 @@ import net.minecraft.client.resources.sounds.SoundInstance; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.core.NonNullList; +import net.minecraft.network.HashedStack; import net.minecraft.network.protocol.Packet; import net.minecraft.network.protocol.game.ServerGamePacketListener; import net.minecraft.network.protocol.game.ServerboundContainerButtonClickPacket; @@ -121,7 +124,7 @@ public class MultiPlayerGameMode { } else { Level level = this.minecraft.level; BlockState blockState = level.getBlockState(pos); - if (!this.minecraft.player.getMainHandItem().getItem().canAttackBlock(blockState, level, pos, this.minecraft.player)) { + if (!this.minecraft.player.getMainHandItem().canDestroyBlock(blockState, level, pos, this.minecraft.player)) { return false; } else { Block block = blockState.getBlock(); @@ -152,7 +155,7 @@ public class MultiPlayerGameMode { } else if (!this.minecraft.level.getWorldBorder().isWithinBounds(loc)) { return false; } else { - if (this.localPlayerMode.isCreative()) { + if (this.minecraft.player.getAbilities().instabuild) { BlockState blockState = this.minecraft.level.getBlockState(loc); this.minecraft.getTutorial().onDestroyBlock(this.minecraft.level, loc, blockState, 1.0F); this.startPrediction(this.minecraft.level, i -> { @@ -212,7 +215,7 @@ public class MultiPlayerGameMode { if (this.destroyDelay > 0) { this.destroyDelay--; return true; - } else if (this.localPlayerMode.isCreative() && this.minecraft.level.getWorldBorder().isWithinBounds(posBlock)) { + } else if (this.minecraft.player.getAbilities().instabuild && this.minecraft.level.getWorldBorder().isWithinBounds(posBlock)) { this.destroyDelay = 5; BlockState blockState = this.minecraft.level.getBlockState(posBlock); this.minecraft.getTutorial().onDestroyBlock(this.minecraft.level, posBlock, blockState, 1.0F); @@ -291,7 +294,7 @@ public class MultiPlayerGameMode { * Syncs the current player item with the server */ private void ensureHasSentCarriedItem() { - int i = this.minecraft.player.getInventory().selected; + int i = this.minecraft.player.getInventory().getSelectedSlot(); if (i != this.carriedIndex) { this.carriedIndex = i; this.connection.send(new ServerboundSetCarriedItemPacket(this.carriedIndex)); @@ -342,7 +345,7 @@ public class MultiPlayerGameMode { if (!itemStack.isEmpty() && !player.getCooldowns().isOnCooldown(itemStack)) { UseOnContext useOnContext = new UseOnContext(player, hand, result); InteractionResult interactionResult3; - if (this.localPlayerMode.isCreative()) { + if (player.hasInfiniteMaterials()) { int i = itemStack.getCount(); interactionResult3 = itemStack.useOn(useOnContext); itemStack.setCount(i); @@ -443,20 +446,21 @@ public class MultiPlayerGameMode { } abstractContainerMenu.clicked(slotId, mouseButton, clickType, player); - Int2ObjectMap int2ObjectMap = new Int2ObjectOpenHashMap<>(); + Int2ObjectMap int2ObjectMap = new Int2ObjectOpenHashMap<>(); for (int j = 0; j < i; j++) { ItemStack itemStack = (ItemStack)list.get(j); ItemStack itemStack2 = nonNullList.get(j).getItem(); if (!ItemStack.matches(itemStack, itemStack2)) { - int2ObjectMap.put(j, itemStack2.copy()); + int2ObjectMap.put(j, HashedStack.create(itemStack2, this.connection.decoratedHashOpsGenenerator())); } } + HashedStack hashedStack = HashedStack.create(abstractContainerMenu.getCarried(), this.connection.decoratedHashOpsGenenerator()); this.connection .send( new ServerboundContainerClickPacket( - containerId, abstractContainerMenu.getStateId(), slotId, mouseButton, clickType, abstractContainerMenu.getCarried().copy(), int2ObjectMap + containerId, abstractContainerMenu.getStateId(), Shorts.checkedCast(slotId), SignedBytes.checkedCast(mouseButton), clickType, int2ObjectMap, hashedStack ) ); } @@ -477,7 +481,7 @@ public class MultiPlayerGameMode { * Used in PlayerControllerMP to update the server with an ItemStack in a slot. */ public void handleCreativeModeItemAdd(ItemStack stack, int slotId) { - if (this.localPlayerMode.isCreative() && this.connection.isFeatureEnabled(stack.getItem().requiredFeatures())) { + if (this.minecraft.player.hasInfiniteMaterials() && this.connection.isFeatureEnabled(stack.getItem().requiredFeatures())) { this.connection.send(new ServerboundSetCreativeModeSlotPacket(slotId, stack)); } } @@ -487,7 +491,7 @@ public class MultiPlayerGameMode { */ public void handleCreativeModeItemDrop(ItemStack stack) { boolean bl = this.minecraft.screen instanceof AbstractContainerScreen && !(this.minecraft.screen instanceof CreativeModeInventoryScreen); - if (this.localPlayerMode.isCreative() && !bl && !stack.isEmpty() && this.connection.isFeatureEnabled(stack.getItem().requiredFeatures())) { + if (this.minecraft.player.hasInfiniteMaterials() && !bl && !stack.isEmpty() && this.connection.isFeatureEnabled(stack.getItem().requiredFeatures())) { this.connection.send(new ServerboundSetCreativeModeSlotPacket(-1, stack)); this.minecraft.player.getDropSpamThrottler().increment(); } @@ -510,13 +514,6 @@ public class MultiPlayerGameMode { return !this.localPlayerMode.isCreative(); } - /** - * Returns {@code true} if player is in creative mode. - */ - public boolean hasInfiniteItems() { - return this.localPlayerMode.isCreative(); - } - /** * Checks if the player is riding a horse, used to choose the GUI to open */ diff --git a/net/minecraft/client/multiplayer/ServerData.java b/net/minecraft/client/multiplayer/ServerData.java index 094fd409..a7a1b4eb 100644 --- a/net/minecraft/client/multiplayer/ServerData.java +++ b/net/minecraft/client/multiplayer/ServerData.java @@ -1,16 +1,19 @@ package net.minecraft.client.multiplayer; import com.mojang.logging.LogUtils; +import com.mojang.serialization.Codec; +import com.mojang.serialization.MapCodec; import java.io.IOException; -import java.util.Base64; import java.util.Collections; import java.util.List; +import java.util.Optional; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.SharedConstants; import net.minecraft.nbt.CompoundTag; import net.minecraft.network.chat.Component; import net.minecraft.network.protocol.status.ServerStatus.Players; +import net.minecraft.util.ExtraCodecs; import net.minecraft.util.PngInfo; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -48,16 +51,8 @@ public class ServerData { CompoundTag compoundTag = new CompoundTag(); compoundTag.putString("name", this.name); compoundTag.putString("ip", this.ip); - if (this.iconBytes != null) { - compoundTag.putString("icon", Base64.getEncoder().encodeToString(this.iconBytes)); - } - - if (this.packStatus == ServerData.ServerPackStatus.ENABLED) { - compoundTag.putBoolean("acceptTextures", true); - } else if (this.packStatus == ServerData.ServerPackStatus.DISABLED) { - compoundTag.putBoolean("acceptTextures", false); - } - + compoundTag.storeNullable("icon", ExtraCodecs.BASE64_STRING, this.iconBytes); + compoundTag.store(ServerData.ServerPackStatus.FIELD_CODEC, this.packStatus); return compoundTag; } @@ -73,26 +68,11 @@ public class ServerData { * Takes an NBTTagCompound with 'name' and 'ip' keys, returns a ServerData instance. */ public static ServerData read(CompoundTag nbtCompound) { - ServerData serverData = new ServerData(nbtCompound.getString("name"), nbtCompound.getString("ip"), ServerData.Type.OTHER); - if (nbtCompound.contains("icon", 8)) { - try { - byte[] bs = Base64.getDecoder().decode(nbtCompound.getString("icon")); - serverData.setIconBytes(validateIcon(bs)); - } catch (IllegalArgumentException var3) { - LOGGER.warn("Malformed base64 server icon", (Throwable)var3); - } - } - - if (nbtCompound.contains("acceptTextures", 99)) { - if (nbtCompound.getBoolean("acceptTextures")) { - serverData.setResourcePackStatus(ServerData.ServerPackStatus.ENABLED); - } else { - serverData.setResourcePackStatus(ServerData.ServerPackStatus.DISABLED); - } - } else { - serverData.setResourcePackStatus(ServerData.ServerPackStatus.PROMPT); - } - + ServerData serverData = new ServerData(nbtCompound.getStringOr("name", ""), nbtCompound.getStringOr("ip", ""), ServerData.Type.OTHER); + serverData.setIconBytes((byte[])nbtCompound.read("icon", ExtraCodecs.BASE64_STRING).orElse(null)); + serverData.setResourcePackStatus( + (ServerData.ServerPackStatus)nbtCompound.read(ServerData.ServerPackStatus.FIELD_CODEC).orElse(ServerData.ServerPackStatus.PROMPT) + ); return serverData; } @@ -162,6 +142,15 @@ public class ServerData { DISABLED("disabled"), PROMPT("prompt"); + public static final MapCodec FIELD_CODEC = Codec.BOOL + .optionalFieldOf("acceptTextures") + .xmap(optional -> (ServerData.ServerPackStatus)optional.map(boolean_ -> boolean_ ? ENABLED : DISABLED).orElse(PROMPT), serverPackStatus -> { + return switch (serverPackStatus) { + case ENABLED -> Optional.of(true); + case DISABLED -> Optional.of(false); + case PROMPT -> Optional.empty(); + }; + }); private final Component name; private ServerPackStatus(final String name) { diff --git a/net/minecraft/client/multiplayer/ServerList.java b/net/minecraft/client/multiplayer/ServerList.java index 6bc01a15..3c3d214e 100644 --- a/net/minecraft/client/multiplayer/ServerList.java +++ b/net/minecraft/client/multiplayer/ServerList.java @@ -42,19 +42,16 @@ public class ServerList { return; } - ListTag listTag = compoundTag.getList("servers", 10); - - for (int i = 0; i < listTag.size(); i++) { - CompoundTag compoundTag2 = listTag.getCompound(i); - ServerData serverData = ServerData.read(compoundTag2); - if (compoundTag2.getBoolean("hidden")) { + compoundTag.getListOrEmpty("servers").compoundStream().forEach(compoundTagx -> { + ServerData serverData = ServerData.read(compoundTagx); + if (compoundTagx.getBooleanOr("hidden", false)) { this.hiddenServerList.add(serverData); } else { this.serverList.add(serverData); } - } - } catch (Exception var6) { - LOGGER.error("Couldn't load server list", (Throwable)var6); + }); + } catch (Exception var2) { + LOGGER.error("Couldn't load server list", (Throwable)var2); } } diff --git a/net/minecraft/client/multiplayer/chat/ChatListener.java b/net/minecraft/client/multiplayer/chat/ChatListener.java index 5eca4538..9d3ceec8 100644 --- a/net/minecraft/client/multiplayer/chat/ChatListener.java +++ b/net/minecraft/client/multiplayer/chat/ChatListener.java @@ -13,11 +13,11 @@ import net.minecraft.Util; import net.minecraft.client.GuiMessageTag; import net.minecraft.client.Minecraft; import net.minecraft.client.multiplayer.ClientPacketListener; -import net.minecraft.network.chat.ChatType; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.FilterMask; import net.minecraft.network.chat.MessageSignature; import net.minecraft.network.chat.PlayerChatMessage; +import net.minecraft.network.chat.ChatType.Bound; import net.minecraft.util.StringDecomposer; import org.apache.commons.lang3.StringUtils; import org.jetbrains.annotations.Nullable; @@ -85,7 +85,7 @@ public class ChatListener { } } - public void handlePlayerChatMessage(PlayerChatMessage chatMessage, GameProfile gameProfile, ChatType.Bound boundChatType) { + public void handlePlayerChatMessage(PlayerChatMessage chatMessage, GameProfile gameProfile, Bound boundChatType) { boolean bl = this.minecraft.options.onlyShowSecureChat().get(); PlayerChatMessage playerChatMessage = bl ? chatMessage.removeUnsignedContent() : chatMessage; Component component = boundChatType.decorate(playerChatMessage.decoratedContent()); @@ -93,16 +93,21 @@ public class ChatListener { this.handleMessage(chatMessage.signature(), () -> { boolean bl2 = this.showMessageToPlayer(boundChatType, chatMessage, component, gameProfile, bl, instant); ClientPacketListener clientPacketListener = this.minecraft.getConnection(); - if (clientPacketListener != null) { - clientPacketListener.markMessageAsProcessed(chatMessage, bl2); + if (clientPacketListener != null && chatMessage.signature() != null) { + clientPacketListener.markMessageAsProcessed(chatMessage.signature(), bl2); } return bl2; }); } - public void handleChatMessageError(UUID sender, ChatType.Bound boundChatType) { + public void handleChatMessageError(UUID sender, @Nullable MessageSignature signature, Bound boundChatType) { this.handleMessage(null, () -> { + ClientPacketListener clientPacketListener = this.minecraft.getConnection(); + if (clientPacketListener != null && signature != null) { + clientPacketListener.markMessageAsProcessed(signature, false); + } + if (this.minecraft.isBlocked(sender)) { return false; } else { @@ -114,7 +119,7 @@ public class ChatListener { }); } - public void handleDisguisedChatMessage(Component message, ChatType.Bound boundChatType) { + public void handleDisguisedChatMessage(Component message, Bound boundChatType) { Instant instant = Instant.now(); this.handleMessage(null, () -> { Component component2 = boundChatType.decorate(message); @@ -127,12 +132,7 @@ public class ChatListener { } private boolean showMessageToPlayer( - ChatType.Bound boundChatType, - PlayerChatMessage chatMessage, - Component decoratedServerContent, - GameProfile gameProfile, - boolean onlyShowSecureChat, - Instant timestamp + Bound boundChatType, PlayerChatMessage chatMessage, Component decoratedServerContent, GameProfile gameProfile, boolean onlyShowSecureChat, Instant timestamp ) { ChatTrustLevel chatTrustLevel = this.evaluateTrustLevel(chatMessage, decoratedServerContent, timestamp); if (onlyShowSecureChat && chatTrustLevel.isNotSecure()) { @@ -160,7 +160,7 @@ public class ChatListener { } } - private void narrateChatMessage(ChatType.Bound boundChatType, Component message) { + private void narrateChatMessage(Bound boundChatType, Component message) { this.minecraft.getNarrator().sayChat(boundChatType.decorateNarration(message)); } @@ -168,7 +168,7 @@ public class ChatListener { return this.isSenderLocalPlayer(chatMessage.sender()) ? ChatTrustLevel.SECURE : ChatTrustLevel.evaluate(chatMessage, decoratedServerContent, timestamp); } - private void logPlayerMessage(PlayerChatMessage message, ChatType.Bound boundChatType, GameProfile gameProfile, ChatTrustLevel trustLevel) { + private void logPlayerMessage(PlayerChatMessage message, Bound boundChatType, GameProfile gameProfile, ChatTrustLevel trustLevel) { ChatLog chatLog = this.minecraft.getReportingContext().chatLog(); chatLog.push(LoggedChatMessage.player(gameProfile, message, trustLevel)); } diff --git a/net/minecraft/client/multiplayer/chat/report/ReportEnvironment.java b/net/minecraft/client/multiplayer/chat/report/ReportEnvironment.java index d0bc2103..a142716b 100644 --- a/net/minecraft/client/multiplayer/chat/report/ReportEnvironment.java +++ b/net/minecraft/client/multiplayer/chat/report/ReportEnvironment.java @@ -46,7 +46,7 @@ public record ReportEnvironment(String clientVersion, @Nullable ReportEnvironmen private static String getClientVersion() { StringBuilder stringBuilder = new StringBuilder(); - stringBuilder.append("1.21.4"); + stringBuilder.append("1.21.5"); if (Minecraft.checkModStatus().shouldReportAsModified()) { stringBuilder.append(" (modded)"); } diff --git a/net/minecraft/client/particle/BreakingItemParticle.java b/net/minecraft/client/particle/BreakingItemParticle.java index 96180a6c..8cdf782b 100644 --- a/net/minecraft/client/particle/BreakingItemParticle.java +++ b/net/minecraft/client/particle/BreakingItemParticle.java @@ -82,7 +82,7 @@ public class BreakingItemParticle extends TextureSheetParticle { private final ItemStackRenderState scratchRenderState = new ItemStackRenderState(); protected ItemStackRenderState calculateState(ItemStack stack, ClientLevel level) { - Minecraft.getInstance().getItemModelResolver().updateForTopItem(this.scratchRenderState, stack, ItemDisplayContext.GROUND, false, level, null, 0); + Minecraft.getInstance().getItemModelResolver().updateForTopItem(this.scratchRenderState, stack, ItemDisplayContext.GROUND, level, null, 0); return this.scratchRenderState; } } diff --git a/net/minecraft/client/particle/FallingLeavesParticle.java b/net/minecraft/client/particle/FallingLeavesParticle.java index 48e9e2b0..8ffa3198 100644 --- a/net/minecraft/client/particle/FallingLeavesParticle.java +++ b/net/minecraft/client/particle/FallingLeavesParticle.java @@ -3,6 +3,7 @@ package net.minecraft.client.particle; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.multiplayer.ClientLevel; +import net.minecraft.core.particles.ColorParticleOption; import net.minecraft.core.particles.SimpleParticleType; @Environment(EnvType.CLIENT) @@ -126,4 +127,19 @@ public class FallingLeavesParticle extends TextureSheetParticle { return new FallingLeavesParticle(clientLevel, d, e, f, this.sprites, 0.07F, 10.0F, true, false, 2.0F, 0.021F); } } + + @Environment(EnvType.CLIENT) + public static class TintedLeavesProvider implements ParticleProvider { + private final SpriteSet sprites; + + public TintedLeavesProvider(SpriteSet sprites) { + this.sprites = sprites; + } + + public Particle createParticle(ColorParticleOption colorParticleOption, ClientLevel clientLevel, double d, double e, double f, double g, double h, double i) { + Particle particle = new FallingLeavesParticle(clientLevel, d, e, f, this.sprites, 0.07F, 10.0F, true, false, 2.0F, 0.021F); + particle.setColor(colorParticleOption.getRed(), colorParticleOption.getGreen(), colorParticleOption.getBlue()); + return particle; + } + } } diff --git a/net/minecraft/client/particle/FireflyParticle.java b/net/minecraft/client/particle/FireflyParticle.java new file mode 100644 index 00000000..cb38be71 --- /dev/null +++ b/net/minecraft/client/particle/FireflyParticle.java @@ -0,0 +1,83 @@ +package net.minecraft.client.particle; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.multiplayer.ClientLevel; +import net.minecraft.core.BlockPos; +import net.minecraft.core.particles.SimpleParticleType; +import net.minecraft.util.Mth; + +@Environment(EnvType.CLIENT) +public class FireflyParticle extends TextureSheetParticle { + private static final float PARTICLE_FADE_OUT_LIGHT_TIME = 0.3F; + private static final float PARTICLE_FADE_IN_LIGHT_TIME = 0.1F; + private static final float PARTICLE_FADE_OUT_ALPHA_TIME = 0.5F; + private static final float PARTICLE_FADE_IN_ALPHA_TIME = 0.3F; + private static final int PARTICLE_MIN_LIFETIME = 36; + private static final int PARTICLE_MAX_LIFETIME = 180; + + FireflyParticle(ClientLevel clientLevel, double d, double e, double f, double g, double h, double i) { + super(clientLevel, d, e, f, g, h, i); + this.speedUpWhenYMotionIsBlocked = true; + this.friction = 0.96F; + this.quadSize *= 0.75F; + this.yd *= 0.8F; + this.xd *= 0.8F; + this.zd *= 0.8F; + } + + @Override + public ParticleRenderType getRenderType() { + return ParticleRenderType.PARTICLE_SHEET_TRANSLUCENT; + } + + @Override + public int getLightColor(float partialTick) { + return (int)(255.0F * getFadeAmount(this.getLifetimeProgress(this.age + partialTick), 0.1F, 0.3F)); + } + + @Override + public void tick() { + super.tick(); + if (!this.level.getBlockState(BlockPos.containing(this.x, this.y, this.z)).isAir()) { + this.remove(); + } else { + this.setAlpha(getFadeAmount(this.getLifetimeProgress(this.age), 0.3F, 0.5F)); + if (Math.random() > 0.95 || this.age == 1) { + this.setParticleSpeed(-0.05F + 0.1F * Math.random(), -0.05F + 0.1F * Math.random(), -0.05F + 0.1F * Math.random()); + } + } + } + + private float getLifetimeProgress(float age) { + return Mth.clamp(age / this.lifetime, 0.0F, 1.0F); + } + + private static float getFadeAmount(float lifetimeProgress, float fadeIn, float fadeOut) { + if (lifetimeProgress >= 1.0F - fadeIn) { + return (1.0F - lifetimeProgress) / fadeIn; + } else { + return lifetimeProgress <= fadeOut ? lifetimeProgress / fadeOut : 1.0F; + } + } + + @Environment(EnvType.CLIENT) + public static class FireflyProvider implements ParticleProvider { + private final SpriteSet sprite; + + public FireflyProvider(SpriteSet sprite) { + this.sprite = sprite; + } + + public Particle createParticle(SimpleParticleType simpleParticleType, ClientLevel clientLevel, double d, double e, double f, double g, double h, double i) { + FireflyParticle fireflyParticle = new FireflyParticle( + clientLevel, d, e, f, 0.5 - clientLevel.random.nextDouble(), clientLevel.random.nextBoolean() ? h : -h, 0.5 - clientLevel.random.nextDouble() + ); + fireflyParticle.setLifetime(clientLevel.random.nextIntBetweenInclusive(36, 180)); + fireflyParticle.scale(1.5F); + fireflyParticle.pickSprite(this.sprite); + fireflyParticle.setAlpha(0.0F); + return fireflyParticle; + } + } +} diff --git a/net/minecraft/client/particle/ParticleEngine.java b/net/minecraft/client/particle/ParticleEngine.java index e6542c85..bc75f6b3 100644 --- a/net/minecraft/client/particle/ParticleEngine.java +++ b/net/minecraft/client/particle/ParticleEngine.java @@ -34,14 +34,50 @@ import net.minecraft.ReportedException; import net.minecraft.Util; import net.minecraft.client.Camera; import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.particle.DustParticle.Provider; +import net.minecraft.client.particle.BlockMarker.Provider; +import net.minecraft.client.particle.CampfireSmokeParticle.CosyProvider; +import net.minecraft.client.particle.CampfireSmokeParticle.SignalProvider; +import net.minecraft.client.particle.CritParticle.DamageIndicatorProvider; +import net.minecraft.client.particle.CritParticle.MagicProvider; +import net.minecraft.client.particle.FireworkParticles.FlashProvider; +import net.minecraft.client.particle.FireworkParticles.SparkProvider; +import net.minecraft.client.particle.FlameParticle.SmallFlameProvider; +import net.minecraft.client.particle.FlyStraightTowardsParticle.OminousSpawnProvider; +import net.minecraft.client.particle.FlyTowardsPositionParticle.EnchantProvider; +import net.minecraft.client.particle.FlyTowardsPositionParticle.NautilusProvider; +import net.minecraft.client.particle.FlyTowardsPositionParticle.VaultConnectionProvider; +import net.minecraft.client.particle.GlowParticle.ElectricSparkProvider; +import net.minecraft.client.particle.GlowParticle.GlowSquidProvider; +import net.minecraft.client.particle.GlowParticle.ScrapeProvider; +import net.minecraft.client.particle.GlowParticle.WaxOffProvider; +import net.minecraft.client.particle.GlowParticle.WaxOnProvider; +import net.minecraft.client.particle.GustParticle.SmallProvider; +import net.minecraft.client.particle.HeartParticle.AngryVillagerProvider; import net.minecraft.client.particle.ParticleProvider.Sprite; +import net.minecraft.client.particle.PlayerCloudParticle.SneezeProvider; +import net.minecraft.client.particle.ReversePortalParticle.ReversePortalProvider; +import net.minecraft.client.particle.SoulParticle.EmissiveProvider; +import net.minecraft.client.particle.SpellParticle.InstantProvider; +import net.minecraft.client.particle.SpellParticle.MobEffectProvider; +import net.minecraft.client.particle.SpellParticle.WitchProvider; +import net.minecraft.client.particle.SquidInkParticle.GlowInkProvider; +import net.minecraft.client.particle.SuspendedParticle.CrimsonSporeProvider; +import net.minecraft.client.particle.SuspendedParticle.SporeBlossomAirProvider; +import net.minecraft.client.particle.SuspendedParticle.UnderwaterProvider; +import net.minecraft.client.particle.SuspendedParticle.WarpedSporeProvider; +import net.minecraft.client.particle.SuspendedTownParticle.ComposterFillProvider; +import net.minecraft.client.particle.SuspendedTownParticle.DolphinSpeedProvider; +import net.minecraft.client.particle.SuspendedTownParticle.EggCrackProvider; +import net.minecraft.client.particle.SuspendedTownParticle.HappyVillagerProvider; +import net.minecraft.client.particle.TerrainParticle.CrumblingProvider; +import net.minecraft.client.particle.TerrainParticle.DustPillarProvider; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.MultiBufferSource.BufferSource; import net.minecraft.client.renderer.texture.SpriteLoader; import net.minecraft.client.renderer.texture.TextureAtlas; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.renderer.texture.TextureManager; +import net.minecraft.client.resources.model.AtlasIds; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.core.particles.ParticleGroup; @@ -54,7 +90,6 @@ import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.PreparableReloadListener; import net.minecraft.server.packs.resources.Resource; import net.minecraft.server.packs.resources.ResourceManager; -import net.minecraft.server.packs.resources.PreparableReloadListener.PreparationBarrier; import net.minecraft.util.GsonHelper; import net.minecraft.util.Mth; import net.minecraft.util.RandomSource; @@ -72,7 +107,6 @@ import org.slf4j.Logger; public class ParticleEngine implements PreparableReloadListener { private static final Logger LOGGER = LogUtils.getLogger(); private static final FileToIdConverter PARTICLE_LISTER = FileToIdConverter.json("particles"); - private static final ResourceLocation PARTICLES_ATLAS_INFO = ResourceLocation.withDefaultNamespace("particles"); private static final int MAX_PARTICLES_PER_LAYER = 16384; private static final List RENDER_ORDER = List.of( ParticleRenderType.TERRAIN_SHEET, ParticleRenderType.PARTICLE_SHEET_OPAQUE, ParticleRenderType.PARTICLE_SHEET_TRANSLUCENT @@ -80,7 +114,6 @@ public class ParticleEngine implements PreparableReloadListener { protected ClientLevel level; private final Map> particles = Maps.>newIdentityHashMap(); private final Queue trackingEmitters = Queues.newArrayDeque(); - private final TextureManager textureManager; private final RandomSource random = RandomSource.create(); private final Int2ObjectMap> providers = new Int2ObjectOpenHashMap<>(); private final Queue particlesToAdd = Queues.newArrayDeque(); @@ -92,123 +125,124 @@ public class ParticleEngine implements PreparableReloadListener { this.textureAtlas = new TextureAtlas(TextureAtlas.LOCATION_PARTICLES); textureManager.register(this.textureAtlas.location(), this.textureAtlas); this.level = level; - this.textureManager = textureManager; this.registerProviders(); } private void registerProviders() { - this.register(ParticleTypes.ANGRY_VILLAGER, HeartParticle.AngryVillagerProvider::new); - this.register(ParticleTypes.BLOCK_MARKER, new BlockMarker.Provider()); - this.register(ParticleTypes.BLOCK, new TerrainParticle.Provider()); - this.register(ParticleTypes.BUBBLE, BubbleParticle.Provider::new); - this.register(ParticleTypes.BUBBLE_COLUMN_UP, BubbleColumnUpParticle.Provider::new); - this.register(ParticleTypes.BUBBLE_POP, BubblePopParticle.Provider::new); - this.register(ParticleTypes.CAMPFIRE_COSY_SMOKE, CampfireSmokeParticle.CosyProvider::new); - this.register(ParticleTypes.CAMPFIRE_SIGNAL_SMOKE, CampfireSmokeParticle.SignalProvider::new); - this.register(ParticleTypes.CLOUD, PlayerCloudParticle.Provider::new); - this.register(ParticleTypes.COMPOSTER, SuspendedTownParticle.ComposterFillProvider::new); - this.register(ParticleTypes.CRIT, CritParticle.Provider::new); - this.register(ParticleTypes.CURRENT_DOWN, WaterCurrentDownParticle.Provider::new); - this.register(ParticleTypes.DAMAGE_INDICATOR, CritParticle.DamageIndicatorProvider::new); - this.register(ParticleTypes.DRAGON_BREATH, DragonBreathParticle.Provider::new); - this.register(ParticleTypes.DOLPHIN, SuspendedTownParticle.DolphinSpeedProvider::new); + this.register(ParticleTypes.ANGRY_VILLAGER, AngryVillagerProvider::new); + this.register(ParticleTypes.BLOCK_MARKER, new Provider()); + this.register(ParticleTypes.BLOCK, new net.minecraft.client.particle.TerrainParticle.Provider()); + this.register(ParticleTypes.BUBBLE, net.minecraft.client.particle.BubbleParticle.Provider::new); + this.register(ParticleTypes.BUBBLE_COLUMN_UP, net.minecraft.client.particle.BubbleColumnUpParticle.Provider::new); + this.register(ParticleTypes.BUBBLE_POP, net.minecraft.client.particle.BubblePopParticle.Provider::new); + this.register(ParticleTypes.CAMPFIRE_COSY_SMOKE, CosyProvider::new); + this.register(ParticleTypes.CAMPFIRE_SIGNAL_SMOKE, SignalProvider::new); + this.register(ParticleTypes.CLOUD, net.minecraft.client.particle.PlayerCloudParticle.Provider::new); + this.register(ParticleTypes.COMPOSTER, ComposterFillProvider::new); + this.register(ParticleTypes.CRIT, net.minecraft.client.particle.CritParticle.Provider::new); + this.register(ParticleTypes.CURRENT_DOWN, net.minecraft.client.particle.WaterCurrentDownParticle.Provider::new); + this.register(ParticleTypes.DAMAGE_INDICATOR, DamageIndicatorProvider::new); + this.register(ParticleTypes.DRAGON_BREATH, net.minecraft.client.particle.DragonBreathParticle.Provider::new); + this.register(ParticleTypes.DOLPHIN, DolphinSpeedProvider::new); this.register(ParticleTypes.DRIPPING_LAVA, DripParticle::createLavaHangParticle); this.register(ParticleTypes.FALLING_LAVA, DripParticle::createLavaFallParticle); this.register(ParticleTypes.LANDING_LAVA, DripParticle::createLavaLandParticle); this.register(ParticleTypes.DRIPPING_WATER, DripParticle::createWaterHangParticle); this.register(ParticleTypes.FALLING_WATER, DripParticle::createWaterFallParticle); - this.register(ParticleTypes.DUST, Provider::new); - this.register(ParticleTypes.DUST_COLOR_TRANSITION, DustColorTransitionParticle.Provider::new); - this.register(ParticleTypes.EFFECT, SpellParticle.Provider::new); + this.register(ParticleTypes.DUST, net.minecraft.client.particle.DustParticle.Provider::new); + this.register(ParticleTypes.DUST_COLOR_TRANSITION, net.minecraft.client.particle.DustColorTransitionParticle.Provider::new); + this.register(ParticleTypes.EFFECT, net.minecraft.client.particle.SpellParticle.Provider::new); this.register(ParticleTypes.ELDER_GUARDIAN, new MobAppearanceParticle.Provider()); - this.register(ParticleTypes.ENCHANTED_HIT, CritParticle.MagicProvider::new); - this.register(ParticleTypes.ENCHANT, FlyTowardsPositionParticle.EnchantProvider::new); + this.register(ParticleTypes.ENCHANTED_HIT, MagicProvider::new); + this.register(ParticleTypes.ENCHANT, EnchantProvider::new); this.register(ParticleTypes.END_ROD, net.minecraft.client.particle.EndRodParticle.Provider::new); - this.register(ParticleTypes.ENTITY_EFFECT, SpellParticle.MobEffectProvider::new); - this.register(ParticleTypes.EXPLOSION_EMITTER, new HugeExplosionSeedParticle.Provider()); - this.register(ParticleTypes.EXPLOSION, HugeExplosionParticle.Provider::new); - this.register(ParticleTypes.SONIC_BOOM, SonicBoomParticle.Provider::new); - this.register(ParticleTypes.FALLING_DUST, FallingDustParticle.Provider::new); - this.register(ParticleTypes.GUST, GustParticle.Provider::new); - this.register(ParticleTypes.SMALL_GUST, GustParticle.SmallProvider::new); - this.register(ParticleTypes.GUST_EMITTER_LARGE, new GustSeedParticle.Provider(3.0, 7, 0)); - this.register(ParticleTypes.GUST_EMITTER_SMALL, new GustSeedParticle.Provider(1.0, 3, 2)); - this.register(ParticleTypes.FIREWORK, FireworkParticles.SparkProvider::new); - this.register(ParticleTypes.FISHING, WakeParticle.Provider::new); - this.register(ParticleTypes.FLAME, FlameParticle.Provider::new); - this.register(ParticleTypes.INFESTED, SpellParticle.Provider::new); - this.register(ParticleTypes.SCULK_SOUL, SoulParticle.EmissiveProvider::new); - this.register(ParticleTypes.SCULK_CHARGE, SculkChargeParticle.Provider::new); - this.register(ParticleTypes.SCULK_CHARGE_POP, SculkChargePopParticle.Provider::new); - this.register(ParticleTypes.SOUL, SoulParticle.Provider::new); - this.register(ParticleTypes.SOUL_FIRE_FLAME, FlameParticle.Provider::new); - this.register(ParticleTypes.FLASH, FireworkParticles.FlashProvider::new); - this.register(ParticleTypes.HAPPY_VILLAGER, SuspendedTownParticle.HappyVillagerProvider::new); - this.register(ParticleTypes.HEART, HeartParticle.Provider::new); - this.register(ParticleTypes.INSTANT_EFFECT, SpellParticle.InstantProvider::new); + this.register(ParticleTypes.ENTITY_EFFECT, MobEffectProvider::new); + this.register(ParticleTypes.EXPLOSION_EMITTER, new net.minecraft.client.particle.HugeExplosionSeedParticle.Provider()); + this.register(ParticleTypes.EXPLOSION, net.minecraft.client.particle.HugeExplosionParticle.Provider::new); + this.register(ParticleTypes.SONIC_BOOM, net.minecraft.client.particle.SonicBoomParticle.Provider::new); + this.register(ParticleTypes.FALLING_DUST, net.minecraft.client.particle.FallingDustParticle.Provider::new); + this.register(ParticleTypes.GUST, net.minecraft.client.particle.GustParticle.Provider::new); + this.register(ParticleTypes.SMALL_GUST, SmallProvider::new); + this.register(ParticleTypes.GUST_EMITTER_LARGE, new net.minecraft.client.particle.GustSeedParticle.Provider(3.0, 7, 0)); + this.register(ParticleTypes.GUST_EMITTER_SMALL, new net.minecraft.client.particle.GustSeedParticle.Provider(1.0, 3, 2)); + this.register(ParticleTypes.FIREWORK, SparkProvider::new); + this.register(ParticleTypes.FISHING, net.minecraft.client.particle.WakeParticle.Provider::new); + this.register(ParticleTypes.FLAME, net.minecraft.client.particle.FlameParticle.Provider::new); + this.register(ParticleTypes.INFESTED, net.minecraft.client.particle.SpellParticle.Provider::new); + this.register(ParticleTypes.SCULK_SOUL, EmissiveProvider::new); + this.register(ParticleTypes.SCULK_CHARGE, net.minecraft.client.particle.SculkChargeParticle.Provider::new); + this.register(ParticleTypes.SCULK_CHARGE_POP, net.minecraft.client.particle.SculkChargePopParticle.Provider::new); + this.register(ParticleTypes.SOUL, net.minecraft.client.particle.SoulParticle.Provider::new); + this.register(ParticleTypes.SOUL_FIRE_FLAME, net.minecraft.client.particle.FlameParticle.Provider::new); + this.register(ParticleTypes.FLASH, FlashProvider::new); + this.register(ParticleTypes.HAPPY_VILLAGER, HappyVillagerProvider::new); + this.register(ParticleTypes.HEART, net.minecraft.client.particle.HeartParticle.Provider::new); + this.register(ParticleTypes.INSTANT_EFFECT, InstantProvider::new); this.register(ParticleTypes.ITEM, new BreakingItemParticle.Provider()); this.register(ParticleTypes.ITEM_SLIME, new BreakingItemParticle.SlimeProvider()); this.register(ParticleTypes.ITEM_COBWEB, new BreakingItemParticle.CobwebProvider()); this.register(ParticleTypes.ITEM_SNOWBALL, new BreakingItemParticle.SnowballProvider()); this.register(ParticleTypes.LARGE_SMOKE, net.minecraft.client.particle.LargeSmokeParticle.Provider::new); - this.register(ParticleTypes.LAVA, LavaParticle.Provider::new); - this.register(ParticleTypes.MYCELIUM, SuspendedTownParticle.Provider::new); - this.register(ParticleTypes.NAUTILUS, FlyTowardsPositionParticle.NautilusProvider::new); - this.register(ParticleTypes.NOTE, NoteParticle.Provider::new); - this.register(ParticleTypes.POOF, ExplodeParticle.Provider::new); - this.register(ParticleTypes.PORTAL, PortalParticle.Provider::new); - this.register(ParticleTypes.RAIN, WaterDropParticle.Provider::new); + this.register(ParticleTypes.LAVA, net.minecraft.client.particle.LavaParticle.Provider::new); + this.register(ParticleTypes.MYCELIUM, net.minecraft.client.particle.SuspendedTownParticle.Provider::new); + this.register(ParticleTypes.NAUTILUS, NautilusProvider::new); + this.register(ParticleTypes.NOTE, net.minecraft.client.particle.NoteParticle.Provider::new); + this.register(ParticleTypes.POOF, net.minecraft.client.particle.ExplodeParticle.Provider::new); + this.register(ParticleTypes.PORTAL, net.minecraft.client.particle.PortalParticle.Provider::new); + this.register(ParticleTypes.RAIN, net.minecraft.client.particle.WaterDropParticle.Provider::new); this.register(ParticleTypes.SMOKE, net.minecraft.client.particle.SmokeParticle.Provider::new); - this.register(ParticleTypes.WHITE_SMOKE, WhiteSmokeParticle.Provider::new); - this.register(ParticleTypes.SNEEZE, PlayerCloudParticle.SneezeProvider::new); - this.register(ParticleTypes.SNOWFLAKE, SnowflakeParticle.Provider::new); - this.register(ParticleTypes.SPIT, SpitParticle.Provider::new); - this.register(ParticleTypes.SWEEP_ATTACK, AttackSweepParticle.Provider::new); + this.register(ParticleTypes.WHITE_SMOKE, net.minecraft.client.particle.WhiteSmokeParticle.Provider::new); + this.register(ParticleTypes.SNEEZE, SneezeProvider::new); + this.register(ParticleTypes.SNOWFLAKE, net.minecraft.client.particle.SnowflakeParticle.Provider::new); + this.register(ParticleTypes.SPIT, net.minecraft.client.particle.SpitParticle.Provider::new); + this.register(ParticleTypes.SWEEP_ATTACK, net.minecraft.client.particle.AttackSweepParticle.Provider::new); this.register(ParticleTypes.TOTEM_OF_UNDYING, net.minecraft.client.particle.TotemParticle.Provider::new); - this.register(ParticleTypes.SQUID_INK, SquidInkParticle.Provider::new); - this.register(ParticleTypes.UNDERWATER, SuspendedParticle.UnderwaterProvider::new); - this.register(ParticleTypes.SPLASH, SplashParticle.Provider::new); - this.register(ParticleTypes.WITCH, SpellParticle.WitchProvider::new); + this.register(ParticleTypes.SQUID_INK, net.minecraft.client.particle.SquidInkParticle.Provider::new); + this.register(ParticleTypes.UNDERWATER, UnderwaterProvider::new); + this.register(ParticleTypes.SPLASH, net.minecraft.client.particle.SplashParticle.Provider::new); + this.register(ParticleTypes.WITCH, WitchProvider::new); this.register(ParticleTypes.DRIPPING_HONEY, DripParticle::createHoneyHangParticle); this.register(ParticleTypes.FALLING_HONEY, DripParticle::createHoneyFallParticle); this.register(ParticleTypes.LANDING_HONEY, DripParticle::createHoneyLandParticle); this.register(ParticleTypes.FALLING_NECTAR, DripParticle::createNectarFallParticle); this.register(ParticleTypes.FALLING_SPORE_BLOSSOM, DripParticle::createSporeBlossomFallParticle); - this.register(ParticleTypes.SPORE_BLOSSOM_AIR, SuspendedParticle.SporeBlossomAirProvider::new); + this.register(ParticleTypes.SPORE_BLOSSOM_AIR, SporeBlossomAirProvider::new); this.register(ParticleTypes.ASH, net.minecraft.client.particle.AshParticle.Provider::new); - this.register(ParticleTypes.CRIMSON_SPORE, SuspendedParticle.CrimsonSporeProvider::new); - this.register(ParticleTypes.WARPED_SPORE, SuspendedParticle.WarpedSporeProvider::new); + this.register(ParticleTypes.CRIMSON_SPORE, CrimsonSporeProvider::new); + this.register(ParticleTypes.WARPED_SPORE, WarpedSporeProvider::new); this.register(ParticleTypes.DRIPPING_OBSIDIAN_TEAR, DripParticle::createObsidianTearHangParticle); this.register(ParticleTypes.FALLING_OBSIDIAN_TEAR, DripParticle::createObsidianTearFallParticle); this.register(ParticleTypes.LANDING_OBSIDIAN_TEAR, DripParticle::createObsidianTearLandParticle); - this.register(ParticleTypes.REVERSE_PORTAL, ReversePortalParticle.ReversePortalProvider::new); + this.register(ParticleTypes.REVERSE_PORTAL, ReversePortalProvider::new); this.register(ParticleTypes.WHITE_ASH, net.minecraft.client.particle.WhiteAshParticle.Provider::new); - this.register(ParticleTypes.SMALL_FLAME, FlameParticle.SmallFlameProvider::new); + this.register(ParticleTypes.SMALL_FLAME, SmallFlameProvider::new); this.register(ParticleTypes.DRIPPING_DRIPSTONE_WATER, DripParticle::createDripstoneWaterHangParticle); this.register(ParticleTypes.FALLING_DRIPSTONE_WATER, DripParticle::createDripstoneWaterFallParticle); this.register(ParticleTypes.CHERRY_LEAVES, FallingLeavesParticle.CherryProvider::new); this.register(ParticleTypes.PALE_OAK_LEAVES, FallingLeavesParticle.PaleOakProvider::new); + this.register(ParticleTypes.TINTED_LEAVES, FallingLeavesParticle.TintedLeavesProvider::new); this.register(ParticleTypes.DRIPPING_DRIPSTONE_LAVA, DripParticle::createDripstoneLavaHangParticle); this.register(ParticleTypes.FALLING_DRIPSTONE_LAVA, DripParticle::createDripstoneLavaFallParticle); - this.register(ParticleTypes.VIBRATION, VibrationSignalParticle.Provider::new); - this.register(ParticleTypes.TRAIL, TrailParticle.Provider::new); - this.register(ParticleTypes.GLOW_SQUID_INK, SquidInkParticle.GlowInkProvider::new); - this.register(ParticleTypes.GLOW, GlowParticle.GlowSquidProvider::new); - this.register(ParticleTypes.WAX_ON, GlowParticle.WaxOnProvider::new); - this.register(ParticleTypes.WAX_OFF, GlowParticle.WaxOffProvider::new); - this.register(ParticleTypes.ELECTRIC_SPARK, GlowParticle.ElectricSparkProvider::new); - this.register(ParticleTypes.SCRAPE, GlowParticle.ScrapeProvider::new); - this.register(ParticleTypes.SHRIEK, ShriekParticle.Provider::new); - this.register(ParticleTypes.EGG_CRACK, SuspendedTownParticle.EggCrackProvider::new); - this.register(ParticleTypes.DUST_PLUME, DustPlumeParticle.Provider::new); - this.register(ParticleTypes.TRIAL_SPAWNER_DETECTED_PLAYER, TrialSpawnerDetectionParticle.Provider::new); - this.register(ParticleTypes.TRIAL_SPAWNER_DETECTED_PLAYER_OMINOUS, TrialSpawnerDetectionParticle.Provider::new); - this.register(ParticleTypes.VAULT_CONNECTION, FlyTowardsPositionParticle.VaultConnectionProvider::new); - this.register(ParticleTypes.DUST_PILLAR, new TerrainParticle.DustPillarProvider()); - this.register(ParticleTypes.RAID_OMEN, SpellParticle.Provider::new); - this.register(ParticleTypes.TRIAL_OMEN, SpellParticle.Provider::new); - this.register(ParticleTypes.OMINOUS_SPAWNING, FlyStraightTowardsParticle.OminousSpawnProvider::new); - this.register(ParticleTypes.BLOCK_CRUMBLE, new TerrainParticle.CrumblingProvider()); + this.register(ParticleTypes.VIBRATION, net.minecraft.client.particle.VibrationSignalParticle.Provider::new); + this.register(ParticleTypes.TRAIL, net.minecraft.client.particle.TrailParticle.Provider::new); + this.register(ParticleTypes.GLOW_SQUID_INK, GlowInkProvider::new); + this.register(ParticleTypes.GLOW, GlowSquidProvider::new); + this.register(ParticleTypes.WAX_ON, WaxOnProvider::new); + this.register(ParticleTypes.WAX_OFF, WaxOffProvider::new); + this.register(ParticleTypes.ELECTRIC_SPARK, ElectricSparkProvider::new); + this.register(ParticleTypes.SCRAPE, ScrapeProvider::new); + this.register(ParticleTypes.SHRIEK, net.minecraft.client.particle.ShriekParticle.Provider::new); + this.register(ParticleTypes.EGG_CRACK, EggCrackProvider::new); + this.register(ParticleTypes.DUST_PLUME, net.minecraft.client.particle.DustPlumeParticle.Provider::new); + this.register(ParticleTypes.TRIAL_SPAWNER_DETECTED_PLAYER, net.minecraft.client.particle.TrialSpawnerDetectionParticle.Provider::new); + this.register(ParticleTypes.TRIAL_SPAWNER_DETECTED_PLAYER_OMINOUS, net.minecraft.client.particle.TrialSpawnerDetectionParticle.Provider::new); + this.register(ParticleTypes.VAULT_CONNECTION, VaultConnectionProvider::new); + this.register(ParticleTypes.DUST_PILLAR, new DustPillarProvider()); + this.register(ParticleTypes.RAID_OMEN, net.minecraft.client.particle.SpellParticle.Provider::new); + this.register(ParticleTypes.TRIAL_OMEN, net.minecraft.client.particle.SpellParticle.Provider::new); + this.register(ParticleTypes.OMINOUS_SPAWNING, OminousSpawnProvider::new); + this.register(ParticleTypes.BLOCK_CRUMBLE, new CrumblingProvider()); + this.register(ParticleTypes.FIREFLY, FireflyParticle.FireflyProvider::new); } private void register(ParticleType particleType, ParticleProvider particleFactory) { @@ -233,13 +267,15 @@ public class ParticleEngine implements PreparableReloadListener { } @Override - public CompletableFuture reload(PreparationBarrier barrier, ResourceManager manager, Executor backgroundExecutor, Executor gameExecutor) { + public CompletableFuture reload( + PreparableReloadListener.PreparationBarrier preparationBarrier, ResourceManager resourceManager, Executor executor, Executor executor2 + ) { @Environment(EnvType.CLIENT) record ParticleDefinition(ResourceLocation id, Optional> sprites) { } CompletableFuture> completableFuture = CompletableFuture.supplyAsync( - () -> PARTICLE_LISTER.listMatchingResources(manager), backgroundExecutor + () -> PARTICLE_LISTER.listMatchingResources(resourceManager), executor ) .thenCompose( map -> { @@ -248,9 +284,7 @@ public class ParticleEngine implements PreparableReloadListener { (resourceLocation, resource) -> { ResourceLocation resourceLocation2 = PARTICLE_LISTER.fileToId(resourceLocation); list.add( - CompletableFuture.supplyAsync( - () -> new ParticleDefinition(resourceLocation2, this.loadParticleDescription(resourceLocation2, resource)), backgroundExecutor - ) + CompletableFuture.supplyAsync(() -> new ParticleDefinition(resourceLocation2, this.loadParticleDescription(resourceLocation2, resource)), executor) ); } ); @@ -258,9 +292,9 @@ public class ParticleEngine implements PreparableReloadListener { } ); CompletableFuture completableFuture2 = SpriteLoader.create(this.textureAtlas) - .loadAndStitch(manager, PARTICLES_ATLAS_INFO, 0, backgroundExecutor) + .loadAndStitch(resourceManager, AtlasIds.PARTICLES, 0, executor) .thenCompose(SpriteLoader.Preparations::waitForUpload); - return CompletableFuture.allOf(completableFuture2, completableFuture).thenCompose(barrier::wait).thenAcceptAsync(void_ -> { + return CompletableFuture.allOf(completableFuture2, completableFuture).thenCompose(preparationBarrier::wait).thenAcceptAsync(void_ -> { this.clearParticles(); ProfilerFiller profilerFiller = Profiler.get(); profilerFiller.push("upload"); @@ -296,7 +330,7 @@ public class ParticleEngine implements PreparableReloadListener { } profilerFiller.pop(); - }, gameExecutor); + }, executor2); } public void close() { diff --git a/net/minecraft/client/player/AbstractClientPlayer.java b/net/minecraft/client/player/AbstractClientPlayer.java index 01c7fbaf..f4e55763 100644 --- a/net/minecraft/client/player/AbstractClientPlayer.java +++ b/net/minecraft/client/player/AbstractClientPlayer.java @@ -33,16 +33,11 @@ public abstract class AbstractClientPlayer extends Player { this.clientLevel = clientLevel; } + @Nullable @Override - public boolean isSpectator() { + public GameType gameMode() { PlayerInfo playerInfo = this.getPlayerInfo(); - return playerInfo != null && playerInfo.getGameMode() == GameType.SPECTATOR; - } - - @Override - public boolean isCreative() { - PlayerInfo playerInfo = this.getPlayerInfo(); - return playerInfo != null && playerInfo.getGameMode() == GameType.CREATIVE; + return playerInfo != null ? playerInfo.getGameMode() : null; } @Nullable diff --git a/net/minecraft/client/player/ClientInput.java b/net/minecraft/client/player/ClientInput.java index f431ca15..e0e87a82 100644 --- a/net/minecraft/client/player/ClientInput.java +++ b/net/minecraft/client/player/ClientInput.java @@ -8,18 +8,17 @@ import net.minecraft.world.phys.Vec2; @Environment(EnvType.CLIENT) public class ClientInput { public Input keyPresses = Input.EMPTY; - public float leftImpulse; - public float forwardImpulse; + protected Vec2 moveVector = Vec2.ZERO; public void tick() { } public Vec2 getMoveVector() { - return new Vec2(this.leftImpulse, this.forwardImpulse); + return this.moveVector; } public boolean hasForwardImpulse() { - return this.forwardImpulse > 1.0E-5F; + return this.moveVector.y > 1.0E-5F; } public void makeJump() { diff --git a/net/minecraft/client/player/KeyboardInput.java b/net/minecraft/client/player/KeyboardInput.java index 8d515487..ccd67f45 100644 --- a/net/minecraft/client/player/KeyboardInput.java +++ b/net/minecraft/client/player/KeyboardInput.java @@ -4,6 +4,7 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.Options; import net.minecraft.world.entity.player.Input; +import net.minecraft.world.phys.Vec2; @Environment(EnvType.CLIENT) public class KeyboardInput extends ClientInput { @@ -32,7 +33,8 @@ public class KeyboardInput extends ClientInput { this.options.keyShift.isDown(), this.options.keySprint.isDown() ); - this.forwardImpulse = calculateImpulse(this.keyPresses.forward(), this.keyPresses.backward()); - this.leftImpulse = calculateImpulse(this.keyPresses.left(), this.keyPresses.right()); + float f = calculateImpulse(this.keyPresses.forward(), this.keyPresses.backward()); + float g = calculateImpulse(this.keyPresses.left(), this.keyPresses.right()); + this.moveVector = new Vec2(g, f).normalized(); } } diff --git a/net/minecraft/client/player/LocalPlayer.java b/net/minecraft/client/player/LocalPlayer.java index 84b9e0ac..8687e0d1 100644 --- a/net/minecraft/client/player/LocalPlayer.java +++ b/net/minecraft/client/player/LocalPlayer.java @@ -22,6 +22,8 @@ import net.minecraft.client.gui.screens.inventory.JigsawBlockEditScreen; import net.minecraft.client.gui.screens.inventory.MinecartCommandBlockEditScreen; import net.minecraft.client.gui.screens.inventory.SignEditScreen; import net.minecraft.client.gui.screens.inventory.StructureBlockEditScreen; +import net.minecraft.client.gui.screens.inventory.TestBlockEditScreen; +import net.minecraft.client.gui.screens.inventory.TestInstanceBlockEditScreen; import net.minecraft.client.multiplayer.ClientLevel; import net.minecraft.client.multiplayer.ClientPacketListener; import net.minecraft.client.resources.sounds.AmbientSoundHandler; @@ -34,14 +36,12 @@ import net.minecraft.client.resources.sounds.UnderwaterAmbientSoundHandler; import net.minecraft.client.resources.sounds.UnderwaterAmbientSoundInstances.UnderwaterAmbientSoundInstance; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; -import net.minecraft.core.Holder; -import net.minecraft.core.Direction.Axis; -import net.minecraft.core.Direction.AxisDirection; import net.minecraft.core.component.DataComponents; import net.minecraft.core.particles.ParticleTypes; import net.minecraft.network.chat.Component; import net.minecraft.network.protocol.game.ServerboundClientCommandPacket; import net.minecraft.network.protocol.game.ServerboundContainerClosePacket; +import net.minecraft.network.protocol.game.ServerboundMovePlayerPacket; import net.minecraft.network.protocol.game.ServerboundMoveVehiclePacket; import net.minecraft.network.protocol.game.ServerboundPlayerAbilitiesPacket; import net.minecraft.network.protocol.game.ServerboundPlayerActionPacket; @@ -49,10 +49,6 @@ import net.minecraft.network.protocol.game.ServerboundPlayerCommandPacket; import net.minecraft.network.protocol.game.ServerboundPlayerInputPacket; import net.minecraft.network.protocol.game.ServerboundRecipeBookSeenRecipePacket; import net.minecraft.network.protocol.game.ServerboundSwingPacket; -import net.minecraft.network.protocol.game.ServerboundMovePlayerPacket.Pos; -import net.minecraft.network.protocol.game.ServerboundMovePlayerPacket.PosRot; -import net.minecraft.network.protocol.game.ServerboundMovePlayerPacket.Rot; -import net.minecraft.network.protocol.game.ServerboundMovePlayerPacket.StatusOnly; import net.minecraft.network.protocol.game.ServerboundPlayerCommandPacket.Action; import net.minecraft.network.syncher.EntityDataAccessor; import net.minecraft.sounds.SoundEvent; @@ -63,11 +59,8 @@ import net.minecraft.tags.FluidTags; import net.minecraft.util.Mth; import net.minecraft.util.TickThrottler; import net.minecraft.world.InteractionHand; -import net.minecraft.world.effect.MobEffect; -import net.minecraft.world.effect.MobEffectInstance; import net.minecraft.world.effect.MobEffects; import net.minecraft.world.entity.Entity; -import net.minecraft.world.entity.EntityType; import net.minecraft.world.entity.HumanoidArm; import net.minecraft.world.entity.MoverType; import net.minecraft.world.entity.PlayerRideableJumping; @@ -89,6 +82,8 @@ import net.minecraft.world.level.block.entity.HangingSignBlockEntity; import net.minecraft.world.level.block.entity.JigsawBlockEntity; import net.minecraft.world.level.block.entity.SignBlockEntity; import net.minecraft.world.level.block.entity.StructureBlockEntity; +import net.minecraft.world.level.block.entity.TestBlockEntity; +import net.minecraft.world.level.block.entity.TestInstanceBlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.phys.AABB; import net.minecraft.world.phys.Vec2; @@ -154,8 +149,8 @@ public class LocalPlayer extends AbstractClientPlayer { public float xBobO; private int jumpRidingTicks; private float jumpRidingScale; - public float spinningEffectIntensity; - public float oSpinningEffectIntensity; + public float portalEffectIntensity; + public float oPortalEffectIntensity; private boolean startedUsingItem; @Nullable private InteractionHand usingItemHand; @@ -235,9 +230,9 @@ public class LocalPlayer extends AbstractClientPlayer { } if (this.isPassenger()) { - this.connection.send(new Rot(this.getYRot(), this.getXRot(), this.onGround(), this.horizontalCollision)); + this.connection.send(new ServerboundMovePlayerPacket.Rot(this.getYRot(), this.getXRot(), this.onGround(), this.horizontalCollision)); Entity entity = this.getRootVehicle(); - if (entity != this && entity.isControlledByLocalInstance()) { + if (entity != this && entity.isLocalInstanceAuthoritative()) { this.connection.send(ServerboundMoveVehiclePacket.fromEntity(entity)); this.sendIsSprintingIfNeeded(); } @@ -276,13 +271,13 @@ public class LocalPlayer extends AbstractClientPlayer { boolean bl = Mth.lengthSquared(d, e, f) > Mth.square(2.0E-4) || this.positionReminder >= 20; boolean bl2 = g != 0.0 || h != 0.0; if (bl && bl2) { - this.connection.send(new PosRot(this.getX(), this.getY(), this.getZ(), this.getYRot(), this.getXRot(), this.onGround(), this.horizontalCollision)); + this.connection.send(new ServerboundMovePlayerPacket.PosRot(this.position(), this.getYRot(), this.getXRot(), this.onGround(), this.horizontalCollision)); } else if (bl) { - this.connection.send(new Pos(this.getX(), this.getY(), this.getZ(), this.onGround(), this.horizontalCollision)); + this.connection.send(new ServerboundMovePlayerPacket.Pos(this.position(), this.onGround(), this.horizontalCollision)); } else if (bl2) { - this.connection.send(new Rot(this.getYRot(), this.getXRot(), this.onGround(), this.horizontalCollision)); + this.connection.send(new ServerboundMovePlayerPacket.Rot(this.getYRot(), this.getXRot(), this.onGround(), this.horizontalCollision)); } else if (this.lastOnGround != this.onGround() || this.lastHorizontalCollision != this.horizontalCollision) { - this.connection.send(new StatusOnly(this.onGround(), this.horizontalCollision)); + this.connection.send(new ServerboundMovePlayerPacket.StatusOnly(this.onGround(), this.horizontalCollision)); } if (bl) { @@ -445,7 +440,7 @@ public class LocalPlayer extends AbstractClientPlayer { for (Direction direction2 : directions) { double g = direction2.getAxis().choose(d, 0.0, e); - double h = direction2.getAxisDirection() == AxisDirection.POSITIVE ? 1.0 - g : g; + double h = direction2.getAxisDirection() == Direction.AxisDirection.POSITIVE ? 1.0 - g : g; if (h < f && !this.suffocatesAt(blockPos.relative(direction2))) { f = h; direction = direction2; @@ -454,7 +449,7 @@ public class LocalPlayer extends AbstractClientPlayer { if (direction != null) { Vec3 vec3 = this.getDeltaMovement(); - if (direction.getAxis() == Axis.X) { + if (direction.getAxis() == Direction.Axis.X) { this.setDeltaMovement(0.1 * direction.getStepX(), vec3.y, vec3.z); } else { this.setDeltaMovement(vec3.x, vec3.y, 0.1 * direction.getStepZ()); @@ -513,11 +508,6 @@ public class LocalPlayer extends AbstractClientPlayer { this.level().playLocalSound(this.getX(), this.getY(), this.getZ(), sound, source, volume, pitch, false); } - @Override - public boolean isEffectiveAi() { - return true; - } - @Override public void startUsingItem(InteractionHand hand) { ItemStack itemStack = this.getItemInHand(hand); @@ -600,6 +590,16 @@ public class LocalPlayer extends AbstractClientPlayer { this.minecraft.setScreen(new StructureBlockEditScreen(structureEntity)); } + @Override + public void openTestBlock(TestBlockEntity testBlockEntity) { + this.minecraft.setScreen(new TestBlockEditScreen(testBlockEntity)); + } + + @Override + public void openTestInstanceBlock(TestInstanceBlockEntity testInstanceBlockEntity) { + this.minecraft.setScreen(new TestInstanceBlockEditScreen(testInstanceBlockEntity)); + } + @Override public void openJigsawBlock(JigsawBlockEntity jigsawBlockEntity) { this.minecraft.setScreen(new JigsawBlockEditScreen(jigsawBlockEntity)); @@ -638,19 +638,58 @@ public class LocalPlayer extends AbstractClientPlayer { } @Override - public void serverAiStep() { - super.serverAiStep(); + public void applyInput() { if (this.isControlledCamera()) { - this.xxa = this.input.leftImpulse; - this.zza = this.input.forwardImpulse; + Vec2 vec2 = this.modifyInput(this.input.getMoveVector()); + this.xxa = vec2.x; + this.zza = vec2.y; this.jumping = this.input.keyPresses.jump(); this.yBobO = this.yBob; this.xBobO = this.xBob; this.xBob = this.xBob + (this.getXRot() - this.xBob) * 0.5F; this.yBob = this.yBob + (this.getYRot() - this.yBob) * 0.5F; + } else { + super.applyInput(); } } + private Vec2 modifyInput(Vec2 moveVector) { + if (moveVector.lengthSquared() == 0.0F) { + return moveVector; + } else { + Vec2 vec2 = moveVector.scale(0.98F); + if (this.isUsingItem() && !this.isPassenger()) { + vec2 = vec2.scale(0.2F); + } + + if (this.isMovingSlowly()) { + float f = (float)this.getAttributeValue(Attributes.SNEAKING_SPEED); + vec2 = vec2.scale(f); + } + + return modifyInputSpeedForSquareMovement(vec2); + } + } + + private static Vec2 modifyInputSpeedForSquareMovement(Vec2 moveVector) { + float f = moveVector.length(); + if (f <= 0.0F) { + return moveVector; + } else { + Vec2 vec2 = moveVector.scale(1.0F / f); + float g = distanceToUnitSquare(vec2); + float h = Math.min(f * g, 1.0F); + return vec2.scale(h); + } + } + + private static float distanceToUnitSquare(Vec2 moveVector) { + float f = Math.abs(moveVector.x); + float g = Math.abs(moveVector.y); + float h = g > f ? f / g : g / f; + return Mth.sqrt(1.0F + Mth.square(h)); + } + protected boolean isControlledCamera() { return this.minecraft.getCameraEntity() == this; } @@ -680,13 +719,13 @@ public class LocalPlayer extends AbstractClientPlayer { } if (!(this.minecraft.screen instanceof ReceivingLevelScreen)) { - this.handleConfusionTransitionEffect(this.getActivePortalLocalTransition() == Transition.CONFUSION); + this.handlePortalTransitionEffect(this.getActivePortalLocalTransition() == Transition.CONFUSION); this.processPortalCooldown(); } boolean bl = this.input.keyPresses.jump(); boolean bl2 = this.input.keyPresses.shift(); - boolean bl3 = this.hasEnoughImpulseToStartSprinting(); + boolean bl3 = this.input.hasForwardImpulse(); Abilities abilities = this.getAbilities(); this.crouching = !abilities.flying && !this.isSwimming() @@ -695,22 +734,6 @@ public class LocalPlayer extends AbstractClientPlayer { && (this.isShiftKeyDown() || !this.isSleeping() && !this.canPlayerFitWithinBlocksAndEntitiesWhen(Pose.STANDING)); this.input.tick(); this.minecraft.getTutorial().onInput(this.input); - if (this.shouldStopSprinting()) { - this.setSprinting(false); - } - - if (this.isUsingItem() && !this.isPassenger()) { - this.input.leftImpulse *= 0.2F; - this.input.forwardImpulse *= 0.2F; - this.sprintTriggerTime = 0; - } - - if (this.isMovingSlowly()) { - float f = (float)this.getAttributeValue(Attributes.SNEAKING_SPEED); - this.input.leftImpulse *= f; - this.input.forwardImpulse *= f; - } - boolean bl4 = false; if (this.autoJumpTime > 0) { this.autoJumpTime--; @@ -725,43 +748,40 @@ public class LocalPlayer extends AbstractClientPlayer { this.moveTowardsClosestSpace(this.getX() + this.getBbWidth() * 0.35, this.getZ() + this.getBbWidth() * 0.35); } - if (bl2) { + if (bl2 || this.isUsingItem() && !this.isPassenger() || this.input.keyPresses.backward()) { this.sprintTriggerTime = 0; } - boolean bl5 = this.canStartSprinting(); - boolean bl6 = this.isPassenger() ? this.getVehicle().onGround() : this.onGround(); - boolean bl7 = !bl2 && !bl3; - if ((bl6 || this.isUnderWater()) && bl7 && bl5) { - if (this.sprintTriggerTime <= 0 && !this.minecraft.options.keySprint.isDown()) { - this.sprintTriggerTime = 7; - } else { + if (this.canStartSprinting()) { + if (!bl3) { + if (this.sprintTriggerTime > 0) { + this.setSprinting(true); + } else { + this.sprintTriggerTime = 7; + } + } + + if (this.input.keyPresses.sprint()) { this.setSprinting(true); } } - if ((!this.isInWater() || this.isUnderWater()) && bl5 && this.minecraft.options.keySprint.isDown()) { - this.setSprinting(true); - } - if (this.isSprinting()) { - boolean bl8 = !this.input.hasForwardImpulse() || !this.hasEnoughFoodToStartSprinting(); - boolean bl9 = bl8 || this.horizontalCollision && !this.minorHorizontalCollision || this.isInWater() && !this.isUnderWater(); if (this.isSwimming()) { - if (!this.onGround() && !this.input.keyPresses.shift() && bl8 || !this.isInWater()) { + if (this.shouldStopSwimSprinting()) { this.setSprinting(false); } - } else if (bl9) { + } else if (this.shouldStopRunSprinting()) { this.setSprinting(false); } } - boolean bl8 = false; + boolean bl5 = false; if (abilities.mayfly) { if (this.minecraft.gameMode.isAlwaysFlying()) { if (!abilities.flying) { abilities.flying = true; - bl8 = true; + bl5 = true; this.onUpdateAbilities(); } } else if (!bl && this.input.keyPresses.jump() && !bl4) { @@ -773,14 +793,14 @@ public class LocalPlayer extends AbstractClientPlayer { this.jumpFromGround(); } - bl8 = true; + bl5 = true; this.onUpdateAbilities(); this.jumpTriggerTime = 0; } } } - if (this.input.keyPresses.jump() && !bl8 && !bl && !this.onClimbable() && this.tryToStartFallFlying()) { + if (this.input.keyPresses.jump() && !bl5 && !bl && !this.onClimbable() && this.tryToStartFallFlying()) { this.connection.send(new ServerboundPlayerCommandPacket(this, Action.START_FALL_FLYING)); } @@ -847,16 +867,21 @@ public class LocalPlayer extends AbstractClientPlayer { } } - private boolean shouldStopSprinting() { - return this.isFallFlying() - || this.hasBlindness() - || this.isMovingSlowly() - || this.isPassenger() && !this.isRidingCamel() - || this.isUsingItem() && !this.isPassenger() && !this.isUnderWater(); + private boolean shouldStopRunSprinting() { + return this.hasBlindness() + || this.isPassenger() && !this.vehicleCanSprint(this.getVehicle()) + || !this.input.hasForwardImpulse() + || !this.hasEnoughFoodToSprint() + || this.horizontalCollision && !this.minorHorizontalCollision + || this.isInWater() && !this.isUnderWater(); } - private boolean isRidingCamel() { - return this.getVehicle() != null && this.getVehicle().getType() == EntityType.CAMEL; + private boolean shouldStopSwimSprinting() { + return this.hasBlindness() + || this.isPassenger() && !this.vehicleCanSprint(this.getVehicle()) + || !this.isInWater() + || !this.input.hasForwardImpulse() && !this.onGround() && !this.input.keyPresses.shift() + || !this.hasEnoughFoodToSprint(); } private boolean hasBlindness() { @@ -875,10 +900,10 @@ public class LocalPlayer extends AbstractClientPlayer { } } - private void handleConfusionTransitionEffect(boolean useConfusion) { - this.oSpinningEffectIntensity = this.spinningEffectIntensity; + private void handlePortalTransitionEffect(boolean inPortal) { + this.oPortalEffectIntensity = this.portalEffectIntensity; float f = 0.0F; - if (useConfusion && this.portalProcess != null && this.portalProcess.isInsidePortalThisTick()) { + if (inPortal && this.portalProcess != null && this.portalProcess.isInsidePortalThisTick()) { if (this.minecraft.screen != null && !this.minecraft.screen.isPauseScreen() && !(this.minecraft.screen instanceof DeathScreen) @@ -890,19 +915,17 @@ public class LocalPlayer extends AbstractClientPlayer { this.minecraft.setScreen(null); } - if (this.spinningEffectIntensity == 0.0F) { + if (this.portalEffectIntensity == 0.0F) { this.minecraft.getSoundManager().play(SimpleSoundInstance.forLocalAmbience(SoundEvents.PORTAL_TRIGGER, this.random.nextFloat() * 0.4F + 0.8F, 0.25F)); } f = 0.0125F; this.portalProcess.setAsInsidePortalThisTick(false); - } else if (this.hasEffect(MobEffects.CONFUSION) && !this.getEffect(MobEffects.CONFUSION).endsWithin(60)) { - f = 0.006666667F; - } else if (this.spinningEffectIntensity > 0.0F) { + } else if (this.portalEffectIntensity > 0.0F) { f = -0.05F; } - this.spinningEffectIntensity = Mth.clamp(this.spinningEffectIntensity + f, 0.0F, 1.0F); + this.portalEffectIntensity = Mth.clamp(this.portalEffectIntensity + f, 0.0F, 1.0F); } @Override @@ -920,17 +943,6 @@ public class LocalPlayer extends AbstractClientPlayer { return this.handsBusy; } - @Nullable - @Override - public MobEffectInstance removeEffectNoUpdate(Holder effect) { - if (effect.is(MobEffects.CONFUSION)) { - this.oSpinningEffectIntensity = 0.0F; - this.spinningEffectIntensity = 0.0F; - } - - return super.removeEffectNoUpdate(effect); - } - @Override public void move(MoverType type, Vec3 movement) { double d = this.getX(); @@ -985,8 +997,8 @@ public class LocalPlayer extends AbstractClientPlayer { if (blockState2.getCollisionShape(this.level(), blockPos, collisionContext).isEmpty()) { float m = 7.0F; float n = 1.2F; - if (this.hasEffect(MobEffects.JUMP)) { - n += (this.getEffect(MobEffects.JUMP).getAmplifier() + 1) * 0.75F; + if (this.hasEffect(MobEffects.JUMP_BOOST)) { + n += (this.getEffect(MobEffects.JUMP_BOOST).getAmplifier() + 1) * 0.75F; } float o = Math.max(f * 7.0F, 1.0F / l); @@ -1018,7 +1030,7 @@ public class LocalPlayer extends AbstractClientPlayer { BlockState blockState3 = this.level().getBlockState(blockPos3); VoxelShape voxelShape; if (!(voxelShape = blockState3.getCollisionShape(this.level(), blockPos3, collisionContext)).isEmpty()) { - r = (float)voxelShape.max(Axis.Y) + blockPos3.getY(); + r = (float)voxelShape.max(Direction.Axis.Y) + blockPos3.getY(); if (r - this.getY() > n) { return; } @@ -1077,31 +1089,26 @@ public class LocalPlayer extends AbstractClientPlayer { } private boolean isMoving() { - Vec2 vec2 = this.input.getMoveVector(); - return vec2.x != 0.0F || vec2.y != 0.0F; + return this.input.getMoveVector().lengthSquared() > 0.0F; } private boolean canStartSprinting() { return !this.isSprinting() - && this.hasEnoughImpulseToStartSprinting() - && this.hasEnoughFoodToStartSprinting() + && this.input.hasForwardImpulse() + && this.hasEnoughFoodToSprint() && !this.isUsingItem() && !this.hasBlindness() && (!this.isPassenger() || this.vehicleCanSprint(this.getVehicle())) - && !this.isFallFlying() - && (!this.isMovingSlowly() || this.isUnderWater()); + && (!this.isFallFlying() || this.isUnderWater()) + && (!this.isMovingSlowly() || this.isUnderWater()) + && (!this.isInWater() || this.isUnderWater()); } private boolean vehicleCanSprint(Entity vehicle) { - return vehicle.canSprint() && vehicle.isControlledByLocalInstance(); + return vehicle.canSprint() && vehicle.isLocalInstanceAuthoritative(); } - private boolean hasEnoughImpulseToStartSprinting() { - double d = 0.8; - return this.isUnderWater() ? this.input.hasForwardImpulse() : this.input.forwardImpulse >= 0.8; - } - - private boolean hasEnoughFoodToStartSprinting() { + private boolean hasEnoughFoodToSprint() { return this.isPassenger() || this.getFoodData().getFoodLevel() > 6.0F || this.getAbilities().mayfly; } @@ -1123,7 +1130,7 @@ public class LocalPlayer extends AbstractClientPlayer { public void onGameModeChanged(GameType gameMode) { if (gameMode == GameType.SPECTATOR) { - this.setDeltaMovement(this.getDeltaMovement().with(Axis.Y, 0.0)); + this.setDeltaMovement(this.getDeltaMovement().with(Direction.Axis.Y, 0.0)); } } diff --git a/net/minecraft/client/player/RemotePlayer.java b/net/minecraft/client/player/RemotePlayer.java index bdda1ab9..8a29cd7f 100644 --- a/net/minecraft/client/player/RemotePlayer.java +++ b/net/minecraft/client/player/RemotePlayer.java @@ -44,9 +44,8 @@ public class RemotePlayer extends AbstractClientPlayer { @Override public void aiStep() { - if (this.lerpSteps > 0) { - this.lerpPositionAndRotationStep(this.lerpSteps, this.lerpX, this.lerpY, this.lerpZ, this.lerpYRot, this.lerpXRot); - this.lerpSteps--; + if (this.isInterpolating()) { + this.getInterpolation().interpolate(); } if (this.lerpHeadSteps > 0) { diff --git a/net/minecraft/client/renderer/BiomeColors.java b/net/minecraft/client/renderer/BiomeColors.java index 51a9d7a1..7c655a77 100644 --- a/net/minecraft/client/renderer/BiomeColors.java +++ b/net/minecraft/client/renderer/BiomeColors.java @@ -11,6 +11,7 @@ import net.minecraft.world.level.biome.Biome; public class BiomeColors { public static final ColorResolver GRASS_COLOR_RESOLVER = Biome::getGrassColor; public static final ColorResolver FOLIAGE_COLOR_RESOLVER = (biome, d, e) -> biome.getFoliageColor(); + public static final ColorResolver DRY_FOLIAGE_COLOR_RESOLVER = (biome, d, e) -> biome.getDryFoliageColor(); public static final ColorResolver WATER_COLOR_RESOLVER = (biome, d, e) -> biome.getWaterColor(); private static int getAverageColor(BlockAndTintGetter level, BlockPos blockPos, ColorResolver colorResolver) { @@ -25,6 +26,10 @@ public class BiomeColors { return getAverageColor(level, blockPos, FOLIAGE_COLOR_RESOLVER); } + public static int getAverageDryFoliageColor(BlockAndTintGetter level, BlockPos blockPos) { + return getAverageColor(level, blockPos, DRY_FOLIAGE_COLOR_RESOLVER); + } + public static int getAverageWaterColor(BlockAndTintGetter level, BlockPos blockPos) { return getAverageColor(level, blockPos, WATER_COLOR_RESOLVER); } diff --git a/net/minecraft/client/renderer/CloudRenderer.java b/net/minecraft/client/renderer/CloudRenderer.java index 3223d885..2aed2bdd 100644 --- a/net/minecraft/client/renderer/CloudRenderer.java +++ b/net/minecraft/client/renderer/CloudRenderer.java @@ -1,19 +1,29 @@ package net.minecraft.client.renderer; +import com.mojang.blaze3d.buffers.BufferType; import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.platform.NativeImage; +import com.mojang.blaze3d.systems.CommandEncoder; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.blaze3d.vertex.BufferBuilder; import com.mojang.blaze3d.vertex.MeshData; import com.mojang.blaze3d.vertex.Tesselator; -import com.mojang.blaze3d.vertex.VertexBuffer; +import com.mojang.blaze3d.vertex.VertexFormat; import com.mojang.logging.LogUtils; import java.io.IOException; import java.io.InputStream; import java.util.Optional; +import java.util.OptionalDouble; +import java.util.OptionalInt; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.CloudStatus; +import net.minecraft.client.Minecraft; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.server.packs.resources.SimplePreparableReloadListener; @@ -22,7 +32,6 @@ import net.minecraft.util.Mth; import net.minecraft.util.profiling.ProfilerFiller; import net.minecraft.world.phys.Vec3; import org.jetbrains.annotations.Nullable; -import org.joml.Matrix4f; import org.slf4j.Logger; @Environment(EnvType.CLIENT) @@ -46,8 +55,10 @@ public class CloudRenderer extends SimplePreparableReloadListener prepare(ResourceManager resourceManager, ProfilerFiller profilerFiller) { try { @@ -131,9 +142,9 @@ public class CloudRenderer extends SimplePreparableReloadListener> 0 & 1L) != 0L; } - public void render(int height, CloudStatus cloudStatus, float color, Matrix4f frustumMatrix, Matrix4f projectionMatrix, Vec3 cameraPosiiton, float ticks) { + public void render(int cloudColor, CloudStatus cloudStatus, float height, Vec3 cameraPosition, float ticks) { if (this.texture != null) { - float f = (float)(color - cameraPosiiton.y); + float f = (float)(height - cameraPosition.y); float g = f + 4.0F; CloudRenderer.RelativeCameraPos relativeCameraPos; if (g < 0.0F) { @@ -144,8 +155,8 @@ public class CloudRenderer extends SimplePreparableReloadListener= meshData.vertexBuffer().remaining()) { + CommandEncoder commandEncoder = RenderSystem.getDevice().createCommandEncoder(); + commandEncoder.writeToBuffer(this.vertexBuffer, meshData.vertexBuffer(), 0); + } else { + if (this.vertexBuffer != null) { + this.vertexBuffer.close(); + } + + this.vertexBuffer = RenderSystem.getDevice() + .createBuffer(() -> "Cloud vertex buffer", BufferType.VERTICES, BufferUsage.DYNAMIC_WRITE, meshData.vertexBuffer()); + } + + this.indexCount = meshData.drawState().indexCount(); + } } } - if (!this.vertexBufferEmpty) { - RenderSystem.setShaderColor(ARGB.redFloat(height), ARGB.greenFloat(height), ARGB.blueFloat(height), 1.0F); - if (cloudStatus == CloudStatus.FANCY) { - this.drawWithRenderType(RenderType.cloudsDepthOnly(), frustumMatrix, projectionMatrix, l, f, m); + if (this.indexCount != 0) { + RenderSystem.setShaderColor(ARGB.redFloat(cloudColor), ARGB.greenFloat(cloudColor), ARGB.blueFloat(cloudColor), 1.0F); + if (bl) { + this.draw(RenderPipelines.CLOUDS_DEPTH_ONLY, l, f, m); } - this.drawWithRenderType(renderType, frustumMatrix, projectionMatrix, l, f, m); - VertexBuffer.unbind(); + this.draw(renderPipeline, l, f, m); RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); } } } - private void drawWithRenderType(RenderType renderType, Matrix4f frustumMatrix, Matrix4f projectionMatrix, float x, float y, float z) { - renderType.setupRenderState(); - CompiledShaderProgram compiledShaderProgram = RenderSystem.getShader(); - if (compiledShaderProgram != null && compiledShaderProgram.MODEL_OFFSET != null) { - compiledShaderProgram.MODEL_OFFSET.set(-x, y, -z); + private void draw(RenderPipeline pipeline, float x, float y, float z) { + RenderSystem.setModelOffset(-x, y, -z); + RenderTarget renderTarget = Minecraft.getInstance().getMainRenderTarget(); + RenderTarget renderTarget2 = Minecraft.getInstance().levelRenderer.getCloudsTarget(); + GpuTexture gpuTexture; + GpuTexture gpuTexture2; + if (renderTarget2 != null) { + gpuTexture = renderTarget2.getColorTexture(); + gpuTexture2 = renderTarget2.getDepthTexture(); + } else { + gpuTexture = renderTarget.getColorTexture(); + gpuTexture2 = renderTarget.getDepthTexture(); } - this.vertexBuffer.drawWithShader(frustumMatrix, projectionMatrix, compiledShaderProgram); - renderType.clearRenderState(); + GpuBuffer gpuBuffer = this.indices.getBuffer(this.indexCount); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass(gpuTexture, OptionalInt.empty(), gpuTexture2, OptionalDouble.empty())) { + renderPass.setPipeline(pipeline); + renderPass.setIndexBuffer(gpuBuffer, this.indices.type()); + renderPass.setVertexBuffer(0, this.vertexBuffer); + renderPass.drawIndexed(0, this.indexCount); + } + + RenderSystem.resetModelOffset(); } @Nullable private MeshData buildMesh( - Tesselator tesselator, int cellX, int cellZ, CloudStatus cloudStatus, CloudRenderer.RelativeCameraPos relativeCameraPos, RenderType renderType + Tesselator tesselator, int cellX, int cellY, CloudStatus cloudStatus, CloudRenderer.RelativeCameraPos relativeCameraPos, RenderPipeline pipeline ) { float f = 0.8F; int i = ARGB.colorFromFloat(0.8F, 1.0F, 1.0F, 1.0F); int j = ARGB.colorFromFloat(0.8F, 0.9F, 0.9F, 0.9F); int k = ARGB.colorFromFloat(0.8F, 0.7F, 0.7F, 0.7F); int l = ARGB.colorFromFloat(0.8F, 0.8F, 0.8F, 0.8F); - BufferBuilder bufferBuilder = tesselator.begin(renderType.mode(), renderType.format()); - this.buildMesh(relativeCameraPos, bufferBuilder, cellX, cellZ, k, i, j, l, cloudStatus == CloudStatus.FANCY); + BufferBuilder bufferBuilder = tesselator.begin(pipeline.getVertexFormatMode(), pipeline.getVertexFormat()); + this.buildMesh(relativeCameraPos, bufferBuilder, cellX, cellY, k, i, j, l, cloudStatus == CloudStatus.FANCY); return bufferBuilder.build(); } @@ -358,7 +398,9 @@ public class CloudRenderer extends SimplePreparableReloadListener samplers = new ArrayList(); - private final Object2IntMap samplerTextures = new Object2IntArrayMap<>(); - private final IntList samplerLocations = new IntArrayList(); - private final List uniforms = new ArrayList(); - private final Map uniformsByName = new HashMap(); - private final Map uniformConfigs = new HashMap(); - private final int programId; - @Nullable - public com.mojang.blaze3d.shaders.Uniform MODEL_VIEW_MATRIX; - @Nullable - public com.mojang.blaze3d.shaders.Uniform PROJECTION_MATRIX; - @Nullable - public com.mojang.blaze3d.shaders.Uniform TEXTURE_MATRIX; - @Nullable - public com.mojang.blaze3d.shaders.Uniform SCREEN_SIZE; - @Nullable - public com.mojang.blaze3d.shaders.Uniform COLOR_MODULATOR; - @Nullable - public com.mojang.blaze3d.shaders.Uniform LIGHT0_DIRECTION; - @Nullable - public com.mojang.blaze3d.shaders.Uniform LIGHT1_DIRECTION; - @Nullable - public com.mojang.blaze3d.shaders.Uniform GLINT_ALPHA; - @Nullable - public com.mojang.blaze3d.shaders.Uniform FOG_START; - @Nullable - public com.mojang.blaze3d.shaders.Uniform FOG_END; - @Nullable - public com.mojang.blaze3d.shaders.Uniform FOG_COLOR; - @Nullable - public com.mojang.blaze3d.shaders.Uniform FOG_SHAPE; - @Nullable - public com.mojang.blaze3d.shaders.Uniform LINE_WIDTH; - @Nullable - public com.mojang.blaze3d.shaders.Uniform GAME_TIME; - @Nullable - public com.mojang.blaze3d.shaders.Uniform MODEL_OFFSET; - - private CompiledShaderProgram(int programId) { - this.programId = programId; - this.samplerTextures.defaultReturnValue(-1); - } - - public static CompiledShaderProgram link(CompiledShader vertexShader, CompiledShader fragmentShader, VertexFormat vertexFormat) throws ShaderManager.CompilationException { - int i = GlStateManager.glCreateProgram(); - if (i <= 0) { - throw new ShaderManager.CompilationException("Could not create shader program (returned program ID " + i + ")"); - } else { - vertexFormat.bindAttributes(i); - GlStateManager.glAttachShader(i, vertexShader.getShaderId()); - GlStateManager.glAttachShader(i, fragmentShader.getShaderId()); - GlStateManager.glLinkProgram(i); - int j = GlStateManager.glGetProgrami(i, 35714); - if (j == 0) { - String string = GlStateManager.glGetProgramInfoLog(i, 32768); - throw new ShaderManager.CompilationException( - "Error encountered when linking program containing VS " + vertexShader.getId() + " and FS " + fragmentShader.getId() + ". Log output: " + string - ); - } else { - return new CompiledShaderProgram(i); - } - } - } - - public void setupUniforms(List uniforms, List samplers) { - RenderSystem.assertOnRenderThread(); - - for (Uniform uniform : uniforms) { - String string = uniform.name(); - int i = com.mojang.blaze3d.shaders.Uniform.glGetUniformLocation(this.programId, string); - if (i != -1) { - com.mojang.blaze3d.shaders.Uniform uniform2 = this.parseUniformNode(uniform); - uniform2.setLocation(i); - this.uniforms.add(uniform2); - this.uniformsByName.put(string, uniform2); - this.uniformConfigs.put(string, uniform); - } - } - - for (Sampler sampler : samplers) { - int j = com.mojang.blaze3d.shaders.Uniform.glGetUniformLocation(this.programId, sampler.name()); - if (j != -1) { - this.samplers.add(sampler); - this.samplerLocations.add(j); - } - } - - this.MODEL_VIEW_MATRIX = this.getUniform("ModelViewMat"); - this.PROJECTION_MATRIX = this.getUniform("ProjMat"); - this.TEXTURE_MATRIX = this.getUniform("TextureMat"); - this.SCREEN_SIZE = this.getUniform("ScreenSize"); - this.COLOR_MODULATOR = this.getUniform("ColorModulator"); - this.LIGHT0_DIRECTION = this.getUniform("Light0_Direction"); - this.LIGHT1_DIRECTION = this.getUniform("Light1_Direction"); - this.GLINT_ALPHA = this.getUniform("GlintAlpha"); - this.FOG_START = this.getUniform("FogStart"); - this.FOG_END = this.getUniform("FogEnd"); - this.FOG_COLOR = this.getUniform("FogColor"); - this.FOG_SHAPE = this.getUniform("FogShape"); - this.LINE_WIDTH = this.getUniform("LineWidth"); - this.GAME_TIME = this.getUniform("GameTime"); - this.MODEL_OFFSET = this.getUniform("ModelOffset"); - } - - public void close() { - this.uniforms.forEach(com.mojang.blaze3d.shaders.Uniform::close); - GlStateManager.glDeleteProgram(this.programId); - } - - public void clear() { - RenderSystem.assertOnRenderThread(); - GlStateManager._glUseProgram(0); - int i = GlStateManager._getActiveTexture(); - - for (int j = 0; j < this.samplerLocations.size(); j++) { - Sampler sampler = (Sampler)this.samplers.get(j); - if (!this.samplerTextures.containsKey(sampler.name())) { - GlStateManager._activeTexture(33984 + j); - GlStateManager._bindTexture(0); - } - } - - GlStateManager._activeTexture(i); - } - - public void apply() { - RenderSystem.assertOnRenderThread(); - GlStateManager._glUseProgram(this.programId); - int i = GlStateManager._getActiveTexture(); - - for (int j = 0; j < this.samplerLocations.size(); j++) { - String string = ((Sampler)this.samplers.get(j)).name(); - int k = this.samplerTextures.getInt(string); - if (k != -1) { - int l = this.samplerLocations.getInt(j); - com.mojang.blaze3d.shaders.Uniform.uploadInteger(l, j); - RenderSystem.activeTexture(33984 + j); - RenderSystem.bindTexture(k); - } - } - - GlStateManager._activeTexture(i); - - for (com.mojang.blaze3d.shaders.Uniform uniform : this.uniforms) { - uniform.upload(); - } - } - - @Nullable - public com.mojang.blaze3d.shaders.Uniform getUniform(String name) { - RenderSystem.assertOnRenderThread(); - return (com.mojang.blaze3d.shaders.Uniform)this.uniformsByName.get(name); - } - - @Nullable - public Uniform getUniformConfig(String name) { - return (Uniform)this.uniformConfigs.get(name); - } - - public AbstractUniform safeGetUniform(String name) { - com.mojang.blaze3d.shaders.Uniform uniform = this.getUniform(name); - return (AbstractUniform)(uniform == null ? DUMMY_UNIFORM : uniform); - } - - public void bindSampler(String samplerName, int textureId) { - this.samplerTextures.put(samplerName, textureId); - } - - private com.mojang.blaze3d.shaders.Uniform parseUniformNode(Uniform uniform) { - int i = com.mojang.blaze3d.shaders.Uniform.getTypeFromString(uniform.type()); - int j = uniform.count(); - int k = j > 1 && j <= 4 && i < 8 ? j - 1 : 0; - com.mojang.blaze3d.shaders.Uniform uniform2 = new com.mojang.blaze3d.shaders.Uniform(uniform.name(), i + k, j); - uniform2.setFromConfig(uniform); - return uniform2; - } - - public void setDefaultUniforms(VertexFormat.Mode mode, Matrix4f frustumMatrix, Matrix4f projectionMatrix, Window window) { - for (int i = 0; i < 12; i++) { - int j = RenderSystem.getShaderTexture(i); - this.bindSampler("Sampler" + i, j); - } - - if (this.MODEL_VIEW_MATRIX != null) { - this.MODEL_VIEW_MATRIX.set(frustumMatrix); - } - - if (this.PROJECTION_MATRIX != null) { - this.PROJECTION_MATRIX.set(projectionMatrix); - } - - if (this.COLOR_MODULATOR != null) { - this.COLOR_MODULATOR.set(RenderSystem.getShaderColor()); - } - - if (this.GLINT_ALPHA != null) { - this.GLINT_ALPHA.set(RenderSystem.getShaderGlintAlpha()); - } - - FogParameters fogParameters = RenderSystem.getShaderFog(); - if (this.FOG_START != null) { - this.FOG_START.set(fogParameters.start()); - } - - if (this.FOG_END != null) { - this.FOG_END.set(fogParameters.end()); - } - - if (this.FOG_COLOR != null) { - this.FOG_COLOR.set(fogParameters.red(), fogParameters.green(), fogParameters.blue(), fogParameters.alpha()); - } - - if (this.FOG_SHAPE != null) { - this.FOG_SHAPE.set(fogParameters.shape().getIndex()); - } - - if (this.TEXTURE_MATRIX != null) { - this.TEXTURE_MATRIX.set(RenderSystem.getTextureMatrix()); - } - - if (this.GAME_TIME != null) { - this.GAME_TIME.set(RenderSystem.getShaderGameTime()); - } - - if (this.SCREEN_SIZE != null) { - this.SCREEN_SIZE.set((float)window.getWidth(), (float)window.getHeight()); - } - - if (this.LINE_WIDTH != null && (mode == VertexFormat.Mode.LINES || mode == VertexFormat.Mode.LINE_STRIP)) { - this.LINE_WIDTH.set(RenderSystem.getShaderLineWidth()); - } - - RenderSystem.setupShaderLights(this); - } - - @VisibleForTesting - public void registerUniform(com.mojang.blaze3d.shaders.Uniform uniform) { - this.uniforms.add(uniform); - this.uniformsByName.put(uniform.getName(), uniform); - } - - @VisibleForTesting - public int getProgramId() { - return this.programId; - } -} diff --git a/net/minecraft/client/renderer/CoreShaders.java b/net/minecraft/client/renderer/CoreShaders.java deleted file mode 100644 index 73f1a07c..00000000 --- a/net/minecraft/client/renderer/CoreShaders.java +++ /dev/null @@ -1,90 +0,0 @@ -package net.minecraft.client.renderer; - -import com.mojang.blaze3d.vertex.DefaultVertexFormat; -import com.mojang.blaze3d.vertex.VertexFormat; -import java.util.ArrayList; -import java.util.List; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.resources.ResourceLocation; - -@Environment(EnvType.CLIENT) -public class CoreShaders { - private static final List PROGRAMS = new ArrayList(); - public static final ShaderProgram BLIT_SCREEN = register("blit_screen", DefaultVertexFormat.BLIT_SCREEN); - public static final ShaderProgram LIGHTMAP = register("lightmap", DefaultVertexFormat.BLIT_SCREEN); - public static final ShaderProgram PARTICLE = register("particle", DefaultVertexFormat.PARTICLE); - public static final ShaderProgram POSITION = register("position", DefaultVertexFormat.POSITION); - public static final ShaderProgram POSITION_COLOR = register("position_color", DefaultVertexFormat.POSITION_COLOR); - public static final ShaderProgram POSITION_COLOR_LIGHTMAP = register("position_color_lightmap", DefaultVertexFormat.POSITION_COLOR_LIGHTMAP); - public static final ShaderProgram POSITION_COLOR_TEX_LIGHTMAP = register("position_color_tex_lightmap", DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP); - public static final ShaderProgram POSITION_TEX = register("position_tex", DefaultVertexFormat.POSITION_TEX); - public static final ShaderProgram POSITION_TEX_COLOR = register("position_tex_color", DefaultVertexFormat.POSITION_TEX_COLOR); - public static final ShaderProgram RENDERTYPE_SOLID = register("rendertype_solid", DefaultVertexFormat.BLOCK); - public static final ShaderProgram RENDERTYPE_CUTOUT_MIPPED = register("rendertype_cutout_mipped", DefaultVertexFormat.BLOCK); - public static final ShaderProgram RENDERTYPE_CUTOUT = register("rendertype_cutout", DefaultVertexFormat.BLOCK); - public static final ShaderProgram RENDERTYPE_TRANSLUCENT = register("rendertype_translucent", DefaultVertexFormat.BLOCK); - public static final ShaderProgram RENDERTYPE_TRANSLUCENT_MOVING_BLOCK = register("rendertype_translucent_moving_block", DefaultVertexFormat.BLOCK); - public static final ShaderProgram RENDERTYPE_ARMOR_CUTOUT_NO_CULL = register("rendertype_armor_cutout_no_cull", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ARMOR_TRANSLUCENT = register("rendertype_armor_translucent", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_SOLID = register("rendertype_entity_solid", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_CUTOUT = register("rendertype_entity_cutout", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_CUTOUT_NO_CULL = register("rendertype_entity_cutout_no_cull", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_CUTOUT_NO_CULL_Z_OFFSET = register( - "rendertype_entity_cutout_no_cull_z_offset", DefaultVertexFormat.NEW_ENTITY - ); - public static final ShaderProgram RENDERTYPE_ITEM_ENTITY_TRANSLUCENT_CULL = register("rendertype_item_entity_translucent_cull", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_TRANSLUCENT = register("rendertype_entity_translucent", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_TRANSLUCENT_EMISSIVE = register("rendertype_entity_translucent_emissive", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_SMOOTH_CUTOUT = register("rendertype_entity_smooth_cutout", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_BEACON_BEAM = register("rendertype_beacon_beam", DefaultVertexFormat.BLOCK); - public static final ShaderProgram RENDERTYPE_ENTITY_DECAL = register("rendertype_entity_decal", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_NO_OUTLINE = register("rendertype_entity_no_outline", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_SHADOW = register("rendertype_entity_shadow", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENTITY_ALPHA = register("rendertype_entity_alpha", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_EYES = register("rendertype_eyes", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_ENERGY_SWIRL = register("rendertype_energy_swirl", DefaultVertexFormat.NEW_ENTITY); - public static final ShaderProgram RENDERTYPE_LEASH = register("rendertype_leash", DefaultVertexFormat.POSITION_COLOR_LIGHTMAP); - public static final ShaderProgram RENDERTYPE_WATER_MASK = register("rendertype_water_mask", DefaultVertexFormat.POSITION); - public static final ShaderProgram RENDERTYPE_OUTLINE = register("rendertype_outline", DefaultVertexFormat.POSITION_TEX_COLOR); - public static final ShaderProgram RENDERTYPE_ARMOR_ENTITY_GLINT = register("rendertype_armor_entity_glint", DefaultVertexFormat.POSITION_TEX); - public static final ShaderProgram RENDERTYPE_GLINT_TRANSLUCENT = register("rendertype_glint_translucent", DefaultVertexFormat.POSITION_TEX); - public static final ShaderProgram RENDERTYPE_GLINT = register("rendertype_glint", DefaultVertexFormat.POSITION_TEX); - public static final ShaderProgram RENDERTYPE_ENTITY_GLINT = register("rendertype_entity_glint", DefaultVertexFormat.POSITION_TEX); - public static final ShaderProgram RENDERTYPE_TEXT = register("rendertype_text", DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP); - public static final ShaderProgram RENDERTYPE_TEXT_BACKGROUND = register("rendertype_text_background", DefaultVertexFormat.POSITION_COLOR_LIGHTMAP); - public static final ShaderProgram RENDERTYPE_TEXT_INTENSITY = register("rendertype_text_intensity", DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP); - public static final ShaderProgram RENDERTYPE_TEXT_SEE_THROUGH = register("rendertype_text_see_through", DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP); - public static final ShaderProgram RENDERTYPE_TEXT_BACKGROUND_SEE_THROUGH = register( - "rendertype_text_background_see_through", DefaultVertexFormat.POSITION_COLOR_LIGHTMAP - ); - public static final ShaderProgram RENDERTYPE_TEXT_INTENSITY_SEE_THROUGH = register( - "rendertype_text_intensity_see_through", DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP - ); - public static final ShaderProgram RENDERTYPE_LIGHTNING = register("rendertype_lightning", DefaultVertexFormat.POSITION_COLOR); - public static final ShaderProgram RENDERTYPE_TRIPWIRE = register("rendertype_tripwire", DefaultVertexFormat.BLOCK); - public static final ShaderProgram RENDERTYPE_END_PORTAL = register("rendertype_end_portal", DefaultVertexFormat.POSITION); - public static final ShaderProgram RENDERTYPE_END_GATEWAY = register("rendertype_end_gateway", DefaultVertexFormat.POSITION); - public static final ShaderProgram RENDERTYPE_CLOUDS = register("rendertype_clouds", DefaultVertexFormat.POSITION_COLOR); - public static final ShaderProgram RENDERTYPE_LINES = register("rendertype_lines", DefaultVertexFormat.POSITION_COLOR_NORMAL); - public static final ShaderProgram RENDERTYPE_CRUMBLING = register("rendertype_crumbling", DefaultVertexFormat.BLOCK); - public static final ShaderProgram RENDERTYPE_GUI = register("rendertype_gui", DefaultVertexFormat.POSITION_COLOR); - public static final ShaderProgram RENDERTYPE_GUI_OVERLAY = register("rendertype_gui_overlay", DefaultVertexFormat.POSITION_COLOR); - public static final ShaderProgram RENDERTYPE_GUI_TEXT_HIGHLIGHT = register("rendertype_gui_text_highlight", DefaultVertexFormat.POSITION_COLOR); - public static final ShaderProgram RENDERTYPE_GUI_GHOST_RECIPE_OVERLAY = register("rendertype_gui_ghost_recipe_overlay", DefaultVertexFormat.POSITION_COLOR); - public static final ShaderProgram RENDERTYPE_BREEZE_WIND = register("rendertype_breeze_wind", DefaultVertexFormat.NEW_ENTITY); - - private static ShaderProgram register(String name, VertexFormat vertexFormat) { - return register(name, vertexFormat, ShaderDefines.EMPTY); - } - - private static ShaderProgram register(String name, VertexFormat vertexFormat, ShaderDefines defines) { - ShaderProgram shaderProgram = new ShaderProgram(ResourceLocation.withDefaultNamespace("core/" + name), vertexFormat, defines); - PROGRAMS.add(shaderProgram); - return shaderProgram; - } - - public static List getProgramsToPreload() { - return PROGRAMS; - } -} diff --git a/net/minecraft/client/renderer/CubeMap.java b/net/minecraft/client/renderer/CubeMap.java index 1a532605..7fbb2536 100644 --- a/net/minecraft/client/renderer/CubeMap.java +++ b/net/minecraft/client/renderer/CubeMap.java @@ -1,25 +1,38 @@ package net.minecraft.client.renderer; import com.mojang.blaze3d.ProjectionType; +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.pipeline.RenderTarget; +import com.mojang.blaze3d.systems.CommandEncoder; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.blaze3d.vertex.BufferBuilder; -import com.mojang.blaze3d.vertex.BufferUploader; +import com.mojang.blaze3d.vertex.ByteBufferBuilder; import com.mojang.blaze3d.vertex.DefaultVertexFormat; -import com.mojang.blaze3d.vertex.Tesselator; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; +import com.mojang.blaze3d.vertex.MeshData; +import com.mojang.blaze3d.vertex.VertexFormat; import java.util.List; +import java.util.OptionalDouble; +import java.util.OptionalInt; import java.util.stream.IntStream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.texture.TextureManager; import net.minecraft.resources.ResourceLocation; +import org.jetbrains.annotations.Nullable; import org.joml.Matrix4f; import org.joml.Matrix4fStack; @Environment(EnvType.CLIENT) public class CubeMap { private static final int SIDES = 6; + @Nullable + private GpuBuffer cubeMapBuffer = null; private final List sides; public CubeMap(ResourceLocation baseImageLocation) { @@ -27,87 +40,91 @@ public class CubeMap { } public void render(Minecraft mc, float pitch, float yaw, float alpha) { - Tesselator tesselator = Tesselator.getInstance(); + if (this.cubeMapBuffer == null) { + this.initializeVertices(); + } + Matrix4f matrix4f = new Matrix4f().setPerspective(1.4835298F, (float)mc.getWindow().getWidth() / mc.getWindow().getHeight(), 0.05F, 10.0F); RenderSystem.backupProjectionMatrix(); RenderSystem.setProjectionMatrix(matrix4f, ProjectionType.PERSPECTIVE); Matrix4fStack matrix4fStack = RenderSystem.getModelViewStack(); matrix4fStack.pushMatrix(); matrix4fStack.rotationX((float) Math.PI); - RenderSystem.setShader(CoreShaders.POSITION_TEX_COLOR); - RenderSystem.enableBlend(); - RenderSystem.disableCull(); - RenderSystem.depthMask(false); int i = 2; + RenderPipeline renderPipeline = RenderPipelines.PANORAMA; + RenderTarget renderTarget = Minecraft.getInstance().getMainRenderTarget(); + GpuTexture gpuTexture = renderTarget.getColorTexture(); + GpuTexture gpuTexture2 = renderTarget.getDepthTexture(); + RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(VertexFormat.Mode.QUADS); + GpuBuffer gpuBuffer = autoStorageIndexBuffer.getBuffer(36); - for (int j = 0; j < 4; j++) { - matrix4fStack.pushMatrix(); - float f = (j % 2 / 2.0F - 0.5F) / 256.0F; - float g = (j / 2 / 2.0F - 0.5F) / 256.0F; - float h = 0.0F; - matrix4fStack.translate(f, g, 0.0F); - matrix4fStack.rotateX(pitch * (float) (Math.PI / 180.0)); - matrix4fStack.rotateY(yaw * (float) (Math.PI / 180.0)); + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass(gpuTexture, OptionalInt.empty(), gpuTexture2, OptionalDouble.empty())) { + renderPass.setPipeline(renderPipeline); + renderPass.setVertexBuffer(0, this.cubeMapBuffer); + renderPass.setIndexBuffer(gpuBuffer, autoStorageIndexBuffer.type()); - for (int k = 0; k < 6; k++) { - RenderSystem.setShaderTexture(0, (ResourceLocation)this.sides.get(k)); - BufferBuilder bufferBuilder = tesselator.begin(Mode.QUADS, DefaultVertexFormat.POSITION_TEX_COLOR); - int l = Math.round(255.0F * alpha) / (j + 1); - if (k == 0) { - bufferBuilder.addVertex(-1.0F, -1.0F, 1.0F).setUv(0.0F, 0.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(-1.0F, 1.0F, 1.0F).setUv(0.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, 1.0F, 1.0F).setUv(1.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, -1.0F, 1.0F).setUv(1.0F, 0.0F).setWhiteAlpha(l); + for (int j = 0; j < 4; j++) { + matrix4fStack.pushMatrix(); + float f = (j % 2 / 2.0F - 0.5F) / 256.0F; + float g = (j / 2 / 2.0F - 0.5F) / 256.0F; + float h = 0.0F; + matrix4fStack.translate(f, g, 0.0F); + matrix4fStack.rotateX(pitch * (float) (Math.PI / 180.0)); + matrix4fStack.rotateY(yaw * (float) (Math.PI / 180.0)); + RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, alpha / (j + 1)); + + for (int k = 0; k < 6; k++) { + renderPass.bindSampler("Sampler0", mc.getTextureManager().getTexture((ResourceLocation)this.sides.get(k)).getTexture()); + renderPass.drawIndexed(6 * k, 6); } - if (k == 1) { - bufferBuilder.addVertex(1.0F, -1.0F, 1.0F).setUv(0.0F, 0.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, 1.0F, 1.0F).setUv(0.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, 1.0F, -1.0F).setUv(1.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, -1.0F, -1.0F).setUv(1.0F, 0.0F).setWhiteAlpha(l); - } - - if (k == 2) { - bufferBuilder.addVertex(1.0F, -1.0F, -1.0F).setUv(0.0F, 0.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, 1.0F, -1.0F).setUv(0.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(-1.0F, 1.0F, -1.0F).setUv(1.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(-1.0F, -1.0F, -1.0F).setUv(1.0F, 0.0F).setWhiteAlpha(l); - } - - if (k == 3) { - bufferBuilder.addVertex(-1.0F, -1.0F, -1.0F).setUv(0.0F, 0.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(-1.0F, 1.0F, -1.0F).setUv(0.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(-1.0F, 1.0F, 1.0F).setUv(1.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(-1.0F, -1.0F, 1.0F).setUv(1.0F, 0.0F).setWhiteAlpha(l); - } - - if (k == 4) { - bufferBuilder.addVertex(-1.0F, -1.0F, -1.0F).setUv(0.0F, 0.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(-1.0F, -1.0F, 1.0F).setUv(0.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, -1.0F, 1.0F).setUv(1.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, -1.0F, -1.0F).setUv(1.0F, 0.0F).setWhiteAlpha(l); - } - - if (k == 5) { - bufferBuilder.addVertex(-1.0F, 1.0F, 1.0F).setUv(0.0F, 0.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(-1.0F, 1.0F, -1.0F).setUv(0.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, 1.0F, -1.0F).setUv(1.0F, 1.0F).setWhiteAlpha(l); - bufferBuilder.addVertex(1.0F, 1.0F, 1.0F).setUv(1.0F, 0.0F).setWhiteAlpha(l); - } - - BufferUploader.drawWithShader(bufferBuilder.buildOrThrow()); + matrix4fStack.popMatrix(); } - - matrix4fStack.popMatrix(); - RenderSystem.colorMask(true, true, true, false); } - RenderSystem.colorMask(true, true, true, true); + RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); RenderSystem.restoreProjectionMatrix(); matrix4fStack.popMatrix(); - RenderSystem.depthMask(true); - RenderSystem.enableCull(); - RenderSystem.enableDepthTest(); + } + + private void initializeVertices() { + this.cubeMapBuffer = RenderSystem.getDevice() + .createBuffer(() -> "Cube map vertex buffer", BufferType.VERTICES, BufferUsage.DYNAMIC_WRITE, 24 * DefaultVertexFormat.POSITION_TEX.getVertexSize()); + + try (ByteBufferBuilder byteBufferBuilder = new ByteBufferBuilder(DefaultVertexFormat.POSITION_TEX.getVertexSize() * 4)) { + BufferBuilder bufferBuilder = new BufferBuilder(byteBufferBuilder, VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION_TEX); + bufferBuilder.addVertex(-1.0F, -1.0F, 1.0F).setUv(0.0F, 0.0F); + bufferBuilder.addVertex(-1.0F, 1.0F, 1.0F).setUv(0.0F, 1.0F); + bufferBuilder.addVertex(1.0F, 1.0F, 1.0F).setUv(1.0F, 1.0F); + bufferBuilder.addVertex(1.0F, -1.0F, 1.0F).setUv(1.0F, 0.0F); + bufferBuilder.addVertex(1.0F, -1.0F, 1.0F).setUv(0.0F, 0.0F); + bufferBuilder.addVertex(1.0F, 1.0F, 1.0F).setUv(0.0F, 1.0F); + bufferBuilder.addVertex(1.0F, 1.0F, -1.0F).setUv(1.0F, 1.0F); + bufferBuilder.addVertex(1.0F, -1.0F, -1.0F).setUv(1.0F, 0.0F); + bufferBuilder.addVertex(1.0F, -1.0F, -1.0F).setUv(0.0F, 0.0F); + bufferBuilder.addVertex(1.0F, 1.0F, -1.0F).setUv(0.0F, 1.0F); + bufferBuilder.addVertex(-1.0F, 1.0F, -1.0F).setUv(1.0F, 1.0F); + bufferBuilder.addVertex(-1.0F, -1.0F, -1.0F).setUv(1.0F, 0.0F); + bufferBuilder.addVertex(-1.0F, -1.0F, -1.0F).setUv(0.0F, 0.0F); + bufferBuilder.addVertex(-1.0F, 1.0F, -1.0F).setUv(0.0F, 1.0F); + bufferBuilder.addVertex(-1.0F, 1.0F, 1.0F).setUv(1.0F, 1.0F); + bufferBuilder.addVertex(-1.0F, -1.0F, 1.0F).setUv(1.0F, 0.0F); + bufferBuilder.addVertex(-1.0F, -1.0F, -1.0F).setUv(0.0F, 0.0F); + bufferBuilder.addVertex(-1.0F, -1.0F, 1.0F).setUv(0.0F, 1.0F); + bufferBuilder.addVertex(1.0F, -1.0F, 1.0F).setUv(1.0F, 1.0F); + bufferBuilder.addVertex(1.0F, -1.0F, -1.0F).setUv(1.0F, 0.0F); + bufferBuilder.addVertex(-1.0F, 1.0F, 1.0F).setUv(0.0F, 0.0F); + bufferBuilder.addVertex(-1.0F, 1.0F, -1.0F).setUv(0.0F, 1.0F); + bufferBuilder.addVertex(1.0F, 1.0F, -1.0F).setUv(1.0F, 1.0F); + bufferBuilder.addVertex(1.0F, 1.0F, 1.0F).setUv(1.0F, 0.0F); + + try (MeshData meshData = bufferBuilder.buildOrThrow()) { + CommandEncoder commandEncoder = RenderSystem.getDevice().createCommandEncoder(); + commandEncoder.writeToBuffer(this.cubeMapBuffer, meshData.vertexBuffer(), 0); + } + } } public void registerTextures(TextureManager textureManager) { diff --git a/net/minecraft/client/renderer/GameRenderer.java b/net/minecraft/client/renderer/GameRenderer.java index 9dbf6b82..df769a60 100644 --- a/net/minecraft/client/renderer/GameRenderer.java +++ b/net/minecraft/client/renderer/GameRenderer.java @@ -1,19 +1,24 @@ package net.minecraft.client.renderer; import com.mojang.blaze3d.ProjectionType; +import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.platform.Lighting; import com.mojang.blaze3d.platform.NativeImage; import com.mojang.blaze3d.platform.Window; import com.mojang.blaze3d.resource.CrossFrameResourcePool; +import com.mojang.blaze3d.shaders.ShaderType; +import com.mojang.blaze3d.systems.GpuDevice; import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.blaze3d.vertex.PoseStack; +import com.mojang.jtracy.TracyClient; import com.mojang.logging.LogUtils; import com.mojang.math.Axis; import java.io.IOException; +import java.io.Reader; import java.nio.file.Files; import java.nio.file.LinkOption; import java.nio.file.Path; -import java.util.Locale; +import java.util.function.BiFunction; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.CrashReport; @@ -28,6 +33,7 @@ import net.minecraft.client.Options; import net.minecraft.client.Screenshot; import net.minecraft.client.gui.GuiGraphics; import net.minecraft.client.player.AbstractClientPlayer; +import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.renderer.MultiBufferSource.BufferSource; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.client.server.IntegratedServer; @@ -66,6 +72,7 @@ import net.minecraft.world.phys.EntityHitResult; import net.minecraft.world.phys.HitResult; import net.minecraft.world.phys.Vec3; import net.minecraft.world.phys.HitResult.Type; +import org.apache.commons.io.IOUtils; import org.jetbrains.annotations.Nullable; import org.joml.Matrix4f; import org.joml.Matrix4fStack; @@ -78,16 +85,18 @@ public class GameRenderer implements AutoCloseable { private static final ResourceLocation BLUR_POST_CHAIN_ID = ResourceLocation.withDefaultNamespace("blur"); public static final int MAX_BLUR_RADIUS = 10; private static final Logger LOGGER = LogUtils.getLogger(); - private static final boolean DEPTH_BUFFER_DEBUG = false; public static final float PROJECTION_Z_NEAR = 0.05F; private static final float GUI_Z_NEAR = 1000.0F; + private static final float PORTAL_SPINNING_SPEED = 20.0F; + private static final float NAUSEA_SPINNING_SPEED = 7.0F; private final Minecraft minecraft; private final ResourceManager resourceManager; private final RandomSource random = RandomSource.create(); private float renderDistance; public final ItemInHandRenderer itemInHandRenderer; private final RenderBuffers renderBuffers; - private int confusionAnimationTick; + private float spinningEffectTime; + private float spinningEffectSpeed; private float fovModifier; private float oldFovModifier; private float darkenWorldAmount; @@ -177,19 +186,49 @@ public class GameRenderer implements AutoCloseable { if (!(f < 1.0F)) { PostChain postChain = this.minecraft.getShaderManager().getPostChain(BLUR_POST_CHAIN_ID, LevelTargetBundle.MAIN_TARGETS); if (postChain != null) { - postChain.setUniform("Radius", f); - postChain.process(this.minecraft.getMainRenderTarget(), this.resourcePool); + postChain.process(this.minecraft.getMainRenderTarget(), this.resourcePool, renderPass -> renderPass.setUniform("Radius", f)); } } } public void preloadUiShader(ResourceProvider resourceProvider) { - try { - this.minecraft - .getShaderManager() - .preloadForStartup(resourceProvider, CoreShaders.RENDERTYPE_GUI, CoreShaders.RENDERTYPE_GUI_OVERLAY, CoreShaders.POSITION_TEX_COLOR); - } catch (ShaderManager.CompilationException | IOException var3) { - throw new RuntimeException("Could not preload shaders for loading UI", var3); + GpuDevice gpuDevice = RenderSystem.getDevice(); + BiFunction biFunction = (resourceLocation, shaderType) -> { + ResourceLocation resourceLocation2 = shaderType.idConverter().idToFile(resourceLocation); + + try { + Reader reader = resourceProvider.getResourceOrThrow(resourceLocation2).openAsReader(); + + String var5; + try { + var5 = IOUtils.toString(reader); + } catch (Throwable var8) { + if (reader != null) { + try { + reader.close(); + } catch (Throwable var7) { + var8.addSuppressed(var7); + } + } + + throw var8; + } + + if (reader != null) { + reader.close(); + } + + return var5; + } catch (IOException var9) { + LOGGER.error("Coudln't preload {} shader {}: {}", shaderType, resourceLocation, var9); + return null; + } + }; + gpuDevice.precompilePipeline(RenderPipelines.GUI, biFunction); + gpuDevice.precompilePipeline(RenderPipelines.GUI_OVERLAY, biFunction); + gpuDevice.precompilePipeline(RenderPipelines.GUI_TEXTURED_OVERLAY, biFunction); + if (TracyClient.isAvailable()) { + gpuDevice.precompilePipeline(RenderPipelines.TRACY_BLIT, biFunction); } } @@ -199,13 +238,22 @@ public class GameRenderer implements AutoCloseable { public void tick() { this.tickFov(); this.lightTexture.tick(); + LocalPlayer localPlayer = this.minecraft.player; if (this.minecraft.getCameraEntity() == null) { - this.minecraft.setCameraEntity(this.minecraft.player); + this.minecraft.setCameraEntity(localPlayer); } this.mainCamera.tick(); this.itemInHandRenderer.tick(); - this.confusionAnimationTick++; + float f = localPlayer.portalEffectIntensity; + float g = localPlayer.getEffectBlendFactor(MobEffects.NAUSEA, 1.0F); + if (!(f > 0.0F) && !(g > 0.0F)) { + this.spinningEffectSpeed = 0.0F; + } else { + this.spinningEffectSpeed = (f * 20.0F + g * 7.0F) / (f + g); + this.spinningEffectTime = this.spinningEffectTime + this.spinningEffectSpeed; + } + if (this.minecraft.level.tickRateManager().runsNormally()) { this.minecraft.levelRenderer.tickParticles(this.mainCamera); this.darkenWorldAmountO = this.darkenWorldAmount; @@ -450,29 +498,25 @@ public class GameRenderer implements AutoCloseable { if (!this.minecraft.noRender) { ProfilerFiller profilerFiller = Profiler.get(); boolean bl = this.minecraft.isGameLoadFinished(); - int i = (int)(this.minecraft.mouseHandler.xpos() * this.minecraft.getWindow().getGuiScaledWidth() / this.minecraft.getWindow().getScreenWidth()); - int j = (int)(this.minecraft.mouseHandler.ypos() * this.minecraft.getWindow().getGuiScaledHeight() / this.minecraft.getWindow().getScreenHeight()); - RenderSystem.viewport(0, 0, this.minecraft.getWindow().getWidth(), this.minecraft.getWindow().getHeight()); + int i = (int)this.minecraft.mouseHandler.getScaledXPos(this.minecraft.getWindow()); + int j = (int)this.minecraft.mouseHandler.getScaledYPos(this.minecraft.getWindow()); if (bl && renderLevel && this.minecraft.level != null) { profilerFiller.push("level"); this.renderLevel(deltaTracker); this.tryTakeScreenshotIfNeeded(); this.minecraft.levelRenderer.doEntityOutline(); if (this.postEffectId != null && this.effectActive) { - RenderSystem.disableBlend(); - RenderSystem.disableDepthTest(); RenderSystem.resetTextureMatrix(); PostChain postChain = this.minecraft.getShaderManager().getPostChain(this.postEffectId, LevelTargetBundle.MAIN_TARGETS); if (postChain != null) { - postChain.process(this.minecraft.getMainRenderTarget(), this.resourcePool); + postChain.process(this.minecraft.getMainRenderTarget(), this.resourcePool, null); } } - - this.minecraft.getMainRenderTarget().bindWrite(true); } Window window = this.minecraft.getWindow(); - RenderSystem.clear(256); + RenderTarget renderTarget = this.minecraft.getMainRenderTarget(); + RenderSystem.getDevice().createCommandEncoder().clearDepthTexture(renderTarget.getDepthTexture(), 1.0); Matrix4f matrix4f = new Matrix4f() .setOrtho(0.0F, (float)(window.getWidth() / window.getGuiScale()), (float)(window.getHeight() / window.getGuiScale()), 0.0F, 1000.0F, 21000.0F); RenderSystem.setProjectionMatrix(matrix4f, ProjectionType.ORTHOGRAPHIC); @@ -489,15 +533,15 @@ public class GameRenderer implements AutoCloseable { this.minecraft.gui.render(guiGraphics, deltaTracker); guiGraphics.flush(); - RenderSystem.clear(256); + RenderSystem.getDevice().createCommandEncoder().clearDepthTexture(renderTarget.getDepthTexture(), 1.0); profilerFiller.pop(); } if (this.minecraft.getOverlay() != null) { try { this.minecraft.getOverlay().render(guiGraphics, i, j, deltaTracker.getGameTimeDeltaTicks()); - } catch (Throwable var17) { - CrashReport crashReport = CrashReport.forThrowable(var17, "Rendering overlay"); + } catch (Throwable var18) { + CrashReport crashReport = CrashReport.forThrowable(var18, "Rendering overlay"); CrashReportCategory crashReportCategory = crashReport.addCategory("Overlay render details"); crashReportCategory.setDetail("Overlay name", (CrashReportDetail)(() -> this.minecraft.getOverlay().getClass().getCanonicalName())); throw new ReportedException(crashReport); @@ -505,28 +549,11 @@ public class GameRenderer implements AutoCloseable { } else if (bl && this.minecraft.screen != null) { try { this.minecraft.screen.renderWithTooltip(guiGraphics, i, j, deltaTracker.getGameTimeDeltaTicks()); - } catch (Throwable var16) { - CrashReport crashReport = CrashReport.forThrowable(var16, "Rendering screen"); + } catch (Throwable var17) { + CrashReport crashReport = CrashReport.forThrowable(var17, "Rendering screen"); CrashReportCategory crashReportCategory = crashReport.addCategory("Screen render details"); crashReportCategory.setDetail("Screen name", (CrashReportDetail)(() -> this.minecraft.screen.getClass().getCanonicalName())); - crashReportCategory.setDetail( - "Mouse location", - (CrashReportDetail)(() -> String.format( - Locale.ROOT, "Scaled: (%d, %d). Absolute: (%f, %f)", i, j, this.minecraft.mouseHandler.xpos(), this.minecraft.mouseHandler.ypos() - )) - ); - crashReportCategory.setDetail( - "Screen size", - (CrashReportDetail)(() -> String.format( - Locale.ROOT, - "Scaled: (%d, %d). Absolute: (%d, %d). Scale factor of %f", - this.minecraft.getWindow().getGuiScaledWidth(), - this.minecraft.getWindow().getGuiScaledHeight(), - this.minecraft.getWindow().getWidth(), - this.minecraft.getWindow().getHeight(), - this.minecraft.getWindow().getGuiScale() - )) - ); + this.minecraft.mouseHandler.fillMousePositionDetails(crashReportCategory, this.minecraft.getWindow()); throw new ReportedException(crashReport); } @@ -534,8 +561,8 @@ public class GameRenderer implements AutoCloseable { if (this.minecraft.screen != null) { this.minecraft.screen.handleDelayedNarration(); } - } catch (Throwable var15) { - CrashReport crashReport = CrashReport.forThrowable(var15, "Narrating screen"); + } catch (Throwable var16) { + CrashReport crashReport = CrashReport.forThrowable(var16, "Narrating screen"); CrashReportCategory crashReportCategory = crashReport.addCategory("Screen details"); crashReportCategory.setDetail("Screen name", (CrashReportDetail)(() -> this.minecraft.screen.getClass().getCanonicalName())); throw new ReportedException(crashReport); @@ -579,8 +606,7 @@ public class GameRenderer implements AutoCloseable { private void takeAutoScreenshot(Path path) { if (this.minecraft.levelRenderer.countRenderedSections() > 10 && this.minecraft.levelRenderer.hasRenderedAllSections()) { - NativeImage nativeImage = Screenshot.takeScreenshot(this.minecraft.getMainRenderTarget()); - Util.ioPool().execute(() -> { + Screenshot.takeScreenshot(this.minecraft.getMainRenderTarget(), nativeImage -> Util.ioPool().execute(() -> { int i = nativeImage.getWidth(); int j = nativeImage.getHeight(); int k = 0; @@ -601,7 +627,7 @@ public class GameRenderer implements AutoCloseable { } finally { nativeImage.close(); } - }); + })); } } @@ -633,9 +659,10 @@ public class GameRenderer implements AutoCloseable { public void renderLevel(DeltaTracker deltaTracker) { float f = deltaTracker.getGameTimeDeltaPartialTick(true); + LocalPlayer localPlayer = this.minecraft.player; this.lightTexture.updateLightTexture(f); if (this.minecraft.getCameraEntity() == null) { - this.minecraft.setCameraEntity(this.minecraft.player); + this.minecraft.setCameraEntity(localPlayer); } this.pick(f); @@ -644,7 +671,7 @@ public class GameRenderer implements AutoCloseable { boolean bl = this.shouldRenderBlockOutline(); profilerFiller.popPush("camera"); Camera camera = this.mainCamera; - Entity entity = (Entity)(this.minecraft.getCameraEntity() == null ? this.minecraft.player : this.minecraft.getCameraEntity()); + Entity entity = (Entity)(this.minecraft.getCameraEntity() == null ? localPlayer : this.minecraft.getCameraEntity()); float g = this.minecraft.level.tickRateManager().isEntityFrozen(entity) ? 1.0F : f; camera.setup(this.minecraft.level, entity, !this.minecraft.options.getCameraType().isFirstPerson(), this.minecraft.options.getCameraType().isMirrored(), g); this.renderDistance = this.minecraft.options.getEffectiveRenderDistance() * 16; @@ -658,29 +685,29 @@ public class GameRenderer implements AutoCloseable { matrix4f.mul(poseStack.last().pose()); float i = this.minecraft.options.screenEffectScale().get().floatValue(); - float j = Mth.lerp(f, this.minecraft.player.oSpinningEffectIntensity, this.minecraft.player.spinningEffectIntensity) * (i * i); - if (j > 0.0F) { - int k = this.minecraft.player.hasEffect(MobEffects.CONFUSION) ? 7 : 20; - float l = 5.0F / (j * j + 5.0F) - j * 0.04F; - l *= l; + float j = Mth.lerp(f, localPlayer.oPortalEffectIntensity, localPlayer.portalEffectIntensity); + float k = localPlayer.getEffectBlendFactor(MobEffects.NAUSEA, f); + float l = Math.max(j, k) * (i * i); + if (l > 0.0F) { + float m = 5.0F / (l * l + 5.0F) - l * 0.04F; + m *= m; Vector3f vector3f = new Vector3f(0.0F, Mth.SQRT_OF_TWO / 2.0F, Mth.SQRT_OF_TWO / 2.0F); - float m = (this.confusionAnimationTick + f) * k * (float) (Math.PI / 180.0); - matrix4f.rotate(m, vector3f); - matrix4f.scale(1.0F / l, 1.0F, 1.0F); - matrix4f.rotate(-m, vector3f); + float n = (this.spinningEffectTime + f * this.spinningEffectSpeed) * (float) (Math.PI / 180.0); + matrix4f.rotate(n, vector3f); + matrix4f.scale(1.0F / m, 1.0F, 1.0F); + matrix4f.rotate(-n, vector3f); } - float n = Math.max(h, this.minecraft.options.fov().get().intValue()); - Matrix4f matrix4f2 = this.getProjectionMatrix(n); + float m = Math.max(h, this.minecraft.options.fov().get().intValue()); + Matrix4f matrix4f2 = this.getProjectionMatrix(m); RenderSystem.setProjectionMatrix(matrix4f, ProjectionType.PERSPECTIVE); Quaternionf quaternionf = camera.rotation().conjugate(new Quaternionf()); Matrix4f matrix4f3 = new Matrix4f().rotation(quaternionf); this.minecraft.levelRenderer.prepareCullFrustum(camera.getPosition(), matrix4f3, matrix4f2); - this.minecraft.getMainRenderTarget().bindWrite(true); this.minecraft.levelRenderer.renderLevel(this.resourcePool, deltaTracker, bl, camera, this, matrix4f3, matrix4f); profilerFiller.popPush("hand"); if (this.renderHand) { - RenderSystem.clear(256); + RenderSystem.getDevice().createCommandEncoder().clearDepthTexture(this.minecraft.getMainRenderTarget().getDepthTexture(), 1.0); this.renderItemInHand(camera, f, matrix4f3); } diff --git a/net/minecraft/client/renderer/GpuWarnlistManager.java b/net/minecraft/client/renderer/GpuWarnlistManager.java index f02fe4b8..144a71a5 100644 --- a/net/minecraft/client/renderer/GpuWarnlistManager.java +++ b/net/minecraft/client/renderer/GpuWarnlistManager.java @@ -7,7 +7,8 @@ import com.google.gson.JsonArray; import com.google.gson.JsonObject; import com.google.gson.JsonParser; import com.google.gson.JsonSyntaxException; -import com.mojang.blaze3d.platform.GlUtil; +import com.mojang.blaze3d.systems.GpuDevice; +import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.logging.LogUtils; import java.io.IOException; import java.io.Reader; @@ -178,19 +179,22 @@ public class GpuWarnlistManager extends SimplePreparableReloadListener apply() { Builder builder = new Builder<>(); - String string = matchAny(this.rendererPatterns, GlUtil.getRenderer()); - if (!string.isEmpty()) { - builder.put("renderer", string); - } + GpuDevice gpuDevice = RenderSystem.getDevice(); + if (gpuDevice.getBackendName().equals("OpenGL")) { + String string = matchAny(this.rendererPatterns, gpuDevice.getRenderer()); + if (!string.isEmpty()) { + builder.put("renderer", string); + } - String string2 = matchAny(this.versionPatterns, GlUtil.getOpenGLVersion()); - if (!string2.isEmpty()) { - builder.put("version", string2); - } + String string2 = matchAny(this.versionPatterns, gpuDevice.getVersion()); + if (!string2.isEmpty()) { + builder.put("version", string2); + } - String string3 = matchAny(this.vendorPatterns, GlUtil.getVendor()); - if (!string3.isEmpty()) { - builder.put("vendor", string3); + String string3 = matchAny(this.vendorPatterns, gpuDevice.getVendor()); + if (!string3.isEmpty()) { + builder.put("vendor", string3); + } } return builder.build(); diff --git a/net/minecraft/client/renderer/ItemBlockRenderTypes.java b/net/minecraft/client/renderer/ItemBlockRenderTypes.java index 42a5041d..fb18c30d 100644 --- a/net/minecraft/client/renderer/ItemBlockRenderTypes.java +++ b/net/minecraft/client/renderer/ItemBlockRenderTypes.java @@ -70,7 +70,10 @@ public class ItemBlockRenderTypes { hashMap.put(Blocks.COBWEB, renderType3); hashMap.put(Blocks.SHORT_GRASS, renderType3); hashMap.put(Blocks.FERN, renderType3); + hashMap.put(Blocks.BUSH, renderType3); hashMap.put(Blocks.DEAD_BUSH, renderType3); + hashMap.put(Blocks.SHORT_DRY_GRASS, renderType3); + hashMap.put(Blocks.TALL_DRY_GRASS, renderType3); hashMap.put(Blocks.SEAGRASS, renderType3); hashMap.put(Blocks.TALL_SEAGRASS, renderType3); hashMap.put(Blocks.DANDELION, renderType3); @@ -285,6 +288,8 @@ public class ItemBlockRenderTypes { hashMap.put(Blocks.FLOWERING_AZALEA, renderType3); hashMap.put(Blocks.AZALEA, renderType3); hashMap.put(Blocks.PINK_PETALS, renderType3); + hashMap.put(Blocks.WILDFLOWERS, renderType3); + hashMap.put(Blocks.LEAF_LITTER, renderType3); hashMap.put(Blocks.BIG_DRIPLEAF, renderType3); hashMap.put(Blocks.BIG_DRIPLEAF_STEM, renderType3); hashMap.put(Blocks.SMALL_DRIPLEAF, renderType3); @@ -303,6 +308,8 @@ public class ItemBlockRenderTypes { hashMap.put(Blocks.WAXED_EXPOSED_COPPER_GRATE, renderType3); hashMap.put(Blocks.WAXED_WEATHERED_COPPER_GRATE, renderType3); hashMap.put(Blocks.WAXED_OXIDIZED_COPPER_GRATE, renderType3); + hashMap.put(Blocks.FIREFLY_BUSH, renderType3); + hashMap.put(Blocks.CACTUS_FLOWER, renderType3); RenderType renderType4 = RenderType.translucent(); hashMap.put(Blocks.ICE, renderType4); hashMap.put(Blocks.NETHER_PORTAL, renderType4); diff --git a/net/minecraft/client/renderer/ItemInHandRenderer.java b/net/minecraft/client/renderer/ItemInHandRenderer.java index e08aed3e..002a6480 100644 --- a/net/minecraft/client/renderer/ItemInHandRenderer.java +++ b/net/minecraft/client/renderer/ItemInHandRenderer.java @@ -131,12 +131,12 @@ public class ItemInHandRenderer { } public void renderItem( - LivingEntity entity, ItemStack itemStack, ItemDisplayContext displayContext, boolean leftHand, PoseStack poseStack, MultiBufferSource buffer, int seed + LivingEntity entity, ItemStack stack, ItemDisplayContext displayContext, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight ) { - if (!itemStack.isEmpty()) { + if (!stack.isEmpty()) { this.itemRenderer .renderStatic( - entity, itemStack, displayContext, leftHand, poseStack, buffer, entity.level(), seed, OverlayTexture.NO_OVERLAY, entity.getId() + displayContext.ordinal() + entity, stack, displayContext, poseStack, bufferSource, entity.level(), packedLight, OverlayTexture.NO_OVERLAY, entity.getId() + displayContext.ordinal() ); } } @@ -409,7 +409,7 @@ public class ItemInHandRenderer { boolean bl2 = CrossbowItem.isCharged(stack); boolean bl3 = humanoidArm == HumanoidArm.RIGHT; int i = bl3 ? 1 : -1; - if (player.isUsingItem() && player.getUseItemRemainingTicks() > 0 && player.getUsedItemHand() == hand) { + if (player.isUsingItem() && player.getUseItemRemainingTicks() > 0 && player.getUsedItemHand() == hand && !bl2) { this.applyItemArmTransform(poseStack, humanoidArm, equippedProgress); poseStack.translate(i * -0.4785682F, -0.094387F, 0.05731531F); poseStack.mulPose(Axis.XP.rotationDegrees(-11.935F)); @@ -440,7 +440,7 @@ public class ItemInHandRenderer { } this.renderItem( - player, stack, bl3 ? ItemDisplayContext.FIRST_PERSON_RIGHT_HAND : ItemDisplayContext.FIRST_PERSON_LEFT_HAND, !bl3, poseStack, buffer, combinedLight + player, stack, bl3 ? ItemDisplayContext.FIRST_PERSON_RIGHT_HAND : ItemDisplayContext.FIRST_PERSON_LEFT_HAND, poseStack, buffer, combinedLight ); } else { boolean bl2 = humanoidArm == HumanoidArm.RIGHT; @@ -527,7 +527,7 @@ public class ItemInHandRenderer { } this.renderItem( - player, stack, bl2 ? ItemDisplayContext.FIRST_PERSON_RIGHT_HAND : ItemDisplayContext.FIRST_PERSON_LEFT_HAND, !bl2, poseStack, buffer, combinedLight + player, stack, bl2 ? ItemDisplayContext.FIRST_PERSON_RIGHT_HAND : ItemDisplayContext.FIRST_PERSON_LEFT_HAND, poseStack, buffer, combinedLight ); } diff --git a/net/minecraft/client/renderer/LevelRenderer.java b/net/minecraft/client/renderer/LevelRenderer.java index 38257b4e..77889806 100644 --- a/net/minecraft/client/renderer/LevelRenderer.java +++ b/net/minecraft/client/renderer/LevelRenderer.java @@ -2,26 +2,25 @@ package net.minecraft.client.renderer; import com.google.common.collect.Lists; import com.google.common.collect.Sets; +import com.mojang.blaze3d.buffers.GpuBuffer; import com.mojang.blaze3d.framegraph.FrameGraphBuilder; import com.mojang.blaze3d.framegraph.FramePass; import com.mojang.blaze3d.framegraph.FrameGraphBuilder.Inspector; +import com.mojang.blaze3d.pipeline.RenderPipeline; import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.pipeline.TextureTarget; import com.mojang.blaze3d.platform.Lighting; -import com.mojang.blaze3d.platform.GlStateManager.DestFactor; -import com.mojang.blaze3d.platform.GlStateManager.SourceFactor; import com.mojang.blaze3d.resource.GraphicsResourceAllocator; import com.mojang.blaze3d.resource.RenderTargetDescriptor; import com.mojang.blaze3d.resource.ResourceHandle; -import com.mojang.blaze3d.shaders.Uniform; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.SheetedDecalTextureGenerator; -import com.mojang.blaze3d.vertex.VertexBuffer; import com.mojang.blaze3d.vertex.VertexConsumer; +import com.mojang.blaze3d.vertex.VertexFormat; import com.mojang.blaze3d.vertex.VertexMultiConsumer; -import com.mojang.blaze3d.vertex.PoseStack.Pose; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; import com.mojang.logging.LogUtils; import it.unimi.dsi.fastutil.ints.Int2ObjectMap; import it.unimi.dsi.fastutil.ints.Int2ObjectOpenHashMap; @@ -36,6 +35,8 @@ import java.util.Collection; import java.util.Iterator; import java.util.List; import java.util.Locale; +import java.util.OptionalDouble; +import java.util.OptionalInt; import java.util.Set; import java.util.SortedSet; import java.util.function.Supplier; @@ -56,6 +57,7 @@ import net.minecraft.client.multiplayer.ClientLevel; import net.minecraft.client.particle.Particle; import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.renderer.DimensionSpecialEffects.SkyType; +import net.minecraft.client.renderer.FogRenderer.FogMode; import net.minecraft.client.renderer.MultiBufferSource.BufferSource; import net.minecraft.client.renderer.blockentity.BlockEntityRenderDispatcher; import net.minecraft.client.renderer.chunk.RenderRegionCache; @@ -75,6 +77,7 @@ import net.minecraft.server.level.ParticleStatus; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.server.packs.resources.ResourceManagerReloadListener; import net.minecraft.util.ARGB; +import net.minecraft.util.Brightness; import net.minecraft.util.Mth; import net.minecraft.util.VisibleForDebug; import net.minecraft.util.profiling.Profiler; @@ -189,8 +192,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab this.entityOutlineTarget.destroyBuffers(); } - this.entityOutlineTarget = new TextureTarget(this.minecraft.getWindow().getWidth(), this.minecraft.getWindow().getHeight(), true); - this.entityOutlineTarget.setClearColor(0.0F, 0.0F, 0.0F, 0.0F); + this.entityOutlineTarget = new TextureTarget("Entity Outline", this.minecraft.getWindow().getWidth(), this.minecraft.getWindow().getHeight(), true); } @Nullable @@ -210,11 +212,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab public void doEntityOutline() { if (this.shouldShowEntityOutlines()) { - RenderSystem.enableBlend(); - RenderSystem.blendFuncSeparate(SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA, SourceFactor.ZERO, DestFactor.ONE); - this.entityOutlineTarget.blitAndBlendToScreen(this.minecraft.getWindow().getWidth(), this.minecraft.getWindow().getHeight()); - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); + this.entityOutlineTarget.blitAndBlendToTexture(this.minecraft.getMainRenderTarget().getColorTexture()); } } @@ -357,6 +355,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab this.lastCameraSectionY = j; this.lastCameraSectionZ = k; this.viewArea.repositionCamera(SectionPos.of(vec3)); + this.worldBorderRenderer.invalidate(); } this.sectionRenderDispatcher.setCamera(vec3); @@ -455,8 +454,8 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab Vector4f vector4f = FogRenderer.computeFogColor( camera, f, this.minecraft.level, this.minecraft.options.getEffectiveRenderDistance(), gameRenderer.getDarkenWorldAmount(f) ); - FogParameters fogParameters = FogRenderer.setupFog(camera, FogRenderer.FogMode.FOG_TERRAIN, vector4f, h, bl2, f); - FogParameters fogParameters2 = FogRenderer.setupFog(camera, FogRenderer.FogMode.FOG_SKY, vector4f, h, bl2, f); + FogParameters fogParameters = FogRenderer.setupFog(camera, FogMode.FOG_TERRAIN, vector4f, h, bl2, f); + FogParameters fogParameters2 = FogRenderer.setupFog(camera, FogMode.FOG_SKY, vector4f, h, bl2, f); profilerFiller.popPush("cullEntities"); boolean bl3 = this.collectVisibleEntities(camera, frustum, this.visibleEntities); this.visibleEntityCount = this.visibleEntities.size(); @@ -471,7 +470,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab this.targets.main = frameGraphBuilder.importExternal("main", this.minecraft.getMainRenderTarget()); int i = this.minecraft.getMainRenderTarget().width; int j = this.minecraft.getMainRenderTarget().height; - RenderTargetDescriptor renderTargetDescriptor = new RenderTargetDescriptor(i, j, true); + RenderTargetDescriptor renderTargetDescriptor = new RenderTargetDescriptor(i, j, true, 0); PostChain postChain = this.getTransparencyChain(); if (postChain != null) { this.targets.translucent = frameGraphBuilder.createInternal("translucent", renderTargetDescriptor); @@ -487,10 +486,16 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab FramePass framePass = frameGraphBuilder.addPass("clear"); this.targets.main = framePass.readsAndWrites(this.targets.main); - framePass.executes(() -> { - RenderSystem.clearColor(vector4f.x, vector4f.y, vector4f.z, 0.0F); - RenderSystem.clear(16640); - }); + framePass.executes( + () -> { + RenderTarget renderTarget = this.minecraft.getMainRenderTarget(); + RenderSystem.getDevice() + .createCommandEncoder() + .clearColorAndDepthTextures( + renderTarget.getColorTexture(), ARGB.colorFromFloat(0.0F, vector4f.x, vector4f.y, vector4f.z), renderTarget.getDepthTexture(), 1.0 + ); + } + ); if (!bl2) { this.addSkyPass(frameGraphBuilder, camera, f, fogParameters2); } @@ -498,7 +503,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab this.addMainPass(frameGraphBuilder, frustum, camera, frustumMatrix, projectionMatrix, fogParameters, renderBlockOutline, bl3, deltaTracker, profilerFiller); PostChain postChain2 = this.minecraft.getShaderManager().getPostChain(ENTITY_OUTLINE_POST_CHAIN_ID, LevelTargetBundle.OUTLINE_TARGETS); if (bl3 && postChain2 != null) { - postChain2.addToFrame(frameGraphBuilder, i, j, this.targets); + postChain2.addToFrame(frameGraphBuilder, i, j, this.targets, null); } this.addParticlesPass(frameGraphBuilder, camera, f, fogParameters); @@ -508,13 +513,13 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab if (!Float.isNaN(k)) { float l = this.ticks + f; int m = this.level.getCloudColor(f); - this.addCloudsPass(frameGraphBuilder, frustumMatrix, projectionMatrix, cloudStatus, camera.getPosition(), l, m, k + 0.33F); + this.addCloudsPass(frameGraphBuilder, cloudStatus, camera.getPosition(), l, m, k + 0.33F); } } this.addWeatherPass(frameGraphBuilder, camera.getPosition(), f, fogParameters); if (postChain != null) { - postChain.addToFrame(frameGraphBuilder, i, j, this.targets); + postChain.addToFrame(frameGraphBuilder, i, j, this.targets, null); } this.addLateDebugPass(frameGraphBuilder, vec3, fogParameters); @@ -530,12 +535,9 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab profilerFiller.pop(); } }); - this.minecraft.getMainRenderTarget().bindWrite(false); this.visibleEntities.clear(); this.targets.clear(); matrix4fStack.popMatrix(); - RenderSystem.depthMask(true); - RenderSystem.disableBlend(); RenderSystem.setShaderFog(FogParameters.NO_FOG); } @@ -572,8 +574,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab ResourceHandle resourceHandle = this.targets.main; ResourceHandle resourceHandle2 = this.targets.translucent; ResourceHandle resourceHandle3 = this.targets.itemEntity; - ResourceHandle resourceHandle4 = this.targets.weather; - ResourceHandle resourceHandle5 = this.targets.entityOutline; + ResourceHandle resourceHandle4 = this.targets.entityOutline; framePass.executes(() -> { RenderSystem.setShaderFog(fogParameters); float f = deltaTracker.getGameTimeDeltaPartialTick(false); @@ -592,21 +593,12 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab } if (resourceHandle3 != null) { - resourceHandle3.get().setClearColor(0.0F, 0.0F, 0.0F, 0.0F); - resourceHandle3.get().clear(); resourceHandle3.get().copyDepthFrom(this.minecraft.getMainRenderTarget()); - resourceHandle.get().bindWrite(false); } - if (resourceHandle4 != null) { - resourceHandle4.get().setClearColor(0.0F, 0.0F, 0.0F, 0.0F); - resourceHandle4.get().clear(); - } - - if (this.shouldShowEntityOutlines() && resourceHandle5 != null) { - resourceHandle5.get().setClearColor(0.0F, 0.0F, 0.0F, 0.0F); - resourceHandle5.get().clear(); - resourceHandle.get().bindWrite(false); + if (this.shouldShowEntityOutlines() && resourceHandle4 != null) { + RenderTarget renderTarget = resourceHandle4.get(); + RenderSystem.getDevice().createCommandEncoder().clearColorAndDepthTextures(renderTarget.getColorTexture(), 0, renderTarget.getDepthTexture(), 1.0); } PoseStack poseStack = new PoseStack(); @@ -653,8 +645,6 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab bufferSource.endBatch(RenderType.waterMask()); bufferSource.endBatch(); if (resourceHandle2 != null) { - resourceHandle2.get().setClearColor(0.0F, 0.0F, 0.0F, 0.0F); - resourceHandle2.get().clear(); resourceHandle2.get().copyDepthFrom(resourceHandle.get()); } @@ -685,8 +675,6 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab framePass.executes(() -> { RenderSystem.setShaderFog(fog); if (resourceHandle2 != null) { - resourceHandle2.get().setClearColor(0.0F, 0.0F, 0.0F, 0.0F); - resourceHandle2.get().clear(); resourceHandle2.get().copyDepthFrom(resourceHandle.get()); } @@ -694,16 +682,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab }); } - private void addCloudsPass( - FrameGraphBuilder frameGraphBuilder, - Matrix4f frustumMatrix, - Matrix4f projectionMatrix, - CloudStatus cloudStatus, - Vec3 cameraPosition, - float ageInTicks, - int height, - float ticks - ) { + private void addCloudsPass(FrameGraphBuilder frameGraphBuilder, CloudStatus cloudStatus, Vec3 cameraPosition, float ticks, int cloudColor, float cloudHeight) { FramePass framePass = frameGraphBuilder.addPass("clouds"); if (this.targets.clouds != null) { this.targets.clouds = framePass.readsAndWrites(this.targets.clouds); @@ -711,15 +690,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab this.targets.main = framePass.readsAndWrites(this.targets.main); } - ResourceHandle resourceHandle = this.targets.clouds; - framePass.executes(() -> { - if (resourceHandle != null) { - resourceHandle.get().setClearColor(0.0F, 0.0F, 0.0F, 0.0F); - resourceHandle.get().clear(); - } - - this.cloudRenderer.render(height, cloudStatus, ticks, frustumMatrix, projectionMatrix, cameraPosition, ageInTicks); - }); + framePass.executes(() -> this.cloudRenderer.render(cloudColor, cloudStatus, cloudHeight, cameraPosition, ticks)); } private void addWeatherPass(FrameGraphBuilder frameGraphBuilder, Vec3 cameraPosition, float partialTick, FogParameters fog) { @@ -751,7 +722,6 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab ResourceHandle resourceHandle = this.targets.main; framePass.executes(() -> { RenderSystem.setShaderFog(fog); - resourceHandle.get().bindWrite(false); PoseStack poseStack = new PoseStack(); BufferSource bufferSource = this.renderBuffers.bufferSource(); this.minecraft.debugRenderer.renderAfterTranslucents(poseStack, bufferSource, cameraPosition.x, cameraPosition.y, cameraPosition.z); @@ -834,7 +804,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab if (sortedSet != null && !sortedSet.isEmpty()) { int i = ((BlockDestructionProgress)sortedSet.last()).getProgress(); if (i >= 0) { - Pose pose = poseStack.last(); + PoseStack.Pose pose = poseStack.last(); VertexConsumer vertexConsumer = new SheetedDecalTextureGenerator( crumblingBufferSource.getBuffer((RenderType)ModelBakery.DESTROY_TYPES.get(i)), pose, 1.0F ); @@ -876,7 +846,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab int i = ((BlockDestructionProgress)sortedSet.last()).getProgress(); poseStack.pushPose(); poseStack.translate(blockPos.getX() - d, blockPos.getY() - e, blockPos.getZ() - f); - Pose pose = poseStack.last(); + PoseStack.Pose pose = poseStack.last(); VertexConsumer vertexConsumer = new SheetedDecalTextureGenerator(bufferSource.getBuffer((RenderType)ModelBakery.DESTROY_TYPES.get(i)), pose, 1.0F); this.minecraft.getBlockRenderer().renderBreakingTexture(this.level.getBlockState(blockPos), blockPos, this.level, poseStack, vertexConsumer); poseStack.popPose(); @@ -917,7 +887,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab * @throws java.lang.IllegalStateException if the specified {@code poseStack} is not clear */ private void checkPoseStack(PoseStack poseStack) { - if (!poseStack.clear()) { + if (!poseStack.isEmpty()) { throw new IllegalStateException("Pose stack not empty"); } } @@ -979,39 +949,66 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab boolean bl = renderType != RenderType.translucent(); ObjectListIterator objectListIterator = this.visibleSections.listIterator(bl ? 0 : this.visibleSections.size()); renderType.setupRenderState(); - CompiledShaderProgram compiledShaderProgram = RenderSystem.getShader(); - if (compiledShaderProgram == null) { - renderType.clearRenderState(); - zone.close(); - } else { - compiledShaderProgram.setDefaultUniforms(Mode.QUADS, frustrumMatrix, projectionMatrix, this.minecraft.getWindow()); - compiledShaderProgram.apply(); - Uniform uniform = compiledShaderProgram.MODEL_OFFSET; + RenderPipeline renderPipeline = renderType.getRenderPipeline(); + ArrayList arrayList = new ArrayList(); + RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(renderType.mode()); + int i = 0; - while (bl ? objectListIterator.hasNext() : objectListIterator.hasPrevious()) { - SectionRenderDispatcher.RenderSection renderSection = bl ? (SectionRenderDispatcher.RenderSection)objectListIterator.next() : objectListIterator.previous(); - if (!renderSection.getCompiled().isEmpty(renderType)) { - VertexBuffer vertexBuffer = renderSection.getBuffer(renderType); - BlockPos blockPos = renderSection.getOrigin(); - if (uniform != null) { - uniform.set((float)(blockPos.getX() - x), (float)(blockPos.getY() - y), (float)(blockPos.getZ() - z)); - uniform.upload(); + while (bl ? objectListIterator.hasNext() : objectListIterator.hasPrevious()) { + SectionRenderDispatcher.RenderSection renderSection = bl ? (SectionRenderDispatcher.RenderSection)objectListIterator.next() : objectListIterator.previous(); + SectionRenderDispatcher.SectionBuffers sectionBuffers = renderSection.getBuffers(renderType); + if (!renderSection.getCompiled().isEmpty(renderType) && sectionBuffers != null) { + GpuBuffer gpuBuffer; + VertexFormat.IndexType indexType; + if (sectionBuffers.getIndexBuffer() == null) { + if (sectionBuffers.getIndexCount() > i) { + i = sectionBuffers.getIndexCount(); } - vertexBuffer.bind(); - vertexBuffer.draw(); + gpuBuffer = null; + indexType = null; + } else { + gpuBuffer = sectionBuffers.getIndexBuffer(); + indexType = sectionBuffers.getIndexType(); + } + + BlockPos blockPos = renderSection.getRenderOrigin(); + arrayList.add( + new RenderPass.Draw( + 0, + sectionBuffers.getVertexBuffer(), + gpuBuffer, + indexType, + 0, + sectionBuffers.getIndexCount(), + uniformUploader -> uniformUploader.upload("ModelOffset", (float)(blockPos.getX() - x), (float)(blockPos.getY() - y), (float)(blockPos.getZ() - z)) + ) + ); + } + } + + GpuBuffer gpuBuffer2 = i == 0 ? null : autoStorageIndexBuffer.getBuffer(i); + VertexFormat.IndexType indexType2 = i == 0 ? null : autoStorageIndexBuffer.type(); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass( + renderType.getRenderTarget().getColorTexture(), OptionalInt.empty(), renderType.getRenderTarget().getDepthTexture(), OptionalDouble.empty() + )) { + renderPass.setPipeline(renderPipeline); + + for (int j = 0; j < 12; j++) { + GpuTexture gpuTexture = RenderSystem.getShaderTexture(j); + if (gpuTexture != null) { + renderPass.bindSampler("Sampler" + j, gpuTexture); } } - if (uniform != null) { - uniform.set(0.0F, 0.0F, 0.0F); - } - - compiledShaderProgram.clear(); - VertexBuffer.unbind(); - zone.close(); - renderType.clearRenderState(); + renderPass.drawMultipleIndexed(arrayList, gpuBuffer2, indexType2); } + + zone.close(); + renderType.clearRenderState(); } public void captureFrustum() { @@ -1083,7 +1080,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab this.skyRenderer.renderSunMoonAndStars(poseStack, bufferSource, h, l, i, j, fog); bufferSource.endBatch(); if (this.shouldRenderDarkDisc(partialTick)) { - this.skyRenderer.renderDarkDisc(poseStack); + this.skyRenderer.renderDarkDisc(); } } }); @@ -1112,7 +1109,7 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab if (renderSection.isDirty() && renderSection.hasAllNeighbors()) { boolean bl = false; if (this.minecraft.options.prioritizeChunkUpdates().get() == PrioritizeChunkUpdates.NEARBY) { - BlockPos blockPos2 = renderSection.getOrigin().offset(8, 8, 8); + BlockPos blockPos2 = SectionPos.of(renderSection.getSectionNode()).center(); bl = blockPos2.distSqr(blockPos) < 768.0 || renderSection.isDirtyFromPlayer(); } else if (this.minecraft.options.prioritizeChunkUpdates().get() == PrioritizeChunkUpdates.PLAYER_AFFECTED) { bl = renderSection.isDirtyFromPlayer(); @@ -1337,21 +1334,22 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab } public static int getLightColor(BlockAndTintGetter level, BlockPos pos) { - return getLightColor(level, level.getBlockState(pos), pos); + return getLightColor(LevelRenderer.BrightnessGetter.DEFAULT, level, level.getBlockState(pos), pos); } - public static int getLightColor(BlockAndTintGetter level, BlockState state, BlockPos pos) { + public static int getLightColor(LevelRenderer.BrightnessGetter brightnessGetter, BlockAndTintGetter level, BlockState state, BlockPos pos) { if (state.emissiveRendering(level, pos)) { return 15728880; } else { - int i = level.getBrightness(LightLayer.SKY, pos); - int j = level.getBrightness(LightLayer.BLOCK, pos); + int i = brightnessGetter.packedBrightness(level, pos); + int j = LightTexture.block(i); int k = state.getLightEmission(); if (j < k) { - j = k; + int l = LightTexture.sky(i); + return LightTexture.pack(k, l); + } else { + return i; } - - return i << 20 | j << 4; } } @@ -1408,4 +1406,16 @@ public class LevelRenderer implements ResourceManagerReloadListener, AutoCloseab public CloudRenderer getCloudRenderer() { return this.cloudRenderer; } + + @FunctionalInterface + @Environment(EnvType.CLIENT) + public interface BrightnessGetter { + LevelRenderer.BrightnessGetter DEFAULT = (blockAndTintGetter, blockPos) -> { + int i = blockAndTintGetter.getBrightness(LightLayer.SKY, blockPos); + int j = blockAndTintGetter.getBrightness(LightLayer.BLOCK, blockPos); + return Brightness.pack(j, i); + }; + + int packedBrightness(BlockAndTintGetter blockAndTintGetter, BlockPos blockPos); + } } diff --git a/net/minecraft/client/renderer/LightTexture.java b/net/minecraft/client/renderer/LightTexture.java index 5e836749..ebfae217 100644 --- a/net/minecraft/client/renderer/LightTexture.java +++ b/net/minecraft/client/renderer/LightTexture.java @@ -1,12 +1,14 @@ package net.minecraft.client.renderer; -import com.mojang.blaze3d.pipeline.TextureTarget; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.systems.GpuDevice; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.blaze3d.systems.RenderSystem; -import com.mojang.blaze3d.vertex.BufferBuilder; -import com.mojang.blaze3d.vertex.BufferUploader; -import com.mojang.blaze3d.vertex.DefaultVertexFormat; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; -import java.util.Objects; +import com.mojang.blaze3d.textures.FilterMode; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.textures.TextureFormat; +import com.mojang.blaze3d.vertex.VertexFormat; +import java.util.OptionalInt; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.Minecraft; @@ -14,7 +16,6 @@ import net.minecraft.client.multiplayer.ClientLevel; import net.minecraft.util.Mth; import net.minecraft.util.profiling.Profiler; import net.minecraft.util.profiling.ProfilerFiller; -import net.minecraft.world.effect.MobEffectInstance; import net.minecraft.world.effect.MobEffects; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.level.dimension.DimensionType; @@ -26,7 +27,7 @@ public class LightTexture implements AutoCloseable { public static final int FULL_SKY = 15728640; public static final int FULL_BLOCK = 240; private static final int TEXTURE_SIZE = 16; - private final TextureTarget target; + private final GpuTexture texture; private boolean updateLightTexture; private float blockLightRedFlicker; private final GameRenderer renderer; @@ -35,14 +36,18 @@ public class LightTexture implements AutoCloseable { public LightTexture(GameRenderer renderer, Minecraft minecraft) { this.renderer = renderer; this.minecraft = minecraft; - this.target = new TextureTarget(16, 16, false); - this.target.setFilterMode(9729); - this.target.setClearColor(1.0F, 1.0F, 1.0F, 1.0F); - this.target.clear(); + GpuDevice gpuDevice = RenderSystem.getDevice(); + this.texture = gpuDevice.createTexture("Light Texture", TextureFormat.RGBA8, 16, 16, 1); + this.texture.setTextureFilter(FilterMode.LINEAR, false); + gpuDevice.createCommandEncoder().clearColorTexture(this.texture, -1); + } + + public GpuTexture getTarget() { + return this.texture; } public void close() { - this.target.destroyBuffers(); + this.texture.close(); } public void tick() { @@ -52,16 +57,11 @@ public class LightTexture implements AutoCloseable { } public void turnOffLightLayer() { - RenderSystem.setShaderTexture(2, 0); + RenderSystem.setShaderTexture(2, null); } public void turnOnLightLayer() { - RenderSystem.setShaderTexture(2, this.target.getColorTextureId()); - } - - private float getDarknessGamma(float partialTick) { - MobEffectInstance mobEffectInstance = this.minecraft.player.getEffect(MobEffects.DARKNESS); - return mobEffectInstance != null ? mobEffectInstance.getBlendFactor(this.minecraft.player, partialTick) : 0.0F; + RenderSystem.setShaderTexture(2, this.texture); } private float calculateDarknessScale(LivingEntity entity, float gamma, float partialTick) { @@ -85,7 +85,7 @@ public class LightTexture implements AutoCloseable { } float h = this.minecraft.options.darknessEffectScale().get().floatValue(); - float i = this.getDarknessGamma(partialTicks) * h; + float i = this.minecraft.player.getEffectBlendFactor(MobEffects.DARKNESS, partialTicks) * h; float j = this.calculateDarknessScale(this.minecraft.player, i, partialTicks) * h; float k = this.minecraft.player.getWaterVision(); float l; @@ -102,26 +102,25 @@ public class LightTexture implements AutoCloseable { float n = clientLevel.dimensionType().ambientLight(); boolean bl = clientLevel.effects().forceBrightLightmap(); float o = this.minecraft.options.gamma().get().floatValue(); - CompiledShaderProgram compiledShaderProgram = (CompiledShaderProgram)Objects.requireNonNull( - RenderSystem.setShader(CoreShaders.LIGHTMAP), "Lightmap shader not loaded" - ); - compiledShaderProgram.safeGetUniform("AmbientLightFactor").set(n); - compiledShaderProgram.safeGetUniform("SkyFactor").set(g); - compiledShaderProgram.safeGetUniform("BlockFactor").set(m); - compiledShaderProgram.safeGetUniform("UseBrightLightmap").set(bl ? 1 : 0); - compiledShaderProgram.safeGetUniform("SkyLightColor").set(vector3f); - compiledShaderProgram.safeGetUniform("NightVisionFactor").set(l); - compiledShaderProgram.safeGetUniform("DarknessScale").set(j); - compiledShaderProgram.safeGetUniform("DarkenWorldFactor").set(this.renderer.getDarkenWorldAmount(partialTicks)); - compiledShaderProgram.safeGetUniform("BrightnessFactor").set(Math.max(0.0F, o - i)); - this.target.bindWrite(true); - BufferBuilder bufferBuilder = RenderSystem.renderThreadTesselator().begin(Mode.QUADS, DefaultVertexFormat.BLIT_SCREEN); - bufferBuilder.addVertex(0.0F, 0.0F, 0.0F); - bufferBuilder.addVertex(1.0F, 0.0F, 0.0F); - bufferBuilder.addVertex(1.0F, 1.0F, 0.0F); - bufferBuilder.addVertex(0.0F, 1.0F, 0.0F); - BufferUploader.drawWithShader(bufferBuilder.buildOrThrow()); - this.target.unbindWrite(); + RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(VertexFormat.Mode.QUADS); + GpuBuffer gpuBuffer = autoStorageIndexBuffer.getBuffer(6); + + try (RenderPass renderPass = RenderSystem.getDevice().createCommandEncoder().createRenderPass(this.texture, OptionalInt.empty())) { + renderPass.setPipeline(RenderPipelines.LIGHTMAP); + renderPass.setUniform("AmbientLightFactor", n); + renderPass.setUniform("SkyFactor", g); + renderPass.setUniform("BlockFactor", m); + renderPass.setUniform("UseBrightLightmap", bl ? 1 : 0); + renderPass.setUniform("SkyLightColor", vector3f.x, vector3f.y, vector3f.z); + renderPass.setUniform("NightVisionFactor", l); + renderPass.setUniform("DarknessScale", j); + renderPass.setUniform("DarkenWorldFactor", this.renderer.getDarkenWorldAmount(partialTicks)); + renderPass.setUniform("BrightnessFactor", Math.max(0.0F, o - i)); + renderPass.setVertexBuffer(0, RenderSystem.getQuadVertexBuffer()); + renderPass.setIndexBuffer(gpuBuffer, autoStorageIndexBuffer.type()); + renderPass.drawIndexed(0, 6); + } + profilerFiller.pop(); } } @@ -149,12 +148,12 @@ public class LightTexture implements AutoCloseable { return packedLight >>> 20 & 15; } - public static int lightCoordsWithEmission(int packedLight, int emission) { - if (emission == 0) { + public static int lightCoordsWithEmission(int packedLight, int emmision) { + if (emmision == 0) { return packedLight; } else { - int i = Math.max(sky(packedLight), emission); - int j = Math.max(block(packedLight), emission); + int i = Math.max(sky(packedLight), emmision); + int j = Math.max(block(packedLight), emmision); return pack(j, i); } } diff --git a/net/minecraft/client/renderer/MapRenderer.java b/net/minecraft/client/renderer/MapRenderer.java index 7f6743a3..e80a7bff 100644 --- a/net/minecraft/client/renderer/MapRenderer.java +++ b/net/minecraft/client/renderer/MapRenderer.java @@ -7,6 +7,7 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.Font; +import net.minecraft.client.gui.Font.DisplayMode; import net.minecraft.client.renderer.state.MapRenderState; import net.minecraft.client.renderer.state.MapRenderState.MapDecorationRenderState; import net.minecraft.client.renderer.texture.TextureAtlasSprite; @@ -81,17 +82,7 @@ public class MapRenderer { poseStack.scale(g, g, 1.0F); poseStack.translate(0.0F, 0.0F, -0.1F); font.drawInBatch( - mapDecorationRenderState.name, - 0.0F, - 0.0F, - -1, - false, - poseStack.last().pose(), - bufferSource, - Font.DisplayMode.NORMAL, - Integer.MIN_VALUE, - packedLight, - false + mapDecorationRenderState.name, 0.0F, 0.0F, -1, false, poseStack.last().pose(), bufferSource, DisplayMode.NORMAL, Integer.MIN_VALUE, packedLight, false ); poseStack.popPose(); } diff --git a/net/minecraft/client/renderer/MaterialMapper.java b/net/minecraft/client/renderer/MaterialMapper.java new file mode 100644 index 00000000..4cc7593a --- /dev/null +++ b/net/minecraft/client/renderer/MaterialMapper.java @@ -0,0 +1,17 @@ +package net.minecraft.client.renderer; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.resources.model.Material; +import net.minecraft.resources.ResourceLocation; + +@Environment(EnvType.CLIENT) +public record MaterialMapper(ResourceLocation sheet, String prefix) { + public Material apply(ResourceLocation name) { + return new Material(this.sheet, name.withPrefix(this.prefix + "/")); + } + + public Material defaultNamespaceApply(String name) { + return this.apply(ResourceLocation.withDefaultNamespace(name)); + } +} diff --git a/net/minecraft/client/renderer/Octree.java b/net/minecraft/client/renderer/Octree.java index 549f583e..ea214a09 100644 --- a/net/minecraft/client/renderer/Octree.java +++ b/net/minecraft/client/renderer/Octree.java @@ -103,9 +103,10 @@ public class Octree { } public boolean add(SectionRenderDispatcher.RenderSection section) { - boolean bl = section.getOrigin().getX() - this.bbCenterX < 0; - boolean bl2 = section.getOrigin().getY() - this.bbCenterY < 0; - boolean bl3 = section.getOrigin().getZ() - this.bbCenterZ < 0; + long l = section.getSectionNode(); + boolean bl = SectionPos.sectionToBlockCoord(SectionPos.x(l)) - this.bbCenterX < 0; + boolean bl2 = SectionPos.sectionToBlockCoord(SectionPos.y(l)) - this.bbCenterY < 0; + boolean bl3 = SectionPos.sectionToBlockCoord(SectionPos.z(l)) - this.bbCenterZ < 0; boolean bl4 = bl != this.cameraXDiffNegative; boolean bl5 = bl2 != this.cameraYDiffNegative; boolean bl6 = bl3 != this.cameraZDiffNegative; diff --git a/net/minecraft/client/renderer/PostChain.java b/net/minecraft/client/renderer/PostChain.java index e24cd289..250381d8 100644 --- a/net/minecraft/client/renderer/PostChain.java +++ b/net/minecraft/client/renderer/PostChain.java @@ -4,23 +4,28 @@ import com.google.common.collect.ImmutableList; import com.google.common.collect.Sets; import com.google.common.collect.ImmutableList.Builder; import com.mojang.blaze3d.framegraph.FrameGraphBuilder; +import com.mojang.blaze3d.pipeline.CompiledRenderPipeline; +import com.mojang.blaze3d.pipeline.RenderPipeline; import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.resource.GraphicsResourceAllocator; import com.mojang.blaze3d.resource.RenderTargetDescriptor; import com.mojang.blaze3d.resource.ResourceHandle; +import com.mojang.blaze3d.shaders.UniformType; +import com.mojang.blaze3d.systems.RenderPass; +import com.mojang.blaze3d.systems.RenderSystem; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.Objects; import java.util.Set; import java.util.Map.Entry; +import java.util.function.Consumer; import java.util.function.UnaryOperator; import java.util.stream.Collectors; import java.util.stream.Stream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.PostChain.TargetBundle.1; -import net.minecraft.client.renderer.PostPass.TargetInput; -import net.minecraft.client.renderer.PostPass.TextureInput; import net.minecraft.client.renderer.texture.AbstractTexture; import net.minecraft.client.renderer.texture.TextureManager; import net.minecraft.resources.ResourceLocation; @@ -40,8 +45,8 @@ public class PostChain { this.externalTargets = externalTargets; } - public static PostChain load(PostChainConfig config, TextureManager textureManager, ShaderManager shaderManager, Set externalTargets) throws ShaderManager.CompilationException { - Stream stream = config.passes().stream().flatMap(passx -> passx.inputs().stream()).flatMap(input -> input.referencedTargets().stream()); + public static PostChain load(PostChainConfig config, TextureManager textureManager, Set externalTargets, ResourceLocation name) throws ShaderManager.CompilationException { + Stream stream = config.passes().stream().flatMap(PostChainConfig.Pass::referencedTargets); Set set = (Set)stream.filter(resourceLocation -> !config.internalTargets().containsKey(resourceLocation)) .collect(Collectors.toSet()); Set set2 = Sets.difference(set, externalTargets); @@ -50,36 +55,51 @@ public class PostChain { } else { Builder builder = ImmutableList.builder(); - for (PostChainConfig.Pass pass : config.passes()) { - builder.add(createPass(textureManager, shaderManager, pass)); + for (int i = 0; i < config.passes().size(); i++) { + PostChainConfig.Pass pass = (PostChainConfig.Pass)config.passes().get(i); + builder.add(createPass(textureManager, pass, name.withSuffix("/" + i))); } return new PostChain(builder.build(), config.internalTargets(), set); } } - private static PostPass createPass(TextureManager textureManager, ShaderManager shaderManager, PostChainConfig.Pass pass) throws ShaderManager.CompilationException { - CompiledShaderProgram compiledShaderProgram = shaderManager.getProgramForLoading(pass.program()); + private static PostPass createPass(TextureManager textureManager, PostChainConfig.Pass pass, ResourceLocation location) throws ShaderManager.CompilationException { + RenderPipeline.Builder builder = RenderPipeline.builder(RenderPipelines.POST_PROCESSING_SNIPPET) + .withFragmentShader(pass.fragmentShaderId()) + .withVertexShader(pass.vertexShaderId()) + .withLocation(location); + + for (PostChainConfig.Input input : pass.inputs()) { + builder.withSampler(input.samplerName() + "Sampler"); + builder.withUniform(input.samplerName() + "Size", UniformType.VEC2); + } for (PostChainConfig.Uniform uniform : pass.uniforms()) { - String string = uniform.name(); - if (compiledShaderProgram.getUniform(string) == null) { - throw new ShaderManager.CompilationException("Uniform '" + string + "' does not exist for " + pass.programId()); + builder.withUniform(uniform.name(), (UniformType)Objects.requireNonNull((UniformType)UniformType.CODEC.byName(uniform.type()))); + } + + RenderPipeline renderPipeline = builder.build(); + CompiledRenderPipeline compiledRenderPipeline = RenderSystem.getDevice().precompilePipeline(renderPipeline); + + for (PostChainConfig.Uniform uniform2 : pass.uniforms()) { + String string = uniform2.name(); + if (!compiledRenderPipeline.containsUniform(string)) { + throw new ShaderManager.CompilationException("Uniform '" + string + "' does not exist for " + location); } } - String string2 = pass.programId().toString(); - PostPass postPass = new PostPass(string2, compiledShaderProgram, pass.outputTarget(), pass.uniforms()); + PostPass postPass = new PostPass(renderPipeline, pass.outputTarget(), pass.uniforms()); - for (PostChainConfig.Input input : pass.inputs()) { - switch (input) { - case PostChainConfig.TextureInput(String var34, ResourceLocation var35, int var36, int var37, boolean var38): - AbstractTexture abstractTexture = textureManager.getTexture(var35.withPath((UnaryOperator)(stringx -> "textures/effect/" + stringx + ".png"))); - abstractTexture.setFilter(var38, false); - postPass.addInput(new TextureInput(var34, abstractTexture, var36, var37)); + for (PostChainConfig.Input input2 : pass.inputs()) { + switch (input2) { + case PostChainConfig.TextureInput(String var39, ResourceLocation var40, int var41, int var42, boolean var43): + AbstractTexture abstractTexture = textureManager.getTexture(var40.withPath((UnaryOperator)(string -> "textures/effect/" + string + ".png"))); + abstractTexture.setFilter(var43, false); + postPass.addInput(new PostPass.TextureInput(var39, abstractTexture, var41, var42)); break; - case PostChainConfig.TargetInput(String var21, ResourceLocation var40, boolean var41, boolean var42): - postPass.addInput(new TargetInput(var21, var40, var41, var42)); + case PostChainConfig.TargetInput(String var22, ResourceLocation var45, boolean var46, boolean var47): + postPass.addInput(new PostPass.TargetInput(var22, var45, var46, var47)); break; default: throw new MatchException(null, null); @@ -89,7 +109,9 @@ public class PostChain { return postPass; } - public void addToFrame(FrameGraphBuilder frameGraphBuilder, int width, int height, PostChain.TargetBundle targetBundle) { + public void addToFrame( + FrameGraphBuilder frameGraphBuilder, int width, int height, PostChain.TargetBundle targetBundle, @Nullable Consumer uniformSetter + ) { Matrix4f matrix4f = new Matrix4f().setOrtho(0.0F, width, 0.0F, height, 0.1F, 1000.0F); Map> map = new HashMap(this.internalTargets.size() + this.externalTargets.size()); @@ -101,15 +123,15 @@ public class PostChain { ResourceLocation resourceLocation2 = (ResourceLocation)entry.getKey(); RenderTargetDescriptor renderTargetDescriptor = switch ((PostChainConfig.InternalTarget)entry.getValue()) { - case PostChainConfig.FixedSizedTarget(int var25, int var26) -> new RenderTargetDescriptor(var25, var26, true); - case PostChainConfig.FullScreenTarget var16 -> new RenderTargetDescriptor(width, height, true); + case PostChainConfig.FixedSizedTarget(int var26, int var27) -> new RenderTargetDescriptor(var26, var27, true, 0); + case PostChainConfig.FullScreenTarget var17 -> new RenderTargetDescriptor(width, height, true, 0); default -> throw new MatchException(null, null); }; map.put(resourceLocation2, frameGraphBuilder.createInternal(resourceLocation2.toString(), renderTargetDescriptor)); } for (PostPass postPass : this.passes) { - postPass.addToFrame(frameGraphBuilder, map, matrix4f); + postPass.addToFrame(frameGraphBuilder, map, matrix4f, uniformSetter); } for (ResourceLocation resourceLocation : this.externalTargets) { @@ -118,17 +140,11 @@ public class PostChain { } @Deprecated - public void process(RenderTarget target, GraphicsResourceAllocator graphicsResourceAllocator) { + public void process(RenderTarget renderTarget, GraphicsResourceAllocator allocator, @Nullable Consumer uniformSetter) { FrameGraphBuilder frameGraphBuilder = new FrameGraphBuilder(); - PostChain.TargetBundle targetBundle = PostChain.TargetBundle.of(MAIN_TARGET_ID, frameGraphBuilder.importExternal("main", target)); - this.addToFrame(frameGraphBuilder, target.width, target.height, targetBundle); - frameGraphBuilder.execute(graphicsResourceAllocator); - } - - public void setUniform(String name, float backgroundBlurriness) { - for (PostPass postPass : this.passes) { - postPass.getShader().safeGetUniform(name).set(backgroundBlurriness); - } + PostChain.TargetBundle targetBundle = PostChain.TargetBundle.of(MAIN_TARGET_ID, frameGraphBuilder.importExternal("main", renderTarget)); + this.addToFrame(frameGraphBuilder, renderTarget.width, renderTarget.height, targetBundle, uniformSetter); + frameGraphBuilder.execute(allocator); } @Environment(EnvType.CLIENT) diff --git a/net/minecraft/client/renderer/PostChainConfig.java b/net/minecraft/client/renderer/PostChainConfig.java index c85f6530..7e65f5c8 100644 --- a/net/minecraft/client/renderer/PostChainConfig.java +++ b/net/minecraft/client/renderer/PostChainConfig.java @@ -1,15 +1,19 @@ package net.minecraft.client.renderer; -import com.mojang.blaze3d.vertex.DefaultVertexFormat; +import com.mojang.blaze3d.shaders.UniformType; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.datafixers.util.Either; import com.mojang.serialization.Codec; import com.mojang.serialization.DataResult; import com.mojang.serialization.codecs.RecordCodecBuilder; import it.unimi.dsi.fastutil.objects.ObjectArraySet; +import java.util.Arrays; import java.util.List; import java.util.Map; +import java.util.Optional; import java.util.Set; import java.util.function.Function; +import java.util.stream.Stream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.resources.ResourceLocation; @@ -72,7 +76,13 @@ public record PostChainConfig(Map inputs, ResourceLocation outputTarget, List uniforms) { + public record Pass( + ResourceLocation vertexShaderId, + ResourceLocation fragmentShaderId, + List inputs, + ResourceLocation outputTarget, + List uniforms + ) { private static final Codec> INPUTS_CODEC = PostChainConfig.Input.CODEC.listOf().validate(list -> { Set set = new ObjectArraySet<>(list.size()); @@ -86,7 +96,8 @@ public record PostChainConfig(Map CODEC = RecordCodecBuilder.create( instance -> instance.group( - ResourceLocation.CODEC.fieldOf("program").forGetter(PostChainConfig.Pass::programId), + ResourceLocation.CODEC.fieldOf("vertex_shader").forGetter(PostChainConfig.Pass::vertexShaderId), + ResourceLocation.CODEC.fieldOf("fragment_shader").forGetter(PostChainConfig.Pass::fragmentShaderId), INPUTS_CODEC.optionalFieldOf("inputs", List.of()).forGetter(PostChainConfig.Pass::inputs), ResourceLocation.CODEC.fieldOf("output").forGetter(PostChainConfig.Pass::outputTarget), PostChainConfig.Uniform.CODEC.listOf().optionalFieldOf("uniforms", List.of()).forGetter(PostChainConfig.Pass::uniforms) @@ -94,8 +105,9 @@ public record PostChainConfig(Map referencedTargets() { + Stream stream = this.inputs.stream().flatMap(input -> input.referencedTargets().stream()); + return Stream.concat(stream, Stream.of(this.outputTarget)); } } @@ -137,13 +149,35 @@ public record PostChainConfig(Map values) { + public record Uniform(String name, String type, Optional> values) { public static final Codec CODEC = RecordCodecBuilder.create( instance -> instance.group( Codec.STRING.fieldOf("name").forGetter(PostChainConfig.Uniform::name), - Codec.FLOAT.sizeLimitedListOf(4).fieldOf("values").forGetter(PostChainConfig.Uniform::values) + Codec.STRING.fieldOf("type").forGetter(PostChainConfig.Uniform::type), + Codec.FLOAT.sizeLimitedListOf(4).optionalFieldOf("values").forGetter(PostChainConfig.Uniform::values) ) .apply(instance, PostChainConfig.Uniform::new) ); + + public void setOnRenderPass(RenderPass renderPass) { + UniformType uniformType = (UniformType)UniformType.CODEC.byName(this.type); + if (!this.values.isEmpty() && uniformType != null && !((List)this.values.get()).isEmpty()) { + List list = (List)this.values.get(); + if (uniformType.isIntStorage()) { + renderPass.setUniform(this.name, (int)((Float)list.getFirst()).floatValue()); + } else { + float[] fs = new float[uniformType.getCount()]; + if (list.size() == 1) { + Arrays.fill(fs, (Float)list.getFirst()); + } else { + for (int i = 0; i < Math.min(list.size(), uniformType.getCount()); i++) { + fs[i] = (Float)list.get(i); + } + } + + renderPass.setUniform(this.name, fs); + } + } + } } } diff --git a/net/minecraft/client/renderer/PostPass.java b/net/minecraft/client/renderer/PostPass.java index 5c408e4d..219ff1e9 100644 --- a/net/minecraft/client/renderer/PostPass.java +++ b/net/minecraft/client/renderer/PostPass.java @@ -1,37 +1,41 @@ package net.minecraft.client.renderer; import com.mojang.blaze3d.ProjectionType; +import com.mojang.blaze3d.buffers.GpuBuffer; import com.mojang.blaze3d.framegraph.FrameGraphBuilder; import com.mojang.blaze3d.framegraph.FramePass; +import com.mojang.blaze3d.pipeline.RenderPipeline; import com.mojang.blaze3d.pipeline.RenderTarget; import com.mojang.blaze3d.resource.ResourceHandle; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.blaze3d.systems.RenderSystem; -import com.mojang.blaze3d.vertex.BufferBuilder; -import com.mojang.blaze3d.vertex.BufferUploader; -import com.mojang.blaze3d.vertex.DefaultVertexFormat; -import com.mojang.blaze3d.vertex.Tesselator; +import com.mojang.blaze3d.textures.FilterMode; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.blaze3d.vertex.VertexFormat; import java.util.ArrayList; import java.util.List; import java.util.Map; +import java.util.OptionalDouble; +import java.util.OptionalInt; +import java.util.function.Consumer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.PostChainConfig.Uniform; import net.minecraft.client.renderer.texture.AbstractTexture; import net.minecraft.resources.ResourceLocation; +import org.jetbrains.annotations.Nullable; import org.joml.Matrix4f; @Environment(EnvType.CLIENT) public class PostPass { private final String name; - private final CompiledShaderProgram shader; + private final RenderPipeline pipeline; private final ResourceLocation outputTargetId; - private final List uniforms; + private final List uniforms; private final List inputs = new ArrayList(); - public PostPass(String name, CompiledShaderProgram shader, ResourceLocation outputTargetId, List uniforms) { - this.name = name; - this.shader = shader; + public PostPass(RenderPipeline pipeline, ResourceLocation outputTargetId, List uniforms) { + this.pipeline = pipeline; + this.name = pipeline.getLocation().toString(); this.outputTargetId = outputTargetId; this.uniforms = uniforms; } @@ -40,7 +44,12 @@ public class PostPass { this.inputs.add(input); } - public void addToFrame(FrameGraphBuilder frameGraphBuilder, Map> targets, Matrix4f projectionMatrix) { + public void addToFrame( + FrameGraphBuilder frameGraphBuilder, + Map> targets, + Matrix4f projectionMatrix, + @Nullable Consumer uniformSetter + ) { FramePass framePass = frameGraphBuilder.addPass(this.name); for (PostPass.Input input : this.inputs) { @@ -53,69 +62,55 @@ public class PostPass { if (resourceHandle == null) { throw new IllegalStateException("Missing handle for target " + this.outputTargetId); } else { - framePass.executes(() -> { - RenderTarget renderTarget = resourceHandle.get(); - RenderSystem.viewport(0, 0, renderTarget.width, renderTarget.height); + framePass.executes( + () -> { + RenderTarget renderTarget = resourceHandle.get(); + RenderSystem.backupProjectionMatrix(); + RenderSystem.setProjectionMatrix(projectionMatrix, ProjectionType.ORTHOGRAPHIC); + GpuBuffer gpuBuffer = RenderSystem.getQuadVertexBuffer(); + RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(VertexFormat.Mode.QUADS); + GpuBuffer gpuBuffer2 = autoStorageIndexBuffer.getBuffer(6); - for (PostPass.Input inputx : this.inputs) { - inputx.bindTo(this.shader, targets); - } + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass( + renderTarget.getColorTexture(), OptionalInt.empty(), renderTarget.useDepth ? renderTarget.getDepthTexture() : null, OptionalDouble.empty() + )) { + renderPass.setPipeline(this.pipeline); + renderPass.setUniform("OutSize", (float)renderTarget.width, (float)renderTarget.height); + renderPass.setVertexBuffer(0, gpuBuffer); + renderPass.setIndexBuffer(gpuBuffer2, autoStorageIndexBuffer.type()); - this.shader.safeGetUniform("OutSize").set((float)renderTarget.width, (float)renderTarget.height); + for (PostPass.Input inputx : this.inputs) { + inputx.bindTo(renderPass, targets); + } - for (Uniform uniform : this.uniforms) { - com.mojang.blaze3d.shaders.Uniform uniform2 = this.shader.getUniform(uniform.name()); - if (uniform2 != null) { - uniform2.setFromConfig(uniform.values(), uniform.values().size()); + if (uniformSetter != null) { + uniformSetter.accept(renderPass); + } + + for (PostChainConfig.Uniform uniform : this.uniforms) { + uniform.setOnRenderPass(renderPass); + } + + renderPass.drawIndexed(0, 6); + } + + RenderSystem.restoreProjectionMatrix(); + + for (PostPass.Input input2 : this.inputs) { + input2.cleanup(targets); } } - - renderTarget.setClearColor(0.0F, 0.0F, 0.0F, 0.0F); - renderTarget.clear(); - renderTarget.bindWrite(false); - RenderSystem.depthFunc(519); - RenderSystem.setShader(this.shader); - RenderSystem.backupProjectionMatrix(); - RenderSystem.setProjectionMatrix(projectionMatrix, ProjectionType.ORTHOGRAPHIC); - BufferBuilder bufferBuilder = Tesselator.getInstance().begin(VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION); - bufferBuilder.addVertex(0.0F, 0.0F, 500.0F); - bufferBuilder.addVertex(renderTarget.width, 0.0F, 500.0F); - bufferBuilder.addVertex(renderTarget.width, renderTarget.height, 500.0F); - bufferBuilder.addVertex(0.0F, renderTarget.height, 500.0F); - BufferUploader.drawWithShader(bufferBuilder.buildOrThrow()); - RenderSystem.depthFunc(515); - RenderSystem.restoreProjectionMatrix(); - renderTarget.unbindWrite(); - - for (PostPass.Input input2 : this.inputs) { - input2.cleanup(targets); - } - - this.restoreDefaultUniforms(); - }); + ); } } - private void restoreDefaultUniforms() { - for (Uniform uniform : this.uniforms) { - String string = uniform.name(); - com.mojang.blaze3d.shaders.Uniform uniform2 = this.shader.getUniform(string); - net.minecraft.client.renderer.ShaderProgramConfig.Uniform uniform3 = this.shader.getUniformConfig(string); - if (uniform2 != null && uniform3 != null && !uniform.values().equals(uniform3.values())) { - uniform2.setFromConfig(uniform3); - } - } - } - - public CompiledShaderProgram getShader() { - return this.shader; - } - @Environment(EnvType.CLIENT) public interface Input { void addToPass(FramePass pass, Map> targets); - void bindTo(CompiledShaderProgram shaderProgram, Map> targets); + void bindTo(RenderPass renderPass, Map> targets); default void cleanup(Map> targets) { } @@ -138,18 +133,23 @@ public class PostPass { } @Override - public void bindTo(CompiledShaderProgram shaderProgram, Map> targets) { + public void bindTo(RenderPass renderPass, Map> targets) { ResourceHandle resourceHandle = this.getHandle(targets); RenderTarget renderTarget = resourceHandle.get(); - renderTarget.setFilterMode(this.bilinear ? 9729 : 9728); - shaderProgram.bindSampler(this.samplerName + "Sampler", this.depthBuffer ? renderTarget.getDepthTextureId() : renderTarget.getColorTextureId()); - shaderProgram.safeGetUniform(this.samplerName + "Size").set((float)renderTarget.width, (float)renderTarget.height); + renderTarget.setFilterMode(this.bilinear ? FilterMode.LINEAR : FilterMode.NEAREST); + GpuTexture gpuTexture = this.depthBuffer ? renderTarget.getDepthTexture() : renderTarget.getColorTexture(); + if (gpuTexture == null) { + throw new IllegalStateException("Missing " + (this.depthBuffer ? "depth" : "color") + "texture for target " + this.targetId); + } else { + renderPass.bindSampler(this.samplerName + "Sampler", gpuTexture); + renderPass.setUniform(this.samplerName + "Size", (float)renderTarget.width, (float)renderTarget.height); + } } @Override public void cleanup(Map> targets) { if (this.bilinear) { - this.getHandle(targets).get().setFilterMode(9728); + this.getHandle(targets).get().setFilterMode(FilterMode.NEAREST); } } } @@ -161,9 +161,9 @@ public class PostPass { } @Override - public void bindTo(CompiledShaderProgram shaderProgram, Map> targets) { - shaderProgram.bindSampler(this.samplerName + "Sampler", this.texture.getId()); - shaderProgram.safeGetUniform(this.samplerName + "Size").set((float)this.width, (float)this.height); + public void bindTo(RenderPass renderPass, Map> targets) { + renderPass.bindSampler(this.samplerName + "Sampler", this.texture.getTexture()); + renderPass.setUniform(this.samplerName + "Size", (float)this.width, (float)this.height); } } } diff --git a/net/minecraft/client/renderer/RenderPipelines.java b/net/minecraft/client/renderer/RenderPipelines.java new file mode 100644 index 00000000..d20399cd --- /dev/null +++ b/net/minecraft/client/renderer/RenderPipelines.java @@ -0,0 +1,759 @@ +package net.minecraft.client.renderer; + +import com.mojang.blaze3d.pipeline.BlendFunction; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.platform.DepthTestFunction; +import com.mojang.blaze3d.platform.DestFactor; +import com.mojang.blaze3d.platform.LogicOp; +import com.mojang.blaze3d.platform.PolygonMode; +import com.mojang.blaze3d.platform.SourceFactor; +import com.mojang.blaze3d.shaders.UniformType; +import com.mojang.blaze3d.vertex.DefaultVertexFormat; +import com.mojang.blaze3d.vertex.VertexFormat; +import java.util.HashMap; +import java.util.List; +import java.util.Map; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.resources.ResourceLocation; + +@Environment(EnvType.CLIENT) +public class RenderPipelines { + private static final Map PIPELINES_BY_LOCATION = new HashMap(); + private static final RenderPipeline.Snippet MATRICES_SNIPPET = RenderPipeline.builder() + .withUniform("ModelViewMat", UniformType.MATRIX4X4) + .withUniform("ProjMat", UniformType.MATRIX4X4) + .buildSnippet(); + private static final RenderPipeline.Snippet FOG_NO_COLOR_SNIPPET = RenderPipeline.builder() + .withUniform("FogStart", UniformType.FLOAT) + .withUniform("FogEnd", UniformType.FLOAT) + .withUniform("FogShape", UniformType.INT) + .buildSnippet(); + private static final RenderPipeline.Snippet FOG_SNIPPET = RenderPipeline.builder(FOG_NO_COLOR_SNIPPET) + .withUniform("FogColor", UniformType.VEC4) + .buildSnippet(); + private static final RenderPipeline.Snippet MATRICES_COLOR_SNIPPET = RenderPipeline.builder(MATRICES_SNIPPET) + .withUniform("ColorModulator", UniformType.VEC4) + .buildSnippet(); + private static final RenderPipeline.Snippet MATRICES_COLOR_FOG_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_SNIPPET, FOG_SNIPPET).buildSnippet(); + private static final RenderPipeline.Snippet MATRICES_COLOR_FOG_OFFSET_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withUniform("ModelOffset", UniformType.VEC3) + .buildSnippet(); + private static final RenderPipeline.Snippet MATRICES_COLOR_FOG_LIGHT_DIR_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_SNIPPET, FOG_SNIPPET) + .withUniform("Light0_Direction", UniformType.VEC3) + .withUniform("Light1_Direction", UniformType.VEC3) + .buildSnippet(); + private static final RenderPipeline.Snippet TERRAIN_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_FOG_OFFSET_SNIPPET) + .withVertexShader("core/terrain") + .withFragmentShader("core/terrain") + .withSampler("Sampler0") + .withSampler("Sampler2") + .withVertexFormat(DefaultVertexFormat.BLOCK, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet ENTITY_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_FOG_LIGHT_DIR_SNIPPET) + .withVertexShader("core/entity") + .withFragmentShader("core/entity") + .withSampler("Sampler0") + .withSampler("Sampler2") + .withVertexFormat(DefaultVertexFormat.NEW_ENTITY, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet BEACON_BEAM_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withVertexShader("core/rendertype_beacon_beam") + .withFragmentShader("core/rendertype_beacon_beam") + .withSampler("Sampler0") + .withVertexFormat(DefaultVertexFormat.BLOCK, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet TEXT_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withBlend(BlendFunction.TRANSLUCENT) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet END_PORTAL_SNIPPET = RenderPipeline.builder(MATRICES_SNIPPET, FOG_SNIPPET) + .withVertexShader("core/rendertype_end_portal") + .withFragmentShader("core/rendertype_end_portal") + .withSampler("Sampler0") + .withSampler("Sampler1") + .withUniform("GameTime", UniformType.FLOAT) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet CLOUDS_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_FOG_OFFSET_SNIPPET) + .withVertexShader("core/rendertype_clouds") + .withFragmentShader("core/rendertype_clouds") + .withBlend(BlendFunction.TRANSLUCENT) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet LINES_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withVertexShader("core/rendertype_lines") + .withFragmentShader("core/rendertype_lines") + .withUniform("LineWidth", UniformType.FLOAT) + .withUniform("ScreenSize", UniformType.VEC2) + .withBlend(BlendFunction.TRANSLUCENT) + .withCull(false) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR_NORMAL, VertexFormat.Mode.LINES) + .buildSnippet(); + private static final RenderPipeline.Snippet DEBUG_FILLED_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withVertexShader("core/position_color") + .withFragmentShader("core/position_color") + .withBlend(BlendFunction.TRANSLUCENT) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet PARTICLE_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withVertexShader("core/particle") + .withFragmentShader("core/particle") + .withSampler("Sampler0") + .withSampler("Sampler2") + .withVertexFormat(DefaultVertexFormat.PARTICLE, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet WEATHER_SNIPPET = RenderPipeline.builder(PARTICLE_SNIPPET) + .withBlend(BlendFunction.TRANSLUCENT) + .withCull(false) + .buildSnippet(); + private static final RenderPipeline.Snippet GUI_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withVertexShader("core/gui") + .withFragmentShader("core/gui") + .withBlend(BlendFunction.TRANSLUCENT) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet GUI_TEXTURED_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withVertexShader("core/position_tex_color") + .withFragmentShader("core/position_tex_color") + .withSampler("Sampler0") + .withBlend(BlendFunction.TRANSLUCENT) + .withVertexFormat(DefaultVertexFormat.POSITION_TEX_COLOR, VertexFormat.Mode.QUADS) + .buildSnippet(); + private static final RenderPipeline.Snippet OUTLINE_SNIPPET = RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withVertexShader("core/rendertype_outline") + .withFragmentShader("core/rendertype_outline") + .withSampler("Sampler0") + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION_TEX_COLOR, VertexFormat.Mode.QUADS) + .buildSnippet(); + public static final RenderPipeline.Snippet POST_PROCESSING_SNIPPET = RenderPipeline.builder() + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.QUADS) + .withUniform("ProjMat", UniformType.MATRIX4X4) + .withUniform("OutSize", UniformType.VEC2) + .buildSnippet(); + public static final RenderPipeline SOLID = register(RenderPipeline.builder(TERRAIN_SNIPPET).withLocation("pipeline/solid").build()); + public static final RenderPipeline WIREFRAME = register( + RenderPipeline.builder(TERRAIN_SNIPPET).withLocation("pipeline/wireframe").withPolygonMode(PolygonMode.WIREFRAME).build() + ); + public static final RenderPipeline CUTOUT_MIPPED = register( + RenderPipeline.builder(TERRAIN_SNIPPET).withLocation("pipeline/cutout_mipped").withShaderDefine("ALPHA_CUTOUT", 0.5F).build() + ); + public static final RenderPipeline CUTOUT = register( + RenderPipeline.builder(TERRAIN_SNIPPET).withLocation("pipeline/cutout").withShaderDefine("ALPHA_CUTOUT", 0.1F).build() + ); + public static final RenderPipeline TRANSLUCENT = register( + RenderPipeline.builder(TERRAIN_SNIPPET).withLocation("pipeline/translucent").withBlend(BlendFunction.TRANSLUCENT).build() + ); + public static final RenderPipeline TRIPWIRE = register( + RenderPipeline.builder(TERRAIN_SNIPPET).withLocation("pipeline/tripwire").withShaderDefine("ALPHA_CUTOUT", 0.1F).withBlend(BlendFunction.TRANSLUCENT).build() + ); + public static final RenderPipeline TRANSLUCENT_MOVING_BLOCK = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/translucent_moving_block") + .withVertexShader("core/rendertype_translucent_moving_block") + .withFragmentShader("core/rendertype_translucent_moving_block") + .withSampler("Sampler0") + .withSampler("Sampler2") + .withBlend(BlendFunction.TRANSLUCENT) + .withVertexFormat(DefaultVertexFormat.BLOCK, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline ARMOR_CUTOUT_NO_CULL = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/armor_cutout_no_cull") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withShaderDefine("NO_OVERLAY") + .withCull(false) + .build() + ); + public static final RenderPipeline ARMOR_DECAL_CUTOUT_NO_CULL = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/armor_decal_cutout_no_cull") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withShaderDefine("NO_OVERLAY") + .withCull(false) + .withDepthTestFunction(DepthTestFunction.EQUAL_DEPTH_TEST) + .build() + ); + public static final RenderPipeline ARMOR_TRANSLUCENT = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/armor_translucent") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withShaderDefine("NO_OVERLAY") + .withBlend(BlendFunction.TRANSLUCENT) + .withCull(false) + .build() + ); + public static final RenderPipeline ENTITY_SOLID = register( + RenderPipeline.builder(ENTITY_SNIPPET).withLocation("pipeline/entity_solid").withSampler("Sampler1").build() + ); + public static final RenderPipeline ENTITY_SOLID_Z_OFFSET_FORWARD = register( + RenderPipeline.builder(ENTITY_SNIPPET).withLocation("pipeline/entity_solid_offset_forward").withSampler("Sampler1").build() + ); + public static final RenderPipeline ENTITY_CUTOUT = register( + RenderPipeline.builder(ENTITY_SNIPPET).withLocation("pipeline/entity_cutout").withShaderDefine("ALPHA_CUTOUT", 0.1F).withSampler("Sampler1").build() + ); + public static final RenderPipeline ENTITY_CUTOUT_NO_CULL = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/entity_cutout_no_cull") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withSampler("Sampler1") + .withCull(false) + .build() + ); + public static final RenderPipeline ENTITY_CUTOUT_NO_CULL_Z_OFFSET = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/entity_cutout_no_cull_z_offset") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withSampler("Sampler1") + .withCull(false) + .build() + ); + public static final RenderPipeline ENTITY_TRANSLUCENT = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/entity_translucent") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withSampler("Sampler1") + .withBlend(BlendFunction.TRANSLUCENT) + .withCull(false) + .build() + ); + public static final RenderPipeline ENTITY_TRANSLUCENT_EMISSIVE = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/entity_translucent_emissive") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withShaderDefine("EMISSIVE") + .withSampler("Sampler1") + .withBlend(BlendFunction.TRANSLUCENT) + .withCull(false) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline ENTITY_SMOOTH_CUTOUT = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/entity_smooth_cutout") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withSampler("Sampler1") + .withCull(false) + .build() + ); + public static final RenderPipeline ENTITY_NO_OUTLINE = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/entity_no_outline") + .withShaderDefine("NO_OVERLAY") + .withBlend(BlendFunction.TRANSLUCENT) + .withCull(false) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline BREEZE_WIND = register( + RenderPipeline.builder(ENTITY_SNIPPET) + .withLocation("pipeline/breeze_wind") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withShaderDefine("APPLY_TEXTURE_MATRIX") + .withShaderDefine("NO_OVERLAY") + .withShaderDefine("NO_CARDINAL_LIGHTING") + .withUniform("TextureMat", UniformType.MATRIX4X4) + .withBlend(BlendFunction.TRANSLUCENT) + .withCull(false) + .build() + ); + public static final RenderPipeline ENERGY_SWIRL = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/energy_swirl") + .withVertexShader("core/entity") + .withFragmentShader("core/entity") + .withShaderDefine("ALPHA_CUTOUT", 0.1F) + .withShaderDefine("EMISSIVE") + .withShaderDefine("NO_OVERLAY") + .withShaderDefine("NO_CARDINAL_LIGHTING") + .withShaderDefine("APPLY_TEXTURE_MATRIX") + .withSampler("Sampler0") + .withUniform("TextureMat", UniformType.MATRIX4X4) + .withBlend(BlendFunction.ADDITIVE) + .withCull(false) + .withVertexFormat(DefaultVertexFormat.NEW_ENTITY, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline EYES = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/eyes") + .withVertexShader("core/entity") + .withFragmentShader("core/entity") + .withShaderDefine("EMISSIVE") + .withShaderDefine("NO_OVERLAY") + .withShaderDefine("NO_CARDINAL_LIGHTING") + .withSampler("Sampler0") + .withBlend(BlendFunction.TRANSLUCENT) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.NEW_ENTITY, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline ENTITY_DECAL = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_LIGHT_DIR_SNIPPET) + .withLocation("pipeline/entity_decal") + .withVertexShader("core/rendertype_entity_decal") + .withFragmentShader("core/rendertype_entity_decal") + .withSampler("Sampler0") + .withSampler("Sampler1") + .withSampler("Sampler2") + .withDepthTestFunction(DepthTestFunction.EQUAL_DEPTH_TEST) + .withCull(false) + .withVertexFormat(DefaultVertexFormat.NEW_ENTITY, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline ENTITY_SHADOW = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/entity_shadow") + .withVertexShader("core/rendertype_entity_shadow") + .withFragmentShader("core/rendertype_entity_shadow") + .withSampler("Sampler0") + .withBlend(BlendFunction.TRANSLUCENT) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.NEW_ENTITY, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline ITEM_ENTITY_TRANSLUCENT_CULL = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_LIGHT_DIR_SNIPPET) + .withLocation("pipeline/item_entity_translucent_cull") + .withVertexShader("core/rendertype_item_entity_translucent_cull") + .withFragmentShader("core/rendertype_item_entity_translucent_cull") + .withSampler("Sampler0") + .withSampler("Sampler2") + .withBlend(BlendFunction.TRANSLUCENT) + .withVertexFormat(DefaultVertexFormat.NEW_ENTITY, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline BEACON_BEAM_OPAQUE = register( + RenderPipeline.builder(BEACON_BEAM_SNIPPET).withLocation("pipeline/beacon_beam_opaque").build() + ); + public static final RenderPipeline BEACON_BEAM_TRANSLUCENT = register( + RenderPipeline.builder(BEACON_BEAM_SNIPPET) + .withLocation("pipeline/beacon_beam_translucent") + .withDepthWrite(false) + .withBlend(BlendFunction.TRANSLUCENT) + .build() + ); + public static final RenderPipeline DRAGON_EXPLOSION_ALPHA = register( + RenderPipeline.builder(MATRICES_SNIPPET) + .withLocation("pipeline/dragon_explosion_alpha") + .withVertexShader("core/rendertype_entity_alpha") + .withFragmentShader("core/rendertype_entity_alpha") + .withSampler("Sampler0") + .withCull(false) + .withVertexFormat(DefaultVertexFormat.NEW_ENTITY, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline LEASH = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/leash") + .withVertexShader("core/rendertype_leash") + .withFragmentShader("core/rendertype_leash") + .withSampler("Sampler2") + .withCull(false) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR_LIGHTMAP, VertexFormat.Mode.TRIANGLE_STRIP) + .build() + ); + public static final RenderPipeline WATER_MASK = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/water_mask") + .withVertexShader("core/rendertype_water_mask") + .withFragmentShader("core/rendertype_water_mask") + .withColorWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline GLINT = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET, FOG_NO_COLOR_SNIPPET) + .withLocation("pipeline/glint") + .withVertexShader("core/glint") + .withFragmentShader("core/glint") + .withSampler("Sampler0") + .withUniform("TextureMat", UniformType.MATRIX4X4) + .withUniform("GlintAlpha", UniformType.FLOAT) + .withDepthWrite(false) + .withCull(false) + .withDepthTestFunction(DepthTestFunction.EQUAL_DEPTH_TEST) + .withBlend(BlendFunction.GLINT) + .withVertexFormat(DefaultVertexFormat.POSITION_TEX, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline CRUMBLING = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/crumbling") + .withVertexShader("core/rendertype_crumbling") + .withFragmentShader("core/rendertype_crumbling") + .withSampler("Sampler0") + .withBlend(new BlendFunction(SourceFactor.DST_COLOR, DestFactor.SRC_COLOR, SourceFactor.ONE, DestFactor.ZERO)) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.BLOCK, VertexFormat.Mode.QUADS) + .withDepthBias(-1.0F, -10.0F) + .build() + ); + public static final RenderPipeline TEXT = register( + RenderPipeline.builder(TEXT_SNIPPET, FOG_SNIPPET) + .withLocation("pipeline/text") + .withVertexShader("core/rendertype_text") + .withFragmentShader("core/rendertype_text") + .withSampler("Sampler0") + .withSampler("Sampler2") + .build() + ); + public static final RenderPipeline TEXT_BACKGROUND = register( + RenderPipeline.builder(TEXT_SNIPPET, FOG_SNIPPET) + .withLocation("pipeline/text_background") + .withVertexShader("core/rendertype_text_background") + .withFragmentShader("core/rendertype_text_background") + .withSampler("Sampler2") + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR_LIGHTMAP, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline TEXT_INTENSITY = register( + RenderPipeline.builder(TEXT_SNIPPET, FOG_SNIPPET) + .withLocation("pipeline/text_intensity") + .withVertexShader("core/rendertype_text_intensity") + .withFragmentShader("core/rendertype_text_intensity") + .withSampler("Sampler0") + .withSampler("Sampler2") + .withDepthBias(-1.0F, -10.0F) + .build() + ); + public static final RenderPipeline TEXT_POLYGON_OFFSET = register( + RenderPipeline.builder(TEXT_SNIPPET, FOG_SNIPPET) + .withLocation("pipeline/text_polygon_offset") + .withVertexShader("core/rendertype_text") + .withFragmentShader("core/rendertype_text") + .withSampler("Sampler0") + .withSampler("Sampler2") + .withDepthBias(-1.0F, -10.0F) + .build() + ); + public static final RenderPipeline TEXT_SEE_THROUGH = register( + RenderPipeline.builder(TEXT_SNIPPET) + .withLocation("pipeline/text_see_through") + .withVertexShader("core/rendertype_text_see_through") + .withFragmentShader("core/rendertype_text_see_through") + .withSampler("Sampler0") + .withDepthWrite(false) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .build() + ); + public static final RenderPipeline TEXT_BACKGROUND_SEE_THROUGH = register( + RenderPipeline.builder(TEXT_SNIPPET) + .withLocation("pipeline/text_background_see_through") + .withVertexShader("core/rendertype_text_background_see_through") + .withFragmentShader("core/rendertype_text_background_see_through") + .withDepthWrite(false) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR_LIGHTMAP, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline TEXT_INTENSITY_SEE_THROUGH = register( + RenderPipeline.builder(TEXT_SNIPPET) + .withLocation("pipeline/text_intensity_see_through") + .withVertexShader("core/rendertype_text_intensity_see_through") + .withFragmentShader("core/rendertype_text_intensity_see_through") + .withSampler("Sampler0") + .withDepthWrite(false) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .build() + ); + public static final RenderPipeline LIGHTNING = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/lightning") + .withVertexShader("core/rendertype_lightning") + .withFragmentShader("core/rendertype_lightning") + .withBlend(BlendFunction.LIGHTNING) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline DRAGON_RAYS = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/dragon_rays") + .withVertexShader("core/rendertype_lightning") + .withFragmentShader("core/rendertype_lightning") + .withDepthWrite(false) + .withBlend(BlendFunction.LIGHTNING) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.TRIANGLES) + .build() + ); + public static final RenderPipeline DRAGON_RAYS_DEPTH = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/dragon_rays_depth") + .withVertexShader("core/position") + .withFragmentShader("core/position") + .withColorWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.TRIANGLES) + .build() + ); + public static final RenderPipeline END_PORTAL = register( + RenderPipeline.builder(END_PORTAL_SNIPPET).withLocation("pipeline/end_portal").withShaderDefine("PORTAL_LAYERS", 15).build() + ); + public static final RenderPipeline END_GATEWAY = register( + RenderPipeline.builder(END_PORTAL_SNIPPET).withLocation("pipeline/end_gateway").withShaderDefine("PORTAL_LAYERS", 16).build() + ); + public static final RenderPipeline FLAT_CLOUDS = register(RenderPipeline.builder(CLOUDS_SNIPPET).withLocation("pipeline/flat_clouds").withCull(false).build()); + public static final RenderPipeline CLOUDS = register(RenderPipeline.builder(CLOUDS_SNIPPET).withLocation("pipeline/clouds").build()); + public static final RenderPipeline CLOUDS_DEPTH_ONLY = register( + RenderPipeline.builder(CLOUDS_SNIPPET).withLocation("pipeline/clouds_depth_only").withColorWrite(false).build() + ); + public static final RenderPipeline LINES = register(RenderPipeline.builder(LINES_SNIPPET).withLocation("pipeline/lines").build()); + public static final RenderPipeline SECONDARY_BLOCK_OUTLINE = register( + RenderPipeline.builder(LINES_SNIPPET).withLocation("pipeline/secondary_block_outline").withDepthWrite(false).build() + ); + public static final RenderPipeline LINE_STRIP = register( + RenderPipeline.builder(LINES_SNIPPET) + .withLocation("pipeline/line_strip") + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR_NORMAL, VertexFormat.Mode.LINE_STRIP) + .build() + ); + public static final RenderPipeline DEBUG_LINE_STRIP = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/debug_line_strip") + .withVertexShader("core/position_color") + .withFragmentShader("core/position_color") + .withCull(false) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.DEBUG_LINE_STRIP) + .build() + ); + public static final RenderPipeline DEBUG_FILLED_BOX = register( + RenderPipeline.builder(DEBUG_FILLED_SNIPPET) + .withLocation("pipeline/debug_filled_box") + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.TRIANGLE_STRIP) + .build() + ); + public static final RenderPipeline DEBUG_QUADS = register( + RenderPipeline.builder(DEBUG_FILLED_SNIPPET).withLocation("pipeline/debug_quads").withCull(false).build() + ); + public static final RenderPipeline DEBUG_TRIANGLE_FAN = register( + RenderPipeline.builder(DEBUG_FILLED_SNIPPET) + .withLocation("pipeline/debug_triangle_fan") + .withCull(false) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.TRIANGLE_FAN) + .build() + ); + public static final RenderPipeline DEBUG_STRUCTURE_QUADS = register( + RenderPipeline.builder(DEBUG_FILLED_SNIPPET).withLocation("pipeline/debug_structure_quads").withCull(false).withDepthWrite(false).build() + ); + public static final RenderPipeline DEBUG_SECTION_QUADS = register( + RenderPipeline.builder(DEBUG_FILLED_SNIPPET).withLocation("pipeline/debug_section_quads").build() + ); + public static final RenderPipeline WORLD_BORDER = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/world_border") + .withVertexShader("core/rendertype_world_border") + .withFragmentShader("core/rendertype_world_border") + .withSampler("Sampler0") + .withUniform("TextureMat", UniformType.MATRIX4X4) + .withUniform("ModelOffset", UniformType.VEC3) + .withBlend(BlendFunction.OVERLAY) + .withCull(false) + .withVertexFormat(DefaultVertexFormat.POSITION_TEX, VertexFormat.Mode.QUADS) + .withDepthBias(-3.0F, -3.0F) + .build() + ); + public static final RenderPipeline OPAQUE_PARTICLE = register(RenderPipeline.builder(PARTICLE_SNIPPET).withLocation("pipeline/opaque_particle").build()); + public static final RenderPipeline TRANSLUCENT_PARTICLE = register( + RenderPipeline.builder(PARTICLE_SNIPPET).withLocation("pipeline/translucent_particle").withBlend(BlendFunction.TRANSLUCENT).build() + ); + public static final RenderPipeline WEATHER_DEPTH_WRITE = register(RenderPipeline.builder(WEATHER_SNIPPET).withLocation("pipeline/weather_depth_write").build()); + public static final RenderPipeline WEATHER_NO_DEPTH_WRITE = register( + RenderPipeline.builder(WEATHER_SNIPPET).withLocation("pipeline/weather_no_depth_write").withDepthWrite(false).build() + ); + public static final RenderPipeline SKY = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/sky") + .withVertexShader("core/position") + .withFragmentShader("core/position") + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.TRIANGLE_FAN) + .build() + ); + public static final RenderPipeline END_SKY = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/end_sky") + .withVertexShader("core/position_tex_color") + .withFragmentShader("core/position_tex_color") + .withSampler("Sampler0") + .withBlend(BlendFunction.TRANSLUCENT) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION_TEX_COLOR, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline SUNRISE_SUNSET = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/sunrise_sunset") + .withVertexShader("core/position_color") + .withFragmentShader("core/position_color") + .withBlend(BlendFunction.TRANSLUCENT) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION_COLOR, VertexFormat.Mode.TRIANGLE_FAN) + .build() + ); + public static final RenderPipeline STARS = register( + RenderPipeline.builder(MATRICES_COLOR_FOG_SNIPPET) + .withLocation("pipeline/stars") + .withVertexShader("core/position") + .withFragmentShader("core/position") + .withBlend(BlendFunction.OVERLAY) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline CELESTIAL = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/celestial") + .withVertexShader("core/position_tex_color") + .withFragmentShader("core/position_tex_color") + .withSampler("Sampler0") + .withBlend(BlendFunction.OVERLAY) + .withDepthWrite(false) + .withVertexFormat(DefaultVertexFormat.POSITION_TEX_COLOR, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline GUI = register(RenderPipeline.builder(GUI_SNIPPET).withLocation("pipeline/gui").build()); + public static final RenderPipeline GUI_OVERLAY = register( + RenderPipeline.builder(GUI_SNIPPET).withLocation("pipeline/gui_overlay").withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST).withDepthWrite(false).build() + ); + public static final RenderPipeline GUI_TEXT_HIGHLIGHT = register( + RenderPipeline.builder(GUI_SNIPPET) + .withLocation("pipeline/gui_text_highlight") + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withColorLogic(LogicOp.OR_REVERSE) + .build() + ); + public static final RenderPipeline GUI_GHOST_RECIPE_OVERLAY = register( + RenderPipeline.builder(GUI_SNIPPET) + .withLocation("pipeline/gui_ghost_recipe_overlay") + .withDepthTestFunction(DepthTestFunction.GREATER_DEPTH_TEST) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline GUI_TEXTURED = register(RenderPipeline.builder(GUI_TEXTURED_SNIPPET).withLocation("pipeline/gui_textured").build()); + public static final RenderPipeline GUI_TEXTURED_OVERLAY = register( + RenderPipeline.builder(GUI_TEXTURED_SNIPPET) + .withLocation("pipeline/gui_textured_overlay") + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline BLOCK_SCREEN_EFFECT = register( + RenderPipeline.builder(GUI_TEXTURED_SNIPPET) + .withLocation("pipeline/block_screen_effect") + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline FIRE_SCREEN_EFFECT = register( + RenderPipeline.builder(GUI_TEXTURED_SNIPPET) + .withLocation("pipeline/fire_screen_effect") + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline GUI_OPAQUE_TEXTURED_BACKGROUND = register( + RenderPipeline.builder(GUI_TEXTURED_SNIPPET).withLocation("pipeline/gui_opaque_textured_background").withoutBlend().build() + ); + public static final RenderPipeline GUI_NAUSEA_OVERLAY = register( + RenderPipeline.builder(GUI_TEXTURED_SNIPPET) + .withLocation("pipeline/gui_nausea_overlay") + .withBlend(BlendFunction.ADDITIVE) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline VIGNETTE = register( + RenderPipeline.builder(GUI_TEXTURED_SNIPPET) + .withLocation("pipeline/vignette") + .withBlend(new BlendFunction(SourceFactor.ZERO, DestFactor.ONE_MINUS_SRC_COLOR)) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline CROSSHAIR = register( + RenderPipeline.builder(GUI_TEXTURED_SNIPPET) + .withLocation("pipeline/crosshair") + .withBlend(new BlendFunction(SourceFactor.ONE_MINUS_DST_COLOR, DestFactor.ONE_MINUS_SRC_COLOR, SourceFactor.ONE, DestFactor.ZERO)) + .build() + ); + public static final RenderPipeline MOJANG_LOGO = register( + RenderPipeline.builder(GUI_TEXTURED_SNIPPET) + .withLocation("pipeline/mojang_logo") + .withBlend(new BlendFunction(SourceFactor.SRC_ALPHA, DestFactor.ONE)) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withDepthWrite(false) + .build() + ); + public static final RenderPipeline ENTITY_OUTLINE_BLIT = register( + RenderPipeline.builder() + .withLocation("pipeline/entity_outline_blit") + .withVertexShader("core/blit_screen") + .withFragmentShader("core/blit_screen") + .withSampler("InSampler") + .withBlend(BlendFunction.ENTITY_OUTLINE_BLIT) + .withDepthWrite(false) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withColorWrite(true, false) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline TRACY_BLIT = register( + RenderPipeline.builder() + .withLocation("pipeline/tracy_blit") + .withVertexShader("core/blit_screen") + .withFragmentShader("core/blit_screen") + .withSampler("InSampler") + .withDepthWrite(false) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline PANORAMA = register( + RenderPipeline.builder(MATRICES_COLOR_SNIPPET) + .withLocation("pipeline/panorama") + .withVertexShader("core/position_tex") + .withFragmentShader("core/position_tex") + .withSampler("Sampler0") + .withDepthWrite(false) + .withColorWrite(true, false) + .withBlend(BlendFunction.PANORAMA) + .withVertexFormat(DefaultVertexFormat.POSITION_TEX, VertexFormat.Mode.QUADS) + .build() + ); + public static final RenderPipeline OUTLINE_CULL = register(RenderPipeline.builder(OUTLINE_SNIPPET).withLocation("pipeline/outline_cull").build()); + public static final RenderPipeline OUTLINE_NO_CULL = register( + RenderPipeline.builder(OUTLINE_SNIPPET).withLocation("pipeline/outline_no_cull").withCull(false).build() + ); + public static final RenderPipeline LIGHTMAP = register( + RenderPipeline.builder() + .withLocation("pipeline/lightmap") + .withVertexShader("core/blit_screen") + .withFragmentShader("core/lightmap") + .withUniform("AmbientLightFactor", UniformType.FLOAT) + .withUniform("SkyFactor", UniformType.FLOAT) + .withUniform("BlockFactor", UniformType.FLOAT) + .withUniform("UseBrightLightmap", UniformType.INT) + .withUniform("SkyLightColor", UniformType.VEC3) + .withUniform("NightVisionFactor", UniformType.FLOAT) + .withUniform("DarknessScale", UniformType.FLOAT) + .withUniform("DarkenWorldFactor", UniformType.FLOAT) + .withUniform("BrightnessFactor", UniformType.FLOAT) + .withVertexFormat(DefaultVertexFormat.POSITION, VertexFormat.Mode.QUADS) + .withDepthWrite(false) + .withDepthTestFunction(DepthTestFunction.NO_DEPTH_TEST) + .build() + ); + + private static RenderPipeline register(RenderPipeline pipeline) { + PIPELINES_BY_LOCATION.put(pipeline.getLocation(), pipeline); + return pipeline; + } + + public static List getStaticPipelines() { + return PIPELINES_BY_LOCATION.values().stream().toList(); + } +} diff --git a/net/minecraft/client/renderer/RenderStateShard.java b/net/minecraft/client/renderer/RenderStateShard.java index fc4a5d1e..3db33c64 100644 --- a/net/minecraft/client/renderer/RenderStateShard.java +++ b/net/minecraft/client/renderer/RenderStateShard.java @@ -1,14 +1,12 @@ package net.minecraft.client.renderer; import com.mojang.blaze3d.pipeline.RenderTarget; -import com.mojang.blaze3d.platform.GlStateManager.DestFactor; -import com.mojang.blaze3d.platform.GlStateManager.LogicOp; -import com.mojang.blaze3d.platform.GlStateManager.SourceFactor; import com.mojang.blaze3d.systems.RenderSystem; import java.util.List; import java.util.Objects; import java.util.Optional; import java.util.OptionalDouble; +import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.Util; @@ -29,224 +27,6 @@ public abstract class RenderStateShard { protected final String name; private final Runnable setupState; private final Runnable clearState; - protected static final RenderStateShard.TransparencyStateShard NO_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "no_transparency", () -> RenderSystem.disableBlend(), () -> {} - ); - protected static final RenderStateShard.TransparencyStateShard ADDITIVE_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "additive_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFunc(SourceFactor.ONE, DestFactor.ONE); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.TransparencyStateShard LIGHTNING_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "lightning_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFunc(SourceFactor.SRC_ALPHA, DestFactor.ONE); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.TransparencyStateShard GLINT_TRANSPARENCY = new RenderStateShard.TransparencyStateShard("glint_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFuncSeparate(SourceFactor.SRC_COLOR, DestFactor.ONE, SourceFactor.ZERO, DestFactor.ONE); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - }); - protected static final RenderStateShard.TransparencyStateShard CRUMBLING_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "crumbling_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFuncSeparate(SourceFactor.DST_COLOR, DestFactor.SRC_COLOR, SourceFactor.ONE, DestFactor.ZERO); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.TransparencyStateShard OVERLAY_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "overlay_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFuncSeparate(SourceFactor.SRC_ALPHA, DestFactor.ONE, SourceFactor.ONE, DestFactor.ZERO); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.TransparencyStateShard TRANSLUCENT_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "translucent_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFuncSeparate(SourceFactor.SRC_ALPHA, DestFactor.ONE_MINUS_SRC_ALPHA, SourceFactor.ONE, DestFactor.ONE_MINUS_SRC_ALPHA); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.TransparencyStateShard VIGNETTE_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "vignette_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFunc(SourceFactor.ZERO, DestFactor.ONE_MINUS_SRC_COLOR); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.TransparencyStateShard CROSSHAIR_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "crosshair_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFuncSeparate(SourceFactor.ONE_MINUS_DST_COLOR, DestFactor.ONE_MINUS_SRC_COLOR, SourceFactor.ONE, DestFactor.ZERO); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.TransparencyStateShard MOJANG_LOGO_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "mojang_logo_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFunc(770, 1); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.TransparencyStateShard NAUSEA_OVERLAY_TRANSPARENCY = new RenderStateShard.TransparencyStateShard( - "nausea_overlay_transparency", () -> { - RenderSystem.enableBlend(); - RenderSystem.blendFuncSeparate(SourceFactor.ONE, DestFactor.ONE, SourceFactor.ONE, DestFactor.ONE); - }, () -> { - RenderSystem.disableBlend(); - RenderSystem.defaultBlendFunc(); - } - ); - protected static final RenderStateShard.ShaderStateShard NO_SHADER = new RenderStateShard.ShaderStateShard(); - protected static final RenderStateShard.ShaderStateShard POSITION_COLOR_LIGHTMAP_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.POSITION_COLOR_LIGHTMAP - ); - protected static final RenderStateShard.ShaderStateShard POSITION_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.POSITION); - protected static final RenderStateShard.ShaderStateShard POSITION_TEX_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.POSITION_TEX); - protected static final RenderStateShard.ShaderStateShard POSITION_COLOR_TEX_LIGHTMAP_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.POSITION_COLOR_TEX_LIGHTMAP - ); - protected static final RenderStateShard.ShaderStateShard POSITION_COLOR_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.POSITION_COLOR); - protected static final RenderStateShard.ShaderStateShard POSITION_TEXTURE_COLOR_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.POSITION_TEX_COLOR); - protected static final RenderStateShard.ShaderStateShard PARTICLE_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.PARTICLE); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_SOLID_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_SOLID); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_CUTOUT_MIPPED_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_CUTOUT_MIPPED - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_CUTOUT_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_CUTOUT); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TRANSLUCENT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_TRANSLUCENT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TRANSLUCENT_MOVING_BLOCK_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_TRANSLUCENT_MOVING_BLOCK - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ARMOR_CUTOUT_NO_CULL_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ARMOR_CUTOUT_NO_CULL - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ARMOR_TRANSLUCENT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ARMOR_TRANSLUCENT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_SOLID_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_SOLID - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_CUTOUT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_CUTOUT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_CUTOUT_NO_CULL_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_CUTOUT_NO_CULL - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_CUTOUT_NO_CULL_Z_OFFSET_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_CUTOUT_NO_CULL_Z_OFFSET - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ITEM_ENTITY_TRANSLUCENT_CULL_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ITEM_ENTITY_TRANSLUCENT_CULL - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_TRANSLUCENT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_TRANSLUCENT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_TRANSLUCENT_EMISSIVE_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_TRANSLUCENT_EMISSIVE - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_SMOOTH_CUTOUT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_SMOOTH_CUTOUT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_BEACON_BEAM_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_BEACON_BEAM - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_DECAL_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_DECAL - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_NO_OUTLINE_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_NO_OUTLINE - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_SHADOW_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_SHADOW - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_ALPHA_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_ALPHA - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_EYES_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_EYES); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENERGY_SWIRL_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENERGY_SWIRL - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_LEASH_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_LEASH); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_WATER_MASK_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_WATER_MASK - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_OUTLINE_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_OUTLINE); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ARMOR_ENTITY_GLINT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ARMOR_ENTITY_GLINT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_GLINT_TRANSLUCENT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_GLINT_TRANSLUCENT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_GLINT_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_GLINT); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_ENTITY_GLINT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_ENTITY_GLINT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_CRUMBLING_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_CRUMBLING); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TEXT_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_TEXT); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TEXT_BACKGROUND_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_TEXT_BACKGROUND - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TEXT_INTENSITY_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_TEXT_INTENSITY - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TEXT_SEE_THROUGH_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_TEXT_SEE_THROUGH - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TEXT_BACKGROUND_SEE_THROUGH_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_TEXT_BACKGROUND_SEE_THROUGH - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TEXT_INTENSITY_SEE_THROUGH_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_TEXT_INTENSITY_SEE_THROUGH - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_LIGHTNING_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_LIGHTNING); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_TRIPWIRE_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_TRIPWIRE); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_END_PORTAL_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_END_PORTAL - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_END_GATEWAY_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_END_GATEWAY - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_CLOUDS_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_CLOUDS); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_LINES_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_LINES); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_GUI_SHADER = new RenderStateShard.ShaderStateShard(CoreShaders.RENDERTYPE_GUI); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_GUI_OVERLAY_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_GUI_OVERLAY - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_GUI_TEXT_HIGHLIGHT_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_GUI_TEXT_HIGHLIGHT - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_GUI_GHOST_RECIPE_OVERLAY_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_GUI_GHOST_RECIPE_OVERLAY - ); - protected static final RenderStateShard.ShaderStateShard RENDERTYPE_BREEZE_WIND_SHADER = new RenderStateShard.ShaderStateShard( - CoreShaders.RENDERTYPE_BREEZE_WIND - ); protected static final RenderStateShard.TextureStateShard BLOCK_SHEET_MIPPED = new RenderStateShard.TextureStateShard( TextureAtlas.LOCATION_BLOCKS, TriState.FALSE, true ); @@ -258,34 +38,19 @@ public abstract class RenderStateShard { "default_texturing", () -> {}, () -> {} ); protected static final RenderStateShard.TexturingStateShard GLINT_TEXTURING = new RenderStateShard.TexturingStateShard( - "glint_texturing", () -> setupGlintTexturing(8.0F), () -> RenderSystem.resetTextureMatrix() + "glint_texturing", () -> setupGlintTexturing(8.0F), RenderSystem::resetTextureMatrix ); protected static final RenderStateShard.TexturingStateShard ENTITY_GLINT_TEXTURING = new RenderStateShard.TexturingStateShard( - "entity_glint_texturing", () -> setupGlintTexturing(0.16F), () -> RenderSystem.resetTextureMatrix() + "entity_glint_texturing", () -> setupGlintTexturing(0.5F), RenderSystem::resetTextureMatrix + ); + protected static final RenderStateShard.TexturingStateShard ARMOR_ENTITY_GLINT_TEXTURING = new RenderStateShard.TexturingStateShard( + "armor_entity_glint_texturing", () -> setupGlintTexturing(0.16F), RenderSystem::resetTextureMatrix ); protected static final RenderStateShard.LightmapStateShard LIGHTMAP = new RenderStateShard.LightmapStateShard(true); protected static final RenderStateShard.LightmapStateShard NO_LIGHTMAP = new RenderStateShard.LightmapStateShard(false); protected static final RenderStateShard.OverlayStateShard OVERLAY = new RenderStateShard.OverlayStateShard(true); protected static final RenderStateShard.OverlayStateShard NO_OVERLAY = new RenderStateShard.OverlayStateShard(false); - protected static final RenderStateShard.CullStateShard CULL = new RenderStateShard.CullStateShard(true); - protected static final RenderStateShard.CullStateShard NO_CULL = new RenderStateShard.CullStateShard(false); - protected static final RenderStateShard.DepthTestStateShard NO_DEPTH_TEST = new RenderStateShard.DepthTestStateShard("always", 519); - protected static final RenderStateShard.DepthTestStateShard EQUAL_DEPTH_TEST = new RenderStateShard.DepthTestStateShard("==", 514); - protected static final RenderStateShard.DepthTestStateShard LEQUAL_DEPTH_TEST = new RenderStateShard.DepthTestStateShard("<=", 515); - protected static final RenderStateShard.DepthTestStateShard GREATER_DEPTH_TEST = new RenderStateShard.DepthTestStateShard(">", 516); - protected static final RenderStateShard.WriteMaskStateShard COLOR_DEPTH_WRITE = new RenderStateShard.WriteMaskStateShard(true, true); - protected static final RenderStateShard.WriteMaskStateShard COLOR_WRITE = new RenderStateShard.WriteMaskStateShard(true, false); - protected static final RenderStateShard.WriteMaskStateShard DEPTH_WRITE = new RenderStateShard.WriteMaskStateShard(false, true); protected static final RenderStateShard.LayeringStateShard NO_LAYERING = new RenderStateShard.LayeringStateShard("no_layering", () -> {}, () -> {}); - protected static final RenderStateShard.LayeringStateShard POLYGON_OFFSET_LAYERING = new RenderStateShard.LayeringStateShard( - "polygon_offset_layering", () -> { - RenderSystem.polygonOffset(-1.0F, -10.0F); - RenderSystem.enablePolygonOffset(); - }, () -> { - RenderSystem.polygonOffset(0.0F, 0.0F); - RenderSystem.disablePolygonOffset(); - } - ); protected static final RenderStateShard.LayeringStateShard VIEW_OFFSET_Z_LAYERING = new RenderStateShard.LayeringStateShard("view_offset_z_layering", () -> { Matrix4fStack matrix4fStack = RenderSystem.getModelViewStack(); matrix4fStack.pushMatrix(); @@ -304,72 +69,30 @@ public abstract class RenderStateShard { matrix4fStack.popMatrix(); } ); - protected static final RenderStateShard.LayeringStateShard WORLD_BORDER_LAYERING = new RenderStateShard.LayeringStateShard("world_border_layering", () -> { - RenderSystem.polygonOffset(-3.0F, -3.0F); - RenderSystem.enablePolygonOffset(); - }, () -> { - RenderSystem.polygonOffset(0.0F, 0.0F); - RenderSystem.disablePolygonOffset(); - }); protected static final RenderStateShard.OutputStateShard MAIN_TARGET = new RenderStateShard.OutputStateShard( - "main_target", () -> Minecraft.getInstance().getMainRenderTarget().bindWrite(false), () -> {} + "main_target", () -> Minecraft.getInstance().getMainRenderTarget() ); protected static final RenderStateShard.OutputStateShard OUTLINE_TARGET = new RenderStateShard.OutputStateShard("outline_target", () -> { RenderTarget renderTarget = Minecraft.getInstance().levelRenderer.entityOutlineTarget(); - if (renderTarget != null) { - renderTarget.bindWrite(false); - } else { - Minecraft.getInstance().getMainRenderTarget().bindWrite(false); - } - }, () -> Minecraft.getInstance().getMainRenderTarget().bindWrite(false)); + return renderTarget != null ? renderTarget : Minecraft.getInstance().getMainRenderTarget(); + }); protected static final RenderStateShard.OutputStateShard TRANSLUCENT_TARGET = new RenderStateShard.OutputStateShard("translucent_target", () -> { RenderTarget renderTarget = Minecraft.getInstance().levelRenderer.getTranslucentTarget(); - if (renderTarget != null) { - renderTarget.bindWrite(false); - } else { - Minecraft.getInstance().getMainRenderTarget().bindWrite(false); - } - }, () -> Minecraft.getInstance().getMainRenderTarget().bindWrite(false)); + return renderTarget != null ? renderTarget : Minecraft.getInstance().getMainRenderTarget(); + }); protected static final RenderStateShard.OutputStateShard PARTICLES_TARGET = new RenderStateShard.OutputStateShard("particles_target", () -> { RenderTarget renderTarget = Minecraft.getInstance().levelRenderer.getParticlesTarget(); - if (renderTarget != null) { - renderTarget.bindWrite(false); - } else { - Minecraft.getInstance().getMainRenderTarget().bindWrite(false); - } - }, () -> Minecraft.getInstance().getMainRenderTarget().bindWrite(false)); + return renderTarget != null ? renderTarget : Minecraft.getInstance().getMainRenderTarget(); + }); protected static final RenderStateShard.OutputStateShard WEATHER_TARGET = new RenderStateShard.OutputStateShard("weather_target", () -> { RenderTarget renderTarget = Minecraft.getInstance().levelRenderer.getWeatherTarget(); - if (renderTarget != null) { - renderTarget.bindWrite(false); - } else { - Minecraft.getInstance().getMainRenderTarget().bindWrite(false); - } - }, () -> Minecraft.getInstance().getMainRenderTarget().bindWrite(false)); - protected static final RenderStateShard.OutputStateShard CLOUDS_TARGET = new RenderStateShard.OutputStateShard("clouds_target", () -> { - RenderTarget renderTarget = Minecraft.getInstance().levelRenderer.getCloudsTarget(); - if (renderTarget != null) { - renderTarget.bindWrite(false); - } else { - Minecraft.getInstance().getMainRenderTarget().bindWrite(false); - } - }, () -> Minecraft.getInstance().getMainRenderTarget().bindWrite(false)); + return renderTarget != null ? renderTarget : Minecraft.getInstance().getMainRenderTarget(); + }); protected static final RenderStateShard.OutputStateShard ITEM_ENTITY_TARGET = new RenderStateShard.OutputStateShard("item_entity_target", () -> { RenderTarget renderTarget = Minecraft.getInstance().levelRenderer.getItemEntityTarget(); - if (renderTarget != null) { - renderTarget.bindWrite(false); - } else { - Minecraft.getInstance().getMainRenderTarget().bindWrite(false); - } - }, () -> Minecraft.getInstance().getMainRenderTarget().bindWrite(false)); + return renderTarget != null ? renderTarget : Minecraft.getInstance().getMainRenderTarget(); + }); protected static final RenderStateShard.LineStateShard DEFAULT_LINE = new RenderStateShard.LineStateShard(OptionalDouble.of(1.0)); - protected static final RenderStateShard.ColorLogicStateShard NO_COLOR_LOGIC = new RenderStateShard.ColorLogicStateShard( - "no_color_logic", () -> RenderSystem.disableColorLogicOp(), () -> {} - ); - protected static final RenderStateShard.ColorLogicStateShard OR_REVERSE_COLOR_LOGIC = new RenderStateShard.ColorLogicStateShard("or_reverse", () -> { - RenderSystem.enableColorLogicOp(); - RenderSystem.logicOp(LogicOp.OR_REVERSE); - }, () -> RenderSystem.disableColorLogicOp()); public RenderStateShard(String name, Runnable setupState, Runnable clearState) { this.name = name; @@ -389,6 +112,10 @@ public abstract class RenderStateShard { return this.name; } + public String getName() { + return this.name; + } + private static void setupGlintTexturing(float scale) { long l = (long)(Util.getMillis() * Minecraft.getInstance().options.glintSpeed().get() * 8.0); float f = (float)(l % 110000L) / 110000.0F; @@ -413,53 +140,6 @@ public abstract class RenderStateShard { } } - @Environment(EnvType.CLIENT) - protected static class ColorLogicStateShard extends RenderStateShard { - public ColorLogicStateShard(String string, Runnable runnable, Runnable runnable2) { - super(string, runnable, runnable2); - } - } - - @Environment(EnvType.CLIENT) - protected static class CullStateShard extends RenderStateShard.BooleanStateShard { - public CullStateShard(boolean useCull) { - super("cull", () -> { - if (!useCull) { - RenderSystem.disableCull(); - } - }, () -> { - if (!useCull) { - RenderSystem.enableCull(); - } - }, useCull); - } - } - - @Environment(EnvType.CLIENT) - protected static class DepthTestStateShard extends RenderStateShard { - private final String functionName; - - public DepthTestStateShard(String functionName, int depthFunc) { - super("depth_test", () -> { - if (depthFunc != 519) { - RenderSystem.enableDepthTest(); - RenderSystem.depthFunc(depthFunc); - } - }, () -> { - if (depthFunc != 519) { - RenderSystem.disableDepthTest(); - RenderSystem.depthFunc(515); - } - }); - this.functionName = functionName; - } - - @Override - public String toString() { - return this.name + "[" + this.functionName + "]"; - } - } - @Environment(EnvType.CLIENT) protected static class EmptyTextureStateShard extends RenderStateShard { public EmptyTextureStateShard(Runnable setupState, Runnable clearState) { @@ -535,7 +215,7 @@ public abstract class RenderStateShard { TextureManager textureManager = Minecraft.getInstance().getTextureManager(); AbstractTexture abstractTexture = textureManager.getTexture(entry.id); abstractTexture.setFilter(entry.blur, entry.mipmap); - RenderSystem.setShaderTexture(i, abstractTexture.getId()); + RenderSystem.setShaderTexture(i, abstractTexture.getTexture()); } }, () -> {}); this.cutoutTexture = entries.isEmpty() ? Optional.empty() : Optional.of(((Entry)entries.getFirst()).id); @@ -560,8 +240,15 @@ public abstract class RenderStateShard { @Environment(EnvType.CLIENT) protected static class OutputStateShard extends RenderStateShard { - public OutputStateShard(String string, Runnable runnable, Runnable runnable2) { - super(string, runnable, runnable2); + private final Supplier renderTargetSupplier; + + public OutputStateShard(String name, Supplier renderTargetSupplier) { + super(name, () -> {}, () -> {}); + this.renderTargetSupplier = renderTargetSupplier; + } + + public RenderTarget getRenderTarget() { + return (RenderTarget)this.renderTargetSupplier.get(); } } @@ -580,26 +267,6 @@ public abstract class RenderStateShard { } } - @Environment(EnvType.CLIENT) - protected static class ShaderStateShard extends RenderStateShard { - private final Optional shader; - - public ShaderStateShard(ShaderProgram shader) { - super("shader", () -> RenderSystem.setShader(shader), () -> {}); - this.shader = Optional.of(shader); - } - - public ShaderStateShard() { - super("shader", RenderSystem::clearShader, () -> {}); - this.shader = Optional.empty(); - } - - @Override - public String toString() { - return this.name + "[" + this.shader + "]"; - } - } - @Environment(EnvType.CLIENT) protected static class TextureStateShard extends RenderStateShard.EmptyTextureStateShard { private final Optional texture; @@ -611,7 +278,7 @@ public abstract class RenderStateShard { TextureManager textureManager = Minecraft.getInstance().getTextureManager(); AbstractTexture abstractTexture = textureManager.getTexture(texture); abstractTexture.setFilter(blur, mipmap); - RenderSystem.setShaderTexture(0, abstractTexture.getId()); + RenderSystem.setShaderTexture(0, abstractTexture.getTexture()); }, () -> {}); this.texture = Optional.of(texture); this.blur = blur; @@ -635,44 +302,4 @@ public abstract class RenderStateShard { super(string, runnable, runnable2); } } - - @Environment(EnvType.CLIENT) - protected static class TransparencyStateShard extends RenderStateShard { - public TransparencyStateShard(String string, Runnable runnable, Runnable runnable2) { - super(string, runnable, runnable2); - } - } - - @Environment(EnvType.CLIENT) - protected static class WriteMaskStateShard extends RenderStateShard { - private final boolean writeColor; - private final boolean writeDepth; - - public WriteMaskStateShard(boolean writeColor, boolean writeDepth) { - super("write_mask_state", () -> { - if (!writeDepth) { - RenderSystem.depthMask(writeDepth); - } - - if (!writeColor) { - RenderSystem.colorMask(writeColor, writeColor, writeColor, writeColor); - } - }, () -> { - if (!writeDepth) { - RenderSystem.depthMask(true); - } - - if (!writeColor) { - RenderSystem.colorMask(true, true, true, true); - } - }); - this.writeColor = writeColor; - this.writeDepth = writeDepth; - } - - @Override - public String toString() { - return this.name + "[writeColor=" + this.writeColor + ", writeDepth=" + this.writeDepth + "]"; - } - } } diff --git a/net/minecraft/client/renderer/RenderType.java b/net/minecraft/client/renderer/RenderType.java index 7fec919a..ad48c1d6 100644 --- a/net/minecraft/client/renderer/RenderType.java +++ b/net/minecraft/client/renderer/RenderType.java @@ -1,14 +1,18 @@ package net.minecraft.client.renderer; import com.google.common.collect.ImmutableList; -import com.mojang.blaze3d.vertex.BufferUploader; -import com.mojang.blaze3d.vertex.DefaultVertexFormat; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.pipeline.RenderTarget; +import com.mojang.blaze3d.systems.RenderPass; +import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.blaze3d.vertex.MeshData; import com.mojang.blaze3d.vertex.VertexFormat; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; import java.util.List; import java.util.Optional; import java.util.OptionalDouble; +import java.util.OptionalInt; import java.util.function.BiFunction; import java.util.function.Function; import net.fabricmc.api.EnvType; @@ -30,346 +34,262 @@ public abstract class RenderType extends RenderStateShard { public static final int TRANSIENT_BUFFER_SIZE = 1536; private static final RenderType SOLID = create( "solid", - DefaultVertexFormat.BLOCK, - Mode.QUADS, 4194304, true, false, - RenderType.CompositeState.builder() - .setLightmapState(LIGHTMAP) - .setShaderState(RENDERTYPE_SOLID_SHADER) - .setTextureState(BLOCK_SHEET_MIPPED) - .createCompositeState(true) + RenderPipelines.SOLID, + RenderType.CompositeState.builder().setLightmapState(LIGHTMAP).setTextureState(BLOCK_SHEET_MIPPED).createCompositeState(true) ); private static final RenderType CUTOUT_MIPPED = create( "cutout_mipped", - DefaultVertexFormat.BLOCK, - Mode.QUADS, 4194304, true, false, - RenderType.CompositeState.builder() - .setLightmapState(LIGHTMAP) - .setShaderState(RENDERTYPE_CUTOUT_MIPPED_SHADER) - .setTextureState(BLOCK_SHEET_MIPPED) - .createCompositeState(true) + RenderPipelines.CUTOUT_MIPPED, + RenderType.CompositeState.builder().setLightmapState(LIGHTMAP).setTextureState(BLOCK_SHEET_MIPPED).createCompositeState(true) ); private static final RenderType CUTOUT = create( "cutout", - DefaultVertexFormat.BLOCK, - Mode.QUADS, 786432, true, false, - RenderType.CompositeState.builder() - .setLightmapState(LIGHTMAP) - .setShaderState(RENDERTYPE_CUTOUT_SHADER) - .setTextureState(BLOCK_SHEET) - .createCompositeState(true) + RenderPipelines.CUTOUT, + RenderType.CompositeState.builder().setLightmapState(LIGHTMAP).setTextureState(BLOCK_SHEET).createCompositeState(true) ); private static final RenderType TRANSLUCENT = create( - "translucent", DefaultVertexFormat.BLOCK, Mode.QUADS, 786432, true, true, translucentState(RENDERTYPE_TRANSLUCENT_SHADER) + "translucent", + 786432, + true, + true, + RenderPipelines.TRANSLUCENT, + RenderType.CompositeState.builder() + .setLightmapState(LIGHTMAP) + .setTextureState(BLOCK_SHEET_MIPPED) + .setOutputState(TRANSLUCENT_TARGET) + .createCompositeState(true) ); private static final RenderType TRANSLUCENT_MOVING_BLOCK = create( - "translucent_moving_block", DefaultVertexFormat.BLOCK, Mode.QUADS, 786432, false, true, translucentMovingBlockState() + "translucent_moving_block", + 786432, + false, + true, + RenderPipelines.TRANSLUCENT_MOVING_BLOCK, + RenderType.CompositeState.builder() + .setLightmapState(LIGHTMAP) + .setTextureState(BLOCK_SHEET_MIPPED) + .setOutputState(ITEM_ENTITY_TARGET) + .createCompositeState(true) ); private static final Function ARMOR_CUTOUT_NO_CULL = Util.memoize( - (Function)(resourceLocation -> createArmorCutoutNoCull("armor_cutout_no_cull", resourceLocation, false)) - ); - private static final Function ARMOR_TRANSLUCENT = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ARMOR_TRANSLUCENT_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .setLayeringState(VIEW_OFFSET_Z_LAYERING) .createCompositeState(true); - return create("armor_translucent", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, true, compositeState); + return create("armor_cutout_no_cull", 1536, true, false, RenderPipelines.ARMOR_CUTOUT_NO_CULL, compositeState); + }) + ); + private static final Function ARMOR_TRANSLUCENT = Util.memoize( + (Function)(resourceLocation -> { + RenderType.CompositeState compositeState = RenderType.CompositeState.builder() + .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) + .setLightmapState(LIGHTMAP) + .setOverlayState(OVERLAY) + .setLayeringState(VIEW_OFFSET_Z_LAYERING) + .createCompositeState(true); + return create("armor_translucent", 1536, true, true, RenderPipelines.ARMOR_TRANSLUCENT, compositeState); }) ); private static final Function ENTITY_SOLID = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_SOLID_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(NO_TRANSPARENCY) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .createCompositeState(true); - return create("entity_solid", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, false, compositeState); + return create("entity_solid", 1536, true, false, RenderPipelines.ENTITY_SOLID, compositeState); }) ); private static final Function ENTITY_SOLID_Z_OFFSET_FORWARD = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_SOLID_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(NO_TRANSPARENCY) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .setLayeringState(VIEW_OFFSET_Z_LAYERING_FORWARD) .createCompositeState(true); - return create("entity_solid_z_offset_forward", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, false, compositeState); + return create("entity_solid_z_offset_forward", 1536, true, false, RenderPipelines.ENTITY_SOLID_Z_OFFSET_FORWARD, compositeState); }) ); private static final Function ENTITY_CUTOUT = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_CUTOUT_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(NO_TRANSPARENCY) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .createCompositeState(true); - return create("entity_cutout", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, false, compositeState); + return create("entity_cutout", 1536, true, false, RenderPipelines.ENTITY_CUTOUT, compositeState); }) ); private static final BiFunction ENTITY_CUTOUT_NO_CULL = Util.memoize( (BiFunction)((resourceLocation, boolean_) -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_CUTOUT_NO_CULL_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(NO_TRANSPARENCY) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .createCompositeState(boolean_); - return create("entity_cutout_no_cull", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, false, compositeState); + return create("entity_cutout_no_cull", 1536, true, false, RenderPipelines.ENTITY_CUTOUT_NO_CULL, compositeState); }) ); private static final BiFunction ENTITY_CUTOUT_NO_CULL_Z_OFFSET = Util.memoize( (BiFunction)((resourceLocation, boolean_) -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_CUTOUT_NO_CULL_Z_OFFSET_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(NO_TRANSPARENCY) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .setLayeringState(VIEW_OFFSET_Z_LAYERING) .createCompositeState(boolean_); - return create("entity_cutout_no_cull_z_offset", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, false, compositeState); + return create("entity_cutout_no_cull_z_offset", 1536, true, false, RenderPipelines.ENTITY_CUTOUT_NO_CULL_Z_OFFSET, compositeState); }) ); private static final Function ITEM_ENTITY_TRANSLUCENT_CULL = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ITEM_ENTITY_TRANSLUCENT_CULL_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setOutputState(ITEM_ENTITY_TARGET) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) - .setWriteMaskState(COLOR_DEPTH_WRITE) .createCompositeState(true); - return create("item_entity_translucent_cull", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, true, compositeState); + return create("item_entity_translucent_cull", 1536, true, true, RenderPipelines.ITEM_ENTITY_TRANSLUCENT_CULL, compositeState); }) ); private static final BiFunction ENTITY_TRANSLUCENT = Util.memoize( (BiFunction)((resourceLocation, boolean_) -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_TRANSLUCENT_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .createCompositeState(boolean_); - return create("entity_translucent", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, true, compositeState); + return create("entity_translucent", 1536, true, true, RenderPipelines.ENTITY_TRANSLUCENT, compositeState); }) ); private static final BiFunction ENTITY_TRANSLUCENT_EMISSIVE = Util.memoize( (BiFunction)((resourceLocation, boolean_) -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_TRANSLUCENT_EMISSIVE_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(NO_CULL) - .setWriteMaskState(COLOR_WRITE) .setOverlayState(OVERLAY) .createCompositeState(boolean_); - return create("entity_translucent_emissive", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, true, compositeState); + return create("entity_translucent_emissive", 1536, true, true, RenderPipelines.ENTITY_TRANSLUCENT_EMISSIVE, compositeState); }) ); private static final Function ENTITY_SMOOTH_CUTOUT = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_SMOOTH_CUTOUT_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) + .setOverlayState(OVERLAY) .createCompositeState(true); - return create("entity_smooth_cutout", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, compositeState); + return create("entity_smooth_cutout", 1536, RenderPipelines.ENTITY_SMOOTH_CUTOUT, compositeState); }) ); private static final BiFunction BEACON_BEAM = Util.memoize( (BiFunction)((resourceLocation, boolean_) -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_BEACON_BEAM_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(boolean_ ? TRANSLUCENT_TRANSPARENCY : NO_TRANSPARENCY) - .setWriteMaskState(boolean_ ? COLOR_WRITE : COLOR_DEPTH_WRITE) .createCompositeState(false); - return create("beacon_beam", DefaultVertexFormat.BLOCK, Mode.QUADS, 1536, false, true, compositeState); + return create("beacon_beam", 1536, false, true, boolean_ ? RenderPipelines.BEACON_BEAM_TRANSLUCENT : RenderPipelines.BEACON_BEAM_OPAQUE, compositeState); }) ); private static final Function ENTITY_DECAL = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_DECAL_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setDepthTestState(EQUAL_DEPTH_TEST) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .createCompositeState(false); - return create("entity_decal", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, compositeState); + return create("entity_decal", 1536, RenderPipelines.ENTITY_DECAL, compositeState); }) ); private static final Function ENTITY_NO_OUTLINE = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_NO_OUTLINE_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) - .setWriteMaskState(COLOR_WRITE) .createCompositeState(false); - return create("entity_no_outline", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, false, true, compositeState); + return create("entity_no_outline", 1536, false, true, RenderPipelines.ENTITY_NO_OUTLINE, compositeState); }) ); private static final Function ENTITY_SHADOW = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_SHADOW_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(CULL) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) - .setWriteMaskState(COLOR_WRITE) - .setDepthTestState(LEQUAL_DEPTH_TEST) .setLayeringState(VIEW_OFFSET_Z_LAYERING) .createCompositeState(false); - return create("entity_shadow", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, false, false, compositeState); + return create("entity_shadow", 1536, false, false, RenderPipelines.ENTITY_SHADOW, compositeState); }) ); private static final Function DRAGON_EXPLOSION_ALPHA = Util.memoize( (Function)(resourceLocation -> { RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_ALPHA_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setCullState(NO_CULL) .createCompositeState(true); - return create("entity_alpha", DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, compositeState); + return create("entity_alpha", 1536, RenderPipelines.DRAGON_EXPLOSION_ALPHA, compositeState); }) ); - private static final BiFunction EYES = Util.memoize( - (BiFunction)((resourceLocation, transparencyStateShard) -> { + private static final Function EYES = Util.memoize( + (Function)(resourceLocation -> { RenderStateShard.TextureStateShard textureStateShard = new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false); return create( - "eyes", - DefaultVertexFormat.NEW_ENTITY, - Mode.QUADS, - 1536, - false, - true, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_EYES_SHADER) - .setTextureState(textureStateShard) - .setTransparencyState(transparencyStateShard) - .setWriteMaskState(COLOR_WRITE) - .createCompositeState(false) + "eyes", 1536, false, true, RenderPipelines.EYES, RenderType.CompositeState.builder().setTextureState(textureStateShard).createCompositeState(false) ); }) ); private static final RenderType LEASH = create( - "leash", - DefaultVertexFormat.POSITION_COLOR_LIGHTMAP, - Mode.TRIANGLE_STRIP, - 1536, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_LEASH_SHADER) - .setTextureState(NO_TEXTURE) - .setCullState(NO_CULL) - .setLightmapState(LIGHTMAP) - .createCompositeState(false) + "leash", 1536, RenderPipelines.LEASH, RenderType.CompositeState.builder().setTextureState(NO_TEXTURE).setLightmapState(LIGHTMAP).createCompositeState(false) ); private static final RenderType WATER_MASK = create( - "water_mask", - DefaultVertexFormat.POSITION, - Mode.QUADS, - 1536, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_WATER_MASK_SHADER) - .setTextureState(NO_TEXTURE) - .setWriteMaskState(DEPTH_WRITE) - .createCompositeState(false) + "water_mask", 1536, RenderPipelines.WATER_MASK, RenderType.CompositeState.builder().setTextureState(NO_TEXTURE).createCompositeState(false) ); private static final RenderType ARMOR_ENTITY_GLINT = create( "armor_entity_glint", - DefaultVertexFormat.POSITION_TEX, - Mode.QUADS, 1536, + RenderPipelines.GLINT, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ARMOR_ENTITY_GLINT_SHADER) - .setTextureState(new RenderStateShard.TextureStateShard(ItemRenderer.ENCHANTED_GLINT_ENTITY, TriState.DEFAULT, false)) - .setWriteMaskState(COLOR_WRITE) - .setCullState(NO_CULL) - .setDepthTestState(EQUAL_DEPTH_TEST) - .setTransparencyState(GLINT_TRANSPARENCY) - .setTexturingState(ENTITY_GLINT_TEXTURING) + .setTextureState(new RenderStateShard.TextureStateShard(ItemRenderer.ENCHANTED_GLINT_ARMOR, TriState.DEFAULT, false)) + .setTexturingState(ARMOR_ENTITY_GLINT_TEXTURING) .setLayeringState(VIEW_OFFSET_Z_LAYERING) .createCompositeState(false) ); private static final RenderType GLINT_TRANSLUCENT = create( "glint_translucent", - DefaultVertexFormat.POSITION_TEX, - Mode.QUADS, 1536, + RenderPipelines.GLINT, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_GLINT_TRANSLUCENT_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(ItemRenderer.ENCHANTED_GLINT_ITEM, TriState.DEFAULT, false)) - .setWriteMaskState(COLOR_WRITE) - .setCullState(NO_CULL) - .setDepthTestState(EQUAL_DEPTH_TEST) - .setTransparencyState(GLINT_TRANSPARENCY) .setTexturingState(GLINT_TEXTURING) .setOutputState(ITEM_ENTITY_TARGET) .createCompositeState(false) ); private static final RenderType GLINT = create( "glint", - DefaultVertexFormat.POSITION_TEX, - Mode.QUADS, 1536, + RenderPipelines.GLINT, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_GLINT_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(ItemRenderer.ENCHANTED_GLINT_ITEM, TriState.DEFAULT, false)) - .setWriteMaskState(COLOR_WRITE) - .setCullState(NO_CULL) - .setDepthTestState(EQUAL_DEPTH_TEST) - .setTransparencyState(GLINT_TRANSPARENCY) .setTexturingState(GLINT_TEXTURING) .createCompositeState(false) ); private static final RenderType ENTITY_GLINT = create( "entity_glint", - DefaultVertexFormat.POSITION_TEX, - Mode.QUADS, 1536, + RenderPipelines.GLINT, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENTITY_GLINT_SHADER) - .setTextureState(new RenderStateShard.TextureStateShard(ItemRenderer.ENCHANTED_GLINT_ENTITY, TriState.DEFAULT, false)) - .setWriteMaskState(COLOR_WRITE) - .setCullState(NO_CULL) - .setDepthTestState(EQUAL_DEPTH_TEST) - .setTransparencyState(GLINT_TRANSPARENCY) + .setTextureState(new RenderStateShard.TextureStateShard(ItemRenderer.ENCHANTED_GLINT_ITEM, TriState.DEFAULT, false)) .setTexturingState(ENTITY_GLINT_TEXTURING) .createCompositeState(false) ); @@ -378,63 +298,44 @@ public abstract class RenderType extends RenderStateShard { RenderStateShard.TextureStateShard textureStateShard = new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false); return create( "crumbling", - DefaultVertexFormat.BLOCK, - Mode.QUADS, 1536, false, true, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_CRUMBLING_SHADER) - .setTextureState(textureStateShard) - .setTransparencyState(CRUMBLING_TRANSPARENCY) - .setWriteMaskState(COLOR_WRITE) - .setLayeringState(POLYGON_OFFSET_LAYERING) - .createCompositeState(false) + RenderPipelines.CRUMBLING, + RenderType.CompositeState.builder().setTextureState(textureStateShard).createCompositeState(false) ); }) ); private static final Function TEXT = Util.memoize( (Function)(resourceLocation -> create( "text", - DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP, - Mode.QUADS, 786432, false, false, + RenderPipelines.TEXT, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_TEXT_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setLightmapState(LIGHTMAP) .createCompositeState(false) )) ); private static final RenderType TEXT_BACKGROUND = create( "text_background", - DefaultVertexFormat.POSITION_COLOR_LIGHTMAP, - Mode.QUADS, 1536, false, true, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_TEXT_BACKGROUND_SHADER) - .setTextureState(NO_TEXTURE) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setLightmapState(LIGHTMAP) - .createCompositeState(false) + RenderPipelines.TEXT_BACKGROUND, + RenderType.CompositeState.builder().setTextureState(NO_TEXTURE).setLightmapState(LIGHTMAP).createCompositeState(false) ); private static final Function TEXT_INTENSITY = Util.memoize( (Function)(resourceLocation -> create( "text_intensity", - DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP, - Mode.QUADS, 786432, false, false, + RenderPipelines.TEXT_INTENSITY, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_TEXT_INTENSITY_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setLightmapState(LIGHTMAP) .createCompositeState(false) )) @@ -442,135 +343,87 @@ public abstract class RenderType extends RenderStateShard { private static final Function TEXT_POLYGON_OFFSET = Util.memoize( (Function)(resourceLocation -> create( "text_polygon_offset", - DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP, - Mode.QUADS, 1536, false, true, + RenderPipelines.TEXT_POLYGON_OFFSET, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_TEXT_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setLightmapState(LIGHTMAP) - .setLayeringState(POLYGON_OFFSET_LAYERING) .createCompositeState(false) )) ); private static final Function TEXT_INTENSITY_POLYGON_OFFSET = Util.memoize( (Function)(resourceLocation -> create( "text_intensity_polygon_offset", - DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP, - Mode.QUADS, 1536, false, true, + RenderPipelines.TEXT_INTENSITY, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_TEXT_INTENSITY_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setLightmapState(LIGHTMAP) - .setLayeringState(POLYGON_OFFSET_LAYERING) .createCompositeState(false) )) ); private static final Function TEXT_SEE_THROUGH = Util.memoize( (Function)(resourceLocation -> create( "text_see_through", - DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP, - Mode.QUADS, 1536, false, false, + RenderPipelines.TEXT_SEE_THROUGH, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_TEXT_SEE_THROUGH_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setLightmapState(LIGHTMAP) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) .createCompositeState(false) )) ); private static final RenderType TEXT_BACKGROUND_SEE_THROUGH = create( "text_background_see_through", - DefaultVertexFormat.POSITION_COLOR_LIGHTMAP, - Mode.QUADS, 1536, false, true, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_TEXT_BACKGROUND_SEE_THROUGH_SHADER) - .setTextureState(NO_TEXTURE) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setLightmapState(LIGHTMAP) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) - .createCompositeState(false) + RenderPipelines.TEXT_BACKGROUND_SEE_THROUGH, + RenderType.CompositeState.builder().setTextureState(NO_TEXTURE).setLightmapState(LIGHTMAP).createCompositeState(false) ); private static final Function TEXT_INTENSITY_SEE_THROUGH = Util.memoize( (Function)(resourceLocation -> create( "text_intensity_see_through", - DefaultVertexFormat.POSITION_COLOR_TEX_LIGHTMAP, - Mode.QUADS, 1536, false, true, + RenderPipelines.TEXT_INTENSITY_SEE_THROUGH, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_TEXT_INTENSITY_SEE_THROUGH_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setLightmapState(LIGHTMAP) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) .createCompositeState(false) )) ); private static final RenderType LIGHTNING = create( - "lightning", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, - 1536, - false, - true, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_LIGHTNING_SHADER) - .setWriteMaskState(COLOR_DEPTH_WRITE) - .setTransparencyState(LIGHTNING_TRANSPARENCY) - .setOutputState(WEATHER_TARGET) - .createCompositeState(false) + "lightning", 1536, false, true, RenderPipelines.LIGHTNING, RenderType.CompositeState.builder().setOutputState(WEATHER_TARGET).createCompositeState(false) ); private static final RenderType DRAGON_RAYS = create( - "dragon_rays", - DefaultVertexFormat.POSITION_COLOR, - Mode.TRIANGLES, - 1536, - false, - false, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_LIGHTNING_SHADER) - .setWriteMaskState(COLOR_WRITE) - .setTransparencyState(LIGHTNING_TRANSPARENCY) - .createCompositeState(false) + "dragon_rays", 1536, false, false, RenderPipelines.DRAGON_RAYS, RenderType.CompositeState.builder().createCompositeState(false) ); private static final RenderType DRAGON_RAYS_DEPTH = create( - "dragon_rays_depth", - DefaultVertexFormat.POSITION, - Mode.TRIANGLES, - 1536, - false, - false, - RenderType.CompositeState.builder().setShaderState(POSITION_SHADER).setWriteMaskState(DEPTH_WRITE).createCompositeState(false) + "dragon_rays_depth", 1536, false, false, RenderPipelines.DRAGON_RAYS_DEPTH, RenderType.CompositeState.builder().createCompositeState(false) + ); + private static final RenderType TRIPWIRE = create( + "tripwire", + 1536, + true, + true, + RenderPipelines.TRIPWIRE, + RenderType.CompositeState.builder().setLightmapState(LIGHTMAP).setTextureState(BLOCK_SHEET_MIPPED).setOutputState(WEATHER_TARGET).createCompositeState(true) ); - private static final RenderType TRIPWIRE = create("tripwire", DefaultVertexFormat.BLOCK, Mode.QUADS, 1536, true, true, tripwireState()); private static final RenderType END_PORTAL = create( "end_portal", - DefaultVertexFormat.POSITION, - Mode.QUADS, 1536, false, false, + RenderPipelines.END_PORTAL, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_END_PORTAL_SHADER) .setTextureState( RenderStateShard.MultiTextureStateShard.builder() .add(TheEndPortalRenderer.END_SKY_LOCATION, false, false) @@ -581,13 +434,11 @@ public abstract class RenderType extends RenderStateShard { ); private static final RenderType END_GATEWAY = create( "end_gateway", - DefaultVertexFormat.POSITION, - Mode.QUADS, 1536, false, false, + RenderPipelines.END_GATEWAY, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_END_GATEWAY_SHADER) .setTextureState( RenderStateShard.MultiTextureStateShard.builder() .add(TheEndPortalRenderer.END_SKY_LOCATION, false, false) @@ -596,420 +447,224 @@ public abstract class RenderType extends RenderStateShard { ) .createCompositeState(false) ); - private static final RenderType FLAT_CLOUDS = createClouds(false, false); - private static final RenderType CLOUDS = createClouds(false, true); - private static final RenderType CLOUDS_DEPTH_ONLY = createClouds(true, true); public static final RenderType.CompositeRenderType LINES = create( "lines", - DefaultVertexFormat.POSITION_COLOR_NORMAL, - Mode.LINES, 1536, + RenderPipelines.LINES, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_LINES_SHADER) .setLineState(new RenderStateShard.LineStateShard(OptionalDouble.empty())) .setLayeringState(VIEW_OFFSET_Z_LAYERING) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setOutputState(ITEM_ENTITY_TARGET) - .setWriteMaskState(COLOR_DEPTH_WRITE) - .setCullState(NO_CULL) .createCompositeState(false) ); public static final RenderType.CompositeRenderType SECONDARY_BLOCK_OUTLINE = create( "secondary_block_outline", - DefaultVertexFormat.POSITION_COLOR_NORMAL, - Mode.LINES, 1536, + RenderPipelines.SECONDARY_BLOCK_OUTLINE, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_LINES_SHADER) .setLineState(new RenderStateShard.LineStateShard(OptionalDouble.of(7.0))) .setLayeringState(VIEW_OFFSET_Z_LAYERING) - .setTransparencyState(RenderStateShard.TRANSLUCENT_TRANSPARENCY) .setOutputState(ITEM_ENTITY_TARGET) - .setWriteMaskState(COLOR_WRITE) - .setCullState(NO_CULL) .createCompositeState(false) ); public static final RenderType.CompositeRenderType LINE_STRIP = create( "line_strip", - DefaultVertexFormat.POSITION_COLOR_NORMAL, - Mode.LINE_STRIP, 1536, + RenderPipelines.LINE_STRIP, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_LINES_SHADER) .setLineState(new RenderStateShard.LineStateShard(OptionalDouble.empty())) .setLayeringState(VIEW_OFFSET_Z_LAYERING) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setOutputState(ITEM_ENTITY_TARGET) - .setWriteMaskState(COLOR_DEPTH_WRITE) - .setCullState(NO_CULL) .createCompositeState(false) ); private static final Function DEBUG_LINE_STRIP = Util.memoize( (Function)(double_ -> create( "debug_line_strip", - DefaultVertexFormat.POSITION_COLOR, - Mode.DEBUG_LINE_STRIP, 1536, - RenderType.CompositeState.builder() - .setShaderState(POSITION_COLOR_SHADER) - .setLineState(new RenderStateShard.LineStateShard(OptionalDouble.of(double_))) - .setTransparencyState(NO_TRANSPARENCY) - .setCullState(NO_CULL) - .createCompositeState(false) + RenderPipelines.DEBUG_LINE_STRIP, + RenderType.CompositeState.builder().setLineState(new RenderStateShard.LineStateShard(OptionalDouble.of(double_))).createCompositeState(false) + )) + ); + private static final Function DEBUG_LINE = Util.memoize( + (Function)(double_ -> create( + "debug_line", + 1536, + RenderPipelines.LINES, + RenderType.CompositeState.builder().setLineState(new RenderStateShard.LineStateShard(OptionalDouble.of(double_))).createCompositeState(false) )) ); private static final RenderType.CompositeRenderType DEBUG_FILLED_BOX = create( "debug_filled_box", - DefaultVertexFormat.POSITION_COLOR, - Mode.TRIANGLE_STRIP, 1536, false, true, - RenderType.CompositeState.builder() - .setShaderState(POSITION_COLOR_SHADER) - .setLayeringState(VIEW_OFFSET_Z_LAYERING) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .createCompositeState(false) + RenderPipelines.DEBUG_FILLED_BOX, + RenderType.CompositeState.builder().setLayeringState(VIEW_OFFSET_Z_LAYERING).createCompositeState(false) ); private static final RenderType.CompositeRenderType DEBUG_QUADS = create( - "debug_quads", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, - 1536, - false, - true, - RenderType.CompositeState.builder() - .setShaderState(POSITION_COLOR_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(NO_CULL) - .createCompositeState(false) + "debug_quads", 1536, false, true, RenderPipelines.DEBUG_QUADS, RenderType.CompositeState.builder().createCompositeState(false) ); private static final RenderType.CompositeRenderType DEBUG_TRIANGLE_FAN = create( - "debug_triangle_fan", - DefaultVertexFormat.POSITION_COLOR, - Mode.TRIANGLE_FAN, - 1536, - false, - true, - RenderType.CompositeState.builder() - .setShaderState(POSITION_COLOR_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(NO_CULL) - .createCompositeState(false) + "debug_triangle_fan", 1536, false, true, RenderPipelines.DEBUG_TRIANGLE_FAN, RenderType.CompositeState.builder().createCompositeState(false) ); private static final RenderType.CompositeRenderType DEBUG_STRUCTURE_QUADS = create( - "debug_structure_quads", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, - 1536, - false, - true, - RenderType.CompositeState.builder() - .setShaderState(POSITION_COLOR_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(NO_CULL) - .setDepthTestState(LEQUAL_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) - .createCompositeState(false) + "debug_structure_quads", 1536, false, true, RenderPipelines.DEBUG_STRUCTURE_QUADS, RenderType.CompositeState.builder().createCompositeState(false) ); private static final RenderType.CompositeRenderType DEBUG_SECTION_QUADS = create( "debug_section_quads", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, 1536, false, true, - RenderType.CompositeState.builder() - .setShaderState(POSITION_COLOR_SHADER) - .setLayeringState(VIEW_OFFSET_Z_LAYERING) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(CULL) - .createCompositeState(false) + RenderPipelines.DEBUG_SECTION_QUADS, + RenderType.CompositeState.builder().setLayeringState(VIEW_OFFSET_Z_LAYERING).createCompositeState(false) ); - private static final RenderType WORLD_BORDER_NO_DEPTH_WRITE = createWorldBorder(false); - private static final RenderType WORLD_BORDER_DEPTH_WRITE = createWorldBorder(true); private static final Function OPAQUE_PARTICLE = Util.memoize( (Function)(resourceLocation -> create( "opaque_particle", - DefaultVertexFormat.PARTICLE, - Mode.QUADS, 1536, false, false, + RenderPipelines.OPAQUE_PARTICLE, RenderType.CompositeState.builder() - .setShaderState(PARTICLE_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) .setLightmapState(LIGHTMAP) - .setWriteMaskState(COLOR_DEPTH_WRITE) .createCompositeState(false) )) ); private static final Function TRANSLUCENT_PARTICLE = Util.memoize( (Function)(resourceLocation -> create( "translucent_particle", - DefaultVertexFormat.PARTICLE, - Mode.QUADS, 1536, false, false, + RenderPipelines.TRANSLUCENT_PARTICLE, RenderType.CompositeState.builder() - .setShaderState(PARTICLE_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setOutputState(PARTICLES_TARGET) .setLightmapState(LIGHTMAP) - .setWriteMaskState(COLOR_DEPTH_WRITE) .createCompositeState(false) )) ); - private static final Function WEATHER_DEPTH_WRITE = createWeather(true); - private static final Function WEATHER_NO_DEPTH_WRITE = createWeather(false); - private static final RenderType SKY = create( - "sky", - DefaultVertexFormat.POSITION, - Mode.QUADS, - 1536, - false, - false, - RenderType.CompositeState.builder().setShaderState(POSITION_SHADER).setWriteMaskState(COLOR_WRITE).createCompositeState(false) - ); - private static final RenderType END_SKY = create( - "end_sky", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, - 1536, - false, - false, - RenderType.CompositeState.builder() - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) - .setTextureState(new RenderStateShard.TextureStateShard(SkyRenderer.END_SKY_LOCATION, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setWriteMaskState(COLOR_WRITE) - .createCompositeState(false) - ); + private static final Function WEATHER_DEPTH_WRITE = createWeather(RenderPipelines.WEATHER_DEPTH_WRITE); + private static final Function WEATHER_NO_DEPTH_WRITE = createWeather(RenderPipelines.WEATHER_NO_DEPTH_WRITE); private static final RenderType SUNRISE_SUNSET = create( - "sunrise_sunset", - DefaultVertexFormat.POSITION_COLOR, - Mode.TRIANGLE_FAN, - 1536, - false, - false, - RenderType.CompositeState.builder() - .setShaderState(POSITION_COLOR_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setWriteMaskState(COLOR_WRITE) - .createCompositeState(false) - ); - private static final RenderType STARS = create( - "stars", - DefaultVertexFormat.POSITION, - Mode.QUADS, - 1536, - false, - false, - RenderType.CompositeState.builder() - .setShaderState(POSITION_SHADER) - .setTransparencyState(OVERLAY_TRANSPARENCY) - .setWriteMaskState(COLOR_WRITE) - .createCompositeState(false) + "sunrise_sunset", 1536, false, false, RenderPipelines.SUNRISE_SUNSET, RenderType.CompositeState.builder().createCompositeState(false) ); private static final Function CELESTIAL = Util.memoize( (Function)(resourceLocation -> create( "celestial", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 1536, false, false, + RenderPipelines.CELESTIAL, RenderType.CompositeState.builder() - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(OVERLAY_TRANSPARENCY) - .setWriteMaskState(COLOR_WRITE) .createCompositeState(false) )) ); private static final Function BLOCK_SCREEN_EFFECT = Util.memoize( (Function)(resourceLocation -> create( "block_screen_effect", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 1536, false, false, + RenderPipelines.BLOCK_SCREEN_EFFECT, RenderType.CompositeState.builder() - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .createCompositeState(false) )) ); private static final Function FIRE_SCREEN_EFFECT = Util.memoize( (Function)(resourceLocation -> create( "fire_screen_effect", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 1536, false, false, + RenderPipelines.FIRE_SCREEN_EFFECT, RenderType.CompositeState.builder() - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .createCompositeState(false) )) ); private static final RenderType.CompositeRenderType GUI = create( - "gui", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, - 786432, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_GUI_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setDepthTestState(LEQUAL_DEPTH_TEST) - .createCompositeState(false) + "gui", 786432, RenderPipelines.GUI, RenderType.CompositeState.builder().createCompositeState(false) ); private static final RenderType.CompositeRenderType GUI_OVERLAY = create( - "gui_overlay", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, - 1536, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_GUI_OVERLAY_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) - .createCompositeState(false) + "gui_overlay", 1536, RenderPipelines.GUI_OVERLAY, RenderType.CompositeState.builder().createCompositeState(false) ); private static final Function GUI_TEXTURED_OVERLAY = Util.memoize( (Function)(resourceLocation -> create( "gui_textured_overlay", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 1536, + RenderPipelines.GUI_TEXTURED_OVERLAY, RenderType.CompositeState.builder() .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.DEFAULT, false)) - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) .createCompositeState(false) )) ); private static final Function GUI_OPAQUE_TEXTURED_BACKGROUND = Util.memoize( (Function)(resourceLocation -> create( "gui_opaque_textured_background", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 786432, + RenderPipelines.GUI_OPAQUE_TEXTURED_BACKGROUND, RenderType.CompositeState.builder() .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) - .setTransparencyState(NO_TRANSPARENCY) - .setDepthTestState(LEQUAL_DEPTH_TEST) .createCompositeState(false) )) ); private static final RenderType.CompositeRenderType GUI_NAUSEA_OVERLAY = create( "gui_nausea_overlay", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 1536, + RenderPipelines.GUI_NAUSEA_OVERLAY, RenderType.CompositeState.builder() .setTextureState(new RenderStateShard.TextureStateShard(Gui.NAUSEA_LOCATION, TriState.DEFAULT, false)) - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) - .setTransparencyState(NAUSEA_OVERLAY_TRANSPARENCY) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) .createCompositeState(false) ); private static final RenderType.CompositeRenderType GUI_TEXT_HIGHLIGHT = create( - "gui_text_highlight", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, - 1536, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_GUI_TEXT_HIGHLIGHT_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setDepthTestState(NO_DEPTH_TEST) - .setColorLogicState(OR_REVERSE_COLOR_LOGIC) - .createCompositeState(false) + "gui_text_highlight", 1536, RenderPipelines.GUI_TEXT_HIGHLIGHT, RenderType.CompositeState.builder().createCompositeState(false) ); private static final RenderType.CompositeRenderType GUI_GHOST_RECIPE_OVERLAY = create( - "gui_ghost_recipe_overlay", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, - 1536, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_GUI_GHOST_RECIPE_OVERLAY_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setDepthTestState(GREATER_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) - .createCompositeState(false) + "gui_ghost_recipe_overlay", 1536, RenderPipelines.GUI_GHOST_RECIPE_OVERLAY, RenderType.CompositeState.builder().createCompositeState(false) ); private static final Function GUI_TEXTURED = Util.memoize( (Function)(resourceLocation -> create( "gui_textured", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 786432, + RenderPipelines.GUI_TEXTURED, RenderType.CompositeState.builder() .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setDepthTestState(LEQUAL_DEPTH_TEST) .createCompositeState(false) )) ); private static final Function VIGNETTE = Util.memoize( (Function)(resourceLocation -> create( "vignette", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 786432, + RenderPipelines.VIGNETTE, RenderType.CompositeState.builder() .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.DEFAULT, false)) - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) - .setTransparencyState(VIGNETTE_TRANSPARENCY) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) .createCompositeState(false) )) ); private static final Function CROSSHAIR = Util.memoize( (Function)(resourceLocation -> create( "crosshair", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 786432, + RenderPipelines.CROSSHAIR, RenderType.CompositeState.builder() .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) - .setTransparencyState(CROSSHAIR_TRANSPARENCY) .createCompositeState(false) )) ); private static final RenderType.CompositeRenderType MOJANG_LOGO = create( "mojang_logo", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 786432, + RenderPipelines.MOJANG_LOGO, RenderType.CompositeState.builder() .setTextureState(new RenderStateShard.TextureStateShard(LoadingOverlay.MOJANG_STUDIOS_LOGO_LOCATION, TriState.DEFAULT, false)) - .setShaderState(POSITION_TEXTURE_COLOR_SHADER) - .setTransparencyState(MOJANG_LOGO_TRANSPARENCY) - .setDepthTestState(NO_DEPTH_TEST) - .setWriteMaskState(COLOR_WRITE) .createCompositeState(false) ); private static final ImmutableList CHUNK_BUFFER_LAYERS = ImmutableList.of(solid(), cutoutMipped(), cutout(), translucent(), tripwire()); - private final VertexFormat format; - private final Mode mode; private final int bufferSize; private final boolean affectsCrumbling; private final boolean sortOnUpload; @@ -1026,54 +681,26 @@ public abstract class RenderType extends RenderStateShard { return CUTOUT; } - private static RenderType.CompositeState translucentState(RenderStateShard.ShaderStateShard state) { - return RenderType.CompositeState.builder() - .setLightmapState(LIGHTMAP) - .setShaderState(state) - .setTextureState(BLOCK_SHEET_MIPPED) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setOutputState(TRANSLUCENT_TARGET) - .createCompositeState(true); - } - public static RenderType translucent() { return TRANSLUCENT; } - private static RenderType.CompositeState translucentMovingBlockState() { - return RenderType.CompositeState.builder() - .setLightmapState(LIGHTMAP) - .setShaderState(RENDERTYPE_TRANSLUCENT_MOVING_BLOCK_SHADER) - .setTextureState(BLOCK_SHEET_MIPPED) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setOutputState(ITEM_ENTITY_TARGET) - .createCompositeState(true); - } - public static RenderType translucentMovingBlock() { return TRANSLUCENT_MOVING_BLOCK; } - private static RenderType.CompositeRenderType createArmorCutoutNoCull(String name, ResourceLocation id, boolean equalDepthTest) { - RenderType.CompositeState compositeState = RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ARMOR_CUTOUT_NO_CULL_SHADER) - .setTextureState(new RenderStateShard.TextureStateShard(id, TriState.FALSE, false)) - .setTransparencyState(NO_TRANSPARENCY) - .setCullState(NO_CULL) - .setLightmapState(LIGHTMAP) - .setOverlayState(OVERLAY) - .setLayeringState(VIEW_OFFSET_Z_LAYERING) - .setDepthTestState(equalDepthTest ? EQUAL_DEPTH_TEST : LEQUAL_DEPTH_TEST) - .createCompositeState(true); - return create(name, DefaultVertexFormat.NEW_ENTITY, Mode.QUADS, 1536, true, false, compositeState); - } - public static RenderType armorCutoutNoCull(ResourceLocation location) { return (RenderType)ARMOR_CUTOUT_NO_CULL.apply(location); } public static RenderType createArmorDecalCutoutNoCull(ResourceLocation id) { - return createArmorCutoutNoCull("armor_decal_cutout_no_cull", id, true); + RenderType.CompositeState compositeState = RenderType.CompositeState.builder() + .setTextureState(new RenderStateShard.TextureStateShard(id, TriState.FALSE, false)) + .setLightmapState(LIGHTMAP) + .setOverlayState(OVERLAY) + .setLayeringState(VIEW_OFFSET_Z_LAYERING) + .createCompositeState(true); + return create("armor_decal_cutout_no_cull", 1536, true, false, RenderPipelines.ARMOR_DECAL_CUTOUT_NO_CULL, compositeState); } public static RenderType armorTranslucent(ResourceLocation id) { @@ -1153,7 +780,7 @@ public abstract class RenderType extends RenderStateShard { } public static RenderType eyes(ResourceLocation location) { - return (RenderType)EYES.apply(location, TRANSLUCENT_TRANSPARENCY); + return (RenderType)EYES.apply(location); } public static RenderType breezeEyes(ResourceLocation location) { @@ -1163,17 +790,13 @@ public abstract class RenderType extends RenderStateShard { public static RenderType breezeWind(ResourceLocation location, float u, float v) { return create( "breeze_wind", - DefaultVertexFormat.NEW_ENTITY, - Mode.QUADS, 1536, false, true, + RenderPipelines.BREEZE_WIND, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_BREEZE_WIND_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(location, TriState.FALSE, false)) .setTexturingState(new RenderStateShard.OffsetTexturingStateShard(u, v)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) .setOverlayState(NO_OVERLAY) .createCompositeState(false) @@ -1183,17 +806,13 @@ public abstract class RenderType extends RenderStateShard { public static RenderType energySwirl(ResourceLocation location, float u, float v) { return create( "energy_swirl", - DefaultVertexFormat.NEW_ENTITY, - Mode.QUADS, 1536, false, true, + RenderPipelines.ENERGY_SWIRL, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_ENERGY_SWIRL_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(location, TriState.FALSE, false)) .setTexturingState(new RenderStateShard.OffsetTexturingStateShard(u, v)) - .setTransparencyState(ADDITIVE_TRANSPARENCY) - .setCullState(NO_CULL) .setLightmapState(LIGHTMAP) .setOverlayState(OVERLAY) .createCompositeState(false) @@ -1209,7 +828,7 @@ public abstract class RenderType extends RenderStateShard { } public static RenderType outline(ResourceLocation location) { - return (RenderType)RenderType.CompositeRenderType.OUTLINE.apply(location, NO_CULL); + return (RenderType)RenderType.CompositeRenderType.OUTLINE.apply(location, false); } public static RenderType armorEntityGlint() { @@ -1276,16 +895,6 @@ public abstract class RenderType extends RenderStateShard { return DRAGON_RAYS_DEPTH; } - private static RenderType.CompositeState tripwireState() { - return RenderType.CompositeState.builder() - .setLightmapState(LIGHTMAP) - .setShaderState(RENDERTYPE_TRIPWIRE_SHADER) - .setTextureState(BLOCK_SHEET_MIPPED) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setOutputState(WEATHER_TARGET) - .createCompositeState(true); - } - public static RenderType tripwire() { return TRIPWIRE; } @@ -1298,36 +907,6 @@ public abstract class RenderType extends RenderStateShard { return END_GATEWAY; } - private static RenderType.CompositeRenderType createClouds(boolean color, boolean cull) { - return create( - "clouds", - DefaultVertexFormat.POSITION_COLOR, - Mode.QUADS, - 786432, - false, - false, - RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_CLOUDS_SHADER) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) - .setCullState(cull ? CULL : NO_CULL) - .setWriteMaskState(color ? DEPTH_WRITE : COLOR_DEPTH_WRITE) - .setOutputState(CLOUDS_TARGET) - .createCompositeState(true) - ); - } - - public static RenderType flatClouds() { - return FLAT_CLOUDS; - } - - public static RenderType clouds() { - return CLOUDS; - } - - public static RenderType cloudsDepthOnly() { - return CLOUDS_DEPTH_ONLY; - } - public static RenderType lines() { return LINES; } @@ -1344,6 +923,10 @@ public abstract class RenderType extends RenderStateShard { return (RenderType)DEBUG_LINE_STRIP.apply(width); } + public static RenderType debugLine(double width) { + return (RenderType)DEBUG_LINE.apply(width); + } + public static RenderType debugFilledBox() { return DEBUG_FILLED_BOX; } @@ -1364,31 +947,6 @@ public abstract class RenderType extends RenderStateShard { return DEBUG_SECTION_QUADS; } - private static RenderType createWorldBorder(boolean depthWrite) { - return create( - "world_border", - DefaultVertexFormat.POSITION_TEX, - Mode.QUADS, - 1536, - false, - false, - RenderType.CompositeState.builder() - .setShaderState(POSITION_TEX_SHADER) - .setTextureState(new RenderStateShard.TextureStateShard(WorldBorderRenderer.FORCEFIELD_LOCATION, TriState.FALSE, false)) - .setTransparencyState(OVERLAY_TRANSPARENCY) - .setLightmapState(LIGHTMAP) - .setOutputState(WEATHER_TARGET) - .setWriteMaskState(depthWrite ? COLOR_DEPTH_WRITE : COLOR_WRITE) - .setLayeringState(WORLD_BORDER_LAYERING) - .setCullState(NO_CULL) - .createCompositeState(false) - ); - } - - public static RenderType worldBorder(boolean depthWrite) { - return depthWrite ? WORLD_BORDER_DEPTH_WRITE : WORLD_BORDER_NO_DEPTH_WRITE; - } - public static RenderType opaqueParticle(ResourceLocation texture) { return (RenderType)OPAQUE_PARTICLE.apply(texture); } @@ -1397,23 +955,18 @@ public abstract class RenderType extends RenderStateShard { return (RenderType)TRANSLUCENT_PARTICLE.apply(texture); } - private static Function createWeather(boolean depthWrite) { + private static Function createWeather(RenderPipeline renderPipeline) { return Util.memoize( (Function)(resourceLocation -> create( "weather", - DefaultVertexFormat.PARTICLE, - Mode.QUADS, 1536, false, false, + renderPipeline, RenderType.CompositeState.builder() - .setShaderState(PARTICLE_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setTransparencyState(TRANSLUCENT_TRANSPARENCY) .setOutputState(WEATHER_TARGET) .setLightmapState(LIGHTMAP) - .setWriteMaskState(depthWrite ? COLOR_DEPTH_WRITE : COLOR_WRITE) - .setCullState(NO_CULL) .createCompositeState(false) )) ); @@ -1423,22 +976,10 @@ public abstract class RenderType extends RenderStateShard { return (RenderType)(depthWrite ? WEATHER_DEPTH_WRITE : WEATHER_NO_DEPTH_WRITE).apply(texture); } - public static RenderType sky() { - return SKY; - } - - public static RenderType endSky() { - return END_SKY; - } - public static RenderType sunriseSunset() { return SUNRISE_SUNSET; } - public static RenderType stars() { - return STARS; - } - public static RenderType celestial(ResourceLocation texture) { return (RenderType)CELESTIAL.apply(texture); } @@ -1495,37 +1036,28 @@ public abstract class RenderType extends RenderStateShard { return MOJANG_LOGO; } - public RenderType( - String name, VertexFormat format, Mode mode, int bufferSize, boolean affectsCrumbling, boolean sortOnUpload, Runnable setupState, Runnable clearState - ) { + public RenderType(String name, int bufferSize, boolean affectsCrumbling, boolean sortOnUpload, Runnable setupState, Runnable clearState) { super(name, setupState, clearState); - this.format = format; - this.mode = mode; this.bufferSize = bufferSize; this.affectsCrumbling = affectsCrumbling; this.sortOnUpload = sortOnUpload; } - static RenderType.CompositeRenderType create(String name, VertexFormat format, Mode mode, int bufferSize, RenderType.CompositeState state) { - return create(name, format, mode, bufferSize, false, false, state); + static RenderType.CompositeRenderType create(String name, int bufferSize, RenderPipeline renderPipeline, RenderType.CompositeState state) { + return create(name, bufferSize, false, false, renderPipeline, state); } private static RenderType.CompositeRenderType create( - String name, VertexFormat format, Mode mode, int bufferSize, boolean affectsCrumbling, boolean sortOnUpload, RenderType.CompositeState state + String name, int bufferSize, boolean affectsCrumbling, boolean sortOnUpload, RenderPipeline renderPipeline, RenderType.CompositeState state ) { - return new RenderType.CompositeRenderType(name, format, mode, bufferSize, affectsCrumbling, sortOnUpload, state); + return new RenderType.CompositeRenderType(name, bufferSize, affectsCrumbling, sortOnUpload, renderPipeline, state); } - public void draw(MeshData meshData) { - this.setupRenderState(); - BufferUploader.drawWithShader(meshData); - this.clearRenderState(); - } + public abstract void draw(MeshData meshData); - @Override - public String toString() { - return this.name; - } + public abstract RenderTarget getRenderTarget(); + + public abstract RenderPipeline getRenderPipeline(); public static List chunkBufferLayers() { return CHUNK_BUFFER_LAYERS; @@ -1535,13 +1067,9 @@ public abstract class RenderType extends RenderStateShard { return this.bufferSize; } - public VertexFormat format() { - return this.format; - } + public abstract VertexFormat format(); - public Mode mode() { - return this.mode; - } + public abstract VertexFormat.Mode mode(); public Optional outline() { return Optional.empty(); @@ -1556,7 +1084,7 @@ public abstract class RenderType extends RenderStateShard { } public boolean canConsolidateConsecutiveGeometry() { - return !this.mode.connectedPrimitives; + return !this.mode().connectedPrimitives; } public boolean sortOnUpload() { @@ -1565,32 +1093,27 @@ public abstract class RenderType extends RenderStateShard { @Environment(EnvType.CLIENT) static final class CompositeRenderType extends RenderType { - static final BiFunction OUTLINE = Util.memoize( - (BiFunction)((resourceLocation, cullStateShard) -> RenderType.create( + static final BiFunction OUTLINE = Util.memoize( + (BiFunction)((resourceLocation, boolean_) -> RenderType.create( "outline", - DefaultVertexFormat.POSITION_TEX_COLOR, - Mode.QUADS, 1536, + boolean_ ? RenderPipelines.OUTLINE_CULL : RenderPipelines.OUTLINE_NO_CULL, RenderType.CompositeState.builder() - .setShaderState(RENDERTYPE_OUTLINE_SHADER) .setTextureState(new RenderStateShard.TextureStateShard(resourceLocation, TriState.FALSE, false)) - .setCullState(cullStateShard) - .setDepthTestState(NO_DEPTH_TEST) .setOutputState(OUTLINE_TARGET) .createCompositeState(RenderType.OutlineProperty.IS_OUTLINE) )) ); private final RenderType.CompositeState state; + private final RenderPipeline renderPipeline; private final Optional outline; private final boolean isOutline; CompositeRenderType( - String name, VertexFormat format, Mode mode, int bufferSize, boolean affectsCrumbling, boolean sortOnUpload, RenderType.CompositeState state + String name, int bufferSize, boolean affectsCrumbling, boolean sortOnUpload, RenderPipeline renderPipeline, RenderType.CompositeState state ) { super( name, - format, - mode, bufferSize, affectsCrumbling, sortOnUpload, @@ -1598,8 +1121,9 @@ public abstract class RenderType extends RenderStateShard { () -> state.states.forEach(RenderStateShard::clearRenderState) ); this.state = state; + this.renderPipeline = renderPipeline; this.outline = state.outlineProperty == RenderType.OutlineProperty.AFFECTS_OUTLINE - ? state.textureState.cutoutTexture().map(resourceLocation -> (RenderType)OUTLINE.apply(resourceLocation, state.cullState)) + ? state.textureState.cutoutTexture().map(resourceLocation -> (RenderType)OUTLINE.apply(resourceLocation, renderPipeline.isCull())) : Optional.empty(); this.isOutline = state.outlineProperty == RenderType.OutlineProperty.IS_OUTLINE; } @@ -1614,8 +1138,85 @@ public abstract class RenderType extends RenderStateShard { return this.isOutline; } - protected final RenderType.CompositeState state() { - return this.state; + @Override + public RenderPipeline getRenderPipeline() { + return this.renderPipeline; + } + + @Override + public VertexFormat format() { + return this.renderPipeline.getVertexFormat(); + } + + @Override + public VertexFormat.Mode mode() { + return this.renderPipeline.getVertexFormatMode(); + } + + @Override + public void draw(MeshData meshData) { + RenderPipeline renderPipeline = this.getRenderPipeline(); + this.setupRenderState(); + MeshData var3 = meshData; + + try { + GpuBuffer gpuBuffer = renderPipeline.getVertexFormat().uploadImmediateVertexBuffer(meshData.vertexBuffer()); + GpuBuffer gpuBuffer2; + VertexFormat.IndexType indexType; + if (meshData.indexBuffer() == null) { + RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(meshData.drawState().mode()); + gpuBuffer2 = autoStorageIndexBuffer.getBuffer(meshData.drawState().indexCount()); + indexType = autoStorageIndexBuffer.type(); + } else { + gpuBuffer2 = renderPipeline.getVertexFormat().uploadImmediateIndexBuffer(meshData.indexBuffer()); + indexType = meshData.drawState().indexType(); + } + + RenderTarget renderTarget = this.state.outputState.getRenderTarget(); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass( + renderTarget.getColorTexture(), OptionalInt.empty(), renderTarget.useDepth ? renderTarget.getDepthTexture() : null, OptionalDouble.empty() + )) { + renderPass.setPipeline(renderPipeline); + renderPass.setVertexBuffer(0, gpuBuffer); + if (RenderSystem.SCISSOR_STATE.isEnabled()) { + renderPass.enableScissor(RenderSystem.SCISSOR_STATE); + } + + for (int i = 0; i < 12; i++) { + GpuTexture gpuTexture = RenderSystem.getShaderTexture(i); + if (gpuTexture != null) { + renderPass.bindSampler("Sampler" + i, gpuTexture); + } + } + + renderPass.setIndexBuffer(gpuBuffer2, indexType); + renderPass.drawIndexed(0, meshData.drawState().indexCount()); + } + } catch (Throwable var14) { + if (meshData != null) { + try { + var3.close(); + } catch (Throwable var11) { + var14.addSuppressed(var11); + } + } + + throw var14; + } + + if (meshData != null) { + meshData.close(); + } + + this.clearRenderState(); + } + + @Override + public RenderTarget getRenderTarget() { + return this.state.outputState.getRenderTarget(); } @Override @@ -1627,66 +1228,24 @@ public abstract class RenderType extends RenderStateShard { @Environment(EnvType.CLIENT) protected static final class CompositeState { final RenderStateShard.EmptyTextureStateShard textureState; - private final RenderStateShard.ShaderStateShard shaderState; - private final RenderStateShard.TransparencyStateShard transparencyState; - private final RenderStateShard.DepthTestStateShard depthTestState; - final RenderStateShard.CullStateShard cullState; - private final RenderStateShard.LightmapStateShard lightmapState; - private final RenderStateShard.OverlayStateShard overlayState; - private final RenderStateShard.LayeringStateShard layeringState; - private final RenderStateShard.OutputStateShard outputState; - private final RenderStateShard.TexturingStateShard texturingState; - private final RenderStateShard.WriteMaskStateShard writeMaskState; - private final RenderStateShard.LineStateShard lineState; - private final RenderStateShard.ColorLogicStateShard colorLogicState; + final RenderStateShard.OutputStateShard outputState; final RenderType.OutlineProperty outlineProperty; final ImmutableList states; CompositeState( RenderStateShard.EmptyTextureStateShard textureState, - RenderStateShard.ShaderStateShard shaderState, - RenderStateShard.TransparencyStateShard transparencyState, - RenderStateShard.DepthTestStateShard depthState, - RenderStateShard.CullStateShard cullState, RenderStateShard.LightmapStateShard lightmapState, RenderStateShard.OverlayStateShard overlayState, RenderStateShard.LayeringStateShard layeringState, RenderStateShard.OutputStateShard outputState, RenderStateShard.TexturingStateShard texturingState, - RenderStateShard.WriteMaskStateShard writeMaskState, RenderStateShard.LineStateShard lineState, - RenderStateShard.ColorLogicStateShard colorLogicState, RenderType.OutlineProperty outlineProperty ) { this.textureState = textureState; - this.shaderState = shaderState; - this.transparencyState = transparencyState; - this.depthTestState = depthState; - this.cullState = cullState; - this.lightmapState = lightmapState; - this.overlayState = overlayState; - this.layeringState = layeringState; this.outputState = outputState; - this.texturingState = texturingState; - this.writeMaskState = writeMaskState; - this.lineState = lineState; - this.colorLogicState = colorLogicState; this.outlineProperty = outlineProperty; - this.states = ImmutableList.of( - this.textureState, - this.shaderState, - this.transparencyState, - this.depthTestState, - this.cullState, - this.lightmapState, - this.overlayState, - this.layeringState, - this.outputState, - this.texturingState, - this.writeMaskState, - this.colorLogicState, - this.lineState - ); + this.states = ImmutableList.of(textureState, lightmapState, overlayState, layeringState, outputState, texturingState, lineState); } public String toString() { @@ -1699,7 +1258,7 @@ public abstract class RenderType extends RenderStateShard { } @Environment(EnvType.CLIENT) - static enum OutlineProperty { + protected static enum OutlineProperty { NONE("none"), IS_OUTLINE("is_outline"), AFFECTS_OUTLINE("affects_outline"); diff --git a/net/minecraft/client/renderer/ScreenEffectRenderer.java b/net/minecraft/client/renderer/ScreenEffectRenderer.java index 460922ce..c066a5be 100644 --- a/net/minecraft/client/renderer/ScreenEffectRenderer.java +++ b/net/minecraft/client/renderer/ScreenEffectRenderer.java @@ -81,9 +81,9 @@ public class ScreenEffectRenderer { vertexConsumer.addVertex(matrix4f, -1.0F, 1.0F, -0.5F).setUv(n, o).setColor(i); } - private static void renderWater(Minecraft minecraft, PoseStack poseStack, MultiBufferSource bufferSource) { - BlockPos blockPos = BlockPos.containing(minecraft.player.getX(), minecraft.player.getEyeY(), minecraft.player.getZ()); - float f = LightTexture.getBrightness(minecraft.player.level().dimensionType(), minecraft.player.level().getMaxLocalRawBrightness(blockPos)); + private static void renderWater(Minecraft mnecraft, PoseStack poseStack, MultiBufferSource bufferSource) { + BlockPos blockPos = BlockPos.containing(mnecraft.player.getX(), mnecraft.player.getEyeY(), mnecraft.player.getZ()); + float f = LightTexture.getBrightness(mnecraft.player.level().dimensionType(), mnecraft.player.level().getMaxLocalRawBrightness(blockPos)); int i = ARGB.colorFromFloat(0.1F, f, f, f); float g = 4.0F; float h = -1.0F; @@ -91,8 +91,8 @@ public class ScreenEffectRenderer { float k = -1.0F; float l = 1.0F; float m = -0.5F; - float n = -minecraft.player.getYRot() / 64.0F; - float o = minecraft.player.getXRot() / 64.0F; + float n = -mnecraft.player.getYRot() / 64.0F; + float o = mnecraft.player.getXRot() / 64.0F; Matrix4f matrix4f = poseStack.last().pose(); VertexConsumer vertexConsumer = bufferSource.getBuffer(RenderType.blockScreenEffect(UNDERWATER_LOCATION)); vertexConsumer.addVertex(matrix4f, -1.0F, -1.0F, -0.5F).setUv(4.0F + n, 4.0F + o).setColor(i); diff --git a/net/minecraft/client/renderer/SectionOcclusionGraph.java b/net/minecraft/client/renderer/SectionOcclusionGraph.java index 2ba96c36..667ce5eb 100644 --- a/net/minecraft/client/renderer/SectionOcclusionGraph.java +++ b/net/minecraft/client/renderer/SectionOcclusionGraph.java @@ -29,7 +29,6 @@ import net.minecraft.client.renderer.culling.Frustum; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.core.SectionPos; -import net.minecraft.core.Direction.Axis; import net.minecraft.server.level.ChunkTrackingView; import net.minecraft.util.Mth; import net.minecraft.util.VisibleForDebug; @@ -37,6 +36,7 @@ import net.minecraft.world.level.ChunkPos; import net.minecraft.world.level.LevelHeightAccessor; import net.minecraft.world.phys.Vec3; import org.jetbrains.annotations.Nullable; +import org.joml.Vector3d; import org.slf4j.Logger; @Environment(EnvType.CLIENT) @@ -44,6 +44,7 @@ public class SectionOcclusionGraph { private static final Logger LOGGER = LogUtils.getLogger(); private static final Direction[] DIRECTIONS = Direction.values(); private static final int MINIMUM_ADVANCED_CULLING_DISTANCE = 60; + private static final int MINIMUM_ADVANCED_CULLING_SECTION_DISTANCE = SectionPos.blockToSectionCoord(60); private static final double CEILED_SECTION_DIAGONAL = Math.ceil(Math.sqrt(3.0) * 16.0); private boolean needsFullUpdate = true; @Nullable @@ -236,7 +237,7 @@ public class SectionOcclusionGraph { } } - list.sort(Comparator.comparingDouble(nodex -> blockPos.distSqr(nodex.section.getOrigin().offset(8, 8, 8)))); + list.sort(Comparator.comparingDouble(nodex -> blockPos.distSqr(SectionPos.of(nodex.section.getSectionNode()).center()))); nodeQueue.addAll(list); } else { nodeQueue.add(new SectionOcclusionGraph.Node(renderSection, null, 0)); @@ -251,10 +252,9 @@ public class SectionOcclusionGraph { Consumer visibleSectionConsumer, LongOpenHashSet loadedEmptySection ) { - int i = 16; - BlockPos blockPos = new BlockPos(Mth.floor(cameraPosition.x / 16.0) * 16, Mth.floor(cameraPosition.y / 16.0) * 16, Mth.floor(cameraPosition.z / 16.0) * 16); - long l = SectionPos.asLong(blockPos); - BlockPos blockPos2 = blockPos.offset(8, 8, 8); + SectionPos sectionPos = SectionPos.of(cameraPosition); + long l = sectionPos.asLong(); + BlockPos blockPos = sectionPos.center(); while (!queue.isEmpty()) { SectionOcclusionGraph.Node node = (SectionOcclusionGraph.Node)queue.poll(); @@ -267,9 +267,10 @@ public class SectionOcclusionGraph { node.section.compiled.compareAndSet(SectionRenderDispatcher.CompiledSection.UNCOMPILED, SectionRenderDispatcher.CompiledSection.EMPTY); } - boolean bl = Math.abs(renderSection.getOrigin().getX() - blockPos.getX()) > 60 - || Math.abs(renderSection.getOrigin().getY() - blockPos.getY()) > 60 - || Math.abs(renderSection.getOrigin().getZ() - blockPos.getZ()) > 60; + long m = renderSection.getSectionNode(); + boolean bl = Math.abs(SectionPos.x(m) - sectionPos.x()) > MINIMUM_ADVANCED_CULLING_SECTION_DISTANCE + || Math.abs(SectionPos.y(m) - sectionPos.y()) > MINIMUM_ADVANCED_CULLING_SECTION_DISTANCE + || Math.abs(SectionPos.z(m) - sectionPos.z()) > MINIMUM_ADVANCED_CULLING_SECTION_DISTANCE; for (Direction direction : DIRECTIONS) { SectionRenderDispatcher.RenderSection renderSection2 = this.getRelativeFrom(l, renderSection, direction); @@ -278,8 +279,8 @@ public class SectionOcclusionGraph { SectionRenderDispatcher.CompiledSection compiledSection = renderSection.getCompiled(); boolean bl2 = false; - for (int j = 0; j < DIRECTIONS.length; j++) { - if (node.hasSourceDirection(j) && compiledSection.facesCanSeeEachother(DIRECTIONS[j].getOpposite(), direction)) { + for (int i = 0; i < DIRECTIONS.length; i++) { + if (node.hasSourceDirection(i) && compiledSection.facesCanSeeEachother(DIRECTIONS[i].getOpposite(), direction)) { bl2 = true; break; } @@ -291,31 +292,31 @@ public class SectionOcclusionGraph { } if (smartCull && bl) { - BlockPos blockPos3 = renderSection2.getOrigin(); - BlockPos blockPos4 = blockPos3.offset( - (direction.getAxis() == Axis.X ? blockPos2.getX() <= blockPos3.getX() : blockPos2.getX() >= blockPos3.getX()) ? 0 : 16, - (direction.getAxis() == Axis.Y ? blockPos2.getY() <= blockPos3.getY() : blockPos2.getY() >= blockPos3.getY()) ? 0 : 16, - (direction.getAxis() == Axis.Z ? blockPos2.getZ() <= blockPos3.getZ() : blockPos2.getZ() >= blockPos3.getZ()) ? 0 : 16 - ); - Vec3 vec3 = new Vec3(blockPos4.getX(), blockPos4.getY(), blockPos4.getZ()); - Vec3 vec32 = cameraPosition.subtract(vec3).normalize().scale(CEILED_SECTION_DIAGONAL); - boolean bl3 = true; + int j = SectionPos.sectionToBlockCoord(SectionPos.x(m)); + int k = SectionPos.sectionToBlockCoord(SectionPos.y(m)); + int ix = SectionPos.sectionToBlockCoord(SectionPos.z(m)); + boolean bl3 = direction.getAxis() == Direction.Axis.X ? blockPos.getX() > j : blockPos.getX() < j; + boolean bl4 = direction.getAxis() == Direction.Axis.Y ? blockPos.getY() > k : blockPos.getY() < k; + boolean bl5 = direction.getAxis() == Direction.Axis.Z ? blockPos.getZ() > ix : blockPos.getZ() < ix; + Vector3d vector3d = new Vector3d(j + (bl3 ? 16 : 0), k + (bl4 ? 16 : 0), ix + (bl5 ? 16 : 0)); + Vector3d vector3d2 = new Vector3d(cameraPosition.x, cameraPosition.y, cameraPosition.z).sub(vector3d).normalize().mul(CEILED_SECTION_DIAGONAL); + boolean bl6 = true; - while (cameraPosition.subtract(vec3).lengthSqr() > 3600.0) { - vec3 = vec3.add(vec32); + while (vector3d.distanceSquared(cameraPosition.x, cameraPosition.y, cameraPosition.z) > 3600.0) { + vector3d.add(vector3d2); LevelHeightAccessor levelHeightAccessor = this.viewArea.getLevelHeightAccessor(); - if (vec3.y > levelHeightAccessor.getMaxY() || vec3.y < levelHeightAccessor.getMinY()) { + if (vector3d.y > levelHeightAccessor.getMaxY() || vector3d.y < levelHeightAccessor.getMinY()) { break; } - SectionRenderDispatcher.RenderSection renderSection3 = this.viewArea.getRenderSectionAt(BlockPos.containing(vec3.x, vec3.y, vec3.z)); + SectionRenderDispatcher.RenderSection renderSection3 = this.viewArea.getRenderSectionAt(BlockPos.containing(vector3d.x, vector3d.y, vector3d.z)); if (renderSection3 == null || storage.sectionToNodeMap.get(renderSection3) == null) { - bl3 = false; + bl6 = false; break; } } - if (!bl3) { + if (!bl6) { continue; } } @@ -331,10 +332,9 @@ public class SectionOcclusionGraph { storage.sectionToNodeMap.put(renderSection2, node3); } else if (this.isInViewDistance(l, renderSection2.getSectionNode())) { storage.sectionToNodeMap.put(renderSection2, node3); + long n = SectionPos.sectionToChunk(renderSection2.getSectionNode()); storage.chunksWaitingForNeighbors - .computeIfAbsent( - ChunkPos.asLong(renderSection2.getOrigin()), (Long2ObjectFunction>)(lx -> new ArrayList()) - ) + .computeIfAbsent(n, (Long2ObjectFunction>)(lx -> new ArrayList())) .add(renderSection2); } } diff --git a/net/minecraft/client/renderer/ShaderDefines.java b/net/minecraft/client/renderer/ShaderDefines.java index 1a661170..c37ef863 100644 --- a/net/minecraft/client/renderer/ShaderDefines.java +++ b/net/minecraft/client/renderer/ShaderDefines.java @@ -88,6 +88,11 @@ public record ShaderDefines(Map values, Set flags) { return this; } + public ShaderDefines.Builder define(String key, int value) { + this.values.put(key, String.valueOf(value)); + return this; + } + public ShaderDefines.Builder define(String flag) { this.flags.add(flag); return this; diff --git a/net/minecraft/client/renderer/ShaderManager.java b/net/minecraft/client/renderer/ShaderManager.java index e0ac9eca..9f591966 100644 --- a/net/minecraft/client/renderer/ShaderManager.java +++ b/net/minecraft/client/renderer/ShaderManager.java @@ -6,17 +6,21 @@ import com.google.gson.JsonElement; import com.google.gson.JsonParseException; import com.google.gson.JsonParser; import com.google.gson.JsonSyntaxException; +import com.mojang.blaze3d.pipeline.CompiledRenderPipeline; +import com.mojang.blaze3d.pipeline.RenderPipeline; import com.mojang.blaze3d.preprocessor.GlslPreprocessor; -import com.mojang.blaze3d.shaders.CompiledShader; -import com.mojang.blaze3d.shaders.CompiledShader.Type; +import com.mojang.blaze3d.shaders.ShaderType; +import com.mojang.blaze3d.systems.GpuDevice; import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.logging.LogUtils; import com.mojang.serialization.JsonOps; import it.unimi.dsi.fastutil.objects.ObjectArraySet; import java.io.IOException; import java.io.Reader; +import java.util.ArrayList; import java.util.HashMap; import java.util.HashSet; +import java.util.List; import java.util.Map; import java.util.Optional; import java.util.Set; @@ -33,7 +37,6 @@ import net.minecraft.resources.FileToIdConverter; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.Resource; import net.minecraft.server.packs.resources.ResourceManager; -import net.minecraft.server.packs.resources.ResourceProvider; import net.minecraft.server.packs.resources.SimplePreparableReloadListener; import net.minecraft.util.profiling.ProfilerFiller; import org.apache.commons.io.IOUtils; @@ -43,11 +46,10 @@ import org.slf4j.Logger; @Environment(EnvType.CLIENT) public class ShaderManager extends SimplePreparableReloadListener implements AutoCloseable { static final Logger LOGGER = LogUtils.getLogger(); - public static final String SHADER_PATH = "shaders"; - public static final String SHADER_INCLUDE_PATH = "shaders/include/"; - private static final FileToIdConverter PROGRAM_ID_CONVERTER = FileToIdConverter.json("shaders"); - private static final FileToIdConverter POST_CHAIN_ID_CONVERTER = FileToIdConverter.json("post_effect"); public static final int MAX_LOG_LENGTH = 32768; + public static final String SHADER_PATH = "shaders"; + private static final String SHADER_INCLUDE_PATH = "shaders/include/"; + private static final FileToIdConverter POST_CHAIN_ID_CONVERTER = FileToIdConverter.json("post_effect"); final TextureManager textureManager; private final Consumer recoveryHandler; private ShaderManager.CompilationCache compilationCache = new ShaderManager.CompilationCache(ShaderManager.Configs.EMPTY); @@ -58,31 +60,32 @@ public class ShaderManager extends SimplePreparableReloadListener builder = ImmutableMap.builder(); - Builder builder2 = ImmutableMap.builder(); - Map map = resourceManager.listResources("shaders", resourceLocation -> isProgram(resourceLocation) || isShader(resourceLocation)); + Builder builder = ImmutableMap.builder(); + Map map = resourceManager.listResources("shaders", ShaderManager::isShader); for (Entry entry : map.entrySet()) { ResourceLocation resourceLocation = (ResourceLocation)entry.getKey(); - Type type = Type.byLocation(resourceLocation); - if (type != null) { - loadShader(resourceLocation, (Resource)entry.getValue(), type, map, builder2); - } else if (isProgram(resourceLocation)) { - loadProgram(resourceLocation, (Resource)entry.getValue(), builder); + ShaderType shaderType = ShaderType.byLocation(resourceLocation); + if (shaderType != null) { + loadShader(resourceLocation, (Resource)entry.getValue(), shaderType, map, builder); } } - Builder builder3 = ImmutableMap.builder(); + Builder builder2 = ImmutableMap.builder(); for (Entry entry2 : POST_CHAIN_ID_CONVERTER.listMatchingResources(resourceManager).entrySet()) { - loadPostChain((ResourceLocation)entry2.getKey(), (Resource)entry2.getValue(), builder3); + loadPostChain((ResourceLocation)entry2.getKey(), (Resource)entry2.getValue(), builder2); } - return new ShaderManager.Configs(builder.build(), builder2.build(), builder3.build()); + return new ShaderManager.Configs(builder.build(), builder2.build()); } private static void loadShader( - ResourceLocation location, Resource shader, Type type, Map shaderResources, Builder output + ResourceLocation location, + Resource shader, + ShaderType type, + Map shaderResources, + Builder output ) { ResourceLocation resourceLocation = type.idConverter().fileToId(location); GlslPreprocessor glslPreprocessor = createPreprocessor(shaderResources, location); @@ -167,36 +170,6 @@ public class ShaderManager extends SimplePreparableReloadListener output) { - ResourceLocation resourceLocation = PROGRAM_ID_CONVERTER.fileToId(location); - - try { - Reader reader = resource.openAsReader(); - - try { - JsonElement jsonElement = JsonParser.parseReader(reader); - ShaderProgramConfig shaderProgramConfig = ShaderProgramConfig.CODEC.parse(JsonOps.INSTANCE, jsonElement).getOrThrow(JsonSyntaxException::new); - output.put(resourceLocation, shaderProgramConfig); - } catch (Throwable var8) { - if (reader != null) { - try { - reader.close(); - } catch (Throwable var7) { - var8.addSuppressed(var7); - } - } - - throw var8; - } - - if (reader != null) { - reader.close(); - } - } catch (JsonParseException | IOException var9) { - LOGGER.error("Failed to parse shader config at {}", location, var9); - } - } - private static void loadPostChain(ResourceLocation location, Resource postChain, Builder output) { ResourceLocation resourceLocation = POST_CHAIN_ID_CONVERTER.fileToId(location); @@ -226,41 +199,28 @@ public class ShaderManager extends SimplePreparableReloadListener map = new HashMap(); - Set set = new HashSet(CoreShaders.getProgramsToPreload()); + Set set = new HashSet(RenderPipelines.getStaticPipelines()); + List list = new ArrayList(); + GpuDevice gpuDevice = RenderSystem.getDevice(); + gpuDevice.clearPipelineCache(); - for (PostChainConfig postChainConfig : configs.postChains.values()) { - for (PostChainConfig.Pass pass : postChainConfig.passes()) { - set.add(pass.program()); + for (RenderPipeline renderPipeline : set) { + CompiledRenderPipeline compiledRenderPipeline = gpuDevice.precompilePipeline(renderPipeline, compilationCache::getShaderSource); + if (!compiledRenderPipeline.isValid()) { + list.add(renderPipeline.getLocation()); } } - for (ShaderProgram shaderProgram : set) { - try { - compilationCache.programs.put(shaderProgram, Optional.of(compilationCache.compileProgram(shaderProgram))); - } catch (ShaderManager.CompilationException var11) { - map.put(shaderProgram, var11); - } - } - - if (!map.isEmpty()) { - compilationCache.close(); + if (!list.isEmpty()) { + gpuDevice.clearPipelineCache(); throw new RuntimeException( - "Failed to load required shader programs:\n" - + (String)map.entrySet() - .stream() - .map(entry -> " - " + entry.getKey() + ": " + ((ShaderManager.CompilationException)entry.getValue()).getMessage()) - .collect(Collectors.joining("\n")) + "Failed to load required shader programs:\n" + (String)list.stream().map(resourceLocation -> " - " + resourceLocation).collect(Collectors.joining("\n")) ); } else { this.compilationCache.close(); @@ -280,94 +240,6 @@ public class ShaderManager extends SimplePreparableReloadListener externalTargets) { try { @@ -384,11 +256,13 @@ public class ShaderManager extends SimplePreparableReloadListener> programs = new HashMap(); - final Map shaders = new HashMap(); final Map> postChains = new HashMap(); boolean triggeredRecovery; @@ -396,51 +270,6 @@ public class ShaderManager extends SimplePreparableReloadListener optional = (Optional)this.programs.get(program); - if (optional != null) { - return (CompiledShaderProgram)optional.orElse(null); - } else { - CompiledShaderProgram compiledShaderProgram = this.compileProgram(program); - this.programs.put(program, Optional.of(compiledShaderProgram)); - return compiledShaderProgram; - } - } - - CompiledShaderProgram compileProgram(ShaderProgram program) throws ShaderManager.CompilationException { - ShaderProgramConfig shaderProgramConfig = (ShaderProgramConfig)this.configs.programs.get(program.configId()); - if (shaderProgramConfig == null) { - throw new ShaderManager.CompilationException("Could not find program with id: " + program.configId()); - } else { - ShaderDefines shaderDefines = shaderProgramConfig.defines().withOverrides(program.defines()); - CompiledShader compiledShader = this.getOrCompileShader(shaderProgramConfig.vertex(), Type.VERTEX, shaderDefines); - CompiledShader compiledShader2 = this.getOrCompileShader(shaderProgramConfig.fragment(), Type.FRAGMENT, shaderDefines); - return ShaderManager.linkProgram(program, shaderProgramConfig, compiledShader, compiledShader2); - } - } - - private CompiledShader getOrCompileShader(ResourceLocation id, Type type, ShaderDefines defines) throws ShaderManager.CompilationException { - ShaderManager.ShaderCompilationKey shaderCompilationKey = new ShaderManager.ShaderCompilationKey(id, type, defines); - CompiledShader compiledShader = (CompiledShader)this.shaders.get(shaderCompilationKey); - if (compiledShader == null) { - compiledShader = this.compileShader(shaderCompilationKey); - this.shaders.put(shaderCompilationKey, compiledShader); - } - - return compiledShader; - } - - private CompiledShader compileShader(ShaderManager.ShaderCompilationKey compilationKey) throws ShaderManager.CompilationException { - String string = (String)this.configs.shaderSources.get(new ShaderManager.ShaderSourceKey(compilationKey.id, compilationKey.type)); - if (string == null) { - throw new ShaderManager.CompilationException("Could not find shader: " + compilationKey); - } else { - String string2 = GlslPreprocessor.injectDefines(string, compilationKey.defines); - return CompiledShader.compile(compilationKey.id, compilationKey.type, string2); - } - } - @Nullable public PostChain getOrLoadPostChain(ResourceLocation name, Set externalTargets) throws ShaderManager.CompilationException { Optional optional = (Optional)this.postChains.get(name); @@ -458,18 +287,17 @@ public class ShaderManager extends SimplePreparableReloadListener optional.ifPresent(CompiledShaderProgram::close)); - this.shaders.values().forEach(CompiledShader::close); - this.programs.clear(); - this.shaders.clear(); this.postChains.clear(); } + + public String getShaderSource(ResourceLocation id, ShaderType type) { + return (String)this.configs.shaderSources.get(new ShaderManager.ShaderSourceKey(id, type)); + } } @Environment(EnvType.CLIENT) @@ -480,25 +308,12 @@ public class ShaderManager extends SimplePreparableReloadListener programs, - Map shaderSources, - Map postChains - ) { - public static final ShaderManager.Configs EMPTY = new ShaderManager.Configs(Map.of(), Map.of(), Map.of()); + public record Configs(Map shaderSources, Map postChains) { + public static final ShaderManager.Configs EMPTY = new ShaderManager.Configs(Map.of(), Map.of()); } @Environment(EnvType.CLIENT) - record ShaderCompilationKey(ResourceLocation id, Type type, ShaderDefines defines) { - - public String toString() { - String string = this.id + " (" + this.type + ")"; - return !this.defines.isEmpty() ? string + " with " + this.defines : string; - } - } - - @Environment(EnvType.CLIENT) - record ShaderSourceKey(ResourceLocation id, Type type) { + record ShaderSourceKey(ResourceLocation id, ShaderType type) { public String toString() { return this.id + " (" + this.type + ")"; } diff --git a/net/minecraft/client/renderer/ShaderProgram.java b/net/minecraft/client/renderer/ShaderProgram.java deleted file mode 100644 index 41a74d0c..00000000 --- a/net/minecraft/client/renderer/ShaderProgram.java +++ /dev/null @@ -1,14 +0,0 @@ -package net.minecraft.client.renderer; - -import com.mojang.blaze3d.vertex.VertexFormat; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.resources.ResourceLocation; - -@Environment(EnvType.CLIENT) -public record ShaderProgram(ResourceLocation configId, VertexFormat vertexFormat, ShaderDefines defines) { - public String toString() { - String string = this.configId + " (" + this.vertexFormat + ")"; - return !this.defines.isEmpty() ? string + " with " + this.defines : string; - } -} diff --git a/net/minecraft/client/renderer/ShaderProgramConfig.java b/net/minecraft/client/renderer/ShaderProgramConfig.java deleted file mode 100644 index c95ed835..00000000 --- a/net/minecraft/client/renderer/ShaderProgramConfig.java +++ /dev/null @@ -1,58 +0,0 @@ -package net.minecraft.client.renderer; - -import com.mojang.serialization.Codec; -import com.mojang.serialization.DataResult; -import com.mojang.serialization.codecs.RecordCodecBuilder; -import java.util.List; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.resources.ResourceLocation; - -@Environment(EnvType.CLIENT) -public record ShaderProgramConfig( - ResourceLocation vertex, - ResourceLocation fragment, - List samplers, - List uniforms, - ShaderDefines defines -) { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group( - ResourceLocation.CODEC.fieldOf("vertex").forGetter(ShaderProgramConfig::vertex), - ResourceLocation.CODEC.fieldOf("fragment").forGetter(ShaderProgramConfig::fragment), - ShaderProgramConfig.Sampler.CODEC.listOf().optionalFieldOf("samplers", List.of()).forGetter(ShaderProgramConfig::samplers), - ShaderProgramConfig.Uniform.CODEC.listOf().optionalFieldOf("uniforms", List.of()).forGetter(ShaderProgramConfig::uniforms), - ShaderDefines.CODEC.optionalFieldOf("defines", ShaderDefines.EMPTY).forGetter(ShaderProgramConfig::defines) - ) - .apply(instance, ShaderProgramConfig::new) - ); - - @Environment(EnvType.CLIENT) - public record Sampler(String name) { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group(Codec.STRING.fieldOf("name").forGetter(ShaderProgramConfig.Sampler::name)).apply(instance, ShaderProgramConfig.Sampler::new) - ); - } - - @Environment(EnvType.CLIENT) - public record Uniform(String name, String type, int count, List values) { - public static final Codec CODEC = RecordCodecBuilder.create( - instance -> instance.group( - Codec.STRING.fieldOf("name").forGetter(ShaderProgramConfig.Uniform::name), - Codec.STRING.fieldOf("type").forGetter(ShaderProgramConfig.Uniform::type), - Codec.INT.fieldOf("count").forGetter(ShaderProgramConfig.Uniform::count), - Codec.FLOAT.listOf().fieldOf("values").forGetter(ShaderProgramConfig.Uniform::values) - ) - .apply(instance, ShaderProgramConfig.Uniform::new) - ) - .validate(ShaderProgramConfig.Uniform::validate); - - private static DataResult validate(ShaderProgramConfig.Uniform uniform) { - int i = uniform.count; - int j = uniform.values.size(); - return j != i && j > 1 - ? DataResult.error(() -> "Invalid amount of uniform values specified (expected " + i + ", found " + j + ")") - : DataResult.success(uniform); - } - } -} diff --git a/net/minecraft/client/renderer/Sheets.java b/net/minecraft/client/renderer/Sheets.java index a3f6519b..39bf7c15 100644 --- a/net/minecraft/client/renderer/Sheets.java +++ b/net/minecraft/client/renderer/Sheets.java @@ -48,7 +48,17 @@ public class Sheets { private static final RenderType SOLID_BLOCK_SHEET = RenderType.entitySolid(TextureAtlas.LOCATION_BLOCKS); private static final RenderType CUTOUT_BLOCK_SHEET = RenderType.entityCutout(TextureAtlas.LOCATION_BLOCKS); private static final RenderType TRANSLUCENT_ITEM_CULL_BLOCK_SHEET = RenderType.itemEntityTranslucentCull(TextureAtlas.LOCATION_BLOCKS); - public static final Material DEFAULT_SHULKER_TEXTURE_LOCATION = createShulkerMaterial(ResourceLocation.withDefaultNamespace("shulker")); + public static final MaterialMapper ITEMS_MAPPER = new MaterialMapper(TextureAtlas.LOCATION_BLOCKS, "item"); + public static final MaterialMapper BLOCKS_MAPPER = new MaterialMapper(TextureAtlas.LOCATION_BLOCKS, "block"); + public static final MaterialMapper BANNER_MAPPER = new MaterialMapper(BANNER_SHEET, "entity/banner"); + public static final MaterialMapper SHIELD_MAPPER = new MaterialMapper(SHIELD_SHEET, "entity/shield"); + public static final MaterialMapper CHEST_MAPPER = new MaterialMapper(CHEST_SHEET, "entity/chest"); + public static final MaterialMapper DECORATED_POT_MAPPER = new MaterialMapper(DECORATED_POT_SHEET, "entity/decorated_pot"); + public static final MaterialMapper BED_MAPPER = new MaterialMapper(BED_SHEET, "entity/bed"); + public static final MaterialMapper SHULKER_MAPPER = new MaterialMapper(SHULKER_SHEET, "entity/shulker"); + public static final MaterialMapper SIGN_MAPPER = new MaterialMapper(SIGN_SHEET, "entity/signs"); + public static final MaterialMapper HANGING_SIGN_MAPPER = new MaterialMapper(SIGN_SHEET, "entity/signs/hanging"); + public static final Material DEFAULT_SHULKER_TEXTURE_LOCATION = SHULKER_MAPPER.defaultNamespaceApply("shulker"); public static final List SHULKER_TEXTURE_LOCATION = (List)Arrays.stream(DyeColor.values()) .sorted(Comparator.comparingInt(DyeColor::getId)) .map(Sheets::createShulkerMaterial) @@ -57,29 +67,29 @@ public class Sheets { .collect(Collectors.toMap(Function.identity(), Sheets::createSignMaterial)); public static final Map HANGING_SIGN_MATERIALS = (Map)WoodType.values() .collect(Collectors.toMap(Function.identity(), Sheets::createHangingSignMaterial)); - public static final Material BANNER_BASE = new Material(BANNER_SHEET, ResourceLocation.withDefaultNamespace("entity/banner/base")); - public static final Material SHIELD_BASE = new Material(SHIELD_SHEET, ResourceLocation.withDefaultNamespace("entity/shield/base")); + public static final Material BANNER_BASE = BANNER_MAPPER.defaultNamespaceApply("base"); + public static final Material SHIELD_BASE = SHIELD_MAPPER.defaultNamespaceApply("base"); private static final Map BANNER_MATERIALS = new HashMap(); private static final Map SHIELD_MATERIALS = new HashMap(); public static final Map, Material> DECORATED_POT_MATERIALS = (Map, Material>)BuiltInRegistries.DECORATED_POT_PATTERN .listElements() - .collect(Collectors.toMap(Reference::key, reference -> createDecoratedPotMaterial(((DecoratedPotPattern)reference.value()).assetId()))); - public static final Material DECORATED_POT_BASE = createDecoratedPotMaterial(ResourceLocation.withDefaultNamespace("decorated_pot_base")); - public static final Material DECORATED_POT_SIDE = createDecoratedPotMaterial(ResourceLocation.withDefaultNamespace("decorated_pot_side")); + .collect(Collectors.toMap(Reference::key, reference -> DECORATED_POT_MAPPER.apply(((DecoratedPotPattern)reference.value()).assetId()))); + public static final Material DECORATED_POT_BASE = DECORATED_POT_MAPPER.defaultNamespaceApply("decorated_pot_base"); + public static final Material DECORATED_POT_SIDE = DECORATED_POT_MAPPER.defaultNamespaceApply("decorated_pot_side"); private static final Material[] BED_TEXTURES = (Material[])Arrays.stream(DyeColor.values()) .sorted(Comparator.comparingInt(DyeColor::getId)) .map(Sheets::createBedMaterial) .toArray(Material[]::new); - public static final Material CHEST_TRAP_LOCATION = chestMaterial("trapped"); - public static final Material CHEST_TRAP_LOCATION_LEFT = chestMaterial("trapped_left"); - public static final Material CHEST_TRAP_LOCATION_RIGHT = chestMaterial("trapped_right"); - public static final Material CHEST_XMAS_LOCATION = chestMaterial("christmas"); - public static final Material CHEST_XMAS_LOCATION_LEFT = chestMaterial("christmas_left"); - public static final Material CHEST_XMAS_LOCATION_RIGHT = chestMaterial("christmas_right"); - public static final Material CHEST_LOCATION = chestMaterial("normal"); - public static final Material CHEST_LOCATION_LEFT = chestMaterial("normal_left"); - public static final Material CHEST_LOCATION_RIGHT = chestMaterial("normal_right"); - public static final Material ENDER_CHEST_LOCATION = chestMaterial("ender"); + public static final Material CHEST_TRAP_LOCATION = CHEST_MAPPER.defaultNamespaceApply("trapped"); + public static final Material CHEST_TRAP_LOCATION_LEFT = CHEST_MAPPER.defaultNamespaceApply("trapped_left"); + public static final Material CHEST_TRAP_LOCATION_RIGHT = CHEST_MAPPER.defaultNamespaceApply("trapped_right"); + public static final Material CHEST_XMAS_LOCATION = CHEST_MAPPER.defaultNamespaceApply("christmas"); + public static final Material CHEST_XMAS_LOCATION_LEFT = CHEST_MAPPER.defaultNamespaceApply("christmas_left"); + public static final Material CHEST_XMAS_LOCATION_RIGHT = CHEST_MAPPER.defaultNamespaceApply("christmas_right"); + public static final Material CHEST_LOCATION = CHEST_MAPPER.defaultNamespaceApply("normal"); + public static final Material CHEST_LOCATION_LEFT = CHEST_MAPPER.defaultNamespaceApply("normal_left"); + public static final Material CHEST_LOCATION_RIGHT = CHEST_MAPPER.defaultNamespaceApply("normal_right"); + public static final Material ENDER_CHEST_LOCATION = CHEST_MAPPER.defaultNamespaceApply("ender"); public static RenderType bannerSheet() { return BANNER_SHEET_TYPE; @@ -134,11 +144,7 @@ public class Sheets { } public static Material createBedMaterial(DyeColor color) { - return createBedMaterial(colorToResourceMaterial(color)); - } - - public static Material createBedMaterial(ResourceLocation assetId) { - return new Material(BED_SHEET, assetId.withPrefix("entity/bed/")); + return BED_MAPPER.apply(colorToResourceMaterial(color)); } public static Material getShulkerBoxMaterial(DyeColor color) { @@ -150,27 +156,15 @@ public class Sheets { } public static Material createShulkerMaterial(DyeColor color) { - return createShulkerMaterial(colorToShulkerMaterial(color)); - } - - public static Material createShulkerMaterial(ResourceLocation assetId) { - return new Material(SHULKER_SHEET, assetId.withPrefix("entity/shulker/")); + return SHULKER_MAPPER.apply(colorToShulkerMaterial(color)); } private static Material createSignMaterial(WoodType woodType) { - return createSignMaterial(ResourceLocation.withDefaultNamespace(woodType.name())); - } - - public static Material createSignMaterial(ResourceLocation assetId) { - return new Material(SIGN_SHEET, assetId.withPrefix("entity/signs/")); + return SIGN_MAPPER.defaultNamespaceApply(woodType.name()); } private static Material createHangingSignMaterial(WoodType woodType) { - return createHangingSignMaterial(ResourceLocation.withDefaultNamespace(woodType.name())); - } - - public static Material createHangingSignMaterial(ResourceLocation assetId) { - return new Material(SIGN_SHEET, assetId.withPrefix("entity/signs/hanging/")); + return HANGING_SIGN_MAPPER.defaultNamespaceApply(woodType.name()); } public static Material getSignMaterial(WoodType woodType) { @@ -182,29 +176,11 @@ public class Sheets { } public static Material getBannerMaterial(Holder pattern) { - return (Material)BANNER_MATERIALS.computeIfAbsent(pattern.value().assetId(), resourceLocation -> { - ResourceLocation resourceLocation2 = resourceLocation.withPrefix("entity/banner/"); - return new Material(BANNER_SHEET, resourceLocation2); - }); + return (Material)BANNER_MATERIALS.computeIfAbsent(pattern.value().assetId(), BANNER_MAPPER::apply); } public static Material getShieldMaterial(Holder pattern) { - return (Material)SHIELD_MATERIALS.computeIfAbsent(pattern.value().assetId(), resourceLocation -> { - ResourceLocation resourceLocation2 = resourceLocation.withPrefix("entity/shield/"); - return new Material(SHIELD_SHEET, resourceLocation2); - }); - } - - private static Material chestMaterial(String chestName) { - return new Material(CHEST_SHEET, ResourceLocation.withDefaultNamespace("entity/chest/" + chestName)); - } - - public static Material chestMaterial(ResourceLocation assetId) { - return new Material(CHEST_SHEET, assetId.withPrefix("entity/chest/")); - } - - private static Material createDecoratedPotMaterial(ResourceLocation assetId) { - return new Material(DECORATED_POT_SHEET, assetId.withPrefix("entity/decorated_pot/")); + return (Material)SHIELD_MATERIALS.computeIfAbsent(pattern.value().assetId(), SHIELD_MAPPER::apply); } @Nullable diff --git a/net/minecraft/client/renderer/SkyRenderer.java b/net/minecraft/client/renderer/SkyRenderer.java index 58295b01..81723e9a 100644 --- a/net/minecraft/client/renderer/SkyRenderer.java +++ b/net/minecraft/client/renderer/SkyRenderer.java @@ -1,19 +1,33 @@ package net.minecraft.client.renderer; +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; +import com.mojang.blaze3d.vertex.BufferBuilder; +import com.mojang.blaze3d.vertex.ByteBufferBuilder; import com.mojang.blaze3d.vertex.DefaultVertexFormat; +import com.mojang.blaze3d.vertex.MeshData; import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexBuffer; import com.mojang.blaze3d.vertex.VertexConsumer; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; +import com.mojang.blaze3d.vertex.VertexFormat; import com.mojang.math.Axis; +import java.util.OptionalDouble; +import java.util.OptionalInt; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.MultiBufferSource.BufferSource; +import net.minecraft.client.renderer.texture.AbstractTexture; +import net.minecraft.client.renderer.texture.TextureManager; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.ARGB; import net.minecraft.util.Mth; import net.minecraft.util.RandomSource; +import net.minecraft.util.TriState; import org.joml.Matrix3f; import org.joml.Matrix4f; import org.joml.Matrix4fStack; @@ -25,38 +39,73 @@ public class SkyRenderer implements AutoCloseable { private static final ResourceLocation MOON_LOCATION = ResourceLocation.withDefaultNamespace("textures/environment/moon_phases.png"); public static final ResourceLocation END_SKY_LOCATION = ResourceLocation.withDefaultNamespace("textures/environment/end_sky.png"); private static final float SKY_DISC_RADIUS = 512.0F; - private final VertexBuffer starBuffer = VertexBuffer.uploadStatic(Mode.QUADS, DefaultVertexFormat.POSITION, this::buildStars); - private final VertexBuffer topSkyBuffer = VertexBuffer.uploadStatic( - Mode.TRIANGLE_FAN, DefaultVertexFormat.POSITION, vertexConsumer -> this.buildSkyDisc(vertexConsumer, 16.0F) - ); - private final VertexBuffer bottomSkyBuffer = VertexBuffer.uploadStatic( - Mode.TRIANGLE_FAN, DefaultVertexFormat.POSITION, vertexConsumer -> this.buildSkyDisc(vertexConsumer, -16.0F) - ); - private final VertexBuffer endSkyBuffer = VertexBuffer.uploadStatic(Mode.QUADS, DefaultVertexFormat.POSITION_TEX_COLOR, this::buildEndSky); + private static final int SKY_VERTICES = 10; + private static final int STAR_COUNT = 1500; + private static final int END_SKY_QUAD_COUNT = 6; + private final GpuBuffer starBuffer; + private final RenderSystem.AutoStorageIndexBuffer starIndices = RenderSystem.getSequentialBuffer(VertexFormat.Mode.QUADS); + private final GpuBuffer topSkyBuffer; + private final GpuBuffer bottomSkyBuffer; + private final GpuBuffer endSkyBuffer; + private int starIndexCount; - private void buildStars(VertexConsumer buffer) { - RandomSource randomSource = RandomSource.create(10842L); - int i = 1500; - float f = 100.0F; + public SkyRenderer() { + this.starBuffer = this.buildStars(); + this.endSkyBuffer = buildEndSky(); - for (int j = 0; j < 1500; j++) { - float g = randomSource.nextFloat() * 2.0F - 1.0F; - float h = randomSource.nextFloat() * 2.0F - 1.0F; - float k = randomSource.nextFloat() * 2.0F - 1.0F; - float l = 0.15F + randomSource.nextFloat() * 0.1F; - float m = Mth.lengthSquared(g, h, k); - if (!(m <= 0.010000001F) && !(m >= 1.0F)) { - Vector3f vector3f = new Vector3f(g, h, k).normalize(100.0F); - float n = (float)(randomSource.nextDouble() * (float) Math.PI * 2.0); - Matrix3f matrix3f = new Matrix3f().rotateTowards(new Vector3f(vector3f).negate(), new Vector3f(0.0F, 1.0F, 0.0F)).rotateZ(-n); - buffer.addVertex(new Vector3f(l, -l, 0.0F).mul(matrix3f).add(vector3f)); - buffer.addVertex(new Vector3f(l, l, 0.0F).mul(matrix3f).add(vector3f)); - buffer.addVertex(new Vector3f(-l, l, 0.0F).mul(matrix3f).add(vector3f)); - buffer.addVertex(new Vector3f(-l, -l, 0.0F).mul(matrix3f).add(vector3f)); + try (ByteBufferBuilder byteBufferBuilder = new ByteBufferBuilder(10 * DefaultVertexFormat.POSITION.getVertexSize())) { + BufferBuilder bufferBuilder = new BufferBuilder(byteBufferBuilder, VertexFormat.Mode.TRIANGLE_FAN, DefaultVertexFormat.POSITION); + this.buildSkyDisc(bufferBuilder, 16.0F); + + try (MeshData meshData = bufferBuilder.buildOrThrow()) { + this.topSkyBuffer = RenderSystem.getDevice() + .createBuffer(() -> "Top sky vertex buffer", BufferType.VERTICES, BufferUsage.STATIC_WRITE, meshData.vertexBuffer()); + } + + bufferBuilder = new BufferBuilder(byteBufferBuilder, VertexFormat.Mode.TRIANGLE_FAN, DefaultVertexFormat.POSITION); + this.buildSkyDisc(bufferBuilder, -16.0F); + + try (MeshData meshData = bufferBuilder.buildOrThrow()) { + this.bottomSkyBuffer = RenderSystem.getDevice() + .createBuffer(() -> "Bottom sky vertex buffer", BufferType.VERTICES, BufferUsage.STATIC_WRITE, meshData.vertexBuffer()); } } } + private GpuBuffer buildStars() { + RandomSource randomSource = RandomSource.create(10842L); + float f = 100.0F; + + GpuBuffer var19; + try (ByteBufferBuilder byteBufferBuilder = new ByteBufferBuilder(DefaultVertexFormat.POSITION.getVertexSize() * 1500 * 4)) { + BufferBuilder bufferBuilder = new BufferBuilder(byteBufferBuilder, VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION); + + for (int i = 0; i < 1500; i++) { + float g = randomSource.nextFloat() * 2.0F - 1.0F; + float h = randomSource.nextFloat() * 2.0F - 1.0F; + float j = randomSource.nextFloat() * 2.0F - 1.0F; + float k = 0.15F + randomSource.nextFloat() * 0.1F; + float l = Mth.lengthSquared(g, h, j); + if (!(l <= 0.010000001F) && !(l >= 1.0F)) { + Vector3f vector3f = new Vector3f(g, h, j).normalize(100.0F); + float m = (float)(randomSource.nextDouble() * (float) Math.PI * 2.0); + Matrix3f matrix3f = new Matrix3f().rotateTowards(new Vector3f(vector3f).negate(), new Vector3f(0.0F, 1.0F, 0.0F)).rotateZ(-m); + bufferBuilder.addVertex(new Vector3f(k, -k, 0.0F).mul(matrix3f).add(vector3f)); + bufferBuilder.addVertex(new Vector3f(k, k, 0.0F).mul(matrix3f).add(vector3f)); + bufferBuilder.addVertex(new Vector3f(-k, k, 0.0F).mul(matrix3f).add(vector3f)); + bufferBuilder.addVertex(new Vector3f(-k, -k, 0.0F).mul(matrix3f).add(vector3f)); + } + } + + try (MeshData meshData = bufferBuilder.buildOrThrow()) { + this.starIndexCount = meshData.drawState().indexCount(); + var19 = RenderSystem.getDevice().createBuffer(() -> "Stars vertex buffer", BufferType.VERTICES, BufferUsage.STATIC_WRITE, meshData.vertexBuffer()); + } + } + + return var19; + } + private void buildSkyDisc(VertexConsumer buffer, float y) { float f = Math.signum(y) * 512.0F; buffer.addVertex(0.0F, y, 0.0F); @@ -68,16 +117,37 @@ public class SkyRenderer implements AutoCloseable { public void renderSkyDisc(float red, float green, float blue) { RenderSystem.setShaderColor(red, green, blue, 1.0F); - this.topSkyBuffer.drawWithRenderType(RenderType.sky()); + GpuTexture gpuTexture = Minecraft.getInstance().getMainRenderTarget().getColorTexture(); + GpuTexture gpuTexture2 = Minecraft.getInstance().getMainRenderTarget().getDepthTexture(); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass(gpuTexture, OptionalInt.empty(), gpuTexture2, OptionalDouble.empty())) { + renderPass.setPipeline(RenderPipelines.SKY); + renderPass.setVertexBuffer(0, this.topSkyBuffer); + renderPass.draw(0, 10); + } + RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); } - public void renderDarkDisc(PoseStack poseStack) { + public void renderDarkDisc() { RenderSystem.setShaderColor(0.0F, 0.0F, 0.0F, 1.0F); - poseStack.pushPose(); - poseStack.translate(0.0F, 12.0F, 0.0F); - this.bottomSkyBuffer.drawWithRenderType(RenderType.sky()); - poseStack.popPose(); + Matrix4fStack matrix4fStack = RenderSystem.getModelViewStack(); + matrix4fStack.pushMatrix(); + matrix4fStack.translate(0.0F, 12.0F, 0.0F); + GpuTexture gpuTexture = Minecraft.getInstance().getMainRenderTarget().getColorTexture(); + GpuTexture gpuTexture2 = Minecraft.getInstance().getMainRenderTarget().getDepthTexture(); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass(gpuTexture, OptionalInt.empty(), gpuTexture2, OptionalDouble.empty())) { + renderPass.setPipeline(RenderPipelines.SKY); + renderPass.setVertexBuffer(0, this.bottomSkyBuffer); + renderPass.draw(0, 10); + } + + matrix4fStack.popMatrix(); RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); } @@ -133,7 +203,20 @@ public class SkyRenderer implements AutoCloseable { matrix4fStack.mul(poseStack.last().pose()); RenderSystem.setShaderColor(starBrightness, starBrightness, starBrightness, starBrightness); RenderSystem.setShaderFog(FogParameters.NO_FOG); - this.starBuffer.drawWithRenderType(RenderType.stars()); + RenderPipeline renderPipeline = RenderPipelines.STARS; + GpuTexture gpuTexture = Minecraft.getInstance().getMainRenderTarget().getColorTexture(); + GpuTexture gpuTexture2 = Minecraft.getInstance().getMainRenderTarget().getDepthTexture(); + GpuBuffer gpuBuffer = this.starIndices.getBuffer(this.starIndexCount); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass(gpuTexture, OptionalInt.empty(), gpuTexture2, OptionalDouble.empty())) { + renderPass.setPipeline(renderPipeline); + renderPass.setVertexBuffer(0, this.starBuffer); + renderPass.setIndexBuffer(gpuBuffer, this.starIndices.type()); + renderPass.drawIndexed(0, this.starIndexCount); + } + RenderSystem.setShaderFog(fog); RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); matrix4fStack.popMatrix(); @@ -162,35 +245,62 @@ public class SkyRenderer implements AutoCloseable { poseStack.popPose(); } - private void buildEndSky(VertexConsumer buffer) { - for (int i = 0; i < 6; i++) { - Matrix4f matrix4f = new Matrix4f(); - switch (i) { - case 1: - matrix4f.rotationX((float) (Math.PI / 2)); - break; - case 2: - matrix4f.rotationX((float) (-Math.PI / 2)); - break; - case 3: - matrix4f.rotationX((float) Math.PI); - break; - case 4: - matrix4f.rotationZ((float) (Math.PI / 2)); - break; - case 5: - matrix4f.rotationZ((float) (-Math.PI / 2)); + private static GpuBuffer buildEndSky() { + GpuBuffer var10; + try (ByteBufferBuilder byteBufferBuilder = new ByteBufferBuilder(24 * DefaultVertexFormat.POSITION_TEX_COLOR.getVertexSize())) { + BufferBuilder bufferBuilder = new BufferBuilder(byteBufferBuilder, VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION_TEX_COLOR); + + for (int i = 0; i < 6; i++) { + Matrix4f matrix4f = new Matrix4f(); + switch (i) { + case 1: + matrix4f.rotationX((float) (Math.PI / 2)); + break; + case 2: + matrix4f.rotationX((float) (-Math.PI / 2)); + break; + case 3: + matrix4f.rotationX((float) Math.PI); + break; + case 4: + matrix4f.rotationZ((float) (Math.PI / 2)); + break; + case 5: + matrix4f.rotationZ((float) (-Math.PI / 2)); + } + + bufferBuilder.addVertex(matrix4f, -100.0F, -100.0F, -100.0F).setUv(0.0F, 0.0F).setColor(-14145496); + bufferBuilder.addVertex(matrix4f, -100.0F, -100.0F, 100.0F).setUv(0.0F, 16.0F).setColor(-14145496); + bufferBuilder.addVertex(matrix4f, 100.0F, -100.0F, 100.0F).setUv(16.0F, 16.0F).setColor(-14145496); + bufferBuilder.addVertex(matrix4f, 100.0F, -100.0F, -100.0F).setUv(16.0F, 0.0F).setColor(-14145496); } - buffer.addVertex(matrix4f, -100.0F, -100.0F, -100.0F).setUv(0.0F, 0.0F).setColor(-14145496); - buffer.addVertex(matrix4f, -100.0F, -100.0F, 100.0F).setUv(0.0F, 16.0F).setColor(-14145496); - buffer.addVertex(matrix4f, 100.0F, -100.0F, 100.0F).setUv(16.0F, 16.0F).setColor(-14145496); - buffer.addVertex(matrix4f, 100.0F, -100.0F, -100.0F).setUv(16.0F, 0.0F).setColor(-14145496); + try (MeshData meshData = bufferBuilder.buildOrThrow()) { + var10 = RenderSystem.getDevice().createBuffer(() -> "End sky vertex buffer", BufferType.VERTICES, BufferUsage.STATIC_WRITE, meshData.vertexBuffer()); + } } + + return var10; } public void renderEndSky() { - this.endSkyBuffer.drawWithRenderType(RenderType.endSky()); + TextureManager textureManager = Minecraft.getInstance().getTextureManager(); + AbstractTexture abstractTexture = textureManager.getTexture(END_SKY_LOCATION); + abstractTexture.setFilter(TriState.FALSE, false); + RenderSystem.AutoStorageIndexBuffer autoStorageIndexBuffer = RenderSystem.getSequentialBuffer(VertexFormat.Mode.QUADS); + GpuBuffer gpuBuffer = autoStorageIndexBuffer.getBuffer(36); + GpuTexture gpuTexture = Minecraft.getInstance().getMainRenderTarget().getColorTexture(); + GpuTexture gpuTexture2 = Minecraft.getInstance().getMainRenderTarget().getDepthTexture(); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass(gpuTexture, OptionalInt.empty(), gpuTexture2, OptionalDouble.empty())) { + renderPass.setPipeline(RenderPipelines.END_SKY); + renderPass.bindSampler("Sampler0", abstractTexture.getTexture()); + renderPass.setVertexBuffer(0, this.endSkyBuffer); + renderPass.setIndexBuffer(gpuBuffer, autoStorageIndexBuffer.type()); + renderPass.drawIndexed(0, 36); + } } public void close() { diff --git a/net/minecraft/client/renderer/ViewArea.java b/net/minecraft/client/renderer/ViewArea.java index 03e1d4a9..39a2c535 100644 --- a/net/minecraft/client/renderer/ViewArea.java +++ b/net/minecraft/client/renderer/ViewArea.java @@ -49,7 +49,7 @@ public class ViewArea { public void releaseAllBuffers() { for (SectionRenderDispatcher.RenderSection renderSection : this.sections) { - renderSection.releaseBuffers(); + renderSection.reset(); } } diff --git a/net/minecraft/client/renderer/WorldBorderRenderer.java b/net/minecraft/client/renderer/WorldBorderRenderer.java index 2084c3bb..78799ca5 100644 --- a/net/minecraft/client/renderer/WorldBorderRenderer.java +++ b/net/minecraft/client/renderer/WorldBorderRenderer.java @@ -1,121 +1,182 @@ package net.minecraft.client.renderer; +import com.mojang.blaze3d.buffers.BufferType; +import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.pipeline.RenderPipeline; +import com.mojang.blaze3d.pipeline.RenderTarget; +import com.mojang.blaze3d.systems.RenderPass; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.blaze3d.vertex.BufferBuilder; -import com.mojang.blaze3d.vertex.BufferUploader; +import com.mojang.blaze3d.vertex.ByteBufferBuilder; import com.mojang.blaze3d.vertex.DefaultVertexFormat; import com.mojang.blaze3d.vertex.MeshData; -import com.mojang.blaze3d.vertex.Tesselator; -import com.mojang.blaze3d.vertex.VertexFormat.Mode; +import com.mojang.blaze3d.vertex.VertexFormat; +import java.util.ArrayList; +import java.util.OptionalDouble; +import java.util.OptionalInt; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.Util; import net.minecraft.client.Minecraft; +import net.minecraft.client.renderer.texture.AbstractTexture; +import net.minecraft.client.renderer.texture.TextureManager; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.ARGB; import net.minecraft.util.Mth; +import net.minecraft.util.TriState; import net.minecraft.world.level.border.WorldBorder; import net.minecraft.world.phys.Vec3; +import org.joml.Matrix4f; @Environment(EnvType.CLIENT) public class WorldBorderRenderer { public static final ResourceLocation FORCEFIELD_LOCATION = ResourceLocation.withDefaultNamespace("textures/misc/forcefield.png"); + private boolean needsRebuild = true; + private double lastMinX; + private double lastMinZ; + private double lastBorderMinX; + private double lastBorderMaxX; + private double lastBorderMinZ; + private double lastBorderMaxZ; + private final GpuBuffer worldBorderBuffer = RenderSystem.getDevice() + .createBuffer(() -> "World border vertex buffer", BufferType.VERTICES, BufferUsage.DYNAMIC_WRITE, 16 * DefaultVertexFormat.POSITION_TEX.getVertexSize()); + private final RenderSystem.AutoStorageIndexBuffer indices = RenderSystem.getSequentialBuffer(VertexFormat.Mode.QUADS); + + private void rebuildWorldBorderBuffer(WorldBorder worldBorder, double renderDistance, double camZ, double camX, float farPlaneDepth, float vBottom, float vTop) { + try (ByteBufferBuilder byteBufferBuilder = new ByteBufferBuilder(DefaultVertexFormat.POSITION_TEX.getVertexSize() * 4)) { + double d = worldBorder.getMinX(); + double e = worldBorder.getMaxX(); + double f = worldBorder.getMinZ(); + double g = worldBorder.getMaxZ(); + double h = Math.max(Mth.floor(camZ - renderDistance), f); + double i = Math.min(Mth.ceil(camZ + renderDistance), g); + float j = (Mth.floor(h) & 1) * 0.5F; + float k = (float)(i - h) / 2.0F; + double l = Math.max(Mth.floor(camX - renderDistance), d); + double m = Math.min(Mth.ceil(camX + renderDistance), e); + float n = (Mth.floor(l) & 1) * 0.5F; + float o = (float)(m - l) / 2.0F; + BufferBuilder bufferBuilder = new BufferBuilder(byteBufferBuilder, VertexFormat.Mode.QUADS, DefaultVertexFormat.POSITION_TEX); + bufferBuilder.addVertex(0.0F, -farPlaneDepth, (float)(g - h)).setUv(n, vBottom); + bufferBuilder.addVertex((float)(m - l), -farPlaneDepth, (float)(g - h)).setUv(o + n, vBottom); + bufferBuilder.addVertex((float)(m - l), farPlaneDepth, (float)(g - h)).setUv(o + n, vTop); + bufferBuilder.addVertex(0.0F, farPlaneDepth, (float)(g - h)).setUv(n, vTop); + bufferBuilder.addVertex(0.0F, -farPlaneDepth, 0.0F).setUv(j, vBottom); + bufferBuilder.addVertex(0.0F, -farPlaneDepth, (float)(i - h)).setUv(k + j, vBottom); + bufferBuilder.addVertex(0.0F, farPlaneDepth, (float)(i - h)).setUv(k + j, vTop); + bufferBuilder.addVertex(0.0F, farPlaneDepth, 0.0F).setUv(j, vTop); + bufferBuilder.addVertex((float)(m - l), -farPlaneDepth, 0.0F).setUv(n, vBottom); + bufferBuilder.addVertex(0.0F, -farPlaneDepth, 0.0F).setUv(o + n, vBottom); + bufferBuilder.addVertex(0.0F, farPlaneDepth, 0.0F).setUv(o + n, vTop); + bufferBuilder.addVertex((float)(m - l), farPlaneDepth, 0.0F).setUv(n, vTop); + bufferBuilder.addVertex((float)(e - l), -farPlaneDepth, (float)(i - h)).setUv(j, vBottom); + bufferBuilder.addVertex((float)(e - l), -farPlaneDepth, 0.0F).setUv(k + j, vBottom); + bufferBuilder.addVertex((float)(e - l), farPlaneDepth, 0.0F).setUv(k + j, vTop); + bufferBuilder.addVertex((float)(e - l), farPlaneDepth, (float)(i - h)).setUv(j, vTop); + + try (MeshData meshData = bufferBuilder.buildOrThrow()) { + RenderSystem.getDevice().createCommandEncoder().writeToBuffer(this.worldBorderBuffer, meshData.vertexBuffer(), 0); + } + + this.lastBorderMinX = d; + this.lastBorderMaxX = e; + this.lastBorderMinZ = f; + this.lastBorderMaxZ = g; + this.lastMinX = l; + this.lastMinZ = h; + this.needsRebuild = false; + } + } public void render(WorldBorder worldBorder, Vec3 cameraPosition, double renderDistance, double farPlaneDepth) { double d = worldBorder.getMinX(); double e = worldBorder.getMaxX(); double f = worldBorder.getMinZ(); double g = worldBorder.getMaxZ(); - if (!(cameraPosition.x < e - renderDistance) - || !(cameraPosition.x > d + renderDistance) - || !(cameraPosition.z < g - renderDistance) - || !(cameraPosition.z > f + renderDistance)) { + if (( + !(cameraPosition.x < e - renderDistance) + || !(cameraPosition.x > d + renderDistance) + || !(cameraPosition.z < g - renderDistance) + || !(cameraPosition.z > f + renderDistance) + ) + && !(cameraPosition.x < d - renderDistance) + && !(cameraPosition.x > e + renderDistance) + && !(cameraPosition.z < f - renderDistance) + && !(cameraPosition.z > g + renderDistance)) { double h = 1.0 - worldBorder.getDistanceToBorder(cameraPosition.x, cameraPosition.z) / renderDistance; h = Math.pow(h, 4.0); h = Mth.clamp(h, 0.0, 1.0); double i = cameraPosition.x; double j = cameraPosition.z; float k = (float)farPlaneDepth; - RenderType renderType = RenderType.worldBorder(Minecraft.useShaderTransparency()); - renderType.setupRenderState(); int l = worldBorder.getStatus().getColor(); float m = ARGB.red(l) / 255.0F; float n = ARGB.green(l) / 255.0F; float o = ARGB.blue(l) / 255.0F; RenderSystem.setShaderColor(m, n, o, (float)h); float p = (float)(Util.getMillis() % 3000L) / 3000.0F; + RenderSystem.setTextureMatrix(new Matrix4f().translation(p, p, 0.0F)); float q = (float)(-Mth.frac(cameraPosition.y * 0.5)); float r = q + k; - BufferBuilder bufferBuilder = Tesselator.getInstance().begin(Mode.QUADS, DefaultVertexFormat.POSITION_TEX); - double s = Math.max(Mth.floor(j - renderDistance), f); - double t = Math.min(Mth.ceil(j + renderDistance), g); - float u = (Mth.floor(s) & 1) * 0.5F; - if (i > e - renderDistance) { - float v = u; + if (this.shouldRebuildWorldBorderBuffer(worldBorder)) { + this.rebuildWorldBorderBuffer(worldBorder, renderDistance, j, i, k, r, q); + } - for (double w = s; w < t; v += 0.5F) { - double x = Math.min(1.0, t - w); - float y = (float)x * 0.5F; - bufferBuilder.addVertex((float)(e - i), -k, (float)(w - j)).setUv(p - v, p + r); - bufferBuilder.addVertex((float)(e - i), -k, (float)(w + x - j)).setUv(p - (y + v), p + r); - bufferBuilder.addVertex((float)(e - i), k, (float)(w + x - j)).setUv(p - (y + v), p + q); - bufferBuilder.addVertex((float)(e - i), k, (float)(w - j)).setUv(p - v, p + q); - w++; + RenderSystem.setModelOffset((float)(this.lastMinX - i), (float)(-cameraPosition.y), (float)(this.lastMinZ - j)); + TextureManager textureManager = Minecraft.getInstance().getTextureManager(); + AbstractTexture abstractTexture = textureManager.getTexture(FORCEFIELD_LOCATION); + abstractTexture.setFilter(TriState.FALSE, false); + RenderPipeline renderPipeline = RenderPipelines.WORLD_BORDER; + RenderTarget renderTarget = Minecraft.getInstance().getMainRenderTarget(); + RenderTarget renderTarget2 = Minecraft.getInstance().levelRenderer.getWeatherTarget(); + GpuTexture gpuTexture; + GpuTexture gpuTexture2; + if (renderTarget2 != null) { + gpuTexture = renderTarget2.getColorTexture(); + gpuTexture2 = renderTarget2.getDepthTexture(); + } else { + gpuTexture = renderTarget.getColorTexture(); + gpuTexture2 = renderTarget.getDepthTexture(); + } + + GpuBuffer gpuBuffer = this.indices.getBuffer(6); + + try (RenderPass renderPass = RenderSystem.getDevice() + .createCommandEncoder() + .createRenderPass(gpuTexture, OptionalInt.empty(), gpuTexture2, OptionalDouble.empty())) { + renderPass.setPipeline(renderPipeline); + renderPass.setIndexBuffer(gpuBuffer, this.indices.type()); + renderPass.bindSampler("Sampler0", abstractTexture.getTexture()); + renderPass.setVertexBuffer(0, this.worldBorderBuffer); + ArrayList arrayList = new ArrayList(); + + for (WorldBorder.DistancePerDirection distancePerDirection : worldBorder.closestBorder(i, j)) { + if (distancePerDirection.distance() < renderDistance) { + int s = distancePerDirection.direction().get2DDataValue(); + arrayList.add(new RenderPass.Draw(0, this.worldBorderBuffer, gpuBuffer, this.indices.type(), 6 * s, 6)); + } } + + renderPass.drawMultipleIndexed(arrayList, null, null); } - if (i < d + renderDistance) { - float v = u; - - for (double w = s; w < t; v += 0.5F) { - double x = Math.min(1.0, t - w); - float y = (float)x * 0.5F; - bufferBuilder.addVertex((float)(d - i), -k, (float)(w - j)).setUv(p + v, p + r); - bufferBuilder.addVertex((float)(d - i), -k, (float)(w + x - j)).setUv(p + y + v, p + r); - bufferBuilder.addVertex((float)(d - i), k, (float)(w + x - j)).setUv(p + y + v, p + q); - bufferBuilder.addVertex((float)(d - i), k, (float)(w - j)).setUv(p + v, p + q); - w++; - } - } - - s = Math.max(Mth.floor(i - renderDistance), d); - t = Math.min(Mth.ceil(i + renderDistance), e); - u = (Mth.floor(s) & 1) * 0.5F; - if (j > g - renderDistance) { - float v = u; - - for (double w = s; w < t; v += 0.5F) { - double x = Math.min(1.0, t - w); - float y = (float)x * 0.5F; - bufferBuilder.addVertex((float)(w - i), -k, (float)(g - j)).setUv(p + v, p + r); - bufferBuilder.addVertex((float)(w + x - i), -k, (float)(g - j)).setUv(p + y + v, p + r); - bufferBuilder.addVertex((float)(w + x - i), k, (float)(g - j)).setUv(p + y + v, p + q); - bufferBuilder.addVertex((float)(w - i), k, (float)(g - j)).setUv(p + v, p + q); - w++; - } - } - - if (j < f + renderDistance) { - float v = u; - - for (double w = s; w < t; v += 0.5F) { - double x = Math.min(1.0, t - w); - float y = (float)x * 0.5F; - bufferBuilder.addVertex((float)(w - i), -k, (float)(f - j)).setUv(p - v, p + r); - bufferBuilder.addVertex((float)(w + x - i), -k, (float)(f - j)).setUv(p - (y + v), p + r); - bufferBuilder.addVertex((float)(w + x - i), k, (float)(f - j)).setUv(p - (y + v), p + q); - bufferBuilder.addVertex((float)(w - i), k, (float)(f - j)).setUv(p - v, p + q); - w++; - } - } - - MeshData meshData = bufferBuilder.build(); - if (meshData != null) { - BufferUploader.drawWithShader(meshData); - } - - renderType.clearRenderState(); RenderSystem.setShaderColor(1.0F, 1.0F, 1.0F, 1.0F); + RenderSystem.resetTextureMatrix(); + RenderSystem.resetModelOffset(); } } + + public void invalidate() { + this.needsRebuild = true; + } + + private boolean shouldRebuildWorldBorderBuffer(WorldBorder worldBorder) { + return this.needsRebuild + || worldBorder.getMinX() != this.lastBorderMinX + || worldBorder.getMinZ() != this.lastBorderMinZ + || worldBorder.getMaxX() != this.lastBorderMaxX + || worldBorder.getMaxZ() != this.lastBorderMaxZ; + } } diff --git a/net/minecraft/client/renderer/block/BlockModelShaper.java b/net/minecraft/client/renderer/block/BlockModelShaper.java index a71e9047..0e940fc0 100644 --- a/net/minecraft/client/renderer/block/BlockModelShaper.java +++ b/net/minecraft/client/renderer/block/BlockModelShaper.java @@ -1,21 +1,16 @@ package net.minecraft.client.renderer.block; import java.util.Map; -import java.util.Map.Entry; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.client.resources.model.BakedModel; import net.minecraft.client.resources.model.ModelManager; -import net.minecraft.client.resources.model.ModelResourceLocation; -import net.minecraft.core.registries.BuiltInRegistries; -import net.minecraft.resources.ResourceLocation; import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.Property; @Environment(EnvType.CLIENT) public class BlockModelShaper { - private Map modelByStateCache = Map.of(); + private Map modelByStateCache = Map.of(); private final ModelManager modelManager; public BlockModelShaper(ModelManager modelManager) { @@ -23,52 +18,23 @@ public class BlockModelShaper { } public TextureAtlasSprite getParticleIcon(BlockState state) { - return this.getBlockModel(state).getParticleIcon(); + return this.getBlockModel(state).particleIcon(); } - public BakedModel getBlockModel(BlockState state) { - BakedModel bakedModel = (BakedModel)this.modelByStateCache.get(state); - if (bakedModel == null) { - bakedModel = this.modelManager.getMissingModel(); + public BlockStateModel getBlockModel(BlockState state) { + BlockStateModel blockStateModel = (BlockStateModel)this.modelByStateCache.get(state); + if (blockStateModel == null) { + blockStateModel = this.modelManager.getMissingBlockStateModel(); } - return bakedModel; + return blockStateModel; } public ModelManager getModelManager() { return this.modelManager; } - public void replaceCache(Map modelByStateCache) { + public void replaceCache(Map modelByStateCache) { this.modelByStateCache = modelByStateCache; } - - public static ModelResourceLocation stateToModelLocation(BlockState state) { - return stateToModelLocation(BuiltInRegistries.BLOCK.getKey(state.getBlock()), state); - } - - public static ModelResourceLocation stateToModelLocation(ResourceLocation location, BlockState state) { - return new ModelResourceLocation(location, statePropertiesToString(state.getValues())); - } - - public static String statePropertiesToString(Map, Comparable> propertyValues) { - StringBuilder stringBuilder = new StringBuilder(); - - for (Entry, Comparable> entry : propertyValues.entrySet()) { - if (stringBuilder.length() != 0) { - stringBuilder.append(','); - } - - Property property = (Property)entry.getKey(); - stringBuilder.append(property.getName()); - stringBuilder.append('='); - stringBuilder.append(getValue(property, (Comparable)entry.getValue())); - } - - return stringBuilder.toString(); - } - - private static > String getValue(Property property, Comparable value) { - return property.getName((T)value); - } } diff --git a/net/minecraft/client/renderer/block/BlockRenderDispatcher.java b/net/minecraft/client/renderer/block/BlockRenderDispatcher.java index 755f5068..7f854019 100644 --- a/net/minecraft/client/renderer/block/BlockRenderDispatcher.java +++ b/net/minecraft/client/renderer/block/BlockRenderDispatcher.java @@ -2,6 +2,8 @@ package net.minecraft.client.renderer.block; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; +import java.util.ArrayList; +import java.util.List; import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -12,8 +14,9 @@ import net.minecraft.client.color.block.BlockColors; import net.minecraft.client.renderer.ItemBlockRenderTypes; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.SpecialBlockModelRenderer; +import net.minecraft.client.renderer.block.model.BlockModelPart; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.client.renderer.texture.OverlayTexture; -import net.minecraft.client.resources.model.BakedModel; import net.minecraft.core.BlockPos; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.server.packs.resources.ResourceManagerReloadListener; @@ -30,7 +33,8 @@ public class BlockRenderDispatcher implements ResourceManagerReloadListener { private final ModelBlockRenderer modelRenderer; private final Supplier specialBlockModelRenderer; private final LiquidBlockRenderer liquidBlockRenderer; - private final RandomSource random = RandomSource.create(); + private final RandomSource singleThreadRandom = RandomSource.create(); + private final List singleThreadPartList = new ArrayList(); private final BlockColors blockColors; public BlockRenderDispatcher(BlockModelShaper blockModelShaper, Supplier specialBlockModelRenderer, BlockColors blockColors) { @@ -47,18 +51,19 @@ public class BlockRenderDispatcher implements ResourceManagerReloadListener { public void renderBreakingTexture(BlockState state, BlockPos pos, BlockAndTintGetter level, PoseStack poseStack, VertexConsumer consumer) { if (state.getRenderShape() == RenderShape.MODEL) { - BakedModel bakedModel = this.blockModelShaper.getBlockModel(state); - long l = state.getSeed(pos); - this.modelRenderer.tesselateBlock(level, bakedModel, state, pos, poseStack, consumer, true, this.random, l, OverlayTexture.NO_OVERLAY); + BlockStateModel blockStateModel = this.blockModelShaper.getBlockModel(state); + this.singleThreadRandom.setSeed(state.getSeed(pos)); + this.singleThreadPartList.clear(); + blockStateModel.collectParts(this.singleThreadRandom, this.singleThreadPartList); + this.modelRenderer.tesselateBlock(level, this.singleThreadPartList, state, pos, poseStack, consumer, true, OverlayTexture.NO_OVERLAY); } } public void renderBatched( - BlockState state, BlockPos pos, BlockAndTintGetter level, PoseStack poseStack, VertexConsumer consumer, boolean checkSides, RandomSource random + BlockState state, BlockPos pos, BlockAndTintGetter level, PoseStack poseStack, VertexConsumer consumer, boolean checkSides, List parts ) { try { - this.modelRenderer - .tesselateBlock(level, this.getBlockModel(state), state, pos, poseStack, consumer, checkSides, random, state.getSeed(pos), OverlayTexture.NO_OVERLAY); + this.modelRenderer.tesselateBlock(level, parts, state, pos, poseStack, consumer, checkSides, OverlayTexture.NO_OVERLAY); } catch (Throwable var11) { CrashReport crashReport = CrashReport.forThrowable(var11, "Tesselating block in world"); CrashReportCategory crashReportCategory = crashReport.addCategory("Block being tesselated"); @@ -73,7 +78,7 @@ public class BlockRenderDispatcher implements ResourceManagerReloadListener { } catch (Throwable var9) { CrashReport crashReport = CrashReport.forThrowable(var9, "Tesselating liquid in world"); CrashReportCategory crashReportCategory = crashReport.addCategory("Block being tesselated"); - CrashReportCategory.populateBlockDetails(crashReportCategory, level, pos, null); + CrashReportCategory.populateBlockDetails(crashReportCategory, level, pos, blockState); throw new ReportedException(crashReport); } } @@ -82,20 +87,21 @@ public class BlockRenderDispatcher implements ResourceManagerReloadListener { return this.modelRenderer; } - public BakedModel getBlockModel(BlockState state) { + public BlockStateModel getBlockModel(BlockState state) { return this.blockModelShaper.getBlockModel(state); } public void renderSingleBlock(BlockState state, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay) { RenderShape renderShape = state.getRenderShape(); if (renderShape != RenderShape.INVISIBLE) { - BakedModel bakedModel = this.getBlockModel(state); + BlockStateModel blockStateModel = this.getBlockModel(state); int i = this.blockColors.getColor(state, null, null, 0); float f = (i >> 16 & 0xFF) / 255.0F; float g = (i >> 8 & 0xFF) / 255.0F; float h = (i & 0xFF) / 255.0F; - this.modelRenderer - .renderModel(poseStack.last(), bufferSource.getBuffer(ItemBlockRenderTypes.getRenderType(state)), state, bakedModel, f, g, h, packedLight, packedOverlay); + ModelBlockRenderer.renderModel( + poseStack.last(), bufferSource.getBuffer(ItemBlockRenderTypes.getRenderType(state)), blockStateModel, f, g, h, packedLight, packedOverlay + ); ((SpecialBlockModelRenderer)this.specialBlockModelRenderer.get()) .renderByBlock(state.getBlock(), ItemDisplayContext.NONE, poseStack, bufferSource, packedLight, packedOverlay); } diff --git a/net/minecraft/client/renderer/block/LiquidBlockRenderer.java b/net/minecraft/client/renderer/block/LiquidBlockRenderer.java index 972b6424..5a10a46f 100644 --- a/net/minecraft/client/renderer/block/LiquidBlockRenderer.java +++ b/net/minecraft/client/renderer/block/LiquidBlockRenderer.java @@ -32,9 +32,9 @@ public class LiquidBlockRenderer { private TextureAtlasSprite waterOverlay; protected void setupSprites() { - this.lavaIcons[0] = Minecraft.getInstance().getModelManager().getBlockModelShaper().getBlockModel(Blocks.LAVA.defaultBlockState()).getParticleIcon(); + this.lavaIcons[0] = Minecraft.getInstance().getModelManager().getBlockModelShaper().getBlockModel(Blocks.LAVA.defaultBlockState()).particleIcon(); this.lavaIcons[1] = ModelBakery.LAVA_FLOW.sprite(); - this.waterIcons[0] = Minecraft.getInstance().getModelManager().getBlockModelShaper().getBlockModel(Blocks.WATER.defaultBlockState()).getParticleIcon(); + this.waterIcons[0] = Minecraft.getInstance().getModelManager().getBlockModelShaper().getBlockModel(Blocks.WATER.defaultBlockState()).particleIcon(); this.waterIcons[1] = ModelBakery.WATER_FLOW.sprite(); this.waterOverlay = ModelBakery.WATER_OVERLAY.sprite(); } @@ -52,7 +52,7 @@ public class LiquidBlockRenderer { return face != Direction.UP || bl; } else { VoxelShape voxelShape2 = Shapes.box(0.0, 0.0, 0.0, 1.0, height, 1.0); - return Shapes.blockOccudes(voxelShape2, voxelShape, face); + return Shapes.blockOccludes(voxelShape2, voxelShape, face); } } diff --git a/net/minecraft/client/renderer/block/ModelBlockRenderer.java b/net/minecraft/client/renderer/block/ModelBlockRenderer.java index e5407d3d..3e1a14ad 100644 --- a/net/minecraft/client/renderer/block/ModelBlockRenderer.java +++ b/net/minecraft/client/renderer/block/ModelBlockRenderer.java @@ -4,7 +4,6 @@ import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; import it.unimi.dsi.fastutil.longs.Long2FloatLinkedOpenHashMap; import it.unimi.dsi.fastutil.longs.Long2IntLinkedOpenHashMap; -import java.util.BitSet; import java.util.List; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -18,21 +17,20 @@ import net.minecraft.client.renderer.LevelRenderer; import net.minecraft.client.renderer.block.ModelBlockRenderer.Cache.1; import net.minecraft.client.renderer.block.ModelBlockRenderer.Cache.2; import net.minecraft.client.renderer.block.model.BakedQuad; -import net.minecraft.client.resources.model.BakedModel; +import net.minecraft.client.renderer.block.model.BlockModelPart; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; +import net.minecraft.util.ARGB; import net.minecraft.util.Mth; import net.minecraft.util.RandomSource; import net.minecraft.world.level.BlockAndTintGetter; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class ModelBlockRenderer { - private static final int FACE_CUBIC = 0; - private static final int FACE_PARTIAL = 1; - static final Direction[] DIRECTIONS = Direction.values(); + private static final Direction[] DIRECTIONS = Direction.values(); private final BlockColors blockColors; private static final int CACHE_SIZE = 100; static final ThreadLocal CACHE = ThreadLocal.withInitial(ModelBlockRenderer.Cache::new); @@ -41,118 +39,135 @@ public class ModelBlockRenderer { this.blockColors = blockColors; } - /** - * @param checkSides if {@code true}, only renders each side if {@link net.minecraft.world.level.block.Block#shouldRenderFace(net.minecraft.world.level.block.state.BlockState, net.minecraft.world.level.BlockGetter, net.minecraft.core.BlockPos, net.minecraft.core.Direction, net.minecraft.core.BlockPos)} returns {@code true} - */ public void tesselateBlock( BlockAndTintGetter level, - BakedModel model, + List parts, BlockState state, BlockPos pos, PoseStack poseStack, VertexConsumer consumer, boolean checkSides, - RandomSource random, - long seed, int packedOverlay ) { - boolean bl = Minecraft.useAmbientOcclusion() && state.getLightEmission() == 0 && model.useAmbientOcclusion(); - poseStack.translate(state.getOffset(pos)); + if (!parts.isEmpty()) { + boolean bl = Minecraft.useAmbientOcclusion() && state.getLightEmission() == 0 && ((BlockModelPart)parts.getFirst()).useAmbientOcclusion(); + poseStack.translate(state.getOffset(pos)); - try { - if (bl) { - this.tesselateWithAO(level, model, state, pos, poseStack, consumer, checkSides, random, seed, packedOverlay); - } else { - this.tesselateWithoutAO(level, model, state, pos, poseStack, consumer, checkSides, random, seed, packedOverlay); + try { + if (bl) { + this.tesselateWithAO(level, parts, state, pos, poseStack, consumer, checkSides, packedOverlay); + } else { + this.tesselateWithoutAO(level, parts, state, pos, poseStack, consumer, checkSides, packedOverlay); + } + } catch (Throwable var13) { + CrashReport crashReport = CrashReport.forThrowable(var13, "Tesselating block model"); + CrashReportCategory crashReportCategory = crashReport.addCategory("Block model being tesselated"); + CrashReportCategory.populateBlockDetails(crashReportCategory, level, pos, state); + crashReportCategory.setDetail("Using AO", bl); + throw new ReportedException(crashReport); } - } catch (Throwable var16) { - CrashReport crashReport = CrashReport.forThrowable(var16, "Tesselating block model"); - CrashReportCategory crashReportCategory = crashReport.addCategory("Block model being tesselated"); - CrashReportCategory.populateBlockDetails(crashReportCategory, level, pos, state); - crashReportCategory.setDetail("Using AO", bl); - throw new ReportedException(crashReport); } } - /** - * @param checkSides if {@code true}, only renders each side if {@link net.minecraft.world.level.block.Block#shouldRenderFace(net.minecraft.world.level.block.state.BlockState, net.minecraft.world.level.BlockGetter, net.minecraft.core.BlockPos, net.minecraft.core.Direction, net.minecraft.core.BlockPos)} returns {@code true} - */ + private static boolean shouldRenderFace(BlockAndTintGetter level, BlockState state, boolean checkSides, Direction face, BlockPos pos) { + if (!checkSides) { + return true; + } else { + BlockState blockState = level.getBlockState(pos); + return Block.shouldRenderFace(state, blockState, face); + } + } + public void tesselateWithAO( BlockAndTintGetter level, - BakedModel model, + List parts, BlockState state, BlockPos pos, PoseStack poseStack, VertexConsumer consumer, boolean checkSides, - RandomSource random, - long seed, int packedOverlay ) { - float[] fs = new float[DIRECTIONS.length * 2]; - BitSet bitSet = new BitSet(3); - ModelBlockRenderer.AmbientOcclusionFace ambientOcclusionFace = new ModelBlockRenderer.AmbientOcclusionFace(); - BlockPos.MutableBlockPos mutableBlockPos = pos.mutable(); + ModelBlockRenderer.AmbientOcclusionRenderStorage ambientOcclusionRenderStorage = new ModelBlockRenderer.AmbientOcclusionRenderStorage(); + int i = 0; + int j = 0; - for (Direction direction : DIRECTIONS) { - random.setSeed(seed); - List list = model.getQuads(state, direction, random); - if (!list.isEmpty()) { - mutableBlockPos.setWithOffset(pos, direction); - if (!checkSides || Block.shouldRenderFace(state, level.getBlockState(mutableBlockPos), direction)) { - this.renderModelFaceAO(level, state, pos, poseStack, consumer, list, fs, bitSet, ambientOcclusionFace, packedOverlay); + for (BlockModelPart blockModelPart : parts) { + for (Direction direction : DIRECTIONS) { + int k = 1 << direction.ordinal(); + boolean bl = (i & k) == 1; + boolean bl2 = (j & k) == 1; + if (!bl || bl2) { + List list = blockModelPart.getQuads(direction); + if (!list.isEmpty()) { + if (!bl) { + bl2 = shouldRenderFace(level, state, checkSides, direction, ambientOcclusionRenderStorage.scratchPos.setWithOffset(pos, direction)); + i |= k; + if (bl2) { + j |= k; + } + } + + if (bl2) { + this.renderModelFaceAO(level, state, pos, poseStack, consumer, list, ambientOcclusionRenderStorage, packedOverlay); + } + } } } - } - random.setSeed(seed); - List list2 = model.getQuads(state, null, random); - if (!list2.isEmpty()) { - this.renderModelFaceAO(level, state, pos, poseStack, consumer, list2, fs, bitSet, ambientOcclusionFace, packedOverlay); + List list2 = blockModelPart.getQuads(null); + if (!list2.isEmpty()) { + this.renderModelFaceAO(level, state, pos, poseStack, consumer, list2, ambientOcclusionRenderStorage, packedOverlay); + } } } - /** - * @param checkSides if {@code true}, only renders each side if {@link net.minecraft.world.level.block.Block#shouldRenderFace(net.minecraft.world.level.block.state.BlockState, net.minecraft.world.level.BlockGetter, net.minecraft.core.BlockPos, net.minecraft.core.Direction, net.minecraft.core.BlockPos)} returns {@code true} - */ public void tesselateWithoutAO( BlockAndTintGetter level, - BakedModel model, + List parts, BlockState state, BlockPos pos, PoseStack poseStack, VertexConsumer consumer, boolean checkSides, - RandomSource random, - long seed, int packedOverlay ) { - BitSet bitSet = new BitSet(3); - BlockPos.MutableBlockPos mutableBlockPos = pos.mutable(); + ModelBlockRenderer.CommonRenderStorage commonRenderStorage = new ModelBlockRenderer.CommonRenderStorage(); + int i = 0; + int j = 0; - for (Direction direction : DIRECTIONS) { - random.setSeed(seed); - List list = model.getQuads(state, direction, random); - if (!list.isEmpty()) { - mutableBlockPos.setWithOffset(pos, direction); - if (!checkSides || Block.shouldRenderFace(state, level.getBlockState(mutableBlockPos), direction)) { - int i = LevelRenderer.getLightColor(level, state, mutableBlockPos); - this.renderModelFaceFlat(level, state, pos, i, packedOverlay, false, poseStack, consumer, list, bitSet); + for (BlockModelPart blockModelPart : parts) { + for (Direction direction : DIRECTIONS) { + int k = 1 << direction.ordinal(); + boolean bl = (i & k) == 1; + boolean bl2 = (j & k) == 1; + if (!bl || bl2) { + List list = blockModelPart.getQuads(direction); + if (!list.isEmpty()) { + BlockPos blockPos = commonRenderStorage.scratchPos.setWithOffset(pos, direction); + if (!bl) { + bl2 = shouldRenderFace(level, state, checkSides, direction, blockPos); + i |= k; + if (bl2) { + j |= k; + } + } + + if (bl2) { + int l = commonRenderStorage.cache.getLightColor(state, level, blockPos); + this.renderModelFaceFlat(level, state, pos, l, packedOverlay, false, poseStack, consumer, list, commonRenderStorage); + } + } } } - } - random.setSeed(seed); - List list2 = model.getQuads(state, null, random); - if (!list2.isEmpty()) { - this.renderModelFaceFlat(level, state, pos, -1, packedOverlay, true, poseStack, consumer, list2, bitSet); + List list2 = blockModelPart.getQuads(null); + if (!list2.isEmpty()) { + this.renderModelFaceFlat(level, state, pos, -1, packedOverlay, true, poseStack, consumer, list2, commonRenderStorage); + } } } - /** - * @param shape the array, of length 12, to store the shape bounds in - * @param shapeFlags the bit set to store the shape flags in. The first bit will be {@code true} if the face should be offset, and the second if the face is less than a block in width and height. - */ private void renderModelFaceAO( BlockAndTintGetter level, BlockState state, @@ -160,31 +175,13 @@ public class ModelBlockRenderer { PoseStack poseStack, VertexConsumer consumer, List quads, - float[] shape, - BitSet shapeFlags, - ModelBlockRenderer.AmbientOcclusionFace aoFace, + ModelBlockRenderer.AmbientOcclusionRenderStorage renderStorage, int packedOverlay ) { for (BakedQuad bakedQuad : quads) { - this.calculateShape(level, state, pos, bakedQuad.getVertices(), bakedQuad.getDirection(), shape, shapeFlags); - aoFace.calculate(level, state, pos, bakedQuad.getDirection(), shape, shapeFlags, bakedQuad.isShade()); - this.putQuadData( - level, - state, - pos, - consumer, - poseStack.last(), - bakedQuad, - aoFace.brightness[0], - aoFace.brightness[1], - aoFace.brightness[2], - aoFace.brightness[3], - aoFace.lightmap[0], - aoFace.lightmap[1], - aoFace.lightmap[2], - aoFace.lightmap[3], - packedOverlay - ); + calculateShape(level, state, pos, bakedQuad.vertices(), bakedQuad.direction(), renderStorage); + renderStorage.calculate(level, state, pos, bakedQuad.direction(), bakedQuad.shade()); + this.putQuadData(level, state, pos, consumer, poseStack.last(), bakedQuad, renderStorage, packedOverlay); } } @@ -195,52 +192,37 @@ public class ModelBlockRenderer { VertexConsumer consumer, PoseStack.Pose pose, BakedQuad quad, - float brightness0, - float brightness1, - float brightness2, - float brightness3, - int lightmap0, - int lightmap1, - int lightmap2, - int lightmap3, + ModelBlockRenderer.CommonRenderStorage renderStorage, int packedOverlay ) { + int i = quad.tintIndex(); float f; float g; float h; - if (quad.isTinted()) { - int i = this.blockColors.getColor(state, level, pos, quad.getTintIndex()); - f = (i >> 16 & 0xFF) / 255.0F; - g = (i >> 8 & 0xFF) / 255.0F; - h = (i & 0xFF) / 255.0F; + if (i != -1) { + int j; + if (renderStorage.tintCacheIndex == i) { + j = renderStorage.tintCacheValue; + } else { + j = this.blockColors.getColor(state, level, pos, i); + renderStorage.tintCacheIndex = i; + renderStorage.tintCacheValue = j; + } + + f = ARGB.redFloat(j); + g = ARGB.greenFloat(j); + h = ARGB.blueFloat(j); } else { f = 1.0F; g = 1.0F; h = 1.0F; } - consumer.putBulkData( - pose, - quad, - new float[]{brightness0, brightness1, brightness2, brightness3}, - f, - g, - h, - 1.0F, - new int[]{lightmap0, lightmap1, lightmap2, lightmap3}, - packedOverlay, - true - ); + consumer.putBulkData(pose, quad, renderStorage.brightness, f, g, h, 1.0F, renderStorage.lightmap, packedOverlay, true); } - /** - * Calculates the shape and corresponding flags for the specified {@code direction} and {@code vertices}, storing the resulting shape in the specified {@code shape} array and the shape flags in {@code shapeFlags}. - * - * @param shape the array, of length 12, to store the shape bounds in, or {@code null} to only calculate shape flags - * @param shapeFlags the bit set to store the shape flags in. The first bit will be {@code true} if the face should be offset, and the second if the face is less than a block in width and height. - */ - private void calculateShape( - BlockAndTintGetter level, BlockState state, BlockPos pos, int[] vertices, Direction direction, @Nullable float[] shape, BitSet shapeFlags + private static void calculateShape( + BlockAndTintGetter level, BlockState state, BlockPos pos, int[] verticies, Direction direction, ModelBlockRenderer.CommonRenderStorage renderStorage ) { float f = 32.0F; float g = 32.0F; @@ -250,9 +232,9 @@ public class ModelBlockRenderer { float k = -32.0F; for (int l = 0; l < 4; l++) { - float m = Float.intBitsToFloat(vertices[l * 8]); - float n = Float.intBitsToFloat(vertices[l * 8 + 1]); - float o = Float.intBitsToFloat(vertices[l * 8 + 2]); + float m = Float.intBitsToFloat(verticies[l * 8]); + float n = Float.intBitsToFloat(verticies[l * 8 + 1]); + float o = Float.intBitsToFloat(verticies[l * 8 + 2]); f = Math.min(f, m); g = Math.min(g, n); h = Math.min(h, o); @@ -261,54 +243,42 @@ public class ModelBlockRenderer { k = Math.max(k, o); } - if (shape != null) { - shape[Direction.WEST.get3DDataValue()] = f; - shape[Direction.EAST.get3DDataValue()] = i; - shape[Direction.DOWN.get3DDataValue()] = g; - shape[Direction.UP.get3DDataValue()] = j; - shape[Direction.NORTH.get3DDataValue()] = h; - shape[Direction.SOUTH.get3DDataValue()] = k; - int l = DIRECTIONS.length; - shape[Direction.WEST.get3DDataValue() + l] = 1.0F - f; - shape[Direction.EAST.get3DDataValue() + l] = 1.0F - i; - shape[Direction.DOWN.get3DDataValue() + l] = 1.0F - g; - shape[Direction.UP.get3DDataValue() + l] = 1.0F - j; - shape[Direction.NORTH.get3DDataValue() + l] = 1.0F - h; - shape[Direction.SOUTH.get3DDataValue() + l] = 1.0F - k; + if (renderStorage instanceof ModelBlockRenderer.AmbientOcclusionRenderStorage ambientOcclusionRenderStorage) { + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.WEST.index] = f; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.EAST.index] = i; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.DOWN.index] = g; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.UP.index] = j; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.NORTH.index] = h; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.SOUTH.index] = k; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.FLIP_WEST.index] = 1.0F - f; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.FLIP_EAST.index] = 1.0F - i; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.FLIP_DOWN.index] = 1.0F - g; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.FLIP_UP.index] = 1.0F - j; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.FLIP_NORTH.index] = 1.0F - h; + ambientOcclusionRenderStorage.faceShape[ModelBlockRenderer.SizeInfo.FLIP_SOUTH.index] = 1.0F - k; } float p = 1.0E-4F; float m = 0.9999F; - switch (direction) { - case DOWN: - shapeFlags.set(1, f >= 1.0E-4F || h >= 1.0E-4F || i <= 0.9999F || k <= 0.9999F); - shapeFlags.set(0, g == j && (g < 1.0E-4F || state.isCollisionShapeFullBlock(level, pos))); - break; - case UP: - shapeFlags.set(1, f >= 1.0E-4F || h >= 1.0E-4F || i <= 0.9999F || k <= 0.9999F); - shapeFlags.set(0, g == j && (j > 0.9999F || state.isCollisionShapeFullBlock(level, pos))); - break; - case NORTH: - shapeFlags.set(1, f >= 1.0E-4F || g >= 1.0E-4F || i <= 0.9999F || j <= 0.9999F); - shapeFlags.set(0, h == k && (h < 1.0E-4F || state.isCollisionShapeFullBlock(level, pos))); - break; - case SOUTH: - shapeFlags.set(1, f >= 1.0E-4F || g >= 1.0E-4F || i <= 0.9999F || j <= 0.9999F); - shapeFlags.set(0, h == k && (k > 0.9999F || state.isCollisionShapeFullBlock(level, pos))); - break; - case WEST: - shapeFlags.set(1, g >= 1.0E-4F || h >= 1.0E-4F || j <= 0.9999F || k <= 0.9999F); - shapeFlags.set(0, f == i && (f < 1.0E-4F || state.isCollisionShapeFullBlock(level, pos))); - break; - case EAST: - shapeFlags.set(1, g >= 1.0E-4F || h >= 1.0E-4F || j <= 0.9999F || k <= 0.9999F); - shapeFlags.set(0, f == i && (i > 0.9999F || state.isCollisionShapeFullBlock(level, pos))); - } + + renderStorage.facePartial = switch (direction) { + case DOWN, UP -> f >= 1.0E-4F || h >= 1.0E-4F || i <= 0.9999F || k <= 0.9999F; + case NORTH, SOUTH -> f >= 1.0E-4F || g >= 1.0E-4F || i <= 0.9999F || j <= 0.9999F; + case WEST, EAST -> g >= 1.0E-4F || h >= 1.0E-4F || j <= 0.9999F || k <= 0.9999F; + }; + + renderStorage.faceCubic = switch (direction) { + case DOWN -> g == j && (g < 1.0E-4F || state.isCollisionShapeFullBlock(level, pos)); + case UP -> g == j && (j > 0.9999F || state.isCollisionShapeFullBlock(level, pos)); + case NORTH -> h == k && (h < 1.0E-4F || state.isCollisionShapeFullBlock(level, pos)); + case SOUTH -> h == k && (k > 0.9999F || state.isCollisionShapeFullBlock(level, pos)); + case WEST -> f == i && (f < 1.0E-4F || state.isCollisionShapeFullBlock(level, pos)); + case EAST -> f == i && (i > 0.9999F || state.isCollisionShapeFullBlock(level, pos)); + }; } /** * @param repackLight {@code true} if packed light should be re-calculated - * @param shapeFlags the bit set to store the shape flags in. The first bit will be {@code true} if the face should be offset, and the second if the face is less than a block in width and height. */ private void renderModelFaceFlat( BlockAndTintGetter level, @@ -320,41 +290,38 @@ public class ModelBlockRenderer { PoseStack poseStack, VertexConsumer consumer, List quads, - BitSet shapeFlags + ModelBlockRenderer.CommonRenderStorage renderStorage ) { for (BakedQuad bakedQuad : quads) { if (repackLight) { - this.calculateShape(level, state, pos, bakedQuad.getVertices(), bakedQuad.getDirection(), null, shapeFlags); - BlockPos blockPos = shapeFlags.get(0) ? pos.relative(bakedQuad.getDirection()) : pos; - packedLight = LevelRenderer.getLightColor(level, state, blockPos); + calculateShape(level, state, pos, bakedQuad.vertices(), bakedQuad.direction(), renderStorage); + BlockPos blockPos = (BlockPos)(renderStorage.faceCubic ? renderStorage.scratchPos.setWithOffset(pos, bakedQuad.direction()) : pos); + packedLight = renderStorage.cache.getLightColor(state, level, blockPos); } - float f = level.getShade(bakedQuad.getDirection(), bakedQuad.isShade()); - this.putQuadData(level, state, pos, consumer, poseStack.last(), bakedQuad, f, f, f, f, packedLight, packedLight, packedLight, packedLight, packedOverlay); + float f = level.getShade(bakedQuad.direction(), bakedQuad.shade()); + renderStorage.brightness[0] = f; + renderStorage.brightness[1] = f; + renderStorage.brightness[2] = f; + renderStorage.brightness[3] = f; + renderStorage.lightmap[0] = packedLight; + renderStorage.lightmap[1] = packedLight; + renderStorage.lightmap[2] = packedLight; + renderStorage.lightmap[3] = packedLight; + this.putQuadData(level, state, pos, consumer, poseStack.last(), bakedQuad, renderStorage, packedOverlay); } } - public void renderModel( - PoseStack.Pose pose, - VertexConsumer consumer, - @Nullable BlockState state, - BakedModel model, - float red, - float green, - float blue, - int packedLight, - int packedOverlay + public static void renderModel( + PoseStack.Pose pose, VertexConsumer consumer, BlockStateModel model, float red, float green, float blue, int packedLight, int packedOverlay ) { - RandomSource randomSource = RandomSource.create(); - long l = 42L; + for (BlockModelPart blockModelPart : model.collectParts(RandomSource.create(42L))) { + for (Direction direction : DIRECTIONS) { + renderQuadList(pose, consumer, red, green, blue, blockModelPart.getQuads(direction), packedLight, packedOverlay); + } - for (Direction direction : DIRECTIONS) { - randomSource.setSeed(42L); - renderQuadList(pose, consumer, red, green, blue, model.getQuads(state, direction, randomSource), packedLight, packedOverlay); + renderQuadList(pose, consumer, red, green, blue, blockModelPart.getQuads(null), packedLight, packedOverlay); } - - randomSource.setSeed(42L); - renderQuadList(pose, consumer, red, green, blue, model.getQuads(state, null, randomSource), packedLight, packedOverlay); } private static void renderQuadList( @@ -700,38 +667,32 @@ public class ModelBlockRenderer { } @Environment(EnvType.CLIENT) - static class AmbientOcclusionFace { - final float[] brightness = new float[4]; - final int[] lightmap = new int[4]; + static class AmbientOcclusionRenderStorage extends ModelBlockRenderer.CommonRenderStorage { + final float[] faceShape = new float[ModelBlockRenderer.SizeInfo.COUNT]; - public AmbientOcclusionFace() { + public AmbientOcclusionRenderStorage() { } - /** - * @param shape the array, of length 12, containing the shape bounds - * @param shapeFlags the bit set to store the shape flags in. The first bit will be {@code true} if the face should be offset, and the second if the face is less than a block in width and height. - */ - public void calculate(BlockAndTintGetter level, BlockState state, BlockPos pos, Direction direction, float[] shape, BitSet shapeFlags, boolean shade) { - BlockPos blockPos = shapeFlags.get(0) ? pos.relative(direction) : pos; + public void calculate(BlockAndTintGetter level, BlockState state, BlockPos pos, Direction direction, boolean shade) { + BlockPos blockPos = this.faceCubic ? pos.relative(direction) : pos; ModelBlockRenderer.AdjacencyInfo adjacencyInfo = ModelBlockRenderer.AdjacencyInfo.fromFacing(direction); - BlockPos.MutableBlockPos mutableBlockPos = new BlockPos.MutableBlockPos(); - ModelBlockRenderer.Cache cache = (ModelBlockRenderer.Cache)ModelBlockRenderer.CACHE.get(); + BlockPos.MutableBlockPos mutableBlockPos = this.scratchPos; mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[0]); BlockState blockState = level.getBlockState(mutableBlockPos); - int i = cache.getLightColor(blockState, level, mutableBlockPos); - float f = cache.getShadeBrightness(blockState, level, mutableBlockPos); + int i = this.cache.getLightColor(blockState, level, mutableBlockPos); + float f = this.cache.getShadeBrightness(blockState, level, mutableBlockPos); mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[1]); BlockState blockState2 = level.getBlockState(mutableBlockPos); - int j = cache.getLightColor(blockState2, level, mutableBlockPos); - float g = cache.getShadeBrightness(blockState2, level, mutableBlockPos); + int j = this.cache.getLightColor(blockState2, level, mutableBlockPos); + float g = this.cache.getShadeBrightness(blockState2, level, mutableBlockPos); mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[2]); BlockState blockState3 = level.getBlockState(mutableBlockPos); - int k = cache.getLightColor(blockState3, level, mutableBlockPos); - float h = cache.getShadeBrightness(blockState3, level, mutableBlockPos); + int k = this.cache.getLightColor(blockState3, level, mutableBlockPos); + float h = this.cache.getShadeBrightness(blockState3, level, mutableBlockPos); mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[3]); BlockState blockState4 = level.getBlockState(mutableBlockPos); - int l = cache.getLightColor(blockState4, level, mutableBlockPos); - float m = cache.getShadeBrightness(blockState4, level, mutableBlockPos); + int l = this.cache.getLightColor(blockState4, level, mutableBlockPos); + float m = this.cache.getShadeBrightness(blockState4, level, mutableBlockPos); BlockState blockState5 = level.getBlockState(mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[0]).move(direction)); boolean bl = !blockState5.isViewBlocking(level, mutableBlockPos) || blockState5.getLightBlock() == 0; BlockState blockState6 = level.getBlockState(mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[1]).move(direction)); @@ -748,8 +709,8 @@ public class ModelBlockRenderer { } else { mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[0]).move(adjacencyInfo.corners[2]); BlockState blockState9 = level.getBlockState(mutableBlockPos); - n = cache.getShadeBrightness(blockState9, level, mutableBlockPos); - o = cache.getLightColor(blockState9, level, mutableBlockPos); + n = this.cache.getShadeBrightness(blockState9, level, mutableBlockPos); + o = this.cache.getLightColor(blockState9, level, mutableBlockPos); } float p; @@ -760,8 +721,8 @@ public class ModelBlockRenderer { } else { mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[0]).move(adjacencyInfo.corners[3]); BlockState blockState9 = level.getBlockState(mutableBlockPos); - p = cache.getShadeBrightness(blockState9, level, mutableBlockPos); - q = cache.getLightColor(blockState9, level, mutableBlockPos); + p = this.cache.getShadeBrightness(blockState9, level, mutableBlockPos); + q = this.cache.getLightColor(blockState9, level, mutableBlockPos); } float r; @@ -772,8 +733,8 @@ public class ModelBlockRenderer { } else { mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[1]).move(adjacencyInfo.corners[2]); BlockState blockState9 = level.getBlockState(mutableBlockPos); - r = cache.getShadeBrightness(blockState9, level, mutableBlockPos); - s = cache.getLightColor(blockState9, level, mutableBlockPos); + r = this.cache.getShadeBrightness(blockState9, level, mutableBlockPos); + s = this.cache.getLightColor(blockState9, level, mutableBlockPos); } float t; @@ -784,63 +745,63 @@ public class ModelBlockRenderer { } else { mutableBlockPos.setWithOffset(blockPos, adjacencyInfo.corners[1]).move(adjacencyInfo.corners[3]); BlockState blockState9 = level.getBlockState(mutableBlockPos); - t = cache.getShadeBrightness(blockState9, level, mutableBlockPos); - u = cache.getLightColor(blockState9, level, mutableBlockPos); + t = this.cache.getShadeBrightness(blockState9, level, mutableBlockPos); + u = this.cache.getLightColor(blockState9, level, mutableBlockPos); } - int v = cache.getLightColor(state, level, pos); + int v = this.cache.getLightColor(state, level, pos); mutableBlockPos.setWithOffset(pos, direction); BlockState blockState10 = level.getBlockState(mutableBlockPos); - if (shapeFlags.get(0) || !blockState10.isSolidRender()) { - v = cache.getLightColor(blockState10, level, mutableBlockPos); + if (this.faceCubic || !blockState10.isSolidRender()) { + v = this.cache.getLightColor(blockState10, level, mutableBlockPos); } - float w = shapeFlags.get(0) - ? cache.getShadeBrightness(level.getBlockState(blockPos), level, blockPos) - : cache.getShadeBrightness(level.getBlockState(pos), level, pos); + float w = this.faceCubic + ? this.cache.getShadeBrightness(level.getBlockState(blockPos), level, blockPos) + : this.cache.getShadeBrightness(level.getBlockState(pos), level, pos); ModelBlockRenderer.AmbientVertexRemap ambientVertexRemap = ModelBlockRenderer.AmbientVertexRemap.fromFacing(direction); - if (shapeFlags.get(1) && adjacencyInfo.doNonCubicWeight) { + if (this.facePartial && adjacencyInfo.doNonCubicWeight) { float x = (m + f + p + w) * 0.25F; float y = (h + f + n + w) * 0.25F; float z = (h + g + r + w) * 0.25F; float aa = (m + g + t + w) * 0.25F; - float ab = shape[adjacencyInfo.vert0Weights[0].shape] * shape[adjacencyInfo.vert0Weights[1].shape]; - float ac = shape[adjacencyInfo.vert0Weights[2].shape] * shape[adjacencyInfo.vert0Weights[3].shape]; - float ad = shape[adjacencyInfo.vert0Weights[4].shape] * shape[adjacencyInfo.vert0Weights[5].shape]; - float ae = shape[adjacencyInfo.vert0Weights[6].shape] * shape[adjacencyInfo.vert0Weights[7].shape]; - float af = shape[adjacencyInfo.vert1Weights[0].shape] * shape[adjacencyInfo.vert1Weights[1].shape]; - float ag = shape[adjacencyInfo.vert1Weights[2].shape] * shape[adjacencyInfo.vert1Weights[3].shape]; - float ah = shape[adjacencyInfo.vert1Weights[4].shape] * shape[adjacencyInfo.vert1Weights[5].shape]; - float ai = shape[adjacencyInfo.vert1Weights[6].shape] * shape[adjacencyInfo.vert1Weights[7].shape]; - float aj = shape[adjacencyInfo.vert2Weights[0].shape] * shape[adjacencyInfo.vert2Weights[1].shape]; - float ak = shape[adjacencyInfo.vert2Weights[2].shape] * shape[adjacencyInfo.vert2Weights[3].shape]; - float al = shape[adjacencyInfo.vert2Weights[4].shape] * shape[adjacencyInfo.vert2Weights[5].shape]; - float am = shape[adjacencyInfo.vert2Weights[6].shape] * shape[adjacencyInfo.vert2Weights[7].shape]; - float an = shape[adjacencyInfo.vert3Weights[0].shape] * shape[adjacencyInfo.vert3Weights[1].shape]; - float ao = shape[adjacencyInfo.vert3Weights[2].shape] * shape[adjacencyInfo.vert3Weights[3].shape]; - float ap = shape[adjacencyInfo.vert3Weights[4].shape] * shape[adjacencyInfo.vert3Weights[5].shape]; - float aq = shape[adjacencyInfo.vert3Weights[6].shape] * shape[adjacencyInfo.vert3Weights[7].shape]; + float ab = this.faceShape[adjacencyInfo.vert0Weights[0].index] * this.faceShape[adjacencyInfo.vert0Weights[1].index]; + float ac = this.faceShape[adjacencyInfo.vert0Weights[2].index] * this.faceShape[adjacencyInfo.vert0Weights[3].index]; + float ad = this.faceShape[adjacencyInfo.vert0Weights[4].index] * this.faceShape[adjacencyInfo.vert0Weights[5].index]; + float ae = this.faceShape[adjacencyInfo.vert0Weights[6].index] * this.faceShape[adjacencyInfo.vert0Weights[7].index]; + float af = this.faceShape[adjacencyInfo.vert1Weights[0].index] * this.faceShape[adjacencyInfo.vert1Weights[1].index]; + float ag = this.faceShape[adjacencyInfo.vert1Weights[2].index] * this.faceShape[adjacencyInfo.vert1Weights[3].index]; + float ah = this.faceShape[adjacencyInfo.vert1Weights[4].index] * this.faceShape[adjacencyInfo.vert1Weights[5].index]; + float ai = this.faceShape[adjacencyInfo.vert1Weights[6].index] * this.faceShape[adjacencyInfo.vert1Weights[7].index]; + float aj = this.faceShape[adjacencyInfo.vert2Weights[0].index] * this.faceShape[adjacencyInfo.vert2Weights[1].index]; + float ak = this.faceShape[adjacencyInfo.vert2Weights[2].index] * this.faceShape[adjacencyInfo.vert2Weights[3].index]; + float al = this.faceShape[adjacencyInfo.vert2Weights[4].index] * this.faceShape[adjacencyInfo.vert2Weights[5].index]; + float am = this.faceShape[adjacencyInfo.vert2Weights[6].index] * this.faceShape[adjacencyInfo.vert2Weights[7].index]; + float an = this.faceShape[adjacencyInfo.vert3Weights[0].index] * this.faceShape[adjacencyInfo.vert3Weights[1].index]; + float ao = this.faceShape[adjacencyInfo.vert3Weights[2].index] * this.faceShape[adjacencyInfo.vert3Weights[3].index]; + float ap = this.faceShape[adjacencyInfo.vert3Weights[4].index] * this.faceShape[adjacencyInfo.vert3Weights[5].index]; + float aq = this.faceShape[adjacencyInfo.vert3Weights[6].index] * this.faceShape[adjacencyInfo.vert3Weights[7].index]; this.brightness[ambientVertexRemap.vert0] = Math.clamp(x * ab + y * ac + z * ad + aa * ae, 0.0F, 1.0F); this.brightness[ambientVertexRemap.vert1] = Math.clamp(x * af + y * ag + z * ah + aa * ai, 0.0F, 1.0F); this.brightness[ambientVertexRemap.vert2] = Math.clamp(x * aj + y * ak + z * al + aa * am, 0.0F, 1.0F); this.brightness[ambientVertexRemap.vert3] = Math.clamp(x * an + y * ao + z * ap + aa * aq, 0.0F, 1.0F); - int ar = this.blend(l, i, q, v); - int as = this.blend(k, i, o, v); - int at = this.blend(k, j, s, v); - int au = this.blend(l, j, u, v); - this.lightmap[ambientVertexRemap.vert0] = this.blend(ar, as, at, au, ab, ac, ad, ae); - this.lightmap[ambientVertexRemap.vert1] = this.blend(ar, as, at, au, af, ag, ah, ai); - this.lightmap[ambientVertexRemap.vert2] = this.blend(ar, as, at, au, aj, ak, al, am); - this.lightmap[ambientVertexRemap.vert3] = this.blend(ar, as, at, au, an, ao, ap, aq); + int ar = blend(l, i, q, v); + int as = blend(k, i, o, v); + int at = blend(k, j, s, v); + int au = blend(l, j, u, v); + this.lightmap[ambientVertexRemap.vert0] = blend(ar, as, at, au, ab, ac, ad, ae); + this.lightmap[ambientVertexRemap.vert1] = blend(ar, as, at, au, af, ag, ah, ai); + this.lightmap[ambientVertexRemap.vert2] = blend(ar, as, at, au, aj, ak, al, am); + this.lightmap[ambientVertexRemap.vert3] = blend(ar, as, at, au, an, ao, ap, aq); } else { float x = (m + f + p + w) * 0.25F; float y = (h + f + n + w) * 0.25F; float z = (h + g + r + w) * 0.25F; float aa = (m + g + t + w) * 0.25F; - this.lightmap[ambientVertexRemap.vert0] = this.blend(l, i, q, v); - this.lightmap[ambientVertexRemap.vert1] = this.blend(k, i, o, v); - this.lightmap[ambientVertexRemap.vert2] = this.blend(k, j, s, v); - this.lightmap[ambientVertexRemap.vert3] = this.blend(l, j, u, v); + this.lightmap[ambientVertexRemap.vert0] = blend(l, i, q, v); + this.lightmap[ambientVertexRemap.vert1] = blend(k, i, o, v); + this.lightmap[ambientVertexRemap.vert2] = blend(k, j, s, v); + this.lightmap[ambientVertexRemap.vert3] = blend(l, j, u, v); this.brightness[ambientVertexRemap.vert0] = x; this.brightness[ambientVertexRemap.vert1] = y; this.brightness[ambientVertexRemap.vert2] = z; @@ -854,31 +815,34 @@ public class ModelBlockRenderer { } } - /** - * @return the ambient occlusion light color - */ - private int blend(int lightColor0, int lightColor1, int lightColor2, int lightColor3) { - if (lightColor0 == 0) { - lightColor0 = lightColor3; + private static int blend(int color1, int color2, int color3, int currentBlockColor) { + if (color1 == 0) { + color1 = currentBlockColor; } - if (lightColor1 == 0) { - lightColor1 = lightColor3; + if (color2 == 0) { + color2 = currentBlockColor; } - if (lightColor2 == 0) { - lightColor2 = lightColor3; + if (color3 == 0) { + color3 = currentBlockColor; } - return lightColor0 + lightColor1 + lightColor2 + lightColor3 >> 2 & 16711935; + return color1 + color2 + color3 + currentBlockColor >> 2 & 16711935; } - private int blend(int brightness0, int brightness1, int brightness2, int brightness3, float weight0, float weight1, float weight2, float weight3) { + private static int blend( + int color1, int color2, int color3, int blockLight, float color1Weight, float color2Weight, float color3Weight, float blockLightWeight + ) { int i = (int)( - (brightness0 >> 16 & 0xFF) * weight0 + (brightness1 >> 16 & 0xFF) * weight1 + (brightness2 >> 16 & 0xFF) * weight2 + (brightness3 >> 16 & 0xFF) * weight3 + (color1 >> 16 & 0xFF) * color1Weight + + (color2 >> 16 & 0xFF) * color2Weight + + (color3 >> 16 & 0xFF) * color3Weight + + (blockLight >> 16 & 0xFF) * blockLightWeight ) & 0xFF; - int j = (int)((brightness0 & 0xFF) * weight0 + (brightness1 & 0xFF) * weight1 + (brightness2 & 0xFF) * weight2 + (brightness3 & 0xFF) * weight3) & 0xFF; + int j = (int)((color1 & 0xFF) * color1Weight + (color2 & 0xFF) * color2Weight + (color3 & 0xFF) * color3Weight + (blockLight & 0xFF) * blockLightWeight) + & 0xFF; return i << 16 | j; } } @@ -930,6 +894,21 @@ public class ModelBlockRenderer { long2FloatLinkedOpenHashMap.defaultReturnValue(Float.NaN); return long2FloatLinkedOpenHashMap; }); + private final LevelRenderer.BrightnessGetter cachedBrightnessGetter = (blockAndTintGetter, blockPos) -> { + long l = blockPos.asLong(); + int i = this.colorCache.get(l); + if (i != Integer.MAX_VALUE) { + return i; + } else { + int j = LevelRenderer.BrightnessGetter.DEFAULT.packedBrightness(blockAndTintGetter, blockPos); + if (this.colorCache.size() == 100) { + this.colorCache.removeFirstInt(); + } + + this.colorCache.put(l, j); + return j; + } + }; private Cache() { } @@ -945,24 +924,7 @@ public class ModelBlockRenderer { } public int getLightColor(BlockState state, BlockAndTintGetter level, BlockPos pos) { - long l = pos.asLong(); - if (this.enabled) { - int i = this.colorCache.get(l); - if (i != Integer.MAX_VALUE) { - return i; - } - } - - int i = LevelRenderer.getLightColor(level, state, pos); - if (this.enabled) { - if (this.colorCache.size() == 100) { - this.colorCache.removeFirstInt(); - } - - this.colorCache.put(l, i); - } - - return i; + return LevelRenderer.getLightColor(this.enabled ? this.cachedBrightnessGetter : LevelRenderer.BrightnessGetter.DEFAULT, level, state, pos); } public float getShadeBrightness(BlockState state, BlockAndTintGetter level, BlockPos pos) { @@ -987,25 +949,38 @@ public class ModelBlockRenderer { } } + @Environment(EnvType.CLIENT) + static class CommonRenderStorage { + public final BlockPos.MutableBlockPos scratchPos = new BlockPos.MutableBlockPos(); + public boolean faceCubic; + public boolean facePartial; + public final float[] brightness = new float[4]; + public final int[] lightmap = new int[4]; + public int tintCacheIndex = -1; + public int tintCacheValue; + public final ModelBlockRenderer.Cache cache = (ModelBlockRenderer.Cache)ModelBlockRenderer.CACHE.get(); + } + @Environment(EnvType.CLIENT) protected static enum SizeInfo { - DOWN(Direction.DOWN, false), - UP(Direction.UP, false), - NORTH(Direction.NORTH, false), - SOUTH(Direction.SOUTH, false), - WEST(Direction.WEST, false), - EAST(Direction.EAST, false), - FLIP_DOWN(Direction.DOWN, true), - FLIP_UP(Direction.UP, true), - FLIP_NORTH(Direction.NORTH, true), - FLIP_SOUTH(Direction.SOUTH, true), - FLIP_WEST(Direction.WEST, true), - FLIP_EAST(Direction.EAST, true); + DOWN(0), + UP(1), + NORTH(2), + SOUTH(3), + WEST(4), + EAST(5), + FLIP_DOWN(6), + FLIP_UP(7), + FLIP_NORTH(8), + FLIP_SOUTH(9), + FLIP_WEST(10), + FLIP_EAST(11); - final int shape; + public static final int COUNT = values().length; + final int index; - private SizeInfo(final Direction direction, final boolean flip) { - this.shape = direction.get3DDataValue() + (flip ? ModelBlockRenderer.DIRECTIONS.length : 0); + private SizeInfo(final int index) { + this.index = index; } } } diff --git a/net/minecraft/client/renderer/block/model/BakedQuad.java b/net/minecraft/client/renderer/block/model/BakedQuad.java index e6b9d34c..58b0c93e 100644 --- a/net/minecraft/client/renderer/block/model/BakedQuad.java +++ b/net/minecraft/client/renderer/block/model/BakedQuad.java @@ -6,51 +6,8 @@ import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.core.Direction; @Environment(EnvType.CLIENT) -public class BakedQuad { - /** - * Joined 4 vertex records, each stores packed data according to the VertexFormat of the quad. Vanilla minecraft uses DefaultVertexFormats.BLOCK, Forge uses (usually) ITEM, use BakedQuad.getFormat() to get the correct format. - */ - protected final int[] vertices; - protected final int tintIndex; - protected final Direction direction; - protected final TextureAtlasSprite sprite; - private final boolean shade; - private final int lightEmission; - - public BakedQuad(int[] verticies, int tintIndex, Direction direction, TextureAtlasSprite sprite, boolean shade, int lightEmission) { - this.vertices = verticies; - this.tintIndex = tintIndex; - this.direction = direction; - this.sprite = sprite; - this.shade = shade; - this.lightEmission = lightEmission; - } - - public TextureAtlasSprite getSprite() { - return this.sprite; - } - - public int[] getVertices() { - return this.vertices; - } - +public record BakedQuad(int[] vertices, int tintIndex, Direction direction, TextureAtlasSprite sprite, boolean shade, int lightEmission) { public boolean isTinted() { return this.tintIndex != -1; } - - public int getTintIndex() { - return this.tintIndex; - } - - public Direction getDirection() { - return this.direction; - } - - public boolean isShade() { - return this.shade; - } - - public int getLightEmission() { - return this.lightEmission; - } } diff --git a/net/minecraft/client/renderer/block/model/BlockElement.java b/net/minecraft/client/renderer/block/model/BlockElement.java index 370b1e0a..677e9ff4 100644 --- a/net/minecraft/client/renderer/block/model/BlockElement.java +++ b/net/minecraft/client/renderer/block/model/BlockElement.java @@ -14,59 +14,24 @@ import java.util.Map.Entry; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.core.Direction; -import net.minecraft.core.Direction.Axis; import net.minecraft.util.GsonHelper; import net.minecraft.util.Mth; import org.jetbrains.annotations.Nullable; import org.joml.Vector3f; +import org.joml.Vector3fc; @Environment(EnvType.CLIENT) -public class BlockElement { +public record BlockElement( + Vector3fc from, Vector3fc to, Map faces, @Nullable BlockElementRotation rotation, boolean shade, int lightEmission +) { private static final boolean DEFAULT_RESCALE = false; private static final float MIN_EXTENT = -16.0F; private static final float MAX_EXTENT = 32.0F; - public final Vector3f from; - public final Vector3f to; - public final Map faces; - @Nullable - public final BlockElementRotation rotation; - public final boolean shade; - public final int lightEmission; - public BlockElement(Vector3f from, Vector3f to, Map faces) { + public BlockElement(Vector3fc from, Vector3fc to, Map faces) { this(from, to, faces, null, true, 0); } - public BlockElement( - Vector3f from, Vector3f to, Map faces, @Nullable BlockElementRotation rotation, boolean shade, int lightEmission - ) { - this.from = from; - this.to = to; - this.faces = faces; - this.rotation = rotation; - this.shade = shade; - this.lightEmission = lightEmission; - this.fillUvs(); - } - - private void fillUvs() { - for (Entry entry : this.faces.entrySet()) { - float[] fs = this.uvsByFace((Direction)entry.getKey()); - ((BlockElementFace)entry.getValue()).uv().setMissingUv(fs); - } - } - - private float[] uvsByFace(Direction face) { - return switch (face) { - case DOWN -> new float[]{this.from.x(), 16.0F - this.to.z(), this.to.x(), 16.0F - this.from.z()}; - case UP -> new float[]{this.from.x(), this.from.z(), this.to.x(), this.to.z()}; - case NORTH -> new float[]{16.0F - this.to.x(), 16.0F - this.to.y(), 16.0F - this.from.x(), 16.0F - this.from.y()}; - case SOUTH -> new float[]{this.from.x(), 16.0F - this.to.y(), this.to.x(), 16.0F - this.from.y()}; - case WEST -> new float[]{this.from.z(), 16.0F - this.to.y(), this.to.z(), 16.0F - this.from.y()}; - case EAST -> new float[]{16.0F - this.to.z(), 16.0F - this.to.y(), 16.0F - this.from.z(), 16.0F - this.from.y()}; - }; - } - @Environment(EnvType.CLIENT) protected static class Deserializer implements JsonDeserializer { private static final boolean DEFAULT_SHADE = true; @@ -105,7 +70,7 @@ public class BlockElement { JsonObject jsonObject = GsonHelper.getAsJsonObject(json, "rotation"); Vector3f vector3f = this.getVector3f(jsonObject, "origin"); vector3f.mul(0.0625F); - Axis axis = this.getAxis(jsonObject); + Direction.Axis axis = this.getAxis(jsonObject); float f = this.getAngle(jsonObject); boolean bl = GsonHelper.getAsBoolean(jsonObject, "rescale", false); blockElementRotation = new BlockElementRotation(vector3f, axis, f, bl); @@ -123,9 +88,9 @@ public class BlockElement { } } - private Axis getAxis(JsonObject json) { + private Direction.Axis getAxis(JsonObject json) { String string = GsonHelper.getAsString(json, "axis"); - Axis axis = Axis.byName(string.toLowerCase(Locale.ROOT)); + Direction.Axis axis = Direction.Axis.byName(string.toLowerCase(Locale.ROOT)); if (axis == null) { throw new JsonParseException("Invalid rotation axis: " + string); } else { diff --git a/net/minecraft/client/renderer/block/model/BlockElementFace.java b/net/minecraft/client/renderer/block/model/BlockElementFace.java index 5fb81c53..bbef9d87 100644 --- a/net/minecraft/client/renderer/block/model/BlockElementFace.java +++ b/net/minecraft/client/renderer/block/model/BlockElementFace.java @@ -1,10 +1,12 @@ package net.minecraft.client.renderer.block.model; +import com.google.gson.JsonArray; import com.google.gson.JsonDeserializationContext; import com.google.gson.JsonDeserializer; import com.google.gson.JsonElement; import com.google.gson.JsonObject; import com.google.gson.JsonParseException; +import com.mojang.math.Quadrant; import java.lang.reflect.Type; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -13,34 +15,78 @@ import net.minecraft.util.GsonHelper; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) -public record BlockElementFace(@Nullable Direction cullForDirection, int tintIndex, String texture, BlockFaceUV uv) { +public record BlockElementFace(@Nullable Direction cullForDirection, int tintIndex, String texture, @Nullable BlockElementFace.UVs uvs, Quadrant rotation) { public static final int NO_TINT = -1; + public static float getU(BlockElementFace.UVs uvs, Quadrant rotation, int vertexIndex) { + return uvs.getVertexU(rotation.rotateVertexIndex(vertexIndex)) / 16.0F; + } + + public static float getV(BlockElementFace.UVs uvs, Quadrant rotation, int vertexIndex) { + return uvs.getVertexV(rotation.rotateVertexIndex(vertexIndex)) / 16.0F; + } + @Environment(EnvType.CLIENT) protected static class Deserializer implements JsonDeserializer { private static final int DEFAULT_TINT_INDEX = -1; + private static final int DEFAULT_ROTATION = 0; public BlockElementFace deserialize(JsonElement json, Type type, JsonDeserializationContext context) throws JsonParseException { JsonObject jsonObject = json.getAsJsonObject(); - Direction direction = this.getCullFacing(jsonObject); - int i = this.getTintIndex(jsonObject); - String string = this.getTexture(jsonObject); - BlockFaceUV blockFaceUV = context.deserialize(jsonObject, BlockFaceUV.class); - return new BlockElementFace(direction, i, string, blockFaceUV); + Direction direction = getCullFacing(jsonObject); + int i = getTintIndex(jsonObject); + String string = getTexture(jsonObject); + BlockElementFace.UVs uVs = getUVs(jsonObject); + Quadrant quadrant = getRotation(jsonObject); + return new BlockElementFace(direction, i, string, uVs, quadrant); } - protected int getTintIndex(JsonObject json) { + private static int getTintIndex(JsonObject json) { return GsonHelper.getAsInt(json, "tintindex", -1); } - private String getTexture(JsonObject json) { + private static String getTexture(JsonObject json) { return GsonHelper.getAsString(json, "texture"); } @Nullable - private Direction getCullFacing(JsonObject json) { + private static Direction getCullFacing(JsonObject json) { String string = GsonHelper.getAsString(json, "cullface", ""); return Direction.byName(string); } + + private static Quadrant getRotation(JsonObject json) { + int i = GsonHelper.getAsInt(json, "rotation", 0); + return Quadrant.parseJson(i); + } + + @Nullable + private static BlockElementFace.UVs getUVs(JsonObject json) { + if (!json.has("uv")) { + return null; + } else { + JsonArray jsonArray = GsonHelper.getAsJsonArray(json, "uv"); + if (jsonArray.size() != 4) { + throw new JsonParseException("Expected 4 uv values, found: " + jsonArray.size()); + } else { + float f = GsonHelper.convertToFloat(jsonArray.get(0), "minU"); + float g = GsonHelper.convertToFloat(jsonArray.get(1), "minV"); + float h = GsonHelper.convertToFloat(jsonArray.get(2), "maxU"); + float i = GsonHelper.convertToFloat(jsonArray.get(3), "maxV"); + return new BlockElementFace.UVs(f, g, h, i); + } + } + } + } + + @Environment(EnvType.CLIENT) + public record UVs(float minU, float minV, float maxU, float maxV) { + public float getVertexU(int vertexIndex) { + return vertexIndex != 0 && vertexIndex != 1 ? this.maxU : this.minU; + } + + public float getVertexV(int vertexIndex) { + return vertexIndex != 0 && vertexIndex != 3 ? this.maxV : this.minV; + } } } diff --git a/net/minecraft/client/renderer/block/model/BlockFaceUV.java b/net/minecraft/client/renderer/block/model/BlockFaceUV.java deleted file mode 100644 index 907cdf86..00000000 --- a/net/minecraft/client/renderer/block/model/BlockFaceUV.java +++ /dev/null @@ -1,97 +0,0 @@ -package net.minecraft.client.renderer.block.model; - -import com.google.gson.JsonArray; -import com.google.gson.JsonDeserializationContext; -import com.google.gson.JsonDeserializer; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.JsonParseException; -import java.lang.reflect.Type; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.util.GsonHelper; -import org.jetbrains.annotations.Nullable; - -@Environment(EnvType.CLIENT) -public class BlockFaceUV { - public float[] uvs; - public final int rotation; - - public BlockFaceUV(@Nullable float[] uvs, int rotation) { - this.uvs = uvs; - this.rotation = rotation; - } - - public float getU(int index) { - if (this.uvs == null) { - throw new NullPointerException("uvs"); - } else { - int i = this.getShiftedIndex(index); - return this.uvs[i != 0 && i != 1 ? 2 : 0]; - } - } - - public float getV(int index) { - if (this.uvs == null) { - throw new NullPointerException("uvs"); - } else { - int i = this.getShiftedIndex(index); - return this.uvs[i != 0 && i != 3 ? 3 : 1]; - } - } - - private int getShiftedIndex(int index) { - return (index + this.rotation / 90) % 4; - } - - public int getReverseIndex(int index) { - return (index + 4 - this.rotation / 90) % 4; - } - - public void setMissingUv(float[] uvs) { - if (this.uvs == null) { - this.uvs = uvs; - } - } - - @Environment(EnvType.CLIENT) - protected static class Deserializer implements JsonDeserializer { - private static final int DEFAULT_ROTATION = 0; - - public BlockFaceUV deserialize(JsonElement json, Type type, JsonDeserializationContext context) throws JsonParseException { - JsonObject jsonObject = json.getAsJsonObject(); - float[] fs = this.getUVs(jsonObject); - int i = this.getRotation(jsonObject); - return new BlockFaceUV(fs, i); - } - - protected int getRotation(JsonObject json) { - int i = GsonHelper.getAsInt(json, "rotation", 0); - if (i >= 0 && i % 90 == 0 && i / 90 <= 3) { - return i; - } else { - throw new JsonParseException("Invalid rotation " + i + " found, only 0/90/180/270 allowed"); - } - } - - @Nullable - private float[] getUVs(JsonObject json) { - if (!json.has("uv")) { - return null; - } else { - JsonArray jsonArray = GsonHelper.getAsJsonArray(json, "uv"); - if (jsonArray.size() != 4) { - throw new JsonParseException("Expected 4 uv values, found: " + jsonArray.size()); - } else { - float[] fs = new float[4]; - - for (int i = 0; i < fs.length; i++) { - fs[i] = GsonHelper.convertToFloat(jsonArray.get(i), "uv[" + i + "]"); - } - - return fs; - } - } - } - } -} diff --git a/net/minecraft/client/renderer/block/model/BlockModel.java b/net/minecraft/client/renderer/block/model/BlockModel.java index 99e0fdbc..7bf7625b 100644 --- a/net/minecraft/client/renderer/block/model/BlockModel.java +++ b/net/minecraft/client/renderer/block/model/BlockModel.java @@ -15,123 +15,39 @@ import java.util.List; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.texture.TextureAtlas; -import net.minecraft.client.resources.model.BakedModel; -import net.minecraft.client.resources.model.ModelBaker; -import net.minecraft.client.resources.model.ModelState; -import net.minecraft.client.resources.model.ResolvableModel; -import net.minecraft.client.resources.model.SimpleBakedModel; +import net.minecraft.client.resources.model.UnbakedGeometry; import net.minecraft.client.resources.model.UnbakedModel; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.GsonHelper; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) -public class BlockModel implements UnbakedModel { +public record BlockModel( + @Nullable UnbakedGeometry geometry, + @Nullable UnbakedModel.GuiLight guiLight, + @Nullable Boolean ambientOcclusion, + @Nullable ItemTransforms transforms, + TextureSlots.Data textureSlots, + @Nullable ResourceLocation parent +) implements UnbakedModel { @VisibleForTesting static final Gson GSON = new GsonBuilder() .registerTypeAdapter(BlockModel.class, new BlockModel.Deserializer()) .registerTypeAdapter(BlockElement.class, new BlockElement.Deserializer()) .registerTypeAdapter(BlockElementFace.class, new BlockElementFace.Deserializer()) - .registerTypeAdapter(BlockFaceUV.class, new BlockFaceUV.Deserializer()) .registerTypeAdapter(ItemTransform.class, new ItemTransform.Deserializer()) .registerTypeAdapter(ItemTransforms.class, new ItemTransforms.Deserializer()) .create(); - private final List elements; - @Nullable - private final UnbakedModel.GuiLight guiLight; - @Nullable - private final Boolean hasAmbientOcclusion; - @Nullable - private final ItemTransforms transforms; - @VisibleForTesting - private final TextureSlots.Data textureSlots; - @Nullable - private UnbakedModel parent; - @Nullable - private final ResourceLocation parentLocation; public static BlockModel fromStream(Reader reader) { return GsonHelper.fromJson(GSON, reader, BlockModel.class); } - public BlockModel( - @Nullable ResourceLocation parentLocation, - List elements, - TextureSlots.Data textureSlots, - @Nullable Boolean hasAmbientOcclusion, - @Nullable UnbakedModel.GuiLight guiLight, - @Nullable ItemTransforms transforms - ) { - this.elements = elements; - this.hasAmbientOcclusion = hasAmbientOcclusion; - this.guiLight = guiLight; - this.textureSlots = textureSlots; - this.parentLocation = parentLocation; - this.transforms = transforms; - } - - @Nullable - @Override - public Boolean getAmbientOcclusion() { - return this.hasAmbientOcclusion; - } - - @Nullable - @Override - public UnbakedModel.GuiLight getGuiLight() { - return this.guiLight; - } - - @Override - public void resolveDependencies(ResolvableModel.Resolver resolver) { - if (this.parentLocation != null) { - this.parent = resolver.resolve(this.parentLocation); - } - } - - @Nullable - @Override - public UnbakedModel getParent() { - return this.parent; - } - - @Override - public TextureSlots.Data getTextureSlots() { - return this.textureSlots; - } - - @Nullable - @Override - public ItemTransforms getTransforms() { - return this.transforms; - } - - @Override - public BakedModel bake( - TextureSlots textureSlots, ModelBaker baker, ModelState modelState, boolean hasAmbientOcclusion, boolean useBlockLight, ItemTransforms transforms - ) { - return this.elements.isEmpty() && this.parent != null - ? this.parent.bake(textureSlots, baker, modelState, hasAmbientOcclusion, useBlockLight, transforms) - : SimpleBakedModel.bakeElements(this.elements, textureSlots, baker.sprites(), modelState, hasAmbientOcclusion, useBlockLight, true, transforms); - } - - @Nullable - @VisibleForTesting - List getElements() { - return this.elements; - } - - @Nullable - @VisibleForTesting - ResourceLocation getParentLocation() { - return this.parentLocation; - } - @Environment(EnvType.CLIENT) public static class Deserializer implements JsonDeserializer { public BlockModel deserialize(JsonElement json, Type type, JsonDeserializationContext context) throws JsonParseException { JsonObject jsonObject = json.getAsJsonObject(); - List list = this.getElements(context, jsonObject); + UnbakedGeometry unbakedGeometry = this.getElements(context, jsonObject); String string = this.getParentName(jsonObject); TextureSlots.Data data = this.getTextureMap(jsonObject); Boolean boolean_ = this.getAmbientOcclusion(jsonObject); @@ -147,7 +63,7 @@ public class BlockModel implements UnbakedModel { } ResourceLocation resourceLocation = string.isEmpty() ? null : ResourceLocation.parse(string); - return new BlockModel(resourceLocation, list, data, boolean_, guiLight, itemTransforms); + return new BlockModel(unbakedGeometry, guiLight, boolean_, itemTransforms, data, resourceLocation); } private TextureSlots.Data getTextureMap(JsonObject json) { @@ -168,9 +84,10 @@ public class BlockModel implements UnbakedModel { return json.has("ambientocclusion") ? GsonHelper.getAsBoolean(json, "ambientocclusion") : null; } - protected List getElements(JsonDeserializationContext context, JsonObject json) { + @Nullable + protected UnbakedGeometry getElements(JsonDeserializationContext context, JsonObject json) { if (!json.has("elements")) { - return List.of(); + return null; } else { List list = new ArrayList(); @@ -178,7 +95,7 @@ public class BlockModel implements UnbakedModel { list.add((BlockElement)context.deserialize(jsonElement, BlockElement.class)); } - return list; + return new SimpleUnbakedGeometry(list); } } } diff --git a/net/minecraft/client/renderer/block/model/BlockModelDefinition.java b/net/minecraft/client/renderer/block/model/BlockModelDefinition.java index 91648f42..569e860f 100644 --- a/net/minecraft/client/renderer/block/model/BlockModelDefinition.java +++ b/net/minecraft/client/renderer/block/model/BlockModelDefinition.java @@ -1,175 +1,104 @@ package net.minecraft.client.renderer.block.model; -import com.google.common.annotations.VisibleForTesting; -import com.google.common.collect.Maps; -import com.google.common.collect.Sets; -import com.google.gson.Gson; -import com.google.gson.GsonBuilder; -import com.google.gson.JsonArray; -import com.google.gson.JsonDeserializationContext; -import com.google.gson.JsonDeserializer; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.JsonParseException; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableList.Builder; import com.mojang.logging.LogUtils; -import java.io.Reader; -import java.lang.reflect.Type; +import com.mojang.serialization.Codec; +import com.mojang.serialization.DataResult; +import com.mojang.serialization.codecs.RecordCodecBuilder; import java.util.IdentityHashMap; import java.util.List; import java.util.Map; -import java.util.Objects; -import java.util.Set; -import java.util.Map.Entry; +import java.util.Optional; +import java.util.function.BiConsumer; +import java.util.function.Predicate; +import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.multipart.MultiPart; +import net.minecraft.client.renderer.block.model.multipart.MultiPartModel; import net.minecraft.client.renderer.block.model.multipart.Selector; -import net.minecraft.util.GsonHelper; +import net.minecraft.util.ExtraCodecs; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.StateDefinition; -import org.jetbrains.annotations.Nullable; +import net.minecraft.world.level.block.state.StateHolder; import org.slf4j.Logger; @Environment(EnvType.CLIENT) -public class BlockModelDefinition { - private static final Logger LOGGER = LogUtils.getLogger(); - public static final Gson GSON = new GsonBuilder() - .registerTypeAdapter(BlockModelDefinition.class, new BlockModelDefinition.Deserializer()) - .registerTypeAdapter(Variant.class, new Variant.Deserializer()) - .registerTypeAdapter(MultiVariant.class, new MultiVariant.Deserializer()) - .registerTypeAdapter(MultiPart.Definition.class, new MultiPart.Deserializer()) - .registerTypeAdapter(Selector.class, new Selector.Deserializer()) - .create(); - private final Map variants; - @Nullable - private final MultiPart.Definition multiPart; +public record BlockModelDefinition( + Optional simpleModels, Optional multiPart +) { + static final Logger LOGGER = LogUtils.getLogger(); + public static final Codec CODEC = RecordCodecBuilder.create( + instance -> instance.group( + BlockModelDefinition.SimpleModelSelectors.CODEC.optionalFieldOf("variants").forGetter(BlockModelDefinition::simpleModels), + BlockModelDefinition.MultiPartDefinition.CODEC.optionalFieldOf("multipart").forGetter(BlockModelDefinition::multiPart) + ) + .apply(instance, BlockModelDefinition::new) + ) + .validate( + blockModelDefinition -> blockModelDefinition.simpleModels().isEmpty() && blockModelDefinition.multiPart().isEmpty() + ? DataResult.error(() -> "Neither 'variants' nor 'multipart' found") + : DataResult.success(blockModelDefinition) + ); - public static BlockModelDefinition fromStream(Reader reader) { - return GsonHelper.fromJson(GSON, reader, BlockModelDefinition.class); - } + public Map instantiate(StateDefinition stateDefinition, Supplier name) { + Map map = new IdentityHashMap(); + this.simpleModels.ifPresent(simpleModelSelectors -> simpleModelSelectors.instantiate(stateDefinition, name, (blockState, unbakedRoot) -> { + BlockStateModel.UnbakedRoot unbakedRoot2 = (BlockStateModel.UnbakedRoot)map.put(blockState, unbakedRoot); + if (unbakedRoot2 != null) { + throw new IllegalArgumentException("Overlapping definition on state: " + blockState); + } + })); + this.multiPart.ifPresent(multiPartDefinition -> { + List list = stateDefinition.getPossibleStates(); + BlockStateModel.UnbakedRoot unbakedRoot = multiPartDefinition.instantiate(stateDefinition); - public static BlockModelDefinition fromJsonElement(JsonElement json) { - return GSON.fromJson(json, BlockModelDefinition.class); - } - - public BlockModelDefinition(Map variants, @Nullable MultiPart.Definition multiPart) { - this.multiPart = multiPart; - this.variants = variants; - } - - @VisibleForTesting - public MultiVariant getVariant(String key) { - MultiVariant multiVariant = (MultiVariant)this.variants.get(key); - if (multiVariant == null) { - throw new BlockModelDefinition.MissingVariantException(); - } else { - return multiVariant; - } - } - - public boolean equals(Object object) { - if (this == object) { - return true; - } else { - return !(object instanceof BlockModelDefinition blockModelDefinition) - ? false - : this.variants.equals(blockModelDefinition.variants) && Objects.equals(this.multiPart, blockModelDefinition.multiPart); - } - } - - public int hashCode() { - return 31 * this.variants.hashCode() + (this.multiPart != null ? this.multiPart.hashCode() : 0); - } - - @VisibleForTesting - public Set getMultiVariants() { - Set set = Sets.newHashSet(this.variants.values()); - if (this.multiPart != null) { - set.addAll(this.multiPart.getMultiVariants()); - } - - return set; - } - - @Nullable - public MultiPart.Definition getMultiPart() { - return this.multiPart; - } - - public Map instantiate(StateDefinition stateDefinition, String name) { - Map map = new IdentityHashMap(); - List list = stateDefinition.getPossibleStates(); - MultiPart multiPart; - if (this.multiPart != null) { - multiPart = this.multiPart.instantiate(stateDefinition); - list.forEach(blockState -> map.put(blockState, multiPart)); - } else { - multiPart = null; - } - - this.variants - .forEach( - (string2, multiVariant) -> { - try { - list.stream() - .filter(VariantSelector.predicate(stateDefinition, string2)) - .forEach( - blockState -> { - UnbakedBlockStateModel unbakedBlockStateModel = (UnbakedBlockStateModel)map.put(blockState, multiVariant); - if (unbakedBlockStateModel != null && unbakedBlockStateModel != multiPart) { - String stringx = (String)((Entry)this.variants.entrySet().stream().filter(entry -> entry.getValue() == unbakedBlockStateModel).findFirst().get()) - .getKey(); - throw new RuntimeException("Overlapping definition with: " + stringx); - } - } - ); - } catch (Exception var9) { - LOGGER.warn("Exception loading blockstate definition: '{}' for variant: '{}': {}", name, string2, var9.getMessage()); - } - } - ); + for (BlockState blockState : list) { + map.putIfAbsent(blockState, unbakedRoot); + } + }); return map; } @Environment(EnvType.CLIENT) - public static class Deserializer implements JsonDeserializer { - public BlockModelDefinition deserialize(JsonElement json, Type type, JsonDeserializationContext context) throws JsonParseException { - JsonObject jsonObject = json.getAsJsonObject(); - Map map = this.getVariants(context, jsonObject); - MultiPart.Definition definition = this.getMultiPart(context, jsonObject); - if (map.isEmpty() && definition == null) { - throw new JsonParseException("Neither 'variants' nor 'multipart' found"); - } else { - return new BlockModelDefinition(map, definition); - } - } + public record MultiPartDefinition(List selectors) { + public static final Codec CODEC = ExtraCodecs.nonEmptyList(Selector.CODEC.listOf()) + .xmap(BlockModelDefinition.MultiPartDefinition::new, BlockModelDefinition.MultiPartDefinition::selectors); - protected Map getVariants(JsonDeserializationContext context, JsonObject json) { - Map map = Maps.newHashMap(); - if (json.has("variants")) { - JsonObject jsonObject = GsonHelper.getAsJsonObject(json, "variants"); + public MultiPartModel.Unbaked instantiate(StateDefinition stateDefinition) { + Builder> builder = ImmutableList.builderWithExpectedSize(this.selectors.size()); - for (Entry entry : jsonObject.entrySet()) { - map.put((String)entry.getKey(), (MultiVariant)context.deserialize((JsonElement)entry.getValue(), MultiVariant.class)); - } + for (Selector selector : this.selectors) { + builder.add(new MultiPartModel.Selector<>(selector.instantiate(stateDefinition), selector.variant())); } - return map; - } - - @Nullable - protected MultiPart.Definition getMultiPart(JsonDeserializationContext context, JsonObject json) { - if (!json.has("multipart")) { - return null; - } else { - JsonArray jsonArray = GsonHelper.getAsJsonArray(json, "multipart"); - return context.deserialize(jsonArray, MultiPart.Definition.class); - } + return new MultiPartModel.Unbaked(builder.build()); } } @Environment(EnvType.CLIENT) - protected static class MissingVariantException extends RuntimeException { + public record SimpleModelSelectors(Map models) { + public static final Codec CODEC = ExtraCodecs.nonEmptyMap( + Codec.unboundedMap(Codec.STRING, BlockStateModel.Unbaked.CODEC) + ) + .xmap(BlockModelDefinition.SimpleModelSelectors::new, BlockModelDefinition.SimpleModelSelectors::models); + + public void instantiate(StateDefinition stateDefinition, Supplier name, BiConsumer output) { + this.models.forEach((string, unbaked) -> { + try { + Predicate> predicate = VariantSelector.predicate(stateDefinition, string); + BlockStateModel.UnbakedRoot unbakedRoot = unbaked.asRoot(); + + for (BlockState blockState : stateDefinition.getPossibleStates()) { + if (predicate.test(blockState)) { + output.accept(blockState, unbakedRoot); + } + } + } catch (Exception var9) { + BlockModelDefinition.LOGGER.warn("Exception loading blockstate definition: '{}' for variant: '{}': {}", name.get(), string, var9.getMessage()); + } + }); + } } } diff --git a/net/minecraft/client/renderer/block/model/BlockModelPart.java b/net/minecraft/client/renderer/block/model/BlockModelPart.java new file mode 100644 index 00000000..1a50f718 --- /dev/null +++ b/net/minecraft/client/renderer/block/model/BlockModelPart.java @@ -0,0 +1,24 @@ +package net.minecraft.client.renderer.block.model; + +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.client.resources.model.ModelBaker; +import net.minecraft.client.resources.model.ResolvableModel; +import net.minecraft.core.Direction; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public interface BlockModelPart { + List getQuads(@Nullable Direction direction); + + boolean useAmbientOcclusion(); + + TextureAtlasSprite particleIcon(); + + @Environment(EnvType.CLIENT) + public interface Unbaked extends ResolvableModel { + BlockModelPart bake(ModelBaker modelBaker); + } +} diff --git a/net/minecraft/client/renderer/block/model/BlockStateModel.java b/net/minecraft/client/renderer/block/model/BlockStateModel.java new file mode 100644 index 00000000..620e329b --- /dev/null +++ b/net/minecraft/client/renderer/block/model/BlockStateModel.java @@ -0,0 +1,106 @@ +package net.minecraft.client.renderer.block.model; + +import com.google.common.collect.Lists; +import com.mojang.datafixers.util.Either; +import com.mojang.serialization.Codec; +import com.mojang.serialization.DataResult; +import com.mojang.serialization.codecs.RecordCodecBuilder; +import it.unimi.dsi.fastutil.objects.ObjectArrayList; +import java.util.ArrayList; +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.BlockStateModel.SimpleCachedUnbakedRoot.1; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.client.resources.model.ModelBaker; +import net.minecraft.client.resources.model.ResolvableModel; +import net.minecraft.client.resources.model.WeightedVariants; +import net.minecraft.util.ExtraCodecs; +import net.minecraft.util.RandomSource; +import net.minecraft.util.random.Weighted; +import net.minecraft.util.random.WeightedList; +import net.minecraft.world.level.block.state.BlockState; + +@Environment(EnvType.CLIENT) +public interface BlockStateModel { + void collectParts(RandomSource random, List output); + + default List collectParts(RandomSource random) { + List list = new ObjectArrayList<>(); + this.collectParts(random, list); + return list; + } + + TextureAtlasSprite particleIcon(); + + @Environment(EnvType.CLIENT) + public static class SimpleCachedUnbakedRoot implements BlockStateModel.UnbakedRoot { + final BlockStateModel.Unbaked contents; + private final ModelBaker.SharedOperationKey bakingKey = new 1(this); + + public SimpleCachedUnbakedRoot(BlockStateModel.Unbaked contents) { + this.contents = contents; + } + + @Override + public void resolveDependencies(ResolvableModel.Resolver resolver) { + this.contents.resolveDependencies(resolver); + } + + @Override + public BlockStateModel bake(BlockState state, ModelBaker baker) { + return baker.compute(this.bakingKey); + } + + @Override + public Object visualEqualityGroup(BlockState state) { + return this; + } + } + + @Environment(EnvType.CLIENT) + public interface Unbaked extends ResolvableModel { + Codec> ELEMENT_CODEC = RecordCodecBuilder.create( + instance -> instance.group(Variant.MAP_CODEC.forGetter(Weighted::value), ExtraCodecs.POSITIVE_INT.optionalFieldOf("weight", 1).forGetter(Weighted::weight)) + .apply(instance, Weighted::new) + ); + Codec HARDCODED_WEIGHTED_CODEC = ExtraCodecs.nonEmptyList(ELEMENT_CODEC.listOf()) + .flatComapMap( + list -> new WeightedVariants.Unbaked(WeightedList.of(Lists.transform(list, weighted -> weighted.map(SingleVariant.Unbaked::new)))), unbaked -> { + List> list = unbaked.entries().unwrap(); + List> list2 = new ArrayList(list.size()); + + for (Weighted weighted : list) { + if (!(weighted.value() instanceof SingleVariant.Unbaked unbaked2)) { + return DataResult.error(() -> "Only single variants are supported"); + } + + list2.add(new Weighted<>(unbaked2.variant(), weighted.weight())); + } + + return DataResult.success(list2); + } + ); + Codec CODEC = Codec.either(HARDCODED_WEIGHTED_CODEC, SingleVariant.Unbaked.CODEC) + .flatComapMap(either -> either.map(unbaked -> unbaked, unbaked -> unbaked), unbaked -> { + return switch (unbaked) { + case SingleVariant.Unbaked unbaked3 -> DataResult.success(Either.right(unbaked3)); + case WeightedVariants.Unbaked unbaked4 -> DataResult.success(Either.left(unbaked4)); + default -> DataResult.error(() -> "Only a single variant or a list of variants are supported"); + }; + }); + + BlockStateModel bake(ModelBaker baker); + + default BlockStateModel.UnbakedRoot asRoot() { + return new BlockStateModel.SimpleCachedUnbakedRoot(this); + } + } + + @Environment(EnvType.CLIENT) + public interface UnbakedRoot extends ResolvableModel { + BlockStateModel bake(BlockState state, ModelBaker baker); + + Object visualEqualityGroup(BlockState state); + } +} diff --git a/net/minecraft/client/renderer/block/model/FaceBakery.java b/net/minecraft/client/renderer/block/model/FaceBakery.java index a4b0e6e4..808def79 100644 --- a/net/minecraft/client/renderer/block/model/FaceBakery.java +++ b/net/minecraft/client/renderer/block/model/FaceBakery.java @@ -1,6 +1,10 @@ package net.minecraft.client.renderer.block.model; +import com.google.common.annotations.VisibleForTesting; +import com.mojang.math.MatrixUtil; +import com.mojang.math.Quadrant; import com.mojang.math.Transformation; +import java.util.function.Consumer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.FaceInfo; @@ -8,15 +12,14 @@ import net.minecraft.client.renderer.FaceInfo.Constants; import net.minecraft.client.renderer.FaceInfo.VertexInfo; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.resources.model.ModelState; -import net.minecraft.core.BlockMath; import net.minecraft.core.Direction; -import net.minecraft.core.Vec3i; import net.minecraft.util.Mth; import org.jetbrains.annotations.Nullable; -import org.joml.Matrix3f; import org.joml.Matrix4f; +import org.joml.Matrix4fc; import org.joml.Quaternionf; import org.joml.Vector3f; +import org.joml.Vector3fc; import org.joml.Vector4f; @Environment(EnvType.CLIENT) @@ -28,34 +31,38 @@ public class FaceBakery { private static final int COLOR_INDEX = 3; public static final int UV_INDEX = 4; + @VisibleForTesting + static BlockElementFace.UVs defaultFaceUV(Vector3fc posFrom, Vector3fc posTo, Direction facing) { + return switch (facing) { + case DOWN -> new BlockElementFace.UVs(posFrom.x(), 16.0F - posTo.z(), posTo.x(), 16.0F - posFrom.z()); + case UP -> new BlockElementFace.UVs(posFrom.x(), posFrom.z(), posTo.x(), posTo.z()); + case NORTH -> new BlockElementFace.UVs(16.0F - posTo.x(), 16.0F - posTo.y(), 16.0F - posFrom.x(), 16.0F - posFrom.y()); + case SOUTH -> new BlockElementFace.UVs(posFrom.x(), 16.0F - posTo.y(), posTo.x(), 16.0F - posFrom.y()); + case WEST -> new BlockElementFace.UVs(posFrom.z(), 16.0F - posTo.y(), posTo.z(), 16.0F - posFrom.y()); + case EAST -> new BlockElementFace.UVs(16.0F - posTo.z(), 16.0F - posTo.y(), 16.0F - posFrom.z(), 16.0F - posFrom.y()); + }; + } + public static BakedQuad bakeQuad( - Vector3f posFrom, - Vector3f posTo, + Vector3fc posFrom, + Vector3fc posTo, BlockElementFace face, TextureAtlasSprite sprite, Direction facing, - ModelState transform, + ModelState modelState, @Nullable BlockElementRotation rotation, boolean shade, int lightEmission ) { - BlockFaceUV blockFaceUV = face.uv(); - if (transform.isUvLocked()) { - blockFaceUV = recomputeUVs(face.uv(), facing, transform.getRotation()); + BlockElementFace.UVs uVs = face.uvs(); + if (uVs == null) { + uVs = defaultFaceUV(posFrom, posTo, facing); } - float[] fs = new float[blockFaceUV.uvs.length]; - System.arraycopy(blockFaceUV.uvs, 0, fs, 0, fs.length); - float f = sprite.uvShrinkRatio(); - float g = (blockFaceUV.uvs[0] + blockFaceUV.uvs[0] + blockFaceUV.uvs[2] + blockFaceUV.uvs[2]) / 4.0F; - float h = (blockFaceUV.uvs[1] + blockFaceUV.uvs[1] + blockFaceUV.uvs[3] + blockFaceUV.uvs[3]) / 4.0F; - blockFaceUV.uvs[0] = Mth.lerp(f, blockFaceUV.uvs[0], g); - blockFaceUV.uvs[2] = Mth.lerp(f, blockFaceUV.uvs[2], g); - blockFaceUV.uvs[1] = Mth.lerp(f, blockFaceUV.uvs[1], h); - blockFaceUV.uvs[3] = Mth.lerp(f, blockFaceUV.uvs[3], h); - int[] is = makeVertices(blockFaceUV, sprite, facing, setupShape(posFrom, posTo), transform.getRotation(), rotation); + uVs = shrinkUVs(sprite, uVs); + Matrix4fc matrix4fc = modelState.inverseFaceTransformation(facing); + int[] is = makeVertices(uVs, face.rotation(), matrix4fc, sprite, facing, setupShape(posFrom, posTo), modelState.transformation(), rotation); Direction direction = calculateFacing(is); - System.arraycopy(fs, 0, blockFaceUV.uvs, 0, fs.length); if (rotation == null) { recalculateWinding(is, direction); } @@ -63,98 +70,96 @@ public class FaceBakery { return new BakedQuad(is, face.tintIndex(), direction, sprite, shade, lightEmission); } - public static BlockFaceUV recomputeUVs(BlockFaceUV uv, Direction facing, Transformation rotation) { - Matrix4f matrix4f = BlockMath.getUVLockTransform(rotation, facing).getMatrix(); - float f = uv.getU(uv.getReverseIndex(0)); - float g = uv.getV(uv.getReverseIndex(0)); - Vector4f vector4f = matrix4f.transform(new Vector4f(f / 16.0F, g / 16.0F, 0.0F, 1.0F)); - float h = 16.0F * vector4f.x(); - float i = 16.0F * vector4f.y(); - float j = uv.getU(uv.getReverseIndex(2)); - float k = uv.getV(uv.getReverseIndex(2)); - Vector4f vector4f2 = matrix4f.transform(new Vector4f(j / 16.0F, k / 16.0F, 0.0F, 1.0F)); - float l = 16.0F * vector4f2.x(); - float m = 16.0F * vector4f2.y(); - float n; - float o; - if (Math.signum(j - f) == Math.signum(l - h)) { - n = h; - o = l; - } else { - n = l; - o = h; - } - - float p; - float q; - if (Math.signum(k - g) == Math.signum(m - i)) { - p = i; - q = m; - } else { - p = m; - q = i; - } - - float r = (float)Math.toRadians(uv.rotation); - Matrix3f matrix3f = new Matrix3f(matrix4f); - Vector3f vector3f = matrix3f.transform(new Vector3f(Mth.cos(r), Mth.sin(r), 0.0F)); - int s = Math.floorMod(-((int)Math.round(Math.toDegrees(Math.atan2(vector3f.y(), vector3f.x())) / 90.0)) * 90, 360); - return new BlockFaceUV(new float[]{n, p, o, q}, s); + private static BlockElementFace.UVs shrinkUVs(TextureAtlasSprite sprite, BlockElementFace.UVs uvs) { + float f = uvs.minU(); + float g = uvs.minV(); + float h = uvs.maxU(); + float i = uvs.maxV(); + float j = sprite.uvShrinkRatio(); + float k = (f + f + h + h) / 4.0F; + float l = (g + g + i + i) / 4.0F; + return new BlockElementFace.UVs(Mth.lerp(j, f, k), Mth.lerp(j, g, l), Mth.lerp(j, h, k), Mth.lerp(j, i, l)); } private static int[] makeVertices( - BlockFaceUV uvs, + BlockElementFace.UVs uvs, + Quadrant rotation, + Matrix4fc inverseFaceTransform, TextureAtlasSprite sprite, - Direction orientation, - float[] posDiv16, + Direction facing, + float[] shape, Transformation transformation, @Nullable BlockElementRotation partRotation ) { + FaceInfo faceInfo = FaceInfo.fromFacing(facing); int[] is = new int[32]; for (int i = 0; i < 4; i++) { - bakeVertex(is, i, orientation, uvs, posDiv16, sprite, transformation, partRotation); + bakeVertex(is, i, faceInfo, uvs, rotation, inverseFaceTransform, shape, sprite, transformation, partRotation); } return is; } - private static float[] setupShape(Vector3f min, Vector3f max) { + private static float[] setupShape(Vector3fc posFrom, Vector3fc posTo) { float[] fs = new float[Direction.values().length]; - fs[Constants.MIN_X] = min.x() / 16.0F; - fs[Constants.MIN_Y] = min.y() / 16.0F; - fs[Constants.MIN_Z] = min.z() / 16.0F; - fs[Constants.MAX_X] = max.x() / 16.0F; - fs[Constants.MAX_Y] = max.y() / 16.0F; - fs[Constants.MAX_Z] = max.z() / 16.0F; + fs[Constants.MIN_X] = posFrom.x() / 16.0F; + fs[Constants.MIN_Y] = posFrom.y() / 16.0F; + fs[Constants.MIN_Z] = posFrom.z() / 16.0F; + fs[Constants.MAX_X] = posTo.x() / 16.0F; + fs[Constants.MAX_Y] = posTo.y() / 16.0F; + fs[Constants.MAX_Z] = posTo.z() / 16.0F; return fs; } private static void bakeVertex( int[] vertexData, int vertexIndex, - Direction facing, - BlockFaceUV blockFaceUV, - float[] posDiv16, + FaceInfo faceInfo, + BlockElementFace.UVs uvs, + Quadrant rotation, + Matrix4fc inverseFaceTransform, + float[] shape, TextureAtlasSprite sprite, Transformation transformation, @Nullable BlockElementRotation partRotation ) { - VertexInfo vertexInfo = FaceInfo.fromFacing(facing).getVertexInfo(vertexIndex); - Vector3f vector3f = new Vector3f(posDiv16[vertexInfo.xFace], posDiv16[vertexInfo.yFace], posDiv16[vertexInfo.zFace]); + VertexInfo vertexInfo = faceInfo.getVertexInfo(vertexIndex); + Vector3f vector3f = new Vector3f(shape[vertexInfo.xFace], shape[vertexInfo.yFace], shape[vertexInfo.zFace]); applyElementRotation(vector3f, partRotation); applyModelRotation(vector3f, transformation); - fillVertex(vertexData, vertexIndex, vector3f, sprite, blockFaceUV); + float f = BlockElementFace.getU(uvs, rotation, vertexIndex); + float g = BlockElementFace.getV(uvs, rotation, vertexIndex); + float i; + float h; + if (MatrixUtil.isIdentity(inverseFaceTransform)) { + h = f; + i = g; + } else { + Vector3f vector3f2 = inverseFaceTransform.transformPosition(new Vector3f(cornerToCenter(f), cornerToCenter(g), 0.0F)); + h = centerToCorner(vector3f2.x); + i = centerToCorner(vector3f2.y); + } + + fillVertex(vertexData, vertexIndex, vector3f, sprite, h, i); } - private static void fillVertex(int[] vertexData, int vertexIndex, Vector3f vector, TextureAtlasSprite sprite, BlockFaceUV blockFaceUV) { + private static float cornerToCenter(float coord) { + return coord - 0.5F; + } + + private static float centerToCorner(float coord) { + return coord + 0.5F; + } + + private static void fillVertex(int[] vertexData, int vertexIndex, Vector3f pos, TextureAtlasSprite sprite, float u, float v) { int i = vertexIndex * 8; - vertexData[i] = Float.floatToRawIntBits(vector.x()); - vertexData[i + 1] = Float.floatToRawIntBits(vector.y()); - vertexData[i + 2] = Float.floatToRawIntBits(vector.z()); + vertexData[i] = Float.floatToRawIntBits(pos.x()); + vertexData[i + 1] = Float.floatToRawIntBits(pos.y()); + vertexData[i + 2] = Float.floatToRawIntBits(pos.z()); vertexData[i + 3] = -1; - vertexData[i + 4] = Float.floatToRawIntBits(sprite.getU(blockFaceUV.getU(vertexIndex) / 16.0F)); - vertexData[i + 4 + 1] = Float.floatToRawIntBits(sprite.getV(blockFaceUV.getV(vertexIndex) / 16.0F)); + vertexData[i + 4] = Float.floatToRawIntBits(sprite.getU(u)); + vertexData[i + 4 + 1] = Float.floatToRawIntBits(sprite.getV(v)); } private static void applyElementRotation(Vector3f vec, @Nullable BlockElementRotation partRotation) { @@ -201,16 +206,16 @@ public class FaceBakery { } } - private static void rotateVertexBy(Vector3f pos, Vector3f origin, Matrix4f transform, Vector3f scale) { + private static void rotateVertexBy(Vector3f pos, Vector3fc origin, Matrix4fc transform, Vector3fc scale) { Vector4f vector4f = transform.transform(new Vector4f(pos.x() - origin.x(), pos.y() - origin.y(), pos.z() - origin.z(), 1.0F)); vector4f.mul(new Vector4f(scale, 1.0F)); pos.set(vector4f.x() + origin.x(), vector4f.y() + origin.y(), vector4f.z() + origin.z()); } private static Direction calculateFacing(int[] faceData) { - Vector3f vector3f = new Vector3f(Float.intBitsToFloat(faceData[0]), Float.intBitsToFloat(faceData[1]), Float.intBitsToFloat(faceData[2])); - Vector3f vector3f2 = new Vector3f(Float.intBitsToFloat(faceData[8]), Float.intBitsToFloat(faceData[9]), Float.intBitsToFloat(faceData[10])); - Vector3f vector3f3 = new Vector3f(Float.intBitsToFloat(faceData[16]), Float.intBitsToFloat(faceData[17]), Float.intBitsToFloat(faceData[18])); + Vector3f vector3f = vectorFromData(faceData, 0); + Vector3f vector3f2 = vectorFromData(faceData, 8); + Vector3f vector3f3 = vectorFromData(faceData, 16); Vector3f vector3f4 = new Vector3f(vector3f).sub(vector3f2); Vector3f vector3f5 = new Vector3f(vector3f3).sub(vector3f2); Vector3f vector3f6 = new Vector3f(vector3f5).cross(vector3f4).normalize(); @@ -221,9 +226,7 @@ public class FaceBakery { float f = 0.0F; for (Direction direction2 : Direction.values()) { - Vec3i vec3i = direction2.getUnitVec3i(); - Vector3f vector3f7 = new Vector3f(vec3i.getX(), vec3i.getY(), vec3i.getZ()); - float g = vector3f6.dot(vector3f7); + float g = vector3f6.dot(direction2.getUnitVec3f()); if (g >= 0.0F && g > f) { f = g; direction = direction2; @@ -234,6 +237,22 @@ public class FaceBakery { } } + private static float xFromData(int[] faceData, int index) { + return Float.intBitsToFloat(faceData[index]); + } + + private static float yFromData(int[] faceData, int index) { + return Float.intBitsToFloat(faceData[index + 1]); + } + + private static float zFromData(int[] faceData, int index) { + return Float.intBitsToFloat(faceData[index + 2]); + } + + private static Vector3f vectorFromData(int[] faceData, int index) { + return new Vector3f(xFromData(faceData, index), yFromData(faceData, index), zFromData(faceData, index)); + } + private static void recalculateWinding(int[] vertices, Direction direction) { int[] is = new int[vertices.length]; System.arraycopy(vertices, 0, is, 0, vertices.length); @@ -247,9 +266,9 @@ public class FaceBakery { for (int i = 0; i < 4; i++) { int j = 8 * i; - float f = Float.intBitsToFloat(is[j]); - float g = Float.intBitsToFloat(is[j + 1]); - float h = Float.intBitsToFloat(is[j + 2]); + float f = xFromData(is, j); + float g = yFromData(is, j); + float h = zFromData(is, j); if (f < fs[Constants.MIN_X]) { fs[Constants.MIN_X] = f; } @@ -289,9 +308,9 @@ public class FaceBakery { for (int n = 0; n < 4; n++) { int o = 8 * n; - float p = Float.intBitsToFloat(is[o]); - float q = Float.intBitsToFloat(is[o + 1]); - float r = Float.intBitsToFloat(is[o + 2]); + float p = xFromData(is, o); + float q = yFromData(is, o); + float r = zFromData(is, o); if (Mth.equal(hx, p) && Mth.equal(l, q) && Mth.equal(m, r)) { vertices[k + 4] = is[o + 4]; vertices[k + 4 + 1] = is[o + 4 + 1]; @@ -299,4 +318,10 @@ public class FaceBakery { } } } + + public static void extractPositions(int[] faceData, Consumer output) { + for (int i = 0; i < 4; i++) { + output.accept(vectorFromData(faceData, 8 * i)); + } + } } diff --git a/net/minecraft/client/renderer/block/model/ItemModelGenerator.java b/net/minecraft/client/renderer/block/model/ItemModelGenerator.java index c64884b5..e68965c8 100644 --- a/net/minecraft/client/renderer/block/model/ItemModelGenerator.java +++ b/net/minecraft/client/renderer/block/model/ItemModelGenerator.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.block.model; +import com.mojang.math.Quadrant; import java.util.ArrayList; import java.util.List; import java.util.Map; @@ -7,13 +8,13 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.block.model.TextureSlots.Data.Builder; import net.minecraft.client.renderer.texture.SpriteContents; -import net.minecraft.client.resources.model.BakedModel; import net.minecraft.client.resources.model.Material; import net.minecraft.client.resources.model.ModelBaker; +import net.minecraft.client.resources.model.ModelDebugName; import net.minecraft.client.resources.model.ModelState; -import net.minecraft.client.resources.model.ResolvableModel; -import net.minecraft.client.resources.model.SimpleBakedModel; +import net.minecraft.client.resources.model.QuadCollection; import net.minecraft.client.resources.model.SpriteGetter; +import net.minecraft.client.resources.model.UnbakedGeometry; import net.minecraft.client.resources.model.UnbakedModel; import net.minecraft.core.Direction; import net.minecraft.resources.ResourceLocation; @@ -27,33 +28,30 @@ public class ItemModelGenerator implements UnbakedModel { private static final float MIN_Z = 7.5F; private static final float MAX_Z = 8.5F; private static final TextureSlots.Data TEXTURE_SLOTS = new Builder().addReference("particle", "layer0").build(); + private static final BlockElementFace.UVs SOUTH_FACE_UVS = new BlockElementFace.UVs(0.0F, 0.0F, 16.0F, 16.0F); + private static final BlockElementFace.UVs NORTH_FACE_UVS = new BlockElementFace.UVs(16.0F, 0.0F, 0.0F, 16.0F); @Override - public TextureSlots.Data getTextureSlots() { + public TextureSlots.Data textureSlots() { return TEXTURE_SLOTS; } @Override - public void resolveDependencies(ResolvableModel.Resolver resolver) { + public UnbakedGeometry geometry() { + return ItemModelGenerator::bake; } @Nullable @Override - public UnbakedModel.GuiLight getGuiLight() { + public UnbakedModel.GuiLight guiLight() { return UnbakedModel.GuiLight.FRONT; } - @Override - public BakedModel bake( - TextureSlots textureSlots, ModelBaker baker, ModelState modelState, boolean hasAmbientOcclusion, boolean useBlockLight, ItemTransforms transforms - ) { - return this.bake(textureSlots, baker.sprites(), modelState, hasAmbientOcclusion, useBlockLight, transforms); + private static QuadCollection bake(TextureSlots textureSlots, ModelBaker baker, ModelState modelState, ModelDebugName debugName) { + return bake(textureSlots, baker.sprites(), modelState, debugName); } - private BakedModel bake( - TextureSlots textureSlots, SpriteGetter spriteGetter, ModelState modelState, boolean hasAmbientOcclusion, boolean useBlockLight, ItemTransforms transforms - ) { - Builder builder = new Builder(); + private static QuadCollection bake(TextureSlots textureSlots, SpriteGetter sprites, ModelState modelState, ModelDebugName debugName) { List list = new ArrayList(); for (int i = 0; i < LAYERS.size(); i++) { @@ -63,33 +61,32 @@ public class ItemModelGenerator implements UnbakedModel { break; } - builder.addTexture(string, material); - SpriteContents spriteContents = spriteGetter.get(material).contents(); - list.addAll(this.processFrames(i, string, spriteContents)); + SpriteContents spriteContents = sprites.get(material, debugName).contents(); + list.addAll(processFrames(i, string, spriteContents)); } - return SimpleBakedModel.bakeElements(list, textureSlots, spriteGetter, modelState, hasAmbientOcclusion, useBlockLight, false, transforms); + return SimpleUnbakedGeometry.bake(list, textureSlots, sprites, modelState, debugName); } - private List processFrames(int tintIndex, String texture, SpriteContents sprite) { + private static List processFrames(int tintIndex, String texture, SpriteContents sprite) { Map map = Map.of( Direction.SOUTH, - new BlockElementFace(null, tintIndex, texture, new BlockFaceUV(new float[]{0.0F, 0.0F, 16.0F, 16.0F}, 0)), + new BlockElementFace(null, tintIndex, texture, SOUTH_FACE_UVS, Quadrant.R0), Direction.NORTH, - new BlockElementFace(null, tintIndex, texture, new BlockFaceUV(new float[]{16.0F, 0.0F, 0.0F, 16.0F}, 0)) + new BlockElementFace(null, tintIndex, texture, NORTH_FACE_UVS, Quadrant.R0) ); List list = new ArrayList(); list.add(new BlockElement(new Vector3f(0.0F, 0.0F, 7.5F), new Vector3f(16.0F, 16.0F, 8.5F), map)); - list.addAll(this.createSideElements(sprite, texture, tintIndex)); + list.addAll(createSideElements(sprite, texture, tintIndex)); return list; } - private List createSideElements(SpriteContents sprite, String texture, int tintIndex) { + private static List createSideElements(SpriteContents sprite, String texture, int tintIndex) { float f = sprite.width(); float g = sprite.height(); List list = new ArrayList(); - for (ItemModelGenerator.Span span : this.getSpans(sprite)) { + for (ItemModelGenerator.Span span : getSpans(sprite)) { float h = 0.0F; float i = 0.0F; float j = 0.0F; @@ -153,7 +150,7 @@ public class ItemModelGenerator implements UnbakedModel { n *= q; o *= q; Map map = Map.of( - spanFacing.getDirection(), new BlockElementFace(null, tintIndex, texture, new BlockFaceUV(new float[]{l, n, m, o}, 0)) + spanFacing.getDirection(), new BlockElementFace(null, tintIndex, texture, new BlockElementFace.UVs(l, n, m, o), Quadrant.R0) ); switch (spanFacing) { case UP: @@ -173,25 +170,25 @@ public class ItemModelGenerator implements UnbakedModel { return list; } - private List getSpans(SpriteContents sprite) { + private static List getSpans(SpriteContents sprite) { int i = sprite.width(); int j = sprite.height(); List list = new ArrayList(); sprite.getUniqueFrames().forEach(k -> { for (int l = 0; l < j; l++) { for (int m = 0; m < i; m++) { - boolean bl = !this.isTransparent(sprite, k, m, l, i, j); - this.checkTransition(ItemModelGenerator.SpanFacing.UP, list, sprite, k, m, l, i, j, bl); - this.checkTransition(ItemModelGenerator.SpanFacing.DOWN, list, sprite, k, m, l, i, j, bl); - this.checkTransition(ItemModelGenerator.SpanFacing.LEFT, list, sprite, k, m, l, i, j, bl); - this.checkTransition(ItemModelGenerator.SpanFacing.RIGHT, list, sprite, k, m, l, i, j, bl); + boolean bl = !isTransparent(sprite, k, m, l, i, j); + checkTransition(ItemModelGenerator.SpanFacing.UP, list, sprite, k, m, l, i, j, bl); + checkTransition(ItemModelGenerator.SpanFacing.DOWN, list, sprite, k, m, l, i, j, bl); + checkTransition(ItemModelGenerator.SpanFacing.LEFT, list, sprite, k, m, l, i, j, bl); + checkTransition(ItemModelGenerator.SpanFacing.RIGHT, list, sprite, k, m, l, i, j, bl); } } }); return list; } - private void checkTransition( + private static void checkTransition( ItemModelGenerator.SpanFacing spanFacing, List listSpans, SpriteContents contents, @@ -202,14 +199,14 @@ public class ItemModelGenerator implements UnbakedModel { int spriteHeight, boolean transparent ) { - boolean bl = this.isTransparent(contents, frameIndex, pixelX + spanFacing.getXOffset(), pixelY + spanFacing.getYOffset(), spriteWidth, spriteHeight) + boolean bl = isTransparent(contents, frameIndex, pixelX + spanFacing.getXOffset(), pixelY + spanFacing.getYOffset(), spriteWidth, spriteHeight) && transparent; if (bl) { - this.createOrExpandSpan(listSpans, spanFacing, pixelX, pixelY); + createOrExpandSpan(listSpans, spanFacing, pixelX, pixelY); } } - private void createOrExpandSpan(List listSpans, ItemModelGenerator.SpanFacing spanFacing, int pixelX, int pixelY) { + private static void createOrExpandSpan(List listSpans, ItemModelGenerator.SpanFacing spanFacing, int pixelX, int pixelY) { ItemModelGenerator.Span span = null; for (ItemModelGenerator.Span span2 : listSpans) { @@ -231,7 +228,7 @@ public class ItemModelGenerator implements UnbakedModel { } } - private boolean isTransparent(SpriteContents sprite, int frameIndex, int pixelX, int pixelY, int spriteWidth, int spriteHeight) { + private static boolean isTransparent(SpriteContents sprite, int frameIndex, int pixelX, int pixelY, int spriteWidth, int spriteHeight) { return pixelX >= 0 && pixelY >= 0 && pixelX < spriteWidth && pixelY < spriteHeight ? sprite.isTransparent(frameIndex, pixelX, pixelY) : true; } diff --git a/net/minecraft/client/renderer/block/model/ItemTransform.java b/net/minecraft/client/renderer/block/model/ItemTransform.java index 00206c72..b05025b0 100644 --- a/net/minecraft/client/renderer/block/model/ItemTransform.java +++ b/net/minecraft/client/renderer/block/model/ItemTransform.java @@ -14,54 +14,36 @@ import net.minecraft.util.GsonHelper; import net.minecraft.util.Mth; import org.joml.Quaternionf; import org.joml.Vector3f; +import org.joml.Vector3fc; @Environment(EnvType.CLIENT) -public class ItemTransform { +public record ItemTransform(Vector3fc rotation, Vector3fc translation, Vector3fc scale) { public static final ItemTransform NO_TRANSFORM = new ItemTransform(new Vector3f(), new Vector3f(), new Vector3f(1.0F, 1.0F, 1.0F)); - public final Vector3f rotation; - public final Vector3f translation; - public final Vector3f scale; - public ItemTransform(Vector3f rotation, Vector3f translation, Vector3f scale) { - this.rotation = new Vector3f(rotation); - this.translation = new Vector3f(translation); - this.scale = new Vector3f(scale); - } - - public void apply(boolean leftHand, PoseStack poseStack) { - if (this != NO_TRANSFORM) { - float f = this.rotation.x(); - float g = this.rotation.y(); - float h = this.rotation.z(); + public void apply(boolean leftHand, PoseStack.Pose pose) { + if (this == NO_TRANSFORM) { + pose.translate(-0.5F, -0.5F, -0.5F); + } else { + float f; + float g; + float h; if (leftHand) { - g = -g; - h = -h; + f = -this.translation.x(); + g = -this.rotation.y(); + h = -this.rotation.z(); + } else { + f = this.translation.x(); + g = this.rotation.y(); + h = this.rotation.z(); } - int i = leftHand ? -1 : 1; - poseStack.translate(i * this.translation.x(), this.translation.y(), this.translation.z()); - poseStack.mulPose(new Quaternionf().rotationXYZ(f * (float) (Math.PI / 180.0), g * (float) (Math.PI / 180.0), h * (float) (Math.PI / 180.0))); - poseStack.scale(this.scale.x(), this.scale.y(), this.scale.z()); + pose.translate(f, this.translation.y(), this.translation.z()); + pose.rotate(new Quaternionf().rotationXYZ(this.rotation.x() * (float) (Math.PI / 180.0), g * (float) (Math.PI / 180.0), h * (float) (Math.PI / 180.0))); + pose.scale(this.scale.x(), this.scale.y(), this.scale.z()); + pose.translate(-0.5F, -0.5F, -0.5F); } } - public boolean equals(Object object) { - if (this == object) { - return true; - } else if (this.getClass() != object.getClass()) { - return false; - } else { - ItemTransform itemTransform = (ItemTransform)object; - return this.rotation.equals(itemTransform.rotation) && this.scale.equals(itemTransform.scale) && this.translation.equals(itemTransform.translation); - } - } - - public int hashCode() { - int i = this.rotation.hashCode(); - i = 31 * i + this.translation.hashCode(); - return 31 * i + this.scale.hashCode(); - } - @Environment(EnvType.CLIENT) protected static class Deserializer implements JsonDeserializer { private static final Vector3f DEFAULT_ROTATION = new Vector3f(0.0F, 0.0F, 0.0F); diff --git a/net/minecraft/client/renderer/block/model/MultiVariant.java b/net/minecraft/client/renderer/block/model/MultiVariant.java deleted file mode 100644 index 6c7ea33d..00000000 --- a/net/minecraft/client/renderer/block/model/MultiVariant.java +++ /dev/null @@ -1,77 +0,0 @@ -package net.minecraft.client.renderer.block.model; - -import com.google.common.collect.Lists; -import com.google.gson.JsonArray; -import com.google.gson.JsonDeserializationContext; -import com.google.gson.JsonDeserializer; -import com.google.gson.JsonElement; -import com.google.gson.JsonParseException; -import java.lang.reflect.Type; -import java.util.List; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.resources.model.BakedModel; -import net.minecraft.client.resources.model.ModelBaker; -import net.minecraft.client.resources.model.ResolvableModel; -import net.minecraft.client.resources.model.WeightedBakedModel; -import net.minecraft.util.random.SimpleWeightedRandomList; -import net.minecraft.world.level.block.state.BlockState; - -@Environment(EnvType.CLIENT) -public record MultiVariant(List variants) implements UnbakedBlockStateModel { - public MultiVariant(List variants) { - if (variants.isEmpty()) { - throw new IllegalArgumentException("Variant list must contain at least one element"); - } else { - this.variants = variants; - } - } - - @Override - public Object visualEqualityGroup(BlockState state) { - return this; - } - - @Override - public void resolveDependencies(ResolvableModel.Resolver resolver) { - this.variants.forEach(variant -> resolver.resolve(variant.modelLocation())); - } - - @Override - public BakedModel bake(ModelBaker baker) { - if (this.variants.size() == 1) { - Variant variant = (Variant)this.variants.getFirst(); - return baker.bake(variant.modelLocation(), variant); - } else { - SimpleWeightedRandomList.Builder builder = SimpleWeightedRandomList.builder(); - - for (Variant variant2 : this.variants) { - BakedModel bakedModel = baker.bake(variant2.modelLocation(), variant2); - builder.add(bakedModel, variant2.weight()); - } - - return new WeightedBakedModel(builder.build()); - } - } - - @Environment(EnvType.CLIENT) - public static class Deserializer implements JsonDeserializer { - public MultiVariant deserialize(JsonElement json, Type type, JsonDeserializationContext context) throws JsonParseException { - List list = Lists.newArrayList(); - if (json.isJsonArray()) { - JsonArray jsonArray = json.getAsJsonArray(); - if (jsonArray.isEmpty()) { - throw new JsonParseException("Empty variant array"); - } - - for (JsonElement jsonElement : jsonArray) { - list.add((Variant)context.deserialize(jsonElement, Variant.class)); - } - } else { - list.add((Variant)context.deserialize(json, Variant.class)); - } - - return new MultiVariant(list); - } - } -} diff --git a/net/minecraft/client/renderer/block/model/SimpleModelWrapper.java b/net/minecraft/client/renderer/block/model/SimpleModelWrapper.java new file mode 100644 index 00000000..707cd7c7 --- /dev/null +++ b/net/minecraft/client/renderer/block/model/SimpleModelWrapper.java @@ -0,0 +1,30 @@ +package net.minecraft.client.renderer.block.model; + +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.client.resources.model.ModelBaker; +import net.minecraft.client.resources.model.ModelState; +import net.minecraft.client.resources.model.QuadCollection; +import net.minecraft.client.resources.model.ResolvedModel; +import net.minecraft.core.Direction; +import net.minecraft.resources.ResourceLocation; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public record SimpleModelWrapper(QuadCollection quads, boolean useAmbientOcclusion, TextureAtlasSprite particleIcon) implements BlockModelPart { + public static SimpleModelWrapper bake(ModelBaker baker, ResourceLocation modelLocation, ModelState modelState) { + ResolvedModel resolvedModel = baker.getModel(modelLocation); + TextureSlots textureSlots = resolvedModel.getTopTextureSlots(); + boolean bl = resolvedModel.getTopAmbientOcclusion(); + TextureAtlasSprite textureAtlasSprite = resolvedModel.resolveParticleSprite(textureSlots, baker); + QuadCollection quadCollection = resolvedModel.bakeTopGeometry(textureSlots, baker, modelState); + return new SimpleModelWrapper(quadCollection, bl, textureAtlasSprite); + } + + @Override + public List getQuads(@Nullable Direction direction) { + return this.quads.getQuads(direction); + } +} diff --git a/net/minecraft/client/renderer/block/model/SimpleUnbakedGeometry.java b/net/minecraft/client/renderer/block/model/SimpleUnbakedGeometry.java new file mode 100644 index 00000000..56fdd7eb --- /dev/null +++ b/net/minecraft/client/renderer/block/model/SimpleUnbakedGeometry.java @@ -0,0 +1,50 @@ +package net.minecraft.client.renderer.block.model; + +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.client.resources.model.ModelBaker; +import net.minecraft.client.resources.model.ModelDebugName; +import net.minecraft.client.resources.model.ModelState; +import net.minecraft.client.resources.model.QuadCollection; +import net.minecraft.client.resources.model.SpriteGetter; +import net.minecraft.client.resources.model.UnbakedGeometry; +import net.minecraft.core.Direction; + +@Environment(EnvType.CLIENT) +public record SimpleUnbakedGeometry(List elements) implements UnbakedGeometry { + @Override + public QuadCollection bake(TextureSlots textureSlots, ModelBaker modelBaker, ModelState modelState, ModelDebugName modelDebugName) { + return bake(this.elements, textureSlots, modelBaker.sprites(), modelState, modelDebugName); + } + + public static QuadCollection bake( + List elements, TextureSlots textureSlots, SpriteGetter sprites, ModelState modelState, ModelDebugName debugName + ) { + QuadCollection.Builder builder = new QuadCollection.Builder(); + + for (BlockElement blockElement : elements) { + blockElement.faces() + .forEach( + (direction, blockElementFace) -> { + TextureAtlasSprite textureAtlasSprite = sprites.resolveSlot(textureSlots, blockElementFace.texture(), debugName); + if (blockElementFace.cullForDirection() == null) { + builder.addUnculledFace(bakeFace(blockElement, blockElementFace, textureAtlasSprite, direction, modelState)); + } else { + builder.addCulledFace( + Direction.rotate(modelState.transformation().getMatrix(), blockElementFace.cullForDirection()), + bakeFace(blockElement, blockElementFace, textureAtlasSprite, direction, modelState) + ); + } + } + ); + } + + return builder.build(); + } + + private static BakedQuad bakeFace(BlockElement element, BlockElementFace face, TextureAtlasSprite sprite, Direction direction, ModelState modelState) { + return FaceBakery.bakeQuad(element.from(), element.to(), face, sprite, direction, modelState, element.rotation(), element.shade(), element.lightEmission()); + } +} diff --git a/net/minecraft/client/renderer/block/model/SingleVariant.java b/net/minecraft/client/renderer/block/model/SingleVariant.java new file mode 100644 index 00000000..53994a22 --- /dev/null +++ b/net/minecraft/client/renderer/block/model/SingleVariant.java @@ -0,0 +1,44 @@ +package net.minecraft.client.renderer.block.model; + +import com.mojang.serialization.Codec; +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.client.resources.model.ModelBaker; +import net.minecraft.client.resources.model.ResolvableModel; +import net.minecraft.util.RandomSource; + +@Environment(EnvType.CLIENT) +public class SingleVariant implements BlockStateModel { + private final BlockModelPart model; + + public SingleVariant(BlockModelPart model) { + this.model = model; + } + + @Override + public void collectParts(RandomSource random, List output) { + output.add(this.model); + } + + @Override + public TextureAtlasSprite particleIcon() { + return this.model.particleIcon(); + } + + @Environment(EnvType.CLIENT) + public record Unbaked(Variant variant) implements BlockStateModel.Unbaked { + public static final Codec CODEC = Variant.CODEC.xmap(SingleVariant.Unbaked::new, SingleVariant.Unbaked::variant); + + @Override + public BlockStateModel bake(ModelBaker baker) { + return new SingleVariant(this.variant.bake(baker)); + } + + @Override + public void resolveDependencies(ResolvableModel.Resolver resolver) { + this.variant.resolveDependencies(resolver); + } + } +} diff --git a/net/minecraft/client/renderer/block/model/TextureSlots.java b/net/minecraft/client/renderer/block/model/TextureSlots.java index cfde4a96..b641c3db 100644 --- a/net/minecraft/client/renderer/block/model/TextureSlots.java +++ b/net/minecraft/client/renderer/block/model/TextureSlots.java @@ -142,7 +142,7 @@ public class TextureSlots { if (!object2ObjectMap2.isEmpty()) { LOGGER.warn( "Unresolved texture references in {}:\n{}", - name.get(), + name.debugName(), object2ObjectMap2.entrySet() .stream() .map(entryx -> "\t#" + (String)entryx.getKey() + "-> #" + ((TextureSlots.Reference)entryx.getValue()).target + "\n") diff --git a/net/minecraft/client/renderer/block/model/UnbakedBlockStateModel.java b/net/minecraft/client/renderer/block/model/UnbakedBlockStateModel.java deleted file mode 100644 index 0d766abd..00000000 --- a/net/minecraft/client/renderer/block/model/UnbakedBlockStateModel.java +++ /dev/null @@ -1,15 +0,0 @@ -package net.minecraft.client.renderer.block.model; - -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.resources.model.BakedModel; -import net.minecraft.client.resources.model.ModelBaker; -import net.minecraft.client.resources.model.ResolvableModel; -import net.minecraft.world.level.block.state.BlockState; - -@Environment(EnvType.CLIENT) -public interface UnbakedBlockStateModel extends ResolvableModel { - BakedModel bake(ModelBaker baker); - - Object visualEqualityGroup(BlockState state); -} diff --git a/net/minecraft/client/renderer/block/model/Variant.java b/net/minecraft/client/renderer/block/model/Variant.java index 03fa660f..fde0eab3 100644 --- a/net/minecraft/client/renderer/block/model/Variant.java +++ b/net/minecraft/client/renderer/block/model/Variant.java @@ -1,78 +1,92 @@ package net.minecraft.client.renderer.block.model; -import com.google.common.annotations.VisibleForTesting; -import com.google.gson.JsonDeserializationContext; -import com.google.gson.JsonDeserializer; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.JsonParseException; -import com.mojang.math.Transformation; -import java.lang.reflect.Type; +import com.mojang.math.Quadrant; +import com.mojang.serialization.Codec; +import com.mojang.serialization.MapCodec; +import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.resources.model.BlockModelRotation; +import net.minecraft.client.resources.model.ModelBaker; import net.minecraft.client.resources.model.ModelState; +import net.minecraft.client.resources.model.ResolvableModel; import net.minecraft.resources.ResourceLocation; -import net.minecraft.util.GsonHelper; @Environment(EnvType.CLIENT) -public record Variant(ResourceLocation modelLocation, Transformation rotation, boolean uvLock, int weight) implements ModelState { - @Override - public Transformation getRotation() { - return this.rotation; +public record Variant(ResourceLocation modelLocation, Variant.SimpleModelState modelState) implements BlockModelPart.Unbaked { + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( + instance -> instance.group( + ResourceLocation.CODEC.fieldOf("model").forGetter(Variant::modelLocation), Variant.SimpleModelState.MAP_CODEC.forGetter(Variant::modelState) + ) + .apply(instance, Variant::new) + ); + public static final Codec CODEC = MAP_CODEC.codec(); + + public Variant(ResourceLocation modelLocation) { + this(modelLocation, Variant.SimpleModelState.DEFAULT); + } + + public Variant withXRot(Quadrant xRot) { + return this.withState(this.modelState.withX(xRot)); + } + + public Variant withYRot(Quadrant yRot) { + return this.withState(this.modelState.withY(yRot)); + } + + public Variant withUvLock(boolean uvLock) { + return this.withState(this.modelState.withUvLock(uvLock)); + } + + public Variant withModel(ResourceLocation modelLocation) { + return new Variant(modelLocation, this.modelState); + } + + public Variant withState(Variant.SimpleModelState modelState) { + return new Variant(this.modelLocation, modelState); + } + + public Variant with(VariantMutator mutator) { + return (Variant)mutator.apply(this); } @Override - public boolean isUvLocked() { - return this.uvLock; + public BlockModelPart bake(ModelBaker modelBaker) { + return SimpleModelWrapper.bake(modelBaker, this.modelLocation, this.modelState.asModelState()); + } + + @Override + public void resolveDependencies(ResolvableModel.Resolver resolver) { + resolver.markDependency(this.modelLocation); } @Environment(EnvType.CLIENT) - public static class Deserializer implements JsonDeserializer { - @VisibleForTesting - static final boolean DEFAULT_UVLOCK = false; - @VisibleForTesting - static final int DEFAULT_WEIGHT = 1; - @VisibleForTesting - static final int DEFAULT_X_ROTATION = 0; - @VisibleForTesting - static final int DEFAULT_Y_ROTATION = 0; + public record SimpleModelState(Quadrant x, Quadrant y, boolean uvLock) { + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( + instance -> instance.group( + Quadrant.CODEC.optionalFieldOf("x", Quadrant.R0).forGetter(Variant.SimpleModelState::x), + Quadrant.CODEC.optionalFieldOf("y", Quadrant.R0).forGetter(Variant.SimpleModelState::y), + Codec.BOOL.optionalFieldOf("uvlock", false).forGetter(Variant.SimpleModelState::uvLock) + ) + .apply(instance, Variant.SimpleModelState::new) + ); + public static final Variant.SimpleModelState DEFAULT = new Variant.SimpleModelState(Quadrant.R0, Quadrant.R0, false); - public Variant deserialize(JsonElement json, Type type, JsonDeserializationContext context) throws JsonParseException { - JsonObject jsonObject = json.getAsJsonObject(); - ResourceLocation resourceLocation = this.getModel(jsonObject); - BlockModelRotation blockModelRotation = this.getBlockRotation(jsonObject); - boolean bl = this.getUvLock(jsonObject); - int i = this.getWeight(jsonObject); - return new Variant(resourceLocation, blockModelRotation.getRotation(), bl, i); + public ModelState asModelState() { + BlockModelRotation blockModelRotation = BlockModelRotation.by(this.x, this.y); + return (ModelState)(this.uvLock ? blockModelRotation.withUvLock() : blockModelRotation); } - private boolean getUvLock(JsonObject json) { - return GsonHelper.getAsBoolean(json, "uvlock", false); + public Variant.SimpleModelState withX(Quadrant xRot) { + return new Variant.SimpleModelState(xRot, this.y, this.uvLock); } - protected BlockModelRotation getBlockRotation(JsonObject json) { - int i = GsonHelper.getAsInt(json, "x", 0); - int j = GsonHelper.getAsInt(json, "y", 0); - BlockModelRotation blockModelRotation = BlockModelRotation.by(i, j); - if (blockModelRotation == null) { - throw new JsonParseException("Invalid BlockModelRotation x: " + i + ", y: " + j); - } else { - return blockModelRotation; - } + public Variant.SimpleModelState withY(Quadrant yRot) { + return new Variant.SimpleModelState(this.x, yRot, this.uvLock); } - protected ResourceLocation getModel(JsonObject json) { - return ResourceLocation.parse(GsonHelper.getAsString(json, "model")); - } - - protected int getWeight(JsonObject json) { - int i = GsonHelper.getAsInt(json, "weight", 1); - if (i < 1) { - throw new JsonParseException("Invalid weight " + i + " found, expected integer >= 1"); - } else { - return i; - } + public Variant.SimpleModelState withUvLock(boolean uvLock) { + return new Variant.SimpleModelState(this.x, this.y, uvLock); } } } diff --git a/net/minecraft/client/renderer/block/model/VariantMutator.java b/net/minecraft/client/renderer/block/model/VariantMutator.java new file mode 100644 index 00000000..21d998bb --- /dev/null +++ b/net/minecraft/client/renderer/block/model/VariantMutator.java @@ -0,0 +1,30 @@ +package net.minecraft.client.renderer.block.model; + +import com.mojang.math.Quadrant; +import java.util.function.UnaryOperator; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.resources.ResourceLocation; + +@FunctionalInterface +@Environment(EnvType.CLIENT) +public interface VariantMutator extends UnaryOperator { + VariantMutator.VariantProperty X_ROT = Variant::withXRot; + VariantMutator.VariantProperty Y_ROT = Variant::withYRot; + VariantMutator.VariantProperty MODEL = Variant::withModel; + VariantMutator.VariantProperty UV_LOCK = Variant::withUvLock; + + default VariantMutator then(VariantMutator variantMutator) { + return variant -> (Variant)variantMutator.apply((Variant)this.apply(variant)); + } + + @FunctionalInterface + @Environment(EnvType.CLIENT) + public interface VariantProperty { + Variant apply(Variant variant, T object); + + default VariantMutator withValue(T object) { + return variant -> this.apply(variant, object); + } + } +} diff --git a/net/minecraft/client/renderer/block/model/multipart/AndCondition.java b/net/minecraft/client/renderer/block/model/multipart/AndCondition.java deleted file mode 100644 index ed7e2e84..00000000 --- a/net/minecraft/client/renderer/block/model/multipart/AndCondition.java +++ /dev/null @@ -1,25 +0,0 @@ -package net.minecraft.client.renderer.block.model.multipart; - -import com.google.common.collect.Streams; -import java.util.function.Predicate; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.Util; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.StateDefinition; - -@Environment(EnvType.CLIENT) -public class AndCondition implements Condition { - public static final String TOKEN = "AND"; - private final Iterable conditions; - - public AndCondition(Iterable conditions) { - this.conditions = conditions; - } - - @Override - public Predicate getPredicate(StateDefinition stateDefinition) { - return Util.allOf(Streams.stream(this.conditions).map(condition -> condition.getPredicate(stateDefinition)).toList()); - } -} diff --git a/net/minecraft/client/renderer/block/model/multipart/CombinedCondition.java b/net/minecraft/client/renderer/block/model/multipart/CombinedCondition.java new file mode 100644 index 00000000..0e236e32 --- /dev/null +++ b/net/minecraft/client/renderer/block/model/multipart/CombinedCondition.java @@ -0,0 +1,39 @@ +package net.minecraft.client.renderer.block.model.multipart; + +import com.google.common.collect.Lists; +import com.mojang.serialization.Codec; +import java.util.List; +import java.util.function.Predicate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.util.StringRepresentable; +import net.minecraft.world.level.block.state.StateDefinition; +import net.minecraft.world.level.block.state.StateHolder; + +@Environment(EnvType.CLIENT) +public record CombinedCondition(CombinedCondition.Operation operation, List terms) implements Condition { + @Override + public > Predicate instantiate(StateDefinition stateDefinition) { + return this.operation.apply(Lists.transform(this.terms, condition -> condition.instantiate(stateDefinition))); + } + + @Environment(EnvType.CLIENT) + public static enum Operation implements StringRepresentable { + AND("AND", 0, "AND"), + OR("OR", 1, "OR"); + + public static final Codec CODEC = StringRepresentable.fromEnum(CombinedCondition.Operation::values); + private final String name; + + Operation(final String name) { + this.name = name; + } + + @Override + public String getSerializedName() { + return this.name; + } + + public abstract Predicate apply(List> conditions); + } +} diff --git a/net/minecraft/client/renderer/block/model/multipart/Condition.java b/net/minecraft/client/renderer/block/model/multipart/Condition.java index d6b6e312..89336c31 100644 --- a/net/minecraft/client/renderer/block/model/multipart/Condition.java +++ b/net/minecraft/client/renderer/block/model/multipart/Condition.java @@ -1,17 +1,46 @@ package net.minecraft.client.renderer.block.model.multipart; +import com.mojang.datafixers.util.Either; +import com.mojang.serialization.Codec; +import com.mojang.serialization.DataResult; +import java.util.List; +import java.util.Map; +import java.util.Map.Entry; import java.util.function.Predicate; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.util.StringRepresentable; import net.minecraft.world.level.block.state.StateDefinition; +import net.minecraft.world.level.block.state.StateHolder; @FunctionalInterface @Environment(EnvType.CLIENT) public interface Condition { - Condition TRUE = stateDefinition -> blockState -> true; - Condition FALSE = stateDefinition -> blockState -> false; + Codec CODEC = Codec.recursive( + "condition", + codec -> { + Codec codec2 = Codec.simpleMap( + CombinedCondition.Operation.CODEC, codec.listOf(), StringRepresentable.keys(CombinedCondition.Operation.values()) + ) + .codec() + .comapFlatMap(map -> { + if (map.size() != 1) { + return DataResult.error(() -> "Invalid map size for combiner condition, expected exactly one element"); + } else { + Entry> entry = (Entry>)map.entrySet().iterator().next(); + return DataResult.success(new CombinedCondition((CombinedCondition.Operation)entry.getKey(), (List)entry.getValue())); + } + }, combinedCondition -> Map.of(combinedCondition.operation(), combinedCondition.terms())); + return Codec.either(codec2, KeyValueCondition.CODEC) + .flatComapMap(either -> either.map(combinedCondition -> combinedCondition, keyValueCondition -> keyValueCondition), condition -> { + return switch (condition) { + case CombinedCondition combinedCondition -> DataResult.success(Either.left(combinedCondition)); + case KeyValueCondition keyValueCondition -> DataResult.success(Either.right(keyValueCondition)); + default -> DataResult.error(() -> "Unrecognized condition"); + }; + }); + } + ); - Predicate getPredicate(StateDefinition stateDefinition); + > Predicate instantiate(StateDefinition stateDefinition); } diff --git a/net/minecraft/client/renderer/block/model/multipart/KeyValueCondition.java b/net/minecraft/client/renderer/block/model/multipart/KeyValueCondition.java index 27676bec..cbb1cce1 100644 --- a/net/minecraft/client/renderer/block/model/multipart/KeyValueCondition.java +++ b/net/minecraft/client/renderer/block/model/multipart/KeyValueCondition.java @@ -1,70 +1,162 @@ package net.minecraft.client.renderer.block.model.multipart; -import com.google.common.base.MoreObjects; +import com.google.common.base.Joiner; import com.google.common.base.Splitter; +import com.google.common.collect.Lists; +import com.mojang.logging.LogUtils; +import com.mojang.serialization.Codec; +import com.mojang.serialization.DataResult; +import java.util.ArrayList; import java.util.List; import java.util.Locale; +import java.util.Map; import java.util.Optional; import java.util.function.Predicate; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.Util; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.util.ExtraCodecs; import net.minecraft.world.level.block.state.StateDefinition; +import net.minecraft.world.level.block.state.StateHolder; import net.minecraft.world.level.block.state.properties.Property; +import org.slf4j.Logger; @Environment(EnvType.CLIENT) -public class KeyValueCondition implements Condition { - private static final Splitter PIPE_SPLITTER = Splitter.on('|').omitEmptyStrings(); - private final String key; - private final String value; - - public KeyValueCondition(String key, String value) { - this.key = key; - this.value = value; - } +public record KeyValueCondition(Map tests) implements Condition { + static final Logger LOGGER = LogUtils.getLogger(); + public static final Codec CODEC = ExtraCodecs.nonEmptyMap(Codec.unboundedMap(Codec.STRING, KeyValueCondition.Terms.CODEC)) + .xmap(KeyValueCondition::new, KeyValueCondition::tests); @Override - public Predicate getPredicate(StateDefinition stateDefinition) { - Property property = stateDefinition.getProperty(this.key); - if (property == null) { - throw new RuntimeException(String.format(Locale.ROOT, "Unknown property '%s' on '%s'", this.key, stateDefinition.getOwner())); - } else { - String string = this.value; - boolean bl = !string.isEmpty() && string.charAt(0) == '!'; - if (bl) { - string = string.substring(1); - } + public > Predicate instantiate(StateDefinition stateDefinition) { + List> list = new ArrayList(this.tests.size()); + this.tests.forEach((string, terms) -> list.add(instantiate(stateDefinition, string, terms))); + return Util.allOf(list); + } - List list = PIPE_SPLITTER.splitToList(string); - if (list.isEmpty()) { - throw new RuntimeException(String.format(Locale.ROOT, "Empty value '%s' for property '%s' on '%s'", this.value, this.key, stateDefinition.getOwner())); + private static > Predicate instantiate(StateDefinition stateDefinition, String property, KeyValueCondition.Terms terms) { + Property property2 = stateDefinition.getProperty(property); + if (property2 == null) { + throw new IllegalArgumentException(String.format(Locale.ROOT, "Unknown property '%s' on '%s'", property, stateDefinition.getOwner())); + } else { + return terms.instantiate(stateDefinition.getOwner(), property2); + } + } + + @Environment(EnvType.CLIENT) + public record Term(String value, boolean negated) { + private static final String NEGATE = "!"; + + public Term(String value, boolean negated) { + if (value.isEmpty()) { + throw new IllegalArgumentException("Empty term"); } else { - Predicate predicate; - if (list.size() == 1) { - predicate = this.getBlockStatePredicate(stateDefinition, property, string); - } else { - predicate = Util.anyOf(list.stream().map(stringx -> this.getBlockStatePredicate(stateDefinition, property, stringx)).toList()); + this.value = value; + this.negated = negated; + } + } + + public static KeyValueCondition.Term parse(String text) { + return text.startsWith("!") ? new KeyValueCondition.Term(text.substring(1), true) : new KeyValueCondition.Term(text, false); + } + + public String toString() { + return this.negated ? "!" + this.value : this.value; + } + } + + @Environment(EnvType.CLIENT) + public record Terms(List entries) { + private static final char SEPARATOR = '|'; + private static final Joiner JOINER = Joiner.on('|'); + private static final Splitter SPLITTER = Splitter.on('|'); + private static final Codec LEGACY_REPRESENTATION_CODEC = Codec.either(Codec.INT, Codec.BOOL) + .flatComapMap(either -> either.map(String::valueOf, String::valueOf), string -> DataResult.error(() -> "This codec can't be used for encoding")); + public static final Codec CODEC = Codec.withAlternative(Codec.STRING, LEGACY_REPRESENTATION_CODEC) + .comapFlatMap(KeyValueCondition.Terms::parse, KeyValueCondition.Terms::toString); + + public Terms(List entries) { + if (entries.isEmpty()) { + throw new IllegalArgumentException("Empty value for property"); + } else { + this.entries = entries; + } + } + + public static DataResult parse(String text) { + List list = SPLITTER.splitToStream(text).map(KeyValueCondition.Term::parse).toList(); + if (list.isEmpty()) { + return DataResult.error(() -> "Empty value for property"); + } else { + for (KeyValueCondition.Term term : list) { + if (term.value.isEmpty()) { + return DataResult.error(() -> "Empty term in value '" + text + "'"); + } } - return bl ? predicate.negate() : predicate; + return DataResult.success(new KeyValueCondition.Terms(list)); } } - } - private Predicate getBlockStatePredicate(StateDefinition definition, Property property, String value) { - Optional optional = property.getValue(value); - if (optional.isEmpty()) { - throw new RuntimeException( - String.format(Locale.ROOT, "Unknown value '%s' for property '%s' on '%s' in '%s'", value, this.key, definition.getOwner(), this.value) - ); - } else { - return blockState -> blockState.getValue(property).equals(optional.get()); + public String toString() { + return JOINER.join(this.entries); + } + + public , T extends Comparable> Predicate instantiate(O owner, Property property) { + Predicate predicate = Util.anyOf(Lists.transform(this.entries, term -> this.instantiate(owner, property, term))); + List list = new ArrayList(property.getPossibleValues()); + int i = list.size(); + list.removeIf(predicate.negate()); + int j = list.size(); + if (j == 0) { + KeyValueCondition.LOGGER.warn("Condition {} for property {} on {} is always false", this, property.getName(), owner); + return stateHolder -> false; + } else { + int k = i - j; + if (k == 0) { + KeyValueCondition.LOGGER.warn("Condition {} for property {} on {} is always true", this, property.getName(), owner); + return stateHolder -> true; + } else { + boolean bl; + List list2; + if (j <= k) { + bl = false; + list2 = list; + } else { + bl = true; + List list3 = new ArrayList(property.getPossibleValues()); + list3.removeIf(predicate); + list2 = list3; + } + + if (list2.size() == 1) { + T comparable = (T)list2.getFirst(); + return stateHolder -> { + T comparable2 = stateHolder.getValue(property); + return comparable.equals(comparable2) ^ bl; + }; + } else { + return stateHolder -> { + T comparablex = stateHolder.getValue(property); + return list2.contains(comparablex) ^ bl; + }; + } + } + } + } + + private > T getValueOrThrow(Object owner, Property property, String value) { + Optional optional = property.getValue(value); + if (optional.isEmpty()) { + throw new RuntimeException(String.format(Locale.ROOT, "Unknown value '%s' for property '%s' on '%s' in '%s'", value, property, owner, this)); + } else { + return (T)optional.get(); + } + } + + private > Predicate instantiate(Object owner, Property property, KeyValueCondition.Term term) { + T comparable = this.getValueOrThrow(owner, property, term.value); + return term.negated ? comparable2 -> !comparable2.equals(comparable) : comparable2 -> comparable2.equals(comparable); } } - - public String toString() { - return MoreObjects.toStringHelper(this).add("key", this.key).add("value", this.value).toString(); - } } diff --git a/net/minecraft/client/renderer/block/model/multipart/MultiPart.java b/net/minecraft/client/renderer/block/model/multipart/MultiPart.java deleted file mode 100644 index a5d321eb..00000000 --- a/net/minecraft/client/renderer/block/model/multipart/MultiPart.java +++ /dev/null @@ -1,109 +0,0 @@ -package net.minecraft.client.renderer.block.model.multipart; - -import com.google.gson.JsonArray; -import com.google.gson.JsonDeserializationContext; -import com.google.gson.JsonDeserializer; -import com.google.gson.JsonElement; -import com.google.gson.JsonParseException; -import com.google.gson.JsonSyntaxException; -import it.unimi.dsi.fastutil.ints.IntArrayList; -import it.unimi.dsi.fastutil.ints.IntList; -import java.lang.reflect.Type; -import java.util.ArrayList; -import java.util.List; -import java.util.Set; -import java.util.function.Predicate; -import java.util.stream.Collectors; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.MultiVariant; -import net.minecraft.client.renderer.block.model.UnbakedBlockStateModel; -import net.minecraft.client.resources.model.BakedModel; -import net.minecraft.client.resources.model.ModelBaker; -import net.minecraft.client.resources.model.MultiPartBakedModel; -import net.minecraft.client.resources.model.ResolvableModel; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.StateDefinition; - -@Environment(EnvType.CLIENT) -public class MultiPart implements UnbakedBlockStateModel { - private final List selectors; - - MultiPart(List selectors) { - this.selectors = selectors; - } - - @Override - public Object visualEqualityGroup(BlockState state) { - IntList intList = new IntArrayList(); - - for (int i = 0; i < this.selectors.size(); i++) { - if (((MultiPart.InstantiatedSelector)this.selectors.get(i)).predicate.test(state)) { - intList.add(i); - } - } - - @Environment(EnvType.CLIENT) - record Key(MultiPart model, IntList selectors) { - } - - return new Key(this, intList); - } - - @Override - public void resolveDependencies(ResolvableModel.Resolver resolver) { - this.selectors.forEach(instantiatedSelector -> instantiatedSelector.variant.resolveDependencies(resolver)); - } - - @Override - public BakedModel bake(ModelBaker baker) { - List list = new ArrayList(this.selectors.size()); - - for (MultiPart.InstantiatedSelector instantiatedSelector : this.selectors) { - BakedModel bakedModel = instantiatedSelector.variant.bake(baker); - list.add(new MultiPartBakedModel.Selector(instantiatedSelector.predicate, bakedModel)); - } - - return new MultiPartBakedModel(list); - } - - @Environment(EnvType.CLIENT) - public record Definition(List selectors) { - public MultiPart instantiate(StateDefinition stateDefinition) { - List list = this.selectors - .stream() - .map(selector -> new MultiPart.InstantiatedSelector(selector.getPredicate(stateDefinition), selector.getVariant())) - .toList(); - return new MultiPart(list); - } - - public Set getMultiVariants() { - return (Set)this.selectors.stream().map(Selector::getVariant).collect(Collectors.toSet()); - } - } - - @Environment(EnvType.CLIENT) - public static class Deserializer implements JsonDeserializer { - public MultiPart.Definition deserialize(JsonElement jsonElement, Type type, JsonDeserializationContext jsonDeserializationContext) throws JsonParseException { - return new MultiPart.Definition(this.getSelectors(jsonDeserializationContext, jsonElement.getAsJsonArray())); - } - - private List getSelectors(JsonDeserializationContext jsonContext, JsonArray elements) { - List list = new ArrayList(); - if (elements.isEmpty()) { - throw new JsonSyntaxException("Empty selector array"); - } else { - for (JsonElement jsonElement : elements) { - list.add((Selector)jsonContext.deserialize(jsonElement, Selector.class)); - } - - return list; - } - } - } - - @Environment(EnvType.CLIENT) - record InstantiatedSelector(Predicate predicate, MultiVariant variant) { - } -} diff --git a/net/minecraft/client/renderer/block/model/multipart/MultiPartModel.java b/net/minecraft/client/renderer/block/model/multipart/MultiPartModel.java new file mode 100644 index 00000000..d574ed14 --- /dev/null +++ b/net/minecraft/client/renderer/block/model/multipart/MultiPartModel.java @@ -0,0 +1,140 @@ +package net.minecraft.client.renderer.block.model.multipart; + +import com.google.common.collect.ImmutableList; +import com.google.common.collect.ImmutableList.Builder; +import it.unimi.dsi.fastutil.ints.IntArrayList; +import it.unimi.dsi.fastutil.ints.IntList; +import java.util.BitSet; +import java.util.List; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; +import java.util.function.Predicate; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.BlockModelPart; +import net.minecraft.client.renderer.block.model.BlockStateModel; +import net.minecraft.client.renderer.block.model.multipart.MultiPartModel.Unbaked.1; +import net.minecraft.client.renderer.block.model.multipart.MultiPartModel.Unbaked.1Key; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.client.resources.model.ModelBaker; +import net.minecraft.client.resources.model.ResolvableModel; +import net.minecraft.util.RandomSource; +import net.minecraft.world.level.block.state.BlockState; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public class MultiPartModel implements BlockStateModel { + private final MultiPartModel.SharedBakedState shared; + private final BlockState blockState; + @Nullable + private List models; + + MultiPartModel(MultiPartModel.SharedBakedState shared, BlockState blockState) { + this.shared = shared; + this.blockState = blockState; + } + + @Override + public TextureAtlasSprite particleIcon() { + return this.shared.particleIcon; + } + + @Override + public void collectParts(RandomSource random, List output) { + if (this.models == null) { + this.models = this.shared.selectModels(this.blockState); + } + + long l = random.nextLong(); + + for (BlockStateModel blockStateModel : this.models) { + random.setSeed(l); + blockStateModel.collectParts(random, output); + } + } + + @Environment(EnvType.CLIENT) + public record Selector(Predicate condition, T model) { + + public MultiPartModel.Selector with(S model) { + return new MultiPartModel.Selector<>(this.condition, model); + } + } + + @Environment(EnvType.CLIENT) + static final class SharedBakedState { + private final List> selectors; + final TextureAtlasSprite particleIcon; + private final Map> subsets = new ConcurrentHashMap(); + + private static BlockStateModel getFirstModel(List> selectors) { + if (selectors.isEmpty()) { + throw new IllegalArgumentException("Model must have at least one selector"); + } else { + return (BlockStateModel)((MultiPartModel.Selector)selectors.getFirst()).model(); + } + } + + public SharedBakedState(List> selectors) { + this.selectors = selectors; + BlockStateModel blockStateModel = getFirstModel(selectors); + this.particleIcon = blockStateModel.particleIcon(); + } + + public List selectModels(BlockState state) { + BitSet bitSet = new BitSet(); + + for (int i = 0; i < this.selectors.size(); i++) { + if (((MultiPartModel.Selector)this.selectors.get(i)).condition.test(state)) { + bitSet.set(i); + } + } + + return (List)this.subsets.computeIfAbsent(bitSet, bitSetx -> { + Builder builder = ImmutableList.builder(); + + for (int ix = 0; ix < this.selectors.size(); ix++) { + if (bitSetx.get(ix)) { + builder.add((BlockStateModel)((MultiPartModel.Selector)this.selectors.get(ix)).model); + } + } + + return builder.build(); + }); + } + } + + @Environment(EnvType.CLIENT) + public static class Unbaked implements BlockStateModel.UnbakedRoot { + final List> selectors; + private final ModelBaker.SharedOperationKey sharedStateKey = new 1(this); + + public Unbaked(List> selectors) { + this.selectors = selectors; + } + + @Override + public Object visualEqualityGroup(BlockState state) { + IntList intList = new IntArrayList(); + + for (int i = 0; i < this.selectors.size(); i++) { + if (((MultiPartModel.Selector)this.selectors.get(i)).condition.test(state)) { + intList.add(i); + } + } + + return new 1Key(this, intList); + } + + @Override + public void resolveDependencies(ResolvableModel.Resolver resolver) { + this.selectors.forEach(selector -> ((BlockStateModel.Unbaked)selector.model).resolveDependencies(resolver)); + } + + @Override + public BlockStateModel bake(BlockState state, ModelBaker baker) { + MultiPartModel.SharedBakedState sharedBakedState = baker.compute(this.sharedStateKey); + return new MultiPartModel(sharedBakedState, state); + } + } +} diff --git a/net/minecraft/client/renderer/block/model/multipart/OrCondition.java b/net/minecraft/client/renderer/block/model/multipart/OrCondition.java deleted file mode 100644 index f05b38da..00000000 --- a/net/minecraft/client/renderer/block/model/multipart/OrCondition.java +++ /dev/null @@ -1,25 +0,0 @@ -package net.minecraft.client.renderer.block.model.multipart; - -import com.google.common.collect.Streams; -import java.util.function.Predicate; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.Util; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.StateDefinition; - -@Environment(EnvType.CLIENT) -public class OrCondition implements Condition { - public static final String TOKEN = "OR"; - private final Iterable conditions; - - public OrCondition(Iterable conditions) { - this.conditions = conditions; - } - - @Override - public Predicate getPredicate(StateDefinition stateDefinition) { - return Util.anyOf(Streams.stream(this.conditions).map(condition -> condition.getPredicate(stateDefinition)).toList()); - } -} diff --git a/net/minecraft/client/renderer/block/model/multipart/Selector.java b/net/minecraft/client/renderer/block/model/multipart/Selector.java index 69b1f628..82d9a4af 100644 --- a/net/minecraft/client/renderer/block/model/multipart/Selector.java +++ b/net/minecraft/client/renderer/block/model/multipart/Selector.java @@ -1,81 +1,25 @@ package net.minecraft.client.renderer.block.model.multipart; -import com.google.common.annotations.VisibleForTesting; -import com.google.common.collect.Streams; -import com.google.gson.JsonDeserializationContext; -import com.google.gson.JsonDeserializer; -import com.google.gson.JsonElement; -import com.google.gson.JsonObject; -import com.google.gson.JsonParseException; -import java.lang.reflect.Type; -import java.util.List; -import java.util.Set; -import java.util.Map.Entry; +import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.RecordCodecBuilder; +import java.util.Optional; import java.util.function.Predicate; -import java.util.stream.Collectors; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.MultiVariant; -import net.minecraft.util.GsonHelper; -import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.world.level.block.state.StateDefinition; +import net.minecraft.world.level.block.state.StateHolder; @Environment(EnvType.CLIENT) -public class Selector { - private final Condition condition; - private final MultiVariant variant; +public record Selector(Optional condition, BlockStateModel.Unbaked variant) { + public static final Codec CODEC = RecordCodecBuilder.create( + instance -> instance.group( + Condition.CODEC.optionalFieldOf("when").forGetter(Selector::condition), BlockStateModel.Unbaked.CODEC.fieldOf("apply").forGetter(Selector::variant) + ) + .apply(instance, Selector::new) + ); - public Selector(Condition condition, MultiVariant variant) { - this.condition = condition; - this.variant = variant; - } - - public MultiVariant getVariant() { - return this.variant; - } - - public Predicate getPredicate(StateDefinition definition) { - return this.condition.getPredicate(definition); - } - - @Environment(EnvType.CLIENT) - public static class Deserializer implements JsonDeserializer { - public Selector deserialize(JsonElement json, Type type, JsonDeserializationContext context) throws JsonParseException { - JsonObject jsonObject = json.getAsJsonObject(); - return new Selector(this.getSelector(jsonObject), context.deserialize(jsonObject.get("apply"), MultiVariant.class)); - } - - private Condition getSelector(JsonObject json) { - return json.has("when") ? getCondition(GsonHelper.getAsJsonObject(json, "when")) : Condition.TRUE; - } - - @VisibleForTesting - static Condition getCondition(JsonObject json) { - Set> set = json.entrySet(); - if (set.isEmpty()) { - throw new JsonParseException("No elements found in selector"); - } else if (set.size() == 1) { - if (json.has("OR")) { - List list = (List)Streams.stream(GsonHelper.getAsJsonArray(json, "OR")) - .map(jsonElement -> getCondition(jsonElement.getAsJsonObject())) - .collect(Collectors.toList()); - return new OrCondition(list); - } else if (json.has("AND")) { - List list = (List)Streams.stream(GsonHelper.getAsJsonArray(json, "AND")) - .map(jsonElement -> getCondition(jsonElement.getAsJsonObject())) - .collect(Collectors.toList()); - return new AndCondition(list); - } else { - return getKeyValueCondition((Entry)set.iterator().next()); - } - } else { - return new AndCondition((Iterable)set.stream().map(Selector.Deserializer::getKeyValueCondition).collect(Collectors.toList())); - } - } - - private static Condition getKeyValueCondition(Entry entry) { - return new KeyValueCondition((String)entry.getKey(), ((JsonElement)entry.getValue()).getAsString()); - } + public > Predicate instantiate(StateDefinition stateDefinition) { + return (Predicate)this.condition.map(condition -> condition.instantiate(stateDefinition)).orElse((Predicate)stateHolder -> true); } } diff --git a/net/minecraft/client/renderer/blockentity/AbstractSignRenderer.java b/net/minecraft/client/renderer/blockentity/AbstractSignRenderer.java index a0c121f9..bceedcc6 100644 --- a/net/minecraft/client/renderer/blockentity/AbstractSignRenderer.java +++ b/net/minecraft/client/renderer/blockentity/AbstractSignRenderer.java @@ -8,9 +8,11 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.Font; +import net.minecraft.client.gui.Font.DisplayMode; import net.minecraft.client.model.Model; import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.resources.model.Material; import net.minecraft.core.BlockPos; import net.minecraft.util.ARGB; @@ -31,7 +33,7 @@ public abstract class AbstractSignRenderer implements BlockEntityRenderer { @@ -34,7 +35,7 @@ public class BannerRenderer implements BlockEntityRenderer { private final BannerFlagModel standingFlagModel; private final BannerFlagModel wallFlagModel; - public BannerRenderer(BlockEntityRendererProvider.Context context) { + public BannerRenderer(Context context) { this(context.getModelSet()); } @@ -45,7 +46,7 @@ public class BannerRenderer implements BlockEntityRenderer { this.wallFlagModel = new BannerFlagModel(modelSet.bakeLayer(ModelLayers.WALL_BANNER_FLAG)); } - public void render(BannerBlockEntity bannerBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(BannerBlockEntity bannerBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { BlockState blockState = bannerBlockEntity.getBlockState(); BannerModel bannerModel; BannerFlagModel bannerFlagModel; @@ -128,7 +129,7 @@ public class BannerRenderer implements BlockEntityRenderer { renderPatternLayer(poseStack, bufferSource, packedLight, packedOverlay, flagPart, banner ? Sheets.BANNER_BASE : Sheets.SHIELD_BASE, baseColor); for (int i = 0; i < 16 && i < patterns.layers().size(); i++) { - Layer layer = (Layer)patterns.layers().get(i); + BannerPatternLayers.Layer layer = (BannerPatternLayers.Layer)patterns.layers().get(i); Material material = banner ? Sheets.getBannerMaterial(layer.pattern()) : Sheets.getShieldMaterial(layer.pattern()); renderPatternLayer(poseStack, bufferSource, packedLight, packedOverlay, flagPart, material, layer.color()); } diff --git a/net/minecraft/client/renderer/blockentity/BeaconRenderer.java b/net/minecraft/client/renderer/blockentity/BeaconRenderer.java index 12d22171..b4254075 100644 --- a/net/minecraft/client/renderer/blockentity/BeaconRenderer.java +++ b/net/minecraft/client/renderer/blockentity/BeaconRenderer.java @@ -2,42 +2,54 @@ package net.minecraft.client.renderer.blockentity; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; -import com.mojang.blaze3d.vertex.PoseStack.Pose; import com.mojang.math.Axis; import java.util.List; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.Minecraft; +import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.ARGB; import net.minecraft.util.Mth; -import net.minecraft.world.level.block.entity.BeaconBlockEntity; +import net.minecraft.world.level.block.entity.BeaconBeamOwner; +import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) -public class BeaconRenderer implements BlockEntityRenderer { +public class BeaconRenderer implements BlockEntityRenderer { public static final ResourceLocation BEAM_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/beacon_beam.png"); - public static final int MAX_RENDER_Y = 1024; + public static final int MAX_RENDER_Y = 2048; + private static final float BEAM_SCALE_THRESHOLD = 96.0F; + public static final float SOLID_BEAM_RADIUS = 0.2F; + public static final float BEAM_GLOW_RADIUS = 0.25F; - public BeaconRenderer(BlockEntityRendererProvider.Context context) { + public BeaconRenderer(Context context) { } - public void render(BeaconBlockEntity beaconBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { - long l = beaconBlockEntity.getLevel().getGameTime(); - List list = beaconBlockEntity.getBeamSections(); - int k = 0; + @Override + public void render(T blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay, Vec3 cameraPos) { + long l = blockEntity.getLevel().getGameTime(); + float f = (float)cameraPos.subtract(blockEntity.getBlockPos().getCenter()).horizontalDistance(); + LocalPlayer localPlayer = Minecraft.getInstance().player; + float g = localPlayer != null && localPlayer.isScoping() ? 1.0F : Math.max(1.0F, f / 96.0F); + List list = blockEntity.getBeamSections(); + int i = 0; - for (int m = 0; m < list.size(); m++) { - BeaconBlockEntity.BeaconBeamSection beaconBeamSection = (BeaconBlockEntity.BeaconBeamSection)list.get(m); - renderBeaconBeam(poseStack, multiBufferSource, f, l, k, m == list.size() - 1 ? 1024 : beaconBeamSection.getHeight(), beaconBeamSection.getColor()); - k += beaconBeamSection.getHeight(); + for (int j = 0; j < list.size(); j++) { + BeaconBeamOwner.Section section = (BeaconBeamOwner.Section)list.get(j); + renderBeaconBeam(poseStack, bufferSource, partialTick, g, l, i, j == list.size() - 1 ? 2048 : section.getHeight(), section.getColor()); + i += section.getHeight(); } } - private static void renderBeaconBeam(PoseStack poseStack, MultiBufferSource bufferSource, float partialTick, long gameTime, int yOffset, int height, int color) { - renderBeaconBeam(poseStack, bufferSource, BEAM_LOCATION, partialTick, 1.0F, gameTime, yOffset, height, color, 0.2F, 0.25F); + private static void renderBeaconBeam( + PoseStack poseStack, MultiBufferSource bufferSource, float partialTick, float radius, long gameTime, int yOffset, int height, int color + ) { + renderBeaconBeam(poseStack, bufferSource, BEAM_LOCATION, partialTick, 1.0F, gameTime, yOffset, height, color, 0.2F * radius, 0.25F * radius); } public static void renderBeaconBeam( @@ -140,7 +152,7 @@ public class BeaconRenderer implements BlockEntityRenderer { float minV, float maxV ) { - Pose pose = poseStack.last(); + PoseStack.Pose pose = poseStack.last(); renderQuad(pose, consumer, color, minY, maxY, x1, z1, x2, z2, minU, maxU, minV, maxV); renderQuad(pose, consumer, color, minY, maxY, x4, z4, x3, z3, minU, maxU, minV, maxV); renderQuad(pose, consumer, color, minY, maxY, x2, z2, x4, z4, minU, maxU, minV, maxV); @@ -148,7 +160,7 @@ public class BeaconRenderer implements BlockEntityRenderer { } private static void renderQuad( - Pose pose, + PoseStack.Pose pose, VertexConsumer consumer, int color, int minY, @@ -168,7 +180,7 @@ public class BeaconRenderer implements BlockEntityRenderer { addVertex(pose, consumer, color, maxY, maxX, maxZ, minU, minV); } - private static void addVertex(Pose pose, VertexConsumer consumer, int color, int y, float x, float z, float u, float v) { + private static void addVertex(PoseStack.Pose pose, VertexConsumer consumer, int color, int y, float x, float z, float u, float v) { consumer.addVertex(pose, x, (float)y, z) .setColor(color) .setUv(u, v) @@ -177,16 +189,18 @@ public class BeaconRenderer implements BlockEntityRenderer { .setNormal(pose, 0.0F, 1.0F, 0.0F); } - public boolean shouldRenderOffScreen(BeaconBlockEntity beaconBlockEntity) { + @Override + public boolean shouldRenderOffScreen(T blockEntity) { return true; } @Override public int getViewDistance() { - return 256; + return Minecraft.getInstance().options.getEffectiveRenderDistance() * 16; } - public boolean shouldRender(BeaconBlockEntity beaconBlockEntity, Vec3 vec3) { - return Vec3.atCenterOf(beaconBlockEntity.getBlockPos()).multiply(1.0, 0.0, 1.0).closerThan(vec3.multiply(1.0, 0.0, 1.0), this.getViewDistance()); + @Override + public boolean shouldRender(T blockEntity, Vec3 cameraPos) { + return Vec3.atCenterOf(blockEntity.getBlockPos()).multiply(1.0, 0.0, 1.0).closerThan(cameraPos.multiply(1.0, 0.0, 1.0), this.getViewDistance()); } } diff --git a/net/minecraft/client/renderer/blockentity/BedRenderer.java b/net/minecraft/client/renderer/blockentity/BedRenderer.java index 807d4b34..ebd611c6 100644 --- a/net/minecraft/client/renderer/blockentity/BedRenderer.java +++ b/net/minecraft/client/renderer/blockentity/BedRenderer.java @@ -17,6 +17,7 @@ import net.minecraft.client.model.geom.builders.PartDefinition; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.Sheets; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.resources.model.Material; import net.minecraft.core.Direction; import net.minecraft.world.level.Level; @@ -28,13 +29,14 @@ import net.minecraft.world.level.block.entity.BedBlockEntity; import net.minecraft.world.level.block.entity.BlockEntityType; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.properties.BedPart; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class BedRenderer implements BlockEntityRenderer { private final Model headModel; private final Model footModel; - public BedRenderer(BlockEntityRendererProvider.Context context) { + public BedRenderer(Context context) { this(context.getModelSet()); } @@ -75,7 +77,7 @@ public class BedRenderer implements BlockEntityRenderer { return LayerDefinition.create(meshDefinition, 64, 64); } - public void render(BedBlockEntity bedBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(BedBlockEntity bedBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { Level level = bedBlockEntity.getLevel(); if (level != null) { Material material = Sheets.getBedMaterial(bedBlockEntity.getColor()); diff --git a/net/minecraft/client/renderer/blockentity/BellRenderer.java b/net/minecraft/client/renderer/blockentity/BellRenderer.java index 30d23d44..f9f528f4 100644 --- a/net/minecraft/client/renderer/blockentity/BellRenderer.java +++ b/net/minecraft/client/renderer/blockentity/BellRenderer.java @@ -8,10 +8,12 @@ import net.minecraft.client.model.BellModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.texture.TextureAtlas; import net.minecraft.client.resources.model.Material; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.level.block.entity.BellBlockEntity; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class BellRenderer implements BlockEntityRenderer { @@ -20,11 +22,11 @@ public class BellRenderer implements BlockEntityRenderer { ); private final BellModel model; - public BellRenderer(BlockEntityRendererProvider.Context context) { + public BellRenderer(Context context) { this.model = new BellModel(context.bakeLayer(ModelLayers.BELL)); } - public void render(BellBlockEntity bellBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(BellBlockEntity bellBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { VertexConsumer vertexConsumer = BELL_RESOURCE_LOCATION.buffer(multiBufferSource, RenderType::entitySolid); this.model.setupAnim(bellBlockEntity, f); this.model.renderToBuffer(poseStack, vertexConsumer, i, j); diff --git a/net/minecraft/client/renderer/blockentity/BlockEntityRenderDispatcher.java b/net/minecraft/client/renderer/blockentity/BlockEntityRenderDispatcher.java index 5e8ba7ee..1b3ab6ec 100644 --- a/net/minecraft/client/renderer/blockentity/BlockEntityRenderDispatcher.java +++ b/net/minecraft/client/renderer/blockentity/BlockEntityRenderDispatcher.java @@ -15,6 +15,7 @@ import net.minecraft.client.model.geom.EntityModelSet; import net.minecraft.client.renderer.LevelRenderer; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.block.BlockRenderDispatcher; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.entity.EntityRenderDispatcher; import net.minecraft.client.renderer.entity.ItemRenderer; import net.minecraft.client.renderer.item.ItemModelResolver; @@ -25,6 +26,7 @@ import net.minecraft.world.level.Level; import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.entity.BlockEntityType; import net.minecraft.world.phys.HitResult; +import net.minecraft.world.phys.Vec3; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) @@ -76,7 +78,7 @@ public class BlockEntityRenderDispatcher implements ResourceManagerReloadListene if (blockEntity.hasLevel() && blockEntity.getType().isValid(blockEntity.getBlockState())) { if (blockEntityRenderer.shouldRender(blockEntity, this.camera.getPosition())) { try { - setupAndRender(blockEntityRenderer, blockEntity, partialTick, poseStack, bufferSource); + setupAndRender(blockEntityRenderer, blockEntity, partialTick, poseStack, bufferSource, this.camera.getPosition()); } catch (Throwable var9) { CrashReport crashReport = CrashReport.forThrowable(var9, "Rendering Block Entity"); CrashReportCategory crashReportCategory = crashReport.addCategory("Block Entity Details"); @@ -89,7 +91,7 @@ public class BlockEntityRenderDispatcher implements ResourceManagerReloadListene } private static void setupAndRender( - BlockEntityRenderer renderer, T blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource + BlockEntityRenderer renderer, T blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, Vec3 cameraPos ) { Level level = blockEntity.getLevel(); int i; @@ -99,7 +101,7 @@ public class BlockEntityRenderDispatcher implements ResourceManagerReloadListene i = 15728880; } - renderer.render(blockEntity, partialTick, poseStack, bufferSource, i, OverlayTexture.NO_OVERLAY); + renderer.render(blockEntity, partialTick, poseStack, bufferSource, i, OverlayTexture.NO_OVERLAY, cameraPos); } public void setLevel(@Nullable Level level) { @@ -111,7 +113,7 @@ public class BlockEntityRenderDispatcher implements ResourceManagerReloadListene @Override public void onResourceManagerReload(ResourceManager resourceManager) { - BlockEntityRendererProvider.Context context = new BlockEntityRendererProvider.Context( + Context context = new Context( this, this.blockRenderDispatcher, this.itemModelResolver, this.itemRenderer, this.entityRenderer, (EntityModelSet)this.entityModelSet.get(), this.font ); this.renderers = BlockEntityRenderers.createEntityRenderers(context); diff --git a/net/minecraft/client/renderer/blockentity/BlockEntityRenderer.java b/net/minecraft/client/renderer/blockentity/BlockEntityRenderer.java index 22cdac18..d4901d25 100644 --- a/net/minecraft/client/renderer/blockentity/BlockEntityRenderer.java +++ b/net/minecraft/client/renderer/blockentity/BlockEntityRenderer.java @@ -9,7 +9,7 @@ import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public interface BlockEntityRenderer { - void render(T blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay); + void render(T blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay, Vec3 cameraPos); default boolean shouldRenderOffScreen(T blockEntity) { return false; diff --git a/net/minecraft/client/renderer/blockentity/BlockEntityRenderers.java b/net/minecraft/client/renderer/blockentity/BlockEntityRenderers.java index de0a8076..f320e32d 100644 --- a/net/minecraft/client/renderer/blockentity/BlockEntityRenderers.java +++ b/net/minecraft/client/renderer/blockentity/BlockEntityRenderers.java @@ -6,6 +6,7 @@ import com.google.common.collect.ImmutableMap.Builder; import java.util.Map; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.core.registries.BuiltInRegistries; import net.minecraft.world.level.block.entity.BlockEntity; import net.minecraft.world.level.block.entity.BlockEntityType; @@ -18,7 +19,7 @@ public class BlockEntityRenderers { PROVIDERS.put(type, renderProvider); } - public static Map, BlockEntityRenderer> createEntityRenderers(BlockEntityRendererProvider.Context context) { + public static Map, BlockEntityRenderer> createEntityRenderers(Context context) { Builder, BlockEntityRenderer> builder = ImmutableMap.builder(); PROVIDERS.forEach((blockEntityType, blockEntityRendererProvider) -> { try { @@ -45,7 +46,8 @@ public class BlockEntityRenderers { register(BlockEntityType.BEACON, BeaconRenderer::new); register(BlockEntityType.SKULL, SkullBlockRenderer::new); register(BlockEntityType.BANNER, BannerRenderer::new); - register(BlockEntityType.STRUCTURE_BLOCK, StructureBlockRenderer::new); + register(BlockEntityType.STRUCTURE_BLOCK, BlockEntityWithBoundingBoxRenderer::new); + register(BlockEntityType.TEST_INSTANCE_BLOCK, TestInstanceRenderer::new); register(BlockEntityType.SHULKER_BOX, ShulkerBoxRenderer::new); register(BlockEntityType.BED, BedRenderer::new); register(BlockEntityType.CONDUIT, ConduitRenderer::new); diff --git a/net/minecraft/client/renderer/blockentity/BlockEntityWithBoundingBoxRenderer.java b/net/minecraft/client/renderer/blockentity/BlockEntityWithBoundingBoxRenderer.java new file mode 100644 index 00000000..f3f12ffa --- /dev/null +++ b/net/minecraft/client/renderer/blockentity/BlockEntityWithBoundingBoxRenderer.java @@ -0,0 +1,134 @@ +package net.minecraft.client.renderer.blockentity; + +import com.mojang.blaze3d.vertex.PoseStack; +import com.mojang.blaze3d.vertex.VertexConsumer; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.Minecraft; +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.ShapeRenderer; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; +import net.minecraft.core.BlockPos; +import net.minecraft.core.Vec3i; +import net.minecraft.world.level.BlockGetter; +import net.minecraft.world.level.block.Blocks; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.entity.BoundingBoxRenderable; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.Vec3; +import net.minecraft.world.phys.shapes.BitSetDiscreteVoxelShape; +import net.minecraft.world.phys.shapes.DiscreteVoxelShape; + +@Environment(EnvType.CLIENT) +public class BlockEntityWithBoundingBoxRenderer implements BlockEntityRenderer { + public BlockEntityWithBoundingBoxRenderer(Context context) { + } + + @Override + public void render(T blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay, Vec3 cameraPos) { + if (Minecraft.getInstance().player.canUseGameMasterBlocks() || Minecraft.getInstance().player.isSpectator()) { + BoundingBoxRenderable.Mode mode = blockEntity.renderMode(); + if (mode != BoundingBoxRenderable.Mode.NONE) { + BoundingBoxRenderable.RenderableBox renderableBox = blockEntity.getRenderableBox(); + BlockPos blockPos = renderableBox.localPos(); + Vec3i vec3i = renderableBox.size(); + if (vec3i.getX() >= 1 && vec3i.getY() >= 1 && vec3i.getZ() >= 1) { + float f = 1.0F; + float g = 0.9F; + float h = 0.5F; + VertexConsumer vertexConsumer = bufferSource.getBuffer(RenderType.lines()); + BlockPos blockPos2 = blockPos.offset(vec3i); + ShapeRenderer.renderLineBox( + poseStack, + vertexConsumer, + blockPos.getX(), + blockPos.getY(), + blockPos.getZ(), + blockPos2.getX(), + blockPos2.getY(), + blockPos2.getZ(), + 0.9F, + 0.9F, + 0.9F, + 1.0F, + 0.5F, + 0.5F, + 0.5F + ); + if (mode == BoundingBoxRenderable.Mode.BOX_AND_INVISIBLE_BLOCKS && blockEntity.getLevel() != null) { + this.renderInvisibleBlocks(blockEntity, blockEntity.getLevel(), blockPos, vec3i, bufferSource, poseStack); + } + } + } + } + } + + private void renderInvisibleBlocks(T blockEntity, BlockGetter level, BlockPos pos, Vec3i boxSize, MultiBufferSource bufferSource, PoseStack poseStack) { + VertexConsumer vertexConsumer = bufferSource.getBuffer(RenderType.lines()); + BlockPos blockPos = blockEntity.getBlockPos(); + BlockPos blockPos2 = blockPos.offset(pos); + + for (BlockPos blockPos3 : BlockPos.betweenClosed(blockPos2, blockPos2.offset(boxSize).offset(-1, -1, -1))) { + BlockState blockState = level.getBlockState(blockPos3); + boolean bl = blockState.isAir(); + boolean bl2 = blockState.is(Blocks.STRUCTURE_VOID); + boolean bl3 = blockState.is(Blocks.BARRIER); + boolean bl4 = blockState.is(Blocks.LIGHT); + boolean bl5 = bl2 || bl3 || bl4; + if (bl || bl5) { + float f = bl ? 0.05F : 0.0F; + double d = blockPos3.getX() - blockPos.getX() + 0.45F - f; + double e = blockPos3.getY() - blockPos.getY() + 0.45F - f; + double g = blockPos3.getZ() - blockPos.getZ() + 0.45F - f; + double h = blockPos3.getX() - blockPos.getX() + 0.55F + f; + double i = blockPos3.getY() - blockPos.getY() + 0.55F + f; + double j = blockPos3.getZ() - blockPos.getZ() + 0.55F + f; + if (bl) { + ShapeRenderer.renderLineBox(poseStack, vertexConsumer, d, e, g, h, i, j, 0.5F, 0.5F, 1.0F, 1.0F, 0.5F, 0.5F, 1.0F); + } else if (bl2) { + ShapeRenderer.renderLineBox(poseStack, vertexConsumer, d, e, g, h, i, j, 1.0F, 0.75F, 0.75F, 1.0F, 1.0F, 0.75F, 0.75F); + } else if (bl3) { + ShapeRenderer.renderLineBox(poseStack, vertexConsumer, d, e, g, h, i, j, 1.0F, 0.0F, 0.0F, 1.0F, 1.0F, 0.0F, 0.0F); + } else if (bl4) { + ShapeRenderer.renderLineBox(poseStack, vertexConsumer, d, e, g, h, i, j, 1.0F, 1.0F, 0.0F, 1.0F, 1.0F, 1.0F, 0.0F); + } + } + } + } + + private void renderStructureVoids(T blockEntity, BlockPos pos, Vec3i boxSize, VertexConsumer consumer, PoseStack poseStack) { + BlockGetter blockGetter = blockEntity.getLevel(); + if (blockGetter != null) { + BlockPos blockPos = blockEntity.getBlockPos(); + DiscreteVoxelShape discreteVoxelShape = new BitSetDiscreteVoxelShape(boxSize.getX(), boxSize.getY(), boxSize.getZ()); + + for (BlockPos blockPos2 : BlockPos.betweenClosed(pos, pos.offset(boxSize).offset(-1, -1, -1))) { + if (blockGetter.getBlockState(blockPos2).is(Blocks.STRUCTURE_VOID)) { + discreteVoxelShape.fill(blockPos2.getX() - pos.getX(), blockPos2.getY() - pos.getY(), blockPos2.getZ() - pos.getZ()); + } + } + + discreteVoxelShape.forAllFaces((direction, i, j, k) -> { + float f = 0.48F; + float g = i + pos.getX() - blockPos.getX() + 0.5F - 0.48F; + float h = j + pos.getY() - blockPos.getY() + 0.5F - 0.48F; + float l = k + pos.getZ() - blockPos.getZ() + 0.5F - 0.48F; + float m = i + pos.getX() - blockPos.getX() + 0.5F + 0.48F; + float n = j + pos.getY() - blockPos.getY() + 0.5F + 0.48F; + float o = k + pos.getZ() - blockPos.getZ() + 0.5F + 0.48F; + ShapeRenderer.renderFace(poseStack, consumer, direction, g, h, l, m, n, o, 0.75F, 0.75F, 1.0F, 0.2F); + }); + } + } + + @Override + public boolean shouldRenderOffScreen(T blockEntity) { + return true; + } + + @Override + public int getViewDistance() { + return 96; + } +} diff --git a/net/minecraft/client/renderer/blockentity/BrushableBlockRenderer.java b/net/minecraft/client/renderer/blockentity/BrushableBlockRenderer.java index c2aaafbc..31c2c963 100644 --- a/net/minecraft/client/renderer/blockentity/BrushableBlockRenderer.java +++ b/net/minecraft/client/renderer/blockentity/BrushableBlockRenderer.java @@ -6,6 +6,7 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.LevelRenderer; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.entity.ItemRenderer; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.core.Direction; @@ -13,16 +14,17 @@ import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.block.entity.BrushableBlockEntity; import net.minecraft.world.level.block.state.properties.BlockStateProperties; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class BrushableBlockRenderer implements BlockEntityRenderer { private final ItemRenderer itemRenderer; - public BrushableBlockRenderer(BlockEntityRendererProvider.Context context) { + public BrushableBlockRenderer(Context context) { this.itemRenderer = context.getItemRenderer(); } - public void render(BrushableBlockEntity brushableBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(BrushableBlockEntity brushableBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { if (brushableBlockEntity.getLevel() != null) { int k = (Integer)brushableBlockEntity.getBlockState().getValue(BlockStateProperties.DUSTED); if (k > 0) { @@ -39,7 +41,10 @@ public class BrushableBlockRenderer implements BlockEntityRenderer { private static final float SIZE = 0.375F; private final ItemRenderer itemRenderer; - public CampfireRenderer(BlockEntityRendererProvider.Context context) { + public CampfireRenderer(Context context) { this.itemRenderer = context.getItemRenderer(); } - public void render(CampfireBlockEntity campfireBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(CampfireBlockEntity campfireBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { Direction direction = campfireBlockEntity.getBlockState().getValue(CampfireBlock.FACING); NonNullList nonNullList = campfireBlockEntity.getItems(); int k = (int)campfireBlockEntity.getBlockPos().asLong(); diff --git a/net/minecraft/client/renderer/blockentity/ChestRenderer.java b/net/minecraft/client/renderer/blockentity/ChestRenderer.java index 9f5a70f7..b09583e7 100644 --- a/net/minecraft/client/renderer/blockentity/ChestRenderer.java +++ b/net/minecraft/client/renderer/blockentity/ChestRenderer.java @@ -11,6 +11,7 @@ import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.Sheets; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.resources.model.Material; import net.minecraft.core.Direction; import net.minecraft.world.level.Level; @@ -25,6 +26,7 @@ import net.minecraft.world.level.block.entity.LidBlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.properties.ChestType; import net.minecraft.world.level.block.state.properties.Property; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class ChestRenderer implements BlockEntityRenderer { @@ -33,7 +35,7 @@ public class ChestRenderer implements Bl private final ChestModel doubleRightModel; private final boolean xmasTextures = xmasTextures(); - public ChestRenderer(BlockEntityRendererProvider.Context context) { + public ChestRenderer(Context context) { this.singleModel = new ChestModel(context.bakeLayer(ModelLayers.CHEST)); this.doubleLeftModel = new ChestModel(context.bakeLayer(ModelLayers.DOUBLE_CHEST_LEFT)); this.doubleRightModel = new ChestModel(context.bakeLayer(ModelLayers.DOUBLE_CHEST_RIGHT)); @@ -45,11 +47,11 @@ public class ChestRenderer implements Bl } @Override - public void render(T blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay) { + public void render(T blockEntity, float partialTick, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay, Vec3 cameraPos) { Level level = blockEntity.getLevel(); boolean bl = level != null; BlockState blockState = bl ? blockEntity.getBlockState() : Blocks.CHEST.defaultBlockState().setValue((Property)ChestBlock.FACING, Direction.SOUTH); - ChestType chestType = blockState.hasProperty((Property)ChestBlock.TYPE) ? blockState.getValue(ChestBlock.TYPE) : ChestType.SINGLE; + ChestType chestType = blockState.hasProperty(ChestBlock.TYPE) ? blockState.getValue(ChestBlock.TYPE) : ChestType.SINGLE; if (blockState.getBlock() instanceof AbstractChestBlock abstractChestBlock) { boolean bl2 = chestType != ChestType.SINGLE; poseStack.pushPose(); diff --git a/net/minecraft/client/renderer/blockentity/ConduitRenderer.java b/net/minecraft/client/renderer/blockentity/ConduitRenderer.java index 408f0469..3f11a5dd 100644 --- a/net/minecraft/client/renderer/blockentity/ConduitRenderer.java +++ b/net/minecraft/client/renderer/blockentity/ConduitRenderer.java @@ -13,35 +13,34 @@ import net.minecraft.client.model.geom.builders.CubeListBuilder; import net.minecraft.client.model.geom.builders.LayerDefinition; import net.minecraft.client.model.geom.builders.MeshDefinition; import net.minecraft.client.model.geom.builders.PartDefinition; +import net.minecraft.client.renderer.MaterialMapper; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.texture.TextureAtlas; import net.minecraft.client.resources.model.Material; -import net.minecraft.resources.ResourceLocation; import net.minecraft.util.Mth; import net.minecraft.world.level.block.entity.ConduitBlockEntity; +import net.minecraft.world.phys.Vec3; import org.joml.Quaternionf; import org.joml.Vector3f; @Environment(EnvType.CLIENT) public class ConduitRenderer implements BlockEntityRenderer { - public static final Material SHELL_TEXTURE = new Material(TextureAtlas.LOCATION_BLOCKS, ResourceLocation.withDefaultNamespace("entity/conduit/base")); - public static final Material ACTIVE_SHELL_TEXTURE = new Material(TextureAtlas.LOCATION_BLOCKS, ResourceLocation.withDefaultNamespace("entity/conduit/cage")); - public static final Material WIND_TEXTURE = new Material(TextureAtlas.LOCATION_BLOCKS, ResourceLocation.withDefaultNamespace("entity/conduit/wind")); - public static final Material VERTICAL_WIND_TEXTURE = new Material( - TextureAtlas.LOCATION_BLOCKS, ResourceLocation.withDefaultNamespace("entity/conduit/wind_vertical") - ); - public static final Material OPEN_EYE_TEXTURE = new Material(TextureAtlas.LOCATION_BLOCKS, ResourceLocation.withDefaultNamespace("entity/conduit/open_eye")); - public static final Material CLOSED_EYE_TEXTURE = new Material( - TextureAtlas.LOCATION_BLOCKS, ResourceLocation.withDefaultNamespace("entity/conduit/closed_eye") - ); + public static final MaterialMapper MAPPER = new MaterialMapper(TextureAtlas.LOCATION_BLOCKS, "entity/conduit"); + public static final Material SHELL_TEXTURE = MAPPER.defaultNamespaceApply("base"); + public static final Material ACTIVE_SHELL_TEXTURE = MAPPER.defaultNamespaceApply("cage"); + public static final Material WIND_TEXTURE = MAPPER.defaultNamespaceApply("wind"); + public static final Material VERTICAL_WIND_TEXTURE = MAPPER.defaultNamespaceApply("wind_vertical"); + public static final Material OPEN_EYE_TEXTURE = MAPPER.defaultNamespaceApply("open_eye"); + public static final Material CLOSED_EYE_TEXTURE = MAPPER.defaultNamespaceApply("closed_eye"); private final ModelPart eye; private final ModelPart wind; private final ModelPart shell; private final ModelPart cage; private final BlockEntityRenderDispatcher renderer; - public ConduitRenderer(BlockEntityRendererProvider.Context context) { + public ConduitRenderer(Context context) { this.renderer = context.getBlockEntityRenderDispatcher(); this.eye = context.bakeLayer(ModelLayers.CONDUIT_EYE); this.wind = context.bakeLayer(ModelLayers.CONDUIT_WIND); @@ -79,7 +78,7 @@ public class ConduitRenderer implements BlockEntityRenderer return LayerDefinition.create(meshDefinition, 32, 16); } - public void render(ConduitBlockEntity conduitBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(ConduitBlockEntity conduitBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { float g = conduitBlockEntity.tickCount + f; if (!conduitBlockEntity.isActive()) { float h = conduitBlockEntity.getActiveRotation(0.0F); diff --git a/net/minecraft/client/renderer/blockentity/DecoratedPotRenderer.java b/net/minecraft/client/renderer/blockentity/DecoratedPotRenderer.java index 4bff4fd6..66cfe3a3 100644 --- a/net/minecraft/client/renderer/blockentity/DecoratedPotRenderer.java +++ b/net/minecraft/client/renderer/blockentity/DecoratedPotRenderer.java @@ -19,6 +19,7 @@ import net.minecraft.client.model.geom.builders.PartDefinition; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.Sheets; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.resources.model.Material; import net.minecraft.core.Direction; import net.minecraft.util.Mth; @@ -26,6 +27,7 @@ import net.minecraft.world.item.Item; import net.minecraft.world.level.block.entity.DecoratedPotBlockEntity; import net.minecraft.world.level.block.entity.DecoratedPotPatterns; import net.minecraft.world.level.block.entity.PotDecorations; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class DecoratedPotRenderer implements BlockEntityRenderer { @@ -45,7 +47,7 @@ public class DecoratedPotRenderer implements BlockEntityRenderer { @@ -23,11 +25,13 @@ public class EnchantTableRenderer implements BlockEntityRenderer hangingSignModels; - public HangingSignRenderer(BlockEntityRendererProvider.Context context) { + public HangingSignRenderer(Context context) { super(context); Stream stream = WoodType.values() .flatMap( diff --git a/net/minecraft/client/renderer/blockentity/LecternRenderer.java b/net/minecraft/client/renderer/blockentity/LecternRenderer.java index 7d6b7eb5..e4de40c0 100644 --- a/net/minecraft/client/renderer/blockentity/LecternRenderer.java +++ b/net/minecraft/client/renderer/blockentity/LecternRenderer.java @@ -9,20 +9,22 @@ import net.minecraft.client.model.BookModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.core.Direction; import net.minecraft.world.level.block.LecternBlock; import net.minecraft.world.level.block.entity.LecternBlockEntity; import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class LecternRenderer implements BlockEntityRenderer { private final BookModel bookModel; - public LecternRenderer(BlockEntityRendererProvider.Context context) { + public LecternRenderer(Context context) { this.bookModel = new BookModel(context.bakeLayer(ModelLayers.BOOK)); } - public void render(LecternBlockEntity lecternBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(LecternBlockEntity lecternBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { BlockState blockState = lecternBlockEntity.getBlockState(); if ((Boolean)blockState.getValue(LecternBlock.HAS_BOOK)) { poseStack.pushPose(); diff --git a/net/minecraft/client/renderer/blockentity/PistonHeadRenderer.java b/net/minecraft/client/renderer/blockentity/PistonHeadRenderer.java index 5d8b142d..2849232f 100644 --- a/net/minecraft/client/renderer/blockentity/PistonHeadRenderer.java +++ b/net/minecraft/client/renderer/blockentity/PistonHeadRenderer.java @@ -2,6 +2,7 @@ package net.minecraft.client.renderer.blockentity; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; +import java.util.List; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.ItemBlockRenderTypes; @@ -9,6 +10,8 @@ import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.block.BlockRenderDispatcher; import net.minecraft.client.renderer.block.ModelBlockRenderer; +import net.minecraft.client.renderer.block.model.BlockModelPart; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.util.RandomSource; @@ -19,16 +22,17 @@ import net.minecraft.world.level.block.piston.PistonHeadBlock; import net.minecraft.world.level.block.piston.PistonMovingBlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.properties.PistonType; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class PistonHeadRenderer implements BlockEntityRenderer { private final BlockRenderDispatcher blockRenderer; - public PistonHeadRenderer(BlockEntityRendererProvider.Context context) { + public PistonHeadRenderer(Context context) { this.blockRenderer = context.getBlockRenderDispatcher(); } - public void render(PistonMovingBlockEntity pistonMovingBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(PistonMovingBlockEntity pistonMovingBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { Level level = pistonMovingBlockEntity.getLevel(); if (level != null) { BlockPos blockPos = pistonMovingBlockEntity.getBlockPos().relative(pistonMovingBlockEntity.getMovementDirection().getOpposite()); @@ -69,11 +73,8 @@ public class PistonHeadRenderer implements BlockEntityRenderer list = this.blockRenderer.getBlockModel(state).collectParts(RandomSource.create(state.getSeed(pos))); + this.blockRenderer.getModelRenderer().tesselateBlock(level, list, state, pos, poseStack, vertexConsumer, extended, packedOverlay); } @Override diff --git a/net/minecraft/client/renderer/blockentity/ShulkerBoxRenderer.java b/net/minecraft/client/renderer/blockentity/ShulkerBoxRenderer.java index 20513237..e00f0acd 100644 --- a/net/minecraft/client/renderer/blockentity/ShulkerBoxRenderer.java +++ b/net/minecraft/client/renderer/blockentity/ShulkerBoxRenderer.java @@ -11,17 +11,19 @@ import net.minecraft.client.model.geom.ModelPart; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.Sheets; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.resources.model.Material; import net.minecraft.core.Direction; import net.minecraft.world.item.DyeColor; import net.minecraft.world.level.block.ShulkerBoxBlock; import net.minecraft.world.level.block.entity.ShulkerBoxBlockEntity; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class ShulkerBoxRenderer implements BlockEntityRenderer { private final ShulkerBoxRenderer.ShulkerBoxModel model; - public ShulkerBoxRenderer(BlockEntityRendererProvider.Context context) { + public ShulkerBoxRenderer(Context context) { this(context.getModelSet()); } @@ -29,7 +31,7 @@ public class ShulkerBoxRenderer implements BlockEntityRenderer signModels; - public SignRenderer(BlockEntityRendererProvider.Context context) { + public SignRenderer(Context context) { super(context); this.signModels = (Map)WoodType.values() .collect( diff --git a/net/minecraft/client/renderer/blockentity/SkullBlockRenderer.java b/net/minecraft/client/renderer/blockentity/SkullBlockRenderer.java index ae1ad447..dd66f35f 100644 --- a/net/minecraft/client/renderer/blockentity/SkullBlockRenderer.java +++ b/net/minecraft/client/renderer/blockentity/SkullBlockRenderer.java @@ -17,6 +17,7 @@ import net.minecraft.client.model.geom.EntityModelSet; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.client.resources.DefaultPlayerSkin; import net.minecraft.core.Direction; @@ -25,29 +26,28 @@ import net.minecraft.world.item.component.ResolvableProfile; import net.minecraft.world.level.block.AbstractSkullBlock; import net.minecraft.world.level.block.SkullBlock; import net.minecraft.world.level.block.WallSkullBlock; -import net.minecraft.world.level.block.SkullBlock.Type; -import net.minecraft.world.level.block.SkullBlock.Types; import net.minecraft.world.level.block.entity.SkullBlockEntity; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.properties.RotationSegment; +import net.minecraft.world.phys.Vec3; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class SkullBlockRenderer implements BlockEntityRenderer { - private final Function modelByType; - private static final Map SKIN_BY_TYPE = Util.make(Maps.newHashMap(), hashMap -> { - hashMap.put(Types.SKELETON, ResourceLocation.withDefaultNamespace("textures/entity/skeleton/skeleton.png")); - hashMap.put(Types.WITHER_SKELETON, ResourceLocation.withDefaultNamespace("textures/entity/skeleton/wither_skeleton.png")); - hashMap.put(Types.ZOMBIE, ResourceLocation.withDefaultNamespace("textures/entity/zombie/zombie.png")); - hashMap.put(Types.CREEPER, ResourceLocation.withDefaultNamespace("textures/entity/creeper/creeper.png")); - hashMap.put(Types.DRAGON, ResourceLocation.withDefaultNamespace("textures/entity/enderdragon/dragon.png")); - hashMap.put(Types.PIGLIN, ResourceLocation.withDefaultNamespace("textures/entity/piglin/piglin.png")); - hashMap.put(Types.PLAYER, DefaultPlayerSkin.getDefaultTexture()); + private final Function modelByType; + private static final Map SKIN_BY_TYPE = Util.make(Maps.newHashMap(), hashMap -> { + hashMap.put(SkullBlock.Types.SKELETON, ResourceLocation.withDefaultNamespace("textures/entity/skeleton/skeleton.png")); + hashMap.put(SkullBlock.Types.WITHER_SKELETON, ResourceLocation.withDefaultNamespace("textures/entity/skeleton/wither_skeleton.png")); + hashMap.put(SkullBlock.Types.ZOMBIE, ResourceLocation.withDefaultNamespace("textures/entity/zombie/zombie.png")); + hashMap.put(SkullBlock.Types.CREEPER, ResourceLocation.withDefaultNamespace("textures/entity/creeper/creeper.png")); + hashMap.put(SkullBlock.Types.DRAGON, ResourceLocation.withDefaultNamespace("textures/entity/enderdragon/dragon.png")); + hashMap.put(SkullBlock.Types.PIGLIN, ResourceLocation.withDefaultNamespace("textures/entity/piglin/piglin.png")); + hashMap.put(SkullBlock.Types.PLAYER, DefaultPlayerSkin.getDefaultTexture()); }); @Nullable - public static SkullModelBase createModel(EntityModelSet modelSet, Type type) { - if (type instanceof Types types) { + public static SkullModelBase createModel(EntityModelSet modelSet, SkullBlock.Type type) { + if (type instanceof SkullBlock.Types types) { return (SkullModelBase)(switch (types) { case SKELETON -> new SkullModel(modelSet.bakeLayer(ModelLayers.SKELETON_SKULL)); case WITHER_SKELETON -> new SkullModel(modelSet.bakeLayer(ModelLayers.WITHER_SKELETON_SKULL)); @@ -62,19 +62,19 @@ public class SkullBlockRenderer implements BlockEntityRenderer } } - public SkullBlockRenderer(BlockEntityRendererProvider.Context context) { + public SkullBlockRenderer(Context context) { EntityModelSet entityModelSet = context.getModelSet(); - this.modelByType = Util.memoize((Function)(type -> createModel(entityModelSet, type))); + this.modelByType = Util.memoize((Function)(type -> createModel(entityModelSet, type))); } - public void render(SkullBlockEntity skullBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(SkullBlockEntity skullBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { float g = skullBlockEntity.getAnimation(f); BlockState blockState = skullBlockEntity.getBlockState(); boolean bl = blockState.getBlock() instanceof WallSkullBlock; Direction direction = bl ? blockState.getValue(WallSkullBlock.FACING) : null; int k = bl ? RotationSegment.convertToSegment(direction.getOpposite()) : (Integer)blockState.getValue(SkullBlock.ROTATION); float h = RotationSegment.convertToDegrees(k); - Type type = ((AbstractSkullBlock)blockState.getBlock()).getType(); + SkullBlock.Type type = ((AbstractSkullBlock)blockState.getBlock()).getType(); SkullModelBase skullModelBase = (SkullModelBase)this.modelByType.apply(type); RenderType renderType = getRenderType(type, skullBlockEntity.getOwnerProfile()); renderSkull(direction, h, g, poseStack, multiBufferSource, i, skullModelBase, renderType); @@ -105,12 +105,12 @@ public class SkullBlockRenderer implements BlockEntityRenderer poseStack.popPose(); } - public static RenderType getRenderType(Type type, @Nullable ResolvableProfile profile) { + public static RenderType getRenderType(SkullBlock.Type type, @Nullable ResolvableProfile profile) { return getRenderType(type, profile, null); } - public static RenderType getRenderType(Type type, @Nullable ResolvableProfile profile, @Nullable ResourceLocation textureOverride) { - return type == Types.PLAYER && profile != null + public static RenderType getRenderType(SkullBlock.Type type, @Nullable ResolvableProfile profile, @Nullable ResourceLocation textureOverride) { + return type == SkullBlock.Types.PLAYER && profile != null ? RenderType.entityTranslucent( textureOverride != null ? textureOverride : Minecraft.getInstance().getSkinManager().getInsecureSkin(profile.gameProfile()).texture() ) diff --git a/net/minecraft/client/renderer/blockentity/SpawnerRenderer.java b/net/minecraft/client/renderer/blockentity/SpawnerRenderer.java index 49633b63..006099ac 100644 --- a/net/minecraft/client/renderer/blockentity/SpawnerRenderer.java +++ b/net/minecraft/client/renderer/blockentity/SpawnerRenderer.java @@ -5,22 +5,24 @@ import com.mojang.math.Axis; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.entity.EntityRenderDispatcher; import net.minecraft.util.Mth; import net.minecraft.world.entity.Entity; import net.minecraft.world.level.BaseSpawner; import net.minecraft.world.level.Level; import net.minecraft.world.level.block.entity.SpawnerBlockEntity; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class SpawnerRenderer implements BlockEntityRenderer { private final EntityRenderDispatcher entityRenderer; - public SpawnerRenderer(BlockEntityRendererProvider.Context context) { + public SpawnerRenderer(Context context) { this.entityRenderer = context.getEntityRenderer(); } - public void render(SpawnerBlockEntity spawnerBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(SpawnerBlockEntity spawnerBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { Level level = spawnerBlockEntity.getLevel(); if (level != null) { BaseSpawner baseSpawner = spawnerBlockEntity.getSpawner(); diff --git a/net/minecraft/client/renderer/blockentity/StructureBlockRenderer.java b/net/minecraft/client/renderer/blockentity/StructureBlockRenderer.java deleted file mode 100644 index 06742e98..00000000 --- a/net/minecraft/client/renderer/blockentity/StructureBlockRenderer.java +++ /dev/null @@ -1,168 +0,0 @@ -package net.minecraft.client.renderer.blockentity; - -import com.mojang.blaze3d.vertex.PoseStack; -import com.mojang.blaze3d.vertex.VertexConsumer; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.Minecraft; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.RenderType; -import net.minecraft.client.renderer.ShapeRenderer; -import net.minecraft.core.BlockPos; -import net.minecraft.core.Vec3i; -import net.minecraft.gametest.framework.StructureUtils; -import net.minecraft.world.level.BlockGetter; -import net.minecraft.world.level.block.Blocks; -import net.minecraft.world.level.block.entity.StructureBlockEntity; -import net.minecraft.world.level.block.state.BlockState; -import net.minecraft.world.level.block.state.properties.StructureMode; -import net.minecraft.world.phys.shapes.BitSetDiscreteVoxelShape; -import net.minecraft.world.phys.shapes.DiscreteVoxelShape; - -@Environment(EnvType.CLIENT) -public class StructureBlockRenderer implements BlockEntityRenderer { - public StructureBlockRenderer(BlockEntityRendererProvider.Context context) { - } - - public void render(StructureBlockEntity structureBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { - if (Minecraft.getInstance().player.canUseGameMasterBlocks() || Minecraft.getInstance().player.isSpectator()) { - BlockPos blockPos = structureBlockEntity.getStructurePos(); - Vec3i vec3i = structureBlockEntity.getStructureSize(); - if (vec3i.getX() >= 1 && vec3i.getY() >= 1 && vec3i.getZ() >= 1) { - if (structureBlockEntity.getMode() == StructureMode.SAVE || structureBlockEntity.getMode() == StructureMode.LOAD) { - double d = blockPos.getX(); - double e = blockPos.getZ(); - double g = blockPos.getY(); - double h = g + vec3i.getY(); - double k; - double l; - switch (structureBlockEntity.getMirror()) { - case LEFT_RIGHT: - k = vec3i.getX(); - l = -vec3i.getZ(); - break; - case FRONT_BACK: - k = -vec3i.getX(); - l = vec3i.getZ(); - break; - default: - k = vec3i.getX(); - l = vec3i.getZ(); - } - - double m; - double n; - double o; - double p; - switch (structureBlockEntity.getRotation()) { - case CLOCKWISE_90: - m = l < 0.0 ? d : d + 1.0; - n = k < 0.0 ? e + 1.0 : e; - o = m - l; - p = n + k; - break; - case CLOCKWISE_180: - m = k < 0.0 ? d : d + 1.0; - n = l < 0.0 ? e : e + 1.0; - o = m - k; - p = n - l; - break; - case COUNTERCLOCKWISE_90: - m = l < 0.0 ? d + 1.0 : d; - n = k < 0.0 ? e : e + 1.0; - o = m + l; - p = n - k; - break; - default: - m = k < 0.0 ? d + 1.0 : d; - n = l < 0.0 ? e + 1.0 : e; - o = m + k; - p = n + l; - } - - float q = 1.0F; - float r = 0.9F; - float s = 0.5F; - if (structureBlockEntity.getMode() == StructureMode.SAVE || structureBlockEntity.getShowBoundingBox()) { - VertexConsumer vertexConsumer = multiBufferSource.getBuffer(RenderType.lines()); - ShapeRenderer.renderLineBox(poseStack, vertexConsumer, m, g, n, o, h, p, 0.9F, 0.9F, 0.9F, 1.0F, 0.5F, 0.5F, 0.5F); - } - - if (structureBlockEntity.getMode() == StructureMode.SAVE && structureBlockEntity.getShowAir()) { - this.renderInvisibleBlocks(structureBlockEntity, multiBufferSource, poseStack); - } - } - } - } - } - - private void renderInvisibleBlocks(StructureBlockEntity blockEntity, MultiBufferSource bufferSource, PoseStack poseStack) { - BlockGetter blockGetter = blockEntity.getLevel(); - VertexConsumer vertexConsumer = bufferSource.getBuffer(RenderType.lines()); - BlockPos blockPos = blockEntity.getBlockPos(); - BlockPos blockPos2 = StructureUtils.getStructureOrigin(blockEntity); - - for (BlockPos blockPos3 : BlockPos.betweenClosed(blockPos2, blockPos2.offset(blockEntity.getStructureSize()).offset(-1, -1, -1))) { - BlockState blockState = blockGetter.getBlockState(blockPos3); - boolean bl = blockState.isAir(); - boolean bl2 = blockState.is(Blocks.STRUCTURE_VOID); - boolean bl3 = blockState.is(Blocks.BARRIER); - boolean bl4 = blockState.is(Blocks.LIGHT); - boolean bl5 = bl2 || bl3 || bl4; - if (bl || bl5) { - float f = bl ? 0.05F : 0.0F; - double d = blockPos3.getX() - blockPos.getX() + 0.45F - f; - double e = blockPos3.getY() - blockPos.getY() + 0.45F - f; - double g = blockPos3.getZ() - blockPos.getZ() + 0.45F - f; - double h = blockPos3.getX() - blockPos.getX() + 0.55F + f; - double i = blockPos3.getY() - blockPos.getY() + 0.55F + f; - double j = blockPos3.getZ() - blockPos.getZ() + 0.55F + f; - if (bl) { - ShapeRenderer.renderLineBox(poseStack, vertexConsumer, d, e, g, h, i, j, 0.5F, 0.5F, 1.0F, 1.0F, 0.5F, 0.5F, 1.0F); - } else if (bl2) { - ShapeRenderer.renderLineBox(poseStack, vertexConsumer, d, e, g, h, i, j, 1.0F, 0.75F, 0.75F, 1.0F, 1.0F, 0.75F, 0.75F); - } else if (bl3) { - ShapeRenderer.renderLineBox(poseStack, vertexConsumer, d, e, g, h, i, j, 1.0F, 0.0F, 0.0F, 1.0F, 1.0F, 0.0F, 0.0F); - } else if (bl4) { - ShapeRenderer.renderLineBox(poseStack, vertexConsumer, d, e, g, h, i, j, 1.0F, 1.0F, 0.0F, 1.0F, 1.0F, 1.0F, 0.0F); - } - } - } - } - - private void renderStructureVoids(StructureBlockEntity blockEntity, VertexConsumer buffer, PoseStack poseStack) { - BlockGetter blockGetter = blockEntity.getLevel(); - if (blockGetter != null) { - BlockPos blockPos = blockEntity.getBlockPos(); - BlockPos blockPos2 = StructureUtils.getStructureOrigin(blockEntity); - Vec3i vec3i = blockEntity.getStructureSize(); - DiscreteVoxelShape discreteVoxelShape = new BitSetDiscreteVoxelShape(vec3i.getX(), vec3i.getY(), vec3i.getZ()); - - for (BlockPos blockPos3 : BlockPos.betweenClosed(blockPos2, blockPos2.offset(vec3i).offset(-1, -1, -1))) { - if (blockGetter.getBlockState(blockPos3).is(Blocks.STRUCTURE_VOID)) { - discreteVoxelShape.fill(blockPos3.getX() - blockPos2.getX(), blockPos3.getY() - blockPos2.getY(), blockPos3.getZ() - blockPos2.getZ()); - } - } - - discreteVoxelShape.forAllFaces((direction, i, j, k) -> { - float f = 0.48F; - float g = i + blockPos2.getX() - blockPos.getX() + 0.5F - 0.48F; - float h = j + blockPos2.getY() - blockPos.getY() + 0.5F - 0.48F; - float l = k + blockPos2.getZ() - blockPos.getZ() + 0.5F - 0.48F; - float m = i + blockPos2.getX() - blockPos.getX() + 0.5F + 0.48F; - float n = j + blockPos2.getY() - blockPos.getY() + 0.5F + 0.48F; - float o = k + blockPos2.getZ() - blockPos.getZ() + 0.5F + 0.48F; - ShapeRenderer.renderFace(poseStack, buffer, direction, g, h, l, m, n, o, 0.75F, 0.75F, 1.0F, 0.2F); - }); - } - } - - public boolean shouldRenderOffScreen(StructureBlockEntity structureBlockEntity) { - return true; - } - - @Override - public int getViewDistance() { - return 96; - } -} diff --git a/net/minecraft/client/renderer/blockentity/TestInstanceRenderer.java b/net/minecraft/client/renderer/blockentity/TestInstanceRenderer.java new file mode 100644 index 00000000..1c7d3c75 --- /dev/null +++ b/net/minecraft/client/renderer/blockentity/TestInstanceRenderer.java @@ -0,0 +1,38 @@ +package net.minecraft.client.renderer.blockentity; + +import com.mojang.blaze3d.vertex.PoseStack; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; +import net.minecraft.world.level.block.entity.TestInstanceBlockEntity; +import net.minecraft.world.phys.Vec3; + +@Environment(EnvType.CLIENT) +public class TestInstanceRenderer implements BlockEntityRenderer { + private final BeaconRenderer beacon; + private final BlockEntityWithBoundingBoxRenderer box; + + public TestInstanceRenderer(Context context) { + this.beacon = new BeaconRenderer<>(context); + this.box = new BlockEntityWithBoundingBoxRenderer<>(context); + } + + public void render(TestInstanceBlockEntity testInstanceBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { + this.beacon.render(testInstanceBlockEntity, f, poseStack, multiBufferSource, i, j, vec3); + this.box.render(testInstanceBlockEntity, f, poseStack, multiBufferSource, i, j, vec3); + } + + public boolean shouldRenderOffScreen(TestInstanceBlockEntity testInstanceBlockEntity) { + return this.beacon.shouldRenderOffScreen(testInstanceBlockEntity) || this.box.shouldRenderOffScreen(testInstanceBlockEntity); + } + + @Override + public int getViewDistance() { + return Math.max(this.beacon.getViewDistance(), this.box.getViewDistance()); + } + + public boolean shouldRender(TestInstanceBlockEntity testInstanceBlockEntity, Vec3 vec3) { + return this.beacon.shouldRender(testInstanceBlockEntity, vec3) || this.box.shouldRender(testInstanceBlockEntity, vec3); + } +} diff --git a/net/minecraft/client/renderer/blockentity/TheEndGatewayRenderer.java b/net/minecraft/client/renderer/blockentity/TheEndGatewayRenderer.java index d55b16d1..30fd116c 100644 --- a/net/minecraft/client/renderer/blockentity/TheEndGatewayRenderer.java +++ b/net/minecraft/client/renderer/blockentity/TheEndGatewayRenderer.java @@ -5,20 +5,24 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.Mth; import net.minecraft.world.item.DyeColor; import net.minecraft.world.level.block.entity.TheEndGatewayBlockEntity; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class TheEndGatewayRenderer extends TheEndPortalRenderer { private static final ResourceLocation BEAM_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/end_gateway_beam.png"); - public TheEndGatewayRenderer(BlockEntityRendererProvider.Context context) { + public TheEndGatewayRenderer(Context context) { super(context); } - public void render(TheEndGatewayBlockEntity theEndGatewayBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render( + TheEndGatewayBlockEntity theEndGatewayBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3 + ) { if (theEndGatewayBlockEntity.isSpawning() || theEndGatewayBlockEntity.isCoolingDown()) { float g = theEndGatewayBlockEntity.isSpawning() ? theEndGatewayBlockEntity.getSpawnPercent(f) : theEndGatewayBlockEntity.getCooldownPercent(f); double d = theEndGatewayBlockEntity.isSpawning() ? theEndGatewayBlockEntity.getLevel().getMaxY() : 50.0; @@ -29,7 +33,7 @@ public class TheEndGatewayRenderer extends TheEndPortalRenderer implements public static final ResourceLocation END_SKY_LOCATION = ResourceLocation.withDefaultNamespace("textures/environment/end_sky.png"); public static final ResourceLocation END_PORTAL_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/end_portal.png"); - public TheEndPortalRenderer(BlockEntityRendererProvider.Context context) { + public TheEndPortalRenderer(Context context) { } - public void render(T theEndPortalBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(T theEndPortalBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { Matrix4f matrix4f = poseStack.last().pose(); this.renderCube(theEndPortalBlockEntity, matrix4f, multiBufferSource.getBuffer(this.renderType())); } diff --git a/net/minecraft/client/renderer/blockentity/TrialSpawnerRenderer.java b/net/minecraft/client/renderer/blockentity/TrialSpawnerRenderer.java index 6f018e94..88df0d69 100644 --- a/net/minecraft/client/renderer/blockentity/TrialSpawnerRenderer.java +++ b/net/minecraft/client/renderer/blockentity/TrialSpawnerRenderer.java @@ -4,22 +4,24 @@ import com.mojang.blaze3d.vertex.PoseStack; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.entity.EntityRenderDispatcher; import net.minecraft.world.entity.Entity; import net.minecraft.world.level.Level; import net.minecraft.world.level.block.entity.TrialSpawnerBlockEntity; import net.minecraft.world.level.block.entity.trialspawner.TrialSpawner; import net.minecraft.world.level.block.entity.trialspawner.TrialSpawnerData; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class TrialSpawnerRenderer implements BlockEntityRenderer { private final EntityRenderDispatcher entityRenderer; - public TrialSpawnerRenderer(BlockEntityRendererProvider.Context context) { + public TrialSpawnerRenderer(Context context) { this.entityRenderer = context.getEntityRenderer(); } - public void render(TrialSpawnerBlockEntity trialSpawnerBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(TrialSpawnerBlockEntity trialSpawnerBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { Level level = trialSpawnerBlockEntity.getLevel(); if (level != null) { TrialSpawner trialSpawner = trialSpawnerBlockEntity.getTrialSpawner(); diff --git a/net/minecraft/client/renderer/blockentity/VaultRenderer.java b/net/minecraft/client/renderer/blockentity/VaultRenderer.java index 2e3b2b95..d044b32e 100644 --- a/net/minecraft/client/renderer/blockentity/VaultRenderer.java +++ b/net/minecraft/client/renderer/blockentity/VaultRenderer.java @@ -5,6 +5,7 @@ import com.mojang.math.Axis; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider.Context; import net.minecraft.client.renderer.entity.ItemEntityRenderer; import net.minecraft.client.renderer.entity.state.ItemClusterRenderState; import net.minecraft.client.renderer.item.ItemModelResolver; @@ -15,6 +16,7 @@ import net.minecraft.world.item.ItemStack; import net.minecraft.world.level.Level; import net.minecraft.world.level.block.entity.vault.VaultBlockEntity; import net.minecraft.world.level.block.entity.vault.VaultClientData; +import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public class VaultRenderer implements BlockEntityRenderer { @@ -22,17 +24,17 @@ public class VaultRenderer implements BlockEntityRenderer { private final RandomSource random = RandomSource.create(); private final ItemClusterRenderState renderState = new ItemClusterRenderState(); - public VaultRenderer(BlockEntityRendererProvider.Context context) { + public VaultRenderer(Context context) { this.itemModelResolver = context.getItemModelResolver(); } - public void render(VaultBlockEntity vaultBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j) { + public void render(VaultBlockEntity vaultBlockEntity, float f, PoseStack poseStack, MultiBufferSource multiBufferSource, int i, int j, Vec3 vec3) { if (VaultBlockEntity.Client.shouldDisplayActiveEffects(vaultBlockEntity.getSharedData())) { Level level = vaultBlockEntity.getLevel(); if (level != null) { ItemStack itemStack = vaultBlockEntity.getSharedData().getDisplayItem(); if (!itemStack.isEmpty()) { - this.itemModelResolver.updateForTopItem(this.renderState.item, itemStack, ItemDisplayContext.GROUND, false, level, null, 0); + this.itemModelResolver.updateForTopItem(this.renderState.item, itemStack, ItemDisplayContext.GROUND, level, null, 0); this.renderState.count = ItemClusterRenderState.getRenderedAmount(itemStack.getCount()); this.renderState.seed = ItemClusterRenderState.getSeedForItemStack(itemStack); VaultClientData vaultClientData = vaultBlockEntity.getClientData(); diff --git a/net/minecraft/client/renderer/chunk/CompileTaskDynamicQueue.java b/net/minecraft/client/renderer/chunk/CompileTaskDynamicQueue.java index dede17be..848ed50c 100644 --- a/net/minecraft/client/renderer/chunk/CompileTaskDynamicQueue.java +++ b/net/minecraft/client/renderer/chunk/CompileTaskDynamicQueue.java @@ -33,7 +33,7 @@ public class CompileTaskDynamicQueue { if (compileTask.isCancelled.get()) { listIterator.remove(); } else { - double f = compileTask.getOrigin().distToCenterSqr(cameraPosition); + double f = compileTask.getRenderOrigin().distToCenterSqr(cameraPosition); if (!compileTask.isRecompile() && f < d) { d = f; i = k; diff --git a/net/minecraft/client/renderer/chunk/SectionCompiler.java b/net/minecraft/client/renderer/chunk/SectionCompiler.java index ba13a7b0..e69bc9a4 100644 --- a/net/minecraft/client/renderer/chunk/SectionCompiler.java +++ b/net/minecraft/client/renderer/chunk/SectionCompiler.java @@ -8,6 +8,7 @@ import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexFormat; import com.mojang.blaze3d.vertex.VertexSorting; import com.mojang.blaze3d.vertex.MeshData.SortState; +import it.unimi.dsi.fastutil.objects.ObjectArrayList; import it.unimi.dsi.fastutil.objects.Reference2ObjectArrayMap; import java.util.ArrayList; import java.util.List; @@ -20,6 +21,7 @@ import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.SectionBufferBuilderPack; import net.minecraft.client.renderer.block.BlockRenderDispatcher; import net.minecraft.client.renderer.block.ModelBlockRenderer; +import net.minecraft.client.renderer.block.model.BlockModelPart; import net.minecraft.client.renderer.blockentity.BlockEntityRenderDispatcher; import net.minecraft.client.renderer.blockentity.BlockEntityRenderer; import net.minecraft.core.BlockPos; @@ -52,6 +54,7 @@ public class SectionCompiler { ModelBlockRenderer.enableCaching(); Map map = new Reference2ObjectArrayMap<>(RenderType.chunkBufferLayers().size()); RandomSource randomSource = RandomSource.create(); + List list = new ObjectArrayList<>(); for (BlockPos blockPos3 : BlockPos.betweenClosed(blockPos, blockPos2)) { BlockState blockState = region.getBlockState(blockPos3); @@ -76,14 +79,17 @@ public class SectionCompiler { if (blockState.getRenderShape() == RenderShape.MODEL) { RenderType renderType = ItemBlockRenderTypes.getChunkRenderType(blockState); BufferBuilder bufferBuilder = this.getOrBeginLayer(map, sectionBufferBuilderPack, renderType); + randomSource.setSeed(blockState.getSeed(blockPos3)); + this.blockRenderer.getBlockModel(blockState).collectParts(randomSource, list); poseStack.pushPose(); poseStack.translate( (float)SectionPos.sectionRelative(blockPos3.getX()), (float)SectionPos.sectionRelative(blockPos3.getY()), (float)SectionPos.sectionRelative(blockPos3.getZ()) ); - this.blockRenderer.renderBatched(blockState, blockPos3, region, poseStack, bufferBuilder, true, randomSource); + this.blockRenderer.renderBatched(blockState, blockPos3, region, poseStack, bufferBuilder, true, list); poseStack.popPose(); + list.clear(); } } diff --git a/net/minecraft/client/renderer/chunk/SectionRenderDispatcher.java b/net/minecraft/client/renderer/chunk/SectionRenderDispatcher.java index c6983820..b5c2064a 100644 --- a/net/minecraft/client/renderer/chunk/SectionRenderDispatcher.java +++ b/net/minecraft/client/renderer/chunk/SectionRenderDispatcher.java @@ -3,14 +3,19 @@ package net.minecraft.client.renderer.chunk; import com.google.common.collect.Lists; import com.google.common.collect.Queues; import com.google.common.collect.Sets; +import com.mojang.blaze3d.buffers.BufferType; import com.mojang.blaze3d.buffers.BufferUsage; +import com.mojang.blaze3d.buffers.GpuBuffer; +import com.mojang.blaze3d.systems.CommandEncoder; +import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.blaze3d.vertex.MeshData; -import com.mojang.blaze3d.vertex.VertexBuffer; +import com.mojang.blaze3d.vertex.VertexFormat; import com.mojang.blaze3d.vertex.VertexSorting; import com.mojang.blaze3d.vertex.ByteBufferBuilder.Result; import com.mojang.blaze3d.vertex.MeshData.SortState; import it.unimi.dsi.fastutil.objects.ObjectArraySet; import java.util.Collection; +import java.util.HashMap; import java.util.List; import java.util.Locale; import java.util.Map; @@ -19,7 +24,6 @@ import java.util.Queue; import java.util.Set; import java.util.concurrent.CompletableFuture; import java.util.concurrent.atomic.AtomicReference; -import java.util.stream.Collectors; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.CrashReport; @@ -56,11 +60,11 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class SectionRenderDispatcher { private final CompileTaskDynamicQueue compileQueue = new CompileTaskDynamicQueue(); - private final Queue toUpload = Queues.newConcurrentLinkedQueue(); + final Queue toUpload = Queues.newConcurrentLinkedQueue(); final SectionBufferBuilderPack fixedBuffers; private final SectionBufferBuilderPool bufferPool; private volatile int toBatchCount; - private volatile boolean closed; + volatile boolean closed; private final ConsecutiveExecutor consecutiveExecutor; private final TracingExecutor executor; ClientLevel level; @@ -170,34 +174,6 @@ public class SectionRenderDispatcher { } } - public CompletableFuture uploadSectionLayer(MeshData meshData, VertexBuffer vertexBuffer) { - return this.closed ? CompletableFuture.completedFuture(null) : CompletableFuture.runAsync(() -> { - if (vertexBuffer.isInvalid()) { - meshData.close(); - } else { - try (Zone zone = Profiler.get().zone("Upload Section Layer")) { - vertexBuffer.bind(); - vertexBuffer.upload(meshData); - VertexBuffer.unbind(); - } - } - }, this.toUpload::add); - } - - public CompletableFuture uploadSectionIndexBuffer(Result result, VertexBuffer vertexBuffer) { - return this.closed ? CompletableFuture.completedFuture(null) : CompletableFuture.runAsync(() -> { - if (vertexBuffer.isInvalid()) { - result.close(); - } else { - try (Zone zone = Profiler.get().zone("Upload Section Indices")) { - vertexBuffer.bind(); - vertexBuffer.uploadIndexBuffer(result); - VertexBuffer.unbind(); - } - } - }, this.toUpload::add); - } - private void clearBatchQueue() { this.compileQueue.clear(); this.toBatchCount = 0; @@ -251,13 +227,11 @@ public class SectionRenderDispatcher { @Nullable private ResortTransparencyTask lastResortTransparencyTask; private final Set globalBlockEntities = Sets.newHashSet(); - private final Map buffers = (Map)RenderType.chunkBufferLayers() - .stream() - .collect(Collectors.toMap(renderType -> renderType, renderType -> new VertexBuffer(BufferUsage.STATIC_WRITE))); + private final Map buffers = new HashMap(); private AABB bb; private boolean dirty = true; - long sectionNode = SectionPos.asLong(-1, -1, -1); - final BlockPos.MutableBlockPos origin = new BlockPos.MutableBlockPos(-1, -1, -1); + volatile long sectionNode = SectionPos.asLong(-1, -1, -1); + final BlockPos.MutableBlockPos renderOrigin = new BlockPos.MutableBlockPos(-1, -1, -1); private boolean playerChanged; public RenderSection(final int index, final long sectionNode) { @@ -288,8 +262,167 @@ public class SectionRenderDispatcher { return this.bb; } - public VertexBuffer getBuffer(RenderType renderType) { - return (VertexBuffer)this.buffers.get(renderType); + @Nullable + public SectionRenderDispatcher.SectionBuffers getBuffers(RenderType renderType) { + return (SectionRenderDispatcher.SectionBuffers)this.buffers.get(renderType); + } + + public CompletableFuture uploadSectionLayer(RenderType renderType, MeshData meshData) { + if (SectionRenderDispatcher.this.closed) { + meshData.close(); + return CompletableFuture.completedFuture(null); + } else { + return CompletableFuture.runAsync( + () -> { + try (Zone zone = Profiler.get().zone("Upload Section Layer")) { + CommandEncoder commandEncoder = RenderSystem.getDevice().createCommandEncoder(); + if (this.buffers.containsKey(renderType)) { + SectionRenderDispatcher.SectionBuffers sectionBuffers = (SectionRenderDispatcher.SectionBuffers)this.buffers.get(renderType); + if (sectionBuffers.vertexBuffer.size() < meshData.vertexBuffer().remaining()) { + sectionBuffers.vertexBuffer.close(); + sectionBuffers.setVertexBuffer( + RenderSystem.getDevice() + .createBuffer( + () -> "Section vertex buffer - layer: " + + renderType.getName() + + "; cords: " + + SectionPos.x(this.sectionNode) + + ", " + + SectionPos.y(this.sectionNode) + + ", " + + SectionPos.z(this.sectionNode), + BufferType.VERTICES, + BufferUsage.STATIC_WRITE, + meshData.vertexBuffer() + ) + ); + } else if (!sectionBuffers.vertexBuffer.isClosed()) { + commandEncoder.writeToBuffer(sectionBuffers.vertexBuffer, meshData.vertexBuffer(), 0); + } + + if (meshData.indexBuffer() != null) { + if (sectionBuffers.indexBuffer != null && sectionBuffers.indexBuffer.size() >= meshData.indexBuffer().remaining()) { + if (!sectionBuffers.indexBuffer.isClosed()) { + commandEncoder.writeToBuffer(sectionBuffers.indexBuffer, meshData.indexBuffer(), 0); + } + } else { + if (sectionBuffers.indexBuffer != null) { + sectionBuffers.indexBuffer.close(); + } + + sectionBuffers.setIndexBuffer( + RenderSystem.getDevice() + .createBuffer( + () -> "Section index buffer - layer: " + + renderType.getName() + + "; cords: " + + SectionPos.x(this.sectionNode) + + ", " + + SectionPos.y(this.sectionNode) + + ", " + + SectionPos.z(this.sectionNode), + BufferType.INDICES, + BufferUsage.STATIC_WRITE, + meshData.indexBuffer() + ) + ); + } + } else if (sectionBuffers.indexBuffer != null) { + sectionBuffers.indexBuffer.close(); + sectionBuffers.setIndexBuffer(null); + } + + sectionBuffers.setIndexCount(meshData.drawState().indexCount()); + sectionBuffers.setIndexType(meshData.drawState().indexType()); + } else { + GpuBuffer gpuBuffer = RenderSystem.getDevice() + .createBuffer( + () -> "Section vertex buffer - layer: " + + renderType.getName() + + "; cords: " + + SectionPos.x(this.sectionNode) + + ", " + + SectionPos.y(this.sectionNode) + + ", " + + SectionPos.z(this.sectionNode), + BufferType.VERTICES, + BufferUsage.STATIC_WRITE, + meshData.vertexBuffer() + ); + GpuBuffer gpuBuffer2 = meshData.indexBuffer() != null + ? RenderSystem.getDevice() + .createBuffer( + () -> "Section index buffer - layer: " + + renderType.getName() + + "; cords: " + + SectionPos.x(this.sectionNode) + + ", " + + SectionPos.y(this.sectionNode) + + ", " + + SectionPos.z(this.sectionNode), + BufferType.INDICES, + BufferUsage.STATIC_WRITE, + meshData.indexBuffer() + ) + : null; + SectionRenderDispatcher.SectionBuffers sectionBuffers2 = new SectionRenderDispatcher.SectionBuffers( + gpuBuffer, gpuBuffer2, meshData.drawState().indexCount(), meshData.drawState().indexType() + ); + this.buffers.put(renderType, sectionBuffers2); + } + + meshData.close(); + } + }, + SectionRenderDispatcher.this.toUpload::add + ); + } + } + + public CompletableFuture uploadSectionIndexBuffer(Result result, RenderType renderType) { + if (SectionRenderDispatcher.this.closed) { + result.close(); + return CompletableFuture.completedFuture(null); + } else { + return CompletableFuture.runAsync( + () -> { + try (Zone zone = Profiler.get().zone("Upload Section Indices")) { + SectionRenderDispatcher.SectionBuffers sectionBuffers = this.getBuffers(renderType); + if (sectionBuffers != null && !SectionRenderDispatcher.this.closed) { + if (sectionBuffers.indexBuffer == null) { + sectionBuffers.setIndexBuffer( + RenderSystem.getDevice() + .createBuffer( + () -> "Section index buffer - layer: " + + renderType.getName() + + "; cords: " + + SectionPos.x(this.sectionNode) + + ", " + + SectionPos.y(this.sectionNode) + + ", " + + SectionPos.z(this.sectionNode), + BufferType.INDICES, + BufferUsage.STATIC_WRITE, + result.byteBuffer() + ) + ); + } else { + CommandEncoder commandEncoder = RenderSystem.getDevice().createCommandEncoder(); + if (!sectionBuffers.indexBuffer.isClosed()) { + commandEncoder.writeToBuffer(sectionBuffers.indexBuffer, result.byteBuffer(), 0); + } + } + + result.close(); + return; + } + + result.close(); + } + }, + SectionRenderDispatcher.this.toUpload::add + ); + } } public void setSectionNode(long sectionNode) { @@ -298,7 +431,7 @@ public class SectionRenderDispatcher { int i = SectionPos.sectionToBlockCoord(SectionPos.x(sectionNode)); int j = SectionPos.sectionToBlockCoord(SectionPos.y(sectionNode)); int k = SectionPos.sectionToBlockCoord(SectionPos.z(sectionNode)); - this.origin.set(i, j, k); + this.renderOrigin.set(i, j, k); this.bb = new AABB(i, j, k, i + 16, j + 16, k + 16); } @@ -314,20 +447,17 @@ public class SectionRenderDispatcher { return (SectionRenderDispatcher.CompiledSection)this.compiled.get(); } - private void reset() { + public void reset() { this.cancelTasks(); this.compiled.set(SectionRenderDispatcher.CompiledSection.UNCOMPILED); this.pointOfView.set(null); this.dirty = true; + this.buffers.values().forEach(SectionRenderDispatcher.SectionBuffers::close); + this.buffers.clear(); } - public void releaseBuffers() { - this.reset(); - this.buffers.values().forEach(VertexBuffer::close); - } - - public BlockPos getOrigin() { - return this.origin; + public BlockPos getRenderOrigin() { + return this.renderOrigin; } public long getSectionNode() { @@ -419,9 +549,65 @@ public class SectionRenderDispatcher { SectionRenderDispatcher.this.renderer.addRecentlyCompiledSection(this); } - VertexSorting createVertexSorting() { + VertexSorting createVertexSorting(SectionPos sectionPos) { Vec3 vec3 = SectionRenderDispatcher.this.getCameraPosition(); - return VertexSorting.byDistance((float)(vec3.x - this.origin.getX()), (float)(vec3.y - this.origin.getY()), (float)(vec3.z - this.origin.getZ())); + return VertexSorting.byDistance((float)(vec3.x - sectionPos.minBlockX()), (float)(vec3.y - sectionPos.minBlockY()), (float)(vec3.z - sectionPos.minBlockZ())); + } + } + + @Environment(EnvType.CLIENT) + public static final class SectionBuffers implements AutoCloseable { + GpuBuffer vertexBuffer; + @Nullable + GpuBuffer indexBuffer; + private int indexCount; + private VertexFormat.IndexType indexType; + + public SectionBuffers(GpuBuffer vertexBuffer, @Nullable GpuBuffer indexBuffer, int indexCount, VertexFormat.IndexType indexType) { + this.vertexBuffer = vertexBuffer; + this.indexBuffer = indexBuffer; + this.indexCount = indexCount; + this.indexType = indexType; + } + + public GpuBuffer getVertexBuffer() { + return this.vertexBuffer; + } + + @Nullable + public GpuBuffer getIndexBuffer() { + return this.indexBuffer; + } + + public void setIndexBuffer(@Nullable GpuBuffer indexBuffer) { + this.indexBuffer = indexBuffer; + } + + public int getIndexCount() { + return this.indexCount; + } + + public VertexFormat.IndexType getIndexType() { + return this.indexType; + } + + public void setIndexType(VertexFormat.IndexType indexType) { + this.indexType = indexType; + } + + public void setIndexCount(int indexCount) { + this.indexCount = indexCount; + } + + public void setVertexBuffer(GpuBuffer vertexBuffer) { + this.vertexBuffer = vertexBuffer; + } + + public void close() { + this.vertexBuffer.close(); + if (this.indexBuffer != null) { + this.indexBuffer.close(); + } } } diff --git a/net/minecraft/client/renderer/debug/ChunkCullingDebugRenderer.java b/net/minecraft/client/renderer/debug/ChunkCullingDebugRenderer.java index 06690437..e3d1d4fe 100644 --- a/net/minecraft/client/renderer/debug/ChunkCullingDebugRenderer.java +++ b/net/minecraft/client/renderer/debug/ChunkCullingDebugRenderer.java @@ -35,7 +35,7 @@ public class ChunkCullingDebugRenderer implements DebugRenderer.SimpleDebugRende for (SectionRenderDispatcher.RenderSection renderSection : levelRenderer.getVisibleSections()) { SectionOcclusionGraph.Node node = sectionOcclusionGraph.getNode(renderSection); if (node != null) { - BlockPos blockPos = renderSection.getOrigin(); + BlockPos blockPos = renderSection.getRenderOrigin(); poseStack.pushPose(); poseStack.translate(blockPos.getX() - camX, blockPos.getY() - camY, blockPos.getZ() - camZ); Matrix4f matrix4f = poseStack.last().pose(); diff --git a/net/minecraft/client/renderer/debug/DebugRenderer.java b/net/minecraft/client/renderer/debug/DebugRenderer.java index 812d3bfb..48fa5b88 100644 --- a/net/minecraft/client/renderer/debug/DebugRenderer.java +++ b/net/minecraft/client/renderer/debug/DebugRenderer.java @@ -9,6 +9,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.Camera; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.Font; +import net.minecraft.client.gui.Font.DisplayMode; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.ShapeRenderer; @@ -244,9 +245,7 @@ public class DebugRenderer { poseStack.scale(scale, -scale, scale); float g = center ? -font.width(text) / 2.0F : 0.0F; g -= xOffset / scale; - font.drawInBatch( - text, g, 0.0F, color, false, poseStack.last().pose(), bufferSource, transparent ? Font.DisplayMode.SEE_THROUGH : Font.DisplayMode.NORMAL, 0, 15728880 - ); + font.drawInBatch(text, g, 0.0F, color, false, poseStack.last().pose(), bufferSource, transparent ? DisplayMode.SEE_THROUGH : DisplayMode.NORMAL, 0, 15728880); poseStack.popPose(); } } diff --git a/net/minecraft/client/renderer/debug/LightSectionDebugRenderer.java b/net/minecraft/client/renderer/debug/LightSectionDebugRenderer.java index 51782cc9..997ee45b 100644 --- a/net/minecraft/client/renderer/debug/LightSectionDebugRenderer.java +++ b/net/minecraft/client/renderer/debug/LightSectionDebugRenderer.java @@ -13,8 +13,8 @@ import net.minecraft.client.renderer.ShapeRenderer; import net.minecraft.core.Direction; import net.minecraft.core.SectionPos; import net.minecraft.world.level.LightLayer; -import net.minecraft.world.level.lighting.LayerLightSectionStorage; import net.minecraft.world.level.lighting.LevelLightEngine; +import net.minecraft.world.level.lighting.LayerLightSectionStorage.SectionType; import net.minecraft.world.phys.shapes.BitSetDiscreteVoxelShape; import net.minecraft.world.phys.shapes.DiscreteVoxelShape; import org.jetbrains.annotations.Nullable; @@ -119,11 +119,11 @@ public class LightSectionDebugRenderer implements DebugRenderer.SimpleDebugRende for (int k = 0; k < i; k++) { for (int l = 0; l < i; l++) { SectionPos sectionPos = SectionPos.of(pos.x() + l - radius, pos.y() + k - radius, pos.z() + j - radius); - LayerLightSectionStorage.SectionType sectionType = levelLightEngine.getDebugSectionType(lightLayer, sectionPos); - if (sectionType == LayerLightSectionStorage.SectionType.LIGHT_AND_DATA) { + SectionType sectionType = levelLightEngine.getDebugSectionType(lightLayer, sectionPos); + if (sectionType == SectionType.LIGHT_AND_DATA) { this.lightAndBlocksShape.fill(l, k, j); this.lightShape.fill(l, k, j); - } else if (sectionType == LayerLightSectionStorage.SectionType.LIGHT_ONLY) { + } else if (sectionType == SectionType.LIGHT_ONLY) { this.lightShape.fill(l, k, j); } } diff --git a/net/minecraft/client/renderer/debug/SupportBlockRenderer.java b/net/minecraft/client/renderer/debug/SupportBlockRenderer.java index d6b53d68..6925a9d2 100644 --- a/net/minecraft/client/renderer/debug/SupportBlockRenderer.java +++ b/net/minecraft/client/renderer/debug/SupportBlockRenderer.java @@ -88,7 +88,7 @@ public class SupportBlockRenderer implements DebugRenderer.SimpleDebugRenderer { DebugRenderer.renderVoxelShape( poseStack, buffer.getBuffer(RenderType.lines()), - this.minecraft.level.getBlockState(pos).getCollisionShape(this.minecraft.level, pos, CollisionContext.empty()).move(pos.getX(), pos.getY(), pos.getZ()), + this.minecraft.level.getBlockState(pos).getCollisionShape(this.minecraft.level, pos, CollisionContext.empty()).move(pos), -camX, -camY, -camZ, diff --git a/net/minecraft/client/renderer/entity/AbstractBoatRenderer.java b/net/minecraft/client/renderer/entity/AbstractBoatRenderer.java index 737eb87d..e9736bb6 100644 --- a/net/minecraft/client/renderer/entity/AbstractBoatRenderer.java +++ b/net/minecraft/client/renderer/entity/AbstractBoatRenderer.java @@ -8,6 +8,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.EntityModel; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.BoatRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.util.Mth; @@ -16,7 +17,7 @@ import org.joml.Quaternionf; @Environment(EnvType.CLIENT) public abstract class AbstractBoatRenderer extends EntityRenderer { - public AbstractBoatRenderer(EntityRendererProvider.Context context) { + public AbstractBoatRenderer(Context context) { super(context); this.shadowRadius = 0.8F; } @@ -30,7 +31,7 @@ public abstract class AbstractBoatRenderer extends EntityRenderer> extends AgeableMobRenderer { - public AbstractHorseRenderer(EntityRendererProvider.Context context, M adultModel, M babyModel) { + public AbstractHorseRenderer(Context context, M adultModel, M babyModel) { super(context, adultModel, babyModel, 0.75F); } public void extractRenderState(T abstractHorse, S equineRenderState, float f) { super.extractRenderState(abstractHorse, equineRenderState, f); - equineRenderState.isSaddled = abstractHorse.isSaddled(); + equineRenderState.saddle = abstractHorse.getItemBySlot(EquipmentSlot.SADDLE).copy(); equineRenderState.isRidden = abstractHorse.isVehicle(); equineRenderState.eatAnimation = abstractHorse.getEatAnim(f); equineRenderState.standAnimation = abstractHorse.getStandAnim(f); diff --git a/net/minecraft/client/renderer/entity/AbstractMinecartRenderer.java b/net/minecraft/client/renderer/entity/AbstractMinecartRenderer.java index 975930f7..7ac1aa5e 100644 --- a/net/minecraft/client/renderer/entity/AbstractMinecartRenderer.java +++ b/net/minecraft/client/renderer/entity/AbstractMinecartRenderer.java @@ -10,6 +10,7 @@ import net.minecraft.client.model.MinecartModel; import net.minecraft.client.model.geom.ModelLayerLocation; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.block.BlockRenderDispatcher; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.MinecartRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -25,10 +26,11 @@ import net.minecraft.world.phys.Vec3; @Environment(EnvType.CLIENT) public abstract class AbstractMinecartRenderer extends EntityRenderer { private static final ResourceLocation MINECART_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/minecart.png"); + private static final float DISPLAY_BLOCK_SCALE = 0.75F; protected final MinecartModel model; private final BlockRenderDispatcher blockRenderer; - public AbstractMinecartRenderer(EntityRendererProvider.Context context, ModelLayerLocation modelLayer) { + public AbstractMinecartRenderer(Context context, ModelLayerLocation modelLayer) { super(context); this.shadowRadius = 0.7F; this.model = new MinecartModel(context.bakeLayer(modelLayer)); @@ -57,7 +59,6 @@ public abstract class AbstractMinecartRenderer extends EntityRenderer { private final ArrowModel model; - public ArrowRenderer(EntityRendererProvider.Context context) { + public ArrowRenderer(Context context) { super(context); this.model = new ArrowModel(context.bakeLayer(ModelLayers.ARROW)); } diff --git a/net/minecraft/client/renderer/entity/BoatRenderer.java b/net/minecraft/client/renderer/entity/BoatRenderer.java index 09d87415..4069b2dd 100644 --- a/net/minecraft/client/renderer/entity/BoatRenderer.java +++ b/net/minecraft/client/renderer/entity/BoatRenderer.java @@ -12,6 +12,7 @@ import net.minecraft.client.model.geom.ModelLayerLocation; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.BoatRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -22,7 +23,7 @@ public class BoatRenderer extends AbstractBoatRenderer { private final ResourceLocation texture; private final EntityModel model; - public BoatRenderer(EntityRendererProvider.Context context, ModelLayerLocation modelLayer) { + public BoatRenderer(Context context, ModelLayerLocation modelLayer) { super(context); this.texture = modelLayer.model().withPath((UnaryOperator)(string -> "textures/entity/" + string + ".png")); this.waterPatchModel = new Simple(context.bakeLayer(ModelLayers.BOAT_WATER_PATCH), resourceLocation -> RenderType.waterMask()); diff --git a/net/minecraft/client/renderer/entity/CamelRenderer.java b/net/minecraft/client/renderer/entity/CamelRenderer.java index feeb7138..5539cefe 100644 --- a/net/minecraft/client/renderer/entity/CamelRenderer.java +++ b/net/minecraft/client/renderer/entity/CamelRenderer.java @@ -3,17 +3,32 @@ package net.minecraft.client.renderer.entity; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.CamelModel; +import net.minecraft.client.model.CamelSaddleModel; import net.minecraft.client.model.geom.ModelLayers; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; +import net.minecraft.client.renderer.entity.layers.SimpleEquipmentLayer; import net.minecraft.client.renderer.entity.state.CamelRenderState; +import net.minecraft.client.resources.model.EquipmentClientInfo; import net.minecraft.resources.ResourceLocation; +import net.minecraft.world.entity.EquipmentSlot; import net.minecraft.world.entity.animal.camel.Camel; @Environment(EnvType.CLIENT) public class CamelRenderer extends AgeableMobRenderer { private static final ResourceLocation CAMEL_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/camel/camel.png"); - public CamelRenderer(EntityRendererProvider.Context context) { + public CamelRenderer(Context context) { super(context, new CamelModel(context.bakeLayer(ModelLayers.CAMEL)), new CamelModel(context.bakeLayer(ModelLayers.CAMEL_BABY)), 0.7F); + this.addLayer( + new SimpleEquipmentLayer<>( + this, + context.getEquipmentRenderer(), + EquipmentClientInfo.LayerType.CAMEL_SADDLE, + camelRenderState -> camelRenderState.saddle, + new CamelSaddleModel(context.bakeLayer(ModelLayers.CAMEL_SADDLE)), + new CamelSaddleModel(context.bakeLayer(ModelLayers.CAMEL_BABY_SADDLE)) + ) + ); } public ResourceLocation getTextureLocation(CamelRenderState camelRenderState) { @@ -26,7 +41,7 @@ public class CamelRenderer extends AgeableMobRenderer { - public CatRenderer(EntityRendererProvider.Context context) { + public CatRenderer(Context context) { super(context, new CatModel(context.bakeLayer(ModelLayers.CAT)), new CatModel(context.bakeLayer(ModelLayers.CAT_BABY)), 0.4F); this.addLayer(new CatCollarLayer(this, context.getModelSet())); } @@ -29,7 +30,7 @@ public class CatRenderer extends AgeableMobRenderer { - private static final ResourceLocation CHICKEN_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/chicken.png"); +public class ChickenRenderer extends MobRenderer { + private final Map> models; - public ChickenRenderer(EntityRendererProvider.Context context) { - super(context, new ChickenModel(context.bakeLayer(ModelLayers.CHICKEN)), new ChickenModel(context.bakeLayer(ModelLayers.CHICKEN_BABY)), 0.3F); + public ChickenRenderer(Context context) { + super(context, new ChickenModel(context.bakeLayer(ModelLayers.CHICKEN)), 0.3F); + this.models = bakeModels(context); + } + + private static Map> bakeModels(Context context) { + return Maps.newEnumMap( + Map.of( + ChickenVariant.ModelType.NORMAL, + new AdultAndBabyModelPair<>(new ChickenModel(context.bakeLayer(ModelLayers.CHICKEN)), new ChickenModel(context.bakeLayer(ModelLayers.CHICKEN_BABY))), + ChickenVariant.ModelType.COLD, + new AdultAndBabyModelPair<>( + new ColdChickenModel(context.bakeLayer(ModelLayers.COLD_CHICKEN)), new ColdChickenModel(context.bakeLayer(ModelLayers.COLD_CHICKEN_BABY)) + ) + ) + ); + } + + public void render(ChickenRenderState chickenRenderState, PoseStack poseStack, MultiBufferSource multiBufferSource, int i) { + if (chickenRenderState.variant != null) { + this.model = (EntityModel)((AdultAndBabyModelPair)this.models.get(chickenRenderState.variant.modelAndTexture().model())).getModel(chickenRenderState.isBaby); + super.render(chickenRenderState, poseStack, multiBufferSource, i); + } } public ResourceLocation getTextureLocation(ChickenRenderState chickenRenderState) { - return CHICKEN_LOCATION; + return chickenRenderState.variant == null ? MissingTextureAtlasSprite.getLocation() : chickenRenderState.variant.modelAndTexture().asset().texturePath(); } public ChickenRenderState createRenderState() { @@ -29,5 +60,6 @@ public class ChickenRenderer extends AgeableMobRenderer { private static final ResourceLocation COD_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/fish/cod.png"); - public CodRenderer(EntityRendererProvider.Context context) { + public CodRenderer(Context context) { super(context, new CodModel(context.bakeLayer(ModelLayers.COD)), 0.3F); } diff --git a/net/minecraft/client/renderer/entity/CowRenderer.java b/net/minecraft/client/renderer/entity/CowRenderer.java index 9521ff8a..714099d9 100644 --- a/net/minecraft/client/renderer/entity/CowRenderer.java +++ b/net/minecraft/client/renderer/entity/CowRenderer.java @@ -1,31 +1,61 @@ package net.minecraft.client.renderer.entity; +import com.google.common.collect.Maps; +import com.mojang.blaze3d.vertex.PoseStack; +import java.util.Map; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.model.AdultAndBabyModelPair; import net.minecraft.client.model.CowModel; +import net.minecraft.client.model.EntityModel; import net.minecraft.client.model.geom.ModelLayers; -import net.minecraft.client.renderer.entity.state.LivingEntityRenderState; +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; +import net.minecraft.client.renderer.entity.state.CowRenderState; +import net.minecraft.client.renderer.texture.MissingTextureAtlasSprite; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.entity.animal.Cow; +import net.minecraft.world.entity.animal.CowVariant; @Environment(EnvType.CLIENT) -public class CowRenderer extends AgeableMobRenderer { - private static final ResourceLocation COW_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/cow/cow.png"); +public class CowRenderer extends MobRenderer { + private final Map> models; - public CowRenderer(EntityRendererProvider.Context context) { - super(context, new CowModel(context.bakeLayer(ModelLayers.COW)), new CowModel(context.bakeLayer(ModelLayers.COW_BABY)), 0.7F); + public CowRenderer(Context context) { + super(context, new CowModel(context.bakeLayer(ModelLayers.COW)), 0.7F); + this.models = bakeModels(context); } - @Override - public ResourceLocation getTextureLocation(LivingEntityRenderState renderState) { - return COW_LOCATION; + private static Map> bakeModels(Context context) { + return Maps.newEnumMap( + Map.of( + CowVariant.ModelType.NORMAL, + new AdultAndBabyModelPair<>(new CowModel(context.bakeLayer(ModelLayers.COW)), new CowModel(context.bakeLayer(ModelLayers.COW_BABY))), + CowVariant.ModelType.WARM, + new AdultAndBabyModelPair<>(new CowModel(context.bakeLayer(ModelLayers.WARM_COW)), new CowModel(context.bakeLayer(ModelLayers.WARM_COW_BABY))), + CowVariant.ModelType.COLD, + new AdultAndBabyModelPair<>(new CowModel(context.bakeLayer(ModelLayers.COLD_COW)), new CowModel(context.bakeLayer(ModelLayers.COLD_COW_BABY))) + ) + ); } - public LivingEntityRenderState createRenderState() { - return new LivingEntityRenderState(); + public ResourceLocation getTextureLocation(CowRenderState cowRenderState) { + return cowRenderState.variant == null ? MissingTextureAtlasSprite.getLocation() : cowRenderState.variant.modelAndTexture().asset().texturePath(); } - public void extractRenderState(Cow cow, LivingEntityRenderState livingEntityRenderState, float f) { - super.extractRenderState(cow, livingEntityRenderState, f); + public CowRenderState createRenderState() { + return new CowRenderState(); + } + + public void extractRenderState(Cow cow, CowRenderState cowRenderState, float f) { + super.extractRenderState(cow, cowRenderState, f); + cowRenderState.variant = cow.getVariant().value(); + } + + public void render(CowRenderState cowRenderState, PoseStack poseStack, MultiBufferSource multiBufferSource, int i) { + if (cowRenderState.variant != null) { + this.model = (EntityModel)((AdultAndBabyModelPair)this.models.get(cowRenderState.variant.modelAndTexture().model())).getModel(cowRenderState.isBaby); + super.render(cowRenderState, poseStack, multiBufferSource, i); + } } } diff --git a/net/minecraft/client/renderer/entity/DisplayRenderer.java b/net/minecraft/client/renderer/entity/DisplayRenderer.java index 9fc012f4..f681fd16 100644 --- a/net/minecraft/client/renderer/entity/DisplayRenderer.java +++ b/net/minecraft/client/renderer/entity/DisplayRenderer.java @@ -11,10 +11,12 @@ import net.fabricmc.api.Environment; import net.minecraft.client.Camera; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.Font; +import net.minecraft.client.gui.Font.DisplayMode; import net.minecraft.client.renderer.LightTexture; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.block.BlockRenderDispatcher; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.BlockDisplayEntityRenderState; import net.minecraft.client.renderer.entity.state.DisplayEntityRenderState; import net.minecraft.client.renderer.entity.state.ItemDisplayEntityRenderState; @@ -39,7 +41,7 @@ import org.joml.Quaternionf; public abstract class DisplayRenderer extends EntityRenderer { private final EntityRenderDispatcher entityRenderDispatcher; - protected DisplayRenderer(EntityRendererProvider.Context context) { + protected DisplayRenderer(Context context) { super(context); this.entityRenderDispatcher = context.getEntityRenderDispatcher(); } @@ -134,7 +136,7 @@ public abstract class DisplayRenderer { private final BlockRenderDispatcher blockRenderer; - protected BlockDisplayRenderer(EntityRendererProvider.Context context) { + protected BlockDisplayRenderer(Context context) { super(context); this.blockRenderer = context.getBlockRenderDispatcher(); } @@ -158,7 +160,7 @@ public abstract class DisplayRenderer { private final ItemModelResolver itemModelResolver; - protected ItemDisplayRenderer(EntityRendererProvider.Context context) { + protected ItemDisplayRenderer(Context context) { super(context); this.itemModelResolver = context.getItemModelResolver(); } @@ -189,7 +191,7 @@ public abstract class DisplayRenderer { private final Font font; - protected TextDisplayRenderer(EntityRendererProvider.Context context) { + protected TextDisplayRenderer(Context context) { super(context); this.font = context.getFont(); } @@ -261,16 +263,7 @@ public abstract class DisplayRenderer extends AbstractHorseRenderer { - public static final ResourceLocation DONKEY_TEXTURE = ResourceLocation.withDefaultNamespace("textures/entity/horse/donkey.png"); - public static final ResourceLocation MULE_TEXTURE = ResourceLocation.withDefaultNamespace("textures/entity/horse/mule.png"); private final ResourceLocation texture; - public DonkeyRenderer(EntityRendererProvider.Context context, ModelLayerLocation adultModel, ModelLayerLocation babyModel, boolean isMule) { - super(context, new DonkeyModel(context.bakeLayer(adultModel)), new DonkeyModel(context.bakeLayer(babyModel))); - this.texture = isMule ? MULE_TEXTURE : DONKEY_TEXTURE; + public DonkeyRenderer(Context context, DonkeyRenderer.Type type) { + super(context, new DonkeyModel(context.bakeLayer(type.model)), new DonkeyModel(context.bakeLayer(type.babyModel))); + this.texture = type.texture; + this.addLayer( + new SimpleEquipmentLayer<>( + this, + context.getEquipmentRenderer(), + type.saddleLayer, + donkeyRenderState -> donkeyRenderState.saddle, + new EquineSaddleModel(context.bakeLayer(type.saddleModel)), + new EquineSaddleModel(context.bakeLayer(type.babySaddleModel)) + ) + ); } public ResourceLocation getTextureLocation(DonkeyRenderState donkeyRenderState) { @@ -31,4 +44,47 @@ public class DonkeyRenderer extends AbstractHors super.extractRenderState(abstractChestedHorse, donkeyRenderState, f); donkeyRenderState.hasChest = abstractChestedHorse.hasChest(); } + + @Environment(EnvType.CLIENT) + public static enum Type { + DONKEY( + ResourceLocation.withDefaultNamespace("textures/entity/horse/donkey.png"), + ModelLayers.DONKEY, + ModelLayers.DONKEY_BABY, + EquipmentClientInfo.LayerType.DONKEY_SADDLE, + ModelLayers.DONKEY_SADDLE, + ModelLayers.DONKEY_BABY_SADDLE + ), + MULE( + ResourceLocation.withDefaultNamespace("textures/entity/horse/mule.png"), + ModelLayers.MULE, + ModelLayers.MULE_BABY, + EquipmentClientInfo.LayerType.MULE_SADDLE, + ModelLayers.MULE_SADDLE, + ModelLayers.MULE_BABY_SADDLE + ); + + final ResourceLocation texture; + final ModelLayerLocation model; + final ModelLayerLocation babyModel; + final EquipmentClientInfo.LayerType saddleLayer; + final ModelLayerLocation saddleModel; + final ModelLayerLocation babySaddleModel; + + private Type( + final ResourceLocation texture, + final ModelLayerLocation model, + final ModelLayerLocation babyModel, + final EquipmentClientInfo.LayerType saddleLayer, + final ModelLayerLocation saddleModel, + final ModelLayerLocation babySaddleModel + ) { + this.texture = texture; + this.model = model; + this.babyModel = babyModel; + this.saddleLayer = saddleLayer; + this.saddleModel = saddleModel; + this.babySaddleModel = babySaddleModel; + } + } } diff --git a/net/minecraft/client/renderer/entity/DragonFireballRenderer.java b/net/minecraft/client/renderer/entity/DragonFireballRenderer.java index 61a6bafd..bdfa8466 100644 --- a/net/minecraft/client/renderer/entity/DragonFireballRenderer.java +++ b/net/minecraft/client/renderer/entity/DragonFireballRenderer.java @@ -2,11 +2,11 @@ package net.minecraft.client.renderer.entity; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; -import com.mojang.blaze3d.vertex.PoseStack.Pose; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.EntityRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.core.BlockPos; @@ -18,7 +18,7 @@ public class DragonFireballRenderer extends EntityRenderer { private static final ResourceLocation DROWNED_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/zombie/drowned.png"); - public DrownedRenderer(EntityRendererProvider.Context context) { + public DrownedRenderer(Context context) { super( context, new DrownedModel(context.bakeLayer(ModelLayers.DROWNED)), @@ -52,10 +53,8 @@ public class DrownedRenderer extends AbstractZombieRenderer builder, float f) { + super.extractAdditionalHitboxes(enderDragon, builder, f); + double d = -Mth.lerp((double)f, enderDragon.xOld, enderDragon.getX()); + double e = -Mth.lerp((double)f, enderDragon.yOld, enderDragon.getY()); + double g = -Mth.lerp((double)f, enderDragon.zOld, enderDragon.getZ()); + + for (EnderDragonPart enderDragonPart : enderDragon.getSubEntities()) { + AABB aABB = enderDragonPart.getBoundingBox(); + HitboxRenderState hitboxRenderState = new HitboxRenderState( + aABB.minX - enderDragonPart.getX(), + aABB.minY - enderDragonPart.getY(), + aABB.minZ - enderDragonPart.getZ(), + aABB.maxX - enderDragonPart.getX(), + aABB.maxY - enderDragonPart.getY(), + aABB.maxZ - enderDragonPart.getZ(), + (float)(d + Mth.lerp((double)f, enderDragonPart.xOld, enderDragonPart.getX())), + (float)(e + Mth.lerp((double)f, enderDragonPart.yOld, enderDragonPart.getY())), + (float)(g + Mth.lerp((double)f, enderDragonPart.zOld, enderDragonPart.getZ())), + 0.25F, + 1.0F, + 0.0F + ); + builder.add(hitboxRenderState); + } + } + protected boolean affectedByCulling(EnderDragon enderDragon) { return false; } diff --git a/net/minecraft/client/renderer/entity/EntityRenderDispatcher.java b/net/minecraft/client/renderer/entity/EntityRenderDispatcher.java index 5d71365c..7fa7578e 100644 --- a/net/minecraft/client/renderer/entity/EntityRenderDispatcher.java +++ b/net/minecraft/client/renderer/entity/EntityRenderDispatcher.java @@ -3,7 +3,6 @@ package net.minecraft.client.renderer.entity; import com.google.common.collect.ImmutableMap; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; -import com.mojang.blaze3d.vertex.PoseStack.Pose; import java.util.Map; import java.util.function.Supplier; import net.fabricmc.api.EnvType; @@ -27,7 +26,12 @@ import net.minecraft.client.renderer.Sheets; import net.minecraft.client.renderer.block.BlockRenderDispatcher; import net.minecraft.client.renderer.culling.Frustum; import net.minecraft.client.renderer.debug.DebugRenderer; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.EntityRenderState; +import net.minecraft.client.renderer.entity.state.HitboxRenderState; +import net.minecraft.client.renderer.entity.state.HitboxesRenderState; +import net.minecraft.client.renderer.entity.state.PlayerRenderState; +import net.minecraft.client.renderer.entity.state.ServerHitboxesRenderState; import net.minecraft.client.renderer.item.ItemModelResolver; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.client.renderer.texture.TextureAtlasSprite; @@ -35,19 +39,14 @@ import net.minecraft.client.renderer.texture.TextureManager; import net.minecraft.client.resources.PlayerSkin.Model; import net.minecraft.client.resources.model.EquipmentAssetManager; import net.minecraft.client.resources.model.ModelBakery; -import net.minecraft.client.server.IntegratedServer; import net.minecraft.core.BlockPos; import net.minecraft.resources.ResourceLocation; -import net.minecraft.server.level.ServerLevel; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.server.packs.resources.ResourceManagerReloadListener; import net.minecraft.util.ARGB; import net.minecraft.util.Mth; import net.minecraft.world.entity.Entity; import net.minecraft.world.entity.EntityType; -import net.minecraft.world.entity.LivingEntity; -import net.minecraft.world.entity.boss.EnderDragonPart; -import net.minecraft.world.entity.boss.enderdragon.EnderDragon; import net.minecraft.world.entity.player.Player; import net.minecraft.world.level.Level; import net.minecraft.world.level.LevelReader; @@ -124,6 +123,16 @@ public class EntityRenderDispatcher implements ResourceManagerReloadListener { } } + public EntityRenderer getRenderer(S renderState) { + if (renderState instanceof PlayerRenderState playerRenderState) { + Model model = playerRenderState.skin.model(); + EntityRenderer entityRenderer = (EntityRenderer)this.playerRenderers.get(model); + return (EntityRenderer)(entityRenderer != null ? entityRenderer : (EntityRenderer)this.playerRenderers.get(Model.WIDE)); + } else { + return (EntityRenderer)this.renderers.get(renderState.entityType); + } + } + public void prepare(Level level, Camera activeRenderInfo, Entity entity) { this.level = level; this.camera = activeRenderInfo; @@ -170,124 +179,138 @@ public class EntityRenderDispatcher implements ResourceManagerReloadListener { int packedLight, EntityRenderer renderer ) { + S entityRenderState; try { - S entityRenderState = renderer.createRenderState(entity, partialTick); - Vec3 vec3 = renderer.getRenderOffset(entityRenderState); + entityRenderState = renderer.createRenderState(entity, partialTick); + } catch (Throwable var19) { + CrashReport crashReport = CrashReport.forThrowable(var19, "Extracting render state for an entity in world"); + CrashReportCategory crashReportCategory = crashReport.addCategory("Entity being extracted"); + entity.fillCrashReportCategory(crashReportCategory); + CrashReportCategory crashReportCategory2 = this.fillRendererDetails(xOffset, yOffset, zOffset, renderer, crashReport); + crashReportCategory2.setDetail("Delta", partialTick); + throw new ReportedException(crashReport); + } + + try { + this.render(entityRenderState, xOffset, yOffset, zOffset, poseStack, bufferSource, packedLight, renderer); + } catch (Throwable var18) { + CrashReport crashReport = CrashReport.forThrowable(var18, "Rendering entity in world"); + CrashReportCategory crashReportCategory = crashReport.addCategory("Entity being rendered"); + entity.fillCrashReportCategory(crashReportCategory); + throw new ReportedException(crashReport); + } + } + + public void render( + S renderState, double xOffset, double yOffset, double zOffset, PoseStack poseStack, MultiBufferSource bufferSource, int packedLight + ) { + EntityRenderer entityRenderer = this.getRenderer(renderState); + this.render(renderState, xOffset, yOffset, zOffset, poseStack, bufferSource, packedLight, entityRenderer); + } + + private void render( + S renderState, + double xOffset, + double yOffset, + double zOffset, + PoseStack poseStack, + MultiBufferSource bufferSource, + int packedLight, + EntityRenderer renderer + ) { + try { + Vec3 vec3 = renderer.getRenderOffset(renderState); double d = xOffset + vec3.x(); double e = yOffset + vec3.y(); double f = zOffset + vec3.z(); poseStack.pushPose(); poseStack.translate(d, e, f); - renderer.render(entityRenderState, poseStack, bufferSource, packedLight); - if (entityRenderState.displayFireAnimation) { - this.renderFlame(poseStack, bufferSource, entityRenderState, Mth.rotationAroundAxis(Mth.Y_AXIS, this.cameraOrientation, new Quaternionf())); + renderer.render(renderState, poseStack, bufferSource, packedLight); + if (renderState.displayFireAnimation) { + this.renderFlame(poseStack, bufferSource, renderState, Mth.rotationAroundAxis(Mth.Y_AXIS, this.cameraOrientation, new Quaternionf())); } - if (entity instanceof Player) { + if (renderState instanceof PlayerRenderState) { poseStack.translate(-vec3.x(), -vec3.y(), -vec3.z()); } - if (this.options.entityShadows().get() && this.shouldRenderShadow && !entityRenderState.isInvisible) { - float g = renderer.getShadowRadius(entityRenderState); + if (this.options.entityShadows().get() && this.shouldRenderShadow && !renderState.isInvisible) { + float g = renderer.getShadowRadius(renderState); if (g > 0.0F) { - double h = entityRenderState.distanceToCameraSq; - float i = (float)((1.0 - h / 256.0) * renderer.getShadowStrength(entityRenderState)); + double h = renderState.distanceToCameraSq; + float i = (float)((1.0 - h / 256.0) * renderer.getShadowStrength(renderState)); if (i > 0.0F) { - renderShadow(poseStack, bufferSource, entityRenderState, i, partialTick, this.level, Math.min(g, 32.0F)); + renderShadow(poseStack, bufferSource, renderState, i, this.level, Math.min(g, 32.0F)); } } } - if (!(entity instanceof Player)) { + if (!(renderState instanceof PlayerRenderState)) { poseStack.translate(-vec3.x(), -vec3.y(), -vec3.z()); } - if (this.renderHitBoxes && !entityRenderState.isInvisible && !Minecraft.getInstance().showOnlyReducedInfo()) { - renderHitbox(poseStack, bufferSource.getBuffer(RenderType.lines()), entity, partialTick, 1.0F, 1.0F, 1.0F); + if (renderState.hitboxesRenderState != null) { + this.renderHitboxes(poseStack, renderState, renderState.hitboxesRenderState, bufferSource); } poseStack.popPose(); - } catch (Throwable var25) { - CrashReport crashReport = CrashReport.forThrowable(var25, "Rendering entity in world"); - CrashReportCategory crashReportCategory = crashReport.addCategory("Entity being rendered"); - entity.fillCrashReportCategory(crashReportCategory); - CrashReportCategory crashReportCategory2 = crashReport.addCategory("Renderer details"); - crashReportCategory2.setDetail("Assigned renderer", renderer); - crashReportCategory2.setDetail("Location", CrashReportCategory.formatLocation(this.level, xOffset, yOffset, zOffset)); - crashReportCategory2.setDetail("Delta", partialTick); + } catch (Throwable var23) { + CrashReport crashReport = CrashReport.forThrowable(var23, "Rendering entity in world"); + CrashReportCategory crashReportCategory = crashReport.addCategory("EntityRenderState being rendered"); + renderState.fillCrashReportCategory(crashReportCategory); + this.fillRendererDetails(xOffset, yOffset, zOffset, renderer, crashReport); throw new ReportedException(crashReport); } } - private static void renderServerSideHitbox(PoseStack poseStack, Entity entity, MultiBufferSource bufferSource) { - Entity entity2 = getServerSideEntity(entity); - if (entity2 == null) { - DebugRenderer.renderFloatingText(poseStack, bufferSource, "Missing", entity.getX(), entity.getBoundingBox().maxY + 1.5, entity.getZ(), -65536); - } else { - poseStack.pushPose(); - poseStack.translate(entity2.getX() - entity.getX(), entity2.getY() - entity.getY(), entity2.getZ() - entity.getZ()); - renderHitbox(poseStack, bufferSource.getBuffer(RenderType.lines()), entity2, 1.0F, 0.0F, 1.0F, 0.0F); - ShapeRenderer.renderVector(poseStack, bufferSource.getBuffer(RenderType.lines()), new Vector3f(), entity2.getDeltaMovement(), -256); - poseStack.popPose(); - } + private CrashReportCategory fillRendererDetails( + double xOffset, double yOffset, double zOffset, EntityRenderer renderer, CrashReport crashReport + ) { + CrashReportCategory crashReportCategory = crashReport.addCategory("Renderer details"); + crashReportCategory.setDetail("Assigned renderer", renderer); + crashReportCategory.setDetail("Location", CrashReportCategory.formatLocation(this.level, xOffset, yOffset, zOffset)); + return crashReportCategory; } - @Nullable - private static Entity getServerSideEntity(Entity entity) { - IntegratedServer integratedServer = Minecraft.getInstance().getSingleplayerServer(); - if (integratedServer != null) { - ServerLevel serverLevel = integratedServer.getLevel(entity.level().dimension()); - if (serverLevel != null) { - return serverLevel.getEntity(entity.getId()); - } - } - - return null; - } - - private static void renderHitbox(PoseStack poseStack, VertexConsumer buffer, Entity entity, float red, float green, float blue, float alpha) { - AABB aABB = entity.getBoundingBox().move(-entity.getX(), -entity.getY(), -entity.getZ()); - ShapeRenderer.renderLineBox(poseStack, buffer, aABB, green, blue, alpha, 1.0F); - if (entity instanceof EnderDragon) { - double d = -Mth.lerp((double)red, entity.xOld, entity.getX()); - double e = -Mth.lerp((double)red, entity.yOld, entity.getY()); - double f = -Mth.lerp((double)red, entity.zOld, entity.getZ()); - - for (EnderDragonPart enderDragonPart : ((EnderDragon)entity).getSubEntities()) { + private void renderHitboxes(PoseStack poseStack, EntityRenderState renderState, HitboxesRenderState hitboxesRenderState, MultiBufferSource bufferSource) { + VertexConsumer vertexConsumer = bufferSource.getBuffer(RenderType.lines()); + renderHitboxesAndViewVector(poseStack, hitboxesRenderState, vertexConsumer, renderState.eyeHeight); + ServerHitboxesRenderState serverHitboxesRenderState = renderState.serverHitboxesRenderState; + if (serverHitboxesRenderState != null) { + if (serverHitboxesRenderState.missing()) { + HitboxRenderState hitboxRenderState = (HitboxRenderState)hitboxesRenderState.hitboxes().getFirst(); + DebugRenderer.renderFloatingText(poseStack, bufferSource, "Missing", renderState.x, hitboxRenderState.y1() + 1.5, renderState.z, -65536); + } else if (serverHitboxesRenderState.hitboxes() != null) { poseStack.pushPose(); - double g = d + Mth.lerp((double)red, enderDragonPart.xOld, enderDragonPart.getX()); - double h = e + Mth.lerp((double)red, enderDragonPart.yOld, enderDragonPart.getY()); - double i = f + Mth.lerp((double)red, enderDragonPart.zOld, enderDragonPart.getZ()); - poseStack.translate(g, h, i); - ShapeRenderer.renderLineBox( - poseStack, - buffer, - enderDragonPart.getBoundingBox().move(-enderDragonPart.getX(), -enderDragonPart.getY(), -enderDragonPart.getZ()), - 0.25F, - 1.0F, - 0.0F, - 1.0F + poseStack.translate( + serverHitboxesRenderState.serverEntityX() - renderState.x, + serverHitboxesRenderState.serverEntityY() - renderState.y, + serverHitboxesRenderState.serverEntityZ() - renderState.z ); + renderHitboxesAndViewVector(poseStack, serverHitboxesRenderState.hitboxes(), vertexConsumer, serverHitboxesRenderState.eyeHeight()); + Vec3 vec3 = new Vec3(serverHitboxesRenderState.deltaMovementX(), serverHitboxesRenderState.deltaMovementY(), serverHitboxesRenderState.deltaMovementZ()); + ShapeRenderer.renderVector(poseStack, vertexConsumer, new Vector3f(), vec3, -256); poseStack.popPose(); } } + } - if (entity instanceof LivingEntity) { - float j = 0.01F; - ShapeRenderer.renderLineBox( - poseStack, buffer, aABB.minX, entity.getEyeHeight() - 0.01F, aABB.minZ, aABB.maxX, entity.getEyeHeight() + 0.01F, aABB.maxZ, 1.0F, 0.0F, 0.0F, 1.0F - ); + private static void renderHitboxesAndViewVector(PoseStack poseStack, HitboxesRenderState hitboxesRenderState, VertexConsumer consumer, float eyeHeight) { + for (HitboxRenderState hitboxRenderState : hitboxesRenderState.hitboxes()) { + renderHitbox(poseStack, consumer, hitboxRenderState); } - Entity entity2 = entity.getVehicle(); - if (entity2 != null) { - float k = Math.min(entity2.getBbWidth(), entity.getBbWidth()) / 2.0F; - float l = 0.0625F; - Vec3 vec3 = entity2.getPassengerRidingPosition(entity).subtract(entity.position()); - ShapeRenderer.renderLineBox(poseStack, buffer, vec3.x - k, vec3.y, vec3.z - k, vec3.x + k, vec3.y + 0.0625, vec3.z + k, 1.0F, 1.0F, 0.0F, 1.0F); - } + Vec3 vec3 = new Vec3(hitboxesRenderState.viewX(), hitboxesRenderState.viewY(), hitboxesRenderState.viewZ()); + ShapeRenderer.renderVector(poseStack, consumer, new Vector3f(0.0F, eyeHeight, 0.0F), vec3.scale(2.0), -16776961); + } - ShapeRenderer.renderVector(poseStack, buffer, new Vector3f(0.0F, entity.getEyeHeight(), 0.0F), entity.getViewVector(red).scale(2.0), -16776961); + private static void renderHitbox(PoseStack posStack, VertexConsumer consumer, HitboxRenderState hitbox) { + posStack.pushPose(); + posStack.translate(hitbox.offsetX(), hitbox.offsetY(), hitbox.offsetZ()); + ShapeRenderer.renderLineBox( + posStack, consumer, hitbox.x0(), hitbox.y0(), hitbox.z0(), hitbox.x1(), hitbox.y1(), hitbox.z1(), hitbox.red(), hitbox.green(), hitbox.blue(), 1.0F + ); + posStack.popPose(); } private void renderFlame(PoseStack poseStack, MultiBufferSource bufferSource, EntityRenderState renderState, Quaternionf quaternion) { @@ -306,7 +329,7 @@ public class EntityRenderDispatcher implements ResourceManagerReloadListener { int l = 0; VertexConsumer vertexConsumer = bufferSource.getBuffer(Sheets.cutoutBlockSheet()); - for (Pose pose = poseStack.last(); i > 0.0F; l++) { + for (PoseStack.Pose pose = poseStack.last(); i > 0.0F; l++) { TextureAtlasSprite textureAtlasSprite3 = l % 2 == 0 ? textureAtlasSprite : textureAtlasSprite2; float m = textureAtlasSprite3.getU0(); float n = textureAtlasSprite3.getV0(); @@ -331,21 +354,21 @@ public class EntityRenderDispatcher implements ResourceManagerReloadListener { poseStack.popPose(); } - private static void fireVertex(Pose matrixEntry, VertexConsumer buffer, float x, float y, float z, float texU, float texV) { + private static void fireVertex(PoseStack.Pose matrixEntry, VertexConsumer buffer, float x, float y, float z, float texU, float texV) { buffer.addVertex(matrixEntry, x, y, z).setColor(-1).setUv(texU, texV).setUv1(0, 10).setLight(240).setNormal(matrixEntry, 0.0F, 1.0F, 0.0F); } private static void renderShadow( - PoseStack poseStack, MultiBufferSource bufferSource, EntityRenderState renderState, float shadowStrength, float partialTick, LevelReader level, float size + PoseStack poseStack, MultiBufferSource bufferSource, EntityRenderState renderState, float strength, LevelReader level, float size ) { - float f = Math.min(shadowStrength / 0.5F, size); + float f = Math.min(strength / 0.5F, size); int i = Mth.floor(renderState.x - size); int j = Mth.floor(renderState.x + size); int k = Mth.floor(renderState.y - f); int l = Mth.floor(renderState.y); int m = Mth.floor(renderState.z - size); int n = Mth.floor(renderState.z + size); - Pose pose = poseStack.last(); + PoseStack.Pose pose = poseStack.last(); VertexConsumer vertexConsumer = bufferSource.getBuffer(SHADOW_RENDER_TYPE); BlockPos.MutableBlockPos mutableBlockPos = new BlockPos.MutableBlockPos(); @@ -356,7 +379,7 @@ public class EntityRenderDispatcher implements ResourceManagerReloadListener { for (int q = k; q <= l; q++) { mutableBlockPos.setY(q); - float g = shadowStrength - (float)(renderState.y - mutableBlockPos.getY()) * 0.5F; + float g = strength - (float)(renderState.y - mutableBlockPos.getY()) * 0.5F; renderBlockShadow(pose, vertexConsumer, chunkAccess, level, mutableBlockPos, renderState.x, renderState.y, renderState.z, size, g); } } @@ -364,7 +387,7 @@ public class EntityRenderDispatcher implements ResourceManagerReloadListener { } private static void renderBlockShadow( - Pose pose, VertexConsumer buffer, ChunkAccess chunk, LevelReader level, BlockPos pos, double x, double y, double z, float size, float weight + PoseStack.Pose pose, VertexConsumer consumer, ChunkAccess chunk, LevelReader level, BlockPos pos, double x, double y, double z, float size, float weight ) { BlockPos blockPos = pos.below(); BlockState blockState = chunk.getBlockState(blockPos); @@ -395,17 +418,17 @@ public class EntityRenderDispatcher implements ResourceManagerReloadListener { float r = -m / 2.0F / size + 0.5F; float s = -o / 2.0F / size + 0.5F; float t = -p / 2.0F / size + 0.5F; - shadowVertex(pose, buffer, i, l, n, o, q, s); - shadowVertex(pose, buffer, i, l, n, p, q, t); - shadowVertex(pose, buffer, i, m, n, p, r, t); - shadowVertex(pose, buffer, i, m, n, o, r, s); + shadowVertex(pose, consumer, i, l, n, o, q, s); + shadowVertex(pose, consumer, i, l, n, p, q, t); + shadowVertex(pose, consumer, i, m, n, p, r, t); + shadowVertex(pose, consumer, i, m, n, o, r, s); } } } } } - private static void shadowVertex(Pose pose, VertexConsumer consumer, int color, float offsetX, float offsetY, float offsetZ, float u, float v) { + private static void shadowVertex(PoseStack.Pose pose, VertexConsumer consumer, int color, float offsetX, float offsetY, float offsetZ, float u, float v) { Vector3f vector3f = pose.pose().transformPosition(offsetX, offsetY, offsetZ, new Vector3f()); consumer.addVertex(vector3f.x(), vector3f.y(), vector3f.z(), color, u, v, OverlayTexture.NO_OVERLAY, 15728880, 0.0F, 1.0F, 0.0F); } @@ -438,7 +461,7 @@ public class EntityRenderDispatcher implements ResourceManagerReloadListener { @Override public void onResourceManagerReload(ResourceManager resourceManager) { - EntityRendererProvider.Context context = new EntityRendererProvider.Context( + Context context = new Context( this, this.itemModelResolver, this.mapRenderer, diff --git a/net/minecraft/client/renderer/entity/EntityRenderer.java b/net/minecraft/client/renderer/entity/EntityRenderer.java index 0c4c06b9..b41b242a 100644 --- a/net/minecraft/client/renderer/entity/EntityRenderer.java +++ b/net/minecraft/client/renderer/entity/EntityRenderer.java @@ -1,19 +1,25 @@ package net.minecraft.client.renderer.entity; +import com.google.common.collect.ImmutableList.Builder; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.Minecraft; import net.minecraft.client.gui.Font; +import net.minecraft.client.gui.Font.DisplayMode; import net.minecraft.client.renderer.LightTexture; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.culling.Frustum; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.EntityRenderState; -import net.minecraft.client.renderer.entity.state.EntityRenderState.LeashState; +import net.minecraft.client.renderer.entity.state.HitboxRenderState; +import net.minecraft.client.renderer.entity.state.HitboxesRenderState; +import net.minecraft.client.server.IntegratedServer; import net.minecraft.core.BlockPos; import net.minecraft.network.chat.Component; +import net.minecraft.server.level.ServerLevel; import net.minecraft.util.Mth; import net.minecraft.world.entity.Entity; import net.minecraft.world.entity.EntityAttachment; @@ -36,7 +42,7 @@ public abstract class EntityRenderer builder = new Builder<>(); + AABB aABB = entity.getBoundingBox(); + HitboxRenderState hitboxRenderState; + if (green) { + hitboxRenderState = new HitboxRenderState( + aABB.minX - entity.getX(), + aABB.minY - entity.getY(), + aABB.minZ - entity.getZ(), + aABB.maxX - entity.getX(), + aABB.maxY - entity.getY(), + aABB.maxZ - entity.getZ(), + 0.0F, + 1.0F, + 0.0F + ); + } else { + hitboxRenderState = new HitboxRenderState( + aABB.minX - entity.getX(), + aABB.minY - entity.getY(), + aABB.minZ - entity.getZ(), + aABB.maxX - entity.getX(), + aABB.maxY - entity.getY(), + aABB.maxZ - entity.getZ(), + 1.0F, + 1.0F, + 1.0F + ); + } + + builder.add(hitboxRenderState); + Entity entity2 = entity.getVehicle(); + if (entity2 != null) { + float f = Math.min(entity2.getBbWidth(), entity.getBbWidth()) / 2.0F; + float g = 0.0625F; + Vec3 vec3 = entity2.getPassengerRidingPosition(entity).subtract(entity.position()); + HitboxRenderState hitboxRenderState2 = new HitboxRenderState(vec3.x - f, vec3.y, vec3.z - f, vec3.x + f, vec3.y + 0.0625, vec3.z + f, 1.0F, 1.0F, 0.0F); + builder.add(hitboxRenderState2); + } + + this.extractAdditionalHitboxes(entity, builder, partialTick); + Vec3 vec32 = entity.getViewVector(partialTick); + return new HitboxesRenderState(vec32.x, vec32.y, vec32.z, builder.build()); + } + + protected void extractAdditionalHitboxes(T entity, Builder hitboxes, float partialTick) { + } + + @Nullable + private static Entity getServerSideEntity(Entity entity) { + IntegratedServer integratedServer = Minecraft.getInstance().getSingleplayerServer(); + if (integratedServer != null) { + ServerLevel serverLevel = integratedServer.getLevel(entity.level().dimension()); + if (serverLevel != null) { + return serverLevel.getEntity(entity.getId()); + } + } + + return null; } } diff --git a/net/minecraft/client/renderer/entity/EntityRenderers.java b/net/minecraft/client/renderer/entity/EntityRenderers.java index 5ec91066..198b333e 100644 --- a/net/minecraft/client/renderer/entity/EntityRenderers.java +++ b/net/minecraft/client/renderer/entity/EntityRenderers.java @@ -10,6 +10,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.SquidModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.player.AbstractClientPlayer; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.player.PlayerRenderer; import net.minecraft.client.resources.PlayerSkin.Model; import net.minecraft.core.registries.BuiltInRegistries; @@ -33,7 +34,7 @@ public class EntityRenderers { PROVIDERS.put(entityType, provider); } - public static Map, EntityRenderer> createEntityRenderers(EntityRendererProvider.Context context) { + public static Map, EntityRenderer> createEntityRenderers(Context context) { Builder, EntityRenderer> builder = ImmutableMap.builder(); PROVIDERS.forEach((entityType, entityRendererProvider) -> { try { @@ -45,7 +46,7 @@ public class EntityRenderers { return builder.build(); } - public static Map> createPlayerRenderers(EntityRendererProvider.Context context) { + public static Map> createPlayerRenderers(Context context) { Builder> builder = ImmutableMap.builder(); PLAYER_PROVIDERS.forEach((model, entityRendererProvider) -> { try { @@ -71,42 +72,30 @@ public class EntityRenderers { } static { + register(EntityType.ACACIA_BOAT, context -> new BoatRenderer(context, ModelLayers.ACACIA_BOAT)); + register(EntityType.ACACIA_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.ACACIA_CHEST_BOAT)); register(EntityType.ALLAY, AllayRenderer::new); register(EntityType.AREA_EFFECT_CLOUD, NoopRenderer::new); register(EntityType.ARMADILLO, ArmadilloRenderer::new); register(EntityType.ARMOR_STAND, ArmorStandRenderer::new); register(EntityType.ARROW, TippableArrowRenderer::new); register(EntityType.AXOLOTL, AxolotlRenderer::new); + register(EntityType.BAMBOO_CHEST_RAFT, context -> new RaftRenderer(context, ModelLayers.BAMBOO_CHEST_RAFT)); + register(EntityType.BAMBOO_RAFT, context -> new RaftRenderer(context, ModelLayers.BAMBOO_RAFT)); register(EntityType.BAT, BatRenderer::new); register(EntityType.BEE, BeeRenderer::new); + register(EntityType.BIRCH_BOAT, context -> new BoatRenderer(context, ModelLayers.BIRCH_BOAT)); + register(EntityType.BIRCH_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.BIRCH_CHEST_BOAT)); register(EntityType.BLAZE, BlazeRenderer::new); register(EntityType.BLOCK_DISPLAY, DisplayRenderer.BlockDisplayRenderer::new); - register(EntityType.OAK_BOAT, context -> new BoatRenderer(context, ModelLayers.OAK_BOAT)); - register(EntityType.SPRUCE_BOAT, context -> new BoatRenderer(context, ModelLayers.SPRUCE_BOAT)); - register(EntityType.BIRCH_BOAT, context -> new BoatRenderer(context, ModelLayers.BIRCH_BOAT)); - register(EntityType.JUNGLE_BOAT, context -> new BoatRenderer(context, ModelLayers.JUNGLE_BOAT)); - register(EntityType.ACACIA_BOAT, context -> new BoatRenderer(context, ModelLayers.ACACIA_BOAT)); - register(EntityType.CHERRY_BOAT, context -> new BoatRenderer(context, ModelLayers.CHERRY_BOAT)); - register(EntityType.DARK_OAK_BOAT, context -> new BoatRenderer(context, ModelLayers.DARK_OAK_BOAT)); - register(EntityType.PALE_OAK_BOAT, context -> new BoatRenderer(context, ModelLayers.PALE_OAK_BOAT)); - register(EntityType.MANGROVE_BOAT, context -> new BoatRenderer(context, ModelLayers.MANGROVE_BOAT)); - register(EntityType.BAMBOO_RAFT, context -> new RaftRenderer(context, ModelLayers.BAMBOO_RAFT)); register(EntityType.BOGGED, BoggedRenderer::new); register(EntityType.BREEZE, BreezeRenderer::new); register(EntityType.BREEZE_WIND_CHARGE, WindChargeRenderer::new); - register(EntityType.CAT, CatRenderer::new); register(EntityType.CAMEL, CamelRenderer::new); + register(EntityType.CAT, CatRenderer::new); register(EntityType.CAVE_SPIDER, CaveSpiderRenderer::new); - register(EntityType.OAK_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.OAK_CHEST_BOAT)); - register(EntityType.SPRUCE_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.SPRUCE_CHEST_BOAT)); - register(EntityType.BIRCH_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.BIRCH_CHEST_BOAT)); - register(EntityType.JUNGLE_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.JUNGLE_CHEST_BOAT)); - register(EntityType.ACACIA_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.ACACIA_CHEST_BOAT)); + register(EntityType.CHERRY_BOAT, context -> new BoatRenderer(context, ModelLayers.CHERRY_BOAT)); register(EntityType.CHERRY_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.CHERRY_CHEST_BOAT)); - register(EntityType.DARK_OAK_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.DARK_OAK_CHEST_BOAT)); - register(EntityType.PALE_OAK_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.PALE_OAK_CHEST_BOAT)); - register(EntityType.MANGROVE_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.MANGROVE_CHEST_BOAT)); - register(EntityType.BAMBOO_CHEST_RAFT, context -> new RaftRenderer(context, ModelLayers.BAMBOO_CHEST_RAFT)); register(EntityType.CHEST_MINECART, context -> new MinecartRenderer(context, ModelLayers.CHEST_MINECART)); register(EntityType.CHICKEN, ChickenRenderer::new); register(EntityType.COD, CodRenderer::new); @@ -114,8 +103,10 @@ public class EntityRenderers { register(EntityType.COW, CowRenderer::new); register(EntityType.CREAKING, CreakingRenderer::new); register(EntityType.CREEPER, CreeperRenderer::new); + register(EntityType.DARK_OAK_BOAT, context -> new BoatRenderer(context, ModelLayers.DARK_OAK_BOAT)); + register(EntityType.DARK_OAK_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.DARK_OAK_CHEST_BOAT)); register(EntityType.DOLPHIN, DolphinRenderer::new); - register(EntityType.DONKEY, context -> new DonkeyRenderer<>(context, ModelLayers.DONKEY, ModelLayers.DONKEY_BABY, false)); + register(EntityType.DONKEY, context -> new DonkeyRenderer<>(context, DonkeyRenderer.Type.DONKEY)); register(EntityType.DRAGON_FIREBALL, DragonFireballRenderer::new); register(EntityType.DROWNED, DrownedRenderer::new); register(EntityType.EGG, ThrownItemRenderer::new); @@ -158,18 +149,27 @@ public class EntityRenderers { register(EntityType.ITEM, ItemEntityRenderer::new); register(EntityType.ITEM_DISPLAY, DisplayRenderer.ItemDisplayRenderer::new); register(EntityType.ITEM_FRAME, ItemFrameRenderer::new); - register(EntityType.OMINOUS_ITEM_SPAWNER, OminousItemSpawnerRenderer::new); + register(EntityType.JUNGLE_BOAT, context -> new BoatRenderer(context, ModelLayers.JUNGLE_BOAT)); + register(EntityType.JUNGLE_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.JUNGLE_CHEST_BOAT)); register(EntityType.LEASH_KNOT, LeashKnotRenderer::new); register(EntityType.LIGHTNING_BOLT, LightningBoltRenderer::new); + register(EntityType.LINGERING_POTION, ThrownItemRenderer::new); register(EntityType.LLAMA, context -> new LlamaRenderer(context, ModelLayers.LLAMA, ModelLayers.LLAMA_BABY)); register(EntityType.LLAMA_SPIT, LlamaSpitRenderer::new); register(EntityType.MAGMA_CUBE, MagmaCubeRenderer::new); + register(EntityType.MANGROVE_BOAT, context -> new BoatRenderer(context, ModelLayers.MANGROVE_BOAT)); + register(EntityType.MANGROVE_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.MANGROVE_CHEST_BOAT)); register(EntityType.MARKER, NoopRenderer::new); register(EntityType.MINECART, context -> new MinecartRenderer(context, ModelLayers.MINECART)); register(EntityType.MOOSHROOM, MushroomCowRenderer::new); - register(EntityType.MULE, context -> new DonkeyRenderer<>(context, ModelLayers.MULE, ModelLayers.MULE_BABY, true)); + register(EntityType.MULE, context -> new DonkeyRenderer<>(context, DonkeyRenderer.Type.MULE)); + register(EntityType.OAK_BOAT, context -> new BoatRenderer(context, ModelLayers.OAK_BOAT)); + register(EntityType.OAK_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.OAK_CHEST_BOAT)); register(EntityType.OCELOT, OcelotRenderer::new); + register(EntityType.OMINOUS_ITEM_SPAWNER, OminousItemSpawnerRenderer::new); register(EntityType.PAINTING, PaintingRenderer::new); + register(EntityType.PALE_OAK_BOAT, context -> new BoatRenderer(context, ModelLayers.PALE_OAK_BOAT)); + register(EntityType.PALE_OAK_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.PALE_OAK_CHEST_BOAT)); register(EntityType.PANDA, PandaRenderer::new); register(EntityType.PARROT, ParrotRenderer::new); register(EntityType.PHANTOM, PhantomRenderer::new); @@ -200,7 +200,6 @@ public class EntityRenderers { ); register(EntityType.PILLAGER, PillagerRenderer::new); register(EntityType.POLAR_BEAR, PolarBearRenderer::new); - register(EntityType.POTION, ThrownItemRenderer::new); register(EntityType.PUFFERFISH, PufferfishRenderer::new); register(EntityType.RABBIT, RabbitRenderer::new); register(EntityType.RAVAGER, RavagerRenderer::new); @@ -210,7 +209,7 @@ public class EntityRenderers { register(EntityType.SHULKER_BULLET, ShulkerBulletRenderer::new); register(EntityType.SILVERFISH, SilverfishRenderer::new); register(EntityType.SKELETON, SkeletonRenderer::new); - register(EntityType.SKELETON_HORSE, context -> new UndeadHorseRenderer(context, ModelLayers.SKELETON_HORSE, ModelLayers.SKELETON_HORSE_BABY, true)); + register(EntityType.SKELETON_HORSE, context -> new UndeadHorseRenderer(context, UndeadHorseRenderer.Type.SKELETON)); register(EntityType.SLIME, SlimeRenderer::new); register(EntityType.SMALL_FIREBALL, context -> new ThrownItemRenderer<>(context, 0.75F, true)); register(EntityType.SNIFFER, SnifferRenderer::new); @@ -219,6 +218,9 @@ public class EntityRenderers { register(EntityType.SPAWNER_MINECART, context -> new MinecartRenderer(context, ModelLayers.SPAWNER_MINECART)); register(EntityType.SPECTRAL_ARROW, SpectralArrowRenderer::new); register(EntityType.SPIDER, SpiderRenderer::new); + register(EntityType.SPLASH_POTION, ThrownItemRenderer::new); + register(EntityType.SPRUCE_BOAT, context -> new BoatRenderer(context, ModelLayers.SPRUCE_BOAT)); + register(EntityType.SPRUCE_CHEST_BOAT, context -> new BoatRenderer(context, ModelLayers.SPRUCE_CHEST_BOAT)); register( EntityType.SQUID, context -> new SquidRenderer<>(context, new SquidModel(context.bakeLayer(ModelLayers.SQUID)), new SquidModel(context.bakeLayer(ModelLayers.SQUID_BABY))) @@ -236,8 +238,8 @@ public class EntityRenderers { register(EntityType.VEX, VexRenderer::new); register(EntityType.VILLAGER, VillagerRenderer::new); register(EntityType.VINDICATOR, VindicatorRenderer::new); - register(EntityType.WARDEN, WardenRenderer::new); register(EntityType.WANDERING_TRADER, WanderingTraderRenderer::new); + register(EntityType.WARDEN, WardenRenderer::new); register(EntityType.WIND_CHARGE, WindChargeRenderer::new); register(EntityType.WITCH, WitchRenderer::new); register(EntityType.WITHER, WitherBossRenderer::new); @@ -246,7 +248,7 @@ public class EntityRenderers { register(EntityType.WOLF, WolfRenderer::new); register(EntityType.ZOGLIN, ZoglinRenderer::new); register(EntityType.ZOMBIE, ZombieRenderer::new); - register(EntityType.ZOMBIE_HORSE, context -> new UndeadHorseRenderer(context, ModelLayers.ZOMBIE_HORSE, ModelLayers.ZOMBIE_HORSE_BABY, false)); + register(EntityType.ZOMBIE_HORSE, context -> new UndeadHorseRenderer(context, UndeadHorseRenderer.Type.ZOMBIE)); register(EntityType.ZOMBIE_VILLAGER, ZombieVillagerRenderer::new); register( EntityType.ZOMBIFIED_PIGLIN, diff --git a/net/minecraft/client/renderer/entity/EvokerFangsRenderer.java b/net/minecraft/client/renderer/entity/EvokerFangsRenderer.java index 334b68a9..60042219 100644 --- a/net/minecraft/client/renderer/entity/EvokerFangsRenderer.java +++ b/net/minecraft/client/renderer/entity/EvokerFangsRenderer.java @@ -8,6 +8,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.EvokerFangsModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.EvokerFangsRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -18,7 +19,7 @@ public class EvokerFangsRenderer extends EntityRenderer extends IllagerRenderer { private static final ResourceLocation EVOKER_ILLAGER = ResourceLocation.withDefaultNamespace("textures/entity/illager/evoker.png"); - public EvokerRenderer(EntityRendererProvider.Context context) { + public EvokerRenderer(Context context) { super(context, new IllagerModel<>(context.bakeLayer(ModelLayers.EVOKER)), 0.5F); this.addLayer(new ItemInHandLayer>(this) { public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, EvokerRenderState evokerRenderState, float f, float g) { diff --git a/net/minecraft/client/renderer/entity/ExperienceOrbRenderer.java b/net/minecraft/client/renderer/entity/ExperienceOrbRenderer.java index f7772c61..21b2f879 100644 --- a/net/minecraft/client/renderer/entity/ExperienceOrbRenderer.java +++ b/net/minecraft/client/renderer/entity/ExperienceOrbRenderer.java @@ -2,11 +2,11 @@ package net.minecraft.client.renderer.entity; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; -import com.mojang.blaze3d.vertex.PoseStack.Pose; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.ExperienceOrbRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.core.BlockPos; @@ -19,7 +19,7 @@ public class ExperienceOrbRenderer extends EntityRenderer { private final BlockRenderDispatcher dispatcher; - public FallingBlockRenderer(EntityRendererProvider.Context context) { + public FallingBlockRenderer(Context context) { super(context); this.shadowRadius = 0.5F; this.dispatcher = context.getBlockRenderDispatcher(); @@ -36,18 +39,19 @@ public class FallingBlockRenderer extends EntityRenderer list = this.dispatcher + .getBlockModel(blockState) + .collectParts(RandomSource.create(blockState.getSeed(fallingBlockRenderState.startBlockPos))); this.dispatcher .getModelRenderer() .tesselateBlock( fallingBlockRenderState, - this.dispatcher.getBlockModel(blockState), + list, blockState, fallingBlockRenderState.blockPos, poseStack, multiBufferSource.getBuffer(ItemBlockRenderTypes.getMovingBlockRenderType(blockState)), false, - RandomSource.create(), - blockState.getSeed(fallingBlockRenderState.startBlockPos), OverlayTexture.NO_OVERLAY ); poseStack.popPose(); diff --git a/net/minecraft/client/renderer/entity/FireworkEntityRenderer.java b/net/minecraft/client/renderer/entity/FireworkEntityRenderer.java index e55a58e8..38dd8b6e 100644 --- a/net/minecraft/client/renderer/entity/FireworkEntityRenderer.java +++ b/net/minecraft/client/renderer/entity/FireworkEntityRenderer.java @@ -5,6 +5,7 @@ import com.mojang.math.Axis; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.FireworkRocketRenderState; import net.minecraft.client.renderer.item.ItemModelResolver; import net.minecraft.client.renderer.texture.OverlayTexture; @@ -15,7 +16,7 @@ import net.minecraft.world.item.ItemDisplayContext; public class FireworkEntityRenderer extends EntityRenderer { private final ItemModelResolver itemModelResolver; - public FireworkEntityRenderer(EntityRendererProvider.Context context) { + public FireworkEntityRenderer(Context context) { super(context); this.itemModelResolver = context.getItemModelResolver(); } diff --git a/net/minecraft/client/renderer/entity/FishingHookRenderer.java b/net/minecraft/client/renderer/entity/FishingHookRenderer.java index 31f4af02..f859aee8 100644 --- a/net/minecraft/client/renderer/entity/FishingHookRenderer.java +++ b/net/minecraft/client/renderer/entity/FishingHookRenderer.java @@ -2,13 +2,13 @@ package net.minecraft.client.renderer.entity; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; -import com.mojang.blaze3d.vertex.PoseStack.Pose; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.Minecraft; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.culling.Frustum; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.FishingHookRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -25,7 +25,7 @@ public class FishingHookRenderer extends EntityRenderer { - public FrogRenderer(EntityRendererProvider.Context context) { + public FrogRenderer(Context context) { super(context, new FrogModel(context.bakeLayer(ModelLayers.FROG)), 0.3F); } @@ -24,11 +25,11 @@ public class FrogRenderer extends MobRenderer public void extractRenderState(Frog frog, FrogRenderState frogRenderState, float f) { super.extractRenderState(frog, frogRenderState, f); - frogRenderState.isSwimming = frog.isInWaterOrBubble(); + frogRenderState.isSwimming = frog.isInWater(); frogRenderState.jumpAnimationState.copyFrom(frog.jumpAnimationState); frogRenderState.croakAnimationState.copyFrom(frog.croakAnimationState); frogRenderState.tongueAnimationState.copyFrom(frog.tongueAnimationState); frogRenderState.swimIdleAnimationState.copyFrom(frog.swimIdleAnimationState); - frogRenderState.texture = frog.getVariant().value().texture(); + frogRenderState.texture = frog.getVariant().value().assetInfo().texturePath(); } } diff --git a/net/minecraft/client/renderer/entity/GlowSquidRenderer.java b/net/minecraft/client/renderer/entity/GlowSquidRenderer.java index 6a8e741d..ca5860fe 100644 --- a/net/minecraft/client/renderer/entity/GlowSquidRenderer.java +++ b/net/minecraft/client/renderer/entity/GlowSquidRenderer.java @@ -3,6 +3,7 @@ package net.minecraft.client.renderer.entity; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.SquidModel; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.SquidRenderState; import net.minecraft.core.BlockPos; import net.minecraft.resources.ResourceLocation; @@ -13,7 +14,7 @@ import net.minecraft.world.entity.GlowSquid; public class GlowSquidRenderer extends SquidRenderer { private static final ResourceLocation GLOW_SQUID_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/squid/glow_squid.png"); - public GlowSquidRenderer(EntityRendererProvider.Context context, SquidModel squidModel, SquidModel squidModel2) { + public GlowSquidRenderer(Context context, SquidModel squidModel, SquidModel squidModel2) { super(context, squidModel, squidModel2); } diff --git a/net/minecraft/client/renderer/entity/GuardianRenderer.java b/net/minecraft/client/renderer/entity/GuardianRenderer.java index 9f9d33ad..2a3c67ed 100644 --- a/net/minecraft/client/renderer/entity/GuardianRenderer.java +++ b/net/minecraft/client/renderer/entity/GuardianRenderer.java @@ -2,7 +2,6 @@ package net.minecraft.client.renderer.entity; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; -import com.mojang.blaze3d.vertex.PoseStack.Pose; import com.mojang.math.Axis; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -13,6 +12,7 @@ import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.culling.Frustum; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.GuardianRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -30,11 +30,11 @@ public class GuardianRenderer extends MobRenderer { - private static final Map LOCATION_BY_VARIANT = Util.make(Maps.newEnumMap(Variant.class), enumMap -> { - enumMap.put(Variant.WHITE, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_white.png")); - enumMap.put(Variant.CREAMY, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_creamy.png")); - enumMap.put(Variant.CHESTNUT, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_chestnut.png")); - enumMap.put(Variant.BROWN, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_brown.png")); - enumMap.put(Variant.BLACK, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_black.png")); - enumMap.put(Variant.GRAY, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_gray.png")); - enumMap.put(Variant.DARK_BROWN, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_darkbrown.png")); - }); + private static final Map LOCATION_BY_VARIANT = Maps.newEnumMap( + Map.of( + Variant.WHITE, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_white.png"), + Variant.CREAMY, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_creamy.png"), + Variant.CHESTNUT, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_chestnut.png"), + Variant.BROWN, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_brown.png"), + Variant.BLACK, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_black.png"), + Variant.GRAY, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_gray.png"), + Variant.DARK_BROWN, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_darkbrown.png") + ) + ); - public HorseRenderer(EntityRendererProvider.Context context) { + public HorseRenderer(Context context) { super(context, new HorseModel(context.bakeLayer(ModelLayers.HORSE)), new HorseModel(context.bakeLayer(ModelLayers.HORSE_BABY))); this.addLayer(new HorseMarkingLayer(this)); - this.addLayer(new HorseArmorLayer(this, context.getModelSet(), context.getEquipmentRenderer())); + this.addLayer( + new SimpleEquipmentLayer<>( + this, + context.getEquipmentRenderer(), + EquipmentClientInfo.LayerType.HORSE_BODY, + horseRenderState -> horseRenderState.bodyArmorItem, + new HorseModel(context.bakeLayer(ModelLayers.HORSE_ARMOR)), + new HorseModel(context.bakeLayer(ModelLayers.HORSE_BABY_ARMOR)) + ) + ); + this.addLayer( + new SimpleEquipmentLayer<>( + this, + context.getEquipmentRenderer(), + EquipmentClientInfo.LayerType.HORSE_SADDLE, + horseRenderState -> horseRenderState.saddle, + new EquineSaddleModel(context.bakeLayer(ModelLayers.HORSE_SADDLE)), + new EquineSaddleModel(context.bakeLayer(ModelLayers.HORSE_BABY_SADDLE)) + ) + ); } public ResourceLocation getTextureLocation(HorseRenderState horseRenderState) { diff --git a/net/minecraft/client/renderer/entity/IllusionerRenderer.java b/net/minecraft/client/renderer/entity/IllusionerRenderer.java index 0bb3a6e7..0ac92206 100644 --- a/net/minecraft/client/renderer/entity/IllusionerRenderer.java +++ b/net/minecraft/client/renderer/entity/IllusionerRenderer.java @@ -7,6 +7,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.IllagerModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.layers.ItemInHandLayer; import net.minecraft.client.renderer.entity.state.IllusionerRenderState; import net.minecraft.resources.ResourceLocation; @@ -19,7 +20,7 @@ import net.minecraft.world.phys.Vec3; public class IllusionerRenderer extends IllagerRenderer { private static final ResourceLocation ILLUSIONER = ResourceLocation.withDefaultNamespace("textures/entity/illager/illusioner.png"); - public IllusionerRenderer(EntityRendererProvider.Context context) { + public IllusionerRenderer(Context context) { super(context, new IllagerModel<>(context.bakeLayer(ModelLayers.ILLUSIONER)), 0.5F); this.addLayer(new ItemInHandLayer>(this) { public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, IllusionerRenderState illusionerRenderState, float f, float g) { diff --git a/net/minecraft/client/renderer/entity/IronGolemRenderer.java b/net/minecraft/client/renderer/entity/IronGolemRenderer.java index e2fc381c..d195e453 100644 --- a/net/minecraft/client/renderer/entity/IronGolemRenderer.java +++ b/net/minecraft/client/renderer/entity/IronGolemRenderer.java @@ -6,6 +6,7 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.IronGolemModel; import net.minecraft.client.model.geom.ModelLayers; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.layers.IronGolemCrackinessLayer; import net.minecraft.client.renderer.entity.layers.IronGolemFlowerLayer; import net.minecraft.client.renderer.entity.state.IronGolemRenderState; @@ -16,7 +17,7 @@ import net.minecraft.world.entity.animal.IronGolem; public class IronGolemRenderer extends MobRenderer { private static final ResourceLocation GOLEM_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/iron_golem/iron_golem.png"); - public IronGolemRenderer(EntityRendererProvider.Context context) { + public IronGolemRenderer(Context context) { super(context, new IronGolemModel(context.bakeLayer(ModelLayers.IRON_GOLEM)), 0.7F); this.addLayer(new IronGolemCrackinessLayer(this)); this.addLayer(new IronGolemFlowerLayer(this, context.getBlockRenderDispatcher())); diff --git a/net/minecraft/client/renderer/entity/ItemEntityRenderer.java b/net/minecraft/client/renderer/entity/ItemEntityRenderer.java index 4ef032b8..7e625bc2 100644 --- a/net/minecraft/client/renderer/entity/ItemEntityRenderer.java +++ b/net/minecraft/client/renderer/entity/ItemEntityRenderer.java @@ -5,6 +5,7 @@ import com.mojang.math.Axis; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.ItemClusterRenderState; import net.minecraft.client.renderer.entity.state.ItemEntityRenderState; import net.minecraft.client.renderer.item.ItemModelResolver; @@ -13,17 +14,17 @@ import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.util.Mth; import net.minecraft.util.RandomSource; import net.minecraft.world.entity.item.ItemEntity; +import net.minecraft.world.phys.AABB; @Environment(EnvType.CLIENT) public class ItemEntityRenderer extends EntityRenderer { + private static final float ITEM_MIN_HOVER_HEIGHT = 0.0625F; private static final float ITEM_BUNDLE_OFFSET_SCALE = 0.15F; - private static final float FLAT_ITEM_BUNDLE_OFFSET_X = 0.0F; - private static final float FLAT_ITEM_BUNDLE_OFFSET_Y = 0.0F; - private static final float FLAT_ITEM_BUNDLE_OFFSET_Z = 0.09375F; + private static final float FLAT_ITEM_DEPTH_THRESHOLD = 0.0625F; private final ItemModelResolver itemModelResolver; private final RandomSource random = RandomSource.create(); - public ItemEntityRenderer(EntityRendererProvider.Context context) { + public ItemEntityRenderer(Context context) { super(context); this.itemModelResolver = context.getItemModelResolver(); this.shadowRadius = 0.15F; @@ -41,16 +42,22 @@ public class ItemEntityRenderer extends EntityRenderer 0.0625F) { + itemStackRenderState.render(poseStack, bufferSource, packedLight, OverlayTexture.NO_OVERLAY); - for (int m = 0; m < i; m++) { - poseStack.pushPose(); - if (m > 0) { - if (bl) { + for (int j = 1; j < i; j++) { + poseStack.pushPose(); + float g = (random.nextFloat() * 2.0F - 1.0F) * 0.15F; + float h = (random.nextFloat() * 2.0F - 1.0F) * 0.15F; float k = (random.nextFloat() * 2.0F - 1.0F) * 0.15F; - float l = (random.nextFloat() * 2.0F - 1.0F) * 0.15F; - float n = (random.nextFloat() * 2.0F - 1.0F) * 0.15F; - poseStack.translate(k, l, n); - } else { - float k = (random.nextFloat() * 2.0F - 1.0F) * 0.15F * 0.5F; - float l = (random.nextFloat() * 2.0F - 1.0F) * 0.15F * 0.5F; - poseStack.translate(k, l, 0.0F); + poseStack.translate(g, h, k); + itemStackRenderState.render(poseStack, bufferSource, packedLight, OverlayTexture.NO_OVERLAY); + poseStack.popPose(); } - } + } else { + float l = f * 1.5F; + poseStack.translate(0.0F, 0.0F, -(l * (i - 1) / 2.0F)); + itemStackRenderState.render(poseStack, bufferSource, packedLight, OverlayTexture.NO_OVERLAY); + poseStack.translate(0.0F, 0.0F, l); - itemStackRenderState.render(poseStack, bufferSource, packedLight, OverlayTexture.NO_OVERLAY); - poseStack.popPose(); - if (!bl) { - poseStack.translate(0.0F * f, 0.0F * g, 0.09375F * h); + for (int m = 1; m < i; m++) { + poseStack.pushPose(); + float h = (random.nextFloat() * 2.0F - 1.0F) * 0.15F * 0.5F; + float k = (random.nextFloat() * 2.0F - 1.0F) * 0.15F * 0.5F; + poseStack.translate(h, k, 0.0F); + itemStackRenderState.render(poseStack, bufferSource, packedLight, OverlayTexture.NO_OVERLAY); + poseStack.popPose(); + poseStack.translate(0.0F, 0.0F, l); + } } } } diff --git a/net/minecraft/client/renderer/entity/ItemFrameRenderer.java b/net/minecraft/client/renderer/entity/ItemFrameRenderer.java index 8748f29a..2a60e65d 100644 --- a/net/minecraft/client/renderer/entity/ItemFrameRenderer.java +++ b/net/minecraft/client/renderer/entity/ItemFrameRenderer.java @@ -9,13 +9,14 @@ import net.minecraft.client.renderer.MapRenderer; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.block.BlockRenderDispatcher; +import net.minecraft.client.renderer.block.ModelBlockRenderer; +import net.minecraft.client.renderer.block.model.BlockStateModel; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.ItemFrameRenderState; import net.minecraft.client.renderer.item.ItemModelResolver; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.client.renderer.texture.TextureAtlas; -import net.minecraft.client.resources.model.BlockStateModelLoader; -import net.minecraft.client.resources.model.ModelManager; -import net.minecraft.client.resources.model.ModelResourceLocation; +import net.minecraft.client.resources.model.BlockStateDefinitions; import net.minecraft.core.BlockPos; import net.minecraft.core.Direction; import net.minecraft.network.chat.Component; @@ -23,6 +24,7 @@ import net.minecraft.world.entity.EntityType; import net.minecraft.world.entity.decoration.ItemFrame; import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.saveddata.maps.MapId; import net.minecraft.world.level.saveddata.maps.MapItemSavedData; import net.minecraft.world.phys.Vec3; @@ -35,7 +37,7 @@ public class ItemFrameRenderer extends EntityRenderer extends EntityRenderer extends EntityRenderer quads, RenderType renderType, ItemStackRenderState.FoilType foilType ) { VertexConsumer vertexConsumer; if (foilType == ItemStackRenderState.FoilType.SPECIAL) { - Pose pose = poseStack.last().copy(); + PoseStack.Pose pose = poseStack.last().copy(); if (displayContext == ItemDisplayContext.GUI) { MatrixUtil.mulComponentWise(pose.pose(), 0.5F); } else if (displayContext.firstPerson()) { @@ -83,7 +66,7 @@ public class ItemRenderer { vertexConsumer = getFoilBuffer(bufferSource, renderType, true, foilType != ItemStackRenderState.FoilType.NONE); } - renderModelLists(model, tintLayers, packedLight, packedOverlay, poseStack, vertexConsumer); + renderQuadList(poseStack, vertexConsumer, quads, tintLayers, packedLight, packedOverlay); } public static VertexConsumer getArmorFoilBuffer(MultiBufferSource bufferSource, RenderType renderType, boolean hasFoil) { @@ -92,7 +75,7 @@ public class ItemRenderer { : bufferSource.getBuffer(renderType); } - private static VertexConsumer getCompassFoilBuffer(MultiBufferSource bufferSource, RenderType renderType, Pose pose) { + private static VertexConsumer getCompassFoilBuffer(MultiBufferSource bufferSource, RenderType renderType, PoseStack.Pose pose) { return VertexMultiConsumer.create( new SheetedDecalTextureGenerator(bufferSource.getBuffer(RenderType.glint()), pose, 0.0078125F), bufferSource.getBuffer(renderType) ); @@ -109,11 +92,11 @@ public class ItemRenderer { } private static int getLayerColorSafe(int[] tintLayers, int index) { - return index >= tintLayers.length ? -1 : tintLayers[index]; + return index >= 0 && index < tintLayers.length ? tintLayers[index] : -1; } private static void renderQuadList(PoseStack poseStack, VertexConsumer buffer, List quads, int[] tintLayers, int packedLight, int packedOverlay) { - Pose pose = poseStack.last(); + PoseStack.Pose pose = poseStack.last(); for (BakedQuad bakedQuad : quads) { float f; @@ -121,7 +104,7 @@ public class ItemRenderer { float h; float j; if (bakedQuad.isTinted()) { - int i = getLayerColorSafe(tintLayers, bakedQuad.getTintIndex()); + int i = getLayerColorSafe(tintLayers, bakedQuad.tintIndex()); f = ARGB.alpha(i) / 255.0F; g = ARGB.red(i) / 255.0F; h = ARGB.green(i) / 255.0F; @@ -140,29 +123,28 @@ public class ItemRenderer { public void renderStatic( ItemStack stack, ItemDisplayContext displayContext, - int combinedLight, - int combinedOverlay, + int packedLight, + int packedOverlay, PoseStack poseStack, MultiBufferSource bufferSource, @Nullable Level level, int seed ) { - this.renderStatic(null, stack, displayContext, false, poseStack, bufferSource, level, combinedLight, combinedOverlay, seed); + this.renderStatic(null, stack, displayContext, poseStack, bufferSource, level, packedLight, packedOverlay, seed); } public void renderStatic( @Nullable LivingEntity entity, - ItemStack itemStack, - ItemDisplayContext diplayContext, - boolean leftHand, + ItemStack stack, + ItemDisplayContext displayContext, PoseStack poseStack, MultiBufferSource bufferSource, @Nullable Level level, - int combinedLight, - int combinedOverlay, + int packedLight, + int packedOverlay, int seed ) { - this.resolver.updateForTopItem(this.scratchItemStackRenderState, itemStack, diplayContext, leftHand, level, entity, seed); - this.scratchItemStackRenderState.render(poseStack, bufferSource, combinedLight, combinedOverlay); + this.resolver.updateForTopItem(this.scratchItemStackRenderState, stack, displayContext, level, entity, seed); + this.scratchItemStackRenderState.render(poseStack, bufferSource, packedLight, packedOverlay); } } diff --git a/net/minecraft/client/renderer/entity/LeashKnotRenderer.java b/net/minecraft/client/renderer/entity/LeashKnotRenderer.java index 26b11101..02bbc940 100644 --- a/net/minecraft/client/renderer/entity/LeashKnotRenderer.java +++ b/net/minecraft/client/renderer/entity/LeashKnotRenderer.java @@ -7,6 +7,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.LeashKnotModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.EntityRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -17,7 +18,7 @@ public class LeashKnotRenderer extends EntityRenderer { - public LightningBoltRenderer(EntityRendererProvider.Context context) { + public LightningBoltRenderer(Context context) { super(context); } diff --git a/net/minecraft/client/renderer/entity/LivingEntityRenderer.java b/net/minecraft/client/renderer/entity/LivingEntityRenderer.java index d46942a3..f39fff7a 100644 --- a/net/minecraft/client/renderer/entity/LivingEntityRenderer.java +++ b/net/minecraft/client/renderer/entity/LivingEntityRenderer.java @@ -1,6 +1,7 @@ package net.minecraft.client.renderer.entity; import com.google.common.collect.Lists; +import com.google.common.collect.ImmutableList.Builder; import com.mojang.blaze3d.vertex.PoseStack; import com.mojang.blaze3d.vertex.VertexConsumer; import com.mojang.math.Axis; @@ -13,8 +14,10 @@ import net.minecraft.client.model.EntityModel; import net.minecraft.client.player.LocalPlayer; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.layers.HumanoidArmorLayer; import net.minecraft.client.renderer.entity.layers.RenderLayer; +import net.minecraft.client.renderer.entity.state.HitboxRenderState; import net.minecraft.client.renderer.entity.state.LivingEntityRenderState; import net.minecraft.client.renderer.item.ItemModelResolver; import net.minecraft.client.renderer.texture.OverlayTexture; @@ -35,7 +38,6 @@ import net.minecraft.world.item.Items; import net.minecraft.world.level.block.AbstractSkullBlock; import net.minecraft.world.phys.AABB; import net.minecraft.world.scores.Team; -import net.minecraft.world.scores.Team.Visibility; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) @@ -47,7 +49,7 @@ public abstract class LivingEntityRenderer> layers = Lists.>newArrayList(); - public LivingEntityRenderer(EntityRendererProvider.Context context, M model, float shadowRadius) { + public LivingEntityRenderer(Context context, M model, float shadowRadius) { super(context); this.itemModelResolver = context.getItemModelResolver(); this.model = model; @@ -218,7 +220,7 @@ public abstract class LivingEntityRenderer builder, float f) { + AABB aABB = livingEntity.getBoundingBox(); + float g = 0.01F; + HitboxRenderState hitboxRenderState = new HitboxRenderState( + aABB.minX - livingEntity.getX(), + livingEntity.getEyeHeight() - 0.01F, + aABB.minZ - livingEntity.getZ(), + aABB.maxX - livingEntity.getX(), + livingEntity.getEyeHeight() + 0.01F, + aABB.maxZ - livingEntity.getZ(), + 1.0F, + 0.0F, + 0.0F + ); + builder.add(hitboxRenderState); + } + private static float solveBodyRot(LivingEntity entity, float yHeadRot, float partialTick) { if (entity.getVehicle() instanceof LivingEntity livingEntity) { float f = Mth.rotLerp(partialTick, livingEntity.yBodyRotO, livingEntity.yBodyRot); diff --git a/net/minecraft/client/renderer/entity/LlamaSpitRenderer.java b/net/minecraft/client/renderer/entity/LlamaSpitRenderer.java index 911a1b78..57268511 100644 --- a/net/minecraft/client/renderer/entity/LlamaSpitRenderer.java +++ b/net/minecraft/client/renderer/entity/LlamaSpitRenderer.java @@ -8,6 +8,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.LlamaSpitModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.LlamaSpitRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -18,7 +19,7 @@ public class LlamaSpitRenderer extends EntityRenderer { - public MinecartRenderer(EntityRendererProvider.Context context, ModelLayerLocation layer) { + public MinecartRenderer(Context context, ModelLayerLocation layer) { super(context, layer); } diff --git a/net/minecraft/client/renderer/entity/MobRenderer.java b/net/minecraft/client/renderer/entity/MobRenderer.java index c404038f..412d361c 100644 --- a/net/minecraft/client/renderer/entity/MobRenderer.java +++ b/net/minecraft/client/renderer/entity/MobRenderer.java @@ -3,12 +3,13 @@ package net.minecraft.client.renderer.entity; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.EntityModel; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.LivingEntityRenderState; import net.minecraft.world.entity.Mob; @Environment(EnvType.CLIENT) public abstract class MobRenderer> extends LivingEntityRenderer { - public MobRenderer(EntityRendererProvider.Context context, M entityModel, float f) { + public MobRenderer(Context context, M entityModel, float f) { super(context, entityModel, f); } diff --git a/net/minecraft/client/renderer/entity/NoopRenderer.java b/net/minecraft/client/renderer/entity/NoopRenderer.java index 17411f55..0a2dae46 100644 --- a/net/minecraft/client/renderer/entity/NoopRenderer.java +++ b/net/minecraft/client/renderer/entity/NoopRenderer.java @@ -2,12 +2,13 @@ package net.minecraft.client.renderer.entity; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.EntityRenderState; import net.minecraft.world.entity.Entity; @Environment(EnvType.CLIENT) public class NoopRenderer extends EntityRenderer { - public NoopRenderer(EntityRendererProvider.Context context) { + public NoopRenderer(Context context) { super(context); } diff --git a/net/minecraft/client/renderer/entity/OminousItemSpawnerRenderer.java b/net/minecraft/client/renderer/entity/OminousItemSpawnerRenderer.java index 1f6d9fb0..ba4e15f0 100644 --- a/net/minecraft/client/renderer/entity/OminousItemSpawnerRenderer.java +++ b/net/minecraft/client/renderer/entity/OminousItemSpawnerRenderer.java @@ -5,6 +5,7 @@ import com.mojang.math.Axis; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.ItemClusterRenderState; import net.minecraft.client.renderer.item.ItemModelResolver; import net.minecraft.util.Mth; @@ -19,7 +20,7 @@ public class OminousItemSpawnerRenderer extends EntityRenderer { - public PaintingRenderer(EntityRendererProvider.Context context) { + public PaintingRenderer(Context context) { super(context); } @@ -98,7 +98,7 @@ public class PaintingRenderer extends EntityRenderer { - private static final Map TEXTURES = Util.make(Maps.newEnumMap(Gene.class), enumMap -> { - enumMap.put(Gene.NORMAL, ResourceLocation.withDefaultNamespace("textures/entity/panda/panda.png")); - enumMap.put(Gene.LAZY, ResourceLocation.withDefaultNamespace("textures/entity/panda/lazy_panda.png")); - enumMap.put(Gene.WORRIED, ResourceLocation.withDefaultNamespace("textures/entity/panda/worried_panda.png")); - enumMap.put(Gene.PLAYFUL, ResourceLocation.withDefaultNamespace("textures/entity/panda/playful_panda.png")); - enumMap.put(Gene.BROWN, ResourceLocation.withDefaultNamespace("textures/entity/panda/brown_panda.png")); - enumMap.put(Gene.WEAK, ResourceLocation.withDefaultNamespace("textures/entity/panda/weak_panda.png")); - enumMap.put(Gene.AGGRESSIVE, ResourceLocation.withDefaultNamespace("textures/entity/panda/aggressive_panda.png")); - }); + private static final Map TEXTURES = Maps.newEnumMap( + Map.of( + Panda.Gene.NORMAL, + ResourceLocation.withDefaultNamespace("textures/entity/panda/panda.png"), + Panda.Gene.LAZY, + ResourceLocation.withDefaultNamespace("textures/entity/panda/lazy_panda.png"), + Panda.Gene.WORRIED, + ResourceLocation.withDefaultNamespace("textures/entity/panda/worried_panda.png"), + Panda.Gene.PLAYFUL, + ResourceLocation.withDefaultNamespace("textures/entity/panda/playful_panda.png"), + Panda.Gene.BROWN, + ResourceLocation.withDefaultNamespace("textures/entity/panda/brown_panda.png"), + Panda.Gene.WEAK, + ResourceLocation.withDefaultNamespace("textures/entity/panda/weak_panda.png"), + Panda.Gene.AGGRESSIVE, + ResourceLocation.withDefaultNamespace("textures/entity/panda/aggressive_panda.png") + ) + ); - public PandaRenderer(EntityRendererProvider.Context context) { + public PandaRenderer(Context context) { super(context, new PandaModel(context.bakeLayer(ModelLayers.PANDA)), new PandaModel(context.bakeLayer(ModelLayers.PANDA_BABY)), 0.9F); this.addLayer(new PandaHoldsItemLayer(this)); } public ResourceLocation getTextureLocation(PandaRenderState pandaRenderState) { - return (ResourceLocation)TEXTURES.getOrDefault(pandaRenderState.variant, (ResourceLocation)TEXTURES.get(Gene.NORMAL)); + return (ResourceLocation)TEXTURES.getOrDefault(pandaRenderState.variant, (ResourceLocation)TEXTURES.get(Panda.Gene.NORMAL)); } public PandaRenderState createRenderState() { diff --git a/net/minecraft/client/renderer/entity/PhantomRenderer.java b/net/minecraft/client/renderer/entity/PhantomRenderer.java index 5cd973ac..e16103ed 100644 --- a/net/minecraft/client/renderer/entity/PhantomRenderer.java +++ b/net/minecraft/client/renderer/entity/PhantomRenderer.java @@ -6,6 +6,7 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.PhantomModel; import net.minecraft.client.model.geom.ModelLayers; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.layers.PhantomEyesLayer; import net.minecraft.client.renderer.entity.state.PhantomRenderState; import net.minecraft.resources.ResourceLocation; @@ -15,7 +16,7 @@ import net.minecraft.world.entity.monster.Phantom; public class PhantomRenderer extends MobRenderer { private static final ResourceLocation PHANTOM_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/phantom.png"); - public PhantomRenderer(EntityRendererProvider.Context context) { + public PhantomRenderer(Context context) { super(context, new PhantomModel(context.bakeLayer(ModelLayers.PHANTOM)), 0.75F); this.addLayer(new PhantomEyesLayer(this)); } diff --git a/net/minecraft/client/renderer/entity/PigRenderer.java b/net/minecraft/client/renderer/entity/PigRenderer.java index 3ece7af2..f6550b2a 100644 --- a/net/minecraft/client/renderer/entity/PigRenderer.java +++ b/net/minecraft/client/renderer/entity/PigRenderer.java @@ -1,32 +1,65 @@ package net.minecraft.client.renderer.entity; +import com.google.common.collect.Maps; +import com.mojang.blaze3d.vertex.PoseStack; +import java.util.Map; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.model.AdultAndBabyModelPair; +import net.minecraft.client.model.ColdPigModel; +import net.minecraft.client.model.EntityModel; import net.minecraft.client.model.PigModel; import net.minecraft.client.model.geom.ModelLayers; -import net.minecraft.client.renderer.entity.layers.SaddleLayer; +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; +import net.minecraft.client.renderer.entity.layers.SimpleEquipmentLayer; import net.minecraft.client.renderer.entity.state.PigRenderState; +import net.minecraft.client.renderer.texture.MissingTextureAtlasSprite; +import net.minecraft.client.resources.model.EquipmentClientInfo; import net.minecraft.resources.ResourceLocation; +import net.minecraft.world.entity.EquipmentSlot; import net.minecraft.world.entity.animal.Pig; +import net.minecraft.world.entity.animal.PigVariant; @Environment(EnvType.CLIENT) -public class PigRenderer extends AgeableMobRenderer { - private static final ResourceLocation PIG_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/pig/pig.png"); +public class PigRenderer extends MobRenderer { + private final Map> models; - public PigRenderer(EntityRendererProvider.Context context) { - super(context, new PigModel(context.bakeLayer(ModelLayers.PIG)), new PigModel(context.bakeLayer(ModelLayers.PIG_BABY)), 0.7F); + public PigRenderer(Context context) { + super(context, new PigModel(context.bakeLayer(ModelLayers.PIG)), 0.7F); + this.models = bakeModels(context); this.addLayer( - new SaddleLayer<>( + new SimpleEquipmentLayer<>( this, + context.getEquipmentRenderer(), + EquipmentClientInfo.LayerType.PIG_SADDLE, + pigRenderState -> pigRenderState.saddle, new PigModel(context.bakeLayer(ModelLayers.PIG_SADDLE)), - new PigModel(context.bakeLayer(ModelLayers.PIG_BABY_SADDLE)), - ResourceLocation.withDefaultNamespace("textures/entity/pig/pig_saddle.png") + new PigModel(context.bakeLayer(ModelLayers.PIG_BABY_SADDLE)) ) ); } + private static Map> bakeModels(Context context) { + return Maps.newEnumMap( + Map.of( + PigVariant.ModelType.NORMAL, + new AdultAndBabyModelPair<>(new PigModel(context.bakeLayer(ModelLayers.PIG)), new PigModel(context.bakeLayer(ModelLayers.PIG_BABY))), + PigVariant.ModelType.COLD, + new AdultAndBabyModelPair<>(new ColdPigModel(context.bakeLayer(ModelLayers.COLD_PIG)), new ColdPigModel(context.bakeLayer(ModelLayers.COLD_PIG_BABY))) + ) + ); + } + + public void render(PigRenderState pigRenderState, PoseStack poseStack, MultiBufferSource multiBufferSource, int i) { + if (pigRenderState.variant != null) { + this.model = (EntityModel)((AdultAndBabyModelPair)this.models.get(pigRenderState.variant.modelAndTexture().model())).getModel(pigRenderState.isBaby); + super.render(pigRenderState, poseStack, multiBufferSource, i); + } + } + public ResourceLocation getTextureLocation(PigRenderState pigRenderState) { - return PIG_LOCATION; + return pigRenderState.variant == null ? MissingTextureAtlasSprite.getLocation() : pigRenderState.variant.modelAndTexture().asset().texturePath(); } public PigRenderState createRenderState() { @@ -35,6 +68,7 @@ public class PigRenderer extends AgeableMobRenderer model; private final ResourceLocation texture; - public RaftRenderer(EntityRendererProvider.Context context, ModelLayerLocation modelLayer) { + public RaftRenderer(Context context, ModelLayerLocation modelLayer) { super(context); this.texture = modelLayer.model().withPath((UnaryOperator)(string -> "textures/entity/" + string + ".png")); this.model = new RaftModel(context.bakeLayer(modelLayer)); diff --git a/net/minecraft/client/renderer/entity/SalmonRenderer.java b/net/minecraft/client/renderer/entity/SalmonRenderer.java index c3be7d29..9095e344 100644 --- a/net/minecraft/client/renderer/entity/SalmonRenderer.java +++ b/net/minecraft/client/renderer/entity/SalmonRenderer.java @@ -7,6 +7,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.SalmonModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.SalmonRenderState; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.Mth; @@ -19,7 +20,7 @@ public class SalmonRenderer extends MobRenderer { private static final ResourceLocation SHEEP_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/sheep/sheep.png"); - public SheepRenderer(EntityRendererProvider.Context context) { + public SheepRenderer(Context context) { super(context, new SheepModel(context.bakeLayer(ModelLayers.SHEEP)), new SheepModel(context.bakeLayer(ModelLayers.SHEEP_BABY)), 0.7F); + this.addLayer(new SheepWoolUndercoatLayer(this, context.getModelSet())); this.addLayer(new SheepWoolLayer(this, context.getModelSet())); } diff --git a/net/minecraft/client/renderer/entity/ShulkerBulletRenderer.java b/net/minecraft/client/renderer/entity/ShulkerBulletRenderer.java index 5a3ca11d..305a0e19 100644 --- a/net/minecraft/client/renderer/entity/ShulkerBulletRenderer.java +++ b/net/minecraft/client/renderer/entity/ShulkerBulletRenderer.java @@ -9,6 +9,7 @@ import net.minecraft.client.model.ShulkerBulletModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.ShulkerBulletRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.core.BlockPos; @@ -22,7 +23,7 @@ public class ShulkerBulletRenderer extends EntityRenderer material.texture().withPath((UnaryOperator)(string -> "textures/" + string + ".png"))) .toArray(ResourceLocation[]::new); - public ShulkerRenderer(EntityRendererProvider.Context context) { + public ShulkerRenderer(Context context) { super(context, new ShulkerModel(context.bakeLayer(ModelLayers.SHULKER)), 0.0F); } diff --git a/net/minecraft/client/renderer/entity/SpectralArrowRenderer.java b/net/minecraft/client/renderer/entity/SpectralArrowRenderer.java index c57591c4..27a13d54 100644 --- a/net/minecraft/client/renderer/entity/SpectralArrowRenderer.java +++ b/net/minecraft/client/renderer/entity/SpectralArrowRenderer.java @@ -2,6 +2,7 @@ package net.minecraft.client.renderer.entity; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.ArrowRenderState; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.entity.projectile.SpectralArrow; @@ -10,7 +11,7 @@ import net.minecraft.world.entity.projectile.SpectralArrow; public class SpectralArrowRenderer extends ArrowRenderer { public static final ResourceLocation SPECTRAL_ARROW_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/projectiles/spectral_arrow.png"); - public SpectralArrowRenderer(EntityRendererProvider.Context context) { + public SpectralArrowRenderer(Context context) { super(context); } diff --git a/net/minecraft/client/renderer/entity/SquidRenderer.java b/net/minecraft/client/renderer/entity/SquidRenderer.java index fc9fdbd4..35300513 100644 --- a/net/minecraft/client/renderer/entity/SquidRenderer.java +++ b/net/minecraft/client/renderer/entity/SquidRenderer.java @@ -5,6 +5,7 @@ import com.mojang.math.Axis; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.SquidModel; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.SquidRenderState; import net.minecraft.resources.ResourceLocation; import net.minecraft.util.Mth; @@ -14,7 +15,7 @@ import net.minecraft.world.entity.animal.Squid; public class SquidRenderer extends AgeableMobRenderer { private static final ResourceLocation SQUID_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/squid/squid.png"); - public SquidRenderer(EntityRendererProvider.Context context, SquidModel adultModel, SquidModel babyModel) { + public SquidRenderer(Context context, SquidModel adultModel, SquidModel babyModel) { super(context, adultModel, babyModel, 0.7F); } diff --git a/net/minecraft/client/renderer/entity/StriderRenderer.java b/net/minecraft/client/renderer/entity/StriderRenderer.java index 03359668..624b3504 100644 --- a/net/minecraft/client/renderer/entity/StriderRenderer.java +++ b/net/minecraft/client/renderer/entity/StriderRenderer.java @@ -4,9 +4,12 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.StriderModel; import net.minecraft.client.model.geom.ModelLayers; -import net.minecraft.client.renderer.entity.layers.SaddleLayer; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; +import net.minecraft.client.renderer.entity.layers.SimpleEquipmentLayer; import net.minecraft.client.renderer.entity.state.StriderRenderState; +import net.minecraft.client.resources.model.EquipmentClientInfo; import net.minecraft.resources.ResourceLocation; +import net.minecraft.world.entity.EquipmentSlot; import net.minecraft.world.entity.monster.Strider; @Environment(EnvType.CLIENT) @@ -15,14 +18,16 @@ public class StriderRenderer extends AgeableMobRenderer( + new SimpleEquipmentLayer<>( this, + context.getEquipmentRenderer(), + EquipmentClientInfo.LayerType.STRIDER_SADDLE, + striderRenderState -> striderRenderState.saddle, new StriderModel(context.bakeLayer(ModelLayers.STRIDER_SADDLE)), - new StriderModel(context.bakeLayer(ModelLayers.STRIDER_BABY_SADDLE)), - ResourceLocation.withDefaultNamespace("textures/entity/strider/strider_saddle.png") + new StriderModel(context.bakeLayer(ModelLayers.STRIDER_BABY_SADDLE)) ) ); } @@ -42,7 +47,7 @@ public class StriderRenderer extends AgeableMobRenderer extends EntityR private final float scale; private final boolean fullBright; - public ThrownItemRenderer(EntityRendererProvider.Context context, float scale, boolean fullBright) { + public ThrownItemRenderer(Context context, float scale, boolean fullBright) { super(context); this.itemModelResolver = context.getItemModelResolver(); this.scale = scale; this.fullBright = fullBright; } - public ThrownItemRenderer(EntityRendererProvider.Context context) { + public ThrownItemRenderer(Context context) { this(context, 1.0F, false); } diff --git a/net/minecraft/client/renderer/entity/ThrownTridentRenderer.java b/net/minecraft/client/renderer/entity/ThrownTridentRenderer.java index 9c2d37ae..1bddca12 100644 --- a/net/minecraft/client/renderer/entity/ThrownTridentRenderer.java +++ b/net/minecraft/client/renderer/entity/ThrownTridentRenderer.java @@ -8,6 +8,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.TridentModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.ThrownTridentRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -18,7 +19,7 @@ public class ThrownTridentRenderer extends EntityRenderer { private final BlockRenderDispatcher blockRenderer; - public TntMinecartRenderer(EntityRendererProvider.Context context) { + public TntMinecartRenderer(Context context) { super(context, ModelLayers.TNT_MINECART); this.blockRenderer = context.getBlockRenderDispatcher(); } diff --git a/net/minecraft/client/renderer/entity/TntRenderer.java b/net/minecraft/client/renderer/entity/TntRenderer.java index 0c866884..3d3a349b 100644 --- a/net/minecraft/client/renderer/entity/TntRenderer.java +++ b/net/minecraft/client/renderer/entity/TntRenderer.java @@ -6,6 +6,7 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.block.BlockRenderDispatcher; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.TntRenderState; import net.minecraft.util.Mth; import net.minecraft.world.entity.item.PrimedTnt; @@ -14,7 +15,7 @@ import net.minecraft.world.entity.item.PrimedTnt; public class TntRenderer extends EntityRenderer { private final BlockRenderDispatcher blockRenderer; - public TntRenderer(EntityRendererProvider.Context context) { + public TntRenderer(Context context) { super(context); this.shadowRadius = 0.5F; this.blockRenderer = context.getBlockRenderDispatcher(); diff --git a/net/minecraft/client/renderer/entity/TropicalFishRenderer.java b/net/minecraft/client/renderer/entity/TropicalFishRenderer.java index 20945167..1bc8b413 100644 --- a/net/minecraft/client/renderer/entity/TropicalFishRenderer.java +++ b/net/minecraft/client/renderer/entity/TropicalFishRenderer.java @@ -9,6 +9,7 @@ import net.minecraft.client.model.TropicalFishModelA; import net.minecraft.client.model.TropicalFishModelB; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.layers.TropicalFishPatternLayer; import net.minecraft.client.renderer.entity.state.TropicalFishRenderState; import net.minecraft.resources.ResourceLocation; @@ -28,14 +29,14 @@ public class TropicalFishRenderer extends MobRenderer MODEL_A_TEXTURE; case LARGE -> MODEL_B_TEXTURE; }; @@ -47,13 +48,13 @@ public class TropicalFishRenderer extends MobRenderer this.modelA; case LARGE -> this.modelB; }; diff --git a/net/minecraft/client/renderer/entity/UndeadHorseRenderer.java b/net/minecraft/client/renderer/entity/UndeadHorseRenderer.java index 1b9cdc92..0e6cf506 100644 --- a/net/minecraft/client/renderer/entity/UndeadHorseRenderer.java +++ b/net/minecraft/client/renderer/entity/UndeadHorseRenderer.java @@ -3,23 +3,34 @@ package net.minecraft.client.renderer.entity; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.AbstractEquineModel; +import net.minecraft.client.model.EquineSaddleModel; import net.minecraft.client.model.HorseModel; import net.minecraft.client.model.geom.ModelLayerLocation; +import net.minecraft.client.model.geom.ModelLayers; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; +import net.minecraft.client.renderer.entity.layers.SimpleEquipmentLayer; import net.minecraft.client.renderer.entity.state.EquineRenderState; +import net.minecraft.client.resources.model.EquipmentClientInfo; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.entity.animal.horse.AbstractHorse; @Environment(EnvType.CLIENT) public class UndeadHorseRenderer extends AbstractHorseRenderer> { - private static final ResourceLocation ZOMBIE_TEXTURE = ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_zombie.png"); - private static final ResourceLocation SKELETON_TEXTURE = ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_skeleton.png"); private final ResourceLocation texture; - public UndeadHorseRenderer( - EntityRendererProvider.Context context, ModelLayerLocation adultModelLayer, ModelLayerLocation babyModelLayer, boolean skeletonHorse - ) { - super(context, new HorseModel(context.bakeLayer(adultModelLayer)), new HorseModel(context.bakeLayer(babyModelLayer))); - this.texture = skeletonHorse ? SKELETON_TEXTURE : ZOMBIE_TEXTURE; + public UndeadHorseRenderer(Context context, UndeadHorseRenderer.Type type) { + super(context, new HorseModel(context.bakeLayer(type.model)), new HorseModel(context.bakeLayer(type.babyModel))); + this.texture = type.texture; + this.addLayer( + new SimpleEquipmentLayer<>( + this, + context.getEquipmentRenderer(), + type.saddleLayer, + equineRenderState -> equineRenderState.saddle, + new EquineSaddleModel(context.bakeLayer(type.saddleModel)), + new EquineSaddleModel(context.bakeLayer(type.babySaddleModel)) + ) + ); } public ResourceLocation getTextureLocation(EquineRenderState equineRenderState) { @@ -29,4 +40,47 @@ public class UndeadHorseRenderer extends AbstractHorseRenderer { private static final ResourceLocation VINDICATOR = ResourceLocation.withDefaultNamespace("textures/entity/illager/vindicator.png"); - public VindicatorRenderer(EntityRendererProvider.Context context) { + public VindicatorRenderer(Context context) { super(context, new IllagerModel<>(context.bakeLayer(ModelLayers.VINDICATOR)), 0.5F); this.addLayer(new ItemInHandLayer>(this) { public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, IllagerRenderState illagerRenderState, float f, float g) { diff --git a/net/minecraft/client/renderer/entity/WindChargeRenderer.java b/net/minecraft/client/renderer/entity/WindChargeRenderer.java index ca12f14c..f0f7e10f 100644 --- a/net/minecraft/client/renderer/entity/WindChargeRenderer.java +++ b/net/minecraft/client/renderer/entity/WindChargeRenderer.java @@ -8,6 +8,7 @@ import net.minecraft.client.model.WindChargeModel; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.EntityRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; import net.minecraft.resources.ResourceLocation; @@ -18,7 +19,7 @@ public class WindChargeRenderer extends EntityRenderer { - public WolfRenderer(EntityRendererProvider.Context context) { + public WolfRenderer(Context context) { super(context, new WolfModel(context.bakeLayer(ModelLayers.WOLF)), new WolfModel(context.bakeLayer(ModelLayers.WOLF_BABY)), 0.5F); this.addLayer(new WolfArmorLayer(this, context.getModelSet(), context.getEquipmentRenderer())); this.addLayer(new WolfCollarLayer(this)); diff --git a/net/minecraft/client/renderer/entity/ZombifiedPiglinRenderer.java b/net/minecraft/client/renderer/entity/ZombifiedPiglinRenderer.java index c86616f0..50a9d057 100644 --- a/net/minecraft/client/renderer/entity/ZombifiedPiglinRenderer.java +++ b/net/minecraft/client/renderer/entity/ZombifiedPiglinRenderer.java @@ -5,6 +5,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.HumanoidArmorModel; import net.minecraft.client.model.ZombifiedPiglinModel; import net.minecraft.client.model.geom.ModelLayerLocation; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.layers.HumanoidArmorLayer; import net.minecraft.client.renderer.entity.state.ZombifiedPiglinRenderState; import net.minecraft.resources.ResourceLocation; @@ -15,7 +16,7 @@ public class ZombifiedPiglinRenderer extends HumanoidMobRenderer extends StuckInBodyLayer { - public ArrowLayer(LivingEntityRenderer renderer, EntityRendererProvider.Context context) { + public ArrowLayer(LivingEntityRenderer renderer, Context context) { super(renderer, new ArrowModel(context.bakeLayer(ModelLayers.ARROW)), TippableArrowRenderer.NORMAL_ARROW_LOCATION, StuckInBodyLayer.PlacementStyle.IN_CUBE); } diff --git a/net/minecraft/client/renderer/entity/layers/BeeStingerLayer.java b/net/minecraft/client/renderer/entity/layers/BeeStingerLayer.java index 3eb4d21e..b356c840 100644 --- a/net/minecraft/client/renderer/entity/layers/BeeStingerLayer.java +++ b/net/minecraft/client/renderer/entity/layers/BeeStingerLayer.java @@ -5,8 +5,8 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.BeeStingerModel; import net.minecraft.client.model.PlayerModel; import net.minecraft.client.model.geom.ModelLayers; -import net.minecraft.client.renderer.entity.EntityRendererProvider; import net.minecraft.client.renderer.entity.LivingEntityRenderer; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.state.PlayerRenderState; import net.minecraft.resources.ResourceLocation; @@ -14,7 +14,7 @@ import net.minecraft.resources.ResourceLocation; public class BeeStingerLayer extends StuckInBodyLayer { private static final ResourceLocation BEE_STINGER_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/bee/bee_stinger.png"); - public BeeStingerLayer(LivingEntityRenderer renderer, EntityRendererProvider.Context context) { + public BeeStingerLayer(LivingEntityRenderer renderer, Context context) { super(renderer, new BeeStingerModel(context.bakeLayer(ModelLayers.BEE_STINGER)), BEE_STINGER_LOCATION, StuckInBodyLayer.PlacementStyle.ON_SURFACE); } diff --git a/net/minecraft/client/renderer/entity/layers/CustomHeadLayer.java b/net/minecraft/client/renderer/entity/layers/CustomHeadLayer.java index 1d78b8cf..219ca90d 100644 --- a/net/minecraft/client/renderer/entity/layers/CustomHeadLayer.java +++ b/net/minecraft/client/renderer/entity/layers/CustomHeadLayer.java @@ -16,14 +16,14 @@ import net.minecraft.client.renderer.blockentity.SkullBlockRenderer; import net.minecraft.client.renderer.entity.RenderLayerParent; import net.minecraft.client.renderer.entity.state.LivingEntityRenderState; import net.minecraft.client.renderer.texture.OverlayTexture; -import net.minecraft.world.level.block.SkullBlock.Type; +import net.minecraft.world.level.block.SkullBlock; @Environment(EnvType.CLIENT) public class CustomHeadLayer & HeadedModel> extends RenderLayer { private static final float ITEM_SCALE = 0.625F; private static final float SKULL_SCALE = 1.1875F; private final CustomHeadLayer.Transforms transforms; - private final Function skullModels; + private final Function skullModels; public CustomHeadLayer(RenderLayerParent renderer, EntityModelSet modelSet) { this(renderer, modelSet, CustomHeadLayer.Transforms.DEFAULT); @@ -32,7 +32,7 @@ public class CustomHeadLayer renderer, EntityModelSet modelSet, CustomHeadLayer.Transforms transforms) { super(renderer); this.transforms = transforms; - this.skullModels = Util.memoize((Function)(type -> SkullBlockRenderer.createModel(modelSet, type))); + this.skullModels = Util.memoize((Function)(type -> SkullBlockRenderer.createModel(modelSet, type))); } public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, S livingEntityRenderState, float f, float g) { @@ -46,7 +46,7 @@ public class CustomHeadLayer)(layerTextureKey -> layerTextureKey.layer.getTextureLocation(layerTextureKey.layerType)) ); this.trimSpriteLookup = Util.memoize( - (Function)(trimSpriteKey -> atlas.getSprite(trimSpriteKey.textureId())) + (Function)(trimSpriteKey -> atlas.getSprite(trimSpriteKey.spriteId())) ); } @@ -73,7 +69,7 @@ public class EquipmentLayerRenderer { ) { List list = this.equipmentAssets.get(equipmentAsset).getLayers(layerType); if (!list.isEmpty()) { - int i = item.is(ItemTags.DYEABLE) ? DyedItemColor.getOrDefault(item, 0) : 0; + int i = DyedItemColor.getOrDefault(item, 0); boolean bl = item.hasFoil(); for (EquipmentClientInfo.Layer layer : list) { @@ -114,15 +110,8 @@ public class EquipmentLayerRenderer { @Environment(EnvType.CLIENT) record TrimSpriteKey(ArmorTrim trim, EquipmentClientInfo.LayerType layerType, ResourceKey equipmentAssetId) { - private static String getColorPaletteSuffix(Holder trimMaterial, ResourceKey equipmentAsset) { - String string = (String)trimMaterial.value().overrideArmorAssets().get(equipmentAsset); - return string != null ? string : trimMaterial.value().assetName(); - } - - public ResourceLocation textureId() { - ResourceLocation resourceLocation = this.trim.pattern().value().assetId(); - String string = getColorPaletteSuffix(this.trim.material(), this.equipmentAssetId); - return resourceLocation.withPath((UnaryOperator)(string2 -> "trims/entity/" + this.layerType.getSerializedName() + "/" + string2 + "_" + string)); + public ResourceLocation spriteId() { + return this.trim.layerAssetId(this.layerType.trimAssetPrefix(), this.equipmentAssetId); } } } diff --git a/net/minecraft/client/renderer/entity/layers/HorseArmorLayer.java b/net/minecraft/client/renderer/entity/layers/HorseArmorLayer.java deleted file mode 100644 index f88d7a3a..00000000 --- a/net/minecraft/client/renderer/entity/layers/HorseArmorLayer.java +++ /dev/null @@ -1,44 +0,0 @@ -package net.minecraft.client.renderer.entity.layers; - -import com.mojang.blaze3d.vertex.PoseStack; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.model.HorseModel; -import net.minecraft.client.model.geom.EntityModelSet; -import net.minecraft.client.model.geom.ModelLayers; -import net.minecraft.client.renderer.MultiBufferSource; -import net.minecraft.client.renderer.entity.RenderLayerParent; -import net.minecraft.client.renderer.entity.state.HorseRenderState; -import net.minecraft.client.resources.model.EquipmentClientInfo; -import net.minecraft.core.component.DataComponents; -import net.minecraft.resources.ResourceKey; -import net.minecraft.world.item.ItemStack; -import net.minecraft.world.item.equipment.EquipmentAsset; -import net.minecraft.world.item.equipment.Equippable; - -@Environment(EnvType.CLIENT) -public class HorseArmorLayer extends RenderLayer { - private final HorseModel adultModel; - private final HorseModel babyModel; - private final EquipmentLayerRenderer equipmentRenderer; - - public HorseArmorLayer(RenderLayerParent renderer, EntityModelSet entityModels, EquipmentLayerRenderer equipmentRenderer) { - super(renderer); - this.equipmentRenderer = equipmentRenderer; - this.adultModel = new HorseModel(entityModels.bakeLayer(ModelLayers.HORSE_ARMOR)); - this.babyModel = new HorseModel(entityModels.bakeLayer(ModelLayers.HORSE_BABY_ARMOR)); - } - - public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, HorseRenderState horseRenderState, float f, float g) { - ItemStack itemStack = horseRenderState.bodyArmorItem; - Equippable equippable = itemStack.get(DataComponents.EQUIPPABLE); - if (equippable != null && !equippable.assetId().isEmpty()) { - HorseModel horseModel = horseRenderState.isBaby ? this.babyModel : this.adultModel; - horseModel.setupAnim(horseRenderState); - this.equipmentRenderer - .renderLayers( - EquipmentClientInfo.LayerType.HORSE_BODY, (ResourceKey)equippable.assetId().get(), horseModel, itemStack, poseStack, multiBufferSource, i - ); - } - } -} diff --git a/net/minecraft/client/renderer/entity/layers/HorseMarkingLayer.java b/net/minecraft/client/renderer/entity/layers/HorseMarkingLayer.java index 5eddf6f5..015beda3 100644 --- a/net/minecraft/client/renderer/entity/layers/HorseMarkingLayer.java +++ b/net/minecraft/client/renderer/entity/layers/HorseMarkingLayer.java @@ -6,7 +6,6 @@ import com.mojang.blaze3d.vertex.VertexConsumer; import java.util.Map; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.Util; import net.minecraft.client.model.HorseModel; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; @@ -18,13 +17,21 @@ import net.minecraft.world.entity.animal.horse.Markings; @Environment(EnvType.CLIENT) public class HorseMarkingLayer extends RenderLayer { - private static final Map LOCATION_BY_MARKINGS = Util.make(Maps.newEnumMap(Markings.class), enumMap -> { - enumMap.put(Markings.NONE, null); - enumMap.put(Markings.WHITE, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_markings_white.png")); - enumMap.put(Markings.WHITE_FIELD, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_markings_whitefield.png")); - enumMap.put(Markings.WHITE_DOTS, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_markings_whitedots.png")); - enumMap.put(Markings.BLACK_DOTS, ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_markings_blackdots.png")); - }); + private static final ResourceLocation INVISIBLE_TEXTURE = ResourceLocation.withDefaultNamespace("invisible"); + private static final Map LOCATION_BY_MARKINGS = Maps.newEnumMap( + Map.of( + Markings.NONE, + INVISIBLE_TEXTURE, + Markings.WHITE, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_markings_white.png"), + Markings.WHITE_FIELD, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_markings_whitefield.png"), + Markings.WHITE_DOTS, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_markings_whitedots.png"), + Markings.BLACK_DOTS, + ResourceLocation.withDefaultNamespace("textures/entity/horse/horse_markings_blackdots.png") + ) + ); public HorseMarkingLayer(RenderLayerParent renderLayerParent) { super(renderLayerParent); @@ -32,7 +39,7 @@ public class HorseMarkingLayer extends RenderLayer public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, HorseRenderState horseRenderState, float f, float g) { ResourceLocation resourceLocation = (ResourceLocation)LOCATION_BY_MARKINGS.get(horseRenderState.markings); - if (resourceLocation != null && !horseRenderState.isInvisible) { + if (resourceLocation != INVISIBLE_TEXTURE && !horseRenderState.isInvisible) { VertexConsumer vertexConsumer = multiBufferSource.getBuffer(RenderType.entityTranslucent(resourceLocation)); this.getParentModel().renderToBuffer(poseStack, vertexConsumer, i, LivingEntityRenderer.getOverlayCoords(horseRenderState, 0.0F)); } diff --git a/net/minecraft/client/renderer/entity/layers/MushroomCowMushroomLayer.java b/net/minecraft/client/renderer/entity/layers/MushroomCowMushroomLayer.java index 14be15b4..0e0e7619 100644 --- a/net/minecraft/client/renderer/entity/layers/MushroomCowMushroomLayer.java +++ b/net/minecraft/client/renderer/entity/layers/MushroomCowMushroomLayer.java @@ -8,11 +8,12 @@ import net.minecraft.client.model.CowModel; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.block.BlockRenderDispatcher; +import net.minecraft.client.renderer.block.ModelBlockRenderer; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.client.renderer.entity.LivingEntityRenderer; import net.minecraft.client.renderer.entity.RenderLayerParent; import net.minecraft.client.renderer.entity.state.MushroomCowRenderState; import net.minecraft.client.renderer.texture.TextureAtlas; -import net.minecraft.client.resources.model.BakedModel; import net.minecraft.world.level.block.state.BlockState; @Environment(EnvType.CLIENT) @@ -30,13 +31,13 @@ public class MushroomCowMushroomLayer extends RenderLayer> extends RenderLayer { - private final ResourceLocation textureLocation; - private final M adultModel; - private final M babyModel; - - public SaddleLayer(RenderLayerParent renderer, M adultModel, M babyModel, ResourceLocation textureLocation) { - super(renderer); - this.adultModel = adultModel; - this.babyModel = babyModel; - this.textureLocation = textureLocation; - } - - public SaddleLayer(RenderLayerParent renderer, M model, ResourceLocation textureLocation) { - this(renderer, model, model, textureLocation); - } - - public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, S livingEntityRenderState, float f, float g) { - if (livingEntityRenderState.isSaddled()) { - M entityModel = livingEntityRenderState.isBaby ? this.babyModel : this.adultModel; - entityModel.setupAnim(livingEntityRenderState); - VertexConsumer vertexConsumer = multiBufferSource.getBuffer(RenderType.entityCutoutNoCull(this.textureLocation)); - entityModel.renderToBuffer(poseStack, vertexConsumer, i, OverlayTexture.NO_OVERLAY); - } - } -} diff --git a/net/minecraft/client/renderer/entity/layers/SheepWoolLayer.java b/net/minecraft/client/renderer/entity/layers/SheepWoolLayer.java index 8808310d..e225b805 100644 --- a/net/minecraft/client/renderer/entity/layers/SheepWoolLayer.java +++ b/net/minecraft/client/renderer/entity/layers/SheepWoolLayer.java @@ -15,14 +15,10 @@ import net.minecraft.client.renderer.entity.LivingEntityRenderer; import net.minecraft.client.renderer.entity.RenderLayerParent; import net.minecraft.client.renderer.entity.state.SheepRenderState; import net.minecraft.resources.ResourceLocation; -import net.minecraft.util.ARGB; -import net.minecraft.util.Mth; -import net.minecraft.world.entity.animal.Sheep; -import net.minecraft.world.item.DyeColor; @Environment(EnvType.CLIENT) public class SheepWoolLayer extends RenderLayer { - private static final ResourceLocation SHEEP_FUR_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/sheep/sheep_fur.png"); + private static final ResourceLocation SHEEP_WOOL_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/sheep/sheep_wool.png"); private final EntityModel adultModel; private final EntityModel babyModel; @@ -38,27 +34,11 @@ public class SheepWoolLayer extends RenderLayer { if (sheepRenderState.isInvisible) { if (sheepRenderState.appearsGlowing) { entityModel.setupAnim(sheepRenderState); - VertexConsumer vertexConsumer = multiBufferSource.getBuffer(RenderType.outline(SHEEP_FUR_LOCATION)); + VertexConsumer vertexConsumer = multiBufferSource.getBuffer(RenderType.outline(SHEEP_WOOL_LOCATION)); entityModel.renderToBuffer(poseStack, vertexConsumer, i, LivingEntityRenderer.getOverlayCoords(sheepRenderState, 0.0F), -16777216); } } else { - int r; - if (sheepRenderState.customName != null && "jeb_".equals(sheepRenderState.customName.getString())) { - int j = 25; - int k = Mth.floor(sheepRenderState.ageInTicks); - int l = k / 25 + sheepRenderState.id; - int m = DyeColor.values().length; - int n = l % m; - int o = (l + 1) % m; - float h = (k % 25 + Mth.frac(sheepRenderState.ageInTicks)) / 25.0F; - int p = Sheep.getColor(DyeColor.byId(n)); - int q = Sheep.getColor(DyeColor.byId(o)); - r = ARGB.lerp(h, p, q); - } else { - r = Sheep.getColor(sheepRenderState.woolColor); - } - - coloredCutoutModelCopyLayerRender(entityModel, SHEEP_FUR_LOCATION, poseStack, multiBufferSource, i, sheepRenderState, r); + coloredCutoutModelCopyLayerRender(entityModel, SHEEP_WOOL_LOCATION, poseStack, multiBufferSource, i, sheepRenderState, sheepRenderState.getWoolColor()); } } } diff --git a/net/minecraft/client/renderer/entity/layers/SheepWoolUndercoatLayer.java b/net/minecraft/client/renderer/entity/layers/SheepWoolUndercoatLayer.java new file mode 100644 index 00000000..5b4e222d --- /dev/null +++ b/net/minecraft/client/renderer/entity/layers/SheepWoolUndercoatLayer.java @@ -0,0 +1,37 @@ +package net.minecraft.client.renderer.entity.layers; + +import com.mojang.blaze3d.vertex.PoseStack; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.model.EntityModel; +import net.minecraft.client.model.SheepFurModel; +import net.minecraft.client.model.SheepModel; +import net.minecraft.client.model.geom.EntityModelSet; +import net.minecraft.client.model.geom.ModelLayers; +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.RenderLayerParent; +import net.minecraft.client.renderer.entity.state.SheepRenderState; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.world.item.DyeColor; + +@Environment(EnvType.CLIENT) +public class SheepWoolUndercoatLayer extends RenderLayer { + private static final ResourceLocation SHEEP_WOOL_UNDERCOAT_LOCATION = ResourceLocation.withDefaultNamespace("textures/entity/sheep/sheep_wool_undercoat.png"); + private final EntityModel adultModel; + private final EntityModel babyModel; + + public SheepWoolUndercoatLayer(RenderLayerParent renderer, EntityModelSet modelSet) { + super(renderer); + this.adultModel = new SheepFurModel(modelSet.bakeLayer(ModelLayers.SHEEP_WOOL_UNDERCOAT)); + this.babyModel = new SheepFurModel(modelSet.bakeLayer(ModelLayers.SHEEP_BABY_WOOL_UNDERCOAT)); + } + + public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, SheepRenderState sheepRenderState, float f, float g) { + if (!sheepRenderState.isInvisible && (sheepRenderState.isJebSheep() || sheepRenderState.woolColor != DyeColor.WHITE)) { + EntityModel entityModel = sheepRenderState.isBaby ? this.babyModel : this.adultModel; + coloredCutoutModelCopyLayerRender( + entityModel, SHEEP_WOOL_UNDERCOAT_LOCATION, poseStack, multiBufferSource, i, sheepRenderState, sheepRenderState.getWoolColor() + ); + } + } +} diff --git a/net/minecraft/client/renderer/entity/layers/SimpleEquipmentLayer.java b/net/minecraft/client/renderer/entity/layers/SimpleEquipmentLayer.java new file mode 100644 index 00000000..a51de79e --- /dev/null +++ b/net/minecraft/client/renderer/entity/layers/SimpleEquipmentLayer.java @@ -0,0 +1,59 @@ +package net.minecraft.client.renderer.entity.layers; + +import com.mojang.blaze3d.vertex.PoseStack; +import java.util.function.Function; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.model.EntityModel; +import net.minecraft.client.renderer.MultiBufferSource; +import net.minecraft.client.renderer.entity.RenderLayerParent; +import net.minecraft.client.renderer.entity.state.LivingEntityRenderState; +import net.minecraft.client.resources.model.EquipmentClientInfo; +import net.minecraft.core.component.DataComponents; +import net.minecraft.resources.ResourceKey; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.item.equipment.EquipmentAsset; +import net.minecraft.world.item.equipment.Equippable; + +@Environment(EnvType.CLIENT) +public class SimpleEquipmentLayer, EM extends EntityModel> + extends RenderLayer { + private final EquipmentLayerRenderer equipmentRenderer; + private final EquipmentClientInfo.LayerType layer; + private final Function itemGetter; + private final EM adultModel; + private final EM babyModel; + + public SimpleEquipmentLayer( + RenderLayerParent renderer, + EquipmentLayerRenderer equipmentRenderer, + EquipmentClientInfo.LayerType layer, + Function itemGetter, + EM adultModel, + EM babyModel + ) { + super(renderer); + this.equipmentRenderer = equipmentRenderer; + this.layer = layer; + this.itemGetter = itemGetter; + this.adultModel = adultModel; + this.babyModel = babyModel; + } + + public SimpleEquipmentLayer( + RenderLayerParent renderer, EquipmentLayerRenderer equipmentRenderer, EM model, EquipmentClientInfo.LayerType layer, Function itemGetter + ) { + this(renderer, equipmentRenderer, layer, itemGetter, model, model); + } + + public void render(PoseStack poseStack, MultiBufferSource multiBufferSource, int i, S livingEntityRenderState, float f, float g) { + ItemStack itemStack = (ItemStack)this.itemGetter.apply(livingEntityRenderState); + Equippable equippable = itemStack.get(DataComponents.EQUIPPABLE); + if (equippable != null && !equippable.assetId().isEmpty()) { + EM entityModel = livingEntityRenderState.isBaby ? this.babyModel : this.adultModel; + entityModel.setupAnim(livingEntityRenderState); + this.equipmentRenderer + .renderLayers(this.layer, (ResourceKey)equippable.assetId().get(), entityModel, itemStack, poseStack, multiBufferSource, i); + } + } +} diff --git a/net/minecraft/client/renderer/entity/layers/SnowGolemHeadLayer.java b/net/minecraft/client/renderer/entity/layers/SnowGolemHeadLayer.java index db5b6bf4..07bad114 100644 --- a/net/minecraft/client/renderer/entity/layers/SnowGolemHeadLayer.java +++ b/net/minecraft/client/renderer/entity/layers/SnowGolemHeadLayer.java @@ -10,11 +10,12 @@ import net.minecraft.client.renderer.ItemBlockRenderTypes; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.block.BlockRenderDispatcher; +import net.minecraft.client.renderer.block.ModelBlockRenderer; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.client.renderer.entity.LivingEntityRenderer; import net.minecraft.client.renderer.entity.RenderLayerParent; import net.minecraft.client.renderer.entity.state.SnowGolemRenderState; import net.minecraft.client.renderer.texture.TextureAtlas; -import net.minecraft.client.resources.model.BakedModel; import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.state.BlockState; @@ -37,13 +38,13 @@ public class SnowGolemHeadLayer extends RenderLayer extends RenderLaye for (int k = 0; k < j; k++) { poseStack.pushPose(); ModelPart modelPart = this.getParentModel().getRandomBodyPart(randomSource); - Cube cube = modelPart.getRandomCube(randomSource); + ModelPart.Cube cube = modelPart.getRandomCube(randomSource); modelPart.translateAndRotate(poseStack); float h = randomSource.nextFloat(); float l = randomSource.nextFloat(); diff --git a/net/minecraft/client/renderer/entity/layers/TropicalFishPatternLayer.java b/net/minecraft/client/renderer/entity/layers/TropicalFishPatternLayer.java index c0142b0f..69201818 100644 --- a/net/minecraft/client/renderer/entity/layers/TropicalFishPatternLayer.java +++ b/net/minecraft/client/renderer/entity/layers/TropicalFishPatternLayer.java @@ -38,7 +38,7 @@ public class TropicalFishPatternLayer extends RenderLayer entityModel = (EntityModel)(switch (pattern.base()) { case SMALL -> this.modelA; diff --git a/net/minecraft/client/renderer/entity/layers/VillagerProfessionLayer.java b/net/minecraft/client/renderer/entity/layers/VillagerProfessionLayer.java index bfa125c0..e903a17b 100644 --- a/net/minecraft/client/renderer/entity/layers/VillagerProfessionLayer.java +++ b/net/minecraft/client/renderer/entity/layers/VillagerProfessionLayer.java @@ -17,9 +17,10 @@ import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.entity.RenderLayerParent; import net.minecraft.client.renderer.entity.state.LivingEntityRenderState; import net.minecraft.client.renderer.entity.state.VillagerDataHolderRenderState; +import net.minecraft.client.renderer.texture.MissingTextureAtlasSprite; import net.minecraft.client.resources.metadata.animation.VillagerMetadataSection; -import net.minecraft.core.DefaultedRegistry; -import net.minecraft.core.registries.BuiltInRegistries; +import net.minecraft.core.Holder; +import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.util.Mth; @@ -37,8 +38,8 @@ public class VillagerProfessionLayer typeHatCache = new Object2ObjectOpenHashMap<>(); - private final Object2ObjectMap professionHatCache = new Object2ObjectOpenHashMap<>(); + private final Object2ObjectMap, VillagerMetadataSection.Hat> typeHatCache = new Object2ObjectOpenHashMap<>(); + private final Object2ObjectMap, VillagerMetadataSection.Hat> professionHatCache = new Object2ObjectOpenHashMap<>(); private final ResourceManager resourceManager; private final String path; @@ -51,23 +52,25 @@ public class VillagerProfessionLayer holder = villagerData.type(); + Holder holder2 = villagerData.profession(); + VillagerMetadataSection.Hat hat = this.getHatData(this.typeHatCache, "type", holder); + VillagerMetadataSection.Hat hat2 = this.getHatData(this.professionHatCache, "profession", holder2); + M entityModel = this.getParentModel(); + entityModel.hatVisible(hat2 == VillagerMetadataSection.Hat.NONE || hat2 == VillagerMetadataSection.Hat.PARTIAL && hat != VillagerMetadataSection.Hat.FULL); + ResourceLocation resourceLocation = this.getResourceLocation("type", holder); + renderColoredCutoutModel(entityModel, resourceLocation, poseStack, multiBufferSource, i, livingEntityRenderState, -1); + entityModel.hatVisible(true); + if (!holder2.is(VillagerProfession.NONE) && !livingEntityRenderState.isBaby) { + ResourceLocation resourceLocation2 = this.getResourceLocation("profession", holder2); + renderColoredCutoutModel(entityModel, resourceLocation2, poseStack, multiBufferSource, i, livingEntityRenderState, -1); + if (!holder2.is(VillagerProfession.NITWIT)) { + ResourceLocation resourceLocation3 = this.getResourceLocation( + "profession_level", LEVEL_LOCATIONS.get(Mth.clamp(villagerData.level(), 1, LEVEL_LOCATIONS.size())) + ); + renderColoredCutoutModel(entityModel, resourceLocation3, poseStack, multiBufferSource, i, livingEntityRenderState, -1); + } } } } @@ -77,15 +80,25 @@ public class VillagerProfessionLayer)(string2 -> "textures/entity/" + this.path + "/" + folder + "/" + string2 + ".png")); } - public VillagerMetadataSection.Hat getHatData(Object2ObjectMap cache, String folder, DefaultedRegistry registry, K key) { - return cache.computeIfAbsent( - key, object2 -> (VillagerMetadataSection.Hat)this.resourceManager.getResource(this.getResourceLocation(folder, registry.getKey(key))).flatMap(resource -> { - try { - return resource.metadata().getSection(VillagerMetadataSection.TYPE).map(VillagerMetadataSection::hat); - } catch (IOException var2) { - return Optional.empty(); - } - }).orElse(VillagerMetadataSection.Hat.NONE) - ); + private ResourceLocation getResourceLocation(String folder, Holder holder) { + return (ResourceLocation)holder.unwrapKey() + .map(resourceKey -> this.getResourceLocation(folder, resourceKey.location())) + .orElse(MissingTextureAtlasSprite.getLocation()); + } + + public VillagerMetadataSection.Hat getHatData(Object2ObjectMap, VillagerMetadataSection.Hat> cache, String folder, Holder key) { + ResourceKey resourceKey = (ResourceKey)key.unwrapKey().orElse(null); + return resourceKey == null + ? VillagerMetadataSection.Hat.NONE + : cache.computeIfAbsent( + resourceKey, + object -> (VillagerMetadataSection.Hat)this.resourceManager.getResource(this.getResourceLocation(folder, resourceKey.location())).flatMap(resource -> { + try { + return resource.metadata().getSection(VillagerMetadataSection.TYPE).map(VillagerMetadataSection::hat); + } catch (IOException var2) { + return Optional.empty(); + } + }).orElse(VillagerMetadataSection.Hat.NONE) + ); } } diff --git a/net/minecraft/client/renderer/entity/player/PlayerRenderer.java b/net/minecraft/client/renderer/entity/player/PlayerRenderer.java index 647e09a2..8b2a2916 100644 --- a/net/minecraft/client/renderer/entity/player/PlayerRenderer.java +++ b/net/minecraft/client/renderer/entity/player/PlayerRenderer.java @@ -5,16 +5,16 @@ import com.mojang.math.Axis; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.HumanoidArmorModel; -import net.minecraft.client.model.HumanoidModel; import net.minecraft.client.model.PlayerModel; +import net.minecraft.client.model.HumanoidModel.ArmPose; import net.minecraft.client.model.geom.ModelLayers; import net.minecraft.client.model.geom.ModelPart; import net.minecraft.client.player.AbstractClientPlayer; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; -import net.minecraft.client.renderer.entity.EntityRendererProvider; import net.minecraft.client.renderer.entity.HumanoidMobRenderer; import net.minecraft.client.renderer.entity.LivingEntityRenderer; +import net.minecraft.client.renderer.entity.EntityRendererProvider.Context; import net.minecraft.client.renderer.entity.layers.ArrowLayer; import net.minecraft.client.renderer.entity.layers.BeeStingerLayer; import net.minecraft.client.renderer.entity.layers.CapeLayer; @@ -53,7 +53,7 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class PlayerRenderer extends LivingEntityRenderer { - public PlayerRenderer(EntityRendererProvider.Context context, boolean useSlimModel) { + public PlayerRenderer(Context context, boolean useSlimModel) { super(context, new PlayerModel(context.bakeLayer(useSlimModel ? ModelLayers.PLAYER_SLIM : ModelLayers.PLAYER), useSlimModel), 0.5F); this.addLayer( new HumanoidArmorLayer<>( @@ -83,56 +83,56 @@ public class PlayerRenderer extends LivingEntityRenderer 0) { ItemUseAnimation itemUseAnimation = stack.getUseAnimation(); if (itemUseAnimation == ItemUseAnimation.BLOCK) { - return HumanoidModel.ArmPose.BLOCK; + return ArmPose.BLOCK; } if (itemUseAnimation == ItemUseAnimation.BOW) { - return HumanoidModel.ArmPose.BOW_AND_ARROW; + return ArmPose.BOW_AND_ARROW; } if (itemUseAnimation == ItemUseAnimation.SPEAR) { - return HumanoidModel.ArmPose.THROW_SPEAR; + return ArmPose.THROW_SPEAR; } if (itemUseAnimation == ItemUseAnimation.CROSSBOW) { - return HumanoidModel.ArmPose.CROSSBOW_CHARGE; + return ArmPose.CROSSBOW_CHARGE; } if (itemUseAnimation == ItemUseAnimation.SPYGLASS) { - return HumanoidModel.ArmPose.SPYGLASS; + return ArmPose.SPYGLASS; } if (itemUseAnimation == ItemUseAnimation.TOOT_HORN) { - return HumanoidModel.ArmPose.TOOT_HORN; + return ArmPose.TOOT_HORN; } if (itemUseAnimation == ItemUseAnimation.BRUSH) { - return HumanoidModel.ArmPose.BRUSH; + return ArmPose.BRUSH; } - } else if (!player.swinging && stack.is(Items.CROSSBOW) && CrossbowItem.isCharged(stack)) { - return HumanoidModel.ArmPose.CROSSBOW_HOLD; } - return HumanoidModel.ArmPose.ITEM; + return ArmPose.ITEM; } } @@ -202,7 +202,7 @@ public class PlayerRenderer extends LivingEntityRenderer 0.0 && e > 0.0) { + if (vec32.horizontalDistanceSqr() > 1.0E-5F && vec3.horizontalDistanceSqr() > 1.0E-5F) { renderState.shouldApplyFlyingYRot = true; - double f = Math.min(1.0, (vec32.x * vec3.x + vec32.z * vec3.z) / Math.sqrt(d * e)); - double g = vec32.x * vec3.z - vec32.z * vec3.x; - renderState.flyingYRot = (float)(Math.signum(g) * Math.acos(f)); + double d = vec32.horizontal().normalize().dot(vec3.horizontal().normalize()); + double e = vec32.x * vec3.z - vec32.z * vec3.x; + renderState.flyingYRot = (float)(Math.signum(e) * Math.acos(Math.min(1.0, Math.abs(d)))); } else { renderState.shouldApplyFlyingYRot = false; renderState.flyingYRot = 0.0F; @@ -246,9 +244,12 @@ public class PlayerRenderer extends LivingEntityRenderer entityType == EntityType.PARROT).isPresent() - ? Parrot.Variant.byId(compoundTag.getInt("Variant")) - : null; + if (compoundTag.isEmpty()) { + return null; + } else { + EntityType entityType = (EntityType)compoundTag.read("id", EntityType.CODEC).orElse(null); + return entityType == EntityType.PARROT ? (Parrot.Variant)compoundTag.read("Variant", Parrot.Variant.LEGACY_CODEC).orElse(Parrot.Variant.RED_BLUE) : null; + } } public void renderRightHand(PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, ResourceLocation skinTexture, boolean isSleeveVisible) { diff --git a/net/minecraft/client/renderer/entity/state/ArmedEntityRenderState.java b/net/minecraft/client/renderer/entity/state/ArmedEntityRenderState.java index 837f2798..34dbb89e 100644 --- a/net/minecraft/client/renderer/entity/state/ArmedEntityRenderState.java +++ b/net/minecraft/client/renderer/entity/state/ArmedEntityRenderState.java @@ -2,7 +2,7 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.model.HumanoidModel; +import net.minecraft.client.model.HumanoidModel.ArmPose; import net.minecraft.client.renderer.item.ItemModelResolver; import net.minecraft.client.renderer.item.ItemStackRenderState; import net.minecraft.world.entity.HumanoidArm; @@ -12,9 +12,9 @@ import net.minecraft.world.item.ItemDisplayContext; @Environment(EnvType.CLIENT) public class ArmedEntityRenderState extends LivingEntityRenderState { public HumanoidArm mainArm = HumanoidArm.RIGHT; - public HumanoidModel.ArmPose rightArmPose = HumanoidModel.ArmPose.EMPTY; + public ArmPose rightArmPose = ArmPose.EMPTY; public final ItemStackRenderState rightHandItem = new ItemStackRenderState(); - public HumanoidModel.ArmPose leftArmPose = HumanoidModel.ArmPose.EMPTY; + public ArmPose leftArmPose = ArmPose.EMPTY; public final ItemStackRenderState leftHandItem = new ItemStackRenderState(); public ItemStackRenderState getMainHandItem() { @@ -23,11 +23,7 @@ public class ArmedEntityRenderState extends LivingEntityRenderState { public static void extractArmedEntityRenderState(LivingEntity entity, ArmedEntityRenderState reusedState, ItemModelResolver itemModelResolver) { reusedState.mainArm = entity.getMainArm(); - itemModelResolver.updateForLiving( - reusedState.rightHandItem, entity.getItemHeldByArm(HumanoidArm.RIGHT), ItemDisplayContext.THIRD_PERSON_RIGHT_HAND, false, entity - ); - itemModelResolver.updateForLiving( - reusedState.leftHandItem, entity.getItemHeldByArm(HumanoidArm.LEFT), ItemDisplayContext.THIRD_PERSON_LEFT_HAND, true, entity - ); + itemModelResolver.updateForLiving(reusedState.rightHandItem, entity.getItemHeldByArm(HumanoidArm.RIGHT), ItemDisplayContext.THIRD_PERSON_RIGHT_HAND, entity); + itemModelResolver.updateForLiving(reusedState.leftHandItem, entity.getItemHeldByArm(HumanoidArm.LEFT), ItemDisplayContext.THIRD_PERSON_LEFT_HAND, entity); } } diff --git a/net/minecraft/client/renderer/entity/state/AxolotlRenderState.java b/net/minecraft/client/renderer/entity/state/AxolotlRenderState.java index 953af65b..179a9ea6 100644 --- a/net/minecraft/client/renderer/entity/state/AxolotlRenderState.java +++ b/net/minecraft/client/renderer/entity/state/AxolotlRenderState.java @@ -2,11 +2,11 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.world.entity.animal.axolotl.Axolotl.Variant; +import net.minecraft.world.entity.animal.axolotl.Axolotl; @Environment(EnvType.CLIENT) public class AxolotlRenderState extends LivingEntityRenderState { - public Variant variant = Variant.LUCY; + public Axolotl.Variant variant = Axolotl.Variant.DEFAULT; public float playingDeadFactor; public float movingFactor; public float inWaterFactor = 1.0F; diff --git a/net/minecraft/client/renderer/entity/state/CamelRenderState.java b/net/minecraft/client/renderer/entity/state/CamelRenderState.java index 503b895f..d407c514 100644 --- a/net/minecraft/client/renderer/entity/state/CamelRenderState.java +++ b/net/minecraft/client/renderer/entity/state/CamelRenderState.java @@ -3,10 +3,11 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.world.entity.AnimationState; +import net.minecraft.world.item.ItemStack; @Environment(EnvType.CLIENT) public class CamelRenderState extends LivingEntityRenderState { - public boolean isSaddled; + public ItemStack saddle = ItemStack.EMPTY; public boolean isRidden; public float jumpCooldown; public final AnimationState sitAnimationState = new AnimationState(); diff --git a/net/minecraft/client/renderer/entity/state/ChickenRenderState.java b/net/minecraft/client/renderer/entity/state/ChickenRenderState.java index 203b2fab..5782d407 100644 --- a/net/minecraft/client/renderer/entity/state/ChickenRenderState.java +++ b/net/minecraft/client/renderer/entity/state/ChickenRenderState.java @@ -2,9 +2,13 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.world.entity.animal.ChickenVariant; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class ChickenRenderState extends LivingEntityRenderState { public float flap; public float flapSpeed; + @Nullable + public ChickenVariant variant; } diff --git a/net/minecraft/client/renderer/entity/state/CowRenderState.java b/net/minecraft/client/renderer/entity/state/CowRenderState.java new file mode 100644 index 00000000..587fc376 --- /dev/null +++ b/net/minecraft/client/renderer/entity/state/CowRenderState.java @@ -0,0 +1,12 @@ +package net.minecraft.client.renderer.entity.state; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.world.entity.animal.CowVariant; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public class CowRenderState extends LivingEntityRenderState { + @Nullable + public CowVariant variant; +} diff --git a/net/minecraft/client/renderer/entity/state/EnderDragonRenderState.java b/net/minecraft/client/renderer/entity/state/EnderDragonRenderState.java index 4447a7ff..9c849659 100644 --- a/net/minecraft/client/renderer/entity/state/EnderDragonRenderState.java +++ b/net/minecraft/client/renderer/entity/state/EnderDragonRenderState.java @@ -3,6 +3,7 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.world.entity.boss.enderdragon.DragonFlightHistory; +import net.minecraft.world.entity.boss.enderdragon.DragonFlightHistory.Sample; import net.minecraft.world.phys.Vec3; import org.jetbrains.annotations.Nullable; @@ -19,11 +20,11 @@ public class EnderDragonRenderState extends EntityRenderState { public float partialTicks; public final DragonFlightHistory flightHistory = new DragonFlightHistory(); - public DragonFlightHistory.Sample getHistoricalPos(int index) { + public Sample getHistoricalPos(int index) { return this.flightHistory.get(index, this.partialTicks); } - public float getHeadPartYOffset(int part, DragonFlightHistory.Sample start, DragonFlightHistory.Sample current) { + public float getHeadPartYOffset(int part, Sample start, Sample current) { double d; if (this.isLandingOrTakingOff) { d = part / Math.max(this.distanceToEgg / 4.0, 1.0); diff --git a/net/minecraft/client/renderer/entity/state/EntityRenderState.java b/net/minecraft/client/renderer/entity/state/EntityRenderState.java index 7e7f8336..f78e2f10 100644 --- a/net/minecraft/client/renderer/entity/state/EntityRenderState.java +++ b/net/minecraft/client/renderer/entity/state/EntityRenderState.java @@ -1,13 +1,17 @@ package net.minecraft.client.renderer.entity.state; +import java.util.Locale; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.CrashReportCategory; import net.minecraft.network.chat.Component; +import net.minecraft.world.entity.EntityType; import net.minecraft.world.phys.Vec3; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class EntityRenderState { + public EntityType entityType; public double x; public double y; public double z; @@ -27,6 +31,15 @@ public class EntityRenderState { public Vec3 nameTagAttachment; @Nullable public EntityRenderState.LeashState leashState; + @Nullable + public HitboxesRenderState hitboxesRenderState; + @Nullable + public ServerHitboxesRenderState serverHitboxesRenderState; + + public void fillCrashReportCategory(CrashReportCategory crashReportCategory) { + crashReportCategory.setDetail("EntityRenderState", this.getClass().getCanonicalName()); + crashReportCategory.setDetail("Entity's Exact location", String.format(Locale.ROOT, "%.2f, %.2f, %.2f", this.x, this.y, this.z)); + } @Environment(EnvType.CLIENT) public static class LeashState { diff --git a/net/minecraft/client/renderer/entity/state/EquineRenderState.java b/net/minecraft/client/renderer/entity/state/EquineRenderState.java index b27dedc5..224db166 100644 --- a/net/minecraft/client/renderer/entity/state/EquineRenderState.java +++ b/net/minecraft/client/renderer/entity/state/EquineRenderState.java @@ -2,10 +2,11 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.world.item.ItemStack; @Environment(EnvType.CLIENT) public class EquineRenderState extends LivingEntityRenderState { - public boolean isSaddled; + public ItemStack saddle = ItemStack.EMPTY; public boolean isRidden; public boolean animateTail; public float eatAnimation; diff --git a/net/minecraft/client/renderer/entity/state/FoxRenderState.java b/net/minecraft/client/renderer/entity/state/FoxRenderState.java index 21ba45f9..6d789a29 100644 --- a/net/minecraft/client/renderer/entity/state/FoxRenderState.java +++ b/net/minecraft/client/renderer/entity/state/FoxRenderState.java @@ -13,5 +13,5 @@ public class FoxRenderState extends HoldingEntityRenderState { public boolean isSitting; public boolean isFaceplanted; public boolean isPouncing; - public Fox.Variant variant = Fox.Variant.RED; + public Fox.Variant variant = Fox.Variant.DEFAULT; } diff --git a/net/minecraft/client/renderer/entity/state/HitboxRenderState.java b/net/minecraft/client/renderer/entity/state/HitboxRenderState.java new file mode 100644 index 00000000..66e380cc --- /dev/null +++ b/net/minecraft/client/renderer/entity/state/HitboxRenderState.java @@ -0,0 +1,13 @@ +package net.minecraft.client.renderer.entity.state; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +public record HitboxRenderState( + double x0, double y0, double z0, double x1, double y1, double z1, float offsetX, float offsetY, float offsetZ, float red, float green, float blue +) { + public HitboxRenderState(double x0, double y0, double z0, double x1, double y1, double z1, float red, float green, float blue) { + this(x0, y0, z0, x1, y1, z1, 0.0F, 0.0F, 0.0F, red, green, blue); + } +} diff --git a/net/minecraft/client/renderer/entity/state/HitboxesRenderState.java b/net/minecraft/client/renderer/entity/state/HitboxesRenderState.java new file mode 100644 index 00000000..7a74e960 --- /dev/null +++ b/net/minecraft/client/renderer/entity/state/HitboxesRenderState.java @@ -0,0 +1,9 @@ +package net.minecraft.client.renderer.entity.state; + +import com.google.common.collect.ImmutableList; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; + +@Environment(EnvType.CLIENT) +public record HitboxesRenderState(double viewX, double viewY, double viewZ, ImmutableList hitboxes) { +} diff --git a/net/minecraft/client/renderer/entity/state/HoldingEntityRenderState.java b/net/minecraft/client/renderer/entity/state/HoldingEntityRenderState.java index e57deee0..6609c03d 100644 --- a/net/minecraft/client/renderer/entity/state/HoldingEntityRenderState.java +++ b/net/minecraft/client/renderer/entity/state/HoldingEntityRenderState.java @@ -12,6 +12,6 @@ public class HoldingEntityRenderState extends LivingEntityRenderState { public final ItemStackRenderState heldItem = new ItemStackRenderState(); public static void extractHoldingEntityRenderState(LivingEntity entity, HoldingEntityRenderState reusedState, ItemModelResolver resolver) { - resolver.updateForLiving(reusedState.heldItem, entity.getMainHandItem(), ItemDisplayContext.GROUND, false, entity); + resolver.updateForLiving(reusedState.heldItem, entity.getMainHandItem(), ItemDisplayContext.GROUND, entity); } } diff --git a/net/minecraft/client/renderer/entity/state/LivingEntityRenderState.java b/net/minecraft/client/renderer/entity/state/LivingEntityRenderState.java index c5d408b0..a0f6447d 100644 --- a/net/minecraft/client/renderer/entity/state/LivingEntityRenderState.java +++ b/net/minecraft/client/renderer/entity/state/LivingEntityRenderState.java @@ -7,7 +7,7 @@ import net.minecraft.core.Direction; import net.minecraft.network.chat.Component; import net.minecraft.world.entity.Pose; import net.minecraft.world.item.component.ResolvableProfile; -import net.minecraft.world.level.block.SkullBlock.Type; +import net.minecraft.world.level.block.SkullBlock; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) @@ -36,7 +36,7 @@ public class LivingEntityRenderState extends EntityRenderState { public final ItemStackRenderState headItem = new ItemStackRenderState(); public float wornHeadAnimationPos; @Nullable - public Type wornHeadType; + public SkullBlock.Type wornHeadType; @Nullable public ResolvableProfile wornHeadProfile; diff --git a/net/minecraft/client/renderer/entity/state/LlamaRenderState.java b/net/minecraft/client/renderer/entity/state/LlamaRenderState.java index 6cde9d20..7b366b01 100644 --- a/net/minecraft/client/renderer/entity/state/LlamaRenderState.java +++ b/net/minecraft/client/renderer/entity/state/LlamaRenderState.java @@ -7,7 +7,7 @@ import net.minecraft.world.item.ItemStack; @Environment(EnvType.CLIENT) public class LlamaRenderState extends LivingEntityRenderState { - public Llama.Variant variant = Llama.Variant.CREAMY; + public Llama.Variant variant = Llama.Variant.DEFAULT; public boolean hasChest; public ItemStack bodyItem = ItemStack.EMPTY; public boolean isTraderLlama; diff --git a/net/minecraft/client/renderer/entity/state/PandaRenderState.java b/net/minecraft/client/renderer/entity/state/PandaRenderState.java index e6e87899..c6b069e1 100644 --- a/net/minecraft/client/renderer/entity/state/PandaRenderState.java +++ b/net/minecraft/client/renderer/entity/state/PandaRenderState.java @@ -2,11 +2,11 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.world.entity.animal.Panda.Gene; +import net.minecraft.world.entity.animal.Panda; @Environment(EnvType.CLIENT) public class PandaRenderState extends HoldingEntityRenderState { - public Gene variant = Gene.NORMAL; + public Panda.Gene variant = Panda.Gene.NORMAL; public boolean isUnhappy; public boolean isSneezing; public int sneezeTime; diff --git a/net/minecraft/client/renderer/entity/state/PigRenderState.java b/net/minecraft/client/renderer/entity/state/PigRenderState.java index f7f82f7e..fed9a0ee 100644 --- a/net/minecraft/client/renderer/entity/state/PigRenderState.java +++ b/net/minecraft/client/renderer/entity/state/PigRenderState.java @@ -2,13 +2,13 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.world.entity.animal.PigVariant; +import net.minecraft.world.item.ItemStack; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) -public class PigRenderState extends LivingEntityRenderState implements SaddleableRenderState { - public boolean isSaddled; - - @Override - public boolean isSaddled() { - return this.isSaddled; - } +public class PigRenderState extends LivingEntityRenderState { + public ItemStack saddle = ItemStack.EMPTY; + @Nullable + public PigVariant variant; } diff --git a/net/minecraft/client/renderer/entity/state/RabbitRenderState.java b/net/minecraft/client/renderer/entity/state/RabbitRenderState.java index eca65a4c..f456d689 100644 --- a/net/minecraft/client/renderer/entity/state/RabbitRenderState.java +++ b/net/minecraft/client/renderer/entity/state/RabbitRenderState.java @@ -8,5 +8,5 @@ import net.minecraft.world.entity.animal.Rabbit; public class RabbitRenderState extends LivingEntityRenderState { public float jumpCompletion; public boolean isToast; - public Rabbit.Variant variant = Rabbit.Variant.BROWN; + public Rabbit.Variant variant = Rabbit.Variant.DEFAULT; } diff --git a/net/minecraft/client/renderer/entity/state/SaddleableRenderState.java b/net/minecraft/client/renderer/entity/state/SaddleableRenderState.java deleted file mode 100644 index defbd316..00000000 --- a/net/minecraft/client/renderer/entity/state/SaddleableRenderState.java +++ /dev/null @@ -1,9 +0,0 @@ -package net.minecraft.client.renderer.entity.state; - -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; - -@Environment(EnvType.CLIENT) -public interface SaddleableRenderState { - boolean isSaddled(); -} diff --git a/net/minecraft/client/renderer/entity/state/ServerHitboxesRenderState.java b/net/minecraft/client/renderer/entity/state/ServerHitboxesRenderState.java new file mode 100644 index 00000000..8c4d30ec --- /dev/null +++ b/net/minecraft/client/renderer/entity/state/ServerHitboxesRenderState.java @@ -0,0 +1,22 @@ +package net.minecraft.client.renderer.entity.state; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public record ServerHitboxesRenderState( + boolean missing, + double serverEntityX, + double serverEntityY, + double serverEntityZ, + double deltaMovementX, + double deltaMovementY, + double deltaMovementZ, + float eyeHeight, + @Nullable HitboxesRenderState hitboxes +) { + public ServerHitboxesRenderState(boolean missing) { + this(missing, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0, 0.0F, null); + } +} diff --git a/net/minecraft/client/renderer/entity/state/SheepRenderState.java b/net/minecraft/client/renderer/entity/state/SheepRenderState.java index 63853bd5..e096388f 100644 --- a/net/minecraft/client/renderer/entity/state/SheepRenderState.java +++ b/net/minecraft/client/renderer/entity/state/SheepRenderState.java @@ -2,6 +2,9 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.util.ARGB; +import net.minecraft.util.Mth; +import net.minecraft.world.entity.animal.sheep.Sheep; import net.minecraft.world.item.DyeColor; @Environment(EnvType.CLIENT) @@ -11,4 +14,25 @@ public class SheepRenderState extends LivingEntityRenderState { public boolean isSheared; public DyeColor woolColor = DyeColor.WHITE; public int id; + + public int getWoolColor() { + if (this.isJebSheep()) { + int i = 25; + int j = Mth.floor(this.ageInTicks); + int k = j / 25 + this.id; + int l = DyeColor.values().length; + int m = k % l; + int n = (k + 1) % l; + float f = (j % 25 + Mth.frac(this.ageInTicks)) / 25.0F; + int o = Sheep.getColor(DyeColor.byId(m)); + int p = Sheep.getColor(DyeColor.byId(n)); + return ARGB.lerp(f, o, p); + } else { + return Sheep.getColor(this.woolColor); + } + } + + public boolean isJebSheep() { + return this.customName != null && "jeb_".equals(this.customName.getString()); + } } diff --git a/net/minecraft/client/renderer/entity/state/StriderRenderState.java b/net/minecraft/client/renderer/entity/state/StriderRenderState.java index 086a1eb7..1256dd87 100644 --- a/net/minecraft/client/renderer/entity/state/StriderRenderState.java +++ b/net/minecraft/client/renderer/entity/state/StriderRenderState.java @@ -2,15 +2,11 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.world.item.ItemStack; @Environment(EnvType.CLIENT) -public class StriderRenderState extends LivingEntityRenderState implements SaddleableRenderState { - public boolean isSaddled; +public class StriderRenderState extends LivingEntityRenderState { + public ItemStack saddle = ItemStack.EMPTY; public boolean isSuffocating; public boolean isRidden; - - @Override - public boolean isSaddled() { - return this.isSaddled; - } } diff --git a/net/minecraft/client/renderer/entity/state/TropicalFishRenderState.java b/net/minecraft/client/renderer/entity/state/TropicalFishRenderState.java index 907edb4d..f631461c 100644 --- a/net/minecraft/client/renderer/entity/state/TropicalFishRenderState.java +++ b/net/minecraft/client/renderer/entity/state/TropicalFishRenderState.java @@ -6,7 +6,7 @@ import net.minecraft.world.entity.animal.TropicalFish; @Environment(EnvType.CLIENT) public class TropicalFishRenderState extends LivingEntityRenderState { - public TropicalFish.Pattern variant = TropicalFish.Pattern.FLOPPER; + public TropicalFish.Pattern pattern = TropicalFish.Pattern.FLOPPER; public int baseColor = -1; public int patternColor = -1; } diff --git a/net/minecraft/client/renderer/entity/state/VillagerDataHolderRenderState.java b/net/minecraft/client/renderer/entity/state/VillagerDataHolderRenderState.java index e44fc821..f42b0800 100644 --- a/net/minecraft/client/renderer/entity/state/VillagerDataHolderRenderState.java +++ b/net/minecraft/client/renderer/entity/state/VillagerDataHolderRenderState.java @@ -3,8 +3,10 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.world.entity.npc.VillagerData; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public interface VillagerDataHolderRenderState { + @Nullable VillagerData getVillagerData(); } diff --git a/net/minecraft/client/renderer/entity/state/VillagerRenderState.java b/net/minecraft/client/renderer/entity/state/VillagerRenderState.java index a99bec2d..a62b95fa 100644 --- a/net/minecraft/client/renderer/entity/state/VillagerRenderState.java +++ b/net/minecraft/client/renderer/entity/state/VillagerRenderState.java @@ -3,14 +3,15 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.world.entity.npc.VillagerData; -import net.minecraft.world.entity.npc.VillagerProfession; -import net.minecraft.world.entity.npc.VillagerType; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class VillagerRenderState extends HoldingEntityRenderState implements VillagerDataHolderRenderState { public boolean isUnhappy; - public VillagerData villagerData = new VillagerData(VillagerType.PLAINS, VillagerProfession.NONE, 1); + @Nullable + public VillagerData villagerData; + @Nullable @Override public VillagerData getVillagerData() { return this.villagerData; diff --git a/net/minecraft/client/renderer/entity/state/ZombieVillagerRenderState.java b/net/minecraft/client/renderer/entity/state/ZombieVillagerRenderState.java index ebef3082..d90441ae 100644 --- a/net/minecraft/client/renderer/entity/state/ZombieVillagerRenderState.java +++ b/net/minecraft/client/renderer/entity/state/ZombieVillagerRenderState.java @@ -3,13 +3,14 @@ package net.minecraft.client.renderer.entity.state; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.world.entity.npc.VillagerData; -import net.minecraft.world.entity.npc.VillagerProfession; -import net.minecraft.world.entity.npc.VillagerType; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class ZombieVillagerRenderState extends ZombieRenderState implements VillagerDataHolderRenderState { - public VillagerData villagerData = new VillagerData(VillagerType.PLAINS, VillagerProfession.NONE, 1); + @Nullable + public VillagerData villagerData; + @Nullable @Override public VillagerData getVillagerData() { return this.villagerData; diff --git a/net/minecraft/client/renderer/item/BlockModelWrapper.java b/net/minecraft/client/renderer/item/BlockModelWrapper.java index 9e5115eb..b7417410 100644 --- a/net/minecraft/client/renderer/item/BlockModelWrapper.java +++ b/net/minecraft/client/renderer/item/BlockModelWrapper.java @@ -1,17 +1,25 @@ package net.minecraft.client.renderer.item; +import com.google.common.base.Suppliers; import com.mojang.serialization.MapCodec; import com.mojang.serialization.codecs.RecordCodecBuilder; +import java.util.HashSet; import java.util.List; +import java.util.Set; +import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.color.item.ItemTintSource; import net.minecraft.client.color.item.ItemTintSources; import net.minecraft.client.multiplayer.ClientLevel; import net.minecraft.client.renderer.ItemBlockRenderTypes; -import net.minecraft.client.renderer.RenderType; -import net.minecraft.client.resources.model.BakedModel; +import net.minecraft.client.renderer.block.model.BakedQuad; +import net.minecraft.client.renderer.block.model.FaceBakery; +import net.minecraft.client.renderer.block.model.TextureSlots; +import net.minecraft.client.resources.model.BlockModelRotation; +import net.minecraft.client.resources.model.ModelBaker; import net.minecraft.client.resources.model.ResolvableModel; +import net.minecraft.client.resources.model.ResolvedModel; import net.minecraft.resources.ResourceLocation; import net.minecraft.tags.ItemTags; import net.minecraft.world.entity.LivingEntity; @@ -19,15 +27,30 @@ import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.ItemStack; import net.minecraft.world.item.Items; import org.jetbrains.annotations.Nullable; +import org.joml.Vector3f; @Environment(EnvType.CLIENT) public class BlockModelWrapper implements ItemModel { - private final BakedModel model; private final List tints; + private final List quads; + private final Supplier extents; + private final ModelRenderProperties properties; - BlockModelWrapper(BakedModel model, List tints) { - this.model = model; + public BlockModelWrapper(List tints, List quads, ModelRenderProperties properties) { this.tints = tints; + this.quads = quads; + this.properties = properties; + this.extents = Suppliers.memoize(() -> computeExtents(this.quads)); + } + + public static Vector3f[] computeExtents(List quads) { + Set set = new HashSet(); + + for (BakedQuad bakedQuad : quads) { + FaceBakery.extractPositions(bakedQuad.vertices(), set::add); + } + + return (Vector3f[])set.toArray(Vector3f[]::new); } @Override @@ -52,8 +75,10 @@ public class BlockModelWrapper implements ItemModel { is[j] = ((ItemTintSource)this.tints.get(j)).calculate(stack, level, entity); } - RenderType renderType = ItemBlockRenderTypes.getRenderType(stack); - layerRenderState.setupBlockModel(this.model, renderType); + layerRenderState.setExtents(this.extents); + layerRenderState.setRenderType(ItemBlockRenderTypes.getRenderType(stack)); + this.properties.applyToLayer(layerRenderState, displayContext); + layerRenderState.prepareQuadList().addAll(this.quads); } private static boolean hasSpecialAnimatedTexture(ItemStack stack) { @@ -72,13 +97,17 @@ public class BlockModelWrapper implements ItemModel { @Override public void resolveDependencies(ResolvableModel.Resolver resolver) { - resolver.resolve(this.model); + resolver.markDependency(this.model); } @Override public ItemModel bake(ItemModel.BakingContext context) { - BakedModel bakedModel = context.bake(this.model); - return new BlockModelWrapper(bakedModel, this.tints); + ModelBaker modelBaker = context.blockModelBaker(); + ResolvedModel resolvedModel = modelBaker.getModel(this.model); + TextureSlots textureSlots = resolvedModel.getTopTextureSlots(); + List list = resolvedModel.bakeTopGeometry(textureSlots, modelBaker, BlockModelRotation.X0_Y0).getAll(); + ModelRenderProperties modelRenderProperties = ModelRenderProperties.fromResolvedModel(modelBaker, resolvedModel, textureSlots); + return new BlockModelWrapper(this.tints, list, modelRenderProperties); } @Override diff --git a/net/minecraft/client/renderer/item/ClientItem.java b/net/minecraft/client/renderer/item/ClientItem.java index 815e6cc6..6fc2a8fb 100644 --- a/net/minecraft/client/renderer/item/ClientItem.java +++ b/net/minecraft/client/renderer/item/ClientItem.java @@ -5,14 +5,24 @@ import com.mojang.serialization.MapCodec; import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.util.RegistryContextSwapper; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) -public record ClientItem(ItemModel.Unbaked model, ClientItem.Properties properties) { +public record ClientItem(ItemModel.Unbaked model, ClientItem.Properties properties, @Nullable RegistryContextSwapper registrySwapper) { public static final Codec CODEC = RecordCodecBuilder.create( instance -> instance.group(ItemModels.CODEC.fieldOf("model").forGetter(ClientItem::model), ClientItem.Properties.MAP_CODEC.forGetter(ClientItem::properties)) .apply(instance, ClientItem::new) ); + public ClientItem(ItemModel.Unbaked model, ClientItem.Properties properties) { + this(model, properties, null); + } + + public ClientItem withRegistrySwapper(RegistryContextSwapper registrySwapper) { + return new ClientItem(this.model, this.properties, registrySwapper); + } + @Environment(EnvType.CLIENT) public record Properties(boolean handAnimationOnSwap) { public static final ClientItem.Properties DEFAULT = new ClientItem.Properties(true); diff --git a/net/minecraft/client/renderer/item/ConditionalItemModel.java b/net/minecraft/client/renderer/item/ConditionalItemModel.java index be5cbb97..74184c15 100644 --- a/net/minecraft/client/renderer/item/ConditionalItemModel.java +++ b/net/minecraft/client/renderer/item/ConditionalItemModel.java @@ -4,10 +4,13 @@ import com.mojang.serialization.MapCodec; import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.multiplayer.CacheSlot; import net.minecraft.client.multiplayer.ClientLevel; import net.minecraft.client.renderer.item.properties.conditional.ConditionalItemModelProperties; import net.minecraft.client.renderer.item.properties.conditional.ConditionalItemModelProperty; +import net.minecraft.client.renderer.item.properties.conditional.ItemModelPropertyTest; import net.minecraft.client.resources.model.ResolvableModel; +import net.minecraft.util.RegistryContextSwapper; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.ItemStack; @@ -15,11 +18,11 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class ConditionalItemModel implements ItemModel { - private final ConditionalItemModelProperty property; + private final ItemModelPropertyTest property; private final ItemModel onTrue; private final ItemModel onFalse; - public ConditionalItemModel(ConditionalItemModelProperty property, ItemModel onTrue, ItemModel onFalse) { + public ConditionalItemModel(ItemModelPropertyTest property, ItemModel onTrue, ItemModel onFalse) { this.property = property; this.onTrue = onTrue; this.onFalse = onFalse; @@ -57,7 +60,23 @@ public class ConditionalItemModel implements ItemModel { @Override public ItemModel bake(ItemModel.BakingContext context) { - return new ConditionalItemModel(this.property, this.onTrue.bake(context), this.onFalse.bake(context)); + return new ConditionalItemModel(this.adaptProperty(this.property, context.contextSwapper()), this.onTrue.bake(context), this.onFalse.bake(context)); + } + + private ItemModelPropertyTest adaptProperty(ConditionalItemModelProperty property, @Nullable RegistryContextSwapper contextSwapper) { + if (contextSwapper == null) { + return property; + } else { + CacheSlot cacheSlot = new CacheSlot<>(clientLevel -> swapContext(property, contextSwapper, clientLevel)); + return (itemStack, clientLevel, livingEntity, i, itemDisplayContext) -> { + ItemModelPropertyTest itemModelPropertyTest = (ItemModelPropertyTest)(clientLevel == null ? property : cacheSlot.compute(clientLevel)); + return itemModelPropertyTest.get(itemStack, clientLevel, livingEntity, i, itemDisplayContext); + }; + } + } + + private static T swapContext(T property, RegistryContextSwapper contextSwapper, ClientLevel level) { + return (T)contextSwapper.swapTo(property.type().codec(), property, level.registryAccess()).result().orElse(property); } @Override diff --git a/net/minecraft/client/renderer/item/ItemModel.java b/net/minecraft/client/renderer/item/ItemModel.java index 9a1af017..0bcd0407 100644 --- a/net/minecraft/client/renderer/item/ItemModel.java +++ b/net/minecraft/client/renderer/item/ItemModel.java @@ -5,11 +5,9 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.model.geom.EntityModelSet; import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.client.resources.model.BakedModel; -import net.minecraft.client.resources.model.BlockModelRotation; import net.minecraft.client.resources.model.ModelBaker; import net.minecraft.client.resources.model.ResolvableModel; -import net.minecraft.resources.ResourceLocation; +import net.minecraft.util.RegistryContextSwapper; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.ItemStack; @@ -28,10 +26,9 @@ public interface ItemModel { ); @Environment(EnvType.CLIENT) - public record BakingContext(ModelBaker blockModelBaker, EntityModelSet entityModelSet, ItemModel missingItemModel) { - public BakedModel bake(ResourceLocation location) { - return this.blockModelBaker().bake(location, BlockModelRotation.X0_Y0); - } + public record BakingContext( + ModelBaker blockModelBaker, EntityModelSet entityModelSet, ItemModel missingItemModel, @Nullable RegistryContextSwapper contextSwapper + ) { } @Environment(EnvType.CLIENT) diff --git a/net/minecraft/client/renderer/item/ItemModelResolver.java b/net/minecraft/client/renderer/item/ItemModelResolver.java index 2f53d92f..d411dc87 100644 --- a/net/minecraft/client/renderer/item/ItemModelResolver.java +++ b/net/minecraft/client/renderer/item/ItemModelResolver.java @@ -28,27 +28,20 @@ public class ItemModelResolver { this.clientProperties = modelManager::getItemProperties; } - public void updateForLiving(ItemStackRenderState renderState, ItemStack stack, ItemDisplayContext displayContext, boolean leftHand, LivingEntity entity) { - this.updateForTopItem(renderState, stack, displayContext, leftHand, entity.level(), entity, entity.getId() + displayContext.ordinal()); + public void updateForLiving(ItemStackRenderState renderState, ItemStack stack, ItemDisplayContext displayContext, LivingEntity entity) { + this.updateForTopItem(renderState, stack, displayContext, entity.level(), entity, entity.getId() + displayContext.ordinal()); } public void updateForNonLiving(ItemStackRenderState renderState, ItemStack stack, ItemDisplayContext displayContext, Entity entity) { - this.updateForTopItem(renderState, stack, displayContext, false, entity.level(), null, entity.getId()); + this.updateForTopItem(renderState, stack, displayContext, entity.level(), null, entity.getId()); } public void updateForTopItem( - ItemStackRenderState renderState, - ItemStack stack, - ItemDisplayContext displayContext, - boolean leftHand, - @Nullable Level level, - @Nullable LivingEntity entity, - int seed + ItemStackRenderState renderState, ItemStack stack, ItemDisplayContext displayContext, @Nullable Level level, @Nullable LivingEntity entity, int seed ) { renderState.clear(); if (!stack.isEmpty()) { renderState.displayContext = displayContext; - renderState.isLeftHand = leftHand; this.appendItemLayers(renderState, stack, displayContext, level, entity, seed); } } diff --git a/net/minecraft/client/renderer/item/ItemStackRenderState.java b/net/minecraft/client/renderer/item/ItemStackRenderState.java index df1c161a..34db4a6b 100644 --- a/net/minecraft/client/renderer/item/ItemStackRenderState.java +++ b/net/minecraft/client/renderer/item/ItemStackRenderState.java @@ -1,24 +1,30 @@ package net.minecraft.client.renderer.item; import com.mojang.blaze3d.vertex.PoseStack; +import java.util.ArrayList; import java.util.Arrays; +import java.util.List; +import java.util.function.Consumer; +import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.MultiBufferSource; import net.minecraft.client.renderer.RenderType; +import net.minecraft.client.renderer.block.model.BakedQuad; import net.minecraft.client.renderer.block.model.ItemTransform; import net.minecraft.client.renderer.entity.ItemRenderer; import net.minecraft.client.renderer.special.SpecialModelRenderer; import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.client.resources.model.BakedModel; import net.minecraft.util.RandomSource; import net.minecraft.world.item.ItemDisplayContext; import org.jetbrains.annotations.Nullable; +import org.joml.Matrix4f; +import org.joml.Vector3f; +import org.joml.Vector3fc; @Environment(EnvType.CLIENT) public class ItemStackRenderState { ItemDisplayContext displayContext = ItemDisplayContext.NONE; - boolean isLeftHand; private int activeLayerCount; private ItemStackRenderState.LayerRenderState[] layers = new ItemStackRenderState.LayerRenderState[]{new ItemStackRenderState.LayerRenderState()}; @@ -41,7 +47,6 @@ public class ItemStackRenderState { public void clear() { this.displayContext = ItemDisplayContext.NONE; - this.isLeftHand = false; for (int i = 0; i < this.activeLayerCount; i++) { this.layers[i].clear(); @@ -58,26 +63,31 @@ public class ItemStackRenderState { return this.activeLayerCount == 0; } - public boolean isGui3d() { - return this.firstLayer().isGui3d(); - } - public boolean usesBlockLight() { - return this.firstLayer().usesBlockLight(); + return this.firstLayer().usesBlockLight; } @Nullable public TextureAtlasSprite pickParticleIcon(RandomSource random) { - if (this.activeLayerCount == 0) { - return null; - } else { - BakedModel bakedModel = this.layers[random.nextInt(this.activeLayerCount)].model; - return bakedModel == null ? null : bakedModel.getParticleIcon(); - } + return this.activeLayerCount == 0 ? null : this.layers[random.nextInt(this.activeLayerCount)].particleIcon; } - public ItemTransform transform() { - return this.firstLayer().transform(); + public void visitExtents(Consumer visitor) { + Vector3f vector3f = new Vector3f(); + PoseStack.Pose pose = new PoseStack.Pose(); + + for (int i = 0; i < this.activeLayerCount; i++) { + ItemStackRenderState.LayerRenderState layerRenderState = this.layers[i]; + layerRenderState.transform.apply(this.displayContext.leftHand(), pose); + Matrix4f matrix4f = pose.pose(); + Vector3f[] vector3fs = (Vector3f[])layerRenderState.extents.get(); + + for (Vector3f vector3f2 : vector3fs) { + visitor.accept(vector3f.set(vector3f2).mulPosition(matrix4f)); + } + + pose.setIdentity(); + } } public void render(PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay) { @@ -95,8 +105,13 @@ public class ItemStackRenderState { @Environment(EnvType.CLIENT) public class LayerRenderState { + private static final Vector3f[] NO_EXTENTS = new Vector3f[0]; + public static final Supplier NO_EXTENTS_SUPPLIER = () -> NO_EXTENTS; + private final List quads = new ArrayList(); + boolean usesBlockLight; @Nullable - BakedModel model; + TextureAtlasSprite particleIcon; + ItemTransform transform = ItemTransform.NO_TRANSFORM; @Nullable private RenderType renderType; private ItemStackRenderState.FoilType foilType = ItemStackRenderState.FoilType.NONE; @@ -105,25 +120,48 @@ public class ItemStackRenderState { private SpecialModelRenderer specialRenderer; @Nullable private Object argumentForSpecialRendering; + Supplier extents = NO_EXTENTS_SUPPLIER; public void clear() { - this.model = null; + this.quads.clear(); this.renderType = null; this.foilType = ItemStackRenderState.FoilType.NONE; this.specialRenderer = null; this.argumentForSpecialRendering = null; Arrays.fill(this.tintLayers, -1); + this.usesBlockLight = false; + this.particleIcon = null; + this.transform = ItemTransform.NO_TRANSFORM; + this.extents = NO_EXTENTS_SUPPLIER; } - public void setupBlockModel(BakedModel model, RenderType renderType) { - this.model = model; + public List prepareQuadList() { + return this.quads; + } + + public void setRenderType(RenderType renderType) { this.renderType = renderType; } - public void setupSpecialModel(SpecialModelRenderer specialRenderer, @Nullable T argumentForSpecialRendering, BakedModel model) { - this.model = model; - this.specialRenderer = eraseSpecialRenderer(specialRenderer); - this.argumentForSpecialRendering = argumentForSpecialRendering; + public void setUsesBlockLight(boolean usesBlockLight) { + this.usesBlockLight = usesBlockLight; + } + + public void setExtents(Supplier extents) { + this.extents = extents; + } + + public void setParticleIcon(TextureAtlasSprite particleIcon) { + this.particleIcon = particleIcon; + } + + public void setTransform(ItemTransform transform) { + this.transform = transform; + } + + public void setupSpecialModel(SpecialModelRenderer renderer, @Nullable T argument) { + this.specialRenderer = eraseSpecialRenderer(renderer); + this.argumentForSpecialRendering = argument; } private static SpecialModelRenderer eraseSpecialRenderer(SpecialModelRenderer specialRenderer) { @@ -143,14 +181,9 @@ public class ItemStackRenderState { return this.tintLayers; } - ItemTransform transform() { - return this.model != null ? this.model.getTransforms().getTransform(ItemStackRenderState.this.displayContext) : ItemTransform.NO_TRANSFORM; - } - void render(PoseStack poseStack, MultiBufferSource bufferSource, int packedLight, int packedOverlay) { poseStack.pushPose(); - this.transform().apply(ItemStackRenderState.this.isLeftHand, poseStack); - poseStack.translate(-0.5F, -0.5F, -0.5F); + this.transform.apply(ItemStackRenderState.this.displayContext.leftHand(), poseStack.last()); if (this.specialRenderer != null) { this.specialRenderer .render( @@ -162,21 +195,13 @@ public class ItemStackRenderState { packedOverlay, this.foilType != ItemStackRenderState.FoilType.NONE ); - } else if (this.model != null) { + } else if (this.renderType != null) { ItemRenderer.renderItem( - ItemStackRenderState.this.displayContext, poseStack, bufferSource, packedLight, packedOverlay, this.tintLayers, this.model, this.renderType, this.foilType + ItemStackRenderState.this.displayContext, poseStack, bufferSource, packedLight, packedOverlay, this.tintLayers, this.quads, this.renderType, this.foilType ); } poseStack.popPose(); } - - boolean isGui3d() { - return this.model != null && this.model.isGui3d(); - } - - boolean usesBlockLight() { - return this.model != null && this.model.usesBlockLight(); - } } } diff --git a/net/minecraft/client/renderer/item/MissingItemModel.java b/net/minecraft/client/renderer/item/MissingItemModel.java index aa0a97e8..13ceb111 100644 --- a/net/minecraft/client/renderer/item/MissingItemModel.java +++ b/net/minecraft/client/renderer/item/MissingItemModel.java @@ -1,21 +1,29 @@ package net.minecraft.client.renderer.item; +import com.google.common.base.Suppliers; +import java.util.List; +import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.multiplayer.ClientLevel; import net.minecraft.client.renderer.Sheets; -import net.minecraft.client.resources.model.BakedModel; +import net.minecraft.client.renderer.block.model.BakedQuad; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.ItemStack; import org.jetbrains.annotations.Nullable; +import org.joml.Vector3f; @Environment(EnvType.CLIENT) public class MissingItemModel implements ItemModel { - private final BakedModel model; + private final List quads; + private final Supplier extents; + private final ModelRenderProperties properties; - public MissingItemModel(BakedModel model) { - this.model = model; + public MissingItemModel(List quads, ModelRenderProperties properties) { + this.quads = quads; + this.properties = properties; + this.extents = Suppliers.memoize(() -> BlockModelWrapper.computeExtents(this.quads)); } @Override @@ -28,6 +36,10 @@ public class MissingItemModel implements ItemModel { @Nullable LivingEntity entity, int seed ) { - renderState.newLayer().setupBlockModel(this.model, Sheets.cutoutBlockSheet()); + ItemStackRenderState.LayerRenderState layerRenderState = renderState.newLayer(); + layerRenderState.setRenderType(Sheets.cutoutBlockSheet()); + this.properties.applyToLayer(layerRenderState, displayContext); + layerRenderState.setExtents(this.extents); + layerRenderState.prepareQuadList().addAll(this.quads); } } diff --git a/net/minecraft/client/renderer/item/ModelRenderProperties.java b/net/minecraft/client/renderer/item/ModelRenderProperties.java new file mode 100644 index 00000000..e4095352 --- /dev/null +++ b/net/minecraft/client/renderer/item/ModelRenderProperties.java @@ -0,0 +1,24 @@ +package net.minecraft.client.renderer.item; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.ItemTransforms; +import net.minecraft.client.renderer.block.model.TextureSlots; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.client.resources.model.ModelBaker; +import net.minecraft.client.resources.model.ResolvedModel; +import net.minecraft.world.item.ItemDisplayContext; + +@Environment(EnvType.CLIENT) +public record ModelRenderProperties(boolean usesBlockLight, TextureAtlasSprite particleIcon, ItemTransforms transforms) { + public static ModelRenderProperties fromResolvedModel(ModelBaker baker, ResolvedModel model, TextureSlots textureSlots) { + TextureAtlasSprite textureAtlasSprite = model.resolveParticleSprite(textureSlots, baker); + return new ModelRenderProperties(model.getTopGuiLight().lightLikeBlock(), textureAtlasSprite, model.getTopTransforms()); + } + + public void applyToLayer(ItemStackRenderState.LayerRenderState renderState, ItemDisplayContext displayContext) { + renderState.setUsesBlockLight(this.usesBlockLight); + renderState.setParticleIcon(this.particleIcon); + renderState.setTransform(this.transforms.getTransform(displayContext)); + } +} diff --git a/net/minecraft/client/renderer/item/SelectItemModel.java b/net/minecraft/client/renderer/item/SelectItemModel.java index d0d303e3..ce1cbbc1 100644 --- a/net/minecraft/client/renderer/item/SelectItemModel.java +++ b/net/minecraft/client/renderer/item/SelectItemModel.java @@ -9,11 +9,13 @@ import java.util.List; import java.util.Optional; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.multiplayer.CacheSlot; import net.minecraft.client.multiplayer.ClientLevel; import net.minecraft.client.renderer.item.properties.select.SelectItemModelProperties; import net.minecraft.client.renderer.item.properties.select.SelectItemModelProperty; import net.minecraft.client.resources.model.ResolvableModel; import net.minecraft.util.ExtraCodecs; +import net.minecraft.util.RegistryContextSwapper; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.ItemStack; @@ -22,9 +24,9 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public class SelectItemModel implements ItemModel { private final SelectItemModelProperty property; - private final Object2ObjectMap models; + private final SelectItemModel.ModelSelector models; - public SelectItemModel(SelectItemModelProperty property, Object2ObjectMap models) { + public SelectItemModel(SelectItemModelProperty property, SelectItemModel.ModelSelector models) { this.property = property; this.models = models; } @@ -40,12 +42,19 @@ public class SelectItemModel implements ItemModel { int seed ) { T object = this.property.get(stack, level, entity, seed, displayContext); - ItemModel itemModel = this.models.get(object); + ItemModel itemModel = this.models.get(object, level); if (itemModel != null) { itemModel.update(renderState, stack, itemModelResolver, displayContext, level, entity, seed); } } + @FunctionalInterface + @Environment(EnvType.CLIENT) + public interface ModelSelector { + @Nullable + ItemModel get(@Nullable T object, @Nullable ClientLevel clientLevel); + } + @Environment(EnvType.CLIENT) public record SwitchCase(List values, ItemModel.Unbaked model) { @@ -106,7 +115,33 @@ public class SelectItemModel implements ItemModel { } object2ObjectMap.defaultReturnValue(model); - return new SelectItemModel<>(this.property, object2ObjectMap); + return new SelectItemModel<>(this.property, this.createModelGetter(object2ObjectMap, bakingContext.contextSwapper())); + } + + private SelectItemModel.ModelSelector createModelGetter(Object2ObjectMap models, @Nullable RegistryContextSwapper contextSwapper) { + if (contextSwapper == null) { + return (object, clientLevel) -> models.get(object); + } else { + ItemModel itemModel = models.defaultReturnValue(); + CacheSlot> cacheSlot = new CacheSlot<>( + clientLevel -> { + Object2ObjectMap object2ObjectMap2 = new Object2ObjectOpenHashMap<>(models.size()); + object2ObjectMap2.defaultReturnValue(itemModel); + models.forEach( + (object, itemModelxx) -> contextSwapper.swapTo(this.property.valueCodec(), (T)object, clientLevel.registryAccess()) + .ifSuccess(objectx -> object2ObjectMap2.put((T)objectx, itemModelxx)) + ); + return object2ObjectMap2; + } + ); + return (object, clientLevel) -> { + if (clientLevel == null) { + return models.get(object); + } else { + return object == null ? itemModel : cacheSlot.compute(clientLevel).get(object); + } + }; + } } public void resolveDependencies(ResolvableModel.Resolver resolver) { diff --git a/net/minecraft/client/renderer/item/SpecialModelWrapper.java b/net/minecraft/client/renderer/item/SpecialModelWrapper.java index 76bab76b..c973f34b 100644 --- a/net/minecraft/client/renderer/item/SpecialModelWrapper.java +++ b/net/minecraft/client/renderer/item/SpecialModelWrapper.java @@ -5,24 +5,37 @@ import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.multiplayer.ClientLevel; +import net.minecraft.client.renderer.block.model.TextureSlots; import net.minecraft.client.renderer.special.SpecialModelRenderer; import net.minecraft.client.renderer.special.SpecialModelRenderers; -import net.minecraft.client.resources.model.BakedModel; +import net.minecraft.client.resources.model.ModelBaker; import net.minecraft.client.resources.model.ResolvableModel; +import net.minecraft.client.resources.model.ResolvedModel; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.entity.LivingEntity; import net.minecraft.world.item.ItemDisplayContext; import net.minecraft.world.item.ItemStack; import org.jetbrains.annotations.Nullable; +import org.joml.Vector3f; @Environment(EnvType.CLIENT) public class SpecialModelWrapper implements ItemModel { + private static final Vector3f[] EXTENTS = new Vector3f[]{ + new Vector3f(0.0F, 0.0F, 0.0F), + new Vector3f(0.0F, 0.0F, 1.0F), + new Vector3f(0.0F, 1.0F, 1.0F), + new Vector3f(0.0F, 1.0F, 0.0F), + new Vector3f(1.0F, 1.0F, 0.0F), + new Vector3f(1.0F, 1.0F, 1.0F), + new Vector3f(1.0F, 0.0F, 1.0F), + new Vector3f(1.0F, 0.0F, 0.0F) + }; private final SpecialModelRenderer specialRenderer; - private final BakedModel baseModel; + private final ModelRenderProperties properties; - public SpecialModelWrapper(SpecialModelRenderer specialRenderer, BakedModel baseModel) { + public SpecialModelWrapper(SpecialModelRenderer specialRenderer, ModelRenderProperties properties) { this.specialRenderer = specialRenderer; - this.baseModel = baseModel; + this.properties = properties; } @Override @@ -40,7 +53,9 @@ public class SpecialModelWrapper implements ItemModel { layerRenderState.setFoilType(ItemStackRenderState.FoilType.STANDARD); } - layerRenderState.setupSpecialModel(this.specialRenderer, this.specialRenderer.extractArgument(stack), this.baseModel); + layerRenderState.setExtents(() -> EXTENTS); + layerRenderState.setupSpecialModel(this.specialRenderer, this.specialRenderer.extractArgument(stack)); + this.properties.applyToLayer(layerRenderState, displayContext); } @Environment(EnvType.CLIENT) @@ -55,14 +70,25 @@ public class SpecialModelWrapper implements ItemModel { @Override public void resolveDependencies(ResolvableModel.Resolver resolver) { - resolver.resolve(this.base); + resolver.markDependency(this.base); } @Override public ItemModel bake(ItemModel.BakingContext context) { - BakedModel bakedModel = context.bake(this.base); SpecialModelRenderer specialModelRenderer = this.specialModel.bake(context.entityModelSet()); - return (ItemModel)(specialModelRenderer == null ? context.missingItemModel() : new SpecialModelWrapper<>(specialModelRenderer, bakedModel)); + if (specialModelRenderer == null) { + return context.missingItemModel(); + } else { + ModelRenderProperties modelRenderProperties = this.getProperties(context); + return new SpecialModelWrapper<>(specialModelRenderer, modelRenderProperties); + } + } + + private ModelRenderProperties getProperties(ItemModel.BakingContext context) { + ModelBaker modelBaker = context.blockModelBaker(); + ResolvedModel resolvedModel = modelBaker.getModel(this.base); + TextureSlots textureSlots = resolvedModel.getTopTextureSlots(); + return ModelRenderProperties.fromResolvedModel(modelBaker, resolvedModel, textureSlots); } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/Broken.java b/net/minecraft/client/renderer/item/properties/conditional/Broken.java index 2432d172..c0f17a22 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/Broken.java +++ b/net/minecraft/client/renderer/item/properties/conditional/Broken.java @@ -14,8 +14,8 @@ public record Broken() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new Broken()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - return stack.nextDamageWillBreak(); + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return itemStack.nextDamageWillBreak(); } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/BundleHasSelectedItem.java b/net/minecraft/client/renderer/item/properties/conditional/BundleHasSelectedItem.java index 2dbcba9b..6056bad6 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/BundleHasSelectedItem.java +++ b/net/minecraft/client/renderer/item/properties/conditional/BundleHasSelectedItem.java @@ -15,8 +15,8 @@ public record BundleHasSelectedItem() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new BundleHasSelectedItem()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - return BundleItem.hasSelectedItem(stack); + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return BundleItem.hasSelectedItem(itemStack); } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/ComponentMatches.java b/net/minecraft/client/renderer/item/properties/conditional/ComponentMatches.java new file mode 100644 index 00000000..1353a90f --- /dev/null +++ b/net/minecraft/client/renderer/item/properties/conditional/ComponentMatches.java @@ -0,0 +1,29 @@ +package net.minecraft.client.renderer.item.properties.conditional; + +import com.mojang.serialization.MapCodec; +import com.mojang.serialization.codecs.RecordCodecBuilder; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.multiplayer.ClientLevel; +import net.minecraft.core.component.predicates.DataComponentPredicate; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.item.ItemDisplayContext; +import net.minecraft.world.item.ItemStack; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public record ComponentMatches(DataComponentPredicate.Single predicate) implements ConditionalItemModelProperty { + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( + instance -> instance.group(DataComponentPredicate.singleCodec("predicate").forGetter(ComponentMatches::predicate)).apply(instance, ComponentMatches::new) + ); + + @Override + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return this.predicate.predicate().matches(itemStack); + } + + @Override + public MapCodec type() { + return MAP_CODEC; + } +} diff --git a/net/minecraft/client/renderer/item/properties/conditional/ConditionalItemModelProperties.java b/net/minecraft/client/renderer/item/properties/conditional/ConditionalItemModelProperties.java index dd3ec237..6820e0bf 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/ConditionalItemModelProperties.java +++ b/net/minecraft/client/renderer/item/properties/conditional/ConditionalItemModelProperties.java @@ -25,5 +25,6 @@ public class ConditionalItemModelProperties { ID_MAPPER.put(ResourceLocation.withDefaultNamespace("extended_view"), ExtendedView.MAP_CODEC); ID_MAPPER.put(ResourceLocation.withDefaultNamespace("keybind_down"), IsKeybindDown.MAP_CODEC); ID_MAPPER.put(ResourceLocation.withDefaultNamespace("view_entity"), IsViewEntity.MAP_CODEC); + ID_MAPPER.put(ResourceLocation.withDefaultNamespace("component"), ComponentMatches.MAP_CODEC); } } diff --git a/net/minecraft/client/renderer/item/properties/conditional/ConditionalItemModelProperty.java b/net/minecraft/client/renderer/item/properties/conditional/ConditionalItemModelProperty.java index 5c32b27b..efa13aa2 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/ConditionalItemModelProperty.java +++ b/net/minecraft/client/renderer/item/properties/conditional/ConditionalItemModelProperty.java @@ -3,15 +3,8 @@ package net.minecraft.client.renderer.item.properties.conditional; import com.mojang.serialization.MapCodec; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.multiplayer.ClientLevel; -import net.minecraft.world.entity.LivingEntity; -import net.minecraft.world.item.ItemDisplayContext; -import net.minecraft.world.item.ItemStack; -import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) -public interface ConditionalItemModelProperty { - boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext); - +public interface ConditionalItemModelProperty extends ItemModelPropertyTest { MapCodec type(); } diff --git a/net/minecraft/client/renderer/item/properties/conditional/CustomModelDataProperty.java b/net/minecraft/client/renderer/item/properties/conditional/CustomModelDataProperty.java index 9108233e..22895538 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/CustomModelDataProperty.java +++ b/net/minecraft/client/renderer/item/properties/conditional/CustomModelDataProperty.java @@ -21,8 +21,8 @@ public record CustomModelDataProperty(int index) implements ConditionalItemModel ); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - CustomModelData customModelData = stack.get(DataComponents.CUSTOM_MODEL_DATA); + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + CustomModelData customModelData = itemStack.get(DataComponents.CUSTOM_MODEL_DATA); return customModelData != null ? customModelData.getBoolean(this.index) == Boolean.TRUE : false; } diff --git a/net/minecraft/client/renderer/item/properties/conditional/Damaged.java b/net/minecraft/client/renderer/item/properties/conditional/Damaged.java index 9a5606d4..d062010e 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/Damaged.java +++ b/net/minecraft/client/renderer/item/properties/conditional/Damaged.java @@ -14,8 +14,8 @@ public record Damaged() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new Damaged()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - return stack.isDamaged(); + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return itemStack.isDamaged(); } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/ExtendedView.java b/net/minecraft/client/renderer/item/properties/conditional/ExtendedView.java index 37ee0dd2..3660083c 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/ExtendedView.java +++ b/net/minecraft/client/renderer/item/properties/conditional/ExtendedView.java @@ -15,8 +15,8 @@ public record ExtendedView() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new ExtendedView()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - return displayContext == ItemDisplayContext.GUI && Screen.hasShiftDown(); + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return itemDisplayContext == ItemDisplayContext.GUI && Screen.hasShiftDown(); } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/FishingRodCast.java b/net/minecraft/client/renderer/item/properties/conditional/FishingRodCast.java index 1c0dc322..ea35fd18 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/FishingRodCast.java +++ b/net/minecraft/client/renderer/item/properties/conditional/FishingRodCast.java @@ -17,10 +17,10 @@ public record FishingRodCast() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new FishingRodCast()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - if (entity instanceof Player player && player.fishing != null) { + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + if (livingEntity instanceof Player player && player.fishing != null) { HumanoidArm humanoidArm = FishingHookRenderer.getHoldingArm(player); - return entity.getItemHeldByArm(humanoidArm) == stack; + return livingEntity.getItemHeldByArm(humanoidArm) == itemStack; } else { return false; } diff --git a/net/minecraft/client/renderer/item/properties/conditional/HasComponent.java b/net/minecraft/client/renderer/item/properties/conditional/HasComponent.java index df2474ba..6624f5c4 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/HasComponent.java +++ b/net/minecraft/client/renderer/item/properties/conditional/HasComponent.java @@ -24,8 +24,8 @@ public record HasComponent(DataComponentType componentType, boolean ignoreDef ); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - return this.ignoreDefault ? stack.hasNonDefault(this.componentType) : stack.has(this.componentType); + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return this.ignoreDefault ? itemStack.hasNonDefault(this.componentType) : itemStack.has(this.componentType); } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/IsCarried.java b/net/minecraft/client/renderer/item/properties/conditional/IsCarried.java index 1b60ac1c..919a1c56 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/IsCarried.java +++ b/net/minecraft/client/renderer/item/properties/conditional/IsCarried.java @@ -15,8 +15,8 @@ public record IsCarried() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new IsCarried()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - return entity instanceof LocalPlayer localPlayer && localPlayer.containerMenu.getCarried() == stack; + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return livingEntity instanceof LocalPlayer localPlayer && localPlayer.containerMenu.getCarried() == itemStack; } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/IsKeybindDown.java b/net/minecraft/client/renderer/item/properties/conditional/IsKeybindDown.java index 30674319..5fb4fe05 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/IsKeybindDown.java +++ b/net/minecraft/client/renderer/item/properties/conditional/IsKeybindDown.java @@ -24,7 +24,7 @@ public record IsKeybindDown(KeyMapping keybind) implements ConditionalItemModelP ); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { return this.keybind.isDown(); } diff --git a/net/minecraft/client/renderer/item/properties/conditional/IsSelected.java b/net/minecraft/client/renderer/item/properties/conditional/IsSelected.java index 18064c57..2e42de81 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/IsSelected.java +++ b/net/minecraft/client/renderer/item/properties/conditional/IsSelected.java @@ -15,8 +15,8 @@ public record IsSelected() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new IsSelected()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - return entity instanceof LocalPlayer localPlayer && localPlayer.getInventory().getSelected() == stack; + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return livingEntity instanceof LocalPlayer localPlayer && localPlayer.getInventory().getSelectedItem() == itemStack; } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/IsUsingItem.java b/net/minecraft/client/renderer/item/properties/conditional/IsUsingItem.java index 711f34c5..3a6143ce 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/IsUsingItem.java +++ b/net/minecraft/client/renderer/item/properties/conditional/IsUsingItem.java @@ -14,8 +14,8 @@ public record IsUsingItem() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new IsUsingItem()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { - return entity == null ? false : entity.isUsingItem() && entity.getUseItem() == stack; + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { + return livingEntity == null ? false : livingEntity.isUsingItem() && livingEntity.getUseItem() == itemStack; } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/IsViewEntity.java b/net/minecraft/client/renderer/item/properties/conditional/IsViewEntity.java index 6682a2a4..4887be6e 100644 --- a/net/minecraft/client/renderer/item/properties/conditional/IsViewEntity.java +++ b/net/minecraft/client/renderer/item/properties/conditional/IsViewEntity.java @@ -16,10 +16,10 @@ public record IsViewEntity() implements ConditionalItemModelProperty { public static final MapCodec MAP_CODEC = MapCodec.unit(new IsViewEntity()); @Override - public boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { + public boolean get(ItemStack itemStack, @Nullable ClientLevel clientLevel, @Nullable LivingEntity livingEntity, int i, ItemDisplayContext itemDisplayContext) { Minecraft minecraft = Minecraft.getInstance(); - Entity entity2 = minecraft.getCameraEntity(); - return entity2 != null ? entity == entity2 : entity == minecraft.player; + Entity entity = minecraft.getCameraEntity(); + return entity != null ? livingEntity == entity : livingEntity == minecraft.player; } @Override diff --git a/net/minecraft/client/renderer/item/properties/conditional/ItemModelPropertyTest.java b/net/minecraft/client/renderer/item/properties/conditional/ItemModelPropertyTest.java new file mode 100644 index 00000000..e4a3c445 --- /dev/null +++ b/net/minecraft/client/renderer/item/properties/conditional/ItemModelPropertyTest.java @@ -0,0 +1,15 @@ +package net.minecraft.client.renderer.item.properties.conditional; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.multiplayer.ClientLevel; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.item.ItemDisplayContext; +import net.minecraft.world.item.ItemStack; +import org.jetbrains.annotations.Nullable; + +@FunctionalInterface +@Environment(EnvType.CLIENT) +public interface ItemModelPropertyTest { + boolean get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext); +} diff --git a/net/minecraft/client/renderer/item/properties/numeric/CompassAngleState.java b/net/minecraft/client/renderer/item/properties/numeric/CompassAngleState.java index d7605131..27450ef7 100644 --- a/net/minecraft/client/renderer/item/properties/numeric/CompassAngleState.java +++ b/net/minecraft/client/renderer/item/properties/numeric/CompassAngleState.java @@ -6,6 +6,7 @@ import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.multiplayer.ClientLevel; +import net.minecraft.client.renderer.item.properties.numeric.NeedleDirectionHelper.Wobbler; import net.minecraft.core.BlockPos; import net.minecraft.core.GlobalPos; import net.minecraft.util.Mth; @@ -26,8 +27,8 @@ public class CompassAngleState extends NeedleDirectionHelper { ) .apply(instance, CompassAngleState::new) ); - private final NeedleDirectionHelper.Wobbler wobbler; - private final NeedleDirectionHelper.Wobbler noTargetWobbler; + private final Wobbler wobbler; + private final Wobbler noTargetWobbler; private final CompassAngleState.CompassTarget compassTarget; private final RandomSource random = RandomSource.create(); diff --git a/net/minecraft/client/renderer/item/properties/numeric/Time.java b/net/minecraft/client/renderer/item/properties/numeric/Time.java index 263a6872..c011314c 100644 --- a/net/minecraft/client/renderer/item/properties/numeric/Time.java +++ b/net/minecraft/client/renderer/item/properties/numeric/Time.java @@ -6,6 +6,7 @@ import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.multiplayer.ClientLevel; +import net.minecraft.client.renderer.item.properties.numeric.NeedleDirectionHelper.Wobbler; import net.minecraft.util.RandomSource; import net.minecraft.util.StringRepresentable; import net.minecraft.world.entity.Entity; @@ -21,7 +22,7 @@ public class Time extends NeedleDirectionHelper implements RangeSelectItemModelP ); private final Time.TimeSource source; private final RandomSource randomSource = RandomSource.create(); - private final NeedleDirectionHelper.Wobbler wobbler; + private final Wobbler wobbler; public Time(boolean wobble, Time.TimeSource source) { super(wobble); diff --git a/net/minecraft/client/renderer/item/properties/select/Charge.java b/net/minecraft/client/renderer/item/properties/select/Charge.java index e99a2efd..21eac1b1 100644 --- a/net/minecraft/client/renderer/item/properties/select/Charge.java +++ b/net/minecraft/client/renderer/item/properties/select/Charge.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.item.properties.select; +import com.mojang.serialization.Codec; import com.mojang.serialization.MapCodec; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -15,8 +16,9 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public record Charge() implements SelectItemModelProperty { + public static final Codec VALUE_CODEC = CrossbowItem.ChargeType.CODEC; public static final SelectItemModelProperty.Type TYPE = SelectItemModelProperty.Type.create( - MapCodec.unit(new Charge()), CrossbowItem.ChargeType.CODEC + MapCodec.unit(new Charge()), VALUE_CODEC ); public CrossbowItem.ChargeType get( @@ -34,4 +36,9 @@ public record Charge() implements SelectItemModelProperty type() { return TYPE; } + + @Override + public Codec valueCodec() { + return VALUE_CODEC; + } } diff --git a/net/minecraft/client/renderer/item/properties/select/ComponentContents.java b/net/minecraft/client/renderer/item/properties/select/ComponentContents.java new file mode 100644 index 00000000..a281391b --- /dev/null +++ b/net/minecraft/client/renderer/item/properties/select/ComponentContents.java @@ -0,0 +1,55 @@ +package net.minecraft.client.renderer.item.properties.select; + +import com.mojang.serialization.Codec; +import com.mojang.serialization.DataResult; +import com.mojang.serialization.MapCodec; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.multiplayer.ClientLevel; +import net.minecraft.client.renderer.item.SelectItemModel; +import net.minecraft.core.component.DataComponentType; +import net.minecraft.core.registries.BuiltInRegistries; +import net.minecraft.world.entity.LivingEntity; +import net.minecraft.world.item.ItemDisplayContext; +import net.minecraft.world.item.ItemStack; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public record ComponentContents(DataComponentType componentType) implements SelectItemModelProperty { + private static final SelectItemModelProperty.Type, ?> TYPE = createType(); + + private static SelectItemModelProperty.Type, T> createType() { + Codec> codec = BuiltInRegistries.DATA_COMPONENT_TYPE + .byNameCodec() + .validate( + dataComponentType -> dataComponentType.isTransient() ? DataResult.error(() -> "Component can't be serialized") : DataResult.success(dataComponentType) + ); + MapCodec, T>> mapCodec = codec.dispatchMap( + "component", + unbakedSwitch -> ((ComponentContents)unbakedSwitch.property()).componentType, + dataComponentType -> SelectItemModelProperty.Type.createCasesFieldCodec(dataComponentType.codecOrThrow()) + .xmap(list -> new SelectItemModel.UnbakedSwitch<>(new ComponentContents(dataComponentType), list), SelectItemModel.UnbakedSwitch::cases) + ); + return new SelectItemModelProperty.Type<>(mapCodec); + } + + public static SelectItemModelProperty.Type, T> castType() { + return (SelectItemModelProperty.Type, T>)TYPE; + } + + @Nullable + @Override + public T get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext) { + return stack.get(this.componentType); + } + + @Override + public SelectItemModelProperty.Type, T> type() { + return castType(); + } + + @Override + public Codec valueCodec() { + return this.componentType.codecOrThrow(); + } +} diff --git a/net/minecraft/client/renderer/item/properties/select/ContextDimension.java b/net/minecraft/client/renderer/item/properties/select/ContextDimension.java index c9b75432..54845dc5 100644 --- a/net/minecraft/client/renderer/item/properties/select/ContextDimension.java +++ b/net/minecraft/client/renderer/item/properties/select/ContextDimension.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.item.properties.select; +import com.mojang.serialization.Codec; import com.mojang.serialization.MapCodec; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -14,8 +15,9 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public record ContextDimension() implements SelectItemModelProperty> { + public static final Codec> VALUE_CODEC = ResourceKey.codec(Registries.DIMENSION); public static final SelectItemModelProperty.Type> TYPE = SelectItemModelProperty.Type.create( - MapCodec.unit(new ContextDimension()), ResourceKey.codec(Registries.DIMENSION) + MapCodec.unit(new ContextDimension()), VALUE_CODEC ); @Nullable @@ -29,4 +31,9 @@ public record ContextDimension() implements SelectItemModelProperty> type() { return TYPE; } + + @Override + public Codec> valueCodec() { + return VALUE_CODEC; + } } diff --git a/net/minecraft/client/renderer/item/properties/select/ContextEntityType.java b/net/minecraft/client/renderer/item/properties/select/ContextEntityType.java index d4a05a48..a87299cc 100644 --- a/net/minecraft/client/renderer/item/properties/select/ContextEntityType.java +++ b/net/minecraft/client/renderer/item/properties/select/ContextEntityType.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.item.properties.select; +import com.mojang.serialization.Codec; import com.mojang.serialization.MapCodec; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -14,8 +15,9 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public record ContextEntityType() implements SelectItemModelProperty>> { + public static final Codec>> VALUE_CODEC = ResourceKey.codec(Registries.ENTITY_TYPE); public static final SelectItemModelProperty.Type>> TYPE = SelectItemModelProperty.Type.create( - MapCodec.unit(new ContextEntityType()), ResourceKey.codec(Registries.ENTITY_TYPE) + MapCodec.unit(new ContextEntityType()), VALUE_CODEC ); @Nullable @@ -29,4 +31,9 @@ public record ContextEntityType() implements SelectItemModelProperty>> type() { return TYPE; } + + @Override + public Codec>> valueCodec() { + return VALUE_CODEC; + } } diff --git a/net/minecraft/client/renderer/item/properties/select/CustomModelDataProperty.java b/net/minecraft/client/renderer/item/properties/select/CustomModelDataProperty.java index f44a6de0..bb8aa17b 100644 --- a/net/minecraft/client/renderer/item/properties/select/CustomModelDataProperty.java +++ b/net/minecraft/client/renderer/item/properties/select/CustomModelDataProperty.java @@ -1,6 +1,7 @@ package net.minecraft.client.renderer.item.properties.select; import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.PrimitiveCodec; import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -15,12 +16,13 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public record CustomModelDataProperty(int index) implements SelectItemModelProperty { + public static final PrimitiveCodec VALUE_CODEC = Codec.STRING; public static final SelectItemModelProperty.Type TYPE = SelectItemModelProperty.Type.create( RecordCodecBuilder.mapCodec( instance -> instance.group(ExtraCodecs.NON_NEGATIVE_INT.optionalFieldOf("index", 0).forGetter(CustomModelDataProperty::index)) .apply(instance, CustomModelDataProperty::new) ), - Codec.STRING + VALUE_CODEC ); @Nullable @@ -33,4 +35,9 @@ public record CustomModelDataProperty(int index) implements SelectItemModelPrope public SelectItemModelProperty.Type type() { return TYPE; } + + @Override + public Codec valueCodec() { + return VALUE_CODEC; + } } diff --git a/net/minecraft/client/renderer/item/properties/select/DisplayContext.java b/net/minecraft/client/renderer/item/properties/select/DisplayContext.java index d43ab9d6..bb0c7d86 100644 --- a/net/minecraft/client/renderer/item/properties/select/DisplayContext.java +++ b/net/minecraft/client/renderer/item/properties/select/DisplayContext.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.item.properties.select; +import com.mojang.serialization.Codec; import com.mojang.serialization.MapCodec; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -11,8 +12,9 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public record DisplayContext() implements SelectItemModelProperty { + public static final Codec VALUE_CODEC = ItemDisplayContext.CODEC; public static final SelectItemModelProperty.Type TYPE = SelectItemModelProperty.Type.create( - MapCodec.unit(new DisplayContext()), ItemDisplayContext.CODEC + MapCodec.unit(new DisplayContext()), VALUE_CODEC ); public ItemDisplayContext get( @@ -25,4 +27,9 @@ public record DisplayContext() implements SelectItemModelProperty type() { return TYPE; } + + @Override + public Codec valueCodec() { + return VALUE_CODEC; + } } diff --git a/net/minecraft/client/renderer/item/properties/select/ItemBlockState.java b/net/minecraft/client/renderer/item/properties/select/ItemBlockState.java index 9cceab28..973dc001 100644 --- a/net/minecraft/client/renderer/item/properties/select/ItemBlockState.java +++ b/net/minecraft/client/renderer/item/properties/select/ItemBlockState.java @@ -1,6 +1,7 @@ package net.minecraft.client.renderer.item.properties.select; import com.mojang.serialization.Codec; +import com.mojang.serialization.codecs.PrimitiveCodec; import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -14,11 +15,12 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public record ItemBlockState(String property) implements SelectItemModelProperty { + public static final PrimitiveCodec VALUE_CODEC = Codec.STRING; public static final SelectItemModelProperty.Type TYPE = SelectItemModelProperty.Type.create( RecordCodecBuilder.mapCodec( instance -> instance.group(Codec.STRING.fieldOf("block_state_property").forGetter(ItemBlockState::property)).apply(instance, ItemBlockState::new) ), - Codec.STRING + VALUE_CODEC ); @Nullable @@ -31,4 +33,9 @@ public record ItemBlockState(String property) implements SelectItemModelProperty public SelectItemModelProperty.Type type() { return TYPE; } + + @Override + public Codec valueCodec() { + return VALUE_CODEC; + } } diff --git a/net/minecraft/client/renderer/item/properties/select/LocalTime.java b/net/minecraft/client/renderer/item/properties/select/LocalTime.java index 551eaf43..69aaf8cf 100644 --- a/net/minecraft/client/renderer/item/properties/select/LocalTime.java +++ b/net/minecraft/client/renderer/item/properties/select/LocalTime.java @@ -25,7 +25,8 @@ import org.jetbrains.annotations.Nullable; public class LocalTime implements SelectItemModelProperty { public static final String ROOT_LOCALE = ""; private static final long UPDATE_INTERVAL_MS = TimeUnit.SECONDS.toMillis(1L); - private static final Codec TIME_ZONE_CODEC = Codec.STRING.comapFlatMap(string -> { + public static final Codec VALUE_CODEC = Codec.STRING; + private static final Codec TIME_ZONE_CODEC = VALUE_CODEC.comapFlatMap(string -> { TimeZone timeZone = TimeZone.getTimeZone(string); return timeZone.equals(TimeZone.UNKNOWN_ZONE) ? DataResult.error(() -> "Unknown timezone: " + string) : DataResult.success(timeZone); }, TimeZone::getID); @@ -38,7 +39,7 @@ public class LocalTime implements SelectItemModelProperty { .apply(instance, LocalTime.Data::new) ); public static final SelectItemModelProperty.Type TYPE = SelectItemModelProperty.Type.create( - DATA_MAP_CODEC.flatXmap(LocalTime::create, localTime -> DataResult.success(localTime.data)), Codec.STRING + DATA_MAP_CODEC.flatXmap(LocalTime::create, localTime -> DataResult.success(localTime.data)), VALUE_CODEC ); private final LocalTime.Data data; private final DateFormat parsedFormat; @@ -89,6 +90,11 @@ public class LocalTime implements SelectItemModelProperty { return TYPE; } + @Override + public Codec valueCodec() { + return VALUE_CODEC; + } + @Environment(EnvType.CLIENT) record Data(String format, String localeId, Optional timeZone) { } diff --git a/net/minecraft/client/renderer/item/properties/select/MainHand.java b/net/minecraft/client/renderer/item/properties/select/MainHand.java index 792d214f..6e7accb2 100644 --- a/net/minecraft/client/renderer/item/properties/select/MainHand.java +++ b/net/minecraft/client/renderer/item/properties/select/MainHand.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.item.properties.select; +import com.mojang.serialization.Codec; import com.mojang.serialization.MapCodec; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -12,9 +13,8 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public record MainHand() implements SelectItemModelProperty { - public static final SelectItemModelProperty.Type TYPE = SelectItemModelProperty.Type.create( - MapCodec.unit(new MainHand()), HumanoidArm.CODEC - ); + public static final Codec VALUE_CODEC = HumanoidArm.CODEC; + public static final SelectItemModelProperty.Type TYPE = SelectItemModelProperty.Type.create(MapCodec.unit(new MainHand()), VALUE_CODEC); @Nullable public HumanoidArm get( @@ -27,4 +27,9 @@ public record MainHand() implements SelectItemModelProperty { public SelectItemModelProperty.Type type() { return TYPE; } + + @Override + public Codec valueCodec() { + return VALUE_CODEC; + } } diff --git a/net/minecraft/client/renderer/item/properties/select/SelectItemModelProperties.java b/net/minecraft/client/renderer/item/properties/select/SelectItemModelProperties.java index 33025fa7..c1ba3be0 100644 --- a/net/minecraft/client/renderer/item/properties/select/SelectItemModelProperties.java +++ b/net/minecraft/client/renderer/item/properties/select/SelectItemModelProperties.java @@ -21,5 +21,6 @@ public class SelectItemModelProperties { ID_MAPPER.put(ResourceLocation.withDefaultNamespace("local_time"), LocalTime.TYPE); ID_MAPPER.put(ResourceLocation.withDefaultNamespace("context_entity_type"), ContextEntityType.TYPE); ID_MAPPER.put(ResourceLocation.withDefaultNamespace("context_dimension"), ContextDimension.TYPE); + ID_MAPPER.put(ResourceLocation.withDefaultNamespace("component"), ComponentContents.castType()); } } diff --git a/net/minecraft/client/renderer/item/properties/select/SelectItemModelProperty.java b/net/minecraft/client/renderer/item/properties/select/SelectItemModelProperty.java index 90cc8ea6..03965ad8 100644 --- a/net/minecraft/client/renderer/item/properties/select/SelectItemModelProperty.java +++ b/net/minecraft/client/renderer/item/properties/select/SelectItemModelProperty.java @@ -22,44 +22,47 @@ public interface SelectItemModelProperty { @Nullable T get(ItemStack stack, @Nullable ClientLevel level, @Nullable LivingEntity entity, int seed, ItemDisplayContext displayContext); + Codec valueCodec(); + SelectItemModelProperty.Type, T> type(); @Environment(EnvType.CLIENT) public record Type

, T>(MapCodec> switchCodec) { public static

, T> SelectItemModelProperty.Type create(MapCodec

mapCodec, Codec codec) { - Codec>> codec2 = SelectItemModel.SwitchCase.codec(codec) - .listOf() - .validate( - list -> { - if (list.isEmpty()) { - return DataResult.error(() -> "Empty case list"); - } else { - Multiset multiset = HashMultiset.create(); - - for (SelectItemModel.SwitchCase switchCase : list) { - multiset.addAll(switchCase.values()); - } - - return multiset.size() != multiset.entrySet().size() - ? DataResult.error( - () -> "Duplicate case conditions: " - + (String)multiset.entrySet() - .stream() - .filter(entry -> entry.getCount() > 1) - .map(entry -> entry.getElement().toString()) - .collect(Collectors.joining(", ")) - ) - : DataResult.success(list); - } - } - ); MapCodec> mapCodec2 = RecordCodecBuilder.mapCodec( instance -> instance.group( - mapCodec.forGetter(SelectItemModel.UnbakedSwitch::property), codec2.fieldOf("cases").forGetter(SelectItemModel.UnbakedSwitch::cases) + mapCodec.forGetter(SelectItemModel.UnbakedSwitch::property), createCasesFieldCodec(codec).forGetter(SelectItemModel.UnbakedSwitch::cases) ) .apply(instance, SelectItemModel.UnbakedSwitch::new) ); return new SelectItemModelProperty.Type<>(mapCodec2); } + + public static MapCodec>> createCasesFieldCodec(Codec codec) { + return SelectItemModel.SwitchCase.codec(codec).listOf().validate(SelectItemModelProperty.Type::validateCases).fieldOf("cases"); + } + + private static DataResult>> validateCases(List> cases) { + if (cases.isEmpty()) { + return DataResult.error(() -> "Empty case list"); + } else { + Multiset multiset = HashMultiset.create(); + + for (SelectItemModel.SwitchCase switchCase : cases) { + multiset.addAll(switchCase.values()); + } + + return multiset.size() != multiset.entrySet().size() + ? DataResult.error( + () -> "Duplicate case conditions: " + + (String)multiset.entrySet() + .stream() + .filter(entry -> entry.getCount() > 1) + .map(entry -> entry.getElement().toString()) + .collect(Collectors.joining(", ")) + ) + : DataResult.success(cases); + } + } } } diff --git a/net/minecraft/client/renderer/item/properties/select/TrimMaterialProperty.java b/net/minecraft/client/renderer/item/properties/select/TrimMaterialProperty.java index 3a958275..4ee3b92b 100644 --- a/net/minecraft/client/renderer/item/properties/select/TrimMaterialProperty.java +++ b/net/minecraft/client/renderer/item/properties/select/TrimMaterialProperty.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.item.properties.select; +import com.mojang.serialization.Codec; import com.mojang.serialization.MapCodec; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -16,8 +17,9 @@ import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public record TrimMaterialProperty() implements SelectItemModelProperty> { + public static final Codec> VALUE_CODEC = ResourceKey.codec(Registries.TRIM_MATERIAL); public static final SelectItemModelProperty.Type> TYPE = SelectItemModelProperty.Type.create( - MapCodec.unit(new TrimMaterialProperty()), ResourceKey.codec(Registries.TRIM_MATERIAL) + MapCodec.unit(new TrimMaterialProperty()), VALUE_CODEC ); @Nullable @@ -32,4 +34,9 @@ public record TrimMaterialProperty() implements SelectItemModelProperty> type() { return TYPE; } + + @Override + public Codec> valueCodec() { + return VALUE_CODEC; + } } diff --git a/net/minecraft/client/renderer/special/BedSpecialRenderer.java b/net/minecraft/client/renderer/special/BedSpecialRenderer.java index f2b3e5b1..0d5e90aa 100644 --- a/net/minecraft/client/renderer/special/BedSpecialRenderer.java +++ b/net/minecraft/client/renderer/special/BedSpecialRenderer.java @@ -32,7 +32,7 @@ public class BedSpecialRenderer implements NoDataSpecialModelRenderer { } @Environment(EnvType.CLIENT) - public record Unbaked(ResourceLocation texture) implements SpecialModelRenderer.Unbaked { + public record Unbaked(ResourceLocation texture) implements net.minecraft.client.renderer.special.SpecialModelRenderer.Unbaked { public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group(ResourceLocation.CODEC.fieldOf("texture").forGetter(BedSpecialRenderer.Unbaked::texture)) .apply(instance, BedSpecialRenderer.Unbaked::new) @@ -49,7 +49,7 @@ public class BedSpecialRenderer implements NoDataSpecialModelRenderer { @Override public SpecialModelRenderer bake(EntityModelSet modelSet) { - return new BedSpecialRenderer(new BedRenderer(modelSet), Sheets.createBedMaterial(this.texture)); + return new BedSpecialRenderer(new BedRenderer(modelSet), Sheets.BED_MAPPER.apply(this.texture)); } } } diff --git a/net/minecraft/client/renderer/special/ChestSpecialRenderer.java b/net/minecraft/client/renderer/special/ChestSpecialRenderer.java index 88b87630..a75771ac 100644 --- a/net/minecraft/client/renderer/special/ChestSpecialRenderer.java +++ b/net/minecraft/client/renderer/special/ChestSpecialRenderer.java @@ -43,7 +43,7 @@ public class ChestSpecialRenderer implements NoDataSpecialModelRenderer { } @Environment(EnvType.CLIENT) - public record Unbaked(ResourceLocation texture, float openness) implements SpecialModelRenderer.Unbaked { + public record Unbaked(ResourceLocation texture, float openness) implements net.minecraft.client.renderer.special.SpecialModelRenderer.Unbaked { public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( ResourceLocation.CODEC.fieldOf("texture").forGetter(ChestSpecialRenderer.Unbaked::texture), @@ -64,7 +64,7 @@ public class ChestSpecialRenderer implements NoDataSpecialModelRenderer { @Override public SpecialModelRenderer bake(EntityModelSet modelSet) { ChestModel chestModel = new ChestModel(modelSet.bakeLayer(ModelLayers.CHEST)); - Material material = Sheets.chestMaterial(this.texture); + Material material = Sheets.CHEST_MAPPER.apply(this.texture); return new ChestSpecialRenderer(chestModel, material, this.openness); } } diff --git a/net/minecraft/client/renderer/special/HangingSignSpecialRenderer.java b/net/minecraft/client/renderer/special/HangingSignSpecialRenderer.java index 07387814..8ee069de 100644 --- a/net/minecraft/client/renderer/special/HangingSignSpecialRenderer.java +++ b/net/minecraft/client/renderer/special/HangingSignSpecialRenderer.java @@ -34,7 +34,7 @@ public class HangingSignSpecialRenderer implements NoDataSpecialModelRenderer { } @Environment(EnvType.CLIENT) - public record Unbaked(WoodType woodType, Optional texture) implements SpecialModelRenderer.Unbaked { + public record Unbaked(WoodType woodType, Optional texture) implements net.minecraft.client.renderer.special.SpecialModelRenderer.Unbaked { public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( WoodType.CODEC.fieldOf("wood_type").forGetter(HangingSignSpecialRenderer.Unbaked::woodType), @@ -55,7 +55,7 @@ public class HangingSignSpecialRenderer implements NoDataSpecialModelRenderer { @Override public SpecialModelRenderer bake(EntityModelSet modelSet) { Model model = HangingSignRenderer.createSignModel(modelSet, this.woodType, HangingSignRenderer.AttachmentType.CEILING_MIDDLE); - Material material = (Material)this.texture.map(Sheets::createHangingSignMaterial).orElseGet(() -> Sheets.getHangingSignMaterial(this.woodType)); + Material material = (Material)this.texture.map(Sheets.HANGING_SIGN_MAPPER::apply).orElseGet(() -> Sheets.getHangingSignMaterial(this.woodType)); return new HangingSignSpecialRenderer(model, material); } } diff --git a/net/minecraft/client/renderer/special/ShulkerBoxSpecialRenderer.java b/net/minecraft/client/renderer/special/ShulkerBoxSpecialRenderer.java index 8730e52b..aa84b525 100644 --- a/net/minecraft/client/renderer/special/ShulkerBoxSpecialRenderer.java +++ b/net/minecraft/client/renderer/special/ShulkerBoxSpecialRenderer.java @@ -38,7 +38,8 @@ public class ShulkerBoxSpecialRenderer implements NoDataSpecialModelRenderer { } @Environment(EnvType.CLIENT) - public record Unbaked(ResourceLocation texture, float openness, Direction orientation) implements SpecialModelRenderer.Unbaked { + public record Unbaked(ResourceLocation texture, float openness, Direction orientation) + implements net.minecraft.client.renderer.special.SpecialModelRenderer.Unbaked { public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( ResourceLocation.CODEC.fieldOf("texture").forGetter(ShulkerBoxSpecialRenderer.Unbaked::texture), @@ -63,7 +64,7 @@ public class ShulkerBoxSpecialRenderer implements NoDataSpecialModelRenderer { @Override public SpecialModelRenderer bake(EntityModelSet modelSet) { - return new ShulkerBoxSpecialRenderer(new ShulkerBoxRenderer(modelSet), this.openness, this.orientation, Sheets.createShulkerMaterial(this.texture)); + return new ShulkerBoxSpecialRenderer(new ShulkerBoxRenderer(modelSet), this.openness, this.orientation, Sheets.SHULKER_MAPPER.apply(this.texture)); } } } diff --git a/net/minecraft/client/renderer/special/StandingSignSpecialRenderer.java b/net/minecraft/client/renderer/special/StandingSignSpecialRenderer.java index d8b83a88..9b3a3aee 100644 --- a/net/minecraft/client/renderer/special/StandingSignSpecialRenderer.java +++ b/net/minecraft/client/renderer/special/StandingSignSpecialRenderer.java @@ -34,7 +34,7 @@ public class StandingSignSpecialRenderer implements NoDataSpecialModelRenderer { } @Environment(EnvType.CLIENT) - public record Unbaked(WoodType woodType, Optional texture) implements SpecialModelRenderer.Unbaked { + public record Unbaked(WoodType woodType, Optional texture) implements net.minecraft.client.renderer.special.SpecialModelRenderer.Unbaked { public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( WoodType.CODEC.fieldOf("wood_type").forGetter(StandingSignSpecialRenderer.Unbaked::woodType), @@ -55,7 +55,7 @@ public class StandingSignSpecialRenderer implements NoDataSpecialModelRenderer { @Override public SpecialModelRenderer bake(EntityModelSet modelSet) { Model model = SignRenderer.createSignModel(modelSet, this.woodType, true); - Material material = (Material)this.texture.map(Sheets::createSignMaterial).orElseGet(() -> Sheets.getSignMaterial(this.woodType)); + Material material = (Material)this.texture.map(Sheets.SIGN_MAPPER::apply).orElseGet(() -> Sheets.getSignMaterial(this.woodType)); return new StandingSignSpecialRenderer(model, material); } } diff --git a/net/minecraft/client/renderer/texture/AbstractTexture.java b/net/minecraft/client/renderer/texture/AbstractTexture.java index ad09105f..40fff5fe 100644 --- a/net/minecraft/client/renderer/texture/AbstractTexture.java +++ b/net/minecraft/client/renderer/texture/AbstractTexture.java @@ -1,47 +1,24 @@ package net.minecraft.client.renderer.texture; -import com.mojang.blaze3d.platform.GlStateManager; -import com.mojang.blaze3d.platform.TextureUtil; -import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.AddressMode; +import com.mojang.blaze3d.textures.FilterMode; +import com.mojang.blaze3d.textures.GpuTexture; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.util.TriState; +import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) public abstract class AbstractTexture implements AutoCloseable { - public static final int NOT_ASSIGNED = -1; - protected int id = -1; + @Nullable + protected GpuTexture texture; protected boolean defaultBlur; - private int wrapS = 10497; - private int wrapT = 10497; - private int minFilter = 9986; - private int magFilter = 9729; public void setClamp(boolean clamp) { - RenderSystem.assertOnRenderThreadOrInit(); - int i; - int j; - if (clamp) { - i = 33071; - j = 33071; + if (this.texture == null) { + throw new IllegalStateException("Texture does not exist, can't change its clamp before something initializes it"); } else { - i = 10497; - j = 10497; - } - - boolean bl = this.wrapS != i; - boolean bl2 = this.wrapT != j; - if (bl || bl2) { - this.bind(); - if (bl) { - GlStateManager._texParameter(3553, 10242, i); - this.wrapS = i; - } - - if (bl2) { - GlStateManager._texParameter(3553, 10243, j); - this.wrapT = j; - } + this.texture.setAddressMode(clamp ? AddressMode.CLAMP_TO_EDGE : AddressMode.REPEAT); } } @@ -53,64 +30,25 @@ public abstract class AbstractTexture implements AutoCloseable { * @param mipmap {@code true} if a mipmap is being used (mip level is greater than 0) */ public void setFilter(boolean blur, boolean mipmap) { - RenderSystem.assertOnRenderThreadOrInit(); - int i; - int j; - if (blur) { - i = mipmap ? 9987 : 9729; - j = 9729; + if (this.texture == null) { + throw new IllegalStateException("Texture does not exist, can't get change its filter before something initializes it"); } else { - i = mipmap ? 9986 : 9728; - j = 9728; - } - - boolean bl = this.minFilter != i; - boolean bl2 = this.magFilter != j; - if (bl2 || bl) { - this.bind(); - if (bl) { - GlStateManager._texParameter(3553, 10241, i); - this.minFilter = i; - } - - if (bl2) { - GlStateManager._texParameter(3553, 10240, j); - this.magFilter = j; - } - } - } - - public int getId() { - RenderSystem.assertOnRenderThreadOrInit(); - if (this.id == -1) { - this.id = TextureUtil.generateTextureId(); - } - - return this.id; - } - - public void releaseId() { - if (!RenderSystem.isOnRenderThread()) { - RenderSystem.recordRenderCall(() -> { - if (this.id != -1) { - TextureUtil.releaseTextureId(this.id); - this.id = -1; - } - }); - } else if (this.id != -1) { - TextureUtil.releaseTextureId(this.id); - this.id = -1; - } - } - - public void bind() { - if (!RenderSystem.isOnRenderThreadOrInit()) { - RenderSystem.recordRenderCall(() -> GlStateManager._bindTexture(this.getId())); - } else { - GlStateManager._bindTexture(this.getId()); + this.texture.setTextureFilter(blur ? FilterMode.LINEAR : FilterMode.NEAREST, mipmap); } } public void close() { + if (this.texture != null) { + this.texture.close(); + this.texture = null; + } + } + + public GpuTexture getTexture() { + if (this.texture == null) { + throw new IllegalStateException("Texture does not exist, can't get it before something initializes it"); + } else { + return this.texture; + } } } diff --git a/net/minecraft/client/renderer/texture/DynamicTexture.java b/net/minecraft/client/renderer/texture/DynamicTexture.java index ea707eb9..0fdbc6c1 100644 --- a/net/minecraft/client/renderer/texture/DynamicTexture.java +++ b/net/minecraft/client/renderer/texture/DynamicTexture.java @@ -1,11 +1,12 @@ package net.minecraft.client.renderer.texture; import com.mojang.blaze3d.platform.NativeImage; -import com.mojang.blaze3d.platform.TextureUtil; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.TextureFormat; import com.mojang.logging.LogUtils; import java.io.IOException; import java.nio.file.Path; +import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.resources.ResourceLocation; @@ -18,30 +19,27 @@ public class DynamicTexture extends AbstractTexture implements Dumpable { @Nullable private NativeImage pixels; - public DynamicTexture(NativeImage pixels) { + public DynamicTexture(Supplier label, NativeImage pixels) { this.pixels = pixels; - if (!RenderSystem.isOnRenderThread()) { - RenderSystem.recordRenderCall(() -> { - TextureUtil.prepareImage(this.getId(), this.pixels.getWidth(), this.pixels.getHeight()); - this.upload(); - }); - } else { - TextureUtil.prepareImage(this.getId(), this.pixels.getWidth(), this.pixels.getHeight()); - this.upload(); - } + this.texture = RenderSystem.getDevice().createTexture(label, TextureFormat.RGBA8, this.pixels.getWidth(), this.pixels.getHeight(), 1); + this.upload(); } - public DynamicTexture(int width, int height, boolean useCalloc) { + public DynamicTexture(String label, int width, int height, boolean useCalloc) { this.pixels = new NativeImage(width, height, useCalloc); - TextureUtil.prepareImage(this.getId(), this.pixels.getWidth(), this.pixels.getHeight()); + this.texture = RenderSystem.getDevice().createTexture(label, TextureFormat.RGBA8, this.pixels.getWidth(), this.pixels.getHeight(), 1); + } + + public DynamicTexture(Supplier label, int width, int height, boolean useCalloc) { + this.pixels = new NativeImage(width, height, useCalloc); + this.texture = RenderSystem.getDevice().createTexture(label, TextureFormat.RGBA8, this.pixels.getWidth(), this.pixels.getHeight(), 1); } public void upload() { - if (this.pixels != null) { - this.bind(); - this.pixels.upload(0, 0, 0, false); + if (this.pixels != null && this.texture != null) { + RenderSystem.getDevice().createCommandEncoder().writeToTexture(this.texture, this.pixels); } else { - LOGGER.warn("Trying to upload disposed texture {}", this.getId()); + LOGGER.warn("Trying to upload disposed texture {}", this.getTexture().getLabel()); } } @@ -62,9 +60,10 @@ public class DynamicTexture extends AbstractTexture implements Dumpable { public void close() { if (this.pixels != null) { this.pixels.close(); - this.releaseId(); this.pixels = null; } + + super.close(); } @Override diff --git a/net/minecraft/client/renderer/texture/OverlayTexture.java b/net/minecraft/client/renderer/texture/OverlayTexture.java index 2f06cf76..2f4cd90d 100644 --- a/net/minecraft/client/renderer/texture/OverlayTexture.java +++ b/net/minecraft/client/renderer/texture/OverlayTexture.java @@ -13,7 +13,7 @@ public class OverlayTexture implements AutoCloseable { public static final int RED_OVERLAY_V = 3; public static final int WHITE_OVERLAY_V = 10; public static final int NO_OVERLAY = pack(0, 10); - private final DynamicTexture texture = new DynamicTexture(16, 16, false); + private final DynamicTexture texture = new DynamicTexture("Entity Color Overlay", 16, 16, false); public OverlayTexture() { NativeImage nativeImage = this.texture.getPixels(); @@ -29,12 +29,9 @@ public class OverlayTexture implements AutoCloseable { } } - RenderSystem.activeTexture(33985); - this.texture.bind(); this.texture.setFilter(false, false); this.texture.setClamp(true); - nativeImage.upload(0, 0, 0, 0, 0, nativeImage.getWidth(), nativeImage.getHeight(), false); - RenderSystem.activeTexture(33984); + this.texture.upload(); } public void close() { @@ -42,7 +39,7 @@ public class OverlayTexture implements AutoCloseable { } public void setupOverlayColor() { - RenderSystem.setupOverlayColor(this.texture.getId(), 16); + RenderSystem.setupOverlayColor(this.texture.getTexture()); } public static int u(float u) { diff --git a/net/minecraft/client/renderer/texture/ReloadableTexture.java b/net/minecraft/client/renderer/texture/ReloadableTexture.java index 4aa6169d..9c8476d5 100644 --- a/net/minecraft/client/renderer/texture/ReloadableTexture.java +++ b/net/minecraft/client/renderer/texture/ReloadableTexture.java @@ -1,8 +1,9 @@ package net.minecraft.client.renderer.texture; import com.mojang.blaze3d.platform.NativeImage; -import com.mojang.blaze3d.platform.TextureUtil; +import com.mojang.blaze3d.systems.GpuDevice; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.TextureFormat; import java.io.IOException; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -25,19 +26,18 @@ public abstract class ReloadableTexture extends AbstractTexture { boolean bl = textureContents.clamp(); boolean bl2 = textureContents.blur(); this.defaultBlur = bl2; - NativeImage nativeImage = textureContents.image(); - if (!RenderSystem.isOnRenderThreadOrInit()) { - RenderSystem.recordRenderCall(() -> this.doLoad(nativeImage, bl2, bl)); - } else { + + try (NativeImage nativeImage = textureContents.image()) { this.doLoad(nativeImage, bl2, bl); } } private void doLoad(NativeImage image, boolean blur, boolean clamp) { - TextureUtil.prepareImage(this.getId(), 0, image.getWidth(), image.getHeight()); + GpuDevice gpuDevice = RenderSystem.getDevice(); + this.texture = gpuDevice.createTexture(this.resourceId::toString, TextureFormat.RGBA8, image.getWidth(), image.getHeight(), 1); this.setFilter(blur, false); this.setClamp(clamp); - image.upload(0, 0, 0, 0, 0, image.getWidth(), image.getHeight(), true); + gpuDevice.createCommandEncoder().writeToTexture(this.texture, image); } public abstract TextureContents loadContents(ResourceManager resourceManager) throws IOException; diff --git a/net/minecraft/client/renderer/texture/SkinTextureDownloader.java b/net/minecraft/client/renderer/texture/SkinTextureDownloader.java index 030a749d..bf8363d9 100644 --- a/net/minecraft/client/renderer/texture/SkinTextureDownloader.java +++ b/net/minecraft/client/renderer/texture/SkinTextureDownloader.java @@ -105,7 +105,7 @@ public class SkinTextureDownloader { private static CompletableFuture registerTextureInManager(ResourceLocation location, NativeImage image) { Minecraft minecraft = Minecraft.getInstance(); return CompletableFuture.supplyAsync(() -> { - minecraft.getTextureManager().register(location, new DynamicTexture(image)); + minecraft.getTextureManager().register(location, new DynamicTexture(location::toString, image)); return location; }, minecraft); } diff --git a/net/minecraft/client/renderer/texture/SpriteContents.java b/net/minecraft/client/renderer/texture/SpriteContents.java index 4d431bd0..a5064265 100644 --- a/net/minecraft/client/renderer/texture/SpriteContents.java +++ b/net/minecraft/client/renderer/texture/SpriteContents.java @@ -1,6 +1,8 @@ package net.minecraft.client.renderer.texture; import com.mojang.blaze3d.platform.NativeImage; +import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.logging.LogUtils; import it.unimi.dsi.fastutil.ints.IntOpenHashSet; import it.unimi.dsi.fastutil.ints.IntSet; @@ -130,9 +132,11 @@ public class SpriteContents implements Entry, AutoCloseable { return list.size() <= 1 ? null : new SpriteContents.AnimatedTexture(List.copyOf(list), i, metadata.interpolatedFrames()); } - void upload(int x, int y, int frameX, int frameY, NativeImage[] atlasData) { + void upload(int x, int y, int sourceX, int sourceY, NativeImage[] images, GpuTexture texture) { for (int i = 0; i < this.byMipLevel.length; i++) { - atlasData[i].upload(i, x >> i, y >> i, frameX >> i, frameY >> i, this.width >> i, this.height >> i, false); + RenderSystem.getDevice() + .createCommandEncoder() + .writeToTexture(texture, images[i], i, x >> i, y >> i, this.width >> i, this.height >> i, sourceX >> i, sourceY >> i); } } @@ -185,11 +189,11 @@ public class SpriteContents implements Entry, AutoCloseable { return ARGB.alpha(this.originalImage.getPixel(i, j)) == 0; } - public void uploadFirstFrame(int x, int y) { + public void uploadFirstFrame(int x, int y, GpuTexture texture) { if (this.animatedTexture != null) { - this.animatedTexture.uploadFirstFrame(x, y); + this.animatedTexture.uploadFirstFrame(x, y, texture); } else { - this.upload(x, y, 0, 0, this.byMipLevel); + this.upload(x, y, 0, 0, this.byMipLevel, texture); } } @@ -213,18 +217,18 @@ public class SpriteContents implements Entry, AutoCloseable { return frameIndex / this.frameRowSize; } - void uploadFrame(int x, int y, int frameIndex) { + void uploadFrame(int x, int y, int frameIndex, GpuTexture texture) { int i = this.getFrameX(frameIndex) * SpriteContents.this.width; int j = this.getFrameY(frameIndex) * SpriteContents.this.height; - SpriteContents.this.upload(x, y, i, j, SpriteContents.this.byMipLevel); + SpriteContents.this.upload(x, y, i, j, SpriteContents.this.byMipLevel, texture); } public SpriteTicker createTicker() { return SpriteContents.this.new Ticker(this, this.interpolateFrames ? SpriteContents.this.new InterpolationData() : null); } - public void uploadFirstFrame(int x, int y) { - this.uploadFrame(x, y, ((SpriteContents.FrameInfo)this.frames.get(0)).index); + public void uploadFirstFrame(int x, int y, GpuTexture texture) { + this.uploadFrame(x, y, ((SpriteContents.FrameInfo)this.frames.get(0)).index, texture); } public IntStream getUniqueFrames() { @@ -248,7 +252,7 @@ public class SpriteContents implements Entry, AutoCloseable { } } - void uploadInterpolatedFrame(int x, int y, SpriteContents.Ticker ticker) { + void uploadInterpolatedFrame(int x, int y, SpriteContents.Ticker ticker, GpuTexture texture) { SpriteContents.AnimatedTexture animatedTexture = ticker.animationInfo; List list = animatedTexture.frames; SpriteContents.FrameInfo frameInfo = (SpriteContents.FrameInfo)list.get(ticker.frame); @@ -269,7 +273,7 @@ public class SpriteContents implements Entry, AutoCloseable { } } - SpriteContents.this.upload(x, y, 0, 0, this.activeFrame); + SpriteContents.this.upload(x, y, 0, 0, this.activeFrame, texture); } } @@ -302,7 +306,7 @@ public class SpriteContents implements Entry, AutoCloseable { } @Override - public void tickAndUpload(int x, int y) { + public void tickAndUpload(int x, int y, GpuTexture texture) { this.subFrame++; SpriteContents.FrameInfo frameInfo = (SpriteContents.FrameInfo)this.animationInfo.frames.get(this.frame); if (this.subFrame >= frameInfo.time) { @@ -311,10 +315,10 @@ public class SpriteContents implements Entry, AutoCloseable { this.subFrame = 0; int j = ((SpriteContents.FrameInfo)this.animationInfo.frames.get(this.frame)).index; if (i != j) { - this.animationInfo.uploadFrame(x, y, j); + this.animationInfo.uploadFrame(x, y, j, texture); } } else if (this.interpolationData != null) { - this.interpolationData.uploadInterpolatedFrame(x, y, this); + this.interpolationData.uploadInterpolatedFrame(x, y, this, texture); } } diff --git a/net/minecraft/client/renderer/texture/SpriteLoader.java b/net/minecraft/client/renderer/texture/SpriteLoader.java index 5ec62042..a77be0d8 100644 --- a/net/minecraft/client/renderer/texture/SpriteLoader.java +++ b/net/minecraft/client/renderer/texture/SpriteLoader.java @@ -11,6 +11,7 @@ import java.util.Set; import java.util.concurrent.CompletableFuture; import java.util.concurrent.Executor; import java.util.function.Function; +import java.util.function.Supplier; import java.util.stream.Collectors; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -25,6 +26,8 @@ import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.metadata.MetadataSectionType; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.util.Mth; +import net.minecraft.util.profiling.Profiler; +import net.minecraft.util.profiling.Zone; import org.slf4j.Logger; @Environment(EnvType.CLIENT) @@ -48,69 +51,74 @@ public class SpriteLoader { } public SpriteLoader.Preparations stitch(List contents, int mipLevel, Executor executor) { - int i = this.maxSupportedTextureSize; - Stitcher stitcher = new Stitcher<>(i, i, mipLevel); - int j = Integer.MAX_VALUE; - int k = 1 << mipLevel; + SpriteLoader.Preparations var17; + try (Zone zone = Profiler.get().zone((Supplier)(() -> "stitch " + this.location))) { + int i = this.maxSupportedTextureSize; + Stitcher stitcher = new Stitcher<>(i, i, mipLevel); + int j = Integer.MAX_VALUE; + int k = 1 << mipLevel; - for (SpriteContents spriteContents : contents) { - j = Math.min(j, Math.min(spriteContents.width(), spriteContents.height())); - int l = Math.min(Integer.lowestOneBit(spriteContents.width()), Integer.lowestOneBit(spriteContents.height())); - if (l < k) { - LOGGER.warn( - "Texture {} with size {}x{} limits mip level from {} to {}", - spriteContents.name(), - spriteContents.width(), - spriteContents.height(), - Mth.log2(k), - Mth.log2(l) - ); - k = l; + for (SpriteContents spriteContents : contents) { + j = Math.min(j, Math.min(spriteContents.width(), spriteContents.height())); + int l = Math.min(Integer.lowestOneBit(spriteContents.width()), Integer.lowestOneBit(spriteContents.height())); + if (l < k) { + LOGGER.warn( + "Texture {} with size {}x{} limits mip level from {} to {}", + spriteContents.name(), + spriteContents.width(), + spriteContents.height(), + Mth.log2(k), + Mth.log2(l) + ); + k = l; + } + + stitcher.registerSprite(spriteContents); } - stitcher.registerSprite(spriteContents); + int m = Math.min(j, k); + int n = Mth.log2(m); + int l; + if (n < mipLevel) { + LOGGER.warn("{}: dropping miplevel from {} to {}, because of minimum power of two: {}", this.location, mipLevel, n, m); + l = n; + } else { + l = mipLevel; + } + + try { + stitcher.stitch(); + } catch (StitcherException var19) { + CrashReport crashReport = CrashReport.forThrowable(var19, "Stitching"); + CrashReportCategory crashReportCategory = crashReport.addCategory("Stitcher"); + crashReportCategory.setDetail( + "Sprites", + var19.getAllSprites() + .stream() + .map(entry -> String.format(Locale.ROOT, "%s[%dx%d]", entry.name(), entry.width(), entry.height())) + .collect(Collectors.joining(",")) + ); + crashReportCategory.setDetail("Max Texture Size", i); + throw new ReportedException(crashReport); + } + + int o = Math.max(stitcher.getWidth(), this.minWidth); + int p = Math.max(stitcher.getHeight(), this.minHeight); + Map map = this.getStitchedSprites(stitcher, o, p); + TextureAtlasSprite textureAtlasSprite = (TextureAtlasSprite)map.get(MissingTextureAtlasSprite.getLocation()); + CompletableFuture completableFuture; + if (l > 0) { + completableFuture = CompletableFuture.runAsync( + () -> map.values().forEach(textureAtlasSpritex -> textureAtlasSpritex.contents().increaseMipLevel(l)), executor + ); + } else { + completableFuture = CompletableFuture.completedFuture(null); + } + + var17 = new SpriteLoader.Preparations(o, p, l, textureAtlasSprite, map, completableFuture); } - int m = Math.min(j, k); - int n = Mth.log2(m); - int l; - if (n < mipLevel) { - LOGGER.warn("{}: dropping miplevel from {} to {}, because of minimum power of two: {}", this.location, mipLevel, n, m); - l = n; - } else { - l = mipLevel; - } - - try { - stitcher.stitch(); - } catch (StitcherException var16) { - CrashReport crashReport = CrashReport.forThrowable(var16, "Stitching"); - CrashReportCategory crashReportCategory = crashReport.addCategory("Stitcher"); - crashReportCategory.setDetail( - "Sprites", - var16.getAllSprites() - .stream() - .map(entry -> String.format(Locale.ROOT, "%s[%dx%d]", entry.name(), entry.width(), entry.height())) - .collect(Collectors.joining(",")) - ); - crashReportCategory.setDetail("Max Texture Size", i); - throw new ReportedException(crashReport); - } - - int o = Math.max(stitcher.getWidth(), this.minWidth); - int p = Math.max(stitcher.getHeight(), this.minHeight); - Map map = this.getStitchedSprites(stitcher, o, p); - TextureAtlasSprite textureAtlasSprite = (TextureAtlasSprite)map.get(MissingTextureAtlasSprite.getLocation()); - CompletableFuture completableFuture; - if (l > 0) { - completableFuture = CompletableFuture.runAsync( - () -> map.values().forEach(textureAtlasSpritex -> textureAtlasSpritex.contents().increaseMipLevel(l)), executor - ); - } else { - completableFuture = CompletableFuture.completedFuture(null); - } - - return new SpriteLoader.Preparations(o, p, l, textureAtlasSprite, map, completableFuture); + return var17; } public static CompletableFuture> runSpriteSuppliers( diff --git a/net/minecraft/client/renderer/texture/SpriteTicker.java b/net/minecraft/client/renderer/texture/SpriteTicker.java index 000cf47e..929091e4 100644 --- a/net/minecraft/client/renderer/texture/SpriteTicker.java +++ b/net/minecraft/client/renderer/texture/SpriteTicker.java @@ -1,11 +1,12 @@ package net.minecraft.client.renderer.texture; +import com.mojang.blaze3d.textures.GpuTexture; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @Environment(EnvType.CLIENT) public interface SpriteTicker extends AutoCloseable { - void tickAndUpload(int x, int y); + void tickAndUpload(int x, int y, GpuTexture texture); void close(); } diff --git a/net/minecraft/client/renderer/texture/TextureAtlas.java b/net/minecraft/client/renderer/texture/TextureAtlas.java index 8d7bbfb5..83fccb2a 100644 --- a/net/minecraft/client/renderer/texture/TextureAtlas.java +++ b/net/minecraft/client/renderer/texture/TextureAtlas.java @@ -2,6 +2,7 @@ package net.minecraft.client.renderer.texture; import com.mojang.blaze3d.platform.TextureUtil; import com.mojang.blaze3d.systems.RenderSystem; +import com.mojang.blaze3d.textures.TextureFormat; import com.mojang.logging.LogUtils; import java.io.IOException; import java.io.Writer; @@ -17,7 +18,6 @@ import net.fabricmc.api.Environment; import net.minecraft.CrashReport; import net.minecraft.CrashReportCategory; import net.minecraft.ReportedException; -import net.minecraft.client.renderer.texture.TextureAtlasSprite.Ticker; import net.minecraft.resources.ResourceLocation; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -30,7 +30,7 @@ public class TextureAtlas extends AbstractTexture implements Dumpable, Tickable @Deprecated public static final ResourceLocation LOCATION_PARTICLES = ResourceLocation.withDefaultNamespace("textures/atlas/particles.png"); private List sprites = List.of(); - private List animatedTextures = List.of(); + private List animatedTextures = List.of(); private Map texturesByName = Map.of(); @Nullable private TextureAtlasSprite missingSprite; @@ -42,12 +42,13 @@ public class TextureAtlas extends AbstractTexture implements Dumpable, Tickable public TextureAtlas(ResourceLocation location) { this.location = location; - this.maxSupportedTextureSize = RenderSystem.maxSupportedTextureSize(); + this.maxSupportedTextureSize = RenderSystem.getDevice().getMaxTextureSize(); } public void upload(SpriteLoader.Preparations preparations) { LOGGER.info("Created: {}x{}x{} {}-atlas", preparations.width(), preparations.height(), preparations.mipLevel(), this.location); - TextureUtil.prepareImage(this.getId(), preparations.mipLevel(), preparations.width(), preparations.height()); + this.texture = RenderSystem.getDevice() + .createTexture(this.location::toString, TextureFormat.RGBA8, preparations.width(), preparations.height(), preparations.mipLevel() + 1); this.width = preparations.width(); this.height = preparations.height(); this.mipLevel = preparations.mipLevel(); @@ -59,13 +60,13 @@ public class TextureAtlas extends AbstractTexture implements Dumpable, Tickable throw new IllegalStateException("Atlas '" + this.location + "' (" + this.texturesByName.size() + " sprites) has no missing texture sprite"); } else { List list = new ArrayList(); - List list2 = new ArrayList(); + List list2 = new ArrayList(); for (TextureAtlasSprite textureAtlasSprite : preparations.regions().values()) { list.add(textureAtlasSprite.contents()); try { - textureAtlasSprite.uploadFirstFrame(); + textureAtlasSprite.uploadFirstFrame(this.texture); } catch (Throwable var9) { CrashReport crashReport = CrashReport.forThrowable(var9, "Stitching texture atlas"); CrashReportCategory crashReportCategory = crashReport.addCategory("Texture being stitched together"); @@ -74,7 +75,7 @@ public class TextureAtlas extends AbstractTexture implements Dumpable, Tickable throw new ReportedException(crashReport); } - Ticker ticker = textureAtlasSprite.createTicker(); + TextureAtlasSprite.Ticker ticker = textureAtlasSprite.createTicker(); if (ticker != null) { list2.add(ticker); } @@ -88,7 +89,7 @@ public class TextureAtlas extends AbstractTexture implements Dumpable, Tickable @Override public void dumpContents(ResourceLocation resourceLocation, Path path) throws IOException { String string = resourceLocation.toDebugFileName(); - TextureUtil.writeAsPNG(path, string, this.getId(), this.mipLevel, this.width, this.height); + TextureUtil.writeAsPNG(path, string, this.getTexture(), this.mipLevel, i -> i); dumpSpriteNames(path, string, this.texturesByName); } @@ -134,10 +135,10 @@ public class TextureAtlas extends AbstractTexture implements Dumpable, Tickable } public void cycleAnimationFrames() { - this.bind(); - - for (Ticker ticker : this.animatedTextures) { - ticker.tickAndUpload(); + if (this.texture != null) { + for (TextureAtlasSprite.Ticker ticker : this.animatedTextures) { + ticker.tickAndUpload(this.texture); + } } } @@ -157,7 +158,7 @@ public class TextureAtlas extends AbstractTexture implements Dumpable, Tickable public void clearTextureData() { this.sprites.forEach(SpriteContents::close); - this.animatedTextures.forEach(Ticker::close); + this.animatedTextures.forEach(TextureAtlasSprite.Ticker::close); this.sprites = List.of(); this.animatedTextures = List.of(); this.texturesByName = Map.of(); diff --git a/net/minecraft/client/renderer/texture/TextureAtlasSprite.java b/net/minecraft/client/renderer/texture/TextureAtlasSprite.java index a3709a30..07cbf451 100644 --- a/net/minecraft/client/renderer/texture/TextureAtlasSprite.java +++ b/net/minecraft/client/renderer/texture/TextureAtlasSprite.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.texture; +import com.mojang.blaze3d.textures.GpuTexture; import com.mojang.blaze3d.vertex.VertexConsumer; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @@ -60,8 +61,8 @@ public class TextureAtlasSprite { final SpriteTicker spriteTicker = this.contents.createTicker(); return spriteTicker != null ? new TextureAtlasSprite.Ticker() { @Override - public void tickAndUpload() { - spriteTicker.tickAndUpload(TextureAtlasSprite.this.x, TextureAtlasSprite.this.y); + public void tickAndUpload(GpuTexture texture) { + spriteTicker.tickAndUpload(TextureAtlasSprite.this.x, TextureAtlasSprite.this.y, texture); } @Override @@ -113,8 +114,8 @@ public class TextureAtlasSprite { return "TextureAtlasSprite{contents='" + this.contents + "', u0=" + this.u0 + ", u1=" + this.u1 + ", v0=" + this.v0 + ", v1=" + this.v1 + "}"; } - public void uploadFirstFrame() { - this.contents.uploadFirstFrame(this.x, this.y); + public void uploadFirstFrame(GpuTexture texture) { + this.contents.uploadFirstFrame(this.x, this.y, texture); } private float atlasSize() { @@ -133,7 +134,7 @@ public class TextureAtlasSprite { @Environment(EnvType.CLIENT) public interface Ticker extends AutoCloseable { - void tickAndUpload(); + void tickAndUpload(GpuTexture texture); void close(); } diff --git a/net/minecraft/client/renderer/texture/TextureManager.java b/net/minecraft/client/renderer/texture/TextureManager.java index 8e75813a..6ac8be37 100644 --- a/net/minecraft/client/renderer/texture/TextureManager.java +++ b/net/minecraft/client/renderer/texture/TextureManager.java @@ -1,7 +1,6 @@ package net.minecraft.client.renderer.texture; import com.mojang.blaze3d.platform.NativeImage; -import com.mojang.blaze3d.systems.RenderSystem; import com.mojang.logging.LogUtils; import com.mojang.realmsclient.gui.screens.AddRealmPopupScreen; import java.io.FileNotFoundException; @@ -25,7 +24,6 @@ import net.minecraft.ReportedException; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.PreparableReloadListener; import net.minecraft.server.packs.resources.ResourceManager; -import net.minecraft.server.packs.resources.PreparableReloadListener.PreparationBarrier; import org.slf4j.Logger; @Environment(EnvType.CLIENT) @@ -39,7 +37,7 @@ public class TextureManager implements PreparableReloadListener, Tickable, AutoC public TextureManager(ResourceManager resourceManager) { this.resourceManager = resourceManager; NativeImage nativeImage = MissingTextureAtlasSprite.generateMissingImage(); - this.register(MissingTextureAtlasSprite.getLocation(), new DynamicTexture(nativeImage)); + this.register(MissingTextureAtlasSprite.getLocation(), new DynamicTexture(() -> "(intentionally-)Missing Texture", nativeImage)); } public void registerAndLoad(ResourceLocation textureId, ReloadableTexture texture) { @@ -90,8 +88,6 @@ public class TextureManager implements PreparableReloadListener, Tickable, AutoC } catch (Exception var4) { LOGGER.warn("Failed to close texture {}", path, var4); } - - texture.releaseId(); } public AbstractTexture getTexture(ResourceLocation path) { @@ -126,33 +122,27 @@ public class TextureManager implements PreparableReloadListener, Tickable, AutoC } @Override - public CompletableFuture reload(PreparationBarrier barrier, ResourceManager manager, Executor backgroundExecutor, Executor gameExecutor) { + public CompletableFuture reload( + PreparableReloadListener.PreparationBarrier preparationBarrier, ResourceManager resourceManager, Executor executor, Executor executor2 + ) { List list = new ArrayList(); this.byPath.forEach((resourceLocation, abstractTexture) -> { if (abstractTexture instanceof ReloadableTexture reloadableTexture) { - list.add(scheduleLoad(manager, resourceLocation, reloadableTexture, backgroundExecutor)); + list.add(scheduleLoad(resourceManager, resourceLocation, reloadableTexture, executor)); } }); return CompletableFuture.allOf((CompletableFuture[])list.stream().map(TextureManager.PendingReload::newContents).toArray(CompletableFuture[]::new)) - .thenCompose(barrier::wait) + .thenCompose(preparationBarrier::wait) .thenAcceptAsync(void_ -> { AddRealmPopupScreen.updateCarouselImages(this.resourceManager); for (TextureManager.PendingReload pendingReload : list) { pendingReload.texture.apply((TextureContents)pendingReload.newContents.join()); } - }, gameExecutor); + }, executor2); } public void dumpAllSheets(Path path) { - if (!RenderSystem.isOnRenderThread()) { - RenderSystem.recordRenderCall(() -> this._dumpAllSheets(path)); - } else { - this._dumpAllSheets(path); - } - } - - private void _dumpAllSheets(Path path) { try { Files.createDirectories(path); } catch (IOException var3) { diff --git a/net/minecraft/client/renderer/texture/atlas/SpriteSource.java b/net/minecraft/client/renderer/texture/atlas/SpriteSource.java index 644a14b2..37d35327 100644 --- a/net/minecraft/client/renderer/texture/atlas/SpriteSource.java +++ b/net/minecraft/client/renderer/texture/atlas/SpriteSource.java @@ -1,5 +1,6 @@ package net.minecraft.client.renderer.texture.atlas; +import com.mojang.serialization.MapCodec; import java.util.function.Function; import java.util.function.Predicate; import net.fabricmc.api.EnvType; @@ -16,7 +17,7 @@ public interface SpriteSource { void run(ResourceManager resourceManager, SpriteSource.Output output); - SpriteSourceType type(); + MapCodec codec(); @Environment(EnvType.CLIENT) public interface Output { diff --git a/net/minecraft/client/renderer/texture/atlas/SpriteSourceType.java b/net/minecraft/client/renderer/texture/atlas/SpriteSourceType.java deleted file mode 100644 index 9b71d08f..00000000 --- a/net/minecraft/client/renderer/texture/atlas/SpriteSourceType.java +++ /dev/null @@ -1,9 +0,0 @@ -package net.minecraft.client.renderer.texture.atlas; - -import com.mojang.serialization.MapCodec; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; - -@Environment(EnvType.CLIENT) -public record SpriteSourceType(MapCodec codec) { -} diff --git a/net/minecraft/client/renderer/texture/atlas/SpriteSources.java b/net/minecraft/client/renderer/texture/atlas/SpriteSources.java index 4b8d6505..7ca47992 100644 --- a/net/minecraft/client/renderer/texture/atlas/SpriteSources.java +++ b/net/minecraft/client/renderer/texture/atlas/SpriteSources.java @@ -1,9 +1,6 @@ package net.minecraft.client.renderer.texture.atlas; -import com.google.common.collect.BiMap; -import com.google.common.collect.HashBiMap; import com.mojang.serialization.Codec; -import com.mojang.serialization.DataResult; import com.mojang.serialization.MapCodec; import java.util.List; import net.fabricmc.api.EnvType; @@ -14,33 +11,19 @@ import net.minecraft.client.renderer.texture.atlas.sources.SingleFile; import net.minecraft.client.renderer.texture.atlas.sources.SourceFilter; import net.minecraft.client.renderer.texture.atlas.sources.Unstitcher; import net.minecraft.resources.ResourceLocation; +import net.minecraft.util.ExtraCodecs; @Environment(EnvType.CLIENT) public class SpriteSources { - private static final BiMap TYPES = HashBiMap.create(); - public static final SpriteSourceType SINGLE_FILE = register("single", SingleFile.CODEC); - public static final SpriteSourceType DIRECTORY = register("directory", DirectoryLister.CODEC); - public static final SpriteSourceType FILTER = register("filter", SourceFilter.CODEC); - public static final SpriteSourceType UNSTITCHER = register("unstitch", Unstitcher.CODEC); - public static final SpriteSourceType PALETTED_PERMUTATIONS = register("paletted_permutations", PalettedPermutations.CODEC); - public static Codec TYPE_CODEC = ResourceLocation.CODEC.flatXmap(resourceLocation -> { - SpriteSourceType spriteSourceType = (SpriteSourceType)TYPES.get(resourceLocation); - return spriteSourceType != null ? DataResult.success(spriteSourceType) : DataResult.error(() -> "Unknown type " + resourceLocation); - }, spriteSourceType -> { - ResourceLocation resourceLocation = (ResourceLocation)TYPES.inverse().get(spriteSourceType); - return spriteSourceType != null ? DataResult.success(resourceLocation) : DataResult.error(() -> "Unknown type " + resourceLocation); - }); - public static Codec CODEC = TYPE_CODEC.dispatch(SpriteSource::type, SpriteSourceType::codec); - public static Codec> FILE_CODEC = CODEC.listOf().fieldOf("sources").codec(); + private static final ExtraCodecs.LateBoundIdMapper> ID_MAPPER = new ExtraCodecs.LateBoundIdMapper<>(); + public static final Codec CODEC = ID_MAPPER.codec(ResourceLocation.CODEC).dispatch(SpriteSource::codec, mapCodec -> mapCodec); + public static final Codec> FILE_CODEC = CODEC.listOf().fieldOf("sources").codec(); - private static SpriteSourceType register(String name, MapCodec codec) { - SpriteSourceType spriteSourceType = new SpriteSourceType(codec); - ResourceLocation resourceLocation = ResourceLocation.withDefaultNamespace(name); - SpriteSourceType spriteSourceType2 = (SpriteSourceType)TYPES.putIfAbsent(resourceLocation, spriteSourceType); - if (spriteSourceType2 != null) { - throw new IllegalStateException("Duplicate registration " + resourceLocation); - } else { - return spriteSourceType; - } + public static void bootstrap() { + ID_MAPPER.put(ResourceLocation.withDefaultNamespace("single"), SingleFile.MAP_CODEC); + ID_MAPPER.put(ResourceLocation.withDefaultNamespace("directory"), DirectoryLister.MAP_CODEC); + ID_MAPPER.put(ResourceLocation.withDefaultNamespace("filter"), SourceFilter.MAP_CODEC); + ID_MAPPER.put(ResourceLocation.withDefaultNamespace("unstitch"), Unstitcher.MAP_CODEC); + ID_MAPPER.put(ResourceLocation.withDefaultNamespace("paletted_permutations"), PalettedPermutations.MAP_CODEC); } } diff --git a/net/minecraft/client/renderer/texture/atlas/sources/DirectoryLister.java b/net/minecraft/client/renderer/texture/atlas/sources/DirectoryLister.java index d5b3ef6d..8ba74f06 100644 --- a/net/minecraft/client/renderer/texture/atlas/sources/DirectoryLister.java +++ b/net/minecraft/client/renderer/texture/atlas/sources/DirectoryLister.java @@ -6,28 +6,18 @@ import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.texture.atlas.SpriteSource; -import net.minecraft.client.renderer.texture.atlas.SpriteSourceType; -import net.minecraft.client.renderer.texture.atlas.SpriteSources; import net.minecraft.resources.FileToIdConverter; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.ResourceManager; @Environment(EnvType.CLIENT) -public class DirectoryLister implements SpriteSource { - public static final MapCodec CODEC = RecordCodecBuilder.mapCodec( +public record DirectoryLister(String sourcePath, String idPrefix) implements SpriteSource { + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( - Codec.STRING.fieldOf("source").forGetter(directoryLister -> directoryLister.sourcePath), - Codec.STRING.fieldOf("prefix").forGetter(directoryLister -> directoryLister.idPrefix) + Codec.STRING.fieldOf("source").forGetter(DirectoryLister::sourcePath), Codec.STRING.fieldOf("prefix").forGetter(DirectoryLister::idPrefix) ) .apply(instance, DirectoryLister::new) ); - private final String sourcePath; - private final String idPrefix; - - public DirectoryLister(String sourcePath, String idPrefix) { - this.sourcePath = sourcePath; - this.idPrefix = idPrefix; - } @Override public void run(ResourceManager resourceManager, SpriteSource.Output output) { @@ -39,7 +29,7 @@ public class DirectoryLister implements SpriteSource { } @Override - public SpriteSourceType type() { - return SpriteSources.DIRECTORY; + public MapCodec codec() { + return MAP_CODEC; } } diff --git a/net/minecraft/client/renderer/texture/atlas/sources/PalettedPermutations.java b/net/minecraft/client/renderer/texture/atlas/sources/PalettedPermutations.java index 0c087050..7b58e792 100644 --- a/net/minecraft/client/renderer/texture/atlas/sources/PalettedPermutations.java +++ b/net/minecraft/client/renderer/texture/atlas/sources/PalettedPermutations.java @@ -22,10 +22,6 @@ import net.fabricmc.api.Environment; import net.minecraft.client.renderer.texture.SpriteContents; import net.minecraft.client.renderer.texture.atlas.SpriteResourceLoader; import net.minecraft.client.renderer.texture.atlas.SpriteSource; -import net.minecraft.client.renderer.texture.atlas.SpriteSourceType; -import net.minecraft.client.renderer.texture.atlas.SpriteSources; -import net.minecraft.client.renderer.texture.atlas.SpriteSource.Output; -import net.minecraft.client.renderer.texture.atlas.SpriteSource.SpriteSupplier; import net.minecraft.client.resources.metadata.animation.FrameSize; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.Resource; @@ -36,28 +32,26 @@ import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @Environment(EnvType.CLIENT) -public class PalettedPermutations implements SpriteSource { +public record PalettedPermutations(List textures, ResourceLocation paletteKey, Map permutations, String separator) + implements SpriteSource { static final Logger LOGGER = LogUtils.getLogger(); - public static final MapCodec CODEC = RecordCodecBuilder.mapCodec( + public static final String DEFAULT_SEPARATOR = "_"; + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( - Codec.list(ResourceLocation.CODEC).fieldOf("textures").forGetter(palettedPermutations -> palettedPermutations.textures), - ResourceLocation.CODEC.fieldOf("palette_key").forGetter(palettedPermutations -> palettedPermutations.paletteKey), - Codec.unboundedMap(Codec.STRING, ResourceLocation.CODEC).fieldOf("permutations").forGetter(palettedPermutations -> palettedPermutations.permutations) + Codec.list(ResourceLocation.CODEC).fieldOf("textures").forGetter(PalettedPermutations::textures), + ResourceLocation.CODEC.fieldOf("palette_key").forGetter(PalettedPermutations::paletteKey), + Codec.unboundedMap(Codec.STRING, ResourceLocation.CODEC).fieldOf("permutations").forGetter(PalettedPermutations::permutations), + Codec.STRING.optionalFieldOf("separator", "_").forGetter(PalettedPermutations::separator) ) .apply(instance, PalettedPermutations::new) ); - private final List textures; - private final Map permutations; - private final ResourceLocation paletteKey; - private PalettedPermutations(List textures, ResourceLocation paletteKey, Map permutations) { - this.textures = textures; - this.permutations = permutations; - this.paletteKey = paletteKey; + public PalettedPermutations(List textures, ResourceLocation paletteKey, Map permutations) { + this(textures, paletteKey, permutations, "_"); } @Override - public void run(ResourceManager resourceManager, Output output) { + public void run(ResourceManager resourceManager, SpriteSource.Output output) { Supplier supplier = Suppliers.memoize(() -> loadPaletteEntryFromImage(resourceManager, this.paletteKey)); Map> map = new HashMap(); this.permutations @@ -76,7 +70,7 @@ public class PalettedPermutations implements SpriteSource { LazyLoadedImage lazyLoadedImage = new LazyLoadedImage(resourceLocation2, (Resource)optional.get(), map.size()); for (Entry> entry : map.entrySet()) { - ResourceLocation resourceLocation3 = resourceLocation.withSuffix("_" + (String)entry.getKey()); + ResourceLocation resourceLocation3 = resourceLocation.withSuffix(this.separator + (String)entry.getKey()); output.add( resourceLocation3, new PalettedPermutations.PalettedSpriteSupplier(lazyLoadedImage, (Supplier)entry.getValue(), resourceLocation3) ); @@ -150,12 +144,13 @@ public class PalettedPermutations implements SpriteSource { } @Override - public SpriteSourceType type() { - return SpriteSources.PALETTED_PERMUTATIONS; + public MapCodec codec() { + return MAP_CODEC; } @Environment(EnvType.CLIENT) - record PalettedSpriteSupplier(LazyLoadedImage baseImage, Supplier palette, ResourceLocation permutationLocation) implements SpriteSupplier { + record PalettedSpriteSupplier(LazyLoadedImage baseImage, Supplier palette, ResourceLocation permutationLocation) + implements SpriteSource.SpriteSupplier { @Nullable public SpriteContents apply(SpriteResourceLoader spriteResourceLoader) { Object var3; diff --git a/net/minecraft/client/renderer/texture/atlas/sources/SingleFile.java b/net/minecraft/client/renderer/texture/atlas/sources/SingleFile.java index f8f0bcf7..2d06e0ac 100644 --- a/net/minecraft/client/renderer/texture/atlas/sources/SingleFile.java +++ b/net/minecraft/client/renderer/texture/atlas/sources/SingleFile.java @@ -7,29 +7,24 @@ import java.util.Optional; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.texture.atlas.SpriteSource; -import net.minecraft.client.renderer.texture.atlas.SpriteSourceType; -import net.minecraft.client.renderer.texture.atlas.SpriteSources; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.Resource; import net.minecraft.server.packs.resources.ResourceManager; import org.slf4j.Logger; @Environment(EnvType.CLIENT) -public class SingleFile implements SpriteSource { +public record SingleFile(ResourceLocation resourceId, Optional spriteId) implements SpriteSource { private static final Logger LOGGER = LogUtils.getLogger(); - public static final MapCodec CODEC = RecordCodecBuilder.mapCodec( + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( - ResourceLocation.CODEC.fieldOf("resource").forGetter(singleFile -> singleFile.resourceId), - ResourceLocation.CODEC.optionalFieldOf("sprite").forGetter(singleFile -> singleFile.spriteId) + ResourceLocation.CODEC.fieldOf("resource").forGetter(SingleFile::resourceId), + ResourceLocation.CODEC.optionalFieldOf("sprite").forGetter(SingleFile::spriteId) ) .apply(instance, SingleFile::new) ); - private final ResourceLocation resourceId; - private final Optional spriteId; - public SingleFile(ResourceLocation resourceId, Optional spriteId) { - this.resourceId = resourceId; - this.spriteId = spriteId; + public SingleFile(ResourceLocation resourceId) { + this(resourceId, Optional.empty()); } @Override @@ -44,7 +39,7 @@ public class SingleFile implements SpriteSource { } @Override - public SpriteSourceType type() { - return SpriteSources.SINGLE_FILE; + public MapCodec codec() { + return MAP_CODEC; } } diff --git a/net/minecraft/client/renderer/texture/atlas/sources/SourceFilter.java b/net/minecraft/client/renderer/texture/atlas/sources/SourceFilter.java index b969c592..07feb1a7 100644 --- a/net/minecraft/client/renderer/texture/atlas/sources/SourceFilter.java +++ b/net/minecraft/client/renderer/texture/atlas/sources/SourceFilter.java @@ -5,22 +5,14 @@ import com.mojang.serialization.codecs.RecordCodecBuilder; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.texture.atlas.SpriteSource; -import net.minecraft.client.renderer.texture.atlas.SpriteSourceType; -import net.minecraft.client.renderer.texture.atlas.SpriteSources; import net.minecraft.server.packs.resources.ResourceManager; import net.minecraft.util.ResourceLocationPattern; @Environment(EnvType.CLIENT) -public class SourceFilter implements SpriteSource { - public static final MapCodec CODEC = RecordCodecBuilder.mapCodec( - instance -> instance.group(ResourceLocationPattern.CODEC.fieldOf("pattern").forGetter(sourceFilter -> sourceFilter.filter)) - .apply(instance, SourceFilter::new) +public record SourceFilter(ResourceLocationPattern filter) implements SpriteSource { + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( + instance -> instance.group(ResourceLocationPattern.CODEC.fieldOf("pattern").forGetter(SourceFilter::filter)).apply(instance, SourceFilter::new) ); - private final ResourceLocationPattern filter; - - public SourceFilter(ResourceLocationPattern filter) { - this.filter = filter; - } @Override public void run(ResourceManager resourceManager, SpriteSource.Output output) { @@ -28,7 +20,7 @@ public class SourceFilter implements SpriteSource { } @Override - public SpriteSourceType type() { - return SpriteSources.FILTER; + public MapCodec codec() { + return MAP_CODEC; } } diff --git a/net/minecraft/client/renderer/texture/atlas/sources/Unstitcher.java b/net/minecraft/client/renderer/texture/atlas/sources/Unstitcher.java index bb237622..d87d293a 100644 --- a/net/minecraft/client/renderer/texture/atlas/sources/Unstitcher.java +++ b/net/minecraft/client/renderer/texture/atlas/sources/Unstitcher.java @@ -13,8 +13,6 @@ import net.minecraft.client.renderer.texture.MissingTextureAtlasSprite; import net.minecraft.client.renderer.texture.SpriteContents; import net.minecraft.client.renderer.texture.atlas.SpriteResourceLoader; import net.minecraft.client.renderer.texture.atlas.SpriteSource; -import net.minecraft.client.renderer.texture.atlas.SpriteSourceType; -import net.minecraft.client.renderer.texture.atlas.SpriteSources; import net.minecraft.client.resources.metadata.animation.FrameSize; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.Resource; @@ -25,28 +23,17 @@ import net.minecraft.util.Mth; import org.slf4j.Logger; @Environment(EnvType.CLIENT) -public class Unstitcher implements SpriteSource { +public record Unstitcher(ResourceLocation resource, List regions, double xDivisor, double yDivisor) implements SpriteSource { static final Logger LOGGER = LogUtils.getLogger(); - public static final MapCodec CODEC = RecordCodecBuilder.mapCodec( + public static final MapCodec MAP_CODEC = RecordCodecBuilder.mapCodec( instance -> instance.group( - ResourceLocation.CODEC.fieldOf("resource").forGetter(unstitcher -> unstitcher.resource), - ExtraCodecs.nonEmptyList(Unstitcher.Region.CODEC.listOf()).fieldOf("regions").forGetter(unstitcher -> unstitcher.regions), - Codec.DOUBLE.optionalFieldOf("divisor_x", 1.0).forGetter(unstitcher -> unstitcher.xDivisor), - Codec.DOUBLE.optionalFieldOf("divisor_y", 1.0).forGetter(unstitcher -> unstitcher.yDivisor) + ResourceLocation.CODEC.fieldOf("resource").forGetter(Unstitcher::resource), + ExtraCodecs.nonEmptyList(Unstitcher.Region.CODEC.listOf()).fieldOf("regions").forGetter(Unstitcher::regions), + Codec.DOUBLE.optionalFieldOf("divisor_x", 1.0).forGetter(Unstitcher::xDivisor), + Codec.DOUBLE.optionalFieldOf("divisor_y", 1.0).forGetter(Unstitcher::yDivisor) ) .apply(instance, Unstitcher::new) ); - private final ResourceLocation resource; - private final List regions; - private final double xDivisor; - private final double yDivisor; - - public Unstitcher(ResourceLocation resource, List regions, double xDivisor, double yDivisor) { - this.resource = resource; - this.regions = regions; - this.xDivisor = xDivisor; - this.yDivisor = yDivisor; - } @Override public void run(ResourceManager resourceManager, SpriteSource.Output output) { @@ -64,12 +51,12 @@ public class Unstitcher implements SpriteSource { } @Override - public SpriteSourceType type() { - return SpriteSources.UNSTITCHER; + public MapCodec codec() { + return MAP_CODEC; } @Environment(EnvType.CLIENT) - record Region(ResourceLocation sprite, double x, double y, double width, double height) { + public record Region(ResourceLocation sprite, double x, double y, double width, double height) { public static final Codec CODEC = RecordCodecBuilder.create( instance -> instance.group( ResourceLocation.CODEC.fieldOf("sprite").forGetter(Unstitcher.Region::sprite), diff --git a/net/minecraft/client/resources/ClientPackSource.java b/net/minecraft/client/resources/ClientPackSource.java index 3cbd7e1d..e3978d0d 100644 --- a/net/minecraft/client/resources/ClientPackSource.java +++ b/net/minecraft/client/resources/ClientPackSource.java @@ -25,6 +25,8 @@ import net.minecraft.server.packs.repository.BuiltInPackSource; import net.minecraft.server.packs.repository.KnownPack; import net.minecraft.server.packs.repository.Pack; import net.minecraft.server.packs.repository.PackSource; +import net.minecraft.server.packs.repository.Pack.Position; +import net.minecraft.server.packs.repository.Pack.ResourcesSupplier; import net.minecraft.world.level.validation.DirectoryValidator; import org.jetbrains.annotations.Nullable; @@ -41,8 +43,8 @@ public class ClientPackSource extends BuiltInPackSource { private static final PackLocationInfo VANILLA_PACK_INFO = new PackLocationInfo( "vanilla", Component.translatable("resourcePack.vanilla.name"), PackSource.BUILT_IN, Optional.of(CORE_PACK_INFO) ); - private static final PackSelectionConfig VANILLA_SELECTION_CONFIG = new PackSelectionConfig(true, Pack.Position.BOTTOM, false); - private static final PackSelectionConfig BUILT_IN_SELECTION_CONFIG = new PackSelectionConfig(false, Pack.Position.TOP, false); + private static final PackSelectionConfig VANILLA_SELECTION_CONFIG = new PackSelectionConfig(true, Position.BOTTOM, false); + private static final PackSelectionConfig BUILT_IN_SELECTION_CONFIG = new PackSelectionConfig(false, Position.TOP, false); private static final ResourceLocation PACKS_DIR = ResourceLocation.withDefaultNamespace("resourcepacks"); @Nullable private final Path externalAssetDir; @@ -89,7 +91,7 @@ public class ClientPackSource extends BuiltInPackSource { @Nullable @Override - protected Pack createBuiltinPack(String id, Pack.ResourcesSupplier resources, Component title) { + protected Pack createBuiltinPack(String id, ResourcesSupplier resources, Component title) { return Pack.readMetaAndCreate(createBuiltInPackLocation(id, title), resources, PackType.CLIENT_RESOURCES, BUILT_IN_SELECTION_CONFIG); } diff --git a/net/minecraft/client/resources/DryFoliageColorReloadListener.java b/net/minecraft/client/resources/DryFoliageColorReloadListener.java new file mode 100644 index 00000000..c945a67b --- /dev/null +++ b/net/minecraft/client/resources/DryFoliageColorReloadListener.java @@ -0,0 +1,27 @@ +package net.minecraft.client.resources; + +import java.io.IOException; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.server.packs.resources.ResourceManager; +import net.minecraft.server.packs.resources.SimplePreparableReloadListener; +import net.minecraft.util.profiling.ProfilerFiller; +import net.minecraft.world.level.DryFoliageColor; + +@Environment(EnvType.CLIENT) +public class DryFoliageColorReloadListener extends SimplePreparableReloadListener { + private static final ResourceLocation LOCATION = ResourceLocation.withDefaultNamespace("textures/colormap/dry_foliage.png"); + + protected int[] prepare(ResourceManager resourceManager, ProfilerFiller profiler) { + try { + return LegacyStuffWrapper.getPixels(resourceManager, LOCATION); + } catch (IOException var4) { + throw new IllegalStateException("Failed to load dry foliage color texture", var4); + } + } + + protected void apply(int[] is, ResourceManager resourceManager, ProfilerFiller profilerFiller) { + DryFoliageColor.init(is); + } +} diff --git a/net/minecraft/client/resources/MapDecorationTextureManager.java b/net/minecraft/client/resources/MapDecorationTextureManager.java index 053f97c6..107bc2ea 100644 --- a/net/minecraft/client/resources/MapDecorationTextureManager.java +++ b/net/minecraft/client/resources/MapDecorationTextureManager.java @@ -4,13 +4,14 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.renderer.texture.TextureManager; +import net.minecraft.client.resources.model.AtlasIds; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.level.saveddata.maps.MapDecoration; @Environment(EnvType.CLIENT) public class MapDecorationTextureManager extends TextureAtlasHolder { public MapDecorationTextureManager(TextureManager textureManager) { - super(textureManager, ResourceLocation.withDefaultNamespace("textures/atlas/map_decorations.png"), ResourceLocation.withDefaultNamespace("map_decorations")); + super(textureManager, ResourceLocation.withDefaultNamespace("textures/atlas/map_decorations.png"), AtlasIds.MAP_DECORATIONS); } public TextureAtlasSprite get(MapDecoration mapDecoration) { diff --git a/net/minecraft/client/resources/MapTextureManager.java b/net/minecraft/client/resources/MapTextureManager.java index d30a73db..087a52ce 100644 --- a/net/minecraft/client/resources/MapTextureManager.java +++ b/net/minecraft/client/resources/MapTextureManager.java @@ -63,7 +63,7 @@ public class MapTextureManager implements AutoCloseable { MapInstance(final int id, final MapItemSavedData data) { this.data = data; - this.texture = new DynamicTexture(128, 128, true); + this.texture = new DynamicTexture(() -> "Map " + id, 128, 128, true); this.location = ResourceLocation.withDefaultNamespace("map/" + id); MapTextureManager.this.textureManager.register(this.location, this.texture); } diff --git a/net/minecraft/client/resources/MobEffectTextureManager.java b/net/minecraft/client/resources/MobEffectTextureManager.java index e2f91d35..909d126c 100644 --- a/net/minecraft/client/resources/MobEffectTextureManager.java +++ b/net/minecraft/client/resources/MobEffectTextureManager.java @@ -5,6 +5,7 @@ import net.fabricmc.api.Environment; import net.minecraft.client.renderer.texture.MissingTextureAtlasSprite; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.renderer.texture.TextureManager; +import net.minecraft.client.resources.model.AtlasIds; import net.minecraft.core.Holder; import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; @@ -13,7 +14,7 @@ import net.minecraft.world.effect.MobEffect; @Environment(EnvType.CLIENT) public class MobEffectTextureManager extends TextureAtlasHolder { public MobEffectTextureManager(TextureManager textureManager) { - super(textureManager, ResourceLocation.withDefaultNamespace("textures/atlas/mob_effects.png"), ResourceLocation.withDefaultNamespace("mob_effects")); + super(textureManager, ResourceLocation.withDefaultNamespace("textures/atlas/mob_effects.png"), AtlasIds.MOB_EFFECTS); } public TextureAtlasSprite get(Holder effect) { diff --git a/net/minecraft/client/resources/PaintingTextureManager.java b/net/minecraft/client/resources/PaintingTextureManager.java index e00d2c6d..93eb9e8e 100644 --- a/net/minecraft/client/resources/PaintingTextureManager.java +++ b/net/minecraft/client/resources/PaintingTextureManager.java @@ -4,6 +4,7 @@ import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.renderer.texture.TextureManager; +import net.minecraft.client.resources.model.AtlasIds; import net.minecraft.resources.ResourceLocation; import net.minecraft.world.entity.decoration.PaintingVariant; @@ -12,7 +13,7 @@ public class PaintingTextureManager extends TextureAtlasHolder { private static final ResourceLocation BACK_SPRITE_LOCATION = ResourceLocation.withDefaultNamespace("back"); public PaintingTextureManager(TextureManager textureManager) { - super(textureManager, ResourceLocation.withDefaultNamespace("textures/atlas/paintings.png"), ResourceLocation.withDefaultNamespace("paintings")); + super(textureManager, ResourceLocation.withDefaultNamespace("textures/atlas/paintings.png"), AtlasIds.PAINTINGS); } public TextureAtlasSprite get(PaintingVariant paintingVariant) { diff --git a/net/minecraft/client/resources/TextureAtlasHolder.java b/net/minecraft/client/resources/TextureAtlasHolder.java index 40228ec2..69007963 100644 --- a/net/minecraft/client/resources/TextureAtlasHolder.java +++ b/net/minecraft/client/resources/TextureAtlasHolder.java @@ -13,7 +13,6 @@ import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.metadata.MetadataSectionType; import net.minecraft.server.packs.resources.PreparableReloadListener; import net.minecraft.server.packs.resources.ResourceManager; -import net.minecraft.server.packs.resources.PreparableReloadListener.PreparationBarrier; import net.minecraft.util.profiling.Profiler; import net.minecraft.util.profiling.Zone; @@ -44,17 +43,19 @@ public abstract class TextureAtlasHolder implements PreparableReloadListener, Au } @Override - public final CompletableFuture reload(PreparationBarrier barrier, ResourceManager manager, Executor backgroundExecutor, Executor gameExecutor) { + public final CompletableFuture reload( + PreparableReloadListener.PreparationBarrier preparationBarrier, ResourceManager resourceManager, Executor executor, Executor executor2 + ) { return SpriteLoader.create(this.textureAtlas) - .loadAndStitch(manager, this.atlasInfoLocation, 0, backgroundExecutor, this.metadataSections) + .loadAndStitch(resourceManager, this.atlasInfoLocation, 0, executor, this.metadataSections) .thenCompose(SpriteLoader.Preparations::waitForUpload) - .thenCompose(barrier::wait) - .thenAcceptAsync(this::apply, gameExecutor); + .thenCompose(preparationBarrier::wait) + .thenAcceptAsync(this::apply, executor2); } - private void apply(SpriteLoader.Preparations preparations) { + private void apply(SpriteLoader.Preparations preperations) { try (Zone zone = Profiler.get().zone("upload")) { - this.textureAtlas.upload(preparations); + this.textureAtlas.upload(preperations); } } diff --git a/net/minecraft/client/resources/model/AtlasIds.java b/net/minecraft/client/resources/model/AtlasIds.java new file mode 100644 index 00000000..5bac6690 --- /dev/null +++ b/net/minecraft/client/resources/model/AtlasIds.java @@ -0,0 +1,23 @@ +package net.minecraft.client.resources.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.resources.ResourceLocation; + +@Environment(EnvType.CLIENT) +public class AtlasIds { + public static final ResourceLocation ARMOR_TRIMS = ResourceLocation.withDefaultNamespace("armor_trims"); + public static final ResourceLocation BANNER_PATTERNS = ResourceLocation.withDefaultNamespace("banner_patterns"); + public static final ResourceLocation BEDS = ResourceLocation.withDefaultNamespace("beds"); + public static final ResourceLocation BLOCKS = ResourceLocation.withDefaultNamespace("blocks"); + public static final ResourceLocation CHESTS = ResourceLocation.withDefaultNamespace("chests"); + public static final ResourceLocation DECORATED_POT = ResourceLocation.withDefaultNamespace("decorated_pot"); + public static final ResourceLocation GUI = ResourceLocation.withDefaultNamespace("gui"); + public static final ResourceLocation MAP_DECORATIONS = ResourceLocation.withDefaultNamespace("map_decorations"); + public static final ResourceLocation MOB_EFFECTS = ResourceLocation.withDefaultNamespace("mob_effects"); + public static final ResourceLocation PAINTINGS = ResourceLocation.withDefaultNamespace("paintings"); + public static final ResourceLocation PARTICLES = ResourceLocation.withDefaultNamespace("particles"); + public static final ResourceLocation SHIELD_PATTERNS = ResourceLocation.withDefaultNamespace("shield_patterns"); + public static final ResourceLocation SHULKER_BOXES = ResourceLocation.withDefaultNamespace("shulker_boxes"); + public static final ResourceLocation SIGNS = ResourceLocation.withDefaultNamespace("signs"); +} diff --git a/net/minecraft/client/resources/model/AtlasSet.java b/net/minecraft/client/resources/model/AtlasSet.java index 3f981510..8199261c 100644 --- a/net/minecraft/client/resources/model/AtlasSet.java +++ b/net/minecraft/client/resources/model/AtlasSet.java @@ -7,6 +7,7 @@ import java.util.concurrent.Executor; import java.util.stream.Collectors; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.Util; import net.minecraft.client.renderer.texture.SpriteLoader; import net.minecraft.client.renderer.texture.TextureAtlas; import net.minecraft.client.renderer.texture.TextureAtlasSprite; @@ -37,20 +38,12 @@ public class AtlasSet implements AutoCloseable { } public Map> scheduleLoad(ResourceManager resourceManager, int mipLevel, Executor executor) { - return (Map>)this.atlases - .entrySet() - .stream() - .collect( - Collectors.toMap( - Entry::getKey, - entry -> { - AtlasSet.AtlasEntry atlasEntry = (AtlasSet.AtlasEntry)entry.getValue(); - return SpriteLoader.create(atlasEntry.atlas) - .loadAndStitch(resourceManager, atlasEntry.atlasInfoLocation, mipLevel, executor) - .thenApply(preparations -> new AtlasSet.StitchResult(atlasEntry.atlas, preparations)); - } - ) - ); + return Util.mapValues( + this.atlases, + atlasEntry -> SpriteLoader.create(atlasEntry.atlas) + .loadAndStitch(resourceManager, atlasEntry.atlasInfoLocation, mipLevel, executor) + .thenApply(preparations -> new AtlasSet.StitchResult(atlasEntry.atlas, preparations)) + ); } @Environment(EnvType.CLIENT) diff --git a/net/minecraft/client/resources/model/BakedModel.java b/net/minecraft/client/resources/model/BakedModel.java deleted file mode 100644 index 162a6f48..00000000 --- a/net/minecraft/client/resources/model/BakedModel.java +++ /dev/null @@ -1,27 +0,0 @@ -package net.minecraft.client.resources.model; - -import java.util.List; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.BakedQuad; -import net.minecraft.client.renderer.block.model.ItemTransforms; -import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.core.Direction; -import net.minecraft.util.RandomSource; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; - -@Environment(EnvType.CLIENT) -public interface BakedModel { - List getQuads(@Nullable BlockState state, @Nullable Direction direction, RandomSource random); - - boolean useAmbientOcclusion(); - - boolean isGui3d(); - - boolean usesBlockLight(); - - TextureAtlasSprite getParticleIcon(); - - ItemTransforms getTransforms(); -} diff --git a/net/minecraft/client/resources/model/BlockModelRotation.java b/net/minecraft/client/resources/model/BlockModelRotation.java index 3ec1522a..540c748e 100644 --- a/net/minecraft/client/resources/model/BlockModelRotation.java +++ b/net/minecraft/client/resources/model/BlockModelRotation.java @@ -1,72 +1,101 @@ package net.minecraft.client.resources.model; import com.mojang.math.OctahedralGroup; +import com.mojang.math.Quadrant; import com.mojang.math.Transformation; -import java.util.Arrays; +import java.util.EnumMap; import java.util.Map; -import java.util.stream.Collectors; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.util.Mth; -import org.joml.Quaternionf; +import net.minecraft.Util; +import net.minecraft.core.BlockMath; +import net.minecraft.core.Direction; +import org.joml.Matrix4f; +import org.joml.Matrix4fc; @Environment(EnvType.CLIENT) public enum BlockModelRotation implements ModelState { - X0_Y0(0, 0), - X0_Y90(0, 90), - X0_Y180(0, 180), - X0_Y270(0, 270), - X90_Y0(90, 0), - X90_Y90(90, 90), - X90_Y180(90, 180), - X90_Y270(90, 270), - X180_Y0(180, 0), - X180_Y90(180, 90), - X180_Y180(180, 180), - X180_Y270(180, 270), - X270_Y0(270, 0), - X270_Y90(270, 90), - X270_Y180(270, 180), - X270_Y270(270, 270); + X0_Y0(Quadrant.R0, Quadrant.R0), + X0_Y90(Quadrant.R0, Quadrant.R90), + X0_Y180(Quadrant.R0, Quadrant.R180), + X0_Y270(Quadrant.R0, Quadrant.R270), + X90_Y0(Quadrant.R90, Quadrant.R0), + X90_Y90(Quadrant.R90, Quadrant.R90), + X90_Y180(Quadrant.R90, Quadrant.R180), + X90_Y270(Quadrant.R90, Quadrant.R270), + X180_Y0(Quadrant.R180, Quadrant.R0), + X180_Y90(Quadrant.R180, Quadrant.R90), + X180_Y180(Quadrant.R180, Quadrant.R180), + X180_Y270(Quadrant.R180, Quadrant.R270), + X270_Y0(Quadrant.R270, Quadrant.R0), + X270_Y90(Quadrant.R270, Quadrant.R90), + X270_Y180(Quadrant.R270, Quadrant.R180), + X270_Y270(Quadrant.R270, Quadrant.R270); - private static final int DEGREES = 360; - private static final Map BY_INDEX = (Map)Arrays.stream(values()) - .collect(Collectors.toMap(blockModelRotation -> blockModelRotation.index, blockModelRotation -> blockModelRotation)); - private final Transformation transformation; + private static final BlockModelRotation[][] XY_TABLE = Util.make( + new BlockModelRotation[Quadrant.values().length][Quadrant.values().length], blockModelRotations -> { + for (BlockModelRotation blockModelRotation : values()) { + blockModelRotations[blockModelRotation.xRotation.ordinal()][blockModelRotation.yRotation.ordinal()] = blockModelRotation; + } + } + ); + private final Quadrant xRotation; + private final Quadrant yRotation; + final Transformation transformation; private final OctahedralGroup actualRotation; - private final int index; + final Map faceMapping = new EnumMap(Direction.class); + final Map inverseFaceMapping = new EnumMap(Direction.class); + private final BlockModelRotation.WithUvLock withUvLock = new BlockModelRotation.WithUvLock(this); - private static int getIndex(int x, int y) { - return x * 360 + y; - } - - private BlockModelRotation(final int x, final int y) { - this.index = getIndex(x, y); - Quaternionf quaternionf = new Quaternionf().rotateYXZ(-y * (float) (Math.PI / 180.0), -x * (float) (Math.PI / 180.0), 0.0F); - OctahedralGroup octahedralGroup = OctahedralGroup.IDENTITY; - - for (int j = 0; j < y; j += 90) { - octahedralGroup = octahedralGroup.compose(OctahedralGroup.ROT_90_Y_NEG); + private BlockModelRotation(final Quadrant xRotation, final Quadrant yRotation) { + this.xRotation = xRotation; + this.yRotation = yRotation; + this.actualRotation = OctahedralGroup.fromXYAngles(xRotation, yRotation); + if (this.actualRotation != OctahedralGroup.IDENTITY) { + this.transformation = new Transformation(new Matrix4f(this.actualRotation.transformation())); + } else { + this.transformation = Transformation.identity(); } - for (int j = 0; j < x; j += 90) { - octahedralGroup = octahedralGroup.compose(OctahedralGroup.ROT_90_X_NEG); + for (Direction direction : Direction.values()) { + Matrix4fc matrix4fc = BlockMath.getFaceTransformation(this.transformation, direction).getMatrix(); + this.faceMapping.put(direction, matrix4fc); + this.inverseFaceMapping.put(direction, matrix4fc.invertAffine(new Matrix4f())); } - - this.transformation = new Transformation(null, quaternionf, null, null); - this.actualRotation = octahedralGroup; } @Override - public Transformation getRotation() { + public Transformation transformation() { return this.transformation; } - public static BlockModelRotation by(int x, int y) { - return (BlockModelRotation)BY_INDEX.get(getIndex(Mth.positiveModulo(x, 360), Mth.positiveModulo(y, 360))); + public static BlockModelRotation by(Quadrant xRot, Quadrant yRot) { + return XY_TABLE[xRot.ordinal()][yRot.ordinal()]; } public OctahedralGroup actualRotation() { return this.actualRotation; } + + public ModelState withUvLock() { + return this.withUvLock; + } + + @Environment(EnvType.CLIENT) + record WithUvLock(BlockModelRotation parent) implements ModelState { + @Override + public Transformation transformation() { + return this.parent.transformation; + } + + @Override + public Matrix4fc faceTransformation(Direction facing) { + return (Matrix4fc)this.parent.faceMapping.getOrDefault(facing, NO_TRANSFORM); + } + + @Override + public Matrix4fc inverseFaceTransformation(Direction facing) { + return (Matrix4fc)this.parent.inverseFaceMapping.getOrDefault(facing, NO_TRANSFORM); + } + } } diff --git a/net/minecraft/client/resources/model/BlockStateDefinitions.java b/net/minecraft/client/resources/model/BlockStateDefinitions.java new file mode 100644 index 00000000..7e35fb39 --- /dev/null +++ b/net/minecraft/client/resources/model/BlockStateDefinitions.java @@ -0,0 +1,44 @@ +package net.minecraft.client.resources.model; + +import java.util.HashMap; +import java.util.Map; +import java.util.function.Function; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.core.registries.BuiltInRegistries; +import net.minecraft.resources.ResourceLocation; +import net.minecraft.world.level.block.Block; +import net.minecraft.world.level.block.Blocks; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.level.block.state.StateDefinition; +import net.minecraft.world.level.block.state.StateDefinition.Builder; +import net.minecraft.world.level.block.state.properties.BlockStateProperties; + +@Environment(EnvType.CLIENT) +public class BlockStateDefinitions { + private static final StateDefinition ITEM_FRAME_FAKE_DEFINITION = createItemFrameFakeState(); + private static final StateDefinition GLOW_ITEM_FRAME_FAKE_DEFINITION = createItemFrameFakeState(); + private static final ResourceLocation GLOW_ITEM_FRAME_LOCATION = ResourceLocation.withDefaultNamespace("glow_item_frame"); + private static final ResourceLocation ITEM_FRAME_LOCATION = ResourceLocation.withDefaultNamespace("item_frame"); + private static final Map> STATIC_DEFINITIONS = Map.of( + ITEM_FRAME_LOCATION, ITEM_FRAME_FAKE_DEFINITION, GLOW_ITEM_FRAME_LOCATION, GLOW_ITEM_FRAME_FAKE_DEFINITION + ); + + private static StateDefinition createItemFrameFakeState() { + return new Builder(Blocks.AIR).add(BlockStateProperties.MAP).create(Block::defaultBlockState, BlockState::new); + } + + public static BlockState getItemFrameFakeState(boolean isGlowing, boolean map) { + return (isGlowing ? GLOW_ITEM_FRAME_FAKE_DEFINITION : ITEM_FRAME_FAKE_DEFINITION).any().setValue(BlockStateProperties.MAP, map); + } + + static Function> definitionLocationToBlockStateMapper() { + Map> map = new HashMap(STATIC_DEFINITIONS); + + for (Block block : BuiltInRegistries.BLOCK) { + map.put(block.builtInRegistryHolder().key().location(), block.getStateDefinition()); + } + + return map::get; + } +} diff --git a/net/minecraft/client/resources/model/BlockStateModelLoader.java b/net/minecraft/client/resources/model/BlockStateModelLoader.java index 0a7b1051..2b10b1aa 100644 --- a/net/minecraft/client/resources/model/BlockStateModelLoader.java +++ b/net/minecraft/client/resources/model/BlockStateModelLoader.java @@ -1,70 +1,40 @@ package net.minecraft.client.resources.model; -import com.google.common.collect.Maps; -import com.google.gson.JsonObject; +import com.google.gson.JsonElement; +import com.google.gson.JsonParseException; +import com.google.gson.JsonParser; import com.mojang.logging.LogUtils; +import com.mojang.serialization.JsonOps; import java.io.Reader; import java.util.ArrayList; -import java.util.HashMap; +import java.util.IdentityHashMap; import java.util.List; import java.util.Map; import java.util.Map.Entry; import java.util.concurrent.CompletableFuture; import java.util.concurrent.Executor; import java.util.function.Function; -import java.util.stream.Stream; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.Util; -import net.minecraft.client.renderer.block.BlockModelShaper; import net.minecraft.client.renderer.block.model.BlockModelDefinition; -import net.minecraft.client.renderer.block.model.UnbakedBlockStateModel; -import net.minecraft.core.registries.BuiltInRegistries; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.resources.FileToIdConverter; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.Resource; import net.minecraft.server.packs.resources.ResourceManager; -import net.minecraft.util.GsonHelper; import net.minecraft.world.level.block.Block; -import net.minecraft.world.level.block.Blocks; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.block.state.StateDefinition; -import net.minecraft.world.level.block.state.StateDefinition.Builder; -import net.minecraft.world.level.block.state.properties.BooleanProperty; import org.slf4j.Logger; @Environment(EnvType.CLIENT) public class BlockStateModelLoader { private static final Logger LOGGER = LogUtils.getLogger(); private static final FileToIdConverter BLOCKSTATE_LISTER = FileToIdConverter.json("blockstates"); - private static final String FRAME_MAP_PROPERTY = "map"; - private static final String FRAME_MAP_PROPERTY_TRUE = "map=true"; - private static final String FRAME_MAP_PROPERTY_FALSE = "map=false"; - private static final StateDefinition ITEM_FRAME_FAKE_DEFINITION = new Builder(Blocks.AIR) - .add(BooleanProperty.create("map")) - .create(Block::defaultBlockState, BlockState::new); - private static final ResourceLocation GLOW_ITEM_FRAME_LOCATION = ResourceLocation.withDefaultNamespace("glow_item_frame"); - private static final ResourceLocation ITEM_FRAME_LOCATION = ResourceLocation.withDefaultNamespace("item_frame"); - private static final Map> STATIC_DEFINITIONS = Map.of( - ITEM_FRAME_LOCATION, ITEM_FRAME_FAKE_DEFINITION, GLOW_ITEM_FRAME_LOCATION, ITEM_FRAME_FAKE_DEFINITION - ); - public static final ModelResourceLocation GLOW_MAP_FRAME_LOCATION = new ModelResourceLocation(GLOW_ITEM_FRAME_LOCATION, "map=true"); - public static final ModelResourceLocation GLOW_FRAME_LOCATION = new ModelResourceLocation(GLOW_ITEM_FRAME_LOCATION, "map=false"); - public static final ModelResourceLocation MAP_FRAME_LOCATION = new ModelResourceLocation(ITEM_FRAME_LOCATION, "map=true"); - public static final ModelResourceLocation FRAME_LOCATION = new ModelResourceLocation(ITEM_FRAME_LOCATION, "map=false"); - private static Function> definitionLocationToBlockMapper() { - Map> map = new HashMap(STATIC_DEFINITIONS); - - for (Block block : BuiltInRegistries.BLOCK) { - map.put(block.builtInRegistryHolder().key().location(), block.getStateDefinition()); - } - - return map::get; - } - - public static CompletableFuture loadBlockStates(UnbakedModel model, ResourceManager resourceManager, Executor executor) { - Function> function = definitionLocationToBlockMapper(); + public static CompletableFuture loadBlockStates(ResourceManager resourceManager, Executor executor) { + Function> function = BlockStateDefinitions.definitionLocationToBlockStateMapper(); return CompletableFuture.supplyAsync(() -> BLOCKSTATE_LISTER.listMatchingResourceStacks(resourceManager), executor).thenCompose(map -> { List> list = new ArrayList(map.size()); @@ -84,33 +54,33 @@ public class BlockStateModelLoader { Reader reader = resource.openAsReader(); try { - JsonObject jsonObject = GsonHelper.parse(reader); - BlockModelDefinition blockModelDefinition = BlockModelDefinition.fromJsonElement(jsonObject); + JsonElement jsonElement = JsonParser.parseReader(reader); + BlockModelDefinition blockModelDefinition = BlockModelDefinition.CODEC.parse(JsonOps.INSTANCE, jsonElement).getOrThrow(JsonParseException::new); list2.add(new BlockStateModelLoader.LoadedBlockModelDefinition(resource.sourcePackId(), blockModelDefinition)); - } catch (Throwable var14) { + } catch (Throwable var13) { if (reader != null) { try { reader.close(); - } catch (Throwable var13) { - var14.addSuppressed(var13); + } catch (Throwable var12) { + var13.addSuppressed(var12); } } - throw var14; + throw var13; } if (reader != null) { reader.close(); } - } catch (Exception var15) { - LOGGER.error("Failed to load blockstate definition {} from pack {}", resourceLocation, resource.sourcePackId(), var15); + } catch (Exception var14) { + LOGGER.error("Failed to load blockstate definition {} from pack {}", resourceLocation, resource.sourcePackId(), var14); } } try { - return loadBlockStateDefinitionStack(resourceLocation, stateDefinition, list2, model); - } catch (Exception var12) { - LOGGER.error("Failed to load blockstate definition {}", resourceLocation, var12); + return loadBlockStateDefinitionStack(resourceLocation, stateDefinition, list2); + } catch (Exception var11) { + LOGGER.error("Failed to load blockstate definition {}", resourceLocation, var11); return null; } } @@ -118,7 +88,7 @@ public class BlockStateModelLoader { } return Util.sequence(list).thenApply(listx -> { - Map mapx = new HashMap(); + Map mapx = new IdentityHashMap(); for (BlockStateModelLoader.LoadedModels loadedModels : listx) { if (loadedModels != null) { @@ -132,20 +102,12 @@ public class BlockStateModelLoader { } private static BlockStateModelLoader.LoadedModels loadBlockStateDefinitionStack( - ResourceLocation id, - StateDefinition stateDefinition, - List modelDefinitions, - UnbakedModel model + ResourceLocation blockStateId, StateDefinition stateDefinition, List modelDefinitions ) { - Map map = new HashMap(); + Map map = new IdentityHashMap(); for (BlockStateModelLoader.LoadedBlockModelDefinition loadedBlockModelDefinition : modelDefinitions) { - loadedBlockModelDefinition.contents - .instantiate(stateDefinition, id + "/" + loadedBlockModelDefinition.source) - .forEach((blockState, unbakedBlockStateModel) -> { - ModelResourceLocation modelResourceLocation = BlockModelShaper.stateToModelLocation(id, blockState); - map.put(modelResourceLocation, new BlockStateModelLoader.LoadedModel(blockState, unbakedBlockStateModel)); - }); + map.putAll(loadedBlockModelDefinition.contents.instantiate(stateDefinition, () -> blockStateId + "/" + loadedBlockModelDefinition.source)); } return new BlockStateModelLoader.LoadedModels(map); @@ -156,17 +118,6 @@ public class BlockStateModelLoader { } @Environment(EnvType.CLIENT) - public record LoadedModel(BlockState state, UnbakedBlockStateModel model) { - } - - @Environment(EnvType.CLIENT) - public record LoadedModels(Map models) { - public Stream forResolving() { - return this.models.values().stream().map(BlockStateModelLoader.LoadedModel::model); - } - - public Map plainModels() { - return Maps.transformValues(this.models, BlockStateModelLoader.LoadedModel::model); - } + public record LoadedModels(Map models) { } } diff --git a/net/minecraft/client/resources/model/ClientItemInfoLoader.java b/net/minecraft/client/resources/model/ClientItemInfoLoader.java index 52ab3760..3fb20a1f 100644 --- a/net/minecraft/client/resources/model/ClientItemInfoLoader.java +++ b/net/minecraft/client/resources/model/ClientItemInfoLoader.java @@ -1,7 +1,9 @@ package net.minecraft.client.resources.model; +import com.google.gson.JsonElement; import com.google.gson.JsonParser; import com.mojang.logging.LogUtils; +import com.mojang.serialization.DynamicOps; import com.mojang.serialization.JsonOps; import java.io.Reader; import java.util.ArrayList; @@ -13,10 +15,13 @@ import java.util.concurrent.Executor; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.Util; +import net.minecraft.client.multiplayer.ClientRegistryLayer; import net.minecraft.client.renderer.item.ClientItem; +import net.minecraft.core.RegistryAccess.Frozen; import net.minecraft.resources.FileToIdConverter; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.ResourceManager; +import net.minecraft.util.PlaceholderLookupProvider; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -26,6 +31,7 @@ public class ClientItemInfoLoader { private static final FileToIdConverter LISTER = FileToIdConverter.json("items"); public static CompletableFuture scheduleLoad(ResourceManager resourceManager, Executor executor) { + Frozen frozen = ClientRegistryLayer.createRegistryAccess().compositeAccess(); return CompletableFuture.supplyAsync(() -> LISTER.listMatchingResources(resourceManager), executor) .thenCompose( map -> { @@ -39,33 +45,40 @@ public class ClientItemInfoLoader { try { Reader reader = resource.openAsReader(); - ClientItemInfoLoader.PendingLoad var5; + ClientItemInfoLoader.PendingLoad var8; try { + PlaceholderLookupProvider placeholderLookupProvider = new PlaceholderLookupProvider(frozen); + DynamicOps dynamicOps = placeholderLookupProvider.createSerializationContext(JsonOps.INSTANCE); ClientItem clientItem = (ClientItem)ClientItem.CODEC - .parse(JsonOps.INSTANCE, JsonParser.parseReader(reader)) + .parse(dynamicOps, JsonParser.parseReader(reader)) .ifError(error -> LOGGER.error("Couldn't parse item model '{}' from pack '{}': {}", resourceLocation2, resource.sourcePackId(), error.message())) .result() + .map( + clientItemx -> placeholderLookupProvider.hasRegisteredPlaceholders() + ? clientItemx.withRegistrySwapper(placeholderLookupProvider.createSwapper()) + : clientItemx + ) .orElse(null); - var5 = new ClientItemInfoLoader.PendingLoad(resourceLocation2, clientItem); - } catch (Throwable var7) { + var8 = new ClientItemInfoLoader.PendingLoad(resourceLocation2, clientItem); + } catch (Throwable var10) { if (reader != null) { try { reader.close(); - } catch (Throwable var6) { - var7.addSuppressed(var6); + } catch (Throwable var9) { + var10.addSuppressed(var9); } } - throw var7; + throw var10; } if (reader != null) { reader.close(); } - return var5; - } catch (Exception var8) { - LOGGER.error("Failed to open item model {} from pack '{}'", resourceLocation, resource.sourcePackId(), var8); + return var8; + } catch (Exception var11) { + LOGGER.error("Failed to open item model {} from pack '{}'", resourceLocation, resource.sourcePackId(), var11); return new ClientItemInfoLoader.PendingLoad(resourceLocation2, null); } }, diff --git a/net/minecraft/client/resources/model/DelegateBakedModel.java b/net/minecraft/client/resources/model/DelegateBakedModel.java deleted file mode 100644 index 21bee1fb..00000000 --- a/net/minecraft/client/resources/model/DelegateBakedModel.java +++ /dev/null @@ -1,51 +0,0 @@ -package net.minecraft.client.resources.model; - -import java.util.List; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.BakedQuad; -import net.minecraft.client.renderer.block.model.ItemTransforms; -import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.core.Direction; -import net.minecraft.util.RandomSource; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; - -@Environment(EnvType.CLIENT) -public abstract class DelegateBakedModel implements BakedModel { - protected final BakedModel parent; - - public DelegateBakedModel(BakedModel parent) { - this.parent = parent; - } - - @Override - public List getQuads(@Nullable BlockState state, @Nullable Direction direction, RandomSource random) { - return this.parent.getQuads(state, direction, random); - } - - @Override - public boolean useAmbientOcclusion() { - return this.parent.useAmbientOcclusion(); - } - - @Override - public boolean isGui3d() { - return this.parent.isGui3d(); - } - - @Override - public boolean usesBlockLight() { - return this.parent.usesBlockLight(); - } - - @Override - public TextureAtlasSprite getParticleIcon() { - return this.parent.getParticleIcon(); - } - - @Override - public ItemTransforms getTransforms() { - return this.parent.getTransforms(); - } -} diff --git a/net/minecraft/client/resources/model/EquipmentClientInfo.java b/net/minecraft/client/resources/model/EquipmentClientInfo.java index 011dbf7f..08699fc9 100644 --- a/net/minecraft/client/resources/model/EquipmentClientInfo.java +++ b/net/minecraft/client/resources/model/EquipmentClientInfo.java @@ -115,7 +115,15 @@ public record EquipmentClientInfo(Map CODEC = StringRepresentable.fromEnum(EquipmentClientInfo.LayerType::values); private final String id; @@ -128,5 +136,9 @@ public record EquipmentClientInfo(Map map = new EnumMap(Direction.class); - - for (Direction direction : Direction.values()) { - map.put(direction, new BlockElementFace(direction, -1, "missingno", blockFaceUV)); - } - + BlockElementFace.UVs uVs = new BlockElementFace.UVs(0.0F, 0.0F, 16.0F, 16.0F); + Map map = Util.makeEnumMap(Direction.class, direction -> new BlockElementFace(direction, -1, "missingno", uVs, Quadrant.R0)); BlockElement blockElement = new BlockElement(new Vector3f(0.0F, 0.0F, 0.0F), new Vector3f(16.0F, 16.0F, 16.0F), map); return new BlockModel( + new SimpleUnbakedGeometry(List.of(blockElement)), null, - List.of(blockElement), + null, + ItemTransforms.NO_TRANSFORMS, new Builder() .addReference("particle", "missingno") .addTexture("missingno", new Material(TextureAtlas.LOCATION_BLOCKS, MissingTextureAtlasSprite.getLocation())) .build(), - null, - null, - ItemTransforms.NO_TRANSFORMS + null ); } } diff --git a/net/minecraft/client/resources/model/ModelBaker.java b/net/minecraft/client/resources/model/ModelBaker.java index f9f6e3a5..12413135 100644 --- a/net/minecraft/client/resources/model/ModelBaker.java +++ b/net/minecraft/client/resources/model/ModelBaker.java @@ -3,14 +3,18 @@ package net.minecraft.client.resources.model; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.resources.ResourceLocation; -import net.minecraft.util.VisibleForDebug; @Environment(EnvType.CLIENT) public interface ModelBaker { - BakedModel bake(ResourceLocation location, ModelState transform); + ResolvedModel getModel(ResourceLocation modelLocation); SpriteGetter sprites(); - @VisibleForDebug - ModelDebugName rootName(); + T compute(ModelBaker.SharedOperationKey key); + + @FunctionalInterface + @Environment(EnvType.CLIENT) + public interface SharedOperationKey { + T compute(ModelBaker modelBaker); + } } diff --git a/net/minecraft/client/resources/model/ModelBakery.java b/net/minecraft/client/resources/model/ModelBakery.java index f30961fb..4907b75a 100644 --- a/net/minecraft/client/resources/model/ModelBakery.java +++ b/net/minecraft/client/resources/model/ModelBakery.java @@ -1,10 +1,13 @@ package net.minecraft.client.resources.model; import com.mojang.logging.LogUtils; -import com.mojang.math.Transformation; import java.util.HashMap; import java.util.List; import java.util.Map; +import java.util.concurrent.CompletableFuture; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.Executor; +import java.util.function.Function; import java.util.function.UnaryOperator; import java.util.stream.Collectors; import java.util.stream.IntStream; @@ -13,14 +16,21 @@ import net.fabricmc.api.Environment; import net.minecraft.client.model.geom.EntityModelSet; import net.minecraft.client.renderer.RenderType; import net.minecraft.client.renderer.Sheets; -import net.minecraft.client.renderer.block.model.UnbakedBlockStateModel; +import net.minecraft.client.renderer.block.model.BlockStateModel; +import net.minecraft.client.renderer.block.model.ItemTransforms; +import net.minecraft.client.renderer.block.model.SimpleModelWrapper; +import net.minecraft.client.renderer.block.model.SingleVariant; +import net.minecraft.client.renderer.block.model.TextureSlots; import net.minecraft.client.renderer.item.ClientItem; import net.minecraft.client.renderer.item.ItemModel; import net.minecraft.client.renderer.item.MissingItemModel; +import net.minecraft.client.renderer.item.ModelRenderProperties; import net.minecraft.client.renderer.texture.TextureAtlas; import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.client.resources.model.ModelBakery.TextureGetter.1; +import net.minecraft.client.resources.model.ModelBakery.MissingModels.1; import net.minecraft.resources.ResourceLocation; +import net.minecraft.util.thread.ParallelMapTransform; +import net.minecraft.world.level.block.state.BlockState; import org.slf4j.Logger; @Environment(EnvType.CLIENT) @@ -43,127 +53,111 @@ public class ModelBakery { public static final List DESTROY_TYPES = (List)BREAKING_LOCATIONS.stream().map(RenderType::crumbling).collect(Collectors.toList()); static final Logger LOGGER = LogUtils.getLogger(); private final EntityModelSet entityModelSet; - final Map bakedCache = new HashMap(); - private final Map unbakedBlockStateModels; + private final Map unbakedBlockStateModels; private final Map clientInfos; - final Map unbakedPlainModels; - final UnbakedModel missingModel; + final Map resolvedModels; + final ResolvedModel missingModel; public ModelBakery( EntityModelSet entityModelSet, - Map unbakedBlockStateModels, - Map unbakedItemStackModels, - Map unbakedPlainModels, - UnbakedModel missingModel + Map unbakedBlockStateModels, + Map clientInfos, + Map resolvedModels, + ResolvedModel missingModel ) { this.entityModelSet = entityModelSet; this.unbakedBlockStateModels = unbakedBlockStateModels; - this.clientInfos = unbakedItemStackModels; - this.unbakedPlainModels = unbakedPlainModels; + this.clientInfos = clientInfos; + this.resolvedModels = resolvedModels; this.missingModel = missingModel; } - public ModelBakery.BakingResult bakeModels(ModelBakery.TextureGetter textureGetter) { - BakedModel bakedModel = UnbakedModel.bakeWithTopModelValues( - this.missingModel, new ModelBakery.ModelBakerImpl(textureGetter, () -> "missing"), BlockModelRotation.X0_Y0 - ); - Map map = new HashMap(this.unbakedBlockStateModels.size()); - this.unbakedBlockStateModels.forEach((modelResourceLocation, unbakedBlockStateModel) -> { - try { - BakedModel bakedModelx = unbakedBlockStateModel.bake(new ModelBakery.ModelBakerImpl(textureGetter, modelResourceLocation::toString)); - map.put(modelResourceLocation, bakedModelx); - } catch (Exception var6x) { - LOGGER.warn("Unable to bake model: '{}': {}", modelResourceLocation, var6x); - } - }); - ItemModel itemModel = new MissingItemModel(bakedModel); - Map map2 = new HashMap(this.clientInfos.size()); - Map map3 = new HashMap(this.clientInfos.size()); - this.clientInfos.forEach((resourceLocation, clientItem) -> { - ModelDebugName modelDebugName = () -> resourceLocation + "#inventory"; - ModelBakery.ModelBakerImpl modelBakerImpl = new ModelBakery.ModelBakerImpl(textureGetter, modelDebugName); - ItemModel.BakingContext bakingContext = new ItemModel.BakingContext(modelBakerImpl, this.entityModelSet, itemModel); - - try { - ItemModel itemModel2 = clientItem.model().bake(bakingContext); - map2.put(resourceLocation, itemModel2); - if (!clientItem.properties().equals(ClientItem.Properties.DEFAULT)) { - map3.put(resourceLocation, clientItem.properties()); + public CompletableFuture bakeModels(SpriteGetter sprites, Executor executor) { + ModelBakery.MissingModels missingModels = ModelBakery.MissingModels.bake(this.missingModel, sprites); + ModelBakery.ModelBakerImpl modelBakerImpl = new ModelBakery.ModelBakerImpl(sprites); + CompletableFuture> completableFuture = ParallelMapTransform.schedule( + this.unbakedBlockStateModels, (blockState, unbakedRoot) -> { + try { + return unbakedRoot.bake(blockState, modelBakerImpl); + } catch (Exception var4x) { + LOGGER.warn("Unable to bake model: '{}': {}", blockState, var4x); + return null; } - } catch (Exception var11) { - LOGGER.warn("Unable to bake item model: '{}'", resourceLocation, var11); + }, executor + ); + CompletableFuture> completableFuture2 = ParallelMapTransform.schedule(this.clientInfos, (resourceLocation, clientItem) -> { + try { + return clientItem.model().bake(new ItemModel.BakingContext(modelBakerImpl, this.entityModelSet, missingModels.item, clientItem.registrySwapper())); + } catch (Exception var6x) { + LOGGER.warn("Unable to bake item model: '{}'", resourceLocation, var6x); + return null; + } + }, executor); + Map map = new HashMap(this.clientInfos.size()); + this.clientInfos.forEach((resourceLocation, clientItem) -> { + ClientItem.Properties properties = clientItem.properties(); + if (!properties.equals(ClientItem.Properties.DEFAULT)) { + map.put(resourceLocation, properties); } }); - return new ModelBakery.BakingResult(bakedModel, map, itemModel, map2, map3); - } - - @Environment(EnvType.CLIENT) - record BakedCacheKey(ResourceLocation id, Transformation transformation, boolean isUvLocked) { + return completableFuture.thenCombine(completableFuture2, (map2, map3) -> new ModelBakery.BakingResult(missingModels, map2, map3, map)); } @Environment(EnvType.CLIENT) public record BakingResult( - BakedModel missingModel, - Map blockStateModels, - ItemModel missingItemModel, + ModelBakery.MissingModels missingModels, + Map blockStateModels, Map itemStackModels, Map itemProperties ) { } @Environment(EnvType.CLIENT) - class ModelBakerImpl implements ModelBaker { - private final ModelDebugName rootName; - private final SpriteGetter modelTextureGetter; + public record MissingModels(BlockStateModel block, ItemModel item) { - ModelBakerImpl(final ModelBakery.TextureGetter textureGetter, final ModelDebugName rootName) { - this.modelTextureGetter = textureGetter.bind(rootName); - this.rootName = rootName; - } - - @Override - public SpriteGetter sprites() { - return this.modelTextureGetter; - } - - private UnbakedModel getModel(ResourceLocation name) { - UnbakedModel unbakedModel = (UnbakedModel)ModelBakery.this.unbakedPlainModels.get(name); - if (unbakedModel == null) { - ModelBakery.LOGGER.warn("Requested a model that was not discovered previously: {}", name); - return ModelBakery.this.missingModel; - } else { - return unbakedModel; - } - } - - @Override - public BakedModel bake(ResourceLocation location, ModelState transform) { - ModelBakery.BakedCacheKey bakedCacheKey = new ModelBakery.BakedCacheKey(location, transform.getRotation(), transform.isUvLocked()); - BakedModel bakedModel = (BakedModel)ModelBakery.this.bakedCache.get(bakedCacheKey); - if (bakedModel != null) { - return bakedModel; - } else { - UnbakedModel unbakedModel = this.getModel(location); - BakedModel bakedModel2 = UnbakedModel.bakeWithTopModelValues(unbakedModel, this, transform); - ModelBakery.this.bakedCache.put(bakedCacheKey, bakedModel2); - return bakedModel2; - } - } - - @Override - public ModelDebugName rootName() { - return this.rootName; + public static ModelBakery.MissingModels bake(ResolvedModel model, SpriteGetter sprites) { + ModelBaker modelBaker = new 1(sprites); + TextureSlots textureSlots = model.getTopTextureSlots(); + boolean bl = model.getTopAmbientOcclusion(); + boolean bl2 = model.getTopGuiLight().lightLikeBlock(); + ItemTransforms itemTransforms = model.getTopTransforms(); + QuadCollection quadCollection = model.bakeTopGeometry(textureSlots, modelBaker, BlockModelRotation.X0_Y0); + TextureAtlasSprite textureAtlasSprite = model.resolveParticleSprite(textureSlots, modelBaker); + BlockStateModel blockStateModel = new SingleVariant(new SimpleModelWrapper(quadCollection, bl, textureAtlasSprite)); + ItemModel itemModel = new MissingItemModel(quadCollection.getAll(), new ModelRenderProperties(bl2, textureAtlasSprite, itemTransforms)); + return new ModelBakery.MissingModels(blockStateModel, itemModel); } } @Environment(EnvType.CLIENT) - public interface TextureGetter { - TextureAtlasSprite get(ModelDebugName name, Material material); + class ModelBakerImpl implements ModelBaker { + private final SpriteGetter sprites; + private final Map, Object> operationCache = new ConcurrentHashMap(); + private final Function, Object> cacheComputeFunction = sharedOperationKey -> sharedOperationKey.compute(this); - TextureAtlasSprite reportMissingReference(ModelDebugName name, String reference); + ModelBakerImpl(final SpriteGetter sprites) { + this.sprites = sprites; + } - default SpriteGetter bind(ModelDebugName name) { - return new 1(this, name); + @Override + public SpriteGetter sprites() { + return this.sprites; + } + + @Override + public ResolvedModel getModel(ResourceLocation modelLocation) { + ResolvedModel resolvedModel = (ResolvedModel)ModelBakery.this.resolvedModels.get(modelLocation); + if (resolvedModel == null) { + ModelBakery.LOGGER.warn("Requested a model that was not discovered previously: {}", modelLocation); + return ModelBakery.this.missingModel; + } else { + return resolvedModel; + } + } + + @Override + public T compute(ModelBaker.SharedOperationKey key) { + return (T)this.operationCache.computeIfAbsent(key, this.cacheComputeFunction); } } } diff --git a/net/minecraft/client/resources/model/ModelDebugName.java b/net/minecraft/client/resources/model/ModelDebugName.java index 8d134e08..7b1df778 100644 --- a/net/minecraft/client/resources/model/ModelDebugName.java +++ b/net/minecraft/client/resources/model/ModelDebugName.java @@ -1,10 +1,10 @@ package net.minecraft.client.resources.model; -import java.util.function.Supplier; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; @FunctionalInterface @Environment(EnvType.CLIENT) -public interface ModelDebugName extends Supplier { +public interface ModelDebugName { + String debugName(); } diff --git a/net/minecraft/client/resources/model/ModelDiscovery.java b/net/minecraft/client/resources/model/ModelDiscovery.java index 5e2a5b14..34d3ee55 100644 --- a/net/minecraft/client/resources/model/ModelDiscovery.java +++ b/net/minecraft/client/resources/model/ModelDiscovery.java @@ -1,92 +1,251 @@ package net.minecraft.client.resources.model; -import com.google.common.collect.Sets; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; import com.mojang.logging.LogUtils; +import it.unimi.dsi.fastutil.objects.Object2ObjectFunction; +import it.unimi.dsi.fastutil.objects.Object2ObjectMap; +import it.unimi.dsi.fastutil.objects.Object2ObjectOpenHashMap; +import java.util.ArrayDeque; import java.util.ArrayList; -import java.util.HashMap; -import java.util.HashSet; +import java.util.Iterator; import java.util.List; import java.util.Map; -import java.util.Set; -import java.util.stream.Collectors; +import java.util.Objects; +import java.util.Queue; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.atomic.AtomicReferenceArray; +import java.util.function.Function; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.ItemModelGenerator; +import net.minecraft.client.renderer.block.model.ItemTransforms; +import net.minecraft.client.renderer.block.model.TextureSlots; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.resources.ResourceLocation; +import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @Environment(EnvType.CLIENT) public class ModelDiscovery { - static final Logger LOGGER = LogUtils.getLogger(); - private final Map inputModels; - final UnbakedModel missingModel; - private final List topModels = new ArrayList(); - private final Map referencedModels = new HashMap(); + private static final Logger LOGGER = LogUtils.getLogger(); + private final Object2ObjectMap modelWrappers = new Object2ObjectOpenHashMap<>(); + private final ModelDiscovery.ModelWrapper missingModel; + private final Object2ObjectFunction uncachedResolver; + private final ResolvableModel.Resolver resolver; + private final Queue parentDiscoveryQueue = new ArrayDeque(); public ModelDiscovery(Map inputModels, UnbakedModel missingModel) { - this.inputModels = inputModels; - this.missingModel = missingModel; - this.referencedModels.put(MissingBlockModel.LOCATION, missingModel); + this.missingModel = new ModelDiscovery.ModelWrapper(MissingBlockModel.LOCATION, missingModel, true); + this.modelWrappers.put(MissingBlockModel.LOCATION, this.missingModel); + this.uncachedResolver = object -> { + ResourceLocation resourceLocation = (ResourceLocation)object; + UnbakedModel unbakedModel = (UnbakedModel)inputModels.get(resourceLocation); + if (unbakedModel == null) { + LOGGER.warn("Missing block model: {}", resourceLocation); + return this.missingModel; + } else { + return this.createAndQueueWrapper(resourceLocation, unbakedModel); + } + }; + this.resolver = this::getOrCreateModel; } - public void registerSpecialModels() { - this.referencedModels.put(ItemModelGenerator.GENERATED_ITEM_MODEL_ID, new ItemModelGenerator()); + private static boolean isRoot(UnbakedModel model) { + return model.parent() == null; + } + + private ModelDiscovery.ModelWrapper getOrCreateModel(ResourceLocation location) { + return this.modelWrappers.computeIfAbsent(location, this.uncachedResolver); + } + + private ModelDiscovery.ModelWrapper createAndQueueWrapper(ResourceLocation id, UnbakedModel model) { + boolean bl = isRoot(model); + ModelDiscovery.ModelWrapper modelWrapper = new ModelDiscovery.ModelWrapper(id, model, bl); + if (!bl) { + this.parentDiscoveryQueue.add(modelWrapper); + } + + return modelWrapper; } public void addRoot(ResolvableModel model) { - this.topModels.add(model); + model.resolveDependencies(this.resolver); } - public void discoverDependencies() { - this.topModels.forEach(resolvableModel -> resolvableModel.resolveDependencies(new ModelDiscovery.ResolverImpl())); - } - - public Map getReferencedModels() { - return this.referencedModels; - } - - public Set getUnreferencedModels() { - return Sets.difference(this.inputModels.keySet(), this.referencedModels.keySet()); - } - - UnbakedModel getBlockModel(ResourceLocation modelLocation) { - return (UnbakedModel)this.referencedModels.computeIfAbsent(modelLocation, this::loadBlockModel); - } - - private UnbakedModel loadBlockModel(ResourceLocation modelLocation) { - UnbakedModel unbakedModel = (UnbakedModel)this.inputModels.get(modelLocation); - if (unbakedModel == null) { - LOGGER.warn("Missing block model: '{}'", modelLocation); - return this.missingModel; + public void addSpecialModel(ResourceLocation id, UnbakedModel model) { + if (!isRoot(model)) { + LOGGER.warn("Trying to add non-root special model {}, ignoring", id); } else { - return unbakedModel; + ModelDiscovery.ModelWrapper modelWrapper = this.modelWrappers.put(id, this.createAndQueueWrapper(id, model)); + if (modelWrapper != null) { + LOGGER.warn("Duplicate special model {}", id); + } + } + } + + public ResolvedModel missingModel() { + return this.missingModel; + } + + public Map resolve() { + List list = new ArrayList(); + this.discoverDependencies(list); + propagateValidity(list); + Builder builder = ImmutableMap.builder(); + this.modelWrappers.forEach((resourceLocation, modelWrapper) -> { + if (modelWrapper.valid) { + builder.put(resourceLocation, modelWrapper); + } else { + LOGGER.warn("Model {} ignored due to cyclic dependency", resourceLocation); + } + }); + return builder.build(); + } + + private void discoverDependencies(List wrappers) { + ModelDiscovery.ModelWrapper modelWrapper; + while ((modelWrapper = (ModelDiscovery.ModelWrapper)this.parentDiscoveryQueue.poll()) != null) { + ResourceLocation resourceLocation = (ResourceLocation)Objects.requireNonNull(modelWrapper.wrapped.parent()); + ModelDiscovery.ModelWrapper modelWrapper2 = this.getOrCreateModel(resourceLocation); + modelWrapper.parent = modelWrapper2; + if (modelWrapper2.valid) { + modelWrapper.valid = true; + } else { + wrappers.add(modelWrapper); + } + } + } + + private static void propagateValidity(List wrappers) { + boolean bl = true; + + while (bl) { + bl = false; + Iterator iterator = wrappers.iterator(); + + while (iterator.hasNext()) { + ModelDiscovery.ModelWrapper modelWrapper = (ModelDiscovery.ModelWrapper)iterator.next(); + if (((ModelDiscovery.ModelWrapper)Objects.requireNonNull(modelWrapper.parent)).valid) { + modelWrapper.valid = true; + iterator.remove(); + bl = true; + } + } } } @Environment(EnvType.CLIENT) - class ResolverImpl implements ResolvableModel.Resolver { - private final List stack = new ArrayList(); - private final Set resolvedModels = new HashSet(); + static class ModelWrapper implements ResolvedModel { + private static final ModelDiscovery.Slot KEY_AMBIENT_OCCLUSION = slot(0); + private static final ModelDiscovery.Slot KEY_GUI_LIGHT = slot(1); + private static final ModelDiscovery.Slot KEY_GEOMETRY = slot(2); + private static final ModelDiscovery.Slot KEY_TRANSFORMS = slot(3); + private static final ModelDiscovery.Slot KEY_TEXTURE_SLOTS = slot(4); + private static final ModelDiscovery.Slot KEY_PARTICLE_SPRITE = slot(5); + private static final ModelDiscovery.Slot KEY_DEFAULT_GEOMETRY = slot(6); + private static final int SLOT_COUNT = 7; + private final ResourceLocation id; + boolean valid; + @Nullable + ModelDiscovery.ModelWrapper parent; + final UnbakedModel wrapped; + private final AtomicReferenceArray fixedSlots = new AtomicReferenceArray(7); + private final Map modelBakeCache = new ConcurrentHashMap(); + + private static ModelDiscovery.Slot slot(int index) { + Objects.checkIndex(index, 7); + return new ModelDiscovery.Slot<>(index); + } + + ModelWrapper(ResourceLocation id, UnbakedModel wrapped, boolean valid) { + this.id = id; + this.wrapped = wrapped; + this.valid = valid; + } @Override - public UnbakedModel resolve(ResourceLocation model) { - if (this.stack.contains(model)) { - ModelDiscovery.LOGGER.warn("Detected model loading loop: {}->{}", this.stacktraceToString(), model); - return ModelDiscovery.this.missingModel; - } else { - UnbakedModel unbakedModel = ModelDiscovery.this.getBlockModel(model); - if (this.resolvedModels.add(model)) { - this.stack.add(model); - unbakedModel.resolveDependencies(this); - this.stack.remove(model); - } - - return unbakedModel; - } + public UnbakedModel wrapped() { + return this.wrapped; } - private String stacktraceToString() { - return (String)this.stack.stream().map(ResourceLocation::toString).collect(Collectors.joining("->")); + @Nullable + @Override + public ResolvedModel parent() { + return this.parent; + } + + @Override + public String debugName() { + return this.id.toString(); + } + + @Nullable + private T getSlot(ModelDiscovery.Slot slot) { + return (T)this.fixedSlots.get(slot.index); + } + + private T updateSlot(ModelDiscovery.Slot slot, T value) { + T object = (T)this.fixedSlots.compareAndExchange(slot.index, null, value); + return object == null ? value : object; + } + + private T getSimpleProperty(ModelDiscovery.Slot slot, Function propertyGetter) { + T object = this.getSlot(slot); + return object != null ? object : this.updateSlot(slot, (T)propertyGetter.apply(this)); + } + + @Override + public boolean getTopAmbientOcclusion() { + return this.getSimpleProperty(KEY_AMBIENT_OCCLUSION, ResolvedModel::findTopAmbientOcclusion); + } + + @Override + public UnbakedModel.GuiLight getTopGuiLight() { + return this.getSimpleProperty(KEY_GUI_LIGHT, ResolvedModel::findTopGuiLight); + } + + @Override + public ItemTransforms getTopTransforms() { + return this.getSimpleProperty(KEY_TRANSFORMS, ResolvedModel::findTopTransforms); + } + + @Override + public UnbakedGeometry getTopGeometry() { + return this.getSimpleProperty(KEY_GEOMETRY, ResolvedModel::findTopGeometry); + } + + @Override + public TextureSlots getTopTextureSlots() { + return this.getSimpleProperty(KEY_TEXTURE_SLOTS, ResolvedModel::findTopTextureSlots); + } + + @Override + public TextureAtlasSprite resolveParticleSprite(TextureSlots textureSlots, ModelBaker modelBaker) { + TextureAtlasSprite textureAtlasSprite = this.getSlot(KEY_PARTICLE_SPRITE); + return textureAtlasSprite != null + ? textureAtlasSprite + : this.updateSlot(KEY_PARTICLE_SPRITE, ResolvedModel.resolveParticleSprite(textureSlots, modelBaker, this)); + } + + private QuadCollection bakeDefaultState(TextureSlots textureSlots, ModelBaker modelBaker, ModelState modelState) { + QuadCollection quadCollection = this.getSlot(KEY_DEFAULT_GEOMETRY); + return quadCollection != null + ? quadCollection + : this.updateSlot(KEY_DEFAULT_GEOMETRY, this.getTopGeometry().bake(textureSlots, modelBaker, modelState, this)); + } + + @Override + public QuadCollection bakeTopGeometry(TextureSlots textureSlots, ModelBaker modelBaker, ModelState modelState) { + return modelState == BlockModelRotation.X0_Y0 + ? this.bakeDefaultState(textureSlots, modelBaker, modelState) + : (QuadCollection)this.modelBakeCache.computeIfAbsent(modelState, modelStatex -> { + UnbakedGeometry unbakedGeometry = this.getTopGeometry(); + return unbakedGeometry.bake(textureSlots, modelBaker, modelStatex, this); + }); } } + + @Environment(EnvType.CLIENT) + record Slot(int index) { + } } diff --git a/net/minecraft/client/resources/model/ModelGroupCollector.java b/net/minecraft/client/resources/model/ModelGroupCollector.java index 4cf8829c..42434c70 100644 --- a/net/minecraft/client/resources/model/ModelGroupCollector.java +++ b/net/minecraft/client/resources/model/ModelGroupCollector.java @@ -11,7 +11,7 @@ import java.util.Set; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; import net.minecraft.client.color.block.BlockColors; -import net.minecraft.client.renderer.block.model.UnbakedBlockStateModel; +import net.minecraft.client.renderer.block.model.BlockStateModel; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.RenderShape; import net.minecraft.world.level.block.state.BlockState; @@ -25,16 +25,11 @@ public class ModelGroupCollector { public static Object2IntMap build(BlockColors blockColors, BlockStateModelLoader.LoadedModels loadedModels) { Map>> map = new HashMap(); Map> map2 = new HashMap(); - loadedModels.models() - .forEach( - (modelResourceLocation, loadedModel) -> { - List> list = (List>)map.computeIfAbsent( - loadedModel.state().getBlock(), block -> List.copyOf(blockColors.getColoringProperties(block)) - ); - ModelGroupCollector.GroupKey groupKey = ModelGroupCollector.GroupKey.create(loadedModel.state(), loadedModel.model(), list); - ((Set)map2.computeIfAbsent(groupKey, groupKeyx -> Sets.newIdentityHashSet())).add(loadedModel.state()); - } - ); + loadedModels.models().forEach((blockState, unbakedRoot) -> { + List> list = (List>)map.computeIfAbsent(blockState.getBlock(), block -> List.copyOf(blockColors.getColoringProperties(block))); + ModelGroupCollector.GroupKey groupKey = ModelGroupCollector.GroupKey.create(blockState, unbakedRoot, list); + ((Set)map2.computeIfAbsent(groupKey, groupKeyx -> Sets.newIdentityHashSet())).add(blockState); + }); int i = 1; Object2IntMap object2IntMap = new Object2IntOpenHashMap<>(); object2IntMap.defaultReturnValue(-1); @@ -61,9 +56,9 @@ public class ModelGroupCollector { @Environment(EnvType.CLIENT) record GroupKey(Object equalityGroup, List coloringValues) { - public static ModelGroupCollector.GroupKey create(BlockState state, UnbakedBlockStateModel model, List> properties) { + public static ModelGroupCollector.GroupKey create(BlockState state, BlockStateModel.UnbakedRoot root, List> properties) { List list = getColoringValues(state, properties); - Object object = model.visualEqualityGroup(state); + Object object = root.visualEqualityGroup(state); return new ModelGroupCollector.GroupKey(object, list); } diff --git a/net/minecraft/client/resources/model/ModelManager.java b/net/minecraft/client/resources/model/ModelManager.java index 01f0899a..5e76dc5d 100644 --- a/net/minecraft/client/resources/model/ModelManager.java +++ b/net/minecraft/client/resources/model/ModelManager.java @@ -2,6 +2,8 @@ package net.minecraft.client.resources.model; import com.google.common.collect.HashMultimap; import com.google.common.collect.Multimap; +import com.google.common.collect.Multimaps; +import com.google.common.collect.Sets; import com.mojang.datafixers.util.Pair; import com.mojang.logging.LogUtils; import it.unimi.dsi.fastutil.objects.Object2IntMap; @@ -28,21 +30,22 @@ import net.minecraft.client.renderer.Sheets; import net.minecraft.client.renderer.SpecialBlockModelRenderer; import net.minecraft.client.renderer.block.BlockModelShaper; import net.minecraft.client.renderer.block.model.BlockModel; +import net.minecraft.client.renderer.block.model.BlockStateModel; +import net.minecraft.client.renderer.block.model.ItemModelGenerator; import net.minecraft.client.renderer.item.ClientItem; import net.minecraft.client.renderer.item.ItemModel; import net.minecraft.client.renderer.texture.TextureAtlas; import net.minecraft.client.renderer.texture.TextureAtlasSprite; import net.minecraft.client.renderer.texture.TextureManager; -import net.minecraft.client.resources.model.AtlasSet.StitchResult; import net.minecraft.core.registries.BuiltInRegistries; import net.minecraft.resources.FileToIdConverter; import net.minecraft.resources.ResourceLocation; import net.minecraft.server.packs.resources.PreparableReloadListener; import net.minecraft.server.packs.resources.Resource; import net.minecraft.server.packs.resources.ResourceManager; -import net.minecraft.server.packs.resources.PreparableReloadListener.PreparationBarrier; import net.minecraft.util.profiling.Profiler; import net.minecraft.util.profiling.ProfilerFiller; +import net.minecraft.util.profiling.Zone; import net.minecraft.world.level.block.Block; import net.minecraft.world.level.block.state.BlockState; import net.minecraft.world.level.material.FluidState; @@ -54,25 +57,24 @@ public class ModelManager implements PreparableReloadListener, AutoCloseable { private static final FileToIdConverter MODEL_LISTER = FileToIdConverter.json("models"); private static final Map VANILLA_ATLASES = Map.of( Sheets.BANNER_SHEET, - ResourceLocation.withDefaultNamespace("banner_patterns"), + AtlasIds.BANNER_PATTERNS, Sheets.BED_SHEET, - ResourceLocation.withDefaultNamespace("beds"), + AtlasIds.BEDS, Sheets.CHEST_SHEET, - ResourceLocation.withDefaultNamespace("chests"), + AtlasIds.CHESTS, Sheets.SHIELD_SHEET, - ResourceLocation.withDefaultNamespace("shield_patterns"), + AtlasIds.SHIELD_PATTERNS, Sheets.SIGN_SHEET, - ResourceLocation.withDefaultNamespace("signs"), + AtlasIds.SIGNS, Sheets.SHULKER_SHEET, - ResourceLocation.withDefaultNamespace("shulker_boxes"), + AtlasIds.SHULKER_BOXES, Sheets.ARMOR_TRIMS_SHEET, - ResourceLocation.withDefaultNamespace("armor_trims"), + AtlasIds.ARMOR_TRIMS, Sheets.DECORATED_POT_SHEET, - ResourceLocation.withDefaultNamespace("decorated_pot"), + AtlasIds.DECORATED_POT, TextureAtlas.LOCATION_BLOCKS, - ResourceLocation.withDefaultNamespace("blocks") + AtlasIds.BLOCKS ); - private Map bakedBlockStateModels = Map.of(); private Map bakedItemStackModels = Map.of(); private Map itemProperties = Map.of(); private final AtlasSet atlases; @@ -81,8 +83,7 @@ public class ModelManager implements PreparableReloadListener, AutoCloseable { private EntityModelSet entityModelSet = EntityModelSet.EMPTY; private SpecialBlockModelRenderer specialBlockModelRenderer = SpecialBlockModelRenderer.EMPTY; private int maxMipmapLevels; - private BakedModel missingModel; - private ItemModel missingItemModel; + private ModelBakery.MissingModels missingModels; private Object2IntMap modelGroups = Object2IntMaps.emptyMap(); public ModelManager(TextureManager textureManager, BlockColors blockColors, int maxMipmapLevels) { @@ -92,16 +93,12 @@ public class ModelManager implements PreparableReloadListener, AutoCloseable { this.atlases = new AtlasSet(VANILLA_ATLASES, textureManager); } - public BakedModel getModel(ModelResourceLocation modelLocation) { - return (BakedModel)this.bakedBlockStateModels.getOrDefault(modelLocation, this.missingModel); - } - - public BakedModel getMissingModel() { - return this.missingModel; + public BlockStateModel getMissingBlockStateModel() { + return this.missingModels.block(); } public ItemModel getItemModel(ResourceLocation modelLocation) { - return (ItemModel)this.bakedItemStackModels.getOrDefault(modelLocation, this.missingItemModel); + return (ItemModel)this.bakedItemStackModels.getOrDefault(modelLocation, this.missingModels.item()); } public ClientItem.Properties getItemProperties(ResourceLocation itemId) { @@ -113,61 +110,60 @@ public class ModelManager implements PreparableReloadListener, AutoCloseable { } @Override - public final CompletableFuture reload(PreparationBarrier barrier, ResourceManager manager, Executor backgroundExecutor, Executor gameExecutor) { - UnbakedModel unbakedModel = MissingBlockModel.missingModel(); - CompletableFuture completableFuture = CompletableFuture.supplyAsync(EntityModelSet::vanilla, backgroundExecutor); - CompletableFuture completableFuture2 = completableFuture.thenApplyAsync(SpecialBlockModelRenderer::vanilla, backgroundExecutor); - CompletableFuture> completableFuture3 = loadBlockModels(manager, backgroundExecutor); - CompletableFuture completableFuture4 = BlockStateModelLoader.loadBlockStates(unbakedModel, manager, backgroundExecutor); - CompletableFuture completableFuture5 = ClientItemInfoLoader.scheduleLoad(manager, backgroundExecutor); - CompletableFuture completableFuture6 = CompletableFuture.allOf(completableFuture3, completableFuture4, completableFuture5) + public final CompletableFuture reload( + PreparableReloadListener.PreparationBarrier preparationBarrier, ResourceManager resourceManager, Executor executor, Executor executor2 + ) { + CompletableFuture completableFuture = CompletableFuture.supplyAsync(EntityModelSet::vanilla, executor); + CompletableFuture completableFuture2 = completableFuture.thenApplyAsync(SpecialBlockModelRenderer::vanilla, executor); + CompletableFuture> completableFuture3 = loadBlockModels(resourceManager, executor); + CompletableFuture completableFuture4 = BlockStateModelLoader.loadBlockStates(resourceManager, executor); + CompletableFuture completableFuture5 = ClientItemInfoLoader.scheduleLoad(resourceManager, executor); + CompletableFuture completableFuture6 = CompletableFuture.allOf(completableFuture3, completableFuture4, completableFuture5) .thenApplyAsync( void_ -> discoverModelDependencies( - unbakedModel, (Map)completableFuture3.join(), (BlockStateModelLoader.LoadedModels)completableFuture4.join(), (ClientItemInfoLoader.LoadedClientInfos)completableFuture5.join() ), - backgroundExecutor + executor ); CompletableFuture> completableFuture7 = completableFuture4.thenApplyAsync( - loadedModels -> buildModelGroups(this.blockColors, loadedModels), backgroundExecutor + loadedModels -> buildModelGroups(this.blockColors, loadedModels), executor ); - Map> map = this.atlases.scheduleLoad(manager, this.maxMipmapLevels, backgroundExecutor); + Map> map = this.atlases.scheduleLoad(resourceManager, this.maxMipmapLevels, executor); return CompletableFuture.allOf( (CompletableFuture[])Stream.concat( - map.values().stream(), Stream.of(completableFuture6, completableFuture7, completableFuture4, completableFuture5, completableFuture, completableFuture2) + map.values().stream(), + Stream.of(completableFuture6, completableFuture7, completableFuture4, completableFuture5, completableFuture, completableFuture2, completableFuture3) ) .toArray(CompletableFuture[]::new) ) - .thenApplyAsync( + .thenComposeAsync( void_ -> { - Map map2 = (Map)map.entrySet() - .stream() - .collect(Collectors.toMap(Entry::getKey, entry -> (StitchResult)((CompletableFuture)entry.getValue()).join())); - ModelDiscovery modelDiscovery = (ModelDiscovery)completableFuture6.join(); + Map map2 = Util.mapValues(map, CompletableFuture::join); + ModelManager.ResolvedModels resolvedModels = (ModelManager.ResolvedModels)completableFuture6.join(); Object2IntMap object2IntMap = (Object2IntMap)completableFuture7.join(); - Set set = modelDiscovery.getUnreferencedModels(); + Set set = Sets.difference(((Map)completableFuture3.join()).keySet(), resolvedModels.models.keySet()); if (!set.isEmpty()) { LOGGER.debug("Unreferenced models: \n{}", set.stream().sorted().map(resourceLocation -> "\t" + resourceLocation + "\n").collect(Collectors.joining())); } ModelBakery modelBakery = new ModelBakery( (EntityModelSet)completableFuture.join(), - ((BlockStateModelLoader.LoadedModels)completableFuture4.join()).plainModels(), + ((BlockStateModelLoader.LoadedModels)completableFuture4.join()).models(), ((ClientItemInfoLoader.LoadedClientInfos)completableFuture5.join()).contents(), - modelDiscovery.getReferencedModels(), - unbakedModel + resolvedModels.models(), + resolvedModels.missing() ); return loadModels( - Profiler.get(), map2, modelBakery, object2IntMap, (EntityModelSet)completableFuture.join(), (SpecialBlockModelRenderer)completableFuture2.join() + map2, modelBakery, object2IntMap, (EntityModelSet)completableFuture.join(), (SpecialBlockModelRenderer)completableFuture2.join(), executor ); }, - backgroundExecutor + executor ) .thenCompose(reloadState -> reloadState.readyForUpload.thenApply(void_ -> reloadState)) - .thenCompose(barrier::wait) - .thenAcceptAsync(reloadState -> this.apply(reloadState, Profiler.get()), gameExecutor); + .thenCompose(preparationBarrier::wait) + .thenAcceptAsync(reloadState -> this.apply(reloadState, Profiler.get()), executor2); } private static CompletableFuture> loadBlockModels(ResourceManager resourceManager, Executor executor) { @@ -216,111 +212,118 @@ public class ModelManager implements PreparableReloadListener, AutoCloseable { ); } - private static ModelDiscovery discoverModelDependencies( - UnbakedModel missingModel, - Map inputModels, - BlockStateModelLoader.LoadedModels loadedModels, - ClientItemInfoLoader.LoadedClientInfos loadedClientInfos + private static ModelManager.ResolvedModels discoverModelDependencies( + Map inputModels, BlockStateModelLoader.LoadedModels loadedModels, ClientItemInfoLoader.LoadedClientInfos loadedClientInfos ) { - ModelDiscovery modelDiscovery = new ModelDiscovery(inputModels, missingModel); - loadedModels.forResolving().forEach(modelDiscovery::addRoot); - loadedClientInfos.contents().values().forEach(clientItem -> modelDiscovery.addRoot(clientItem.model())); - modelDiscovery.registerSpecialModels(); - modelDiscovery.discoverDependencies(); - return modelDiscovery; + ModelManager.ResolvedModels var5; + try (Zone zone = Profiler.get().zone("dependencies")) { + ModelDiscovery modelDiscovery = new ModelDiscovery(inputModels, MissingBlockModel.missingModel()); + modelDiscovery.addSpecialModel(ItemModelGenerator.GENERATED_ITEM_MODEL_ID, new ItemModelGenerator()); + loadedModels.models().values().forEach(modelDiscovery::addRoot); + loadedClientInfos.contents().values().forEach(clientItem -> modelDiscovery.addRoot(clientItem.model())); + var5 = new ModelManager.ResolvedModels(modelDiscovery.missingModel(), modelDiscovery.resolve()); + } + + return var5; } - private static ModelManager.ReloadState loadModels( - ProfilerFiller profiler, - Map atlasPreperations, + private static CompletableFuture loadModels( + Map stitchResults, ModelBakery modelBakery, Object2IntMap modelGroups, EntityModelSet entityModelSet, - SpecialBlockModelRenderer specialBlockModelRenderer + SpecialBlockModelRenderer specialBlockModelRenderer, + Executor executor ) { - profiler.push("baking"); - final Multimap multimap = HashMultimap.create(); - final Multimap multimap2 = HashMultimap.create(); - final TextureAtlasSprite textureAtlasSprite = ((StitchResult)atlasPreperations.get(TextureAtlas.LOCATION_BLOCKS)).missing(); - ModelBakery.BakingResult bakingResult = modelBakery.bakeModels(new ModelBakery.TextureGetter() { - @Override - public TextureAtlasSprite get(ModelDebugName name, Material material) { - StitchResult stitchResult = (StitchResult)atlasPreperations.get(material.atlasLocation()); - TextureAtlasSprite textureAtlasSpritex = stitchResult.getSprite(material.texture()); - if (textureAtlasSpritex != null) { - return textureAtlasSpritex; - } else { - multimap.put((String)name.get(), material); - return stitchResult.missing(); - } - } - - @Override - public TextureAtlasSprite reportMissingReference(ModelDebugName name, String reference) { - multimap2.put((String)name.get(), reference); - return textureAtlasSprite; - } - }); - multimap.asMap() - .forEach( - (string, collection) -> LOGGER.warn( - "Missing textures in model {}:\n{}", - string, - collection.stream() - .sorted(Material.COMPARATOR) - .map(material -> " " + material.atlasLocation() + ":" + material.texture()) - .collect(Collectors.joining("\n")) - ) - ); - multimap2.asMap() - .forEach( - (string, collection) -> LOGGER.warn( - "Missing texture references in model {}:\n{}", string, collection.stream().sorted().map(stringx -> " " + stringx).collect(Collectors.joining("\n")) - ) - ); - profiler.popPush("dispatch"); - Map map = createBlockStateToModelDispatch(bakingResult.blockStateModels(), bakingResult.missingModel()); CompletableFuture completableFuture = CompletableFuture.allOf( - (CompletableFuture[])atlasPreperations.values().stream().map(StitchResult::readyForUpload).toArray(CompletableFuture[]::new) + (CompletableFuture[])stitchResults.values().stream().map(AtlasSet.StitchResult::readyForUpload).toArray(CompletableFuture[]::new) ); - profiler.pop(); - return new ModelManager.ReloadState(bakingResult, modelGroups, map, atlasPreperations, entityModelSet, specialBlockModelRenderer, completableFuture); + final Multimap multimap = Multimaps.synchronizedMultimap(HashMultimap.create()); + final Multimap multimap2 = Multimaps.synchronizedMultimap(HashMultimap.create()); + return modelBakery.bakeModels(new SpriteGetter() { + private final TextureAtlasSprite missingSprite = ((AtlasSet.StitchResult)stitchResults.get(TextureAtlas.LOCATION_BLOCKS)).missing(); + + @Override + public TextureAtlasSprite get(Material material, ModelDebugName debugName) { + AtlasSet.StitchResult stitchResult = (AtlasSet.StitchResult)stitchResults.get(material.atlasLocation()); + TextureAtlasSprite textureAtlasSprite = stitchResult.getSprite(material.texture()); + if (textureAtlasSprite != null) { + return textureAtlasSprite; + } else { + multimap.put(debugName.debugName(), material); + return stitchResult.missing(); + } + } + + @Override + public TextureAtlasSprite reportMissingReference(String name, ModelDebugName debugName) { + multimap2.put(debugName.debugName(), name); + return this.missingSprite; + } + }, executor) + .thenApply( + bakingResult -> { + multimap.asMap() + .forEach( + (string, collection) -> LOGGER.warn( + "Missing textures in model {}:\n{}", + string, + collection.stream() + .sorted(Material.COMPARATOR) + .map(material -> " " + material.atlasLocation() + ":" + material.texture()) + .collect(Collectors.joining("\n")) + ) + ); + multimap2.asMap() + .forEach( + (string, collection) -> LOGGER.warn( + "Missing texture references in model {}:\n{}", string, collection.stream().sorted().map(stringx -> " " + stringx).collect(Collectors.joining("\n")) + ) + ); + Map map2 = createBlockStateToModelDispatch(bakingResult.blockStateModels(), bakingResult.missingModels().block()); + return new ModelManager.ReloadState(bakingResult, modelGroups, map2, stitchResults, entityModelSet, specialBlockModelRenderer, completableFuture); + } + ); } - private static Map createBlockStateToModelDispatch(Map blockStateModels, BakedModel missingModel) { - Map map = new IdentityHashMap(); + private static Map createBlockStateToModelDispatch( + Map blockStateModels, BlockStateModel missingModel + ) { + Object var8; + try (Zone zone = Profiler.get().zone("block state dispatch")) { + Map map = new IdentityHashMap(blockStateModels); - for (Block block : BuiltInRegistries.BLOCK) { - block.getStateDefinition().getPossibleStates().forEach(blockState -> { - ResourceLocation resourceLocation = blockState.getBlock().builtInRegistryHolder().key().location(); - ModelResourceLocation modelResourceLocation = BlockModelShaper.stateToModelLocation(resourceLocation, blockState); - BakedModel bakedModel2 = (BakedModel)blockStateModels.get(modelResourceLocation); - if (bakedModel2 == null) { - LOGGER.warn("Missing model for variant: '{}'", modelResourceLocation); - map.putIfAbsent(blockState, missingModel); - } else { - map.put(blockState, bakedModel2); - } - }); + for (Block block : BuiltInRegistries.BLOCK) { + block.getStateDefinition().getPossibleStates().forEach(blockState -> { + if (blockStateModels.putIfAbsent(blockState, missingModel) == null) { + LOGGER.warn("Missing model for variant: '{}'", blockState); + } + }); + } + + var8 = map; } - return map; + return (Map)var8; } private static Object2IntMap buildModelGroups(BlockColors blockColors, BlockStateModelLoader.LoadedModels loadedModels) { - return ModelGroupCollector.build(blockColors, loadedModels); + Object2IntMap var3; + try (Zone zone = Profiler.get().zone("block groups")) { + var3 = ModelGroupCollector.build(blockColors, loadedModels); + } + + return var3; } private void apply(ModelManager.ReloadState reloadState, ProfilerFiller profiler) { profiler.push("upload"); - reloadState.atlasPreparations.values().forEach(StitchResult::upload); + reloadState.atlasPreparations.values().forEach(AtlasSet.StitchResult::upload); ModelBakery.BakingResult bakingResult = reloadState.bakedModels; - this.bakedBlockStateModels = bakingResult.blockStateModels(); this.bakedItemStackModels = bakingResult.itemStackModels(); this.itemProperties = bakingResult.itemProperties(); this.modelGroups = reloadState.modelGroups; - this.missingModel = bakingResult.missingModel(); - this.missingItemModel = bakingResult.missingItemModel(); + this.missingModels = bakingResult.missingModels(); profiler.popPush("cache"); this.blockModelShaper.replaceCache(reloadState.modelCache); this.specialBlockModelRenderer = reloadState.specialBlockModelRenderer; @@ -370,11 +373,15 @@ public class ModelManager implements PreparableReloadListener, AutoCloseable { record ReloadState( ModelBakery.BakingResult bakedModels, Object2IntMap modelGroups, - Map modelCache, - Map atlasPreparations, + Map modelCache, + Map atlasPreparations, EntityModelSet entityModelSet, SpecialBlockModelRenderer specialBlockModelRenderer, CompletableFuture readyForUpload ) { } + + @Environment(EnvType.CLIENT) + record ResolvedModels(ResolvedModel missing, Map models) { + } } diff --git a/net/minecraft/client/resources/model/ModelResourceLocation.java b/net/minecraft/client/resources/model/ModelResourceLocation.java deleted file mode 100644 index 35862ecb..00000000 --- a/net/minecraft/client/resources/model/ModelResourceLocation.java +++ /dev/null @@ -1,27 +0,0 @@ -package net.minecraft.client.resources.model; - -import java.util.Locale; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.resources.ResourceLocation; - -@Environment(EnvType.CLIENT) -public record ModelResourceLocation(ResourceLocation id, String variant) { - public ModelResourceLocation(ResourceLocation id, String variant) { - variant = lowercaseVariant(variant); - this.id = id; - this.variant = variant; - } - - private static String lowercaseVariant(String variant) { - return variant.toLowerCase(Locale.ROOT); - } - - public String getVariant() { - return this.variant; - } - - public String toString() { - return this.id + "#" + this.variant; - } -} diff --git a/net/minecraft/client/resources/model/ModelState.java b/net/minecraft/client/resources/model/ModelState.java index 6eae0058..eed71157 100644 --- a/net/minecraft/client/resources/model/ModelState.java +++ b/net/minecraft/client/resources/model/ModelState.java @@ -3,14 +3,23 @@ package net.minecraft.client.resources.model; import com.mojang.math.Transformation; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.core.Direction; +import org.joml.Matrix4f; +import org.joml.Matrix4fc; @Environment(EnvType.CLIENT) public interface ModelState { - default Transformation getRotation() { + Matrix4fc NO_TRANSFORM = new Matrix4f(); + + default Transformation transformation() { return Transformation.identity(); } - default boolean isUvLocked() { - return false; + default Matrix4fc faceTransformation(Direction facing) { + return NO_TRANSFORM; + } + + default Matrix4fc inverseFaceTransformation(Direction facing) { + return NO_TRANSFORM; } } diff --git a/net/minecraft/client/resources/model/MultiPartBakedModel.java b/net/minecraft/client/resources/model/MultiPartBakedModel.java deleted file mode 100644 index 83952ba3..00000000 --- a/net/minecraft/client/resources/model/MultiPartBakedModel.java +++ /dev/null @@ -1,71 +0,0 @@ -package net.minecraft.client.resources.model; - -import it.unimi.dsi.fastutil.objects.Reference2ObjectOpenHashMap; -import java.util.ArrayList; -import java.util.BitSet; -import java.util.Collections; -import java.util.List; -import java.util.Map; -import java.util.function.Predicate; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.BakedQuad; -import net.minecraft.core.Direction; -import net.minecraft.util.RandomSource; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; - -@Environment(EnvType.CLIENT) -public class MultiPartBakedModel extends DelegateBakedModel { - private final List selectors; - private final Map selectorCache = new Reference2ObjectOpenHashMap<>(); - - private static BakedModel getFirstModel(List selectors) { - if (selectors.isEmpty()) { - throw new IllegalArgumentException("Model must have at least one selector"); - } else { - return ((MultiPartBakedModel.Selector)selectors.getFirst()).model(); - } - } - - public MultiPartBakedModel(List selectors) { - super(getFirstModel(selectors)); - this.selectors = selectors; - } - - @Override - public List getQuads(@Nullable BlockState state, @Nullable Direction direction, RandomSource random) { - if (state == null) { - return Collections.emptyList(); - } else { - BitSet bitSet = (BitSet)this.selectorCache.get(state); - if (bitSet == null) { - bitSet = new BitSet(); - - for (int i = 0; i < this.selectors.size(); i++) { - if (((MultiPartBakedModel.Selector)this.selectors.get(i)).condition.test(state)) { - bitSet.set(i); - } - } - - this.selectorCache.put(state, bitSet); - } - - List list = new ArrayList(); - long l = random.nextLong(); - - for (int j = 0; j < bitSet.length(); j++) { - if (bitSet.get(j)) { - random.setSeed(l); - list.addAll(((MultiPartBakedModel.Selector)this.selectors.get(j)).model.getQuads(state, direction, random)); - } - } - - return list; - } - } - - @Environment(EnvType.CLIENT) - public record Selector(Predicate condition, BakedModel model) { - } -} diff --git a/net/minecraft/client/resources/model/QuadCollection.java b/net/minecraft/client/resources/model/QuadCollection.java new file mode 100644 index 00000000..0bd5c7c5 --- /dev/null +++ b/net/minecraft/client/resources/model/QuadCollection.java @@ -0,0 +1,128 @@ +package net.minecraft.client.resources.model; + +import com.google.common.collect.ArrayListMultimap; +import com.google.common.collect.ImmutableList; +import com.google.common.collect.Multimap; +import java.util.Collection; +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.BakedQuad; +import net.minecraft.core.Direction; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public class QuadCollection { + public static final QuadCollection EMPTY = new QuadCollection(List.of(), List.of(), List.of(), List.of(), List.of(), List.of(), List.of(), List.of()); + private final List all; + private final List unculled; + private final List north; + private final List south; + private final List east; + private final List west; + private final List up; + private final List down; + + QuadCollection( + List all, + List unculled, + List north, + List south, + List east, + List west, + List up, + List down + ) { + this.all = all; + this.unculled = unculled; + this.north = north; + this.south = south; + this.east = east; + this.west = west; + this.up = up; + this.down = down; + } + + public List getQuads(@Nullable Direction direction) { + return switch (direction) { + case null -> this.unculled; + case NORTH -> this.north; + case SOUTH -> this.south; + case EAST -> this.east; + case WEST -> this.west; + case UP -> this.up; + case DOWN -> this.down; + }; + } + + public List getAll() { + return this.all; + } + + @Environment(EnvType.CLIENT) + public static class Builder { + private final ImmutableList.Builder unculledFaces = ImmutableList.builder(); + private final Multimap culledFaces = ArrayListMultimap.create(); + + public QuadCollection.Builder addCulledFace(Direction direction, BakedQuad quad) { + this.culledFaces.put(direction, quad); + return this; + } + + public QuadCollection.Builder addUnculledFace(BakedQuad quad) { + this.unculledFaces.add(quad); + return this; + } + + private static QuadCollection createFromSublists( + List quads, int unculledSize, int northSize, int southSize, int eastSize, int westSize, int upSize, int downSize + ) { + int i = 0; + int var16; + List list = quads.subList(i, var16 = i + unculledSize); + List list2 = quads.subList(var16, i = var16 + northSize); + int var18; + List list3 = quads.subList(i, var18 = i + southSize); + List list4 = quads.subList(var18, i = var18 + eastSize); + int var20; + List list5 = quads.subList(i, var20 = i + westSize); + List list6 = quads.subList(var20, i = var20 + upSize); + List list7 = quads.subList(i, i + downSize); + return new QuadCollection(quads, list, list2, list3, list4, list5, list6, list7); + } + + public QuadCollection build() { + ImmutableList immutableList = this.unculledFaces.build(); + if (this.culledFaces.isEmpty()) { + return immutableList.isEmpty() + ? QuadCollection.EMPTY + : new QuadCollection(immutableList, immutableList, List.of(), List.of(), List.of(), List.of(), List.of(), List.of()); + } else { + ImmutableList.Builder builder = ImmutableList.builder(); + builder.addAll(immutableList); + Collection collection = this.culledFaces.get(Direction.NORTH); + builder.addAll(collection); + Collection collection2 = this.culledFaces.get(Direction.SOUTH); + builder.addAll(collection2); + Collection collection3 = this.culledFaces.get(Direction.EAST); + builder.addAll(collection3); + Collection collection4 = this.culledFaces.get(Direction.WEST); + builder.addAll(collection4); + Collection collection5 = this.culledFaces.get(Direction.UP); + builder.addAll(collection5); + Collection collection6 = this.culledFaces.get(Direction.DOWN); + builder.addAll(collection6); + return createFromSublists( + builder.build(), + immutableList.size(), + collection.size(), + collection2.size(), + collection3.size(), + collection4.size(), + collection5.size(), + collection6.size() + ); + } + } + } +} diff --git a/net/minecraft/client/resources/model/ResolvableModel.java b/net/minecraft/client/resources/model/ResolvableModel.java index 4e6f60dd..bc2beab7 100644 --- a/net/minecraft/client/resources/model/ResolvableModel.java +++ b/net/minecraft/client/resources/model/ResolvableModel.java @@ -10,6 +10,6 @@ public interface ResolvableModel { @Environment(EnvType.CLIENT) public interface Resolver { - UnbakedModel resolve(ResourceLocation model); + void markDependency(ResourceLocation resourceLocation); } } diff --git a/net/minecraft/client/resources/model/ResolvedModel.java b/net/minecraft/client/resources/model/ResolvedModel.java new file mode 100644 index 00000000..855b1c4b --- /dev/null +++ b/net/minecraft/client/resources/model/ResolvedModel.java @@ -0,0 +1,131 @@ +package net.minecraft.client.resources.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.ItemTransform; +import net.minecraft.client.renderer.block.model.ItemTransforms; +import net.minecraft.client.renderer.block.model.TextureSlots; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.world.item.ItemDisplayContext; +import org.jetbrains.annotations.Nullable; + +@Environment(EnvType.CLIENT) +public interface ResolvedModel extends ModelDebugName { + boolean DEFAULT_AMBIENT_OCCLUSION = true; + UnbakedModel.GuiLight DEFAULT_GUI_LIGHT = UnbakedModel.GuiLight.SIDE; + + UnbakedModel wrapped(); + + @Nullable + ResolvedModel parent(); + + static TextureSlots findTopTextureSlots(ResolvedModel model) { + ResolvedModel resolvedModel = model; + + TextureSlots.Resolver resolver; + for (resolver = new TextureSlots.Resolver(); resolvedModel != null; resolvedModel = resolvedModel.parent()) { + resolver.addLast(resolvedModel.wrapped().textureSlots()); + } + + return resolver.resolve(model); + } + + default TextureSlots getTopTextureSlots() { + return findTopTextureSlots(this); + } + + static boolean findTopAmbientOcclusion(ResolvedModel model) { + while (model != null) { + Boolean boolean_ = model.wrapped().ambientOcclusion(); + if (boolean_ != null) { + return boolean_; + } + + model = model.parent(); + } + + return true; + } + + default boolean getTopAmbientOcclusion() { + return findTopAmbientOcclusion(this); + } + + static UnbakedModel.GuiLight findTopGuiLight(ResolvedModel model) { + while (model != null) { + UnbakedModel.GuiLight guiLight = model.wrapped().guiLight(); + if (guiLight != null) { + return guiLight; + } + + model = model.parent(); + } + + return DEFAULT_GUI_LIGHT; + } + + default UnbakedModel.GuiLight getTopGuiLight() { + return findTopGuiLight(this); + } + + static UnbakedGeometry findTopGeometry(ResolvedModel model) { + while (model != null) { + UnbakedGeometry unbakedGeometry = model.wrapped().geometry(); + if (unbakedGeometry != null) { + return unbakedGeometry; + } + + model = model.parent(); + } + + return UnbakedGeometry.EMPTY; + } + + default UnbakedGeometry getTopGeometry() { + return findTopGeometry(this); + } + + default QuadCollection bakeTopGeometry(TextureSlots textureSlots, ModelBaker modelBaker, ModelState modelState) { + return this.getTopGeometry().bake(textureSlots, modelBaker, modelState, this); + } + + static TextureAtlasSprite resolveParticleSprite(TextureSlots textureSlots, ModelBaker modelBaker, ModelDebugName debugName) { + return modelBaker.sprites().resolveSlot(textureSlots, "particle", debugName); + } + + default TextureAtlasSprite resolveParticleSprite(TextureSlots textureSlots, ModelBaker modelBaker) { + return resolveParticleSprite(textureSlots, modelBaker, this); + } + + static ItemTransform findTopTransform(ResolvedModel model, ItemDisplayContext displayContext) { + while (model != null) { + ItemTransforms itemTransforms = model.wrapped().transforms(); + if (itemTransforms != null) { + ItemTransform itemTransform = itemTransforms.getTransform(displayContext); + if (itemTransform != ItemTransform.NO_TRANSFORM) { + return itemTransform; + } + } + + model = model.parent(); + } + + return ItemTransform.NO_TRANSFORM; + } + + static ItemTransforms findTopTransforms(ResolvedModel model) { + ItemTransform itemTransform = findTopTransform(model, ItemDisplayContext.THIRD_PERSON_LEFT_HAND); + ItemTransform itemTransform2 = findTopTransform(model, ItemDisplayContext.THIRD_PERSON_RIGHT_HAND); + ItemTransform itemTransform3 = findTopTransform(model, ItemDisplayContext.FIRST_PERSON_LEFT_HAND); + ItemTransform itemTransform4 = findTopTransform(model, ItemDisplayContext.FIRST_PERSON_RIGHT_HAND); + ItemTransform itemTransform5 = findTopTransform(model, ItemDisplayContext.HEAD); + ItemTransform itemTransform6 = findTopTransform(model, ItemDisplayContext.GUI); + ItemTransform itemTransform7 = findTopTransform(model, ItemDisplayContext.GROUND); + ItemTransform itemTransform8 = findTopTransform(model, ItemDisplayContext.FIXED); + return new ItemTransforms(itemTransform, itemTransform2, itemTransform3, itemTransform4, itemTransform5, itemTransform6, itemTransform7, itemTransform8); + } + + default ItemTransforms getTopTransforms() { + return findTopTransforms(this); + } +} diff --git a/net/minecraft/client/resources/model/SimpleBakedModel.java b/net/minecraft/client/resources/model/SimpleBakedModel.java deleted file mode 100644 index 389c5c5e..00000000 --- a/net/minecraft/client/resources/model/SimpleBakedModel.java +++ /dev/null @@ -1,173 +0,0 @@ -package net.minecraft.client.resources.model; - -import com.google.common.collect.ImmutableList; -import com.google.common.collect.Maps; -import java.util.EnumMap; -import java.util.List; -import java.util.Map; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.BakedQuad; -import net.minecraft.client.renderer.block.model.BlockElement; -import net.minecraft.client.renderer.block.model.BlockElementFace; -import net.minecraft.client.renderer.block.model.FaceBakery; -import net.minecraft.client.renderer.block.model.ItemTransforms; -import net.minecraft.client.renderer.block.model.TextureSlots; -import net.minecraft.client.renderer.texture.TextureAtlasSprite; -import net.minecraft.core.Direction; -import net.minecraft.util.RandomSource; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; - -@Environment(EnvType.CLIENT) -public class SimpleBakedModel implements BakedModel { - public static final String PARTICLE_TEXTURE_REFERENCE = "particle"; - private final List unculledFaces; - private final Map> culledFaces; - private final boolean hasAmbientOcclusion; - private final boolean isGui3d; - private final boolean usesBlockLight; - private final TextureAtlasSprite particleIcon; - private final ItemTransforms transforms; - - public SimpleBakedModel( - List unculledFaces, - Map> culledFaces, - boolean hasAmbientOcclusion, - boolean useBlockLight, - boolean isGui3d, - TextureAtlasSprite particleIcon, - ItemTransforms transforms - ) { - this.unculledFaces = unculledFaces; - this.culledFaces = culledFaces; - this.hasAmbientOcclusion = hasAmbientOcclusion; - this.isGui3d = isGui3d; - this.usesBlockLight = useBlockLight; - this.particleIcon = particleIcon; - this.transforms = transforms; - } - - public static BakedModel bakeElements( - List elements, - TextureSlots textureSlots, - SpriteGetter spriteGetter, - ModelState modelState, - boolean hasAmbientOcclusion, - boolean useBlockLight, - boolean isGui3d, - ItemTransforms transforms - ) { - TextureAtlasSprite textureAtlasSprite = findSprite(spriteGetter, textureSlots, "particle"); - SimpleBakedModel.Builder builder = new SimpleBakedModel.Builder(hasAmbientOcclusion, useBlockLight, isGui3d, transforms).particle(textureAtlasSprite); - - for (BlockElement blockElement : elements) { - for (Direction direction : blockElement.faces.keySet()) { - BlockElementFace blockElementFace = (BlockElementFace)blockElement.faces.get(direction); - TextureAtlasSprite textureAtlasSprite2 = findSprite(spriteGetter, textureSlots, blockElementFace.texture()); - if (blockElementFace.cullForDirection() == null) { - builder.addUnculledFace(bakeFace(blockElement, blockElementFace, textureAtlasSprite2, direction, modelState)); - } else { - builder.addCulledFace( - Direction.rotate(modelState.getRotation().getMatrix(), blockElementFace.cullForDirection()), - bakeFace(blockElement, blockElementFace, textureAtlasSprite2, direction, modelState) - ); - } - } - } - - return builder.build(); - } - - private static BakedQuad bakeFace(BlockElement element, BlockElementFace face, TextureAtlasSprite sprite, Direction facing, ModelState transform) { - return FaceBakery.bakeQuad(element.from, element.to, face, sprite, facing, transform, element.rotation, element.shade, element.lightEmission); - } - - private static TextureAtlasSprite findSprite(SpriteGetter spriteGetter, TextureSlots textureSlots, String material) { - Material material2 = textureSlots.getMaterial(material); - return material2 != null ? spriteGetter.get(material2) : spriteGetter.reportMissingReference(material); - } - - @Override - public List getQuads(@Nullable BlockState state, @Nullable Direction direction, RandomSource random) { - return direction == null ? this.unculledFaces : (List)this.culledFaces.get(direction); - } - - @Override - public boolean useAmbientOcclusion() { - return this.hasAmbientOcclusion; - } - - @Override - public boolean isGui3d() { - return this.isGui3d; - } - - @Override - public boolean usesBlockLight() { - return this.usesBlockLight; - } - - @Override - public TextureAtlasSprite getParticleIcon() { - return this.particleIcon; - } - - @Override - public ItemTransforms getTransforms() { - return this.transforms; - } - - @Environment(EnvType.CLIENT) - public static class Builder { - private final ImmutableList.Builder unculledFaces = ImmutableList.builder(); - private final EnumMap> culledFaces = Maps.newEnumMap(Direction.class); - private final boolean hasAmbientOcclusion; - @Nullable - private TextureAtlasSprite particleIcon; - private final boolean usesBlockLight; - private final boolean isGui3d; - private final ItemTransforms transforms; - - public Builder(boolean hasAmbientOcclusion, boolean useBlockLight, boolean isGui3d, ItemTransforms transforms) { - this.hasAmbientOcclusion = hasAmbientOcclusion; - this.usesBlockLight = useBlockLight; - this.isGui3d = isGui3d; - this.transforms = transforms; - - for (Direction direction : Direction.values()) { - this.culledFaces.put(direction, ImmutableList.builder()); - } - } - - public SimpleBakedModel.Builder addCulledFace(Direction facing, BakedQuad quad) { - ((ImmutableList.Builder)this.culledFaces.get(facing)).add(quad); - return this; - } - - public SimpleBakedModel.Builder addUnculledFace(BakedQuad quad) { - this.unculledFaces.add(quad); - return this; - } - - public SimpleBakedModel.Builder particle(TextureAtlasSprite particleIcon) { - this.particleIcon = particleIcon; - return this; - } - - public SimpleBakedModel.Builder item() { - return this; - } - - public BakedModel build() { - if (this.particleIcon == null) { - throw new RuntimeException("Missing particle!"); - } else { - Map> map = Maps.transformValues(this.culledFaces, ImmutableList.Builder::build); - return new SimpleBakedModel( - this.unculledFaces.build(), new EnumMap(map), this.hasAmbientOcclusion, this.usesBlockLight, this.isGui3d, this.particleIcon, this.transforms - ); - } - } - } -} diff --git a/net/minecraft/client/resources/model/SpriteGetter.java b/net/minecraft/client/resources/model/SpriteGetter.java index fff29a4d..3e43bf79 100644 --- a/net/minecraft/client/resources/model/SpriteGetter.java +++ b/net/minecraft/client/resources/model/SpriteGetter.java @@ -2,11 +2,17 @@ package net.minecraft.client.resources.model; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.TextureSlots; import net.minecraft.client.renderer.texture.TextureAtlasSprite; @Environment(EnvType.CLIENT) public interface SpriteGetter { - TextureAtlasSprite get(Material material); + TextureAtlasSprite get(Material material, ModelDebugName debugName); - TextureAtlasSprite reportMissingReference(String reference); + TextureAtlasSprite reportMissingReference(String name, ModelDebugName debugName); + + default TextureAtlasSprite resolveSlot(TextureSlots textureSlots, String name, ModelDebugName modelDebugName) { + Material material = textureSlots.getMaterial(name); + return material != null ? this.get(material, modelDebugName) : this.reportMissingReference(name, modelDebugName); + } } diff --git a/net/minecraft/client/resources/model/UnbakedGeometry.java b/net/minecraft/client/resources/model/UnbakedGeometry.java new file mode 100644 index 00000000..5cccd44b --- /dev/null +++ b/net/minecraft/client/resources/model/UnbakedGeometry.java @@ -0,0 +1,13 @@ +package net.minecraft.client.resources.model; + +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.TextureSlots; + +@FunctionalInterface +@Environment(EnvType.CLIENT) +public interface UnbakedGeometry { + UnbakedGeometry EMPTY = (textureSlots, modelBaker, modelState, modelDebugName) -> QuadCollection.EMPTY; + + QuadCollection bake(TextureSlots textureSlots, ModelBaker modelBaker, ModelState modelState, ModelDebugName modelDebugName); +} diff --git a/net/minecraft/client/resources/model/UnbakedModel.java b/net/minecraft/client/resources/model/UnbakedModel.java index e1e1174c..26d51f55 100644 --- a/net/minecraft/client/resources/model/UnbakedModel.java +++ b/net/minecraft/client/resources/model/UnbakedModel.java @@ -2,116 +2,42 @@ package net.minecraft.client.resources.model; import net.fabricmc.api.EnvType; import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.ItemTransform; import net.minecraft.client.renderer.block.model.ItemTransforms; import net.minecraft.client.renderer.block.model.TextureSlots; -import net.minecraft.world.item.ItemDisplayContext; +import net.minecraft.resources.ResourceLocation; import org.jetbrains.annotations.Nullable; @Environment(EnvType.CLIENT) -public interface UnbakedModel extends ResolvableModel { - boolean DEFAULT_AMBIENT_OCCLUSION = true; - UnbakedModel.GuiLight DEFAULT_GUI_LIGHT = UnbakedModel.GuiLight.SIDE; - - BakedModel bake( - TextureSlots textureSlots, ModelBaker baker, ModelState modelState, boolean hasAmbientOcclusion, boolean useBlockLight, ItemTransforms transforms - ); +public interface UnbakedModel { + String PARTICLE_TEXTURE_REFERENCE = "particle"; @Nullable - default Boolean getAmbientOcclusion() { + default Boolean ambientOcclusion() { return null; } @Nullable - default UnbakedModel.GuiLight getGuiLight() { + default UnbakedModel.GuiLight guiLight() { return null; } @Nullable - default ItemTransforms getTransforms() { + default ItemTransforms transforms() { return null; } - default TextureSlots.Data getTextureSlots() { + default TextureSlots.Data textureSlots() { return TextureSlots.Data.EMPTY; } @Nullable - default UnbakedModel getParent() { + default UnbakedGeometry geometry() { return null; } - static BakedModel bakeWithTopModelValues(UnbakedModel model, ModelBaker baker, ModelState modelState) { - TextureSlots textureSlots = getTopTextureSlots(model, baker.rootName()); - boolean bl = getTopAmbientOcclusion(model); - boolean bl2 = getTopGuiLight(model).lightLikeBlock(); - ItemTransforms itemTransforms = getTopTransforms(model); - return model.bake(textureSlots, baker, modelState, bl, bl2, itemTransforms); - } - - static TextureSlots getTopTextureSlots(UnbakedModel model, ModelDebugName name) { - TextureSlots.Resolver resolver = new TextureSlots.Resolver(); - - while (model != null) { - resolver.addLast(model.getTextureSlots()); - model = model.getParent(); - } - - return resolver.resolve(name); - } - - static boolean getTopAmbientOcclusion(UnbakedModel model) { - while (model != null) { - Boolean boolean_ = model.getAmbientOcclusion(); - if (boolean_ != null) { - return boolean_; - } - - model = model.getParent(); - } - - return true; - } - - static UnbakedModel.GuiLight getTopGuiLight(UnbakedModel model) { - while (model != null) { - UnbakedModel.GuiLight guiLight = model.getGuiLight(); - if (guiLight != null) { - return guiLight; - } - - model = model.getParent(); - } - - return DEFAULT_GUI_LIGHT; - } - - static ItemTransform getTopTransform(UnbakedModel model, ItemDisplayContext displayContext) { - while (model != null) { - ItemTransforms itemTransforms = model.getTransforms(); - if (itemTransforms != null) { - ItemTransform itemTransform = itemTransforms.getTransform(displayContext); - if (itemTransform != ItemTransform.NO_TRANSFORM) { - return itemTransform; - } - } - - model = model.getParent(); - } - - return ItemTransform.NO_TRANSFORM; - } - - static ItemTransforms getTopTransforms(UnbakedModel unbakedModel) { - ItemTransform itemTransform = getTopTransform(unbakedModel, ItemDisplayContext.THIRD_PERSON_LEFT_HAND); - ItemTransform itemTransform2 = getTopTransform(unbakedModel, ItemDisplayContext.THIRD_PERSON_RIGHT_HAND); - ItemTransform itemTransform3 = getTopTransform(unbakedModel, ItemDisplayContext.FIRST_PERSON_LEFT_HAND); - ItemTransform itemTransform4 = getTopTransform(unbakedModel, ItemDisplayContext.FIRST_PERSON_RIGHT_HAND); - ItemTransform itemTransform5 = getTopTransform(unbakedModel, ItemDisplayContext.HEAD); - ItemTransform itemTransform6 = getTopTransform(unbakedModel, ItemDisplayContext.GUI); - ItemTransform itemTransform7 = getTopTransform(unbakedModel, ItemDisplayContext.GROUND); - ItemTransform itemTransform8 = getTopTransform(unbakedModel, ItemDisplayContext.FIXED); - return new ItemTransforms(itemTransform, itemTransform2, itemTransform3, itemTransform4, itemTransform5, itemTransform6, itemTransform7, itemTransform8); + @Nullable + default ResourceLocation parent() { + return null; } @Environment(EnvType.CLIENT) diff --git a/net/minecraft/client/resources/model/WeightedBakedModel.java b/net/minecraft/client/resources/model/WeightedBakedModel.java deleted file mode 100644 index c954b60f..00000000 --- a/net/minecraft/client/resources/model/WeightedBakedModel.java +++ /dev/null @@ -1,28 +0,0 @@ -package net.minecraft.client.resources.model; - -import java.util.Collections; -import java.util.List; -import net.fabricmc.api.EnvType; -import net.fabricmc.api.Environment; -import net.minecraft.client.renderer.block.model.BakedQuad; -import net.minecraft.core.Direction; -import net.minecraft.util.RandomSource; -import net.minecraft.util.random.SimpleWeightedRandomList; -import net.minecraft.util.random.WeightedEntry.Wrapper; -import net.minecraft.world.level.block.state.BlockState; -import org.jetbrains.annotations.Nullable; - -@Environment(EnvType.CLIENT) -public class WeightedBakedModel extends DelegateBakedModel { - private final SimpleWeightedRandomList list; - - public WeightedBakedModel(SimpleWeightedRandomList list) { - super((BakedModel)((Wrapper)list.unwrap().getFirst()).data()); - this.list = list; - } - - @Override - public List getQuads(@Nullable BlockState state, @Nullable Direction direction, RandomSource random) { - return (List)this.list.getRandomValue(random).map(bakedModel -> bakedModel.getQuads(state, direction, random)).orElse(Collections.emptyList()); - } -} diff --git a/net/minecraft/client/resources/model/WeightedVariants.java b/net/minecraft/client/resources/model/WeightedVariants.java new file mode 100644 index 00000000..0b8999af --- /dev/null +++ b/net/minecraft/client/resources/model/WeightedVariants.java @@ -0,0 +1,46 @@ +package net.minecraft.client.resources.model; + +import java.util.List; +import net.fabricmc.api.EnvType; +import net.fabricmc.api.Environment; +import net.minecraft.client.renderer.block.model.BlockModelPart; +import net.minecraft.client.renderer.block.model.BlockStateModel; +import net.minecraft.client.renderer.texture.TextureAtlasSprite; +import net.minecraft.util.RandomSource; +import net.minecraft.util.random.Weighted; +import net.minecraft.util.random.WeightedList; + +@Environment(EnvType.CLIENT) +public class WeightedVariants implements BlockStateModel { + private final WeightedList list; + private final TextureAtlasSprite particleIcon; + + public WeightedVariants(WeightedList list) { + this.list = list; + BlockStateModel blockStateModel = (BlockStateModel)((Weighted)list.unwrap().getFirst()).value(); + this.particleIcon = blockStateModel.particleIcon(); + } + + @Override + public TextureAtlasSprite particleIcon() { + return this.particleIcon; + } + + @Override + public void collectParts(RandomSource random, List output) { + this.list.getRandomOrThrow(random).collectParts(random, output); + } + + @Environment(EnvType.CLIENT) + public record Unbaked(WeightedList entries) implements BlockStateModel.Unbaked { + @Override + public BlockStateModel bake(ModelBaker baker) { + return new WeightedVariants(this.entries.map(unbaked -> unbaked.bake(baker))); + } + + @Override + public void resolveDependencies(ResolvableModel.Resolver resolver) { + this.entries.unwrap().forEach(weighted -> ((BlockStateModel.Unbaked)weighted.value()).resolveDependencies(resolver)); + } + } +} diff --git a/net/minecraft/client/server/IntegratedServer.java b/net/minecraft/client/server/IntegratedServer.java index 42e00d4d..72d26963 100644 --- a/net/minecraft/client/server/IntegratedServer.java +++ b/net/minecraft/client/server/IntegratedServer.java @@ -30,7 +30,7 @@ import net.minecraft.util.profiling.ProfilerFiller; import net.minecraft.world.level.ChunkPos; import net.minecraft.world.level.GameType; import net.minecraft.world.level.chunk.storage.RegionStorageInfo; -import net.minecraft.world.level.storage.LevelStorageSource.LevelStorageAccess; +import net.minecraft.world.level.storage.LevelStorageSource; import org.jetbrains.annotations.Nullable; import org.slf4j.Logger; @@ -52,7 +52,7 @@ public class IntegratedServer extends MinecraftServer { public IntegratedServer( Thread serverThread, Minecraft minecraft, - LevelStorageAccess storageSource, + LevelStorageSource.LevelStorageAccess storageSource, PackRepository packRepository, WorldStem worldStem, Services services, diff --git a/net/minecraft/commands/Commands.java b/net/minecraft/commands/Commands.java index a3568744..c08df217 100644 --- a/net/minecraft/commands/Commands.java +++ b/net/minecraft/commands/Commands.java @@ -207,6 +207,7 @@ public class Commands { TeamMsgCommand.register(this.dispatcher); TeleportCommand.register(this.dispatcher); TellRawCommand.register(this.dispatcher, context); + TestCommand.register(this.dispatcher, context); TickCommand.register(this.dispatcher); TimeCommand.register(this.dispatcher); TitleCommand.register(this.dispatcher, context); @@ -218,7 +219,6 @@ public class Commands { } if (SharedConstants.IS_RUNNING_IN_IDE) { - TestCommand.register(this.dispatcher); RaidCommand.register(this.dispatcher, context); DebugPathCommand.register(this.dispatcher); DebugMobSpawningCommand.register(this.dispatcher); @@ -294,9 +294,7 @@ public class Commands { } } - commandSourceStack.sendFailure( - Component.translatable("command.failed").withStyle(style -> style.withHoverEvent(new HoverEvent(HoverEvent.Action.SHOW_TEXT, mutableComponent))) - ); + commandSourceStack.sendFailure(Component.translatable("command.failed").withStyle(style -> style.withHoverEvent(new HoverEvent.ShowText(mutableComponent)))); if (SharedConstants.IS_RUNNING_IN_IDE) { commandSourceStack.sendFailure(Component.literal(Util.describeError(var12))); LOGGER.error("'/{}' threw an exception", command, var12); @@ -318,7 +316,7 @@ public class Commands { int i = Math.min(var7.getInput().length(), var7.getCursor()); MutableComponent mutableComponent = Component.empty() .withStyle(ChatFormatting.GRAY) - .withStyle(style -> style.withClickEvent(new ClickEvent(ClickEvent.Action.SUGGEST_COMMAND, "/" + command))); + .withStyle(style -> style.withClickEvent(new ClickEvent.SuggestCommand("/" + command))); if (i > 10) { mutableComponent.append(CommonComponents.ELLIPSIS); } diff --git a/net/minecraft/commands/ParserUtils.java b/net/minecraft/commands/ParserUtils.java index 7d15583b..72db2237 100644 --- a/net/minecraft/commands/ParserUtils.java +++ b/net/minecraft/commands/ParserUtils.java @@ -1,62 +1,9 @@ package net.minecraft.commands; -import com.google.gson.JsonElement; -import com.google.gson.JsonParseException; -import com.google.gson.internal.Streams; -import com.google.gson.stream.JsonReader; import com.mojang.brigadier.StringReader; -import com.mojang.serialization.Codec; -import com.mojang.serialization.JsonOps; -import java.lang.reflect.Field; import net.minecraft.CharPredicate; -import net.minecraft.Util; -import net.minecraft.core.HolderLookup; public class ParserUtils { - private static final Field JSON_READER_POS = Util.make(() -> { - try { - Field field = JsonReader.class.getDeclaredField("pos"); - field.setAccessible(true); - return field; - } catch (NoSuchFieldException var1) { - throw new IllegalStateException("Couldn't get field 'pos' for JsonReader", var1); - } - }); - private static final Field JSON_READER_LINESTART = Util.make(() -> { - try { - Field field = JsonReader.class.getDeclaredField("lineStart"); - field.setAccessible(true); - return field; - } catch (NoSuchFieldException var1) { - throw new IllegalStateException("Couldn't get field 'lineStart' for JsonReader", var1); - } - }); - - private static int getPos(JsonReader reader) { - try { - return JSON_READER_POS.getInt(reader) - JSON_READER_LINESTART.getInt(reader); - } catch (IllegalAccessException var2) { - throw new IllegalStateException("Couldn't read position of JsonReader", var2); - } - } - - public static T parseJson(HolderLookup.Provider registries, StringReader reader, Codec codec) { - JsonReader jsonReader = new JsonReader(new java.io.StringReader(reader.getRemaining())); - jsonReader.setLenient(false); - - Object var5; - try { - JsonElement jsonElement = Streams.parse(jsonReader); - var5 = codec.parse(registries.createSerializationContext(JsonOps.INSTANCE), jsonElement).getOrThrow(JsonParseException::new); - } catch (StackOverflowError var9) { - throw new JsonParseException(var9); - } finally { - reader.setCursor(reader.getCursor() + getPos(jsonReader)); - } - - return (T)var5; - } - public static String readWhile(StringReader reader, CharPredicate predicate) { int i = reader.getCursor(); diff --git a/net/minecraft/commands/arguments/ComponentArgument.java b/net/minecraft/commands/arguments/ComponentArgument.java index 95f9589a..270f69c3 100644 --- a/net/minecraft/commands/arguments/ComponentArgument.java +++ b/net/minecraft/commands/arguments/ComponentArgument.java @@ -1,47 +1,53 @@ package net.minecraft.commands.arguments; -import com.mojang.brigadier.StringReader; -import com.mojang.brigadier.arguments.ArgumentType; import com.mojang.brigadier.context.CommandContext; import com.mojang.brigadier.exceptions.CommandSyntaxException; import com.mojang.brigadier.exceptions.DynamicCommandExceptionType; +import com.mojang.serialization.DynamicOps; import java.util.Arrays; import java.util.Collection; import net.minecraft.commands.CommandBuildContext; import net.minecraft.commands.CommandSourceStack; -import net.minecraft.commands.ParserUtils; import net.minecraft.core.HolderLookup; +import net.minecraft.nbt.NbtOps; +import net.minecraft.nbt.SnbtGrammar; +import net.minecraft.nbt.Tag; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.ComponentSerialization; +import net.minecraft.network.chat.ComponentUtils; +import net.minecraft.util.parsing.packrat.commands.CommandArgumentParser; +import net.minecraft.util.parsing.packrat.commands.ParserBasedArgument; +import net.minecraft.world.entity.Entity; +import org.jetbrains.annotations.Nullable; -public class ComponentArgument implements ArgumentType { - private static final Collection EXAMPLES = Arrays.asList("\"hello world\"", "\"\"", "\"{\"text\":\"hello world\"}", "[\"\"]"); - public static final DynamicCommandExceptionType ERROR_INVALID_JSON = new DynamicCommandExceptionType( +public class ComponentArgument extends ParserBasedArgument { + private static final Collection EXAMPLES = Arrays.asList("\"hello world\"", "'hello world'", "\"\"", "{text:\"hello world\"}", "[\"\"]"); + public static final DynamicCommandExceptionType ERROR_INVALID_COMPONENT = new DynamicCommandExceptionType( object -> Component.translatableEscape("argument.component.invalid", object) ); - private final HolderLookup.Provider registries; + private static final DynamicOps OPS = NbtOps.INSTANCE; + private static final CommandArgumentParser TAG_PARSER = SnbtGrammar.createParser(OPS); private ComponentArgument(HolderLookup.Provider registries) { - this.registries = registries; + super(TAG_PARSER.withCodec(registries.createSerializationContext(OPS), TAG_PARSER, ComponentSerialization.CODEC, ERROR_INVALID_COMPONENT)); } - public static Component getComponent(CommandContext context, String name) { + public static Component getRawComponent(CommandContext context, String name) { return context.getArgument(name, Component.class); } + public static Component getResolvedComponent(CommandContext context, String name, @Nullable Entity entity) throws CommandSyntaxException { + return ComponentUtils.updateForEntity(context.getSource(), getRawComponent(context, name), entity, 0); + } + + public static Component getResolvedComponent(CommandContext context, String name) throws CommandSyntaxException { + return getResolvedComponent(context, name, context.getSource().getEntity()); + } + public static ComponentArgument textComponent(CommandBuildContext context) { return new ComponentArgument(context); } - public Component parse(StringReader reader) throws CommandSyntaxException { - try { - return ParserUtils.parseJson(this.registries, reader, ComponentSerialization.CODEC); - } catch (Exception var4) { - String string = var4.getCause() != null ? var4.getCause().getMessage() : var4.getMessage(); - throw ERROR_INVALID_JSON.createWithContext(reader, string); - } - } - @Override public Collection getExamples() { return EXAMPLES; diff --git a/net/minecraft/commands/arguments/CompoundTagArgument.java b/net/minecraft/commands/arguments/CompoundTagArgument.java index 27d820c1..597aef57 100644 --- a/net/minecraft/commands/arguments/CompoundTagArgument.java +++ b/net/minecraft/commands/arguments/CompoundTagArgument.java @@ -24,7 +24,7 @@ public class CompoundTagArgument implements ArgumentType { } public CompoundTag parse(StringReader reader) throws CommandSyntaxException { - return new TagParser(reader).readStruct(); + return TagParser.parseCompoundAsArgument(reader); } @Override diff --git a/net/minecraft/commands/arguments/NbtPathArgument.java b/net/minecraft/commands/arguments/NbtPathArgument.java index 8686163f..ec74af70 100644 --- a/net/minecraft/commands/arguments/NbtPathArgument.java +++ b/net/minecraft/commands/arguments/NbtPathArgument.java @@ -1,5 +1,6 @@ package net.minecraft.commands.arguments; +import com.google.common.collect.Iterables; import com.google.common.collect.Lists; import com.mojang.brigadier.StringReader; import com.mojang.brigadier.arguments.ArgumentType; @@ -89,7 +90,7 @@ public class NbtPathArgument implements ArgumentType { reader.skip(); int i = reader.peek(); if (i == 123) { - CompoundTag compoundTag2 = new TagParser(reader).readStruct(); + CompoundTag compoundTag2 = TagParser.parseCompoundAsArgument(reader); reader.expect(']'); yield new NbtPathArgument.MatchElementNode(compoundTag2); } else if (i == 93) { @@ -106,7 +107,7 @@ public class NbtPathArgument implements ArgumentType { throw ERROR_INVALID_NODE.createWithContext(reader); } - CompoundTag compoundTag = new TagParser(reader).readStruct(); + CompoundTag compoundTag = TagParser.parseCompoundAsArgument(reader); yield new NbtPathArgument.MatchRootObjectNode(compoundTag); } default -> readObjectNode(reader, readUnquotedName(reader)); @@ -114,8 +115,10 @@ public class NbtPathArgument implements ArgumentType { } private static NbtPathArgument.Node readObjectNode(StringReader reader, String name) throws CommandSyntaxException { - if (reader.canRead() && reader.peek() == '{') { - CompoundTag compoundTag = new TagParser(reader).readStruct(); + if (name.isEmpty()) { + throw ERROR_INVALID_NODE.createWithContext(reader); + } else if (reader.canRead() && reader.peek() == '{') { + CompoundTag compoundTag = TagParser.parseCompoundAsArgument(reader); return new NbtPathArgument.MatchObjectNode(name, compoundTag); } else { return new NbtPathArgument.CompoundChildNode(name); @@ -163,21 +166,21 @@ public class NbtPathArgument implements ArgumentType { @Override public void getTag(Tag tag, List tags) { - if (tag instanceof CollectionTag) { - tags.addAll((CollectionTag)tag); + if (tag instanceof CollectionTag collectionTag) { + Iterables.addAll(tags, collectionTag); } } @Override public void getOrCreateTag(Tag tag, Supplier supplier, List tags) { - if (tag instanceof CollectionTag collectionTag) { + if (tag instanceof CollectionTag collectionTag) { if (collectionTag.isEmpty()) { Tag tag2 = (Tag)supplier.get(); if (collectionTag.addTag(0, tag2)) { tags.add(tag2); } } else { - tags.addAll(collectionTag); + Iterables.addAll(tags, collectionTag); } } } @@ -189,7 +192,7 @@ public class NbtPathArgument implements ArgumentType { @Override public int setTag(Tag tag, Supplier supplier) { - if (!(tag instanceof CollectionTag collectionTag)) { + if (!(tag instanceof CollectionTag collectionTag)) { return 0; } else { int i = collectionTag.size(); @@ -219,7 +222,7 @@ public class NbtPathArgument implements ArgumentType { @Override public int removeTag(Tag tag) { - if (tag instanceof CollectionTag collectionTag) { + if (tag instanceof CollectionTag collectionTag) { int i = collectionTag.size(); if (i > 0) { collectionTag.clear(); @@ -301,11 +304,11 @@ public class NbtPathArgument implements ArgumentType { @Override public void getTag(Tag tag, List tags) { - if (tag instanceof CollectionTag collectionTag) { + if (tag instanceof CollectionTag collectionTag) { int i = collectionTag.size(); int j = this.index < 0 ? i + this.index : this.index; if (0 <= j && j < i) { - tags.add((Tag)collectionTag.get(j)); + tags.add(collectionTag.get(j)); } } } @@ -322,11 +325,11 @@ public class NbtPathArgument implements ArgumentType { @Override public int setTag(Tag tag, Supplier supplier) { - if (tag instanceof CollectionTag collectionTag) { + if (tag instanceof CollectionTag collectionTag) { int i = collectionTag.size(); int j = this.index < 0 ? i + this.index : this.index; if (0 <= j && j < i) { - Tag tag2 = (Tag)collectionTag.get(j); + Tag tag2 = collectionTag.get(j); Tag tag3 = (Tag)supplier.get(); if (!tag3.equals(tag2) && collectionTag.setTag(j, tag3)) { return 1; @@ -339,7 +342,7 @@ public class NbtPathArgument implements ArgumentType { @Override public int removeTag(Tag tag) { - if (tag instanceof CollectionTag collectionTag) { + if (tag instanceof CollectionTag collectionTag) { int i = collectionTag.size(); int j = this.index < 0 ? i + this.index : this.index; if (0 <= j && j < i) { @@ -613,15 +616,14 @@ public class NbtPathArgument implements ArgumentType { return true; } else { if (tag instanceof CompoundTag compoundTag) { - for (String string : compoundTag.getAllKeys()) { - Tag tag2 = compoundTag.get(string); - if (tag2 != null && isTooDeep(tag2, currentDepth + 1)) { + for (Tag tag2 : compoundTag.values()) { + if (isTooDeep(tag2, currentDepth + 1)) { return true; } } } else if (tag instanceof ListTag) { - for (Tag tag3 : (ListTag)tag) { - if (isTooDeep(tag3, currentDepth + 1)) { + for (Tag tag2x : (ListTag)tag) { + if (isTooDeep(tag2x, currentDepth + 1)) { return true; } } @@ -674,7 +676,7 @@ public class NbtPathArgument implements ArgumentType { boolean bl = false; for (Tag tag3 : collection) { - if (!(tag3 instanceof CollectionTag collectionTag)) { + if (!(tag3 instanceof CollectionTag collectionTag)) { throw NbtPathArgument.ERROR_EXPECTED_LIST.create(tag3); } diff --git a/net/minecraft/commands/arguments/NbtTagArgument.java b/net/minecraft/commands/arguments/NbtTagArgument.java index 91fd1eeb..f5e63c58 100644 --- a/net/minecraft/commands/arguments/NbtTagArgument.java +++ b/net/minecraft/commands/arguments/NbtTagArgument.java @@ -1,18 +1,20 @@ package net.minecraft.commands.arguments; -import com.mojang.brigadier.StringReader; -import com.mojang.brigadier.arguments.ArgumentType; import com.mojang.brigadier.context.CommandContext; -import com.mojang.brigadier.exceptions.CommandSyntaxException; import java.util.Arrays; import java.util.Collection; +import net.minecraft.nbt.NbtOps; +import net.minecraft.nbt.SnbtGrammar; import net.minecraft.nbt.Tag; -import net.minecraft.nbt.TagParser; +import net.minecraft.util.parsing.packrat.commands.CommandArgumentParser; +import net.minecraft.util.parsing.packrat.commands.ParserBasedArgument; -public class NbtTagArgument implements ArgumentType { +public class NbtTagArgument extends ParserBasedArgument { private static final Collection EXAMPLES = Arrays.asList("0", "0b", "0l", "0.0", "\"foo\"", "{foo=bar}", "[0]"); + private static final CommandArgumentParser TAG_PARSER = SnbtGrammar.createParser(NbtOps.INSTANCE); private NbtTagArgument() { + super(TAG_PARSER); } public static NbtTagArgument nbtTag() { @@ -23,10 +25,6 @@ public class NbtTagArgument implements ArgumentType { return context.getArgument(name, Tag.class); } - public Tag parse(StringReader reader) throws CommandSyntaxException { - return new TagParser(reader).readValue(); - } - @Override public Collection getExamples() { return EXAMPLES; diff --git a/net/minecraft/commands/arguments/ParticleArgument.java b/net/minecraft/commands/arguments/ParticleArgument.java index db89a1b8..c05ad628 100644 --- a/net/minecraft/commands/arguments/ParticleArgument.java +++ b/net/minecraft/commands/arguments/ParticleArgument.java @@ -13,15 +13,15 @@ import java.util.concurrent.CompletableFuture; import net.minecraft.commands.CommandBuildContext; import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.SharedSuggestionProvider; -import net.minecraft.core.Holder; import net.minecraft.core.HolderLookup; +import net.minecraft.core.Holder.Reference; import net.minecraft.core.particles.ParticleOptions; import net.minecraft.core.particles.ParticleType; import net.minecraft.core.registries.Registries; -import net.minecraft.nbt.CompoundTag; import net.minecraft.nbt.NbtOps; import net.minecraft.nbt.TagParser; import net.minecraft.network.chat.Component; +import net.minecraft.resources.RegistryOps; import net.minecraft.resources.ResourceKey; import net.minecraft.resources.ResourceLocation; @@ -34,6 +34,7 @@ public class ParticleArgument implements ArgumentType { object -> Component.translatableEscape("particle.invalidOptions", object) ); private final HolderLookup.Provider registries; + private static final TagParser VALUE_PARSER = TagParser.create(NbtOps.INSTANCE); public ParticleArgument(CommandBuildContext buildContext) { this.registries = buildContext; @@ -58,26 +59,28 @@ public class ParticleArgument implements ArgumentType { public static ParticleOptions readParticle(StringReader reader, HolderLookup.Provider registries) throws CommandSyntaxException { ParticleType particleType = readParticleType(reader, registries.lookupOrThrow(Registries.PARTICLE_TYPE)); - return readParticle(reader, (ParticleType)particleType, registries); + return readParticle(VALUE_PARSER, reader, (ParticleType)particleType, registries); } private static ParticleType readParticleType(StringReader reader, HolderLookup> particleTypeLookup) throws CommandSyntaxException { ResourceLocation resourceLocation = ResourceLocation.read(reader); ResourceKey> resourceKey = ResourceKey.create(Registries.PARTICLE_TYPE, resourceLocation); - return (ParticleType)((Holder.Reference)particleTypeLookup.get(resourceKey) - .orElseThrow(() -> ERROR_UNKNOWN_PARTICLE.createWithContext(reader, resourceLocation))) + return (ParticleType)((Reference)particleTypeLookup.get(resourceKey).orElseThrow(() -> ERROR_UNKNOWN_PARTICLE.createWithContext(reader, resourceLocation))) .value(); } - private static T readParticle(StringReader reader, ParticleType particleType, HolderLookup.Provider registries) throws CommandSyntaxException { - CompoundTag compoundTag; + private static T readParticle( + TagParser parser, StringReader reader, ParticleType particleType, HolderLookup.Provider registries + ) throws CommandSyntaxException { + RegistryOps registryOps = registries.createSerializationContext(parser.getOps()); + O object; if (reader.canRead() && reader.peek() == '{') { - compoundTag = new TagParser(reader).readStruct(); + object = parser.parseAsArgument(reader); } else { - compoundTag = new CompoundTag(); + object = registryOps.emptyMap(); } - return particleType.codec().codec().parse(registries.createSerializationContext(NbtOps.INSTANCE), compoundTag).getOrThrow(ERROR_INVALID_OPTIONS::create); + return particleType.codec().codec().parse(registryOps, object).getOrThrow(ERROR_INVALID_OPTIONS::create); } @Override diff --git a/net/minecraft/commands/arguments/ResourceKeyArgument.java b/net/minecraft/commands/arguments/ResourceKeyArgument.java index 83e3dc81..934f85ba 100644 --- a/net/minecraft/commands/arguments/ResourceKeyArgument.java +++ b/net/minecraft/commands/arguments/ResourceKeyArgument.java @@ -16,6 +16,7 @@ import net.minecraft.advancements.Advancement; import net.minecraft.advancements.AdvancementHolder; import net.minecraft.commands.CommandSourceStack; import net.minecraft.commands.SharedSuggestionProvider; +import net.minecraft.commands.SharedSuggestionProvider.ElementSuggestionType; import net.minecraft.commands.synchronization.ArgumentTypeInfo; import net.minecraft.core.Registry; import net.minecraft.core.Holder.Reference; @@ -58,7 +59,7 @@ public class ResourceKeyArgument implements ArgumentType> { return new ResourceKeyArgument<>(registryKey); } - private static ResourceKey getRegistryKey( + public static ResourceKey getRegistryKey( CommandContext context, String argument, ResourceKey> registryKey, DynamicCommandExceptionType exception ) throws CommandSyntaxException { ResourceKey resourceKey = context.getArgument(argument, ResourceKey.class); @@ -113,9 +114,7 @@ public class ResourceKeyArgument implements ArgumentType> { @Override public CompletableFuture listSuggestions(CommandContext commandContext, SuggestionsBuilder suggestionsBuilder) { return commandContext.getSource() instanceof SharedSuggestionProvider sharedSuggestionProvider - ? sharedSuggestionProvider.suggestRegistryElements( - this.registryKey, SharedSuggestionProvider.ElementSuggestionType.ELEMENTS, suggestionsBuilder, commandContext - ) + ? sharedSuggestionProvider.suggestRegistryElements(this.registryKey, ElementSuggestionType.ELEMENTS, suggestionsBuilder, commandContext) : suggestionsBuilder.buildFuture(); } diff --git a/net/minecraft/commands/arguments/ResourceOrIdArgument.java b/net/minecraft/commands/arguments/ResourceOrIdArgument.java index dcb7ea15..0200f13a 100644 --- a/net/minecraft/commands/arguments/ResourceOrIdArgument.java +++ b/net/minecraft/commands/arguments/ResourceOrIdArgument.java @@ -8,6 +8,8 @@ import com.mojang.brigadier.exceptions.CommandSyntaxException; import com.mojang.brigadier.exceptions.DynamicCommandExceptionType; import com.mojang.brigadier.exceptions.SimpleCommandExceptionType; import com.mojang.serialization.Codec; +import com.mojang.serialization.Dynamic; +import com.mojang.serialization.DynamicOps; import java.util.Collection; import java.util.List; import net.minecraft.commands.CommandBuildContext; @@ -17,8 +19,6 @@ import net.minecraft.core.HolderLookup; import net.minecraft.core.Registry; import net.minecraft.core.registries.Registries; import net.minecraft.nbt.NbtOps; -import net.minecraft.nbt.StringTag; -import net.minecraft.nbt.Tag; import net.minecraft.nbt.TagParser; import net.minecraft.network.chat.Component; import net.minecraft.resources.RegistryOps; @@ -36,6 +36,7 @@ public class ResourceOrIdArgument implements ArgumentType> { object -> Component.translatableEscape("argument.resource_or_id.failed_to_parse", object) ); private static final SimpleCommandExceptionType ERROR_INVALID = new SimpleCommandExceptionType(Component.translatable("argument.resource_or_id.invalid")); + private static final TagParser VALUE_PARSER = TagParser.create(NbtOps.INSTANCE); private final HolderLookup.Provider registryLookup; private final boolean hasRegistry; private final Codec> codec; @@ -76,26 +77,27 @@ public class ResourceOrIdArgument implements ArgumentType> { @Nullable public Holder parse(StringReader reader) throws CommandSyntaxException { - Tag tag = parseInlineOrId(reader); - if (!this.hasRegistry) { - return null; - } else { - RegistryOps registryOps = this.registryLookup.createSerializationContext(NbtOps.INSTANCE); - return this.codec.parse(registryOps, tag).getOrThrow(string -> ERROR_FAILED_TO_PARSE.createWithContext(reader, string)); - } + return this.parse(reader, VALUE_PARSER); + } + + @Nullable + private Holder parse(StringReader reader, TagParser parser) throws CommandSyntaxException { + RegistryOps registryOps = this.registryLookup.createSerializationContext(parser.getOps()); + Dynamic dynamic = parseInlineOrId(registryOps, parser, reader); + return !this.hasRegistry ? null : this.codec.parse(dynamic).getOrThrow(string -> ERROR_FAILED_TO_PARSE.createWithContext(reader, string)); } @VisibleForTesting - static Tag parseInlineOrId(StringReader reader) throws CommandSyntaxException { + static Dynamic parseInlineOrId(DynamicOps ops, TagParser tagParser, StringReader reader) throws CommandSyntaxException { int i = reader.getCursor(); - Tag tag = new TagParser(reader).readValue(); + T object = tagParser.parseAsArgument(reader); if (hasConsumedWholeArg(reader)) { - return tag; + return new Dynamic<>(ops, object); } else { reader.setCursor(i); ResourceLocation resourceLocation = ResourceLocation.read(reader); if (hasConsumedWholeArg(reader)) { - return StringTag.valueOf(resourceLocation.toString()); + return new Dynamic<>(ops, ops.createString(resourceLocation.toString())); } else { reader.setCursor(i); throw ERROR_INVALID.createWithContext(reader); diff --git a/net/minecraft/commands/arguments/ResourceSelectorArgument.java b/net/minecraft/commands/arguments/ResourceSelectorArgument.java new file mode 100644 index 00000000..13541775 --- /dev/null +++ b/net/minecraft/commands/arguments/ResourceSelectorArgument.java @@ -0,0 +1,117 @@ +package net.minecraft.commands.arguments; + +import com.google.gson.JsonObject; +import com.mojang.brigadier.StringReader; +import com.mojang.brigadier.arguments.ArgumentType; +import com.mojang.brigadier.context.CommandContext; +import com.mojang.brigadier.exceptions.CommandSyntaxException; +import com.mojang.brigadier.exceptions.Dynamic2CommandExceptionType; +import com.mojang.brigadier.suggestion.Suggestions; +import com.mojang.brigadier.suggestion.SuggestionsBuilder; +import java.util.Collection; +import java.util.List; +import java.util.concurrent.CompletableFuture; +import net.minecraft.commands.CommandBuildContext; +import net.minecraft.commands.CommandSourceStack; +import net.minecraft.commands.SharedSuggestionProvider; +import net.minecraft.commands.SharedSuggestionProvider.ElementSuggestionType; +import net.minecraft.commands.synchronization.ArgumentTypeInfo; +import net.minecraft.core.HolderLookup; +import net.minecraft.core.Registry; +import net.minecraft.core.Holder.Reference; +import net.minecraft.network.FriendlyByteBuf; +import net.minecraft.network.chat.Component; +import net.minecraft.resources.ResourceKey; +import net.minecraft.resources.ResourceLocation; +import org.apache.commons.io.FilenameUtils; + +public class ResourceSelectorArgument implements ArgumentType>> { + private static final Collection EXAMPLES = List.of("minecraft:*", "*:asset", "*"); + public static final Dynamic2CommandExceptionType ERROR_NO_MATCHES = new Dynamic2CommandExceptionType( + (object, object2) -> Component.translatableEscape("argument.resource_selector.not_found", object, object2) + ); + final ResourceKey> registryKey; + private final HolderLookup registryLookup; + + ResourceSelectorArgument(CommandBuildContext buildContext, ResourceKey> registryKey) { + this.registryKey = registryKey; + this.registryLookup = buildContext.lookupOrThrow(registryKey); + } + + public Collection> parse(StringReader stringReader) throws CommandSyntaxException { + String string = ensureNamespaced(readPattern(stringReader)); + List> list = this.registryLookup.listElements().filter(reference -> matches(string, reference.key().location())).toList(); + if (list.isEmpty()) { + throw ERROR_NO_MATCHES.createWithContext(stringReader, string, this.registryKey.location()); + } else { + return list; + } + } + + public static Collection> parse(StringReader parse, HolderLookup lookup) { + String string = ensureNamespaced(readPattern(parse)); + return lookup.listElements().filter(reference -> matches(string, reference.key().location())).toList(); + } + + private static String readPattern(StringReader reader) { + int i = reader.getCursor(); + + while (reader.canRead() && isAllowedPatternCharacter(reader.peek())) { + reader.skip(); + } + + return reader.getString().substring(i, reader.getCursor()); + } + + private static boolean isAllowedPatternCharacter(char c) { + return ResourceLocation.isAllowedInResourceLocation(c) || c == '*' || c == '?'; + } + + private static String ensureNamespaced(String name) { + return !name.contains(":") ? "minecraft:" + name : name; + } + + private static boolean matches(String string, ResourceLocation location) { + return FilenameUtils.wildcardMatch(location.toString(), string); + } + + public static ResourceSelectorArgument resourceSelector(CommandBuildContext buildContext, ResourceKey> registryKey) { + return new ResourceSelectorArgument<>(buildContext, registryKey); + } + + public static Collection> getSelectedResources( + CommandContext context, String argument, ResourceKey> registryKey + ) { + return context.getArgument(argument, Collection.class); + } + + @Override + public CompletableFuture listSuggestions(CommandContext commandContext, SuggestionsBuilder suggestionsBuilder) { + return commandContext.getSource() instanceof SharedSuggestionProvider sharedSuggestionProvider + ? sharedSuggestionProvider.suggestRegistryElements(this.registryKey, ElementSuggestionType.ELEMENTS, suggestionsBuilder, commandContext) + : SharedSuggestionProvider.suggest(this.registryLookup.listElementIds().map(ResourceKey::location).map(ResourceLocation::toString), suggestionsBuilder); + } + + @Override + public Collection getExamples() { + return EXAMPLES; + } + + public static class Info implements ArgumentTypeInfo, ResourceSelectorArgument.Info.Template> { + public void serializeToNetwork(ResourceSelectorArgument.Info.Template template, FriendlyByteBuf friendlyByteBuf) { + friendlyByteBuf.writeResourceKey(template.registryKey); + } + + public ResourceSelectorArgument.Info.Template deserializeFromNetwork(FriendlyByteBuf friendlyByteBuf) { + return new net.minecraft.commands.arguments.ResourceSelectorArgument.Info.Template(this, friendlyByteBuf.readRegistryKey()); + } + + public void serializeToJson(ResourceSelectorArgument.Info.Template template, JsonObject jsonObject) { + jsonObject.addProperty("registry", template.registryKey.location().toString()); + } + + public ResourceSelectorArgument.Info.Template unpack(ResourceSelectorArgument resourceSelectorArgument) { + return new net.minecraft.commands.arguments.ResourceSelectorArgument.Info.Template(this, resourceSelectorArgument.registryKey); + } + } +} diff --git a/net/minecraft/commands/arguments/ScoreHolderArgument.java b/net/minecraft/commands/arguments/ScoreHolderArgument.java index 43325405..7c53f861 100644 --- a/net/minecraft/commands/arguments/ScoreHolderArgument.java +++ b/net/minecraft/commands/arguments/ScoreHolderArgument.java @@ -93,8 +93,8 @@ public class ScoreHolderArgument implements ArgumentType ScoreHolderArgument.Result parse(StringReader reader, S suggestionProvider) throws CommandSyntaxException { - return this.parse(reader, EntitySelectorParser.allowSelectors(suggestionProvider)); + public ScoreHolderArgument.Result parse(StringReader stringReader, S object) throws CommandSyntaxException { + return this.parse(stringReader, EntitySelectorParser.allowSelectors(object)); } private ScoreHolderArgument.Result parse(StringReader reader, boolean allowSelectors) throws CommandSyntaxException { diff --git a/net/minecraft/commands/arguments/StyleArgument.java b/net/minecraft/commands/arguments/StyleArgument.java index c67231bc..e01f036a 100644 --- a/net/minecraft/commands/arguments/StyleArgument.java +++ b/net/minecraft/commands/arguments/StyleArgument.java @@ -1,28 +1,31 @@ package net.minecraft.commands.arguments; -import com.mojang.brigadier.StringReader; -import com.mojang.brigadier.arguments.ArgumentType; import com.mojang.brigadier.context.CommandContext; -import com.mojang.brigadier.exceptions.CommandSyntaxException; import com.mojang.brigadier.exceptions.DynamicCommandExceptionType; +import com.mojang.serialization.DynamicOps; import java.util.Collection; import java.util.List; import net.minecraft.commands.CommandBuildContext; import net.minecraft.commands.CommandSourceStack; -import net.minecraft.commands.ParserUtils; import net.minecraft.core.HolderLookup; +import net.minecraft.nbt.NbtOps; +import net.minecraft.nbt.SnbtGrammar; +import net.minecraft.nbt.Tag; import net.minecraft.network.chat.Component; import net.minecraft.network.chat.Style; +import net.minecraft.util.parsing.packrat.commands.CommandArgumentParser; +import net.minecraft.util.parsing.packrat.commands.ParserBasedArgument; -public class StyleArgument implements ArgumentType