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.

Featured Replies

Posted

In my mod I want a piece of armor (chest plate) that changes the players skin. I have moderate experience with coding. I have no idea where to start or even if this is possible. If you can help me I would appreciate it.

Hmm... What have you tried? Post your code so far.

Well, to change someone's skin, you need their Minecraft password, so you'd need a GUI to prompt for their Minecraft password. That's a start.

Sup bruh.

No, OP is trying to temporarily change the skin on the client side, not on the Mojang servers.

 

Side note: No (sensible) person would trust a popup in MC that prompts them for their username/email and password.

Don't make mods if you don't know Java.

Check out my website: http://shadowfacts.net

Developer of many mods

Okay, thanks Shadow.

You might be able to use Java's ImageIO to download a skin and put it inside the directory that the user's skin is in. Not sure if this is possible, but it's an idea.

Sup bruh.

LOL, totally off topic but really funny. I was looking through the Minecraft source code looking for a answer to this question when I found this in RenderPlayer:

if (p_77029_1_.getCommandSenderName().equals("deadmau5") && p_77029_1_.func_152123_o())
        {
            this.bindTexture(p_77029_1_.getLocationSkin());

            for (int j = 0; j < 2; ++j)
            {
                float f9 = p_77029_1_.prevRotationYaw + (p_77029_1_.rotationYaw - p_77029_1_.prevRotationYaw) * p_77029_2_ - (p_77029_1_.prevRenderYawOffset + (p_77029_1_.renderYawOffset - p_77029_1_.prevRenderYawOffset) * p_77029_2_);
                float f10 = p_77029_1_.prevRotationPitch + (p_77029_1_.rotationPitch - p_77029_1_.prevRotationPitch) * p_77029_2_;
                GL11.glPushMatrix();
                GL11.glRotatef(f9, 0.0F, 1.0F, 0.0F);
                GL11.glRotatef(f10, 1.0F, 0.0F, 0.0F);
                GL11.glTranslatef(0.375F * (float)(j * 2 - 1), 0.0F, 0.0F);
                GL11.glTranslatef(0.0F, -0.375F, 0.0F);
                GL11.glRotatef(-f10, 1.0F, 0.0F, 0.0F);
                GL11.glRotatef(-f9, 0.0F, 1.0F, 0.0F);
                f2 = 1.3333334F;
                GL11.glScalef(f2, f2, f2);
                this.modelBipedMain.renderEars(0.0625F);
                GL11.glPopMatrix();
            }

 

It puts ears on any player named "deadmau5". :)

Haven't found anything yet, but I'll keep looking. :(

Again off topic, but whats with the obsession with deadmau5. huh.gif

/**
     * renders the ears (specifically, deadmau5's)
     */
    public void renderEars(float p_78110_1_)
    {
        this.bipedEars.rotateAngleY = this.bipedHead.rotateAngleY;
        this.bipedEars.rotateAngleX = this.bipedHead.rotateAngleX;
        this.bipedEars.rotationPointX = 0.0F;
        this.bipedEars.rotationPointY = 0.0F;
        this.bipedEars.render(p_78110_1_);
    }

Idk if it's possible, but there is a SkinManager field in Minecraft's main class you could try. I don't know what the name is, most of the names of Minecraft source are appearing as "field_123456_a" and similar since I moved my code to another computer. Huh, weird.

  • Author

I know it is possible to morph players. Is there a way to use a method that those mods do as it is pretty much the same thing.

To morph players? :) That would be RenderPlayerEvent (I think). There is Pre and Post within the class so you'll have to experiment.

You could try and replace the player model, kind of like the morph mod when you kill another player. (I have no idea how this would work though)

The proud(ish) developer of Ancients

  • Author

Idk how to render the players model but I will try to do so with a tick handler so it knows when the player is wearing the armor.

  • Author

I'm completely lost, but what i'm trying to do it make it so your skin changes when you wear certain armor. I want this because armor looks too blocks and doesn't cover your hands and over places. Also then you don't need to have 4 armor pieces.

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

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.