|
| 11 Sep 2014 03:37 PM |
ThePlayer.PlayerGui.Main.Teams.Changed:connect(function (change) if game.Players.LocalPlayer.TeamColor == BrickColor.new("Bright violet") or game.Players.LocalPlayer.TeamColor == BrickColor.new("Bright yellow") then return end if #t > 0 then for i = 1,#t do local base = Instance.new("Frame") for _,lol in pairs (game.Lighting.MainGamePortions.Acronyms:GetChildren()) do if lol.Value == t[i] then base.Name = lol.Name end end base.Size = UDim2.new(1,0,.05,0) base.Position = UDim2.new(0,0,calculateYPosition(),10) base.BackgroundTransparency = 1 base.Parent = ThePlayer.PlayerGui.Main.Teams local a = ThePlayer.PlayerGui.Main.Example:Clone() for _,lold in pairs (game.Lighting.MainGamePortions.Acronyms:GetChildren()) do if lold.Value == t[i] then a.Text = lold.Name end end a.Visible = true a.TextColor = game.Lighting.Teams:FindFirstChild(t[i]).TeamColor a.Parent = base a.MouseButton1Down:connect(function () game.Players.LocalPlayer.TeamColor = a.TextColor game.Players.LocalPlayer.PlayerGui.Money.TeamVal.Value = a.Text game.Players.LocalPlayer.PlayerGui.Money.Money.Value = findMoney(t[i]) game.Players.LocalPlayer:LoadCharacter() end) end end end)
It clones the buttons lots of times. |
|
|
| Report Abuse |
|
|
| 11 Sep 2014 03:40 PM |
| I know why because it tweens the position but how can i make it where it checks the visible property? |
|
|
| Report Abuse |
|
Bobobob12
|
  |
| Joined: 23 Jan 2008 |
| Total Posts: 5350 |
|
|
| 11 Sep 2014 03:43 PM |
| if not changed == "Visible" then return end |
|
|
| Report Abuse |
|