Game Maker 7.0 Lite How to make an arcade-style game

Game Maker 7.0 Lite How to make an arcade-style game Terminology Loose definition Sprite All images required to create your game. Object This is ...
Author: Harvey Osborne
4 downloads 0 Views 478KB Size
Game Maker 7.0 Lite How to make an arcade-style game Terminology

Loose definition

Sprite

All images required to create your game.

Object

This is where you ‘program’ your sprites to behave in certain ways.

Events

A list of anticipated behaviours of the player and sprites.

Actions

The resulting behaviours of sprites (after an event) as programmed by you. These actions must be organised in the order you wish them to occur.

Rooms

This is the space where the game takes place. If creating a game with a series of levels, it is useful to create a new room for each level.

Background

This is where you can format your rooms’ colours.

Sound

Insert sounds to synchronise with a behaviour.

Tab

They look just like tabs in a filing cabinet.

Special keys

Function

F5

This key ‘executes’ (starts) your game.

F6

Executes your game and also tells you if you have any ‘bugs’ in the programming.

Ctrl S

Hold these two keys down to save your creation at any time.

Ctrl Z

Undo! (Your best friend on the keyboard)

Tracy Considine ◘ Middle Years ICT Consultant ◘ South Western Sydney Region

Game Maker 7.0 Lite How to make an arcade-style game SPRITES 1. Open the Game Maker program 2. Right click on the Sprite folder (or click on the short cut in the toolbar and ignore step 3) 3. Select Create Sprite 4. In the Name box, type Main 5. Click on Load Sprite 6. Locate and open the Sprite folder (possibly located in My Computer -> Local Disk (C:) -> Program Files -> Game_Maker7 -> Sprites 7. Open the Pacman folder 8. Select the pacman_stand.gif file 9. Click Open 10. Make sure the transparent box is ticked then click OK 11. Notice the Sprite folder now contains your first sprite (Pacman facing front on) 12. Repeat steps 2 to 10 until you have all the Pacman sprites in your Sprite folder including Pacman facing up, right, left and down. NOTE: in Step 4, name each of your new sprites uniquely, e.g. Mainup, Mainright, Mainleft and Maindown. 13. Now do similar steps to create one Wall sprite, one Baddy sprite, one Pellet sprite (what Pacman eats to score points), one Finishing sprite (e.g. a flag icon that Pacman eats last to move on to the next level). 14. To edit any of these sprites, simply double click on their icon in the Sprites folder SAVE NOW!!!! File -> Save As -> Save in: (locate where you want to save this file) File name: (your name.gmk) OBJECTS 15. Now we need to ‘program’ events and actions so that your sprites behave in certain ways when we play the game. Right click on the Objects folder (or click on the short cut in the toolbar and ignore step 16) 16. Select Create Object 17. In the Name box, type Main 18. Beneath the Name box, click on the small blue browser icon or anywhere in the empty Sprite box 19. Click on your Main Sprite from the list of sprites that appears 20. Make sure the Visible box is ticked Tracy Considine ◘ Middle Years ICT Consultant ◘ South Western Sydney Region

Game Maker 7.0 Lite How to make an arcade-style game 21. Click on the Add Event button 22. Click on the Keyboard button 23. Click on and notice it now appears in the Events window 24. Now we have to program this event so that when the player isn’t pressing any key on the keyboard, the Main sprite doesn’t move. Drag the RED Move Fixed icon (the first icon under the Move options) into the Actions window pane 25. A Move Fixed window should appear. Click once on the small square in the middle of all the arrows so that it changes to red 26. Click OK 27. Click on the Main1 tab on the far right hand side 28. Drag the first Sprite icon (Change Sprite) into the Actions window pane 29. A Change Sprite window should appear. Click on the small blue browse icon next to the sprite box and select Main sprite from the list 30. Click OK 31. In the Actions window pane, drag this new action (Change sprite into Main) above the other action (Start moving in a direction) so that it occurs first 32. Repeat steps 21 to 31 to create more events including , , and . EXCEPT THIS TIME NOTE: In Step 24, ensure the blue direction you click on is the same as the Event (e.g. for event click on the left arrow only). Also in Step 24 change the speed to 5 for all of these new events. ALSO NOTE: In Step 29 select the sprite image that reflects the direction you are programming (e.g. Mainleft for event. 33. Click OK to finally exit the Main sprite’s Object Properties window 34. Now we need to program the Wall, Pellet, Finishing and Baddy sprites. Repeat Steps 15 and 16. 35. In the Name box, type Wall 36. Beneath the Name box, click on the small blue browser icon or anywhere in the empty Sprite box 37. Click on your Wall Sprite from the list of sprites that appears 38. Make sure the Visible and Solid boxes are both ticked Tracy Considine ◘ Middle Years ICT Consultant ◘ South Western Sydney Region

Game Maker 7.0 Lite How to make an arcade-style game 39. Click on the Add Event button 40. Click on the Collision button 41. Click on the Main object 42. Now we have to program this event so that when the Main sprite hits a wall, it doesn’t move. Drag the RED Move Fixed icon (the first icon under the Move options) into the Actions window pane 43. A Move Fixed window should appear. Click once on the small square in the middle of all the arrows so that it changes to red 44. Click OK 45. Click OK again to close the Object Properties window. We will come back to program the Wall a little later on. But first we need to create objects out of all our sprites. 46. Right click on the Objects folder (or click on the short cut in the toolbar and ignore the next step) 47. Select Create Object 48. In the Name box, type Baddy 49. Beneath the Name box, click on the small blue browser icon or anywhere in the empty Sprite box 50. Click on your Baddy sprite from the list of sprites that appears 51. Click OK to close the Object Properties window 52. Repeat Steps 46 to 51 until you have created an object for every sprite in your list. Remember to Name them appropriately 53. In the Objects folder, double click on your Wall object so that the Object Properties window appears 54. Click Add Event 55. Click Collision 56. Click on the Baddy icon

Tracy Considine ◘ Middle Years ICT Consultant ◘ South Western Sydney Region

Game Maker 7.0 Lite How to make an arcade-style game 57. Click on the Move Tab and drag the last icon (Bounce) under the Jump section in the into the Actions window pane. 58. A Bounce window should appear. Click on Applies to: Other 59. Click on the blue browse icon next to the precise box and select Not Precisely 60. Click on the blue browse icon next to the against box and select Solid Objects 61. Click OK 62. Click OK to finally exit the Wall sprite’s Object Properties window 63. In the Objects folder, double click on your Baddy object so that the Object Properties window appears 64. Make sure the Visible box is ticked 65. Click on the Add Event button 66. Click on the Create button 67. Drag the RED Move Fixed icon (the first icon under the Move options) into the Actions window pane 68. A Move Fixed window should appear. Click once on all arrows so they change to red. Leave the middle square blue. 69. Change the Speed to 5 70. Click OK 71. Click Add Event 72. Click Collision 73. Click on the Main sprite 74. Click on the Main 1 tab on the right hand side 75. Drag the Destroy Instance icon (looks like Trash Can) into the Actions window pane 76. Click on Applies to: Other 77. Click OK 78. Click on the Scores tab on the right hand side 79. Drag the Show Highscores icon into the Actions window pane 80. Click OK 81. Click on the Main2 tab on the right hand side 82. Drag the Restart Game icon into the Actions window pane 83. Click OK to close the Baddy Object Properties window 84. Right click on the Sounds folder 85. Select Create Sound 86. Name this sound Gameover Tracy Considine ◘ Middle Years ICT Consultant ◘ South Western Sydney Region

Game Maker 7.0 Lite How to make an arcade-style game 87. Click on Load Sound button 88. Locate and open the Sound folder (possibly located in My Computer -> Local Disk (C:) -> Program Files -> Game_Maker7 -> Sounds 89. Select an appropriate ‘gameover’ sound and click Open 90. Hit the play (green) and stop (red) icons to listen to this sound 91. Click OK if you’re happy with this sound or click on Load Sound to find another one 92. Double-click on the Baddy icon under the Objects folder 93. Click on the Event: Collision with Main 94. Click on the Main1 tab 95. Drag the sound icon into the Actions window pane 96. Click on the blue Browse icon next to the Sound box and select the sound you just created from the list 97. Click on the blue Browse icon next the Loop box and select False 98. Click OK 99. Click OK to close the Baddy Object Properties window 100.

In the Objects folder, double click on your Pellet object so that the Object

Properties window appears 101.

Click on Add Event

102. Click on Collision 103. Choose Main sprite 104. Click on the Score tab on right hand side and drag the Set Score icon (the first one) into the Actions window pane 105. Set the score to 5 and make sure the Relative box is ticked (so that scores accumulate) 106. Click OK 107. Repeat steps 84 to 91 to create a sound that occurs when the Main sprite ‘eats’ a pellet 108. Double click on the Pellet object then click on the Main1 tab on right hand side 109. Drag the Destroy Instance icon (looks like Trash Can) into the Actions window pane 110. Select Applies to Self 111. Click OK Tracy Considine ◘ Middle Years ICT Consultant ◘ South Western Sydney Region

Game Maker 7.0 Lite How to make an arcade-style game 112. Click OK to close the Pellet object properties window 113. In the Objects folder, double click on your Finishing object so that the Object Properties window appears 114. Click on Add Event 115. Click on Collision 116. Choose Main sprite and click OK 117. Follow Steps 84 to 91 to create a sound that occurs when the Main sprite collides with the Finishing sprite and therefore indicates completion of that level 118. Click on the Main 1 tab on the right hand side 119. Drag the Go to Next Room icon into the Actions window pane (the 2nd Rooms icon) 120. Choose a transition and click OK 121. Click OK to close the Finishing object properties window SAVE NOW!!! ROOMS 122. Right click on the Rooms folder and select Create Room 123. Change the Snap X and Snap Y to 32 124. Make sure the screen is maximised so you can see the entire room without scrolling down or across. 125. Click on the blue browse icon next to the Add Object box 126. Select the Wall object 127. Hold down the Shift key on the keyboard and left click and drag your wall icon all the way around the outside of the room to enclose the space (If you don’t enclose the room with walls, the other objects won’t be contained within the room) 128. To delete any part of the wall, right click on it or hold down the Shift key and right click and drag over the top of the wall to erase a whole section 129. Create a maze of walls throughout the room 130. Click on the blue browse icon next to the Add Object box 131. Select the Baddy object 132. Click in various places in the room to place your baddies 133. Click on the blue browse icon next to the Add Object box 134. Select the Pellet object 135. Click in various places in the room to place your Pellets Tracy Considine ◘ Middle Years ICT Consultant ◘ South Western Sydney Region

Game Maker 7.0 Lite How to make an arcade-style game 136. Click on the blue browse icon next to the Add Object box 137. Select the Main object 138. Click a place in the room to position your Main object 139. Click on the blue browse icon next to the Add Object box 140. Select the Finishing object 141. Click a place in the room to position your Finishing object 142. Click on the Backgrounds tab 143. Select a colour from the empty colour box 144. Make sure the Visible When Room Starts box is ticked 145. Click on the Close the form, saving the changes icon (it’s a little green tick just to the right of the Sprites folder) Then….IF a warning window appears, click YES 146. Hit the F5 key to play your game and check for errors. Remember we haven’t created a new level (second room) so expect this error to appear if you complete the level 147. Repeat Steps 122 to 124 to create a second room (new level). 148. To make Level 2 harder Right Click on the Baddy object (in the Objects folder) and select Duplicate 149. Double click on the Action: Start Moving in a Direction and increase the speed to 10 then click OK 150. Add Event 151. Collision 152. Wall 153. Drag Start moving in a direction icon into Actions window 154. Click on all external arrows changing them to RED 155. Change speed to 10 156. OK 157. Click OK to close the Object Properties window 158. Continue Steps 125 to 145 except remember to select the new Baddy object (the faster one which is probably called Object 6) from Step 148 SAVE NOW!!!! Turn your game into a stand-alone game that can be played on other computers that don’t have Game Maker 7 installed, click on the “Create a stand-alone executable for your game” icon. Open and play other games by clicking on the Open Folder icon and then hit the GREEN ARROW icon (Play)

Tracy Considine ◘ Middle Years ICT Consultant ◘ South Western Sydney Region