Jump to content

Karbonite/Real Fuels Integration Configs [1/18/15]


Raptor831
 Share

Recommended Posts

Again, your one step ahead of me. :) I'm working on a realistic set of minerals for Duna so I can colonize it using Real Fuels and Karbonite. (Duna data based off mars with some liberties for "play-ability") It'll be it's own mod with dependency checks for other mods and may include models for the drills, mine or acquired elsewhere, and of course use Open Resource System. If it works well for Duna I'll go on to other planets and release it. I'm not looking forward to the conversions though. lol. Your solution is nice and clean, I doubt mine will be. So good on ya. Care to help with the chem/converters?

I'll do what I can, if you need. My "specialty" is more in config wrangling than anything, which you seem to be well versed in. :wink: You can check the repository for this one to see how it's all working. The only chemistry stuff is going on in the XLS, which is basic reaction equations. Which I still manage to mess up.

@lordkrike you should be able to add line breaks with Open Office Calc. Though, maybe that was why I switched from that to Excel? I don't remember anymore.

I'll pull down the latest version to my local machine and have a go with it sometime this weekend. RP-1 is a much better short name than Kero. Didn't think of that when I was writing those in. If I find anything odd, I'll post it up when I can.

EDIT: Ok, I added your code to the XLS and it should be working now. Committed and pushed to the repository.

Edited by Raptor831
Link to comment
Share on other sites

Alright, thanks to Raptor I updated the .cfg file.

I've set up a new release for anyone out there that is interested. You can get it from Raptor's github here. Note that the atmospheric stuff is very untested, but the converters should work just fine.

Changes for v0.1.2:
Included atmospheric resource configs.

Refinery split into three modules:
Refinery C produces hydrocarbon-based bipropellant fuels and LOx.
Refinery N produces nitrogen-based bipropellant fuels and N2O4.
Refinery H produces LH2 and LOx.

Distillery split into two modules:
Distillery MON produces mixed oxides of nitrogen.
Regular distillery produces everything else.

Chemical production ratios tweaked.

If you're out there and using this, please give us feedback! :)

Link to comment
Share on other sites

Alright, thanks to Raptor I updated the .cfg file.

I've set up a new release for anyone out there that is interested. You can get it from Raptor's github here. Note that the atmospheric stuff is very untested, but the converters should work just fine.

Changes for v0.1.2:
Included atmospheric resource configs.

Refinery split into three modules:
Refinery C produces hydrocarbon-based bipropellant fuels and LOx.
Refinery N produces nitrogen-based bipropellant fuels and N2O4.
Refinery H produces LH2 and LOx.

Distillery split into two modules:
Distillery MON produces mixed oxides of nitrogen.
Regular distillery produces everything else.

Chemical production ratios tweaked.

If you're out there and using this, please give us feedback! :)

Thanks for setting up the release!

Link to comment
Share on other sites

  • 1 month later...

Notice, this is not compatible with RF v8.x. I've gotten stuck with RL, so this one's on the back burner. You can find/replace all of the resources that changed in the configs, for now. But since NathanKell changed some of the base properties of the resources (made them more accurate) I don't want to update until I can confirm all of the details, and that just takes time.

Link to comment
Share on other sites

  • 3 weeks later...

Any chance you could provide some initial pointers so I can look into performing the updates on my local machine - I'm not so much concerned whether the conversion rates are realistic with Nathan's changes (afterall, Karbonite is magicinium), but it would be handy to be able to convert my Karbs into something useful for my 6.4 scale realfuels game.

(I think mainly a prod in the correct direction for what the resource name changes were in RF v8.x, and how to wrangle the spreadsheet into configury-pokery).

If not, no problem, it'll just be a more involved trek into the evils of xcel for me!

Thanks,

Timmers

Link to comment
Share on other sites

Any chance you could provide some initial pointers so I can look into performing the updates on my local machine - I'm not so much concerned whether the conversion rates are realistic with Nathan's changes (afterall, Karbonite is magicinium), but it would be handy to be able to convert my Karbs into something useful for my 6.4 scale realfuels game.

