ps local script
local player = game.Players.LocalPlayer
If player.Character:FindFirstChild("Head") then
print("found")
end
Error says no character
ps local script
local player = game.Players.LocalPlayer
If player.Character:FindFirstChild("Head") then
print("found")
end
Error says no character
Ok, you indexed the variable player to game.Players.LocalPlayer before the LocalPlayer even existed. To prevent from doing that, you should have
repeat wait() until game:GetService'Players'.LocalPlayer and game:GetService'Players'.LocalPlayer.Character
then you can index a variable for them
and you also have a capital I in your if statement, it should be lowercase
repeat wait() until game:GetService'Players'.LocalPlayer and game:GetService'Players'.LocalPlayer.Character
local player = game.Players.LocalPlayer
local character = player.Character
If character:FindFirstChild("Head") then
print("found")
end
This discussion is preserved as it was. New answers, comments, and votes are closed.