Saturday, August 30, 2014

Best Practice for Game Development

Hello developers,
           Here i am sharing game development phases that one should go with, Especially for indie game developers and studios.




           If you are planing to being game developer then their are lots of factors you should keep in mind, as being a game developer is not as easy as playing a game. It is inverse it.

Key phases for game development,


1. Market Research


           Before planning for any kind of game development one should make some research on current game trends, game user audience, game platforms etc. This would help a lot for your game and make you more clear what should you choose for your game.

         For example: If their is currently trend of 2048 kind of game then you can either go for same game development or similar kind of game development, so that you can easily redirect 2048 game users to you game and make money. Or if you are planning to rock the game market then you can choose your own concept and make it on stage. Its up to you how you are going!

Area of Research:

1. Current market trends
2. Targeted audience and country
3. Targeted platforms
4. Game category and scope
5. Age group

2. Game Design

           Game design is the main factor after market research if you are planning to develop a game, and it is ignored by most of indie game developer but i recommend to spend much time on designing a game rather planning for other stuffs. The more effort you made on designing the game the less effort would required on developing and marketing your game.

           For example : If you are planning to do like Subway Surfer like endless runner game then you will probably gathers basic requirements for your game and start development but in between of actual development if you will find more entertaining game then Subway Surfer then probably you would change your game design and this will result in delay of your product as well might be costly to packet.

Topics covered in game design:

1. Game story/Game concept
2. Game category
3. Game play and HUD design
4. Power ups
5. Future update
6. Dealing with developer team
7. Game engine selection and limitations
8. Multiple platform support
9. Marketing scenario

3. Graphics Development

           Once game design phase is completed the product would come in development phase, here it will come in graphics and UI development phase.


           If game is 3d then it would come in animation/model development and this would start your actual product development.

           Graphics development is very important part of your game as graphics is the one who makes first impression when you game is released. If game is containing eye catching graphics then use would probably download and play your game at least once.

4. Game Programming

           This is where your product is got rigged. Yes game programming is the phase where product is actually got rigged and lead to playable game.

           Game programming phase is one of most expensive phase of game development. Previous three phase would be gathered and programming team starts on product development. The more effort on programming makes product more engaging. This is where programming team is adding Physics, Animations, Event system, Third party tools, VFX(particles and all) and Sounds.

           Once game is downloaded journey is not stooped here, it is started actually. User would only sticked to game he/she found something engaging or unique in game otherwise he/she will simply uninstall game and never recommend others to play it. If he/she will found something engaging or unique in game they game would be played and also recommended to others. That would result in inter user marketing and of course that makes your pocket heavy.

5. Game Marketing(App Store Optimization)



           Once your product has been developed, tested and released successfully this phase starts. This is where your actual journey starts! Yes it is, your game is containing pretty and eye catching graphics, is has been executed nicely on game programming phase but if there is no marketing there is not installs of your game.

           This is where most of indie developer/studio got punched,  their are lost of game stores/portals are available, their are millions of games/apps on the game market, hundreds of game are released per day.. Out of them where your game would be ? Area of thinking.. Like any newly released website for game also their would require lots of marketing to attract user to download and play the game.


Marketing Agenda and Type

1. Social media marketing
2. Google AdMob or other advertiser platform 
3. Video marketing
4. Inter game or Inter user marketing
5.  Content based marketing

Tuesday, August 26, 2014

Getter and Setter in C# Unity3d

C# Unity has support for Getter and Setter properties which is very important in terms of Object Oriented Programming, Here is a simple example of Getter and Setter properties which shows its usefulness,
Without getter and setter properties:
  1. public int getX()
  2. {
    1. return x;
  3. }
  4. public void setX(int newX)
  5. {
  6. if(newX < 0)
  7. x = 0;
  8. else
  9. x = newX;
  10. }
To change the value of x you have to write like
  1. setX(getX()+4);
With getter and setter properties:
  1. public int X
  2. {
  3. get { return x; }
  4. set
  5. {
  6. if(value < 0)
  7. x = 0;
  8. else
  9. x = value;
  10. }
  11. }
Now in this case you can easily change value of x with 
  1. X += 4;
Getter and Setter is very usefull properties of C# programming language and can be utilize interestingly in Game Development also in Unity3d.

To know some basic but important key points about C# programming language go HERE,


Some basic use of these properties listed below,

1. Flexible way to get and set values conditionaly.
2. Works great with Unity3d Transform and other Vector properties.
3. Use mainly in Score/Health calculation/computaion etc.

Monday, July 28, 2014

Resolution Manager Script Unity3d

