Universal Script for Aimbot, Fling and other fun featuers
Just a baseplate Keyless
Universal Script for Aimbot, Fling and other fun featuers
👤 alexriderr 👁 14 views ❤️ 0 likes ⏱ Apr 2, 2026
This script is developed by KAaMs Hub and can be used across most Roblox games with ease. It also works smoothly with the Xeno executor.
✨ Features
God mode Visuals Fling Fun Cosmetics Fly Teleport Noclip Aimbot Rainbow avatar Invisible Rainbow trail Fling players Infinite jump ESP etc.
📋 Script Code
-- ============================================================
--  kAaMs Hub  |  LocalScript → StarterPlayerScripts
--  Requires FlingHandler Script in ServerScriptService
-- ============================================================

local Players          = game:GetService("Players")
local RunService       = game:GetService("RunService")
local UserInputService = game:GetService("UserInputService")
local TweenService     = game:GetService("TweenService")
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local Lighting         = game:GetService("Lighting")

local ME = Players.LocalPlayer
local function getChar() return ME.Character end
local function getHRP()  local c=getChar(); return c and c:FindFirstChild("HumanoidRootPart") end
local function getHum()  local c=getChar(); return c and c:FindFirstChildOfClass("Humanoid") end

local FlingRE = ReplicatedStorage:WaitForChild("kAaMsFling", 10)

-- ── Palette ───────────────────────────────────────────────────────────
local C = {
    bg       = Color3.fromRGB(22,22,32),   sidebar  = Color3.fromRGB(15,15,22),
    card     = Color3.fromRGB(30,30,44),   border   = Color3.fromRGB(48,48,68),
    accent   = Color3.fromRGB(99,102,241), green    = Color3.fromRGB(34,197,94),
    orange   = Color3.fromRGB(234,88,12),  red      = Color3.fromRGB(210,50,50),
    yellow   = Color3.fromRGB(234,179,8),  text     = Color3.fromRGB(220,220,232),
    sub      = Color3.fromRGB(130,130,155),pill_off = Color3.fromRGB(50,50,72),
    row      = Color3.fromRGB(26,26,38),   row_sel  = Color3.fromRGB(40,38,72),
    teal     = Color3.fromRGB(20,184,166), pink     = Color3.fromRGB(236,72,153),
    purple   = Color3.fromRGB(168,85,247),
}

local TW = TweenInfo.new(0.14, Enum.EasingStyle.Quad)

local function mkCorner(p,r) local o=Instance.new("UICorner"); o.CornerRadius=UDim.new(0,r or 8); o.Parent=p end
local function mkStroke(p,col,th) local o=Instance.new("UIStroke"); o.Color=col or C.border; o.Thickness=th or 1; o.Parent=p end
local function mkFrame(p,props) local f=Instance.new("Frame"); f.BorderSizePixel=0; for k,v in pairs(props) do f[k]=v end; f.Parent=p; return f end
local function mkLabel(p,props) local l=Instance.new("TextLabel"); l.BackgroundTransparency=1; l.TextXAlignment=Enum.TextXAlignment.Left; l.Font=Enum.Font.GothamBold; for k,v in pairs(props) do l[k]=v end; l.Parent=p; return l end
local function mkBtn(p,props) local b=Instance.new("TextButton"); b.BorderSizePixel=0; b.Font=Enum.Font.GothamBold; for k,v in pairs(props) do b[k]=v end; b.Parent=p; return b end

local old=ME.PlayerGui:FindFirstChild("kAaMsHub"); if old then old:Destroy() end

-- ══════════════════════════════════════════════════════════════════════
--  WINDOW
-- ══════════════════════════════════════════════════════════════════════
local SG=Instance.new("ScreenGui"); SG.Name="kAaMsHub"; SG.ResetOnSpawn=false
SG.ZIndexBehavior=Enum.ZIndexBehavior.Sibling; SG.Parent=ME.PlayerGui

local WIN=mkFrame(SG,{Size=UDim2.new(0,580,0,460),Position=UDim2.new(0.5,-290,0.5,-230),
    BackgroundColor3=C.bg,Active=true,Draggable=true})
mkCorner(WIN,14); mkStroke(WIN,C.border,1.2)

