But, playergui is an thing for Player = game.Getservice.
Do not reply if your not going to actually help.
local Player = game:GetService("Players")
--changed to Player instead of players--
--player not playres--
--workspace.w
workspace.Wubbox.Head.ProximityPrompt.Triggered:Connect(function(plr)
--script.Parent.scree
--game.PlayerGui.StarterGui.Frame.Enabled
--player
Player.PlayerGui.ScreenGui.Frame.Visible = true
wait(1)
Player.PlayerGui.ScreenGui.Frame.TextLabel.Text = "Hello"
local text = Player.PlayerGui.ScreenGui.Frame.TextLabel.Text
--text = "
wait(2)
--had to add wait(2)
text = "Hello there"
wait(2)
text = "I see you are new here, this is an building."
wait(2)
text = "This is an high building, not going to lie, what brings you here?"
wait(2)
text = "Watching birds? nice... bit weird but ok.."
wait(4)
text = "Anyways, You mind going to the ledge of the building for one sec?"
wait(2)
text = "Hehe... i wont budge..."
wait(2)
text = "You wont? ok, whatever."
wait(2)
text = "Well..."
wait(2)
text = "You know the traffic cone man?"
wait(2)
text = "He's gone..."
wait(2)
text = "Also, thanks for saving me from that monster... some of it is still in me, thats why i said go to the ledge, the monster was trying to push you off suspicous right!"
wait(2)
text = "Traffic cone, man got shot 12 times in the street, of new york"
wait(2)
text = "This is new york by the way!"
wait(2)
text = "Anyways, Theres something weird on another building its close"
wait(1)
--had to add wait(1)
text = "You think you can do some parkour?"
--wait
--(2)
wait(2)
--s
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.9
wait(2)
--was going to -- this but eh--
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.8
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.7
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.6
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.5
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.4
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.3
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.2
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.1
wait(0.1)
wait(1)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.
wait(5)
game.PlayerGui.ScreenGui.TextLabel.Text = "Let's begin.."
wait(2)
game.PlayerGui.ScreenGui.TextLabel.Visible = false
end)
no Players is a service and PlayerGui isn’t a child of Players
it would be game.Players.PlayerName.PlayerGui
the PlayerName being the name of the player
if player is already defined you can do Player.PlayerGui
--Table loop
local Dialogue = {
"Hello!",
"My name is Alpha",
"I'm a programmer."
}
for i, v in pairs(Dialogue) do
TextLabel.Text = v
wait(2)
end
--Tween transparency
local TweenService = game:GetService("TweenService")
TweenService:Create(TextLabel, TweenInfo.new(5), {Transparency = 0}):Play()
I provided a basic example for tweening but you can use more parameters of your choice to make it nicer within TweenInfo()
So when the ProximityPrompt is triggered, you want to loop through all the players and change the GUI for each player. Like so:
local Players = game:GetService("Players")
workspace.Wubbox.Head.ProximityPrompt.Triggered:Connect(function(plr)
for i,Player in pairs(Players:GetPlayers()) do
--script.Parent.scree
--game.PlayerGui.StarterGui.Frame.Enabled
--player
Player.PlayerGui.ScreenGui.Frame.Visible = true
wait(1)
Player.PlayerGui.ScreenGui.Frame.TextLabel.Text = "Hello"
local text = Player.PlayerGui.ScreenGui.Frame.TextLabel.Text
--text = "
wait(2)
--had to add wait(2)
text = "Hello there"
wait(2)
text = "I see you are new here, this is an building."
wait(2)
text = "This is an high building, not going to lie, what brings you here?"
wait(2)
text = "Watching birds? nice... bit weird but ok.."
wait(4)
text = "Anyways, You mind going to the ledge of the building for one sec?"
wait(2)
text = "Hehe... i wont budge..."
wait(2)
text = "You wont? ok, whatever."
wait(2)
text = "Well..."
wait(2)
text = "You know the traffic cone man?"
wait(2)
text = "He's gone..."
wait(2)
text = "Also, thanks for saving me from that monster... some of it is still in me, thats why i said go to the ledge, the monster was trying to push you off suspicous right!"
wait(2)
text = "Traffic cone, man got shot 12 times in the street, of new york"
wait(2)
text = "This is new york by the way!"
wait(2)
text = "Anyways, Theres something weird on another building its close"
wait(1)
--had to add wait(1)
text = "You think you can do some parkour?"
--wait
--(2)
wait(2)
--s
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.9
wait(2)
--was going to -- this but eh--
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.8
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.7
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.6
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.5
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.4
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.3
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.2
wait(0.5)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.1
wait(0.1)
wait(1)
game.PlayerGui.ScreenGui.TextLabel.Transparency = 0.
wait(5)
game.PlayerGui.ScreenGui.TextLabel.Text = "Let's begin.."
wait(2)
game.PlayerGui.ScreenGui.TextLabel.Visible = false
end
end)
Also I recommend following @alphajpeg’s advice and using a table to store the text strings. It’s a lot easier to code and read.
Looping through the players in one script is a bad idea. It will go to each individual player and wait for each of them. Instead, you should connect the proximity prompt to a server script which fires a remote event.
In this example I have a remote event name playerText in ReplicatedStorage.
Client
local player = game:GetService('Players').LocalPlayer
game.ReplicatedStorage.playerText.OnClientEvent:Connect(function()
--gui stuff
end)
Also here you wrote “Player:GetPlayers()” and I’m guessing the Player variable is the LocalPlayer and :GetPlayers() isnt a function of LocalPlayer so make sure to use the Players service cause that’s what it is apart of.