PROJECTION SORCERY SCRIPT
Key RequiredUniversal

PROJECTION SORCERY SCRIPT

Universal Scriptyeetteet111yeetteet111 440 views 5.1K executesUpdated Jul 21, 2026
0.0/ 5(1 votes)
010% Positive
Lua Script•603 lines (20376 chars)
-- Naoya Projection: Procedural Animation Engine (Infinite Scaling & Horizon Gaze)
local Players = game:GetService("Players")
local RunService = game:GetService("RunService")
local TweenService = game:GetService("TweenService")
local Debris = game:GetService("Debris")

local player = Players.LocalPlayer
local character, humanoid, root
local rigType = Enum.HumanoidRigType.R6

-- State Variables
local isActive = false
local isExecuting = false 
local momentum = 0
local trailInterval = 0.05 
local lastTrailTime = 0
local lastPhaseUpdate = 0

-- Movement & Procedural Config
local BASE_ACCEL = 6.5      
local FRICTION = 0.30       
local distanceTraveled = 0
local lastMoveDir = Vector3.new(0, 0, 1)
local currentLean = 0

-- Drawing Variables
local isDrawing = false
local drawnFrames = {}
local drawInterval = 0.1 
local lastDrawTime = 0
local startClone = nil
local originalTransparencies = {}

-- Joint References for Procedural Animation
local rootMotor = nil
local originalRootC0 = nil
local neckMotor = nil
local originalNeckC0 = nil

local limbs = {RA = nil, LA = nil, RL = nil, LL = nil, RE = nil, LE = nil, RK = nil, LK = nil}
local originalC0 = {} 
local allMotors = {} 

-- ==========================================
-- SOUND EFFECTS
-- ==========================================
local teleportSound = Instance.new("Sound")
teleportSound.SoundId = "rbxassetid://82433875401352" 
teleportSound.Volume = 1
teleportSound.PlaybackSpeed = 1.2

-- ==========================================
-- RAW / STYLIZED UI SETUP
-- ==========================================
local screenGui = Instance.new("ScreenGui", player.PlayerGui)
screenGui.Name = "ProjectionSorceryUI"
screenGui.ResetOnSpawn = false 
screenGui.IgnoreGuiInset = true 

local topBar = Instance.new("Frame", screenGui)
topBar.Size = UDim2.new(1, 0, 0, 24)
topBar.Position = UDim2.new(0, 0, 0, 0)
topBar.BackgroundColor3 = Color3.fromRGB(0, 0, 0)
topBar.BackgroundTransparency = 0.25 
topBar.BorderSizePixel = 0
topBar.Visible = false

local topText = Instance.new("TextLabel", topBar)
topText.Size = UDim2.new(1, 0, 1, 0)
topText.Position = UDim2.new(0, 0, 0, 0)
topText.BackgroundTransparency = 1
topText.Text = "By YEETTEET"
topText.TextColor3 = Color3.fromRGB(255, 255, 255)
topText.Font = Enum.Font.Arial 
topText.TextSize = 18
topText.TextXAlignment = Enum.TextXAlignment.Center
topText.TextStrokeTransparency = 0.85 

local uiContainer = Instance.new("Frame", screenGui)
uiContainer.Size = UDim2.new(0, 200, 0, 70)
uiContainer.Position = UDim2.new(0.5, -100, 0.85, -35)
uiContainer.BackgroundTransparency = 1 
uiContainer.Visible = false

local function createRawButton(name, yPos, defaultText)
	local btn = Instance.new("TextButton", uiContainer)
	btn.Name = name
	btn.Size = UDim2.new(1, 0, 0, 30)
	btn.Position = UDim2.new(0, 0, 0, yPos)
	btn.BackgroundColor3 = Color3.fromRGB(10, 10, 10)
	btn.BorderSizePixel = 1
	btn.BorderColor3 = Color3.fromRGB(80, 80, 80)
	btn.TextColor3 = Color3.fromRGB(200, 200, 200)
	btn.Text = defaultText
	btn.Font = Enum.Font.Code
	btn.TextSize = 14
	btn.AutoButtonColor = false 
	return btn
end

local toggleButton = createRawButton("Toggle", 0, "[ PROJECTION: OFF ]")
local drawBtn = createRawButton("Draw", 40, "DRAW PATH")

