Jump to content

[0.21] Hooligan Labs - Airship, Submarines and More


Recommended Posts

What's it's weight?? That is the ultimate factor that determines the answer you need.....

Ok, I'll attach mechjeb and get back to you

elind21: you need sufficient tanks to displace the same volume of water as your ship's mass in tons. (eg, a 60t ship must have 60m3 of displacement (60 of the small tanks)).

Shouldn't the structural fuselage have more buoyancy than the equivalent size liquid fuel tanks?

Also it does float without the submarine ballasts attached, and I have used a similar design with the carrier parts in 0.20 where if there was insufficient buoyancy you would sink and be destroyed deeper than ~20m.

Thanks to all the help, I will see what I can do.

Also any ideas on how to have a plane take off while a boat fires a missile at it? Is there a plugin or something? I tried using mechjeb, but it says that I cannot switch vessels in an atmosphere.

Once again thanks

Link to post
Share on other sites
i have tried different tanks, more tanks, less tanks, even adding airship parts! but to no avail. it sinks as soon as it hits the water, PLZ PLZ help me

That is a really cool design! Check this video out for how he got his heavy vessel to float (by adding many of the largest part to the side):

Link to post
Share on other sites

For stability, you want the center of buoyancy above the center of mass. Since it's not often you'll have your ballast tanks chock-full (express elevator to 600m), having the tanks above the vessel's CoM should keep the vessel correctly oriented.

Link to post
Share on other sites

the only thing is, i am not having tipping problems, i am having sinking problems...

maybe i could replace the structural fuselage on the side with the rockomax sized ballast tanks

HL, could you create a Rockomax Jumbo-64 sized ballast tank? that would be cool. also some probe sized parts would be helpful

Link to post
Share on other sites

I have been informed that all KSP mods must have a license, so here is the one that was recommended and this now uses: http://choosealicense.com/licenses/mit/

I want to stress that I have learned so much from doing these KSP mods and want to pass that knowledge forward. I think this is the most free software license that I can use and hope that it does not discourage anyone from using my mods our the source code in any way.

HL, could you create a Rockomax Jumbo-64 sized ballast tank? that would be cool. also some probe sized parts would be helpful

Sorry, not anytime soon. Stack Lemurias.

Link to post
Share on other sites
This should be it: http://wiki.kerbalspaceprogram.com/wiki/Atmosphere

Air density is rather properly modeled, based on altitude. The effects of high pressure on hydrogen has been apparently called "the holy grail of high-pressure physics."

Thanks for the link. If the wiki is accurate, then it is true that your balloons should float in Jool's atmosphere because all atmospheres in the game are made out of the same thing, a mysterious, unrealistic “gas†that does not change in density when the temperature is changed! So assuming the wiki is accurate, then it's not your balloons, but the atmosphere they are floating in, that is unrealistic.

In fact, I must strongly (but respectfully!) disagree with your statement that air density is properly modeled. To me it is not properly modeled, not even close. First of all, it is very unrealistic to assume that all planetary atmospheres have the same specific density. Let’s look at the specific density of real-life solar system atmospheres at 1 atm and 0 degrees C:

Venus:

2.0 kg/m^3 (almost entirely CO2, molecular weight 44)

Earth:

1.3 kg/m^3 (approx. 80% N2, 20% O2, molecular weights 28 and 32)

Mars:

2.0 kg/m^3 (almost entirely CO2, molecular weight 44)

Jupiter, Saturn, Uranus, Neptune:

(all roughly around) 0.1 kg/m^3 (mostly H2, molecular weight 2, with a small to smallish fraction of He, molecular weight 4, thrown in)

Titan:

1.25 kg/m^3 (almost entirely N2, molecular weight 28)

Of course, remember these are specific densities- specific to 1 atm and 0 degrees C.

So I guess my point is that I find it to be a very poor atmospheric model if they assume that all planetary atmospheres have the same density at the same pressure and temperature. It is not even close IRL, especially when comparing gas giants vs. rocky worlds. As a general rule, rocky worlds will have atmospheres largely composed of heavier gases, as they do not have the gravity to hold onto anything lighter, while gas giants are heavy enough to prevent the escape of even the lightest gases.

