Target Shooter

Target Shooter is a fast-paced test of your timing and precision. You are faced with a series of targets moving steadily across your screen, and your only job is to hit the mark. It is not just about hitting the board; it is about hitting the center. With a fixed scope and a clock that never stops, you have to find your rhythm to become the ultimate marksman.

▶ Play Now – It's Free

Learning creating target board using Target Shooter

One of the most important things in a shooting game is the target board. Players need something clear, colorful, and easy to understand. A good target board helps players focus better and makes every hit feel satisfying. In Target Shooter, the board becomes the center of the gameplay experience because the entire game depends on timing and accuracy.

When beginners start making games in Flutter using Flame Engine, they usually focus only on movement or score systems. But creating a proper target board teaches many useful skills. You learn how to draw shapes, place components on screen, handle collisions, organize layers, and build reusable game objects.

In this tutorial you will learn how to create a complete target board system inspired by Target Shooter. The target board will contain multiple circles with different colors and scoring zones. We will also make the board reusable so you can spawn many targets later inside your game.

This tutorial uses simple Flame Engine concepts and beginner friendly Dart code. Everything is explained in human language so even new developers can follow comfortably.

Understanding the idea behind a target board

Before writing code, you should first understand how a target board actually works inside a game. Most target boards are made using circles placed one inside another. The outer ring usually gives low points while the center gives maximum score.

In Target Shooter, the center area is the most important part because players try to hit it for the highest points. That means our target board should visually guide the player toward the middle area. Bright colors help a lot here.

We will create a board using five circular layers.

  • Outer white ring
  • Black ring
  • Blue ring
  • Red ring
  • Yellow center

This style is easy to recognize and looks professional even though the code is simple.

Creating the TargetBoard component

In Flame Engine, every visual object usually becomes a component. Since the target board is a reusable object, we should create a separate component class for it.

Create a new Dart file called target_board.dart.

import 'package:flame/components.dart'; import 'package:flutter/material.dart'; class TargetBoard extends PositionComponent { final double radius; TargetBoard({ required this.radius, required Vector2 position, }) { this.position = position; size = Vector2.all(radius * 2); anchor = Anchor.center; } }

Let us understand this code slowly.

We imported Flame components and Flutter material package because we need colors and drawing tools.

The TargetBoard class extends PositionComponent. This means the board can be placed anywhere on the screen.

We created a radius variable because different target boards may have different sizes.

We also set the anchor to center. This makes positioning much easier because the board rotates and scales correctly from its middle point.

Drawing the target board

Right now the component exists but nothing is visible. To show graphics on screen we need to override the render method.

@override void render(Canvas canvas) { super.render(canvas); final center = Offset(radius, radius); final outerPaint = Paint() ..color = Colors.white; final blackPaint = Paint() ..color = Colors.black; final bluePaint = Paint() ..color = Colors.blue; final redPaint = Paint() ..color = Colors.red; final yellowPaint = Paint() ..color = Colors.yellow; canvas.drawCircle(center, radius, outerPaint); canvas.drawCircle( center, radius * 0.8, blackPaint, ); canvas.drawCircle( center, radius * 0.6, bluePaint, ); canvas.drawCircle( center, radius * 0.4, redPaint, ); canvas.drawCircle( center, radius * 0.15, yellowPaint, ); }

This is the main part of the target board system.

We first create a center point. Since our board size is based on radius, the middle point becomes radius and radius.

After that we create multiple paint objects with different colors.

Then we use canvas.drawCircle several times. Every new circle becomes smaller than the previous one. This creates the layered target design.

The yellow center acts as the bullseye area. This is usually the highest scoring zone in arcade shooting games.

Adding the target board into the game

Now we need to place the board inside the actual game screen.

Open your main game file.

import 'package:flame/game.dart'; import 'package:flutter/material.dart'; import 'target_board.dart'; class TargetShooterGame extends FlameGame { @override Future<void> onLoad() async { final target = TargetBoard( radius: 100, position: Vector2( size.x / 2, size.y / 2, ), ); add(target); } }

Here we create one target board and place it at the center of the screen.

The size.x and size.y values come from Flame Engine. They represent the screen width and height.

By dividing them by two we place the board exactly at the middle.

Why layered circles work so well

Many beginner developers ask why target boards use circles instead of rectangles or random shapes.

Circles naturally guide the eye toward the center. This creates focus. Players instantly understand that the middle area is important.

Another advantage is fairness. Circular layers create equal distance from all directions. This makes scoring feel balanced and predictable.

Games like archery simulators, dart games, and carnival shooters use this design because players already understand it without needing tutorials.

Adding shadows for better depth

Flat graphics work fine, but adding a shadow gives the board more life. Small visual improvements can make your game feel much more polished.

Update your render method.

