Setting Up Play Games Services with the Google Play Developer Console

This document covers how to use the Google Play Developer Console to set up Games services for your Android, iOS, or web-based game.

  1. Step 1. Sign in to the Google Play Developer Console
  2. Step 2. Add your game to the Google Play Developer Console
  3. Step 3. Generate an OAuth 2.0 client ID
    1. a. Create a linked application
    2. b. Create a client ID
    3. c. Specify client ID settings
    4. d. Gather credentials for authentication and authorization
    5. e. (Optional) Creating multiple client IDs
  4. Next steps

To set up Games services, you first need to add your game to the Google Play Developer Console. In the game entry, you can specify details such as the name and description of the game.

In order for your game to access the Games services, you also need to generate the necessary credentials to authorize and authenticate your game.

You can link the game entry in the Google Play Developer Console to Android, iOS, and web versions of your game, so that players on these platforms can see the same game details and share the same Games services.

Step 1. Sign in to the Google Play Developer Console

To sign in, go the Google Play Developer Console. If you haven’t registered for the Google Play Developer Console before, you will be prompted to do so.

Step 2. Add your game to the Google Play Developer Console

To add your game to the Google Play Developer Console:

  1. Open the Games with Game Services page and add your game.
    1. Select the Games services tab on the left.
      The Game Services tab
    2. Click the Add a New Game button.
  2. Specify if the game you are adding already uses Google APIs.
    • If this is a game you are creating from scratch, or you have never set up Google APIs for it previously, stay on the I don’t use any Google APIs in my game yet tab. Enter your game’s name and assign it a category, and then click the Continue button.
      The 'Create a new Game' dialog box
    • If this is a game for which you have already set up one or more Google APIs (for instance, Google+ sign-in) , select the I already use Google APIs in my game tab. You will see a list of projects from the Google Developers Console for which you are listed as a developer. Select your project from this list, assign the game a category, then click the Continue button.
      The 'Create a new Game' dialog box
  3. In the Game Details form, add the description, category, and graphic assets for your game. Only the display name is required for testing. The other fields must be filled out before you can publish your game.
  4. Click Save to create a new entry for your game in the Google Play Developer Console. A corresponding entry in the Google Developers Console is also created for you.

Step 3. Generate an OAuth 2.0 client ID

Your game must have an OAuth 2.0 client ID in order to be authenticated and authorized to call the Play Games services.

To set up the association between a client ID and your game, use the Google Play Developer Console to generate the client ID and link it to your game.

To generate an OAuth 2.0 client ID for your game, follow these steps:

a. Create a linked application

To link your game to a Google Developers Console project, open the Linked apps page, and then follow the instructions specific to your platform.

  1. Click the Link an Android app button.
    Choosing the platform to link
  2. The application name may be shown to your players, so specify a name that closely matches the name of your actual Android game.
  3. Add the application’s package name.
  4. To use Games services’ real-time or turn-based multiplayer support, enable the appropriate multiplayer settings.
  5. Select whether or not to turn on Anti-Piracy.
  6. Click Save and continue, then follow the steps in the Create a client ID section below.
    Linking an Android application, step 1

b. Create a client ID

  1. In the Step 2: Authorize your app screen, click the Authorize your app now button to begin the process of creating an OAuth 2.0 client ID.
The 'Authorize your app' button
  1. You will be prompted to enter a project name along with an optional product logo. This information will appear in the OAuth 2.0 permissions dialog box when a user is asked to authorize your game. Your game name is placed in the project name field by default.
  2. Click Continue, then follow the steps in the Specify client ID settings section below.

c. Specify client ID settings

Next, specify your client ID settings by following the instructions specific to your platform.

  1. Choose Installed application as your Application type and select Android as the installed application type (these should be your only options).
    Linking an Android application, step 2
  2. In the Package name field, enter your Android application’s package name.
  3. Open a terminal and run the the Keytool utility to get the SHA1 fingerprint of the certificate. You should get both the release and debug certificate fingerprints.To get the release certificate fingerprint:
    keytool -exportcert \
    -alias <your-key-name> \
    -keystore <path-to-production-keystore> \
    -list -v

    To get the debug certificate fingerprint:

    keytool -exportcert \
    -alias androiddebugkey \
    -keystore <path-to-debug-keystore> \
    -list -v
  4. The keytool prompts you to enter a password for the keystore. The default password for the debug keystore is android. The keytool then prints the fingerprint to the terminal. For example:
    Certificate fingerprint: SHA1: DA:39:A3:EE:5E:6B:4B:0D:32:55:BF:EF:95:60:18:90:AF:D8:07:09
  5. Paste the SHA1 fingerprint into the Signing certificate fingerprint field.
  6. Click the Create client button, then follow the steps in the Gather credential information section below.

