Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
1

did you forget to implement OnServerEvent?

Asked by 3 years ago
Edited 3 years ago

Ok so i tried making some visualizer in a mainmodule thing and it just came with the error : exhausted for Players.IEntity_303I.PlayerGui.Scripts.NewEvent; did you forget to implement OnServerEvent? (256 events dropped) local script :

game:GetService("RunService").RenderStepped:Connect(function()
script.Parent.NewEvent:FireServer(script.Parent.Object.Visualizer.Sound.PlaybackLoudness)
end) 

Server script :

script.Parent.NewEvent.OnServerEvent:Connect(function(Player,Loud)
    local PlaybackLoudness = Loud * 0.100
    if Player.Character:FindFirstChild("Visualizer") then
        local v = script.Parent.Object.Visualizer:Clone()
        if v then
            v.Parent = Player.Character
            v.CFrame = Player.Character.HumanoidRootPart.CFrame * CFrame.new(0,5,0)
            local weld = Instance.new("Weld")
            weld.Part0 = Player.Character.HumanoidRootPart
            weld.Part1 = v
            weld.C0 = Player.Character.HumanoidRootPart.CFrame:Inverse()
            weld.C1 = v.CFrame.Inverse()
            weld.Parent = Player.Character.HumanoidRootPart
        end
    end
end)

1 answer

Log in to vote
0
Answered by 3 years ago
Edited 3 years ago

Hmm... Maybe you are being rate limited? Try editing your local script to not be firing as many events.

On a side note, looking at the instance names, it seems you are building some sort of audio visualizer. May I ask why you need to send remotes to the server for this? There are some ways around what you are doing:

  1. If you are making music play on the server and the audio visualizer on the server, the client doesn't need involvement.

  2. If you are making music play on the client and the audio visualizer appear with the corresponding movements but local to the client, then the server doesn't need involvement.

  3. If you want to keep doing what you are doing now without altering your intended actions, you can use network ownership.

0
ok IEntity_303I 80 — 3y
0
ok IEntity_303I 80 — 3y
0
ok IEntity_303I 80 — 3y
0
Just tell me if it works. RetroGalacticGamer 331 — 3y
View all comments (3 more)
0
it happened the samew thing IEntity_303I 80 — 3y
0
brb i gotta go for a sec IEntity_303I 80 — 3y
0
its the same error mate IEntity_303I 80 — 3y
Ad

Answer this question