Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/dev/pacmath.activity/gameMain.py
diff options
context:
space:
mode:
Diffstat (limited to 'dev/pacmath.activity/gameMain.py')
-rw-r--r--dev/pacmath.activity/gameMain.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/dev/pacmath.activity/gameMain.py b/dev/pacmath.activity/gameMain.py
index 72ebcff..224c780 100644
--- a/dev/pacmath.activity/gameMain.py
+++ b/dev/pacmath.activity/gameMain.py
@@ -12,6 +12,8 @@ from GhostMovement import ghostMovement
from mazeSetup import mazeSetup
from questionGenerator import questionGenerator
from question import question
+import random
+import string
import pygame
import sys
@@ -35,7 +37,8 @@ class gameMain:
# size = olpcgames.ACTIVITY.game_size
pygame.display.set_caption('PacMath')
self.screen.fill((0,0,0))
- self.questGen = questionGenerator( 'x', 2, 12 )
+ self.operation = random.sample('x+-/', 1)
+ self.questGen = questionGenerator( self.operation, 2, 12 )
self.lives = BASE_LIVES
self.score = 0