Guide

Make your first game in 5 minutes

Most "make a game" tutorials start with an hour of downloading art. This one doesn't. You'll draw two coloured squares, place them, and wire up eleven blocks — and you'll end with a real game: red squares rain down, you slide left and right to survive, your score climbs, and hitting one starts you over. Everything happens on your phone in Max2D, free on Google Play. Set a timer.

What you're building A dodge game. A blue square you control at the bottom, ten red squares falling down the screen at different speeds, one point every time a block gets past you, and instant restart when one hits you. Fourteen objects total — but eleven of them are duplicates of one you build once.
Want the finished project? Download it free and import it — reading a working game is sometimes faster than building one, and you can pull it apart block by block.

Download ColourDodge.zip (2 KB)

To open it: Max2D → ProjectsImport Project → pick the file. The project takes its name from the zip, so leave the filename alone.

Minute 1: The project and two squares

  1. Make a new projectOpen Max2D, Create tab, new project. Call it Colour Dodge. Leave the first scene named scene1.
  2. Draw the player squareOpen the sprite editor, fill a 64 × 64 canvas with blue, and save it as player. Solid colour, no detail — that's the whole point.
  3. Draw the danger squareSame again in red, saved as block. Red reads as danger without a single word of explanation, which is a real design decision doing real work.

Prefer real art? Open the Asset Store inside Max2D for ready-made sprites, or import any image from your gallery. Every step below is identical either way, and the art can be swapped at any time.

Minute 2: The player

Tap + and choose Sprite, name it exactly player, and place it near the bottom of the view. Give it three components:

ComponentSettingsWhy
Spriteyour blue squareWhat you see
Rigidbodydynamic, gravity scale 0, fixed rotation onSlides sideways, never falls, never spins
Box Collider64 × 64What the red blocks hit

Two of those settings are the difference between a game and a mess. Gravity scale 0 is why the player doesn't drop off the bottom of the screen. Dynamic rather than kinematic is subtler: a kinematic body ignores walls entirely and would slide straight off the edge. Dynamic bodies get stopped by things, which is what you want.

Minute 3: Controls, in three tiny chains

Open the player's script. You're adding three separate chains, none of them connected to each other:

  1. Slide leftWhen Screen Touched (event Touch Down, location Left) → Move (Velocity) with linear x = −260.
  2. Slide rightWhen Screen Touched (Touch Down, location Right) → Move (Velocity) with linear x = 260.
  3. Stop on releaseWhen Screen Touched (event Touch Up, location Whole) → Move (Velocity) with linear x = 0.

Leave every other field on those Move blocks as NaN. NaN means "don't touch this property", so these blocks only ever change horizontal speed and leave everything else alone.

That's your entire control scheme: touch a side of the screen, go that way; let go, stop. The location dropdown on the touch event does all the work — no maths, no joystick, no dead zones.

Add two walls, or you'll slide into the void Tap + and choose Empty — not Sprite. The Add Object sheet offers Sprite, Text, Sound and Empty; an Empty object has no image at all, which is exactly what a boundary wants to be.

Name it wall, give it a static Rigidbody and a tall Box Collider (about 40 × 700), and place it just off the left edge. Then duplicate it for the right edge. Invisible but solid.

Minute 4: The falling block

Create the score variable first Open the scene's variables panel and add a global number variable called score, starting at 0. Do this before you build the block's script. The Set Variable block picks its target from a dropdown, so if the variable doesn't exist yet there is nothing to pick — you'd wire up the whole chain and then wonder why tapping through blocks scores nothing.

Now the only genuinely interesting object in the game. Tap +Sprite, name it exactly block, give it your red square, a kinematic Rigidbody and a 64 × 64 Box Collider, and place it above the top of the view. Kinematic means it moves exactly how you tell it and nothing pushes it around.

Its script is five blocks in one chain:

  1. On PlayRuns every frame.
  2. Move (Velocity)Linear y = −150. Negative is downward. Everything else NaN.
  3. If (True/False)Expression position_y < -320 — "have I fallen past the bottom?"
  4. Change Position/Size, on the true branchSet position y = 320, leave position x, both scales and angle as NaN. This teleports the block back above the top of the screen.
  5. Set VariableThis block has three fields, and the order matters. Set scope to global first, then pick variablescore, then open the num value dropdown, choose Expression solver, and enter score + 1. A block that got past you is a point earned.
Typing a formula instead of a number Any number field can hold a formula instead of a fixed value. Tap the field's dropdown and pick Expression solver — the field then shows {expression} instead of a number. That's how score + 1 goes into num value, and how score goes into the score label's text field later.

