I was working on a project and came across this issue. I have never came across the issue before and I just think that this is just a silly mistake in one of my scripts. I will send screenshots of all the scripts and problems. Also, this is for an inventory system.
When I try to fire a remote event from a local script, the server script won’t pick it up. Is this because I put a lot of parameters?
Here is the local script which fires the remote event:
Here is the server script which needs to pick up the remote event:
Here is the remote event in replicated storage:
Thanks, softdevv. If you need more of an explanation, just ask me because I know I’m a bit brief sometimes.
i just replied to someone that did this same thing. when you fire that EquipRemote, you dont need to send over the player, the remote event will already have the player as the first parameter, so the server would see it like this
I just tested and it is possible to send and receive 11 parameters of data + receiving the player on the server, of course. It would for sure be able to send or receive even more parameters of data.
As I can see, you have fewer parameters than what I tested which will most definitely work in your scenario. You sending four parameters of data is probably not a problem. The problem might be that you are sending incorrect data / receiving it incorrectly or maybe even handling the main statements/functions incorrectly.
If you are interested to see how I tested the 11 parameters which were successfully received and printed:
Client:
local Event = game.ReplicatedStorage.RemoteEvent
script.Parent.Parent.TextButton.MouseButton1Click:Connect(function()
local One = 1
local Two = "Test"
local Three = 0.123
local Four = "Roblox is an epic game for epic people!"
local Five = "Hey, this player sent this parameter of data. LOL."
local Six = 49
local Seven = true
local Eight = false
local Nine = "Those BoolValues worked."
local Ten = "Mhmmm."
local Eleven = "I'd say this works perfectly fine."
Event:FireServer(One, Two, Three, Four, Five, Six, Seven, Eight, Nine, Ten, Eleven)
end)
Server:
local Event = game.ReplicatedStorage.RemoteEvent
local function Test(Player, One, Two, Three, Four, Five, Six, Seven, Eight, Nine, Ten, Eleven)
print(Player.Name)
print(tostring(One))
print(Two)
print(tostring(Three))
print(Four)
print(Five)
print(tostring(Six))
print(Seven)
print(Eight)
print(Nine)
print(Ten)
print(Eleven)
end
Event.OnServerEvent:Connect(Test)