Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- -- Letter drawer --
- Player = game.Players.LocalPlayer
- Mouse = Player:GetMouse()
- PlayerGui = Player:WaitForChild("PlayerGui")
- Screen = Instance.new("ScreenGui",PlayerGui)
- Screen.Name = "Letter Draw"
- letters = {
- H = {
- [1]={1,0,0,0,0,0,1};
- [2]={1,0,0,0,0,0,1};
- [3]={1,0,0,0,0,0,1};
- [4]={1,1,1,1,1,1,1};
- [5]={1,0,0,0,0,0,1};
- [6]={1,0,0,0,0,0,1};
- [7]={1,0,0,0,0,0,1};
- }}
- local Box = Instance.new("Frame",Screen)
- Box.Position = UDim2.new(0.5,0,0.5,0)
- Size = 7
- PSize = 12
- LastPos = UDim2.new(0,0,0,0)
- Box.Size = UDim2.new(0,PSize*Size,0,PSize*Size)
- Box.Position = UDim2.new(0.5,-(PSize*Size/2),0.5,-(PSize*Size/2))
- Pixels = {}
- for x = 0,Size-1 do
- for y = 0,Size-1 do
- local Pixel = Instance.new("Frame",Box)
- Pixel.BackgroundColor3 = Color3.new(1,1,1)
- Pixel.Size = UDim2.new(0,PSize,0,PSize)
- Pixel.Position = UDim2.new(0,x*PSize,0,y*PSize)
- Pixel.BorderSizePixel = 0
- table.insert(Pixels,{x=x+1,y=y+1,Pixel=Pixel})
- end
- end
- MD = false
- Mouse.Button1Down:connect(function()
- MD = true
- LastPos = UDim2.new(0,0,0,0)
- while MD and wait() do
- for i,v in pairs(Pixels) do
- if Mouse.X > v.Pixel.AbsolutePosition.X and Mouse.Y > v.Pixel.AbsolutePosition.Y and Mouse.X < v.Pixel.AbsolutePosition.X+v.Pixel.AbsoluteSize.X and Mouse.Y < v.Pixel.AbsolutePosition.Y+v.Pixel.AbsoluteSize.Y then
- v.Pixel.BackgroundColor3 = Color3.new(0,0,0)
- end
- end
- end
- end)
- Mouse.Button1Up:connect(function() MD = false end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement