Jump to content

Way to combine a resource in a part's RESOURCE section


Recommended Posts

Is there a built in way, or a mod .dll that allows one to define an amount of a resource on a part, but have that total amount be taken up by more than one resource.

For example, let's say you have MineralA and MineralB, and have a Storage Bin part. What would be nice would be to say something like:

RESOURCE{

name=MineralA

and

name=MineralB

amount=0

maxAmount=10

}

That way the part would hold MineralA and MineralB, but together they can only reach a max amount of 10, be it 1%:99% or 50%:50%.

I suspect this does not currently exit, but thought I'd check first.

Link to comment
Share on other sites

Hm, this isn't possible stock, but I think it might be possible using MFS. Else it would be rather easy to do via plugin. Something like this perhaps:

DUAL_RESOURCE
{
nameA = mineralA
nameB = mineralB
densityA = 0.01
densityB = 0.02
}

and then in the config:

MODULE
{
name = ModuleDualResource
maxAmount = 10
amountA = 0
amountB = 0
}

You'd just have to define everything in a .dll and set that amountA + amountB <= maxAmount.

EDIT: Okay, I'm tired. Above makes no sense. Would probably make more sense this way:

RESOURCE_DEFINITION
{
name = mineralA
density = 0.01
flowMode = NO_FLOW
transfer = NONE
}

RESOURCE_DEFINITION
{
name = mineralB
density = 0.0
flowMode = NO_FLOW
transfer = NONE
}

and then in the config:

MODULE
{
name = ModuleDualResource
maxAmount = 10
resourceA = mineralA
resourceB = mineralB
amountA = 0
amountB = 0
}

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