Tagged Questions
12
votes
2answers
646 views
How do you handle uneven tiles while rendering a tile map?
Here is what I want to do with my tile map that I am unsure of. As you can see the top walls are way larger then the bottom and side ones (this is also an issue with my corners which are odd shapes ...
9
votes
5answers
511 views
Increasing the probability for similar tiles to generate next to each other
I'm working on a tile map system, which insofar looks like this (green is grass, air is white, stone is grey, and blue is water):
It uses a simple random number generator so that there's a 45% ...
8
votes
2answers
2k views
How do I tackle top down RPG movement?
I have a game that I am writing in Java. It is a top down RPG and I am trying to handle movement in the world. The world is largely procedural and I am having a difficult time tackling how to handle ...
5
votes
2answers
2k views
Tiled based map collision detection problem
I'm working on a tile-based Mario clone. I have implemented the tile based collision method from the tutorial http://www.tonypa.pri.ee/tbw/tut05.html.
This works all fine when walking and falling. ...
5
votes
1answer
780 views
Method of terrain in a 3d RPG
I am working on a RPG using the JMonkey engine. While I was conceptualizing the map, I realized I would have a problem with the terrain.
My problem is this: I want to have a click to move interface, ...
3
votes
1answer
2k views
Scrolling tile system
I know this is a common question, but I can't find an answer to it that isn't written using a huge game library sadly.
I'm trying to write a scrollable tile system, which allows the user to move ...
3
votes
1answer
338 views
More smaller maps among which player can travel
I am developing 2d game, where maps are tile based, small about 20x20 tiles and player can travel between a lot of maps (in my game rooms) like this. The maps are connected sometimes verticaly and ...
3
votes
2answers
415 views
Slick2D Isometric TiledMap Rendering Problem
I created a Tiled Map using the Tiled Map Editor. In the Editor it looks like this:
Desired State
In my java program it looks like this:
Actual State
My java code is:
public class Game extends ...
2
votes
2answers
810 views
Tile based map and collision; getting stuck
I'm trying to make my character move around a tile map with collisions. Everything works fine except for one thing. I show you a picture with the problem:
http://i.stack.imgur.com/ZWI7x.jpg
That is, ...
2
votes
2answers
180 views
How to stack units in a tile based game?
I'm trying to make it so that no more than 5 units can be stacked on a tile. I have a Tile class that creates each tile's preferences. Should I store the units in an array or arraylist in this class?
2
votes
3answers
821 views
Java tilemap not working, Think it has something to do with my image rendering
Hey can someone help me out, I've been trying to fix this for about 2 hours now, and I'm a noob when it comes to game programming and Java(only been reading and programming with it for a week now, ...
2
votes
1answer
2k views
Java - 2d Array Tile Map Collision
How would I go about making certain tiles in my array collide with my player? Like say I want every number 2 in the array to collide. I am reading my array from a txt file if that matters and I am ...
2
votes
1answer
584 views
Storing Tiled Level Data in J2ME game
I'm developing a J2ME game which uses tiled backgrounds for the levels. My question is how do I store this tile information in my game. At the moment it is stored as an array; with each number ...
2
votes
1answer
515 views
Slick2D Tile Based 'Fog of War' Blurring Problem
I'm working on my first Java Game and I have run into a little problem I'm hoping to get some help with. I'm using Slick2D displaying a tile based map, and I'd like to know how I can created a ...
2
votes
0answers
606 views
Collision Detection on floor tiles Isometric game
I am having a very hard to time figuring out a bug in my code. It should have taken me 20 minutes but instead I've been working on it for over 12 hours. I am writing a isometric tile based game where ...
1
vote
3answers
305 views
For the handling of buildings on a tile-based strategy game, what aproach should I use?
On a tile-based game of the strategy genre, which allows the player to place buildings over the terrain tiles, there are multiple approaches that can be taken for handling such situation.
The ones ...
1
vote
3answers
269 views
(int) Math.floor(x / TILESIZE) or just (int) (x / TILESIZE)
I have a Array that stores my map data and my Tiles are 64X64. Sometimes I need to convert from pixels to units of tiles. So I was doing:
int x
int y
public void myFunction()
{
getTile((int) ...
1
vote
2answers
353 views
How can I create tiles that scale to multiple resolutions?
I am trying to create a multiplayer version of the popular Flash game N in Java. However, I'm not sure how to create a tileset that will scale up. Are the tiles for N pre-drawn or are they defined ...
1
vote
1answer
1k views
Drawing hexagonal grid on Android
I'm trying to draw a hexagon grid in my Android application. I don't want to reinvent the wheel here so I'm looking for some frameworks/libraries or just some basic ideas about how should one do this. ...
1
vote
2answers
397 views
Level Creating Help
I am making a little 2d overhead RPG type game just for fun. I have almost all the basic stuff set up, but I just need a little help on level creation. I can already make a level and place each tile ...
1
vote
1answer
272 views
How to render a tilemap efficiently? [duplicate]
I'm using this code to load a tiled map, composed of 1000x1000 32x32px tiles:
map = new TmxMapLoader().load("levels/xyz.tmx");
camera = new OrthographicCamera();
camera.setToOrtho(false, ...
1
vote
1answer
241 views
Saving a list of points into a text file
I recently posted a question about this, but was not really sure where to go. I've gotten some progress, and have generated some simple noise here:
http://pastie.org/5408655
That works well enough ...
1
vote
2answers
311 views
Collision checking problem on a Tiled map
I'm working on a pacman styled dungeon crawler, using the free oryx sprites. I've created the map using Tiled, separating the floor, walls and treasure in three different layers. After importing the ...
1
vote
2answers
525 views
Java: Tile-based Collision Detection with Rectangles
There are a few tile-based collision detection questions out there, but none seemed to suit my need.
I guess I really would like to know why this method for collision detection isn't working.
It ...
1
vote
1answer
248 views
How do I determine if a tile is a slope based on the tile image?
In my game, every tile is a 32x32 texture. All the slopes are a 0 - 45 degree angle. I would like to determine, at the time I load the tile, if the is sloped by examining its texture/bitmap data. How ...
1
vote
2answers
654 views
2d very large tile based game, zoom and pan considerations
what's a sensible way of implementing zoom and panning for my game?
each tile is very large, 100,000 x 100,000 pixels, with some objects possibly being only a single pixel at maximum zoom (small ...
1
vote
3answers
412 views
Compressing 2D level data
So, I'm developing a 2D, tile based game and a map maker thingy - all in Java.
The problem is that recently I've been having some memory issues when about 4 maps are loaded. Each one of these maps ...
1
vote
0answers
693 views
TileMapRenderer in libGDX not drawing anything
So I followed the tutorial on the libGDX wiki to draw Tiled maps but it doesn't seem to render anything.
Here's how I setup my OrthographicCamera and load the map:
camera = new ...
0
votes
1answer
281 views
Java - Finding distance between player and tile in array
What is the best way performance wise to do this? When I click a tile I want it to get the distance and if I am close enough I can interact with the tile. One way would be to find the tile by doing ...
0
votes
1answer
275 views
Please help me with my 2D isometric tile picking [duplicate]
Possible Duplicate:
How to convert mouse coordinates to isometric indexes?
Okay, I apologise in advance if I make no sense here.
Basically, I've got a simple application that takes in a ...