Пример #1
0
 def __init__(self, random=random, granularity=1, platformClock=None):
     SimulationTime.__init__(self, granularity, platformClock)
     self.random = random
     #the plant
     self.plant = Plant()
     #array for the players
     self.players = []
Пример #2
0
 def __init__(self, random=random, granularity=1, platformClock=None):
     SimulationTime.__init__(self, granularity, platformClock)
     self.random = random
     #the plant
     self.plant = Plant()
     #array for the players
     self.players = []
Пример #3
0
 def __init__(self, random=random, playerCreationRectangle=None,
              granularity=1, platformClock=None):
     SimulationTime.__init__(self, granularity, platformClock)
     if playerCreationRectangle is None:
         playerCreationRectangle = point(1, 1), point(5, 5)
     self.random = random
     self.playerCreationRectangle = playerCreationRectangle
     self.observers = []
     self.players = []
     self.terrain = Terrain()
Пример #4
0
 def start(self):
     SimulationTime.start(self)
     # add plant update as an observer to the sim time tick
     self.addObserver(self.plant.update)
Пример #5
0
 def start(self):
     SimulationTime.start(self)
     # add plant update as an observer to the sim time tick
     self.addObserver(self.plant.update)