Battlezone Universe

Battlezone Universe => Battlezone 2 => Maps and Modding => Topic started by: TheJamsh on July 19, 2009, 02:12:28 PM

Title: ground-hugging physics
Post by: TheJamsh on July 19, 2009, 02:12:28 PM
does anyone have any?

Im trying to create a ship that will stay virtually spot-on its setAltitude value. The ship basically needs to hug the ground, rather than being able to ramp off of terrain and basically 'get air'

obviously the vehicle is a [HoverCraftClass]
Title: Re: ground-hugging physics
Post by: mrtwosheds on July 19, 2009, 02:27:42 PM
Increasing its mass should cause it to fly less, but of course it will also cause it to knock other units about harder.
Decreasing the jump thrusters will also help, but might cause it to get stuck on hills more.
Title: Re: ground-hugging physics
Post by: TheJamsh on July 19, 2009, 03:51:07 PM
I was thinking about adjusting the damping values really.
Title: Re: ground-hugging physics
Post by: Red Devil on July 19, 2009, 04:19:31 PM
velocForward = 20.0 // [40]
velocReverse = 20.0 // [15.6]
velocStrafe = 20.0  // [20]

accelBrake = 36.0
aiAccelDrag = 46.0
accelDragFull = 16.0 // 6.0 // 0 = nothing
accelDragStop = 22.0 // how fast it stops once hands are off controls [5.9]
accelJump = 0.0
accelThrust = 5.0  // acceleration [25.0]  [32.0]

