WEBVTT 00:00:00.840 --> 00:00:04.680 Unplugged Activity | The Big Event 00:00:07.060 --> 00:00:10.030 This lesson is called "The Big Event" It's all about how 00:00:10.030 --> 00:00:15.969 we can control our programs and actually change the way a program runs on the fly, using events. 00:00:15.969 --> 00:00:21.590 Like the push of a button or like the click of a mouse. For this lesson, you'll be controlled 00:00:21.590 --> 00:00:28.590 with a paper remote control. It's just like a real live video game. An event is an action 00:00:29.390 --> 00:00:33.540 that causes something to happen. It's like when you click the button on a mouse, and 00:00:33.540 --> 00:00:37.810 the web page loads. That's an event. When you touch your screen on a tablet to scroll, 00:00:37.810 --> 00:00:43.840 that's an event also. Events are a great way of letting the user direct your program, whenever 00:00:43.840 --> 00:00:50.840 they need or want to. There are things that happen that we all respond to. 00:00:50.840 --> 00:00:54.840 We feel hungry so we go to the fridge. 00:00:54.840 --> 00:00:57.420 We hear the mailman come, he puts our mail in the mailbox, and 00:00:57.430 --> 00:01:02.640 then we go get our mail. Those are just like the events of pushing a button or moving the 00:01:02.640 --> 00:01:07.860 joystick. They are something that happens that triggers us to do something. Most people 00:01:07.860 --> 00:01:13.189 who program video games, there's this one event that everyone calls "update" and it 00:01:13.189 --> 00:01:20.030 happens 30 or 60 times a second. For video game programmers, that's more important as 00:01:20.030 --> 00:01:24.479 an event than the buttons or the joystick. Because what we tend to do is, the main event 00:01:24.479 --> 00:01:30.539 we're watching for is that tick happening. And then we check the joystick in the tick. 00:01:30.539 --> 00:01:37.539 So we say.. oh? Has somebody pushed the button in this frame? Yes or no? Without events, 00:01:37.749 --> 00:01:44.749 the player couldn't move. The player couldn't jump. You wouldn't be able to control what's 00:01:44.889 --> 00:01:50.530 going on. The video game wouldn't be able to animate anything. It's only because of 00:01:50.530 --> 00:01:56.850 the events of time passing that we're able to make animations and things move.