local SB=mkFrame(WIN,{Size=UDim2.new(0,148,1,0),BackgroundColor3=C.sidebar})
mkCorner(SB,14)
mkFrame(SB,{Size=UDim2.new(0,14,1,0),Position=UDim2.new(1,-14,0,0),BackgroundColor3=C.sidebar})
mkLabel(SB,{Size=UDim2.new(1,0,0,30),Position=UDim2.new(0,0,0,12),Text="⚡",TextSize=24,TextColor3=C.accent,TextXAlignment=Enum.TextXAlignment.Center})
mkLabel(SB,{Size=UDim2.new(1,0,0,16),Position=UDim2.new(0,0,0,44),Text="kAaMs hub",TextSize=12,TextColor3=C.text,TextXAlignment=Enum.TextXAlignment.Center})
mkFrame(SB,{Size=UDim2.new(1,-20,0,1),Position=UDim2.new(0,10,0,68),BackgroundColor3=C.border})

local TAB_LIST=mkFrame(SB,{Size=UDim2.new(1,0,1,-80),Position=UDim2.new(0,0,0,76),BackgroundTransparency=1})
do
    local ul=Instance.new("UIListLayout"); ul.SortOrder=Enum.SortOrder.LayoutOrder; ul.Padding=UDim.new(0,4); ul.Parent=TAB_LIST
    local up=Instance.new("UIPadding"); up.PaddingLeft=UDim.new(0,8); up.PaddingRight=UDim.new(0,8); up.PaddingTop=UDim.new(0,4); up.Parent=TAB_LIST
end
mkLabel(SB,{Size=UDim2.new(1,0,0,18),Position=UDim2.new(0,0,1,-22),Text="[ 5 ]  Toggle",TextSize=10,TextColor3=C.sub,TextXAlignment=Enum.TextXAlignment.Center})

local CONTENT=mkFrame(WIN,{Size=UDim2.new(1,-156,1,-8),Position=UDim2.new(0,152,0,4),BackgroundTransparency=1})
local PAGE_TITLE=mkLabel(CONTENT,{Size=UDim2.new(1,-44,0,44),Text="Movement",TextSize=16,TextColor3=C.text})
local CLOSE=mkBtn(CONTENT,{Size=UDim2.new(0,26,0,26),Position=UDim2.new(1,-30,0,9),BackgroundColor3=C.red,Text="✕",TextColor3=C.text,TextSize=12})
mkCorner(CLOSE,6); CLOSE.MouseButton1Click:Connect(function() WIN.Visible=false end)

local SCROLL=Instance.new("ScrollingFrame")
SCROLL.Size=UDim2.new(1,0,1,-48); SCROLL.Position=UDim2.new(0,0,0,48)
SCROLL.BackgroundTransparency=1; SCROLL.BorderSizePixel=0
SCROLL.ScrollBarThickness=3; SCROLL.ScrollBarImageColor3=C.accent
SCROLL.CanvasSize=UDim2.new(0,0,0,0); SCROLL.AutomaticCanvasSize=Enum.AutomaticSize.Y
SCROLL.Parent=CONTENT
do
    local ul=Instance.new("UIListLayout"); ul.SortOrder=Enum.SortOrder.LayoutOrder; ul.Padding=UDim.new(0,8); ul.Parent=SCROLL
    local up=Instance.new("UIPadding"); up.PaddingLeft=UDim.new(0,4); up.PaddingRight=UDim.new(0,10); up.PaddingTop=UDim.new(0,4); up.Parent=SCROLL
end

-- ══════════════════════════════════════════════════════════════════════
--  TAB SYSTEM
-- ══════════════════════════════════════════════════════════════════════
local tabData={}; local tabCount=0
local function makeTab(icon,name)
    tabCount+=1; local order=tabCount
    local btn=mkBtn(TAB_LIST,{Size=UDim2.new(1,0,0,34),BackgroundColor3=C.sidebar,Text="",LayoutOrder=order}); mkCorner(btn,8)
    local ic=mkLabel(btn,{Size=UDim2.new(0,22,1,0),Position=UDim2.new(0,8,0,0),Text=icon,TextSize=13,TextColor3=C.sub,TextXAlignment=Enum.TextXAlignment.Center})
    local lb=mkLabel(btn,{Size=UDim2.new(1,-34,1,0),Position=UDim2.new(0,32,0,0),Text=name,TextSize=11,TextColor3=C.sub})
    local bar=mkFrame(btn,{Size=UDim2.new(0,3,0.6,0),Position=UDim2.new(0,0,0.2,0),BackgroundColor3=C.accent,Visible=false}); mkCorner(bar,2)
    local page=mkFrame(SCROLL,{Name=name.."Page",Size=UDim2.new(1,0,0,0),AutomaticSize=Enum.AutomaticSize.Y,BackgroundTransparency=1,Visible=false,LayoutOrder=order})
    do local ul=Instance.new("UIListLayout"); ul.SortOrder=Enum.SortOrder.LayoutOrder; ul.Padding=UDim.new(0,8); ul.Parent=page end
    tabData[name]={btn=btn,ic=ic,lb=lb,bar=bar,page=page}
    local function activate()
        for _,d in pairs(tabData) do d.page.Visible=false; d.bar.Visible=false; d.btn.BackgroundColor3=C.sidebar; d.ic.TextColor3=C.sub; d.lb.TextColor3=C.sub end
        page.Visible=true; bar.Visible=true; btn.BackgroundColor3=Color3.fromRGB(28,28,42)
        ic.TextColor3=C.accent; lb.TextColor3=C.text; PAGE_TITLE.Text=name; SCROLL.CanvasPosition=Vector2.zero
    end
    btn.MouseButton1Click:Connect(activate)
    if order==1 then activate() end
    return page
