GameMaker Example Projects A

101 GameMaker Projects To Learn From


GameMaker Examples on This Page Now Include Code Comments


 1 Keep Instance In Room 

This keeps the instance within the room’s boundary.

Craft a horror game featuring lighting effects powered by GameMaker Studio
1 Keep Instance In Room Zip
Archive – 529.8 KB

 2 Line Of Sight

This example looks for a line of sight from enemy to player, without a crate between them.

Program a quiz game with dynamic question generation in GML.
2 Line Of Sight Zip
Archive – 644.9 KB

 3 Simple Level Complete Save System

To load and save whether player has completed a level.

Create a tower defense game using GML for pathfinding algorithms
3 Simple Level Complete Save System Zip
Archive – 519.5 KB

 4 Seeking Missile

This creates a missile that seeks out an enemy instance.

Program a rhythm-based music game with GameMaker's timeline features
4 Seeking Missile Zip
Archive – 534.6 KB

 5 Draw Health As Bars

Draws Health As Separate Sections.

5 Draw Health As Bars Zip
Archive – 488.5 KB

 6 Ellipse Movement

This code will move in instance in an ellipse.

Develop a survival game with crafting systems coded in GML
6 Elipse Movement Zip
Archive – 482.8 KB

 7 Draw Contents Of 2D Array

A simple method to draw data from an array.

Design a narrative-driven adventure game with dialogue trees in GameMaker Studio
7 Draw Contents Of Array Zip
Archive – 475.5 KB

 8 Adaptable Engine Noise

This code changes te pitch of an engine noise based on its speed.

Craft a stealth-based action game with GameMaker's camera controls
8 Adaptable Engine Noise Zip
Archive – 742.0 KB

 9 Drag-able Objects

Sometimes you may wish the player to be able to click and drag an instance around the room. Here is a simple solution.

Create a multiplayer racing game using GameMaker
9 Dragable Objects Zip
Archive – 493.8 KB

 10 Mini Map

This code draws a mini-map,

10 Mini Map Zip
Archive – 509.6 KB

 11 Trail Effect

A simple script for drawing an image trail.

Craft an endless runner game with GameMaker's sprite editor
11 Trail Effect Zip
Archive – 493.6 KB

 12 Change Image On Mouse Interaction

This example uses a sprite with 3 different subimages,0=no mouse, 1=mouse over and 2=mouse pressed.

Create a top-down shooter with enemy AI powered by GML.
12 Change Image On Mouse Interaction Zip
Archive – 530.1 KB

 13 Mouse Pointer Point Direction

Draws a sprite as pointer, pointing direction of target and slowly moves.

Build a dynamic platformer using GameMaker Studio
13 Mouse Pointer Point Direction Zip
Archive – 533.9 KB

 14 Power Up

A simple solution for managing a power up.

Create a classic breakout-style game using GameMaker Studio
14 Power Up Zip
Archive – 522.9 KB

 15 Push-able Block

A simple pushing system.

15 Pushanble Block Zip
Archive – 542.6 KB

 16 Radar

A great adaptable radar system.

Design a shooting gallery game with GML-powered moving targets
16 Radar Zip
Archive – 542.5 KB

 17 Random Word From A Text File

This example shows how to select a random word from a text file.

17 Random Word From Text File Zip
Archive – 489.0 KB

 18 Real Time Clock Example

Draws the players local time according to the system clock.

Build a memory matching card game in GameMaker Studio
18 Real Time Clock Zip
Archive – 476.3 KB

 19 Score With Leading Zeros

A simple method of drawing a score with leading 0's

Develop a maze game with enemy AI coded in GML
19 Score With Leading Zeros Zip
Archive – 523.6 KB

 20 Fading Moving Text

Creates moving fading text, great providing info to the player.

20 Fading Moving Test Zip
Archive – 526.2 KB

Use Coupon Code SPRING For 40% Off


 21 Cool Down System

