[HALLOWEEN] The Strongest Battlegrounds
10.6k Views
675 Executions

Auto lock on when blocking

The Strongest Battlegrounds
Zrbihzrhsejseihe
Zrbihzrhsejseihe10K executions
1 year ago
Please login to perform these actions:

Auto lock on when blocking is a The Strongest Battlegrounds script for Roblox, uploaded to ScriptBlox on Sep 25, 2025.

Does it work?

No reports yet

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

Also noticed:

Description

Auto locks onto nearest player within a close distance when blocking

View Raw
-- Lock On Script (TSB style, with animation trigger)
--[[
 WARNING: Heads up! This script has not been verified by ScriptBlox. Use at your own risk!
]]

local Players = game:GetService("Players")
local RunService = game:GetService("RunService")
local player = Players.LocalPlayer
local camera = workspace.CurrentCamera
local playerGui = player:WaitForChild("PlayerGui")

-- CONFIG
local LOCK_ON_ANIM_ID = "10470389827" -- Animation ID to trigger lock-on
local MAX_DISTANCE = 50

-- GUI
local screenGui = Instance.new("ScreenGui", playerGui)
screenGui.Name = "LockOnGui"

local button = Instance.new("TextButton", screenGui)
button.Name = "LockOnButton"
button.Size = UDim2.new(0, 35, 0, 35)
button.Position = UDim2.new(0, 605, 0, -40)
button.Text = "Lock"
button.TextScaled = true
button.BackgroundColor3 = Color3.fromRGB(50, 50, 50)
button.TextColor3 = Color3.fromRGB(255, 255, 255)
button.BackgroundTransparency = 0.4

local glowFrame = Instance.new("Frame", button)
glowFrame.Size = UDim2.new(1.2, 0, 1.2, 0)
glowFrame.Position = UDim2.new(0, -5, 0, -5)
glowFrame.BackgroundTransparency = 1
glowFrame.BackgroundColor3 = Color3.fromRGB(0, 255, 0)
local glowGradient = Instance.new("UIGradient", glowFrame)
glowGradient.Color = ColorSequence.new(Color3.fromRGB(0, 255, 0), Color3.fromRGB(0, 255, 0))
glowGradient.Transparency = NumberSequence.new(0.5, 1)
glowGradient.Rotation = 45
glowFrame.Visible = false



Comments

1
Log in to join the conversation. Login
afternear's profile picture
afternear1 year ago

Anyway to configurate this script for the weapon-using characters? Such as Sonic or Metal Bat? Thanks

1