I’m having a very small issue when sending the ServerMessage.
The issue is when I FireAllClients. When I pass the Mutator it seems like the middle is getting the Mutator from the top one, and the bottom one is getting the middle and top Mutator.
productHandlers[1615053567] = function(localPlayer)
workspace.Mutators.DoubleCoins.Value = true
Mutator = workspace.Mutators.DoubleCoins
ServerMessage:FireAllClients(localPlayer, Mutator)
end
productHandlers[1616661350] = function(localPlayer)
workspace.Mutators.DoubleJump.Value = true
Mutator = workspace.Mutators.DoubleJump
ServerMessage:FireAllClients(localPlayer, Mutator)
end
productHandlers[1617799800] = function(localPlayer)
workspace.Mutators.BunnyHop.Value = true
Mutator = workspace.Mutators.BunnyHop
ServerMessage:FireAllClients(localPlayer, Mutator)
end
here’s an image of the problem. 1 is the top, 2 is the middle, and 3 is the bottom.
Idk what’s going on here but I’ve tried few stuff a few stuff like putting Mutator in the function’s variables but that had no effect. I’ve also tried making them private with an underscore but I don’t know how to make it work.
productHandlers[1615053567] = function(localPlayer, Mutator)
workspace.Mutators.DoubleCoins.Value = true
Mutator = workspace.Mutators.DoubleCoins
ServerMessage:FireAllClients(localPlayer, Mutator)
end
I know this is probably a super easy fix I’ve just never done this before so I don’t know where to look. Also note that I’ve got a local script and when OnClientEvent, it basically types a message in chat of what the player bought and who bought it.
any help is very appreciated