Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/main.py
diff options
context:
space:
mode:
Diffstat (limited to 'main.py')
-rw-r--r--main.py15
1 files changed, 12 insertions, 3 deletions
diff --git a/main.py b/main.py
index 362f6e6..cf45384 100644
--- a/main.py
+++ b/main.py
@@ -7,8 +7,11 @@ from pygame import K_ESCAPE
from pygame.locals import *
from random import randint
+
from tree import Tree
from ranger import Ranger
+from cutter import Cutter
+
pygame.init()
@@ -34,6 +37,12 @@ unit = 1
ranger_speed = 4
ranger = Ranger(window_h, window_w, ranger_speed)
+# Cutter
+cutter_speed = 3
+cutter = Cutter(window_h, window_w, cutter_speed)
+
+
+
# Draw background
screen.fill(bg_color)
# Draw everything on top of that
@@ -76,6 +85,7 @@ while True:
# Update ranger position based on events
ranger.update()
+ cutter.update()
# Draw background
screen.fill(bg_color)
@@ -86,10 +96,9 @@ while True:
text = font.render( score_text , 1, (0, 0, 0, 0))
screen.blit(text, (0, 0))
- #for arbol in trees:
- # trees.remove(arbol)
-
ranger.draw(screen)
+ cutter.draw(screen)
+
for arbol in trees:
arbol.draw(screen)