A game library which enables cross-platform game development in Java, with support for Android development and desktop development. It makes use of OpenGL for portability.

learn more… | top users | synonyms

0
votes
1answer
516 views

Communication between Box2D and libGDX Stage (Scene2D) running in separate threads

I'm making a physics based 2D game using libGDX and Box2D. I want to move the execution of the simulation out of render thread. I use immutable messages and the BlockingQueue to pass the information ...
0
votes
0answers
13 views

Automated GUI testing for libGDX [on hold]

There is Selenium - a tool, which emulates browser and makes automated UI testing of a web application possible. For a native Android applications - it's Robotium. Does similar tool exist for testing ...
1
vote
2answers
1k views

Why does resizing my game window move and distort my rendering?

I'm starting to make a game, and the first screen I've made is a very simple loading screen with some centered text. On starting it up, the text is nicely centered: Then I resize the window, and I ...
0
votes
1answer
11 views

LibGDX Table.drawDebug deprecated?

I am following the "Learning LibGDX Game Development" book to make a simple game. I am in the menu creation section where we create a stage and render it with debug borders The book says to use ...
1
vote
0answers
27 views

How do I fill a shape with a texture in Libgdx?

I am making a 2D racing game. I want to fill the area of the ground object with a texture. I have the shapes of the ground (a Box2D shape). If I make images of the ground with textures, it uses a lot ...
0
votes
0answers
33 views

How can I share high scores on Facebook from a desktop libgdx game?

