Jump to content

[0.17] Electrical Energy Plugin | v1.5 (Oct 12)


Kreuzung

Ion engines...  

1 member has voted

  1. 1. Ion engines...

    • ...should stay infinite (only using energy)
      111
    • ...should use a bit of normal fuel too
      33
    • ...should use a bit of RCS fuel
      10
    • ...should have their own fuel type
      45
    • ... are for idiots (do not vote for this option!)
      8


Recommended Posts

So how exactly do I get this to work? I've installed Electrical Energy, Deep space and the Dynasat fix but nothing works. I am very confused. :(

Edit1: Realised that might be ambiguous and confusing, I meant none of the Ion Engines work. I put the battery then attach some solars, make sure they are being charged and... nothing.

Also, what is Zoxygen? I can't place some of those parts...

Thanks

Edited by AmpsterMan
Link to comment
Share on other sites

I am using the "Kerbal Space Program: Mod Manager" to install my mods. I'll try checking if those files are installed

Edit1: Fixed! So the issue was that The Mod Manager does not automatically install to the resources folder. Thank you very much for your help!

Edited by AmpsterMan
Link to comment
Share on other sites

Yeah, I have no EPS compatibility as well; so ZO2 is useless with it... well... Dynasat is useless with ZO2. You think you could do it, and make the batteries/panels able to recharge ZO2? The community would definitely appreciate it.

Link to comment
Share on other sites

Yeah, I have no EPS compatibility as well; so ZO2 is useless with it... well... Dynasat is useless with ZO2. You think you could do it, and make the batteries/panels able to recharge ZO2? The community would definitely appreciate it.
See PowerTech plugin documentation. There is EPS part type - just change couple lines in part.cfg
Link to comment
Share on other sites

I am trying to modify the DamnedAerospace propellers to work with this as a fuel source, however; I can not make them work as anything other than Ion engines, which means they are no MuMechVariableEngines which in turn means they no longer rotate. Any suggestions?

Link to comment
Share on other sites

I removed MuMech-style engines for 1.4, didn't know anyone uses them... You could take the 1.3 IonEngine.cs, rename the class and compile it with reference to zKreuzung.dll and MuMechLib.dll, I'd do it for you but it's 21:30 local time, a storm is coming and I'll be in a train for 10 hours tomorrow, so you'd have to wait 2 days.

Link to comment
Share on other sites

using System;
using System.Collections.Generic;
using UnityEngine;

public class IonEngine_MuMech : MuMechVariableEngine
{
protected override void onPartStart()
{
if (group == "Main engine")
group = "Ion engine";
stackIcon.SetIconColor(XKCDColors.Yellow);
base.onPartStart();
}
protected override void onActiveFixedUpdate()
{
if (EL_API.GetVesselEnergy(vessel) == 0)
vessels[vessel].groups[group] = false;
base.onActiveFixedUpdate();
}
public override bool RequestFuel(Part source, float amount, uint reqId)
{
if (source != this)
return false;

fuelLookupTargets.Clear();
if ((fuelConsumption2 > 0) && (fuelType2 != "") && !RequestFuelType(fuelType2, amount * (fuelConsumption2 / fuelConsumption), reqId))
{
state = PartStates.DEAD;
return false;
}
return EL_API.Consume(amount, vessel);
}
}

https://dl.dropbox.com/u/82912977/ElEnergy/IonEngine_MuMech.zip

99% untested.

Edit: Hmm, this takes very long for 4 KB...

Edited by Kreuzung
Link to comment
Share on other sites

It was an easy edit to make the Probodobodyne RTG a real, working generator. Since these are RTGs they work with a nuclear heat source and don't burn fuel, so I avoided that issue. I did run into a problem with running an Ion engine off the RTGs directly without a battery, it won't work even if the RTG produces power faster than the engine uses it. But if you put the code for a battery into the RTG part.cfg, as well as the generator code, with a very small battery storage capacity (just has to be more that the engine burn rate) you don't need any additional batteries. You can run off the RTGs alone, as should be possible.

Great news for those low-mass probes that need to fly far away from Kerbol, where solar panels don't do well. :)

Link to comment
Share on other sites

It was an easy edit to make the Probodobodyne RTG a real, working generator. Since these are RTGs they work with a nuclear heat source and don't burn fuel, so I avoided that issue. I did run into a problem with running an Ion engine off the RTGs directly without a battery, it won't work even if the RTG produces power faster than the engine uses it. But if you put the code for a battery into the RTG part.cfg, as well as the generator code, with a very small battery storage capacity (just has to be more that the engine burn rate) you don't need any additional batteries. You can run off the RTGs alone, as should be possible.

Great news for those low-mass probes that need to fly far away from Kerbol, where solar panels don't do well. :)

I'm working on something similar to this, only in a few different sizes. I've got this strange issue all of the sudden-- in my live KSP, the one I play. Energy works fine, but in my KSP test (base+my parts), even though all of the plugins are the same, the parts are the same, etc -- Energy always shows up as -1. My brain might be fried at this point. Anyone have any suggestions?

Complete fail. /resources/Kreuzung.cfg needs to be there.

I'm going to sleep.

Edited by dishycourier
Link to comment
Share on other sites

Quickly looking over the EPS concept and the new code, I managed to get an overview about the compatibilites.

Plugins that use my EL_API or similar code like PowerTech does are compatible to EPS, they charge and discharge EPS batteries the same way as they do with my batteries.

Only batteries using this plugin will not be recognized by EPS!

That means EPS sources will not recharge my batteries, nor will EPS consumers use them.

I could add full EPS compatibility, but it whould require a dependency on EPS which I don't want, considering the fact that almost everything in the new EPS version can be done using my plugin and that EPS overcomplicates things in my opinion.

Edit: Applying both the EPS one and my part module to a battery might solve the compatibility problems while keeping the mod usable for users who don't have EPS (part modules that aren't found are ignored).

Edited by Kreuzung
Link to comment
Share on other sites

So Kreuzung, I've got a working generator going, but I'd like to add a mumechvariable tank with fueltype "U235", but I can't get the fuelconsumption to work. I've tried a few things and I think I can get it to use liquid fuel (which would be okay in the long run, I guess), but as far as any type of "mystery fuel" or internal fuel hasn't worked so far.

Ideally, I'd like to have a supply of fuel inside the generator that depletes when active. Let's say, for testing purposes, and assuming I've done the math for the ratio, I'd like to get the generator to generate X points of energy or half an hour of power generation. Any ideas?

Link to comment
Share on other sites

It doesn't work with MuMech tanks, but it should work with part resources.

Try putting it in the part itself or the one above it, I dunno if having the resource below a gwnerator placed on top caused my problems while testing.

Edited by Kreuzung
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...