Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Appearing and disappearing text label not changing transparency 2?

So i made an article yesterday, got a reply, but now im running into some more problems. In my script i used to have

startingbox = Instance.new("ScreenGui", game.Players.LocalPlayer.PlayerGui

and

startingd =  Instance.new("TextLabel", game.Players.LocalPlayer.PlayerGui.startingbox)

which didn't give me any problems, but then i started using this:

startingbox = Instance.new("ScreenGui")
startingbox.Parent = game.Players.LocalPlayer.PlayerGui

startingd = Instance.new("TextLabel")
startingd.parent = game.Players.LocalPlayer.PlayerGui.startingbox

the problem I'm having is it is not recognizing startingbox as being in PlayerGui, and isn't moving on with the script.

I'm trying to make some character monologuing with the textlabel

Here is my full script. When I did the first thing I mentioned, it ran through the script fine. My original problem was it wasn't changing transparency, even though it goes through the whole script. It used to be directed at game.StartGui, but even after changing to PlayerGui I'm still having the same problem. Can anyone help?

game:GetService("Players").LocalPlayer:WaitForChild("PlayerGui")
startingboxd = Instance.new("ScreenGui")
startingd = Instance.new("TextLabel")
startingboxd.Parent = game.Players.LocalPlayer.PlayerGui
startingd.Parent = game.Players.LocalPlayer.PlayerGui.startingboxd
	startingboxd.Name = "completegui1"
	startingd.Text = "Finally, I’ve made it to the checkpoint."
		startingd.BackgroundTransparency = 1
		startingd.Position = UDim2.new(string)
		startingd.Size = UDim2.new(string)
		startingd.Font = "Fantasy"
		startingd.FontSize = 30
		startingd.TextColor = Color3.fromRGB(225, 225, 225)
		startingd.TextTransparency = 1
wait(3)
	for iappear = 1, 0, -.01 do
		startingd.TextTransparency = iappear
		wait(.05)
	end
wait(5)
	for idisappear = 0, 1, .01 do
		startingd.TextTransparency = idisappear
		wait(.05)
	end
wait(2)
--[[Next line of text]]--
	startingd.Text = "I better get going, there’s no point in standing out in the rain."
	for iappear2 = 1, 0 -.01 do
		startingd.TextTransparency = iappear2
		wait(.05)
	end
wait(7)
	for idisappear2 = 0, 1, .01 do
		startingd.TextTransparency = idisappear2
		wait(.05)
	end
--[[Cleanup]]--
game.Players.LocalPlayer.PlayerGui.completegui1:Destroy()
wait(1)

print("ScriptFullyLoaded")

2 comments

0

I changed fontsize to textsize and i think my first problem was because i needed to name the screengui first. im still having the second problem though

0

Okay the script i published was a test script, it has a bunch of wholes I can see now. if i fix them and am still having problems ill post here

1 answer

alright i fixed it if anyone else was having my problems. here is the complete script, it should work fine. you might have to tweak things depending on how you want them if you want to copy it ^_^

game:GetService("Players").LocalPlayer:WaitForChild("PlayerGui")
startingboxd = Instance.new("ScreenGui", game.Players.LocalPlayer.PlayerGui)
startingboxd.Name = "completegui1"
startingd = Instance.new("TextLabel", game.Players.LocalPlayer.PlayerGui.completegui1)
	startingd.Text = "Finally, I’ve made it to the checkpoint."
		startingd.BackgroundTransparency = 1
		startingd.Position = UDim2.new(0.417, 0, 0.862, 0)
		startingd.Size = UDim2.new(0, 319, 0, 57)
		startingd.Font = "Fantasy"
		startingd.TextSize = 30
		startingd.TextColor3 = Color3.new(1, 1, 1)
		startingd.TextTransparency = 1
wait(3)
	for iappear = 1, 0, -.01 do
		startingd.TextTransparency = iappear
		wait(.05)
	end
wait(5)
	for idisappear = 0, 1, .01 do
		startingd.TextTransparency = idisappear
		wait(.05)
	end
wait(2)
--[[Next line of text]]--
	startingd.Text = "I better get going, there’s no point in standing out in the rain."
	for iappear2 = 1, 0 -.01 do
		startingd.TextTransparency = iappear2
		wait(.05)
	end
wait(7)
	for idisappear2 = 0, 1, .01 do
		startingd.TextTransparency = idisappear2
		wait(.05)
	end
--[[Cleanup]]--
game.Players.LocalPlayer.PlayerGui.completegui1:Destroy()
wait(1)

print("ScriptFullyLoaded")

This discussion is preserved as it was. New answers, comments, and votes are closed.