Jump to content

Modular Fuel System Continued v3.3 (OBSOLETE)


NathanKell

Recommended Posts

Note: This has been superseded by Real Fuels (for all your MFS/RF needs), and Modular Fuel Tanks (for your stock-MFS needs).

RF is by me: http://forum.kerbalspaceprogram.com/threads/64118

MFT is by taniwha: http://forum.kerbalspaceprogram.com/threads/64117

Consider this thread over and done.

===========

I'm maintaining Modular Fuel System in ialdabaoth's absence; he has blessed the endeavor and was even kind enough to send me his dev build for this (and Deadly Reentry, which I'm also going to be working on). So here is the promised thread.

This integrates Chestburtster's work with extending MFS compatability; indeed Chestburster and I are working together on this so it's not fair to say it's just me maintaining it!

Description

Modular Fuel System does the following:

*It allows any supported tank to be filled with exactly how much or how little fuel you want, of whatever type you want (though different tanks may allow or disallow certain fuels; jet fuel tanks won't take oxidizer for instance)

That's the classic modular fuels.

Then, there's the Real Fuels mode. That opens up some new options. First, new resources get added, so engines can use real-world fuels, and KSP fuels are changed to be their real-world counterparts. Also, Isps are made realistic for the type of engine. Finally, engines can be of multiple tech levels; at higher tech levels they have higher thrust, lower mass, and better Isp.

Second, engines can have multiple configurations (for example, an upper stage could support a kerosene + liquid oxygen mode, and a liquid hydrogen + liquid oxygen mode). These modes have different thrust, Isp, etc.

You can access all MFS-related GUIs ingame by going to the Action Group editor in the VAB/SPH and clicking on a tank or (if RF is installed) an engine.

Now, I'm offering three premade builds, in case the whole unzip-RealFuels-thing was confusing.

Regular Modular Fuels (no RealFuels): https://www.dropbox.com/s/rge60psousb0f3i/ModularFuelSystemCont_v3_3.zip

Modular Fuel Tanks with Real Fuels (KSP-style masses of engines and tanks): https://www.dropbox.com/s/7vj48njyo634v38/ModularFuelSystemCont_v3_3RF.zip

Modular Fuel Tanks with Real Fuels and realistic masses (for use with the Real Solar System mod): https://www.dropbox.com/s/lpq7wgkdsewuvm2/ModularFuelSystemCont_v3_3RFRM.zip

Also, see the Realism Overhaul release thread for an alternative set of engine configs for RFRM. With those engines I don't feel obligated to maintain their original mass or thrust, so they have a much more diverse and realistic feel. (Successor to KATO Engines)

From the readme:

This update is by NathanKell and Chestburster.

ialdabaoth (who is awesome) created Modular Fuels, and we're maintaining it in his absence.

This update supercedes any dev release by NathanKell or MFS Configs release by Chestburster.

License remains CC-BY-SA as modified by ialdabaoth.

Also included: Module Manager (by sarbian, based on ialdabaoth's work). See Module Manager thread for details and license and source: http://http://forum.kerbalspaceprogram.com/threads/55219

Module Manager is required for MFSC to work.

Mods Supported, beyond Stock KSP:

AIES

B9 (partial--full soon)

FASA (frizzank's Gemini etc.)

HexCans

Kethane

KOSMOS

KSP Interstellar

KSPX

KW Rocketry

NovaPunch

RLA Stockalikes (partial--full soon)

Rocket Power Industruies

Rocketdyne F-1 in real scale (use in RFRM mode for real mass. Must have space taken out of part name, so it's now F1_RocketMotor)

Space Shuttle Engines

SDHI Service Module

Spherical Tanks

Taverio's Pizzan and Aerospace (TVPP)

THHS

Touhou Torpedo's Mk3 and Mk4 mods

INSTALL INSTRUCTIONS:

0. Download the appropriate archive! See thread for details. MFSC now offers three builds (though any build can be made into any other).

1. Delete any existing ModularFuelTanks folder in your KSP/GameData folder. This is VITAL.

2. Extract this archive to your KSP/GameData folder (NOTE CHANGE)

To go from ModularFuels, alone, to Modular Fuels + Real Fuels: extract the RealFuels.zip in the ModularFuelTanks folder.

To go from Real Fuels to Real Fuels + Realistic Masses, go to that RealFuels folder you created and change the line useRealisticMasses = false to useRealisticMasses = true

(To go back, set it back to false)

To go from Real Fuels to just ModularFuels, delete that RealFuels folder.

AN OVERVIEW OF FUEL TYPES AND TECH LEVELS ARE IN THE README BELOW THE CHANGELOG

==========

Changelog:

v3.3 = \/

*Swapped how thrust and mass are changed by TL increase.

*Made the battery multiplier (how much charge per unit of volume) configurable in MFSSettings

*Changed Xenon around. Tanks now hold 1/10 what they used to, and Xenon is now 10x as dense. It's kept pressurized at a hopefully reasonable temperature to yield that 0.2 g/cc density (what I've set it to).

*Changed tank masses again to try go get them ever closer in line with the real world.

*Added Balloon tanktype (practically no basemass; structural integrity kept by internal pressure). C.f. Atlas missile / LV. Same for BalloonCryo. Since the tank goes all the way to the skin they hold slightly more (at least the StretchyTank ones, the only ones so far, do).

*Fixed propellant ratios so that they are displayed in percents rather than 0.x ratios that get rounded.

*Added tooltips for hovering over autofill buttons to say which engines use that mixture.

*Added SRFirefox's fix for NTRs so nuclear fuel lasts longer. Also increased ElectricCharge generation.

*Added Syntin; changed Methane to LqdMethane to comport with other fuels.

===============

Oh, and because I know how this game works, the pix:

1c2Tfp2l.gif

About a quarter of the engines we support.

Edited by NathanKell
Link to comment
Share on other sites

Uweeehehehehe.

Okay, it's not confusing now.

Although if Sabres are now Configurable, I'm going to have to fiddle with my planes...again...I added a fuel tank to both of them to accomodate the fact the LH2/LOX has a lower Density :P

Link to comment
Share on other sites

Cool. :)

Configurable in the sense that a hybrid engine's modes are stored the same was as a modular engine's configs. Don't think any other fuel modes have been added for SABREs...

Oh. Well w/e that's easy then, but I still have to see how messed up the Delta-V is again. :P

Link to comment
Share on other sites

Oh yeah, if you're not using LH2/LOX, you'll have to reconfigure your tanks. We no longer support LF/Oxidizer for engines (replaced with LF/Lox, like real life; the third mixture is hypergolic NTO/MMH), and the ratio for LF/Lox changed slightly. LH2/Lox ratio didn't change, although density changed ever so slightly for both.

Of course, for any engines we haven't touched yet, there's still LF/Ox.

Link to comment
Share on other sites

Oh yeah, if you're not using LH2/LOX, you'll have to reconfigure your tanks. We no longer support LF/Oxidizer for engines (replaced with LF/Lox, like real life; the third mixture is hypergolic NTO/MMH), and the ratio for LF/Lox changed slightly. LH2/Lox ratio didn't change, although density changed ever so slightly for both.

Of course, for any engines we haven't touched yet, there's still LF/Ox.

Well, Sabres. The one's not so easy to add tanks to because they're welded, it was too flopsy without it (it's still a bit flopsy WITH it, frankly.)

I'd already added an extra tank to both of my spaceplane designs to compensate for the lost Delta-V, making up the rest with their more efficient flight profiles from the reduced weight. I'm going to have to check them both to make sure that with all the changes they still work and have acceptable amounts of delta-V.

I've also got to recreate the cfgs for the welded body of the one, because I just deleted them without making a note of the values. Bleh. Can I add them to a new .cfg file I can stick in there, or do I have to put them in one of the existing ones?

Link to comment
Share on other sites

Tiron, you might lose 1-5% of your DV? Dunno. The values were balanced so a tank of LF/LOX at their ratio will yield the same dV as a same-size tank of LF/Ox at the old 9:11 ratio, for an engine of the same Isp.

Just up the volume of the welded part slightly (in the cfg and in the .craft) until you get the same dV. After each upping, go into the game, and MFS, and clear the tank of LH2 and LOX, and then autofill to your engine's ratio.

....Except in looking into this, I've found two problems.

1. A typo in my resource definition for LH2 (should be 36, not 40).

2. The ratios for the Hybrid engines are all wrong. In air-breathing mode, the real SABRE has a ox:fuel ratio by mass of 23 to 1, not 6 to 1 So the ratio should be 62.3% intake air, 37.7% LH2. That will lower your fuel use before switchover, and it should all balance out, despite the lesser volume of the tank, I think. Though you might need more intakes!

Replaced the archive. Please regrab.

Edited by NathanKell
Link to comment
Share on other sites

dlrk, thanks!

You'll be pleased to note that ialdabaoth added thermal fins for cooling your tanks. I neglected to mention that in the readme; fixed now.

loss_rate works as follows. Find the loss_rate of the fuel in the tank (for LH2 in a cryogenic tank, it's 0.0000000002.

Multiply that by the number of seconds in the trip. Then multiply it by the difference between the average tank temperature (right-click on your tank in flight if you have Deadly Reentry, and it will tell you the tank's temperature) and the desired temperature (-283).

If your journey is 30 days (30*86400=2,592,000) then you will lose 0.05% * temperature_difference (let's say 100c, i.e. part temp = -183) = 5% of your fuel.

I don't recall what the usual orbital temperature of a part is, so -183 was just a guess. Loss will be higher if temperature of the tank is higher.

Edited by NathanKell
Link to comment
Share on other sites

Kommitz, thanks!

Yes they can. However, if you make them hybrid rather than just configurable, they will also be switchable in flight.

The modules are as follows:

ModuleEngineConfigs = Modular Engine. Can choose config in VAB/SPH.

ModuleHybridEngine = Same code style as MEC, but can alternate between configs in flight too. Check out the CFG for KSPX under RealFuels for an example of the new style.

ModuleHybridEngines = the old Hybrid Engines module. Note the S at the end. This is for backwards compatibility.

Link to comment
Share on other sites

Tiron, you might lose 1-5% of your DV? Dunno. The values were balanced so a tank of LF/LOX at their ratio will yield the same dV as a same-size tank of LF/Ox at the old 9:11 ratio, for an engine of the same Isp.

Replaced the archive. Please regrab.

Yeah, trick being both my SSTOs being SSTOs use Sabres, so LH2 and LOX, not LF/OX. at least, not since I started using the original modular fuels a few days ago. The initial switch cut the delta-v by quite a bit, but adding a fuel tank to each plane pretty much solved it. It was going from original setup with LF/OX to Modular Fuels setup with LH2/LOX that cut my delta-v, not your update (though I haven't checked it yet.)

Also, since I need to add a .cfg entry for my welded body on the one, can I put them in my own .cfg file that won't get overwritten by updates? In other words, is it set to read any .cfg file in there, or just the ones that came with it?

Link to comment
Share on other sites

Tiron, yup, you can copy the PART[] block for the appropriate engine, save it in a new CFG, change what's in the [] to the right part, and that's fine. But put it in some other folder, just in case I later ask you to delete the ModularFuelTanks folder. ;)

KSP reads any .CFG file anywhere under GameData, you can put it where you like.

In other news...some people might have to wait for .22, but I give it to you early: TECH LEVELS.

VLZ4hVAl.png

Check out the info popup.

Zzfr0tcl.png

Check out the Modular Engines GUI and the -/+ buttons.

Coming soon. Now you can increase an engine's tech level for better performance.

Link to comment
Share on other sites

Tiron, yup, you can copy the PART[] block for the appropriate engine, save it in a new CFG, change what's in the [] to the right part, and that's fine. But put it in some other folder, just in case I later ask you to delete the ModularFuelTanks folder. ;)

KSP reads any .CFG file anywhere under GameData, you can put it where you like.

I got just the folder. Although it's a body, not an engine (bunch of LFO tanks, an SAS, and a tail welded together), so it's really a fuel tank. Already got the config set up though, just wanted to know if I could split it out. ;)

Link to comment
Share on other sites

Although I am not currently using this awesome mod, it is nice to see that someone is continuing to work on those mods for iadaboath, while he isn't able to do so for himself. Did I read right, you als want to continue work on Deadly Reentry? That would be really awesome. Either way thumbs up for helping iadaboath out and don't let this mod die

Link to comment
Share on other sites

Can Nuclear Engines have configurable fuels before launch now?

Also nice to see work on this project again.

Check my real fuels addon in my signature.

In addition to allowing LH2 I've also added ammonia, water and kethane. Also hydrogen slush, which doesn't doesn't perform any differently than LH2 but allows slightly denser storage.

Not sure there's configs for your engines in there yet, I forget.

dlrk, thanks!

You'll be pleased to note that ialdabaoth added thermal fins for cooling your tanks. I neglected to mention that in the readme; fixed now.

loss_rate works as follows. Find the loss_rate of the fuel in the tank (for LH2 in a cryogenic tank, it's 0.0000000002.

Multiply that by the number of seconds in the trip. Then multiply it by the difference between the average tank temperature (right-click on your tank in flight if you have Deadly Reentry, and it will tell you the tank's temperature) and the desired temperature (-283).

If your journey is 30 days (30*86400=2,592,000) then you will lose 0.05% * temperature_difference (let's say 100c, i.e. part temp = -183) = 5% of your fuel.

I don't recall what the usual orbital temperature of a part is, so -183 was just a guess. Loss will be higher if temperature of the tank is higher.

In Kerbin orbit it's about -100 to -130 when the sun is occluded and about -10 to -50 when exposed to the sun. That can vary a LOT though. And it seems to dip suddenly and sharply just before 'sunrise' instead of being gradual. Kind of weird actually. Also, and to be expected, is that temperature only changes when the ship is active. If it's on rails then its temperature remains at whatever it was at the time it went on rails.

Should fall off further out but I haven't taken measurements very far out.

Edited by Starwaster
Link to comment
Share on other sites

Tiron, you might lose 1-5% of your DV? Dunno. The values were balanced so a tank of LF/LOX at their ratio will yield the same dV as a same-size tank of LF/Ox at the old 9:11 ratio, for an engine of the same Isp.

...

2. The ratios for the Hybrid engines are all wrong. In air-breathing mode, the real SABRE has a ox:fuel ratio by mass of 23 to 1, not 6 to 1 So the ratio should be 62.3% intake air, 37.7% LH2. That will lower your fuel use before switchover, and it should all balance out, despite the lesser volume of the tank, I think. Though you might need more intakes!

Replaced the archive. Please regrab.

Okay. Based on my first test flight, total Delta-V loss (After reaching orbit) on the Valkyrie from old MFS 1.3 to new MFS 1a is a little over 27%.

This is attributable to the massively, wildly, insanely higher fuel consumption on the Sabre-Ms in air breathing mode. In MFS 1.3, it took about 500 units (Though I gave it 600) of LH2 to get up to speed and altitude. In 1a, I was at 1550 units and still slightly underspeed when I cut it off and went for orbit anyway.

Additionally, a mission in progress prior to switching versions lost an engine on takeoff and had to emergency abort back to KSC as a result. This flight, in new version 1 (not 1a, yet), was barely able to make it back to KSC on well over 8000(I think close to 9000, actually) units of LH2. In part because it spent a lot of time, and fuel, wallowing at low altitude due to the difficulty it had in climbing with asymmetric thrust(including one flat spin I had to pull it out of, and several more that I barely averted). I have screenshots demonstrating total fuel consumption of 7358 units of LH2 to fly back to KSC and land, a total, direct distance of ~385 KM. With course deviation, planetary curvature, and landing approach etc it was probably closer to 450 or 500km actually covered.

Note that when I started the flight with old MFS 1.3, I only gave it 10000 units of fuel. My first screenshot shows it climbing through 9900 m with 8238 units of fuel and a TWR of 1.89. I'm pretty sure I had at LEAST 8700 units on the ground, and I think I had a fair bit more than that. The flight to get there was more efficient than the flight back, but still. I flew out there, circled around, found a landing spot, and landed, on something like 12% of the fuel it took to fly back, using a very excessive two engines on the way out and one on the way back.

That's 'switch back to the old version' worthy right there, so I hope to god that's a bug or miscalculation of some sort. And could you explain how '23 to 1' (95.833:4.1667) turns into 62.3:37.7? Even accounting for the different densities (Which I would've thought the original ratio already did) that seems extreme, especially since air has less oxygen in it than LOX.

As for that, I've noticed two other, much more minor issues.

Configuring a fuel tank for a Sabre has gone from 'mildly annoying' to 'fair pain in the butt'. They don't show up as options on the autofill, and before the easy answer was to just attach a radial engine to the thing, reconfigure it to LH2 and LOX, and then use that to set the ratios. Now, none of the radial engines and what seems to be very few of the inline engines are able to be reconfigured to LH2/LOX, so sticking something on temporarily just to get the autofill to work has gotten a whole lot harder.

Second, just like the old version, the archive is a mess, with a .git folder, two source folders, and THREE copies of the DLL, plus Mac OS '.ds_store' files scattered all throughout the stuff in gamedata. On most mods, that kind of stuff is put in a separate top-level folder, usually called 'source', so that you can install just the gamedata bits and not be mucking up your game with a bunch of crap it can't use. The current setup makes that a bit of a chore, because most of the subfolders have at LEAST one extraneous bit.

Edited by Tiron
Link to comment
Share on other sites

Following the discussion on the prior thread, I'd encourage using stock resources wherever they make sense. In particular monopropellant/oxidizer over MMH/N2O4.

But then you'll get engines that burn monopropelant plus oxidizer. Can it still be called monopropelant then ?

Link to comment
Share on other sites

Guessing this a bug and not a feature: (In realfuels' engines.cfg)

@PART[KW2mengineGriffonG8D] //Griffon G8D ®

{

@mass = 44

@maxTemp = 1800

@MODULE[ModuleEngines]

{

@maxThrust = 10400

@heatProduction = 222

@atmosphereCurve

{

@key,0 = 0 330

@key,1 = 1 264

}

@PROPELLANT[LiquidFuel]

{

@name = LiquidFuel

@ratio = 0.39

}

@PROPELLANT[Oxidizer]

{

@name = LiquidOxygen

@ratio = 0.61

}

}

@MODULE[ModuleGimbal]

{

@gimbalRange = 0.25

}

MODULE

{

name = ModuleEngineConfigs

techLevel = 4

origTechLevel = 4

engineType = L+

configuration = LiquidFuel+LiquidOxygen

modded = false

CONFIG

{

name = LiquidFuel+LiquidOxygen

maxThrust = 10400

heatProduction = 222

PROPELLANT

{

name = LiquidFuel

ratio = 0.39

DrawGauge = True

}

PROPELLANT

{

name = LiquidOxygen

ratio = 0.61

}

atmosphereCurve

{

key = 0 330

key = 1 264

}

IspSL = 1

IspV = 1

}

}

}

Referring to the fact that it has 10400 thrust of course :).

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...