Bouncing Ball Assignment 3
The assignment involves creating a bouncing ball application with Android Studio, where the user can interact with different shapes, such as balls, rectangles, and squares, and observe their behaviors.
Introduction to Assignment 3
The speaker starts by mentioning that this assignment is a bit more complex than the previous ones and involves working with Android Studio. They acknowledge that they are still learning and sometimes struggle with the math involved in the project.
This is the initial screenshot of the application
Main Activity and Shape Classes
The speaker explains that the main activity involves creating a custom view and handling user interactions, such as touches and swipes. They also mention that there are different shape classes, including ball, rectangle, and square, each with its own characteristics and behaviors.
Ball Class
The speaker talks about the ball class, which has properties such as x and y coordinates, speed, and radius. They explain how the ball's movement is handled and how collisions are detected.
This is a screenshot of the ball class
Rectangle and Square Classes
The speaker discusses the rectangle and square classes, highlighting their similarities and differences. They explain how these shapes are drawn and how their properties, such as width and height, are handled.
Collision Detection
The speaker delves into collision detection, explaining how the application checks for collisions between shapes and handles them accordingly. They also mention the importance of using separate classes for collision detection to keep the code organized and efficient.
This is a screenshot of the collision detection
Custom View and User Interactions
The speaker talks about creating a custom view and handling user interactions, such as touches and swipes. They explain how the application responds to these interactions and updates the shapes accordingly.
This is a screenshot of the custom view
Conclusion and Final Thoughts
The speaker concludes by summarizing the key points of the assignment and reflecting on their experience with Android Studio. They mention that the project was challenging but rewarding and that they learned a lot about object-oriented programming and collision detection.