Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Why is my tool just falling onto the baseplate in my game?

So I've just created a script that allows you to change your weapon. But when I went to test it, I noticed that the tool that equips to your humanoid using EquipTool is not working. I can't really explain it much but I hope the title cleared it up. This image I took shows it perfectly. https://gyazo.com/133ee1fa6237a2b03d51eeaa343fa34b Code:

local Player = game.Players.LocalPlayer
local UserInput = game:GetService("UserInputService")
game.StarterGui:SetCoreGuiEnabled("Backpack", false)

repeat wait() until Player.Character or Player.CharacterAdded:Wait()
local Pistol = Player.Character:WaitForChild("Humanoid"):EquipTool(game.ReplicatedStorage.Pistol:Clone())

UserInput.InputBegan:Connect(function(input)
	if input.KeyCode == Enum.KeyCode.One then
		if Player.Character:FindFirstChild("Pistol") == nil then
			local Pistol = Player.Character:WaitForChild("Humanoid"):EquipTool(game.ReplicatedStorage.Pistol:Clone())
		end
	end
end)

3 comments

0

Hey Let me tell you I dont think this is a problem with your script. I am not the best at Coding yet but I believe this is an issue with the tool itself. To fix this maybe download a pluguin to put how you want the player to hold the tool. Try the Tool Grip Editor

0

@JuzeyPlayz I don't believe that it is. I have CloneTrooper's Tool Grip Editor and it's grip is fine. The gun worked perfectly before without the script and instead using the backpack.

1 answer

Name the part of the tool "Handle", or it won't work

The same rule against leader-stats.

I apologize for lack of elaborate explanation.

1 comment

0

It is, and it still doesn't work.

This discussion is preserved as it was. New answers, comments, and votes are closed.