A useful idea that limits how often a player can shoot / attack / or perform other actions.

Program a dice-rolling game with random number generation in GML
21 Cool Down System Zip
Archive – 538.9 KB

 22 Sliding Bar

A useful bit of code that allows a user to select a value.

Create a 2D racing game with checkpoint systems in GameMaker Studio.
22 Sliding Bar Zip
Archive – 569.4 KB

 23 Slowly Move

This slowly moves to a position, in this example to the mouse’s position.

Craft a balloon-popping game with touch or mouse input in GameMaker Studio
23 Slowly Move Zip
Archive – 574.0 KB

 24 Rising Smoke Effect

Create a rising and fading smoke effect. Requires a sprite of a smoke.

Program a simple hangman word game with GML string functions
24 Rising Smoke Effect Zip
Archive – 684.7 KB

 25 Typewriter Text Effect

Draws text, one character at a time.

25 Typewriter Effect Zip
Archive – 530.9 KB

 26 Level Unlock System

The currently available levels is the value global.levels, ie a value of 2 would mean levels 1 and 2 unlocked.

Create a color-matching game with cascading effects in GameMaker
26 Level Unlock System Zip
Archive – 550.4 KB

 27 Weapon Management

An example for storing info for multiple weapons.

Develop a countdown timer game for quick reflex challenges using GML
27 Weapon System Zip
Archive – 1.3 MB

 28 Top Down Character Control

4 direction movement and sprite control.

Build a catch-the-falling-items game with increasing difficulty using GML
28 Top Down Character Control Zip
Archive – 583.9 KB

 29 Blood Effect Using Particles

Creates a blood effect using particles.

Design a dynamic weather system in GML for your game
29 Blood Effects Using Particles Zip
Archive – 523.0 KB

 30 Draw Text Info With Background

A Simple script that can be used to draw info text for the player.

30 Draw Text Info With Background Zip
Archive – 519.1 KB

 31 Speed Boost

A simple system to allow a temporary increase of an instance’s max speed.

Create a health bar mechanic using GML scripting
31 Speed Boost Zip
Archive – 534.6 KB

 32 Projectile Curved Path

Makes a projectile follow a curved path to target.

Develop an inventory management system in GML for RPG
32 Proectile Curved Path Zip
Archive – 528.9 KB

 33 Draw Power Bar With Image Background

A useful approach that draws power, health, boost etc,using an image as the background.

Program enemy behavior patterns in GML for a challenging game
33 Draw Power Bar With Image Background Zip
Archive – 525.0 KB

 34 Create Muzzle Flash

This example shows how to create a muzzle flash for a rotating weapon.

Build a parallax scrolling background effect with GML.
34 Create Muzzle Flash Zip
Archive – 831.9 KB

 35 Cloud Effect Using Filters & Effects

This example make use of the powerful filters and effects layer.

35 Cloud Effect Using Filters And Effects Zip
Archive – 474.7 KB

 36 Missile Smoke Trail

A simple method using built in effects system to create smoke trail effect.

Implement a save and load system in GML for your game progress
36 Missile Smoke Trail Zip
Archive – 528.0 KB

 37 Selectable Stats

This allows the player to choose a player object with various stats.

Design a basic AI opponent for a card game using GML
37 Selectable Stats Zip
Archive – 627.9 KB

 38 Add Playing Cards & Shuffle

A simple method to shuffle a deck of playing cards.

Build a scoring system for arcade-style games using GML
38 Add Playing Cards And Shuffle Zip
Archive – 8.8 MB

 39 Enemy Track Player’s Movement

Sometimes you may want an enemy to match the player’s movement. This example moves the enemy’s y position towards the player.

Develop a day-night cycle in GML to enhance game realism
39 Enemy Track Players Movement Zip
Archive – 535.8 KB

 40 Tool Tip Pop Up

A useful bit of code that provides extra info to the player on mouse over.

40 Tool Tip Pop Up Zip
Archive – 531.6 KB

