Save this video — free

CS50 2D - Lecture 4 - Super Mario Bros. (live, unedited)

CS50 · 2:08:26 · Watch on YouTube

CS50 2D - Lecture 4 - Super Mario Bros. (live, unedited) Watch on YouTube →

Overview

CS50's lecture on Super Mario Bros. introduces 2D game development concepts, focusing on creating virtual worlds using tile maps, 2D animation, procedural level generation, and platformer physics. David J. Malan demonstrates how to implement scrolling with `love.graphics.translate`, animate characters using sprite sheets, and manage entity states with state machines. The lecture also covers game objects, collision detection (point-to-tile for tiles, AABB for game objects), and power-up mechanics, culminating in a demonstration of a functional Mario-like platformer.

Key takeaways

Chapters

4:39 Introduction to CS50 2D and Super Mario Bros.
8:54 Key Concepts: Tile Maps, Animation, and Level Generation
10:07 Live Demonstration: Mario Gameplay
12:13 Implementing Tile Maps for World Representation
14:09 Code Walkthrough: Static Tiles (Tile Zero)
15:45 Implementing Scrolling with `love.graphics.translate` (Tile One)
18:21 Adding a Player Character (Character Zero)
20:01 Character Movement and Camera Tracking (Character One & Two)
21:48 Implementing Character Animation (Character Three)
25:04 Animating Player Actions: Walking, Idle, and Flipping
28:25 Implementing Jumping Mechanics (Character Four)
32:24 Introduction to Procedural Level Generation
34:34 Utilizing a Rich Tile Set and Toppers
35:17 Level Zero: Random Tile and Topper Combinations
38:25 Level One: Generating Pillars with Random Height
41:12 Level Two: Creating Chasms by Skipping Tile Generation
43:13 Collision Detection Fundamentals with Tile Maps
44:33 Implementing Tile Collision Checks (Left/Right)
46:43 Entities, Game Objects, and State Machines
50:00 Player States: Walking, Idle, Falling, and Jumping
52:41 Game Objects: Consumables and Interactive Blocks
58:11 Level Maker: Generating Objects like Bushes and Jump Blocks
1:00:07 Snail Entity States: Idle, Moving, and Chasing
1:07:31 Assignment 4: Level Progression and New Mechanics
1:07:54 Assignment 4: Power-ups and Invincibility
1:08:27 Preview of Next Lecture: Zelda and Top-Down Perspective
2:02:39 Post-Lecture Fix: Pong Assignment Clarification
2:04:13 Preview of Lecture 1: Flappy Bird and Game Illusions

Keep these chapters and the full searchable transcript in your own library.

Summary, takeaways, and chapters were generated by AI from the video's transcript and may contain errors. The video belongs to its creator, CS50.

Want the full transcript?

Save this video in YouTube Collector to get its complete searchable transcript, your own AI summaries, and a library that keeps every video you collect in one place.