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

How do you delete the the toolbar?

Asked by 10 years ago

The toolbar is the bar with the tools on it. And I want to know how to delete it. Because I have a script I want to do, but without the toolbar, because it's cool.

player = game.Players.LocalPlayer
mouse = player:GetMouse()

function keyDown(key)
if key==1 then
player:EquipTool(tool.Name)
end

mouse.KeyDown:connect(keyDown)

1 answer

Log in to vote
0
Answered by
BlueTaslem 18071 Moderation Voter Administrator Community Moderator Super Administrator
10 years ago

We use the SetCoreGuiEnabled method of the StarterGui to disable and enable ROBLOX Core Gui objects.


According to the CoreGuiType Enum list the backpack is 2, which is the first parameter to SetCoreGuiEnabled. The second parameter would be false since we are disabling that gui.

game.StarterGui:SetCoreGuiEnabled(2, false);

This must be done in a LocalScript and only affects the local player

Ad

Answer this question