|
| 16 Nov 2014 12:04 AM |
So I made this script:
alert = script.Parent.Parent.Players.LocalPlayer.PlayerGui.AlertTime.Frame wait(14)
local i = 1 while i < 10 do alert.BackgroundTransparency = 0.1 wait(0.05) alert.BackgroundTransparency = 0.2 wait(0.05) alert.BackgroundTransparency = 0.3 wait(0.5) alert.BackgroundTransparency = 0.4 wait(0.05) alert.BackgroundTransparency = 0.5 wait(0.05) alert.BackgroundTransparency = 0.6 wait(0.05) alert.BackgroundTransparency = 0.7 wait(0.05) alert.BackgroundTransparency = 0.8 wait(0.05) alert.BackgroundTransparency = 0.9 wait(0.05) alert.BackgroundTransparency = 0.8 wait(0.05) alert.BackgroundTransparency = 0.7 wait(0.05) alert.BackgroundTransparency = 0.6 wait(0.05) alert.BackgroundTransparency = 0.5 wait(0.05) alert.BackgroundTransparency = 0.4 wait(0.05) alert.BackgroundTransparency = 0.3 wait(0.05) alert.BackgroundTransparency = 0.2 wait(0.05) end
I also tried changing:
alert = script.Parent.Parent.Players.LocalPlayer.PlayerGui.AlertTime.Frame
To
alert = game.Players.LocalPlayer.PlayerGui.AlertTime.Frame
But that did nothing, for some reason I can't access the PlayerGui with this script, can anyone help? I think it might be because it can't find the local player. Thank you. |
|
|
| Report Abuse |
|
|
WishNite
|
  |
| Joined: 11 Feb 2009 |
| Total Posts: 15828 |
|
|
| 16 Nov 2014 12:18 AM |
its a localscript, correct?
put the alert define line underneath the wait(14) and you should be okay. |
|
|
| Report Abuse |
|
|
| |
|
|
| 16 Nov 2014 01:26 AM |
local player = game.Players.LocalPlayer local alert = player.PlayerGui.AlertTime.Frame
for i = 1, 7, 0.1 do alert.BackgroundTransparency = i wait(0.05) end for i = 1, 5, -0.1 do alert.BackgroundTransparency = i wait(0.05) end
|
|
|
| Report Abuse |
|
|
MrEpic534
|
  |
| Joined: 12 May 2012 |
| Total Posts: 1349 |
|
|
| 16 Nov 2014 02:07 AM |
| player = game.players.LocalPlayer |
|
|
| Report Abuse |
|
|
parkiet3
|
  |
| Joined: 16 Jul 2011 |
| Total Posts: 832 |
|
|
| 16 Nov 2014 04:27 AM |
| Does it give an error? Btw replace those transparency stuff with 2 loops |
|
|
| Report Abuse |
|
|
parkiet3
|
  |
| Joined: 16 Jul 2011 |
| Total Posts: 832 |
|
|
| 16 Nov 2014 04:31 AM |
Also make sure this is a localscript and if it gets called in the beginning of the game, it could be it isnt yet created So put the fist line below the wait or add repeat wait() until game.Players.LocalPlayer.PlayerGui:FindFirstChild("alertGui") or something like that :) |
|
|
| Report Abuse |
|
|