game

game

Game loop and screen management for Asteroid Impact game.

class game.GameModeManager(args)

Bases: object

Follow the instructions to switch between game screens, and levels Rather than specifying a single level list, specify a file that has a list of entries where each entry specifies the following:

  • Action: Either Instructions, Game, or Black Screen
  • Levels: For the game, the list of level files to play. The player will progress (or not) through them in order, and after completing the last level will start again at the beginning. Dying will restart the current level.
  • Duration: After this many seconds move to the next step, regardless of what the player is doing now.
gameloop()

run the game frame/tick loop

get_parallel_trigger_status_value()
init_step()

setup for next game mode step

load_level_templates(step)

Load level templates for game-adaptive step from inline JSON or file

load_levels(step)

Load level details for game step from inline JSON or file

update_outbound_triggers(frametriggerlist)
game.main()

parse console arguments and start game