Hello! I’m currently making a system which applies impulse on an object using the swipe of your finger. I’ve used both the TouchStarted and TouchEnded to do this for mobile. I had planned that with the touch parameter in the TouchEnded function, I could get its position to create a lookvector for the object to push it towards the location of where you released your finger. This mostly works, except the position of the touch isn’t anywhere near where it should be. Anybody know how I could fix this?
UserInputService.TouchEnded:Connect(function(touch, gpe)
if push then
push = false
Part.BrickColor = BrickColor.new("Really black")
game.ReplicatedStorage.RemoteEvent:FireServer(touch.Position, Part)
print(touch.Position) -- Output is both the X and Y being in the void, and Z always being 0
camera.CameraType = Enum.CameraType.Custom
end
end)