#7 Owe, legs and flaps
- launch mount by Owe with 20 clamps and nice staircase
- Starship legs by Steve Mattinson
- Starship flaps, fully functional with automatic pitch control and aero drag
- complete rework of ship controls and internals (more below)
- ship and booster landing can now be initiated from an arbitrary direction
- ship and booster can swim
- some smaller tweaks on raptor engines, catcher and the UI
- you can zoom in now with right mouse and I also changed the time scale keys to not change it accidentally when putting negative numbers somewhere
- small quitting screen
- changed all masses in rigidbodies (and corresponding scripts) to resemble kg instead of tons, so the moments of inertia should be more realistic now
- (experimental) the landing data are saved to the game's data folder where also the settings.ini is
Oof, this took much longer than hoped, again . I have to allocate more time for work on the controls stuff. It's always such a head scratcher. I thought, I could just quickly add the legs to the ship for this update after I had the launch mount already in. I even had a version of the clamps already set up with Unity's articulation body feature last year. So I thought, I just need to switch the ship from rigidbody to articulation body as you can not mix them. Cannot be too hard, can it? It can!
The main problem was that you cannot just get the forces on the joints in Unity with articulation bodies, at least not in Unity2021. It's still a relatively new feature in Unity. So I had to update to 2022, which is only beta version. Luckily the update went fairly smooth. Only one major thing broke. So, why do we need the joint forces? To break things of course! I wanted to have the flaps break off when the force on them is too high. However, there is some strange bug currently with the articulation body setup which made me skip this feature for the time being. Luckily it worked for the legs. So, the legs (blades) can break off when the load is too high. Nice! Also, I use the force on their joints to deform the blade meshes. It's not working perfectly like this, but gives at least somewhat the impression as if they would flex under load.
Next issue with articulation bodies was that the drag doesn't work quite the same as with rigidbodies. So I decided to go directly to full aero drag for the ship. Another avenue for producing bugs - yay! However, I don't want to spend time on this here. In the end it was just interesting to see that I actually got best results with a coefficient of drag of 0.44 for Starship body and 0.66 for the flaps. Even though they are constant values, it's just at low velocities which don't change that much. So it should be somewhat accurate.
For the booster I decided to change to the same system in the next update as I had enough of the work on the ship.
Now, after having functional flaps, I tried to set up pitch control, which itself worked quite well. However, there was still the issue that the gimbal controllers for Starship didn't quite work as intended when it was flying horizontal. This was already the case in the last update, where I just solved it by having a fixed landing approach. But now the controllers had to do the work. The problem is, it seems, that it is just not possible to always get the correct rotation of the object when using euler angles. At least I tried different versions, but nothing worked, or I am too dumb. When I read up about it, I found some papers about quaternion controllers, but nothing which I could easily implement. So, I skipped it for the time being as I had spent already too much time on this problem. In the end I made some hacks so that it works mostly with the current setup. The position control is still a bit problematic though. But I deemed it good enough for my needs.
Anyway, the ship has much more realistic controls and behaviour in general now. So for the next update, I will update the booster as well to articulation bodies and also to the model so that it fits to the launch mount.
I also looked into the High Definition Render Pipeline very briefly and I might change to it in the future. It seems the transition might not be that difficult. Just for fun, I tried setting up ray tracing and it was pretty easily actually. I got the result in the attached video within a day!
Get Starbase Simulator
Leave a comment
Log in with itch.io to leave a comment.