Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

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, and have the player move in increments of 1 world unit (wu). This is actually rather reminiscent of a tile based engine, but in 3d. While making the world map, do I need to make an object made of the world geometries, and load the one object, or would it be better to build a map out of the necessary tiles, using a file to tell the engine how to build the map (similar to 2d tile games)?

I might also add, the game isn't going to use heavy collision detection or real time physics, which is why I thought a tile based "pass-abilty" system might work.

Would loading that many objects for a tile be too much as far as memory goes? What if I make a single object, constructed of tiles by a definition file, and just make the player move in 1 wu increments, giving the illusion of "tile-based"?

I'm assuming that a combination of any of these might work, it's just that I don't have any prior experience making a system like this and would like some opinions on the most efficient method of doing what I'm trying to do.

share|improve this question
1  
If they click 2+ wu/tiles away from where they are, are you going to move them 1 wu/tile in that direction as best you can figure or to the closest complete wu/tile they clicked on? –  James Mar 30 '11 at 21:50
    
@James: If they clicked 2 wu away, the idea is that it detects the closest wu "tile" to the coordinates of the click, and moves them to that wu tile. So in that case, they would move two "squares" in that direction. –  Lord Zero Mar 30 '11 at 21:54
add comment

1 Answer 1

up vote 1 down vote accepted

Not sure about JMonkey, but for most 3D engines having lots of different objects has a negative impact on performance (not memory). That's because every object requires a separate call to draw it. If that's the case with JMonkey too, you'd be better off having one, or few, bigger objects. You might even build them from tiles on-the-fly.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.