Added comments to lawyer class
parent
ddebb1a452
commit
b41c4a3180
|
@ -1,4 +1,7 @@
|
|||
#!/usr/bin/env python3
|
||||
"""
|
||||
A class that represents a lawyer
|
||||
"""
|
||||
|
||||
import os, pygame
|
||||
from support import operations
|
||||
|
@ -10,11 +13,15 @@ class Lawyer:
|
|||
self.screen = screen
|
||||
screen_width, screen_height = screen.get_size()
|
||||
temp_image = pygame.image.load(os.path.join('img', 'lawyer.png'))
|
||||
# WARNING!! Absolute sizes
|
||||
# WARNING!! FIXME Absolute sizes FIXME
|
||||
self.image = pygame.transform.scale(temp_image, (200, 400))
|
||||
rect = self.image.get_rect()
|
||||
self.pos = (screen_width - rect.w, screen_height - rect.h)
|
||||
|
||||
def blitme(self):
|
||||
""" Blit this object to the screen """
|
||||
operations.color_surface(self.image, WHITE)
|
||||
self.screen.blit(self.image, self.pos)
|
||||
|
||||
def announce(self):
|
||||
""" Announces the color to pin """
|
||||
|
|
Loading…
Reference in New Issue