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

0
votes
1answer
13 views

Should I use one GLSurfaceView.Renderer for each part of my game?

I am creating a small platformer-like game for Android using OpenGL. The game has 3 main screens/states: Main menu screen Level selection screen The game screen Currently I use a ...
0
votes
0answers
10 views

HTML5 game - Difference in layouts in webview of app and webpage

I have created a working prototype of an HTML5 game and tried to convert it into an android app using PhoneGap. My issue is that the layout of the screen is bigger in case of the webview of the app. ...
-4
votes
0answers
28 views

I want to upload my game [on hold]

i want to upload my game and want installs for it Kindly help me out in this , so that my talent would be shown to all of the world
0
votes
0answers
28 views

Paint objects cause lower FPS by time

I'm creating squares on XML layout with Paint, you can see how exactly bellow: public class PaintObject extends View { Paint paint; public int x; public int y; public ...
0
votes
1answer
17 views

LibGDX Rotate 2D image with touchDragged() event

Objective: to rotate an image in the center of the screen with movement equal to left or right touchDragged event. Right now I have a basic Stage that is created and adds an actor (centerMass.png) ...
0
votes
0answers
34 views

Removing no longer used paint out of screen

I have Paint, like this: Paint paint = new Paint(); paint = new Paint(Paint.ANTI_ALIAS_FLAG); paint.setStyle(Paint.Style.FILL); paint.setStrokeWidth(5); paint.setColor(Color.BLUE); and I'm drawing ...
0
votes
0answers
30 views

LibGDX works well on android 4 and very bad on android 5 and 6

I have a problem with my game. The game is made with libgdx, scene2d and box2d and it uses an AssetManager. I tested this app on all my devices and here it is the results: Galaxy S3, android 4 ...
0
votes
0answers
25 views

POST & push for turn-based network?

Can you create a viable two player turn-based networking implementation using only REST API for outbound and push for inbound data? If a game is comprised of, on average, 30 moves, is it a bad idea to ...
1
vote
1answer
76 views
+50

Android OpenGL Sprite Component Pattern

Ok so I have a 2D OpenGL project that was originally a class assignment, and now I am using it to experiment with and to broaden my knowledge. Originally, I had been using the Normalized Devices ...
0
votes
1answer
23 views
17
votes
2answers
4k views

How can I implement a “disable ads” purchase in my game?

I would like to add a "no ads" service to my game such that ads can be removed with a single payment. How can I implement this correctly? If I just save the fact that the service was paid for locally ...
0
votes
0answers
16 views

Is it necessary to publish the game App on store in a way work Autocomplete Deep linking

App indexing , Deep linking and Auto complete feature in my game , so Whenever i open the Game it shows the recorded pages of the Game in Auto complete of the Google App , i.e of-course the Start of ...
0
votes
0answers
5 views

Why music doesn't play when I export the apk on Gamemaker on Android?

I have made a simple app with buttons and when you press any of them a specific sound plays. I tested that on Windows and the sounds work properly. I also tested that on Android and it also works, but ...
0
votes
0answers
15 views

Direction buttons for Android game

I am new to Android development and i am trying to develop a game. I have a basket which is used to catch different objects which are falling down randomly. Now to catch those objects, i am currently ...
2
votes
0answers
8 views

How to implement app indexing plugin, by using Prime31 UnityPlayerActivity?

I am implementing the App indexing plugin, using Prime 31 UnityPlayerActivity which is implemented by overriding Androinds onCreate, onStop methods etc, but when I use this keyword in onCreate method ...
0
votes
0answers
25 views

HorizontalScrollView with multiple views in one “frame”

I have ImageButton, with TextView and ImagaView inside it. I have six of these. So I want to implement them into HorizontalScrollView. I remember I had one HorizontalScrollView with images some time ...
1
vote
1answer
31 views

Libgdx black rectangles problem

I'm working on a game for Android using Android Studio with LibGDX in Java. I recently found a weird problem when closing and reopening the game. When I first open the game, it works fine. If I click ...
0
votes
0answers
36 views

