Android Game Development Design Steps

Source: Internet
Author: User
Tags android games

The number of mobile phones with Android operating systems today is much larger than the iphone. Android devices are reported to be activated on average 400,000 units per day. But iOS is still a more lucrative and popular platform for developers. The reason: Android doesn't have to pay for apps, and many devices and apps store the Android Market in a decentralized state. So how to effectively design the development of Android games, professional IT training Clip Ding Academy for you to answer:

1 Introduction to mobile game development

The essence of the game is to constantly display and update the picture on the screen, but not to update it randomly, but to control it according to the logic of the program. A complete game requires a wide range of knowledge, such as the game's creativity, background, storyline, game sound, game style, game type, speed, adaptation model and so on. In addition, the development of the game needs planning, art, procedures, testing and coordination of work and tacit cooperation to complete.

2 Game Frame Design

First you need a view class to display the game interface, and then you need to build an entire game logic class to control which interface is displayed on the current screen, and even some logical processing of the interface. After creating and controlling the view display, to allow the game to move, you need to turn on a thread to update the view display interface and refresh the view in real time.

3 Map Design

Usually the map in the game is a large map composed of several small pieces, and the data that makes up these pieces can usually be stored using a two-dimensional array, and then the program will map the small pieces of the map data to the screen to form a complete map. Of course, the data is not a single input from the keyboard, usually first by the programmer to do a map editor, in this map editor with the mouse click to save, or to download some mature editor from the network, such as the use of tools such as mappy to generate maps, Then use the scripting language for Mappy to write a program that should remain in what format. Usually the map is divided into 45-degree angles, angled angles, and lateral angles.

4 Lead Design

The protagonist in the game is here to become "elves", of course, the elves include a wide range, not only the protagonist, as well as NPC, props and so on. Since it is a wizard, there must be a lot of animation, the animation itself is the picture frame by frame to connect, the loop to play each frame formed. You can also use your own Wizard editor to edit the wizard, the wizard into a lot of parts, and then combined together, this can save a lot of space. The characteristics of the Sprite class, you can only use one image at a time instead of multiple images to fill the screen, there are several frames, but only one display at a time.

5 Layer Manager

Simply add all layers (including maps, protagonists) to the layer manager, and then set the position and size of the view when you call the layer Manager's Paint method to draw the layer. The order in which you draw is in the reverse order of the addition, which is added first and then drawn so that the layer is not visible after it is overwritten.

6 Gameplay sounds

First of all, we divide the sound effects in the game into the following categories: Background music, drama music, sound effects (action sounds, use of Prop sound, auxiliary sound), etc. Background music generally needs to be played all the time, while the drama music only needs to play when the plot needs, the sound is very short.

7 Game Archive

Game archiving is the player's current game progress and other information stored, the player can enter the game again by reading the last archive to continue the last progress of the game.

(1). Identify the data that needs to be stored

First of all, in order to re-play successfully reproduced the last progress, need to save some of the protagonist's properties (including location, life, attack, defense, etc.), but also need to save some properties of the current map (such as rows, columns, the current number of layers), also need to save the conversation of the relevant content, Finally, you need to save the entire map data for the game (each layer), as well as the current music status.

(2). Save data

Gets the stored data, package data into properties, and writes the properties to a file.

(3). Loading data

Open file, load the file stream into properties, and use the Properties.get method to get the specified label data-"assigns the resulting data to the corresponding variable in the application."

When you exit the game, the player will save it automatically, regardless of whether it is saved.

If you want to know more about it, please click I want to apply for it CD

Android Game Development Design Steps

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.