Python Forum
[PyGame] Best way to pass data to the few game states with the same superclass?
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[PyGame] Best way to pass data to the few game states with the same superclass?
#6
I avoid inheritance unless I'm extending the class. Common gotcha is same variable and/or method name. Last one rules. They also been big discussing about multi inheritance. Most programming language don't even allow it. Like java and d.
Example of extending class. Game class need to be refactor thou.
99 percent of computer problems exists between chair and keyboard.
Reply


Messages In This Thread
RE: Best way to pass data to the few game states with the same superclass? - by Windspar - Oct-20-2021, 01:47 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  [PyGame] Variables shared between game states, how to? michael1789 5 3,423 Dec-10-2019, 10:09 PM
Last Post: metulburr

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020