local Players = game:GetService("Players") local RunService = game:GetService("RunService") local TweenService = game:GetService("TweenService") local Lighting = game:GetService("Lighting") local Debris = game:GetService("Debris") local SoundService = game:GetService("SoundService") local Workspace = game:GetService("Workspace") local LocalPlayer = Players.LocalPlayer local CONFIG = { ToolName = "Hamby Bomb Upgrade", MeshId = "", TextureId = "", MeshScale = Vector3.new(1, 1, 1), MeshRotation = Vector3.new(0, 0, 0), SkyboxId = "72212333110471", BombSoundId = "4418405082", BombSoundPitch = 0.85, BombSoundVolume = 10, RadioSoundId = "116265298618286", RadioSoundPitch = 0.7, RadioSoundVolume = 10, Cooldown = 10, CallDelay = 1.4, BombLength = 11, BombDiameter = 2.6, SpawnHeight = 260, HoverTime = 1, TurnTime = 0.5, FallAccel = 300, MaxFallSpeed = 420, FireballDiameter = 320, ShockDiameter = 900, RingDiameter = 1100, FireballLife = 2, GrayTime = 8, ShakePower = 4, ShakeTime = 4.5, ShakeRange = 900, ShockSpeed = 450, BlastRadius = 170, ThrowRadius = 300, Gravity = Workspace.Gravity, FallSpin = 5, FallFloorMargin = 50, SmokeDuration = 11, SmokeBurstCount = 90, SmokeTrickleTime = 3, MaxSafeSpeed = 520, MaxSafeSpin = 60, } local rng = Random.new() local lastUse = 0 local fxFolder local lastSafeCFrame local guardConn local skyInstance pcall(function() sethiddenproperty(LocalPlayer, "SimulationRadius", 1e9) sethiddenproperty(LocalPlayer, "MaximumSimulationRadius", 1e9) end) local function getFolder() if fxFolder and fxFolder.Parent then return fxFolder end fxFolder = Instance.new("Folder") fxFolder.Name = "HambyUpgradeFx" fxFolder.Parent = Workspace return fxFolder end local function assetUrl(value) value = tostring(value or "") if value == "" or value == "0" then return nil end if value:match("^%d+$") then return "rbxassetid://" .. value end return value end local function newPart(props) local part = Instance.new("Part") part.Anchored = true part.CanCollide = false part.CanTouch = false part.CanQuery = false part.CastShadow = false part.Material = Enum.Material.SmoothPlastic part.TopSurface = Enum.SurfaceType.Smooth part.BottomSurface = Enum.SurfaceType.Smooth for key, value in pairs(props) do part[key] = value end return part end local function collectFilter(extra) local list = { getFolder() } for _, plr in ipairs(Players:GetPlayers()) do if plr.Character then list[#list + 1] = plr.Character end end if extra then list[#list + 1] = extra end return list end local function ownCharacter() local character = LocalPlayer.Character if not character then return nil, nil, nil end return character, character:FindFirstChild("HumanoidRootPart"), character:FindFirstChildOfClass("Humanoid") end local function startGuard() if guardConn then return end guardConn = RunService.RenderStepped:Connect(function() local _, root = ownCharacter() if not root then return end local velocity = root.AssemblyLinearVelocity local spin = root.AssemblyAngularVelocity if velocity.Magnitude > CONFIG.MaxSafeSpeed then root.AssemblyLinearVelocity = velocity.Unit * CONFIG.MaxSafeSpeed end if spin.Magnitude > CONFIG.MaxSafeSpin then root.AssemblyAngularVelocity = spin.Unit * CONFIG.MaxSafeSpin end local position = root.Position local invalid = position.X ~= position.X or position.Y ~= position.Y or position.Z ~= position.Z if invalid or position.Magnitude > 100000 then if lastSafeCFrame then root.AssemblyLinearVelocity = Vector3.zero root.AssemblyAngularVelocity = Vector3.zero root.CFrame = lastSafeCFrame end elseif velocity.Magnitude < CONFIG.MaxSafeSpeed * 0.8 then lastSafeCFrame = root.CFrame end end) end local function hookCharacter(character) local humanoid = character:WaitForChild("Humanoid", 10) if not humanoid then return end humanoid.Died:Connect(function() for _, descendant in ipairs(character:GetDescendants()) do if descendant:IsA("BasePart") then descendant.CanCollide = false end end local root = character:FindFirstChild("HumanoidRootPart") if root then root.AssemblyAngularVelocity = Vector3.zero end end) end local function buildBomb() local length = CONFIG.BombLength local diameter = CONFIG.BombDiameter local model = Instance.new("Model") model.Name = "HambyLittleBoyUpgrade" local core = newPart({ Name = "Core", Size = Vector3.new(0.5, 0.5, 0.5), Transparency = 1 }) core.Parent = model model.PrimaryPart = core local meshUrl = assetUrl(CONFIG.MeshId) if meshUrl then local body = newPart({ Size = Vector3.new(length, diameter, diameter), Color = Color3.fromRGB(110, 112, 108), Material = Enum.Material.Metal, }) local mesh = Instance.new("SpecialMesh") mesh.MeshType = Enum.MeshType.FileMesh mesh.MeshId = meshUrl local textureUrl = assetUrl(CONFIG.TextureId) if textureUrl then mesh.TextureId = textureUrl end mesh.Scale = CONFIG.MeshScale mesh.Parent = body local rot = CONFIG.MeshRotation body.CFrame = CFrame.Angles(math.rad(rot.X), math.rad(rot.Y), math.rad(rot.Z)) body.Parent = model return model end local gray = Color3.fromRGB(96, 100, 96) local dark = Color3.fromRGB(52, 54, 52) local function cylinder(fromFrac, toFrac, diaFrac, color) local len = (toFrac - fromFrac) * length local part = newPart({ Shape = Enum.PartType.Cylinder, Size = Vector3.new(len, diameter * diaFrac, diameter * diaFrac), Color = color, Material = Enum.Material.Metal, }) part.CFrame = CFrame.new(((fromFrac + toFrac) * 0.5) * length, 0, 0) part.Parent = model end local function box(centerFrac, size, color) local part = newPart({ Size = size, Color = color, Material = Enum.Material.Metal }) part.CFrame = CFrame.new(centerFrac * length, 0, 0) part.Parent = model end cylinder(-0.30, 0.20, 1, gray) cylinder(0.04, 0.07, 1.04, dark) local noseLayers = { { 0.20, 0.27, 0.97 }, { 0.27, 0.33, 0.86 }, { 0.33, 0.39, 0.72 }, { 0.39, 0.44, 0.56 }, { 0.44, 0.47, 0.38 }, { 0.47, 0.49, 0.2 }, } for _, layer in ipairs(noseLayers) do cylinder(layer[1], layer[2], layer[3], gray) end local tailLayers = { { -0.40, -0.30, 0.9 }, { -0.45, -0.40, 0.7 }, { -0.50, -0.45, 0.52 }, } for _, layer in ipairs(tailLayers) do cylinder(layer[1], layer[2], layer[3], gray) end box(-0.43, Vector3.new(0.14 * length, diameter * 1.4, 0.12), dark) box(-0.43, Vector3.new(0.14 * length, 0.12, diameter * 1.4), dark) cylinder(-0.50, -0.42, 1.05, dark) return model end local function applySkybox() if skyInstance and skyInstance.Parent then skyInstance:Destroy() end local sky = Instance.new("Sky") sky.Name = "HambyUpgradeSky" local url = assetUrl(CONFIG.SkyboxId) sky.SkyboxBk = url sky.SkyboxDn = url sky.SkyboxFt = url sky.SkyboxLf = url sky.SkyboxRt = url sky.SkyboxUp = url sky.Parent = Lighting skyInstance = sky end local function screenFx() local cc = Instance.new("ColorCorrectionEffect") cc.Name = "HambyUpgradeGray" cc.Brightness = 0.7 cc.Parent = Lighting TweenService:Create(cc, TweenInfo.new(0.5, Enum.EasingStyle.Quad, Enum.EasingDirection.Out), { Brightness = 0, Saturation = -1, Contrast = 0.12, }):Play() task.delay(CONFIG.GrayTime, function() local tween = TweenService:Create(cc, TweenInfo.new(2.5), { Saturation = 0, Contrast = 0 }) tween:Play() tween.Completed:Wait() cc:Destroy() end) end local function playSoundAt(id, pitch, volume, parent) local url = assetUrl(id) if not url then return nil end local sound = Instance.new("Sound") sound.SoundId = url sound.Volume = volume or 1 sound.PlaybackSpeed = pitch or 1 sound.Looped = false sound.Parent = parent or SoundService sound:Play() sound.Ended:Connect(function() sound:Destroy() end) Debris:AddItem(sound, 90) return sound end local function shockwaves(P) local folder = getFolder() local fireDia = CONFIG.FireballDiameter local ball = newPart({ Name = "Fireball", Shape = Enum.PartType.Ball, Size = Vector3.one * 12, Material = Enum.Material.Neon, Color = Color3.fromRGB(255, 150, 10), Position = P, }) ball.Parent = folder TweenService:Create(ball, TweenInfo.new(1.1, Enum.EasingStyle.Quart, Enum.EasingDirection.Out), { Size = Vector3.one * fireDia, Position = P + Vector3.new(0, fireDia * 0.32, 0), }):Play() TweenService:Create( ball, TweenInfo.new(CONFIG.FireballLife - 0.4, Enum.EasingStyle.Linear, Enum.EasingDirection.Out, 0, false, 0.4), { Transparency = 1 } ):Play() Debris:AddItem(ball, CONFIG.FireballLife + 0.5) local shockDia = CONFIG.ShockDiameter local outer = newPart({ Name = "OuterShock", Shape = Enum.PartType.Ball, Size = Vector3.one * 12, Material = Enum.Material.Neon, Color = Color3.fromRGB(255, 125, 0), Transparency = 0.89, Position = P, }) outer.Parent = folder TweenService:Create(outer, TweenInfo.new(1.8, Enum.EasingStyle.Quad, Enum.EasingDirection.Out), { Size = Vector3.one * shockDia, Position = P + Vector3.new(0, shockDia * 0.2, 0), }):Play() TweenService:Create( outer, TweenInfo.new(1.3, Enum.EasingStyle.Linear, Enum.EasingDirection.Out, 0, false, 0.5), { Transparency = 1 } ):Play() Debris:AddItem(outer, 2.6) local ringDia = CONFIG.RingDiameter local ring = newPart({ Name = "GroundRing", Shape = Enum.PartType.Cylinder, Size = Vector3.new(2, 10, 10), Material = Enum.Material.Neon, Color = Color3.fromRGB(255, 255, 255), Transparency = 0.1, }) ring.CFrame = CFrame.new(P + Vector3.new(0, 2, 0)) * CFrame.Angles(0, 0, math.pi / 2) ring.Parent = folder TweenService:Create(ring, TweenInfo.new(3, Enum.EasingStyle.Quad, Enum.EasingDirection.Out), { Size = Vector3.new(2, ringDia, ringDia), }):Play() TweenService:Create(ring, TweenInfo.new(3, Enum.EasingStyle.Quad, Enum.EasingDirection.In), { Transparency = 1, }):Play() Debris:AddItem(ring, 3.3) end local function blackSmoke(P) local folder = getFolder() local anchor = newPart({ Size = Vector3.one, Transparency = 1, Position = P + Vector3.new(0, 3, 0) }) anchor.Parent = folder local attachment = Instance.new("Attachment") attachment.Parent = anchor local smoke = Instance.new("ParticleEmitter") smoke.Texture = "rbxasset://textures/particles/smoke_main.dds" smoke.Color = ColorSequence.new(Color3.fromRGB(12, 12, 12), Color3.fromRGB(45, 45, 45)) smoke.Size = NumberSequence.new({ NumberSequenceKeypoint.new(0, 6), NumberSequenceKeypoint.new(0.4, 22), NumberSequenceKeypoint.new(1, 42), }) smoke.Transparency = NumberSequence.new({ NumberSequenceKeypoint.new(0, 0.1), NumberSequenceKeypoint.new(0.6, 0.45), NumberSequenceKeypoint.new(1, 1), }) smoke.Lifetime = NumberRange.new(CONFIG.SmokeDuration * 0.6, CONFIG.SmokeDuration) smoke.Speed = NumberRange.new(10, 26) smoke.SpreadAngle = Vector2.new(25, 25) smoke.Acceleration = Vector3.new(0, 9, 0) smoke.Drag = 0.6 smoke.Rotation = NumberRange.new(0, 360) smoke.RotSpeed = NumberRange.new(-20, 20) smoke.Rate = 0 smoke.Parent = attachment smoke:Emit(CONFIG.SmokeBurstCount) smoke.Rate = 26 task.delay(CONFIG.SmokeTrickleTime, function() smoke.Rate = 0 end) Debris:AddItem(anchor, CONFIG.SmokeDuration + 2) end local function shake(power, duration, delay) if delay and delay > 0 then task.wait(delay) end local seed = rng:NextNumber() * 100 local t0 = os.clock() local name = "HambyUpgradeShake" pcall(function() RunService:UnbindFromRenderStep(name) end) RunService:BindToRenderStep(name, Enum.RenderPriority.Camera.Value + 1, function() local t = os.clock() - t0 if t >= duration then pcall(function() RunService:UnbindFromRenderStep(name) end) return end local f = (1 - t / duration) ^ 2 * power local n = t * 28 local x = math.noise(n, seed, 0) * 2 local y = math.noise(n, seed, 10) * 2 local z = math.noise(n, seed, 20) * 2 local cam = Workspace.CurrentCamera cam.CFrame = cam.CFrame * CFrame.new(x * f, y * f, 0) * CFrame.Angles(math.rad(y * f * 1.2), math.rad(x * f * 1.2), math.rad(z * f * 2)) end) end local function throwCharacter(P) local character, root, humanoid = ownCharacter() if not root or not humanoid then return end local dist = (root.Position - P).Magnitude if dist > CONFIG.ThrowRadius then return end task.wait(dist / CONFIG.ShockSpeed) if humanoid.Health <= 0 or not root.Parent then return end local dir = root.Position - P dir = Vector3.new(dir.X, 0, dir.Z) if dir.Magnitude < 0.1 then dir = -root.CFrame.LookVector end dir = dir.Unit local k = math.clamp(1 - dist / CONFIG.ThrowRadius, 0.1, 1) humanoid.PlatformStand = true root.AssemblyLinearVelocity = dir * (190 + 230 * k) + Vector3.new(0, 110 + 150 * k, 0) root.AssemblyAngularVelocity = Vector3.new(rng:NextNumber(-1, 1), rng:NextNumber(-1, 1), rng:NextNumber(-1, 1)) * (4 + 10 * k) task.delay(1.8, function() pcall(function() humanoid.PlatformStand = false humanoid:ChangeState(Enum.HumanoidStateType.GettingUp) end) end) end local fallBodies = {} local function registerFall(part, velocity) if fallBodies[part] then return end fallBodies[part] = { velocity = velocity, spin = Vector3.new( rng:NextNumber(-CONFIG.FallSpin, CONFIG.FallSpin), rng:NextNumber(-CONFIG.FallSpin, CONFIG.FallSpin), rng:NextNumber(-CONFIG.FallSpin, CONFIG.FallSpin) ) * 0.2, } end local function gravityStep(dt) local floor = Workspace.FallenPartsDestroyHeight + CONFIG.FallFloorMargin for part, data in pairs(fallBodies) do if not part.Parent or part.Position.Y < floor then fallBodies[part] = nil else data.velocity += Vector3.new(0, -CONFIG.Gravity * dt, 0) part.CFrame = (part.CFrame + data.velocity * dt) * CFrame.Angles( data.spin.X * dt, data.spin.Y * dt, data.spin.Z * dt ) end end end local function destruction(P) local params = OverlapParams.new() params.FilterType = Enum.RaycastFilterType.Exclude params.FilterDescendantsInstances = collectFilter() params.MaxParts = 1000 local found = Workspace:GetPartBoundsInRadius(P, CONFIG.BlastRadius, params) local camera = Workspace.CurrentCamera local list = {} for _, part in ipairs(found) do local valid = not part:IsA("Terrain") and part.Parent and not part:IsDescendantOf(camera) if valid then local model = part:FindFirstAncestorOfClass("Model") if not (model and model:FindFirstChildOfClass("Humanoid")) then list[#list + 1] = { part = part, d = (part.Position - P).Magnitude } end end end table.sort(list, function(a, b) return a.d < b.d end) local function affect(part, d) if not part.Parent then return end pcall(function() part:BreakJoints() for _, joint in ipairs(part:GetJoints()) do joint:Destroy() end end) part.Anchored = false part.CanCollide = true local dir = part.Position - P if dir.Magnitude < 0.1 then dir = Vector3.yAxis end dir = dir.Unit local k = 1 - d / CONFIG.BlastRadius registerFall(part, dir * (90 + 170 * k) + Vector3.new(0, 70 + 120 * k, 0)) end local t0 = os.clock() local index = 1 while index <= #list do local elapsed = os.clock() - t0 local processed = 0 while index <= #list and list[index].d / CONFIG.ShockSpeed <= elapsed and processed < 60 do local item = list[index] pcall(affect, item.part, item.d) index += 1 processed += 1 end task.wait() end end local function explode(P) applySkybox() local camera = Workspace.CurrentCamera local dist = (camera.CFrame.Position - P).Magnitude local strength = math.clamp(1 - dist / CONFIG.ShakeRange, 0, 1) * CONFIG.ShakePower local delay = math.min(dist / CONFIG.ShockSpeed, 1.5) local effects = { screenFx, function() playSoundAt(CONFIG.BombSoundId, CONFIG.BombSoundPitch, CONFIG.BombSoundVolume) end, function() shockwaves(P) end, function() blackSmoke(P) end, function() shake(strength, CONFIG.ShakeTime, delay) end, function() throwCharacter(P) end, function() destruction(P) end, } for _, effect in ipairs(effects) do task.spawn(function() pcall(effect) end) end task.delay(CONFIG.FireballLife + 14, function() if fxFolder and #fxFolder:GetChildren() == 0 then fxFolder:Destroy() fxFolder = nil end end) end local function dropBomb(target) local camera = Workspace.CurrentCamera local bomb = buildBomb() bomb.Parent = getFolder() local rayParams = RaycastParams.new() rayParams.FilterType = Enum.RaycastFilterType.Exclude rayParams.FilterDescendantsInstances = collectFilter(bomb) local right = camera.CFrame.RightVector local yaw = math.atan2(-right.Z, right.X) local function pose(position, tilt) return CFrame.new(position) * CFrame.Angles(0, yaw, 0) * CFrame.Angles(0, 0, -tilt) end local pos = Vector3.new(target.X, target.Y + CONFIG.SpawnHeight, target.Z) bomb:PivotTo(pose(pos, 0)) local t0 = os.clock() local speed = 0 local halfLen = CONFIG.BombLength * 0.5 local conn conn = RunService.RenderStepped:Connect(function(dt) dt = math.min(dt, 0.05) local t = os.clock() - t0 if t < CONFIG.HoverTime then bomb:PivotTo(pose(pos, math.sin(t * 3) * 0.04)) return end local turnT = t - CONFIG.HoverTime if turnT < CONFIG.TurnTime then local a = turnT / CONFIG.TurnTime a = a * a * (3 - 2 * a) bomb:PivotTo(pose(pos, a * math.pi / 2)) return end speed = math.min(speed + CONFIG.FallAccel * dt, CONFIG.MaxFallSpeed) local step = speed * dt local result = Workspace:Raycast(pos, Vector3.new(0, -(step + halfLen), 0), rayParams) if result then conn:Disconnect() bomb:Destroy() explode(result.Position) return end pos -= Vector3.new(0, step, 0) bomb:PivotTo(pose(pos, math.pi / 2)) if pos.Y < Workspace.FallenPartsDestroyHeight + 5 then conn:Disconnect() bomb:Destroy() end end) end local function callBomb() local now = os.clock() if now - lastUse < CONFIG.Cooldown then return end local character, root, humanoid = ownCharacter() if not root or not humanoid or humanoid.Health <= 0 then return end lastUse = now local mouse = LocalPlayer:GetMouse() local rayParams = RaycastParams.new() rayParams.FilterType = Enum.RaycastFilterType.Exclude rayParams.FilterDescendantsInstances = collectFilter() local target pcall(function() local ray = mouse.UnitRay local result = Workspace:Raycast(ray.Origin, ray.Direction * 4000, rayParams) if result then target = result.Position end end) if not target then target = root.Position + root.CFrame.LookVector * 60 end playSoundAt(CONFIG.RadioSoundId, CONFIG.RadioSoundPitch, CONFIG.RadioSoundVolume) task.delay(CONFIG.CallDelay, function() pcall(dropBomb, target) end) end local function giveTool() local backpack = LocalPlayer:FindFirstChildOfClass("Backpack") or LocalPlayer:WaitForChild("Backpack", 10) if not backpack then return end local character = LocalPlayer.Character if backpack:FindFirstChild(CONFIG.ToolName) or (character and character:FindFirstChild(CONFIG.ToolName)) then return end local tool = Instance.new("Tool") tool.Name = CONFIG.ToolName tool.ToolTip = CONFIG.ToolName tool.RequiresHandle = false tool.CanBeDropped = false tool.Activated:Connect(function() pcall(callBomb) end) tool.Parent = backpack end startGuard() if LocalPlayer.Character then task.spawn(hookCharacter, LocalPlayer.Character) end giveTool() LocalPlayer.CharacterAdded:Connect(function(character) task.spawn(hookCharacter, character) task.wait(1) pcall(giveTool) end) RunService.Heartbeat:Connect(function(dt) gravityStep(math.min(dt, 0.05)) end)