final shadowPaint = Paint() ..color = Colors.black.withOpacity(0.25); canvas.drawCircle( Offset(radius + 6, radius + 6), radius, shadowPaint, );

Add this before drawing the outer white circle.

The shadow appears slightly below the board which creates a floating effect.

Creating scoring zones

A target board becomes much more useful when it can calculate score values.

We can create a simple function that checks how close the hit position is to the center.

int calculateScore(Vector2 hitPosition) { final center = Vector2(radius, radius); final distance = hitPosition.distanceTo(center); if (distance < radius * 0.15) { return 100; } if (distance < radius * 0.4) { return 75; } if (distance < radius * 0.6) { return 50; } if (distance < radius * 0.8) { return 25; } return 10; }

This function checks the distance between the player hit and the center point.

Smaller distance means better accuracy.

The yellow center gives 100 points while outer rings give lower points.

Understanding hit detection

Hit detection is very important in shooting games. Players should feel that every click or tap is accurate.

In Flame Engine, touch positions usually come from tap events. Once the player taps the screen, you can compare that position with the target board.

If the tap falls inside the target area, you award points.

This simple system is enough for arcade games and casual browser shooters.

Making the board move

Target Shooter becomes exciting because targets move across the screen. Static boards are good for testing, but moving targets create real challenge.

Add an update method inside the TargetBoard class.

double speed = 150; @override void update(double dt) { super.update(dt); position.x += speed * dt; if (position.x > 900) { position.x = -200; } }

Here dt means delta time. It keeps movement smooth across all devices.

The board moves toward the right side continuously.

Once it leaves the screen, it goes back to the left side.

This creates endless moving targets similar to classic shooting games.

Improving performance

Many beginners worry about performance while drawing circles repeatedly. The good news is that simple shapes are extremely lightweight in Flutter and Flame.

Even low end phones can handle many target boards without issues.

Still, you should avoid unnecessary calculations inside the render method.

Keep your drawing code simple and organized.

Creating multiple targets

One target board is not enough for a full game. Usually games spawn many targets with different speeds and positions.

Here is a simple loop example.

for (int i = 0; i < 5; i++) { final target = TargetBoard( radius: 70, position: Vector2( -200.0 * i, 150 + (i * 100), ), ); add(target); }

This creates five moving target boards.

Each board starts from a different position which makes gameplay more dynamic.

Using bright colors correctly

Bright colors are useful in arcade games because they immediately catch player attention.

But using too many strong colors everywhere can hurt the visual quality.

The target board works well because only the center areas are bright. The player focus naturally goes there.

Good game design is not only about coding. Color balance and visual clarity are equally important.

Adding animation effects

Small animations can make your target board feel alive.

For example you can slightly scale the board when it gets hit.

This gives visual feedback and makes the game more satisfying.

Even simple arcade games feel much more professional when objects react to player actions.

Common mistakes beginners make

One common mistake is using huge target sizes. Oversized boards remove the challenge from the game.

Another mistake is making the center zone too large. The bullseye should feel rewarding because it is difficult to hit.

Some beginners also use too many shadows and effects. This can make the board look messy.

Simple and clean designs usually work best in browser games.

Making the game more addictive

Good target boards create tension. Players want to try again because they know they were very close to the perfect hit.

This is why timing games become addictive. Small improvements feel meaningful.

When your board design is clear and your scoring system feels fair, players naturally continue practicing.

That is the secret behind many successful arcade games.

Final thoughts

Creating a target board may look simple at first, but it teaches many important Flame Engine concepts. You learn rendering, positioning, movement, scoring, reusable components, and visual hierarchy all in one project.

Target Shooter style games are excellent practice projects for Flutter web game development because they are easy to understand yet still fun to build.

Once your target board system is complete, you can continue improving the game by adding sound effects, particle explosions, combo systems, moving backgrounds, difficulty levels, and leaderboards.

The best part is that the same target board system can later be reused in archery games, carnival shooters, sniper games, or training simulators.

Keep experimenting with colors, movement speed, and scoring zones. Every small improvement teaches you more about real game development.

About the game:

What makes Target Shooter a true test of your focus

When you first start Target Shooter, the movement seems simple. Targets slide from the left side of the screen to the right at a constant speed. Because your scope is fixed in one position, you cannot move your aim around. You have to wait for the target to enter your sights and click at the exact millisecond.

The game challenges you to hit 10 targets in the shortest time possible. If you rush, you might miss the high-scoring center. If you wait too long, your total time increases. It is a balancing act between being quick and being accurate.

The targets are divided into three regions. While any hit counts toward your goal of ten, hitting the red center region rewards you with a massive 100 points. The goal is simple: hit 10 targets, maximize your score, and do it faster than anyone else.

A step-by-step guide on how to play and win

