Android is an operating system for mobile devices developed and maintained by Google, Inc. This tag should contain specific programming questions about Android.

learn more… | top users | synonyms

5
votes
2answers
2k views

Implementing fog of war in opengl es 2.0 game

Hi game development community, this is my first question here! ;) I'm developing a tactics/strategy real time android game and I've been wondering for some time what's the best way to implement an ...
6
votes
1answer
1k views

Android game loop's effect on cpu/battery usage - unexpected results

I will try to keep this question as concise and as readable as I can. I recently came across an odd problem with my Android game that I'm developing. It's an openGL ES 2.0 game and initially I was ...
0
votes
1answer
660 views

AndEngine drawing 2D tiled game field

I'm in process of developing simple android puzzle game. I decided to choose andEngine as an engine for my game. In my game I have a gameField [][] array, which represents a game field, where each ...
8
votes
3answers
886 views

Collision detection problems using AABB's

I implemented a simple collision detection routine using AABB's between my main game sprite and various platforms (Please see code below). It works great, but I'm now introducing gravity to make my ...
2
votes
2answers
2k views

AndEngine Sprite position

I had noticed the AndEngine a few days ago, and I tried to create basic game with a few Sprites.Sure, the engine makes the development process much more easier.However I found the sprite lacking a ...
0
votes
1answer
3k views

Android cocos2d removing a sprite after animation

I have an object going across the screen with an animation using the following code: CCSpriteFrameCache.sharedSpriteFrameCache().addSpriteFrames("ninjastar.plist"); CCSpriteSheet projectileSheet = ...
0
votes
1answer
909 views

Drawing more that one quad with only one glDrawArray call…?