For more information about OAuth 2.0 on Android, see Authenticating to OAuth2 Services.

You should create two client IDs, one with the release certificate fingerprint and another with the debug certificate fingerprint. Make sure to use the same package name for both. This allows Play Games services to recognize calls from your linked APKs that are signed with either certificate. For more information about certificate signing for Android, see Signing Your Application.

You can add more than one Android app to the same game entry in Google Play Developer Console. However, this should only be done if there are different versions of the same game (for example, the free version and the paid version). In this case, always list the paid version before the free version (or the full version before the demo/trial version). Do not link different games to the same project as this may cause incorrect behavior. Instead, create a separate game entry in the Google Play Developer Console for each game that you publish.

d. Gather credentials for authentication and authorization

Depending on the platform you are developing for, you may need to locate and record the following credential information.

Client ID

After you click the Create Client button, you should see your new client ID for this application. Make a note of the client ID, as you will need this information later. You will have a different client ID for each platform.

For Games Development  Requirement  Services

Email : inquiry@bharat-infosys.com

Website : http://www.bharat-infosys.com

Contact : Heraj : 9099856329

Shekhar : 9016690608

 

 

Android App Distribution

Amazon Appstore

Amazon Appstore is an alternate application store for the Android operating system. It was opened in March 2011, with 3800 applications.

App Store

Apple‘s App Store for iOS was the first app distribution service, which set the standard for app distribution services and continues to do so, opened on July 10, 2008, and as of January 2011, reported over 10 billion downloads. As of June 6, 2011, there are 425,000 third-party apps available, which are downloaded by 200 million iOS users.[12][13] During Apple’s 2012 Worldwide Developers Conference, Apple CEO Tim Cook announced that the App Store has 650,000 available apps to download as well as “an astounding 30 billion apps” downloaded from the app store until that date.[14] From an alternative perspective, figures seen in July 2013 by the BBC from tracking service Adeven indicate over two-thirds of apps in the store are “zombies”, barely ever installed by consumers.

BlackBerry World

BlackBerry World is the application store for BlackBerry 10 and BlackBerry OS devices. It opened in April 2009 as BlackBerry App World, and as of February 2011, was claiming the largest revenue per app: $9,166.67 compared to $6,480.00 at the Apple App Store and $1,200 in the Android market. In July 2011, it was reporting 3 million downloads per day and 1 billion total downloads. In May 2013, BlackBerry World reached over 120,000 apps. BlackBerry 10 users can also run Android apps.

Google Play

Google Play (formerly known as the Android Market) is an international online software store developed by Google for Android devices. It opened in October 2008. In April 2013, there were approximately 850,000 apps available for Android, and the estimated number of applications downloaded from Google Play was 40 billion. Android Apps can also run on BlackBerry 10 devices.

Nokia Store

An app store for Nokia phones was launched internationally in May 2009. As of April 2011 there were 50,000 apps, and as of August 2011, Nokia was reporting 9 million downloads per day. In February 2011, Nokia reported that it would start using Windows Phone as its primary operating system. In May 2011, Nokia announced plans to rebrand its Ovi product line under the Nokia brand and Ovi Store was renamed Nokia Store in October 2011. Nokia Store remains as the distribution platform for its previous lines of mobile operating systems but will no longer allow developers to publish new apps or app updates for its legacy Symbian and MeeGo operating systems from January 2014.

Windows Phone Store

Windows Phone Store was introduced by Microsoft for its Windows Phone platform, which was launched in October 2010. As of October 2012, it has over 120,000 apps available.

Windows Store

Windows Store was introduced by Microsoft for its Windows 8 and Windows RT platforms. While it can also carry listings for traditional desktop programs certified for compatibility with Windows 8, it is primarily used to distribute “Windows Store apps”—which are primarily built for use on tablets and other touch-based devices (but can still be used with a keyboard and mouse, and on desktop computers and laptops).[23][24]

Samsung Apps Store

An app store for Samsung mobile phones was founded in September 2009.As of October 2011 Samsung Apps reached 10 million downloads. Currently the store is available in 125 countries and it offers apps for Windows Mobile, Android and Bada platforms.

If you Wont  your App to stay this type of App store join or deal with bharat information system.

We Developed Your Business Application and Upload This Type of App Store and Download also. then you have a good Business Growth. So Think About it and deal with bharat information System

We have a many Experience Developer in This Field and Technical Support Team.

Website : http://www.bharat-infosys.com

