See also: Myriapod 4 https://scratch.mit.edu/projects/543446519/ Chomp. Chomp. Chomp. Chomp. Chomp. Look out the Myriapods are loose and they're eating every coin in sight! ←↑→↓<Arrow Keys> Move, <Space> Fire Laser Mobile friendly: Touch to fire and move Extra life awarded every 10000 points. Scoring: Meanie (the moth-like thing) is worth 300, 600 or 900 points. Myriapod head 100 points, body segment 10 points. 100 points for a totem rock. When you die you are awarded 5 points for every rock with 0 or 1 health. You're trapped in the perilous Enchanted Forest. Dark, dangerous rocks push up through the squishy forest floor, surrounding you on every side. Threatening thumps and evil buzzings fill the air. Something slimy flashes through the rocks, closing in on you. Suddenly, glaring eyes and quivering antenna jump right out at you! Some people claim that you are a garden gnome with a magic bug-zapping wand charged with eliminating the pests. Others claim that these bugs are not ordinary bugs but Godzilla-sized insects that threaten to trample your home town, and it's up to you to stop them. I've got it: They're mutations caused by radiation. No, wait- the government made 'em. Well, there's nothing like them in the fossil record. Okay, so they predate the fossil record. That'd make them a couple of billion years old, and we've just never seen one until now. Right. I vote for outer space. No way these are local boys. Why don't we just make a run for it? We outran 'em yesterday. Run for it? Running’s not a plan! Running’s what you do once a plan fails. This valley is just one long smorgasbord. #retro #arcade #centipede #clone #codetheclassics #games
Based on Centipede (Atari) 1980, designed by Dona Bailey and Ed Logg Myriapod (Code the Classics – Volume 1) under Creative Commons Attribution Non-Commercial Share Alike 3.0 (CC BY-NC-SA 3.0) https://wireframe.raspberrypi.org/books/code-the-classics1 https://en.wikipedia.org/wiki/Centipede_(video_game) . Originally designed for the Senior Style Studio this project is a demonstration of object orientated programming style. It is provided as an example only and is not a recommendation. Scratch after all is about learning and having fun. The project is broken down into functional modules, each module is represented by a sprite. The behaviour of each sprite is contained (encapsulated) within the sprite. For example all the functionality of the player sprite is contained inside the player sprite. Naming conventions are used to work around some of the limitations of Scratch. Global variables are only used where multiple sprites need to update the same value. E.g. Player: Score is a global variable belonging to the Player sprite. The Sensing reporter block () of () is used to allow one sprite to read the local variables of another sprite. Global Lists are used where multiple sprites need to read or write list data. E.g. Grid: Cells is a 2 dimensional list belonging to the Grid sprite. It is used by several sprites to check which cell is occupied and record the value of each cell, e.g. Rock, Segment, etc. Magic numbers are removed so each value is defined in one and only one constant. E.g. Grid: _CELL SIZE defines the size of each cell. Changing this value automatically changes the scale of all the other sprites in the project. Some custom blocks are defined to be reusable by other sprites. E.g. Grid: get cell(column, row) provides the calculation to read the 2 dimensional list. This code block has been copied to other sprites that need the same function. The Myriapod Segments are synchronised with one variable Game Loop: Frame Count this allows the sprites to move and animate at exactly the same time.