Edit After initially thinking that my sprite batch test was faster than calling each sprite individually, it appears that is not the case!! :-( With a single set of GL calls for a each sprite, I can ...
2
votes
1answer
476 views

Android Virtual Pet Gameloop

Hello I'm looking for a bit of advice in which way is the best to proceed creating my applications 'gameloop' - It doesn't want to be a game loop in the truest sense since I'm not really rendering any ...
-3
votes
1answer
1k views

Which programming language is used to develop an app in corona?

What is Corona & Which programming language is used to develop an application in corona? What physics Engine is corona using? and any other information that is absent in their site?
2
votes
1answer
647 views

Moving sprites based on Delta time - consistent movement across all devices with different resolutions

This is the formula I am currently using to move my sprites across the screen: Examples below only deal with X coordinates to keeps things as short as possible. Initial variable declarations: float ...
2
votes
2answers
272 views

Correct utilisation of gameloop (Android)

When using a gameloop like (much simplified)............ updateLogic(); render(); How does one perform 'single' operations? I mean, things like triggering sounds (which will only be played once), ...
1
vote
1answer
1k views

How would one render dynamic vertices in OpenGL ES 2.0 like in a 3D modeling program?

Is there an easy way to re-render dynamic vertices in OpenGL ES 2.0 so that one could, for example, make a modeling program? I understand how to make a dynamic vertex array, but what I don't ...
7
votes
4answers
4k views

Sprite Animation in Android with OpenGL ES

How to do a sprite animation in android using OpenGL ES? What i have done : Now I am able to draw a rectangle and apply my texture(Spritesheet) to it What I need to know : Now the rectangle shows ...
0
votes
1answer
2k views

Using Unity3D from within Eclipse

Is it possible to use Unity3D from within Eclipse? I've seen that I can import a Unity3D project into Eclipse, but I cannot seem to be able to access classes such as Terrain or Ray. I don't know if ...
3
votes
1answer
148 views

Saving data across same game in multiple devices [closed]

Is there any library or something that works like iCloud but for different operating systems (Android, IOS, Windows Phone) that allow me to save game data to cloud and open the game data from another ...
3
votes
2answers
260 views

Formula for converting ratio of current device to target device

I am designing my (Android/OpenGL ES 2.0) app on one device and want it to run all all other devices while keeping the screen ratio of the development device (so the image doesn't stretch / squash), ...
1
vote
1answer
755 views

Centering GLViewport position within physical screen

I'm developing my app on one device and want it to display at the same ratio on all other devices. Currently what I have is 'image 1' in my image below - the game fits perfectly onto my development ...
12
votes
1answer
739 views

When and why is a Pool class needed to hold objects?

I've been studying opengl es and an example I saw was using a "Pool" class to keep track of touch and keyboard events. Could someone please explain how and why a pool class is needed. From what I was ...
1
vote
1answer
447 views

GLES2.0 3D Android game performance and multi threading the update?

I have profiled my mixed Java\C++ Android game and I got the following result: As you can see, the pink think is a C++ functions that updates the game. It does things like updating the logic but it ...
4
votes
1answer
244 views

How can I get pre-release reviews of my mobile game?

My iOS and Android game is at its last stage of development. Is there a way for me to get pre-release reviews from people? Or maybe from the press? How should I proceed?
2
votes
1answer
2k views

Game Development at iOS, Android and PC with OpenGL ES

I'm beginning iOS apps development, and my aim is to make games to launch on App Store. But I want to know if it's possible to program a game on Xcode with OpenGL ES (C++ game logic), integrate it on ...
0
votes
1answer
239 views

Real cash gambling app

I am making a cash game like deal or no deal for use as an android app, using adobe software. The idea is player wagers 50 pence through Paypal plays the game wins, say, £10 pounds and then cash out. ...
5
votes
4answers
2k views

More profitable: Android apps or Flash games?

Which market (that of Android games or that of Flash games) is more profitable and will give me a better chance of success? Where can I find the relative market shares of these markets, globally?
-2
votes
1answer
216 views

Spawning enemies outside of view [closed]

I'm trying to create a 2d shooter for Android. How do I spawn enemies "above" the screen, so that they "enter" the game screen instead of spawning at the top of it? I think I need to make a game ...
2
votes
1answer
5k views

How do I implement a score database in Android?

I making a 2D game for Android using OpenGL-ES technology. It is a space shooting game where the player shoots enemy ships. I want to keep a track of score for the amount of enemy ships destroyed ...
-1
votes
1answer
861 views

Ways to achieve path finding on android [closed]

I have spent two weeks on this task and its to no avail,i hope your expertise can help me. I want to create a simple set of activities that allow the shortest path to be calculated between two points ...
-2
votes
1answer
274 views

Game code structure using openGL / Android [closed]

My game will have 3 activities (splashscreen, options menu and main game). As it stands, each is a separate activity with it's own activity class and GLSurfaceview class. Is this structure the right ...
0
votes
3answers
2k views

Where to run logic update in openGL ES?

Using Canvas with Surfaceview I had a run() method where I would essentially do the following: onDraw(); update(); Where onDraw method would do the rendering and update would update all my game ...
2
votes
1answer
704 views

How to create a 2D ocean effect in cocos2dx and box2d for iphone, android, windows phones

Currently my game needs a top ocean view. Can this ocean effect done using box2d? or should I dive into write my own physics (liquid/water simulation). Ideas and suggestions are welcome.
3
votes
1answer
477 views

OUYA Developer Kit throws various errors on start

I followed these instructions for Mac OS X using an existing IDE (shell + text editor) instead of the Eclipse ADT thingy. I activated “Use Host GPU”, and installed Intel HAXM. Installing the ouya-...
2
votes
1answer
2k views

Separate renderng thread in Android (OpenGL ES 2.0)

I'm used to mainly working with the Canvas SurfaceView API on Android and have recently been learning openGL ES 2.0 With canvas I know that surfaceView gives you the ability to start a new thread to ...
1
vote
1answer
465 views

Powers of 2 textures in Android 2d games?

I've read a lot about the importance of using powers of 2 png's for textures when using OpenGL ES. However, how does this relate to Google's own documentation regarding the resizing of graphics for ...
2
votes
2answers
3k views

Developing a 2D Android game on Unity - Pros and Cons [closed]

Depending on your experiences, if you have created a 2D game on Android using Unity, was it painful? Have you ever said "I wish I have used X instead of Unity!"? Tell me the Pros, Cons and the name ...
1
vote
1answer
5k views

Show view over existing view in same activity

I am newbie Android developer, and I am starting out with a simple Sudoku game. The problem I am facing right now is that I have my game showing on a dedicated Activity, which is displaying a custom ...
1
vote
2answers
11k views

How can i use A star pathfinding algorithm

How would i implement an A star algorithm for a game that i'm making on the android in java? i'm looking for a pre-made A star API in java with classes and methods to call. i don't want to have to ...
2
votes
2answers
1k views

How can set vibration option with my game in android? [closed]

I am using AndEngine to develop an Android game and I want vibration to be triggered when an enemy hits a player. How can I implement this into my game?
3
votes
2answers
4k views

Android: Loading bitmaps without premultiplied alpha (OpenGL ES 2.0)

Is this possible? To load textures in non-premultiplied format (Straight alpha?)? My game has 1 or 2 images which have semi-transparent pixels and I need to be able to fade them in and out but this ...
-2
votes
1answer
99 views

Android game adaptative game flux [closed]

¡Hi mates! Two friends and I are planning to code a game for Android using AndEngine GLES 2.0 Anchor but we have a concept problem, we need the game to be as adaptative as possible, I mean, if we make ...
1
vote
1answer
470 views

Adding local wireles multiplayer mode to my Android game

I've created a little game on Android. Now, I want to add a multiplayer mode which works with bluetooth or WiFi, so you can play together with other "smartphones" in your neighborhood . Which is the ...
1
vote
1answer
295 views

Switching from OpenGL ES 1.0 to 2.0

I have been developing an Android app using OpenGL 1.0 for quite some time using a naive approach to rendering, basically making a call to glColor4f(...) and glDrawArrays(...) with FloatBuffers each ...
11
votes
3answers
13k views

Best solution for multiplayer realtime Android game [closed]

I plan to make multiplayer realtime game for Android (2-8 players), and I consider, which solution for multiplayer organization is the best: Make server on PC, and client on mobile, all communition ...
4
votes
2answers
8k views

Drawing a circle in OpenGL ES Android, squiggly boundaries

I am new to OpenGL ES and facing a hard time drawing a circle on my GLSurfaceView. Here's what I have so far. The circle class public class MyGLBall { private int points=40; private float ...
-1
votes
1answer
973 views

Why doesn't onSurfaceCreated ever run in this code?

I create my game element this way in my activity: public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); mGame = new Game(this); mGame.bootstrap(); ...
-1
votes
1answer
175 views

How to Fix Some Portion of bound camera?

I want to add Progress bar with my game to display life of player but when i move down through DigitalOnScreen Control the black bar that i want to display is not displayed there. I want to display ...
5
votes
4answers
1k views

Better way to generate enemies of different sub-classes

So lets pretend I have an enemy class that has some generic implementation and inheriting from it I have all the specific enemies of my game. There are points in my code that I need to check whether ...
1
vote
0answers
82 views

Android opengles how to use glunproject

How to use glunproject in my android app? I have the following parts in my engine: A projection matrix A view matrix for the camera A model matrix for each of the objects in my world. This matrix ...
4
votes
1answer
2k views

Google Play 3rd Party Payment Allowed?

Does Google allow 3rd party payment solutions to be enabled in developers' apps (i.e., Paypal, carrier/SMS payment), especially in countries where Google Checkout isn't present? Or does this violate ...
0
votes
1answer
391 views

Develop a 2d isometric mobile game on Flash [closed]

I'm building a game on Flash that will run on web/Android/iOS. The game is 2d isometric.I heard that developing mobile apps on Flash sucks and the graphics looks just awful.It'd be quite uncomfortable ...
1
vote
1answer
116 views

Can't call method out of a timer. Why? [closed]

I have another problem i can't solve by myselve. My situation: I have four FrameLayouts in LinearLayouts. I color them, set Layout hight and width at wrap content and just change the minwidth to ...
1
vote
1answer
913 views

Get back or delete an existing OpenGL object, then change it and draw at new. How?

With OpenGL i'm drawing for example a circle. Can i take this drawn circle back out of the window and change something and then draw it back on the window? Or can i /have to delete it and then draw ...