local function applyRawHover(button)
	button.MouseEnter:Connect(function()
		button.BackgroundColor3 = Color3.fromRGB(200, 200, 200)
		button.TextColor3 = Color3.fromRGB(10, 10, 10)
	end)
	button.MouseLeave:Connect(function()
		button.BackgroundColor3 = Color3.fromRGB(10, 10, 10)
		if button.Name == "Toggle" then
			button.TextColor3 = isActive and Color3.fromRGB(150, 0, 255) or Color3.fromRGB(200, 200, 200)
		else
			button.TextColor3 = isDrawing and Color3.fromRGB(0, 255, 255) or Color3.fromRGB(200, 200, 200)
		end
	end)
end
applyRawHover(toggleButton)
applyRawHover(drawBtn)

-- ==========================================
-- INTRO SEQUENCE
-- ==========================================
task.spawn(function()
	local introFrame = Instance.new("Frame", screenGui)
	introFrame.Size = UDim2.new(1, 0, 1, 0)
	introFrame.BackgroundTransparency = 1
	
	local introImage = Instance.new("ImageLabel", introFrame)
	introImage.Size = UDim2.new(0, 300, 0, 300)
	introImage.Position = UDim2.new(0.5, -150, 0.5, -180)
	introImage.BackgroundTransparency = 1
	introImage.Image = "rbxthumb://type=Asset&id=111776532678554&w=420&h=420"
	introImage.ScaleType = Enum.ScaleType.Fit
	introImage.ImageTransparency = 1
	
	local introText = Instance.new("TextLabel", introFrame)
	introText.Size = UDim2.new(0, 400, 0, 50)
	introText.Position = UDim2.new(0.5, -200, 0.5, 120)
	introText.BackgroundTransparency = 1
	introText.Text = "PROJECTION SORCERY"
	introText.TextColor3 = Color3.fromRGB(150, 0, 255)
	introText.Font = Enum.Font.Oswald
	introText.TextSize = 36
	introText.TextTransparency = 1
	introText.TextStrokeTransparency = 0.8
	
	TweenService:Create(introImage, TweenInfo.new(0.8), {ImageTransparency = 0}):Play()
	TweenService:Create(introText, TweenInfo.new(0.8), {TextTransparency = 0}):Play()
	task.wait(2.5)
	
	TweenService:Create(introImage, TweenInfo.new(0.5), {ImageTransparency = 1}):Play()
	TweenService:Create(introText, TweenInfo.new(0.5), {TextTransparency = 1}):Play()
	task.wait(0.6)
	
	introFrame:Destroy()
	topBar.Visible = true
	uiContainer.Visible = true
end)

-- ==========================================
-- VISUALS & PHASING ENGINE
-- ==========================================
local function updatePhasing(shouldPhase)
	if not character then return end
	local phaseFolder = character:FindFirstChild("PhaseConstraints")
	if not phaseFolder then
		phaseFolder = Instance.new("Folder", character)
		phaseFolder.Name = "PhaseConstraints"
	end
	phaseFolder:ClearAllChildren()

	if shouldPhase then
		for _, otherPlayer in ipairs(Players:GetPlayers()) do
			if otherPlayer ~= player and otherPlayer.Character then
				for _, myPart in ipairs(character:GetChildren()) do
					if myPart:IsA("BasePart") then
						for _, theirPart in ipairs(otherPlayer.Character:GetChildren()) do
							if theirPart:IsA("BasePart") then
								local ncc = Instance.new("NoCollisionConstraint")
								ncc.Part0 = myPart
								ncc.Part1 = theirPart
								ncc.Parent = phaseFolder
							end
						end
					end
				end
			end
		end
	end
end

local function setPlayerVisibility(visible)
	if not character then return end
	for _, part in pairs(character:GetDescendants()) do
		if (part:IsA("BasePart") and part.Name ~= "HumanoidRootPart") or part:IsA("Decal") then
			if not visible then
				if originalTransparencies[part] == nil then originalTransparencies[part] = part.Transparency end
				part.Transparency = 1
			else
				if originalTransparencies[part] ~= nil then part.Transparency = originalTransparencies[part] end
			end
		end
	end
end

