Jump to content

[KSP 1.12.4] On Demand Fuel Cells (ODFC) - 1.2.99.1-prerelease - `<BlackOut>` edition [26 Dec 2022]


zer0Kerbal

Recommended Posts

On Demand Fuel Cells (ODFC) KSP version License
Curseforge GitHub SpaceDock CKAN
Pages

On Demand Fuel Cells (ODFC)

By zer0Kerbal, originally by @`Orum

adopted with express permission and brought to you by KerbSimpleCo

OnDemandFuelCells Hero

Preamble by Orum

On Demand Fuel Cells (ODFC) is a plugin to simulate fuel cells in Kerbal Space Program (KSP), and do a better job of it than stock's use of a resource converter. The main difference is it only generates electricity when it's really needed (batteries almost empty), and otherwise lets electricity of a craft float up and down, as it might in a solar powered vehicle when the sun is eclipsed by another celestial body. It also allows fuel cells to generate byproducts, aimed at supporting life support mods like TACLS.

The plugin requires a set of Module Manager patches to function, as it does not do anything unless integrated into a part. There are two different sets of patches available on CKAN or SpaceDock. One set that copies the fuel cells from Stock, Universal Storage 2, Jatwaa Demolitions Co, and Solid Fuel Cells (soon more) and replaces the stock modules with ODFC with three modes (four if Community Resource Pack is installed correctly) of operation. Also adds a 0.5 EC/s multimode fuel cell to all stock command pods (easily disabled since in separate patch) Another set that modifies the same set of parts instead of copying them.

Features

  • adjustable fuel cell use - much more than just On/Off operation
  • multiple fuel modes (serial usage - one mode at a time)
  • variable activation threshold
  • configurable to produce byproducts (so O+H2 = EC + H2O)
  • very small memory footprint
  • Brown and Black out protection assistance
  • PAW (Part Action Window / Right Click Menu) grouping with auto collapse, click the down arrow to drop the ODFC control panel down (KSP 1.7.1).
  • Two new features from the game settings:
    • Stall: fuel cell stops working if vessel total electric charge falls to close to zero (0f) and will not start until there is more electric charge. Fuel cells require EC to work.
    • autoSwitch: automatically switched fuel mode looking for fuel if the current mode becomes fuel deprived.
  • more features coming soon

See More

Help Wanted

  • Compatibility patches
  • Contracts for these glorious parts
  • Marketing Images and Videos such as hero shots, animated gifs, short highlight
  • Have a request? Glad to have them, kindly submit through GitHub.

Localization

  • English English
  • your translation here

HELP WANTED - See the README in the Localization folder or the Quickstart Guide for instructions for adding or improving translations. GitHub push is the best way to contribute. Additions and corrections welcome!


Installation Directions 1

Use CurseForge/OverWolf App (currently does not install dependencies)

CurseForge/OverWolf App

Whilst I agree CKAN is a great mod for those that can't use zip tools. I take no part, nor am I interested in maintaining the CKAN mod metadata for my mods. Please don't ask me about it but refer to the CKAN mod thread if you are having issues with CKAN or the metadata it maintains. Beware, CKAN can really mess up though it tries very, very, very hard not to.

or CKAN

Dependencies

Supports

Suggests (These mods have Fuel Cells)

Does not work with parts from (because they use own generation MODULES)

  • Kethane
  • USI
  • @Angel-125's mods (Buffalo, Pathfinder, et al)

CONFLICTS

  • [ODFC-Refueled-CopyPatches][ODFC-C]
  • [ODFC-Refueled-ModifyPatches][ODFC-M]

REPLACES

Tags

plugin, config, flags, agency, control, convenience, sound, resources

red box below is a link to forum post on how to get support

How to get support

Be Kind: Lithobrake, not jakebrake! Keep your Module Manager up to date

Credits and Special Thanks

Known Issue Tracker

  • [NEW][BUG 1.1.2.1a] AmpYear doesn't seem to recognize ODFC
  • [BUG 1.1.2.0a] TweakScale will not scale module ODFC
  • [BUG 1.1.2.0b] Kerbalism doesn't recognize ODFC, ODFC still functions correctly
  • [BUG 0.0.1.9a] B9 doesn't work on ODFC enabled parts
  • [BUG 0.0.1.9b] next fuel mode should not be visible when only one mode
  • [BUG 0.0.1.6a] BackgroundProcessing or Background Resources mods don't see ODFC, so ODFC doesn't work when doesn't have focus. Should not have both BackgroundProcessing and BackgroundResources installed.
  • any mod that requires to use onLoad() instead of onStart() to update a part

Legal Mumbo Jumbo (License provenance)

 

  Reveal hidden contents

 


How to support this and other great mods by zer0Kerbal

Support Github Sponsor Patreon Buy zer0Kerbal a snack


Connect with me

Track progress: issues here and projects here along with The Short List

zer0Kerbal | kerbalspaceprogram.comzer0Kerbal | CurseForgezer0Kerbal | redditzer0Kerbal | Patreonzer0Kerbal | YouTubezer0Kerbal | Twitchzer0Kerbal | PayPalzer0Kerbal | Buy Me a Coffeezer0Kerbal | Twitter

 


  1. this isn't a mod. ;P↩︎

  2. may work on other versions (YMMV)↩︎

  3. Be Kind: Lithobrake, not jakebrake! Keep your Module Manager up to date!↩︎

  •  
Edited by zer0Kerbal
new release.
Link to comment
Share on other sites

reserved for changelog (full changelog here):

v1.2.0.0 - To Go Boldly (KSP 1.8.1 + .NET Framework 4.8)

Released on 2019-11-30

*See ChangeLog for full details of mod changes*

  • update to .NET Framework 4.8
  • update to Kerbal Space Program (KSP) 1.8.1.
  • update .csproj: Reference Include="$(DevDir)\KSP_x64_Data\Managed\UnityEngine*.dll" /
  • now can enter numbers instead of using slider by using the # on PAW
  • recompile for KSP 1.8.1
  • Known Issue Tracker
    • [NEW][BUG 1.1.2.1a] AmpYear doesn't seem to recognize ODFC
    • [BUG 1.1.2.0a] TweakScale will not scale module ODFC
    • [BUG 0.0.1.9a] B9 module swapping - needs onLoad etc update to make work
    • [BUG 0.0.1.9b] next fuel mode should not be visible when only one mode
    • [BUG 0.0.1.6a] Does not seeming work with BackgroundProcessing or Background Resources mods (being looked at) (so ODFC doesn't work when doesn't have focus). Should not have both BackgroundProcessing and BackgroundResources installed.
    • [BUG 1.1.2.0b] Kerbalism doesn't recognize ODFC, ODFC still functions correctly

Feature Request Tracker
 + AYA integration
 + Add Heat production
 + Convert to On-Demand Resource Converter (still base of ODFC) by either adding or modifying

 

v1.1.2.1 - Set SCE to AUX

  Reveal hidden contents

v1.1.2.0 -Stall Alert! aka Stall Tactics

  Reveal hidden contents

v0.0.1.9 (this is actually 1.1.1.9 and next release will switch to 1.1.2.0)

  Reveal hidden contents

v.0.0.1.8

  Reveal hidden contents

v.0.0.1.7

  Reveal hidden contents

v.0.0.1.6

  Reveal hidden contents

v.0.0.1.5

  Reveal hidden contents

v.0.0.1.4

  Reveal hidden contents

v.0.0.1.3

  Reveal hidden contents

v.0.0.1.2

  Reveal hidden contents

v.1.0.1.1 - >-- ORIGINAL --<

  Reveal hidden contents

v.0.0.1.0 - >-- ORIGINAL --<

  Reveal hidden contents

 

Edited by zer0Kerbal
Link to comment
Share on other sites

Would you kindly help us out by trying this plugin (and the non-game breaking copied parts) and telling us what you think?

Here is a Betatest / Checklist to assist you: To make things easier, have added link to github version of this checklist.
 

  Reveal hidden contents
Edited by zer0Kerbal
Link to comment
Share on other sites

 

This discussion concerns .1 meter high stack fuel cells.

Each module contains the fuel cell, fuel tank (in units) and a battery module. These will be released shortly in another (related) parts only mod which is being prepped for release.

I want your input as to the game balance of each of the sizes, and where on the tech tree they should appear

Don't want to use Tweakscale on these due to the need for fine tuning game balance.

Fuselage versions (mk0-mk5) are included just in case a model/texture can be found/provided that will allow these to be created/included.

Thank you in advance!

image.png

 

For comparison

Stock Fuel Cell:

  • cost:  750
  • entry cost:  2250
  • techRequired: Electrics
  • mass:    0.05
  • EC/s Produced:    1.5       
  • EC storage: 50

Stock Fuel Cell Array:

  • cost:  4500
  • entry cost:  13500
  • techRequired: Electrics
  • mass:    0.24
  • EC/s Produced:    18      
  • EC storage: 300
Edited by zer0Kerbal
Link to comment
Share on other sites

Niiice...i hate stock fuel cell logic. This is superb. Honestly i dont think new parts should be a big deal. My vote is simply for the plugin and providing cfgs that optionally clones/replaces modules or does a full swap of modules alltogether with no cloning. Im certain there are a plethora of mods out there that adds a fuelcell part. To be kind and ask if you can make a cfg for said part for this plugin and g2g. Universal storage2 for example? I really like his modeling and texturing and im almost positive theres a fuelcell in that mod pack.

Edited by Jesusthebird
Link to comment
Share on other sites

  On 8/27/2019 at 4:26 AM, Jesusthebird said:

Niiice...i hate stock fuel cell logic. This is superb. Honestly i dont think new parts should be a big deal. My vote is simply for the plugin and providing cfgs that optionally clones/replaces modules or does a full swap of modules alltogether with no cloning. Im certain there are a plethora of mods out there that adds a fuelcell part. To be kind and ask if you can make a cfg for said part for this plugin and g2g. Universal storage2 for example? I really like his modeling and texturing and im almost positive theres a fuelcell in that mod pack.

Expand  

thank you for the response. I like those models/textures very much as well.

done. already included is one patch (+PART) for the two stock fuel cells.

done. There are two - the PEM and the Akaline Fuel Cells are included in Universal Storage 2. US2 support is fully uploaded to the github repo for the next version. I made sure to keep the specification true to the original. I have (briefly) tried them in game, but forgot to see if they change size like most of the other parts do (they don't). I will look at US(the original) and see if a patch for those parts is warranted (it is).

Both patches add Monopropellent / LFO / Liquid Fuel + Intake Air / and if you have Community Resource Pack installed - Hydrogen+Oxygen=EC+Water.

Currently the patch is a (+PART), but will add an update(@PART) optional version as well. I don't know which version should be default, the copy or modify patch.

Believe it or not, I have been hard pressed to find other *current* mods with fuel cell parts. Am currently busy updating one that will remedy that. Just want someone to update the textures. :D

What about adding a ODFC patch to include a fuel cell in stock pods?

Edited by zer0Kerbal
Link to comment
Share on other sites

Hmm tough call on the default...

My 2cents? I think @part should be default as the aim of this mod is to change the logic of the fuelcells anyways. If anyone wants the additional cloning to keep the stock logic in addition..an extra set of cfgs are simple enough to add in. I think if its ckan indexed this would be the easier route too. 1 install to change..2 to change and clone. Only stipulation being the mm configs possibly needing different syntax to patch correctly and in proper order if cloning is wanted.

 

I dont have much experience with fuelcells honestly...and i could be totally wrong here as i could be thinking of respurce converters like isrus.. But off the top of my head as im not at my computer these mods could contain fuelcells:

Near future electric??

Opt??

Kas/kis??

Stockalike mining extention??

Planetary base systems??

USI??

 

I have all of these installed so when i get home ill check it out and report back

Edited by Jesusthebird
Link to comment
Share on other sites

Universal Storage has one fuel cell (alkaline). it produces 16 EC/s max.

done. have created the copy patch however, ssomething is not quite adding up with the consumption so will be asking @Paul Kingtiger about the discrepancies between US and US2 fuel cell consumption.

  On 8/27/2019 at 6:26 PM, Jesusthebird said:

My 2cents? I think @part should be default as the aim of this mod is to change the logic of the fuelcells anyways. If anyone wants the additional cloning to keep the stock logic in addition..an extra set of cfgs are simple enough to add in. I think if its ckan indexed this would be the easier route too. 1 install to change..2 to change and clone. Only stipulation being the mm configs possibly needing different syntax to patch correctly and in proper order if cloning is wanted.

Expand  

I was thinking the same, three CKAN entries - ODFC (core, copy, edit). This way no special coding is needed (except for the timing of the patches maybe)

  1. just the core .dll and generic utility patches
  2. option one - copy existing fuel cells
  3. option two - patch existing fuel cells
  On 8/27/2019 at 6:26 PM, Jesusthebird said:

Near future electric??

Opt??

Kas/kis??

Stockalike mining extention??

Planetary base systems??

USI??

Expand  

Thank you for the suggestions, will also look at @CobaltWolf's voluminous and wonderful BDB mod for fuel cells later. Found two fuel cells (one in Gemini, the other in Apollo)

  • NFE one would think nfe would - but I've looked through all of @Nertea's glorious NF mods, and no fuel cells.
  • KAS/KIS - again nothing.
  • SME - nadda correction - 3xGenerator - patching
  • Planetary Base Systems by @Nils277 might - didn't see any
  • USI - by @RoverDude might - checking - yes but uses own system.
  • @Angel-125's Buffalo (et al) might have has fuel cells, pretty sure they do, but they use their own module
  • Feline Utility Rover also by @Nils277 might have fuel cells (didn't see any)
  • KSPEi might as well.

I have also added a Mk2 and Mk3 .(25m ish) fuel cell fuselage part (both with and without ODFC) into Hot Beverages (soon to be released) parts pack.

I plan on releasing v.0.0.1.9 just as soon as I have the final numbers for the US(original) fuel cell. Should have both types of patches, and a slight adjustment to the PAW (having <<PREV>> above <<NEXT>> was driving me nuts)

 

 

Edited by zer0Kerbal
Link to comment
Share on other sites

Found two fuel cells in Bluedog Design Bureau (BDB); one in Gemini, the other in Apollo.

added StockPods.cfg - which copies most stock command pods and inserts a very small ODFC into each pod. Specs will be posted later for comment. Again, will see if can provide a +PART and a @PART patch.

Seems RLA has a MP fuelcell. Adding it. :)

Edited by zer0Kerbal
Link to comment
Share on other sites

Hello,

First Thank you for this great mod!

 

Does this mod work with this mod, too, or do it need a MM-patch or something else?

 

I don't want to bother you, but I'm working on setting up a new install (after not having played KSP for over 12 moths) and I was wondering, if there will be a new update in the next days/weeks...

(For the other fuel cells and on CKAN?)

Or at least a rough ETA of some sort...

Link to comment
Share on other sites

  On 8/30/2019 at 5:40 AM, N3N said:

Hello,

First Thank you for this great mod!

 

Does this mod work with this mod, too, or do it need a MM-patch or something else?

...

I don't want to bother you, but I'm working on setting up a new install (after not having played KSP for over 12 moths) and I was wondering, if there will be a new update in the next days/weeks...

(For the other fuel cells and on CKAN?)

Or at least a rough ETA of some sort...

Expand  

You are welcome.

Haven't tried, but there is no reason why it shouldn't - yes, it would need a  MM-patch - but that should be simple enough.

here is the patch - untested, kindly tell me if it works for you: (github)

Also - if the patch works (it should), suggest sending it to @Rocket Witch to include with the mod.

  Reveal hidden contents

I am planning on releasing ODFC v.0.0.19 this weekend to Spacedock and CKAN. It should be stable - been no complaints or bugs reported so far in this brief beta.

The release should include this patch, and others for stock and several other mods fuel cells.

I am also attempting to release stack mounted fuel cells (not the mods name) also this weekend.

The last major issue is with BackgroundProcessing, and that is something that is being looked into, and is probably going to take an update to BackgroundProcessing itself.

Hope this helps. Welcome back!

Edited by zer0Kerbal
Link to comment
Share on other sites

  On 8/30/2019 at 6:27 AM, zer0Kerbal said:

You are welcome.

Haven't tried, but there is no reason why it shouldn't - yes, it would need a  MM-patch - but that should be simple enough.

here is the patch - untested, kindly tell me if it works for you: (github)

Also - if the patch works (it should), suggest sending it to @Rocket Witch to include with the mod.

  Reveal hidden contents

I am planning on releasing ODFC v.0.0.19 this weekend to Spacedock and CKAN. It should be stable - been no complaints or bugs reported so far in this brief beta.

The release should include this patch, and others for stock and several other mods fuel cells.

I am also attempting to release stack mounted fuel cells (not the mods name) also this weekend.

The last major issue is with BackgroundProcessing, and that is something that is being looked into, and is probably going to take an update to BackgroundProcessing itself.

Hope this helps. Welcome back!

Expand  

Hey,

Thank you for your great and fast work! :wink:

Link to comment
Share on other sites

update:

attempting to install a B9 MODULE switch into the patches, there is an issue with compatibility - ODFC does things in onStart() that B9(and maybe other mods) needs done in onLoad() (and other changes).

@blowfish is being very, very, very patient with my lack of C# programing skills(thank you).
working on it.

Am also working with @Lisias to bring in Tweakscale patches using the new generator scaling.

 

The current plan is to release the plugin (.dll) /nakid/ meaning without any parts or patches, but also release two sets of patches as separate releases - I just don't know how to do this, yet.

  1. one that replaces part's existing fuel cells with ODFC versions
  2. one that copies existing parts and replaces the existing fuel cells with ODFC versions
Edited by zer0Kerbal
Link to comment
Share on other sites

moderators - kindly move this thread into Add on releases.

On Demand Fuel Cells Refueled

OndDemandFuelCellsRefueledOndDemandFuelCellsRefueledOndDemandFuelCellsRefueled

v.0.0.1.9 - Start 'em up! Oh you glorious Fuel Cells!

(this is actually 1.1.1.9 and next release will switch to 1.1.2.0)

  • added item grouping in PAW.
  • [NEW][BUG 0.0.1.9a] - B9 module swapping - needs onLoad etc update to make work
  • [NEW][BUG 0.0.1.9b] next fuel mode should not be visible when only one mode
  • [D][BUG 0.0.1.9c] mangled config caused this. added error checking in cfg.cs - thank you LGG for this code.
  • [NEW][BUG 0.0.1.9c] ERROR!'s out when there is only one fuel mode. Stock pod patch only adds one mode (monoprop - because pods usually have monoprop if they have any fuel). This bug was temporarily fixed by added a second mode(it can be the same as the first so it appears like there only one fuel mode) in the patch (LFO).
  • Split patches into two categories, copy (green text) and modify (blue text)
  • Copy/Modify patches all add 50 cost, 0.001 mass, 5 EC battery, and 5 MP tank to all parts, even if part already has a battery / monoPropellant tank.
  • Release to Beta-Testers
  • Added support for the following: JatwaaDemolitionsCo, SolidFuelCell, StockPods, UniversalStorage2
  • Patches coming for the following: Bluedog Design Bureau, RLA, MiningExpansion, UniversalStorage
  • ad hoc, ergo promptus hoc: dropping the 'v' on all future version numbering
  •  
  • Known Issue Tracker
    • [BUG 0.0.1.6a] Does not seeming work with BackgroundProcessing or Background Resources mods (being looked at) (so ODFC doesn't work when doesn't have focus). Should not have both BackgroundProcessing and BackgroundResources installed.
    •  

 


Kerbal Space Program 1.7.3

Unity 2017.1.3p1

.NET 3.5

Edited by zer0Kerbal
Link to comment
Share on other sites

  On 9/3/2019 at 5:42 PM, Snark said:

Hi @zer0Kerbal,

Looks like a fun mod!  :)

In accordance with our add-on posting rules, however, can you please add a source code link to your OP above? Thanks!

Expand  

thank you. :D

isn't it already there? Done.

Would you be so kind @Snark to move this thread to Add on releases? Thank you in advance.

Edited by zer0Kerbal
Link to comment
Share on other sites

  On 9/3/2019 at 7:56 PM, zer0Kerbal said:

isn't it already there? Done.

Expand  

Close, but not quite.  First, saying "github" doesn't automatically mean "source code"-- it's perfectly possible for people to host files on github without putting source code there.  So please just say "source code here" rather than "github here".

Second, please make a link to the actual source code, not to a releases page.  Not everyone knows how to navigate their web interface.  That is, use this link:

https://github.com/zer0Kerbal/ODFCr

^ that right there's to the code, which is what we're after.  Take care of that and we're happy to move it across.  :)

Link to comment
Share on other sites

  On 9/3/2019 at 8:42 PM, Snark said:

Close, but not quite.  First, saying "github" doesn't automatically mean "source code"-- it's perfectly possible for people to host files on github without putting source code there.  So please just say "source code here" rather than "github here".

Second, please make a link to the actual source code, not to a releases page.  Not everyone knows how to navigate their web interface.  That is, use this link:

https://github.com/zer0Kerbal/ODFCr

^ that right there's to the code, which is what we're after.  Take care of that and we're happy to move it across.  :)

Expand  

thank you for the explanation. :D  :rep:

Done. Put it at the bottom of the post after your first post. :D

  Reveal hidden contents

 

Link to comment
Share on other sites

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