Jump to content

Generator Config?


Oppum
 Share

Recommended Posts

I'm trying to make a cheaty generator part for my game, but it doesn't want to generate anything when I turn it on ingame

This is the .cfg:

	MODULE
	{
		 name = ModuleGenerator
		 OUTPUT_RESOURCE
		 {
			ResourceName = ElectricCharge
			Ratio = 999999
			rate = 999999
		 }
		 OUTPUT_RESOURCE
		 {
			ResourceName = LiquidFuel
			Ratio = 999999
			rate = 999999
		 }
		 OUTPUT_RESOURCE
		 {
			ResourceName = Oxidizer
			Ratio = 999999
			rate = 999999
		 }
		 OUTPUT_RESOURCE
		 {
			ResourceName = XenonGas
			Ratio = 999999
			rate = 999999
		 }
		 OUTPUT_RESOURCE
		 {
			ResourceName = MonoPropellant
			Ratio = 999999
			rate = 999999
		 }
	}

that's not the entire cfg, just the part that matters

How do I make it so it actually generates the resources when I turn it on ingame?

Link to comment
Share on other sites

Looking at the RTG (the closest thing to what I think you want)

	MODULE
	{
		name = ModuleGenerator
		isAlwaysActive = true
		OUTPUT_RESOURCE
		{
			name = ElectricCharge
			rate = 0.75
		}
	}

I say you should change ResourceName to name, and remove Ratio. Maybe also add isAlwaysActive = false as well. Don't know about making a button for it, or if that will happen automatically if it's not always active.

Link to comment
Share on other sites

16 hours ago, Oppum said:

How do I make it so it actually generates the resources when I turn it on ingame?

Hi below is one of my universal module setups i use when setting up new parts ,  to generate your extra resources simply add them in in the same format as the one already there . This generator only supplies when it is switched on via gui

MODULE
	{
	name = ModuleGenerator
	isAlwaysActive = false   // only active when switched on 
	statusGUIName = FuelGen  // will appear in right click menu
	activateGUIName = FuelON  // will appear in right click menu
	shutdownGUIName = FuelOff  // will appear in right click menu
	OUTPUT_RESOURCE
	{
	   name = LiquidFuel // resource
	   rate = 100	   // how much 
	}	
	OUTPUT_RESOURCE
	{
	   name = ElectricCharge
	   rate = 100
	}	
}

 

Link to comment
Share on other sites

  • 2 years later...
On 6/2/2018 at 1:46 AM, Superfluous J said:

Don't know about making a button for it, or if that will happen automatically if it's not always active.

This is necro, but I just stumbled upon this.

A launch clamp with ModuleGenerator which is set

isAlwaysActive = false

will not have a button to toggle in VAB to consider.

This must be a stock bug. Still.  In KSP 1.10.1

 

Edit:

I found it - darn, the good old AFLC patch did this mistake (never put FINAL on legacy-type patches - some old config suggestion from an old forum post was in my copy):
https://github.com/Galileo88/AlmostFreeLaunchClamps/pull/1

Edited by Gordon Dry
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...