Further enhance and make it so that it ONLY tracks the player without moving towards the player, it'll just follow the direction they're facing. Use cframe, heartbeat, renderstepped, and humanoid move.

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

-- Configuration
local TRACKED_TARGET = nil  -- Currently tracked target (player or model with humanoid)
local ROTATION_SPEED = 0.5  -- Adjust the rotation smoothing factor

local player = Players.LocalPlayer
local character = player.Character or player.CharacterAdded:Wait()
local humanoidRootPart = character:WaitForChild("HumanoidRootPart")
local humanoid = character:WaitForChild("Humanoid")

-- Variable to store ESP BillboardGui
local espBillboard = nil

-- Forward declarations of functions
local hasHumanoid
local updateESP
local onModelClicked
local faceTarget

-- Function to check if a model has a humanoid
hasHumanoid = function(model)
    return model:FindFirstChildOfClass("Humanoid") ~= nil
end

-- Function to update the ESP to show which model is being tracked
updateESP = function()
    if not espBillboard then
        -- Create the BillboardGui once
        espBillboard = Instance.new("BillboardGui")
        espBillboard.Name = "TargetESP"
        espBillboard.Size = UDim2.new(0, 100, 0, 40)
        espBillboard.StudsOffset = Vector3.new(0, 2, 0)
        espBillboard.AlwaysOnTop = true

        local textLabel = Instance.new("TextLabel")
        textLabel.Size = UDim2.new(1, 0, 1, 0)
        textLabel.Text = "Targeted"
        textLabel.TextColor3 = Color3.fromRGB(255, 0, 0)
        textLabel.BackgroundTransparency = 1
        textLabel.TextStrokeTransparency = 0.8
        textLabel.Parent = espBillboard

        espBillboard.Parent = player:WaitForChild("PlayerGui")
    end

    if TRACKED_TARGET then
        local targetHead = TRACKED_TARGET:FindFirstChild("Head")
        if targetHead then
            espBillboard.Adornee = targetHead
            espBillboard.Enabled = true
        else
            espBillboard.Enabled = false
        end
    else
        espBillboard.Enabled = false
    end
end

-- Optimized function to toggle selection on a new target or deselect the current one
onModelClicked = function(targetModel)
    -- Deselect if the same target is clicked again
    if TRACKED_TARGET == targetModel then
        TRACKED_TARGET = nil
    else
        TRACKED_TARGET = targetModel
    end

    -- Update ESP
    updateESP()
end

-- Function to face the target using Humanoid:Move()
faceTarget = function(targetModel)
    if targetModel and targetModel:FindFirstChild("HumanoidRootPart") then
        local targetHumanoidRootPart = targetModel:FindFirstChild("HumanoidRootPart")
        if targetHumanoidRootPart then
            local direction = (targetHumanoidRootPart.Position - humanoidRootPart.Position) * Vector3.new(1, 0, 1)
            if direction.Magnitude > 0 then
                -- Normalize the direction
                local moveDirection = direction.Unit
                -- Smoothly interpolate the current move direction towards the target direction
                local currentMoveDirection = humanoid.MoveDirection * Vector3.new(1, 0, 1)
                local newMoveDirection = currentMoveDirection:Lerp(moveDirection, ROTATION_SPEED)
                -- Move the humanoid in the new direction with zero speed
                humanoid:Move(newMoveDirection, false)
            end
        end
    end
end

-- Listen for player clicks to target or deselect a model
UserInputService.InputBegan:Connect(function(input, gameProcessed)
    if gameProcessed then return end
    if input.UserInputType == Enum.UserInputType.MouseButton1 then
        local mouse = player:GetMouse()
        local target = mouse.Target

        if target and target.Parent and hasHumanoid(target.Parent) then
            -- Toggle selection if the clicked target has a humanoid
            onModelClicked(target.Parent)
        else
            -- Deselect if clicking on an invalid target
            if TRACKED_TARGET then
                onModelClicked(TRACKED_TARGET)
            end
        end
    end
end)

-- Ensure the script continues working when the character respawns
player.CharacterAdded:Connect(function(newCharacter)
    character = newCharacter
    humanoidRootPart = newCharacter:WaitForChild("HumanoidRootPart")
    humanoid = newCharacter:WaitForChild("Humanoid")
end)

-- Run service to update the face tracking smoothly
RunService.RenderStepped:Connect(function()
    if TRACKED_TARGET then
        faceTarget(TRACKED_TARGET)
    else
        -- Stop moving when no target is selected
        humanoid:Move(Vector3.new(0, 0, 0), false)
    end
end)