Jump to content

Recommended Posts

Posted

Do you have a picture of what it is supposed to look like because from what I can gather, the model seems to be rendering the way you wrote it.

 

Fun fact about global and local ModelRenderers: If you make a global ModelRenderer a child of some other model, it will render twice! So, for every ModelRenderer you add, you need to make them local variables within your constructor to prevent that. Also, you shouldn't need to copyModelAngles if they are a child of the parent ModelRenderer.

 

Also, make sure you are using the newest version of tabula released for 1.15 if you are creating models.

Posted
On 7/7/2020 at 4:55 PM, ChampionAsh5357 said:

Do you have a picture of what it is supposed to look like because from what I can gather, the model seems to be rendering the way you wrote it.

 

Fun fact about global and local ModelRenderers: If you make a global ModelRenderer a child of some other model, it will render twice! So, for every ModelRenderer you add, you need to make them local variables within your constructor to prevent that. Also, you shouldn't need to copyModelAngles if they are a child of the parent ModelRenderer.

 

Also, make sure you are using the newest version of tabula released for 1.15 if you are creating models.

http://prntscr.com/teaidw 

^how to textures look in tabula(im using the latest version btw 8.0.1 for 1.15)

 

        ModelRenderer helmetLocal = this.Helmet;
        ModelRenderer chestplateLocal = this.Chestplate;
        ModelRenderer leftSleeveLocal = this.LeftSleeve;
        ModelRenderer rightSleeveLocal = this.RightSleeve;
        ModelRenderer rightLeggingLocal = this.RightLegging;
        ModelRenderer leftLeggingLocal = this.LeftLegging;
        ModelRenderer rightBootLocal = this.RightBoot;
        ModelRenderer leftBootLocal = this.LeftBoot;

^ also i'm not sure if this is what you meant with the local variables and would the double rendering cause the incorrect textures

 

 

Posted
5 minutes ago, clearcut said:

also i'm not sure if this is what you meant with the local variables and would the double rendering cause the incorrect textures

Setting a global variable to a local variable does not make it local.

 

You're having the same issue as the other person where you are trying to render everything custom and then adding child models. The top 64x32 area is reserved for the biped model rendering. Everything beneath that is space to render your own model on top of. If you are creating a texture that uses basic armor texturing, use the biped model area. Else, create your own model and attach it.

Posted

My textures have been changed to make sure that nothing is in the 64 x 32 area so I believe that shouldnt get in the way of the default model rendering.

 

But I still do not understand why the textures on the model are so off.

17 hours ago, ChampionAsh5357 said:

When declaring the width, height, or depth of your model, it adjusts the scale of the texture needed to be wrapped. In the example I took from you, a width and height of 5.0 and 4.0 are fine. However, .26 is not so much. Even though in the tabula it will look normal, Minecraft will actually take your image, scale it up, and reference it as if it was literally 0.26 instead of what tabula outputs. So in your case, to have a correctly mapped texture, it would need to be scaled up to 6400x3200 to correctly map those decimal values.

I thought this might be the same problem for me but I do not have any decimals and I tried playing around with scaling the texture up aswell as increasing textureHeight and textureWidth in the model but It does not make it any better.

 

Thanks for your help so far btw,

onyx_armor2.png

Posted

Well that's an easy problem. You call textureHeight and textureWidth too late. For the biped model, it still uses a 64x32 image. So, your texture is compressed and scaled to that. You need to set it within your super like so:

super(modelSize, 0, 128, 128);

This makes it so that the default biped renderer knows that its supposed to be just taking the 64x32 area into account rather than the entire 128x128.

 

Due to the lack of understanding of ModelRenderer and custom armor models, I spent the entire day creating a detailed explanation of it and how it should be rendered. I would recommend taking a read through it as it should go over everything you need to know.

Posted

It is finally fixed! Thanks for the help

 

 

 

For the people having the same issue as me.

super(modelSize, 0, 128, 128);

 

^I implemented this change and followed this tutorial below to update all my classes.

2 hours ago, ChampionAsh5357 said:

That made the model look a bit better as it fixed the double rendering issue. However, I still had the same issue.

 

 

I then found out that the problem was as below.

       ModelRenderer LeftBoot = new ModelRenderer(this, 0, 13);
	LeftBoot.setTextureOffset(22, 53).addBox(-3.0F, 8.0F, -3.0F, 1.0F, 4.0F, 6.0F, 0.0F, 0.0F, 0.0F);

