Surface GUI not appearing on Screen

– Constants
local GAMEPASS_ID = 12345678 – Replace with your actual game pass ID
local VIP_MESSAGE = “You unfortunately can’t access this area due to it being exclusive to VIPs. In order to access this room, buy the game pass.”
local BACKGROUND_COLOR = Color3.new(0, 0, 0)
local TEXT_COLOR = Color3.new(1, 1, 1)

– Function to check if a player has the game pass
local function hasGamePass(player)
return player:FindFirstChild(“GamePass” … GAMEPASS_ID) ~= nil
end

– Function to create and display the SurfaceGui
local function createSurfaceGui(player)
– Create SurfaceGui
local surfaceGui = Instance.new(“SurfaceGui”)
surfaceGui.Name = “VIPPrompt”
surfaceGui.Enabled = true
surfaceGui.ResetOnSpawn = false
surfaceGui.LightInfluence = 0
surfaceGui.Face = Enum.NormalId.Front
surfaceGui.Parent = player.PlayerGui

-- Create frame
local frame = Instance.new("Frame")
frame.Size = UDim2.new(0, 300, 0, 150)
frame.Position = UDim2.new(0.5, -150, 1, -150)
frame.AnchorPoint = Vector2.new(0.5, 1)
frame.BackgroundColor3 = BACKGROUND_COLOR
frame.BackgroundTransparency = 0
frame.Parent = surfaceGui

-- Create UICorner
local uiCorner = Instance.new("UICorner")
uiCorner.CornerRadius = UDim.new(0, 8)
uiCorner.Parent = frame

-- Create text label
local textLabel = Instance.new("TextLabel")
textLabel.Text = VIP_MESSAGE
textLabel.Size = UDim2.new(1, 0, 1, 0)
textLabel.TextColor3 = TEXT_COLOR
textLabel.BackgroundTransparency = 1
textLabel.Font = Enum.Font.SourceSansBold
textLabel.TextScaled = true
textLabel.TextWrapped = true
textLabel.Parent = frame

-- Connect the player removing the SurfaceGui when they have the game pass
local function removeSurfaceGui()
	surfaceGui:Destroy()
end

player.CharacterRemoving:Connect(removeSurfaceGui)

end

– Function to handle player touch event
local function onTouch(part)
local player = game.Players:GetPlayerFromCharacter(part.Parent)
if player and not hasGamePass(player) then
createSurfaceGui(player)

	-- Prompt player to buy the game pass
	game:GetService("MarketplaceService"):PromptGamePassPurchase(player, GAMEPASS_ID)
end

end

– Connect player touch event
game.Workspace.ForceField.Touched:Connect(onTouch)

Can someone tell me where I’ve gone wrong?