H1dden
|
  |
| Joined: 07 Jun 2011 |
| Total Posts: 27 |
|
|
| 03 Sep 2011 02:55 PM |
-- here it is
local screen, image = Instance.new('ScreenGui'), Instance.new('ImageLabel')
screen.Parent = game:service('StarterGui') image.Parent = screen
image.Position = UDim2.new(.100, -5, .70) image.Size = UDim2.new(.2, 900, .2, 0) image.Image = 'http://www.roblox.com/asset/?id=60958137' image.BackgroundTransparency = 0
while true do image.BorderColor3 = Color3.new(math.random(), math.random(), math.random()) image.BackgroundColor3 = Color3.new(math.random(), math.random(), math.random()) wait(0.1) end
- It will only show one random color when I have a random color changeing script in.. for index,plr in pairs(game:service('Players'):children()) do if plr:findFirstChild('PlayerGui') ~= nil then screen:clone().Parent = plr.PlayerGui end end
|
|
|
| Report Abuse |
|
|
Xsitsu
|
  |
| Joined: 28 Jul 2009 |
| Total Posts: 2921 |
|
|
| 03 Sep 2011 02:56 PM |
local screen, image = Instance.new('ScreenGui'), Instance.new('ImageLabel')
screen.Parent = game:service('StarterGui') image.Parent = screen
image.Position = UDim2.new(.100, -5, .70) image.Size = UDim2.new(.2, 900, .2, 0) image.Image = 'http://www.roblox.com/asset/?id=60958137' image.BackgroundTransparency = 0
while true do image.BorderColor3 = Color3.new(math.random(0, 255)/255, math.random(0, 255)/255, math.random(0, 255)/255) image.BackgroundColor3 = Color3.new(math.random(0, 255)/255, math.random(0, 255)/255, math.random(0, 255)/255) wait(0.1) end
|
|
|
| Report Abuse |
|
|
H1dden
|
  |
| Joined: 07 Jun 2011 |
| Total Posts: 27 |
|
| |
|
Xsitsu
|
  |
| Joined: 28 Jul 2009 |
| Total Posts: 2921 |
|
|
| 03 Sep 2011 03:11 PM |
*upon closer examination*
local screen, image = Instance.new('ScreenGui', game.StarterGui), Instance.new('ImageLabel', screen)
image.Position = UDim2.new(.100, -5, .70, 0) image.Size = UDim2.new(.2, 900, .2, 0) image.Image = 'http://www.roblox.com/asset/?id=60958137' image.BackgroundTransparency = 0
while true do image.BorderColor3 = Color3.new(math.random(0, 255)/255, math.random(0, 255)/255, math.random(0, 255)/255) image.BackgroundColor3 = Color3.new(math.random(0, 255)/255, math.random(0, 255)/255, math.random(0, 255)/255) wait(0.1) end
Now? |
|
|
| Report Abuse |
|
|
H1dden
|
  |
| Joined: 07 Jun 2011 |
| Total Posts: 27 |
|
|
| 03 Sep 2011 03:14 PM |
| No that just made it stop working. |
|
|
| Report Abuse |
|
|
Camoy
|
  |
| Joined: 21 May 2009 |
| Total Posts: 6207 |
|
|
| 03 Sep 2011 03:14 PM |
*tries to be calm* Give the output. |
|
|
| Report Abuse |
|
|
Xsitsu
|
  |
| Joined: 28 Jul 2009 |
| Total Posts: 2921 |
|
|
| 03 Sep 2011 03:15 PM |
local screen, image = Instance.new('ScreenGui'), Instance.new('ImageLabel')
screen.Parent = game:service('StarterGui') image.Parent = screen
image.Position = UDim2.new(.100, -5, .70) image.Size = UDim2.new(.2, 900, .2, 0) image.Image = 'http://www.roblox.com/asset/?id=60958137' image.BackgroundTransparency = 0
while true do image.BorderColor3 = Color3.new(math.random(0, 255)/255, math.random(0, 255)/255, math.random(0, 255)/255) image.BackgroundColor3 = Color3.new(math.random(0, 255)/255, math.random(0, 255)/255, math.random(0, 255)/255) wait(0.1) end
So what exactly would the problem be with this one? |
|
|
| Report Abuse |
|
|
H1dden
|
  |
| Joined: 07 Jun 2011 |
| Total Posts: 27 |
|
|
| 03 Sep 2011 03:24 PM |
-"So what exactly would the problem be with this one?" =
Well my friend, I played the server in my test game and all's it does is choose's a random color. No, I need it to repeat. |
|
|
| Report Abuse |
|
|
Xsitsu
|
  |
| Joined: 28 Jul 2009 |
| Total Posts: 2921 |
|
|
| 03 Sep 2011 03:35 PM |
Oh, I see what's happening. It's changing the color of the gui in the StarterGui. So when you respawn it will clone that exact copy of it at the time with it's color and place it into your startergui. It will continue to change the color of the one in the StarterGui, not the one you have.
I'll edit it a little to fix it :P
function createNew()
local screen, image = Instance.new('ScreenGui'), Instance.new('ImageLabel')
screen.Parent = game:service('StarterGui') image.Parent = screen
local newscript = script:clone() newscript.Parent = image
end
function changeColors()
image = script.Parent
image.Position = UDim2.new(.100, -5, .70) image.Size = UDim2.new(.2, 900, .2, 0) image.Image = 'http://www.roblox.com/asset/?id=60958137' image.BackgroundTransparency = 0
while true do image.BorderColor3 = Color3.new(math.random(0, 255)/255, math.random(0, 255)/255, math.random(0, 255)/255) image.BackgroundColor3 = Color3.new(math.random(0, 255)/255, math.random(0, 255)/255, math.random(0, 255)/255) wait(0.1) end
end
if script.Parent:IsA("ImageLabel") then changeColors() else createNew() end
Hopefully I did that right! |
|
|
| Report Abuse |
|
|