Placeholder Image

字幕表 動画を再生する

  • COLTON OGDEN: All right, hello world.

  • This is-- oop, you're a little cut off there.

  • This CS50 on Twitch.

  • My name is Colton Ogden.

  • I'm joined briefly by--

  • DAVID MALAN: David Malan.

  • Nice to see everyone again.

  • COLTON OGDEN: Today we're doing--

  • well, first of all I should say happy Thanksgiving, happy late Thanksgiving.

  • Hope you enjoyed your holiday if you were celebrating Thanksgiving here

  • in the US or abroad.

  • We had a bit of a weekend here but we're back.

  • We're streaming today.

  • I just came back.

  • I'm a little tired.

  • I don't know about you.

  • Did you enjoy your Thanksgiving?

  • DAVID MALAN: I'm very rested, ready to start the day.

  • COLTON OGDEN: Ready to start the-- you have the hackathon this week.

  • DAVID MALAN: Indeed.

  • COLTON OGDEN: CS50 Hackathon.

  • DAVID MALAN: CS50's all night hackathon, 7:00 PM

  • to 7:00 AM later this week on campus.

  • COLTON OGDEN: Yeah.

  • So that'll be a good time, an all nighter with IHOP

  • and a bunch of other stuff.

  • Today on Twitch what we're going to do is

  • a from scratch implementation of Space Invaders.

  • Did you play Space Invaders when you were--

  • DAVID MALAN: I did.

  • When I a kid this was the state of the art.

  • Space Invaders probably came out a few years before I really got into games,

  • but this was high tech.

  • COLTON OGDEN: Yeah, this was-- oh, and thanks Jumpjump123 and Lifedevourer22

  • and DZsniper.

  • I saw that you guys followed before the stream began, so thank you very much.

  • But yeah, so we're going to do a from scratch using Love and Lua,

  • just kind of like how we did Snake and how we did Memory Game,

  • and what was the-- we did one last one that I can't remember.

  • Having a brain fart.

  • But yeah, so I'm going to jump to my laptop.

  • DAVID MALAN: I'm going to jump out, but I'm

  • going to hop into chat later and stay in touch.

  • COLTON OGDEN: Cool, cool.

  • Thanks a lot.

  • DAVID MALAN: Good too see everyone.

  • COLTON OGDEN: All right.

  • Oh, and this is funny.

  • You'll like this, by the way, before you leave.

  • I made the mistake, and everyone else from Twitch can enjoy this.

  • I'm wearing a green shirt.

  • So I am wearing an invisible shirt today.

  • DAVID MALAN: Oh, this is great.

  • So we could actually see things through you.

  • COLTON OGDEN: Yeah, exactly.

  • A little bit less screen coverage of me, more of the screen.

  • DAVID MALAN: Such a professional.

  • OK, on that note.

  • COLTON OGDEN: But yeah, that was a funny thing

  • I realized when I was coming in here to set the green screen up.

  • Let me just say hello to everybody before we actually begin.

  • I know we had quite a few people in the chat prior to everything starting up.

  • So, [INAUDIBLE],, Bavich_knight, Forcelnight, Fatma, Brenda,

  • Realcuriousqe, thank everybody who--

  • all the regulars I see are here.

  • Nishthegamer, hello!

  • Bavich_knight, hello!

  • Rajeshcanonrk, I think I have seen that name before.

  • Correct me if I'm wrong.

  • Good to see you.

  • Cloudxyzc definitely has been here before, hello.

  • Nuwanda3333 is [INAUDIBLE] and Goal1.

  • So thanks everybody who is already here.

  • So yeah, Space Invaders!

  • This is going to be fun.

  • So, Space Invaders we actually taught in the games course that I teach, GD50.

  • It was a project that we implemented.

  • We ended up scrapping the project idea from the course

  • for the second iteration of it just because it was a bit too much work.

  • But it's a great game because it's similar in some ways

  • to Breakout which we teach just prior to that,

  • because it's kind of this vertical oriented game

  • where you play as a spaceship that shoots up

  • towards the top of the screen.

  • And Breakout is a game where you're a paddle that moves left to right

  • and you bounce a ball back up to the top of the screen.

  • So I sort of feel like the two games were sort of related in a sense.

  • I think certainly the folks that implemented Space Invaders probably

  • played Breakout and were inspired.

  • And Breakout I do believe was implemented by Steve Wozniak

  • although I'm not 100% sure on that.

  • So let's do a quick old Wikipedia and just verify whether that's true.

  • Breakout the game which is here--

  • so it's by Atari.

  • I know that he implemented the Apple II version.

  • I'm not 100% sure if he--

  • oh yes, Steve.

  • So he did design breakout for Atari.

  • And then he implemented it for the Apple II.

  • And from what it says here, it was a big influence on the actual architecture

  • of the Apple II.

  • So gaming has a huge influence in the history of personal computers as well.

  • Inolove19 watching from the Philippines, thank you very much for tuning in.

  • I would like to read your comments [INAUDIBLE]..

  • I'll try to comment as much as I can.

  • What did I miss?

  • I opened and David was already leaving, says Aslee.

  • Yeah, you missed-- unfortunately he made a brief appearance and you missed it.

  • But surely we'll get him on stream again, maybe next week even.

  • Jebcochasin says, what are--

  • I apologize if I'm mispronouncing that name.

  • It could be Yobcochasin or Yobcochosin.

  • What are we going to do today?

  • We're going to implement Space Invaders from scratch.

  • So if you're unfamiliar, in prior streams

  • we've used a framework called Love2d and a language called Lua.

  • So you can download the framework Love by going to Love2d.org.

  • So I'm just going to go straight to that main page.

  • And for whatever operating system you're using you can download it,

  • if you're Windows, Mac, Linux, or otherwise.

  • And you can download prior versions, newer or older versions.

  • It's a super nice, super easy to use framework

  • that gives you a lot of abilities to do drawing and input and sound

  • and all kinds of other stuff.

  • So we'll be using that.

  • I'm sort of going to be assuming that you've maybe watched the prior streams.

  • But we'll still take it fairly slow so that folks

  • that are tuning in for the first time can follow along

  • without too much difficulty.

  • But definitely if you haven't downloaded the framework yet, download it here.

  • It's going to download an executable that you will then

  • use to run game code.

  • And if you go to the wiki page which is at the top right,

  • you go to this getting started page.

  • This getting started page will tell you, depending

  • on what operating system you're running, how to actually run your game.

  • So if you're on a Windows machine for example,

  • usually the easy way would be clicking and dragging your game folder

  • onto the executable or the shortcut.

  • But there are other ways to do it.

  • If you're on a Linux or a Mac machine, you

  • can alias the location of the actual executable file and then call that.

  • I have it set up so that in my terminal, for example--

  • I'm going to clear this--

  • I can just type love dot like that.

  • And that will actually call the love executable

  • and run it with dot, which is the current directory that I'm in.

  • So if I'm in a directory that has a main dot Lua, this will work.

  • It won't work right now because I'm not in a folder that actually has that.

  • So by default, if you just type love or type the path

  • to where it is on your machine and you have it actually there,

  • you should get a box that looks something like this with a balloon--

  • if you're running 11.1, with a balloon and a scrolling background.

  • So that's Love.

  • That's sort of the basics of how to actually find

  • it and get started with it.

  • Thanks for this game.

  • It's one of my favorite games, says Goal1.

  • Yeah, it's an awesome game.

  • I love the Breakout pset of old, says Bavich_knight.

  • Yeah, it was a great pset.

  • And I remember, I contributed a little bit to that pset as well.

  • That was right when I started working for CS50 roughly.

  • We had a laser part of that pset if you remember that,

  • and that was the part that I contributed.

  • Hi everyone's, says Lintzpotaguara.

  • Hey, Lintz, thanks for joining us.

  • Taking CS50, this is my first time watching your stream,

  • says Jacobchaussen.

  • Yes, thank you very much for joining.

  • So typically what we do is, we have a bunch of people come in,

  • people that work with CS50, myself included.