Status
Key Required

Status

Kick Ball! ⚽ [NEW]NolanzNolanz 16.7K views 312 executesUpdated Apr 15, 2025
2.5/ 5(2 votes)
1150% Positive
Lua Script•182 lines (6237 chars)
local RunService = game:GetService("RunService")
local Players = game:GetService("Players")
local Debris = game:GetService("Debris")

local LocalPlayer = Players.LocalPlayer
local Character = LocalPlayer.Character or LocalPlayer.CharacterAdded:Wait()
local HumanoidRootPart = Character:WaitForChild("HumanoidRootPart")

local Rayfield = loadstring(game:HttpGet("https://sirius.menu/rayfield"))()
local Window = Rayfield:CreateWindow({
    Name = "Ball Monitor",
    Theme = "Serenity",
    ConfigurationSaving = {
        Enabled = true,
        FolderName = "DragnirBallMonitor",
        FileName = "Config"
    }
})

local StatusTab = Window:CreateTab("Ball Status")
local StatusParagraph = StatusTab:CreateParagraph({
    Title = "Ball Monitoring System",
    Content = "Initializing..."
})

local TargetTraceTab = Window:CreateTab("Ball Target Trace")
local TargetTraceParagraph = TargetTraceTab:CreateParagraph({
    Title = "Ball Target Chain",
    Content = "Tracking..."
})

local lastPosition = nil
local lastVelocity = nil
local lastTime = os.clock()
local totalSpeed = 0
local speedMeasurements = 0

local currentTarget = nil
local previousTarget = nil

local function GetTargetedPlayer()
    for _, player in ipairs(Players:GetPlayers()) do
        if player.Character and player.Character:FindFirstChildWhichIsA("Highlight", true) then
            return player
        end
    end
    return nil
end

local function CalculateCollisionTime(ballPosition, ballVelocity, targetPosition)
    local distance = (targetPosition - ballPosition).Magnitude
    local speed = ballVelocity.Magnitude
    if speed == 0 then
        return math.huge
    end
    return distance / speed -- Time = Distance / Speed
end

local function MonitorBall()
    local ball = workspace:FindFirstChild("gamespace") and workspace.gamespace:FindFirstChild("ball") and workspace.gamespace.ball:FindFirstChild("origin")
    if not ball then
        return "Ball not found in workspace."
    end

    local currentTime = os.clock()
    local deltaTime = currentTime - lastTime
    lastTime = currentTime

    local currentPosition = ball.Position
    local currentVelocity = ball.Velocity
    local acceleration = Vector3.zero
    if lastVelocity then
        acceleration = (currentVelocity - lastVelocity) / math.max(deltaTime, 0.01)
    end
    
    local verticalSpeed = currentVelocity.Y
    local horizontalSpeed = Vector3.new(currentVelocity.X, 0, currentVelocity.Z).Magnitude
    local direction = currentVelocity.Magnitude > 0 and currentVelocity.Unit or Vector3.zero
    local rotation = ball.RotVelocity
    local angularVelocity = rotation.Magnitude
    
    totalSpeed = totalSpeed + currentVelocity.Magnitude
    speedMeasurements = speedMeasurements + 1
    local averageSpeed = totalSpeed / speedMeasurements

    lastVelocity = currentVelocity
    lastPosition = currentPosition
    
    local targetedPlayer = GetTargetedPlayer()
    local targetInfo = targetedPlayer and ("🎯 Targeted Player: " .. targetedPlayer.Name) or "🎯 Targeted Player: None"
    local distanceToTarget = targetedPlayer and (targetedPlayer.Character.PrimaryPart.Position - ball.Position).Magnitude or 0
    local collisionTime = targetedPlayer and CalculateCollisionTime(ball.Position, ball.Velocity, targetedPlayer.Character.PrimaryPart.Position) or math.huge
    
    local motionStatus = "Stationary"
    if currentVelocity.Magnitude > 0.1 then
        motionStatus = "In Motion"
    end
    
    local warnings = ""
    if currentVelocity.Magnitude < 0.01 and angularVelocity < 0.01 then
        warnings = "⚠️ Warning: Ball is stationary."
    end
    
    return string.format(
        "Advanced Ball Monitoring Report\n\n" ..
        "📍 Position: (%.2f, %.2f, %.2f)\n" ..
        "💨 Velocity: (%.2f, %.2f, %.2f)\n" ..
        "⚡ Speed: %.2f studs/sec\n" ..
        "📈 Acceleration: (%.2f, %.2f, %.2f)\n" ..
        "↕️ Vertical Speed: %.2f\n" ..
        "➡️ Horizontal Speed: %.2f\n" ..
        "🧭 Direction Vector: (%.2f, %.2f, %.2f)\n" ..
        "🔁 Rotation: (%.2f, %.2f, %.2f)\n" ..
        "🔄 Angular Velocity: %.2f radians/sec\n" ..
        "📊 Average Speed: %.2f studs/sec\n" ..
        "📜 Motion Status: %s\n\n" ..
        "%s\n" ..
        "📏 Distance to Target: %.2f studs\n" ..
        "⏱️ Predicted Collision Time: %.2f seconds\n\n" ..
        "%s",
        currentPosition.X, currentPosition.Y, currentPosition.Z,
        currentVelocity.X, currentVelocity.Y, currentVelocity.Z,
        currentVelocity.Magnitude,
        acceleration.X, acceleration.Y, acceleration.Z,
        verticalSpeed,
        horizontalSpeed,
        direction.X, direction.Y, direction.Z,
        rotation.X, rotation.Y, rotation.Z,
        angularVelocity,
        averageSpeed,
        motionStatus,
        targetInfo,
        distanceToTarget,
        collisionTime,
        warnings
    )
end

local function UpdateBallTargetTrace()
    local ball = workspace:FindFirstChild("gamespace") and workspace.gamespace:FindFirstChild("ball") and workspace.gamespace.ball:FindFirstChild("origin")
    if not ball then
        return "Ball not found in workspace."
    end
    
    local targetPlayer = GetTargetedPlayer()
    
    if targetPlayer and targetPlayer ~= currentTarget then
        previousTarget = currentTarget
        currentTarget = targetPlayer
    end
    
    local currentName = currentTarget and currentTarget.Name or "None"
    local previousName = previousTarget and previousTarget.Name or "None"
    local isTargeted = tostring(currentTarget ~= nil)
    
    return string.format(
        "Ball Target Trace\n\n" ..
        "🎯 Current Target: %s\n" ..
        "🔄 Is Targeted: %s\n" ..
        "⏪ Previous Target: %s",
        currentName,
        isTargeted,
        previousName
    )
end

task.spawn(function()
    while task.wait(0.015) do
        if StatusParagraph then
            StatusParagraph:Set({
                Title = "Ball Monitoring System",
                Content = MonitorBall()
            })
        end
        if TargetTraceParagraph then
            TargetTraceParagraph:Set({
                Title = "Ball Target Chain",
                Content = UpdateBallTargetTrace()
            })
        end
    end
end)

Features & Information

-- Made w ChatGPT -- [•] Ball Status {Tab} [✔] Real-time position tracking (X, Y, Z) [✔] Velocity vector + total speed in studs/sec [✔] Acceleration vector calculation [✔] Horizontal & vertical speed separation [✔] Average speed over time [✔] Rotation vector (RotVelocity) + angular velocity (radians/sec) [✔] Motion status (In Motion / Stationary) [✔] Warning if completely still (velocity + rotvelocity) --- [•] Ball Target Trace {Tab} [✔] Highlights current targeted player (via Highlight instance) [✔] Displays previously targeted player [✔] Predicts collision time with current target (Distance / Speed) [✔] Tracks distance to target in studs [✔] Dynamic switching of current/previous target --- [•] Smart Update Loop [✔] Uses task.spawn and task.wait(0.015) for fast, efficient updates (~66 FPS) [✔] Zero memory buildup using os.clock and rolling averages [✔] Minimal garbage creation—optimized math usage --- [•] UI System [✔] Rayfield UI with Serenity theme [✔] Saved configuration using DragnirBallMonitor/Config [✔] Organized tabs: Ball Status + Target Trace [✔] Uses dynamic paragraphs with live updating content
#Universal

Community Comments (2)

MaggieMaggieApr 15, 2025

Does it work?

NolanzNolanzApr 15, 2025(edited)

@Maggie Yeah, it works, but like the *le says, it’s just a script that shows the status, no auto-parry or anything yet. I’m working on it, but it’s not there just yet.

More Scripts for Kick Ball! ⚽ [NEW]