Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/bridge.py
diff options
context:
space:
mode:
authorDaniel Drake <dsd@laptop.org>2008-08-30 20:55:23 (GMT)
committer Daniel Drake <dsd@laptop.org>2008-08-30 20:55:23 (GMT)
commit53489a7c53e90e1c31a06877549bd8e2fb052685 (patch)
treeee279d52bd0279e56b2251727b71e367beca2fbf /bridge.py
parentaa57da74cff454332624bcdf8d7149213fdb0fc4 (diff)
Add simple world-creation code
Diffstat (limited to 'bridge.py')
-rw-r--r--bridge.py14
1 files changed, 14 insertions, 0 deletions
diff --git a/bridge.py b/bridge.py
new file mode 100644
index 0000000..76daffc
--- /dev/null
+++ b/bridge.py
@@ -0,0 +1,14 @@
+import pygame
+
+def create_world(game):
+ rect = pygame.Rect((0,800), (350, -250))
+ rect.normalize()
+ pygame.draw.rect(game.screen, (100,180,255), rect, 3)
+ game.world.add.rect(rect.center, rect.width / 2, rect.height / 2,
+ dynamic=False)
+ rect = pygame.Rect((1200,800), (-350, -250))
+ rect.normalize()
+ pygame.draw.rect(game.screen, (100,180,255), rect, 3)
+ game.world.add.rect(rect.center, rect.width / 2, rect.height / 2,
+ dynamic=False)
+