How to make Flappy Bird in Unity (Complete Tutorial) 🐤💨

Zigurous · 393K views · 2021 · 1:06:47

Open on YouTube

Indie game developmentGame programming & enginestutorial

Why Stack Overflow recommends it

Stack Overflow users link it because beginners follow it to build a Flappy Bird clone in Unity and then ask for help when their code diverges from the tutorial.

Recommended by 1 people across 1 different months, 2022 to 2024.

What it is

A complete hour-long Unity tutorial by Zigurous that builds a Flappy Bird clone from scratch. It covers project setup, sprite import, input and movement, sprite animation, parallax backgrounds, pipe spawning, scoring, UI and menus, with source code on GitHub.

What people said

Recommends TechNerdTheCoder · 2023-01 · Stack Overflow · on “Unity 2D Not detecting when touching object with tag obstacle”

I am making a game similar to flappy bird I am currently following this guy's tutorial [this video] and I'm stuck near the end I have been searching for 4hours and can't find a solution here's the code Game Manager: using UnityEngine; public class GameManager : MonoBehaviour { private int score; public void GameOver() { Debug.Log("Game Over!"); } public void IncreaseScore() { score++; } } player: using UnityEngine; public class playermove : MonoBehaviour { private Vector3 direction; public float gravity = -9.8f; public float strength = 5f; private void Update() { if (Input.GetKeyDown(KeyCode.Space) || Input.GetMouseButtonDown(0)) { direction = Vector3.up * strength; } direction.y += gravity * Tim

Cites Ori Bergman · 2022-06 · Stack Overflow · on “Why does changing this picture in any way ruins the way it displays in unity?”

I downloaded a picture from a tutorial on how to create Flappy Bird in Unity: [this video] When I use it in Unity it works perfect however when I try to make any changes to it, whether by simple "Paint" or "Photoshop", the picture turns blurry and I can't understand why, here is a video where you can see the problem: [LINK] Here are 2 of the picture's details page, on the left, the one I downloaded from the tutorial that works good, on the right the one I simply changed some pixels in "Paint": [LINK]

Cites NamNam · 2023-05 · Stack Overflow · on “flappy bird doesnt want to flap its wing when i press space for some reason in unity”

i just just started unity and figured to recreate a flappy bird game to understand unity first. at the part where you put the script onto the "player" aka the bird for some reason the inputs doesn't work even though im certain i made no difference with the tutorial guy and my big sis who is also a programmer didnt really see any fault here. i need help or else i cant make further progress here ight its solved here, apperantly i forgot to make the body type kinematic link to tutorial video: [this video] public class Player : MonoBehaviour { private Vector3 direction; public float gravity = -9.8f; public float strength = 5f; private void Update() { if (Input.GetKeyDown(KeyCode.Space) || Input.GetMo

Cites Khalifa Alkhatri · 2024-09 · Stack Overflow · on “Why is my UI button not attaching a function?”

I'm trying to achieve a UI like this in my Unity project, where I can use my custom function in a C# script: [LINK] However, instead of the desired UI, I'm getting this on my button: [LINK] code (player file c#) : using UnityEngine; using UnityEngine.UI; public class GameManager : MonoBehaviour { public player player; public Text scoreText; public GameObject playbutton; public GameObject gameoverText; private int score; void Awake() { Application.targetFrameRate = 60; Pause(); } void Play() { Debug.Log("Play"); score = 0; scoreText.text = score.ToString(); Time.timeScale = 1f; player.enabled = true; playbutton.SetActive(false); gameoverText.SetActive(false); Pipes[] pipes = FindObjectsOfType