Use Coupon Code SPRING For 40% Off


 41 Pop Up Wobbly Text

A simple text effect, great for using when a player collects a coin, showing the score the player gets.

Craft a player movement system with smooth animations using GML
41 Pop Up Wobbly Text Zip
Archive – 567.8 KB

 42 Grow and Shrink Message Control

This example grows and shrinks an image.

Implement a combo attack system in GML for fighting game
42 Grow And Shrink Message Control Zip
Archive – 658.4 KB

 43 Smoothly Move To Mouse Position

This moves smoothly to a position, in this example the mouse’s position.

Program a timer countdown mechanic with GML for added tension
43 Smoothly Move To Mouse Position Zip
Archive – 528.0 KB

 44 Bounce Off Room Border

A simple effect, great for sprucing up a menu or pause screen.

Create a branching dialogue system using GML for story-driven games.
44 Bounce Off Room Border Zip
Archive – 480.7 KB

 45 Pause Music When Sound Effect Plays

This little method pauses the background music whilst an audio effect plays, great for adding atmosphere to your games.

45 Pause Music When Sound Effect Plays Zip
Archive – 29.2 MB

 46 Glitch Effect Text

Creates a shaking text effect.

Design a basic pathfinding algorithm for enemies in GML
46 Glitch Text Effect Zip
Archive – 529.0 KB

 47 Wobbly Text

This makes a cool text floating wobble effect.

Build a dynamic sound effect system in GML for immersive gameplay
47 Wobbly Text Zip
Archive – 529.1 KB

 48 Choose A Random Instance

This code chooses a random enemy instance.

Program collectible items with unique effects using GML
48 Choose A Random Instance Zip
Archive – 542.4 KB

 49 Draw Mini Healthbar For Enemy

This is a simple method to draw a mini healthbar above an enemy instance.

Craft a camera-follow script in GML for smooth tracking
49 Draw Mini Healthbar For Enemy Zip
Archive – 537.2 KB

 50 Fade In And Out

This fades a sprite in and out.

50 Fade In And Out Zip
Archive – 550.4 KB


 51 Rotating Text

A Simple method for rotating text.

Design an auto-targeting system in GML for shooter games
51 Rotating Text Zip
Archive – 529.1 KB

 52 Flashing Text

You can use this method to make text flash and glow, ideal for getting the attention of the player.

Note: Contains Flashing Images

Create a score combo system in GML to reward skillful gameplay.
52 Flashing Text Zip
Archive – 528.8 KB

 53 Play Sound At Selected Volume

Sometimes you may wish to play a sound at a lower or higher volume.

Build a teleportation mechanic using GML for unique movement options
53 Play Sound At Selected Volume Zip
Archive – 2.7 MB

 54 Spawn Powerups Control System

An example system for providing the player with a bonus. Works on a percentage system, each with a chance of happening.

Craft a hunger and stamina system in GML for survival games
54 Spawn Power Up Control System Zip
Archive – 529.8 KB

 55 Move Crosshair To Mouse Position

At time you want a player crosshair to move towards the mouse’s position.

55 Move Crosshair To Mouse Position Zip
Archive – 490.8 KB

 56 Checkpoint System

Sometimes you want the player to save it’s position at a level checkpoint.

Build a randomized loot drop system with GML for RPG-style games
56 Checkpoint System Zip
Archive – 557.2 KB

 57 Check If Instance Is In View

Sometimes you may want to check if an instance is in view, for example only allowing an enemy to shoot it’s projectile when within the current view.

Develop a gravity manipulation mechanic with GML for puzzle games.
57 Check If Instance In View Zip
Archive – 548.5 KB

 58 Jump Through Platforms

Sometimes you may want to allow a player to be able to jump through a platform.

Build a power-up system using GML for boosting player abilities
58 Jump Through Platforms Zip
Archive – 557.4 KB

 59 Random Level Music

Plays random music.

Craft an animation control system with GML for sprite actions.

