SHOW:
|
|
- or go back to the newest paste.
1 | -- // Variables //-- | |
2 | local player = game.Players.LocalPlayer | |
3 | local mouse = player:GetMouse() | |
4 | ||
5 | -- // Music // -- | |
6 | local Music = Instance.new("Sound", game.Workspace) | |
7 | Music.SoundId = "rbxassetid://774530420" | |
8 | Music.Volume = 10 | |
9 | Music.Looped = true | |
10 | Music:Play() | |
11 | ||
12 | -- // Events // -- | |
13 | ||
14 | ((mouse.KeyDown:connect(function(key) | |
15 | if key == "q" then | |
16 | local part = Instance.new("Part", workspace) | |
17 | part.Name = "Brick" | |
18 | part.Material = "Neon" | |
19 | part.Size = Vector3.new(2, 2, 2) | |
20 | part.CFrame = mouse.hit | |
21 | while wait() do | |
22 | part.BrickColor = BrickColor.Random() | |
23 | end) | |
24 | if key == "e" then | |
25 | local part = Instance.new("Ball", workspace) | |
26 | part.Name = "Ball" | |
27 | part.Material = "Neon" | |
28 | part.Size = Vector3.new(2, 2, 2) | |
29 | part.CFrame = mouse.hit | |
30 | while wait() do | |
31 | part.BrickColor = BrickColor.Random() | |
32 | end | |
33 | elseif key == "m" then | |
34 | for i, v in pairs(workspace:GetChildren()) do | |
35 | if v:IsA "Part" and v.Name == "Brick" then | |
36 | v:remove() | |
37 | end | |
38 | end | |
39 | end | |
40 | end) |