Jump to content

[1.0.x] [V1.9f] Kerbal Foundries wheels, anti-grav repulsors and tracks


lo-fi

What to work on next?  

1,282 members have voted

  1. 1. What to work on next?

    • More wheels
      123
    • More tracks
      453
    • Rover bodies
      241
    • Landing gear
      137
    • Landing legs
      108
    • Something completely different
      193


Recommended Posts

51 minutes ago, damerell said:

How launch-y are we talking here? Vessel does a wheelie, or vessel fired into orbit? The former seems consistent with the idea that if you hit a bump at speed with the suspension bottomed out, bad things will happen.

As launchy as a Kerbal launchy thing. To be expected when the bump stops have zero spring. Needs fixing, but makes total sense if you think about it.

Link to comment
Share on other sites

Interesting to see some progress in an environment I recognize.  And yeah, bump stops = orbital vessel cannon is... Well, that'd be amusing, but highly counter-productive...

 

Although, if you could harness that, scale it back massively, and bind it to an action-group for a small "Jump" feature... That could be cool.  Although I'd love to see that reserved for walking legs.  Just one of my crazy ideas.

Link to comment
Share on other sites

On Saturday, October 29, 2016 at 1:27 PM, lo-fi said:

Right, I've found where it was all going wrong. @xEvilReeperx was spot on with the world axis. My code worked when the axis of the wheel objects aligned with the world (as in the test environment), but fell apart when it didn't at the equator. This affected the setting of the joint anchor offset, which caused all the problems. Of course, there are now a whole set of new problems to deal with, but at least things are ending up where they should, the craft isn't spinning out of control and the runway doesn't blow up. Happy days.

That is excellent news :)  Glad you got it sorted out and that it was a simple error rather than base incompatibilities between joints and KSP.

Please let me know if the friction stuff needs any further tuning for your immediate testing needs.  Can probably sneak in a bit of time to tweak things a bit if needed.  Or if there is anything else you would like a hand with, please just let me know :)

 

 

Link to comment
Share on other sites

Cheers. I can tell you it's doing nothing bad so far :)

I need to get the control input from the modified KF plugin going before I can really start testing the dynamics, but I'd say I'm quietly confident that it's going to be fine. I just need to find a neat, easy, robust way to delay everything starting up until rigidbody on the part is added, then I'll be able to really see what we've achieved! That's this evenings job, so I'll keep you updated. I ought to try the new colliders on a track unit too, before I get too carried away with the higher level stuff. 

Link to comment
Share on other sites

On the understanding that nobody even mentions the hype train, let alone boards it:

 

I haven't even started to mess around with the grip, torque and suspension settings to really finesse the dynamics and they'll need a little more respect from the plugin and config parameters, but this is looking extremely promising. @Shadowmage's grip model worked beautifully from the first moment I pushed the W key, as nice wide powerslides are possible with no hint of tripping over and flipping. I almost can't quite believe how well and realistically they handle.

 

Link to comment
Share on other sites

So glad to hear that the physics bits are starting to get sorted out; this mod has been one of my must-haves for quite a while.  The tracks were essential for my larger (400+ ton) rovers, obviously.  Also, I'm a big fan of multirole vehicles and one of my favorite designs was an electric prop-and-ion engine SSTO seaplane capable of flying itself to Laythe or Eve to act as an emergency all-terrain recovery vehicle; while early versions tried all sorts of pontoon setups, these repulsors made it MUCH more practical.

But this comment made me want to ask a question:

18 hours ago, damerell said:

How launch-y are we talking here? Vessel does a wheelie, or vessel fired into orbit? The former seems consistent with the idea that if you hit a bump at speed with the suspension bottomed out, bad things will happen.

 

So, the question is, how "launch-y" CAN you make things while still being controllable in normal situations?  I get that you've been trying to adhere to real-world physics as much as possible, but is it possible to make completely different styles of repulsor by taking advantage of these springiness issues?  Can you add an active "jump jet" mode to normal repulsors, to let them briefly get in the air?  One of the biggest problems I had with that multirole plane mentioned above was taking back OFF from the surface of the water, since I couldn't easily pitch the nose up while on the ocean, and this'd avoid that.