end

-- ══════════════════════════════════════════════════════════════════════
--  ELEMENT FACTORIES
-- ══════════════════════════════════════════════════════════════════════
local elemOrd=0
local function card(page,h)
    elemOrd+=1
    local f=mkFrame(page,{Size=UDim2.new(1,0,0,h),BackgroundColor3=C.card,LayoutOrder=elemOrd})
    mkCorner(f,10); mkStroke(f,C.border); return f
end

local function makeToggle(page,name,sub,cb)
    local f=card(page,56)
    mkLabel(f,{Size=UDim2.new(1,-70,0,20),Position=UDim2.new(0,14,0,10),Text=name,TextSize=13,TextColor3=C.text})
    mkLabel(f,{Size=UDim2.new(1,-70,0,16),Position=UDim2.new(0,14,0,30),Text=sub,TextSize=11,Font=Enum.Font.Gotham,TextColor3=C.sub})
    local pill=mkBtn(f,{Size=UDim2.new(0,44,0,24),Position=UDim2.new(1,-58,0.5,-12),BackgroundColor3=C.pill_off,Text=""}); mkCorner(pill,12)
    local knob=mkFrame(pill,{Size=UDim2.new(0,18,0,18),Position=UDim2.new(0,3,0.5,-9),BackgroundColor3=Color3.new(1,1,1)}); mkCorner(knob,9)
    local on=false
    pill.MouseButton1Click:Connect(function()
        on=not on
        TweenService:Create(pill,TW,{BackgroundColor3=on and C.accent or C.pill_off}):Play()
        TweenService:Create(knob,TW,{Position=on and UDim2.new(1,-21,0.5,-9) or UDim2.new(0,3,0.5,-9)}):Play()
        cb(on)
    end)
end

local function makeSlider(page,name,mn,mx,def,cb)
    local f=card(page,64)
    mkLabel(f,{Size=UDim2.new(1,-70,0,18),Position=UDim2.new(0,14,0,10),Text=name,TextSize=13,TextColor3=C.text})
    local vl=mkLabel(f,{Size=UDim2.new(0,52,0,18),Position=UDim2.new(1,-62,0,10),Text=tostring(def),TextSize=13,TextColor3=C.accent,TextXAlignment=Enum.TextXAlignment.Right})
    local track=mkFrame(f,{Size=UDim2.new(1,-28,0,6),Position=UDim2.new(0,14,0,42),BackgroundColor3=C.pill_off}); mkCorner(track,3)
    local fill=mkFrame(track,{Size=UDim2.new((def-mn)/(mx-mn),0,1,0),BackgroundColor3=C.accent}); mkCorner(fill,3)
    local sk=mkBtn(track,{Size=UDim2.new(0,16,0,16),AnchorPoint=Vector2.new(0.5,0.5),Position=UDim2.new((def-mn)/(mx-mn),0,0.5,0),BackgroundColor3=Color3.new(1,1,1),Text="",ZIndex=5}); mkCorner(sk,8)
    local drag=false
    sk.MouseButton1Down:Connect(function() drag=true end)
    UserInputService.InputEnded:Connect(function(i) if i.UserInputType==Enum.UserInputType.MouseButton1 then drag=false end end)
    UserInputService.InputChanged:Connect(function(i)
        if not drag or i.UserInputType~=Enum.UserInputType.MouseMovement then return end
        local r=math.clamp((i.Position.X-track.AbsolutePosition.X)/track.AbsoluteSize.X,0,1)
        local v=math.floor(mn+r*(mx-mn)); fill.Size=UDim2.new(r,0,1,0); sk.Position=UDim2.new(r,0,0.5,0); vl.Text=tostring(v); cb(v)
    end)
