MCPcopy
hub / github.com/sqlalchemy/sqlalchemy / main

Function main

examples/space_invaders/space_invaders.py:769–783  ·  view source on GitHub ↗

Initialize the database and establish the game loop.

()

Source from the content-addressed store, hash-verified

767
768
769def main():
770 """Initialize the database and establish the game loop."""
771
772 e = create_engine("sqlite://")
773 Base.metadata.create_all(e)
774 session = Session(e)
775 init_glyph(session)
776 session.commit()
777 window = setup_curses()
778 state = {}
779 start(session, window, state)
780 while True:
781 update_state(session, window, state)
782 draw(session, window, state)
783 time.sleep(0.01)
784
785
786if __name__ == "__main__":

Callers 1

space_invaders.pyFile · 0.70

Calls 9

commitMethod · 0.95
create_engineFunction · 0.90
SessionClass · 0.90
init_glyphFunction · 0.85
setup_cursesFunction · 0.85
startFunction · 0.85
update_stateFunction · 0.85
drawFunction · 0.85
create_allMethod · 0.80

Tested by

no test coverage detected