Jan 22 2013

New AndEngine book – AndEngine for Android Game Development Cookbook

Category: AndEngine,GLES2Nicolas Gramlich @ 18:59

Hello Community,

Jayme Schroeder and Brian Broyles recently finished writing their new book ‘AndEngine for Android Game Development Cookbook‘. It is the first book to cover the OpenGL ES 2 branch of AndEngine! I couldn’t get my hands on it so far, but what I’ve heard from Jayme and Packt Publishing, sounds very promising!

AndEngine for Android Game Development Cookbook

The book can be purchased through: Packt Publishingamazon.com, amazon.co.uk, Barnes&Noble, Safari Books Online.

(Note: The e-book/kindle versions come at almost 50% discount!)

This is the official book description:

Over 70 highly effective recipes with real-world examples to get to grips with the powerful capabilities of AndEngine and GLES 2

Overview

  • Step by step detailed instructions and information on a number of AndEngine functions, including illustrations and diagrams for added support and results.
  • Learn all about the various aspects of AndEngine with prime and practical examples, useful for bringing your ideas to life.
  • Improve the performance of past and future game projects with a collection of useful optimization tips.
  • Structure your applications in a manner that provides a smooth flow from splash screen to level selection, to game play.

In Detail

AndEngine is a broad 2D game engine which allows game developers, both experienced and inexperienced, to develop games for the Android platform with ease. Don’t be fooled by the simplicity, though. As easy as it is to “pick up and go,” AndEngine includes enough functionality to bring any type of 2D game world to life.

The “AndEngine for Android Game Development Cookbook” contains all of the necessary information and examples in order to build the games as you imagine them. The book’s recipes will walk you through the various aspects of game design with AndEngine and provides detailed instructions on how to achieve some of the most desirable effects for your games.

The “AndEngine for Android Game Development Cookbook” begins with detailed information on some of the more useful structuring techniques in game design and general aspects of resource management. Continuing on, the book will begin to discuss AndEngine entities, including sprites, text, meshes, and more. Everything from positioning, to modifiers, and even tips on improving entity functionality with raw OpenGL capabilities. From here on, everything from applying physics to your game, working with multi-touch events and gestures, game optimization, and even an overview of the various AndEngine extensions will be covered.

The book has a widerange of recipes, from saving and loading game data, applying parallax backgrounds to create a seemingly 3D world, relying on touch events to zoom the game camera, taking screen-shots of the device’s screen, and performance optimization using object pools. If physics-based games are more interesting to you, there’s also a list of recipes ranging from controlling the world forces and calculating forces applied to bodies, creating destructible objects, and even creating rag-dolls.

Pong styled games were fun 35 years ago, but it is time to take your game to the next level with the AndEngine for Android Game Development Cookbook.

What you will learn from this book

  • Create your ultimate Android games with ease using recipes that take advantage of AndEngine’s powerful framework and extensions.
  • Make your games playable across a vast range of devices by implementing multi-touch, performance-optimizations, and accurate, screen-resolution scaling.
  • Construct a customizable, front-end framework that simplifies menu and level creation.
  • Use the Box2D extension to generate realistic, physics-based gameplay and simulations.
  • Take advantage of source code for a full-featured game built with AndEngine.
  • Make the most of vector-based graphics with AndEngine’s SVG extension.
  • Build animated, responsive Live-Wallpapers for Android’s home screen using the AndEngine’s Live-Wallpaper extension.
  • Control every aspect of interaction that players have with your games by managing the Android application lifecycles.

The book can be purchased through: Packt Publishing, amazon.comamazon.co.ukBarnes&NobleSafari Books Online.

(Note: The e-book/kindle versions come at almost 50% discount!)

Best Regards,
Nicolas


Jun 20 2012

AndEngine – GLES2 – Old and New News

Category: AndEngine,GLES2Nicolas Gramlich @ 05:23

Hello Community,

as you guys are probably already aware, since a couple of months, the current main active development branch is the so called GLES2 branch. He main difference to the old master branch, besides being actually in development and being much more awesome is that it is based on OpenGL ES 2.0. That means you can do all the fancy shit like FragmentShaders and VertexShaders, but only if you want to, since the public API is almost identical to the old OpenGL ES 1.0/1.1 based master branch.

To give you an impression of what you can do, have a look at the DreamZoo, first game based on the GLES2 branch that we here in Zynga released in early 2012:

Did you check how smooth the animals animate and how they can have a infinite variety of colors/patterns? It’s impossible to do using sprites animations, instead we did: this, which is impossible without VertexShaders and FramentShaders.

Switching a project from GLES1 to GLES2 is usually not too difficult, if you didn’t scratch the surface of AndEngine too deep (i.e. added custom object/rendering). If you decide so, you’ll be able to fix 90% of the compile errors, by organizing the imports. 8% of the remaining 10% will be common sense and for the final 2% will get resolved in the forums.

 

In fact if you really want to be on the cutting edge of AndEngine, where the cool kids are, you go for a spin-off of the GLES2 branch, the GLES2-AnchorCenter branch. The main difference of this branch is that the coordinate system has changed.

Important note: Rather sooner than later the GLES2-AnchorCenter branch will be merged into the GLES2 branch!

The coordinate system in the GLES2-AnchorCenter branch has its origin in the lower left. This was changed for multiple reasons:

  • It is the native OpenGL coordinate system. (I can save a few +- calculations here and there.)
  • It is the same coordinate system as cocos2d-iphone and cocos2d-x. (This eases porting efforts in both directions by a whole bunch!)
  • It allowed me to easily/efficiently write the AndEngineCocosBuilderExtension, which allows reading a format exported by CocosBuilder.
  • It just feels more natural for any side-scrolling game.

Another thing that changed in this branch is that the anchorpoints (rotatincenter, scalecenter, etc…) are now relative, from 0.0 to 1.0, instead of being absolute values. So in general, AndEngine got a little more cocos2d-like on this branch, which is definitely not a bad thing.

Best Regards,
Nicolas