Jump to content

Developing a modular engine mod


Recommended Posts

1 hour ago, bananasrawesome said:

[ERR 09:19:18.681] Module ModuleEngines threw during OnLoad: System.ArgumentException: The requested value 'hotGas' was not found.
  at System.Enum.Parse (System.Type enumType, System.String value, Boolean ignoreCase) [0x00000] in <filename unknown>:0 
  at System.Enum.Parse (System.Type enumType, System.String value) [0x00000] in <filename unknown>:0 
  at ModuleEngines.OnLoad (.ConfigNode node) [0x00000] in <filename unknown>:0 
  at PartModule.Load (.ConfigNode node) [0x00000] in <filename unknown>:0 

Did you also try to create a modded engine that runs on hotGas? This is another enum parsing error, this time in ModuleEngines; some property is being set to hotGas that doesn't allow that value. My guess is it's EngineType, which only allows:

  • Generic 
  • SolidBooster 
  • LiquidFuel 
  • Piston 
  • Turbine 
  • ScramJet 
  • Electric 
  • Nuclear 
  • MonoProp 

https://kerbalspaceprogram.com/api/_module_engines_8cs.html

Link to comment
Share on other sites

2 minutes ago, HebaruSan said:

Did you also try to create a modded engine that runs on hotGas? This is another enum parsing error, this time in ModuleEngines; some property is being set to hotGas that doesn't allow that value. My guess is it's EngineType, which only allows:

  • Generic 
  • SolidBooster 
  • LiquidFuel 
  • Piston 
  • Turbine 
  • ScramJet 
  • Electric 
  • Nuclear 
  • MonoProp 

https://kerbalspaceprogram.com/api/_module_engines_8cs.html

No. The engine seemed to work fine when provided with the hotGas resource by enabling infinite fuel and using the combustion chamber part like an isru. I did change the type to hotGas. I'll try the LiquidFuel type.

Link to comment
Share on other sites

42 minutes ago, bananasrawesome said:

It's a simple definition. Code:

RESOURCE_DEFINITION
{
  name = hotGas
  title = Hot Gas
  abbreviation = HG
  density = 0.005
  unitCost = 0
  hsp = 0
  flowMode = STAGE_PRIORITY_FLOW
  transfer = NONE
  isTweakable = false
  volume = 5
}

Is it possible to make a fuel cell start start automatically?

with out seeing the parts and how you are using them is alittle hard but change  ( transfer = PUMP )   and on your pump for now you could try and //fuelCrossFeed = False   for now you can tweak it later ?

31 minutes ago, HebaruSan said:

Did you also try to create a modded engine that runs on hotGas? This is another enum parsing error, this time in ModuleEngines; some property is being set to hotGas that doesn't allow that value. My guess is it's EngineType, which only allows:

  • Generic 
  • SolidBooster 
  • LiquidFuel 
  • Piston 
  • Turbine 
  • ScramJet 
  • Electric 
  • Nuclear 
  • MonoProp 

https://kerbalspaceprogram.com/api/_module_engines_8cs.html

I might be wrong and more then likely I am but my best guess in playing around with them is that that's what adds a little shake to your craft has there is also a atmosphereCurve key = ***** with them too  and by any chance you know what all can have EXPERIENCE_TRAIT ?  Can parts have traits ?

EDIT- I see there is a so call mod that adds this 

@EXPERIENCE_TRAIT[Pilot]:Needs[SQUAD]:Final
{
	%EFFECT[FuelUsage]
	{
		%modifiers = 0.99, 0.97, 0.94, 0.90, 0.85
	}	
}

I found where that is even listed ?

Edited by Mecripp2
Link to comment
Share on other sites

5 minutes ago, MeCripp said:

with out seeing the parts and how you are using them is alittle hard but change  ( transfer = PUMP )   and on your pump for now you could try and //fuelCrossFeed = False   for now you can tweak it later ?

I think I fixed the resource error but the generator won't work. Here's the combustion chamber cfg:

http://www.mediafire.com/file/uu916rouldxou9d/combustionChamberA.cfg

Link to comment
Share on other sites

33 minutes ago, HebaruSan said:

I'm pretty sure MODULE should be in ALL CAPS. This may or may not fix it, but it's the first thing I'd try.

That made it work, but when I replaced resource ElectricCharge with resources LiquidFuel and Oxidizer the generator said there wasn't enough of those when I right-clicked on the part even though I had a big fuel tank on the ship. The generator doesn't seem to work when given two input resources.

Link to comment
Share on other sites

58 minutes ago, bananasrawesome said:

Here's a snapshot of the mod. Since it only contains three test parts and cfg files which are "incomplete", don't expect anything fancy. I'll have a lot more done a few days from now.

https://www.mediafire.com/file/ddx8yiilr59wy5e/Modular Rocket Engines.zip

If you use TextureReplacerReplacer try this 

Spoiler
Spoiler
@PART[combustionChamberA]:HAS[!MODULE[TRR_Reflection]]:NEEDS[TextureReplacerReplaced]
{
 %MODULE[TRR_Reflection]
 {
%name = TRR_Reflection
%shader = ShaderNG/TR_Reflective_Emissive_Alpha
%colour = 0.5 0.5 0.5
%interval = 1
%meshes =
 }
}
@PART[engineNozzleA]:HAS[!MODULE[TRR_Reflection]]:NEEDS[TextureReplacerReplaced]
{
 %MODULE[TRR_Reflection]
 {
%name = TRR_Reflection
%shader = ShaderNG/TR_Reflective_Emissive_Alpha
%colour = 0.5 0.5 0.5
%interval = 1
%meshes =
 }
}
@PART[enginePlateA]:HAS[!MODULE[TRR_Reflection]]:NEEDS[TextureReplacerReplaced]
{
 %MODULE[TRR_Reflection]
 {
%name = TRR_Reflection
%shader = ShaderNG/TR_Reflective_Emissive_Alpha
%colour = 0.5 0.5 0.5
%interval = 1
%meshes =
 }
}

 

 

Link to comment
Share on other sites

1 hour ago, Bottle Rocketeer 500 said:

@bananasrawesome A spelling mistake caused the generator to be deprived of "Elictric Charge".  Also, the models and textures so far aren't really that nice. 

Yeah, I know. I'll work hard on new models and textures once I get everything working. I forgot to fix the electric charge thing, though.

Link to comment
Share on other sites

@linuxgurugamer I ran into a few issues. In order for the combustion chamber to not produce hot gas without wasting the fuel, it must be staged, and too many staged parts could get annoying. Instead, I could add a fuel injector part type which could throttle the amount of fuel going into the combustion chamber as resource mixed fuel (since lfo mixes in the combustion chamber) and could be staged enabling the rest of the engine. Of course, that would cause a couple of other issues later on, but extra parts won't have to be staged.

Never mind the above (much), I know Java and C++ so C# won't be much of an issue. I'll make a plugin that will make this work.

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