How to modify my script to do this

Hello there I need help modify my script because I want prevent from this
It’s doing camera isn’t at correct Cframe
https://gyazo.com/0631faeb56824b9bb13a0ffa78967e64
Script here

local RunService = game:GetService("RunService")

local TweenService = game:GetService("TweenService")

local Player = game.Players.LocalPlayer

local Character = Player.Character

local InfoTween = TweenInfo.new(0.00001,Enum.EasingStyle.Sine,Enum.EasingDirection.In)
local Camera = game.Workspace.CurrentCamera

RunService.Stepped:Connect(function()

	if not Character then  print("Player character isn't here") end
	pcall(function()
    for _,parts in pairs(Character:GetChildren()) do
			parts.LocalTransparencyModifier = 0
	end
	end)

end)

I don’t know how
So thank for all tips
Pixeluted

In this case it would be alright to use RenderStepped to update the LocalTransparencyModifier of the parts (you might need to specifically use BindToRenderStep as that’s how it’s implemented in the PlayerModule) and the camera as well. You’ll have to set the CameraType to Scriptable and make the Camera’s CFrame a little forward from the character’s head. Alternatively, if you don’t want to bother with that logic and retain default camera behaviours, use CameraOffset.

1 Like