RobloxScripterAI
Discord ↗
Link Copied to Clipboard
×
"a working superpower that makes things surrounding you slowly move towards you for 3 seconds"
-- local script local player = game.Players.LocalPlayer local character = player.Character or player.CharacterAdded:Wait() local humanoidRootPart = character:WaitForChild("HumanoidRootPart") local superpowerActive = false local function activateSuperpower() if not superpowerActive then superpowerActive = true local startTime = tick() while tick() - startTime < 3 do local parts = workspace:FindPartsInRegion3( humanoidRootPart.Position - Vector3.new(10, 10, 10), humanoidRootPart.Position + Vector3.new(10, 10, 10), {character} ) for _, part in ipairs(parts) do if part:IsA("BasePart") and part.CanCollide then local direction = humanoidRootPart.Position - part.Position part.Velocity = direction.Unit * 10 end end wait(0.1) end superpowerActive = false end end game.Players.LocalPlayer:GetMouse().KeyDown:Connect(function(key) if key == "p" then activateSuperpower() end end)