Jump to content

GlobalEntityTypeAttributes does not exist anymore in 1.17.1 ?


Recommended Posts

Hi i'm trying to make a new entity in my mod however i can't find the class GlobalEntityTypeAttributes in 1.17.1. I think it got renamed but after hours of research i can't find it at all here is what i'm trying to do in my mod main class :

private void setup(final FMLCommonSetupEvent event) {
        DeferredWorkQueue.runLater(() -> {
            GlobalEntityTypeAttributes.put(ModEntityType.ENTITY.get(), Entity.setCustomAttributes().create());

Can someone help me ?

Link to comment
Share on other sites

I did that

	public static final void entityClientRederer(EntityRenderersEvent.RegisterRenderers event) {
		event.registerEntityRenderer(EntityInit.SLEEPING_PLAYER.get(), SleepingPlayerRenderer::new);

But it says that :

The type SleepingPlayerRenderer does not define SleepingPlayerRenderer(EntityRendererProvider.Context) that is applicable here

can you help me ? Thank you btw diesieben07 

Link to comment
Share on other sites

I know that the problem is here but i don't know what to change ... 

public class SleepingPlayerRenderer extends MobRenderer<SleepingPlayerEntity, SleepingPlayerModel<SleepingPlayerEntity>> {

	protected static final ResourceLocation Texture = new ResourceLocation(DreamyMain.MOD_ID, "textures/entity/sleeping_player.png");
	public SleepingPlayerRenderer(Context p_174304_, SleepingPlayerModel<SleepingPlayerEntity> p_174305_) {
		super(p_174304_, p_174305_, 0.7f);
	public ResourceLocation getTextureLocation(SleepingPlayerEntity p_114482_) {
		// TODO Auto-generated method stub
		return Texture;



Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


  • Create New...

Important Information

By using this site, you agree to our Terms of Use.