package info.u_team.u_team_core.util.registry;

import java.util.function.Supplier;

import net.minecraft.client.KeyMapping;
import net.minecraft.client.gui.screens.MenuScreens;
import net.minecraft.client.gui.screens.Screen;
import net.minecraft.client.gui.screens.inventory.MenuAccess;
import net.minecraft.client.renderer.blockentity.BlockEntityRendererProvider;
import net.minecraft.client.renderer.blockentity.BlockEntityRenderers;
import net.minecraft.client.renderer.entity.EntityRendererProvider;
import net.minecraft.world.entity.Entity;
import net.minecraft.world.entity.EntityType;
import net.minecraft.world.inventory.AbstractContainerMenu;
import net.minecraft.world.inventory.MenuType;
import net.minecraft.world.level.block.entity.BlockEntity;
import net.minecraft.world.level.block.entity.BlockEntityType;
import net.minecraftforge.fmlclient.registry.RenderingRegistry;

public class ClientRegistry {

	public static <M extends AbstractContainerMenu, U extends Screen & MenuAccess<M>> void registerScreen(Supplier<? extends MenuType<? extends M>> supplier, MenuScreens.ScreenConstructor<M, U> factory) {
		MenuScreens.register(supplier.get(), factory);
	}

	public static <T extends Entity> void registerEntityRenderer(Supplier<? extends EntityType<? extends T>> supplier, EntityRendererProvider<T> provider) {
		RenderingRegistry.registerEntityRenderingHandler(supplier.get(), provider);
	}

	public static <T extends BlockEntity> void registerSpecialTileEntityRenderer(Supplier<? extends BlockEntityType<T>> supplier, BlockEntityRendererProvider<T> provider) {
		BlockEntityRenderers.register(supplier.get(), provider);
	}

	public static void registerKeybinding(KeyMapping key) {
		net.minecraftforge.fmlclient.registry.ClientRegistry.registerKeyBinding(key);
	}

}

@@ -306,583 +306,92 @@
 aft.
-client.renderer.blockentity.BlockEntityRendererProvider;%0Aimport net.minecraft.client.renderer.blockentity.BlockEntityRenderers;%0Aimport net.minecraft.client.renderer.entity.EntityRendererProvider;%0Aimport net.minecraft.world.entity.Entity;%0Aimport net.minecraft.world.entity.EntityType;%0Aimport net.minecraft.world.inventory.AbstractContainerMenu;%0Aimport net.minecraft.world.inventory.MenuType;%0Aimport net.minecraft.world.level.block.entity.BlockEntity;%0Aimport net.minecraft.world.level.block.entity.BlockEntityType;%0Aimport net.minecraftforge.fmlclient.registry.RenderingRegistry
+world.inventory.AbstractContainerMenu;%0Aimport net.minecraft.world.inventory.MenuType
 ;%0A%0Ap
@@ -419,16 +419,45 @@
 istry %7B%0A
+%09%0A%09@Deprecated // TODO remove
 %0A%09public
@@ -707,477 +707,9 @@
 %0A%09%7D%0A
-%0A%09public static %3CT extends Entity%3E void registerEntityRenderer(Supplier%3C? extends EntityType%3C? extends T%3E%3E supplier, EntityRendererProvider%3CT%3E provider) %7B%0A%09%09RenderingRegistry.registerEntityRenderingHandler(supplier.get(), provider);%0A%09%7D%0A%0A%09public static %3CT extends BlockEntity%3E void registerSpecialTileEntityRenderer(Supplier%3C? extends BlockEntityType%3CT%3E%3E supplier, BlockEntityRendererProvider%3CT%3E provider) %7B%0A%09%09BlockEntityRenderers.register(supplier.get(), provider);%0A%09%7D%0A
+%09
 %0A%09pu
@@ -845,11 +845,12 @@
 ey);%0A%09%7D%0A
+%09
 %0A%7D%0A

Remove oudated methods due to new forge update