Hello developers,
As a mobile app/game developers it is not quite easy to make app/game UI same on different resolution devices,
In previous post you can see common resolutions with aspect ratios, also most used resolution devices among with that,
Below is the Unity3d Monobehaviour version of that discussion which is quite easy to get and use,

using UnityEngine;
using System.Collections;

public class ResolutionManager : MonoBehaviour 
{
public int bgWidthToLaod = 800;

float xWidth;
float yHeight;

void Awake()
{
xWidth = Screen.width;
yHeight = Screen.height;

float aspectRatio = xWidth / yHeight;

if(aspectRatio >= 1.30f && aspectRatio <= 1.35f)
{
// 2048 * 1536
aspectRatio = 1.33f;
bgWidthToLaod = 2048;
}
else if(aspectRatio >= 1.45f && aspectRatio <= 1.55f)
{
// 960 * 640
aspectRatio = 1.5f;
bgWidthToLaod = 960;
}
else if(aspectRatio >= 1.58f && aspectRatio <= 1.70f)
{
// 1280 * 768
aspectRatio = 1.67f;
bgWidthToLaod = 1280;
}
else if(aspectRatio >= 1.75f && aspectRatio <= 1.80f)
{
// 1136 * 640
aspectRatio = 1.78f;
bgWidthToLaod = 1136;
}
else
{
aspectRatio = 1.67f;
bgWidthToLaod = 1280;
}
}
}

Tuesday, July 22, 2014

Unity3d Important Methods and its Priority Order

Some Unity3d important methods and its usage with priority order,

[1] Awake : 

        Called just after object got initialized, also for prefab. It is called before Start function call. If gameobject is disabled Awake is not called, but if any function of this script or function of script attached to same object is invoked, object would be initialized and Awake is called. This is where most of developers got confused with Awake method invocation.
Priority : 1


[2] OnEnable : 

        This is called when Monobehaviour is enabled. It is also called before Start call. If object is not active this will not be invoked.
Priority : 2


[3] Start :

        Start is called before any frame update started if object is enabled.
Priority : 3

[4] FixedUndate :

        Fixed update is called more frequently then Update call if frame rate is low. If frame rate is high then it might called less frequently then Update call. Fixed update is called on reliable basis then Update function that's why you do not need to multiply movement calculation with Time.deltaTime. All physics related calculation should be placed inside FixedUpdate to make it behave correctly.
Priority : 4


[5] Update : 

        Update is called once per frame. This is main function in Unity3d Monobehaviour. If frame rate is set to be high then all input related code should be placed here to avoid input issues.
Priority : 5


[6] LateUpdate :

        LateUpdate is also called once per frame. The only difference between Update and LateUpdate is that its been called once Update has completed its execution. This will be very usefull in case where there is a need of task to be executed if and only if another task got completed. 
Example : Camera movement, score calculation, input management.
Priority : 6


[7] OnDisable : 

        This is called when Monobehaviour becomes inactive/disabled.
Priority : 7


[8] OnGUI :

        This function is called multiple time per frame, might call double then the Update call depending upon current frame rate. All input related code should be place in this function. Main use of this function is two draw various UI elements. Thought it is not advisable to use this function as of performance issues.

Sunday, July 20, 2014

Resoultions and Aspect Ratio

As a mobile game/app developer it is headache to port game/app to various mobile/hand held devices having different resolutions. Here is the list of resolutions for all major mobile and hand held devices which would help you while developing cross platforms mobile applications and games,

Resolutions* (AR*)

2048 * 1536 --> 1.33
1024 * 768 --> 1.33
1136 * 640 --> 1.78
960 * 640 --> 1.50
854 * 480 --> 1.78
800 * 480 --> 1.67
800 * 400 --> 1.50
2560 * 1536 --> 1.67
2560 * 1600 --> 1.60
1920 * 1080 --> 1.78
1920 * 1200 --> 1.60
1920 * 1152 --> 1.67
1824 * 1200 --> 1.52
1536 * 1152 --> 1.33
1280 * 720 --> 1.78
1280 * 800 --> 1.60
1280 * 768 --> 1.67
1024 * 600 --> 1.71
1024 * 800 --> 1.28
960 * 600 --> 1.60

* Resolutions are in Pixels
* AR - Aspect Ration

Most used aspect ratios,

1.33 - iPad, iPad 2, iPad Retina
1.50 - iPhone 4, iPhone 4s
1.67 - Most of Android devices
1.78 - iPhone 5, iPhone 5s, iPhone 5c, Android Tab Series

Monobehaviour script for resolutions and aspect ration is here.

Popular Posts