Jump to content

Help with resin spawning


JamesB

Recommended Posts

I'm looking through the log-withresin.json to try and determine where/if I can change the spawn time of the resin blocks on pine trees.  I think I found a lead but I'm not sure if I'm reading it correctly:

attributesByType: {
		"log-resinharvested-*": {
			transientProps: {
				convertFrom: "log-resinharvested-pine-ud", 
				convertTo: "log-resin-pine-ud", 
				inGameHours: "168",

Does anyone know what exactly inGameHours is controling?

Link to comment
Share on other sites

@l33tmaan Hey so I was wondering if you could help me with something.  I'm looking at your mod as a guide.  In it the json code to replace bread nutrition:

{
    "op": "replace",
    "path": "/nutritionPropsByType/*/saturation",
    "value": 160,
    "file": "itemtypes/food/bread.json"
  }

Which is replacing values in here:

creativeinventory: { "general": ["*"], "items": ["*"] },
    nutritionPropsByType: {
        "*-flax": { saturation: 160, foodcategory: "Grain" },
        "*-rice": { saturation: 330, foodcategory: "Grain" },
        "*": { saturation: 300, foodcategory: "Grain" }
    },

I'm having trouble desiphering this line:

 "path": "/nutritionPropsByType/*/saturation",

Is this replacing all the values for "saturation"?

I'm looking at this in the log-withresin.json:

attributesByType: {
        "log-resinharvested-*": {
            transientProps: {
                convertFrom: "log-resinharvested-pine-ud", 
                convertTo: "log-resin-pine-ud", 
                inGameHours: "168",
            },
            preventsDecay: true
        },
        "*": {
            preventsDecay: true,
            forageStatAffected: true
        }
    }

So am I correct with this syntax?

{
        "op": "replace",
        "path": "/transientProps/inGameHours",
        "value": 72,
        "file": "blocktypes/wood/log-withresin.json"
    }

I'm assuming the \*\ is a wildcard to catch all the instances that have "saturation"?  So with mine I won't need that.  Correct?

Link to comment
Share on other sites

13 minutes ago, James Berkheimer said:

@l33tmaan Hey so I was wondering if you could help me with something.  I'm looking at your mod as a guide.  In it the json code to replace bread nutrition:

{
    "op": "replace",
    "path": "/nutritionPropsByType/*/saturation",
    "value": 160,
    "file": "itemtypes/food/bread.json"
  }

Which is replacing values in here:

creativeinventory: { "general": ["*"], "items": ["*"] },
    nutritionPropsByType: {
        "*-flax": { saturation: 160, foodcategory: "Grain" },
        "*-rice": { saturation: 330, foodcategory: "Grain" },
        "*": { saturation: 300, foodcategory: "Grain" }
    },

I'm having trouble desiphering this line:

 "path": "/nutritionPropsByType/*/saturation",

Is this replacing all the values for "saturation"?

I'm looking at this in the log-withresin.json:

attributesByType: {
        "log-resinharvested-*": {
            transientProps: {
                convertFrom: "log-resinharvested-pine-ud", 
                convertTo: "log-resin-pine-ud", 
                inGameHours: "168",
            },
            preventsDecay: true
        },
        "*": {
            preventsDecay: true,
            forageStatAffected: true
        }
    }

So am I correct with this syntax?

{
        "op": "replace",
        "path": "/transientProps/inGameHours",
        "value": 72,
        "file": "blocktypes/wood/log-withresin.json"
    }

I'm assuming the \*\ is a wildcard to catch all the instances that have "saturation"?  So with mine I won't need that.  Correct?

I think your path needs to be "attributesByType/*/transientProps/inGameHours". I'm not sure, though.
When it comes to patches, most of the time I just change the file in my VS installation and use the ModMaker.exe to spit something out. That usually works.

13 minutes ago, James Berkheimer said:

@l33tmaan I've also been doing some research.  It might be a good idea to add resins to your mod for the spiles.  I found this:

I have also been doing research, and I've already got something in the works. I just didn't want to spoil it here. 😉

  • Like 1
Link to comment
Share on other sites

25 minutes ago, l33tmaan said:

I think your path needs to be "attributesByType/*/transientProps/inGameHours". I'm not sure, though.
When it comes to patches, most of the time I just change the file in my VS installation and use the ModMaker.exe to spit something out. That usually works.

I have also been doing research, and I've already got something in the works. I just didn't want to spoil it here. 😉

Huh, where can I find the ModMaker?  Is that a separate download like the ModelCreator?

And sweet!  Looking forward to the updates.  :)

Link to comment
Share on other sites

9 minutes ago, l33tmaan said:

It should be wherever your VintageStory.exe is...

Huh, well fancy that!  You were close.

Thanks!

{
    "op": "replace",
    "path": "/attributesByType/log-resinharvested-*/transientProps/inGameHours",
    "value": "72",
    "file": "blocktypes/wood/log-withresin.json"
  }
Link to comment
Share on other sites

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.