-
What do you want to achieve? Keep it simple and clear!
I’m trying to Make my own Backpack type of thing -
What is the issue? Include screenshots / videos if possible!
I’m Using UserInputService to Detect when The player presses a Number but Using
game:GetService("UserInputService").InputBegan
Makes it so If you hold it, it will unequip and equip rapidly, what I want is if you press the one key one time it will equip, and if you press it another time it will unequip just like the standard Backpack
-
What solutions have you tried so far? Did you look for solutions on the Developer Hub?
I’ve tried Checking if the Player has the tool but I want if you press one the second time it unequips so it wont do anything if your just holding 1 down
UserInputService.InputBegan:Connect(function(Input)
if Input.KeyCode == Equip1 then
if not Character:FindFirstChild("P90") then
Humanoid:EquipTool(Player.Backpack:FindFirstChild("P90"))
end
elseif Character:FindFirstChild("P90") then
Humanoid:UnequipTools()
end
end)
Sorry if This Post is a Little Confusing