Please enable JavaScript to use CodeHS

Video Game Design in JavaScript (2022)

Lesson 4.5 Mouse Events: Mouse Clicked

Description

Here we introduce a way the students can get input from the mouse using mouse clicked. We keep some of the same building blocks by showing examples with circles and ghosts, and then the student programs prompt them to use this new idea in combination with tracking overall program state.


Objective

Students will be able to…

  • Describe how events are different than timers
  • Use mouse click events to create programs that respond to user clicks