unity UI buttons staying highlighted after touch

i have a touch dpad giving me some weird issues i havent experienced in older versions of unity. after building the game and running on android i am noticing that some touches to the dpad are leaving ...
0
votes
3answers
67 views

LibGDX simple button with image

I want to make two image buttons (play, restart) in my main menu screen but I dont know how to do it. I tried this: Texture playTexture = new Texture(...) Image playImage = new Image(playTexture) ...
2
votes
0answers
102 views

Bilinear filtering by sampling corners of a texel

I'm trying to do bilinear filtering in texels to get the convoluted value of a 3x3 block. Implemented as below: offsetx = 1/width offsety = 1/height Fragment shader: "varying vec2 ...
0
votes
1answer
26 views

libgdx collision on moving Rectangle with other Rectangle

I'm making a soccer game where you touch the screen and the player shoot the ball to the touched position with the objective of scoring goals when it hits the goal. The player is just a Sprite and the ...
0
votes
1answer
22 views

libgdx sprite placement

Im making a soccer game where you basically have to shoot the ball to the goal and the ball goes to where you touch the screen. Im having an issue with the ball though, when the ball spawns on the ...
1
vote
1answer
26 views

How to know when Android OpenGL Context has been preserved?

I am implementing a pause menu for my game in Android. If the activity pauses and then resume, It lose the OpenGl context. However if you use setPreserveEGLContextOnPause(true) it MAY preserve the ...
-2
votes
2answers
30 views

i want to make four letter one word game. i have designed xml but getting problem in main activity java. [closed]

i want to make four letter one word game. I have designed xml using four imagebutton and randomly load from string array, but how to code entire java file. i am beginner to programming.
0
votes
0answers
10 views

Libdgx and Overlap2D export settings for Android

So I have a problem when exporting assets from Overlap2D to Android Studio project location. When setting up libgdx I set the project to be for desktop and android and selected Overlap2D extension. ...
0
votes
0answers
9 views

Is there a specific file in the NDK that I need to link Unity3d to?

This is Android Development. I'm having issues with Unity saying that Android NDK isnt installed. I gave it the file path to the NDK directory. Its the exact NDK it told me to install (Unity). Do i ...
0
votes
0answers
28 views

Unity Android character controll with UI Buttons

So I'm trying to find a good tutorial which will explain how to controll character in 2D game when button is clicked (left, right, jump button). All the tutorials I've found are outdated and not ...
0
votes
1answer
41 views

Unity5 build won't run on android 2.3.3

I made a game using one of the Unity tutorials on their site and now would like to run on my phone (LG P500). But when I try to run it on the device, it says "Failure to initialize: Your hardware does ...
0
votes
1answer
46 views

Sprites blurred in Unity (filter mode set to point)

I'm new to Unity and I'm developing Android game. When I connect my phone with Unity Remote and launch game, all textured are blurred and they look awfull. Did some research and set Filter mode to ...
0
votes
0answers
59 views

How to update projectile trajectory point?

I am a new game developer, I am making a game, but I have a problem, I don't know how I can update my trajectory point in OnDraw method. Could anyone please help me? Thank you! Here is my code: ...
1
vote
0answers
53 views

Libgdx stops all sounds when there are lots of sounds

I'm making a 2D game for Android using Android Studio with Libgdx in Java. I have a class, called SoundPlayer, which holds an ArrayMap. The key is the name of the sound file and the value is the sound ...
0
votes
1answer
46 views

Simplifying Object Factory

I'm making a game for Android using Libgdx with Android Studio in Java. In my game, I have a class called ObjectFactory which has a method createGameObject(int objectType) which receives an integer ...
5
votes
2answers
613 views

Main game objects as static

I'm making a game for Android using Android Studio with Libgdx in Java. In my game there are main object like Screen, ObjectFactory, SoundPlayer, Painter (Responsible for drawing) and a few more. 'til ...
0
votes
0answers
20 views

