Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

matsuokisho

Members
  • Joined

  • Last visited

  1. Sorry my mistake, the previous code was not working. Here is a new one, there are also no errors and it doesn’t change anything, I tried to add a layer through AddLayers, but it seems to me that I indicated the wrong values, I did not understand what values to indicate there. ModEventClientBusEvents MyPlayerLayer MyPlayerRenderer debug.log
  2. The way you change the skin doesn't matter to me. I redid the code so that it renders a new skin, there are also no errors and nothing changes. public class MyPlayerLayer extends LayerRenderer<PlayerEntity, PlayerModel<PlayerEntity>> { public MyPlayerLayer(IEntityRenderer<PlayerEntity, PlayerModel<PlayerEntity>> entityRenderer) { super(entityRenderer); } @Override public void render(MatrixStack matrixStack, IRenderTypeBuffer buffer, int light, PlayerEntity player, float limbAngle, float limbDistance, float tickDelta, float customAngle, float headYaw, float headPitch) { PlayerModel<PlayerEntity> model = getParentModel(); renderCutoutModel(model, new ResourceLocation("tutorialmod:textures/entity/player_layer.png"), matrixStack, buffer, light, player, 1, 1, 1, tickDelta, 1, 1, 1, 1); } } public class MyPlayerRenderer extends LivingRenderer<PlayerEntity, PlayerModel<PlayerEntity>> { public MyPlayerRenderer(EntityRendererManager rendererManager) { super(rendererManager, new PlayerModel<>(0.0f, false), 0.5f); addLayer(new MyPlayerLayer(this)); } @Override public ResourceLocation getTextureLocation(PlayerEntity entity) { return new ResourceLocation("tutorialmod:textures/entity/player.png"); } } RenderingRegistry.registerEntityRenderingHandler(EntityType.PLAYER, (RenderFactory) MyPlayerRenderer::new);
  3. matsuokisho joined the community
  4. Ultimate Goal: Change the skin of the player on the server, but for now I just want to change the skin locally. There are no errors in my code, but the skin does not change. My code: private void onClientSetup(final FMLClientSetupEvent event) { ResourceLocation skinLocation = new ResourceLocation(TutorialMod.MOD_ID, "textures/entity/raccoon/raccoon.png"); Property textureProperty = new Property("textures", skinLocation.toString()); GameProfile gp = Minecraft.getInstance().getUser().getGameProfile(); gp.getProperties().removeAll("textures"); gp.getProperties().put("textures", textureProperty); SkinManager skinManager = Minecraft.getInstance().getSkinManager(); skinManager.registerSkins(gp, (type, location, profileTexture) -> {}, true); }

Important Information

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

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.