Could this possibly lag the game badly?

So for my emote equipping system, Its mostly based off the one from Nico’s nextbots (or just any game with multiple emote slots lol) So you can click on an emote in your inventory, and click on a slot to add it there, And if you have an emote selected, and click on a slot that is already that emote, Then it will set that emote to “none”
Video example (from NN, Not my game.)


You might say i should use cooldowns, But a cooldown for switching emote slots might be a little confusing to some players (I can still implement this, however)
Nico’s nextbots has no cooldown (as shown in video)

So the way it works in my game, is whenever you switch a slot, It fires a remote event to the server (All it does on the server is change a value and do some checks.) And this cannot be handled fully on the server, otherwise the lag would be worse since like a ton of GUI would be handled on the server, Plus i dont think it would even work.

(Also just a small question, How could i check if everything in a string can be found in a folder? like for example: string: “Apple,Pizza,Chicken,Chocolate Milk” in order for “Good” to print, all those strings must be found in the “Food” folder, however, if the string is “Apple,Pizza,Chicken,Nil” then only check the strings that dont say “Nil”)

Judging from the video, the slots that show what’s equipped are static images. Unless you are changing your slots thousands of times a second there won’t normally be any issues with lag.

I’m almost all cases, GUI should never be programmed on the server, locally is the best route.

If you are really worried about any lag caused by this, you can use this Rate Limiter Module for that.

For the strings, you can split it by the commas then use the resulting table to check if the value is inside of a specific folder using a for loop.

Players can’t do that, But Autoclickers can, Maybe i should add a short cooldown?

I see, But how could i make it print/do something after it made sure all those values were found in a folder, unless the value is “Nil”?