AdMob Banner appears 960x150 instead of 320x50 in libGdx - what's wrong here?

I am a bit helpless with this strange effect from AdMob. AdView is instanciated in code and so is the relative layout and libGdx view. View view = ...
0
votes
1answer
46 views

How create/draw faded circles in Java

How do I create some circle - like the one on the image - in Java, and in various colors? I would like to make more of these circles to fly from specific position to random direction.
0
votes
2answers
109 views

Java RPG class implementation (design pattern ?)

For my school project I'm making a little NFC based game on Android. The concept is simple, on each phone you create a character and you can fight with other people through NFC. The character will ...
0
votes
1answer
32 views

LibGDX Textfield - Text Overflow - Not Wrapping

In my app's registration screen, the textfield is not wrapping text as I expected. Notice in the above image, the email field is not containing the text. I have set the size of the textfield using ...
0
votes
0answers
14 views

Android Studio:ive desing my game to fit 1080*1920.how to scale it to different sizes? [duplicate]

all the bitmaps in my app are scaled for 1080*1920,so when i run my game on a smaller or larger screen it breakes...i know i can manually scale each one of the values to fit the screen size,but it ...
0
votes
0answers
74 views

Standard file path for pictures in Android

I created a png file from an RenderTexture and I can save it to the standard directory in Windows. Now I want to do the same in Android. How can I get the standard picture path?
0
votes
0answers
39 views

LibGDX - black bars, FitViewport and drawing background

actually I'm creating game in LibGDX and i have few problems. I'm trying to solve resolution and aspect ratio problem by using FitViewport but i want to dispose black bars which occur when resolution ...
0
votes
1answer
74 views

GameMaker android support

Game-maker asks me to install android sdk api 13 for it to work. I opened the SDK Manager so that I install it, clicked at API 13 and I couldn't be able to click the "install packages" button. I ...
0
votes
0answers
50 views

Unity3D - Android build has no Internet Access

I'm having trouble connecting to the internet in an Android build. I created a simple program that checks if there is an connection. Also I set in 'Edit > Project Settings > Player' the Internet ...
0
votes
0answers
18 views

Physics2D lag on increased timescale Unity

I have been working on an infinite runner kind of game in which i am trying to implement a speedup powerup kind of thing . Something that will allow me to boost through the levels at a high speed I ...
0
votes
0answers
25 views

Is this how I use activities in android studio?

I'm a student who is just stepping into android game development. I'd like to create a text-based RPG game for android and started to learn about Android Studio (I think Android Studio is enough ...
0
votes
0answers
14 views

Move ball through a direction angle in android canvas [duplicate]

I am building a simple game in android. I am successful in first step where I draw a ball in canvas in touch point. Now I am trying to move it from an initial point A (center) through the touch point ...
0
votes
0answers
53 views

Share Image on Android Application from Unity Game

I've captured screenshot in my game when player dies. I've following code to capture screen shot. RenderTexture rt = new RenderTexture (800, 600, 24); MainCamera.targetTexture = rt; ...
1
vote
0answers
45 views

libGDX text doesn't appear in TextField

A game I'm working on has libgdx's TextField. They work fine in every instance I've used them, however on a play tester's phone he says no typed text appears in the box until enter or space is ...
0
votes
1answer
22 views

How do I know if the ad is open while the use pressed the back button?

I am trying to reward a user a point whenever they watch/look at an ad. I give the user the reward whenever they watch the ad. However, the user earns a point even if they go to the ad and click back: ...
1
vote
1answer
65 views

Draw wireframe models for Gear VR app: Unity or Eclipse?

I want to create a 3D Android app for Gear VR that does/lets me do the following: Read an input file with a bunch of coordinates of points (including information about how they should be connected) ...
1
vote
1answer
77 views

libgdx - Texture not appearing sometimes

When I run the App the Ball moves sometimes downwards, but sometimes its not moving. I dont change anything on script. What I want is the ball should come from top outside of the screen, but when its ...