local function makeGlassFrame(clone)
	for _, child in pairs(clone:GetDescendants()) do
		if child:IsA("Humanoid") or child:IsA("Script") or child:IsA("LocalScript") or child:IsA("Accessory") or child:IsA("Shirt") or child:IsA("Pants") or child:IsA("ShirtGraphic") or child:IsA("Decal") then
			child:Destroy()
		elseif child:IsA("Motor6D") then
			local realMotor = character:FindFirstChild(child.Name, true)
			if realMotor and realMotor:IsA("Motor6D") then
				child.C0 = realMotor.C0 
				child.Transform = CFrame.new()
			end
		elseif child:IsA("BasePart") then
			if child:IsA("MeshPart") then child.TextureID = "" end
			child.Material = Enum.Material.Glass
			child.Color = Color3.fromRGB(100, 200, 255)
			child.Transparency = 0.4
			child.Reflectance = 0.2
			child.Anchored = true
			child.CanCollide = false
			child.CanTouch = false 
			child.CanQuery = false
			if child.Name == "HumanoidRootPart" then child:Destroy() end
		end
	end
end

local function createAfterimage()
	character.Archivable = true
	local clone = character:Clone()
	clone.Name = "ProjectionTrail" 
	makeGlassFrame(clone)
	
	for _, child in pairs(clone:GetDescendants()) do
		if child:IsA("BasePart") then
			TweenService:Create(child, TweenInfo.new(0.4, Enum.EasingStyle.Quad, Enum.EasingDirection.Out), {Transparency = 1}):Play()
		end
	end
	
	clone:PivotTo(character:GetPivot())
	clone.Parent = workspace
	Debris:AddItem(clone, 0.4) 
end

local function createStaticFrame(frameNumber)
	character.Archivable = true
	local clone = character:Clone()
	clone.Name = "ProjectionCheckpoint" 
	makeGlassFrame(clone)
	
	for _, child in pairs(clone:GetDescendants()) do
		if child:IsA("BasePart") then child.Transparency = 0.25 end
	end
	
	local primaryPart = clone:FindFirstChild("UpperTorso") or clone:FindFirstChild("Torso") or clone:FindFirstChild("Head")
	if primaryPart then
		local bbGui = Instance.new("BillboardGui", primaryPart)
		bbGui.Size = UDim2.new(0, 40, 0, 40)
		bbGui.StudsOffset = Vector3.new(0, 3, 0)
		bbGui.AlwaysOnTop = true
		
		local label = Instance.new("TextLabel", bbGui)
		label.Size = UDim2.new(1, 0, 1, 0)
		label.BackgroundTransparency = 1
		label.Text = tostring(frameNumber)
		label.TextColor3 = Color3.fromRGB(0, 255, 255)
		label.TextStrokeTransparency = 0
		label.Font = Enum.Font.Code
		label.TextScaled = true
	end
	
	clone.Parent = workspace
	return clone
end

-- ==========================================
-- RESET ENGINE HELPERS
-- ==========================================
local function resetJoints()
	if rootMotor and originalRootC0 then rootMotor.C0 = originalRootC0 end
	if neckMotor and originalNeckC0 then neckMotor.C0 = originalNeckC0 end
	for jointName, motor in pairs(limbs) do
		if motor and originalC0[jointName] then
			motor.C0 = originalC0[jointName]
		end
	end
end

-- ==========================================
-- EXECUTION ENGINE
-- ==========================================
local function toggleProjection(forceState)
	if isExecuting then return end
	isActive = forceState ~= nil and forceState or not isActive
	
	if isActive then
		toggleButton.Text = "[ PROJECTION: ACTIVE ]"
		toggleButton.TextColor3 = Color3.fromRGB(150, 0, 255)
		toggleButton.BorderColor3 = Color3.fromRGB(150, 0, 255)
		updatePhasing(true)
	else
		toggleButton.Text = "[ PROJECTION: OFF ]"
		toggleButton.TextColor3 = Color3.fromRGB(200, 200, 200)
		toggleButton.BorderColor3 = Color3.fromRGB(80, 80, 80)
		if humanoid then humanoid.WalkSpeed = 16 end
		updatePhasing(false)
		
		momentum = 0
		currentLean = 0
		resetJoints()
	end
end