Contact Details :  Heraj Mishra – +91-9099856329

Email : inquiry@bharat-infosys.com

Memory management in Android Application

Since Android devices are usually battery-powered, Android is designed to manage memory (RAM) to keep power consumption at a minimum, in contrast to desktop operating systems which generally assume they are connected to unlimited mains electricity. When an Android app is no longer in use, the system will automatically suspend it in memory – while the app is still technically “open”, suspended apps consume no resources (e.g. battery power or processing power) and sit idly in the background until needed again. This has the dual benefit of increasing the general responsiveness of Android devices, since apps don’t need to be closed and reopened from scratch each time, but also ensuring background apps do not consume power needlessly.

Android manages the apps stored in memory automatically: when memory is low, the system will begin killing apps and processes that have been inactive for a while, in reverse order since they were last used (i.e. oldest first). This process is designed to be invisible to the user, such that users do not need to manage memory or the killing of apps themselves. However, confusion over Android memory management has resulted in third-party task killers becoming popular on the Google Play store; these third-party task killers are generally regarded as doing more harm than good.

We Provides Android App, Java Based App, Games Development, Web Development Services in India and Many More Countries.

Contact @ :  inquiry@bharat-infosys.com

Heraj Mishra – +91-9099856329

http://www.bharat-infosys.com

Google Android Info – Basic Facts about Android

Google Android Info Brings You Basic Facts about Android

Android has become the world’s most successful mobile OS. Not too long ago, we presented the short history of this OS in our Evolution of Android series (part I, part II). This former underdog has now become the market’s dominant player. And chances are that if you received a new smartphone or tablet under the tree earlier today, it’s running Android.

Android is not quite as easy to understand as you may think. API levels, Dalvik architecture, and many other terms still require some reading to fully understand. Luckily, XDA Forum Member newaageappz got an interesting idea of compiling all this information together and releasing it in an application. Now, whenever you have some free time, you can learn about the basics of Android, its history, features, and even some sample source code so that you can eventually create your own, innovative applications.

This simple, yet interesting app is a good idea for those long winter nights, when boredom strikes back and you are looking for something to read. If you are interested in Android, you should visit the application thread and give this application a try. Live and learn.

www.bharat-infosys.com

Heraj – 9099856329

Android Application Development With the Lattest Smartphones !!!

The use of Android smartphones is flourishi well, with thousands of apps being created and distributed across millions of smartphones across the world. According to the recent study, Android phones have witnessed an increase in sales of 65 per cent every month, with new handsets being released frequently. Industry experts believe that the app development has also witnessed a drastic rise with the advent of feature-rich smartphones. The first and foremost reason for the rise is obviously the open source nature of the platform and its flexibility. Additionally, a significant growth has been witnessed over a couple of years when it comes to download of Android applications which is expected to sales too.

Some of the latest functionalities and features offered by the Android platform for application development have included Cloud based service integration. Cloud computing has helped out different companies to efficiently manage IT and also make the best use of the utilities and promotion of their own services. There have been many popular Android apps which has taken advantage of the Location based feature offered by Google which is basically an extension of the Google map feature. This feature has facilitated many apps which can track down the location of the customer via GPS and now have gone a step further in giving out relevant information about the place.

It has been said by analysts that mobile apps will soon involve e-payments since there are gadgets which can help mobile phones swipe credit cards. In the near future, you can expect your Android phone to send and receive payments. Android app development is geared towards offering e-commerce based services too.

There are many offshore software development firms who offer mobile app development services and specifically related to the Android platform. These programmers try to make the best use of the platform and its attributes for making a range of innovative apps at cost-effective prices. It is important for most of these organizations to churn out the best Android applications quickly and make use of the recent trends and the upcoming smart phones and its features.

Android developers create Java-based third party mobile applications for mobile devices which include PDAs. Some of the services offered within Android application development include:

  • Web-based application mobile development
  • Custom Android add-on development
  • Mobile utilities development
  • Android games development
  • Java-based games development
  • Business app development
  • Multimedia mobile solutions
  • Location based app development with GPS support
  • Communication mobile application development
  • QA and testing services

Leading Android App Development and Games Development company have team of skilled and experience android developers who develops apps for many platforms that suit for business needs.

Website        :     http://www.bharat-infosys.com

Contact @   :      Heraj  +91-9099856329

Email @       :     inquiry@bharat-infosys.com

Android Intent Structure

The primary pieces of information in an intent are:

  • action — The general action to be performed, such as ACTION_VIEW, ACTION_EDIT, ACTION_MAIN, etc.
  • data — The data to operate on, such as a person record in the contacts database, expressed as a Uri.

