I need a hover vehicle.. something that will remain between 1Meter and say 10 Meters above the heightmap... its a kinda space craft pod racer thing..
Currently I am just using a car with invisible wheels to give the effect but plane physics/handling would be better.. im looking for that wipeout kinda feel.
possible? ideas? thanks!
Possible to limit an aircrafts height above terrain
- Apache Thunder
- Posts: 1213
- Joined: Mon Oct 19, 2009 2:48 am
- Location: Levelland Texas, USA
- Contact:
Re: Possible to limit an aircrafts height above terrain
Problem with that is that the terrain won't always be the same distance from the water. Try creating obstacle objects (the same object class the barb wire fences use) and setting damage to zero so the new object(s) won't hurt soldiers:
Then addTemplate them to your vehicle(s). Of coarse make sure they have a collision mesh. They can be made invisible. The only thing that the obstacle class will collide with is with the terrain. Soldiers can collide a little bit. They can walk through the col mesh of the obstacle but it will slow them down a bit. The damage setting tells the game how much damage the soldier will get from touching it. Set it to zero like above so it won't damage them. It will still slow them down a bit. This of coarse won't matter much as soldiers would have a hard time moving around anyway if they were under a hover craft.
Also note PCOs like every thing else is unaffected by the obstacle object. So it should not interfere with the host vehicle's movement when it's not near the terrain.
Perhaps set up a custom material for the obstacle's collision mesh so that it has zero friction with the terrain.
You can also try putting some plane engines on it. Have it so when they turn on, they only provide enough thrust to lift the vehicle up a bit. Check out how my helos work. I added auto hover to them so that they only drop just a tad bit when no thrust is provided. You can probably tweak that so it doesn't drop at all and any thrust used doesn't add to the engine thrust so it won't fly off or anything when thrust is applied.
Code: Select all
ObjectTemplate.create Obstacle Example
ObjectTemplate.geometry ExampleMesh
ObjectTemplate.damage 0
ObjectTemplate.createInvisible 1
ObjectTemplate.hasCollisionPhysics 1
ObjectTemplate.hasResponsePhysics 1
ObjectTemplate.addToCollisionGroup c_CGProjectiles

Perhaps set up a custom material for the obstacle's collision mesh so that it has zero friction with the terrain.
You can also try putting some plane engines on it. Have it so when they turn on, they only provide enough thrust to lift the vehicle up a bit. Check out how my helos work. I added auto hover to them so that they only drop just a tad bit when no thrust is provided. You can probably tweak that so it doesn't drop at all and any thrust used doesn't add to the engine thrust so it won't fly off or anything when thrust is applied.



I have cameras in your head!