def updateBullet(self, bullet):
        if not ObjectFactory.updateBullet(bullet):
            newBullet = BulletFactory.getInstance(bullet)
            newBullet.rotation = bullet.get('rotation')
            newBullet.do(MoveBy(bullet.get('moveTo'), 1))

            LayoutFactory.addBullet(newBullet)
            ObjectFactory.addBullet(newBullet)
    def updateTank(self, tank):
        fraction = tank.get('fraction')

        if not ObjectFactory.updateTank(tank):
            movingHandler = MovingHandlersFactory.getInstance(fraction)

            newTank = TankFactory.getInstance(tank)
            newTank.do(movingHandler())

            LayoutFactory.addTank(newTank, fraction)
            ObjectFactory.addTank(newTank, fraction)
    def tanks(self):
        if self.arguments.get('tanks'):
            for tank in self.arguments.get('tanks'):
                fraction = tank.get('fraction')
                type = tank.get('type')

                movingHandler = MovingHandlersFactory.getInstance(fraction)

                Tank = TankFactory.getInstance(type)
                Tank.do(movingHandler())

                Tank.position = (tank.get('x'), tank.get('y'))

                #settings.collision_manager.add(Tank1)

                LayoutFactory.addTank(Tank, fraction)
                ObjectFactory.addTank(Tank, fraction)