This makes the group "LeftBoot" as well as all my other groups that were declared have a texture offset(that is the "0,13").

 

In tabula, to find the texture offset for a box, it adds the texture offset from the group to the texture offset from the individual boxes and so your model will look normal.

However, in game it does not work the same way.

 

 

	LeftBoot = new ModelRenderer(this);
        LeftBoot.setTextureOffset(22, 66).addBox(-3.0F, 8.0F, -3.0F, 1.0F, 4.0F, 6.0F, 0.0F, 0.0F, 0.0F);

 

To fix this, I changed the declaration of all my groups to be declared as above. This makes the group texture offset (0,0) then you can add the numbers that were in the group's texture offset to each of the boxes in that group.

Posted
2 hours ago, clearcut said:

In tabula, to find the texture offset for a box, it adds the texture offset from the group to the texture offset from the individual boxes and so your model will look normal.

However, in game it does not work the same way.

I will make sure to include this as a note in my explanation. Congrats on getting it fixed.

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.

Guest
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.

Announcements



  • Recently Browsing

    • No registered users viewing this page.
  • Posts

    • Reach Out To Rapid Digital: What sapp Info: +1 41 4 80 7 14 85 Email INFO: rap iddi gita lrecov ery @ exe cs. com Hello, my name is Jayson, and I’m 35 years old from the United Kingdom. My family and I recently endured an incredibly challenging experience that I wouldn’t wish on anyone. We became victims of a cryptocurrency investment fraud scheme that saw us lose a staggering $807,000 in USDT and Bitcoins. The fraudsters had created a convincing facade, and we were lured into investing, only to discover later that the platform was a complete scam. We were left devastated, not just financially, but emotionally, as we had trusted these people and believed in the legitimacy of the investment. After the initial shock wore off, we desperately searched for ways to recover the lost funds. It seemed like an impossible task, and we felt as though there was no hope. That’s when, by sheer luck, we stumbled across a post about Rapid Digital Recovery, a cryptocurrency and funds recovery organization with a proven track record in cybersecurity and fraud recovery. We decided to reach out to them, and from the first interaction, we were impressed with their professionalism and transparency. They explained the recovery process in detail and reassured us that they had the skills and expertise to track down the perpetrators and recover our funds. This gave us a renewed sense of hope, something we hadn’t felt in months. What truly stood out during our experience with Rapid Digital Recovery was their dedication to the recovery process. The team went above and beyond, using sophisticated tracking tools and cyber forensics to gather critical information. Within a matter of weeks, they had successfully located the funds and traced the scam back to the fraudsters responsible. They worked with the authorities to ensure the criminals were held accountable for their actions. To our relief, the team at Rapid Digital Recovery was able to recover every single penny we had lost. The funds were returned in full, and the sense of closure we felt was invaluable. We couldn’t have imagined such a positive outcome in the early stages of our recovery journey, and we are deeply grateful for the work they did. If you ever find yourself in a similar situation, I highly recommend contacting Rapid Digital Recovery. Their expertise, transparency, and dedication to their clients make them the go-to choice for anyone seeking to recover lost cryptocurrency or funds. They truly gave us back our financial future.  
    • This is my first time modding anything, so maybe just skill issue. I'm using Forge 54.0.12 and Temurin 21.0.5+11-LTS I wanted to create a custom keybind and to check whether it works I'd like to send a chat message. I tried using Minecraft.getInstance().player.sendSystemMessage(Component.literal("test")); but IntelliJ couldnt resolve sendSystemMessage(...). Since I saw people using it in earlier versions, I tried the same thing with 1.20.6(- 50.1.0), where it works fine, now I can't figure out if this is intentional and whether there are other options for sending chat messages. On that note, is there more documentation than https://docs.minecraftforge.net/en/1.21.x/? It seems very incomplete compared to something like the Oracle Java docs
    • Hi, i'm having this error and I wanna fix it. we try: -Reload drivers -Eliminate .minecraft -Eliminate Java -Restart launcher -Verify if minecraft is using gpu -Mods  in .minecraft is empty -Install the latest and recomended version of forge idk what i have to do, help me pls. the lastest log is: https://mclo.gs/WAMao8x  
    • Read the FAQ, Rule #2. (https://forums.minecraftforge.net/topic/125488-rules-and-frequently-asked-questions-faq/)  
  • Topics

×
×
  • Create New...

Important Information

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