Jump to content

Modular Fuel System Continued v3.3 (OBSOLETE)


NathanKell

Recommended Posts

Alright so I've been looking to my problems with adding fuel types and it seems I can't even add them in the text files. When I try to change the Default tank to start with Fluorine or Lithium the loader just gets stuck on the first fuel tank, or if I make a new tank type and change a specific fuel tank to have that then the loader gets stuck on that one. It's very annoying cause it seems like this should work...

Link to comment
Share on other sites

Alright so I've been looking to my problems with adding fuel types and it seems I can't even add them in the text files. When I try to change the Default tank to start with Fluorine or Lithium the loader just gets stuck on the first fuel tank, or if I make a new tank type and change a specific fuel tank to have that then the loader gets stuck on that one. It's very annoying cause it seems like this should work...

I think you should provide some snippets demonstrating what you tried to do . And what do you mean the loader got stuck? Did the game actually fail to run, is that what you mean?

Edit: Wait, I see that you posted some config files....

Edited by Starwaster
Link to comment
Share on other sites

I think you should provide some snippets demonstrating what you tried to do. And what do you mean the loader got stuck? Did the game actually fail to run, is that what you mean?

That is what I mean. The loading screen which shows which part you are currently loading just stops at the fuel tank. I posted the files I have modified and posted pictures, not quite sure what demonstrations you want. Do you know how to add new fuels?

Link to comment
Share on other sites

That is what I mean. The loading screen which shows which part you are currently loading just stops at the fuel tank. I posted the files I have modified and posted pictures, not quite sure what demonstrations you want. Do you know how to add new fuels?

Don't do this.


RESOURCE_DEFINITION{ name = DiFluorine density = 0.00753 flowMode = STACK_PRIORITY_SEARCH transfer = PUMP}
RESOURCE_DEFINITION{ name = Lithium density = 0.00256 flowMode = STACK_PRIORITY_SEARCH transfer = PUMP}

Do this.


RESOURCE_DEFINITION
{
name = DiFluorine
density = 0.00753
flowMode = STACK_PRIORITY_SEARCH
transfer = PUMP
}
RESOURCE_DEFINITION
{
name = Lithium
density = 0.00256
flowMode = STACK_PRIORITY_SEARCH
transfer = PUMP
}

Not sure if there's any other issues I'm still looking at the files.

<snipped the part about the line breaks in front of the first bracket, just tried it out and it didn't seem to break anything>

Edit #2: BTW, breaks / returns between the full node (that is between the final brace and the next node) are OK.

Edited by Starwaster
Link to comment
Share on other sites

Yup, Starwaster's got it. Pretty sure it's that the resource definitions are being processed as a single key/value rather than a node. KSP requires linebreaks to terminate node defines or k/v pairs.

The linebreak between the nodename and the opening brace may or may not be OK; don't know.

Link to comment
Share on other sites

Yup, Starwaster's got it. Pretty sure it's that the resource definitions are being processed as a single key/value rather than a node. KSP requires linebreaks to terminate node defines or k/v pairs.

The linebreak between the nodename and the opening brace may or may not be OK; don't know.

Nah I just tested it; tried to break the game that way and it loaded ok.

I also found a problem in his engines.cfg

There's 1,262 { but only 1,261 }

That WILL break loading for sure. (the first one with the RESOURCE being all inline I'm not sure breaks loading, it might just break parsing. I forget what happens if you do that)

Anyway I'm not sure where the missing } is

gm537, where possible make a new config file instead of editing the existing ones. I can sort of see why you did it with the engines.cfg, looks like you rewrote large parts of it but the resource declaration could have been in a single file by themselves.

For instance, the corrected RESOURCE node that I pasted in could have been in their own file, and it makes it easier for others to troubleshoot your stuff.

Link to comment
Share on other sites

Yup, Starwaster's got it. Pretty sure it's that the resource definitions are being processed as a single key/value rather than a node. KSP requires linebreaks to terminate node defines or k/v pairs.

The linebreak between the nodename and the opening brace may or may not be OK; don't know.

Or maybe the breaks matter a lot... Hehe Yeah I guess just making a new file would be better rather than editing existing. Hmm it doesn't seem to be the engines.cfg that's causing the problem though let me try the linebreaks to see if it changes.

Link to comment
Share on other sites

Yep that worked! Thanks guys! Good catch on the '{'. I am still noticing that when I change the tech level on my LV-909 the Isp does not change for the custom fuel configuration, but does change with MMH+N2O4 and the LiquidH2+LiquidOxygen. Any thoughts? Also what text editor are you guys using? (aka how did you catch the brace imbalance?)

Link to comment
Share on other sites

Or maybe the breaks matter a lot... Hehe Yeah I guess just making a new file would be better rather than editing existing. Hmm it doesn't seem to be the engines.cfg that's causing the problem though let me try the linebreaks to see if it changes.

You definitely have a problem in engines.cfg and I have seen mismatched braces break the game.

The problem is in the liquidEngine3 part.

You need to insert another } between line 1637 and 1638

