Advertisement
Guest User

script tres

a guest
Feb 24th, 2020
73
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.13 KB | None | 0 0
  1. local Players = game:GetService("Players")
  2. local plrgui = script.Parent.Parent.Parent.BackgroundManagement.Background.FGBG
  3. script.Parent.Visible = true
  4.  
  5. local function onPlayerAdded(player)
  6. if player ~= game.Players.LocalPlayer then
  7. local nplr = Instance.new("TextLabel")
  8. nplr.Parent = plrgui
  9. nplr.BackgroundTransparency = 1
  10. nplr.Text = "[+]"..player.Name.." joined!"
  11. nplr.Size = UDim2.new(0, 250, 0, 50)
  12. nplr.Position = UDim2.new(0, 0, 0.2, 0)
  13. nplr.TextScaled = true
  14. nplr.ZIndex = 100
  15. nplr.TextColor3 = Color3.new(255, 241, 43)
  16. nplr.Font = "Cartoon"
  17. local tweenInfo1 = TweenInfo.new(10, Enum.EasingStyle.Linear, Enum.EasingDirection.InOut, 0, false, 0)
  18. local tweenInfo = TweenInfo.new(3, Enum.EasingStyle.Linear, Enum.EasingDirection.InOut, 0, false, 2)
  19. local goal1 = {}
  20. goal1.Position = UDim2.new(0, 0, -0.1, 0)
  21. local goal = {}
  22. goal.TextTransparency = 1
  23. local tween1 = game:GetService("TweenService"):Create(nplr, tweenInfo1, goal1)
  24. local tween = game:GetService("TweenService"):Create(nplr, tweenInfo, goal)
  25. wait()
  26. tween:Play()
  27. tween1:Play()
  28. wait(10)
  29. nplr:Destroy()
  30. end
  31. end
  32.  
  33. local function onPlayerLeave(player)
  34. local nplr = Instance.new("TextLabel")
  35. nplr.Parent = plrgui
  36. nplr.BackgroundTransparency = 1
  37. nplr.Text = "[-]"..player.Name.." left!"
  38. nplr.Size = UDim2.new(0, 250, 0, 50)
  39. nplr.Position = UDim2.new(0, 0, 0.2, 0)
  40. nplr.TextScaled = true
  41. nplr.ZIndex = 100
  42. nplr.TextColor3 = Color3.new(255, 241, 43)
  43. nplr.Font = "Cartoon"
  44. local tweenInfo1 = TweenInfo.new(10, Enum.EasingStyle.Linear, Enum.EasingDirection.InOut, 0, false, 0)
  45. local tweenInfo = TweenInfo.new(3, Enum.EasingStyle.Linear, Enum.EasingDirection.InOut, 0, false, 2)
  46. local goal1 = {}
  47. goal1.Position = UDim2.new(0, 0, -0.1, 0)
  48. local goal = {}
  49. goal.TextTransparency = 1
  50. local tween1 = game:GetService("TweenService"):Create(nplr, tweenInfo1, goal1)
  51. local tween = game:GetService("TweenService"):Create(nplr, tweenInfo, goal)
  52. wait()
  53. tween:Play()
  54. tween1:Play()
  55. wait(10)
  56. nplr:Destroy()
  57. end
  58.  
  59. game.Players.PlayerRemoving:Connect(onPlayerLeave)
  60. game.Players.PlayerAdded:Connect(onPlayerAdded)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement