Servers keep going Slow and getting really high ping

  1. What do you want to achieve?
    I want to stop servers going slow

  2. What is the issue?
    Servers keep going slow

  3. What solutions have you tried so far?
    I’ve remade everything and put streaming enabled on and still the same results

I used normal .Touched events for checking if player touched checkpoint and kill part + teleporting to floors

Here is the game so you can see for yourself
Game: Super Easy Obby 🌟 100 Stages - Roblox

Here is a picture of servers when posting this


Here is a picture of ping

There’s not much people can do with this information but it’s probably due to poor optimisation in scripts

I said it’s done with touched events what else do you need? You all should know how touched events are used.

Is this better? Showing a example of killing parts?

for _,vKillParts in ipairs(game:GetService("Workspace").MainGame.Stages.KillParts:GetChildren()) do
	vKillParts.Touched:Connect(function(hit)
		if hit.Parent:FindFirstChild("Humanoid") then
			local Player = game.Players:GetPlayerFromCharacter(hit.Parent)
			if Player then
				if not KillsDebounces[Player.Name].Debounce then
					KillsDebounces[Player.Name].Debounce = false

					hit.Parent:FindFirstChild("Humanoid").Health = 0

					task.wait(0.2)
					if hit.Parent:FindFirstChild("Humanoid") then
						KillsDebounces[Player.Name].Debounce = false
					end	
				end
			end
		end
	end)
end

You mentioned touch events but didn’t specify that that was the issue, which is why I got confused

I’m still trying to figure out the issue myself, I contacted roblox support about this and they keep saying to restart my pc like that will help they are useless so I done this I thought I am just being dumb or something I’ve been trying to fix this for 2-3 days straight

I don’t really know what’s going on either, all I know is that FindFirstChild can sometimes cause lag when used a lot, so if there are lots of events and they are constantly being fired, it could be linked to that? Unlikely though

Man I’ve tried a TUN of stuff, I’ve tried just server and client TO server and same results. but I remember someone telling me about findfirstchild can make lag before. I’ve just tried doing waitforchild instead of findfirstchild and it just gave me a bunch of warnings.

check for any virus scripts. Normally they slow down your game

There ain’t any virus scripts I programmed the game myself.

are u using 1 or multiple scripts

I’ve tried both. and still the same results of slow servers

You’re looping through the entire workspace with this script. Maybe try making a killscript to detect when the parent is touched and add that to every kill part? If this only runs once then something else in your code must be the issue causing the ping.

Are you making sure to clean everything up when a player leaves and just in general removing unnecessary objects / indexes? This might be a memory leak.

It’s fixed now either I fixed it or roblox did it was really confusing I diddn’t know if it was a roblox bug or not.