Mekanism

Mekanism

111M Downloads

Mekasuit Does Not Render

PessimisticBastard opened this issue · 14 comments

commented

Please use the search functionality before reporting an issue. Also take a look at the closed issues!

Issue description:

Mekasuit is not rendering, just shows empty space

Steps to reproduce:

  1. Put on Mekasuit
  2. Player model becomes invisible

Version (make sure you are on the latest version before reporting):

Forge: 35.1.13
Mekanism: 10.0.18.445
Other relevant version: Minecraft 1.16.4

commented

Same issue of the HUD not rendering, and I'm not using Optifine.

Minecraft version: 1.16.5
Mekanism version: 10.1.2.457

commented

I’m having the same issue. The Meka-Suit does not render on my player, and worse, it makes my hand invisible, even in first-person mode (when empty-handed), when using the MekaSuit bodyarmour, which is annoying.

I’m using the latest version of Mekanism for 1.18.2, 10.2.5.

Same issue here, I assume we will have to open a new ticket for this issue.

commented

This is an issue caused by Oculus. Disabling shaders solves it. Reported it here; I hope they fix it.

commented

I’m having the same issue. The Meka-Suit does not render on my player, and worse, it makes my hand invisible, even in first-person mode (when empty-handed), when using the MekaSuit bodyarmour, which is annoying.

I’m using the latest version of Mekanism for 1.18.2, 10.2.5.

commented

If the issue is as simple as the MekaSuit not being rendered by Oculus, then as a temporary workaround it would be better to render both the original player model and the suit, or at least add a config option for it. That way even if the suit is invisible, the original plyer model is still rendered, which is better than nothing being rendered at all.

commented

I used the Mekasuit with Mekanism 10.0.17, and it works. Maybe it's an issue with 10.0.18.

commented

Do you have optifine or other very hacky rendering mods and if so does removing it fix it?

commented

I do not have any performance enhancement mods. The suit was rendering correctly before the update.

commented

I just tested rolling back Mekanism to version 10.0.17.444. The suit is rendering correctly.

commented

Maybe i know the problem, there are multiple errors in the rendering code and i found it.
It's this function in the ClientRegistration class:
private static <T extends LivingEntity, M extends BipedModel, A extends BipedModel> void addCustomArmorLayer(LivingRenderer<T, M> renderer) {
for (LayerRenderer<T, M> layerRenderer : new ArrayList<>(renderer.layerRenderers)) {
//Only allow an exact match, so we don't add to modded entities that only have a modded extended armor layer
if (layerRenderer.getClass() == BipedArmorLayer.class) {
BipedArmorLayer<T, M, A> bipedArmorLayer = (BipedArmorLayer<T, M, A>) layerRenderer;
renderer.addLayer(new MekanismArmorLayer<>(renderer, bipedArmorLayer.modelLeggings, bipedArmorLayer.modelArmor));
break;
}
}
}
These are the errors:
renderer.layerRenderers
bipedArmorLayer.modelLeggings
bipedArmorLayer.modelArmor

The variables are private in the main class with the new forge update and this gives errors.

The same problem is in the rendering functions of the other armor pieces too in the rendering function:
@OverRide
public void render(@nonnull MatrixStack matrix, @nonnull IRenderTypeBuffer renderer, int light, int overlayLight, float partialTicks, boolean hasEffect,
LivingEntity entity, ItemStack stack) {
if (isChild) {
matrix.push();
float f1 = 1.0F / childBodyScale;
matrix.scale(f1, f1, f1);
matrix.translate(0.0D, childBodyOffsetY / 16.0F, 0.0D);
renderMekaSuit(matrix, renderer, light, overlayLight, partialTicks, hasEffect, entity);
matrix.pop();
} else {
renderMekaSuit(matrix, renderer, light, overlayLight, partialTicks, hasEffect, entity);
}
}

Problems:
childBodyScale
childBodyOffsetY

And i think there is another error, but i need to search it.

P.S. : i tried to fix but i need to create a custom render system for that.

commented

Those variables are not private with Mekanism, we AT them, they are only a problem if another mod like optifine goes ahead and overwrites entire classes, if that is what the issue is and there are access errors in the log I am going to go ahead and close this.

commented

Well, how i can solve the problem of the private variables, then?
I can't start the mod in the dev enviroment.

commented

By setting up the forge project the same as any other forge project so that it can apply the ATs. This isn't the place for support with figuring out how to setup a forge mod.

commented

Not able to reproduce this best guess is there is some other mod you have installed that is breaking things. Providing a modlist may help or even better testing a few of your mods at a time with Mekanism also installed and seeing when the mekasuit stops rendering.