Archive - 107 MB

Download


 60 Exploding Effect

If your sprite assets have several parts available here is a simple effect.

60 Exploding Effect Zip
Archive – 678.1 KB

Use Coupon Code SPRING For 40% Off


 61 Draw Text With Border

Here is a simple script that draws text with a border. Great for sprucing up your GUI text.

Design a checkpoint system in GML to save player progress
61 Draw Text With Border Zip
Archive – 568.6 KB

 62 Move Coin To Score Text

This creates a coin moving effect that moves it towards the HUD text for displaying score.

Create a functional shop system using GML for in-game purchases
62 Move Coin To Score Text Zip
Archive – 802.1 KB

 63 Tire Track Effects

Draws tyre tracks that fade away. Ideal for top down car or tank games.

Implement a shooting mechanic in GML for action-packed gameplay
63 Tyre Track Effect Zip
Archive – 482.3 KB

 64 Fireworks Display

A cool graphical effect, ideal for when a player completes a level.

Program an auto-scrolling background with GML for immersive environments.
64 Firework Display Zip
Archive – 475.3 KB

 65 Spawn Bullets From Double Weapon

This allows for spawning bullets in a double-barrelled weapon.

65 Spawn Bullets From Double Weapon Zip
Archive – 615.3 KB

 66 Sprite Drop Shadow

A simple method for creating a drop shadow effect.

Create a basic rhythm game mechanic using GML for timed inputs
66 Sprite Drop Shadow Zip
Archive – 486.7 KB

 67 Simple Top Down Collision

This code works well in top down games, for example a racing game.

Program a random item drop system in GML for surprise rewards
67 Simple Top Down Collision Zip
Archive – 543.4 KB

 68 Spawn Instance With Random Subimage

This example spawns an instance with a random subimage and vertical speed.

Design a particle effect system in GML for explosions
68 Spawn Instance With Random Subimage Zip
Archive – 676.3 KB

 69 Sine Wave Based Movement

A sine wave can be used for a lot of effects, for example smoothly moving an instance up and down, as in this example.

Build a save and load feature using GML to store game progress
69 Sine Wave Based Movement Zip
Archive – 486.8 KB

 70 Draw Player’s Speed On Dial

A simple way to visually show the player’s speed.

70 Draw Players Speed On Dial Zip
Archive – 694.9 KB

 71 Spawn Trees Border

A simple method of spawning a border of trees, suitable for a top-down vertical scrolling shooter.

Develop an experience points system with GML for leveling up
71 Spawn Trees Border Zip
Archive – 491.4 KB

 72 One Button Controlled Movement

Allows you to add some accessibility to your games, by allow the player to move a crosshair around the room with a single button.

Program dynamic enemy pathfinding in GML for added realism
72 One Button Controlled Movement Zip
Archive – 502.2 KB

 73 Plane Movement

A flexible movement system for a player plane in a side-scrolling shooter.

Develop a space shooter game with GML for collision detection
73 Plane Movement Zip
Archive – 537.5 KB

 74 Player Power Up Creator

Sometimes you may wish for your player to work hard to earn a powerup. This example requires the player mash the mouse buttons to unlock an upgrade.

Program a health bar in GML to reflect player status
74 Player Power Up Creator Zip
Archive – 522.9 KB

 75 Coin Drop Bonus Effect

Creates a cool looking graphical effect.

75 Coin Drop Bonus Effect Zip
Archive – 528.2 KB

 76 Endless Levels

By using a static screen without views you can create an endless level by spawning instances off screen and for example moving them down.

Build a weather effects system using GML for dynamic environments
76 Endless Levels Zip
Archive – 2.1 MB

 77 Mini Healthbar With Segments

Draws a healthbar with segments.

Create an inventory system in GML to manage player items
77 Mini Healthbars With Segments Zip
Archive – 541.5 KB

 78 Outline Shader

Creates a white border around an instance.

