Layered clothing causes lag spikes when updating unrelated part properties

Can confirm this is an issue. Equipping and unequipping a tool for example will cause layered clothing to rebuild. Sitting in a seat will cause it to rebuild. Rescaling a character through their scale values will also cause a rebuild. Any eta on a fix for this?

3 Likes

I do believe rescaling a character causing rebuilds is intentional. But I recently added a system in my game where when you talk to NPCs their mouth opens and closes which literally sets the transparency of 2 decals to 0 and 1 and even just that will cause noticeable FPS drops as it triggers the rebuilds every single time.

For a simple repro you can literally have a loop setting a dummy’s face transparency every second and equip that dummy with layered clothing and watch the FPS drop.

I wish we had a way to disable layered clothing rebuilds as I dont rescale the characters or change them in anyway that would even require a rebuild aside from initial spawning in. Idk why setting decal transparencies would even trigger rebuilds in the first place.

2 Likes

Hello to make this easier for staff to solve I updated my layered clothing lag test replication place to show how my use case is game-breaking and potentially help staff come to a solution quicker.

Instructions:
I recommend you use the blocky avatar although it doesn’t really matter that much. Also use a decal face if you want the face toggling to work. (and obviously wear as much layered clothing as you can)

Keybinds:
Q - adds an aura made of parts around the character then destroys it after a few seconds. This is how u essentially see the lag.

C - This is a toggle key. When enabled your faces transparency will change every task.wait(0.05) this is to show that something completely unrelated to layer clothing can still cause the rebuilds

X - This is a toggle key that will add and remove the exact wings I use on my characters which amplify the problem A LOT. I highly recommend you try this with the wings on just to see how bad it gets when adding extra rigging to the character.

B - This is a toggle. When active it changes the transparency of your lefthand every task.wait(0.05)

If you enable the wings and spam Q with layered clothes on you will almost immediately experience FPS dropping.

I appreciate any staff members time looking into this a lot! Hopefully this can help!

4 Likes

This issue has been happening to me for a while and it’s very frustrating, my game has rainbow accessories that are parented to the player’s character, with the color of those accessories being updated by the client, if the player happens to be wearing layered clothing, it causes very noticeable lag spikes.

5 Likes

was debugging a strange lag spike while equipping / unequipping tools today and led to this known issue :raised_hands: would there be an ETA on when the fix will be rolled out? it would be quite unfortunate that we couldn’t enable layered clothing due to engine performance issue :sob:

3 Likes

I asked under another post relating to layered clothing and got this response.
Hopefully this gets prioritized more as it is a game breaking issue.

3 Likes

Thank youu so much for letting me know! :raised_hands: very glad to see the issue is being actively worked on

Besides the fps dropping issue, I was encountering another very strange issue about memory usage regarding the tools being updated / altered while the character is using layered clothings :man_bowing: not sure if you could share some thought / insight Thank youu in advance!

Currently the game of mine making use of remote event to simulate gun’s motion and effect (motor 6D bolt cycling animation / sounds, etc) and there was one time when a player using layered clothings firing their weapons caused my client’s LuaHeap memory usage to an insane value and thus crashed my client

However, seems that I couldn’t replicate the same situation again regarding the luaheap memory leak again so far

2 Likes

Thanks for this example, someone will take a look. Thanks for you patience on this issue, we know the current behavior is a problem and are actively working on it, but the solution is non trivial so it’s taking time. In the meantime there are several workarounds that can be used in many cases, we will be posting more information about that soon.

4 Likes

Appreciate you guys working hard on the issue as always and the updates along the way.
By any chance could we get functionality to disable layered clothing rebuilds? Something like accessory.AllowRebuilds = false either a property or a function. This could prove useful as in my game there are custom characters and the rig size and package never changes so I really have no need to have rebuilds happening in the first place.

I initially wanted to disable rebuilds as a temporary fix for this issue when I first had it occurring but came to find out there wasn’t actually a way to stop them.

1 Like

Hey it’s almost been 2 months and I was wondering when this new information was going to be posted. I’ve been looking forward to it.

3 Likes

Sorry, many competing priorities, but this is wip. Fwiw it’s not new information, just summarizing what we’ve already posted on the forum.

3 Likes

many competing priorities? Layered clothing seems to be ur main priority right now at roblox and if ur considering rolling out layered clothings for UGC bodies I would expect this to be fixed already

1 Like

roblox legal team? Be fr… roblox legal teams do not make the decisions

1 Like

This is a severe bug. If a player is aware of this bug and how it works they can intentionally abuse it in my game with certain mechanics and theres nothing I can do unless I disable layered clothing entirely. Simply spam equipping a tool with layered clothing can cause lag. The post is 6 months old. I understand staff has priorities but I am hoping this can be fixed before the release of my game.

Or at the very least give us an option to disable layered clothing rebuilds for the time being as thats the source of this issue. I’m not gonna say this with confidence because I am not 100% sure but I imagine it shouldn’t be too difficult to allow us to disable layered clothing rebuilds as a temporary solution. Especially since its such a severe bug and I am just left with a super laggy game until its fixed.

tl;dr I understand it’ll take time plz offer us a temporary solution (letting us disable layer clothing rebuilds in our games).

2 Likes

Lets bring attention to this as layered clothing is in every game now making this bug VERY IMPORTANT.

2 Likes

If you have read this post throughoutly, you could see @yoolurs has made and provided a full detailed exmaple and reproduction test place on the issue and even Roblox staff has acknowledged the reproduction method

I’m a bit confused the reason why you joined this post’s discussion without actually get to know about the bug / issue - this is actually a serious game breaking bug and there were serveral similar bug reports mentioning about the same issue

Everyone is welcome to discuss but unfortunately that the replies of yours made me feel like you just went in this discussion and proceed to challenge / disappove others intentionally

3 Likes

I was replying to someone who, in my head, was saying that Roblox as a whole was focusing on Layered Clothing, and that they should fix this bug because of that. It sounded like they were saying Roblox has literally no other priorities right now, and so I responded to that single person to say that no, that’s not how Roblox as a company works. I apologize for appearing to try and dismiss this totally valid bug report as a whole.

Roblox is focusing on layered clothing. It’s literally the future of roblox. what do you think is gonna happen when theres so many clothings and bodys to pick from and they all include layered clothing? Ill tell you one thing. No one is gonna be playing with a lag spike every 2-4 seconds

1 Like

Hey its been nearly 7 months since the initial post, the impact on my game is severe making it very difficult to have an enjoyable experience and layered clothing is pretty important. My game is nearing the point where its ready to release and I am afraid this wont be fixed by then. I understand 100% that it may take time and its being worked on. All I ask is that you give us the option to disable rebuilds in the meantime.

I am unable to just simply not parent things to the characters. Something as simple as a decals transparency being changed can cause significant lag and tools are forced to be added to the character to function.

If we can disable layered clothing rebuilds so it only triggers the build once its equipped it’ll help everyone suffering with this bug a lot. It’s gamebreaking for me and I don’t doubt its the same for others. Thanks and please consider this!

This may not be as simple as it sounds, but I will share your suggestion. Fwiw this work is still ongoing and making good progress, thanks as always for your patience.

1 Like