Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRodolfo D. Arce S <rodolfo.arce.s@gmail.com>2011-05-12 00:37:18 (GMT)
committer Rodolfo D. Arce S <rodolfo.arce.s@gmail.com>2011-05-12 00:37:18 (GMT)
commit72c6638fc8dac5ac67f8ec6c9a6b42974f776b85 (patch)
treecf8bc9eb4a770133ae81bd8d2a9b8e6cdab21714
First commit
-rw-r--r--README3
-rw-r--r--main.py47
2 files changed, 50 insertions, 0 deletions
diff --git a/README b/README
new file mode 100644
index 0000000..db9cdf8
--- /dev/null
+++ b/README
@@ -0,0 +1,3 @@
+Rodolfo D. Arce S.
+
+This game is design to make children aware of the damages to the enviroment we do when we throw garbage.
diff --git a/main.py b/main.py
new file mode 100644
index 0000000..51eb83e
--- /dev/null
+++ b/main.py
@@ -0,0 +1,47 @@
+# Robot saving nature
+
+import pygame
+import time
+
+from pygame.locals import *
+
+pygame.init()
+
+# Screen size
+window_h = 472
+window_w = 608
+screen = pygame.display.set_mode((window_w, window_h))
+
+object_background = pygame.image.load('images/park.png')
+screen.blit(object_background, (0, 0))
+
+object_robot = pygame.image.load('images/robot.png')
+screen.blit(object_robot, (300,200))
+
+# Initialize images
+pygame.display.update()
+
+object_position = [0,0]
+start_time = time.time()
+fps = 30
+frame_time = 1.0/fps
+
+
+
+# Main loop
+exit = False
+
+while not exit:
+ # Process pygame events
+ for event in pygame.event.get():
+ # Escape key to quit the game
+ if event.type == pygame.QUIT or \
+ (event.type == pygame.KEYDOWN and event.key == pygame.K_ESCAPE):
+ exit = True
+ break
+ if exit:
+ break
+
+pygame.display.update()
+
+pygame.quit()