Let me go into more detail, I am sending information from server to client in a remote event but I am getting nil as a response.
function checkKilled(plr, hit)
numofKillsEvent:FireClient(plr, 1) --the "1" is not getting through
print(data) --outputting nil
Ask me if you need more information.
Thanks for the Help!
Remove the “plr” argument on the OnClientEvent and only keep “data”, like this:
but, will it go to the right player?
When you use
FireClient, the 1st argument is the player that the event will be fired to, everything else are the arguments that are passed to the player (this means the “plr” argument isn’t passed)
(i’m not the best at explaining so sorry if it sounds weird)
After editing it, it is saying unable to cast value into an object, I am confused on what this means.
Did you remove the “plr” argument from the server-side or the client-side?
Only remove the “plr” in the client-side. Keep it at the server-side so the server knows who to fire the event at
oh…i see, that makes sense…that works, thanks a lot