Universal Script 📌
16.7k Views
3.0k Executions

Better First Person and Smooth Camera Movement

Universal Script 📌
AzScripter
AzScripter1M views
1 year ago
Get an executor
Please login to perform these actions:

Does it work?

No reports yet

No reports yet. Tried it? Be the first to say.

Also noticed:

Description

Features: - Swinging Camera - body visible in first person - customize script Update: - Camera Tracking Head / camera follows the x,y,z position of the head - When is in first person all R15 clothing is visible

View Raw
-- Script By @AzizAnzofficiall on Youtube
-- ScriptBlox Account @AzScripter

local Players = game:GetService("Players")
local RunService = game:GetService("RunService")

local player = Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
local humanoid = character:WaitForChild("Humanoid")
local camera = workspace.CurrentCamera

local head = character:WaitForChild("Head")
local hrp = character:WaitForChild("HumanoidRootPart")

local shakePower = 0
local targetFOV = 70
local fovSpeed = 10

local baseOffsetY = -1.5
local baseOffsetZ = -1
local bobAmount = 0.2
local bobSpeed = 2

local headAttachments = {"HatAttachment", "HairAttachment", "FaceFrontAttachment", "FaceCenterAttachment"}

player.CameraMode = Enum.CameraMode.Classic

RunService.RenderStepped:Connect(function()
	local isFirstPerson = (head.Position - camera.CFrame.Position).Magnitude < 2

	for _, part in ipairs(character:GetDescendants()) do
		if part:IsA("BasePart") then
			if part.Name == "Head" then
				part.LocalTransparencyModifier = isFirstPerson and 1 or 0
			elseif part.Name == "Handle" then
				local attachment = part:FindFirstChildOfClass("Attachment")
				if attachment and table.find(headAttachments, attachment.Name) then
					part.LocalTransparencyModifier = isFirstPerson and 1 or 0
				else
					part.LocalTransparencyModifier = 0


Comments

2
Log in to join the conversation. Login
superbillionaire's profile picture
superbillionaire5 months ago

w munchkin mans

1
marinoroman2014's profile picture
marinoroman20141 year ago

W bro

1

Tags

More universal scripts

See all
Universal Script 📌
3.8k
184.5k
Bumped 3 hours ago
Script hub
339
31
4 hours ago
Universal Script 📌
28.6k
663.4k
Bumped 6 hours ago
Script hub
13.7k
2.7k
Bumped 8 hours ago
Key System
Paid
Script hub
263.6k
88.1k
Bumped 8 hours ago
Key System
Universal Script 📌
2.9k
9.5k
Bumped 9 hours ago
Universal Script 📌
611
38
Approved 9 hours ago
Universal Script 📌
645
36
Approved 9 hours ago