Jump to content
  • Advertisement
Sign in to follow this  
Meshboy

Door FPS

This topic is 3807 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, i have a FPS game where i use Polygons for collision detection. If you hit any wall wiithin the polygon you slide along it, it works with both convex and concave corners. How do i best implement doors in my game? Move and rearange the vertex of my polygons or create a new "Master" Line that the player always should slide on if there. How would you people solve this problem, need good ideas before start coding... tnx!

Share this post


Link to post
Share on other sites
Advertisement
I would probably separate the door from the polygon soup of the static geometry and handle all such objects separately.

Static geometry: Black
Door mesh: Red

-------
| |___________
| |___________
| |
-------


Door mesh can now be rotated upon collision, for example.

-------
| |__________
| __________
| |
-------


This is just one idea amongst many I'm sure [smile]

Share this post


Link to post
Share on other sites
I plan to do this using the physics engine, based on what I saw in a demo application for NewtonGD. The player is represented by a rigid body, an ellipse, and is able to physically push doors open. The door is a rigid body attached to the scene using a hinge joint.

Another option is that when the door has been touched by a player, it will open itself. You could also go with the system in Rainbow 6, where the player can open the door manually, when close enough to it. IIRC an icon appears, and you can then open / close the door, using the mouse wheel, and get just enough space to poke your gun through and waste some bad guys. It was an interesting dynamic that I haven't seen in any other games.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!