local function executeDraw()
	if isExecuting then return end
	isDrawing = false
	isExecuting = true
	drawBtn.Text = "DRAW PATH"
	drawBtn.TextColor3 = Color3.fromRGB(200, 200, 200)
	drawBtn.BorderColor3 = Color3.fromRGB(80, 80, 80)
	
	setPlayerVisibility(true)
	
	local antiGravity = nil
	if root then
		antiGravity = Instance.new("BodyVelocity")
		antiGravity.MaxForce = Vector3.new(100000, 100000, 100000)
		antiGravity.Velocity = Vector3.zero
		antiGravity.Parent = root
	end
	
	if startClone and root then
		root.CFrame = startClone:GetPivot() 
		teleportSound:Play()
		task.wait(0.15)
		startClone:Destroy()
		startClone = nil
	end
	
	for i, frameData in ipairs(drawnFrames) do
		if root and frameData.CFrame then
			root.CFrame = frameData.CFrame
			root.AssemblyLinearVelocity = Vector3.zero 
			teleportSound:Play()
			
			local fakePhase = i * 0.8
			local swingA = math.rad(60 * math.sin(fakePhase))
			local swingL = math.rad(50 * math.sin(fakePhase))
			
			if limbs.RA and originalC0.RA then limbs.RA.C0 = originalC0.RA * CFrame.Angles(swingA, math.rad(-6), math.rad(4)) end
			if limbs.LA and originalC0.LA then limbs.LA.C0 = originalC0.LA * CFrame.Angles(-swingA, math.rad(6), math.rad(-4)) end
			if limbs.RL and originalC0.RL then limbs.RL.C0 = originalC0.RL * CFrame.Angles(-swingL, 0, math.rad(-1.5)) end
			if limbs.LL and originalC0.LL then limbs.LL.C0 = originalC0.LL * CFrame.Angles(swingL, 0, math.rad(1.5)) end
		end
		if frameData.Model then frameData.Model:Destroy() end
		task.wait(0.05) 
	end
	
	if antiGravity then antiGravity:Destroy() end
	drawnFrames = {}
	
	resetJoints()
	isExecuting = false
end

drawBtn.MouseButton1Click:Connect(function()
	if isExecuting then return end
	if not isActive then toggleProjection(true) end
	
	if isDrawing then
		task.spawn(executeDraw)
	else
		isDrawing = true
		drawnFrames = {}
		
		character.Archivable = true
		startClone = character:Clone()
		startClone.Name = "ProjectionStart"
		makeGlassFrame(startClone)
		startClone.Parent = workspace
		
		setPlayerVisibility(false)
		drawBtn.Text = "> TRACKING (24) <"
		drawBtn.TextColor3 = Color3.fromRGB(0, 255, 255)
		drawBtn.BorderColor3 = Color3.fromRGB(0, 255, 255)
		lastDrawTime = tick()
	end
end)

toggleButton.MouseButton1Click:Connect(function()
	if isDrawing then task.spawn(executeDraw) end
	toggleProjection()
end)

-- ==========================================
-- CHARACTER INITIALIZATION & RIG DETECTION
-- ==========================================
local function onCharacterAdded(newChar)
	character = newChar
	humanoid = character:WaitForChild("Humanoid")
	root = character:WaitForChild("HumanoidRootPart")
	rigType = humanoid.RigType
	
	task.delay(0.5, function()
		allMotors = {}
		originalC0 = {}
		
		for _, desc in ipairs(character:GetDescendants()) do
			if desc:IsA("Motor6D") then table.insert(allMotors, desc) end
		end
		
		if rigType == Enum.HumanoidRigType.R15 then
			rootMotor = character:FindFirstChild("Root", true) 
			neckMotor = character:FindFirstChild("Neck", true)
		else
			rootMotor = character:FindFirstChild("RootJoint", true) 
			neckMotor = character:FindFirstChild("Neck", true)
		end
		
		if rootMotor then originalRootC0 = rootMotor.C0 end
		if neckMotor then originalNeckC0 = neckMotor.C0 end
		
		limbs.RA = character:FindFirstChild("RightShoulder", true) or character:FindFirstChild("Right Shoulder", true)
		limbs.LA = character:FindFirstChild("LeftShoulder", true) or character:FindFirstChild("Left Shoulder", true)
		limbs.RL = character:FindFirstChild("RightHip", true) or character:FindFirstChild("Right Hip", true)
		limbs.LL = character:FindFirstChild("LeftHip", true) or character:FindFirstChild("Left Hip", true)
		
		if rigType == Enum.HumanoidRigType.R15 then
			limbs.RE = character:FindFirstChild("RightElbow", true)
			limbs.LE = character:FindFirstChild("LeftElbow", true)
			limbs.RK = character:FindFirstChild("RightKnee", true)
			limbs.LK = character:FindFirstChild("LeftKnee", true)
		else
			limbs.RE, limbs.LE, limbs.RK, limbs.LK = nil, nil, nil, nil
		end
		
		for jointName, motor in pairs(limbs) do
			if motor then originalC0[jointName] = motor.C0 end
		end
	end)
	
	teleportSound.Parent = root
	momentum = 0
	distanceTraveled = 0
	currentLean = 0
	isDrawing = false
	isExecuting = false
	drawnFrames = {}
	originalTransparencies = {}