One trap on Set Variable: changing scope clears whatever variable you had chosen, because the variable list is filtered by scope. Always set scope first, or you'll wonder why the dropdown went blank.

Those five blocks are what makes the game endless. Nothing is ever created or destroyed — ten blocks fall forever in a loop, and the scoring is a free side effect of the recycling.

Why is the reset value positive when the block starts negative? Because they're different coordinate systems, and this trips up everyone once. Placing objects in the editor uses screen coordinates, where down is positive. Expressions like position_y and the Change Position/Size block use world coordinates, where up is positive. So a block placed at editor y = −300 sits above the screen, and sending it back there means setting y = 320. If your blocks vanish instead of looping, flip that sign first.

Minute 5: Duplicate, then finish

  1. Copy the block across the screenDuplicate it nine times and spread the copies horizontally. Duplicating carries the script with it, so this is nine taps, not nine scripts.
  2. Stagger their heightsDrag each copy to a different height above the screen. This is what turns a wall of blocks into a rain of them.
  3. Give each one a different speedChange the Move block's linear y on each copy: −130, −160, −190, −145, and so on. Identical speeds mean the blocks stay in formation forever; different speeds mean the gaps keep changing and the game never plays the same way twice. This is the single highest-value minute in the build.
  4. Add the fail stateBack on the player's script, a fourth chain: On PlayIs Colliding With (object block) → from the blue true port → Load Scene set to scene1. Reloading the current scene is the cheapest restart there is.
  5. Show the scoreTap +Text and place it at the top with a two-block script: On PlaySet Text. In the Set Text block, open the text field's dropdown, choose Expression solver and enter score. Type it as plain text instead and your label will proudly display the word "score" forever.

Now play it

Press play. Blocks fall, you slide, the number climbs, and a red square ends the run. That's a game — a loop with a goal, a skill, and a consequence.

If something's off, it's almost certainly on this list:

SymptomCause
Player falls off the bottomGravity scale isn't 0
Player slides off the sideWalls missing, or the player is kinematic instead of dynamic
Blocks fall once and never come backReset y is negative — it should be positive (see the coordinates note)
Blocks pile up at the bottomThey're dynamic instead of kinematic, so they're colliding with each other
Score jumps by dozensThe If block is wired to the wrong port, so it fires every frame instead of once
Nothing kills youObject name typo — the Is Colliding With block needs exactly block
Player spins when hitFixed rotation is off
Score stays at 0Set Text has plain text instead of an Expression solver value
Set Variable's variable dropdown is emptyThe score variable doesn't exist yet, or scope was changed after picking it (which clears it)

Five more minutes, five better games

You now have a skeleton worth reusing. Each of these is a small change to what you just built:

  • Catch instead of dodge. Make the blocks green, and swap the Load Scene on collision for a Set Variable that adds points. Same objects, opposite goal.
  • Speed ramp. Change a block's speed to an expression like -150 - score * 2 so the game accelerates as you get better.
  • Two colours. Duplicate the block, tint it green, and give it the scoring behaviour while red keeps the killing behaviour. Now the player has to make decisions instead of just avoiding things.
  • Lives. Add a lives variable, subtract one on a hit instead of restarting, and only load the scene when it reaches zero.
  • Sound. One Play Sound block on the hit chain does more for the feel of the game than any visual change of the same size.

When you want the next step up — real physics, animation, a saved high score and a second screen — build Flappy Bird. It's the same ideas with more of them. If you'd rather describe a game and have it built for you, see making a game with AI, and if you're weighing up tools first, start with making a game without coding.

Frequently asked questions

Can I really make a game in five minutes?

If the game is small, yes. This one is fourteen objects and eleven blocks, and eleven of those objects are duplicates of one you build once. Five minutes buys you a finished, playable loop with scoring and a fail state — not a polished product.

Do I need to download any art?

No. The sprite editor is built in, so a solid coloured square takes about ten seconds. Two squares is the whole art budget. You can swap in real sprites later without touching any of the logic.

Why does my player fall off the bottom of the screen?

Gravity scale isn't 0. This player only slides sideways, so it wants a dynamic body with gravity scale 0 and fixed rotation on. Dynamic matters too — a kinematic body ignores the side walls and slides off the edge.

How do I make it harder?

Raise the falling speed on some blocks, add more blocks, or slow the player down. Because each block carries its own speed, varying that number is the cheapest way to stop the pattern repeating.

What should I build after this?

Reuse the same three ideas in a new shape: an event chain per input, a moving object that recycles, and a variable that counts. A catch game, a lane runner and a simple shooter are all this skeleton wearing different clothes.

Five minutes from now you could be playing it

No PC, no art, no code. Free on Google Play.

Free onGoogle Play