Some examples of action/data pairs are:

  • ACTION_VIEW content://contacts/people/1 — Display information about the person whose identifier is “1”.
  • ACTION_DIAL content://contacts/people/1 — Display the phone dialer with the person filled in.
  • ACTION_VIEW tel:123 — Display the phone dialer with the given number filled in. Note how the VIEW action does what what is considered the most reasonable thing for a particular URI.
  • ACTION_DIAL tel:123 — Display the phone dialer with the given number filled in.
  • ACTION_EDIT content://contacts/people/1 — Edit information about the person whose identifier is “1”.
  • ACTION_VIEW content://contacts/people/ — Display a list of people, which the user can browse through. This example is a typical top-level entry into the Contacts application, showing you the list of people. Selecting a particular person to view would result in a new intent { ACTION_VIEW content://contacts/N } being used to start an activity to display that person.

In addition to these primary attributes, there are a number of secondary attributes that you can also include with an intent:

  • category — Gives additional information about the action to execute. For example, CATEGORY_LAUNCHER means it should appear in the Launcher as a top-level application, while CATEGORY_ALTERNATIVE means it should be included in a list of alternative actions the user can perform on a piece of data.
  • type — Specifies an explicit type (a MIME type) of the intent data. Normally the type is inferred from the data itself. By setting this attribute, you disable that evaluation and force an explicit type.
  • component — Specifies an explicit name of a component class to use for the intent. Normally this is determined by looking at the other information in the intent (the action, data/type, and categories) and matching that with a component that can handle it. If this attribute is set then none of the evaluation is performed, and this component is used exactly as is. By specifying this attribute, all of the other Intent attributes become optional.
  • extras — This is a Bundle of any additional information. This can be used to provide extended information to the component. For example, if we have a action to send an e-mail message, we could also include extra pieces of data here to supply a subject, body, etc.

Here are some examples of other operations you can specify as intents using these additional parameters:

There are a variety of standard Intent action and category constants defined in the Intent class, but applications can also define their own. These strings use java style scoping, to ensure they are unique — for example, the standard ACTION_VIEW is called “android.intent.action.VIEW”.

The set of actions, data types, categories, and extra data defines a language for the system allowing for the expression of phrases such as “call john smith’s cell”. As applications are added to the system, they can extend this language by adding new actions, types, and categories, or they can modify the behavior of existing phrases by supplying their own activities that handle them.

Android Activity LifeCycle

Activities in the system are managed as an activity stack. When a new activity is started, it is placed on the top of the stack and becomes the running activity — the previous activity always remains below it in the stack, and will not come to the foreground again until the new activity exits.

An activity has essentially four states:

  • If an activity in the foreground of the screen (at the top of the stack), it is active or running.
  • If an activity has lost focus but is still visible (that is, a new non-full-sized or transparent activity has focus on top of your activity), it is paused. A paused activity is completely alive (it maintains all state and member information and remains attached to the window manager), but can be killed by the system in extreme low memory situations.
  • If an activity is completely obscured by another activity, it is stopped. It still retains all state and member information, however, it is no longer visible to the user so its window is hidden and it will often be killed by the system when memory is needed elsewhere.
  • If an activity is paused or stopped, the system can drop the activity from memory by either asking it to finish, or simply killing its process. When it is displayed again to the user, it must be completely restarted and restored to its previous state.

The following diagram shows the important state paths of an Activity. The square rectangles represent callback methods you can implement to perform operations when the Activity moves between states.activity_lifecycle

http://www.bharat-infosys.com

Android OS

Android is an operating system based on the Linux kernel, and designed primarily for touchscreen mobile devices such as smartphones and tablet computers. Initially developed by Android, Inc., which Google backed financially and later bought in 2005,Android was unveiled in 2007 along with the founding of the Open Handset Alliance: a consortium of hardware, software, and telecommunication companies devoted to advancing open standards for mobile devices. The first publicly available smartphone running Android, the HTC Dream.

The user interface of Android is based on direct manipulation, using touch inputs that loosely correspond to real-world actions, like swiping, tapping, pinching and reverse pinching to manipulate on-screen objects. Internal hardware such as accelerometers, gyroscopes and proximity sensors are used by some applications to respond to additional user actions, for example adjusting the screen from portrait to landscape depending on how the device is oriented. Android allows users to customize their home screens with shortcuts to applications and widgets, which allow users to display live content, such as emails and weather information, directly on the home screen. Applications can further send notifications to the user to inform them of relevant information, such as new emails and text messages.