(I think mainly a prod in the correct direction for what the resource name changes were in RF v8.x, and how to wrangle the spreadsheet into configury-pokery).

If not, no problem, it'll just be a more involved trek into the evils of xcel for me!

Thanks,

Timmers

Just find and replace all of the old resources with the new resources. That's it. :)

I'm looking to update this in the near future, now that the Stockalike Configs are updated and I have the new data.

Link to comment
Share on other sites

Thanks for the quick response.

Just find and replace all of the old resources with the new resources. That's it. :)

I'm looking to update this in the near future, now that the Stockalike Configs are updated and I have the new data.

In which case I shall put my world class procrastination skills to good use - I'm a ways away from making use of Karbonite in my 6.4x game anyway - if I get there soon enough I'll bodge the resources over to the 8.x RF resources though, probably just in the MM configs though, rather than deal in the land of excel.

Edited by timmers_uk
Karbonite! not carbonite... grr spellcheck
Link to comment
Share on other sites

I can upload an edited version of the .cfg for you if Raptor's okay with it.

I've been having a bodge at this also, although I'm having a bit of a gui issue - if there's more than a few conversion types on a converter, the gui is filled with constraint info and the actual buttons to activate the converters is offscreen. How did you solve this?

Link to comment
Share on other sites

I can upload an edited version of the .cfg for you if Raptor's okay with it.

Yes, please do! It'd be helpful. :)

I've been having a bodge at this also, although I'm having a bit of a gui issue - if there's more than a few conversion types on a converter, the gui is filled with constraint info and the actual buttons to activate the converters is offscreen. How did you solve this?

We didn't "solve" it really. We just limited the number of conversions per part and added a few "duplicate" converters to accommodate the wealth of resources.

Link to comment
Share on other sites

For anyone interested, I've updated the config to the new resources for RF 8.x. I'm not calling this a release yet, since I haven't tested this well. So, if you use it, let me know if it's working well for you. You can download from the repository, which is linked in the OP.

PS - Thanks Whovian for posting your fix! I do appreciate that. For anyone in the future, if this needs a fix and I'm not around, feel free to post a hotfix here. The license allows this, but just to be extra clear. :)

Link to comment
Share on other sites

For anyone interested, I've updated the config to the new resources for RF 8.x. I'm not calling this a release yet, since I haven't tested this well. So, if you use it, let me know if it's working well for you. You can download from the repository, which is linked in the OP.

PS - Thanks Whovian for posting your fix! I do appreciate that. For anyone in the future, if this needs a fix and I'm not around, feel free to post a hotfix here. The license allows this, but just to be extra clear. :)

Aaagh lol, I just spent an hour grinding through the diffs on realfuels to work out the updates - should have checked for updates on the thread first!... still ... it'll be useful to fact check my local changes to see if they match up :D

Timmers

Link to comment
Share on other sites

Aaagh lol, I just spent an hour grinding through the diffs on realfuels to work out the updates - should have checked for updates on the thread first!... still ... it'll be useful to fact check my local changes to see if they match up :D

Timmers

Ah! Sorry. :wink: There were a few density changes in the "source" XLS to match the new resources. NathanKell updated a few of those with more accurate numbers since he realized a few were off. So, it's not quite as simple as just find-replace.

If I goofed on any change, do let me know.

Link to comment
Share on other sites

I just tried the new configs and there doesn't seem to be Kerosene listed on the fuel choices. Stock Fuels like LFO are listed multiple times and the LOX conversion now works but yes no Kero.

EDIT:

I think I see the issue, the Kero conversions are done by a part named @PART[KA_Converter_250_01O], which doesn't exist in the "Karbonite_New_Converters.cfg" file.

EDIT2:

I added the "KA_Converter_250_01O" to the new converters file and I can now make RP-1 :)

Edited by 7rex
Link to comment
Share on other sites

