Introduction .com



Flappy BirdGame Design / Technical Design DocumentAuthor: Justin EseigbeDate: 07/05/2015Contents TOC \o "1-3" \h \z \u Introduction PAGEREF _Toc418614050 \h 3Why Make “Game Name” PAGEREF _Toc418614051 \h 3How is the game supposed to play? PAGEREF _Toc418614052 \h 3Game Features PAGEREF _Toc418614053 \h 3Player Character PAGEREF _Toc418614054 \h 3Game World PAGEREF _Toc418614055 \h 3Controls PAGEREF _Toc418614056 \h 4Power-ups and Collectables PAGEREF _Toc418614057 \h 4Scoring PAGEREF _Toc418614058 \h 4Level Design PAGEREF _Toc418614059 \h 4User Interface PAGEREF _Toc418614060 \h 4Audio PAGEREF _Toc418614061 \h 5Technical Features and Code PAGEREF _Toc418614062 \h 5Main Game Loop PAGEREF _Toc418614063 \h 5Character, Movement and Controls PAGEREF _Toc418614064 \h 6Camera PAGEREF _Toc418614065 \h 6Procedural Level Generation PAGEREF _Toc418614066 \h 6Power-up and Collectable systems PAGEREF _Toc418614067 \h 6Scoring System PAGEREF _Toc418614068 \h 7UI system PAGEREF _Toc418614069 \h 7Audio System PAGEREF _Toc418614070 \h 7Test Plan and Test Data PAGEREF _Toc418614071 \h 7Alternative Ideas PAGEREF _Toc418614072 \h 9Character, Movement and Controls PAGEREF _Toc418614073 \h 9Level layout and generation PAGEREF _Toc418614074 \h 9Power-Ups and Collectables PAGEREF _Toc418614075 \h 9User Interface and game screens PAGEREF _Toc418614076 \h 9Scoring PAGEREF _Toc418614077 \h 9Audio PAGEREF _Toc418614078 \h 9Constraints and Summary of Project PAGEREF _Toc418614079 \h 9IntroductionIntroduce the purpose of this document, why it is being written and how it will help you when you begin work on the development of your game. This document illustrates the information about the game “Flappy Bird” What’s it about, the assets used like characters and stages. The code used to make it and etc. Why Make “Flappy Bird”Within this section you need to describe in detail why you are making the game. Talk about the Flappy Jam and talk about other games made during it. Explain why you want to make the game that you’re making. You also need to explain how it will be different to other similar games. You must also mention that the game is being developed in the Unity engine and is aimed at cross platform release (PC and Mobile / Tablet devices). I am making this game app because I was inspired by a game I played when I visited a website called Flappy Jam which has a collection of game just like the one I played and the one I’m currently talking about making which is different from other because the game include items you can collect other that avoiding pipelines. I’m hoping to release this game on mobile and tablet devices since most people of this generation play apps more than those on the computer.How is the game supposed to play?Within this section you need to describe the purpose of your game. What is the player supposed to do? Why are they doing it? Is the game supposed to be entertaining or are you trying to do something else such as educate the player? You also need to talk about the intended audience for your game, this includes the age group and whether the game is aimed more at males or females or both. In flappy birds you play as this bird who is trying to fly to the shops and collect as many coin as it can on the way there in order to buy food for itself and its babies while avoiding obstacles such as pipelines and other dangerous items that may be in its way. Your job is to flap the bird’s wings by pressing a specific button to help him avoid obstacles and collect as many coins as you can without bumping into pipelines that cause you to fall. The purpose of the game is not only helping out the bird in the story but encourages an all genders audience of ages 8 or older who are interested in games that challenge you go through the game without failing, to test your limits and to try and beat someone’s high score which makes the game addictive has you playing it even after completing the story which is what my new game I trying to make is delivering.Game FeaturesThis section should be broken down into sub sections that cover the following topics:Player CharacterWhat is your character? My character is a white bird.Why is your character what it is? My main character is a bird in order to reflect the game title.How does the character tie into the overall gameplay? The bird will be flapping his wings throughout the gameplay.If you use an existing piece of art for your main character you must explain where you sourced the art assets from in the table below:Asset NameSource Google images.Game WorldWhere is your game set? My game is set in modern times in New York/ LondonWhy is your game set here? Because I want to set my game apart from other games which take place in fields.Is there an overarching story or narrative in your game? There is no narration in the game.ControlsWhat are the intended controls for your game? The controls I plan to incorporate in the game is to type down the Up key on the keypad to flap his wings and fly higher and hold down the Down key to descend down. How do the controls differ across each platform? Because in my game you can control the descend of the bird.Power-ups and CollectablesAre there power-ups / Collectables in your game? There are coins and lightning bolts. What do each of the power-ups / collectables do? Coins are items you collect and bolts give you temporary invincibility.What is the intended effect of these power-ups / collectables on the gameplay experience? Points gained coins are added to the scoreboard. And bolts allow you to bust through pipelines without dying. ScoringHow does the player score points? The bird score points by collecting coinsHow is the score calculated? By the size of the coins. The smaller the coins the more points you get like bit-size coin are worth 3 points.Is there a high score table and how will this be organized and displayed? In the game there will be score board showing only the highest score.Level DesignDuring completion of this section you are required to use the skills learnt during the Graphics units to create mock ups of game screen and level layouts. These should look as close to how you want your final game to look as possible.Explain the features of your levels here. What are the obstacles going to be? What exactly is the challenge for the player? The challenge is to collect as many coins as you can while avoiding pipelines.Explain how your art assets tie in with the game world and character you have designed. My assets tie in with the game because my bird would be able to stand out more and also the streets are modern with buildings and cars coming at you.Explain how you will generate the level. The level difficultly will depend on how long you survive and how many coins you collect.Provide mock ups of level layouts here. This is my first hand drawn layout of the level and what it is like and how it will turn out.If you have used any art assets for your user interface you must provide links to where you sourced them from within the table below:Asset NameSource Google images.User InterfaceDuring completion of this section you are required to use the skills learnt during the Graphics units to create mock ups of the user interface and menus. These should look as close to how you want your final game to look as possible.What is going to be show to the player during gameplay? Provide mock-ups of your designs here along with explanations of the layout. There will be two signs 1 will keep score and 1 will tell you how many pipes you went through. As well as that there will also be icon players can press with their finger. What are the menu’s going to look like? Provide mock-ups of your designs here along with explanations of the layout. The layout is of my game’s main menu with the 4 icon which appears as four buildings: Story which displays a description on what the game is about. Free play allows you to play the game. High score opens up the highest score recorded and New update allows you to update the game with new features or DLCs if possible. How will the player navigate your menus? What will the pause menu look like? How about the game over menu? Provide mock Ups and descriptions here. Players navigate through the main menu by touching one of the icons. Next to the score board there will be and Icon you touch in order to pause the game found on the right corner of the screen and when you do pause it 2 buttons will appear one allowing you to return to the main menu and the other will un-pause the game. If you have used any art assets for your user interface you must provide links to where you sourced them from within a table below:Asset NameSource Pause buttonHandmade by me in the paint program.AudioExplain the music that you will have in your game. What style is it? Why have you chosen this music? Will you have one piece of music for the title screen and another for in-game? The music I have chosen for the game is from a classical game but is now acoustic remix version called “Mute city”. The reason I chosen this type of music is because acoustics kind of blend in well with the stage in modern times unlike rock, jazz or classical music which make it fell out of place. Explain how you want the sound effects to sound. Why do you want them to sound like this? The sounds that I want to add to the game are retro games types like super Mario or sonic because my game is 2D and I want to incorporate 2D elements to the game. Collect / make all the sounds and music that you are going to use in your game and list them in the assets table below:Asset NameWhere asset will be usedSource?F Zero "Mute City"?Gameplay musicTook the mp3 file and added acoustics using Reaper.242857__plasterbrain__coin-getWhen you collect coins Effects (Car Driving Sound Effects)When Car is driving towards youRecorded it and edit it on reaper.Technical Features and CodeThe following section is where you need to get into the technical qualities of the game and how each part will be programmed – well, at least the basic elements. You will need to also explain where you have used code sourced from other places. A good example of this would be the Advanced C# Messaging system that we installed together – this is a great tool for triggering events in your game, but you didn’t write the code and as such the original author must be credited. Below are the topics you must include:Main Game LoopHere you must provide a flow diagram of the main game loop. The game loop will start from your splash screen and go to the main menu (which should have an option for viewing the high score table and start game and exit game). Depending on the choice the player makes the program will to one of three branches. Exit game and high score are self-explanatory. If the player selects start game you must then continue the flow chart in a logical manner – what happens when the player earns points? What happens to these points when the player dies? What options does the player have when the game over screen appears? Think of all the different events / scenarios that the player will go through – this will help you with the UI system section.Character, Movement and ControlsGive an example of the code that will allow your character to move. This will be your character controller script. Explain the variables that you are going to make public so that you can tweak them within the inspector within Unity to better balance the game. You must also explain the code that you will be using to animate your character along with explanations of the different animations. Finally you must also show and explain the code that controls when your player dies. List in the table below all the built in Unity Methods that you will be using within your code, use the Unity scripting manual as a guide. An example would be Transform.translate to make a character move on screen:Unity MethodWhat it does and howvoid Update() { if (Input.GetKeyDown("space")) { anim.SetTrigger("Flapped"); body.AddForce(new Vector2(0, (jumpHeight * 1.2f))); Messenger.Broadcast("Flapped"); }This method allows you to flap your birds’ wings with the space bar while it plays the animation of it flapping its wings using anim.SetTrigger("Flapped"); on script.The jumpHeight is made pubic so it can be altered or changed in the character inspector.The Messenger.Broadcast("Flapped"); is used to get game components faster like this one is used to get the animation. CameraShow and explain the code used to make the game camera follow the player. List in the table below all the built in Unity Methods that you will be using within your code, use the Unity scripting manual as a guide.Unity MethodWhat it doesvoid Update () { transform.position = new Vector3(player.position.x + 6, 0, - 10);}This transform.position is focused on the level in the game and moves to the right using player.position as the x axis.Procedural Level GenerationGive an example of the code and method that you are using to generate the level layout and explain how it works. This must be as detailed as possible. You can also provide screenshots of how you are doing this along with your code example. List in the table below all the built in Unity Methods that you will be using within your code, use the Unity scripting manual as a guide.Unity MethodWhat it doesvoid OnTriggerEnter2D(Collider2D other) { if (other.tag == "Player") { Application.LoadLevel(1); }This void is set in a away when a player collinds with ground or hit one of the pipes it will load a new scene which is whereApplication.LoadLevel(1);Comes in.The bird is about to hit the ground.The game over screen appear automatically after hitting the ground.Power-up and Collectable systemsGive code examples for each of your power-ups and how they affect the player. Also show how the collectables will add to the score in code. Explain how the code works. List in the table below all the built in Unity Methods that you will be using within your code, use the Unity scripting manual as a guide.Unity MethodWhat it doesvoid OnTriggerEnter2D(Collider2D other) { if (other.tag == "Player") { hud = GameObject.Find("Main Camera").GetComponent<HUDScrpt>(); hud.increaseScore(2); Debug.Log("Score Increase by 2"); Destroy(this.gameObject); Messenger.Broadcast("Collected"); } }void OnTriggerEnter2D(Collider2D other) { if (other.tag == "Player")if player touches power-up hud.increaseScore(2); Debug.Log("Score Increase by 2");This power-up will increase the points collected by 2 times. Destroy(this.gameObject);At the same time vanishes after being collected.Scoring SystemShow the code you will use to calculate the player’s score. You must also show the code that you use to generate the high score table. Explain how the code works. List in the table below all the built in Unity Methods that you will be using within your code, use the Unity scripting manual as a guide.Unity MethodWhat it doesvoid OnTriggerEnter(Collider other) {if (other.gameObject.tag == "Pick up") {other.gameObject.SetActive(false);count = count + 1;SetCountText ();}void OnTriggerEnter(Collider other) happens when two colliders interact with each other. in this case if the player interacts with the coin, other.gameObject.SetActive(false); meaning the coin will disappear after being collected.count = count + 1;SetCountText ();This method adds one point on the existing scoreboard.int [] highScore = new int[] { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 }; int InsertScore( int score ) { int i = 0;? //Look for the index to insert score while( i < highScore.length ) { if( highScore[i] <= score ) { break; } i++; }? //Score doesn't make it to top 10 if( i >= highScore.length ) { return -1; }? //Push all the scores not higher than score backward for( int j = highScore.length - 1; j <= i; --j ) { highScore[j] = highScore[j-1]; } ? //Set score highScore[i] = score; return i; }int [] highScore = new int[] { 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 };is a list of of the top 10 scores from high to lowest.int InsertScore( int score ) { int i = 0;this inserts your current score to the board. if( i >= highScore.length ) { return -1;if the score doesn’t make the top 10 it will not be there. for( int j = highScore.length - 1; j <= i; --j ) { highScore[j] = highScore[j-1]; } This Push all the scores not higher than score backward.This method Sets score. highScore[i] = score; return i; }UI systemShow the code you will be using to make the Ui functional and work – this includes the code triggers you use for buttons and how you get the game to go from one screen to another. Explain the code in detail. List in the table below all the built in Unity Methods that you will be using within your code, use the Unity scripting manual as a guide.Unity MethodWhat it doesusing UnityEngine;using System.Collections;public class LoadOnClick : MonoBehaviour { public GameObject loadingImage; public void LoadScene(int level) { loadingImage.SetActive(true); Application.LoadLevel(level); }}Once I create the buttons in my game I used a code on one of them that allows you to load the level. public GameObject loadingImage; is used on one of my buildings in the main menu. public void LoadScene(int level) { loadingImage.SetActive(true); Application.LoadLevel(level);Is used to load another scene in the game depending on how you set it.Audio SystemExplain the code that you are using to trigger sounds. Explain the Advanced C# Messaging system and how you are using it. Explain the mixer system in Unity. List in the table below all the built in Unity Methods that you will be using within your code, use the Unity scripting manual as a guide.Unity MethodWhat it does [RequireComponent] (typeof (AudioSource))] public class PowerUpScript : MonoBehaviour { HUDScript hud; void OnTriggerEnter2D(Collider2D other) { if(other.tag == "Player") { hud = GameObject.Find ("Main Camera").GetComponent<HUDScript>(); hud.IncreaseScore(10); Destroy (this.gameObject); audio.Play(); } } }?This onTriggerEnter is in a way that ifif(other.gameObject.tag=="Player") meaning if the player collides with coin or gameobject play a sound selected from the AudioSource. At the same timeit will destroy the game object usingDestroy(gameObject);audio. Play() will play the audio. Once done you can go to the mixer to adjust the sound to how you want it to be played (similar to Reaper).Test Plan and Test DataThe following section is to be used to prepare a test plan for your game. The test plan must contain at least 20 elements of your game that you will be testing for functionality. This can include things such as making user the score is calculated correctly when the player is playing the game or making sure that the score is properly added to the high score table and is placed in the correct position on the table. Other tests could include making sure the hit box around the character sprite works correctly, the jump height and the controls work correctly or that the buttons on the menus do what they are supposed to do. Test plans are supposed to be as detailed as possible with each and every element of the game being tested – that means separate tests for each and every button on your menus, tests for both the upward bounding box and lower bounding box and tests to make sure that each and every object does what it’s supposed to do. Detail is key, a buggy or broken game is not fun to play.Item Being TestedWhere the Item IsExpected OutcomeActual OutcomePass / FailLoad game over screenDuring gameplayWhen player dies Load game over screencoinsDuring gameplaySparking animationCoin being collectedDuring gameplayCoin disappears after being collected by the playerCoin being collected audio During gameplayCoin makes a ding sound effect while being collectedBackground musicDuring gameplayBackground music plays during gameplayScore being calculated correctlyDuring gameplayKeeping score after collecting coinsBuilding scrollingDuring gameplayItems resembling building continue on as player movesRetry buttonDuring game over sceneAllows you to retry after dyingFlapping animationDuring gameplayWhen button is pressed the bird flaps its wings.Flapping animation soundDuring gameplayWhen button is pressed the bird flaps its wings and generates sound effectThe groundDuring gameplayWhen player touches ground they die.pipesDuring gameplayCheck if the pipes kill the player as wellCamera focusDuring gameplayCamera is following playerscoreboardAfter gameCurrent score should be added on to scoreboardMain menubefore gameplayOne of the buttons should load the game.The pipes are placed correctlyDuring gameplayThe pipes should spawn in the right placesFlapping birdDuring gameplayWhen spacebar is pressed bird should fly up a certain altitude. Doubling power upDuring gameplayPower up should double points for a certain time.Car animationDuring gameplayCar should be animated and driving along the road.Sound effect to carDuring gameplayAs the car first appears and is passing through the sound it makes should be active until it disappears. Alternative IdeasWithin this section you must explain any other ideas that you have that might work better than your original concepts. You must consider the visual / auditory elements as well as the code for the following:Character, Movement and ControlsGive examples of how you might change these elements of the game. What I could do to improve the controls is to add a pause menu in the game and the script I can use for this is:using System; using UnityEngine; public class pause : MonoBehaviour { bool paused = false; void Update() { if(Input.GetButtonDown("pauseButton")) paused = togglePause(); } void OnGUI() { if(paused) { GUILayout.Label("Game is paused!"); if(GUILayout.Button("Click me to unpause")) paused = togglePause(); } } bool togglePause() { if(Time.timeScale == 0f) { Time.timeScale = 1f; return(false); } else { Time.timeScale = 0f; return(true); } } }Level layout and generationGive examples of how you might change these elements of the game. What I could do is try to find more buildings so players won’t be bored seeing the same one as before which would increase game activity.Power-Ups and CollectablesGive examples of how you might change these elements of the game. What I can do in the game to make it more challenging is adding another power up that allows your points to go down every time you hit a minus coin. The code I plan to use for it is:void OnTriggerEnter2D(Collider2D other) { if (other.tag == "Player") { hud = GameObject.Find("Main Camera").GetComponent<HUDScrpt>(); hud.decreaseScore(2); Debug.Log("Score decrease by 2"); Destroy(this.gameObject); Messenger.Broadcast("Collected"); } }User Interface and game screensGive examples of how you might change these elements of the game. What I could do is also make the buttons more interactive and use images as the links. The script I can use for interactive links are:using UnityEngine;using System.Collections;public class GameOverButtons : MonoBehaviour { public void OnRetryButtonPressed() { Debug.Log("I got here"); Application.LoadLevel(0); }public void onMainMenuPressed(){Application.LoadLevel (2);}public void onExitPressed(){Application.Quit();}}ScoringGive examples of how you might change these elements of the game. For scoring I can change the font to something more appropriate for the score to make it seem less boring and also add color to it in order for it to stand out more.AudioGive examples of how you might change these elements of the game. Players may be bored of hearing the same background sound so I plan to add a feature that allows them to switch between tracks this makes it more like a realistic radio. The script I plan to use is:using UnityEngine; using System.Collections; public class myPlaySwitch : MonoBehaviour { public AudioSource _AudioSource1; public AudioSource _AudioSource2; void Start() { _AudioSource1.Play(); } void Update () { if (Input.GetKeyDown(KeyCode.S)) { if (_AudioSource1.isPlaying) { _AudioSource1.Stop(); _AudioSource2.Play(); } else { _AudioSource2.Stop(); _AudioSource1.Play(); } } } }Constraints and Summary of Project Within this last section you must write a report about any constraints that you feel you might have while completing the development of your project along with predictions of any changes that you might need to make due to the constraints. You must then explain how your game design matches up and meets the requirements and purpose of the project. ................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download