Jump to content

Developing a modular engine mod


Recommended Posts

3 minutes ago, MeCripp said:

Did you make a Resources cfg for you new Resources ?

Yeah. Here's the code:

RESOURCE_DEFINITION
{
  name = hotGas
//  title = EnginePlasma
//  abbreviation = EP
  density = 0.005
  unitCost = 0
//  hsp = 0
  flowMode = STACK_PRIORITY_FLOW
  transfer = NONE
  isTweakable = false
//  volume = 5
}
 

Link to comment
Share on other sites

Just now, bananasrawesome said:

Yeah. Here's the code:

RESOURCE_DEFINITION
{
  name = hotGas
//  title = EnginePlasma
//  abbreviation = EP
  density = 0.005
  unitCost = 0
//  hsp = 0
  flowMode = STACK_PRIORITY_FLOW
  transfer = NONE
  isTweakable = false
//  volume = 5
}
 

Try changing STACK_PRIORITY_FLOW to STAGE_PRIORITY_FLOW.

[EXC 11:47:13.362] ArgumentException: The requested value 'STACK_PRIORITY_FLOW' was not found.
	System.Enum.Parse (System.Type enumType, System.String value, Boolean ignoreCase)
	System.Enum.Parse (System.Type enumType, System.String value)
	PartResourceDefinition.Load (.ConfigNode node)
	PartResourceDefinitionList.Add (.ConfigNode node)
	PartResourceLibrary.LoadDefinitions ()
	GameDatabase+<CreateDatabase>c__Iterator49.MoveNext ()
	UnityEngine.SetupCoroutine.InvokeMoveNext (IEnumerator enumerator, IntPtr returnValueAddress)

http://wiki.kerbalspaceprogram.com/wiki/CFG_File_Documentation#Resource_Configuration_Files

Link to comment
Share on other sites

9 minutes ago, HebaruSan said:

Try changing STACK_PRIORITY_FLOW to STAGE_PRIORITY_FLOW.


[EXC 11:47:13.362] ArgumentException: The requested value 'STACK_PRIORITY_FLOW' was not found.
	System.Enum.Parse (System.Type enumType, System.String value, Boolean ignoreCase)
	System.Enum.Parse (System.Type enumType, System.String value)
	PartResourceDefinition.Load (.ConfigNode node)
	PartResourceDefinitionList.Add (.ConfigNode node)
	PartResourceLibrary.LoadDefinitions ()
	GameDatabase+<CreateDatabase>c__Iterator49.MoveNext ()
	UnityEngine.SetupCoroutine.InvokeMoveNext (IEnumerator enumerator, IntPtr returnValueAddress)

http://wiki.kerbalspaceprogram.com/wiki/CFG_File_Documentation#Resource_Configuration_Files

Or they could go STACK_PRIORITY_SEARCH

EDIT- And it would be best to make just a stock install when you are testing new stuff 

Edited by Mecripp2
Link to comment
Share on other sites

7 minutes ago, HebaruSan said:

Try changing STACK_PRIORITY_FLOW to STAGE_PRIORITY_FLOW.


[EXC 11:47:13.362] ArgumentException: The requested value 'STACK_PRIORITY_FLOW' was not found.
	System.Enum.Parse (System.Type enumType, System.String value, Boolean ignoreCase)
	System.Enum.Parse (System.Type enumType, System.String value)
	PartResourceDefinition.Load (.ConfigNode node)
	PartResourceDefinitionList.Add (.ConfigNode node)
	PartResourceLibrary.LoadDefinitions ()
	GameDatabase+<CreateDatabase>c__Iterator49.MoveNext ()
	UnityEngine.SetupCoroutine.InvokeMoveNext (IEnumerator enumerator, IntPtr returnValueAddress)

http://wiki.kerbalspaceprogram.com/wiki/CFG_File_Documentation#Resource_Configuration_Files

Thank you very much, it works! I have a few bugs with the parts, but I can fix those.

