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

Why Isn't notification not sending a message?

Asked by 2 years ago
Edited by Xapelize 2 years ago

So I have gotten Into a problem where I am trying to have a notification pop up when It touched a part however the problem Is that It doesn't show let me break It down:

This Is the part: (Note: The part Is Inside of a model)

local part = script.Parent

local function findBot()
    game.StarterGui.findBot.Disabled = false
    wait(0.1)
    game.StarterGui.findBot.Disabled = true
end

part.Touched:Connect(findBot)



This Is the starterGUI local script:


local part = script.Parent local function findBot() game.StarterGui.findBot.Disabled = false wait(0.1) game.StarterGui.findBot.Disabled = true end part.Touched:Connect(findBot)

Hopefully this Is enough Information to get you started on nerfing It, thank you!

1 answer

Log in to vote
0
Answered by
Xapelize 2658 Moderation Voter Community Moderator
2 years ago

You should change PlayerGui not the StarterGui, for example:

game:GetService("Players").LocalPlayer:WaitForChild("PlayerGui").findBot.Disabled = true

not

game.StarterGui.findBot.Disabled = true

Full script:

local part = script.Parent

local function findBot()
    game:GetService("Players").LocalPlayer:WaitForChild("PlayerGui").findBot.Disabled = false
    wait(0.1)
    game:GetService("Players").LocalPlayer:WaitForChild("PlayerGui").findBot.Disabled = true
end

part.Touched:Connect(findBot)
0
Omg no variables Puppynniko 1059 — 2y
0
@Puppynniko this is old post and you replied so you basicaly broke every single rules in scripting helpers ill ban you now!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!1 Xapelize 2658 — 2y
Ad

Answer this question