Python Forum
[PyGame] Beginning PyGame question about "self"
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[PyGame] Beginning PyGame question about "self"
#2
self refers to the object. Without self they are local variables that disappear when method is returned.

__init__ is just a constructor. Player() = Player.__init__() .
99 percent of computer problems exists between chair and keyboard.
Reply


Messages In This Thread
RE: Beginning PyGame question about "self" - by Windspar - Dec-08-2017, 09:07 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  question about my pygame code for space shooter Than999 4 3,870 Feb-07-2022, 03:55 AM
Last Post: metulburr
  question about my Pygame code Than999 2 2,517 Feb-06-2022, 10:03 PM
Last Post: Than999

Forum Jump:

User Panel Messages

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