For some reason, this is not working. What’s wrong?
local parent = script.Parent
function e()
parent.MaxVisibleGraphemes = 0
local graph = parent.MaxVisibleGraphemes
graph += 0.5
end
if script.Parent.Parent.Visible == true then
e()
end
It would work, doesn’t need to be a local function.
I can only suggest it isn’t working because the if statement doesn’t = true
Also since you’ve already created a variable for script.Parent you may as well use it in the if statement too:
local parent = script.Parent
function e()
parent.MaxVisibleGraphemes = 0
local graph = parent.MaxVisibleGraphemes
graph += 0.5
end
if parent.Parent.Visible == true then
e()
else print("Not Visible!") end
Try that code and see if it prints the Not Visible message
local Parent = script.Parent
function Test()
local Graph = Parent.MaxVisibleGraphemes
Graph += 0.5
end
if Parent.Parent.Visible == true then
Test()
print("Starting function?")
else
print("Something happened")
end
local Parent = script.Parent
print("Is this script even working")
function Test()
local Graph = Parent.MaxVisibleGraphemes
Graph += 0.5
end
if Parent.Parent.Visible == true then
Test()
print("Starting function?")
else
print("Something happened")
end
wait(30)
Test()
The Output looks like the function should’ve started, so it should’ve worked???
Confirm it 1 last time:
local Parent = script.Parent
print("Is this script even working")
function Test()
print("Bruh")
local Graph = Parent.MaxVisibleGraphemes
Graph += 0.5
end
wait()
if Parent.Parent.Visible == true then
Test()
print("Starting function?")
else
print("Something happened")
end