But it gets worse yet. In the above example, notice that I was just comparing specific densities of planetary atmospheres- not their actual densities. I just wanted to make the pointthat all other things being equal, it is still a very poor model to make all planetary atmospheres equal in specific density. But all other things are NOT equal. The density of a gas is ALSO related to its temperature. The cooler a gas gets, the denser it gets. I don’t even see temperature as a factor in those atmospheric density calculations. Instead- we only see a single factor, pressure.

Again, I’m not surprised- Squad only has so much time on their hands, and the game is still in development. Still, at some point, I’d like to see atmospheres get a realistic treatment, with attention paid to making the atmospheres of the various planets actually different.

Anyway, I’m still going to send those atmosphere probes to Jool, because wikis are not renowned for their flawless factual accuracy. It could be wrong. I'll probably share the results here, I'm assuming you would like to know, at least just for curiosity's sake?

Oh and about high pressure hydrogen- again, that applies to pressures that far exceed what you would float a balloon in. For balloon dynamics, it's safe to just use ideal gas assumptions and equations.

Edited by |Velocity|
Link to post
Share on other sites
Answer: Use something like KAS to attach to the ground so you count as 'Landed' according to the game.

Oh I've done that, works fine on Eve or Duna or Kerbin, etc, but not Jool! First of all things get really really hot as they approach the surface (not good if deadly reentry is on) Second once anything make contact with the bottom no matter the speed it [implodes]. Would be nice if I could save up higher and cooler.

Link to post
Share on other sites
Thanks for the link. If the wiki is accurate, then it is true that your balloons should float in Jool's atmosphere because all atmospheres in the game are made out of the same thing, a mysterious, unrealistic “gas†that does not change in density when the temperature is changed!

The KSP developers themselves have said that, unfortunately, right now temperature is only a factor of height and now location on a planet. However, each planet does have different temperatures (see the wiki).

So I guess my point is that I find it to be a very poor atmospheric model if they assume that all planetary atmospheres have the same density at the same pressure and temperature.

Here is what is in the documentation...


/// <summary>
/// Converts an atmospheric pressure into an atmospheric density. Atmospheric density is what
/// appears in the KSP drag equation. This function seems to just multiply the input by 1.2230948554874
/// </summary>
/// <param name="pressure">Use the output of getStaticPressure</param>
/// <returns>An atmospheric density, suitable for use in calculating drag.</returns>
public extern static double getAtmDensity(double pressure);

So you may be right, without going to another planet and testing. This could be a suggestion to SQUAD as an easy way to do a small mathematical change and improve accuracy (even easier than fixing buoyancy in water!)

Answer: Use something like KAS to attach to the ground so you count as 'Landed' according to the game.

Can this be added to the wiki? hlmods.wikia.com

Link to post
Share on other sites

So I've been using these in my Eve or Bust series and I don't know if you're aware but the performance can be truly awful. I docked my submarine to my 1000 part mothership and the fps went from 8 to <1fps. This was a ship orbiting in deep space and it seems that the submarine parts are running some sort of calculation on ever part, even though the vehicle is in deep space. I've simply disable the submarines DLL it works fine, I can re-enable it once I've detached the sub.

Link to post
Share on other sites
So I've been using these in my Eve or Bust series and I don't know if you're aware but the performance can be truly awful. I docked my submarine to my 1000 part mothership and the fps went from 8 to <1fps.

Thanks for the feedback! I'm glad you found a workaround in the meantime. I've been watching your series in both awe and dreaded anticipation of the bugs you might find. :)

I think no-one has tried to make such a complex interplanetary submarine as yours. Usually a frame drop like that is caused by errors being spammed into the debug log. Can you open that up and see what was causing the issue?

I have some other projects going on now but I will try to take a look as soon as I can. I do rely heavily on users to bring problems they find to this forum.

EDIT: Added a piece to the FAQ now that should address that subject!

Well done!

Link to post
Share on other sites

Lots of these messages in the logs

[LOG 07:42:43.805] Part -334640 is removing stock partBuoyancy from solarPanels5 -323278

[LOG 07:42:43.806] Part -334640 is removing stock partBuoyancy from solarPanels5 -323304

[LOG 07:42:43.807] Part -334640 is removing stock partBuoyancy from solarPanels5 -323330

