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

How do I make a game shout script, I can activate the shout but text doesn't change?

So the box and all shows but the text does not change. I use a text button to activate the shout and a text box on the gui to create a shout.

local Text = script.Parent.Shout.Shout.Text
local Button = script.Parent.ShoutBox.TextButton
local SText = script.Parent.ShoutBox.TextBox.Text
local Frame = script.Parent.Shout

Button.MouseButton1Click:connect(function()
	script.Parent.Shout.Shout.TextScaled = true
	Frame.Visible = true
	Text = SText
	wait(5)
	Frame.Visible = false
	script.Parent.Shout.Shout.TextScaled = false
end)

2 comments

0

SText.Text?

0

Look at the local things at the start they tell you what Text and SText are

1 answer

✓ Accepted answer

You get the text on the start of your script, you should get it when the function runs

You have the same problem with text, as text is a string var it won't update the object propertie.

Also never use Text as a name :/

Like this

local AText = script.Parent.Shout.Shout
local Button = script.Parent.ShoutBox.TextButton
local SText = script.Parent.ShoutBox.TextBox
local Frame = script.Parent.Shout

Button.MouseButton1Click:connect(function()
    script.Parent.Shout.Shout.TextScaled = true
    Frame.Visible = true
    AText.Text = SText.Text
    wait(5)
    Frame.Visible = false
    script.Parent.Shout.Shout.TextScaled = false
end)

Should work :)

2 comments

0

Works perfectly thanks!

0

Np :)

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