#How i delete a frame with values
32 messages · Page 1 of 1 (latest)
also if you want to edit players gui in-game you might want to do this through a local script
and change it directly from the player
-- LOCALSCRIPT IN PlayerCharacterScripts
local Player = game.Players.LocalPlayer
local battery = game.ReplicatedStorage.FlashlightBattery.Value
local Frame = Player.StarterGui.ScreenGui.FlashLightGui.Max100
Frame.Transparency = battery < 100
you also have to add ScreenGui in StarterGui Folder and move your frames inside of it
otherwise it wont appear
and this only checks once, if you want to check this everytime the value changed you might want to do this instead
-- LOCALSCRIPT IN PlayerCharacterScripts
local Player = game.Players.LocalPlayer
local Battery = game.ReplicatedStorage.FlashlightBattery
local Frame = Player.PlayerGui.FlashLightGui.Max100
Battery.Changed:Connect(function()
Frame.Transparency = Battery.Value < 100
end)
like that ?
Oh
It's a screengui the flashlight gui
You should never rename screenguis
Instead you name the frame accordingly
Let me update the code accordingly
You can remove the screenGui
ok ty
And keep the FlashLightGui
i have this error "StarterGui is not a valid member of Player"
Replace startergui with Playergui
In local frame
Player.StarterGui -> Player.PlayerGui
Can you go to players
And click the dropdwon
On your name
I forgot what it is named
Here ?
edited
not working
** You are now Level 2! **
a dont have errors