I have a UserInputService and then a UserInputType But forsome reason after i press e and then my left button mouse it doesen’t print out “Clicked”
Services.UerInputService.InputBegan:Connect(function(input, p)
if p then return end
if input.KeyCode == Enum.KeyCode.E then
print("Pressed E")
local UpperTorso = player.Character:FindFirstChild("UpperTorso")
wall.Parent = workspace.Ignore
if WC.configure.Actived == false then
WC.configure.Actived = true
wallShower(mouse, UpperTorso)
if input.UserInputType == Enum.UserInputType.MouseButton1 then
print("Clicked")
end
else
print("Disconnect")
loopConnection:Disconnect()
WC.configure.Actived = false
wall.Parent = nil
end
end
end)
i’m guessing it wasn’t working because you spelled “UserInputService” like “UerInputService”
I also changed the way you accessed the service into something a lot better imo
local UserInputService = game:GetService("UserInputService")
UserInputService.InputBegan:Connect(function(input, p)
New Code
local UserInputService = game:GetService("UserInputService")
UserInputService.InputBegan:Connect(function(input, p)
if p then return end
local UpperTorso = player.Character:FindFirstChild("UpperTorso")
wall.Parent = workspace.Ignore
if input.KeyCode == Enum.KeyCode.E then
print("Pressed E")
if WC.configure.Actived == false then
WC.configure.Actived = true
wallShower(mouse, UpperTorso)
if input.UserInputType == Enum.UserInputType.MouseButton1 then
print("Clicked")
end
else
print("Disconnect")
loopConnection:Disconnect()
WC.configure.Actived = false
wall.Parent = nil
end
end
end)
i cheaked every where i cant find a clue i tried elseif but it didn’t really do anything, and i tried to remove the if statement. I also closed my roblox studio still no work. Also wdym by ill try and fix that?