I just tried the new configs and there doesn't seem to be Kerosene listed on the fuel choices. Stock Fuels like LFO are listed multiple times and the LOX conversion now works but yes no Kero.

EDIT:

I think I see the issue, the Kero conversions are done by a part named @PART[KA_Converter_250_01O], which doesn't exist in the "Karbonite_New_Converters.cfg" file.

EDIT2:

I added the "KA_Converter_250_01O" to the new converters file and I can now make RP-1 :)

Thanks for the heads up. I'll see if I can fix this up in the XLS and such.

Link to comment
Share on other sites

  • 1 month later...
Hey Raptor, any progress with updating this mod? Karbonite has switched to Regolith and thus has changed the way converters are defined. Also, MKS needs some tank definitions for the storage tanks.

Unfortunately, no real progress. I've heard someone else saying they want to make something similar based on the new Regolith system, and I've been working on different projects. It'll be a bit before I can get to this one.

Link to comment
Share on other sites

Unfortunately, no real progress. I've heard someone else saying they want to make something similar based on the new Regolith system, and I've been working on different projects. It'll be a bit before I can get to this one.

Seems like an easy fix, the only problem is the sheer amount of resources :)

Example Regolith Converter:


MODULE
{
name = REGO_ModuleResourceConverter
ConverterName = Oxidizer
StartActionName = Start Oxidizer
StopActionName = Stop Oxidizer
RecipeInputs = ElectricCharge,3,Karbonite,2.2
RecipeOutputs = Oxidizer,0.275,False
}

Based on this, I've checked if modifying the Karbonite_RF.cfg file, simply replacing the text but keeping your values:


@PART[KA_Converter_250_01]:AFTER[Karbonite]:NEEDS[RealFuels]{
MODULE
{

name = REGO_ModuleResourceConverter
ConverterName = Azine, LOX

StartActionName = Start Azine/LOX
StopActionName = Stop Azine/LOX
conversionRate = 1

RecipeInputs = ElectricCharge, 2, Karbonite, 1

RecipeOutputs = Aerozine50, 1.06943544155199, False, LqdOxygen, 1.01695809636349, True

}
}



@PART[KA_Converter_125_01]:AFTER[Karbonite]:NEEDS[RealFuels]

{
MODULE
{

name = REGO_ModuleResourceConverter
ConverterName = Azine, LOX

StartActionName = Start Azine/LOX
StopActionName = Stop Azine/LOX
conversionRate = 0.5

RecipeInputs = ElectricCharge, 2, Karbonite, 1

RecipeOutputs = Aerozine50, 1.06943544155199, False, LqdOxygen, 1.01695809636349, True}
}




@PART[KA_Converter_250_01]:AFTER[Karbonite]:NEEDS[RealFuels]

{
MODULE
{

name = REGO_ModuleResourceConverter
ConverterName = Hydyne, LOX, Hzine

StartActionName = Start Hydyne/LOX/Hzine
StopActionName = Stop Hydyne/LOX/Hzine
conversionRate = 1

RecipeInputs = ElectricCharge, 2, Karbonite, 1

RecipeOutputs = Hydyne, 1.1644502220112, False, LqdOxygen, 1.01695809636349, True, Hydrazine, 0.0826714788616067, True

}
}



@PART[KA_Converter_125_01]:AFTER[Karbonite]:NEEDS[RealFuels]

{
MODULE
{

name = REGO_ModuleResourceConverter
ConverterName = Hydyne, LOX, Hzine

StartActionName = Start Hydyne/LOX/Hzine
StopActionName = Stop Hydyne/LOX/Hzine
conversionRate = 0.5

RecipeInputs = ElectricCharge, 2, Karbonite, 1

RecipeOutputs = Hydyne, 1.1644502220112, False, LqdOxygen, 1.01695809636349, True, Hydrazine, 0.0826714788616067, True

}
}

Also, in the Karbonite_RemoveStock.cfg file, they have looks something like this:


