Advertisement
SlyHades66

Part To Screen Gui

Jul 10th, 2016
307
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 2.67 KB | None | 0 0
  1. --How has no-one done this yet, sense we can't TECHNICALLY inject guis into other players PlayerGuis, why not position a part to do it
  2. --For Us?
  3. --  Love, Scappy
  4.  
  5. local f = Instance.new("Folder", game.Workspace)
  6. f.Name = "Gui Handlers"
  7. for _,v in pairs(game.Players:GetChildren()) do
  8.     v.CameraMode = "LockFirstPerson"
  9.     local p = Instance.new("Part", f)
  10.     p.Size = Vector3.new(6,4,0.2)
  11.     p.CanCollide = false
  12.     p.Name = v.Name.."'s Gui Part"
  13.     p.Position = v.Character.Head.Position
  14.     wait(0.03)
  15.     local w = Instance.new("Weld", p)
  16.     w.Part0 = v.Character.Head
  17.     w.Part1 = p
  18.     w.C0 = CFrame.new(0,0,-1)
  19.     wait(0.03)
  20.     local s = Instance.new("SurfaceGui", p)
  21.     s.Face = "Back"
  22.     local l = Instance.new("Frame", s)
  23.     l.Size = UDim2.new(1,0,1,0)
  24.     l.BackgroundColor3 = Color3.new(0,0,0)
  25.     local t = Instance.new("TextLabel", l)
  26.     t.Text = "Scapters Was Here"
  27.     t.FontSize = "Size48"
  28.     t.Font = "SourceSansBold"
  29.     t.BackgroundTransparency = 1
  30.     t.Position = UDim2.new(0.5,-250,0.5,-250)
  31.     t.Size = UDim2.new(0,500,0,500)
  32. end
  33.  
  34. game.Players.PlayerAdded:connect(function(player)
  35.     player.CameraMode = "LockFirstPerson"
  36.     local p = Instance.new("Part", f)
  37.     p.Size = Vector3.new(6, 4, 0.2)
  38.     p.CanCollide = false
  39.     p.Name = player.Name.."'s Gui Part"
  40.     p.Position = player.Character.Head.Position
  41.     wait(0.03)
  42.     local w = Instance.new("Weld", p)
  43.     w.Part0 = player.Character.Head
  44.     w.Part1 = p
  45.     w.C0 = CFrame.new(0,0,-1)
  46.     wait(0.03)
  47.     local s = Instance.new("SurfaceGui", p)
  48.     s.Face = "Back"
  49.     local l = Instance.new("Frame", s)
  50.     l.Size = UDim2.new(1,0,1,0)
  51.     l.BackgroundColor3 = Color3.new(0,0,0)
  52.     local t = Instance.new("TextLabel", l)
  53.     t.Text = "Scapters Was Here"
  54.     t.FontSize = "Size48"
  55.     t.Font = "SourceSansBold"
  56.     t.BackgroundTransparency = 1
  57.     t.Position = UDim2.new(0.5,-250,0.5,-250)
  58.     t.Size = UDim2.new(0,500,0,500)
  59. end)
  60.  
  61. game.Players.PlayerAdded:connect(function(player)
  62.     player.CameraMode = "LockFirstPerson"
  63.     player.CharacterAdded:connect(function(character)
  64.         local p = Instance.new("Part", f)
  65.         p.Size = Vector3.new(6, 4, 0.2)
  66.         p.CanCollide = false
  67.         p.Name = player.Name.."'s Gui Part"
  68.         p.Position = character.Head.Position
  69.         wait(0.03)
  70.         local w = Instance.new("ManualWeld", p)
  71.         w.Part0 = player.Character.Head
  72.         w.Part1 = p
  73.         w.C0 = CFrame.new(0,0,-1)
  74.         wait(0.03)
  75.         local s = Instance.new("SurfaceGui", p)
  76.         s.Face = "Back"
  77.         local l = Instance.new("Frame", s)
  78.         l.Size = UDim2.new(1,0,1,0)
  79.         l.BackgroundColor3 = Color3.new(0,0,0)
  80.         local t = Instance.new("TextLabel", l)
  81.         t.Text = "Scapters Was Here"
  82.         t.FontSize = "Size48"
  83.         t.Font = "SourceSansBold"
  84.         t.BackgroundTransparency = 1
  85.         t.Position = UDim2.new(0.5,-250,0.5,-250)
  86.         t.Size = UDim2.new(0,500,0,500)
  87.     end)
  88. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement