Chapter 13. Using arrays and simulating gravity in a single-screen platformer

 

Before Donkey Kong, games had goals, but the player didn’t know their motivation or how they had ended up in the situation. Donkey Kong changed that by giving the player a story with a beginning, middle, and end that unfolded as the player moved from level to level, usually in the form of cutscenes, videos that occur before or after a level to pause the gameplay and give information. That story starred a little plumber known as Mario.

Yes, our friend, Mario, that you know from Super Mario Bros, started out as a carpenter at a construction site, climbing ladders in Donkey Kong to save his girlfriend who was stolen by a giant gorilla. Nintendo brought back Mario for Mario Bros and then Super Mario Bros, turning him into a plumber who needs to jump up on brick platforms or slide down pipes in order to save Princess Toadstool from the evil Bowser. Mario can only run to the right. That’s because Super Mario Bros is a single-screen platformer.

Preparing to program

 
 

Programming Ms. Finebean

 
 

Answer This: Why Does ScrollX Need to Change by 1?

 

Programming the kindergarteners

 
 
 

Programming the desks

 

Answer This: Why Do You Need to Delete Items From the List?

 
 
 

Programming the clocks

 

Programming the door

 
 

Troubleshooting the game

 
 
 

Learning in action

 
 
 
sitemap

Unable to load book!

The book could not be loaded.

(try again in a couple of minutes)

manning.com homepage
test yourself with a liveTest