1 00:00:01,159 --> 00:00:04,295 [Welcome to the Hour of Code...] 2 00:00:05,240 --> 00:00:13,440 (Star Wars musical theme) 3 00:00:13,440 --> 00:00:19,060 Hi! I'm Kathleen Kennedy and I'm the producer of Star Wars The Force Awakens. 4 00:00:19,815 --> 00:00:26,230 Today you'll be working with one of our stars, BB-8: BB-8 is a spherical droid, 5 00:00:26,230 --> 00:00:31,770 Everything he does and every movement he makes is controlled by computer software. 6 00:00:33,079 --> 00:00:38,281 Computer science impacts every industry from marketing to healthcare to film. 7 00:00:38,803 --> 00:00:42,070 In fact, hundreds of computer engineers work together 8 00:00:42,070 --> 00:00:44,800 to make a film like "The Force Awakens." 9 00:00:45,845 --> 00:00:49,348 Hi, I'm Rachel Rose, I'm the senior R&D engineer at ILM 10 00:00:49,348 --> 00:00:53,000 and I lead the animation and creature development team. 11 00:00:53,726 --> 00:00:57,780 In The Force Awakens I'm responsible for helping me artist develop rigs 12 00:00:57,780 --> 00:01:01,160 which are the parts of the character that move, 13 00:01:01,160 --> 00:01:05,644 that allow the character to look very believable in a galaxy far far away. 14 00:01:06,652 --> 00:01:09,590 In the next hour we're gonna build our own Star Wars game 15 00:01:09,597 --> 00:01:12,200 that will teach you the basic concepts of programming. 16 00:01:12,600 --> 00:01:15,780 Usually programming is all text but we're going to use blocks here 17 00:01:15,780 --> 00:01:18,436 so that we can drag and drop to rate the programs (check) 18 00:01:18,776 --> 00:01:20,738 Under the hood you're still creating code. 19 00:01:21,290 --> 00:01:24,645 After you try the basics with blocks, we'll switch you to JavaScript, 20 00:01:24,645 --> 00:01:27,399 one the most popular programming languages on the web. 21 00:01:28,148 --> 00:01:32,409 To start off, we're going to work with Ray to program BB-8 to walk 22 00:01:32,409 --> 00:01:34,203 to collect all of the scrap parts. 23 00:01:34,639 --> 00:01:36,608 Your screen is split into three parts: 24 00:01:36,608 --> 00:01:39,919 on the left is a Star Wars game space where code will run. 25 00:01:39,919 --> 00:01:43,519 The instructions for each level are written below the game space. 26 00:01:43,519 --> 00:01:47,060 This middle area is the tool box and each of these boxes 27 00:01:47,060 --> 00:01:49,039 is a command that BB-8 can understand. 28 00:01:49,629 --> 00:01:51,999 The white space on the right is called the workspace 29 00:01:51,999 --> 00:01:53,979 and this is where we're going to build our program. 30 00:01:54,362 --> 00:01:58,659 if I drag the "Move left" block to our workspace and press run, what happens ? 31 00:01:59,169 --> 00:02:01,879 BB-8 moves left one block on the grid. 32 00:02:02,269 --> 00:02:05,429 And what if I want BB-8 to do something after the "move left" block? 33 00:02:05,429 --> 00:02:07,520 I can add another block to our program. 34 00:02:08,297 --> 00:02:10,144 I'm going to choose the "move up" block 35 00:02:10,144 --> 00:02:12,520 and I'll drag it underneath my "move left" block 36 00:02:12,520 --> 00:02:14,700 until the highlight appears and then I'll drop it 37 00:02:14,700 --> 00:02:16,571 and the two blocks will snap together. 38 00:02:17,450 --> 00:02:18,980 When i press "run again" 39 00:02:18,980 --> 00:02:21,192 BB-8 will ... (check) the commands that are stacked 40 00:02:21,192 --> 00:02:23,364 from top to bottom on our workspace. 41 00:02:24,431 --> 00:02:27,000 if you ever want to delete a block, just remove it from the stack 42 00:02:27,000 --> 00:02:28,800 and drag it back into the tool box. 43 00:02:29,240 --> 00:02:34,180 After you've hit "Run", you can always hit the reset button to get back to start. 44 00:02:34,730 --> 00:02:36,100 Now let's get rolling