Build a farming simulation game with GameMaker
78 Outline Shader Zip
Archive – 959.5 KB

 79 Move Crosshair To Target

This automatically selects a target and moves the crosshair to the target.

Program a shooter game with enemy AI in GameMaker
79 Move Crosshair To Target Zip
Archive – 538.3 KB

 80 Spawn Items With Gap

A method to place multiple instances with a gap inbetween.

80 Spawn Items With Gap Zip
Archive – 1.2 MB

Use Coupon Code SPRING For 40% Off


 81 Add Scores To A List

There may be times when you want to keep track of player score, for example in a darts game.

Start your platformer project today with a GameMaker download
81 Add Scores To List Zip
Archive – 522.9 KB

 82 Cloud Effect

Create a cloud scrolling effect, great for above and below various layers in your game.

Design a color-matching game using cascading effects from gamemaker.at
82 Cloud Effect Zip
Archive – 660.4 KB

 83 Ball Bouncing Off Instances

A Simple method to make a ball bounce off of walls.

Craft a tower defense game using GML projects from gamemaker.at
83 Ball Bouncing Off Instances Zip
Archive – 491.6 KB

84 Keeping A Value In A Range

There will be time when you wish to keep a value within a given range.

Experiment with procedural generation using gamemaker.at's resources
84 Keeping Vakue In Range Zip
Archive – 533.2 KB

 85 Film Style Scrolling Credits

Create scrolling text in a film style. Ideal for showing credits on game complete.

85 Film Style Scrolling Credits Zip
Archive – 582.0 KB

 86 Rotate Room View

This method provides a great method for giving additional visual feedback to the player. Idea for a driving or flying game.

Learn advanced AI techniques with GML projects from gamemaker.at.
86 Rotate Room View Zip
Archive – 677.7 KB

 87 Toggle Full Screen

There may be times when you want to allow the player to choice of full screen or windowed.

Develop a platformer using examples from gamemaker.at
87 Toggle Fullscreen Zip
Archive – 650.2 KB

 88 Progress Bar

Sometimes it’s nice to show the player their level progress.

Develop a character customization example project using GML.
88 Progress Bar Zip
Archive – 713.4 KB

 89 Flash Player To Show Damage

This example shows one method of visually showing a player that they have taken damage. This changes the player’s character to red.

Warning: Contains Flashing Images

Craft an interactive menu system example project in GameMaker.
89 Flash Player To Show Damage Zip
Archive – 548.5 KB

 90 Fade Between Two Images

This fades in and out two subimages. Great for making appealing looking text without the overhead of having to use multiple images.

90 Fade Between Two Images Zip
Archive – 677.7 KB

 91 Draw A Path As Circles

A useful method of drawing a path as circles. Ideal for giving hints to the player.

Program a side-scrolling shooter as a fun GML project
91 Draw Path As Circles Zip
Archive – 475.7 KB

 92 Simple Top Down Movement Control

A simple top down movement control that uses a single mouse button. The good thing is that this leaves the right mouse button free for attacking.

Create a dynamic weather example project using GML.
92 Simple Top Down Movement Zip
Archive – 1.9 MB

 93 Laser To Target

This draws a laser from the instance to a target,which in this example is the mouse’s x position.

Build a simple stealth game project using GML for AI behavior.
93 Laser To Target Zip
Archive – 645.2 KB

 94 Bubble Explosion Effect

Here’s a simple effect that makes a load of bubbles great for an underwater themed game (or use something other than bubbles to match your theme).

Develop a puzzle-solving game project with GML
94 Bubble Explosion Effect Zip
Archive – 1.1 MB

 95 Add Instances To A Grid & Move To A Target

Below is a simple method of making a grid with areas that are not allowed. It then makes a path to a random instance.

95 Add Instances To Grid And Move To Target Zip
Archive – 488.2 KB

 96 Image Scale, Fade and Rotate Effect

An effect that can be used for a variety reasons.

