I would like the remote to not spam fire. How will I go about this?
infoUI.Equip.MouseButton1Click:Connect(function() game.ReplicatedStorage.Equip:FireServer(itemSelected.ItemId); itemSelected.Equipped = not itemSelected.Equipped if itemSelected.Equipped == true then infoUI.Equip.Text = 'Unequip'; else infoUI.Equip.Text = 'Equip'; end end)
I tried adding a debounce on the remote itself, but it still fires consistently anyway so eventually it stops datastore request and errors, and creates data loss. Please help. If you need any more code from my system, I am willing to provide it.
Edit: I added a
return and a client sided debounce, it still spam fires, just doesn’t lag the client. Any fix this time?