Getting a print message saying 'LivignArt_SSN'

Script is,

local Workspace = game.Workspace
local StarterGui = game.StarterGui
local ReplicatedStorage = game.ReplicatedStorage
local RemoteEvent = ReplicatedStorage:WaitForChild("RemoteEvent")
local barrier = Workspace:WaitForChild("Levels"):WaitForChild("LevelSun"):WaitForChild("MercuryGravityBarrier")
local runbefore = false
local function changegravityGUI()
	local GravityIndicatorMercury = StarterGui.ScreenGui.GravityIndicatorSun:clone()
	GravityIndicatorMercury.Parent = StarterGui.ScreenGui
	GravityIndicatorMercury.Name = 'GravityIndicatorMercury'
	GravityIndicatorMercury.Zindex = 3
	GravityIndicatorMercury.Image = 'rbxassetid://117685724959818'
end
local function touched(hit)
	if runbefore == false then
		print('hi')
		runbefore = true
		local humanoid = hit.Parent:FindFirstChild("Humanoid")
		print(hit.Parent)
		print(humanoid)
		if humanoid == 'Humanoid' then
			changegravityGUI()
			print('worked')
			RemoteEvent:FireServer(196.2 * 0.38)
		end
	end
end
barrier.Touched:Connect(touched)
--edit

But from line 19

		print(hit.Parent)

I’m getting the message
Screenshot 2024-12-23 at 3.30.36 PM

its printing the parent of the object that touched the barrier. so if a players arm touched the barrier it would print the parent of the arm, which is just the character.

1 Like

Thanks, that’s the name of one of my avatar accessories.