All Questions
58 questions
0
votes
0
answers
33
views
How does Cube Slam uses the camera for gameplay?
Cube Slam is a unique multiplayer game that allows players to compete against each other in a face-to-face format simply by sharing a link. The game utilizes the camera for interactive gameplay, ...
0
votes
1
answer
90
views
LWJGL2 Camera Movement Stutter
I'm having quite some trouble with camera stutter in my LWJGL2 game. The stutter only occurs when moving the camera. When it stands still, the scene is rendered smoothly. I could verify that by ...
0
votes
0
answers
55
views
How to add level-by-level game camera following in 2D java game?
I've been working on my first game recently, and I've built a player tracking camera that works great, but my goal for the game would be to have a camera that is fixed for each area that the player ...
0
votes
0
answers
271
views
LibGDX TiledMap Rendering
For the life of me I cannot figure out why these lines keep appearing on my rendered tiled map. Every time I resize my libgdx window, the tiled map creates lines all across the screen.
I have adjusted ...
1
vote
0
answers
38
views
Parallax camera is not independent from the stage camera
I have a weird camera problem that I can't solve! I add my actors to the main stage and use its camera too. Actors are constrained within the screen viewport.
I also have a second camera that I use ...
0
votes
1
answer
394
views
How do I zoom in and out in a fully tiled based game
I am currently developing a tile based game in Java and trying to add the option of zooming. I do the zoom by reducing and enlarging the tiles, but the problem is that it creates spaces between the ...
0
votes
0
answers
76
views
Java clicking on tiles detection
I am making small isometric game, where I want to do something when user clicks a tile. I can simple do it by mouse location, but I want to be able for zooming and moving camera. It will be 2D game ...
0
votes
2
answers
157
views
How can I calculate all the tiles visible to a camera in 2D?
I am creating a basic tile-based 2D game ~mostly from scratch in Java, however all I need is pseudo-code for how this could be achieved. My problem lies in the fact that my world (stored in ...
0
votes
1
answer
49
views
Extending the camera vs CameraHelper class vs camera field
I am following an eBook called "Learning Libgdx Game Development"
In it, the author implements a CameraHelper class that implements ...
0
votes
1
answer
308
views
Face culling all faces that cannot be seen [duplicate]
I'm working on a simple 3d game using the Processing Java environment. I want to optimise my code so I can draw many many 'objects' (the world is made up of many different shaped objects that live ...
0
votes
2
answers
123
views
Why is the Tilemap not fitting the screen?
I have a background image which I made it in tiled map editor of width 40tiles and height of 8tiles.When I run the game the tilemap bounces with the player and I can see the black portion of the ...
3
votes
2
answers
1k
views
How to make the camera follow the player in Libgdx?
In Play class I have the viewport of game height=320 and game width=240unitswith camera cam. I have set the camera(cam) viewport width to 10 and viewport height to 7.I have another camera hud whose ...
0
votes
1
answer
76
views
Box2D and OrthographicCamera working incorrectly
I'm trying to build a simple game where TileMapRenderer renders a labyrinth, a ball moves in it and camera follows it. I'm currently having the following bug:
For some reason, the game renders the ...
0
votes
1
answer
2k
views
LibGDX - Move camera not working
I'm starting with LibGDX and I loving it so far, but I have found some troubles and I'm getting a little frustrated. I've searched a lot for a solution and tried many things, but nothing seems to work....
1
vote
2
answers
3k
views
libGDX - orthographic camera and world units
I've followed the advice in this post to handle world/screen coordinates, but I'm getting results I don't quite understand, as I'm not terribly good in math.
So, when I use this code:
...