1
\$\begingroup\$

I'm making a 2D dungeon crawler. The problem I found, it is that trying to animate the movement through the dungeon it is hard as hell. Then I thought that maybe a 3D dungeon will be better for this, but I don't like it. Are anyways to make a 3D game look like a 2D game? I mean...

There is some kind of shader o camera mode to achieve a 3D game look like this?

enter image description here

(Tough the game is in 3D, looks like it was a 2D game trying to be 3D).

\$\endgroup\$

2 Answers 2

1
\$\begingroup\$

Use an orthographic camera instead of perspective camera.

\$\endgroup\$
1
\$\begingroup\$

I believe you should still want to use a perspective projection instead of orthogonal one, as there is still a perspective in it.

There's some ways on how to achive it. One would be using a perspective projection and tweak the fov to achieve the narrow camera effect and maybe a low resolution framebuffer (OpenGL) and resize it to get a pixelated effect. Second would be using a ray casting method which is used for some old 3D games.

There should be more ways to achieve this though.

\$\endgroup\$
2
  • \$\begingroup\$ I will look at this. Raycasting is interesting too, but it doesn't seem to allow using textures on its walls. \$\endgroup\$
    – user74224
    Jun 27, 2016 at 19:14
  • \$\begingroup\$ @Tchangla Nah, texture is allowed. There is a stream video where Markus "Notch" Persson use this technique (or i think he did) to make a dunegon crawler which has textures for walls and floors. Edit: You can see that texture is allowed at the wikipedia link i provided at the feature and limitation part. \$\endgroup\$
    – Greffin28
    Jun 28, 2016 at 4:41

You must log in to answer this question.