Ariaxs
|
  |
| Joined: 27 Feb 2012 |
| Total Posts: 637 |
|
|
| 04 Jul 2014 09:28 PM |
Trying to basically make a "Rank GUI" but by according to your rank it'll show you your access level to allow you to enter certain rooms.
Script its self:
groupid = 795844 --Insert group id here. game.Players.PlayerAdded:connect(onPlayerRespawned) function onPlayerRespawned(newPlayer) wait(1) if newPlayer:IsInGroup(groupid) then textgroup = script.Parent.Text textcolor = script.Parent.TextColor3 UnrefinedRank = newPlayer:GetRoleInGroup(groupid) if UnrefinedRank >= 8 then textgroup = "ACCESS LEVEL: RED" textcolor = Color3.new(255,0,0) if UnrefinedRank <= 7 then textgroup = "ACCESS LEVEL: GREEN" textcolor = Color3.new(0,255,0) else UnrefinedRank = "Visitor" textgroup = "ACCESS LEVEL: NONE" textcolor = Color3.new(255,255,255) end end end end
The output:
21:25:40.102 - Attempt to connect failed: Passed value is not a function 21:25:40.103 - Script 'Players.Player1.PlayerGui.ScreenGui.ACCESS.ACCESSLEVEL.Scri', Line 2 21:25:40.104 - Stack End |
|
|
| Report Abuse |
|
|
|
| 04 Jul 2014 09:34 PM |
Take this line: game.Players.PlayerAdded:connect(onPlayerRespawned)
and put it at the very bottom of your script
-[::ƧѡÎḾḠΰῩ::]-[::Helper of Scripting and Writer of Wikis::] |
|
|
| Report Abuse |
|
|
Ariaxs
|
  |
| Joined: 27 Feb 2012 |
| Total Posts: 637 |
|
|
| 04 Jul 2014 09:36 PM |
It still puts this.
21:35:21.151 - Attempt to connect failed: Passed value is not a function 21:35:21.151 - Script 'Players.Player1.PlayerGui.ScreenGui.ACCESS.ACCESSLEVEL.Scri', Line 2 21:35:21.152 - Stack End |
|
|
| Report Abuse |
|
|
|
| 04 Jul 2014 10:58 PM |
Do what I said earlier, but make sure to delete the one on line 2
-[::ƧѡÎḾḠΰῩ::]-[::Helper of Scripting and Writer of Wikis::] |
|
|
| Report Abuse |
|
|
Ariaxs
|
  |
| Joined: 27 Feb 2012 |
| Total Posts: 637 |
|
|
| 07 Jul 2014 07:37 PM |
So, Like this correct?
groupid = 795844 --Insert group id here. function onPlayerRespawned(newPlayer) wait(1) if newPlayer:IsInGroup(groupid) then textgroup = script.Parent.Text textcolor = script.Parent.TextColor3 UnrefinedRank = newPlayer:GetRoleInGroup(groupid) if UnrefinedRank >= 8 then textgroup = "ACCESS LEVEL: RED" textcolor = Color3.new(255,0,0) if UnrefinedRank <= 7 then textgroup = "ACCESS LEVEL: GREEN" textcolor = Color3.new(0,255,0) else UnrefinedRank = "Visitor" textgroup = "ACCESS LEVEL: NONE" textcolor = Color3.new(255,255,255) end end end end
game.Players.PlayerAdded:connect(onPlayerRespawned) |
|
|
| Report Abuse |
|
|