end

local function makeButton(page,label,color,cb)
    local f=card(page,48); mkStroke(f,color,1)
    local b=mkBtn(f,{Size=UDim2.new(1,-20,0,32),Position=UDim2.new(0,10,0.5,-16),BackgroundColor3=color,Text=label,TextColor3=Color3.new(1,1,1),TextSize=13}); mkCorner(b,8)
    b.MouseButton1Click:Connect(function()
        cb()
        TweenService:Create(b,TW,{BackgroundColor3=C.green}):Play()
        task.delay(0.4,function() TweenService:Create(b,TW,{BackgroundColor3=color}):Play() end)
    end)
    return b
end

local function makePlayerList(parent,height,onSelect)
    local stCard=card(parent,34)
    local stLbl=mkLabel(stCard,{Size=UDim2.new(1,-18,1,0),Position=UDim2.new(0,10,0,0),Text="👆  Select a player below",TextSize=11,TextColor3=C.sub})
    local lhCard=card(parent,34)
    mkLabel(lhCard,{Size=UDim2.new(1,-72,1,0),Position=UDim2.new(0,12,0,0),Text="🎮  Players in Lobby",TextSize=12,TextColor3=C.text})
    local refBtn=mkBtn(lhCard,{Size=UDim2.new(0,60,0,22),Position=UDim2.new(1,-64,0.5,-11),BackgroundColor3=C.accent,Text="↺  Refresh",TextColor3=C.text,TextSize=10}); mkCorner(refBtn,6)
    elemOrd+=1
    local outer=mkFrame(parent,{Size=UDim2.new(1,0,0,height),BackgroundColor3=Color3.fromRGB(18,18,28),LayoutOrder=elemOrd,ClipsDescendants=true})
    mkCorner(outer,10); mkStroke(outer,C.border)
    local sf=Instance.new("ScrollingFrame"); sf.Size=UDim2.new(1,0,1,0); sf.BackgroundTransparency=1; sf.BorderSizePixel=0
    sf.ScrollBarThickness=5; sf.ScrollBarImageColor3=C.accent; sf.CanvasSize=UDim2.new(0,0,0,0)
    sf.AutomaticCanvasSize=Enum.AutomaticSize.Y; sf.ScrollingDirection=Enum.ScrollingDirection.Y; sf.Parent=outer
    do
        local ul=Instance.new("UIListLayout"); ul.SortOrder=Enum.SortOrder.LayoutOrder; ul.Padding=UDim.new(0,4); ul.Parent=sf
        local up=Instance.new("UIPadding"); up.PaddingLeft=UDim.new(0,6); up.PaddingRight=UDim.new(0,10); up.PaddingTop=UDim.new(0,6); up.PaddingBottom=UDim.new(0,6); up.Parent=sf
    end
    local pBtns={}; local selected=nil
    local function setStatus(txt,col) stLbl.Text=txt; stLbl.TextColor3=col or C.sub end
    local function buildList()
        for _,c in ipairs(sf:GetChildren()) do if not c:IsA("UIListLayout") and not c:IsA("UIPadding") then c:Destroy() end end
        pBtns={}; selected=nil; setStatus("👆  Select a player below",C.sub)
        local others={}; for _,p in ipairs(Players:GetPlayers()) do if p~=ME then table.insert(others,p) end end
        if #others==0 then
            local ef=mkFrame(sf,{Size=UDim2.new(1,0,0,50),BackgroundColor3=Color3.fromRGB(24,24,36)}); mkCorner(ef,8)
            mkLabel(ef,{Size=UDim2.new(1,0,1,0),Text="😔  No other players in server",TextSize=12,Font=Enum.Font.Gotham,TextColor3=C.sub,TextXAlignment=Enum.TextXAlignment.Center}); return
        end
        for i,p in ipairs(others) do
            local row=mkFrame(sf,{Size=UDim2.new(1,0,0,44),BackgroundColor3=C.row,LayoutOrder=i}); mkCorner(row,8)
            local av=mkFrame(row,{Size=UDim2.new(0,30,0,30),Position=UDim2.new(0,7,0.5,-15),BackgroundColor3=C.accent}); mkCorner(av,15)
            mkLabel(av,{Size=UDim2.new(1,0,1,0),Text=string.upper(string.sub(p.Name,1,1)),TextSize=14,TextColor3=Color3.new(1,1,1),TextXAlignment=Enum.TextXAlignment.Center})
            mkLabel(row,{Size=UDim2.new(1,-110,0,18),Position=UDim2.new(0,45,0,5),Text=p.Name,TextSize=12,TextColor3=C.text})
            mkLabel(row,{Size=UDim2.new(1,-110,0,14),Position=UDim2.new(0,45,0,24),Text=(p.DisplayName~=p.Name) and p.DisplayName or "Roblox Player",TextSize=10,Font=Enum.Font.Gotham,TextColor3=C.sub})
            local sb=mkBtn(row,{Size=UDim2.new(0,54,0,26),Position=UDim2.new(1,-58,0.5,-13),BackgroundColor3=Color3.fromRGB(38,38,58),Text="Select",TextColor3=C.text,TextSize=11}); mkCorner(sb,6)
            pBtns[p]={row=row,btn=sb,av=av}
            sb.MouseButton1Click:Connect(function()
                for _,d in pairs(pBtns) do d.row.BackgroundColor3=C.row; d.btn.BackgroundColor3=Color3.fromRGB(38,38,58); d.btn.Text="Select"; d.btn.TextColor3=C.text; d.av.BackgroundColor3=C.accent end
                selected=p; row.BackgroundColor3=C.row_sel; sb.BackgroundColor3=C.accent; sb.Text="✓"; sb.TextColor3=Color3.new(1,1,1); av.BackgroundColor3=C.orange
                onSelect(p,setStatus)
            end)
        end
        TweenService:Create(refBtn,TW,{BackgroundColor3=C.green}):Play()
        task.delay(0.4,function() TweenService:Create(refBtn,TW,{BackgroundColor3=C.accent}):Play() end)
    end
    refBtn.MouseButton1Click:Connect(buildList)
    Players.PlayerAdded:Connect(function() task.wait(0.6); buildList() end)
    Players.PlayerRemoving:Connect(function() task.wait(0.15); buildList() end)
    buildList()
    return sf,buildList,setStatus,function() return selected end
end

-- ══════════════════════════════════════════════════════════════════════
--  FEATURE STATE
-- ══════════════════════════════════════════════════════════════════════
local fly=false; local flySpeed=50; local bv,bg2
local nc=false; local infJump=false; local god=false
local espOn=false; local espHL={}
local flingPow=150
local floatOn=false; local floatBV=nil
local spinOn=false; local spinConn=nil
local rainbowOn=false; local rainbowConn=nil
local trailOn=false; local trailObj=nil
local invisOn=false
local followOn=false; local followTarget=nil; local followConn=nil
local spectateOn=false; local spectateTarget=nil
local origCamType=nil

-- ── AIM ASSIST STATE ─────────────────────────────────────────────────
local aimOn          = false
local aimFOV         = 25    -- degrees (acquisition cone)
local aimSmooth      = 8     -- 1-20, divide by 100 for lerp factor
local aimDist        = 150   -- studs
local aimHead        = true  -- aim at head vs body center
local aimHoldOnly    = true  -- only active while right-click held
local aimLockedTarget = nil  -- currently locked part

-- ── FLY ───────────────────────────────────────────────────────────────
local function startFly()
    local hrp=getHRP(); local hum=getHum(); if not hrp or not hum then return end
    fly=true; hum.PlatformStand=true
    if hrp:FindFirstChild("_bv") then hrp:FindFirstChild("_bv"):Destroy() end
    if hrp:FindFirstChild("_bg") then hrp:FindFirstChild("_bg"):Destroy() end
    bv=Instance.new("BodyVelocity"); bv.Name="_bv"; bv.MaxForce=Vector3.new(1e5,1e5,1e5); bv.Velocity=Vector3.zero; bv.Parent=hrp
    bg2=Instance.new("BodyGyro"); bg2.Name="_bg"; bg2.MaxTorque=Vector3.new(1e5,1e5,1e5); bg2.P=1e4; bg2.Parent=hrp
end
local function stopFly()
    fly=false; local hum=getHum(); if hum then hum.PlatformStand=false end
    if bv and bv.Parent then bv:Destroy() end; if bg2 and bg2.Parent then bg2:Destroy() end; bv=nil; bg2=nil
end