LIFT_DAMP = 0.0
LIFT_SPRING = -10.0
Title: Re: ground-hugging physics
Post by: TheJamsh on July 19, 2009, 06:02:59 PM
vely naice :)
Title: Re: ground-hugging physics
Post by: BNG Da BZ Fool on July 19, 2009, 11:58:18 PM
Would the same apply to water vessels? I've made a ship, but even though I set the altitude to like
-1.25 it still hovers above the terrain and water. I set to accel jump really low along with accel thrust. Is there a way to make water based ships float evenly with the water? Or would it be more practical to make the ships look more like hydra-foil types? Something like the stealth ship in the James Bond movie Goldeneye. Tanks, BNG.
Title: Re: ground-hugging physics
Post by: Clavin12 on July 20, 2009, 12:02:52 AM
Is your ship supposed to traverse only on water.
Title: Re: ground-hugging physics
Post by: BNG Da BZ Fool on July 20, 2009, 12:25:57 AM
I guess not as the odf is a hover class, but I don't think BZII directly supports water vessel types. It seems to get non-standard models to work right you have to monkey around with existing settings to improvise possible solutions. I'd like make a few other water vessels like an aircraft carrier, fast attack boats, etc. They are doable, but quite a bit of in game testing slows down development to get the physics to do what you to get them to do. I find the geometryScale very handy for keeping the model size manageable in my 3d modeler; otherwise they're so large in the 3d workspace it's a challenge editing them efficiently. Large long ships are kind of neat to create; especially the aircraft class where secondary 3d models like air units are displayed on the carriers deck to simulate proper visual effect.
Title: Re: ground-hugging physics
Post by: mrtwosheds on July 20, 2009, 12:48:05 AM
As far as I know only TV has made functioning water only craft, submarines. They are water only because the custom dll makes them explode if you drive them out of the water.
Title: Re: ground-hugging physics
Post by: Nielk1 on July 20, 2009, 07:55:15 AM
The custom DLL works by height. I requested (and thank GSH got) the ability to detect water in DLL, so now we can all do it in a more dynamic way. Picture, aircraft under water, hovercraft that ignores water (falls though) with no thought above water. PERFECT. Just a quick DLL swap.
Title: Re: ground-hugging physics
Post by: TheJamsh on July 20, 2009, 05:25:02 PM
you can get hovercraft under-water without .dll. set AccelJump to -6 or something, drive over water and hit 'e'. You will sink and stay put.
Title: Re: ground-hugging physics
Post by: BNG Da BZ Fool on July 20, 2009, 07:41:15 PM
Not true with the subs on other maps (the exploding must be specific to TV's DLL) as I've placed them out of water without them destructing. They're just APC class craft which seem to just land under water or on land. I just want my water vessels to glide even with the terrain or water like a normal ship would do perhaps even slightly submerged but still mostly above the water level.

Unfortunately, many maps have little or no water at all, so the use of water vessels is quite limited and only a few current maps like seabattle can make any use of water vessels. I guess one solution would be to modify existing maps to include like rivers with a few bridges placed at key points to allow land based units to get across the rivers. Considering that bridges are destroyable objects this would create problems for tracked units or an advantage for water based vessels.

Anybody remember Command and Conquer? Quite similar to BZ, but with some odd twists, and quite a array of land, water and air based units. 
Title: Re: ground-hugging physics
Post by: Nielk1 on July 20, 2009, 08:04:51 PM
Quote from: TheJamsh on July 20, 2009, 05:25:02 PM
you can get hovercraft under-water without .dll. set AccelJump to -6 or something, drive over water and hit 'e'. You will sink and stay put.

My point was I can get a unit with aircraft physics underwater, and dead thrust hovercraft above, like a real sub.

That and just make a hover unit ignore water and only have any speed when on water if you want to have a quick and dirty sub. Yes, you can do BOTH those things in TA5.
Title: Re: ground-hugging physics
Post by: TheJamsh on July 21, 2009, 07:22:57 AM
Actually you're right... i forgot about all those ex-constants. I did my dodgy one in PB4a i think, hell it may have even been PB3.
Title: Re: ground-hugging physics
Post by: bb1 on July 22, 2009, 03:57:09 PM
As a matter of circumstance since it was brought up here, does a negative accelJump still put you under the terrain if held too long?
Title: Re: ground-hugging physics
Post by: TheJamsh on July 22, 2009, 05:50:37 PM
no, but it will pull you under water tiles if the are above ground level.
Title: Re: ground-hugging physics
Post by: AHadley on July 25, 2009, 08:02:36 PM
And how do you get yourself back up again? In, for example, ivbsub_tj?
Title: Re: ground-hugging physics
Post by: TheJamsh on July 25, 2009, 08:38:11 PM
I dont remember :P, i dont think you can, but i was planning to make a booster weapon to raise me back up

that was made back in the olden days of modding :P. I think the best idea would have been to use morphtankclass...
Title: Re: ground-hugging physics
Post by: Rocket on July 25, 2009, 11:49:23 PM
Quote from: AHadley on July 25, 2009, 08:02:36 PM
And how do you get yourself back up again? In, for example, ivbsub_tj?

I believe you would automatically "Float" back up to the top...
Title: Re: ground-hugging physics
Post by: TheJamsh on July 26, 2009, 12:01:11 AM
No you wont, the beauty is you will stay put, wherever you are  because of the - altitude as well.
Title: Re: ground-hugging physics
Post by: Rocket on July 26, 2009, 01:14:53 AM
Hmm, is it possible to impliment a negative effect the (E) button does, maybe make it (X) or one of the lower case letters, and it could be used for going underwater, ducking down low, doing stunts, and falling faster, I'm sure you could come up with a whole bunch of things you could use that for. :-)
Title: Re: ground-hugging physics
Post by: AHadley on July 26, 2009, 10:29:31 AM
If the engine supports it that is.
Title: Re: ground-hugging physics
Post by: TheJamsh on July 26, 2009, 01:04:55 PM
It would have to be a code change.
Title: Re: ground-hugging physics
Post by: AHadley on July 26, 2009, 02:22:56 PM
So no, unless GSH is in an extremely good mood :lol:
Title: Re: ground-hugging physics
Post by: bb1 on July 26, 2009, 04:05:50 PM
Vertical strafe is a dream of mine in this game.
Title: Re: ground-hugging physics
Post by: AHadley on July 26, 2009, 04:08:14 PM
Would be fun. Jamsh, you're the 1.3 tester :P