end

player.CharacterAdded:Connect(onCharacterAdded)
if player.Character then onCharacterAdded(player.Character) end

-- ==========================================
-- DYNAMIC NATIVE ANIMATION MUTING
-- ==========================================
RunService.RenderStepped:Connect(function()
	if isActive and (momentum > 0.1 or isExecuting) then
		for _, motor in ipairs(allMotors) do
			motor.Transform = CFrame.new()
		end
	end
end)

-- ==========================================
-- MAIN PHYSICS & MOMENTUM LOOP
-- ==========================================
RunService.Heartbeat:Connect(function(dt)
	if not humanoid or not root or isExecuting then return end
	
	if isActive and tick() - lastPhaseUpdate > 1 then
		updatePhasing(true)
		lastPhaseUpdate = tick()
	end
	
	if isActive then
		humanoid.WalkSpeed = 1 
		local moveDir = humanoid.MoveDirection
		
		if moveDir.Magnitude > 0 then
			lastMoveDir = moveDir
			
			-- NEW INFINITE ACCELERATION CURVE
			-- Smoothly scales down acceleration as you go faster, but never hits a dead wall.
			local dynamicFactor = 1 / (1 + (momentum / 120))
			momentum = momentum + (BASE_ACCEL * dynamicFactor * dt * 60)
			
			local targetLean = math.clamp(momentum * 0.6, 0, 65) 
			currentLean = currentLean + (targetLean - currentLean) * 0.25
		else
			momentum = momentum * FRICTION
			if momentum < 1 then momentum = 0 end
			currentLean = currentLean + (0 - currentLean) * 0.45
		end
		
		if momentum > 0.1 then
			distanceTraveled = distanceTraveled + (momentum * dt)
			
			local targetPos = root.Position + (lastMoveDir * momentum * dt)
			local targetLookCFrame = CFrame.lookAt(Vector3.zero, Vector3.new(lastMoveDir.X, 0, lastMoveDir.Z))
			local currentLookCFrame = root.CFrame - root.Position
			local newLookCFrame = currentLookCFrame:Lerp(targetLookCFrame, 0.25) 
			
			root.CFrame = newLookCFrame + targetPos
			root.AssemblyLinearVelocity = Vector3.zero 
			
			if rootMotor and originalRootC0 then
				local stepBob = math.sin(distanceTraveled * 0.45) * 0.25 * math.clamp(momentum / 50, 0, 1)
				rootMotor.C0 = originalRootC0 * CFrame.new(0, stepBob, 0) * CFrame.Angles(math.rad(-currentLean), 0, 0)
			end
			
			-- CORRECTED HORIZON GAZE: Multiplier bumped to 0.90 to lock the face right onto the track ahead
			if neckMotor and originalNeckC0 then
				local scanYaw = math.rad(18 * math.sin(tick() * 2.5))
				local neckCompensation = currentLean * 0.90 
				
				neckMotor.C0 = originalNeckC0 * CFrame.Angles(math.rad(-neckCompensation), scanYaw, 0)
			end
			
			local armAmp = math.clamp(currentLean * 1.8, 0, 90) 
			local legAmp = math.clamp(currentLean * 1.5, 0, 80) 
			local runPhase = distanceTraveled * 0.42 
			
			local targetArmSwing = math.rad(armAmp * math.sin(runPhase))
			local targetLegSwing = math.rad(legAmp * math.sin(runPhase))
			
			if limbs.RA and originalC0.RA then limbs.RA.C0 = originalC0.RA * CFrame.Angles(targetArmSwing, math.rad(-6), math.rad(4)) end
			if limbs.LA and originalC0.LA then limbs.LA.C0 = originalC0.LA * CFrame.Angles(-targetArmSwing, math.rad(6), math.rad(-4)) end
			if limbs.RL and originalC0.RL then limbs.RL.C0 = originalC0.RL * CFrame.Angles(-targetLegSwing, 0, math.rad(-1.5)) end
			if limbs.LL and originalC0.LL then limbs.LL.C0 = originalC0.LL * CFrame.Angles(targetLegSwing, 0, math.rad(1.5)) end
			
			if rigType == Enum.HumanoidRigType.R15 then
				local currentElbowFlex = math.rad(75 + 15 * math.abs(math.sin(runPhase)))
				
				local rightLegVelocity = -math.cos(runPhase)
				local leftLegVelocity = math.cos(runPhase)
				
				local rKneeFlex = math.rad(15)
				local lKneeFlex = math.rad(15)
				
				if rightLegVelocity > 0 then
					rKneeFlex = rKneeFlex + (rightLegVelocity * math.rad(70))
				end
				if leftLegVelocity > 0 then
					lKneeFlex = lKneeFlex + (leftLegVelocity * math.rad(70))
				end
				
				if limbs.RE and originalC0.RE then limbs.RE.C0 = originalC0.RE * CFrame.Angles(currentElbowFlex, 0, 0) end
				if limbs.LE and originalC0.LE then limbs.LE.C0 = originalC0.LE * CFrame.Angles(currentElbowFlex, 0, 0) end
				if limbs.RK and originalC0.RK then limbs.RK.C0 = originalC0.RK * CFrame.Angles(-rKneeFlex, 0, 0) end
				if limbs.LK and originalC0.LK then limbs.LK.C0 = originalC0.LK * CFrame.Angles(-lKneeFlex, 0, 0) end
			end
			
			if not isDrawing and tick() - lastTrailTime > trailInterval and momentum > 5 then
				createAfterimage()
				lastTrailTime = tick()
			end
			
			if isDrawing and tick() - lastDrawTime > drawInterval and momentum > 2 then
				if #drawnFrames < 24 then
					local frameCount = #drawnFrames + 1
					local frame = createStaticFrame(frameCount)
					table.insert(drawnFrames, {Model = frame, CFrame = root.CFrame})
					drawBtn.Text = "> TRACKING (" .. (24 - frameCount) .. ") <"
					lastDrawTime = tick()
					
					if #drawnFrames >= 24 then
						task.spawn(executeDraw) 
					end
				end
			end
			
		else
			if currentLean > 0.1 then
				if rootMotor and originalRootC0 then
					rootMotor.C0 = rootMotor.C0:Lerp(originalRootC0 * CFrame.Angles(math.rad(-currentLean), 0, 0), 0.3)
				end
				if neckMotor and originalNeckC0 then
					local neckCompensation = currentLean * 0.90
					neckMotor.C0 = neckMotor.C0:Lerp(originalNeckC0 * CFrame.Angles(math.rad(-neckCompensation), 0, 0), 0.3)
				end
			else
				currentLean = 0
				if rootMotor and originalRootC0 then rootMotor.C0 = originalRootC0 end
				if neckMotor and originalNeckC0 then neckMotor.C0 = originalNeckC0 end
			end
			
			for jointName, motor in pairs(limbs) do
				if motor and originalC0[jointName] then
					motor.C0 = motor.C0:Lerp(originalC0[jointName], 0.45)
					if currentLean == 0 then
						motor.C0 = originalC0[jointName]
					end
				end
			end
		end
	end
end)

Features & Information

GO FAST BE NAOYA EXCLUSIVE PROCEDURAL ANIMATION DRAW FEATURE
#naoya#jujutsu#projection#sorcery#speed

Community Comments (2)

sa*avrilchuk1sa*avrilchuk1Sep 9, 2026

thats cool but where is controll for pc

sa*avrilchuk1sa*avrilchuk1Sep 9, 2026

and wth with my movement

More Scripts for Universal Scripts