-- ── ESP ───────────────────────────────────────────────────────────────
local function addESP(p)
    if p==ME then return end; local ch=p.Character; if not ch or espHL[p] then return end
    local h=Instance.new("Highlight"); h.FillColor=C.accent; h.OutlineColor=Color3.new(1,1,1)
    h.FillTransparency=0.35; h.OutlineTransparency=0; h.DepthMode=Enum.HighlightDepthMode.AlwaysOnTop; h.Adornee=ch; h.Parent=ch
    local bb=Instance.new("BillboardGui"); bb.Name="ESPbb"; bb.Size=UDim2.new(0,110,0,28); bb.StudsOffset=Vector3.new(0,3.8,0); bb.AlwaysOnTop=true
    bb.Adornee=ch:FindFirstChild("HumanoidRootPart") or ch:FindFirstChildWhichIsA("BasePart"); bb.Parent=ch
    local nl=Instance.new("TextLabel"); nl.Size=UDim2.new(1,0,1,0); nl.BackgroundTransparency=1
    nl.Text="⬥ "..p.Name; nl.TextColor3=Color3.new(1,1,1); nl.TextSize=13; nl.Font=Enum.Font.GothamBold; nl.TextStrokeTransparency=0; nl.Parent=bb
    espHL[p]=h
end
local function remESP(p)
    if espHL[p] then espHL[p]:Destroy(); espHL[p]=nil end
    local ch=p.Character; if ch then local b=ch:FindFirstChild("ESPbb"); if b then b:Destroy() end end
end
local function clearESP() for p in pairs(espHL) do remESP(p) end end
local function refreshESP() if not espOn then clearESP(); return end; for _,p in ipairs(Players:GetPlayers()) do addESP(p) end end
Players.PlayerAdded:Connect(function(p) if espOn then p.CharacterAdded:Connect(function() task.wait(0.5); addESP(p) end) end end)
Players.PlayerRemoving:Connect(remESP)

-- ── FLOAT ─────────────────────────────────────────────────────────────
local function startFloat()
    local hrp=getHRP(); if not hrp then return end
    if hrp:FindFirstChild("_floatBV") then hrp:FindFirstChild("_floatBV"):Destroy() end
    floatBV=Instance.new("BodyVelocity"); floatBV.Name="_floatBV"
    floatBV.MaxForce=Vector3.new(0,1e4,0); floatBV.Velocity=Vector3.new(0,8,0); floatBV.Parent=hrp
    local hum=getHum(); if hum then hum.PlatformStand=false end
end
local function stopFloat()
    if floatBV and floatBV.Parent then floatBV:Destroy() end; floatBV=nil
end

-- ── SPIN ──────────────────────────────────────────────────────────────
local function startSpin()
    spinOn=true
    spinConn=RunService.Heartbeat:Connect(function()
        local hrp=getHRP(); if not hrp then return end
        hrp.CFrame=hrp.CFrame*CFrame.Angles(0,math.rad(8),0)
    end)
end
local function stopSpin()
    spinOn=false; if spinConn then spinConn:Disconnect(); spinConn=nil end
end

-- ── RAINBOW ───────────────────────────────────────────────────────────
local rainbowHue=0
local function startRainbow()
    rainbowOn=true
    rainbowConn=RunService.Heartbeat:Connect(function()
        local ch=getChar(); if not ch then return end
        rainbowHue=(rainbowHue+0.5)%360
        local col=Color3.fromHSV(rainbowHue/360,1,1)
        for _,p in ipairs(ch:GetDescendants()) do
            if p:IsA("BasePart") and p.Name~="HumanoidRootPart" then p.Color=col end
        end
    end)
end
local function stopRainbow()
    rainbowOn=false; if rainbowConn then rainbowConn:Disconnect(); rainbowConn=nil end
    local ch=getChar(); if not ch then return end
    for _,p in ipairs(ch:GetDescendants()) do
        if p:IsA("BasePart") then p.Color=Color3.fromRGB(163,162,165) end
    end
end

-- ── TRAIL ─────────────────────────────────────────────────────────────
local function startTrail()
    local hrp=getHRP(); if not hrp then return end
    if hrp:FindFirstChild("_trail") then hrp:FindFirstChild("_trail"):Destroy() end
    local a0=Instance.new("Attachment"); a0.Position=Vector3.new(0,1,0); a0.Parent=hrp
    local a1=Instance.new("Attachment"); a1.Position=Vector3.new(0,-1,0); a1.Parent=hrp
    trailObj=Instance.new("Trail"); trailObj.Name="_trail"
    trailObj.Attachment0=a0; trailObj.Attachment1=a1
    trailObj.Lifetime=0.6; trailObj.MinLength=0
    trailObj.Color=ColorSequence.new({
        ColorSequenceKeypoint.new(0,Color3.fromHSV(0,1,1)),
        ColorSequenceKeypoint.new(0.5,Color3.fromHSV(0.5,1,1)),
        ColorSequenceKeypoint.new(1,Color3.fromHSV(1,1,1)),
    })
    trailObj.Parent=hrp; trailOn=true
