예제 #1
0
 def __init__(self):
     AbstractGroup.__init__(self)
예제 #2
0
 def __init__(self):
     AbstractGroup.__init__(self)
     self._spritelist = []
예제 #3
0
 def add_internal(self, sprite):
     AbstractGroup.add_internal(self, sprite)
     self._spritelist.append(sprite)
예제 #4
0
파일: map.py 프로젝트: ceronman/twsitemall
	def __init__(self, owner_map, *sprites):
		AbstractGroup.__init__(self)
		self.add(*sprites)
		self.owner_map = owner_map
		owner_map.group = self
예제 #5
0
# print(rect)
# print(rect.centerx)
# print(rect.bottom)
# print(rect.midleft)


class AbstractPrint(Sprite):
    def __init__(self):
        super().__init__()
        self.lines = 'abstract'

    def update(self):
        print(self.lines + " * ")


abstract_prints = AbstractGroup()
for numb in range(4):
    abstract_print = AbstractPrint()
    abstract_prints.add(abstract_print)
    print(abstract_print.lines + " " + str(numb) + " *")
print(abstract_prints.update())
print(abstract_prints.spritedict)

# def shot_bullet():

#     pygame.init()
#     pygame.display.set_mode((100, 100))
#     # abstract_bullets = AbstractGroup()
#     bullets = Group()
#     while True:
#         for event in pygame.event.get():
예제 #6
0
 def __init__(self):
     AbstractGroup.__init__(self)
     self.zorder = []
예제 #7
0
 def remove(self, sprite):
     AbstractGroup.remove(self, sprite)
     self.sort_by_z()
예제 #8
0
 def add(self, sprite):
     AbstractGroup.add(self, sprite)
     self.sort_by_z()