Moving on all sides of a 3D tunnel
by Great_Gamer · in Technical Issues · 02/14/2008 (7:29 pm) · 2 replies
Hi all,
I am making a 3D tunnel racing game using the Torque game engine. The object of the game is to control a vehicle which can move on all sides of the tunnel and shoot enemies as they pass by. The vehicle moves forward down the tunnel at a continuous rate, and it can rotate around the sides of the tunnel. If you cannot envision the game, you can try playing this simple flash version:
http://www.cartoonnetwork.com/games/action/toonami/tunnelrush/index.html
I have two questions about how to implement this game:
1) How can I make the vehicle stick to the sides of the tunnel DIF object? Should I turn gravity off for the
vehicle, or is there a way to make the ship "fall" in different directions?
2) How can I make the vehicle move down the tunnel in a "straight" direction? (i.e. the ship always moves
down the tunnel at a constant rate and cannot turn around. It can however rotate about the sides of the
tunnel as in the above flash game)
The work that I have put into the game so far consist of changing the demo programs to use my vehicle and tunnel objects, and I can move my vehicle around inside the tunnel, but now I have hit a brick wall with regards to making the vehicle stick to the sides. If anyone can provide answers to these questions, I would be very grateful.
I am making a 3D tunnel racing game using the Torque game engine. The object of the game is to control a vehicle which can move on all sides of the tunnel and shoot enemies as they pass by. The vehicle moves forward down the tunnel at a continuous rate, and it can rotate around the sides of the tunnel. If you cannot envision the game, you can try playing this simple flash version:
http://www.cartoonnetwork.com/games/action/toonami/tunnelrush/index.html
I have two questions about how to implement this game:
1) How can I make the vehicle stick to the sides of the tunnel DIF object? Should I turn gravity off for the
vehicle, or is there a way to make the ship "fall" in different directions?
2) How can I make the vehicle move down the tunnel in a "straight" direction? (i.e. the ship always moves
down the tunnel at a constant rate and cannot turn around. It can however rotate about the sides of the
tunnel as in the above flash game)
The work that I have put into the game so far consist of changing the demo programs to use my vehicle and tunnel objects, and I can move my vehicle around inside the tunnel, but now I have hit a brick wall with regards to making the vehicle stick to the sides. If anyone can provide answers to these questions, I would be very grateful.
#2
Also, I will check out the Polysoup Collision resource when I get the chance. Sounds like it's pretty useful.
02/18/2008 (12:08 pm)
Thanks for the response Lee. I've checked out the Stupid Vehicle Tricks resource, and I have gotten the wheeled vehicle to work in my game. However, I would like for my vehicle to strafe side to side if possible. Would you know how to get a hover vehicle or flying vehicle to stick to walls?Also, I will check out the Polysoup Collision resource when I get the chance. Sounds like it's pretty useful.
Torque Owner Lee Latham
Default Studio Name
To make the Tube, I doubt you can get DIF to give you the vector resolution you need. That's why I applied the Polysoup Collision resource (search for "christmas polysoup"), which let's you use arbitrary DTS meshes for collision. It's freaking wonderful. I also use that heavily in my game. Actually, completely--I have no DIF's, and I'm oh so very happy.
The other bit will come in time.