RobloxScripterAI
Discord ↗
Link Copied to Clipboard
×
"a button that tweens around map and changes size and position every time clicked"
-- local script (ServerScriptService) local button = script.Parent local map = game.Workspace.Map local tweenInfo = TweenInfo.new(1, Enum.EasingStyle.Quad, Enum.EasingDirection.Out, 0, false, 0) local function onClick() local newPosition = Vector3.new(math.random(-100, 100), 0, math.random(-100, 100)) local newSize = Vector3.new(math.random(5, 20), math.random(5, 20), math.random(5, 20)) local tween = game:GetService("TweenService"):Create(button, tweenInfo, {Position = newPosition, Size = newSize}) tween:Play() end button.MouseButton1Click:Connect(onClick)