Ad
Log in to vote
0

Gui won't display on tool Equipped?

Asked by 19 days ago

My screen gui won't display

script.Parent.Equipped:Connect(function()
    script.Parent.Parent.Parent.StarterGui["Device Screen"].Enabled = true
end)

script.Parent.Unequipped:Connect(function()
    script.Parent.Parent.Parent.PlayerGui["Device Screen"].Enabled = false
end)

I have tried startergui and playergui

0
you should try to define it as a value like "local screengui = script.Parent.Parent.Parent.StarterGui["Device Screen"]  Fouxelefr 7 — 19d

2 answers

Log in to vote
1
Answered by 19 days ago

You are going to be using PlayerGui but instead of Script.Parent Your going to need to use game.Players.LocalPlayer.PlayerGui Full example in local script in your tool

game.Players.LocalPlayer.PlayerGui["Device Screen"].Enabled =  true --For the Unequipped function copy this and change it to false

Hope this Helps!!

Ad
Log in to vote
0
Answered by
xXMadonXx 190
19 days ago

You have set the PlayerGui (which is the correct one) to false instead of true.

0
Hu that just disables the players gui completely 666_brithday 64 — 19d

Answer this question