User Experience Stack Exchange is a question and answer site for user experience researchers and experts. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have an top-down perspective android game that uses opengl-es. In the game, the user moves around a cylinder to navigate obstacle courses. I have implemented a jump effect (user flicks the screen up to initiate), and I want to have some bottomless pits that must be jumped over.

I'm looking for some ideas about how to draw this given the top-down 2d perspective. My question isn't about the specific implementation (I can handle that), but just what are some ways to depict a pit in 2d?

share|improve this question

closed as off topic by Charles Boyung, jonshariat, Phil, James Crook, JonW May 10 '11 at 9:57

Questions on User Experience Stack Exchange are expected to relate to user experience within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

Maybe try also... – Tony the Pony May 8 '11 at 21:22
Or – Charles Boyung May 9 '11 at 0:27
i like how programmers exchange referred me here, and now you're referring me elsewhere – farm ostrich May 9 '11 at 7:20
Yep... sorry for the redirecting but it really isn't a UX question. I'd go for – Phil May 9 '11 at 7:55
its totally a user experience question. this is all about perception. – farm ostrich May 9 '11 at 15:25

The most obvious thing that springs to mind is a something that fades from the colour of the ground (or something equally visible) to black at the centre. As long as your ground isn't black they should stand out and once the player falls in one they'll remember ;)

share|improve this answer

Texture, or rather a change in the graininess of the texture over distance can be a strong visual cue for slope or depth. You could have a texture around the entry of the pit that originates from the surrounding graphics and as the gradient of the surface increases into the pit the texture becomes finer and darker in color. This will give the impression of depth into the screen. As ChrisF said, for a bottomless pit the obvious color for the center would be black; in this case the texture would decrease in size until it got fine enough to blur into black.

An advantage of using texture over just a color gradient is that you can more obviously show the pit looming up from a distance from an oblique angle view point as the texture provides a stronger cue for shape than color does. However you did say that your domain was a 2D one only.

Another advantage of texture gradients is that they can be used to give an impression of motion which you would not get from a uniform color gradient. Rerendering texture elements on the screen over time in the appropriate locations will give the impression that the whole surface is moving. Should your hapless game character venture too close to the pit it would be nice to show some movement of the pit surface as they plumet into it.

There are many other Monocular cues for depth perception that you could also explore.

The other thing to think about, which is really cool with the latest devices with forward facing cameras, is the possibility of developing a [no-glasses ] 3D effect (maybe in a future version of your game). This will allow the game to obscure the edge of the pit from certain viewing angles which would give a very strong illusion of pit-ness.

share|improve this answer

I agree with ChrisF. I recently downloaded a game from my iPad entitled "Falling Fred". The whole game revolves around you dodging obstacles as you fall to your death. Here's how they treat the perspective and the hints at distance.

share|improve this answer
Link: 403 - Forbidden – Phil May 9 '11 at 7:03

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