So ima trying to make an SCP blinking Meter with my Blinking Meter and Someones SCP 173 but theres a Blinking UI in the SCP but i dont like that one so im trying to use my own, only problem is mines in the StarterUI and the other one i believe replicates its ui onto the player when near, but i want it to be there whenever and i think its simpler to have in the StarterUI (And its more Organized) heres Script if needed
His Blinking Event
while true do
wait(10)
for i,v in pairs(workspace:GetChildren()) do
delay(0,function()
if v:findFirstChild("Humanoid") and v:findFirstChild("HumanoidRootPart") and v.Name ~= "SCP-173" then
if (v.HumanoidRootPart.Position - script.Parent.HumanoidRootPart.Position).magnitude <= math.huge and v.Humanoid.Health > 0 then
if v:findFirstChild("Blinking") == nil then
print("Blinking")
local blink = Instance.new("IntValue")
blink.Name = "Blinking"
blink.Parent = v
if game.Players:findFirstChild(""..v.Name) ~= nil then
local blinkgui = script.Parent.BlinkGui:Clone()
blinkgui.Parent = game.Players:findFirstChild(""..v.Name).PlayerGui
for i = 1,10 do
wait()
blinkgui.Frame.BackgroundTransparency = blinkgui.Frame.BackgroundTransparency - 0.1
end
end
wait()
blink:Destroy()
if game.Players:findFirstChild(""..v.Name) ~= nil then
if game.Players:findFirstChild(""..v.Name).PlayerGui:findFirstChild("BlinkGui") ~= nil then
for i = 1,10 do
wait()
game.Players:findFirstChild(""..v.Name).PlayerGui:findFirstChild("BlinkGui").Frame.BackgroundTransparency = game.Players:findFirstChild(""..v.Name).PlayerGui:findFirstChild("BlinkGui").Frame.BackgroundTransparency + 0.1
end
game.Players:findFirstChild(""..v.Name).PlayerGui:findFirstChild("BlinkGui"):Destroy()
end
end
end
end
end
end)
end
end
My Blinking Meter
--Lordkhalton
local MeterLocation = script.Parent:WaitForChild("Meter")
local BlinkCast = script.Parent.Parent:WaitForChild("BlinkCastFrame")
local MeterV = 0
local MeterX = 19
local Blink = false
while true do
while Blink == false do
wait(0.75)
MeterV = MeterV + 1
if MeterLocation:FindFirstChild("Meter"..MeterX) then
MeterLocation["Meter"..MeterX].ImageTransparency = 1
MeterX = MeterX - 1
end
if MeterV == 19 then
wait(0.5)
Blink = true
MeterV = 0
MeterX = 19
end
end
if Blink == true then
while (BlinkCast.BackgroundTransparency > 0) do
wait(0.01)
BlinkCast.BackgroundTransparency = BlinkCast.BackgroundTransparency - 0.333
end
BlinkCast.BackgroundTransparency = 0
wait(0.15)
while (BlinkCast.BackgroundTransparency < 1) do
wait(0.01)
BlinkCast.BackgroundTransparency = BlinkCast.BackgroundTransparency + 0.333
end
BlinkCast.BackgroundTransparency = 1
MeterLocation.Meter1.ImageTransparency = 0
MeterLocation.Meter2.ImageTransparency = 0
MeterLocation.Meter3.ImageTransparency = 0
MeterLocation.Meter4.ImageTransparency = 0
MeterLocation.Meter5.ImageTransparency = 0
MeterLocation.Meter6.ImageTransparency = 0
MeterLocation.Meter7.ImageTransparency = 0
MeterLocation.Meter8.ImageTransparency = 0
MeterLocation.Meter9.ImageTransparency = 0
MeterLocation.Meter10.ImageTransparency = 0
MeterLocation.Meter11.ImageTransparency = 0
MeterLocation.Meter12.ImageTransparency = 0
MeterLocation.Meter13.ImageTransparency = 0
MeterLocation.Meter14.ImageTransparency = 0
MeterLocation.Meter15.ImageTransparency = 0
MeterLocation.Meter16.ImageTransparency = 0
MeterLocation.Meter17.ImageTransparency = 0
MeterLocation.Meter18.ImageTransparency = 0
MeterLocation.Meter19.ImageTransparency = 0
Blink = false
end
end
