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

How do I make where when you choose the item in your inventory, the inventory disappears?

Asked by 10 years ago

Just wondering, for certain games. Mainly Horror games. You know? Is there a way?

0
Are you asking to remove the tool or the actual core GUI where all of your tools are stored? Aethex 256 — 10y
0
actual core GUI where all of your tools are stored... alienvspredatorfan1 0 — 10y

1 answer

Log in to vote
0
Answered by
Aethex 256 Moderation Voter
10 years ago

You would use the Equipped event to know that the tool is equipped and the SetCoreGuiEnabled method to get rid of the backpack GUI. Also, please make sure the script inside the tool is a localscript. As well as to remember that tools always need handles to work.

local tool = script.Parent;

tool.Equipped:connect(function()

    game.StarterGui:SetCoreGuiEnabled("Backpack", false);

end)
Ad

Answer this question