fix index stepping to avoid pushing front layers into back layers (#32553)

Co-authored-by: charlie <charlie.sc.wong@veiwsonic.com>
This commit is contained in:
Charlie 2024-10-01 03:27:33 +08:00 committed by GitHub
parent db198d2813
commit 55ae02f320
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -320,7 +320,8 @@ public sealed class ClientClothingSystem : ClothingSystem
if (layerData.State is not null && inventory.SpeciesId is not null && layerData.State.EndsWith(inventory.SpeciesId))
continue;
_displacement.TryAddDisplacement(displacementData, sprite, index, key, revealedLayers);
if (_displacement.TryAddDisplacement(displacementData, sprite, index, key, revealedLayers))
index++;
}
}