Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Why is NPC Chat not updating?

Asked by 5 years ago

Hello!

I'm making a story game, which features NPC Chat, and a tram. The script below opens a door, and the most important part is that it also.. How do I say it: Makes the message for the NPC? (The location of the script is: game.StarterGuI.Chat.Frame.script)

Script:

01local chat = game.Players.LocalPlayer.PlayerGui.Chat.Frame
02local text = chat:WaitForChild("TextLabel")
03local name = chat.NpcName
04local de = false
05local conveyor = workspace.ConveyorStop
06local vault = workspace.VaultDoor1
07local door1 = vault.OpemDoor1
08local door2 = vault.OpenDoor2
09local tram = workspace.Tram
10 
11function message(speech)
12    for i = 1, #speech do
13            text.Text = string.sub(speech, 1, i)
14            wait()
15        end
View all 47 lines...

Any help would be grateful!

Answer this question