Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

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

The second parameter aka the problem is an entityRendererProvider The renderer provider, can be a lambda like MyRenderer::new.

What i sent to him was a lambda. So i really don't know whats the problem.

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.

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.


  • Recently Browsing

    No registered users viewing this page.

  • Posts

    • Hi, I would like to know if it's possible to render the glowing effect with depth test so it won't be visible through walls? Should I implement my own render type buffer? Thanks!
    • I think that this is easier. Thank you. I do know how to do that.
    • Thank you for your help. I think I'm on the correct page. https://mcforge.readthedocs.io/en/latest/models/color/ I only need to find out how this works.
    • Hi, I did not know where exactly to put this, so I just put it in off topic. I was under an hour ago banned from the Forge discord, the reason was "You were banned from The Forge Project | Sending Friend Requests to random users while under watch" When the user I was sending the message to was no a random person, I had a very specific reason to try to get to them, and in addition, there is no rule saying I could not send friend requests, and if there was a rule I would like to see where it is because I looked in the Code of Conduct and it was not there. And if it was there, an infraction system is used, and at the very worse it would be considered "spammy*, as it was not illegal or against TOS, and even spammy would be kind of extreme as all I did was send a friend request to someone who was the host of an even I was interested in. I was not given an amount of time which the ban would last so I guess it would be Perma, even though what I did was either within the rules, or a minor infraction. If there are some rules I do not know about, please let me know about them because I have not seen these other rules. Also, I do not understand why I am on watch, the only other rule break I had was from a few months ago for talking about old stuff, and I am generally not all that active in the Forge discord so do not see where this watch would have come from. In addition, the rules never say anything about watches and that other rules would apply. The only real conflict I had recently was a mistake in MMD  (which even then was unjust), but that is MMD thus it is separate and there was nothing that is in the rules which would say that what happens there puts anyone in any situation, and I do not know much other conflict I was in recently, especially which would have caused this. If my action were so severe I do not know why I was not  notified about them earlier, but I did not perform any bad actions, so please look into this and explain the steps I need to take to be unbanned or have my punishment reduced and please clarify some of this stuff about me being under watch as I really do not know.   My Discord is Asbestosstar#2338
  • Topics

  • Who's Online (See full list)

  • Create New...

Important Information

By using this site, you agree to our Privacy Policy.