(it's easier to see with proper indentation)

I had to search the document bubble search style to locate that.

Link to comment
Share on other sites

Yep that worked! Thanks guys! Good catch on the '{'. I am still noticing that when I change the tech level on my LV-909 the Isp does not change for the custom fuel configuration, but does change with MMH+N2O4 and the LiquidH2+LiquidOxygen. Any thoughts? Also what text editor are you guys using? (aka how did you catch the brace imbalance?)

argh you ninja'ed me.

I use Notepad++

Use it and you won't regret it.

This is how I found the missing }

First, because I had that problem myself once I suspected it could be an issue here so I just searched first for the { then for the } and Notepad++ told me how many of each it found.

Then I selected the first half (making sure to end my selection BEFORE it included the beginning of another part so I was only selecting complete PARTs) and searched again.

When I still got a mismatched number of braces I knew it was in the first half. So I selected the first quarter and searched again until I narrowed it down.

That's what programmers call a bubble search. Only they're meant to be done by programs and not people, but meh, the concept works for the meat just as well as the silicon.

Narrowing it down within the part I just did by going down the line properly indenting with tabs. Notepad++ has a special way of connecting braces when you indent with tabs that makes it graphically obvious where the missing brace is. (the connecting line ended in a place that had no brace)

Link to comment
Share on other sites

Uh, I think you mean binary search. ;)

gm537, you have IspSP instead of IspSL in that block. Otherwise it looks fine. When you correct the typo, I think techlevels will work fine.

You may be right but I've been calling them bubble searches for almost 20 years now.

*shrug*

Link to comment
Share on other sites

Haha yeah Binary search is a good idea! Haha I've programmed it before but didn't think to apply it 'by hand'! And spelling ftw! 'IspSP' doh! Thanks bunches for all the help! I will now leave you in peace to continue your awesome modding while I go back to adding ridiculous fuel configurations that only Kerbals would use! (Basically everything with Fluorine has awesome performance!)

Link to comment
Share on other sites

ridiculous fuel configurations that only Kerbals would use! (Basically everything with Fluorine has awesome performance!)

Wouldn't touch, with a ten foot pole, a ten foot pole that had touched it. Gah, flourine. Gah.

Starwaster: Huh. The only bubble algorithm I know is bubble sort: http://en.wikipedia.org/wiki/Bubble_sort

But whatever works, and it sure worked! :)

Link to comment
Share on other sites

Wouldn't touch, with a ten foot pole, a ten foot pole that had touched it. Gah, flourine. Gah.

Starwaster: Huh. The only bubble algorithm I know is bubble sort: http://en.wikipedia.org/wiki/Bubble_sort

But whatever works, and it sure worked! :)

There's some quote on Project Rho's website... something about how fluorine stops being gentle and cuddly above a certain temperature....

Link to comment
Share on other sites

Q1 is yes. Q2 is definitely yes. Flux is a fancy pants word for flow. Usually flux is used as a flow per area but is just as commonly used in the "total flux" form which is simply a flow.

ok thats what I thought.

I downloaded RPA 1.2 lite but it doesnt display thrust and my head is spinning and my browser has about 20 tabs open to assorted rocketry and NTR pages and equations and I just drew a complete blank

Link to comment
Share on other sites

Hey, I've just watched Rocket Girls (awesome anime, BTW, check it out. Has some really Kerbal moments, and gets most of it's rocket science right :)) and had an idea. Why not add hybrid rockets to MFT lineup? Basically, it's an SRB with an oxidizer (usually LOX) tank on top. Pretty non-explosive, medicore Isp (but higher than pure solid), but cheap, very throttleable and easily restarted. I imagine that the most basic implementation would be SolidFuel+LOX. Not entirely realistic (hybrid fuel and pure solid fuels are different things), but should work for a proof-of-concept. It'd work like a normal SRB that you need to provide with some kind of oxidizer for it to work, either from a stack tank or through a fuel line. This could be implemented as a "fuel mode" on existing SRBs, so it's only config-side work, not even needing a plugin change, just a few additions to the spreadsheet.

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...