local PoBox = game.Workspace.Assets.PostBox31
local Posting = game.Players.LocalPlayer:FindFirstChild("Posting")
Posting.Value = false
PoBox.ClickDetector.MouseClick:Connect(function(clicked)
if Posting.Value == true then
game.ReplicatedStorage.AlreadyPosting:FireClient()
print("Already posted fired")
else
game.ReplicatedStorage.PostingStarted:FireClient()
print("Fired")
end
end)
Output:
17:07:25.565 - Workspace.Assets.PostBox31.PostingScript:2: attempt to index nil with 'FindFirstChild'
17:07:25.566 - Stack Begin
17:07:25.566 - Script 'Workspace.Assets.PostBox31.PostingScript', Line 2
17:07:25.567 - Stack End
Using WaitForChild shows the error: 17:18:35.169 - Workspace.Assets.PostBox31.PostingScript:2: attempt to index nil with 'WaitForChild'

1 comment
Could be the LocalPlayer hasnt finished loading in. (not 100% sure) You could try using game.Players.LocalPlayer:WaitForChild("Posting")