The code below is supposed to create the teleport UI, fill in some data, and then use it for teleporting. However, it doesn’t work, and rather the default skybox is provided during teleporting (teleporting still works fine).
local teleportUI = game.ReplicatedStorage.TeleportUI:Clone() teleportUI.Frame.FlightID.Text = flightID teleportUI.Frame.Location.Text = "En route to "..destination teleportUI.Frame.LocationImage.Image = "rbxassetid://"..image teleportUI.Parent = game.Players.LocalPlayer:FindFirstChild("PlayerGui") TPS:SetTeleportGui(teleportUI) TPS:Teleport(HIDDEN,game.Players.LocalPlayer,teleportData)
The code above is ran in a LocalScript. I’ve also tried not using SetTeleportGui and providing the teleport screen as a parameter of the Teleport function, however that also didn’t work. What am I doing wrong?