How do I prevent players from unequipping their tools?

Hi I’m trying to prevent players from unequipping or equipping other tools until the tool they are using finishes the action it does.

Right now the only thing I came up with is using this:

game.StarterGui:SetCoreGuiEnabled(Enum.CoreGuiType.Backpack, false)

But this will also disable the inventory screen itself which is annoying.

I guess you can put a attribute or value inside the player and call it something like DoingAction, and set that value to true each time they use a tool, then set it back to false when the player isn’t doing an action, and they can only put away the gun if the value is false.

Though idk if its possible to turn off unequip on tools, so you might have to look into that.

I already have the values for the player tool thing but yeah that’s the problem ,I don’t know how to disable players from putting it away.

Oh.

Well, I don’t think theres an easy way really, unlike you’re doing now.

You would probably have to make you’re own inventory system to prevent the UI from hiding.

Heres a topic I found related to unequipping tools:

Or this one:

Well I guess the time has come for it.

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.