MENU

Fun & Interesting

OOP with Pygame - Object Oriented Programming Exercise

Python Simplified 29,938 11 months ago
Video Not Working? Fix It Now

Welcome to another Python Object Oriented Programming exercise! Where we will practice classes, objects, attributes, methods, and inheritance using Pygame 🐍🐍🐍 We will take an image of a car, turn it into an object, and use it to generate trucks, police vehicles, and all kinds of sedans. The purpose of this tutorial is to help you understand the different aspects of OOP and show you why it's such an important programming concept. Even though this video begins with a quick refresher, it is recommended for folks who already have a basic background with Python classes. If you are an absolute beginner, please refer to the two tutorial recommendations on the screen and in the links below. 📺 Related Videos 📺 ---------------------------------------------------------------- ⭐ Anaconda for beginners: https://youtu.be/MUZtVEDKXsk ⭐ OOP Methods and Attributes for beginners: https://youtu.be/f0TrMH9s-VE ⭐ OOP Class Inheritance Super Init for beginners: https://youtu.be/6c6NYPjO_rI ⭐ OOP Exercise with OpenCV - Draw a Forest of Random Objects: https://youtu.be/-LsuiVGO-88 ⭐ Pygame Car Game for Beginners: https://youtu.be/W-QOtdD3qx4 ⏰ Timestamps ⏰ ---------------------------------------------------------------- 00:00 - intro 00:36 - Pygame starter code 01:04 - setup Pygame environment 02:07 - class attributes and init 04:31 - class methods 04:16 - self parameter tips and tricks 04:59 - draw object with Pygame 06:48 - why using OOP? 07:22 - keyword arguments 08:04 - create multiple objects with one class using random values 10:17 - inherit methods and attributes from parent class 10:57 - super function 11:19 - super init 11:19 - super init keyword arguments 13:00 - override attributes of child class 13:56 - child class keyword arguments 14:47 - advanced OOP example 18:22 - thanks for watching! :) 💻 Github Repo 💻 ---------------------------------------------------------------- https://github.com/MariyaSha/practiceOOP_Pygame 🤝 Connect with me 🤝 ---------------------------------------------------------------- 🔗 Github: https://github.com/mariyasha 🔗 Discord: https://discord.com/invite/wgTTmsWmXA 🔗 LinkedIn: https://ca.linkedin.com/in/mariyasha888 🔗 Twitter: https://twitter.com/mariyasha888 🔗 Blog: https://www.pythonsimplified.org 💳 Credits 💳 ---------------------------------------------------------------- ⭐ Beautiful titles, transitions, sound FX: mixkit.co ⭐ Beautiful icons: flaticon.com ⭐ Beautiful graphics and dog meme: freepik.com #python #pythonprogramming #pythontutorial #oop #objectorientedprogramming #classes #objects #coding #programming #attributes #methods #functions #inheritance #learnpython

Comment