samolego / FabricTailor

A server-side or singleplayer skin changing mod for fabric.
https://modrinth.com/mod/FabricTailor
GNU Lesser General Public License v3.0
109 stars 17 forks source link

[BUG] Skin reset after reconnect #53

Closed seb303 closed 2 years ago

seb303 commented 2 years ago

Describe the bug

After using the /skin clear command, the next time the player logs in, they still have their previous skin set. Sometimes it does work, but often it is necessary to run /skin clear multiple times before the player gets their normal skin back.

Note that within the current game session, the skin clears immediately, it's only when re-connecting that the previously set skin often comes back.

Using: fabrictailor-1.7.1.jar With 1.17.1 game

Other installed mods: fabric-api-0.46.1+1.17.jar FabricProxy-Lite-1.1.5.jar FabricTPA-3.0.1.jar lithium-fabric-mc1.17.1-0.7.5.jar phosphor-fabric-mc1.17.x-0.8.0.jar

samolego commented 2 years ago

Which launcher are you using?

seb303 commented 2 years ago

It happens with various clients: Vanilla (Mojang launcher), Fabric-modded client (Mojang launcher), Lunar client.

Looks like a server-side thing: the /skin clear command seems not to clear the skin override from the stored player data, even though it does clear it in memory for the current session/connection.

samolego commented 2 years ago

The /skin clear resets FabricTailor skin data. If player has skin set, it will be refetched after relog. That's intended behaviour actually.

seb303 commented 2 years ago

To clarify what I am seeing:

Is this really the intended behaviour of /skin clear? Surely it should clear any skin override, so the player skin follows the one set in the Mojang launcher?

seb303 commented 2 years ago

I made a video showing what I mean: https://youtu.be/C2Dr-TdPBk4

The initial server "minigames" is a spigot server and there you see my usual skin. When I switch to server "piglincraft" you can see that FabricTailor is applying a red Among Us skin. After /skin clear it resets to my usual skin. But after disconnecting and reconnecting, it's back to the Among Us skin.

For convenience I'm disconnecting and reconnecting from the Fabric server using the /server command (the 2 different servers are running behind a proxy), but it's the same if I disconnect completely (from the Fabric server point of view it's no different).

seb303 commented 2 years ago

Further info: if I look at the NBT playerdata, I can see that the data is not being cleared after the command /skin clear has been used:

image