Exemple #1
0
def redraw_board():
    gameloop.init()
    theme.update()  # This is going to create the new theme if it doesn't exist

    # Force the game to update
    graphics.drawGame()
    graphics.update()
Exemple #2
0
def init():
    global state, speed, last_update

    # set the initial time for the first update with the current time
    last_update = time.time()

    game.score = 0
    game.reset()
    graphics.drawGame()
    state = 1
    try:
        speed = config.game_speed[parser.args.speed]
    except:
        speed = config.game_speed['m']

    livesIn = parser.args.lives
    if livesIn >= 1 and livesIn <= 5:
        game.lives = livesIn
        game.livesMax = livesIn
    elif livesIn > 5:
        game.lives = 5
        game.livesMax = 5
    else:
        game.lives = 1
        game.livesMax = 1
Exemple #3
0
def redraw_board():
    gameloop.init()
    theme.update()  # This is going to create the new theme if it doesn't exist

    # Force the game to update
    graphics.drawGame()
    graphics.update()
Exemple #4
0
def init():
    game.init()
    graphics.drawGame()
    graphics.update()
def reset():
    game.reset()
    graphics.drawGame()
def init():
    global state

    game.init()
    graphics.drawGame()
    state = 0