Re: [Tutor] inheritance, python and pygame

2011-10-11 Thread Steven D'Aprano
rail shafigulin wrote: i'm trying to learn OOP, python and pygame at the same time. so far it has been ok, but i stumbled onto a problem Hugo has already pointed out that you mispelled __init__, and that in Python 3 you don't need to explicitly provide arguments to super(). class BaseSprite

Re: [Tutor] inheritance, python and pygame

2011-10-11 Thread rail shafigulin
On Tue, Oct 11, 2011 at 10:56 AM, Hugo Arts wrote: > On Tue, Oct 11, 2011 at 4:20 PM, rail shafigulin > wrote: > > i'm trying to learn OOP, python and pygame at the same time. so far it > has > > been ok, but i stumbled onto a problem > > > > here is the code that causes problems > > > > #!/usr/

Re: [Tutor] inheritance, python and pygame

2011-10-11 Thread Hugo Arts
On Tue, Oct 11, 2011 at 4:20 PM, rail shafigulin wrote: > i'm trying to learn OOP, python and pygame at the same time. so far it has > been ok, but i stumbled onto a problem > > here is the code that causes problems > > #!/usr/bin/python3.1 > import pygame > pygame.init() > > class BaseSprite(pyga

[Tutor] inheritance, python and pygame

2011-10-11 Thread rail shafigulin
i'm trying to learn OOP, python and pygame at the same time. so far it has been ok, but i stumbled onto a problem here is the code that causes problems #!/usr/bin/python3.1 import pygame pygame.init() class BaseSprite(pygame.sprite.Sprite): def __init(self, imagefile): super(type(self), se