How to intentionally lag yourself to test game mechanics?

I would like to intentionally lag myself in terms of Frames per second and ping.

It’s pretty straight forward how to cause lag for your self in terms of FPS you would just need to hog up how much work is done each frame.

However, I want to test my client-server communication between scripts especially on poor Wi-Fi connections but I’m not sure how. I could make my own Wi-Fi worse? Or is there a way to limit my ping?

If anyone has any ideas let me know. :smile:

2 Likes

Buy a low end kindle used for $60 on amazon.

4 Likes

I have a kindle tablet that I never use but it won’t reduce my network performance. Although I could try making all the devices in my house take up bandwidth.

1 Like

Having poor Wi-Fi essentially increases the time delay between each Client-Server communication. The typical delay for normal connections is around 0.15 seconds, but it can increase to several seconds with a poor connection. One way to simulate this in the studio would be to add a task.wait() at the beginning of each Client-Server communication, as shown in the following example:

--Client
RemoteEvent:FireServer()

--Server
RemoteEvent.OnServerEvent:Connect(function()
    task.wait(0.5) --Simulate the communication delay of the client's poor connection
    --do your things
end)
2 Likes

To lower your FPS, I would personally recommend calculating alot of noise values with every render step on the client, noise is probably the most effective at creating lag and consuming resources, and probably easier to control too if you wanted to stay at a target FPS. (OR you could just use an FPS Unlocker, or use the FPS limit in the roblox settings menu)

I don’t know too much about how to add extra ping though.

you can set a custom ping in studio
go to studio setting and then Network and then change this value
{AD71F944-77B8-4E44-83F1-14D4FF4C3236}
ping after playtesting in studio with empty baseplate

3 Likes

Studio has an “incoming replication lag” setting.

There is a plugin that allows you to drop your FPS down as desired.

You can also increase network lag by going to studio settings > network > incoming replication lag.

As others have mentioned using the Incoming Replication Lag setting to add a flat amount of latency in studio settings. You can also simulate other connection issues e.g packet dropping on Windows with Clumsy.