1
00:00:00,390 --> 00:00:01,410
Hey and welcome.

2
00:00:01,440 --> 00:00:07,710
This is going to be a fun section where we're going to build a car game from scratch using JavaScript

3
00:00:07,950 --> 00:00:14,010
and it's also going to be fairly visual where you need to drive the car to avoid the other cars, use

4
00:00:14,010 --> 00:00:17,160
the keyboards to move your car element around.

5
00:00:17,670 --> 00:00:19,750
So random movements of the other cars.

6
00:00:19,770 --> 00:00:22,140
So these are the obstacles that you cannot hit.

7
00:00:22,410 --> 00:00:27,180
We're also going to be introducing the request animation frame, which is going to give us the ability

8
00:00:27,180 --> 00:00:34,590
to iterate through and loop through the gameplay, as well as movement with the keyboard and key events

9
00:00:34,860 --> 00:00:39,720
and then success and style manipulation, which is going to be fairly heavy on this game because it

10
00:00:39,720 --> 00:00:42,510
is a visual game and collision detection.

11
00:00:42,510 --> 00:00:43,530
So that's another new one.

12
00:00:43,680 --> 00:00:50,830
And this is used quite often within games to check, to see if one is one element is overlapping another.

13
00:00:50,850 --> 00:00:52,530
So let's let's check this one.

14
00:00:52,740 --> 00:00:56,610
So here's the card game and we need to press here to start.

15
00:00:56,910 --> 00:00:58,800
And there we've got our cars.

16
00:00:58,950 --> 00:01:03,030
We've got the enemy cars that are the obstacles that we have to try to avoid.

17
00:01:03,180 --> 00:01:06,020
If we hit any of those, then the game is over.

18
00:01:06,060 --> 00:01:08,930
We get a score on the game and we can always start again.

19
00:01:09,120 --> 00:01:10,680
And then you can also move up.

20
00:01:10,680 --> 00:01:12,360
You can move backwards a little bit.

21
00:01:12,480 --> 00:01:16,590
And the objective, again, to try to avoid the other cars on the road.

22
00:01:16,590 --> 00:01:19,050
And that's what you're trying to do with the card game.

23
00:01:19,410 --> 00:01:24,570
So you can move up, you can move down a bit and these are restricted so you can adjust and tweak these

24
00:01:24,570 --> 00:01:25,350
as needed.

25
00:01:25,470 --> 00:01:30,750
You can also even add in even more obstacle cars and update the graphics.

26
00:01:31,110 --> 00:01:32,630
So I know you're excited for this one.

27
00:01:32,640 --> 00:01:34,440
Let's dive right in and start creating this.
