feat(startscreen): add button initialization
This commit is contained in:
+8
-1
@@ -10,7 +10,14 @@ class Button:
|
|||||||
self.color = color
|
self.color = color
|
||||||
self.hover = hover
|
self.hover = hover
|
||||||
|
|
||||||
# todo
|
# create rectangle for button
|
||||||
|
self.rect = pygame.Rect(self.pos_x, self.pos_y, self.width, self.height)
|
||||||
|
|
||||||
|
# set font for button text
|
||||||
|
self.font = pygame.font.SysFont("Arial", 30)
|
||||||
|
|
||||||
|
# temp var to stor click event - so it will be executed just once
|
||||||
|
self.clicked = False
|
||||||
|
|
||||||
def draw(self, screen):
|
def draw(self, screen):
|
||||||
action = False
|
action = False
|
||||||
|
|||||||
Reference in New Issue
Block a user