I created a tool which shoots a bomb in the position of the cursor
The script is supposed to give exp from the line
game.Players.LocalPlayer.leaderstats2.XP.Value = game.Players.LocalPlayer.leaderstats2.XP.Value + 10
However instead it gives an error
Is their a way to fix this?
Thank you for your time
For your situation, the following should work: (judging by your error)
local player = script.Parent.Parent.Parent --One parent is the tool, another parent is the backpack, the third parent is the player
--and then do your stuff....
player.leaderstats2........