OK, so we can add songs, we can remove songs, now we want to look at starting to play songs, so
let's go ahead and close this.
So the thing we're going to use to play songs is something called pygame.
And pygame is a sort of third party python system, let's call it.
That helps.
That allows you to build games with Python.
And it comes with a fairly robust music system that we can use and we can use it very, very easily.
And so that's what we're going to start to set up in this video.
So we have to actually download it onto our computer in order to use it.
So that's what we're going to do now.
So let's head over to our terminal.
And let me just clear the screen, so in order to install this, we type and PPIF install pygame and
make sure you're in your seat and B three directory, make sure your virtual environment is turned on
because we're going to install this inside of our virtual environment.
One of the reasons why we have a virtual environment so that we can install things just like this into
it.
Now, this will only be available to us in our virtual environment.
If we deactivate our virtual environment, pygame won't be there and our app won't work.
Right.
So make sure you're in your virtual environment.
So Pip, install pygame.
And there we go, it connects online, Pippi is the Python installation program.
I think it stands for it installs little programs for you with Python.
So, OK, we've successfully installed pygame and we're good to go.
So in order to use this.
Let's head up to the top of our program and we need to import it into our file here, so let's go import
pygame.
And that's all there is to it now in order to start using this thing.
Let's go initialise pygame.
So we would just go pygame.
That Mixu.
Dot net, and this is a function and the mixer is the thing that we're going to be using, it's a music
mixer, basically, right.
So we go ahead and initialize it.
And that's really all there is to it.
That's the only thing we have to do now.
We can just start using it in our program.
So I think that's all for this video.
Go ahead and install pygame and import it if you haven't already.
In the next video, we'll start to play our first song.