90 likes | 111 Views
Welcome to. Computer Game Development Laboratory Scratch Modules. www.build-it-yourself.com. Series and Parallel Execution Put on your socks. Then Put on your shoes. Take a shower. At the same time, Brush your teeth. www.build-it-yourself.com. Iteration Breath. www.build-it-yourself.com.
E N D
Welcome to Computer Game Development Laboratory Scratch Modules www.build-it-yourself.com
Series and Parallel ExecutionPut on your socks. Then Put on your shoes.Take a shower.At the same time,Brush your teeth. www.build-it-yourself.com
IterationBreath. www.build-it-yourself.com
Conditional StatementsIf there is candy on the plate, keep eating!If not, ask for more! www.build-it-yourself.com
VariablesThe score in a game. www.build-it-yourself.com
MessagesWhen you are hungry, call the pizza shop. Broadcasting messages allows communication between sprites and the stage. For example you may want to change a background color or costume when the space bar is pressed. www.build-it-yourself.com
Modular Programming1) Create solutions quickly.2) Edit solutions quickly.3) Make solutions more reliable. Spaghetti Code Ordered Code www.build-it-yourself.com
Program Structures1) Sequence vs. Parallel2) Iteration3) Conditional Statements4) Variables5) Messages6) Modular Programming In many ways, a computer works just like your brain! www.build-it-yourself.com
Program Guidelines Make descriptive names for all Scratch projects, costumes, sprites, variables, messages. Modularize the code. Break down code into simple, reusable, functional building blocks. Set up logical hand shaking rules so one module can easily drive another module. Initialize costume and variable states when the program starts. (position, size, show, value …) Avoid forever loops or make sure you stop a forever loop when it is no longer needed. Use ‘Repeat Until’ so big projects with many forever loops will not overload your processor. Document how your program works. Add code comments. www.build-it-yourself.com