Skip to Content
Object-Oriented Python
book

Object-Oriented Python

by Irv Kalb
January 2022
Beginner to intermediate
416 pages
10h 21m
English
No Starch Press
Content preview from Object-Oriented Python

15 Scenes

Games and programs will often need to present different scenes to the user. For the purpose of this discussion, I’ll define a scene as any window layout and related user interactions that are significantly different from any other. For example, a game like Space Invaders may have a starting or splash scene, a main game play scene, a high scores scene, and perhaps an ending or goodbye scene.

In this chapter I will discuss two different approaches to writing a program that has multiple scenes. First, I’ll introduce the state machine technique, which works well for relatively small programs. Then I’ll show a fully object-oriented ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Python Object-Oriented Programming - Fourth Edition

Python Object-Oriented Programming - Fourth Edition

Steven F. Lott, Dusty Phillips
Python for Programmers

Python for Programmers

Paul Deitel, Harvey Deitel
Robust Python

Robust Python

Patrick Viafore

Publisher Resources

ISBN: 9781098129842Errata Page