6 minutes ago, Bottle Rocketeer 500 said:

I knew it! That's what the dll is for! Is it your man Steam install or just a backup. If it's a backup, delete the dll. Can you try deleting everything from the game data folder except for the squad folder and your mod's folder?

I backed up the main one, deleted some stuff and will restore the backup unless I find a more efficient way of using installations.

Link to comment
Share on other sites

Just wanted to stop by to say that I think this is an absolutely awesome idea for a mod. People have been kicking around the idea of procedural engines for a few years, but as far as I know, nobody has attempted to make a mod for them. This is an even better idea, getting to design our own engines piece by piece (well, more like small assemblies, since engines are made up of thousands of parts :D ).

I'm assuming we'd just save the engines as subassemblies if we want to use them later, which would be great. What about once the engine is built—any plans on some sort of "welding" mechanic when loading the craft on the launchpad, so as to reduce part count? On a multi-stage rocket with large engine clusters, the part count could inflate pretty quickly.

Subscribed, can't wait to see more progress on this.

Link to comment
Share on other sites

5 minutes ago, MeCripp said:

Or they could go STACK_PRIORITY_SEARCH

Yeah, presumably any of the values from the enum would allow the game to finish loading; there seem to be several more that the wiki doesn't know about:

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

Do you know which one would be best for this mod? The documentation isn't exactly verbose.

Link to comment
Share on other sites

1 hour ago, HebaruSan said:

Yeah, presumably any of the values from the enum would allow the game to finish loading; there seem to be several more that the wiki doesn't know about:

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

Do you know which one would be best for this mod? The documentation isn't exactly verbose.

I know it would take alot of time but it would be nice when a new update came out some where a list of all the new stuff was added it's kind of funny how you can use some of the old MODULE to do the samething as the news 

and @blorgon  nice video's 

Edited by Mecripp2
Link to comment
Share on other sites

54 minutes ago, bananasrawesome said:

I ran into an issue with my combustion chamber part. I based the cfg off of the isru stock cfg and the chamber doesn't start automatically, or at least, as a staged part. How can I do this?

You can use 

	MODULE
	{
		name = ModuleGenerator
		isAlwaysActive = true
		OUTPUT_RESOURCE
		{
			name = ******
			rate = ****
		}
	}

You can add a input also 

Edited by Mecripp2
Link to comment
Share on other sites

This does look like an interesting idea for a procedural engines mod. Am following, feel free to ping for info! :wink: 

You should talk to the folks over at Ubizo Welding to see if they could hook you up with something, either a dependency, or an incorporated thing. 

Link to comment
Share on other sites

9 minutes ago, Benjamin Kerman said:

This does look like an interesting idea for a procedural engines mod. Am following, feel free to ping for info! :wink: 

You should talk to the folks over at Ubizo Welding to see if they could hook you up with something, either a dependency, or an incorporated thing. 

Yeah I'm thinking subassembly welding is gonna be pretty necessary here. I'm super stoked for this though, even with inflated part counts.

Link to comment
Share on other sites

1 hour ago, Benjamin Kerman said:

Yeah, there still will eventually have to be a plugin i think, just because of how it works. I dont know if you are able to do it without cheesing available and bouncing stop/starts with the engines...

I'm not sure I understand, lol. Are you talking about joint strength when physics loads? What do you mean by 'cheesing'?

Link to comment
Share on other sites

15 hours ago, MeCripp said:

You can use 


	MODULE
	{
		name = ModuleGenerator
		isAlwaysActive = true
		OUTPUT_RESOURCE
		{
			name = ******
			rate = ****
		}
	}

You can add a input also 

Never mind, I'm having issues with ModuleGenerator for some reason. Here's the config:

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

I also got this error in the log:

[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 

Link to comment
Share on other sites

28 minutes ago, MeCripp said:

can you post you RESOURCE DEFINITION for your Resource ?

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?

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