i am using an oculus quest 2, UIS is registering the button press but not detecting the hold?
my current code is this, i dont really care if it detects it being inside a block i just want it to register the left paddle down
script:WaitForChild("newarm"):WaitForChild("Script")
script.newarm:FireServer("LeftHand")
local inputService = game:GetService("UserInputService")
local leftheld = false
local leftitem = nil
local leftHand = character:WaitForChild("LeftHand")
game:GetService("RunService").RenderStepped:Connect(function()
if inputService:IsKeyDown(Enum.KeyCode.ButtonL1) then
print("left paddle down")
local parts = leftHand:GetTouchingParts()
for i2,v2 in parts do
print("iterating")
for i,v in pairs(game.Workspace.Interactables:GetDescendants()) do
if v:IsA("BasePart") then
print("isbase")
if v2 == v then
print("item found")
leftheld = true
leftitem = v
end
end
end
end
else
print("paddle not down")
leftheld = false
leftitem = nil
end
if leftheld and leftitem then
leftitem.Position = leftHand.leftatt.Position
leftitem.Orientation = leftHand.Orientation
end
end)
inputService.InputBegan:Connect(function(key, ret)
if ret then return end
if key.KeyCode == Enum.KeyCode.ButtonX then
game:GetService("VRService"):RecenterUserHeadCFrame()
end
end)