But take it further, and imagine three distinct styles of repulsor:

1> A "classic" kind that's ideal for ground-effect vehicles and/or a landing gear replacement for planes; more-or-less useless at altitudes of more than a few meters, and a "soft" deceleration curve (i.e., the repulsive force scales up at altitudes approaching zero, but not THAT quickly).  That soft curve minimizes strain on airframes, but is only really useful for things flying more-or-less horizontally at surface level as anything vertical would bottom out on the ground before its velocity zeroes.  It also isn't very suitable for vehicles floating across the surface of a craggy moon (like Mun), where the surface can go from horizontal to 45 degrees instantly, although it'd do fine on Minmus.

2> A straight lifting repulsor; less efficient, and with very little ground effect (force nearly independent of altitude), but resulting in a much higher altitude ceiling.  Basically, a helicopter-style setup that doesn't require rotors and such but that requires a lot more micromanagement to fly.  You could use these to reduce the need for large wing surfaces as well on engine-heavy aircraft, a la the Snowspeeders on Hoth.  It'd also be a way to reduce or replace parachutes on high-tech designs, but VTOLs are what I'd want the most.

3> At the other extreme, a "hard" repulsor to replace/supplement landing gear for large high-tech rockets with lots of battery power to burn at the end of their flights.  Huge energy drain (so unusable for general ground-effect use) but with as high of a deceleration in those last few meters as a pilot can safely survive, so that it'd be nearly impossible to catastrophically crash.  If you add an active jump jets to your Mun rovers to clear crater walls, this'd be what you'd use to safely land.  (My old wheel-based Mun rover kept throwing tires every time it hit a sharp bump at speed; this, combined with the first type, would avoid that.  And you'd have plenty of time to charge the batteries back up between uses, so the energy cost wouldn't be an issue.)

 

Similar concepts could be applied to old-fashioned wheels, I'm sure.  This'd help keep this mod's wheels distinct from the stock rover wheels.  But repulsors came to mind first, as they're the least constrained by reality...

Link to comment
Share on other sites

I guess some of that might be possible as we've got a much greater degree of freedom than ever before. Shadowmage's purely force based suspension springs could be abused modified for quite a bit of repulsors craziness. 

I'm just happy this stuff is working, and most importantly better than what we had before, kinks and edge-cases aside. I'm also very pleased that the new collider has nothing KSP specific and might well benefit far more games than KSP. 

Still a lot of discovery, work and testing to do. 

Link to comment
Share on other sites

7 hours ago, drtedastro said:

OK<

Interstellar drifting is back on!!!!!!

Great work.

cheers.

 

And regarding all of the nonsense fish stuff...

I know, you JUST had to do it for the HALIBUT...

argh. sorry.

Note that the drifting is mostly due to default/un-tuned friction parameters.  You can make those wheels quite 'sticky', even to the point of digging in and causing flips/rollovers.  I would say that the friction shown in the video is probably about 1/2 of what it will be when tuned.... so about like driving on wet grass or loose gravel.

Ohh... friction could also (potentially) be tuned on a per-surface basis to simulate the different friction coefficients.  The trick there is figuring out how to determine what surface friction coefficient should be in use, as I don't think the various PQS meshes are tagged in any sort.

 

6 hours ago, lo-fi said:

I guess some of that might be possible as we've got a much greater degree of freedom than ever before. Shadowmage's purely force based suspension springs could be abused modified for quite a bit of repulsors craziness. 

I'm just happy this stuff is working, and most importantly better than what we had before, kinks and edge-cases aside. I'm also very pleased that the new collider has nothing KSP specific and might well benefit far more games than KSP. 

Still a lot of discovery, work and testing to do. 

I've been very tempted to continue developing the force-based solution...for reasons.  Think it would be nice to have alternatives, perhaps even a config-level toggle for what suspension model to use.  But no matter, still a ways before I can work on it very much anyhow.