@PART[*]:HAS[@MODULE[REGO_ModuleResourceConverter]:HAS[#ConverterName[LiquidFuel]]]:NEEDS[RealFuels]
{
!MODULE[REGO_ModuleResourceConverter] {}}


@PART[*]:HAS[@MODULE[REGO_ModuleResourceConverter]:HAS[#ConverterName[Oxidizer]]]:NEEDS[RealFuels]
{
!MODULE[REGO_ModuleResourceConverter] {}
}


@PART[*]:HAS[@MODULE[REGO_ModuleResourceConverter]:HAS[#ConverterName[MonoPropellant]]]:NEEDS[RealFuels]
{
!MODULE[REGO_ModuleResourceConverter] {}
}

The only problem is that Realfuels simply has too many fuels for stock :) In 0.25 I've played a lot with your engine configs, but since I only use B9 and KW, I never saw more than say 10 resources needed. Cutting them out with clever config files would also make converting to Karbonite much easier ;) Unfortunately, MKS has changed a few parts, so the tanks need a few redefinitions.

Link to comment
Share on other sites

Well, heck, if it's just a search/replace, then we're golden. I'll see if I can get that done this weekend sometime.

The plethora of resources is why the converters were duplicated into a few different parts. There's no way to add all of the resources, and some should not be used for in-situ extracting anyway. The really scary stuff (like say IRFNA, or flourine-based ones, or possibly hydrazine-based ones) probably should be left out due to their handling "issues". Stuff like hydrogen and oxygen don't really need that kind of handling protection, and all they need to be produced is water and electricity.

Link to comment
Share on other sites

  • 3 weeks later...

How is this mod looking for compatibility currently?

I use RealFuels already and am looking to include some form of ISRU, Karbonite seems like a pretty good looking mod even if it is totally incompatible as is :)

The changes you are talking of to get this converter to work with Regolith, is that simply something I can do to the MM scripts or is it in the coding?

Link to comment
Share on other sites

How is this mod looking for compatibility currently?

I use RealFuels already and am looking to include some form of ISRU, Karbonite seems like a pretty good looking mod even if it is totally incompatible as is :)

The changes you are talking of to get this converter to work with Regolith, is that simply something I can do to the MM scripts or is it in the coding?

Been putting this off for too long. So, the OP is updated with a new "release" for Regolith compatibility. This should get the converters to work with Regolith now. This is really a hotfix, all things considered. However, please do let me know if you find errors.

Link to comment
Share on other sites

Eeeerrrrrr, not quite :)

In its current form this is non functional, however after looking at the MM files, (I'm no programmer but I can play spot-the-difference with the best of em!!) you have got different names for your input/output fields to the Karbonite converters;

You want RecipeInputs/RecipeOutputs instead of InputResources/OutputResources.

This will get the converters working, however none of the different actions are named in game so you get presented with a wall of unnamed processes.

You want to add a "StartActionName =" and a "StopActionName =" to each module.

The only thing I couldnt figure out how to fix was the removal of the stock modules, they are not being removed but I dont have enough 'MM foo' to know why :)

Link to comment
Share on other sites

Well, phooey. :)

Thanks for figuring that out. Admittedly, I haven't messed with Karbonite in a while, so I've unfortunately been slack with testing. :wink: But, I did update my generator, so it should be corrected now. The removal of the stock modules was failing because the case was wrong on the specific tag. (it was using "converterName" instead of "ConverterName") Other than that, you were spot on.

Also, @karamazovnew, thanks for your posting as well. Should have referred back to yours and I would have done this right the first time!

In any case, new release (v0.1.4), OP is updated. As always, give me a shout if there are any more errors.

Link to comment
Share on other sites

While I have yet to test this, I am unsure that the 'conversionRate' parameter will work as expected. I've not dug into the regolith code, but I've not seen it elsewhere in example cases -- you may need to pre-compute the Input/Output units.

Secondarily, I will suggest a formatting tweak: place all converter MODULE{} blocks for a single part in a single @PART{} block.

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.

 Share

×
×
  • Create New...