How to create a 2D game just by using a View - Draw shapes and animate - Android Studio

Channel:
Subscribers:
338
Published on ● Video Link: https://www.youtube.com/watch?v=fe2jwIChmhU



Category:
Tutorial
Duration: 53:39
181 views
4


This video tutorial demonstrates how you can draw basic shapes like circles, rectangles, strings and lines on a view and without using a layout, just use Java code, you can not only draw the shapes but can also animate these shapes to turn it into a simple 2D game

The 2D game uses an accelerometer to animate a tab left and right and the ball is bouncing off the balls.

We learn how to change screen refresh rate to 24 frames per second.
We learn how to use accelerometer to control game objects
We learn how to display score
We learn how to calculate collusion
We learn how to calculate game over condition and show it on screen

This is a very basic example but demonstrates the capabilities really well.







Tags:
Android Studio
Java
Android
Canvas
View
Invalidate
Redraw
Thread
2D Animation
Animatino
Game
Basic Game