end
local function stopTrail()
    trailOn=false
    local hrp=getHRP(); if not hrp then return end
    local t=hrp:FindFirstChild("_trail"); if t then t:Destroy() end
    for _,a in ipairs(hrp:GetChildren()) do if a:IsA("Attachment") then a:Destroy() end end
end

-- ── INVISIBLE ─────────────────────────────────────────────────────────
local function setInvis(on)
    invisOn=on
    local ch=getChar(); if not ch then return end
    for _,p in ipairs(ch:GetDescendants()) do
        if p:IsA("BasePart") and p.Name~="HumanoidRootPart" then p.LocalTransparencyModifier=on and 1 or 0 end
        if p:IsA("Decal") then p.Transparency=on and 1 or 0 end
    end
end

-- ── RESIZE ────────────────────────────────────────────────────────────
local function resizeChar(scale)
    local ch=getChar(); if not ch then return end
    local hum=getHum(); if not hum then return end
    local function setScale(name,val)
        local s=hum:FindFirstChild(name)
        if s and s:IsA("NumberValue") then s.Value=val end
    end
    setScale("BodyDepthScale",scale); setScale("BodyHeightScale",scale)
    setScale("BodyWidthScale",scale); setScale("HeadScale",scale)
end

-- ── FOLLOW ────────────────────────────────────────────────────────────
local function startFollow(target)
    followTarget=target; followOn=true
    if followConn then followConn:Disconnect() end
    followConn=RunService.Heartbeat:Connect(function()
        if not followOn then return end
        local hrp=getHRP(); if not hrp then return end
        local tch=followTarget and followTarget.Character
        local thrp=tch and tch:FindFirstChild("HumanoidRootPart")
        if not thrp then return end
        local hum=getHum(); if not hum then return end
        local dist=(thrp.Position-hrp.Position).Magnitude
        if dist>4 then
            hum:MoveTo(thrp.Position)
        end
    end)
end
local function stopFollow()
    followOn=false; followTarget=nil
    if followConn then followConn:Disconnect(); followConn=nil end
end

-- ── SPECTATE ──────────────────────────────────────────────────────────
local function startSpectate(target)
    spectateTarget=target; spectateOn=true
    local cam=workspace.CurrentCamera
    origCamType=cam.CameraType
    cam.CameraType=Enum.CameraType.Scriptable
    RunService.RenderStepped:Connect(function()
        if not spectateOn then return end
        local tch=spectateTarget and spectateTarget.Character
        local thrp=tch and tch:FindFirstChild("HumanoidRootPart")
        if thrp then
            cam.CFrame=CFrame.new(thrp.Position+Vector3.new(0,6,-12),thrp.Position)
        end
    end)
end
local function stopSpectate()
    spectateOn=false; spectateTarget=nil
    local cam=workspace.CurrentCamera
    if origCamType then cam.CameraType=origCamType end
end

-- ── AIM ASSIST HELPERS ────────────────────────────────────────────────
local function aimIsValid(player)
    if player == ME then return false end

    -- Team check: skip teammates, only target enemies
    -- If the game uses Teams, ME.Team is set. nil means no team (FFA) → treat everyone as enemy.
    if ME.Team ~= nil and player.Team == ME.Team then return false end

    local ch = player.Character
    if not ch then return false end
    local hum = ch:FindFirstChildOfClass("Humanoid")
    if not hum or hum.Health <= 0 then return false end
    return ch:FindFirstChild("HumanoidRootPart") ~= nil
end

