In-Game Core Escape Menu UI: Player List Is Creating RenderStep(s) For Every Player And Never Unbinds

When opening the Core Escape Menu A Core Script Is Creating a RenderStep Bind For Every Player and whether you switch tabs or close the menu it doesn’t unbind causing extreme performance problems scaling up with more players.

Possible Core Script Causing Issue (this is a single bind of the many shown in the later image):



In Game example of a ~130 player server and the huge amount of frame time it’s taking up compared to everything else:


Running the code below fixed the issue for me live in game, any RenderSteps pictured above disappeared and performance fixed.
I imagine a workaround for developers is to just run this when they detect the escape menu being closed (GuiService.MenuClosed):

for _,v in pairs(game.Players:GetPlayers()) do
	game["Run Service"]:UnbindFromRenderStep("utility-focus-state".."-friendstatuslabel-"..v.Name)
	game["Run Service"]:UnbindFromRenderStep("utility-focus-state".."-blockbutton-"..v.Name)
	game["Run Service"]:UnbindFromRenderStep("utility-focus-state".."-mutestatusbutton-"..v.Name)
	game["Run Service"]:UnbindFromRenderStep("utility-focus-state".."-reportplayer-"..v.Name)
	game["Run Service"]:UnbindFromRenderStep("utility-focus-state".."-inspect-"..v.Name)
	game["Run Service"]:UnbindFromRenderStep("utility-focus-state".."-sharegame")
	game["Run Service"]:UnbindFromRenderStep("utility-focus-state".."-muteall")
end

These RenderStep names source from the script:
image

Client Info:

Expected behavior

I expect the RenderStep Binds to Un-Bind when the Menu switches tabs or the menu closes.

10 Likes

Thanks for doing the work and finding the why. I’ve seen this reported a few times in the last month or so, it also affects my game with ~ 50 concurrent players per server!

2 Likes

Thanks for this report! We’ll get back to you as soon as we have an update :slight_smile:

2 Likes