Zooming in first person with trail looks weird

What can I script to make the trail not appear while in first person? Here is the script I have so far that attaches it to the humanoid Root part:

local trail = game:GetService("ReplicatedStorage").Trails.BrownTrail

game.Players.PlayerAdded:Connect(function(plr)
        wait(5)

	trail.Parent = plr.Character.HumanoidRootPart
	local at0 = Instance.new("Attachment",plr.Character.HumanoidRootPart)
	at0.Name = "TrailAttachment0"
	local at1 = Instance.new("Attachment",plr.Character.Head)
	at1.Name = "TrailAttachment1"
	trail.Attachment0 = at0
	trail.Attachment1 = at1
end)

Have a good day!

You can probably (on the client) detect if the camera goes into first person/close to player.

Once it does, disable the trail on the client so that it disappears and only appears once you’ve zoomed out and or other players view you since it’ll be only invisible on the client.

2 Likes