so all i need left in my titan shift thing is to make it so that if they are a titan, they cant use it again. so since i havent made a scripting helpers post in a while you probably dont know what i am doing. i am making a titan shift tool from the anime "shingeki no kyojin" or "attack on titan" so i am trying to get the humanoid from a tool so it can check if the player is a titan by its size but idk if it is possible to get a humanoid through tool but i tried

local player = game:GetService("Players").LocalPlayer.Character.Humanoid
local bds = player.BodyDepthScale
local bhs = player.BodyHeightScale
local bps = player.BodyProportionScale
local bts = player.BodyTypeScale
local bws = player.BodyWidthScale
local hs = game.Workspace:FindFirstChild(player.name):WaitForChild("Humanoid").HeadScale
script.Parent.Equipped:Connect(function(Mouse)
	Mouse.Button1Down:Connect(function()
		animation = game.Players.LocalPlayer.Character.Humanoid:LoadAnimation(script.Parent.Titanshift)
		if bds.Value <= 50 and bhs.Value <= 50 and bps.Value <= 50 and bts.Value <= 50 and bws.Value <= 50 and hs.Value <= 50 then
			animation:Play()
			game.ReplicatedStorage.ColossalTitan:FireServer()
		end
	end)
end)

10 comments

0

I think it would work if you changed line 07 to "local hs = player.HeadScale"

0

oof i forgot

0

still

0

on line 1

0

try ":WaitForChild("Humanoid")" on line 01 like you did on line 07

0

attempt to index nil with 'WaitForChild'

0

I tried the script myself and solved it by inserting a line above everything else: "repeat wait() until game:IsLoaded()"

0

Is your script a local script ?

0

its local

0

Try to put the local script in StarterCharacterScripts in the StarterPlayer Service as I have faced this problem many times and putting the local script in there has prevented this error from happening. If it doesn't work, I don't know.