Skip to content

Commit

Permalink
tilt and prsssure working
Browse files Browse the repository at this point in the history
  • Loading branch information
HEAVYPOLY committed Aug 29, 2024
1 parent 0e30e42 commit 31fd6b0
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -518,8 +518,8 @@ static boolean handleMouseEvent(final MotionEvent event) {
sourceMouseRelative = event.isFromSource(InputDevice.SOURCE_MOUSE_RELATIVE);
}

tiltX = (float) (tilt * Math.sin(orientation));
tiltY = (float) (tilt * Math.cos(orientation));
tiltX = (float) (tilt * Math.cos(orientation + Math.PI / 2));
tiltY = (float) (tilt * Math.sin(orientation + Math.PI / 2));
Log.d("GodotInputHandler", "move" + eventAction + " buttonMask " + buttonsMask + " pressure " + pressure + " tilt " + tiltX);
pressure = event.getPressure();
return handleMouseEvent(eventAction, buttonsMask, x, y, horizontalFactor, verticalFactor, false, sourceMouseRelative, pressure, tiltX, tiltY);
Expand Down

0 comments on commit 31fd6b0

Please sign in to comment.