am 2f63207d: am a6491229: am 930ac01f: am de0a8700: Merge "docs: Fixed typos in Game Controller training code snippets. bug: 17959906" into lmp-docs
* commit '2f63207d873fcd2c39488f78b5cb1b67f868f232': docs: Fixed typos in Game Controller training code snippets. bug: 17959906
This commit is contained in:
@@ -518,7 +518,7 @@ public class GameView extends View {
|
|||||||
// Check that the event came from a game controller
|
// Check that the event came from a game controller
|
||||||
if ((event.getSource() & InputDevice.SOURCE_JOYSTICK) ==
|
if ((event.getSource() & InputDevice.SOURCE_JOYSTICK) ==
|
||||||
InputDevice.SOURCE_JOYSTICK &&
|
InputDevice.SOURCE_JOYSTICK &&
|
||||||
event.getAction() == MotionEvent.ACTION_MOVE)
|
event.getAction() == MotionEvent.ACTION_MOVE) {
|
||||||
|
|
||||||
// Process all historical movement samples in the batch
|
// Process all historical movement samples in the batch
|
||||||
final int historySize = event.getHistorySize();
|
final int historySize = event.getHistorySize();
|
||||||
@@ -609,9 +609,6 @@ private void processJoystickInput(MotionEvent event,
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Update the ship object based on the new x and y values
|
// Update the ship object based on the new x and y values
|
||||||
...
|
|
||||||
|
|
||||||
return true;
|
|
||||||
}
|
}
|
||||||
</pre>
|
</pre>
|
||||||
<p>To support game controllers that have more sophisticated
|
<p>To support game controllers that have more sophisticated
|
||||||
|
|||||||
Reference in New Issue
Block a user