Hi! I am creating a game where, when the player touches the button, the character jumps and adds 1 to the leaderboard. Unfortunately, one of the two scripts makes that only the player who clicks on the button sees his score but not the others (see the video) and I don't know how to make everyone see it, here are the two scripts: the button script:
script.Parent.MouseButton1Click:Connect(function()
local player = game.Players.LocalPlayer
local character = player.Character
local humanoid = character.Humanoid
if humanoid.FloorMaterial == Enum.Material.Air then return end
humanoid.JumpHeight += 1
player.leaderstats.JumpPwr.Value = player.leaderstats.JumpPwr.Value + 1
local oldJumpPower = humanoid.JumpPower
humanoid.JumpPower = 10
humanoid:ChangeState(Enum.HumanoidStateType.Jumping)
humanoid.JumpPower = oldJumpPower
end)
and the leaderboard script:
local players = game:GetService('Players')
players.PlayerAdded:Connect(function(player)
if player then
local folder = Instance.new('Folder')
folder.Name = 'leaderstats'
folder.Parent = player
local JumpPwr = Instance.new ('IntValue')
JumpPwr.Name = 'JumpPwr'
JumpPwr.Parent = folder
JumpPwr.Value = 0
end
end)
And theres the example video: https://streamable.com/a7uj6u Thanks in advance for your help and have a nice day!

3 comments
you are changing the value on Client (using LocalScript) this makes it only visible for this player, if you want to change for everybody you should change it on server, using RemoteEvents you can communicate with server using LocalScript
uWu i found your discord i spam there
nvm i got rejected :sob: