Jump to content

ModuleManager help needed. Can't figure out why simple patch doesn't work.


Recommended Posts

I can't figure out what's wrong with the syntax in the following patch:

Spoiler

@PART[*]:HAS[RESOURCE[ElectricCharge]]:Final

{

    @RESOURCE[ElectricCharge]

    {

        amount *= 10

    }

}

This is inside of a .cfg file in my GameData folder. It is supposed to multiply electric charge by ten in all parts which have electric charge. It is not working, and I cannot figure out why. It doesn't even appear to show up in my ModuleManager log; there's no error message, it just seems to be getting ignored completely. If the syntax is wrong somehow, I can't figure out why. If the syntax is not wrong, what else could be causing a patch to be completely ignored?

Link to comment
Share on other sites

The HAS part needs an @ to match the resource. Editing amount needs another @. And you'd probably want to increase maxAmount, too.

@PART[*]:HAS[@RESOURCE[ElectricCharge]]:FINAL
{
    @RESOURCE[ElectricCharge]
    {
        @amount *= 10
        @maxAmount *= 10
    }
}

 

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