[LOG 07:42:43.808] Part -334640 is removing stock partBuoyancy from solarPanels5 -323356

[LOG 07:42:43.810] Part -334640 is removing stock partBuoyancy from solarPanels5 -323382

[LOG 07:42:43.811] Part -334640 is removing stock partBuoyancy from solarPanels5 -323408

[LOG 07:42:43.817] Part -334640 is removing stock partBuoyancy from solarPanels5 -323434

[LOG 07:42:43.818] Part -334640 is removing stock partBuoyancy from solarPanels5 -323460

[LOG 07:42:43.820] Part -334640 is removing stock partBuoyancy from solarPanels5 -323486

[LOG 07:42:43.821] Part -334640 is removing stock partBuoyancy from solarPanels5 -323512

[LOG 07:42:43.822] Part -334640 is removing stock partBuoyancy from solarPanels5 -323538

[LOG 07:42:43.824] Part -334640 is removing stock partBuoyancy from solarPanels5 -323564

Link to post
Share on other sites

Thanks! This should only run once when the plugin first starts in order to replace the stock buoyancy code. However, something must be happening in space which is causing the stock buoyancy to be reapplied to the parts over again (causing it to need to be removed again). My guess is that it is quietly but rapidly loading between different scenes.

There are two ways I can make this run faster...

1) Remove that debug output. That makes everything run much much faster.

2) Have a better check for when it should be running. It ONLY should attempt to replace stock buoyancy when the "main body" (which the vessel is orbiting) has an ocean. Maybe KSP thinks that the sun has an ocean or something strange? An altitude check might do it.

Link to post
Share on other sites
Thanks! This should only run once when the plugin first starts in order to replace the stock buoyancy code. However, something must be happening in space which is causing the stock buoyancy to be reapplied to the parts over again (causing it to need to be removed again). My guess is that it is quietly but rapidly loading between different scenes.

There are two ways I can make this run faster...

1) Remove that debug output. That makes everything run much much faster.

2) Have a better check for when it should be running. It ONLY should attempt to replace stock buoyancy when the "main body" (which the vessel is orbiting) has an ocean. Maybe KSP thinks that the sun has an ocean or something strange? An altitude check might do it.

If I may give my two cents on this? Don't remove the debug printing. It's one of the biggest tools you have for finding errors. But perhaps alter it so it doesn't print to the in game one?

Link to post
Share on other sites

I will probably compress the debug output. Right now it outputs for every part, where it removes the old buoyancy and then applies the new. I think part of the problem is that the Destroy(partBuoyancy) is not immediate, it happens after all parts seem to run FixedUpdate at least once. Thus, you see each part post that it is trying to remove the old buoyancy from every other part (so messages roughly = number of parts squared). So the amount of lag this could generate could be exponential and there is no reason to report it happening all the time, it's spam.

I can always turn the full debugger back on when more bugs come up and I'm given a good description of the issue to work from.

Link to post
Share on other sites
The problem that you run into there is that this is a game, if we wanted real life we would either play orbiter or join nasa. Now I'm all for the planets getting upgraded to be better but not to the point of being 'realistic'.

With this impassioned and well-thought-out argument, I'm afraid that I must change my original position and agree with you. Squad shouldn't ever take the time to implement different atmosphere types on different planets- how could I have EVER thought otherwise? Of course, this isn't Orbiter! This cancer of people wanting more features in Kerbal Space Program MUST BE STOPPED! I see Hooligan is working on submarines now. What is he thinking?!?! SAY "NO!" TO SUBMARINES IN KSP, THIS ISN'T Silent Hunter!!!!!

But even Squad is having problems keeping focus on what KSP is really about. This Space Plane hanger must go! THIS ISN'T X-Plane!!! And what the heck is this Kerbonaut training center doing in MY Kerbal Space Center?!?! THIS ISN'T The Sims!!!! And really, planets? With ORBITS? REALLY?!?! GET RID OF THEM, THIS ISN'T Universe Sandbox!!!!!

Kerbal Space Program MUST be SOLELY about launching blowing up green cartoon men on cartoon rockets into cartoon space. PERIOD. Nothing else. No physics, THIS ISN'T SCHOOL!

Edited by |Velocity|
Link to post
Share on other sites
Guest
This topic is now closed to further replies.
×
×
  • Create New...