Hello everybody,
I’m getting this really frustrating error messages in my game and I can’t seem to find a reason or a solution to it.
This is the code where the error is coming from:
game:GetService("ReplicatedStorage").Remotes.Visual.ShadowClone.OnServerEvent:Connect(function(player)
local character = player.Character
local headc = character.Head
local torsoc = character.Torso
local rightarmc = character["Right Arm"]
local leftarmc = character["Left Arm"]
local rightlegc = character["Right Leg"]
local leftlegc = character["Left Leg"]
local meclone = game:GetService("ReplicatedStorage").Main.Abilities.Broly.BrolyBox["ShadowJutsu"]:Clone()
meclone.Head.Color = headc.Color
meclone.Torso.Color = torsoc.Color
meclone["Right Arm"].Color = rightarmc.Color
meclone["Left Arm"].Color = leftarmc.Color
meclone["Right Leg"].Color = rightlegc.Color
meclone["Left Leg"].Color = leftlegc.Color
meclone.Parent = workspace.FXFolder
meclone.Name = "Brocolli Clone"
--positioning
for _,par in ipairs(meclone:GetDescendants()) do
if par:IsA("BasePart") and player.Character:FindFirstChild(par.Name) then
par.CFrame = player.Character:FindFirstChild(par.Name).CFrame
par.CollisionGroupId = 1
delay(.025, function()
local ts = game:GetService("TweenService")
ts:Create(par, TweenInfo.new(1), {Transparency = 1, Color = Color3.fromRGB(0, 255, 0)}):Play()
end)
elseif par.Name == "Handle" then
local ts = game:GetService("TweenService")
par.CollisionGroupId = 1
ts:Create(par, TweenInfo.new(1), {Transparency = 1}):Play()
end
end
delay(.15, function()
game:GetService("Debris"):AddItem(meclone, 1)
end)
end)
Any kind of help would be appreciated.
How many times are you firing the event, 64 times seems like a lot of network traffic.
Based_Bern
(Based_Bern)
January 6, 2022, 6:55am
#3
Your script may be spamming the RemoteEvent by keeping on firing it.
Based_Bern
(Based_Bern)
January 6, 2022, 6:56am
#4
You also have to set up a listener for the RemoteEvent on the Server and Client.
Yeah about that…
I honestly couldn’t find another way to make this work.
The ShadowEvent is the remote where the error is coming from
Based_Bern
(Based_Bern)
January 6, 2022, 6:59am
#6
I think it’s because you did repeat.
What is this ability supposed to do? There’s probably a more efficient way.
Based_Bern
(Based_Bern)
January 6, 2022, 7:00am
#8
Your until is inside the repeat, so there may be an indentation error.
Judgy_Oreo
(DisplayName)
January 6, 2022, 7:01am
#9
The loop might be running before .OnServerEvent is connected
OilMerchant
(baldconductor)
January 6, 2022, 7:03am
#10
Alright so let me explain,
This code above is from a function that activates whenever a player holds “R”. It’s a barrage move and the shadowevent thing is just an effect.
Nevermind this is really hard to explain, I’ll just show it with a gif.
OilMerchant
(baldconductor)
January 6, 2022, 7:05am
#11
Judgy_Oreo
(DisplayName)
January 6, 2022, 7:08am
#12
Are there any wait()s above
?
The :Connect might be running after the event gets fired.
Try putting a print() above the :Connect and check if anything appears in the output.
OilMerchant
(baldconductor)
January 6, 2022, 7:16am
#13
Yeah it appeared in the output
1 Like
Judgy_Oreo
(DisplayName)
January 6, 2022, 7:19am
#14
I’ve just noticed, the error shows the remote event is in a folder called “Broly” under Abilities in the Main folder, and not “Visual” under Remotes, you might want to check that.
OilMerchant
(baldconductor)
January 6, 2022, 7:22am
#15
That’s really strange, in the script the remote is under visuals…
Judgy_Oreo
(DisplayName)
January 6, 2022, 7:23am
#16
The server script might be accessing the wrong remote, try changing it to the one in the error.
2 Likes
OilMerchant
(baldconductor)
January 6, 2022, 7:25am
#17
Oh my god you’re a lifesaver, tysm.