Tower defense (OOP4Fun Book)

TLA details

Name
Collision detection explanation
Description

The teacher put an instance of the Enemy class on the World, and an instance of the Direction class in the same row. The teacher adds code to the act() method so that the object moves one step forward.

The teacher explains to the students how to determine whether two or more objects ("characters") on the World are in the same position (on the same cell). The teacher explains the method: isTouching().

The teacher and students modify the act() method of the Enemy class to ensure that the enemy rotates 90° clockwise when it is in the same cell that contains an instance of the Direction class.

Together with the students, the teacher observes what happens with the rotation attribute.

Learning type
Investigation
Description Learning through investigation guides the learner to explore, compare and critique the texts, documents and resources that reflect the concepts and ideas being taught.
Example usage Comparing texts, searching and evaluating information and ideas, using digital tools to collect and analyse data, using conventional methods to collect and analyse data,…
Workload
30
Activity delivery
Online
On-site
Hybrid
Synchronous
Asynchronous
Teacher-present
Teacher not present
Collaboration
Work in groups
Feedback
Feedback provider
Teacher
Automated
Peer
Other

Assessment