Either way, what you have working so far seems to be... well.. working well :)

Link to comment
Share on other sites

7 minutes ago, Shadowmage said:

Note that the drifting is mostly due to default/un-tuned friction parameters.  You can make those wheels quite 'sticky', even to the point of digging in and causing flips/rollovers.  I would say that the friction shown in the video is probably about 1/2 of what it will be when tuned.... so about like driving on wet grass or loose gravel.

Ohh... friction could also (potentially) be tuned on a per-surface basis to simulate the different friction coefficients.  The trick there is figuring out how to determine what surface friction coefficient should be in use, as I don't think the various PQS meshes are tagged in any sort.

I already upped it from the default - the wheels were behaving like repulsors! I'm looking forward to trying out some different values this eve, and will report back.

We have, for the dustfx stuff, a biome table that changes the dust colour depending where you are. This could be an excellent way of also changing the grip!

7 minutes ago, Shadowmage said:

I've been very tempted to continue developing the force-based solution...for reasons.  Think it would be nice to have alternatives, perhaps even a config-level toggle for what suspension model to use.  But no matter, still a ways before I can work on it very much anyhow.

Either way, what you have working so far seems to be... well.. working well :)

I actually think the force based solution may be better long term, but that it'll take a lot more development to get right. The joints were a quick win apart from my little fubar with the anchor point code. If you're happy to do so, I think we ought to continue for force based solution as a side project, as it's definitely promising. This is indeed looking very good - thank you for all your efforts :)

Link to comment
Share on other sites

5 minutes ago, lo-fi said:

the wheels were behaving like repulsors!

I would be happy with this. I just wanna make hovertanks again!

Is there any way to hack it into the game ourselves from the files on GitHub?

Edited by 0111narwhalz
Link to comment
Share on other sites

it's great to hear about mod progress @lo-fi !

FYI steeringCurve mechanics on stock wheels is broken since unity 5 implementation. I've tried looking up relevant code but I couldn't get it to work. So if there's any chance to implement it in your mod it would be awesome:)

http://bugs.kerbalspaceprogram.com/issues/12987

 

Link to comment
Share on other sites

2 hours ago, 0111narwhalz said:

Is there any way to hack it into the game ourselves from the files on GitHub?

Not really, as nothing in the game currently is coded for the new wheel colliders, other than the KF plugin code which is isn't anywhere near a state I'd wan to commit it, let alone let people loose with it.

2 hours ago, riocrokite said:

FYI steeringCurve mechanics on stock wheels is broken since unity 5 implementation.

Ah, that's something in the new stock wheel module. Thankfully not in any way relevant to KF :) It will be possible to convert stock parts (and indeed other wheeled parts) to KF just in config with no model re-export needed. I have a little partmodule that takes the settings from colliders in the model, strips them off and adds the new colliders instead. I wouldn't be able to get PartTools to export the new colliders in a part anyway, so that seemed like a sane, easy way of doing things.

Link to comment
Share on other sites

16 minutes ago, lo-fi said:

Hmmmm. Well here's an interesting thing... Even when my test rover is stationary, you can't swap away from flight, same as you can't when it's in motion.

This wouldn't have anything to do with the bug from 1.0.x, where if you hit pause everything would keep moving? Would it?

Edited by V8jester
Link to comment
Share on other sites

21 minutes ago, lo-fi said:

Hmmmm. Well here's an interesting thing... Even when my test rover is stationary, you can't swap away from flight, same as you can't when it's in motion.

Yeah, you need to manually set the part.grounded state every tick, as it thinks it is flying unless there are colliders in contact with the ground...

https://github.com/shadowmage45/KSPWheel/blob/master/VSProject/KSPWheel/PartModule/KSPWheelModule.cs#L584-L589

^^^ is the solution I used last time I was testing them in KSP.  It worked as far as the 'landed' check went.  It did not prevent leaving while under accelleration/motion though.

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • Create New...