Getting started is easy, but mastering the rhythm takes practice. Here is exactly how the game works:

  1. Launch the game and get ready as the first target appears from the left.
  2. Observe the fixed scope in the middle of your screen; this is where your shot will land.
  3. Wait for the moving target to align perfectly with your scope.
  4. Tap your screen or click your mouse to fire a shot the moment the target passes through.
  5. Try to aim for the red center zone of the target to earn the maximum 100 points.
  6. Continue shooting until you have successfully hit 10 different targets.
  7. Keep an eye on the timer—your final rank depends on how quickly you finish the set.

The targets move at a steady, constant speed. The secret is to find the beat and click in a consistent rhythm rather than panicking.

What is on the screen and what you should notice while playing

  1. A fixed scope stays at the center of the screen all the time You cannot move it so your aim never changes position Every shot you take will go exactly through this point This means your focus should not be on moving aim Instead you must wait for the target to come to you Understanding this makes the game much easier to control
  2. Targets move from left to right across the screen They travel at a steady speed which helps you learn timing Each target passes through the center where your scope is placed You need to watch their movement carefully before clicking After a few rounds you will start feeling a rhythm This rhythm helps you hit more accurate shots
  3. Each target has different zones including a red center The center gives the highest score when you hit it Outer areas still give points but less compared to the center Your goal is not just to hit the target but to hit the center This requires better timing and patience A perfect hit feels more rewarding and boosts your score quickly
  4. A score display shows how many points you have earned Every successful hit adds to your total score Better accuracy gives higher points Watching your score grow keeps you motivated It also helps you track how well you are improving Higher scores mean better timing and focus
  5. A timer runs during the game and tracks how fast you finish You need to hit a set number of targets as quickly as possible Both speed and accuracy matter for a good result Taking too long will increase your total time Missing shots also wastes time and breaks your rhythm Balancing speed and precision is the key to winning

The Story: Karim's Shooting Practice

Karim grew up in a small village surrounded by vast, open fields. His grandfather was a legendary marksman who could hit a moving leaf from a hundred yards away. Karim always looked up to him and wanted to carry on the family legacy of incredible focus and steady hands.

To prepare for the upcoming regional championship, Karim built a special training machine. He used old wood and gears to create targets that slide across a track at a fixed speed. He set up a heavy iron scope that is bolted to the ground, meaning he cannot move his gun. He has to rely entirely on his timing.

Every morning before the sun is high, Karim goes out to the fields. He knows that in a real competition, he only gets a few chances to prove his worth. He sets a goal for himself: hit ten targets as perfectly as possible.

The red paint in the center of the targets is starting to fade from so many hits, but Karim doesn't stop. He knows that speed is just as important as accuracy. Now, you are stepping into Karim's shoes. Can you handle the pressure of the practice field and hit the marks just as well as he does?

Key features of the game

🎯

Three-Zone Scoring

Each target has three distinct areas. Hitting the outer rings gives you points, but the red center is the "sweet spot" worth 100 points.

⏱️

Time-Based Challenge

It is not just about hitting the targets; it is about how fast you can do it. Every second counts toward your final performance.

🔄

Constant Speed Motion

The targets move at a reliable, steady pace. This allows you to develop a "muscle memory" rhythm for your clicks.

🔭

Fixed Scope Mechanic

Unlike other shooters, your aim is locked. You must master the art of "leading" the target and timing your shot perfectly.

🔢

Ten-Target Sprint

The game is a short, intense burst of action. You need exactly 10 hits to complete a round, making it perfect for quick breaks.

📱

Universal Controls

Whether you are on a phone or a computer, the "tap to hit" mechanic works seamlessly across all your devices.

Expert tips to improve your high score

  1. Listen to the "click" of the targets. Sometimes finding a physical beat in your head helps with timing.
  2. Don't try to move the scope—remember, it is fixed! Focus only on the target's entry into the center.
  3. If you miss a target, don't double-click immediately. Wait for the next one to reset your rhythm.
  4. Focus your eyes slightly to the left of the scope so you can see the target coming before it hits the center.
  5. Practice makes perfect. Your first few rounds will be slow, but your brain will quickly adapt to the speed.

Frequently Asked Questions

How do I get the maximum score in Target Shooter?

To get the highest possible score, you must hit the red center of all 10 targets. Each center hit gives you 100 points, for a total of 1000 points.

Can I move the crosshair or scope?

No, the scope is fixed in the center of the screen. This is a game of timing, not traditional aiming. You must wait for the target to move into your sights.

What happens after I hit 10 targets?

The game ends once you reach 10 hits. Your total score and the total time taken will be displayed, allowing you to try again and beat your record.

Why is rhythm so important in this game?

Since the targets move at a constant speed, the time between each target appearing is predictable. Finding a rhythm helps you click at the right moment without overthinking.

Is there a penalty for missing a shot?

While there isn't a direct point penalty for a miss, it wastes time. Since your goal is to finish as fast as possible, every missed shot hurts your final time.