Sign in to follow this  
gcsaba2

Isometic in OpenGL

Recommended Posts

Hi, I'm just making an isometric game in OpenGL. It's 2D so I mainly use OpenGL for 3D effects like a rotating cube, everything else is 2D. I'm having a labyrinth, with walls and corridors. The walls, for example, are simple pictures like this: This is all nice, but now I'm thinking that maybe it would be nice to have an option to rotate the map. I don't want to rotate so that it would be a FPS game, the view would still be from the top, but for example, if someone is hiding behind a wall, I just need to rotate the camera and see him. For this I would probably have to use 3D quads instead of the 2D images I have right now. OK, so my question would be, how difficult it is to implement this? I've already tried placing cubes next to each other, and found it almost impossible to do, since I have to calculate the Z axis etc. Is there some "easy" way to do this? Also this would mean I would have to have 3D models of all the players and monsters etc?

Share this post


Link to post
Share on other sites
>>This is all nice, but now I'm thinking that maybe it would be nice to have an option to rotate the map.

Rotating and isometric maps do not go well together. Sure it is possible as proven by for instance transport tycoon and its succesors. Ask yourself how often you've used that option and were there any benefits?

That isn't to say it is difficult. Apart from calculating the 3 extra views, next to the origional, your main problem is most likely the amount of extra graphics required for those extra views. The question is, are you up for that?

There are other alternatives to make important objects, like game characters visible in isometric games. You could for example create outlines around such characters or (partially) make objects transparent when characters are behind them. Technically perhaps a bit harder, but certainly not as timeconsuming as creating graphics for 3 extra views.

Your last question is somewhat confusing. Creating 3d models of the characters wont help you in this matter. Remember you're changing the entire view of the scene. Unless your whole scene is 3d (which would certainly help if you really want rotation), there is little or no benefit from having 3d characters over the 2d versions.

Share this post


Link to post
Share on other sites
Making the walls transparent seems to be a good idea, I could implement that.
I thought of the rotating thingie cause I seem to remember it in a lot of games. But you're right, they're true 3D games like Warcraft 3, that's why they have rotation.

Share this post


Link to post
Share on other sites
But I think most graphics don't need to be rotated. For example take your wall block or take a tree or a wooden box or something, they need not to be rotated, they can be just displayed in the same way as they are. Of course it's not "correct" but how many players would notice that or think that this would matter?

So the only thing you would have to do is to draw the array onto other positions. It's just like you would rotate the entire array and then draw it completely.

But then, if you have big buildings or other things that don't look basically the same on every side, you HAVE to do some rotated sprites of them. But I don't know your game, so you'd have to decide that for yourself :)

But I would also think about other ways, because in Sim City I always found it very difficult to find where things are located when I rotated the map ;) and then I just stopped rotating it :)

In The Sims, I think it was made with walls that can disappear nearly completely, so that you just can see a small piece of that wall on the bottom, and the rest is completely transparent.

Another idea would be (though it depends on the type of your game) to display arrows on top of the players, perhaps together with their name or energy etc. Or you could just display shadows, so as if the walls would be those asian paper walls :)

Share this post


Link to post
Share on other sites
You're right, I didn't rotate maps in SimCity either. Or in Tropico. But I could imlement that, seems like something easy to do.

In my game I will have a labyrinth where people can go around and shoot each other. There are also going to be NPCs that can also be shot. I'll add doors and special items, and that's it, so nothing too complicated.

I'm not sure if having an arrow above the character is a good idea. I want to have an element of surprise, which the player can avoid if he's careful.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this