Advertisement
Greatgamer59

RainbowRankV3 Gamepass

Jul 25th, 2019
5,526
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.76 KB | None | 0 0
  1. --[[
  2. ** Rainbow Rank **
  3. Update V3
  4.  
  5. + Added a better admin system
  6. + Added a better way of configuring stuff
  7. Created by XboxCoder59
  8. --]]
  9.  
  10. -- ** Gamepass Edition **
  11.  
  12. --//\\ Config //\\
  13. local Admins = {
  14. "ROBLOX"; -- Username example
  15. 1; -- User ID example
  16.  
  17. }
  18. local Gamepassid = 0 -- your gamepass id
  19. local GroupId = 0 -- Your group ID
  20. local Speed = 0 -- How fast you want it to change color
  21.  
  22.  
  23. --//\\ Stuff below do not touch --//\\
  24. function IsWhitelisted(Player)
  25. for _,Whitelisted in pairs (Admins) do
  26. if type(Whitelisted) == "string" and string.lower(Whitelisted) == string.lower(Player.Name) then
  27. return true
  28. elseif type(Whitelisted) == "number" and Whitelisted == Player.UserId then
  29. return true
  30. end
  31. end
  32. return false
  33. end
  34.  
  35.  
  36.  
  37. local rs = game:GetService("ReplicatedStorage")
  38. local remotefolder = rs:WaitForChild("RankFolder")
  39. local remote = remotefolder:WaitForChild("RankPlayerOnRespawn")
  40.  
  41. remote.OnServerEvent:connect(function(Player)
  42. if not Player then
  43. print("ERROR Can't fetch the player")
  44. end
  45. local pRank = Player:GetRoleInGroup(GroupId)
  46. wait(1)
  47. local ui = script.Rank:Clone()
  48. ui.Parent = Player.Character
  49. ui.Adornee = Player.Character.Head
  50.  
  51. while not Player.Character.Humanoid do wait() end
  52. Player.Character.Humanoid.DisplayDistanceType = Enum.HumanoidDisplayDistanceType.None
  53. local frame = ui.Frame
  54. local name = frame.Name1
  55. local role = frame.TextLabel
  56.  
  57. name.Text = Player.Name
  58. role.Text = pRank
  59.  
  60.  
  61. -- //\\ Custom Name //\\
  62.  
  63. if name.Text == "ROBLOX" then -- Example
  64. name.TextStrokeTransparency = 0
  65. name.TextStrokeColor3 = Color3.new(0, 0, 0) -- Text Color for username
  66. role.TextStrokeTransparency = 0
  67. role.TextStrokeColor3 = Color3.new(0, 0, 0) -- Text Color for rank
  68. role.Text = "ROBLOX | Admin" -- Example of what the text should be
  69. elseif name.Text == "EXAMPLE" then
  70. name.TextStrokeTransparency = 0
  71. name.TextStrokeColor3 = Color3.new(0, 0, 0)
  72. role.TextStrokeTransparency = 0
  73. role.TextStrokeColor3 = Color3.new(0, 255, 0)
  74. role.Text = "Example yee"
  75. end
  76. -- Scripted by Xboxcoder59 plays
  77.  
  78.  
  79.  
  80. if IsWhitelisted(Player) or game:GetService("MarketplaceService"):UserOwnsGamePassAsync(Player.UserId,Gamepassid) then
  81.  
  82. wait(2)
  83. while wait() do
  84. local rc = math.random(0,255)
  85. local gc = math.random(0,255)
  86. local bc = math.random(0,255)
  87. local r = rc / 255
  88. local g = gc / 255
  89. local b = bc / 255
  90. local c = Color3.new(r, g, b)
  91. for i = 0,1,0.03 do
  92. wait(Speed)
  93. Player.Character.Rank.Frame.Name1.TextColor3 = Player.Character.Rank.Frame.Name1.TextColor3:lerp(c,i)
  94. Player.Character.Rank.Frame.TextLabel.TextColor3 = Player.Character.Rank.Frame.Name1.TextColor3:lerp(c,i)
  95. end
  96. end
  97. end
  98. end)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement