Game Programming for Beginners

The StarLogo TNG game curriculum unit uses computer game design as the motivation and theme to introduce programming to middle or high school students. StarLogo TNG is The Next Generation of StarLogo modeling and simulation software. Students and teachers use SLTNG’s agents-based programming and 3-D graphics to create and understand simulations and complex systems. Each 1.5 hour lesson includes a mini-lesson to introduce new programming commands and one or more programming exercises to practice using those commands to design a game play element. Ideally, students continue working on programming activities on their own for 30 min to 1 hour outside of class time. Over the course of 10 lessons, students gain the programming knowledge to develop their own “Treasure Hunt” game, a complex system that includes multiple agents and first person game play. They also learn programming basics such as the concept of a forever loop, Boolean logic used in if / then statements, procedures and abstraction, and using variables.

The unit is designed for a teacher to use in an in-school computer class or after school computer club. The instructional materials are available to download as individual files (see below) or as a single zip file .

Sample lesson description and screenshots :

In lesson 1, students are introduced to four movement blocks (forward, back, left and right). They use these blocks to program instructions for 20 turtle agents so to maximize the score, which is based on the height of the patches that the turtles are standing on. The challenge is to figure out how best to keep the turtles on high scoring patches and away from low scoring patches.

A screenshot of the PowerPoint slide presentations:

Screenshot of student handout of programming activities for lesson 1:

Back to top