The Android version of my game can share scores on Facebook. How can I do this on the desktop version? Is Gdx.net.openURI (“http://graph.facebook.com/me/feed”); sufficient?
-2
votes
0answers
37 views

How to create a game animated guide? [on hold]

I want to show users before starting each level how to use it. So I want to make an animated tutorial that shows how to select textures, by animating the movement of a cursor, which is in the form of ...
0
votes
0answers
13 views

a model with Libgdx [on hold]

We have a project in class to make an rpg game with Libgdx. For the first step we have to make the model for our game,, by model i mean : Homepage for the game:(when the player can choose the ...
0
votes
1answer
26 views

Collision detection Libgdx

I'm trying to implement Collision detection using Rectangles for my game but can't seem to get it to work. Bullets are updated when pressing space every frame so they move across the screen. ...
0
votes
1answer
48 views

Libgdx desktop windows resize

I have tried to make game with libgdx I want to create 3x3 grid in the middle of screen I ran the desktop project, it seems that not much problem at all, but if I resize the windows the 3x3 grid move ...
0
votes
0answers
16 views

LibGdx Exception

Here is the exception: Exception in thread "LWJGL Application" java.lang.NullPointerException at com.mygdx.test.excav.game.WorldRender.renderTest(WorldRender.java:34) at ...
0
votes
2answers
96 views

LibGDX how to change animations

I have a Player Class and i have 3 different Animations for it. I can render them perfectly but i don't know how to change from one animation to another. For exmaple i have 3 animations, one for ...
0
votes
0answers
9 views

Libgdx Scene2d shows White screen when executed

package com.Darth377Apps.DeepShadow; import com.badlogic.gdx.*; import com.badlogic.gdx.graphics.g2d.*; import com.badlogic.gdx.scenes.scene2d.*; import com.badlogic.gdx.scenes.scene2d.ui.*; import ...
0
votes
1answer
32 views

Box2D pixel to meter conversion

I have a game that was written in pixels and now I want to change it to meters like(box2D do). How I need to do that. I have wached a lot of tutorials and all they have some SCALING FACTOR but when I ...
0
votes
0answers
8 views

Libgdx: ModelInstance texture is not rendered on Java8

I have project based on opengl, libgdx framework. It's impossible I think, but when I switch my project from Jdk1.7 on Jdk1.8 I have problem with rendering model's texture. I have no idea how language ...
1
vote
1answer
818 views

Two pass blur shader using libgdx tile map renderer

I am trying to apply the following technique: blur effect using two pass shader to my libgdx game using the OrthogonalTiledMapRenderer. The idea is to blur the background wich is also a tilemap but ...
1
vote
1answer
32 views

How do I find the shape of Tiled's circles or ellipses in libGDX?

I created a level in the 'Tiled Map Editor' and loaded it into my libGDX game. I can easily transform almost all objects into Box2D objects (although this problem is not Box2D specific), but I have ...
0
votes
1answer
14 views

Predicting circle-circle bounce vector when aiming one at another

I am making a game with libGDX (with box2d) in which you drag and aim one circle body at another then release to fire. I would like to be able to predict the path of the second circle based on the aim ...
0
votes
2answers
80 views

get View from LibGDX for Android

I am making a LibGDX app, and I need to get the view to put to an Android app. Here is the code to get the view: package jangkoo.game.shadowfiend.android; import ...
-1
votes
2answers
81 views

Libgdx, find Vector3 direction

I am using Libgdx along with Bullet physics. I have a vehicle moving. I would like to use a ray from the vehicles origin and in the vehicles forward direction. How can I create the forward Vector3 ...
0
votes
0answers
22 views

Bullet Physics for Collision Detection and Smooth Response

I'm creating a game using LibGDX, and to prevent the need to spend lots of time writing collision detection code I've decided to make use of Bullet Physics, simply for collision detection and not for ...
0
votes
1answer
27 views

LibGDX Bounding Rectangles

I'm creating some rectangles surrounding my sprites for my player and bullet class to detect collisions with the overlaps method in Intersector class of LibGDX. I have a question: When I instantiate ...
2
votes
1answer
288 views

Setting uniform value of a vertex shader for different sprites in a SpriteBatch

I'm using libGDX and currently have a simple shader that does a passthrough, except for randomly shifting the vertex positions. This shift is a vec2 uniform that I set within my code's render() loop. ...
1
vote
2answers
127 views

How to create Whirlpool/Vortex effect?

Im trying to make a Vortex effect on a Circle Body that is a Sensor. I've been looking for this and all examples i look for are in C++ or Objective C and i dont seem to translate them well. when my ...
0
votes
0answers
5 views

Problem with the method unproject of the class OrthographicCamera of LibGdx [closed]

cam is a object of OrthographicCamera v3 is a object of Vector 3 in the next line the play closes in android, in the PC it works good, I don´t which is the problem cam.unproject(v3); Thanks very ...
0
votes
0answers
13 views

Android LibGdx Assets Sizes/Newbie Questions [closed]

I'm trying to get started with a game idea for Android. I've got everything planned out, yet I don't know where to begin. I know what the player, and enemies will look like, as well as the ...
0
votes
0answers
15 views

Leaderboard in game, android, LibGDX [closed]

I am developing android game using LibGDX engine (java) , I want to put leaderboard (top scores) in it . I can't find any tutorial that explains how to do it using Google play services , any ...
0
votes
0answers
37 views

Make a smooth curved terrain from chain shape [closed]

what have i tried: Vector2[] vs = new Vector2[6]; vs[0] = (new Vector2(-50, 7.3f)); vs[1] = (new Vector2(-18, 7.3f)); vs[2] = (new Vector2(-10, 2)); vs[3] = (new Vector2(-5, 4)); vs[4] = (new ...
0
votes
0answers
4 views

GdxRuntimeException uiskin.atlas

I have problem when trying to use the uiskin.atlas from github/libgdx. I've downloaded(cloned) it from libgdx.git but it just doesnt work. I get the following error: ...
2
votes
1answer
501 views

Libgdx - IsometricTiledMapRenderer and light shading

I am wondering if there is any way to simulate light shading in Libgdx using an IsometricTiledMapRenderer. Here is my code to draw an isometric map, it's able to be moved around with the mouse and ...
0
votes
1answer
25 views

Why does my libgdx app just display the badlogic.jpg instead of my start screen?

I have been looking at example libgdx games. It looks like https://github.com/libgdx/libgdx-demo-cuboc is the closest thing to a game I would like to make. I am able to download, compile and execute ...
0
votes
0answers
18 views

libgdx y axis rotation (card flip)

I am a complete new user to libgdx and am looking to use it to write a simple card game. I want to be able to flip my cards over to reveal them, in the same way as this example from Google shows. ...
0
votes
0answers
13 views

Using fonts in Scene2D GUI

I'm learning how to use Box2D and Scene2D together. I'm trying to create a Sprite class that combines a Box2D body with a Scene2D actor. Before I can do this I need to set up the environment I plan to ...
0
votes
0answers
29 views

Problem with changing font color in libgdx

I recently noticed that my version of libgdx was way out of date, so I updated from version .9.something to 1.4.1. I copied files for the project I'm working on over into a new project generated with ...
2
votes
0answers
32 views

Drag And Drop in libGDX (Target and Source)

I'm trying to put together a drag and drop system in libGDX with the help of DragAndDrop class. I have the typical system in which you can drag something into a box. So far it is working all dough I ...
1
vote
1answer
78 views

How can I implement a camera like the one in RotMG?

RotMG, an MMO top-down shooter, takes on a unique 2d-3d style, and has an intriguing camera; The game is obviously 3d, not simply isometric, and if you play the game and turn on camera rotation you ...
0
votes
0answers
19 views

Change a vertices and display corner of a polygon

I'm currently building a level editor for my game and i'm having some trouble on how to change vertices of a polygon. Basicly i searched the web trying to figure out how to update the vertices of a ...
1
vote
2answers
75 views

Random undirected graph generation

I would like to generate graphs randomly, like this: I have found that Box2d maybe can do it to me. But I do not know, how to use it, so how can I generate bobies after world initialization?
0
votes
0answers
14 views

Cant Set Image Origin in Table Cell - LibGDX

I am having real issues with my Actors when placed in table cells. I would like to set center Origin to allow me to tween the scale around the center. I am aware that the Table is responsible for ...
0
votes
1answer
267 views

Libgdx actor bounds are wrong

The Actor's boundaries are not centered at the ButtonText but I used the setBounds() method. The higher the Y position is, the less centered is the boundary. The weird thing is that i only created ...
1
vote
1answer
124 views

Design pattern for animation sequence in LibGDX

What design pattern to use for sequence of animation that involve different actor in libGDX. For example I am making a game to choose a wolf from a group of sheeps. The first animation played when the ...
3
votes
2answers
487 views

How do I crop a camera's viewport?

I'm making an Android game using LibGDX. I would like to render a cropped version of the camera's viewport. Here's an original camera view (in 3ds max): I can get the same view in LibGDX without ...
1
vote
1answer
146 views

Libgdx 2D Game, Random generated World of random size, how to get mouse coordinates?

I'm a noob and English is not my mothertongue, so please bear with me! I'm generating a map for a Sidescroller out of a 2D-array. That is, the array holds different values and I create blocks based ...
0
votes
1answer
34 views

Card game - creating card Listener

I am making a card game where there are 21 cards on hand and 2 options from where user can draw cards to his hand and throw a card from hand. I am new on game development and I'm following the ...
0
votes
0answers
12 views

In libgdx, how do I get the intersection of a ray with a model instance?

I am using LibGDX trying to use raypicking to pick a point on a Mesh. I have two methods for this that don't seem to work quite right: /** * @param ray * @param intersection The vector to store ...
0
votes
2answers
1k views

SpriteBatch being drawn outside of Stage?

Currently working on my first game, though running into some problems with libgx and screen aspect ratio. What I have is a Stage which contains things like menu buttons etc, and the rest of the game ...
-1
votes
1answer
43 views

How to mirror a texture in libGDX

Is it possible to rotate my sprite in LibGDX? public class Flame { private static final int FRAME_COLS = 6; private static final int FRAME_ROWS = 1; private Animation flameAnimation; private ...
2
votes
1answer
60 views

How can I get the instantaneous volume level of a sound at a particular playback point?

How can I go about getting the current volume output of an audio file in libGDX? By that I mean of the actual file at its current play position. Essentially I want to write my own version of a plugin ...
0
votes
1answer
327 views

What is the approach of creating an image puzzle game with libgdx

I would like to create a game which consists of taking a random image, slicing it up into some number of pieces (according to a selected difficulty) and letting the player solve the puzzle. I've ...
1
vote
1answer
49 views

Libgdx - gesture dection

I have made a card game, and have two methods that sort the players hand. sortHandBySuit(); sortHandByValue(); I would like one method to be called when the user slides their finger from left to ...