Build a top-down shooter in GML as a practice project
96 Image Scale Rotate And Fade Zip
Archive – 675.1 KB

97 Player Streak

Keep tracks of a player’s streak, for example the number of enemies killed without missing.

An example project in GameMaker demonstrating basic platformer mechanics
97 Player Streak Zip
Archive – 519.3 KB

 98 Numbers As Text

This script will change digits to text, for example 16783 to sixteen thousand seven hundred and eighty three. Works upto 999999

Simplify 2D game creation with the latest GameMaker download.
98 Numbers As Text Zip
Archive – 520.1 KB

 99 Draw Lives As Images

This draws the players lives as images.

Jump into game development with a free GameMaker download
99 Draw Lives As Images Zip
Archive – 528.8 KB

 100 Coin Explosion Effect

The following is a cool explosion effect, great when collecting coins.

100 Coin Explosion Effect Zip
Archive – 526.9 KB

 101 Text With Gradient

This script draws gradient text with a border. Great for game titles, game-over screen etc..

Learn GML scripting easily after a GameMaker download
101 Text With Gradient Zip
Archive – 517.8 KB

Use Coupon Code SPRING For 40% Off


Level Up Your Game Development Skills with GameMaker Examples A

Game development is an exciting journey, but even the best developers sometimes hit roadblocks. That’s where GameMaker Examples A comes in—a carefully curated collection of ready-to-use GML code snippets designed to help developers of all skill levels turn their ideas into stunning reality.

What Makes GameMaker Examples A Essential?

GameMaker Examples A is a hub for anyone looking to refine their coding skills in GameMaker Language (GML), whether you're tackling game physics, AI movement, or particle effects. Here’s what makes it a must-visit resource:

  • Beginner-Friendly: Perfect for newcomers to GML, these examples include intuitive code that’s easy to understand and modify.

  • Advanced Solutions: For seasoned developers, the site offers innovative scripts that solve complex game development challenges.

  • Save Time and Boost Creativity: You’ll find pre-tested and optimized GML code, so you can focus on designing an immersive game experience.

Dive into the World of GML

For those unfamiliar, GameMaker Language (GML) is a versatile tool for creating everything from simple arcade games to sprawling RPGs. It provides developers with control over their game's behavior, from gameplay mechanics to custom visual effects. At GameMaker Examples A, we showcase the potential of GML by offering clear examples that inspire creativity and speed up development.

Popular Code Snippets from GameMaker Examples A

Here are some standout examples from our growing library:

  1. Character Movement Scripts: Whether you’re designing a platformer or a top-down shooter, these scripts provide smooth and precise controls.

  2. Projectile Systems: Add powerful combat mechanics with examples that let your characters shoot projectiles and track their impact.

  3. Dynamic Lighting and Shadows: Enhance your game’s atmosphere with visually stunning and efficient lighting code.

  4. Interactive Menus: From pause screens to customizable main menus, these scripts make navigating your game a breeze.

Why Choose GameMaker Examples A?

At GameMaker Examples A, we believe in empowering developers. That’s why our examples come with detailed explanations, ensuring you understand not just the how but the why behind each piece of code. By using these examples, you can:

  • Improve Your Skills: Learn GML best practices and coding techniques.

  • Discover New Ideas: Find inspiration to experiment with game mechanics you hadn’t considered before.

  • Streamline Your Workflow: Spend less time debugging and more time creating.

 

Whether you're building your first game or working on your next indie hit, GameMaker Examples A is your go-to resource for unlocking the full potential of GameMaker Language. Explore now and take your game to new heights!


Current Contents

Collection A: 101 Mini Projects

Collection B: More 101 Mini Projects

Collection C: Even More 101 Mini Projects

Collection D: Lots More 101 Mini Projects

Collection E: Another 101 Mini Projects

New Page:

Games & Interesting Ideas: Updated Weekly

Also Taking Suggestions For Mini Projects and Games - Send Me Your Ideas Here