Hi, I’m trying to make a level-up system so when a player’s exp hits something they earn a level. But the output says that leaderstats is not a member of Players. I am still new to RemoteEvents with Server to Client and I’m not sure if there is a problem with me calling the player or parameters. Anyone have any solutions?
Try using WaitForChild()
instead of giving the path directly. This will pause the script until ‘leaderstats’ exists. Or, you never actually created a folder in the player.
In your function, you’re using the service Players instead of the player you have as a parameter.
Also, if your goal is to update the leaderstats value, you can’t do that in a client script and have it show up for everyone else.
check your script You put Players.leaderstats not player.leaderstats
btw this is similar to the above reply but much eaiser to understand
Line 9 to 11, you used “Player” instead of “player”
This person right here got it right!
trey using Player = game.Players.LocalPlayer
all is wrong with this script lol
Just add .LocalPlayer
at the end of local Player = game.Players
yeah, it is the on client event only can run via local script ._.
oh ok now i get it but my solution also works dosent it?
i dont think soooooooooooooooo
i guess it wont work not i will never get a solution from a topic
oh yea btw if you have problems for leaderstats its an easy fix, and changing the values from client aint gonna work so use a serverscript you dont need a useless remote its exploitable
if you cant fix it then your terrible at scripting
I’m sorry but this is coming from the man who couldn’t even tell if the script is a local script or a normal script, even though ‘OnClientEvent’ is client only. No offense.
On top of the Player variable needing to refer to the LocalPlayer, you can’t add to values on the client, you have to do it one the server either through remote events or remote functions.
Change the paramter at the top to
local Player = game.Players.LocalPlayer
And .OnClientEvent
does NOT have the player as a parameter, just use the one at the top as your player.
i think the error message is false the “worst” scripter migjt but OnclientEqvrnt not OnSercerEvent