-- Acquire nearest target within FOV cone; once locked, track by proximity only
local function aimFindTarget()
    local localChar = getChar()
    if not localChar then aimLockedTarget = nil; return nil end

    local cam      = workspace.CurrentCamera
    local camPos   = cam.CFrame.Position
    local camLook  = cam.CFrame.LookVector

    -- Validate existing lock: keep it if still alive and in range
    if aimLockedTarget and aimLockedTarget.Parent then
        local owner = Players:GetPlayerFromCharacter(aimLockedTarget.Parent)
        if owner and aimIsValid(owner) then
            local dist = (aimLockedTarget.Position - camPos).Magnitude
            if dist <= aimDist then
                return aimLockedTarget   -- stay locked
            end
        end
    end
    aimLockedTarget = nil  -- old lock invalid, pick a new one

    -- Acquire: find nearest player within FOV cone
    local bestPart = nil
    local bestDist = aimDist

    for _, player in ipairs(Players:GetPlayers()) do
        if aimIsValid(player) then
            local ch   = player.Character
            local part = aimHead
                and (ch:FindFirstChild("Head") or ch:FindFirstChild("HumanoidRootPart"))
                or  ch:FindFirstChild("HumanoidRootPart")

            if part then
                local toTarget = part.Position - camPos
                local dist     = toTarget.Magnitude

                if dist <= aimDist then
                    local angle = math.deg(math.acos(math.clamp(camLook:Dot(toTarget.Unit), -1, 1)))
                    if angle <= aimFOV and dist 0 and d.Unit or Vector3.zero)*flySpeed; bg2.CFrame=cam.CFrame
        end
    end
    if nc then local ch=getChar(); if ch then for _,p in ipairs(ch:GetDescendants()) do if p:IsA("BasePart") then p.CanCollide=false end end end end
    if god then local h=getHum(); if h then h.Health=h.MaxHealth end end
    if espOn then
        for _,p in ipairs(Players:GetPlayers()) do
            if p~=ME then
                if p.Character and not espHL[p] then addESP(p)
                elseif not p.Character and espHL[p] then remESP(p) end
            end
        end
    end
    if invisOn then
        local ch=getChar(); if ch then
            for _,p in ipairs(ch:GetDescendants()) do
                if p:IsA("BasePart") and p.Name~="HumanoidRootPart" then p.LocalTransparencyModifier=1 end
            end
        end
    end
end)

-- ── AIM ASSIST LOOP ───────────────────────────────────────────────────
-- Runs AFTER Roblox's own camera update (Camera priority + 1) so our
-- CFrame write is the last one each frame and cannot be overridden.
RunService:BindToRenderStep("kAaMsAimAssist", Enum.RenderPriority.Camera.Value + 1, function()
    if not aimOn then aimLockedTarget = nil; return end

    -- Activation gate
    if aimHoldOnly and not UserInputService:IsMouseButtonPressed(Enum.UserInputType.MouseButton2) then
        aimLockedTarget = nil; return
    end

    local target = aimFindTarget()
    if not target then return end

    local cam      = workspace.CurrentCamera
    local camPos   = cam.CFrame.Position
    local toTarget = (target.Position - camPos).Unit

    -- Hard lock: snap directly to target, bypassing any camera script
    local lockedCF = CFrame.lookAt(camPos, camPos + toTarget)

    -- Optional smoothing: aimSmooth 1 = gentle pull, 20 = instant snap
    local factor = math.clamp(aimSmooth / 20, 0.05, 1)
    cam.CFrame = cam.CFrame:Lerp(lockedCF, factor)
end)

UserInputService.JumpRequest:Connect(function()
    if infJump then local h=getHum(); if h then h:ChangeState(Enum.HumanoidStateType.Jumping) end end
end)

UserInputService.InputBegan:Connect(function(inp,gp)
    if gp then return end
    if inp.KeyCode==Enum.KeyCode.Five then WIN.Visible=not WIN.Visible end
end)

ME.CharacterAdded:Connect(function(ch)
    fly=false; bv=nil; bg2=nil; floatOn=false; floatBV=nil
    spinOn=false; rainbowOn=false; trailOn=false; invisOn=false
    if spinConn then spinConn:Disconnect(); spinConn=nil end
    if rainbowConn then rainbowConn:Disconnect(); rainbowConn=nil end
    local h=ch:WaitForChild("Humanoid",5); if h then h.PlatformStand=false end
end)
🎮 Similar Scripts
💬 Comments (0)
Login to post a comment
No comments yet. Be the first!
Script Info
Game Just a baseplate
TypeKeyless
Authoralexriderr
Views14
Likes0
PublishedApr 2, 2026
🎮 Play Game on Roblox
🕐 Recent Scripts
Cursed Blade v1.61 – Auto Farm v1 and v2
Cursed Blade v1.61 – Auto Farm v1 and v2
Cursed Blade • 👁 4
Keyless
+1 Double Jump for brainrots Script – Find Best Brainrot
+1 Double Jump for brainrots Script – Find Best Brainrot
+1 double jump for Brainrots • 👁 6
Keyless
Auto farm, Rebirth Time Set, Anti AFK
Auto farm, Rebirth Time Set, Anti AFK
Aura Ascensio • 👁 8
Keyless
Blackout Npc Aimbot
Blackout Npc Aimbot
Blackout Revival • 👁 8
Keyless
counter blox script for semi rage or hvvh
counter blox script for semi rage or hvvh
Counter Blox • 👁 11
Keyless