TrussPart not working ingame, only in studio

I have a game where the Character can climb on every wall. To achieve this, I move a small trusspart to the front of the character when it raycasts something in front. This was working until some days ago, then stopped working for no reason. Wtf is happening?

This is a photo of how it should work in server, but only happens in studio:

image

I have tried putting a normal trusspart free in workspace and the character climbed it with no problems, only this one I create does not work.

Also, the trusspart exist only in client.

Here is the code:

local Players = game.Players
local Player = Players.LocalPlayer
local Character = Player.Character
local Root = Character:WaitForChild("HumanoidRootPart")

local nilPos = Vector3.new(0,10000000000000,0)

local raycastParams = RaycastParams.new()
raycastParams.FilterDescendantsInstances = {script.Parent, workspace.MouseIgnore}
raycastParams.FilterType = Enum.RaycastFilterType.Blacklist

local truss = Instance.new("TrussPart")
truss.Anchored = true
truss.Position = nilPos
truss.Transparency = 0.5
truss.CanCollide = true
truss.Parent = workspace.MouseIgnore

spawn(function()
	while true do
		wait()
		local raycastResult = workspace:Raycast(Root.Position, Root.CFrame.LookVector*2, raycastParams)

		if raycastResult then
			if raycastResult.Instance.Transparency == 0 then
				truss.Position = raycastResult.Position
			end
		end
	end
end)

Maybe your truss is still up in the nil position… The first truss to get to the null zone.

the truss can be seen in front of plr when is not transparent (like in the photo) while ingame too, he just dont climb it