Android’s source code is released by Google under the Apache License; this permissive licensing allows the software to be freely modified and distributed by device manufacturers, wireless carriers and enthusiast developers. Most Android devices ship with a combination of open source and proprietary software.As of July 2013, Android has the largest number of applications (“apps“), available for download in Google Play store which has had over 1 million apps published, and over 50 billion downloads. A developer survey conducted in April–May 2013 found that Android is the most used platform among developers: it is used by 71% of the mobile developers population.

Android is popular with technology companies who require a ready-made, low-cost and customizable operating system for high tech devices. Despite being primarily designed for phones and tablets, it also has been used in televisions, games consoles, digital cameras and other electronics. Android’s open nature has encouraged a large community of developers and enthusiasts to use the open-source code as a foundation for community-driven projects, which add new features for advanced users or bring Android to devices which were officially released running other operating systems.

Android became the most popular mobile OS, having the largest installed base, and is a market leader in most countries including the United States; there it has had the highest installed base of mobile phones for years. In the third quarter of 2013, Android’s share of the global smartphone shipment market—led by Samsung products—was 81.3%, the highest ever. In most markets Android-powered phones are the most popular comprising more than half of the overall smartphone sales, including the United States market starting with the September–November 2013 period. The operating system’s success has made it a target for patent litigation as part of the so-called “smartphone wars” between technology companies. As of September 2013, one billion Android devices have been activated.

BIS Provides World’s Best IT Services Provider Android, Java, Games and Web Development Services.If you wont any Services Visit Our Website Or Contact @

www.bharat-infosys.com

Heraj Mishra : +91-9099856329

public class Activity extends ApplicationContext {
     protected void onCreate(Bundle savedInstanceState);

     protected void onStart();
     
     protected void onRestart();

     protected void onResume();

     protected void onPause();

     protected void onStop();

     protected void onDestroy();
 }

As a user navigates through, out of, and back to your app, the activity instances in your app transition between different states in their lifecycle. For instance, when your activity starts for the first time, it comes to the foreground of the system and receives user focus. During this process, the Android system calls a series of lifecycle methods on the activity in which you set up the user interface and other components. If the user performs an action that starts another activity or switches to another app, the system calls another set of lifecycle methods on your activity as it moves into the background (where the activity is no longer visible, but the instance and its state remains intact). Within the lifecycle callback methods, you can declare how your activity behaves when the user leaves and re-enters the activity. For example, if you’re building a streaming video player, you might pause the video and terminate the network connection when the user switches to another app. When the user returns, you can reconnect to the network and allow the user to resume the video from the same spot.

This class explains important lifecycle callback methods that each Activity instance receives and how you can use them so your activity does what the user expects and does not consume system resources when your activity doesn’t need them.

 

Android’s Process Virtual machine & System Properties

Android’s Process Virtual machine

There is no Java Virtual Machine in the Android platform. Java byte code is not executed. Instead Java classes are compiled into Dalvik executables and run on Dalvik, a specialized virtual machine (VM) designed specifically for Android. Unlike Java VMs, which are stack machines, the Dalvik VM is a register-based architecture.

Dalvik has some specific characteristics that differentiate it from other standard VMs

  • The VM was designed to use less space.
  • The constant pool has been modified to use only 32-bit indexes to simplify the interpreter.
  • Standard Java bytecode executes 8-bit stack instructions. Local variables must be copied to or from the operand stack by separate instructions. Dalvik instead uses its own 16-bit instruction set that works directly on local variables. The local variable is commonly picked by a 4-bit ‘virtual register’ field.

Because the bytecode loaded by the Dalvik virtual machine is not Java bytecode, and of the specific way Dalvik load classes, it is not possible to load Java libraries packages as jar files, and even a specific logic must be used to load Android libraries (specifically the content of the underlying dex file must be copied in the application private internal storage area, before being able to be loaded).

System properties

As it is the case for the Java SE class System, the Android System class allows the retrieval of system properties. However, some mandatory properties defined with the Java Virtual Machine have no meaning or a different meaning on Android. For example:

  • “java.version” property returns 0 because it is not used on Android,
  • “java.specification.version” invariably returns 0.9 independently of the version of Android used,
  • “java.class.version” invariably returns 50 independently of the version of Android used,
  • “user.dir” has a different meaning on Android,
  • “user.home” and “user.name” properties do not exist on Android

    We Provides Android App and Android games Development Services in india and many more countries.

    We Also Offers Games Development and Affordable Web Development Services.

    you wonts this type of services then visit our website or  contact us

    http://www.bharat-infosys.com

    9099856329

    inquiry@bharat-infosys.com